From fd12aefcafbbe494511538fe209716cef554bcd9 Mon Sep 17 00:00:00 2001 From: kobakaku <82507211+kobakaku@users.noreply.github.com> Date: Mon, 13 Nov 2023 16:19:57 +0900 Subject: [PATCH] update from base repo (#3) * contracts-bedrock: deal better * op-service: fix typo in comment * contracts-bedrock: gas snapshot * op-node: static-peers list local-peer check and flag description update * proxyd: configurable IP rate limit header * op-node: static-peers test * build(deps-dev): bump hardhat from 2.18.3 to 2.19.0 Bumps [hardhat](https://github.com/nomiclabs/hardhat) from 2.18.3 to 2.19.0. - [Release notes](https://github.com/nomiclabs/hardhat/releases) - [Commits](https://github.com/nomiclabs/hardhat/compare/hardhat@2.18.3...hardhat@2.19.0) --- updated-dependencies: - dependency-name: hardhat dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] * build(deps): bump @ethereumjs/rlp from 5.0.0 to 5.0.1 Bumps [@ethereumjs/rlp](https://github.com/ethereumjs/ethereumjs-monorepo) from 5.0.0 to 5.0.1. - [Release notes](https://github.com/ethereumjs/ethereumjs-monorepo/releases) - [Commits](https://github.com/ethereumjs/ethereumjs-monorepo/compare/@ethereumjs/rlp@5.0.0...@ethereumjs/rlp@5.0.1) --- updated-dependencies: - dependency-name: "@ethereumjs/rlp" dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] * build(deps): bump viem from 1.18.2 to 1.18.3 Bumps [viem](https://github.com/wagmi-dev/viem) from 1.18.2 to 1.18.3. - [Release notes](https://github.com/wagmi-dev/viem/releases) - [Commits](https://github.com/wagmi-dev/viem/compare/viem@1.18.2...viem@1.18.3) --- updated-dependencies: - dependency-name: viem dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] * chore: Make paths references DRY * specs: clarify span-batch validation rules include upgrade activation check * specs: improve wording of upgrade activation rules * op-node: attributes queue reset state for consistency * op-e2e/actions: use interface in batcher for l2 block ref access * Usage of 'Immutable' for variables storing keccak hashes * contracts-bedrock: lite foundry profile Adds a `lite` profile for foundry that turns off the compiler optimizer. This is suitable for development purposes when the compiler is taking a long time to compile. The developer should be sure to not use this mode when doing contract deployments. To set the profile, set the env var `FOUNDRY_PROFILE=lite`. * contracts-bedrock: simplify merkle trie setup The `MerkleTrie` tests were using `CommonTest` but do not require anything besides `FFIInterface` so instead of pulling in all of the overhead of `CommonTest`, just deploy `FFIInterface` on its on in the `setUp` function. This should be a slight optimization as it reduces the amount of execution required for setup. Reducing diff from https://github.com/ethereum-optimism/optimism/pull/7928 * contracts-bedrock: migrate ffi interface * contracts-bedrock: gas-snapshot * contracts-bedrock: simplify test Simplify the `DeployerWhitelist` tests by using `Test` instead of `CommonTest`. Should slightly reduce the overhead of the tests. * contracts-bedrock: simplify rlp tests Migrates the rlp tests to use `Test` instead of `CommonTest`. This will reduce the overhead of running the test slightly. * contracts-bedrock: 1967 helper version Use a more relaxed version for the `EIP1967Helper` contract. This will make it much more portable. Part of https://github.com/ethereum-optimism/optimism/pull/7928 * fix(fm-test-services): Use lockfile in docker test * contracts-bedrock: simplify CrossDomainOwnable test Removes usage of `CommonTest` that are not required. Also canonicalize the import paths. This should help to speed up the tests slightly by reducing the amount of execution required to run the tests. * contracts-bedrock: fix * contracts-bedrock: cleanup * build(deps): bump viem from 1.18.3 to 1.18.4 Bumps [viem](https://github.com/wagmi-dev/viem) from 1.18.3 to 1.18.4. - [Release notes](https://github.com/wagmi-dev/viem/releases) - [Commits](https://github.com/wagmi-dev/viem/compare/viem@1.18.3...viem@1.18.4) --- updated-dependencies: - dependency-name: viem dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] * proxyd: add weighting feature to node selection * Review feedback * op-challenger: Remove AbsolutePreState from TraceProvider Nothing actually uses it - only AbsolutePreStateCommitment so we can narrow the interface. * op-challenger: Introduce TraceAccessor The game solver uses TraceAccessor instead of TraceProvider directly so that it has enough information to encapsulate a split trace provider game type. * op-challenger: Remove claim loader It was only used in an unused e2e helper method. * Code review feedback * op-challenger: Use FaultDisputeGameContract to retrieve cannon local inputs. * Parameterize span batch related test cases * Remove OP_E2E_USE_SPAN_BATCH env usage * build(deps): bump github.com/jackc/pgx/v5 from 5.4.3 to 5.5.0 Bumps [github.com/jackc/pgx/v5](https://github.com/jackc/pgx) from 5.4.3 to 5.5.0. - [Changelog](https://github.com/jackc/pgx/blob/master/CHANGELOG.md) - [Commits](https://github.com/jackc/pgx/compare/v5.4.3...v5.5.0) --- updated-dependencies: - dependency-name: github.com/jackc/pgx/v5 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] * build(deps): bump golang.org/x/sync from 0.4.0 to 0.5.0 Bumps [golang.org/x/sync](https://github.com/golang/sync) from 0.4.0 to 0.5.0. - [Commits](https://github.com/golang/sync/compare/v0.4.0...v0.5.0) --- updated-dependencies: - dependency-name: golang.org/x/sync dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] * build(deps): bump golang.org/x/time from 0.3.0 to 0.4.0 Bumps [golang.org/x/time](https://github.com/golang/time) from 0.3.0 to 0.4.0. - [Commits](https://github.com/golang/time/compare/v0.3.0...v0.4.0) --- updated-dependencies: - dependency-name: golang.org/x/time dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] * build(deps): bump github.com/libp2p/go-libp2p-pubsub Bumps [github.com/libp2p/go-libp2p-pubsub](https://github.com/libp2p/go-libp2p-pubsub) from 0.9.3 to 0.10.0. - [Release notes](https://github.com/libp2p/go-libp2p-pubsub/releases) - [Commits](https://github.com/libp2p/go-libp2p-pubsub/compare/v0.9.3...v0.10.0) --- updated-dependencies: - dependency-name: github.com/libp2p/go-libp2p-pubsub dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] * op-node: remove deprecated `Pretty()` call Use `String()` over `Pretty()` - https://github.com/libp2p/go-libp2p/pull/2563 - https://github.com/libp2p/go-libp2p-pubsub/issues/547 * contracts-bedrock: foundry d85718785859dc0b5a095d2302d1a20ec06ab77a Updates foundry to a version that contains the `loadAllocs` cheatcode - https://github.com/foundry-rs/foundry/pull/6207 This will unblock work on implementing test coverage against the L2 genesis generation script * contracts-bedrock: decouple magic number in test Remove the magic number `1800` in favor of a generic submission interval. Based on the test's comment, this is the expected input. Breaking this into its own test from https://github.com/ethereum-optimism/optimism/pull/7928 to show that without the rest of the diff, the test still passes to ensure that a bug doesn't sneak in. fwiw this test will likely be modified with the next release of the fault proof. * contracts-bedrock: test deploy script This updates the tests to use the deploy script to set up the L1 contracts. This ensures that the tests are testing a setup as close as possible as to what ends up in production. The L2 contracts are setup in a unified place but as not set up behind proxies yet. This has been an issue but should be addressed when we have the ability to import the output of the L2 genesis generation script. Any circleci machines that run `forge build` oom when the machine is not an xlarge. This means that many jobs need to be bumped up to that size for them to run until the end. `CommonTest` is heavily modified and cleaned up. A lot of code was deleted and a good amount of the code that was added is from moving things to kwargs sytax from not. Some tests were converted from being regular tests into fuzz tests. * contracts-bedrock: modularize L2 setup * op-bindings: regenerate * contracts-bedrock: cleanup * contracts-bedrock: gas-snapshot * invariant-docs: regenerate * contracts-bedrock: fix review nits * Pull in basic types from op-service/eth package. Co-authored-by: protolambda Co-authored-by: Roberto Bayardo * Pull in basic types from op-service/sources. Co-authored-by: Roberto Bayardo Co-authored-by: protolambda * Pull in blob and blob_test from PR. Co-authored-by: protolambda Co-authored-by: Roberto Bayardo * Revert "Pull in basic types from op-service/eth package." This reverts commit 7eccd9fbc4497b60431d7e34f15a50f56f53aee5. Co-authored-by: protolambda Co-authored-by: Roberto Bayardo * Add placeholder for dencun fork test. * Add filler scaffolding for dencun fork test: literally the old shapella test. * Start to tweak things in dencun_fork_test: mainly replacing "shanghai" with "Cancun" * More minor test tweaks: change require statement's message, get head's time differently, add a couple breadcrumb comments. * Fix usage of IsCancun. * Tweak test message: really we're just testing isCancun, so acknowledge that. * Use types.Withdrawals in rpcBlock, not eth.Withdrawals. * Flag the failing line, it's non-obvious in CI output. * Add how test is failing just for onlookers. * Add issue links per semgrep request. * WIP stash for discussion. * Commit missed hunk editing a comment in dencun_fork_test. * Remove useless call to ParentBeaconRoot. * Remove some commented-out cruft. * Set necessary header fields if config is cancun. * contracts-bedrock: lint * Preserve co-authorship. Co-authored-by: protolambda Co-authored-by: Roberto Bayardo * build(deps): bump viem from 1.18.4 to 1.18.6 Bumps [viem](https://github.com/wagmi-dev/viem) from 1.18.4 to 1.18.6. - [Release notes](https://github.com/wagmi-dev/viem/releases) - [Commits](https://github.com/wagmi-dev/viem/compare/viem@1.18.4...viem@1.18.6) --- updated-dependencies: - dependency-name: viem dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] * build(deps-dev): bump eslint from 8.52.0 to 8.53.0 Bumps [eslint](https://github.com/eslint/eslint) from 8.52.0 to 8.53.0. - [Release notes](https://github.com/eslint/eslint/releases) - [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md) - [Commits](https://github.com/eslint/eslint/compare/v8.52.0...v8.53.0) --- updated-dependencies: - dependency-name: eslint dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] * build(deps-dev): bump nx from 17.0.2 to 17.0.3 Bumps [nx](https://github.com/nrwl/nx/tree/HEAD/packages/nx) from 17.0.2 to 17.0.3. - [Release notes](https://github.com/nrwl/nx/releases) - [Commits](https://github.com/nrwl/nx/commits/17.0.3/packages/nx) --- updated-dependencies: - dependency-name: nx dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] * [indexer.api.supply_view] addressing pr feedback * [indexer.api.supply_view] Update typescript bindings * op-node: Add command to dump rollup configs * op-service: Ensure block body validation tests fail for the expected reason. Adds coverage for nil transactions and withdrawals and blocks with correct block hash but a transaction or withdrawal root that doesn't match the body. Removes the generation of body tests from the script as the generated scripts were a useful start, but ultimately ineffective at testing the code. * op-node: Fixup PGN Sepolia Rollup Config * op-node: Check withdrawals hash in P2P validation * op-service: Add unit tests for verifying receipts. * op-service/eth: Expose GasLimit from the header in BlockInfo * op-chain-ops: Canyon checker script * op-challenger: Use new contract bindings in responder * contracts-bedrock: visibility into flake A flake in CI was introduced when https://github.com/ethereum-optimism/optimism/pull/7928 was merged. It is probably due to a race condition when reading a file from disk. Is there a way to have foundry only do something once for the entire test suite? Tried moving things to the constructor instead of `setUp` but that did not work. Ideally we do not need to read the file from disk for each contract deployed, this adds a lot of overhead. A solution around this is to refactor the way that the deploy script works or to add in the env var that will skip the check that sometimes fails. * contracts-bedrock: gas snapshot * op-service: Remove attributes from warn-log in EngineClient * op-chain-ops: Better handle 1559 case * feat: move envrc to top level * feat: add getting started config script Adds a new script to contracts-bedrock that generates the deploy config for the getting started network. Removes the getting started config from the repository and avoids unnecessary work for the user while following the guide. * feat: add getting started wallet script Adds a script to contracts-bedrock that generates the four wallets required for the getting started guide. * fix: add config files to op-node gitignore Adds the common config files to op-node gitignore since these get created frequently and shouldn't be committed. * fix: strip 0x prefix when loading pk in op-node * fix: simplify loading environment vars * fix: remove private key override * feat: move scripts to getting-started folder * fix: update make version * contracts-bedrock: bump `forge-std` Bumps `forge-std` to `37a37ab73364d6644bfe11edf88a07880f99bd56`. This is not a release commit but it does include the latest change to the `Vm` such that `loadAllocs(string)` is included. Pulling this in now unblocks progress on loading in the L2 genesis state into the solidity tests. We can update the `forge-std` version to an official release in the future. All diffs are updating changes to `forge-std` so that things compile again. * op-bindings: regenerate * contracts-bedrock: invariant-docs * return check for nil tx in rpc block verification * return withdrawals check in rpc block verification. * build(deps-dev): bump @types/mocha from 10.0.3 to 10.0.4 Bumps [@types/mocha](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/mocha) from 10.0.3 to 10.0.4. - [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases) - [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/mocha) --- updated-dependencies: - dependency-name: "@types/mocha" dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] * Improve delegated attestations * Update bindings * Lock semver * remove blob.go and blob_test.go. they'll come back in in another PR when they're needed. * specs: Clarify withdrawals specs better * specs: Add receipt hash fix to the specs * specs: 1559 configuration * op-challenger: Add TraceAccessor docs and rename file. * op-challenger: Return the TraceAccessor directly from the resourceCreator Allows different game types to use a different TraceAccessor implementation. Prestate validation moved to a game type specific function returned by the resourceCreator. * build(deps): bump golang.org/x/term from 0.13.0 to 0.14.0 Bumps [golang.org/x/term](https://github.com/golang/term) from 0.13.0 to 0.14.0. - [Commits](https://github.com/golang/term/compare/v0.13.0...v0.14.0) --- updated-dependencies: - dependency-name: golang.org/x/term dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] * cannon: go mod tidy * contracts-bedrock: update eas v1.3.0 Small update to https://github.com/ethereum-optimism/optimism/pull/8085 to bump semantic version. > In this PR, we have improved delegated attestations/revocations by additionally committing to the address of the attester/revoker in the EIP712 signature itself. The recently released EAS SDK already supports this new version of delegated attestations/revocations (via ethereum-attestation-service/eas-sdk#68) * [indexer.api.supply_view] add withdrawal suppply calculations * contracts-bedrock: delete dead script Delete a dead upgrade script that is no longer used. We are moving towards `superchain-ops` for upgrade scripts instead. No reason to maintain this script anymore and have it slow down compilation time. * contracts-bedrock: update `StorageSetter` Adds a new setter that takes a list of slots to set. This allows a single `upgradeToAndCall` to be used with this contract that sets many storage slots in a single call. This will simplify future upgrades using the 2 step upgrade model. Includes fuzz tests for the new functionality. The complexity with the fuzz testing of this operation is that we cannot pass in duplicate keys, otherwise it is impossible to make assertions against because there is no way to hook in to the call. Perhaps if we had a way to see every state diff then we would be able to make assertions against that. * contracts-bedrock: update bindings + gas snapshot * op-bindings: regenerate * contracts-bedrock: fix snapshot * docs(ctb): Add network-specific to style guide * feat(ctb): reusable post-deploy checks Adds a post-deploy function to check that L1 contracts were deploy correctly. This allows both the Multichain upgrade and the devnet Deploy scripts to reuse the same checks. * op-node: flexible L2 genesis generation Allow for the `op-node` L2 genesis generation to use either hardhat artifacts or the `.deploy` L1Deployments JSON file that is created by the solidity deployment script. While adding extra logic, this makes genesis generation much easier to be consumed by the solidity scripts. It also sets up the ability to deprecate the need for maintaining hardhat deploy style artifacts. This will allow us to remove a lot of solidity code and remove the need to call `sync()` to generate the artifacts. The artifacts make less sense now, especially since it is planned to have one set of implementation contracts for the entire superchain. There isn't as much of a need to keep around artifacts for many contracts separated by network when they are shared between different L2s. * op-chain-ops: fix error formatting * check only the legacy SystemConfig interface * op-node: add description to l2 genesis command * specs: Specify create2Deployer * specs: Specify full Canyon upgrade * update bindings using CI foundry version * ci: Use xlarge box for ci-builder * op-challenger: Update expected error message. * feat(chain-mon): monitor safe nonce as a metric * op-node: gofmt files * use ethers contract wrapper * Weighted shuffle list * build(deps-dev): bump @typescript-eslint/eslint-plugin Bumps [@typescript-eslint/eslint-plugin](https://github.com/typescript-eslint/typescript-eslint/tree/HEAD/packages/eslint-plugin) from 6.9.1 to 6.10.0. - [Release notes](https://github.com/typescript-eslint/typescript-eslint/releases) - [Changelog](https://github.com/typescript-eslint/typescript-eslint/blob/main/packages/eslint-plugin/CHANGELOG.md) - [Commits](https://github.com/typescript-eslint/typescript-eslint/commits/v6.10.0/packages/eslint-plugin) --- updated-dependencies: - dependency-name: "@typescript-eslint/eslint-plugin" dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] * build(deps): bump github.com/onsi/gomega from 1.29.0 to 1.30.0 Bumps [github.com/onsi/gomega](https://github.com/onsi/gomega) from 1.29.0 to 1.30.0. - [Release notes](https://github.com/onsi/gomega/releases) - [Changelog](https://github.com/onsi/gomega/blob/master/CHANGELOG.md) - [Commits](https://github.com/onsi/gomega/compare/v1.29.0...v1.30.0) --- updated-dependencies: - dependency-name: github.com/onsi/gomega dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] * Temporarily limit codecov path to contracts src * build(deps): bump golang.org/x/crypto from 0.14.0 to 0.15.0 Bumps [golang.org/x/crypto](https://github.com/golang/crypto) from 0.14.0 to 0.15.0. - [Commits](https://github.com/golang/crypto/compare/v0.14.0...v0.15.0) --- updated-dependencies: - dependency-name: golang.org/x/crypto dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] * cannon: go mod tidy * contracts-bedrock: cleanup deploy config check Removes the special case for the deploy config check where the `getting-started.json` was not valid JSON and would need to be skipped by the deploy config checking script. The getting started guide has been updated with new logic so this special case can be removed. * add safe abi to chain-mon * op-challenger: Add a translating trace provider. * CI: Make validate-spaces quick * CI: Switch to medium machines * CI: Set STRICT_DEPLOYMENT=false for gas snapshots * feat: multisig-mon (#8119) * feat: multisig-mon * add to dockerfile and ci pipeline, need for bignumber * logger.error * safe nonces * fix(ci): chain-mon release (#8124) * add docker-build step for chain-mon-docker-release (#8125) * fix(ci): add chain-mon to ops/scripts/ci-docker-tag-op-stack-release.sh (#8126) * indexer.bridge.processing.split * nit * indexer.bridge.logging * feat(proxyd): ability to add additional headers to backend requests (#8134) * proxyd: add example block range regulation params (#8039) * op-challenger: fixes the latestBlockNumber signature and makes the ROOT_CLAIM variable 32 bytes in size --------- Signed-off-by: dependabot[bot] Co-authored-by: Inphi Co-authored-by: Hamdi Allam Co-authored-by: protolambda Co-authored-by: Mark Tyneway Co-authored-by: Danyal Prout Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Will Cory Co-authored-by: Aryan Malik Co-authored-by: felipe <130432649+felipe-op@users.noreply.github.com> Co-authored-by: Adrian Sutton Co-authored-by: Will Cory Co-authored-by: Adrian Sutton Co-authored-by: Tei Im Co-authored-by: Matthew Slipper Co-authored-by: EvanJRichard Co-authored-by: Roberto Bayardo Co-authored-by: Joshua Gutow Co-authored-by: Ethen Pociask Co-authored-by: Joshua Gutow Co-authored-by: Sebastian Stammler Co-authored-by: Kelvin Fichter Co-authored-by: Kelvin Fichter Co-authored-by: tre Co-authored-by: lbeder Co-authored-by: Maurelian Co-authored-by: Felipe Andrade Co-authored-by: kaliubuntu0206 <139627505+kaliubuntu0206@users.noreply.github.com> Co-authored-by: Joseandro Luiz --- .circleci/config.yml | 987 +- .envrc.example | 55 + .foundryrc | 2 +- .gethrc | 1 + .github/CODEOWNERS | 9 +- .github/workflows/release-docker-canary.yml | 32 +- .github/workflows/release.yml | 34 +- .gitignore | 1 + .gitmodules | 3 - .nvmrc | 2 +- CONTRIBUTING.md | 4 +- Makefile | 33 +- bedrock-devnet/devnet/__init__.py | 99 +- cannon/Makefile | 7 +- cannon/cmd/run.go | 9 - cannon/example/claim/go.mod | 4 +- cannon/example/claim/go.sum | 8 +- cannon/mipsevm/evm.go | 22 +- cannon/mipsevm/evm_test.go | 6 +- cannon/mipsevm/witness.go | 18 +- codecov.yml | 17 +- docker-bake.hcl | 183 + docs/fault-proof-alpha/immunefi.md | 3 + docs/postmortems/2022-02-02-inflation-vuln.md | 2 +- endpoint-monitor/Makefile | 4 +- endpoint-monitor/cmd/main.go | 4 +- go.mod | 78 +- go.sum | 317 +- indexer/api-ts/generated.ts | 10 +- indexer/api/api.go | 211 +- indexer/api/api_test.go | 48 +- indexer/api/config.go | 60 + indexer/api/models/models.go | 69 +- indexer/api/models/models_test.go | 64 + indexer/api/routes/supply.go | 35 + indexer/api/routes/withdrawals.go | 30 +- indexer/bigint/bigint.go | 6 + indexer/client/client.go | 20 + indexer/cmd/indexer/cli.go | 65 +- indexer/cmd/indexer/main.go | 14 +- indexer/config/config.go | 24 +- indexer/config/config_test.go | 46 + indexer/database/blocks.go | 141 +- indexer/database/bridge_messages.go | 37 +- indexer/database/bridge_transactions.go | 109 +- indexer/database/bridge_transfers.go | 49 +- indexer/database/contract_events.go | 29 +- indexer/database/db.go | 65 +- indexer/database/logger.go | 6 +- indexer/database/mocks.go | 16 +- indexer/database/serializers/bytes.go | 3 +- indexer/database/serializers/rlp.go | 3 +- indexer/docker-compose.yml | 3 +- indexer/e2e_tests/bridge_messages_e2e_test.go | 8 +- .../e2e_tests/bridge_transactions_e2e_test.go | 10 +- .../e2e_tests/bridge_transfers_e2e_test.go | 57 +- indexer/e2e_tests/setup.go | 74 +- indexer/etl/etl.go | 125 +- indexer/etl/l1_etl.go | 198 +- indexer/etl/l1_etl_test.go | 8 +- indexer/etl/l2_etl.go | 180 +- indexer/etl/metrics.go | 68 +- indexer/indexer.go | 283 +- indexer/indexer.toml | 1 + indexer/migrations/20230523_create_schema.sql | 34 +- indexer/node/client.go | 121 +- indexer/node/client_test.go | 35 + indexer/node/header_traversal.go | 50 +- indexer/node/header_traversal_test.go | 63 +- indexer/node/metrics.go | 2 +- indexer/node/mocks.go | 7 +- indexer/processors/bridge.go | 454 +- .../processors/bridge/l1_bridge_processor.go | 82 +- .../processors/bridge/l2_bridge_processor.go | 67 +- .../bridge/legacy_bridge_processor.go | 113 +- indexer/processors/bridge/metrics.go | 105 +- op-batcher/Dockerfile | 33 +- op-batcher/Dockerfile.dockerignore | 2 + op-batcher/Makefile | 8 +- op-batcher/batcher/batch_submitter.go | 108 +- op-batcher/batcher/channel.go | 5 +- op-batcher/batcher/channel_builder.go | 24 +- op-batcher/batcher/channel_builder_test.go | 262 +- op-batcher/batcher/channel_manager.go | 9 +- op-batcher/batcher/channel_manager_test.go | 132 +- op-batcher/batcher/channel_test.go | 13 +- op-batcher/batcher/config.go | 52 +- op-batcher/batcher/driver.go | 204 +- op-batcher/batcher/service.go | 344 + op-batcher/cmd/main.go | 19 +- op-batcher/flags/flags.go | 7 + op-batcher/metrics/metrics.go | 22 +- op-batcher/metrics/noop.go | 12 +- op-batcher/rpc/api.go | 14 +- op-bindings/Makefile | 3 - op-bindings/bindings/alphabetvm.go | 28 +- op-bindings/bindings/alphabetvm_more.go | 4 +- op-bindings/bindings/basefeevault.go | 2 +- op-bindings/bindings/basefeevault_more.go | 2 +- op-bindings/bindings/eas.go | 2 +- op-bindings/bindings/eas_more.go | 2 +- op-bindings/bindings/faultdisputegame.go | 28 +- op-bindings/bindings/faultdisputegame_more.go | 2 +- .../bindings/l1crossdomainmessenger.go | 2 +- .../bindings/l1crossdomainmessenger_more.go | 2 +- op-bindings/bindings/l1erc721bridge.go | 2 +- op-bindings/bindings/l1erc721bridge_more.go | 2 +- op-bindings/bindings/l1feevault.go | 2 +- op-bindings/bindings/l1feevault_more.go | 2 +- op-bindings/bindings/l1standardbridge.go | 2 +- op-bindings/bindings/l1standardbridge_more.go | 2 +- .../bindings/l2crossdomainmessenger.go | 2 +- .../bindings/l2crossdomainmessenger_more.go | 2 +- op-bindings/bindings/l2erc721bridge.go | 28 +- op-bindings/bindings/l2erc721bridge_more.go | 2 +- op-bindings/bindings/l2standardbridge.go | 2 +- op-bindings/bindings/l2standardbridge_more.go | 2 +- op-bindings/bindings/legacyerc20eth.go | 2 +- op-bindings/bindings/legacyerc20eth_more.go | 2 +- op-bindings/bindings/mips.go | 28 +- op-bindings/bindings/mips_more.go | 4 +- op-bindings/bindings/optimismmintableerc20.go | 2 +- .../bindings/optimismmintableerc20_more.go | 2 +- .../bindings/optimismmintableerc20factory.go | 2 +- .../optimismmintableerc20factory_more.go | 2 +- op-bindings/bindings/preimageoracle.go | 28 +- op-bindings/bindings/preimageoracle_more.go | 4 +- op-bindings/bindings/sequencerfeevault.go | 2 +- .../bindings/sequencerfeevault_more.go | 2 +- op-bindings/bindings/storagesetter.go | 49 +- op-bindings/bindings/storagesetter_more.go | 2 +- op-bootnode/Makefile | 10 +- op-chain-ops/Makefile | 3 - op-chain-ops/cmd/check-canyon/main.go | 272 + op-chain-ops/cmd/op-upgrade/README.md | 2 +- op-chain-ops/cmd/op-upgrade/main.go | 2 +- op-chain-ops/genesis/config.go | 70 +- op-chain-ops/genesis/config_test.go | 12 + op-chain-ops/genesis/genesis.go | 11 +- op-chain-ops/genesis/layer_one_test.go | 3 +- op-chain-ops/genesis/layer_two.go | 3 +- op-chain-ops/genesis/layer_two_test.go | 3 +- op-chain-ops/genesis/setters.go | 11 +- .../testdata/test-deploy-config-full.json | 1 + op-chain-ops/state/encoding.go | 11 +- op-challenger/Dockerfile | 51 +- op-challenger/Dockerfile.dockerignore | 2 + op-challenger/Makefile | 7 +- op-challenger/cmd/main.go | 15 +- op-challenger/cmd/main_test.go | 78 +- op-challenger/config/config.go | 21 +- op-challenger/config/config_test.go | 25 +- op-challenger/flags/flags.go | 70 +- op-challenger/game/fault/agent.go | 8 +- op-challenger/game/fault/agent_test.go | 7 +- .../game/fault/contracts/faultdisputegame.go | 214 + .../fault/contracts/faultdisputegame_test.go | 261 + .../game/fault/contracts/gamefactory.go | 60 + .../game/fault/contracts/gamefactory_test.go | 99 + op-challenger/game/fault/loader.go | 153 - op-challenger/game/fault/loader_test.go | 274 - op-challenger/game/fault/player.go | 62 +- op-challenger/game/fault/player_test.go | 4 +- op-challenger/game/fault/register.go | 74 + .../game/fault/responder/abi_test.go | 104 - .../game/fault/responder/responder.go | 127 +- .../game/fault/responder/responder_test.go | 150 +- .../game/fault/solver/game_solver.go | 6 +- .../game/fault/solver/game_solver_test.go | 3 +- op-challenger/game/fault/solver/solver.go | 66 +- .../game/fault/solver/solver_test.go | 3 +- op-challenger/game/fault/test/alphabet.go | 2 +- .../game/fault/test/claim_builder.go | 9 - op-challenger/game/fault/trace/access.go | 39 + op-challenger/game/fault/trace/access_test.go | 70 + .../game/fault/trace/alphabet/provider.go | 20 +- .../game/fault/trace/cannon/executor_test.go | 2 +- .../game/fault/trace/cannon/local.go | 21 +- .../game/fault/trace/cannon/local_test.go | 41 +- .../game/fault/trace/cannon/provider.go | 20 +- .../game/fault/trace/cannon/provider_test.go | 14 +- .../game/fault/trace/cannon/updater.go | 1 + .../game/fault/trace/cannon/updater_test.go | 12 +- .../game/fault/trace/outputs/provider.go | 2 +- .../game/fault/trace/split/provider.go | 5 - .../game/fault/trace/split/provider_test.go | 18 - op-challenger/game/fault/trace/translate.go | 42 + .../game/fault/trace/translate_test.go | 60 + op-challenger/game/fault/types/game.go | 12 + op-challenger/game/fault/types/game_test.go | 78 +- op-challenger/game/fault/types/types.go | 33 +- op-challenger/game/fault/types/types_test.go | 62 +- op-challenger/game/loader/game_loader.go | 33 +- op-challenger/game/loader/game_loader_test.go | 41 +- op-challenger/game/monitor.go | 6 +- op-challenger/game/monitor_test.go | 5 +- op-challenger/game/registry/registry.go | 41 + op-challenger/game/registry/registry_test.go | 40 + .../game/scheduler/coordinator_test.go | 31 +- .../game/scheduler/scheduler_test.go | 5 +- .../game/scheduler/test/stub_player.go | 24 + op-challenger/game/scheduler/worker_test.go | 17 +- op-challenger/game/service.go | 16 +- op-challenger/metrics/metrics.go | 7 +- op-challenger/scripts/alphabet/init_game.sh | 2 +- op-challenger/scripts/create_game.sh | 2 +- op-e2e/Makefile | 6 +- op-e2e/actions/blocktime_test.go | 36 +- op-e2e/actions/dencun_fork_test.go | 53 + op-e2e/actions/garbage_channel_out.go | 25 +- op-e2e/actions/l1_miner.go | 19 +- op-e2e/actions/l1_replica.go | 2 +- op-e2e/actions/l1_replica_test.go | 2 +- op-e2e/actions/l2_batcher.go | 55 +- op-e2e/actions/l2_batcher_test.go | 72 +- op-e2e/actions/l2_engine.go | 21 +- op-e2e/actions/l2_engine_test.go | 14 +- op-e2e/actions/l2_proposer.go | 3 - op-e2e/actions/l2_proposer_test.go | 30 +- op-e2e/actions/l2_sequencer_test.go | 2 +- op-e2e/actions/l2_verifier.go | 5 + op-e2e/actions/reorg_test.go | 183 +- op-e2e/actions/span_batch_test.go | 365 + op-e2e/actions/sync_test.go | 269 +- op-e2e/actions/system_config_test.go | 52 +- op-e2e/actions/tx_helper.go | 49 + op-e2e/actions/user_test.go | 32 +- op-e2e/e2eutils/challenger/helper.go | 9 +- .../e2eutils/disputegame/alphabet_helper.go | 18 +- op-e2e/e2eutils/disputegame/cannon_helper.go | 10 +- .../e2eutils/disputegame/dishonest_helper.go | 5 +- op-e2e/e2eutils/disputegame/game_helper.go | 35 +- op-e2e/e2eutils/geth/fakepos.go | 25 +- op-e2e/e2eutils/setup.go | 7 +- op-e2e/e2eutils/wait/blocks.go | 11 + op-e2e/external.go | 6 + op-e2e/faultproof_test.go | 65 +- op-e2e/helper.go | 58 +- op-e2e/op_geth.go | 11 +- op-e2e/op_geth_test.go | 152 +- op-e2e/setup.go | 62 +- op-e2e/system_fpp_test.go | 49 +- op-e2e/system_test.go | 53 +- op-heartbeat/Dockerfile | 21 +- op-heartbeat/Dockerfile.dockerignore | 2 + op-heartbeat/Makefile | 7 +- op-heartbeat/cmd/main.go | 4 +- op-node/.gitignore | 5 + op-node/Dockerfile | 30 +- op-node/Dockerfile.dockerignore | 2 + op-node/Makefile | 7 +- op-node/chaincfg/chains.go | 23 +- op-node/chaincfg/chains_test.go | 48 +- .../batch_decoder/reassemble/reassemble.go | 18 +- op-node/cmd/genesis/cmd.go | 52 +- op-node/cmd/main.go | 23 +- op-node/cmd/networks/cmd.go | 43 + op-node/flags/flags.go | 24 +- op-node/flags/p2p_flags.go | 5 +- op-node/metrics/metrics.go | 15 +- op-node/node/config.go | 3 + op-node/node/node.go | 4 + op-node/node/server_test.go | 1 + op-node/p2p/cli/load_signer.go | 3 +- op-node/p2p/gossip.go | 157 +- op-node/p2p/gossip_test.go | 77 + op-node/p2p/host.go | 10 +- op-node/p2p/host_test.go | 11 + op-node/p2p/node.go | 7 +- op-node/p2p/rpc_server.go | 24 +- op-node/p2p/store/scorebook.go | 8 +- op-node/p2p/sync.go | 18 +- op-node/p2p/sync_test.go | 54 + op-node/rollup/derive/attributes.go | 6 + op-node/rollup/derive/attributes_queue.go | 25 +- .../rollup/derive/attributes_queue_test.go | 6 +- op-node/rollup/derive/batch.go | 69 +- op-node/rollup/derive/batch_queue.go | 197 +- op-node/rollup/derive/batch_queue_test.go | 778 +- op-node/rollup/derive/batch_test.go | 85 +- op-node/rollup/derive/batch_tob_test.go | 8 +- op-node/rollup/derive/batches.go | 280 +- op-node/rollup/derive/batches_test.go | 1258 +- op-node/rollup/derive/channel.go | 22 +- op-node/rollup/derive/channel_bank.go | 46 +- op-node/rollup/derive/channel_bank_test.go | 73 +- op-node/rollup/derive/channel_in_reader.go | 42 +- op-node/rollup/derive/channel_out.go | 121 +- op-node/rollup/derive/channel_out_test.go | 22 +- op-node/rollup/derive/deposit_log.go | 6 +- op-node/rollup/derive/engine_consolidate.go | 31 + .../rollup/derive/engine_consolidate_test.go | 70 + op-node/rollup/derive/engine_queue.go | 94 +- op-node/rollup/derive/engine_queue_test.go | 13 +- op-node/rollup/derive/fuzz_parsers_test.go | 2 +- op-node/rollup/derive/l1_traversal.go | 2 +- op-node/rollup/derive/params.go | 6 +- op-node/rollup/derive/pipeline.go | 7 +- op-node/rollup/derive/singular_batch.go | 14 + op-node/rollup/derive/singular_batch_test.go | 8 +- op-node/rollup/derive/span_batch.go | 139 +- op-node/rollup/derive/span_batch_test.go | 329 +- op-node/rollup/derive/span_batch_tx.go | 46 - op-node/rollup/derive/span_batch_tx_test.go | 158 +- op-node/rollup/derive/span_batch_txs.go | 8 +- op-node/rollup/derive/span_batch_txs_test.go | 94 +- op-node/rollup/derive/span_channel_out.go | 228 + op-node/rollup/derive/test/random.go | 11 + op-node/rollup/driver/driver.go | 1 + op-node/rollup/driver/state.go | 1 + op-node/rollup/superchain.go | 7 +- op-node/rollup/types.go | 4 + op-node/rollup/types_test.go | 51 + op-node/service.go | 8 +- op-preimage/filepoller_test.go | 12 +- op-program/Dockerfile | 32 +- op-program/Dockerfile.dockerignore | 2 + op-program/Makefile | 26 +- op-program/client/driver/driver.go | 8 +- op-program/client/driver/driver_test.go | 12 +- op-program/client/l2/engine.go | 27 +- op-program/client/l2/engine_test.go | 6 +- .../client/l2/engineapi/block_processor.go | 2 +- .../client/l2/engineapi/l2_engine_api.go | 22 +- .../l2/engineapi/test/l2_engine_api_tests.go | 60 +- op-program/client/mpt/trie.go | 2 +- op-program/client/program.go | 2 +- op-program/host/cmd/main.go | 15 +- op-program/host/cmd/main_test.go | 4 +- op-program/host/config/config.go | 2 +- op-program/host/flags/flags.go | 2 +- op-program/verify/cmd/goerli.go | 135 +- op-proposer/Dockerfile | 30 +- op-proposer/Dockerfile.dockerignore | 2 + op-proposer/Makefile | 7 +- op-proposer/cmd/main.go | 4 +- op-proposer/metrics/metrics.go | 7 +- op-proposer/proposer/l2_output_submitter.go | 4 +- op-service/Makefile | 6 +- op-service/cliapp/lifecycle.go | 18 +- op-service/cliapp/lifecycle_test.go | 21 +- op-service/clock/loop.go | 64 + op-service/clock/loop_test.go | 32 + op-service/dial/dial.go | 8 +- op-service/eth/address.go | 12 + op-service/eth/block_info.go | 5 + op-service/eth/ssz.go | 186 +- op-service/eth/ssz_test.go | 222 +- op-service/eth/sync_status.go | 2 + op-service/eth/types.go | 41 +- op-service/metrics/balance.go | 60 +- op-service/metrics/http.go | 26 +- op-service/metrics/registry.go | 4 + op-service/metrics/rpc_metrics.go | 14 + op-service/opio/interrupts.go | 71 + op-service/rethdb-reader/.gitignore | 5 + op-service/rethdb-reader/Cargo.lock | 7452 +++ op-service/rethdb-reader/Cargo.toml | 15 + op-service/rethdb-reader/README.md | 83 + op-service/rethdb-reader/headgen.sh | 16 + op-service/rethdb-reader/src/lib.rs | 33 + op-service/rethdb-reader/src/receipts.rs | 211 + op-service/retry/strategies.go | 23 +- op-service/retry/strategies_test.go | 11 +- op-service/sources/{ => batching}/batching.go | 2 +- .../sources/{ => batching}/batching_test.go | 2 +- op-service/sources/batching/call.go | 135 + op-service/sources/batching/call_test.go | 186 + op-service/sources/batching/multicall.go | 111 + op-service/sources/batching/test/stubs.go | 126 + op-service/sources/batching/types.go | 11 + op-service/sources/debug_client.go | 5 +- op-service/sources/engine_client.go | 11 +- op-service/sources/eth_client.go | 9 +- op-service/sources/eth_client_test.go | 8 +- op-service/sources/l2_client.go | 2 +- op-service/sources/receipts.go | 61 +- op-service/sources/receipts_test.go | 242 + op-service/sources/reth_db.go | 65 + op-service/sources/reth_db_stub.go | 13 + op-service/sources/rollupclient.go | 4 + .../post-shanghai-bad-receipts-hash_data.json | 1 + ...t-shanghai-bad-receipts-hash_metadata.json | 1 + ...t-shanghai-bad-transactions-hash_data.json | 1 + ...anghai-bad-transactions-hash_metadata.json | 1 + ...st-shanghai-bad-transactions-nil_data.json | 1 + ...hanghai-bad-transactions-nil_metadata.json | 1 + .../post-shanghai-bad-transactions_data.json | 1 + ...st-shanghai-bad-transactions_metadata.json | 1 + ...st-shanghai-bad-withdrawals-hash_data.json | 1 + ...hanghai-bad-withdrawals-hash_metadata.json | 1 + ...ost-shanghai-bad-withdrawals-nil_data.json | 1 + ...shanghai-bad-withdrawals-nil_metadata.json | 1 + .../post-shanghai-bad-withdrawals_data.json | 1 + ...ost-shanghai-bad-withdrawals_metadata.json | 1 + .../blocks/post-shanghai-success_data.json | 1 + .../post-shanghai-success_metadata.json | 1 + .../pre-shanghai-bad-receipts-hash_data.json | 1 + ...e-shanghai-bad-receipts-hash_metadata.json | 1 + ...e-shanghai-bad-transactions-hash_data.json | 1 + ...anghai-bad-transactions-hash_metadata.json | 1 + .../pre-shanghai-bad-transactions_data.json | 1 + ...re-shanghai-bad-transactions_metadata.json | 1 + .../blocks/pre-shanghai-success_data.json | 1 + .../blocks/pre-shanghai-success_metadata.json | 1 + .../post-shanghai-bad-receipts_data.json | 1 + .../post-shanghai-bad-receipts_metadata.json | 1 + .../post-shanghai-bad-transactions_data.json | 1 + ...st-shanghai-bad-transactions_metadata.json | 1 + .../post-shanghai-bad-withdrawals_data.json | 1 + ...ost-shanghai-bad-withdrawals_metadata.json | 1 + .../headers/post-shanghai-success_data.json | 1 + .../post-shanghai-success_metadata.json | 1 + .../pre-shanghai-bad-receipts_data.json | 1 + .../pre-shanghai-bad-receipts_metadata.json | 1 + .../pre-shanghai-bad-transactions_data.json | 1 + ...re-shanghai-bad-transactions_metadata.json | 1 + .../headers/pre-shanghai-success_data.json | 1 + .../pre-shanghai-success_metadata.json | 1 + op-service/sources/testdata/gen.sh | 74 + op-service/sources/types.go | 48 +- op-service/sources/types_test.go | 86 +- op-service/tasks/tasks.go | 32 + op-service/testutils/l1info.go | 5 + op-service/testutils/mock_l2.go | 18 +- op-service/testutils/random.go | 97 +- op-service/txmgr/cli.go | 23 + op-service/txmgr/mocks/TxManager.go | 29 - op-service/txmgr/send_state.go | 3 + op-service/txmgr/txmgr.go | 176 +- op-service/txmgr/txmgr_test.go | 62 +- op-service/version.go | 19 + op-service/version_test.go | 75 + op-wheel/Dockerfile | 21 +- op-wheel/Dockerfile.dockerignore | 2 + op-wheel/Makefile | 8 +- op-wheel/cheat/cheat.go | 12 +- op-wheel/cmd/main.go | 4 +- ops-bedrock/Dockerfile.l1 | 2 +- ops-bedrock/docker-compose.yml | 53 +- ops/check-changed/requirements.txt | 2 +- ops/docker/Dockerfile.packages | 33 +- ops/docker/ci-builder/Dockerfile | 156 +- ops/docker/ci-builder/Dockerfile.dockerignore | 5 + ops/docker/op-stack-go/Dockerfile | 84 + .../op-stack-go/Dockerfile.dockerignore | 19 + ops/scripts/ci-docker-tag-op-stack-release.sh | 2 +- ops/scripts/ci-match-values-between-files.sh | 57 + ops/scripts/geth-version-checker.sh | 23 + ops/tag-service/tag-service.py | 1 + package.json | 22 +- packages/chain-mon/.env.example | 12 + packages/chain-mon/CHANGELOG.md | 6 + packages/chain-mon/package.json | 20 +- .../chain-mon/src/abi/IGnosisSafe.0.8.19.json | 6991 +++ packages/chain-mon/src/balance-mon/service.ts | 34 +- packages/chain-mon/src/index.ts | 3 +- .../chain-mon/src/multisig-mon/service.ts | 109 + packages/chain-mon/tsconfig.json | 1 + packages/common-ts/package.json | 10 +- .../src/base-service/base-service-v2.ts | 3 +- packages/contracts-bedrock/.envrc.example | 18 - packages/contracts-bedrock/.gas-snapshot | 1106 +- packages/contracts-bedrock/.gitignore | 8 +- packages/contracts-bedrock/README.md | 2 +- packages/contracts-bedrock/STYLE_GUIDE.md | 19 +- .../deploy-config/devnetL1-template.json | 4 +- .../deploy-config/getting-started.json | 60 - .../deploy-config/goerli.json | 5 +- .../deploy-config/hardhat.json | 15 +- .../deploy-config/mainnet.json | 4 +- .../deploy-config/sepolia.json | 4 +- .../deployments/4460/.chainId | 1 + .../deployments/58008/.chainId | 1 + .../deployments/84532/.chainId | 1 + .../deployments/919/.chainId | 1 + .../deployments/999999999/.chainId | 1 + .../deployments/mainnet/ProtocolVersions.json | 496 + .../mainnet/ProtocolVersionsProxy.json | 256 + .../deployments/optimism-sepolia/.chainId | 1 + .../sepolia/ProtocolVersionsProxy.json | 256 + packages/contracts-bedrock/foundry.toml | 7 + .../invariant-docs/CrossDomainMessenger.md | 4 +- .../invariant-docs/OptimismPortal.md | 8 +- .../invariant-docs/SystemConfig.md | 2 +- packages/contracts-bedrock/lib/forge-std | 2 +- packages/contracts-bedrock/package.json | 25 +- .../periphery-deploy-config/4460.json | 41 + .../periphery-deploy-config/58008.json | 41 + .../periphery-deploy-config/84532.json | 41 + .../periphery-deploy-config/901.json | 41 + .../periphery-deploy-config/919.json | 41 + .../periphery-deploy-config/999999999.json | 41 + .../optimism-goerli.json | 29 +- .../optimism-sepolia.json | 41 + .../periphery-deploy-config/sepolia.json | 41 + .../scripts/ChainAssertions.sol | 141 + .../contracts-bedrock/scripts/Deploy.s.sol | 104 +- .../scripts/DeployConfig.s.sol | 19 +- .../scripts/DeployPeriphery.s.sol | 253 +- .../contracts-bedrock/scripts/Deployer.sol | 9 +- .../scripts/PeripheryDeployConfig.s.sol | 51 + packages/contracts-bedrock/scripts/Types.sol | 16 + .../scripts/check-deploy-configs.sh | 5 - .../scripts/getting-started/config.sh | 94 + .../scripts/getting-started/versions.sh | 36 + .../scripts/getting-started/wallets.sh | 43 + .../scripts/go-ffi/README.md | 68 + .../contracts-bedrock/scripts/go-ffi/bin.go | 17 + .../differential-testing.go | 7 +- .../trie => scripts/go-ffi}/trie.go | 70 +- .../{differential-testing => go-ffi}/utils.go | 0 .../scripts/interfaces/ISystemConfigV0.sol | 19 + .../scripts/outputs/DeleteOutput.s.sol | 152 - .../scripts/outputs/README.md | 38 - .../scripts/universal/EnhancedScript.sol | 6 +- .../scripts/upgrades/EASUpgrade.s.sol | 130 - .../scripts/upgrades/Multichain.s.sol | 492 - packages/contracts-bedrock/semver-lock.json | 38 +- packages/contracts-bedrock/src/EAS/EAS.sol | 12 +- .../src/EAS/eip1271/EIP1271Verifier.sol | 23 +- .../src/EAS/resolver/SchemaResolver.sol | 12 +- .../src/L1/L1CrossDomainMessenger.sol | 4 +- .../src/L1/L1ERC721Bridge.sol | 4 +- .../src/L1/L1StandardBridge.sol | 4 +- .../contracts-bedrock/src/L2/BaseFeeVault.sol | 4 +- .../contracts-bedrock/src/L2/L1FeeVault.sol | 4 +- .../src/L2/L2CrossDomainMessenger.sol | 7 +- .../src/L2/L2ERC721Bridge.sol | 13 +- .../src/L2/L2StandardBridge.sol | 7 +- .../src/L2/SequencerFeeVault.sol | 4 +- .../src/Safe/LivenessGuard.sol | 159 + .../src/Safe/LivenessModule.sol | 231 + .../src/Safe/SafeSigners.sol | 86 + .../contracts-bedrock/src/cannon/MIPS.sol | 29 +- .../src/cannon/PreimageKeyLib.sol | 18 +- .../src/cannon/PreimageOracle.sol | 3 +- .../src/cannon/interfaces/IPreimageOracle.sol | 3 + .../src/dispute/FaultDisputeGame.sol | 21 +- .../src/dispute/interfaces/IBigStepper.sol | 10 +- .../dispute/interfaces/IFaultDisputeGame.sol | 4 +- .../drippie/dripchecks/CheckBalanceHigh.sol | 25 - .../authmodules/AdminFaucetAuthModule.sol | 2 +- .../periphery/op-nft/AttestationStation.sol | 9 +- .../src/periphery/op-nft/Optimist.sol | 17 +- .../periphery/op-nft/OptimistAllowlist.sol | 17 +- .../src/periphery/op-nft/OptimistInviter.sol | 15 +- .../src/universal/CrossDomainMessenger.sol | 8 +- .../src/universal/ERC721Bridge.sol | 2 +- .../src/universal/FeeVault.sol | 4 +- .../src/universal/OptimismMintableERC20.sol | 12 +- .../OptimismMintableERC20Factory.sol | 4 +- .../contracts-bedrock/src/universal/Proxy.sol | 2 +- .../src/universal/ProxyAdmin.sol | 8 +- .../src/universal/Semver.sol | 40 - .../src/universal/StandardBridge.sol | 8 +- .../src/universal/StorageSetter.sol | 18 +- .../test-case-generator/README.md | 34 - .../test-case-generator/cmd/fuzz.go | 31 - .../test-case-generator/go.mod | 26 - .../test-case-generator/go.sum | 141 - .../test/AddressAliasHelper.t.sol | 2 +- .../test/AdminFaucetAuthModule.t.sol | 6 +- .../test/AssetReceiver.t.sol | 6 +- .../test/AttestationStation.t.sol | 2 +- .../test/BenchmarkTest.t.sol | 92 +- packages/contracts-bedrock/test/Bytes.t.sol | 2 +- .../test/CheckBalanceHigh.t.sol | 40 - .../test/CheckBalanceLow.t.sol | 2 +- .../test/CheckGelatoLow.t.sol | 4 +- .../contracts-bedrock/test/CheckTrue.t.sol | 2 +- packages/contracts-bedrock/test/Clones.t.sol | 2 +- .../contracts-bedrock/test/CommonTest.t.sol | 808 - .../test/CrossDomainMessenger.t.sol | 55 +- .../test/CrossDomainOwnable.t.sol | 18 +- .../test/CrossDomainOwnable2.t.sol | 26 +- .../test/CrossDomainOwnable3.t.sol | 28 +- .../test/DelayedVetoable.t.sol | 4 +- .../test/DeployerWhitelist.t.sol | 8 +- .../test/DisputeGameFactory.t.sol | 14 +- packages/contracts-bedrock/test/Drippie.t.sol | 8 +- .../contracts-bedrock/test/Encoding.t.sol | 8 +- packages/contracts-bedrock/test/Faucet.t.sol | 6 +- .../test/FaultDisputeGame.t.sol | 83 +- .../contracts-bedrock/test/FeeVault.t.sol | 45 +- .../test/GasPriceOracle.t.sol | 37 +- .../test/GovernanceToken.t.sol | 98 +- packages/contracts-bedrock/test/Hashing.t.sol | 10 +- packages/contracts-bedrock/test/Helpers.sol | 221 - .../test/Initializable.t.sol | 60 + packages/contracts-bedrock/test/L1Block.t.sol | 44 +- .../test/L1BlockNumber.t.sol | 6 +- .../test/L1CrossDomainMessenger.t.sol | 197 +- .../test/L1ERC721Bridge.t.sol | 110 +- .../test/L1StandardBridge.t.sol | 344 +- .../test/L2CrossDomainMessenger.t.sol | 111 +- .../test/L2ERC721Bridge.t.sol | 108 +- .../test/L2OutputOracle.t.sol | 303 +- .../test/L2StandardBridge.t.sol | 255 +- .../test/L2ToL1MessagePasser.t.sol | 111 +- .../test/LegacyERC20ETH.t.sol | 6 +- .../test/LegacyMessagePasser.t.sol | 20 +- .../contracts-bedrock/test/LibClock.t.sol | 2 +- .../contracts-bedrock/test/LibPosition.t.sol | 4 +- .../test/LivenessGuard.t.sol | 327 + .../test/LivenessModule.t.sol | 499 + packages/contracts-bedrock/test/MIPS.t.sol | 168 +- .../contracts-bedrock/test/MerkleTrie.t.sol | 13 +- .../contracts-bedrock/test/MintManager.t.sol | 6 +- .../test/OptimismMintableERC20.t.sol | 20 +- .../test/OptimismMintableERC20Factory.t.sol | 26 +- .../test/OptimismMintableERC721.t.sol | 80 +- .../test/OptimismMintableERC721Factory.t.sol | 16 +- .../test/OptimismPortal.t.sol | 568 +- .../contracts-bedrock/test/Optimist.t.sol | 10 +- .../test/OptimistAllowlist.t.sol | 10 +- .../test/OptimistInviter.t.sol | 12 +- .../test/PreimageOracle.t.sol | 36 +- .../test/ProtocolVersions.t.sol | 39 +- packages/contracts-bedrock/test/Proxy.t.sol | 2 +- .../contracts-bedrock/test/ProxyAdmin.t.sol | 12 +- packages/contracts-bedrock/test/RLP.t.sol | 46 - .../contracts-bedrock/test/RLPReader.t.sol | 8 +- .../contracts-bedrock/test/RLPWriter.t.sol | 10 +- .../test/ResolvedDelegateProxy.t.sol | 4 +- .../test/ResourceMetering.t.sol | 6 +- .../contracts-bedrock/test/SafeCall.t.sol | 21 +- .../contracts-bedrock/test/SafeSigners.t.sol | 112 + packages/contracts-bedrock/test/Semver.t.sol | 35 - .../test/SequencerFeeVault.t.sol | 117 +- .../test/StandardBridge.t.sol | 6 +- packages/contracts-bedrock/test/Storage.t.sol | 22 + .../contracts-bedrock/test/SystemConfig.t.sol | 269 +- .../contracts-bedrock/test/Transactor.t.sol | 5 +- .../test/TransferOnion.t.sol | 2 +- .../test/invariants/AddressAliasHelper.t.sol | 2 +- .../test/invariants/Burn.Eth.t.sol | 2 +- .../test/invariants/Burn.Gas.t.sol | 2 +- .../invariants/CrossDomainMessenger.t.sol | 31 +- .../test/invariants/Encoding.t.sol | 2 +- .../test/invariants/Hashing.t.sol | 4 +- .../test/invariants/L2OutputOracle.t.sol | 10 +- .../test/invariants/OptimismPortal.t.sol | 76 +- .../test/invariants/ResourceMetering.t.sol | 8 +- .../test/invariants/SafeCall.t.sol | 2 +- .../test/invariants/SystemConfig.t.sol | 16 +- .../test/mocks/AlphabetVM.sol | 38 + .../contracts-bedrock/test/mocks/Callers.sol | 93 + .../test/mocks/EIP1967Helper.sol | 19 + .../test/mocks/FaucetHelper.sol | 59 + .../contracts-bedrock/test/mocks/NextImpl.sol | 21 + .../test/mocks/OptimistInviterHelper.sol | 94 + .../test/mocks/SimpleStorage.sol | 14 + .../test/mocks/TestERC1271Wallet.sol | 19 + .../test/mocks/TestERC20.sol | 12 + .../test/mocks/TestERC721.sol | 14 + .../CompatibilityFallbackHandler_1_3_0.sol | 213 + .../test/safe-tools/SafeTestTools.sol | 636 + .../test/setup/Bridge_Initializer.sol | 69 + .../test/setup/CommonTest.sol | 84 + .../contracts-bedrock/test/setup/Events.sol | 97 + .../test/setup/FFIInterface.sol | 243 + .../contracts-bedrock/test/setup/Setup.sol | 189 + packages/contracts-ts/CHANGELOG.md | 6 + packages/contracts-ts/abis.json | 9645 ++-- packages/contracts-ts/addresses.json | 24 +- packages/contracts-ts/package.json | 12 +- packages/contracts-ts/src/actions.ts | 14460 ++---- packages/contracts-ts/src/constants.ts | 19352 +++----- packages/contracts-ts/src/react.spec.tsx | 87 - packages/contracts-ts/src/react.ts | 39383 +++------------- packages/contracts-ts/wagmi.config.ts | 27 +- packages/core-utils/package.json | 2 +- packages/fee-estimation/package.json | 8 +- packages/sdk/hardhat.config.ts | 22 +- packages/sdk/package.json | 16 +- packages/sdk/tasks/deposit-erc20.ts | 16 +- packages/sdk/tasks/deposit-eth.ts | 9 +- packages/web3js-plugin/package.json | 8 +- pnpm-lock.yaml | 1653 +- proxyd/Dockerfile | 4 +- proxyd/Dockerfile.ignore | 3 + proxyd/backend.go | 97 +- proxyd/backend_test.go | 21 + proxyd/cache.go | 10 +- proxyd/cache_test.go | 2 +- proxyd/cmd/proxyd/main.go | 37 + proxyd/config.go | 34 +- proxyd/example.config.toml | 2 + proxyd/go.mod | 91 +- proxyd/go.sum | 557 +- proxyd/integration_tests/batching_test.go | 17 + proxyd/integration_tests/caching_test.go | 25 + proxyd/integration_tests/mock_backend_test.go | 1 + .../integration_tests/testdata/caching.toml | 1 + .../testdata/consensus_responses.yml | 21 + .../testdata/size_limits.toml | 21 + proxyd/integration_tests/validation_test.go | 26 + proxyd/methods.go | 16 +- proxyd/proxyd.go | 23 +- proxyd/reader.go | 32 + proxyd/reader_test.go | 43 + proxyd/rewriter.go | 93 +- proxyd/rewriter_test.go | 109 +- proxyd/server.go | 83 +- proxyd/tools/mockserver/handler/handler.go | 2 +- proxyd/tools/mockserver/node1.yml | 10 +- specs/deposits.md | 11 +- specs/derivation.md | 25 +- specs/exec-engine.md | 24 +- specs/glossary.md | 9 +- specs/meta/devnet.md | 2 +- specs/predeploys.md | 55 +- specs/rollup-node-p2p.md | 16 +- specs/safe-liveness-checking.md | 194 + specs/span-batches.md | 69 +- specs/superchain-upgrades.md | 40 +- ufm-test-services/metamask/Dockerfile | 6 +- ufm-test-services/metamask/pnpm-lock.yaml | 81 +- 719 files changed, 61112 insertions(+), 74445 deletions(-) create mode 100644 .envrc.example create mode 100644 .gethrc create mode 100644 docker-bake.hcl create mode 100644 indexer/api/config.go create mode 100644 indexer/api/models/models_test.go create mode 100644 indexer/api/routes/supply.go create mode 100644 indexer/node/client_test.go create mode 100644 op-batcher/Dockerfile.dockerignore create mode 100644 op-batcher/batcher/service.go create mode 100644 op-chain-ops/cmd/check-canyon/main.go create mode 100644 op-challenger/Dockerfile.dockerignore create mode 100644 op-challenger/game/fault/contracts/faultdisputegame.go create mode 100644 op-challenger/game/fault/contracts/faultdisputegame_test.go create mode 100644 op-challenger/game/fault/contracts/gamefactory.go create mode 100644 op-challenger/game/fault/contracts/gamefactory_test.go delete mode 100644 op-challenger/game/fault/loader.go delete mode 100644 op-challenger/game/fault/loader_test.go create mode 100644 op-challenger/game/fault/register.go delete mode 100644 op-challenger/game/fault/responder/abi_test.go create mode 100644 op-challenger/game/fault/trace/access.go create mode 100644 op-challenger/game/fault/trace/access_test.go create mode 100644 op-challenger/game/fault/trace/translate.go create mode 100644 op-challenger/game/fault/trace/translate_test.go create mode 100644 op-challenger/game/registry/registry.go create mode 100644 op-challenger/game/registry/registry_test.go create mode 100644 op-challenger/game/scheduler/test/stub_player.go create mode 100644 op-e2e/actions/dencun_fork_test.go create mode 100644 op-e2e/actions/span_batch_test.go create mode 100644 op-e2e/actions/tx_helper.go create mode 100644 op-heartbeat/Dockerfile.dockerignore create mode 100644 op-node/Dockerfile.dockerignore create mode 100644 op-node/cmd/networks/cmd.go create mode 100644 op-node/rollup/derive/engine_consolidate_test.go create mode 100644 op-node/rollup/derive/span_channel_out.go create mode 100644 op-program/Dockerfile.dockerignore create mode 100644 op-proposer/Dockerfile.dockerignore create mode 100644 op-service/clock/loop.go create mode 100644 op-service/clock/loop_test.go create mode 100644 op-service/eth/address.go create mode 100644 op-service/rethdb-reader/.gitignore create mode 100644 op-service/rethdb-reader/Cargo.lock create mode 100644 op-service/rethdb-reader/Cargo.toml create mode 100644 op-service/rethdb-reader/README.md create mode 100755 op-service/rethdb-reader/headgen.sh create mode 100644 op-service/rethdb-reader/src/lib.rs create mode 100644 op-service/rethdb-reader/src/receipts.rs rename op-service/sources/{ => batching}/batching.go (99%) rename op-service/sources/{ => batching}/batching_test.go (99%) create mode 100644 op-service/sources/batching/call.go create mode 100644 op-service/sources/batching/call_test.go create mode 100644 op-service/sources/batching/multicall.go create mode 100644 op-service/sources/batching/test/stubs.go create mode 100644 op-service/sources/batching/types.go create mode 100644 op-service/sources/reth_db.go create mode 100644 op-service/sources/reth_db_stub.go create mode 100644 op-service/sources/testdata/data/blocks/post-shanghai-bad-receipts-hash_data.json create mode 100644 op-service/sources/testdata/data/blocks/post-shanghai-bad-receipts-hash_metadata.json create mode 100644 op-service/sources/testdata/data/blocks/post-shanghai-bad-transactions-hash_data.json create mode 100644 op-service/sources/testdata/data/blocks/post-shanghai-bad-transactions-hash_metadata.json create mode 100644 op-service/sources/testdata/data/blocks/post-shanghai-bad-transactions-nil_data.json create mode 100644 op-service/sources/testdata/data/blocks/post-shanghai-bad-transactions-nil_metadata.json create mode 100644 op-service/sources/testdata/data/blocks/post-shanghai-bad-transactions_data.json create mode 100644 op-service/sources/testdata/data/blocks/post-shanghai-bad-transactions_metadata.json create mode 100644 op-service/sources/testdata/data/blocks/post-shanghai-bad-withdrawals-hash_data.json create mode 100644 op-service/sources/testdata/data/blocks/post-shanghai-bad-withdrawals-hash_metadata.json create mode 100644 op-service/sources/testdata/data/blocks/post-shanghai-bad-withdrawals-nil_data.json create mode 100644 op-service/sources/testdata/data/blocks/post-shanghai-bad-withdrawals-nil_metadata.json create mode 100644 op-service/sources/testdata/data/blocks/post-shanghai-bad-withdrawals_data.json create mode 100644 op-service/sources/testdata/data/blocks/post-shanghai-bad-withdrawals_metadata.json create mode 100644 op-service/sources/testdata/data/blocks/post-shanghai-success_data.json create mode 100644 op-service/sources/testdata/data/blocks/post-shanghai-success_metadata.json create mode 100644 op-service/sources/testdata/data/blocks/pre-shanghai-bad-receipts-hash_data.json create mode 100644 op-service/sources/testdata/data/blocks/pre-shanghai-bad-receipts-hash_metadata.json create mode 100644 op-service/sources/testdata/data/blocks/pre-shanghai-bad-transactions-hash_data.json create mode 100644 op-service/sources/testdata/data/blocks/pre-shanghai-bad-transactions-hash_metadata.json create mode 100644 op-service/sources/testdata/data/blocks/pre-shanghai-bad-transactions_data.json create mode 100644 op-service/sources/testdata/data/blocks/pre-shanghai-bad-transactions_metadata.json create mode 100644 op-service/sources/testdata/data/blocks/pre-shanghai-success_data.json create mode 100644 op-service/sources/testdata/data/blocks/pre-shanghai-success_metadata.json create mode 100644 op-service/sources/testdata/data/headers/post-shanghai-bad-receipts_data.json create mode 100644 op-service/sources/testdata/data/headers/post-shanghai-bad-receipts_metadata.json create mode 100644 op-service/sources/testdata/data/headers/post-shanghai-bad-transactions_data.json create mode 100644 op-service/sources/testdata/data/headers/post-shanghai-bad-transactions_metadata.json create mode 100644 op-service/sources/testdata/data/headers/post-shanghai-bad-withdrawals_data.json create mode 100644 op-service/sources/testdata/data/headers/post-shanghai-bad-withdrawals_metadata.json create mode 100644 op-service/sources/testdata/data/headers/post-shanghai-success_data.json create mode 100644 op-service/sources/testdata/data/headers/post-shanghai-success_metadata.json create mode 100644 op-service/sources/testdata/data/headers/pre-shanghai-bad-receipts_data.json create mode 100644 op-service/sources/testdata/data/headers/pre-shanghai-bad-receipts_metadata.json create mode 100644 op-service/sources/testdata/data/headers/pre-shanghai-bad-transactions_data.json create mode 100644 op-service/sources/testdata/data/headers/pre-shanghai-bad-transactions_metadata.json create mode 100644 op-service/sources/testdata/data/headers/pre-shanghai-success_data.json create mode 100644 op-service/sources/testdata/data/headers/pre-shanghai-success_metadata.json create mode 100644 op-service/sources/testdata/gen.sh create mode 100644 op-service/tasks/tasks.go create mode 100644 op-service/version.go create mode 100644 op-service/version_test.go create mode 100644 op-wheel/Dockerfile.dockerignore create mode 100644 ops/docker/ci-builder/Dockerfile.dockerignore create mode 100644 ops/docker/op-stack-go/Dockerfile create mode 100644 ops/docker/op-stack-go/Dockerfile.dockerignore create mode 100755 ops/scripts/ci-match-values-between-files.sh create mode 100755 ops/scripts/geth-version-checker.sh create mode 100644 packages/chain-mon/src/abi/IGnosisSafe.0.8.19.json create mode 100644 packages/chain-mon/src/multisig-mon/service.ts delete mode 100644 packages/contracts-bedrock/.envrc.example delete mode 100644 packages/contracts-bedrock/deploy-config/getting-started.json create mode 100644 packages/contracts-bedrock/deployments/4460/.chainId create mode 100644 packages/contracts-bedrock/deployments/58008/.chainId create mode 100644 packages/contracts-bedrock/deployments/84532/.chainId create mode 100644 packages/contracts-bedrock/deployments/919/.chainId create mode 100644 packages/contracts-bedrock/deployments/999999999/.chainId create mode 100644 packages/contracts-bedrock/deployments/mainnet/ProtocolVersions.json create mode 100644 packages/contracts-bedrock/deployments/mainnet/ProtocolVersionsProxy.json create mode 100644 packages/contracts-bedrock/deployments/optimism-sepolia/.chainId create mode 100644 packages/contracts-bedrock/deployments/sepolia/ProtocolVersionsProxy.json create mode 100644 packages/contracts-bedrock/periphery-deploy-config/4460.json create mode 100644 packages/contracts-bedrock/periphery-deploy-config/58008.json create mode 100644 packages/contracts-bedrock/periphery-deploy-config/84532.json create mode 100644 packages/contracts-bedrock/periphery-deploy-config/901.json create mode 100644 packages/contracts-bedrock/periphery-deploy-config/919.json create mode 100644 packages/contracts-bedrock/periphery-deploy-config/999999999.json create mode 100644 packages/contracts-bedrock/periphery-deploy-config/optimism-sepolia.json create mode 100644 packages/contracts-bedrock/periphery-deploy-config/sepolia.json create mode 100644 packages/contracts-bedrock/scripts/ChainAssertions.sol create mode 100644 packages/contracts-bedrock/scripts/Types.sol create mode 100755 packages/contracts-bedrock/scripts/getting-started/config.sh create mode 100755 packages/contracts-bedrock/scripts/getting-started/versions.sh create mode 100755 packages/contracts-bedrock/scripts/getting-started/wallets.sh create mode 100644 packages/contracts-bedrock/scripts/go-ffi/README.md create mode 100644 packages/contracts-bedrock/scripts/go-ffi/bin.go rename packages/contracts-bedrock/scripts/{differential-testing => go-ffi}/differential-testing.go (99%) rename packages/contracts-bedrock/{test-case-generator/trie => scripts/go-ffi}/trie.go (85%) rename packages/contracts-bedrock/scripts/{differential-testing => go-ffi}/utils.go (100%) create mode 100644 packages/contracts-bedrock/scripts/interfaces/ISystemConfigV0.sol delete mode 100644 packages/contracts-bedrock/scripts/outputs/DeleteOutput.s.sol delete mode 100644 packages/contracts-bedrock/scripts/outputs/README.md delete mode 100644 packages/contracts-bedrock/scripts/upgrades/EASUpgrade.s.sol delete mode 100644 packages/contracts-bedrock/scripts/upgrades/Multichain.s.sol create mode 100644 packages/contracts-bedrock/src/Safe/LivenessGuard.sol create mode 100644 packages/contracts-bedrock/src/Safe/LivenessModule.sol create mode 100644 packages/contracts-bedrock/src/Safe/SafeSigners.sol delete mode 100644 packages/contracts-bedrock/src/periphery/drippie/dripchecks/CheckBalanceHigh.sol delete mode 100644 packages/contracts-bedrock/src/universal/Semver.sol delete mode 100644 packages/contracts-bedrock/test-case-generator/README.md delete mode 100644 packages/contracts-bedrock/test-case-generator/cmd/fuzz.go delete mode 100644 packages/contracts-bedrock/test-case-generator/go.mod delete mode 100644 packages/contracts-bedrock/test-case-generator/go.sum delete mode 100644 packages/contracts-bedrock/test/CheckBalanceHigh.t.sol delete mode 100644 packages/contracts-bedrock/test/CommonTest.t.sol delete mode 100644 packages/contracts-bedrock/test/Helpers.sol create mode 100644 packages/contracts-bedrock/test/Initializable.t.sol create mode 100644 packages/contracts-bedrock/test/LivenessGuard.t.sol create mode 100644 packages/contracts-bedrock/test/LivenessModule.t.sol delete mode 100644 packages/contracts-bedrock/test/RLP.t.sol create mode 100644 packages/contracts-bedrock/test/SafeSigners.t.sol delete mode 100644 packages/contracts-bedrock/test/Semver.t.sol create mode 100644 packages/contracts-bedrock/test/mocks/AlphabetVM.sol create mode 100644 packages/contracts-bedrock/test/mocks/Callers.sol create mode 100644 packages/contracts-bedrock/test/mocks/EIP1967Helper.sol create mode 100644 packages/contracts-bedrock/test/mocks/FaucetHelper.sol create mode 100644 packages/contracts-bedrock/test/mocks/NextImpl.sol create mode 100644 packages/contracts-bedrock/test/mocks/OptimistInviterHelper.sol create mode 100644 packages/contracts-bedrock/test/mocks/SimpleStorage.sol create mode 100644 packages/contracts-bedrock/test/mocks/TestERC1271Wallet.sol create mode 100644 packages/contracts-bedrock/test/mocks/TestERC20.sol create mode 100644 packages/contracts-bedrock/test/mocks/TestERC721.sol create mode 100644 packages/contracts-bedrock/test/safe-tools/CompatibilityFallbackHandler_1_3_0.sol create mode 100644 packages/contracts-bedrock/test/safe-tools/SafeTestTools.sol create mode 100644 packages/contracts-bedrock/test/setup/Bridge_Initializer.sol create mode 100644 packages/contracts-bedrock/test/setup/CommonTest.sol create mode 100644 packages/contracts-bedrock/test/setup/Events.sol create mode 100644 packages/contracts-bedrock/test/setup/FFIInterface.sol create mode 100644 packages/contracts-bedrock/test/setup/Setup.sol delete mode 100644 packages/contracts-ts/src/react.spec.tsx create mode 100644 proxyd/Dockerfile.ignore create mode 100644 proxyd/backend_test.go create mode 100644 proxyd/integration_tests/testdata/size_limits.toml create mode 100644 proxyd/reader.go create mode 100644 proxyd/reader_test.go create mode 100644 specs/safe-liveness-checking.md diff --git a/.circleci/config.yml b/.circleci/config.yml index 21e5e6a225a44..59048ebf827df 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -58,6 +58,19 @@ commands: cd ops/check-changed pip3 install -r requirements.txt python3 main.py "<>" + notify-failures-on-develop: + description: "Notify Slack" + parameters: + channel: + type: string + default: C03N11M0BBN + steps: + - slack/notify: + channel: << parameters.channel >> + event: fail + template: basic_fail_1 + branch_pattern: develop + jobs: cannon-go-lint-and-test: docker: @@ -142,83 +155,21 @@ jobs: root: "." paths: - "packages/**/dist" + - "packages/contracts-bedrock/cache" + - "packages/contracts-bedrock/artifacts" - "packages/contracts-bedrock/forge-artifacts" + - "packages/contracts-bedrock/tsconfig.tsbuildinfo" + - "packages/contracts-bedrock/tsconfig.build.tsbuildinfo" docker-build: environment: DOCKER_BUILDKIT: 1 parameters: - docker_name: - description: Docker image name - type: string docker_tags: - description: Docker image tags as csv - type: string - docker_file: - description: Path to Dockerfile - type: string - docker_context: - description: Docker build context - type: string - registry: - description: Docker registry + description: Docker image tags, comma-separated type: string - default: "us-docker.pkg.dev" - repo: - description: Docker repo - type: string - default: "oplabs-tools-artifacts/images" - machine: - image: ubuntu-2204:2022.07.1 - resource_class: medium - steps: - - checkout - - run: - command: mkdir -p /tmp/docker_images - - run: - name: Build - command: | - # Check to see if DOCKER_HUB_READ_ONLY_TOKEN is set (i.e. we are in repo) before attempting to use secrets. - # Building should work without this read only login, but may get rate limited. - if [[ -v DOCKER_HUB_READ_ONLY_TOKEN ]]; then - echo "$DOCKER_HUB_READ_ONLY_TOKEN" | docker login -u "$DOCKER_HUB_READ_ONLY_USER" --password-stdin - fi - IMAGE_BASE="<>/<>/<>" - DOCKER_TAGS=$(echo -ne <> | sed "s/,/\n/g" | sed "s/[^a-zA-Z0-9\n]/-/g" | sed -e "s|^|-t ${IMAGE_BASE}:|") - docker build --progress plain \ - $(echo -ne $DOCKER_TAGS | tr '\n' ' ') \ - -f <> \ - <> - - run: - name: Save - command: | - IMAGE_BASE="<>/<>/<>" - DOCKER_LABELS=$(echo -ne <> | sed "s/,/\n/g" | sed "s/[^a-zA-Z0-9\n]/-/g") - echo -ne $DOCKER_LABELS | tr ' ' '\n' | xargs -I {} docker save -o /tmp/docker_images/<>_{}.tar $IMAGE_BASE:{} - - persist_to_workspace: - root: /tmp/docker_images - paths: - - "." - - docker-publish: - environment: - DOCKER_BUILDKIT: 1 - parameters: docker_name: - description: Docker image name - type: string - docker_tags: - description: Docker image tags as csv - type: string - docker_file: - description: Path to Dockerfile - type: string - docker_context: - description: Docker build context - type: string - default: "." - docker_target: - description: "target build stage" + description: "Docker buildx bake target" type: string default: "" registry: @@ -229,15 +180,47 @@ jobs: description: Docker repo type: string default: "oplabs-tools-artifacts/images" + save_image_tag: + description: Save docker image with given tag + type: string + default: "" platforms: - description: Platforms to build for + description: Platforms to build for, comma-separated type: string default: "linux/amd64" + publish: + description: Publish the docker image (multi-platform, all tags) + type: boolean + default: false + release: + description: Run the release script + type: boolean + default: false + resource_class: + description: Docker resoruce class + type: string + default: medium machine: image: ubuntu-2204:2022.07.1 - resource_class: medium + resource_class: "<>" + docker_layer_caching: true # we rely on this for faster builds, and actively warm it up for builds with common stages steps: - - gcp-oidc-authenticate + - checkout + - attach_workspace: + at: /tmp/docker_images + - run: + command: mkdir -p /tmp/docker_images + - when: + condition: "<>" + steps: + - gcp-cli/install + - when: + condition: + or: + - "<>" + - "<>" + steps: + - gcp-oidc-authenticate # Below is CircleCI recommended way of specifying nameservers on an Ubuntu box: # https://support.circleci.com/hc/en-us/articles/7323511028251-How-to-set-custom-DNS-on-Ubuntu-based-images-using-netplan - run: sudo sed -i '13 i \ \ \ \ \ \ \ \ \ \ \ \ nameservers:' /etc/netplan/50-cloud-init.yaml @@ -245,83 +228,88 @@ jobs: - run: sudo sed -i "s/addresses:/ addresses":" [8.8.8.8, 8.8.4.4] /g" /etc/netplan/50-cloud-init.yaml - run: cat /etc/netplan/50-cloud-init.yaml - run: sudo netplan apply - - checkout - run: - name: Build & Publish + name: Build command: | - gcloud auth configure-docker <> - IMAGE_BASE="<>/<>/<>" - DOCKER_TAGS=$(echo -ne <> | sed "s/,/\n/g" | sed "s/[^a-zA-Z0-9\n]/-/g" | sed -e "s|^|-t ${IMAGE_BASE}:|") - docker context create buildx-build - docker buildx create --use buildx-build - docker buildx build --progress plain --platform=<> --target "<>" --push \ - $(echo -ne $DOCKER_TAGS | tr '\n' ' ') \ - -f <> \ - <> + # Check to see if DOCKER_HUB_READ_ONLY_TOKEN is set (i.e. we are in repo) before attempting to use secrets. + # Building should work without this read only login, but may get rate limited. + if [[ -v DOCKER_HUB_READ_ONLY_TOKEN ]]; then + echo "$DOCKER_HUB_READ_ONLY_TOKEN" | docker login -u "$DOCKER_HUB_READ_ONLY_USER" --password-stdin + fi + + export REGISTRY="<>" + export REPOSITORY="<>" + export IMAGE_TAGS="$(echo -ne "<>" | sed "s/[^a-zA-Z0-9\n,]/-/g")" + export GIT_COMMIT="$(git rev-parse HEAD)" + export GIT_DATE="$(git show -s --format='%ct')" + export GIT_VERSION="<>" + export PLATFORMS="<>" + + # Create, start (bootstrap) and use a *named* docker builder + # This allows us to cross-build multi-platform, + # and naming allows us to use the DLC (docker-layer-cache) + docker buildx create --driver=docker-container --name=buildx-build --bootstrap --use + + DOCKER_OUTPUT_DESTINATION="" + if [ "<>" == "true" ]; then + gcloud auth configure-docker <> + echo "Building for platforms $PLATFORMS and then publishing to registry" + DOCKER_OUTPUT_DESTINATION="--push" + if [ "<>" != "" ]; then + echo "ERROR: cannot save image to docker when publishing to registry" + exit 1 + fi + else + if [ "<>" == "" ]; then + echo "Running $PLATFORMS build without destination (cache warm-up)" + DOCKER_OUTPUT_DESTINATION="" + elif [[ $PLATFORMS == *,* ]]; then + echo "ERROR: cannot perform multi-arch (platforms: $PLATFORMS) build while also loading the result into regular docker" + exit 1 + else + echo "Running single-platform $PLATFORMS build and loading into docker" + DOCKER_OUTPUT_DESTINATION="--load" + fi + fi + + # Let them cook! + docker buildx bake \ + --progress plain \ + --builder=buildx-build \ + -f docker-bake.hcl \ + $DOCKER_OUTPUT_DESTINATION \ + <> + + no_output_timeout: 45m + - when: + condition: "<>" + steps: + - notify-failures-on-develop + - when: + condition: "<>" + steps: + - run: + name: Save + command: | + IMAGE_NAME="<>/<>/<>:<>" + docker save -o /tmp/docker_images/<>.tar $IMAGE_NAME + - persist_to_workspace: + root: /tmp/docker_images + paths: # only write the one file, to avoid concurrent workspace-file additions + - "<>.tar" + - when: + condition: "<>" + steps: + - run: + name: Tag + command: | + ./ops/scripts/ci-docker-tag-op-stack-release.sh <>/<> $CIRCLE_TAG $CIRCLE_SHA1 - docker-release: - environment: - DOCKER_BUILDKIT: 1 - parameters: - docker_name: - description: Docker image name - type: string - docker_tags: - description: Docker image tags as csv - type: string - docker_file: - description: Path to Dockerfile - type: string - docker_context: - description: Docker build context - type: string - docker_target: - description: "target build stage" - type: string - default: "" - registry: - description: Docker registry - type: string - default: "us-docker.pkg.dev" - repo: - description: Docker repo - type: string - default: "oplabs-tools-artifacts/images" - platforms: - description: Platforms to build for - type: string - default: "linux/amd64" - machine: - image: ubuntu-2204:2022.07.1 - resource_class: medium - steps: - - gcp-cli/install - - gcp-oidc-authenticate - - checkout - - run: - name: Configure Docker - command: | - gcloud auth configure-docker <> - - run: - name: Build & Publish - command: | - IMAGE_BASE="<>/<>/<>" - DOCKER_TAGS=$(echo -ne <> | sed "s/,/\n/g" | sed "s/[^a-zA-Z0-9\n]/-/g" | sed -e "s|^|-t ${IMAGE_BASE}:|") - docker context create buildx-build - docker buildx create --use buildx-build - docker buildx build --progress plain --platform=<> --target "<>" --push \ - $(echo -ne $DOCKER_TAGS | tr '\n' ' ') \ - -f <> \ - <> - - run: - name: Tag - command: | - ./ops/scripts/ci-docker-tag-op-stack-release.sh <>/<> $CIRCLE_TAG $CIRCLE_SHA1 contracts-bedrock-coverage: docker: - image: us-docker.pkg.dev/oplabs-tools-artifacts/images/ci-builder:latest - resource_class: large + resource_class: xlarge steps: - checkout - check-changed: @@ -392,7 +380,7 @@ jobs: name: gas snapshot command: | forge --version - pnpm gas-snapshot --check || echo "export GAS_SNAPSHOT_STATUS=1" >> "$BASH_ENV" + STRICT_DEPLOYMENT=false pnpm gas-snapshot --check || echo "export GAS_SNAPSHOT_STATUS=1" >> "$BASH_ENV" environment: FOUNDRY_PROFILE: ci working_directory: packages/contracts-bedrock @@ -416,8 +404,8 @@ jobs: git diff --exit-code ./invariant-docs/*.md || echo "export INVARIANT_DOCS_STATUS=1" >> "$BASH_ENV" working_directory: packages/contracts-bedrock - run: - name: check deploy configs || echo "export DEPLOY_CONFIGS_STATUS=1" >> "$BASH_ENV" - command: pnpm validate-deploy-configs + name: check deploy configs + command: pnpm validate-deploy-configs || echo "export DEPLOY_CONFIGS_STATUS=1" >> "$BASH_ENV" working_directory: packages/contracts-bedrock - run: name: check statuses @@ -453,7 +441,7 @@ jobs: contracts-bedrock-slither: docker: - image: us-docker.pkg.dev/oplabs-tools-artifacts/images/ci-builder:latest - resource_class: large + resource_class: xlarge steps: - checkout - check-changed: @@ -466,14 +454,14 @@ jobs: contracts-bedrock-validate-spaces: docker: - image: us-docker.pkg.dev/oplabs-tools-artifacts/images/ci-builder:latest + resource_class: medium steps: - checkout - - attach_workspace: { at: "." } - restore_cache: name: Restore PNPM Package Cache keys: - pnpm-packages-v2-{{ checksum "pnpm-lock.yaml" }} - # populate node modules from the cache + - attach_workspace: { at: "." } - run: name: Install dependencies command: pnpm install --frozen-lockfile --prefer-offline @@ -487,7 +475,7 @@ jobs: op-bindings-build: docker: - image: us-docker.pkg.dev/oplabs-tools-artifacts/images/ci-builder:latest - resource_class: large + resource_class: xlarge steps: - checkout - run: @@ -509,7 +497,7 @@ jobs: type: string docker: - image: us-docker.pkg.dev/oplabs-tools-artifacts/images/ci-builder:latest - resource_class: large + resource_class: medium steps: - checkout - attach_workspace: { at: "." } @@ -538,7 +526,7 @@ jobs: contracts-ts-tests: docker: - image: us-docker.pkg.dev/oplabs-tools-artifacts/images/ci-builder:latest - resource_class: large + resource_class: medium steps: - checkout - attach_workspace: { at: "." } @@ -560,7 +548,7 @@ jobs: sdk-next-tests: docker: - image: us-docker.pkg.dev/oplabs-tools-artifacts/images/ci-builder:latest - resource_class: large + resource_class: medium steps: - checkout - attach_workspace: { at: "." } @@ -622,10 +610,7 @@ jobs: - run: name: Check TODO issues command: ./ops/scripts/todo-checker.sh --verbose - - slack/notify: - channel: C03N11M0BBN - event: fail - template: basic_fail_1 + - notify-failures-on-develop bedrock-markdown: machine: @@ -669,58 +654,37 @@ jobs: name: link lint command: | make bedrock-markdown-links - - slack/notify: + - notify-failures-on-develop: channel: C055R639XT9 #notify-link-check - event: fail - template: basic_fail_1 - - fuzz-op-node: - docker: - - image: us-docker.pkg.dev/oplabs-tools-artifacts/images/ci-builder:latest - steps: - - checkout - - check-changed: - patterns: op-node - - run: - name: Fuzz - command: make fuzz - working_directory: op-node - - fuzz-op-service: - docker: - - image: us-docker.pkg.dev/oplabs-tools-artifacts/images/ci-builder:latest - steps: - - checkout - - check-changed: - patterns: op-service - - run: - name: Fuzz - command: make fuzz - working_directory: op-service - - fuzz-op-chain-ops: - docker: - - image: us-docker.pkg.dev/oplabs-tools-artifacts/images/ci-builder:latest - steps: - - checkout - - check-changed: - patterns: op-chain-ops,op-bindings - - run: - name: Fuzz - command: make fuzz - working_directory: op-chain-ops - fuzz-cannon: + fuzz-golang: + parameters: + package_name: + description: Go package name + type: string + on_changes: + description: changed pattern to fire fuzzer on + type: string docker: - image: us-docker.pkg.dev/oplabs-tools-artifacts/images/ci-builder:latest steps: - checkout - check-changed: - patterns: cannon,packages/contracts-bedrock/src/cannon + patterns: "<>" + - restore_cache: + name: Restore Go modules cache + key: gomod-{{ checksum "go.sum" }} + - restore_cache: + name: Restore Go build cache + key: golang-build-cache - run: name: Fuzz command: make fuzz - working_directory: cannon + working_directory: "<>" + - save_cache: + key: golang-build-cache + paths: + - "/root/.cache/go-build" depcheck: docker: @@ -747,19 +711,42 @@ jobs: command: npx depcheck working_directory: packages/sdk + l1-geth-version-check: + docker: + - image: us-docker.pkg.dev/oplabs-tools-artifacts/images/ci-builder:latest + steps: + - checkout + - run: + name: "Check L1 geth version" + command: ./ops/scripts/geth-version-checker.sh || (echo "geth version is wrong, update ci-builder"; false) + go-lint: - parameters: - module: - description: Go Module Name - type: string docker: - - image: cimg/go:1.21 + - image: us-docker.pkg.dev/oplabs-tools-artifacts/images/ci-builder:latest steps: - checkout + - restore_cache: + name: Restore Go modules cache + key: gomod-{{ checksum "go.sum" }} + - restore_cache: + key: golang-build-cache + - restore_cache: + key: golang-lint-cache - run: - name: run lint - command: make lint - working_directory: <> + name: run Go linter + command: | + # Identify how many cores it defaults to + golangci-lint --help | grep concurrency + make lint-go + working_directory: . + - save_cache: + key: golang-build-cache + paths: + - "/root/.cache/go-build" + - save_cache: + key: golang-lint-cache + paths: + - "/root/.cache/golangci-lint" go-test: parameters: @@ -771,6 +758,13 @@ jobs: resource_class: xlarge steps: - checkout + - restore_cache: + name: Restore Go modules cache + key: gomod-{{ checksum "go.sum" }} + - restore_cache: + keys: + - golang-build-cache-<> + - golang-build-cache- - run: name: prep results dir command: mkdir -p /tmp/test-results @@ -780,9 +774,14 @@ jobs: gotestsum --format=standard-verbose --junitfile=/tmp/test-results/<>.xml \ -- -parallel=8 -coverpkg=github.com/ethereum-optimism/optimism/... -coverprofile=coverage.out ./... working_directory: <> - - run: - name: upload coverage - command: codecov --verbose --clean --flags bedrock-go-tests + - save_cache: + key: golang-build-cache-<> + paths: + - "/root/.cache/go-build" + # TODO(CLI-148): Fix codecov + #- run: + #name: upload coverage + #command: codecov --verbose --clean --flags bedrock-go-tests - store_test_results: path: /tmp/test-results @@ -794,9 +793,19 @@ jobs: target: description: The make target to execute type: string + cannon_enabled: + description: Whether to include cannon tests + default: true + type: boolean docker: - image: us-docker.pkg.dev/oplabs-tools-artifacts/images/ci-builder:latest resource_class: xlarge + # Note: Tests are split between runs manually. + # Tests default to run on the first executor but can be moved to the second with: + # InitParallel(t, UseExecutor(1)) + # Any tests assigned to an executor greater than the number available automatically use the last executor. + # Executor indexes start from 0 + parallelism: 2 steps: - checkout - check-changed: @@ -804,18 +813,23 @@ jobs: - run: name: prep results dir command: mkdir -p /tmp/test-results + - attach_workspace: + at: /tmp/workspace - run: - name: install geth - command: make install-geth - - run: - name: git submodules - command: git submodule update --init --recursive + name: Load devnet-allocs + command: | + mkdir -p .devnet + cp /tmp/workspace/.devnet/allocs-l1.json .devnet/allocs-l1.json + cp /tmp/workspace/.devnet/addresses.json .devnet/addresses.json + cp /tmp/workspace/packages/contracts-bedrock/deploy-config/devnetL1.json packages/contracts-bedrock/deploy-config/devnetL1.json + cp -r /tmp/workspace/packages/contracts-bedrock/deployments/devnetL1 packages/contracts-bedrock/deployments/devnetL1 - run: name: print go's available MIPS targets command: go tool dist list | grep mips - run: name: run tests - command: + command: | + export OP_E2E_CANNON_ENABLED="<>" # Note: We don't use circle CI test splits because we need to split by test name, not by package. There is an additional # constraint that gotestsum does not currently (nor likely will) accept files from different pacakges when building. JUNIT_FILE=/tmp/test-results/<>_<>.xml make <> @@ -870,7 +884,7 @@ jobs: docker: - image: us-docker.pkg.dev/oplabs-tools-artifacts/images/ci-builder:latest - image: cimg/postgres:14.1 - resource_class: large + resource_class: xlarge steps: - checkout - check-changed: @@ -879,9 +893,6 @@ jobs: name: Lint command: golangci-lint run -E goimports,sqlclosecheck,bodyclose,asciicheck,misspell,errorlint --timeout 4m -e "errors.As" -e "errors.Is" ./... working_directory: indexer - - run: - name: install geth - command: make install-geth - run: name: git submodules command: git submodule update --init --recursive @@ -916,11 +927,67 @@ jobs: command: npm run generate && git diff --exit-code working_directory: indexer/api-ts + cannon-prestate: + docker: + - image: us-docker.pkg.dev/oplabs-tools-artifacts/images/ci-builder:latest + steps: + - checkout + - restore_cache: + name: Restore Go modules cache + key: gomod-{{ checksum "go.sum" }} + - restore_cache: + key: golang-build-cache + - restore_cache: + key: cannon-prestate-{{ checksum "./cannon/bin/cannon" }}-{{ checksum "op-program/bin/op-program-client.elf" }} + name: Load cannon prestate cache + - run: + name: generate cannon prestate + command: make cannon-prestate + - save_cache: + key: cannon-prestate-{{ checksum "./cannon/bin/cannon" }}-{{ checksum "op-program/bin/op-program-client.elf" }} + name: Save Cannon prestate to cache + paths: + - "op-program/bin/prestate.json" + - "op-program/bin/meta.json" + - "op-program/bin/prestate-proof.json" + - persist_to_workspace: + root: . + paths: + - "op-program/bin/prestate.json" + - "op-program/bin/meta.json" + - "op-program/bin/prestate-proof.json" + + devnet-allocs: + docker: + - image: us-docker.pkg.dev/oplabs-tools-artifacts/images/ci-builder:latest + resource_class: xlarge + steps: + - checkout + - restore_cache: + name: Restore Go modules cache + key: gomod-{{ checksum "go.sum" }} + - restore_cache: + key: golang-build-cache + - run: + name: git submodules + command: git submodule update --init --recursive + - run: + name: generate devnet allocs + command: make devnet-allocs + - persist_to_workspace: + root: . + paths: + - ".devnet/allocs-l1.json" + - ".devnet/addresses.json" + - "packages/contracts-bedrock/deploy-config/devnetL1.json" + - "packages/contracts-bedrock/deployments/devnetL1" + devnet: machine: image: ubuntu-2204:2022.10.2 environment: DOCKER_BUILDKIT: 1 + DEVNET_NO_BUILD: 'true' steps: - checkout - check-changed: @@ -967,9 +1034,37 @@ jobs: name: Install and build command: | pnpm install --frozen-lockfile --prefer-offline && pnpm build + - attach_workspace: + at: /tmp/workspace - run: - name: generate cannon prestate - command: make cannon-prestate + name: Load cannon pre-state + command: | + mkdir -p op-program/bin + cp /tmp/workspace/op-program/bin/prestate.json op-program/bin/prestate.json + cp /tmp/workspace/op-program/bin/meta.json op-program/bin/meta.json + cp /tmp/workspace/op-program/bin/prestate-proof.json op-program/bin/prestate-proof.json + - run: + name: Load devnet-allocs + command: | + mkdir -p .devnet + cp /tmp/workspace/.devnet/allocs-l1.json .devnet/allocs-l1.json + cp /tmp/workspace/.devnet/addresses.json .devnet/addresses.json + cp /tmp/workspace/packages/contracts-bedrock/deploy-config/devnetL1.json packages/contracts-bedrock/deploy-config/devnetL1.json + cp -r /tmp/workspace/packages/contracts-bedrock/deployments/devnetL1 packages/contracts-bedrock/deployments/devnetL1 + - run: + name: Load and tag docker images + command: | + IMAGE_BASE_PREFIX="us-docker.pkg.dev/oplabs-tools-artifacts/images" + # Load from previous docker-build job + docker load < "/tmp/workspace/op-stack-go.tar" + docker load < "/tmp/workspace/op-node.tar" + docker load < "/tmp/workspace/op-proposer.tar" + docker load < "/tmp/workspace/op-batcher.tar" + # rename to the tags that the docker-compose of the devnet expects + docker tag "$IMAGE_BASE_PREFIX/op-stack-go:<>" "$IMAGE_BASE_PREFIX/op-stack-go:devnet" + docker tag "$IMAGE_BASE_PREFIX/op-node:<>" "$IMAGE_BASE_PREFIX/op-node:devnet" + docker tag "$IMAGE_BASE_PREFIX/op-proposer:<>" "$IMAGE_BASE_PREFIX/op-proposer:devnet" + docker tag "$IMAGE_BASE_PREFIX/op-batcher:<>" "$IMAGE_BASE_PREFIX/op-batcher:devnet" - run: name: Bring up the stack command: make devnet-up @@ -1052,19 +1147,52 @@ jobs: - run: name: "Semgrep scan" command: semgrep ci + - notify-failures-on-develop + + go-mod-download: + docker: + - image: us-docker.pkg.dev/oplabs-tools-artifacts/images/ci-builder:latest + parameters: + file: + default: go.sum + description: The file name of checksum for restore_cache and save_cache. + type: string + key: + default: gomod + description: The key of restore_cache and save_cache. + type: string + steps: + - checkout + - restore_cache: + key: << parameters.key >>-{{ checksum "<< parameters.file >>" }} + name: Restore Go modules cache + - run: + name: Sanity check go mod cache path + command: test "$(go env GOMODCACHE)" == "/go/pkg/mod" # yes, it's an odd path + - run: + command: go mod download + name: Download Go module dependencies + - save_cache: + key: << parameters.key >>-{{ checksum "<< parameters.file >>" }} + name: Save Go modules cache + paths: + - "/go/pkg/mod" go-mod-tidy: docker: - image: us-docker.pkg.dev/oplabs-tools-artifacts/images/ci-builder:latest steps: - checkout + - restore_cache: + name: Restore Go modules cache + key: gomod-{{ checksum "go.sum" }} - run: name: "Go mod tidy" command: make mod-tidy && git diff --exit-code - bedrock-go-tests: + bedrock-go-tests: # just a helper, that depends on all the actual test jobs docker: - - image: cimg/go:1.21 + - image: us-docker.pkg.dev/oplabs-tools-artifacts/images/ci-builder:latest resource_class: medium steps: - run: echo Done @@ -1079,10 +1207,23 @@ jobs: command: | make verify-goerli working_directory: op-program - - slack/notify: - channel: C03N11M0BBN - event: fail - template: basic_fail_1 + - notify-failures-on-develop + + op-program-compat: + docker: + - image: us-docker.pkg.dev/oplabs-tools-artifacts/images/ci-builder:latest + steps: + - checkout + - restore_cache: + name: Restore Go modules cache + key: gomod-{{ checksum "go.sum" }} + - restore_cache: + key: golang-build-cache + - run: + name: compat-goerli + command: | + make run-goerli-verify + working_directory: op-program check-generated-mocks-op-node: docker: @@ -1106,6 +1247,28 @@ jobs: name: check-generated-mocks command: make generate-mocks-op-service && git diff --exit-code + check-values-match: + parameters: + pattern_file1: + type: string + default: "" + pattern_file2: + type: string + default: "" + file1_path: + type: string + default: "" + file2_path: + type: string + default: "" + docker: + - image: us-docker.pkg.dev/oplabs-tools-artifacts/images/ci-builder:latest + steps: + - checkout + - run: + name: Verify Values Match + command: | + ./ops/scripts/ci-match-values-between-files.sh "<< parameters.file1_path >>" "<< parameters.pattern_file1 >>" "<< parameters.file2_path >>" "<< parameters.pattern_file2 >>" workflows: main: when: @@ -1166,110 +1329,116 @@ workflows: - depcheck: requires: - pnpm-monorepo - - devnet - go-lint-test-build: name: proxyd-tests binary_name: proxyd working_directory: proxyd - indexer-tests - - go-lint-test-build: - name: op-heartbeat-tests - binary_name: op-heartbeat - working_directory: op-heartbeat + - l1-geth-version-check - semgrep-scan - - go-mod-tidy - - fuzz-op-node - - fuzz-op-service - - fuzz-op-chain-ops - - fuzz-cannon + - go-mod-download + - go-mod-tidy: + requires: ["go-mod-download"] + - devnet-allocs: # devnet-allocs uses op-node genesis sub-command + requires: + - "go-mod-tidy" + - l1-geth-version-check - bedrock-markdown - - go-lint: - name: op-batcher-lint - module: op-batcher - - go-lint: - name: op-bootnode-lint - module: op-bootnode - - go-lint: - name: op-bindings-lint - module: op-bindings - - go-lint: - name: op-chain-ops-lint - module: op-chain-ops - - go-lint: - name: op-e2e-lint - module: op-e2e - - go-lint: - name: op-node-lint - module: op-node - - go-lint: - name: op-proposer-lint - module: op-proposer - - go-lint: - name: op-challenger-lint - module: op-challenger - - go-lint: - name: op-program-lint - module: op-program - - go-lint: - name: op-service-lint - module: op-service - - go-lint: - name: op-wheel-lint - module: op-wheel + - go-lint: # we combine most of the go-lint work for two reasons: (1) warm up the Go build cache, (2) reduce sum of lint time + name: op-stack-go-lint + requires: [ "go-mod-tidy" ] + - fuzz-golang: + name: op-node-fuzz + package_name: op-node + on_changes: op-node + requires: ["op-stack-go-lint"] + - fuzz-golang: + name: op-service-fuzz + package_name: op-service + on_changes: op-service + requires: ["op-stack-go-lint"] + - fuzz-golang: + name: op-chain-ops-fuzz + package_name: op-chain-ops + on_changes: op-chain-ops,op-bindings + requires: ["op-stack-go-lint"] + - fuzz-golang: + name: cannon-fuzz + package_name: cannon + on_changes: cannon,packages/contracts-bedrock/src/cannon + requires: ["op-stack-go-lint"] + - go-test: + name: op-heartbeat-tests + module: op-heartbeat + requires: [ "op-stack-go-lint" ] - go-test: name: op-batcher-tests module: op-batcher + requires: ["op-stack-go-lint"] - go-test: name: op-bindings-tests module: op-bindings + requires: ["op-stack-go-lint"] - go-test: name: op-chain-ops-tests module: op-chain-ops + requires: ["op-stack-go-lint"] - go-test: name: op-node-tests module: op-node - # TODO: override resource class + requires: ["op-stack-go-lint"] - go-test: name: op-proposer-tests module: op-proposer + requires: ["op-stack-go-lint"] - go-test: name: op-challenger-tests module: op-challenger + requires: ["op-stack-go-lint"] - go-test: name: op-program-tests module: op-program + requires: ["op-stack-go-lint"] - go-test: name: op-service-tests module: op-service + requires: ["op-stack-go-lint"] - go-e2e-test: name: op-e2e-WS-tests module: op-e2e target: test-ws + requires: + - op-stack-go-lint + - devnet-allocs - go-e2e-test: name: op-e2e-HTTP-tests module: op-e2e target: test-http + cannon_enabled: false + requires: + - op-stack-go-lint + - devnet-allocs - go-e2e-test: name: op-e2e-ext-geth-tests module: op-e2e target: test-external-geth + cannon_enabled: false + requires: + - op-stack-go-lint + - devnet-allocs + - l1-geth-version-check + - op-program-compat: + requires: + - op-program-tests - bedrock-go-tests: requires: + - go-mod-download - go-mod-tidy - cannon-build-test-vectors - cannon-go-lint-and-test - check-generated-mocks-op-node - check-generated-mocks-op-service - - op-batcher-lint - - op-bootnode-lint - - op-bindings-lint - - op-chain-ops-lint - - op-e2e-lint - - op-node-lint - - op-proposer-lint - - op-challenger-lint - - op-program-lint - - op-service-lint + - op-stack-go-lint - op-batcher-tests - op-bindings-tests - op-chain-ops-tests @@ -1278,63 +1447,79 @@ workflows: - op-proposer-tests - op-challenger-tests - op-program-tests + - op-program-compat - op-service-tests - op-e2e-WS-tests - op-e2e-HTTP-tests - op-e2e-ext-geth-tests + - docker-build: # just to warm up the cache (other jobs run in parallel) + name: op-stack-go-docker-build + docker_name: op-stack-go + docker_tags: <>,<> + save_image_tag: <> # for devnet later - docker-build: name: op-node-docker-build - docker_file: op-node/Dockerfile docker_name: op-node docker_tags: <>,<> - docker_context: . + requires: ['op-stack-go-docker-build'] + save_image_tag: <> # for devnet later - docker-build: name: op-batcher-docker-build - docker_file: op-batcher/Dockerfile docker_name: op-batcher docker_tags: <>,<> - docker_context: . + requires: ['op-stack-go-docker-build'] + save_image_tag: <> # for devnet later - docker-build: name: op-program-docker-build - docker_file: op-program/Dockerfile docker_name: op-program docker_tags: <>,<> - docker_context: . + requires: ['op-stack-go-docker-build'] + save_image_tag: <> # for devnet later - docker-build: name: op-proposer-docker-build - docker_file: op-proposer/Dockerfile docker_name: op-proposer docker_tags: <>,<> - docker_context: . + requires: ['op-stack-go-docker-build'] + save_image_tag: <> # for devnet later - docker-build: name: op-challenger-docker-build - docker_file: op-challenger/Dockerfile docker_name: op-challenger docker_tags: <>,<> - docker_context: . + requires: ['op-stack-go-docker-build'] + save_image_tag: <> # for devnet later - docker-build: name: op-heartbeat-docker-build - docker_file: op-heartbeat/Dockerfile docker_name: op-heartbeat docker_tags: <>,<> - docker_context: . + requires: ['op-stack-go-docker-build'] + save_image_tag: <> # for devnet later + - cannon-prestate: + requires: ["op-stack-go-lint"] + - devnet: + requires: + - op-node-docker-build + - op-batcher-docker-build + - op-proposer-docker-build + - l1-geth-version-check + - devnet-allocs + - cannon-prestate - docker-build: name: indexer-docker-build - docker_file: indexer/Dockerfile docker_name: indexer docker_tags: <>,<> - docker_context: . - docker-build: name: ufm-metamask-docker-build - docker_file: ufm-test-services/metamask/Dockerfile docker_name: ufm-metamask docker_tags: <>,<> - docker_context: ufm-test-services/metamask - check-generated-mocks-op-node - check-generated-mocks-op-service - cannon-go-lint-and-test - cannon-build-test-vectors - + - check-values-match: + pattern_file1: "uint8 internal constant INITIALIZER =" + pattern_file2: "const initializedValue =" + file1_path: "packages/contracts-bedrock/src/libraries/Constants.sol" + file2_path: "op-chain-ops/genesis/config.go" release: when: not: @@ -1344,175 +1529,184 @@ workflows: type: approval filters: tags: - only: /^(proxyd|indexer|ci-builder|ufm-[a-z0-9\-]*|op-[a-z0-9\-]*)\/v.*/ + only: /^(proxyd|chain-mon|indexer|ci-builder|ufm-[a-z0-9\-]*|op-[a-z0-9\-]*)\/v.*/ branches: ignore: /.*/ - - docker-release: + - docker-build: # just to warm up the cache (other jobs run in parallel) + name: op-stack-go-docker-build-release + filters: + tags: + only: /^(proxyd|chain-mon|indexer|ci-builder|ufm-[a-z0-9\-]*|op-[a-z0-9\-]*)\/v.*/ + branches: + ignore: /.*/ + docker_name: op-stack-go + docker_tags: <> + platforms: "linux/amd64,linux/arm64" + requires: + - hold + - docker-build: name: op-heartbeat-release filters: tags: only: /^op-heartbeat\/v.*/ branches: ignore: /.*/ - docker_file: op-heartbeat/Dockerfile docker_name: op-heartbeat - docker_tags: <>,<> - docker_context: . + docker_tags: <> + requires: ['op-stack-go-docker-build-release'] platforms: "linux/amd64,linux/arm64" + publish: true + release: true context: - oplabs-gcr-release - requires: - - hold - - docker-release: + - docker-build: name: op-node-docker-release filters: tags: only: /^op-node\/v.*/ branches: ignore: /.*/ - docker_file: op-node/Dockerfile docker_name: op-node - docker_tags: <>,<> - docker_context: . + docker_tags: <> + requires: ['op-stack-go-docker-build-release'] platforms: "linux/amd64,linux/arm64" + publish: true + release: true context: - oplabs-gcr-release - requires: - - hold - - docker-release: + - docker-build: name: op-batcher-docker-release filters: tags: only: /^op-batcher\/v.*/ branches: ignore: /.*/ - docker_file: op-batcher/Dockerfile docker_name: op-batcher - docker_tags: <>,<> - docker_context: . + docker_tags: <> + requires: ['op-stack-go-docker-build-release'] platforms: "linux/amd64,linux/arm64" + publish: true + release: true context: - oplabs-gcr-release - requires: - - hold - - docker-release: + - docker-build: name: op-proposer-docker-release filters: tags: only: /^op-proposer\/v.*/ branches: ignore: /.*/ - docker_file: op-proposer/Dockerfile docker_name: op-proposer - docker_tags: <>,<> - docker_context: . + docker_tags: <> + requires: ['op-stack-go-docker-build-release'] platforms: "linux/amd64,linux/arm64" + publish: true + release: true context: - oplabs-gcr-release - requires: - - hold - - docker-release: + - docker-build: name: op-challenger-docker-release filters: tags: only: /^op-challenger\/v.*/ branches: ignore: /.*/ - docker_file: op-challenger/Dockerfile docker_name: op-challenger - docker_tags: <>,<> - docker_context: . + docker_tags: <> + requires: ['op-stack-go-docker-build-release'] platforms: "linux/amd64,linux/arm64" + publish: true + release: true context: - oplabs-gcr-release - requires: - - hold - docker-build: - name: op-migrate-docker-release - filters: - tags: - only: /^op-migrate\/v.*/ - branches: - ignore: /.*/ - docker_file: op-chain-ops/Dockerfile - docker_name: op-migrate - docker_tags: <>,<> - docker_context: . - context: - - oplabs-gcr-release - requires: - - hold - - docker-release: name: op-ufm-docker-release filters: tags: only: /^op-ufm\/v.*/ branches: ignore: /.*/ - docker_file: op-ufm/Dockerfile docker_name: op-ufm - docker_tags: <>,<> - docker_context: . + docker_tags: <> + publish: true + release: true context: - oplabs-gcr-release requires: - hold - - docker-release: + - docker-build: name: proxyd-docker-release filters: tags: only: /^proxyd\/v.*/ branches: ignore: /.*/ - docker_file: proxyd/Dockerfile docker_name: proxyd - docker_tags: <>,<> - docker_context: . + docker_tags: <> + publish: true + release: true context: - oplabs-gcr-release requires: - hold - - docker-release: + - docker-build: name: indexer-docker-release filters: tags: only: /^indexer\/v.*/ branches: ignore: /.*/ - docker_file: indexer/Dockerfile docker_name: indexer - docker_tags: <>,<> - docker_context: . + docker_tags: <> + publish: true + release: true + context: + - oplabs-gcr-release + requires: + - hold + - docker-build: + name: chain-mon-docker-release + filters: + tags: + only: /^chain-mon\/v.*/ + branches: + ignore: /.*/ + docker_name: chain-mon + docker_tags: <>,latest + publish: true + release: true + resource_class: xlarge context: - oplabs-gcr-release requires: - hold - - docker-release: + - docker-build: name: ci-builder-docker-release filters: tags: only: /^ci-builder\/v.*/ branches: ignore: /.*/ - docker_file: ./ops/docker/ci-builder/Dockerfile docker_name: ci-builder docker_tags: <>,latest - docker_context: . + publish: true + release: true + resource_class: xlarge context: - oplabs-gcr requires: - hold - - docker-release: + - docker-build: name: ufm-metamask-docker-release filters: tags: only: /^ufm-metamask\/v.*/ branches: ignore: /.*/ - docker_file: ./ufm-test-services/metamask/Dockerfile docker_name: ufm-metamask docker_tags: <>,latest - docker_context: ./ufm-test-services/metamask + publish: true + release: true context: - oplabs-gcr requires: @@ -1547,75 +1741,96 @@ workflows: when: equal: [ build_hourly, <> ] jobs: - - docker-publish: + - docker-build: # just to warm up the cache (other jobs run in parallel) + name: op-stack-go-docker-build-publish + docker_name: op-stack-go + docker_tags: <>,<> + platforms: "linux/amd64,linux/arm64" + context: + - oplabs-gcr + - slack + - docker-build: name: op-node-docker-publish docker_name: op-node - docker_file: op-node/Dockerfile docker_tags: <>,<> + requires: [ 'op-stack-go-docker-build-publish' ] + platforms: "linux/amd64,linux/arm64" + publish: true context: - oplabs-gcr - platforms: "linux/amd64,linux/arm64" - - docker-publish: + - slack + - docker-build: name: op-batcher-docker-publish - docker_file: op-batcher/Dockerfile docker_name: op-batcher docker_tags: <>,<> + requires: [ 'op-stack-go-docker-build-publish' ] + platforms: "linux/amd64,linux/arm64" + publish: true context: - oplabs-gcr - platforms: "linux/amd64,linux/arm64" - - docker-publish: + - slack + - docker-build: name: op-program-docker-publish - docker_file: op-program/Dockerfile docker_name: op-program docker_tags: <>,<> + requires: [ 'op-stack-go-docker-build-publish' ] + platforms: "linux/amd64,linux/arm64" + publish: true context: - oplabs-gcr - platforms: "linux/amd64,linux/arm64" - - docker-publish: + - slack + - docker-build: name: op-proposer-docker-publish - docker_file: op-proposer/Dockerfile docker_name: op-proposer docker_tags: <>,<> + requires: [ 'op-stack-go-docker-build-publish' ] + platforms: "linux/amd64,linux/arm64" + publish: true context: - oplabs-gcr - platforms: "linux/amd64,linux/arm64" - - docker-publish: + - slack + - docker-build: name: op-challenger-docker-publish - docker_file: op-challenger/Dockerfile docker_name: op-challenger docker_tags: <>,<> + requires: [ 'op-stack-go-docker-build-publish' ] + platforms: "linux/amd64,linux/arm64" + publish: true context: - oplabs-gcr - platforms: "linux/amd64,linux/arm64" - - docker-publish: + - slack + - docker-build: name: op-heartbeat-docker-publish - docker_file: op-heartbeat/Dockerfile docker_name: op-heartbeat docker_tags: <>,<> + requires: [ 'op-stack-go-docker-build-publish' ] + platforms: "linux/amd64,linux/arm64" + publish: true context: - oplabs-gcr - platforms: "linux/amd64,linux/arm64" - - docker-publish: + - slack + - docker-build: name: indexer-docker-publish - docker_file: indexer/Dockerfile docker_name: indexer docker_tags: <>,<> + publish: true context: - oplabs-gcr + - slack platforms: "linux/amd64,linux/arm64" - - docker-publish: + - docker-build: name: chain-mon-docker-publish - docker_file: ./ops/docker/Dockerfile.packages docker_name: chain-mon docker_tags: <>,<> - docker_target: wd-mon + publish: true context: - oplabs-gcr - - docker-publish: + - slack + - docker-build: name: ufm-metamask-docker-publish - docker_file: ufm-test-services/metamask/Dockerfile docker_name: ufm-metamask - docker_context: ufm-test-services/metamask docker_tags: <>,<> + publish: true context: - oplabs-gcr + - slack diff --git a/.envrc.example b/.envrc.example new file mode 100644 index 0000000000000..0ea9d7ea1bac1 --- /dev/null +++ b/.envrc.example @@ -0,0 +1,55 @@ +################################################## +# Getting Started # +################################################## + +# Admin account +export GS_ADMIN_ADDRESS= +export GS_ADMIN_PRIVATE_KEY= + +# Batcher account +export GS_BATCHER_ADDRESS= +export GS_BATCHER_PRIVATE_KEY= + +# Proposer account +export GS_PROPOSER_ADDRESS= +export GS_PROPOSER_PRIVATE_KEY= + +# Sequencer account +export GS_SEQUENCER_ADDRESS= +export GS_SEQUENCER_PRIVATE_KEY= + +################################################## +# op-node Configuration # +################################################## + +# The kind of RPC provider, used to inform optimal transactions receipts +# fetching. Valid options: alchemy, quicknode, infura, parity, nethermind, +# debug_geth, erigon, basic, any. +export L1_RPC_KIND= + +################################################## +# Contract Deployment # +################################################## + +# RPC URL for the L1 network to interact with +export L1_RPC_URL= + +# Salt used via CREATE2 to determine implementation addresses +# NOTE: If you want to deploy contracts from scratch you MUST reload this +# variable to ensure the salt is regenerated and the contracts are +# deployed to new addresses (otherwise deployment will fail) +export IMPL_SALT=$(openssl rand -hex 32) + +# Name for the deployed network +export DEPLOYMENT_CONTEXT=getting-started + +# Optional Tenderly details for simulation link during deployment +export TENDERLY_PROJECT= +export TENDERLY_USERNAME= + +# Optional Etherscan API key for contract verification +export ETHERSCAN_API_KEY= + +# Private key to use for contract deployments, you don't need to worry about +# this for the Getting Started guide. +export PRIVATE_KEY= diff --git a/.foundryrc b/.foundryrc index 5023fd81fc9f7..90fe0bd77b757 100644 --- a/.foundryrc +++ b/.foundryrc @@ -1 +1 @@ -3b1129b5bc43ba22a9bcf4e4323c5a9df0023140 +d85718785859dc0b5a095d2302d1a20ec06ab77a diff --git a/.gethrc b/.gethrc new file mode 100644 index 0000000000000..dd64e523ec449 --- /dev/null +++ b/.gethrc @@ -0,0 +1 @@ +v1.13.4 diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS index a216ace2af2e4..a142b138a992c 100644 --- a/.github/CODEOWNERS +++ b/.github/CODEOWNERS @@ -16,7 +16,7 @@ /op-exporter @ethereum-optimism/go-reviewers /op-heartbeat @ethereum-optimism/go-reviewers /op-node @ethereum-optimism/go-reviewers -/op-node/rollup @protolambda @trianglesphere +/op-node/rollup @protolambda @trianglesphere @ajsutton /op-preimage @ethereum-optimism/go-reviewers /op-program @ethereum-optimism/go-reviewers /op-proposer @ethereum-optimism/go-reviewers @@ -25,9 +25,10 @@ /ops-bedrock @ethereum-optimism/go-reviewers # Ops -/.circleci @ethereum-optimism/infra-reviewers -/.github @ethereum-optimism/infra-reviewers -/ops @ethereum-optimism/infra-reviewers +/.circleci @ethereum-optimism/infra-reviewers +/.github @ethereum-optimism/infra-reviewers +/ops @ethereum-optimism/infra-reviewers +/docker-bake.hcl @ethereum-optimism/infra-reviewers # Misc /proxyd @ethereum-optimism/infra-reviewers diff --git a/.github/workflows/release-docker-canary.yml b/.github/workflows/release-docker-canary.yml index 559d56a155f15..ad16a8fc25a53 100644 --- a/.github/workflows/release-docker-canary.yml +++ b/.github/workflows/release-docker-canary.yml @@ -15,11 +15,12 @@ jobs: runs-on: ubuntu-latest # map the step outputs to job outputs outputs: - fault-mon: ${{ steps.packages.outputs.fault-mon }} balance-mon: ${{ steps.packages.outputs.balance-mon }} drippie-mon: ${{ steps.packages.outputs.drippie-mon }} - wd-mon: ${{ steps.packages.outputs.wd-mon }} + fault-mon: ${{ steps.packages.outputs.fault-mon }} + multisig-mon: ${{ steps.packages.outputs.multisig-mon }} replica-mon: ${{ steps.packages.outputs.replica-mon }} + wd-mon: ${{ steps.packages.outputs.wd-mon }} canary-docker-tag: ${{ steps.docker-image-name.outputs.canary-docker-tag }} op-exporter: ${{ steps.packages.outputs.op-exporter }} endpoint-monitor: ${{ steps.packages.outputs.endpoint-monitor }} @@ -97,6 +98,33 @@ jobs: push: true tags: ethereumoptimism/balance-mon:${{ needs.canary-publish.outputs.canary-docker-tag }} + multisig-mon: + name: Publish Multisig Monitor Version ${{ needs.canary-publish.outputs.canary-docker-tag }} + needs: canary-publish + if: needs.canary-publish.outputs.multisig-mon != '' + runs-on: ubuntu-latest + + steps: + - name: Checkout + uses: actions/checkout@v4 + - name: Set up Docker Buildx + uses: docker/setup-buildx-action@v3 + + - name: Login to Docker Hub + uses: docker/login-action@v3 + with: + username: ${{ secrets.DOCKERHUB_ACCESS_TOKEN_USERNAME }} + password: ${{ secrets.DOCKERHUB_ACCESS_TOKEN_SECRET }} + + - name: Build and push + uses: docker/build-push-action@v2 + with: + context: . + file: ./ops/docker/Dockerfile.packages + target: multisig-mon + push: true + tags: ethereumoptimism/multisig-mon:${{ needs.canary-publish.outputs.canary-docker-tag }} + drippie-mon: name: Publish Drippie Monitor Version ${{ needs.canary-publish.outputs.canary-docker-tag }} needs: canary-publish diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 4ecc0e2113168..39e19b0aeb591 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -16,11 +16,12 @@ jobs: if: github.repository == 'ethereum-optimism/optimism' # map the step outputs to job outputs outputs: - fault-mon: ${{ steps.packages.outputs.fault-mon }} - balance-mon: ${{ steps.packages.outputs.drippie-mon }} + balance-mon: ${{ steps.packages.outputs.balance-mon }} drippie-mon: ${{ steps.packages.outputs.drippie-mon }} - wd-mon: ${{ steps.packages.outputs.wd-mon }} + fault-mon: ${{ steps.packages.outputs.fault-mon }} + multisig-mon: ${{ steps.packages.outputs.multisig-mon }} replica-mon: ${{ steps.packages.outputs.replica-mon }} + wd-mon: ${{ steps.packages.outputs.wd-mon }} op-exporter: ${{ steps.packages.outputs.op-exporter }} endpoint-monitor: ${{ steps.packages.outputs.endpoint-monitor }} # Permissions necessary for Changesets to push a new branch and open PRs @@ -186,6 +187,33 @@ jobs: push: true tags: ethereumoptimism/balance-mon:${{ needs.release.outputs.balance-mon }},ethereumoptimism/balance-mon:latest + multisig-mon: + name: Publish Multisig Monitor Version ${{ needs.release.outputs.multisig-mon }} + needs: release + if: needs.release.outputs.multisig-mon != '' + runs-on: ubuntu-latest + + steps: + - name: Checkout + uses: actions/checkout@v4 + - name: Set up Docker Buildx + uses: docker/setup-buildx-action@v3 + + - name: Login to Docker Hub + uses: docker/login-action@v3 + with: + username: ${{ secrets.DOCKERHUB_ACCESS_TOKEN_USERNAME }} + password: ${{ secrets.DOCKERHUB_ACCESS_TOKEN_SECRET }} + + - name: Build and push + uses: docker/build-push-action@v2 + with: + context: . + file: ./ops/docker/Dockerfile.packages + target: multisig-mon + push: true + tags: ethereumoptimism/multisig-mon:${{ needs.release.outputs.multisig-mon }},ethereumoptimism/multisig-mon:latest + drippie-mon: name: Publish Drippie Monitor Version ${{ needs.release.outputs.drippie-mon }} needs: release diff --git a/.gitignore b/.gitignore index 7e43dbf2efc1d..be41d3314033e 100644 --- a/.gitignore +++ b/.gitignore @@ -30,6 +30,7 @@ packages/contracts-bedrock/deployments/anvil .env .env* !.env.example +!.envrc.example *.log .devnet diff --git a/.gitmodules b/.gitmodules index 802f78e7a218c..e3bf555822963 100644 --- a/.gitmodules +++ b/.gitmodules @@ -17,6 +17,3 @@ path = packages/contracts-bedrock/lib/safe-contracts url = https://github.com/safe-global/safe-contracts branch = v1.4.0 - - - diff --git a/.nvmrc b/.nvmrc index 860cc5000ae69..805b5a4e00bff 100644 --- a/.nvmrc +++ b/.nvmrc @@ -1 +1 @@ -v18.17.1 +v20.9.0 diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index bcf0e8703602b..96cd56173c13a 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -181,9 +181,9 @@ You must have Python 3.x installed to run `slither`. To run `slither` locally, do: ```bash -cd packages/contracts +cd packages/contracts-bedrock pip3 install slither-analyzer -pnpm test:slither +pnpm slither ``` ## Labels diff --git a/Makefile b/Makefile index 077c477bbab57..6125ed93ef138 100644 --- a/Makefile +++ b/Makefile @@ -1,6 +1,10 @@ COMPOSEFLAGS=-d ITESTS_L2_HOST=http://localhost:9545 BEDROCK_TAGS_REMOTE?=origin +OP_STACK_GO_BUILDER?=us-docker.pkg.dev/oplabs-tools-artifacts/images/op-stack-go:latest + +# Requires at least Python v3.9; specify a minor version below if needed +PYTHON?=python3 build: build-go build-ts .PHONY: build @@ -8,6 +12,10 @@ build: build-go build-ts build-go: submodules op-node op-proposer op-batcher .PHONY: build-go +lint-go: + golangci-lint run -E goimports,sqlclosecheck,bodyclose,asciicheck,misspell,errorlint --timeout 5m -e "errors.As" -e "errors.Is" ./... +.PHONY: lint-go + build-ts: submodules if [ -n "$$NVM_DIR" ]; then \ . $$NVM_DIR/nvm.sh && nvm use; \ @@ -19,6 +27,18 @@ build-ts: submodules ci-builder: docker build -t ci-builder -f ops/docker/ci-builder/Dockerfile . +golang-docker: + # We don't use a buildx builder here, and just load directly into regular docker, for convenience. + GIT_COMMIT=$$(git rev-parse HEAD) \ + GIT_DATE=$$(git show -s --format='%ct') \ + IMAGE_TAGS=$$(git rev-parse HEAD),latest \ + docker buildx bake \ + --progress plain \ + --load \ + -f docker-bake.hcl \ + op-node op-batcher op-proposer op-challenger +.PHONY: golang-docker + submodules: # CI will checkout submodules on its own (and fails on these commands) if [ -z "$$GITHUB_ENV" ]; then \ @@ -97,14 +117,14 @@ pre-devnet: devnet-up: pre-devnet ./ops/scripts/newer-file.sh .devnet/allocs-l1.json ./packages/contracts-bedrock \ || make devnet-allocs - PYTHONPATH=./bedrock-devnet python3 ./bedrock-devnet/main.py --monorepo-dir=. + PYTHONPATH=./bedrock-devnet $(PYTHON) ./bedrock-devnet/main.py --monorepo-dir=. .PHONY: devnet-up # alias for devnet-up devnet-up-deploy: devnet-up devnet-test: pre-devnet - PYTHONPATH=./bedrock-devnet python3 ./bedrock-devnet/main.py --monorepo-dir=. --test + PYTHONPATH=./bedrock-devnet $(PYTHON) ./bedrock-devnet/main.py --monorepo-dir=. --test .PHONY: devnet-test devnet-down: @@ -120,7 +140,7 @@ devnet-clean: .PHONY: devnet-clean devnet-allocs: pre-devnet - PYTHONPATH=./bedrock-devnet python3 ./bedrock-devnet/main.py --monorepo-dir=. --allocs + PYTHONPATH=./bedrock-devnet $(PYTHON) ./bedrock-devnet/main.py --monorepo-dir=. --allocs devnet-logs: @(cd ./ops-bedrock && docker compose logs -f) @@ -163,4 +183,9 @@ bedrock-markdown-links: --exclude-mail /input/README.md "/input/specs/**/*.md" install-geth: - go install github.com/ethereum/go-ethereum/cmd/geth@v1.12.0 + ./ops/scripts/geth-version-checker.sh && \ + (echo "Geth versions match, not installing geth..."; true) || \ + (echo "Versions do not match, installing geth!"; \ + go install -v github.com/ethereum/go-ethereum/cmd/geth@$(shell cat .gethrc); \ + echo "Installed geth!"; true) +.PHONY: install-geth diff --git a/bedrock-devnet/devnet/__init__.py b/bedrock-devnet/devnet/__init__.py index 1f0a5680f0dad..1f3b91a95a894 100644 --- a/bedrock-devnet/devnet/__init__.py +++ b/bedrock-devnet/devnet/__init__.py @@ -10,6 +10,9 @@ import shutil import http.client from multiprocessing import Process, Queue +import concurrent.futures +from collections import namedtuple + import devnet.log_setup @@ -94,10 +97,21 @@ def main(): devnet_l1_genesis(paths) return - log.info('Building docker images') - run_command(['docker', 'compose', 'build', '--progress', 'plain'], cwd=paths.ops_bedrock_dir, env={ - 'PWD': paths.ops_bedrock_dir - }) + git_commit = subprocess.run(['git', 'rev-parse', 'HEAD'], capture_output=True, text=True).stdout.strip() + git_date = subprocess.run(['git', 'show', '-s', "--format=%ct"], capture_output=True, text=True).stdout.strip() + + # CI loads the images from workspace, and does not otherwise know the images are good as-is + if os.getenv('DEVNET_NO_BUILD') == "true": + log.info('Skipping docker images build') + else: + log.info(f'Building docker images for git commit {git_commit} ({git_date})') + run_command(['docker', 'compose', 'build', '--progress', 'plain', + '--build-arg', f'GIT_COMMIT={git_commit}', '--build-arg', f'GIT_DATE={git_date}'], + cwd=paths.ops_bedrock_dir, env={ + 'PWD': paths.ops_bedrock_dir, + 'DOCKER_BUILDKIT': '1', # (should be available by default in later versions, but explicitly enable it anyway) + 'COMPOSE_DOCKER_CLI_BUILD': '1' # use the docker cache + }) log.info('Devnet starting') devnet_deploy(paths) @@ -188,13 +202,12 @@ def devnet_deploy(paths): # If someone reads this comment and understands why this is being done, please # update this comment to explain. init_devnet_l1_deploy_config(paths, update_timestamp=True) - outfile_l1 = pjoin(paths.devnet_dir, 'genesis-l1.json') run_command([ 'go', 'run', 'cmd/main.go', 'genesis', 'l1', '--deploy-config', paths.devnet_config_path, '--l1-allocs', paths.allocs_path, '--l1-deployments', paths.addresses_json_path, - '--outfile.l1', outfile_l1, + '--outfile.l1', paths.genesis_l1_path, ], cwd=paths.op_node_dir) log.info('Starting L1.') @@ -213,8 +226,8 @@ def devnet_deploy(paths): '--l1-rpc', 'http://localhost:8545', '--deploy-config', paths.devnet_config_path, '--deployment-dir', paths.deployment_dir, - '--outfile.l2', pjoin(paths.devnet_dir, 'genesis-l2.json'), - '--outfile.rollup', pjoin(paths.devnet_dir, 'rollup.json') + '--outfile.l2', paths.genesis_l2_path, + '--outfile.rollup', paths.rollup_config_path ], cwd=paths.op_node_dir) rollup_config = read_json(paths.rollup_config_path) @@ -274,21 +287,27 @@ def debug_dumpBlock(url): def wait_for_rpc_server(url): log.info(f'Waiting for RPC server at {url}') - conn = http.client.HTTPConnection(url) headers = {'Content-type': 'application/json'} body = '{"id":1, "jsonrpc":"2.0", "method": "eth_chainId", "params":[]}' while True: try: + conn = http.client.HTTPConnection(url) conn.request('POST', '/', body, headers) response = conn.getresponse() - conn.close() if response.status < 300: log.info(f'RPC server at {url} ready') return except Exception as e: log.info(f'Waiting for RPC server at {url}') time.sleep(1) + finally: + if conn: + conn.close() + + +CommandPreset = namedtuple('Command', ['name', 'args', 'cwd', 'timeout']) + def devnet_test(paths): # Check the L2 config @@ -297,17 +316,57 @@ def devnet_test(paths): cwd=paths.ops_chain_ops, ) - run_command( - ['npx', 'hardhat', 'deposit-erc20', '--network', 'devnetL1', '--l1-contracts-json-path', paths.addresses_json_path], - cwd=paths.sdk_dir, - timeout=8*60, - ) + # Run the two commands with different signers, so the ethereum nonce management does not conflict + # And do not use devnet system addresses, to avoid breaking fee-estimation or nonce values. + run_commands([ + CommandPreset('erc20-test', + ['npx', 'hardhat', 'deposit-erc20', '--network', 'devnetL1', + '--l1-contracts-json-path', paths.addresses_json_path, '--signer-index', '14'], + cwd=paths.sdk_dir, timeout=8*60), + CommandPreset('eth-test', + ['npx', 'hardhat', 'deposit-eth', '--network', 'devnetL1', + '--l1-contracts-json-path', paths.addresses_json_path, '--signer-index', '15'], + cwd=paths.sdk_dir, timeout=8*60) + ], max_workers=2) + + +def run_commands(commands: list[CommandPreset], max_workers=2): + with concurrent.futures.ThreadPoolExecutor(max_workers=max_workers) as executor: + futures = [executor.submit(run_command_preset, cmd) for cmd in commands] + + for future in concurrent.futures.as_completed(futures): + result = future.result() + if result: + print(result.stdout) + + +def run_command_preset(command: CommandPreset): + with subprocess.Popen(command.args, cwd=command.cwd, + stdout=subprocess.PIPE, stderr=subprocess.PIPE, text=True) as proc: + try: + # Live output processing + for line in proc.stdout: + # Annotate and print the line with timestamp and command name + timestamp = datetime.datetime.utcnow().strftime('%H:%M:%S.%f') + # Annotate and print the line with the timestamp + print(f"[{timestamp}][{command.name}] {line}", end='') + + stdout, stderr = proc.communicate(timeout=command.timeout) + + if proc.returncode != 0: + raise RuntimeError(f"Command '{' '.join(command.args)}' failed with return code {proc.returncode}: {stderr}") + + except subprocess.TimeoutExpired: + raise RuntimeError(f"Command '{' '.join(command.args)}' timed out!") + + except Exception as e: + raise RuntimeError(f"Error executing '{' '.join(command.args)}': {e}") + + finally: + # Ensure process is terminated + proc.kill() + return proc.returncode - run_command( - ['npx', 'hardhat', 'deposit-eth', '--network', 'devnetL1', '--l1-contracts-json-path', paths.addresses_json_path], - cwd=paths.sdk_dir, - timeout=8*60, - ) def run_command(args, check=True, shell=False, cwd=None, env=None, timeout=None): env = env if env else {} diff --git a/cannon/Makefile b/cannon/Makefile index 186a2a05c8674..6e3afdd265241 100644 --- a/cannon/Makefile +++ b/cannon/Makefile @@ -1,5 +1,5 @@ -GITCOMMIT := $(shell git rev-parse HEAD) -GITDATE := $(shell git show -s --format='%ct') +GITCOMMIT ?= $(shell git rev-parse HEAD) +GITDATE ?= $(shell git show -s --format='%ct') VERSION := v0.0.0 LDFLAGSSTRING +=-X main.GitCommit=$(GITCOMMIT) @@ -20,9 +20,6 @@ elf: test: elf go test -v ./... -lint: - golangci-lint run -E goimports,sqlclosecheck,bodyclose,asciicheck,misspell,errorlint --timeout 5m -e "errors.As" -e "errors.Is" - fuzz: go test -run NOTAREALTEST -v -fuzztime 10s -fuzz=FuzzStateSyscallBrk ./mipsevm go test -run NOTAREALTEST -v -fuzztime 10s -fuzz=FuzzStateSyscallClone ./mipsevm diff --git a/cannon/cmd/run.go b/cannon/cmd/run.go index 8eb46a21d7c84..86234684fd4ce 100644 --- a/cannon/cmd/run.go +++ b/cannon/cmd/run.go @@ -94,9 +94,6 @@ type Proof struct { OracleKey hexutil.Bytes `json:"oracle-key,omitempty"` OracleValue hexutil.Bytes `json:"oracle-value,omitempty"` OracleOffset uint32 `json:"oracle-offset,omitempty"` - - StepInput hexutil.Bytes `json:"step-input"` - OracleInput hexutil.Bytes `json:"oracle-input"` } type rawHint string @@ -348,14 +345,8 @@ func Run(ctx *cli.Context) error { Post: postStateHash, StateData: witness.State, ProofData: witness.MemProof, - StepInput: witness.EncodeStepInput(), } if witness.HasPreimage() { - inp, err := witness.EncodePreimageOracleInput() - if err != nil { - return fmt.Errorf("failed to encode pre-image oracle input: %w", err) - } - proof.OracleInput = inp proof.OracleKey = witness.PreimageKey[:] proof.OracleValue = witness.PreimageValue proof.OracleOffset = witness.PreimageOffset diff --git a/cannon/example/claim/go.mod b/cannon/example/claim/go.mod index 1b0164620c72e..40d79b115ac5c 100644 --- a/cannon/example/claim/go.mod +++ b/cannon/example/claim/go.mod @@ -7,8 +7,8 @@ toolchain go1.21.1 require github.com/ethereum-optimism/optimism v0.0.0 require ( - golang.org/x/crypto v0.14.0 // indirect - golang.org/x/sys v0.13.0 // indirect + golang.org/x/crypto v0.15.0 // indirect + golang.org/x/sys v0.14.0 // indirect ) replace github.com/ethereum-optimism/optimism v0.0.0 => ../../.. diff --git a/cannon/example/claim/go.sum b/cannon/example/claim/go.sum index 9651411c94df7..484dafa8adf16 100644 --- a/cannon/example/claim/go.sum +++ b/cannon/example/claim/go.sum @@ -4,9 +4,9 @@ github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZb github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= github.com/stretchr/testify v1.8.4 h1:CcVxjf3Q8PM0mHUKJCdn+eZZtm5yQwehR5yeSVQQcUk= github.com/stretchr/testify v1.8.4/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo= -golang.org/x/crypto v0.14.0 h1:wBqGXzWJW6m1XrIKlAH0Hs1JJ7+9KBwnIO8v66Q9cHc= -golang.org/x/crypto v0.14.0/go.mod h1:MVFd36DqK4CsrnJYDkBA3VC4m2GkXAM0PvzMCn4JQf4= -golang.org/x/sys v0.13.0 h1:Af8nKPmuFypiUBjVoU9V20FiaFXOcuZI21p0ycVYYGE= -golang.org/x/sys v0.13.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/crypto v0.15.0 h1:frVn1TEaCEaZcn3Tmd7Y2b5KKPaZ+I32Q2OA3kYp5TA= +golang.org/x/crypto v0.15.0/go.mod h1:4ChreQoLWfG3xLDer1WdlH5NdlQ3+mwnQq1YTKY+72g= +golang.org/x/sys v0.14.0 h1:Vz7Qs629MkJkGyHxUlRHizWJRG2j8fbQKjELVSNhy7Q= +golang.org/x/sys v0.14.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= diff --git a/cannon/mipsevm/evm.go b/cannon/mipsevm/evm.go index 6453f7384e5a6..7c6ddd8f5c480 100644 --- a/cannon/mipsevm/evm.go +++ b/cannon/mipsevm/evm.go @@ -16,7 +16,6 @@ import ( "github.com/ethereum/go-ethereum/core/state" "github.com/ethereum/go-ethereum/core/types" "github.com/ethereum/go-ethereum/core/vm" - "github.com/ethereum/go-ethereum/crypto" "github.com/ethereum/go-ethereum/params" "github.com/ethereum-optimism/optimism/op-bindings/bindings" @@ -24,11 +23,26 @@ import ( ) var ( - StepBytes4 = crypto.Keccak256([]byte("step(bytes,bytes)"))[:4] - LoadKeccak256PreimagePartBytes4 = crypto.Keccak256([]byte("loadKeccak256PreimagePart(uint256,bytes)"))[:4] - LoadLocalDataBytes4 = crypto.Keccak256([]byte("loadLocalData(uint256,bytes32,uint256,uint256)"))[:4] + StepBytes4 []byte + LoadKeccak256PreimagePartBytes4 []byte + LoadLocalDataBytes4 []byte ) +func init() { + mipsAbi, err := bindings.MIPSMetaData.GetAbi() + if err != nil { + panic(fmt.Errorf("failed to load MIPS ABI: %w", err)) + } + StepBytes4 = mipsAbi.Methods["step"].ID[:4] + + preimageAbi, err := bindings.PreimageOracleMetaData.GetAbi() + if err != nil { + panic(fmt.Errorf("failed to load pre-image oracle ABI: %w", err)) + } + LoadKeccak256PreimagePartBytes4 = preimageAbi.Methods["loadKeccak256PreimagePart"].ID[:4] + LoadLocalDataBytes4 = preimageAbi.Methods["loadLocalData"].ID[:4] +} + // LoadContracts loads the Cannon contracts, from op-bindings package func LoadContracts() (*Contracts, error) { var mips, oracle Contract diff --git a/cannon/mipsevm/evm_test.go b/cannon/mipsevm/evm_test.go index 22df188cd8b19..a6d1362026ba8 100644 --- a/cannon/mipsevm/evm_test.go +++ b/cannon/mipsevm/evm_test.go @@ -76,13 +76,13 @@ func (m *MIPSEVM) Step(t *testing.T, stepWitness *StepWitness) []byte { if stepWitness.HasPreimage() { t.Logf("reading preimage key %x at offset %d", stepWitness.PreimageKey, stepWitness.PreimageOffset) - poInput, err := stepWitness.EncodePreimageOracleInput() + poInput, err := stepWitness.EncodePreimageOracleInput(0) require.NoError(t, err, "encode preimage oracle input") _, leftOverGas, err := m.env.Call(vm.AccountRef(sender), m.addrs.Oracle, poInput, startingGas, big.NewInt(0)) require.NoErrorf(t, err, "evm should not fail, took %d gas", startingGas-leftOverGas) } - input := stepWitness.EncodeStepInput() + input := stepWitness.EncodeStepInput(0) ret, leftOverGas, err := m.env.Call(vm.AccountRef(sender), m.addrs.MIPS, input, startingGas, big.NewInt(0)) require.NoError(t, err, "evm should not fail") require.Len(t, ret, 32, "expecting 32-byte state hash") @@ -241,7 +241,7 @@ func TestEVMFault(t *testing.T) { State: initialState.EncodeWitness(), MemProof: insnProof[:], } - input := stepWitness.EncodeStepInput() + input := stepWitness.EncodeStepInput(0) startingGas := uint64(30_000_000) _, _, err := env.Call(vm.AccountRef(sender), addrs.MIPS, input, startingGas, big.NewInt(0)) diff --git a/cannon/mipsevm/witness.go b/cannon/mipsevm/witness.go index 7f6329a6aa593..7a4b8087b2979 100644 --- a/cannon/mipsevm/witness.go +++ b/cannon/mipsevm/witness.go @@ -8,6 +8,8 @@ import ( preimage "github.com/ethereum-optimism/optimism/op-preimage" ) +type LocalContext uint64 + type StepWitness struct { // encoded state witness State []byte @@ -25,7 +27,13 @@ func uint32ToBytes32(v uint32) []byte { return out[:] } -func (wit *StepWitness) EncodeStepInput() []byte { +func uint64ToBytes32(v uint64) []byte { + var out [32]byte + binary.BigEndian.PutUint64(out[32-8:], v) + return out[:] +} + +func (wit *StepWitness) EncodeStepInput(localContext LocalContext) []byte { abiStateLen := len(wit.State) if abiStateLen%32 != 0 { abiStateLen += 32 - (abiStateLen % 32) @@ -36,8 +44,9 @@ func (wit *StepWitness) EncodeStepInput() []byte { var input []byte input = append(input, StepBytes4...) - input = append(input, uint32ToBytes32(32*2)...) // state data offset in bytes - input = append(input, uint32ToBytes32(32*2+32+uint32(len(abiState)))...) // proof data offset in bytes + input = append(input, uint32ToBytes32(32*3)...) // state data offset in bytes + input = append(input, uint32ToBytes32(32*3+32+uint32(len(abiState)))...) // proof data offset in bytes + input = append(input, uint64ToBytes32(uint64(localContext))...) // local context in bytes input = append(input, uint32ToBytes32(uint32(len(wit.State)))...) // state data length in bytes input = append(input, abiState[:]...) @@ -50,7 +59,7 @@ func (wit *StepWitness) HasPreimage() bool { return wit.PreimageKey != ([32]byte{}) } -func (wit *StepWitness) EncodePreimageOracleInput() ([]byte, error) { +func (wit *StepWitness) EncodePreimageOracleInput(localContext LocalContext) ([]byte, error) { if wit.PreimageKey == ([32]byte{}) { return nil, errors.New("cannot encode pre-image oracle input, witness has no pre-image to proof") } @@ -63,6 +72,7 @@ func (wit *StepWitness) EncodePreimageOracleInput() ([]byte, error) { var input []byte input = append(input, LoadLocalDataBytes4...) input = append(input, wit.PreimageKey[:]...) + input = append(input, uint64ToBytes32(uint64(localContext))...) // local context in bytes preimagePart := wit.PreimageValue[8:] var tmp [32]byte diff --git a/codecov.yml b/codecov.yml index 557c0f65aedfb..52aa7ea38a889 100644 --- a/codecov.yml +++ b/codecov.yml @@ -1,8 +1,18 @@ -comment: false +codecov: + require_ci_to_pass: false +comment: + layout: "diff, flags, files" + behavior: default + require_changes: true + flags: + - contracts-bedrock-tests + ignore: - "op-e2e" - - "**/*.t.sol" - "op-bindings/bindings/*.go" + - "**/*.t.sol" + - "packages/contracts-bedrock/test/**/*.sol" + - "packages/contracts-bedrock/scripts/**/*.sol" - "packages/contracts-bedrock/contracts/vendor/WETH9.sol" - 'packages/contracts-bedrock/contracts/EAS/**/*.sol' coverage: @@ -13,6 +23,7 @@ coverage: threshold: 0% # coverage is not allowed to reduce vs. the PR base base: auto informational: true + enabled: true project: default: informational: true @@ -22,7 +33,7 @@ flag_management: individual_flags: - name: contracts-bedrock-tests paths: - - packages/contracts-bedrock/contracts + - packages/contracts-bedrock/src statuses: - type: patch target: 100% diff --git a/docker-bake.hcl b/docker-bake.hcl new file mode 100644 index 0000000000000..d808f751b2736 --- /dev/null +++ b/docker-bake.hcl @@ -0,0 +1,183 @@ +variable "REGISTRY" { + default = "us-docker.pkg.dev" +} + +variable "REPOSITORY" { + default = "oplabs-tools-artifacts/images" +} + +variable "GIT_COMMIT" { + default = "dev" +} + +variable "GIT_DATE" { + default = "0" +} + +variable "GIT_VERSION" { + default = "docker" // original default as set in proxyd file, not used by full go stack, yet +} + +variable "IMAGE_TAGS" { + default = "${GIT_COMMIT}" // split by "," +} + +variable "PLATFORMS" { + // You can override this as "linux/amd64,linux/arm64". + // Only a specify a single platform when `--load` ing into docker. + // Multi-platform is supported when outputting to disk or pushing to a registry. + // Multi-platform builds can be tested locally with: --set="*.output=type=image,push=false" + default = "linux/amd64" +} + +target "op-stack-go" { + dockerfile = "ops/docker/op-stack-go/Dockerfile" + context = "." + args = { + GIT_COMMIT = "${GIT_COMMIT}" + GIT_DATE = "${GIT_DATE}" + } + platforms = split(",", PLATFORMS) + tags = [for tag in split(",", IMAGE_TAGS) : "${REGISTRY}/${REPOSITORY}/op-stack-go:${tag}"] +} + +target "op-node" { + dockerfile = "Dockerfile" + context = "./op-node" + args = { + OP_STACK_GO_BUILDER = "op-stack-go" + } + contexts = { + op-stack-go: "target:op-stack-go" + } + platforms = split(",", PLATFORMS) + tags = [for tag in split(",", IMAGE_TAGS) : "${REGISTRY}/${REPOSITORY}/op-node:${tag}"] +} + +target "op-batcher" { + dockerfile = "Dockerfile" + context = "./op-batcher" + args = { + OP_STACK_GO_BUILDER = "op-stack-go" + } + contexts = { + op-stack-go: "target:op-stack-go" + } + platforms = split(",", PLATFORMS) + tags = [for tag in split(",", IMAGE_TAGS) : "${REGISTRY}/${REPOSITORY}/op-batcher:${tag}"] +} + +target "op-proposer" { + dockerfile = "Dockerfile" + context = "./op-proposer" + args = { + OP_STACK_GO_BUILDER = "op-stack-go" + } + contexts = { + op-stack-go: "target:op-stack-go" + } + platforms = split(",", PLATFORMS) + tags = [for tag in split(",", IMAGE_TAGS) : "${REGISTRY}/${REPOSITORY}/op-proposer:${tag}"] +} + +target "op-challenger" { + dockerfile = "Dockerfile" + context = "./op-challenger" + args = { + OP_STACK_GO_BUILDER = "op-stack-go" + } + contexts = { + op-stack-go: "target:op-stack-go" + } + platforms = split(",", PLATFORMS) + tags = [for tag in split(",", IMAGE_TAGS) : "${REGISTRY}/${REPOSITORY}/op-challenger:${tag}"] +} + +target "op-heartbeat" { + dockerfile = "Dockerfile" + context = "./op-heartbeat" + args = { + OP_STACK_GO_BUILDER = "op-stack-go" + } + contexts = { + op-stack-go: "target:op-stack-go" + } + platforms = split(",", PLATFORMS) + tags = [for tag in split(",", IMAGE_TAGS) : "${REGISTRY}/${REPOSITORY}/op-heartbeat:${tag}"] +} + +target "op-program" { + dockerfile = "Dockerfile" + context = "./op-program" + args = { + OP_STACK_GO_BUILDER = "op-stack-go" + } + contexts = { + op-stack-go: "target:op-stack-go" + } + platforms = split(",", PLATFORMS) + tags = [for tag in split(",", IMAGE_TAGS) : "${REGISTRY}/${REPOSITORY}/op-program:${tag}"] +} + +target "proxyd" { + dockerfile = "Dockerfile" + context = "./proxyd" + args = { + // proxyd dockerfile has no _ in the args + GITCOMMIT = "${GIT_COMMIT}" + GITDATE = "${GIT_DATE}" + GITVERSION = "${GIT_VERSION}" + } + platforms = split(",", PLATFORMS) + tags = [for tag in split(",", IMAGE_TAGS) : "${REGISTRY}/${REPOSITORY}/proxyd:${tag}"] +} + +target "indexer" { + dockerfile = "./indexer/Dockerfile" + context = "./" + args = { + // proxyd dockerfile has no _ in the args + GITCOMMIT = "${GIT_COMMIT}" + GITDATE = "${GIT_DATE}" + GITVERSION = "${GIT_VERSION}" + } + platforms = split(",", PLATFORMS) + tags = [for tag in split(",", IMAGE_TAGS) : "${REGISTRY}/${REPOSITORY}/indexer:${tag}"] +} + +target "ufm-metamask" { + dockerfile = "Dockerfile" + context = "./ufm-test-services/metamask" + args = { + // proxyd dockerfile has no _ in the args + GITCOMMIT = "${GIT_COMMIT}" + GITDATE = "${GIT_DATE}" + GITVERSION = "${GIT_VERSION}" + } + platforms = split(",", PLATFORMS) + tags = [for tag in split(",", IMAGE_TAGS) : "${REGISTRY}/${REPOSITORY}/ufm-metamask:${tag}"] +} + +target "chain-mon" { + dockerfile = "./ops/docker/Dockerfile.packages" + context = "." + args = { + // proxyd dockerfile has no _ in the args + GITCOMMIT = "${GIT_COMMIT}" + GITDATE = "${GIT_DATE}" + GITVERSION = "${GIT_VERSION}" + } + // this is a multi-stage build, where each stage is a possible output target, but wd-mon is all we publish + target = "wd-mon" + platforms = split(",", PLATFORMS) + tags = [for tag in split(",", IMAGE_TAGS) : "${REGISTRY}/${REPOSITORY}/chain-mon:${tag}"] +} + +target "ci-builder" { + dockerfile = "./ops/docker/ci-builder/Dockerfile" + context = "." + platforms = split(",", PLATFORMS) + tags = [for tag in split(",", IMAGE_TAGS) : "${REGISTRY}/${REPOSITORY}/ci-builder:${tag}"] +} + + diff --git a/docs/fault-proof-alpha/immunefi.md b/docs/fault-proof-alpha/immunefi.md index aedd3c0401900..f3ad942950b02 100644 --- a/docs/fault-proof-alpha/immunefi.md +++ b/docs/fault-proof-alpha/immunefi.md @@ -6,6 +6,9 @@ During this early phase of ongoing development, we invite security researchers a The current system is not production ready, however the core infrastructure for creating an instruction trace ([Cannon][cannon] + the [`op-program`][op-program]), the off-chain challenge agent ([`op-challenger`][op-challenger]), and the on-chain infrastructure for the [Dispute Game][dispute-game] are all in place. +For the Fault Proof Alpha security review, we've pinned `546fb2c7a5796b7fe50b0b7edc7666d3bd281d6f` as the commit hash in the monorepo. This commit hash was the head of the `develop` branch at the time of the alpha's launch. All +security reviews and PoCs should be derived from this commit hash, as the contracts and off-chain agents are being updated frequently at this stage of development. + ### Resources > **Note** diff --git a/docs/postmortems/2022-02-02-inflation-vuln.md b/docs/postmortems/2022-02-02-inflation-vuln.md index 212abf15cc85a..5b25206f55e77 100644 --- a/docs/postmortems/2022-02-02-inflation-vuln.md +++ b/docs/postmortems/2022-02-02-inflation-vuln.md @@ -229,7 +229,7 @@ of checking email at the start of their day. This caused some delay in the initi Early in the process, the existence of the issue was openly discussed in a public slack channel, although the details of the vulnerability and exploit path were not described. This violates the -[principle of least priviledge](https://en.wikipedia.org/wiki/Principle_of_least_privilege), as well +[principle of least privilege](https://en.wikipedia.org/wiki/Principle_of_least_privilege), as well as our already existing incident response protocols **Action taken:** diff --git a/endpoint-monitor/Makefile b/endpoint-monitor/Makefile index bb536d77a2163..a5c17d519e7d3 100644 --- a/endpoint-monitor/Makefile +++ b/endpoint-monitor/Makefile @@ -1,5 +1,5 @@ -GITCOMMIT := $(shell git rev-parse HEAD) -GITDATE := $(shell git show -s --format='%ct') +GITCOMMIT ?= $(shell git rev-parse HEAD) +GITDATE ?= $(shell git show -s --format='%ct') VERSION := v0.0.0 LDFLAGSSTRING +=-X main.GitCommit=$(GITCOMMIT) diff --git a/endpoint-monitor/cmd/main.go b/endpoint-monitor/cmd/main.go index b31ac9359c6ef..4a7599488f0d5 100644 --- a/endpoint-monitor/cmd/main.go +++ b/endpoint-monitor/cmd/main.go @@ -1,9 +1,9 @@ package main import ( - "fmt" "os" + opservice "github.com/ethereum-optimism/optimism/op-service" oplog "github.com/ethereum-optimism/optimism/op-service/log" "github.com/ethereum/go-ethereum/log" "github.com/urfave/cli/v2" @@ -22,7 +22,7 @@ func main() { app := cli.NewApp() app.Flags = endpointMonitor.CLIFlags("ENDPOINT_MONITOR") - app.Version = fmt.Sprintf("%s-%s-%s", Version, GitCommit, GitDate) + app.Version = opservice.FormatVersion(Version, GitCommit, GitDate, "") app.Name = "endpoint-monitor" app.Usage = "Endpoint Monitoring Service" app.Description = "" diff --git a/go.mod b/go.mod index 2091feb0ccd0c..5eebd388489f9 100644 --- a/go.mod +++ b/go.mod @@ -8,50 +8,50 @@ require ( github.com/btcsuite/btcd/chaincfg/chainhash v1.0.1 github.com/decred/dcrd/dcrec/secp256k1/v4 v4.2.0 github.com/ethereum-optimism/go-ethereum-hdwallet v0.1.3 - github.com/ethereum-optimism/superchain-registry/superchain v0.0.0-20231001123245-7b48d3818686 + github.com/ethereum-optimism/superchain-registry/superchain v0.0.0-20231030223232-e16eae11e492 github.com/ethereum/go-ethereum v1.13.1 - github.com/fsnotify/fsnotify v1.6.0 + github.com/fsnotify/fsnotify v1.7.0 github.com/go-chi/chi/v5 v5.0.10 github.com/go-chi/docgen v1.2.0 github.com/golang/snappy v0.0.5-0.20220116011046-fa5810519dcb github.com/google/go-cmp v0.6.0 github.com/google/gofuzz v1.2.1-0.20220503160820-4a35382e8fc8 - github.com/google/uuid v1.3.1 + github.com/google/uuid v1.4.0 github.com/hashicorp/go-multierror v1.1.1 github.com/hashicorp/golang-lru/v2 v2.0.5 github.com/holiman/uint256 v1.2.3 github.com/ipfs/go-datastore v0.6.0 github.com/ipfs/go-ds-leveldb v0.5.0 github.com/jackc/pgtype v1.14.0 - github.com/jackc/pgx/v5 v5.4.3 - github.com/libp2p/go-libp2p v0.31.0 + github.com/jackc/pgx/v5 v5.5.0 + github.com/libp2p/go-libp2p v0.32.0 github.com/libp2p/go-libp2p-mplex v0.9.0 - github.com/libp2p/go-libp2p-pubsub v0.9.3 + github.com/libp2p/go-libp2p-pubsub v0.10.0 github.com/libp2p/go-libp2p-testing v0.12.0 - github.com/mattn/go-isatty v0.0.19 + github.com/mattn/go-isatty v0.0.20 github.com/multiformats/go-base32 v0.1.0 github.com/multiformats/go-multiaddr v0.12.0 github.com/multiformats/go-multiaddr-dns v0.3.1 github.com/olekukonko/tablewriter v0.0.5 - github.com/onsi/gomega v1.28.0 + github.com/onsi/gomega v1.30.0 github.com/pkg/errors v0.9.1 github.com/pkg/profile v1.7.0 github.com/prometheus/client_golang v1.17.0 github.com/stretchr/testify v1.8.4 github.com/urfave/cli/v2 v2.25.7 - golang.org/x/crypto v0.14.0 - golang.org/x/exp v0.0.0-20230905200255-921286631fa9 - golang.org/x/sync v0.4.0 - golang.org/x/term v0.13.0 - golang.org/x/time v0.3.0 - gorm.io/driver/postgres v1.5.3 + golang.org/x/crypto v0.15.0 + golang.org/x/exp v0.0.0-20231006140011-7918f672742d + golang.org/x/sync v0.5.0 + golang.org/x/term v0.14.0 + golang.org/x/time v0.4.0 + gorm.io/driver/postgres v1.5.4 gorm.io/gorm v1.25.5 ) require ( github.com/DataDog/zstd v1.5.2 // indirect github.com/Microsoft/go-winio v0.6.1 // indirect - github.com/VictoriaMetrics/fastcache v1.10.0 // indirect + github.com/VictoriaMetrics/fastcache v1.12.1 // indirect github.com/allegro/bigcache v1.2.1 // indirect github.com/benbjohnson/clock v1.3.5 // indirect github.com/beorn7/perks v1.0.1 // indirect @@ -60,12 +60,13 @@ require ( github.com/btcsuite/btcd/btcutil v1.1.0 // indirect github.com/btcsuite/btclog v0.0.0-20170628155309-84c8d2346e9f // indirect github.com/cespare/xxhash/v2 v2.2.0 // indirect - github.com/cockroachdb/errors v1.9.1 // indirect + github.com/cockroachdb/errors v1.11.1 // indirect github.com/cockroachdb/logtags v0.0.0-20230118201751-21c54148d20b // indirect - github.com/cockroachdb/pebble v0.0.0-20230906160148-46873a6a7a06 // indirect - github.com/cockroachdb/redact v1.1.3 // indirect + github.com/cockroachdb/pebble v0.0.0-20231018212520-f6cde3fc2fa4 // 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 - github.com/consensys/gnark-crypto v0.12.0 // indirect + github.com/consensys/gnark-crypto v0.12.1 // indirect github.com/containerd/cgroups v1.1.0 // indirect github.com/coreos/go-systemd/v22 v22.5.0 // indirect github.com/cpuguy83/go-md2man/v2 v2.0.2 // indirect @@ -81,7 +82,7 @@ require ( github.com/dop251/goja v0.0.0-20230806174421-c933cf95e127 // indirect github.com/elastic/gosigar v0.14.2 // indirect github.com/ethereum/c-kzg-4844 v0.3.1 // indirect - github.com/fatih/color v1.7.0 // indirect + github.com/fatih/color v1.13.0 // indirect github.com/felixge/fgprof v0.9.3 // indirect github.com/fjl/memsize v0.0.1 // indirect github.com/flynn/noise v1.0.0 // indirect @@ -96,11 +97,10 @@ require ( github.com/godbus/dbus/v5 v5.1.0 // indirect github.com/gofrs/flock v0.8.1 // indirect github.com/gogo/protobuf v1.3.2 // indirect - github.com/golang-jwt/jwt/v4 v4.4.2 // indirect - github.com/golang/mock v1.6.0 // indirect + github.com/golang-jwt/jwt/v4 v4.5.0 // indirect github.com/golang/protobuf v1.5.3 // indirect github.com/google/gopacket v1.1.19 // indirect - github.com/google/pprof v0.0.0-20230817174616-7a8ec2ada47b // indirect + github.com/google/pprof v0.0.0-20231023181126-ff6d637d2a7b // indirect github.com/gorilla/websocket v1.5.0 // indirect github.com/graph-gophers/graphql-go v1.3.0 // indirect github.com/hashicorp/errwrap v1.1.0 // indirect @@ -117,6 +117,7 @@ require ( github.com/jackc/pgio v1.0.0 // indirect github.com/jackc/pgpassfile v1.0.0 // indirect github.com/jackc/pgservicefile v0.0.0-20221227161230-091c0ba34f0a // indirect + github.com/jackc/puddle/v2 v2.2.1 // indirect github.com/jackpal/go-nat-pmp v1.0.2 // indirect github.com/jbenet/go-temp-err-catcher v0.1.0 // indirect github.com/jbenet/goprocess v0.1.4 // indirect @@ -124,7 +125,7 @@ require ( github.com/jinzhu/inflection v1.0.0 // indirect github.com/jinzhu/now v1.1.5 // indirect github.com/karalabe/usb v0.0.3-0.20230711191512-61db3e06439c // indirect - github.com/klauspost/compress v1.16.7 // indirect + github.com/klauspost/compress v1.17.2 // indirect github.com/klauspost/cpuid/v2 v2.2.5 // indirect github.com/koron/go-ssdp v0.0.4 // indirect github.com/kr/pretty v0.3.1 // indirect @@ -144,7 +145,7 @@ require ( github.com/mattn/go-colorable v0.1.13 // indirect github.com/mattn/go-runewidth v0.0.14 // indirect github.com/matttproud/golang_protobuf_extensions v1.0.4 // indirect - github.com/miekg/dns v1.1.55 // indirect + github.com/miekg/dns v1.1.56 // indirect github.com/mikioh/tcpinfo v0.0.0-20190314235526-30a79bb1804b // indirect github.com/mikioh/tcpopt v0.0.0-20190314235656-172688c1accc // indirect github.com/minio/sha256-simd v1.0.1 // indirect @@ -157,11 +158,11 @@ require ( github.com/multiformats/go-multibase v0.2.0 // indirect github.com/multiformats/go-multicodec v0.9.0 // indirect github.com/multiformats/go-multihash v0.2.3 // indirect - github.com/multiformats/go-multistream v0.4.1 // indirect + github.com/multiformats/go-multistream v0.5.0 // indirect github.com/multiformats/go-varint v0.0.7 // indirect github.com/naoina/go-stringutil v0.1.0 // indirect github.com/naoina/toml v0.1.2-0.20170918210437-9fafd6967416 // indirect - github.com/onsi/ginkgo/v2 v2.12.0 // indirect + github.com/onsi/ginkgo/v2 v2.13.0 // indirect github.com/opencontainers/runtime-spec v1.1.0 // indirect github.com/opentracing/opentracing-go v1.2.0 // indirect github.com/pbnjay/memory v0.0.0-20210728143218-7b4eea64cf58 // indirect @@ -171,9 +172,9 @@ require ( github.com/prometheus/common v0.44.0 // indirect github.com/prometheus/procfs v0.11.1 // indirect github.com/quic-go/qpack v0.4.0 // indirect - github.com/quic-go/qtls-go1-20 v0.3.3 // indirect - github.com/quic-go/quic-go v0.38.1 // indirect - github.com/quic-go/webtransport-go v0.5.3 // indirect + github.com/quic-go/qtls-go1-20 v0.3.4 // indirect + github.com/quic-go/quic-go v0.39.3 // indirect + github.com/quic-go/webtransport-go v0.6.0 // indirect github.com/raulk/go-watchdog v1.3.0 // indirect github.com/rivo/uniseg v0.4.3 // indirect github.com/rogpeppe/go-internal v1.10.0 // indirect @@ -191,15 +192,16 @@ require ( github.com/xrash/smetrics v0.0.0-20201216005158-039620a65673 // indirect github.com/yusufpapurcu/wmi v1.2.2 // indirect go.uber.org/automaxprocs v1.5.2 // indirect - go.uber.org/dig v1.17.0 // indirect - go.uber.org/fx v1.20.0 // indirect + go.uber.org/dig v1.17.1 // indirect + go.uber.org/fx v1.20.1 // indirect + go.uber.org/mock v0.3.0 // indirect go.uber.org/multierr v1.11.0 // indirect - go.uber.org/zap v1.25.0 // indirect - golang.org/x/mod v0.12.0 // indirect + go.uber.org/zap v1.26.0 // indirect + golang.org/x/mod v0.13.0 // indirect golang.org/x/net v0.17.0 // indirect - golang.org/x/sys v0.13.0 // indirect - golang.org/x/text v0.13.0 // indirect - golang.org/x/tools v0.13.0 // indirect + golang.org/x/sys v0.14.0 // indirect + golang.org/x/text v0.14.0 // indirect + golang.org/x/tools v0.14.0 // indirect google.golang.org/protobuf v1.31.0 // indirect gopkg.in/natefinch/lumberjack.v2 v2.0.0 // indirect gopkg.in/yaml.v2 v2.4.0 // indirect @@ -208,7 +210,7 @@ require ( rsc.io/tmplfunc v0.0.3 // indirect ) -replace github.com/ethereum/go-ethereum v1.13.1 => github.com/ethereum-optimism/op-geth v1.101301.0-rc.2.0.20231002141926-1e6910b91798 +replace github.com/ethereum/go-ethereum v1.13.1 => github.com/ethereum-optimism/op-geth v1.101304.0-rc.2.0.20231030225546-cd491fa3b588 //replace github.com/ethereum-optimism/superchain-registry/superchain => ../superchain-registry/superchain //replace github.com/ethereum/go-ethereum v1.13.1 => ../go-ethereum diff --git a/go.sum b/go.sum index a7dd59c251acb..845f128acc9d9 100644 --- a/go.sum +++ b/go.sum @@ -7,31 +7,23 @@ dmitri.shuralyov.com/html/belt v0.0.0-20180602232347-f7d459c86be0/go.mod h1:JLBr dmitri.shuralyov.com/service/change v0.0.0-20181023043359-a85b471d5412/go.mod h1:a1inKt/atXimZ4Mv927x+r7UpyzRUf4emIoiiSC2TN4= dmitri.shuralyov.com/state v0.0.0-20180228185332-28bcc343414c/go.mod h1:0PRwlb0D6DFvNNtx+9ybjezNCa8XF0xaYcETyp6rHWU= git.apache.org/thrift.git v0.0.0-20180902110319-2566ecd5d999/go.mod h1:fPE2ZNJGynbRyZ4dJvy6G277gSllfV2HJqblrnkyeyg= -github.com/AndreasBriese/bbloom v0.0.0-20190306092124-e2d15f34fcf9/go.mod h1:bOvUY6CB00SOBii9/FifXqc0awNKxLFCL/+pkDPuyl8= github.com/AndreasBriese/bbloom v0.0.0-20190825152654-46b345b51c96 h1:cTp8I5+VIoKjsnZuH8vjyaysT/ses3EvZeaV/1UkF2M= github.com/AndreasBriese/bbloom v0.0.0-20190825152654-46b345b51c96/go.mod h1:bOvUY6CB00SOBii9/FifXqc0awNKxLFCL/+pkDPuyl8= github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= github.com/BurntSushi/toml v1.3.2 h1:o7IhLm0Msx3BaB+n3Ag7L8EVlByGnpq14C4YWiu/gL8= github.com/BurntSushi/toml v1.3.2/go.mod h1:CxXYINrC8qIiEnFrOxCa7Jy5BFHlXnUU2pbicEuybxQ= -github.com/CloudyKit/fastprinter v0.0.0-20200109182630-33d98a066a53/go.mod h1:+3IMCy2vIlbG1XG/0ggNQv0SvxCAIpPM5b1nCz56Xno= -github.com/CloudyKit/jet/v3 v3.0.0/go.mod h1:HKQPgSJmdK8hdoAbKUUWajkHyHo4RaU5rMdUywE7VMo= github.com/DataDog/zstd v1.5.2 h1:vUG4lAyuPCXO0TLbXvPv7EB7cNK1QV/luu55UHLrrn8= github.com/DataDog/zstd v1.5.2/go.mod h1:g4AWEaM3yOg3HYfnJ3YIawPnVdXJh9QME85blwSAmyw= -github.com/Joker/hpp v1.0.0/go.mod h1:8x5n+M1Hp5hC0g8okX3sR3vFQwynaX/UgSOM9MeBKzY= github.com/Masterminds/semver/v3 v3.1.1/go.mod h1:VPu/7SZ7ePZ3QOrcuXROw5FAcLl4a0cBrbBpGY/8hQs= github.com/Microsoft/go-winio v0.6.1 h1:9/kr64B9VUZrLm5YYwbGtUJnMgqWVOdUAXu6Migciow= github.com/Microsoft/go-winio v0.6.1/go.mod h1:LRdKpFKfdobln8UmuiYcKPot9D2v6svN5+sAH+4kjUM= -github.com/Shopify/goreferrer v0.0.0-20181106222321-ec9c9a553398/go.mod h1:a1uqRtAwp2Xwc6WNPJEufxJ7fx3npB4UV/JOLmbu5I0= -github.com/VictoriaMetrics/fastcache v1.10.0 h1:5hDJnLsKLpnUEToub7ETuRu8RCkb40woBZAUiKonXzY= -github.com/VictoriaMetrics/fastcache v1.10.0/go.mod h1:tjiYeEfYXCqacuvYw/7UoDIeJaNxq6132xHICNP77w8= +github.com/VictoriaMetrics/fastcache v1.12.1 h1:i0mICQuojGDL3KblA7wUNlY5lOK6a4bwt3uRKnkZU40= +github.com/VictoriaMetrics/fastcache v1.12.1/go.mod h1:tX04vaqcNoQeGLD+ra5pU5sWkuxnzWhEzLwhP9w653o= github.com/aead/siphash v1.0.1/go.mod h1:Nywa3cDsYNNK3gaciGTWPwHt0wlpNV15vwmswBAUSII= -github.com/ajg/form v1.5.1/go.mod h1:uL1WgH+h2mgNtvBq0339dVnzXdBETtL2LeUXaIv25UY= github.com/allegro/bigcache v1.2.1-0.20190218064605-e24eb225f156/go.mod h1:Cb/ax3seSYIx7SuZdm2G2xzfwmv3TPSk2ucNfQESPXM= github.com/allegro/bigcache v1.2.1 h1:hg1sY1raCwic3Vnsvje6TT7/pnZba83LeFck5NrFKSc= github.com/allegro/bigcache v1.2.1/go.mod h1:Cb/ax3seSYIx7SuZdm2G2xzfwmv3TPSk2ucNfQESPXM= github.com/anmitsu/go-shlex v0.0.0-20161002113705-648efa622239/go.mod h1:2FmKhYUyUczH0OGQWaF5ceTx0UBShxjsH6f8oGKYe2c= -github.com/armon/consul-api v0.0.0-20180202201655-eb2c6b5be1b6/go.mod h1:grANhF5doyWs3UAsr3K4I6qtAmlQcZDesFNEHPZAzj8= -github.com/aymerick/raymond v2.0.3-0.20180322193309-b565731e1464+incompatible/go.mod h1:osfaiScAUVup+UC9Nfq76eWqDhXlp+4UYaA8uhTBO6g= github.com/benbjohnson/clock v1.1.0/go.mod h1:J11/hYXuz8f4ySSvYwY0FKfm+ezbsZBKZxNJlLklBHA= github.com/benbjohnson/clock v1.3.0/go.mod h1:J11/hYXuz8f4ySSvYwY0FKfm+ezbsZBKZxNJlLklBHA= github.com/benbjohnson/clock v1.3.5 h1:VvXlSJBzZpA/zum6Sj74hxwYI2DIxRWuNIoXAzHZz5o= @@ -65,12 +57,10 @@ github.com/btcsuite/snappy-go v1.0.0/go.mod h1:8woku9dyThutzjeg+3xrA5iCpBRH8XEEg github.com/btcsuite/websocket v0.0.0-20150119174127-31079b680792/go.mod h1:ghJtEyQwv5/p4Mg4C0fgbePVuGr935/5ddU9Z3TmDRY= github.com/btcsuite/winsvc v1.0.0/go.mod h1:jsenWakMcC0zFBFurPLEAyrnc/teJEM1O46fmI40EZs= github.com/buger/jsonparser v0.0.0-20181115193947-bf1c66bbce23/go.mod h1:bbYlZJ7hK1yFx9hf58LP0zeX7UjIGs20ufpu3evjr+s= -github.com/census-instrumentation/opencensus-proto v0.2.1/go.mod h1:f6KPmirojxKA12rnyqOA5BBL4O983OfeGPqjHWSTneU= github.com/cespare/cp v0.1.0 h1:SE+dxFebS7Iik5LK0tsi1k9ZCxEaFX4AjQmoyA+1dJk= github.com/cespare/cp v0.1.0/go.mod h1:SOGHArjBr4JWaSDEVpWpo/hNg6RoKrls6Oh40hiwW+s= github.com/cespare/xxhash v1.1.0 h1:a6HrQnmkObjyL+Gs60czilIUGqrzKutQD6XZog3p+ko= github.com/cespare/xxhash v1.1.0/go.mod h1:XrSqR1VqqWfGrhpAt58auRo0WTKS1nRRg3ghfAqPWnc= -github.com/cespare/xxhash/v2 v2.1.2/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= github.com/cespare/xxhash/v2 v2.2.0 h1:DC2CZ1Ep5Y4k3ZQ899DldepgrayRUGE6BBZ/cd9Cj44= github.com/cespare/xxhash/v2 v2.2.0/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= github.com/chzyer/logex v1.1.10/go.mod h1:+Ywpsq7O8HXn0nuIou7OrIPyXbp3wmkHB+jjWRnGsAI= @@ -81,38 +71,32 @@ github.com/chzyer/test v0.0.0-20180213035817-a1ea475d72b1/go.mod h1:Q3SI9o4m/ZMn github.com/chzyer/test v0.0.0-20210722231415-061457976a23/go.mod h1:Q3SI9o4m/ZMnBNeIyt5eFwwo7qiLfzFZmjNmxjkiQlU= github.com/cilium/ebpf v0.2.0/go.mod h1:To2CFviqOWL/M0gIMsvSMlqe7em/l1ALkX1PyjrX2Qs= github.com/client9/misspell v0.3.4/go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDkc90ppPyw= -github.com/cncf/udpa/go v0.0.0-20201120205902-5459f2c99403/go.mod h1:WmhPx2Nbnhtbo57+VJT5O0JRkEi1Wbu0z5j0R8u5Hbk= github.com/cockroachdb/apd v1.1.0/go.mod h1:8Sl8LxpKi29FqWXR16WEFZRNSz3SoPzUzeMeY4+DwBQ= -github.com/cockroachdb/datadriven v1.0.2/go.mod h1:a9RdTaap04u637JoCzcUoIcDmvwSUtcUFtT/C3kJlTU= -github.com/cockroachdb/datadriven v1.0.3-0.20230801171734-e384cf455877 h1:1MLK4YpFtIEo3ZtMA5C795Wtv5VuUnrXX7mQG+aHg6o= -github.com/cockroachdb/datadriven v1.0.3-0.20230801171734-e384cf455877/go.mod h1:a9RdTaap04u637JoCzcUoIcDmvwSUtcUFtT/C3kJlTU= -github.com/cockroachdb/errors v1.9.1 h1:yFVvsI0VxmRShfawbt/laCIDy/mtTqqnvoNgiy5bEV8= -github.com/cockroachdb/errors v1.9.1/go.mod h1:2sxOtL2WIc096WSZqZ5h8fa17rdDq9HZOZLBCor4mBk= -github.com/cockroachdb/logtags v0.0.0-20211118104740-dabe8e521a4f/go.mod h1:Vz9DsVWQQhf3vs21MhPMZpMGSht7O/2vFW2xusFUVOs= +github.com/cockroachdb/datadriven v1.0.3-0.20230413201302-be42291fc80f h1:otljaYPt5hWxV3MUfO5dFPFiOXg9CyG5/kCfayTqsJ4= +github.com/cockroachdb/datadriven v1.0.3-0.20230413201302-be42291fc80f/go.mod h1:a9RdTaap04u637JoCzcUoIcDmvwSUtcUFtT/C3kJlTU= +github.com/cockroachdb/errors v1.11.1 h1:xSEW75zKaKCWzR3OfxXUxgrk/NtT4G1MiOv5lWZazG8= +github.com/cockroachdb/errors v1.11.1/go.mod h1:8MUxA3Gi6b25tYlFEBGLf+D8aISL+M4MIpiWMSNRfxw= 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-20230906160148-46873a6a7a06 h1:T+Np/xtzIjYM/P5NAw0e2Rf1FGvzDau1h54MKvx8G7w= -github.com/cockroachdb/pebble v0.0.0-20230906160148-46873a6a7a06/go.mod h1:bynZ3gvVyhlvjLI7PT6dmZ7g76xzJ7HpxfjgkzCGz6s= -github.com/cockroachdb/redact v1.1.3 h1:AKZds10rFSIj7qADf0g46UixK8NNLwWTNdCIGS5wfSQ= -github.com/cockroachdb/redact v1.1.3/go.mod h1:BVNblN9mBWFyMyqK1k3AAiSxhvhfK2oOZZ2lK+dpvRg= -github.com/codegangsta/inject v0.0.0-20150114235600-33e0aa1cb7c0/go.mod h1:4Zcjuz89kmFXt9morQgcfYZAYZ5n8WHjt81YYWIwtTM= +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/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= +github.com/cockroachdb/tokenbucket v0.0.0-20230807174530-cc333fc44b06/go.mod h1:7nc4anLGjupUW/PeY5qiNYsdNXj7zopG+eqsS7To5IQ= github.com/consensys/bavard v0.1.13 h1:oLhMLOFGTLdlda/kma4VOJazblc7IM5y5QPd2A/YjhQ= github.com/consensys/bavard v0.1.13/go.mod h1:9ItSMtA/dXMAiL7BG6bqW2m3NdSEObYWoH223nGHukI= -github.com/consensys/gnark-crypto v0.12.0 h1:1OnSpOykNkUIBIBJKdhwy2p0JlW5o+Az02ICzZmvvdg= -github.com/consensys/gnark-crypto v0.12.0/go.mod h1:v2Gy7L/4ZRosZ7Ivs+9SfUDr0f5UlG+EM5t7MPHiLuY= +github.com/consensys/gnark-crypto v0.12.1 h1:lHH39WuuFgVHONRl3J0LRBtuYdQTumFSDtJF7HpyG8M= +github.com/consensys/gnark-crypto v0.12.1/go.mod h1:v2Gy7L/4ZRosZ7Ivs+9SfUDr0f5UlG+EM5t7MPHiLuY= github.com/containerd/cgroups v0.0.0-20201119153540-4cbc285b3327/go.mod h1:ZJeTFisyysqgcCdecO57Dj79RfL0LNeGiFUqLYQRYLE= github.com/containerd/cgroups v1.1.0 h1:v8rEWFl6EoqHB+swVNjVoCJE8o3jX7e8nqBGPLaDFBM= github.com/containerd/cgroups v1.1.0/go.mod h1:6ppBcbh/NOOUU+dMKrykgaBnK9lCIBxHqJDGwsa1mIw= -github.com/coreos/etcd v3.3.10+incompatible/go.mod h1:uF7uidLiAD3TWHmW31ZFd/JWoc32PjwdhPthX9715RE= -github.com/coreos/go-etcd v2.0.0+incompatible/go.mod h1:Jez6KQU2B/sWsbdaef3ED8NzMklzPG4d5KIOhIy30Tk= -github.com/coreos/go-semver v0.2.0/go.mod h1:nnelYz7RCh+5ahJtPPxZlU+153eP4D4r3EedlOD2RNk= github.com/coreos/go-systemd v0.0.0-20181012123002-c6f51f82210d/go.mod h1:F5haX7vjVVG0kc13fIWeqUViNPyEJxv/OmvnBo0Yme4= github.com/coreos/go-systemd v0.0.0-20190321100706-95778dfbb74e/go.mod h1:F5haX7vjVVG0kc13fIWeqUViNPyEJxv/OmvnBo0Yme4= github.com/coreos/go-systemd v0.0.0-20190719114852-fd7a80b32e1f/go.mod h1:F5haX7vjVVG0kc13fIWeqUViNPyEJxv/OmvnBo0Yme4= github.com/coreos/go-systemd/v22 v22.1.0/go.mod h1:xO0FLkIi5MaZafQlIrOotqXZ90ih+1atmu1JpKERPPk= github.com/coreos/go-systemd/v22 v22.5.0 h1:RrqgGjYQKalulkV8NGVIfkXQf6YYmOyiJKk8iXXhfZs= github.com/coreos/go-systemd/v22 v22.5.0/go.mod h1:Y58oyj3AT4RCenI/lSvhwexgC+NSVTIJ3seZv2GcEnc= -github.com/cpuguy83/go-md2man v1.0.10/go.mod h1:SmD6nW6nTyfqj6ABTjUi3V3JVMnlJmwcJI5acqYI6dE= github.com/cpuguy83/go-md2man/v2 v2.0.0-20190314233015-f79a8a8ca69d/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU= github.com/cpuguy83/go-md2man/v2 v2.0.0/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU= github.com/cpuguy83/go-md2man/v2 v2.0.2 h1:p1EgwI/C7NhT0JmVkwCD2ZBK8j4aeHQX2pMHHBfMQ6w= @@ -142,13 +126,11 @@ github.com/decred/dcrd/lru v1.0.0/go.mod h1:mxKOwFd7lFjN2GZYsiz/ecgqR6kkYAl+0pz0 github.com/deepmap/oapi-codegen v1.6.0/go.mod h1:ryDa9AgbELGeB+YEXE1dR53yAjHwFvE9iAUlWl9Al3M= github.com/deepmap/oapi-codegen v1.8.2 h1:SegyeYGcdi0jLLrpbCMoJxnUUn8GBXHsvr4rbzjuhfU= github.com/deepmap/oapi-codegen v1.8.2/go.mod h1:YLgSKSDv/bZQB7N4ws6luhozi3cEdRktEqrX88CvjIw= -github.com/dgraph-io/badger v1.6.0/go.mod h1:zwt7syl517jmP8s94KqSxTlM6IMsdhYy6psNgSztDR4= github.com/dgraph-io/badger v1.6.2 h1:mNw0qs90GVgGGWylh0umH5iag1j6n/PeJtNvL6KY/x8= github.com/dgraph-io/badger v1.6.2/go.mod h1:JW2yswe3V058sS0kZ2h/AXeDSqFjxnZcRrVH//y2UQE= github.com/dgraph-io/ristretto v0.0.2 h1:a5WaUrDa0qm0YrAAS1tUykT5El3kt62KNZZeMxQn3po= github.com/dgraph-io/ristretto v0.0.2/go.mod h1:KPxhHT9ZxKefz+PCeOGsrHpl1qZ7i70dGTu2u+Ahh6E= github.com/dgrijalva/jwt-go v3.2.0+incompatible/go.mod h1:E3ru+11k8xSBh+hMPgOLZmtrrCbhqsmaPHjLKYnJCaQ= -github.com/dgryski/go-farm v0.0.0-20190423205320-6a90982ecee2/go.mod h1:SqUrOPUnsFjfmXRMNPybcSiG0BgUW2AuFH8PAnS2iTw= github.com/dlclark/regexp2 v1.4.1-0.20201116162257-a2a8dda75c91/go.mod h1:2pZnwuY/m+8K6iRw6wQdMtk+rH5tNGR1i55kozfMjCc= github.com/dlclark/regexp2 v1.7.0 h1:7lJfhqlPssTb1WQx4yvTHN0uElPEv52sbaECrAQxjAo= github.com/dlclark/regexp2 v1.7.0/go.mod h1:DHkYz0B9wPfa6wondMfaivmHpzrQ3v9q8cnmRbL6yW8= @@ -164,27 +146,19 @@ github.com/dop251/goja_nodejs v0.0.0-20210225215109-d91c329300e7/go.mod h1:hn7BA github.com/dop251/goja_nodejs v0.0.0-20211022123610-8dd9abb0616d/go.mod h1:DngW8aVqWbuLRMHItjPUyqdj+HWPvnQe8V8y1nDpIbM= github.com/dustin/go-humanize v1.0.0 h1:VSnTsYCnlFHaM2/igO1h6X3HA71jcobQuxemgkq4zYo= github.com/dustin/go-humanize v1.0.0/go.mod h1:HtrtbFcZ19U5GC7JDqmcUSB87Iq5E25KnS6fMYU6eOk= -github.com/eknkc/amber v0.0.0-20171010120322-cdade1c07385/go.mod h1:0vRUJqYpeSZifjYj7uP3BG/gKcuzL9xWVV/Y+cK33KM= github.com/elastic/gosigar v0.12.0/go.mod h1:iXRIGg2tLnu7LBdpqzyQfGDEidKCfWcCMS0WKyPWoMs= github.com/elastic/gosigar v0.14.2 h1:Dg80n8cr90OZ7x+bAax/QjoW/XqTI11RmA79ZwIm9/4= github.com/elastic/gosigar v0.14.2/go.mod h1:iXRIGg2tLnu7LBdpqzyQfGDEidKCfWcCMS0WKyPWoMs= -github.com/envoyproxy/go-control-plane v0.9.0/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4= -github.com/envoyproxy/go-control-plane v0.9.1-0.20191026205805-5f8ba28d4473/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4= -github.com/envoyproxy/go-control-plane v0.9.9-0.20210217033140-668b12f5399d/go.mod h1:cXg6YxExXjJnVBQHBLXeUAgxn2UodCpnH306RInaBQk= -github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c= -github.com/etcd-io/bbolt v1.3.3/go.mod h1:ZF2nL25h33cCyBtcyWeZ2/I3HQOfTP+0PIEvHjkjCrw= github.com/ethereum-optimism/go-ethereum-hdwallet v0.1.3 h1:RWHKLhCrQThMfch+QJ1Z8veEq5ZO3DfIhZ7xgRP9WTc= github.com/ethereum-optimism/go-ethereum-hdwallet v0.1.3/go.mod h1:QziizLAiF0KqyLdNJYD7O5cpDlaFMNZzlxYNcWsJUxs= -github.com/ethereum-optimism/op-geth v1.101301.0-rc.2.0.20231002141926-1e6910b91798 h1:WRaF/uniRnlxTVlMfFWPtMe9NefzZWg/8Fc93Nao76w= -github.com/ethereum-optimism/op-geth v1.101301.0-rc.2.0.20231002141926-1e6910b91798/go.mod h1:p02vxGt8jcF8pCwkUU5Oy56X8/JsM1Js+KC+fwihVgk= -github.com/ethereum-optimism/superchain-registry/superchain v0.0.0-20231001123245-7b48d3818686 h1:f57hd8G96c8ORWd4ameFpveSnHcb0hA2D1VatviwoDc= -github.com/ethereum-optimism/superchain-registry/superchain v0.0.0-20231001123245-7b48d3818686/go.mod h1:q0u2UbyOr1q/y94AgMOj/V8b1KO05ZwILTR/qKt7Auo= +github.com/ethereum-optimism/op-geth v1.101304.0-rc.2.0.20231030225546-cd491fa3b588 h1:jrvFoV3aSGJcTT8Pyo8R2Sp7CZ0v3hqrdhfSmyZbJVw= +github.com/ethereum-optimism/op-geth v1.101304.0-rc.2.0.20231030225546-cd491fa3b588/go.mod h1:12W+vBetjYbDj5D2+V8hizke5yWuLrUDf7UmVkXTnCQ= +github.com/ethereum-optimism/superchain-registry/superchain v0.0.0-20231030223232-e16eae11e492 h1:FyzLzMLKMc9zcDYcSxbrLDglIRrGQJE9juFzIO35RmE= +github.com/ethereum-optimism/superchain-registry/superchain v0.0.0-20231030223232-e16eae11e492/go.mod h1:/70H/KqrtKcvWvNGVj6S3rAcLC+kUPr3t2aDmYIS+Xk= github.com/ethereum/c-kzg-4844 v0.3.1 h1:sR65+68+WdnMKxseNWxSJuAv2tsUrihTpVBTfM/U5Zg= github.com/ethereum/c-kzg-4844 v0.3.1/go.mod h1:VewdlzQmpT5QSrVhbBuGoCdFJkpaJlO1aQputP83wc0= -github.com/fasthttp-contrib/websocket v0.0.0-20160511215533-1f3b11f56072/go.mod h1:duJ4Jxv5lDcvg4QuQr0oowTf7dz4/CR8NtyCooz9HL8= -github.com/fatih/color v1.7.0 h1:DkWD4oS2D8LGGgTQ6IvwJJXSL5Vp2ffcQg58nFV38Ys= -github.com/fatih/color v1.7.0/go.mod h1:Zm6kSWBoL9eyXnKyktHP6abPY2pDugNf5KwzbycvMj4= -github.com/fatih/structs v1.1.0/go.mod h1:9NiDSp5zOcgEDl+j00MP/WkGVPOlPRLejGD8Ga6PJ7M= +github.com/fatih/color v1.13.0 h1:8LOYc1KYPPmyKMuN8QV2DNRWNbLo6LZ0iLs8+mlH53w= +github.com/fatih/color v1.13.0/go.mod h1:kLAiJbzzSOZDVNGyDpeOxJ47H46qBXwg5ILebYFFOfk= github.com/felixge/fgprof v0.9.3 h1:VvyZxILNuCiUCSXtPtYmmtGvb65nqXh2QFWc0Wpf2/g= github.com/felixge/fgprof v0.9.3/go.mod h1:RdbpDgzqYVh/T9fPELJyV7EYJuHB55UTEULNun8eiPw= github.com/fjl/memsize v0.0.1 h1:+zhkb+dhUgx0/e+M8sF0QqiouvMQUiKR+QYvdxIOKcQ= @@ -197,23 +171,18 @@ github.com/francoispqt/gojay v1.2.13/go.mod h1:ehT5mTG4ua4581f1++1WLG0vPdaA9HaiD 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= -github.com/fsnotify/fsnotify v1.6.0 h1:n+5WquG0fcWoWp6xPWfHdbskMCQaFnG6PfBrh1Ky4HY= -github.com/fsnotify/fsnotify v1.6.0/go.mod h1:sl3t1tCWJFWoRz9R8WJCbQihKKwmorjAbSClcnxKAGw= -github.com/gavv/httpexpect v2.0.0+incompatible/go.mod h1:x+9tiU1YnrOvnB725RkpoLv1M62hOWzwo5OXotisrKc= +github.com/fsnotify/fsnotify v1.7.0 h1:8JEhPFa5W2WU7YfeZzPNqzMP6Lwt7L2715Ggo0nosvA= +github.com/fsnotify/fsnotify v1.7.0/go.mod h1:40Bi/Hjc2AVfZrqy+aj+yEI+/bRxZnMJyTJwOpGvigM= github.com/gballet/go-libpcsclite v0.0.0-20191108122812-4678299bea08 h1:f6D9Hr8xV8uYKlyuj8XIruxlh9WjVjdh1gIicAS7ays= github.com/gballet/go-libpcsclite v0.0.0-20191108122812-4678299bea08/go.mod h1:x7DCsMOv1taUwEWCzT4cmDeAkigA5/QCwUodaVOe8Ww= github.com/gballet/go-verkle v0.0.0-20230607174250-df487255f46b h1:vMT47RYsrftsHSTQhqXwC3BYflo38OLC3Y4LtXtLyU0= github.com/gballet/go-verkle v0.0.0-20230607174250-df487255f46b/go.mod h1:CDncRYVRSDqwakm282WEkjfaAj1hxU/v5RXxk5nXOiI= github.com/getkin/kin-openapi v0.53.0/go.mod h1:7Yn5whZr5kJi6t+kShccXS8ae1APpYTW6yheSwk8Yi4= github.com/getkin/kin-openapi v0.61.0/go.mod h1:7Yn5whZr5kJi6t+kShccXS8ae1APpYTW6yheSwk8Yi4= -github.com/getsentry/sentry-go v0.12.0/go.mod h1:NSap0JBYWzHND8oMbyi0+XZhUalc1TBdRL1M71JZW2c= github.com/getsentry/sentry-go v0.18.0 h1:MtBW5H9QgdcJabtZcuJG80BMOwaBpkRDZkxRkNC1sN0= github.com/getsentry/sentry-go v0.18.0/go.mod h1:Kgon4Mby+FJ7ZWHFUAZgVaIa8sxHtnRJRLTXZr51aKQ= github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04= -github.com/gin-contrib/sse v0.0.0-20190301062529-5545eab6dad3/go.mod h1:VJ0WA2NBN22VlZ2dKZQPAPnyWw5XTlK1KymzLKsr59s= -github.com/gin-gonic/gin v1.4.0/go.mod h1:OW2EZn3DO8Ln9oIKOvM++LBO+5UPHJJDH72/q/3rZdM= github.com/gliderlabs/ssh v0.1.1/go.mod h1:U7qILu1NlMHj9FlMhZLlkCdDnU1DBEAqr0aevW3Awn0= -github.com/go-check/check v0.0.0-20180628173108-788fd7840127/go.mod h1:9ES+weclKsC9YodN5RgxqK/VD9HM9JsCSh7rNhMZE98= github.com/go-chi/chi/v5 v5.0.0/go.mod h1:BBug9lr0cqtdAhsu6R4AAdvufI0/XBzAQSsUqJpoZOs= github.com/go-chi/chi/v5 v5.0.1/go.mod h1:DslCQbL2OYiznFReuXYUmQ2hGd1aDpCnlMNITLSKoi8= github.com/go-chi/chi/v5 v5.0.10 h1:rLz5avzKpjqxrYwXNfmjkrYYXOyLJd37pz53UFHC6vk= @@ -228,7 +197,6 @@ github.com/go-kit/log v0.1.0/go.mod h1:zbhenjAZHb184qTLMA9ZjW7ThYL0H2mk7Q6pNt4vb github.com/go-logfmt/logfmt v0.5.0/go.mod h1:wCYkCAKZfumFQihp8CzCvQ3paCTfi41vtzG1KdI/P7A= github.com/go-logr/logr v1.2.4 h1:g01GSCwiDw2xSZfjJ2/T9M+S6pFdcNtFYsp+Y43HYDQ= github.com/go-logr/logr v1.2.4/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A= -github.com/go-martini/martini v0.0.0-20170121215854-22fa46961aab/go.mod h1:/P9AEU963A2AYjv4d1V5eVL1CQbEJq6aCNHDDjibzu8= github.com/go-ole/go-ole v1.2.6 h1:/Fpf6oFPoeFik9ty7siob0G6Ke8QvQEuVcuChpwXzpY= github.com/go-ole/go-ole v1.2.6/go.mod h1:pprOEPIfldk/42T2oK7lQ4v4JSDwmV0As9GaiUsvbm0= github.com/go-openapi/jsonpointer v0.19.5/go.mod h1:Pl9vOtqEWErmShwVjC8pYs9cog34VGT37dQOVbmoatg= @@ -241,9 +209,6 @@ github.com/go-stack/stack v1.8.1/go.mod h1:dcoOX6HbPZSZptuspn9bctJ+N/CnF5gGygcUP github.com/go-task/slim-sprig v0.0.0-20210107165309-348f09dbbbc0/go.mod h1:fyg7847qk6SyHyPtNmDHnmrv/HOrqktSC+C9fM+CJOE= github.com/go-task/slim-sprig v0.0.0-20230315185526-52ccab3ef572 h1:tfuBGBXKqDEevZMzYi5KSi8KkcZtzBcTgAUUtapy0OI= github.com/go-task/slim-sprig v0.0.0-20230315185526-52ccab3ef572/go.mod h1:9Pwr4B2jHnOSGXyyzV8ROjYa2ojvAY6HCGYYfMoC3Ls= -github.com/gobwas/httphead v0.0.0-20180130184737-2c6c146eadee/go.mod h1:L0fX3K22YWvt/FAX9NnzrNzcI4wNYi9Yku4O0LKYflo= -github.com/gobwas/pool v0.2.0/go.mod h1:q8bcK0KcYlCgd9e7WYLm9LpyS+YeLd8JVDW6WezmKEw= -github.com/gobwas/ws v1.0.2/go.mod h1:szmBTxLgaFppYjEmNtny/v3w89xOydFnnZMcgRRu/EM= github.com/godbus/dbus/v5 v5.0.3/go.mod h1:xhWf0FNVPg57R7Z0UbKHbJfkEywrmjJnf7w5xrFpKfA= github.com/godbus/dbus/v5 v5.0.4/go.mod h1:xhWf0FNVPg57R7Z0UbKHbJfkEywrmjJnf7w5xrFpKfA= github.com/godbus/dbus/v5 v5.1.0 h1:4KLkAxT3aOY8Li4FRJe/KvhoNFFxo0m6fNuFUO8QJUk= @@ -251,32 +216,23 @@ github.com/godbus/dbus/v5 v5.1.0/go.mod h1:xhWf0FNVPg57R7Z0UbKHbJfkEywrmjJnf7w5x github.com/gofrs/flock v0.8.1 h1:+gYjHKf32LDeiEEFhQaotPbLuUXjY5ZqxKgXy7n59aw= github.com/gofrs/flock v0.8.1/go.mod h1:F1TvTiK9OcQqauNUHlbJvyl9Qa1QvF/gOUDKA14jxHU= github.com/gofrs/uuid v4.0.0+incompatible/go.mod h1:b2aQJv3Z4Fp6yNu3cdSllBxTCLRxnplIgP/c0N/04lM= -github.com/gogo/googleapis v0.0.0-20180223154316-0cd9801be74a/go.mod h1:gf4bu3Q80BeJ6H1S1vYPm8/ELATdvryBaNFGgqEef3s= -github.com/gogo/googleapis v1.4.1/go.mod h1:2lpHqI5OcWCtVElxXnPt+s8oJvMpySlOyM6xDCrzib4= github.com/gogo/protobuf v1.1.1/go.mod h1:r8qH/GZQm5c6nD/R0oafs1akxWv10x8SbQlK7atdtwQ= -github.com/gogo/protobuf v1.2.0/go.mod h1:r8qH/GZQm5c6nD/R0oafs1akxWv10x8SbQlK7atdtwQ= github.com/gogo/protobuf v1.3.1/go.mod h1:SlYgWuQ5SjCEi6WLHjHCa1yvBfUnHcTbrrZtXPKa29o= github.com/gogo/protobuf v1.3.2 h1:Ov1cvc58UF3b5XjBnZv7+opcTcQFZebYjWzi34vdm4Q= github.com/gogo/protobuf v1.3.2/go.mod h1:P1XiOD3dCwIKUDQYPy72D8LYyHL2YPYrpS2s69NZV8Q= -github.com/gogo/status v1.1.0/go.mod h1:BFv9nrluPLmrS0EmGVvLaPNmRosr9KapBYd5/hpY1WM= -github.com/golang-jwt/jwt v3.2.2+incompatible/go.mod h1:8pz2t5EyA70fFQQSrl6XZXzqecmYZeUEB8OUGHkxJ+I= -github.com/golang-jwt/jwt/v4 v4.4.2 h1:rcc4lwaZgFMCZ5jxF9ABolDcIHdBytAFgqFPbSJQAYs= -github.com/golang-jwt/jwt/v4 v4.4.2/go.mod h1:m21LjoU+eqJr34lmDMbreY2eSTRJ1cv77w39/MY0Ch0= +github.com/golang-jwt/jwt/v4 v4.5.0 h1:7cYmW1XlMY7h7ii7UhUyChSgS5wUJEnm9uZVTGqOWzg= +github.com/golang-jwt/jwt/v4 v4.5.0/go.mod h1:m21LjoU+eqJr34lmDMbreY2eSTRJ1cv77w39/MY0Ch0= github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q= github.com/golang/lint v0.0.0-20180702182130-06c8688daad7/go.mod h1:tluoj9z5200jBnyusfRPU2LqT6J+DAorxEvtC7LHB+E= github.com/golang/mock v1.1.1/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A= github.com/golang/mock v1.2.0/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A= -github.com/golang/mock v1.6.0 h1:ErTB+efbowRARo13NNdxyJji2egdxLGQhRaY+DUumQc= -github.com/golang/mock v1.6.0/go.mod h1:p6yTPP+5HYm5mzsMV8JkE6ZKdX+/wYM6Hr+LicevLPs= github.com/golang/protobuf v1.2.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= github.com/golang/protobuf v1.3.1/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= -github.com/golang/protobuf v1.3.2/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= github.com/golang/protobuf v1.4.0-rc.1/go.mod h1:ceaxUfeHdC40wWswd/P6IGgMaK3YpKi5j83Wpe3EHw8= github.com/golang/protobuf v1.4.0-rc.1.0.20200221234624-67d41d38c208/go.mod h1:xKAWHe0F5eneWXFV3EuXVDTCmh+JuBKY0li0aMyXATA= github.com/golang/protobuf v1.4.0-rc.2/go.mod h1:LlEzMj4AhA7rCAGe4KMBDvJI+AwstrUpVNzEA03Pprs= github.com/golang/protobuf v1.4.0-rc.4.0.20200313231945-b860323f09d0/go.mod h1:WU3c8KckQ9AFe+yFwt9sWVRKCVIyN9cPHBJSNnbL67w= github.com/golang/protobuf v1.4.0/go.mod h1:jodUvKwWbYaEsadDk5Fwe5c77LiNKVO9IDvqG2KuDX0= -github.com/golang/protobuf v1.4.1/go.mod h1:U8fpvMrcmy5pZrNK1lt4xCsGvpyWQ/VVv6QDs8UjoX8= github.com/golang/protobuf v1.4.2/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI= github.com/golang/protobuf v1.5.0/go.mod h1:FsONVRAS9T7sI+LIUmWTfcYkHO4aIWwzhcaSAoJOfIk= github.com/golang/protobuf v1.5.2/go.mod h1:XVQd3VNwM+JqD3oG2Ue2ip4fOMUkwXdXDdiuN0vRsmY= @@ -287,20 +243,17 @@ github.com/golang/snappy v0.0.4/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEW github.com/golang/snappy v0.0.5-0.20220116011046-fa5810519dcb h1:PBC98N2aIaM3XXiurYmW7fx4GZkL8feAMVq7nEjURHk= github.com/golang/snappy v0.0.5-0.20220116011046-fa5810519dcb/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= github.com/golangci/lint-1 v0.0.0-20181222135242-d2cdd8c08219/go.mod h1:/X8TswGSh1pIozq4ZwCfxS0WA5JGXguxk94ar/4c87Y= -github.com/gomodule/redigo v1.7.1-0.20190724094224-574c33c3df38/go.mod h1:B4C85qUVwatsJoIUNIfCRsp7qO0iAmpGFZ4EELWSbC4= github.com/google/btree v0.0.0-20180813153112-4030bb1f1f0c/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ= github.com/google/go-cmp v0.2.0/go.mod h1:oXzfMopK8JAjlY9xF4vHSVASa0yLyX7SntLO5aqRK0M= github.com/google/go-cmp v0.3.0/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU= github.com/google/go-cmp v0.3.1/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU= github.com/google/go-cmp v0.4.0/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= -github.com/google/go-cmp v0.5.0/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.5.2/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.5.5/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.6.0 h1:ofyhxvXcZhMsU5ulbFiLKl/XBFqE1GSq7atu8tAmTRI= github.com/google/go-cmp v0.6.0/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= github.com/google/go-github v17.0.0+incompatible/go.mod h1:zLgOLi98H3fifZn+44m+umXrS52loVEgC2AApnigrVQ= github.com/google/go-querystring v1.0.0/go.mod h1:odCYkC5MyYFN7vkCjXpyrEuKhc/BUO6wN/zVPAxq5ck= -github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= github.com/google/gofuzz v1.2.1-0.20220503160820-4a35382e8fc8 h1:Ep/joEub9YwcjRY6ND3+Y/w0ncE540RtGatVhtZL0/Q= github.com/google/gofuzz v1.2.1-0.20220503160820-4a35382e8fc8/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= github.com/google/gopacket v1.1.19 h1:ves8RnFZPGiFnTS0uPQStjwru6uO6h+nlr9j6fL7kF8= @@ -310,19 +263,17 @@ github.com/google/pprof v0.0.0-20181206194817-3ea8567a2e57/go.mod h1:zfwlbNMJ+OI github.com/google/pprof v0.0.0-20210407192527-94a9f03dee38/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= github.com/google/pprof v0.0.0-20211214055906-6f57359322fd/go.mod h1:KgnwoLYCZ8IQu3XUZ8Nc/bM9CCZFOyjUNOSygVozoDg= github.com/google/pprof v0.0.0-20230207041349-798e818bf904/go.mod h1:uglQLonpP8qtYCYyzA+8c/9qtqgA3qsXGYqCPKARAFg= -github.com/google/pprof v0.0.0-20230817174616-7a8ec2ada47b h1:h9U78+dx9a4BKdQkBBos92HalKpaGKHrp+3Uo6yTodo= -github.com/google/pprof v0.0.0-20230817174616-7a8ec2ada47b/go.mod h1:czg5+yv1E0ZGTi6S6vVK1mke0fV+FaUhNGcd6VRS9Ik= +github.com/google/pprof v0.0.0-20231023181126-ff6d637d2a7b h1:RMpPgZTSApbPf7xaVel+QkoGPRLFLrwFO89uDUHEGf0= +github.com/google/pprof v0.0.0-20231023181126-ff6d637d2a7b/go.mod h1:czg5+yv1E0ZGTi6S6vVK1mke0fV+FaUhNGcd6VRS9Ik= github.com/google/renameio v0.1.0/go.mod h1:KWCgfxg9yswjAJkECMjeO8J8rahYeXnNhOm40UhjYkI= github.com/google/subcommands v1.2.0/go.mod h1:ZjhPrFU+Olkh9WazFPsl27BQ4UPiG37m3yTrtFlrHVk= github.com/google/uuid v1.1.1/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= -github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= -github.com/google/uuid v1.3.1 h1:KjJaJ9iWZ3jOFZIf1Lqf4laDRCasjl0BCmnEGxkdLb4= -github.com/google/uuid v1.3.1/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= +github.com/google/uuid v1.4.0 h1:MtMxsa51/r9yyhkyLsVeVt0B+BGQZzpQiTQ4eHZ8bc4= +github.com/google/uuid v1.4.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/googleapis/gax-go v2.0.0+incompatible/go.mod h1:SFVmujtThgffbyetf+mdk2eWhX2bMyUtNHzFKcPA9HY= github.com/googleapis/gax-go/v2 v2.0.3/go.mod h1:LLvjysVCY1JZeum8Z6l8qUty8fiNwE08qbEPm1M08qg= github.com/gopherjs/gopherjs v0.0.0-20181017120253-0766667cb4d1/go.mod h1:wJfORRmW1u3UXTncJ5qlYoELFm8eSnnEO6hX4iZ3EWY= github.com/gorilla/mux v1.8.0/go.mod h1:DVbg23sWSpFRCP0SfiEN6jmj59UnW/n46BH5rLB71So= -github.com/gorilla/websocket v1.4.1/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE= github.com/gorilla/websocket v1.5.0 h1:PPwGk2jz7EePpoHN/+ClbZu8SPxiqlu12wZP/3sWmnc= github.com/gorilla/websocket v1.5.0/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE= github.com/graph-gophers/graphql-go v1.3.0 h1:Eb9x/q6MFpCLz7jBCiP/WTxjSDrYLR1QY41SORZyNJ0= @@ -336,12 +287,10 @@ github.com/hashicorp/go-bexpr v0.1.11 h1:6DqdA/KBjurGby9yTY0bmkathya0lfwF2SeuubC github.com/hashicorp/go-bexpr v0.1.11/go.mod h1:f03lAo0duBlDIUMGCuad8oLcgejw4m7U+N8T+6Kz1AE= github.com/hashicorp/go-multierror v1.1.1 h1:H5DkEtf6CXdFp0N0Em5UCwQpXMWke8IA0+lD48awMYo= github.com/hashicorp/go-multierror v1.1.1/go.mod h1:iw975J/qwKPdAO1clOe2L8331t/9/fmwbPZ6JB6eMoM= -github.com/hashicorp/go-version v1.2.0/go.mod h1:fltr4n8CU8Ke44wwGCBoEymUuxUHl09ZGVZPK5anwXA= github.com/hashicorp/golang-lru/arc/v2 v2.0.5 h1:l2zaLDubNhW4XO3LnliVj0GXO3+/CGNJAg1dcN2Fpfw= github.com/hashicorp/golang-lru/arc/v2 v2.0.5/go.mod h1:ny6zBSQZi2JxIeYcv7kt2sH2PXJtirBN7RDhRpxPkxU= github.com/hashicorp/golang-lru/v2 v2.0.5 h1:wW7h1TG88eUIJ2i69gaE3uNVtEPIagzhGvHgwfx2Vm4= github.com/hashicorp/golang-lru/v2 v2.0.5/go.mod h1:QeFd9opnmA6QUJc5vARoKUSoFhyfM2/ZepoAG6RGpeM= -github.com/hashicorp/hcl v1.0.0/go.mod h1:E5yfLk+7swimpb2L/Alb/PJmXilQ/rhwaUYs4T20WEQ= github.com/holiman/billy v0.0.0-20230718173358-1c7e68d277a7 h1:3JQNjnMRil1yD0IfZKHF9GxxWKDJGj8I0IqOUol//sw= github.com/holiman/billy v0.0.0-20230718173358-1c7e68d277a7/go.mod h1:5GuXa7vkL8u9FkFuWdVvfR5ix8hRB7DbOAaYULamFpc= github.com/holiman/bloomfilter/v2 v2.0.3 h1:73e0e/V0tCydx14a0SCYS/EWCxgwLZ18CZcZKVu0fao= @@ -351,12 +300,9 @@ github.com/holiman/uint256 v1.2.3/go.mod h1:SC8Ryt4n+UBbPbIBKaG9zbbDlp4jOru9xFZm github.com/hpcloud/tail v1.0.0/go.mod h1:ab1qPbhIpdTxEkNHXyeSf5vhxWSCs/tWer42PpOxQnU= github.com/huin/goupnp v1.3.0 h1:UvLUlWDNpoUdYzb2TCn+MuTWtcjXKSza2n6CBdQ0xXc= github.com/huin/goupnp v1.3.0/go.mod h1:gnGPsThkYa7bFi/KWmEysQRf48l2dvR5bxr2OFckNX8= -github.com/hydrogen18/memlistener v0.0.0-20200120041712-dcc25e7acd91/go.mod h1:qEIFzExnS6016fRpRfxrExeVn2gbClQA99gQhnIcdhE= github.com/ianlancetaylor/demangle v0.0.0-20200824232613-28f6c0f3b639/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= github.com/ianlancetaylor/demangle v0.0.0-20210905161508-09a460cdf81d/go.mod h1:aYm2/VgdVmcIU8iMfdMvDMsRAQjcfZSKFby6HOFvi/w= github.com/ianlancetaylor/demangle v0.0.0-20220319035150-800ac71e25c2/go.mod h1:aYm2/VgdVmcIU8iMfdMvDMsRAQjcfZSKFby6HOFvi/w= -github.com/imkira/go-interpol v1.1.0/go.mod h1:z0h2/2T3XF8kyEPpRgJ3kmNv+C43p+I/CoI+jC3w2iA= -github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8= github.com/influxdata/influxdb-client-go/v2 v2.4.0 h1:HGBfZYStlx3Kqvsv1h2pJixbCl/jhnFtxpKFAv9Tu5k= github.com/influxdata/influxdb-client-go/v2 v2.4.0/go.mod h1:vLNHdxTJkIf2mSLvGrpj8TCcISApPoXkaxP8g9uRlW8= github.com/influxdata/influxdb1-client v0.0.0-20220302092344-a9ab5670611c h1:qSHzRbhzK8RdXOsAdfDgO49TtqC1oZ+acxPrkfTxcCs= @@ -378,11 +324,6 @@ github.com/ipfs/go-ds-leveldb v0.5.0/go.mod h1:d3XG9RUDzQ6V4SHi8+Xgj9j1XuEk1z82l github.com/ipfs/go-ipfs-delay v0.0.0-20181109222059-70721b86a9a8/go.mod h1:8SP1YXK1M1kXuc4KJZINY3TQQ03J2rwBG9QfXmbRPrw= github.com/ipfs/go-log/v2 v2.5.1 h1:1XdUzF7048prq4aBjDQQ4SL5RxftpRGdXhNRwKSAlcY= github.com/ipfs/go-log/v2 v2.5.1/go.mod h1:prSpmC1Gpllc9UYWxDiZDreBYw7zp4Iqp1kOLU9U5UI= -github.com/iris-contrib/blackfriday v2.0.0+incompatible/go.mod h1:UzZ2bDEoaSGPbkg6SAB4att1aAwTmVIx/5gCVqeyUdI= -github.com/iris-contrib/go.uuid v2.0.0+incompatible/go.mod h1:iz2lgM/1UnEf1kP0L/+fafWORmlnuysV2EMP8MW+qe0= -github.com/iris-contrib/jade v1.1.3/go.mod h1:H/geBymxJhShH5kecoiOCSssPX7QWYH7UaeZTSWddIk= -github.com/iris-contrib/pongo2 v0.0.1/go.mod h1:Ssh+00+3GAZqSQb30AvBRNxBx7rf0GqwkjqxNd0u65g= -github.com/iris-contrib/schema v0.0.1/go.mod h1:urYA3uvUNG1TIIjOSCzHr9/LmbQo8LrOcOqfqxa4hXw= github.com/jackc/chunkreader v1.0.0 h1:4s39bBR8ByfqH+DKm8rQA3E1LHZWB9XWcrz8fqaZbe0= github.com/jackc/chunkreader v1.0.0/go.mod h1:RT6O25fNZIuasFJRyZ4R/Y2BbhasbmZXF9QQ7T3kePo= github.com/jackc/chunkreader/v2 v2.0.0/go.mod h1:odVSm741yZoC3dpHEUXIqA9tQRhFrgOHwnPIn9lDKlk= @@ -425,11 +366,13 @@ github.com/jackc/pgx/v4 v4.0.0-20190421002000-1b8f0016e912/go.mod h1:no/Y67Jkk/9 github.com/jackc/pgx/v4 v4.0.0-pre1.0.20190824185557-6972a5742186/go.mod h1:X+GQnOEnf1dqHGpw7JmHqHc1NxDoalibchSk9/RWuDc= github.com/jackc/pgx/v4 v4.12.1-0.20210724153913-640aa07df17c h1:Dznn52SgVIVst9UyOT9brctYUgxs+CvVfPaC3jKrA50= github.com/jackc/pgx/v4 v4.12.1-0.20210724153913-640aa07df17c/go.mod h1:1QD0+tgSXP7iUjYm9C1NxKhny7lq6ee99u/z+IHFcgs= -github.com/jackc/pgx/v5 v5.4.3 h1:cxFyXhxlvAifxnkKKdlxv8XqUf59tDlYjnV5YYfsJJY= -github.com/jackc/pgx/v5 v5.4.3/go.mod h1:Ig06C2Vu0t5qXC60W8sqIthScaEnFvojjj9dSljmHRA= +github.com/jackc/pgx/v5 v5.5.0 h1:NxstgwndsTRy7eq9/kqYc/BZh5w2hHJV86wjvO+1xPw= +github.com/jackc/pgx/v5 v5.5.0/go.mod h1:Ig06C2Vu0t5qXC60W8sqIthScaEnFvojjj9dSljmHRA= github.com/jackc/puddle v0.0.0-20190413234325-e4ced69a3a2b/go.mod h1:m4B5Dj62Y0fbyuIc15OsIqK0+JU8nkqQjsgx7dvjSWk= github.com/jackc/puddle v0.0.0-20190608224051-11cab39313c9/go.mod h1:m4B5Dj62Y0fbyuIc15OsIqK0+JU8nkqQjsgx7dvjSWk= github.com/jackc/puddle v1.1.3/go.mod h1:m4B5Dj62Y0fbyuIc15OsIqK0+JU8nkqQjsgx7dvjSWk= +github.com/jackc/puddle/v2 v2.2.1 h1:RhxXJtFG022u4ibrCSMSiu5aOq1i77R3OHKNJj77OAk= +github.com/jackc/puddle/v2 v2.2.1/go.mod h1:vriiEXHvEE654aYKXXjOvZM39qJ0q+azkZFrfEOc3H4= github.com/jackpal/go-nat-pmp v1.0.2 h1:KzKSgb7qkJvOUTqYl9/Hg/me3pWgBmERKrTGD7BdWus= github.com/jackpal/go-nat-pmp v1.0.2/go.mod h1:QPH045xvCAeXUZOxsnwmrtiCoxIr9eob+4orBN1SBKc= github.com/jbenet/go-cienv v0.1.0/go.mod h1:TqNnHUmJgXau0nCzC7kXWeotg3J9W34CUv5Djy1+FlA= @@ -448,28 +391,17 @@ github.com/jinzhu/now v1.1.5 h1:/o9tlHleP7gOFmsnYNz3RGnqzefHA47wQpKrrdTIwXQ= github.com/jinzhu/now v1.1.5/go.mod h1:d3SSVoowX0Lcu0IBviAWJpolVfI5UJVZZ7cO71lE/z8= github.com/jrick/logrotate v1.0.0/go.mod h1:LNinyqDIJnpAur+b8yyulnQw/wDuN1+BYKlTRt3OuAQ= github.com/json-iterator/go v1.1.6/go.mod h1:+SdeFBvtyEkXs7REEP0seUULqWtbJapLOCVDaaPEHmU= -github.com/json-iterator/go v1.1.9/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= github.com/jstemmer/go-junit-report v0.0.0-20190106144839-af01ea7f8024/go.mod h1:6v2b51hI/fHJwM22ozAgKL4VKDeJcHhJFhtBdhmNjmU= -github.com/jtolds/gls v4.20.0+incompatible/go.mod h1:QJZ7F/aHp+rZTRtaJ1ow/lLfFfVYBRgL+9YlvaHOwJU= github.com/julienschmidt/httprouter v1.3.0 h1:U0609e9tgbseu3rBINet9P48AI/D3oJs4dN7jwJOQ1U= github.com/julienschmidt/httprouter v1.3.0/go.mod h1:JR6WtHb+2LUe8TCKY3cZOxFyyO8IZAc4RVcycCCAKdM= -github.com/k0kubun/colorstring v0.0.0-20150214042306-9440f1994b88/go.mod h1:3w7q1U84EfirKl04SVQ/s7nPm1ZPhiXd34z40TNz36k= github.com/karalabe/usb v0.0.3-0.20230711191512-61db3e06439c h1:AqsttAyEyIEsNz5WLRwuRwjiT5CMDUfLk6cFJDVPebs= github.com/karalabe/usb v0.0.3-0.20230711191512-61db3e06439c/go.mod h1:Od972xHfMJowv7NGVDiWVxk2zxnWgjLlJzE+F4F7AGU= -github.com/kataras/golog v0.0.10/go.mod h1:yJ8YKCmyL+nWjERB90Qwn+bdyBZsaQwU3bTVFgkFIp8= -github.com/kataras/iris/v12 v12.1.8/go.mod h1:LMYy4VlP67TQ3Zgriz8RE2h2kMZV2SgMYbq3UhfoFmE= -github.com/kataras/neffos v0.0.14/go.mod h1:8lqADm8PnbeFfL7CLXh1WHw53dG27MC3pgi2R1rmoTE= -github.com/kataras/pio v0.0.2/go.mod h1:hAoW0t9UmXi4R5Oyq5Z4irTbaTsOemSrDGUtaTl7Dro= -github.com/kataras/sitemap v0.0.5/go.mod h1:KY2eugMKiPwsJgx7+U103YZehfvNGOXURubcGyk0Bz8= github.com/kisielk/errcheck v1.2.0/go.mod h1:/BMXB+zMLi60iA8Vv6Ksmxu/1UDYcXs4uQLJ+jE2L00= github.com/kisielk/errcheck v1.5.0/go.mod h1:pFxgyoBC7bSaBwPgfKdkLd5X25qrDl4LWUI2bnpBCr8= github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck= github.com/kkdai/bstream v0.0.0-20161212061736-f391b8402d23/go.mod h1:J+Gs4SYgM6CZQHDETBtE9HaSEkGmuNXF86RwHhHUvq4= -github.com/klauspost/compress v1.8.2/go.mod h1:RyIbtBH6LamlWaDj8nUwkbUhJ87Yi3uG0guNDohfE1A= -github.com/klauspost/compress v1.9.7/go.mod h1:RyIbtBH6LamlWaDj8nUwkbUhJ87Yi3uG0guNDohfE1A= -github.com/klauspost/compress v1.16.7 h1:2mk3MPGNzKyxErAw8YaohYh69+pa4sIQSC0fPGCFR9I= -github.com/klauspost/compress v1.16.7/go.mod h1:ntbaceVETuRiXiv4DpjP66DpAtAGkEQskQzEyD//IeE= -github.com/klauspost/cpuid v1.2.1/go.mod h1:Pj4uuM528wm8OyEC2QMXAi2YiTZ96dNQPGgoMS4s3ek= +github.com/klauspost/compress v1.17.2 h1:RlWWUY/Dr4fL8qk9YG7DTZ7PDgME2V4csBXA8L/ixi4= +github.com/klauspost/compress v1.17.2/go.mod h1:ntbaceVETuRiXiv4DpjP66DpAtAGkEQskQzEyD//IeE= github.com/klauspost/cpuid/v2 v2.2.5 h1:0E5MSMDEoAulmXNFquVs//DdoomxaoTY1kUhbc/qbZg= github.com/klauspost/cpuid/v2 v2.2.5/go.mod h1:Lcz8mBdAVJIBVzewtcLocK12l3Y+JytZYpaMropDUws= github.com/konsorten/go-windows-terminal-sequences v1.0.1/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= @@ -491,7 +423,6 @@ github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE= github.com/kylelemons/godebug v1.1.0 h1:RPNrshWIDI6G2gRW9EHilWtl7Z6Sb1BR0xunSBf0SNc= github.com/kylelemons/godebug v1.1.0/go.mod h1:9/0rRGxNHcop5bhtWyNeEfOS8JIWk580+fNqagV/RAw= github.com/labstack/echo/v4 v4.2.1/go.mod h1:AA49e0DZ8kk5jTOOCKNuPR6oTnBS0dYiM4FW1e6jwpg= -github.com/labstack/echo/v4 v4.5.0/go.mod h1:czIriw4a0C1dFun+ObrXp7ok03xON0N1awStJ6ArI7Y= github.com/labstack/gommon v0.3.0/go.mod h1:MULnywXg0yavhxWKc+lOruYdAhDwPK9wf0OL7NoOu+k= github.com/leanovate/gopter v0.2.9 h1:fQjYxZaynp97ozCzfOyOuAGOU4aU/z37zf/tOujFk7c= github.com/leanovate/gopter v0.2.9/go.mod h1:U2L/78B+KVFIx2VmW6onHJQzXtFb+p5y3y2Sh+Jxxv8= @@ -507,14 +438,14 @@ github.com/libp2p/go-cidranger v1.1.0 h1:ewPN8EZ0dd1LSnrtuwd4709PXVcITVeuwbag38y github.com/libp2p/go-cidranger v1.1.0/go.mod h1:KWZTfSr+r9qEo9OkI9/SIEeAtw+NNoU0dXIXt15Okic= github.com/libp2p/go-flow-metrics v0.1.0 h1:0iPhMI8PskQwzh57jB9WxIuIOQ0r+15PChFGkx3Q3WM= github.com/libp2p/go-flow-metrics v0.1.0/go.mod h1:4Xi8MX8wj5aWNDAZttg6UPmc0ZrnFNsMtpsYUClFtro= -github.com/libp2p/go-libp2p v0.31.0 h1:LFShhP8F6xthWiBBq3euxbKjZsoRajVEyBS9snfHxYg= -github.com/libp2p/go-libp2p v0.31.0/go.mod h1:W/FEK1c/t04PbRH3fA9i5oucu5YcgrG0JVoBWT1B7Eg= +github.com/libp2p/go-libp2p v0.32.0 h1:86I4B7nBUPIyTgw3+5Ibq6K7DdKRCuZw8URCfPc1hQM= +github.com/libp2p/go-libp2p v0.32.0/go.mod h1:hXXC3kXPlBZ1eu8Q2hptGrMB4mZ3048JUoS4EKaHW5c= github.com/libp2p/go-libp2p-asn-util v0.3.0 h1:gMDcMyYiZKkocGXDQ5nsUQyquC9+H+iLEQHwOCZ7s8s= github.com/libp2p/go-libp2p-asn-util v0.3.0/go.mod h1:B1mcOrKUE35Xq/ASTmQ4tN3LNzVVaMNmq2NACuqyB9w= github.com/libp2p/go-libp2p-mplex v0.9.0 h1:R58pDRAmuBXkYugbSSXR9wrTX3+1pFM1xP2bLuodIq8= github.com/libp2p/go-libp2p-mplex v0.9.0/go.mod h1:ro1i4kuwiFT+uMPbIDIFkcLs1KRbNp0QwnUXM+P64Og= -github.com/libp2p/go-libp2p-pubsub v0.9.3 h1:ihcz9oIBMaCK9kcx+yHWm3mLAFBMAUsM4ux42aikDxo= -github.com/libp2p/go-libp2p-pubsub v0.9.3/go.mod h1:RYA7aM9jIic5VV47WXu4GkcRxRhrdElWf8xtyli+Dzc= +github.com/libp2p/go-libp2p-pubsub v0.10.0 h1:wS0S5FlISavMaAbxyQn3dxMOe2eegMfswM471RuHJwA= +github.com/libp2p/go-libp2p-pubsub v0.10.0/go.mod h1:1OxbaT/pFRO5h+Dpze8hdHQ63R0ke55XTs6b6NwLLkw= github.com/libp2p/go-libp2p-testing v0.12.0 h1:EPvBb4kKMWO29qP4mZGyhVzUyR25dvfUIK5WDu6iPUA= github.com/libp2p/go-libp2p-testing v0.12.0/go.mod h1:KcGDRXyN7sQCllucn1cOOS+Dmm7ujhfEyXQL5lvkcPg= github.com/libp2p/go-mplex v0.7.0 h1:BDhFZdlk5tbr0oyFq/xv/NPGfjbnrsDam1EvutpBDbY= @@ -530,7 +461,6 @@ github.com/libp2p/go-reuseport v0.4.0/go.mod h1:ZtI03j/wO5hZVDFo2jKywN6bYKWLOy8S github.com/libp2p/go-yamux/v4 v4.0.1 h1:FfDR4S1wj6Bw2Pqbc8Uz7pCxeRBPbwsBbEdfwiCypkQ= github.com/libp2p/go-yamux/v4 v4.0.1/go.mod h1:NWjl8ZTLOGlozrXSOZ/HlfG++39iKNnM5wwmtQP1YB4= github.com/lunixbochs/vtclean v1.0.0/go.mod h1:pHhQNgMf3btfWnGBVipUOjRYhoOsdGqdm/+2c2E2WMI= -github.com/magiconair/properties v1.8.0/go.mod h1:PppfXfuXeibc/6YijjN8zIbojt8czPbwD3XqdrwzmxQ= github.com/mailru/easyjson v0.0.0-20190312143242-1de009706dbe/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc= github.com/mailru/easyjson v0.0.0-20190614124828-94de47d64c63/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc= github.com/mailru/easyjson v0.0.0-20190626092158-b2ccc519800e/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc= @@ -542,7 +472,7 @@ github.com/mattn/go-colorable v0.1.2/go.mod h1:U0ppj6V5qS13XJ6of8GYAs25YV2eR4EVc github.com/mattn/go-colorable v0.1.6/go.mod h1:u6P/XSegPjTcexA+o6vUJrdnUu04hMope9wVRipJSqc= github.com/mattn/go-colorable v0.1.7/go.mod h1:u6P/XSegPjTcexA+o6vUJrdnUu04hMope9wVRipJSqc= github.com/mattn/go-colorable v0.1.8/go.mod h1:u6P/XSegPjTcexA+o6vUJrdnUu04hMope9wVRipJSqc= -github.com/mattn/go-colorable v0.1.11/go.mod h1:u5H1YNBxpqRaxsYJYSkiCWKzEfiAb1Gb520KVy5xxl4= +github.com/mattn/go-colorable v0.1.9/go.mod h1:u6P/XSegPjTcexA+o6vUJrdnUu04hMope9wVRipJSqc= github.com/mattn/go-colorable v0.1.13 h1:fFA4WZxdEF4tXPZVKMLwD8oUnCTTo08duU7wxecdEvA= github.com/mattn/go-colorable v0.1.13/go.mod h1:7S9/ev0klgBDR4GtXTXX8a3vIGJpMovkB8vQcUbaXHg= github.com/mattn/go-isatty v0.0.5/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s= @@ -552,22 +482,19 @@ github.com/mattn/go-isatty v0.0.9/go.mod h1:YNRxwqDuOph6SZLI9vUUz6OYw3QyUt7WiY2y github.com/mattn/go-isatty v0.0.12/go.mod h1:cbi8OIDigv2wuxKPP5vlRcQ1OAZbq2CE4Kysco4FUpU= github.com/mattn/go-isatty v0.0.14/go.mod h1:7GGIvUiUoEMVVmxf/4nioHXj79iQHKdU27kJ6hsGG94= github.com/mattn/go-isatty v0.0.16/go.mod h1:kYGgaQfpe5nmfYZH+SKPsOc2e4SrIfOl2e/yFXSvRLM= -github.com/mattn/go-isatty v0.0.19 h1:JITubQf0MOLdlGRuRq+jtsDlekdYPia9ZFsB8h/APPA= -github.com/mattn/go-isatty v0.0.19/go.mod h1:W+V8PltTTMOvKvAeJH7IuucS94S2C6jfK/D7dTCTo3Y= +github.com/mattn/go-isatty v0.0.20 h1:xfD0iDuEKnDkl03q4limB+vH+GxLEtL/jb4xVJSWWEY= +github.com/mattn/go-isatty v0.0.20/go.mod h1:W+V8PltTTMOvKvAeJH7IuucS94S2C6jfK/D7dTCTo3Y= github.com/mattn/go-runewidth v0.0.3/go.mod h1:LwmH8dsx7+W8Uxz3IHJYH5QSwggIsqBzpuz5H//U1FU= github.com/mattn/go-runewidth v0.0.9/go.mod h1:H031xJmbD/WCDINGzjvQ9THkh0rPKHF+m2gUSrubnMI= github.com/mattn/go-runewidth v0.0.14 h1:+xnbZSEeDbOIg5/mE6JF0w6n9duR1l3/WmbinWVwUuU= github.com/mattn/go-runewidth v0.0.14/go.mod h1:Jdepj2loyihRzMpdS35Xk/zdY8IAYHsh153qUoGf23w= -github.com/mattn/goveralls v0.0.2/go.mod h1:8d1ZMHsd7fW6IRPKQh46F2WRpyib5/X4FOpevwGNQEw= github.com/matttproud/golang_protobuf_extensions v1.0.1/go.mod h1:D8He9yQNgCq6Z5Ld7szi9bcBfOoFv/3dc6xSMkL2PC0= github.com/matttproud/golang_protobuf_extensions v1.0.4 h1:mmDVorXM7PCGKw94cs5zkfA9PSy5pEvNWRP0ET0TIVo= github.com/matttproud/golang_protobuf_extensions v1.0.4/go.mod h1:BSXmuO+STAnVfrANrmjBb36TMTDstsz7MSK+HVaYKv4= -github.com/mediocregopher/radix/v3 v3.4.2/go.mod h1:8FL3F6UQRXHXIBSPUs5h0RybMF8i4n7wVopoX3x7Bv8= github.com/microcosm-cc/bluemonday v1.0.1/go.mod h1:hsXNsILzKxV+sX77C5b8FSuKF00vh2OMYv+xgHpAMF4= -github.com/microcosm-cc/bluemonday v1.0.2/go.mod h1:iVP4YcDBq+n/5fb23BhYFvIMq/leAFZyRl6bYmGDlGc= github.com/miekg/dns v1.1.41/go.mod h1:p6aan82bvRIyn+zDIv9xYNUpwa73JcSh9BKwknJysuI= -github.com/miekg/dns v1.1.55 h1:GoQ4hpsj0nFLYe+bWiCToyrBEJXkQfOOIvFGFy0lEgo= -github.com/miekg/dns v1.1.55/go.mod h1:uInx36IzPl7FYnDcMeVWxj9byh7DutNykX4G9Sj60FY= +github.com/miekg/dns v1.1.56 h1:5imZaSeoRNvpM9SzWNhEcP9QliKiz20/dA2QabIGVnE= +github.com/miekg/dns v1.1.56/go.mod h1:cRm6Oo2C8TY9ZS/TqsSrseAcncm74lfK5G+ikN2SWWY= github.com/mikioh/tcp v0.0.0-20190314235350-803a9b46060c h1:bzE/A84HN25pxAuk9Eej1Kz9OUelF97nAc82bDquQI8= github.com/mikioh/tcp v0.0.0-20190314235350-803a9b46060c/go.mod h1:0SQS9kMwD2VsyFEB++InYyBJroV/FRmBgcydeSUcJms= github.com/mikioh/tcpinfo v0.0.0-20190314235526-30a79bb1804b h1:z78hV3sbSMAUoyUMM0I83AUIT6Hu17AWfgjzIbtrYFc= @@ -578,8 +505,6 @@ github.com/minio/blake2b-simd v0.0.0-20160723061019-3f5f724cb5b1/go.mod h1:pD8Rv github.com/minio/sha256-simd v0.1.1-0.20190913151208-6de447530771/go.mod h1:B5e1o+1/KgNmWrSQK08Y6Z1Vb5pwIktudl0J58iy0KM= github.com/minio/sha256-simd v1.0.1 h1:6kaan5IFmwTNynnKKpDHe6FWHohJOHhCPchzK49dzMM= github.com/minio/sha256-simd v1.0.1/go.mod h1:Pz6AKMiUdngCLpeTL/RJY1M9rUuPMYujV5xJjtbRSN8= -github.com/mitchellh/go-homedir v1.1.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0= -github.com/mitchellh/mapstructure v1.1.2/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y= github.com/mitchellh/mapstructure v1.4.1/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= github.com/mitchellh/mapstructure v1.5.0 h1:jeMsZIYE/09sWLaz43PL7Gy6RuMjD2eJVyuac5Z2hdY= github.com/mitchellh/mapstructure v1.5.0/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= @@ -588,11 +513,8 @@ github.com/mitchellh/pointerstructure v1.2.1/go.mod h1:BRAsLI5zgXmw97Lf6s25bs8oh github.com/mmcloughlin/addchain v0.4.0 h1:SobOdjm2xLj1KkXN5/n0xTIWyZA2+s99UCY1iPfkHRY= github.com/mmcloughlin/addchain v0.4.0/go.mod h1:A86O+tHqZLMNO4w6ZZ4FlVQEadcoqkyU72HC5wJ4RlU= github.com/mmcloughlin/profile v0.1.1/go.mod h1:IhHD7q1ooxgwTgjxQYkACGA77oFTDdFVejUS1/tS/qU= -github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= -github.com/modern-go/reflect2 v0.0.0-20180701023420-4b7aa43c6742/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0= github.com/modern-go/reflect2 v1.0.1/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0= -github.com/moul/http2curl v1.0.0/go.mod h1:8UbvGypXm98wA/IqH45anm5Y2Z6ep6O31QGOAZ3H0fQ= github.com/mr-tron/base58 v1.1.2/go.mod h1:BinMc/sQntlIE1frQmRFPUoPA1Zkr8VRgBdjWI2mNwc= github.com/mr-tron/base58 v1.2.0 h1:T/HDJBh4ZCPbU39/+c3rRvE0uKBQlU27+QI8LJ4t64o= github.com/mr-tron/base58 v1.2.0/go.mod h1:BinMc/sQntlIE1frQmRFPUoPA1Zkr8VRgBdjWI2mNwc= @@ -615,8 +537,8 @@ github.com/multiformats/go-multicodec v0.9.0/go.mod h1:L3QTQvMIaVBkXOXXtVmYE+LI1 github.com/multiformats/go-multihash v0.0.8/go.mod h1:YSLudS+Pi8NHE7o6tb3D8vrpKa63epEDmG8nTduyAew= github.com/multiformats/go-multihash v0.2.3 h1:7Lyc8XfX/IY2jWb/gI7JP+o7JEq9hOa7BFvVU9RSh+U= github.com/multiformats/go-multihash v0.2.3/go.mod h1:dXgKXCXjBzdscBLk9JkjINiEsCKRVch90MdaGiKsvSM= -github.com/multiformats/go-multistream v0.4.1 h1:rFy0Iiyn3YT0asivDUIR05leAdwZq3de4741sbiSdfo= -github.com/multiformats/go-multistream v0.4.1/go.mod h1:Mz5eykRVAjJWckE2U78c6xqdtyNUEhKSM0Lwar2p77Q= +github.com/multiformats/go-multistream v0.5.0 h1:5htLSLl7lvJk3xx3qT/8Zm9J4K8vEOf/QGkvOGQAyiE= +github.com/multiformats/go-multistream v0.5.0/go.mod h1:n6tMZiwiP2wUsR8DgfDWw1dydlEqV3l6N3/GBsX6ILA= github.com/multiformats/go-varint v0.0.1/go.mod h1:3Ls8CIEsrijN6+B7PbrXRPxHRPuXSrVKRY101jdMZYE= github.com/multiformats/go-varint v0.0.7 h1:sWSGR+f/eu5ABZA2ZpYKBILXTTs9JWpdEM/nEGOHFS8= github.com/multiformats/go-varint v0.0.7/go.mod h1:r8PUYw/fD/SjBCiKOoDlGF6QawOELpZAu9eioSos/OU= @@ -624,10 +546,6 @@ github.com/naoina/go-stringutil v0.1.0 h1:rCUeRUHjBjGTSHl0VC00jUPLz8/F9dDzYI70Hz github.com/naoina/go-stringutil v0.1.0/go.mod h1:XJ2SJL9jCtBh+P9q5btrd/Ylo8XwT/h1USek5+NqSA0= github.com/naoina/toml v0.1.2-0.20170918210437-9fafd6967416 h1:shk/vn9oCoOTmwcouEdwIeOtOGA/ELRUw/GwvxwfT+0= github.com/naoina/toml v0.1.2-0.20170918210437-9fafd6967416/go.mod h1:NBIhNtsFMo3G2szEBne+bO4gS192HuIYRqfvOWb4i1E= -github.com/nats-io/jwt v0.3.0/go.mod h1:fRYCDE99xlTsqUzISS1Bi75UBJ6ljOJQOAAu5VglpSg= -github.com/nats-io/nats.go v1.9.1/go.mod h1:ZjDU1L/7fJ09jvUSRVBR2e7+RnLiiIQyqyzEE/Zbp4w= -github.com/nats-io/nkeys v0.1.0/go.mod h1:xpnFELMwJABBLVhffcfd1MZx6VsNRFpEugbxziKVo7w= -github.com/nats-io/nuid v1.0.1/go.mod h1:19wcPz3Ph3q0Jbyiqsd0kePYG7A95tJPxeL+1OSON2c= github.com/neelance/astrewrite v0.0.0-20160511093645-99348263ae86/go.mod h1:kHJEU3ofeGjhHklVoIGuVj85JJwZ6kWPaJwCIxgnFmo= github.com/neelance/sourcemap v0.0.0-20151028013722-8c68805598ab/go.mod h1:Qr6/a/Q4r9LP1IltGz7tA7iOK1WonHEYhu1HRBA7ZiM= github.com/nxadm/tail v1.4.4/go.mod h1:kenIhsEOeOJmVchQTgglprH7qJGnHDVpk1VPCcaMI8A= @@ -637,23 +555,22 @@ github.com/olekukonko/tablewriter v0.0.5 h1:P2Ga83D34wi1o9J6Wh1mRuqd4mF/x/lgBS7N github.com/olekukonko/tablewriter v0.0.5/go.mod h1:hPp6KlRPjbx+hW8ykQs1w3UBbZlj6HuIJcUGPhkA7kY= github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= github.com/onsi/ginkgo v1.7.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= -github.com/onsi/ginkgo v1.10.3/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= github.com/onsi/ginkgo v1.12.1/go.mod h1:zj2OWP4+oCPe1qIXoGWkgMRwljMUYCdkwsT2108oapk= github.com/onsi/ginkgo v1.14.0/go.mod h1:iSB4RoI2tjJc9BBv4NKIKWKya62Rps+oPG/Lv9klQyY= github.com/onsi/ginkgo v1.16.4/go.mod h1:dX+/inL/fNMqNlz0e9LfyB9TswhZpCVdJM/Z6Vvnwo0= github.com/onsi/ginkgo v1.16.5 h1:8xi0RTUf59SOSfEtZMvwTvXYMzG4gV23XVHOZiXNtnE= github.com/onsi/ginkgo v1.16.5/go.mod h1:+E8gABHa3K6zRBolWtd+ROzc/U5bkGt0FwiG042wbpU= github.com/onsi/ginkgo/v2 v2.1.3/go.mod h1:vw5CSIxN1JObi/U8gcbwft7ZxR2dgaR70JSE3/PpL4c= -github.com/onsi/ginkgo/v2 v2.12.0 h1:UIVDowFPwpg6yMUpPjGkYvf06K3RAiJXUhCxEwQVHRI= -github.com/onsi/ginkgo/v2 v2.12.0/go.mod h1:ZNEzXISYlqpb8S36iN71ifqLi3vVD1rVJGvWRCJOUpQ= +github.com/onsi/ginkgo/v2 v2.13.0 h1:0jY9lJquiL8fcf3M4LAXN5aMlS/b2BV86HFFPCPMgE4= +github.com/onsi/ginkgo/v2 v2.13.0/go.mod h1:TE309ZR8s5FsKKpuB1YAQYBzCaAfUgatB/xlT/ETL/o= github.com/onsi/gomega v1.4.1/go.mod h1:C1qb7wdrVGGVU+Z6iS04AVkA3Q65CEZX59MT0QO5uiA= github.com/onsi/gomega v1.4.3/go.mod h1:ex+gbHU/CVuBBDIJjb2X0qEXbFg53c61hWP/1CpauHY= github.com/onsi/gomega v1.7.1/go.mod h1:XdKZgCCFLUoM/7CFJVPcG8C1xQ1AJ0vpAezJrB7JYyY= github.com/onsi/gomega v1.10.1/go.mod h1:iN09h71vgCQne3DLsj+A5owkum+a2tYe+TOCB1ybHNo= github.com/onsi/gomega v1.17.0/go.mod h1:HnhC7FXeEQY45zxNK3PPoIUhzk/80Xly9PcubAlGdZY= github.com/onsi/gomega v1.19.0/go.mod h1:LY+I3pBVzYsTBU1AnDwOSxaYi9WoWiqgwooUqq9yPro= -github.com/onsi/gomega v1.28.0 h1:i2rg/p9n/UqIDAMFUJ6qIUUMcsqOuUHgbpbu235Vr1c= -github.com/onsi/gomega v1.28.0/go.mod h1:A1H2JE76sI14WIP57LMKj7FVfCHx3g3BcZVjJG8bjX8= +github.com/onsi/gomega v1.30.0 h1:hvMK7xYz4D3HapigLTeGdId/NcfQx1VHMJc60ew99+8= +github.com/onsi/gomega v1.30.0/go.mod h1:9sxs+SwGrKI0+PWe4Fxa9tFQQBG5xSsSbMXOI8PPpoQ= github.com/opencontainers/runtime-spec v1.0.2/go.mod h1:jwyrGlmzljRJv/Fgzds9SsS/C5hL+LL3ko9hs6T5lQ0= github.com/opencontainers/runtime-spec v1.1.0 h1:HHUyrt9mwHUjtasSbXSMvs4cyFxh+Bll4AjJ9odEGpg= github.com/opencontainers/runtime-spec v1.1.0/go.mod h1:jwyrGlmzljRJv/Fgzds9SsS/C5hL+LL3ko9hs6T5lQ0= @@ -663,7 +580,6 @@ github.com/opentracing/opentracing-go v1.2.0/go.mod h1:GxEUsuufX4nBwe+T+Wl9TAgYr github.com/openzipkin/zipkin-go v0.1.1/go.mod h1:NtoC/o8u3JlF1lSlyPNswIbeQH9bJTmOf0Erfk+hxe8= github.com/pbnjay/memory v0.0.0-20210728143218-7b4eea64cf58 h1:onHthvaw9LFnH4t2DcNVpwGmV9E1BkGknEliJkfwQj0= github.com/pbnjay/memory v0.0.0-20210728143218-7b4eea64cf58/go.mod h1:DXv8WO4yhMYhSNPKjeNKa5WY9YCIEBRbNzFFPJbWO6Y= -github.com/pelletier/go-toml v1.2.0/go.mod h1:5z9KED0ma1S8pY6P1sdut58dfprrGBbd/94hg7ilaic= github.com/peterh/liner v1.1.1-0.20190123174540-a2c9a5303de7 h1:oYW+YCJ1pachXTQmzR3rNLYGGz4g/UgFcjb28p/viDM= github.com/peterh/liner v1.1.1-0.20190123174540-a2c9a5303de7/go.mod h1:CRroGNssyjTd/qIG2FyxByd2S8JEAZXBl4qUrZf8GS0= github.com/pingcap/errors v0.11.4 h1:lFuQV/oaUMGcD2tqt+01ROSmJs75VG1ToEOkZIZ4nE4= @@ -682,7 +598,6 @@ github.com/prometheus/client_golang v0.8.0/go.mod h1:7SWBe2y4D6OKWSNQJUaRYU/AaXP github.com/prometheus/client_golang v1.17.0 h1:rl2sfwZMtSthVU752MqfjQozy7blglC+1SOtjMAMh+Q= github.com/prometheus/client_golang v1.17.0/go.mod h1:VeL+gMmOAxkS2IqfCq0ZmHSL+LjWfWDUmp1mBz9JgUY= github.com/prometheus/client_model v0.0.0-20180712105110-5c3871d89910/go.mod h1:MbSGuTsp3dbXC40dX6PRTWyKYBIrTGTE9sqQNg2J8bo= -github.com/prometheus/client_model v0.0.0-20190812154241-14fe0d1b01d4/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= github.com/prometheus/client_model v0.4.1-0.20230718164431-9a2bf3000d16 h1:v7DLqVdK4VrYkVD5diGdl4sxJurKJEMnODWRJlxV9oM= github.com/prometheus/client_model v0.4.1-0.20230718164431-9a2bf3000d16/go.mod h1:oMQmHW1/JoDwqLtg57MGgP/Fb1CJEYF2imWWhWtMkYU= github.com/prometheus/common v0.0.0-20180801064454-c7de2306084e/go.mod h1:daVV7qP5qjZbuso7PdcryaAu0sAZbrN9i7WWcTMWvro= @@ -693,12 +608,12 @@ github.com/prometheus/procfs v0.11.1 h1:xRC8Iq1yyca5ypa9n1EZnWZkt7dwcoRPQwX/5gwa github.com/prometheus/procfs v0.11.1/go.mod h1:eesXgaPo1q7lBpVMoMy0ZOFTth9hBn4W/y0/p/ScXhY= github.com/quic-go/qpack v0.4.0 h1:Cr9BXA1sQS2SmDUWjSofMPNKmvF6IiIfDRmgU0w1ZCo= github.com/quic-go/qpack v0.4.0/go.mod h1:UZVnYIfi5GRk+zI9UMaCPsmZ2xKJP7XBUvVyT1Knj9A= -github.com/quic-go/qtls-go1-20 v0.3.3 h1:17/glZSLI9P9fDAeyCHBFSWSqJcwx1byhLwP5eUIDCM= -github.com/quic-go/qtls-go1-20 v0.3.3/go.mod h1:X9Nh97ZL80Z+bX/gUXMbipO6OxdiDi58b/fMC9mAL+k= -github.com/quic-go/quic-go v0.38.1 h1:M36YWA5dEhEeT+slOu/SwMEucbYd0YFidxG3KlGPZaE= -github.com/quic-go/quic-go v0.38.1/go.mod h1:ijnZM7JsFIkp4cRyjxJNIzdSfCLmUMg9wdyhGmg+SN4= -github.com/quic-go/webtransport-go v0.5.3 h1:5XMlzemqB4qmOlgIus5zB45AcZ2kCgCy2EptUrfOPWU= -github.com/quic-go/webtransport-go v0.5.3/go.mod h1:OhmmgJIzTTqXK5xvtuX0oBpLV2GkLWNDA+UeTGJXErU= +github.com/quic-go/qtls-go1-20 v0.3.4 h1:MfFAPULvst4yoMgY9QmtpYmfij/em7O8UUi+bNVm7Cg= +github.com/quic-go/qtls-go1-20 v0.3.4/go.mod h1:X9Nh97ZL80Z+bX/gUXMbipO6OxdiDi58b/fMC9mAL+k= +github.com/quic-go/quic-go v0.39.3 h1:o3YB6t2SR+HU/pgwF29kJ6g4jJIJEwEZ8CKia1h1TKg= +github.com/quic-go/quic-go v0.39.3/go.mod h1:T09QsDQWjLiQ74ZmacDfqZmhY/NLnw5BC40MANNNZ1Q= +github.com/quic-go/webtransport-go v0.6.0 h1:CvNsKqc4W2HljHJnoT+rMmbRJybShZ0YPFDD3NxaZLY= +github.com/quic-go/webtransport-go v0.6.0/go.mod h1:9KjU4AEBqEQidGHNDkZrb8CAa1abRaosM2yGOyiikEc= github.com/raulk/go-watchdog v1.3.0 h1:oUmdlHxdkXRJlwfG0O9omj8ukerm8MEQavSiDTEtBsk= github.com/raulk/go-watchdog v1.3.0/go.mod h1:fIvOnLbF0b0ZwkB9YU4mOW9Did//4vPZtDqv66NfsMU= github.com/rivo/uniseg v0.2.0/go.mod h1:J6wj4VEh+S6ZtnVlnTBMWIodfgj8LQOQFoIToxlJtxc= @@ -706,7 +621,6 @@ github.com/rivo/uniseg v0.4.3 h1:utMvzDsuh3suAEnhH0RdHmoPbU648o6CvXxTx4SBMOw= github.com/rivo/uniseg v0.4.3/go.mod h1:FN3SvrM+Zdj16jyLfmOkMNblXMcoc8DfTHruCPUcx88= github.com/rogpeppe/go-internal v1.3.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFRclV5y23lUDJ4= github.com/rogpeppe/go-internal v1.6.1/go.mod h1:xXDCJY+GAPziupqXw64V24skbSoqbTEfhy4qGm1nDQc= -github.com/rogpeppe/go-internal v1.8.1/go.mod h1:JeRgkft04UBgHMgCIwADu4Pn6Mtm5d4nPKWu0nJ5d+o= github.com/rogpeppe/go-internal v1.9.0/go.mod h1:WtVeX8xhTBvf0smdhujwtBcq4Qrzq/fJaraNFVN+nFs= github.com/rogpeppe/go-internal v1.10.0 h1:TMyTOH3F/DB16zRVcYyreMH6GnZZrwQVAoYjRBZyWFQ= github.com/rogpeppe/go-internal v1.10.0/go.mod h1:UQnix2H7Ngw/k4C5ijL5+65zddjncjaFoBhdsK/akog= @@ -719,9 +633,7 @@ github.com/russross/blackfriday v1.5.2/go.mod h1:JO/DiYxRf+HjHt06OyowR9PTA263kcR github.com/russross/blackfriday/v2 v2.0.1/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= github.com/russross/blackfriday/v2 v2.1.0 h1:JIOH55/0cWyOuilr9/qlrm0BSXldqnqwMsf35Ld67mk= github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= -github.com/ryanuber/columnize v2.1.0+incompatible/go.mod h1:sm1tb6uqfes/u+d4ooFouqFdy9/2g9QGwK3SQygK0Ts= github.com/satori/go.uuid v1.2.0/go.mod h1:dA0hQrYB0VpLJoorglMZABFdXlWrHn1NEOzdhQKdks0= -github.com/schollz/closestmatch v2.1.0+incompatible/go.mod h1:RtP1ddjLong6gTkbtmuhtR2uUrrJOpYzYRvbcPAid+g= github.com/sergi/go-diff v1.0.0/go.mod h1:0CfEIISq7TuYL3j771MWULgwwjU+GofnZX9QAmXWZgo= github.com/shirou/gopsutil v3.21.11+incompatible h1:+1+c1VGhc88SSonWP6foOcLhvnKlUeu/erjjvaPEYiI= github.com/shirou/gopsutil v3.21.11+incompatible/go.mod h1:5b4v6he4MtMOwMlS0TUMTu2PcXUg8+E1lC7eC3UO/RA= @@ -753,18 +665,10 @@ github.com/shurcooL/webdavfs v0.0.0-20170829043945-18c3829fa133/go.mod h1:hKmq5k github.com/sirupsen/logrus v1.4.1/go.mod h1:ni0Sbl8bgC9z8RoU9G6nDWqqs/fq4eDPysMBDgk/93Q= github.com/sirupsen/logrus v1.4.2/go.mod h1:tLMulIdttU9McNUspp0xgXVQah82FyeX6MwdIuYE2rE= github.com/sirupsen/logrus v1.7.0/go.mod h1:yWOB1SBYBC5VeMP7gHvWumXLIWorT60ONWic61uBYv0= -github.com/smartystreets/assertions v0.0.0-20180927180507-b2de0cb4f26d/go.mod h1:OnSkiWE9lh6wB0YB77sQom3nweQdgAjqCqsofrRNTgc= -github.com/smartystreets/goconvey v1.6.4/go.mod h1:syvi0/a8iFYH4r/RixwvyeAJjdLS9QV7WQ/tjFTllLA= github.com/sourcegraph/annotate v0.0.0-20160123013949-f4cad6c6324d/go.mod h1:UdhH50NIW0fCiwBSr0co2m7BnFLdv4fQTgdqdJTHFeE= github.com/sourcegraph/syntaxhighlight v0.0.0-20170531221838-bd320f5d308e/go.mod h1:HuIsMU8RRBOtsCgI77wP899iHVBQpCmg4ErYMZB+2IA= github.com/spaolacci/murmur3 v1.1.0 h1:7c1g84S4BPRrfL5Xrdp6fOJ206sU9y293DDHaoy0bLI= github.com/spaolacci/murmur3 v1.1.0/go.mod h1:JwIasOWyU6f++ZhiEuf87xNszmSA2myDM2Kzu9HwQUA= -github.com/spf13/afero v1.1.2/go.mod h1:j4pytiNVoe2o6bmDsKpLACNPDBIoEAkihy7loJ1B0CQ= -github.com/spf13/cast v1.3.0/go.mod h1:Qx5cxh0v+4UWYiBimWS+eyWzqEqokIECu5etghLkUJE= -github.com/spf13/cobra v0.0.5/go.mod h1:3K3wKZymM7VvHMDS9+Akkh4K60UwM26emMESw8tLCHU= -github.com/spf13/jwalterweatherman v1.0.0/go.mod h1:cQK4TGJAtQXfYWX+Ddv3mKDzgVb68N+wFjFa4jdeBTo= -github.com/spf13/pflag v1.0.3/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4= -github.com/spf13/viper v1.3.2/go.mod h1:ZiWeW+zYFKm7srdB9IoDzzZXaJaI5eL9QjNiN/DMA2s= github.com/status-im/keycard-go v0.2.0 h1:QDLFswOQu1r5jsycloeQh3bVU8n/NatHHaZobtDnDzA= github.com/status-im/keycard-go v0.2.0/go.mod h1:wlp8ZLbsmrF6g6WjugPAx+IzoLrkdf9+mHxBEeo3Hbg= github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= @@ -796,31 +700,16 @@ github.com/tklauser/numcpus v0.6.1 h1:ng9scYS7az0Bk4OZLvrNXNSAO2Pxr1XXRAPyjhIx+F github.com/tklauser/numcpus v0.6.1/go.mod h1:1XfjsgE2zo8GVw7POkMbHENHzVg3GzmoZ9fESEdAacY= github.com/tyler-smith/go-bip39 v1.1.0 h1:5eUemwrMargf3BSLRRCalXT93Ns6pQJIjYQN2nyfOP8= github.com/tyler-smith/go-bip39 v1.1.0/go.mod h1:gUYDtqQw1JS3ZJ8UWVcGTGqqr6YIN3CWg+kkNaLt55U= -github.com/ugorji/go v1.1.4/go.mod h1:uQMGLiO92mf5W77hV/PUCpI3pbzQx3CRekS0kk+RGrc= -github.com/ugorji/go v1.1.7/go.mod h1:kZn38zHttfInRq0xu/PH0az30d+z6vm202qpg1oXVMw= -github.com/ugorji/go/codec v0.0.0-20181204163529-d75b2dcb6bc8/go.mod h1:VFNgLljTbGfSG7qAOspJ7OScBnGdDN/yBr0sguwnwf0= -github.com/ugorji/go/codec v1.1.7/go.mod h1:Ax+UKWsSmolVDwsd+7N3ZtXu+yMGCf907BLYF3GoBXY= github.com/urfave/cli v1.22.2/go.mod h1:Gos4lmkARVdJ6EkW0WaNv/tZAAMe9V7XWyB60NtXRu0= github.com/urfave/cli/v2 v2.25.7 h1:VAzn5oq403l5pHjc4OhD54+XGO9cdKVL/7lDjF+iKUs= github.com/urfave/cli/v2 v2.25.7/go.mod h1:8qnjx1vcq5s2/wpsqoZFndg2CE5tNFyrTvS6SinrnYQ= -github.com/urfave/negroni v1.0.0/go.mod h1:Meg73S6kFm/4PpbYdq35yYWoCZ9mS/YSx+lKnmiohz4= github.com/valyala/bytebufferpool v1.0.0/go.mod h1:6bBcMArwyJ5K/AmCkWv1jt77kVWyCJ6HpOuEn7z0Csc= -github.com/valyala/fasthttp v1.6.0/go.mod h1:FstJa9V+Pj9vQ7OJie2qMHdwemEDaDiSdBnvPM1Su9w= github.com/valyala/fasttemplate v1.0.1/go.mod h1:UQGH1tvbgY+Nz5t2n7tXsz52dQxojPUpymEIMZ47gx8= github.com/valyala/fasttemplate v1.2.1/go.mod h1:KHLXt3tVN2HBp8eijSv/kGJopbvo7S+qRAEEKiv+SiQ= -github.com/valyala/tcplisten v0.0.0-20161114210144-ceec8f93295a/go.mod h1:v3UYOV9WzVtRmSR+PDvWpU/qWl4Wa5LApYYX4ZtKbio= github.com/viant/assertly v0.4.8/go.mod h1:aGifi++jvCrUaklKEKT0BU95igDNaqkvz+49uaYMPRU= github.com/viant/toolbox v0.24.0/go.mod h1:OxMCG57V0PXuIP2HNQrtJf2CjqdmbrOx5EkMILuUhzM= -github.com/xeipuuv/gojsonpointer v0.0.0-20180127040702-4e3ac2762d5f/go.mod h1:N2zxlSyiKSe5eX1tZViRH5QA0qijqEDrYZiPEAiq3wU= -github.com/xeipuuv/gojsonreference v0.0.0-20180127040603-bd5ef7bd5415/go.mod h1:GwrjFmJcFw6At/Gs6z4yjiIwzuJ1/+UwLxMQDVQXShQ= -github.com/xeipuuv/gojsonschema v1.2.0/go.mod h1:anYRn/JVcOK2ZgGU+IjEV4nwlhoK5sQluxsYJ78Id3Y= -github.com/xordataexchange/crypt v0.0.3-0.20170626215501-b2862e3d0a77/go.mod h1:aYKd//L2LvnjZzWKhF00oedf4jCCReLcmhLdhm1A27Q= github.com/xrash/smetrics v0.0.0-20201216005158-039620a65673 h1:bAn7/zixMGCfxrRTfdpNzjtPYqr8smhKouy9mxVdGPU= github.com/xrash/smetrics v0.0.0-20201216005158-039620a65673/go.mod h1:N3UwUGtsrSj3ccvlPHLoLsHnpR27oXr4ZE984MbSER8= -github.com/yalp/jsonpath v0.0.0-20180802001716-5cc68e5049a0/go.mod h1:/LWChgwKmvncFJFHJ7Gvn9wZArjbV5/FppcK2fKk/tI= -github.com/yudai/gojsondiff v1.0.0/go.mod h1:AY32+k2cwILAkW1fbgxQ5mUmMiZFgLIV+FBNExI05xg= -github.com/yudai/golcs v0.0.0-20170316035057-ecda9a501e82/go.mod h1:lgjkn3NuSvDfVJdfcVVdX+jpBxNmX4rDAzaS45IcYoM= -github.com/yudai/pp v2.0.1+incompatible/go.mod h1:PuxR/8QJ7cyCkFp/aUDS+JY727OFEZkTdatxwunjIkc= github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.3.5/go.mod h1:mwnBkeHKe2W/ZEtQ+71ViKU8L12m81fl3OWwC1Zlc8k= @@ -838,13 +727,15 @@ go.uber.org/atomic v1.11.0 h1:ZvwS0R+56ePWxUNi+Atn9dWONBPp/AUETXlHW0DxSjE= go.uber.org/atomic v1.11.0/go.mod h1:LUxbIzbOniOlMKjJjyPfpl4v+PKK2cNJn91OQbhoJI0= go.uber.org/automaxprocs v1.5.2 h1:2LxUOGiR3O6tw8ui5sZa2LAaHnsviZdVOUZw4fvbnME= go.uber.org/automaxprocs v1.5.2/go.mod h1:eRbA25aqJrxAbsLO0xy5jVwPt7FQnRgjW+efnwa1WM0= -go.uber.org/dig v1.17.0 h1:5Chju+tUvcC+N7N6EV08BJz41UZuO3BmHcN4A287ZLI= -go.uber.org/dig v1.17.0/go.mod h1:rTxpf7l5I0eBTlE6/9RL+lDybC7WFwY2QH55ZSjy1mU= -go.uber.org/fx v1.20.0 h1:ZMC/pnRvhsthOZh9MZjMq5U8Or3mA9zBSPaLnzs3ihQ= -go.uber.org/fx v1.20.0/go.mod h1:qCUj0btiR3/JnanEr1TYEePfSw6o/4qYJscgvzQ5Ub0= +go.uber.org/dig v1.17.1 h1:Tga8Lz8PcYNsWsyHMZ1Vm0OQOUaJNDyvPImgbAu9YSc= +go.uber.org/dig v1.17.1/go.mod h1:Us0rSJiThwCv2GteUN0Q7OKvU7n5J4dxZ9JKUXozFdE= +go.uber.org/fx v1.20.1 h1:zVwVQGS8zYvhh9Xxcu4w1M6ESyeMzebzj2NbSayZ4Mk= +go.uber.org/fx v1.20.1/go.mod h1:iSYNbHf2y55acNCwCXKx7LbWb5WG1Bnue5RDXz1OREg= go.uber.org/goleak v1.1.11-0.20210813005559-691160354723/go.mod h1:cwTWslyiVhfpKIDGSZEM2HlOvcqm+tG4zioyIeLoqMQ= go.uber.org/goleak v1.2.0 h1:xqgm/S+aQvhWFTtR0XK3Jvg7z8kGV8P4X14IzwN3Eqk= go.uber.org/goleak v1.2.0/go.mod h1:XJYK+MuIchqpmGmUSAzotztawfKvYLUIgg7guXrwVUo= +go.uber.org/mock v0.3.0 h1:3mUxI1No2/60yUYax92Pt8eNOEecx2D3lcXZh2NEZJo= +go.uber.org/mock v0.3.0/go.mod h1:a6FSlNadKUHUa9IP5Vyt1zh4fC7uAwxMutEAscFbkZc= go.uber.org/multierr v1.1.0/go.mod h1:wR5kodmAFQ0UK8QlbwjlSNy0Z68gJhDJUG5sjR94q/0= go.uber.org/multierr v1.3.0/go.mod h1:VgVr7evmIr6uPjLBxg28wmKNXyqE9akIJ5XnfpiKl+4= go.uber.org/multierr v1.5.0/go.mod h1:FeouvMocqHpRaaGuG9EjoKcStLC43Zu/fmqdUMPcKYU= @@ -856,22 +747,19 @@ go.uber.org/zap v1.9.1/go.mod h1:vwi/ZaCAaUcBkycHslxD9B2zi4UTXhF60s6SWpuDF0Q= go.uber.org/zap v1.10.0/go.mod h1:vwi/ZaCAaUcBkycHslxD9B2zi4UTXhF60s6SWpuDF0Q= go.uber.org/zap v1.13.0/go.mod h1:zwrFLgMcdUuIBviXEYEH1YKNaOBnKXsx2IPda5bBwHM= go.uber.org/zap v1.19.1/go.mod h1:j3DNczoxDZroyBnOT1L/Q79cfUMGZxlv/9dzN7SM1rI= -go.uber.org/zap v1.25.0 h1:4Hvk6GtkucQ790dqmj7l1eEnRdKm3k3ZUrUMS2d5+5c= -go.uber.org/zap v1.25.0/go.mod h1:JIAUzQIH94IC4fOJQm7gMmBJP5k7wQfdcnYdPoEXJYk= +go.uber.org/zap v1.26.0 h1:sI7k6L95XOKS281NhVKOFCUNIvv9e0w4BF8N3u+tCRo= +go.uber.org/zap v1.26.0/go.mod h1:dtElttAiwGvoJ/vj4IwHBS/gXsEu/pZ50mUIRWuG0so= go4.org v0.0.0-20180809161055-417644f6feb5/go.mod h1:MkTOUMDaeVYJUOUsaDXIhWPZYa1yOyC1qaOBpL57BhE= golang.org/x/build v0.0.0-20190111050920-041ab4dc3f9d/go.mod h1:OWs+y06UdEOHN4y+MfF/py+xQ/tYqIWW03b70/CG9Rw= golang.org/x/crypto v0.0.0-20170930174604-9419663f5a44/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= golang.org/x/crypto v0.0.0-20181030102418-4d3f4d9ffa16/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= -golang.org/x/crypto v0.0.0-20181203042331-505ab145d0a9/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= golang.org/x/crypto v0.0.0-20190313024323-a1f597ede03a/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= golang.org/x/crypto v0.0.0-20190411191339-88737f569e3a/go.mod h1:WFFai1msRO1wXaEeE5yQxYXgSfI8pQAWXbQop6sCtWE= golang.org/x/crypto v0.0.0-20190510104115-cbcb75029529/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20190611184440-5c40567a22f8/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= -golang.org/x/crypto v0.0.0-20190701094942-4def268fd1a4/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20190820162420-60c769a6c586/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= -golang.org/x/crypto v0.0.0-20191227163750-53104e6ec876/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20200602180216-279210d13fed/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20200820211705-5c72a883971a/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= @@ -881,44 +769,37 @@ golang.org/x/crypto v0.0.0-20210322153248-0c34fe9e7dc2/go.mod h1:T9bdIzuCu7OtxOm golang.org/x/crypto v0.0.0-20210616213533-5ff15b29337e/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= golang.org/x/crypto v0.0.0-20210711020723-a769d52b0f97/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= -golang.org/x/crypto v0.14.0 h1:wBqGXzWJW6m1XrIKlAH0Hs1JJ7+9KBwnIO8v66Q9cHc= -golang.org/x/crypto v0.14.0/go.mod h1:MVFd36DqK4CsrnJYDkBA3VC4m2GkXAM0PvzMCn4JQf4= +golang.org/x/crypto v0.15.0 h1:frVn1TEaCEaZcn3Tmd7Y2b5KKPaZ+I32Q2OA3kYp5TA= +golang.org/x/crypto v0.15.0/go.mod h1:4ChreQoLWfG3xLDer1WdlH5NdlQ3+mwnQq1YTKY+72g= golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= -golang.org/x/exp v0.0.0-20230905200255-921286631fa9 h1:GoHiUyI/Tp2nVkLI2mCxVkOjsbSXD66ic0XW0js0R9g= -golang.org/x/exp v0.0.0-20230905200255-921286631fa9/go.mod h1:S2oDrQGGwySpoQPVqRShND87VCbxmc6bL1Yd2oYrm6k= +golang.org/x/exp v0.0.0-20231006140011-7918f672742d h1:jtJma62tbqLibJ5sFQz8bKtEM8rJBtfilJ2qTU199MI= +golang.org/x/exp v0.0.0-20231006140011-7918f672742d/go.mod h1:ldy0pHrwJyGW56pPQzzkH36rKxoZW1tw7ZJpeKx+hdo= golang.org/x/lint v0.0.0-20180702182130-06c8688daad7/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE= golang.org/x/lint v0.0.0-20181026193005-c67002cb31c3/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE= golang.org/x/lint v0.0.0-20190227174305-5b3e6a55c961/go.mod h1:wehouNa3lNwaWXcvxsM5YxQ5yQlVC4a0KAMCusXpPoU= -golang.org/x/lint v0.0.0-20190313153728-d0100b6bd8b3/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc= golang.org/x/lint v0.0.0-20190930215403-16217165b5de/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc= golang.org/x/lint v0.0.0-20200302205851-738671d3881b/go.mod h1:3xt1FjdF8hUf6vQPIChWIBhFzV8gjjsPE/fR3IyQdNY= -golang.org/x/lint v0.0.0-20210508222113-6edffad5e616/go.mod h1:3xt1FjdF8hUf6vQPIChWIBhFzV8gjjsPE/fR3IyQdNY= golang.org/x/mod v0.0.0-20190513183733-4bf6d317e70e/go.mod h1:mXi4GBBbnImb6dmsKGUJ2LatrhH/nqhxcFungHvyanc= golang.org/x/mod v0.1.1-0.20191105210325-c90efee705ee/go.mod h1:QqPTAvyqsEbceGzBzNggFXnrqF1CaUcvgkdR5Ot7KZg= golang.org/x/mod v0.2.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.4.2/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.6.0-dev.0.20220419223038-86c51ed26bb4/go.mod h1:jJ57K6gSWd91VN4djpZkiMVwK6gcyfeH4XE8wZrZaV4= -golang.org/x/mod v0.12.0 h1:rmsUpXtvNzj340zd98LZ4KntptpfRHwpFOHG188oHXc= -golang.org/x/mod v0.12.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs= +golang.org/x/mod v0.13.0 h1:I/DsJXRlw/8l/0c24sM9yb0T4z9liZTduXvdAWYiysY= +golang.org/x/mod v0.13.0/go.mod h1:hTbmBsO62+eylJbnUtE2MGJUyE7QWk4xUqPFrRgJ+7c= golang.org/x/net v0.0.0-20180719180050-a680a1efc54d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20180724234803-3673e40ba225/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20180826012351-8a410e7b638d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20180906233101-161cd47e91fd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20181029044818-c44066c5c816/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20181106065722-10aee1819953/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= -golang.org/x/net v0.0.0-20181220203305-927f97764cc3/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20190108225652-1e06a53dbb7e/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20190213061140-3a22650c66bd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20190311183353-d8887717615a/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20190313220215-9f648a60d977/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= -golang.org/x/net v0.0.0-20190327091125-710a502c58a2/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= -golang.org/x/net v0.0.0-20190503192946-f4e77d36d62c/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20190813141303-74dc4d7220e7/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= -golang.org/x/net v0.0.0-20190827160401-ba9fcec4b297/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= -golang.org/x/net v0.0.0-20191209160850-c0dbc17a3553/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20200226121028-0de0cce0169b/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20200520004742-59133d7f0dd7/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A= golang.org/x/net v0.0.0-20200813134508-3edf25e44fcc/go.mod h1:/O7V0waA8r7cgGh81Ro3o1hOxt32SMVPicZroKQ2sZA= @@ -928,7 +809,6 @@ golang.org/x/net v0.0.0-20210119194325-5f4716e94777/go.mod h1:m0MpNAwzfU5UDzcl9v golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= golang.org/x/net v0.0.0-20210405180319-a5a99cb37ef4/go.mod h1:p54w0d4576C0XHj96bSt6lcn1PtDYWL6XObtHCRCNQM= golang.org/x/net v0.0.0-20210428140749-89ef3d95e781/go.mod h1:OJAsFXCWl8Ukc7SiCT/9KSuxbyM7479/AVlXFRxuMCk= -golang.org/x/net v0.0.0-20211008194852-3b03d305991f/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= golang.org/x/net v0.0.0-20220225172249-27dd8689420f/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= golang.org/x/net v0.0.0-20220607020251-c690dde0001d/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c= golang.org/x/net v0.0.0-20220722155237-a158d28d115b/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c= @@ -949,21 +829,19 @@ golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJ golang.org/x/sync v0.0.0-20210220032951-036812b2e83c/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.1.0/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.4.0 h1:zxkM55ReGkDlKSM+Fu41A+zmbZuaPVbGMzvvdUPznYQ= -golang.org/x/sync v0.4.0/go.mod h1:FU7BRWz2tNW+3quACPkgCx/L+uEAv1htQ0V83Z9Rj+Y= +golang.org/x/sync v0.5.0 h1:60k92dhOjHxJkrqnwsfl8KuaHbn/5dl0lUPUklKo3qE= +golang.org/x/sync v0.5.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= golang.org/x/sys v0.0.0-20180810173357-98c5dad5d1a0/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180905080454-ebe1bf3edb33/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180909124046-d0be0721c37e/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20181029174526-d69651ed3497/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20181205085412-a5c9d58dba9a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190222072716-a9d3bda3a223/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190316082340-a2f829d7f35f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190403152447-81d4e9dc473e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190422165155-953cdadca894/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20190626221950-04f50cda93cb/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190813064441-fde4db37ae7a/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190904154756-749cb33beabd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190916202348-b4ddaad3f8a3/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -985,34 +863,29 @@ golang.org/x/sys v0.0.0-20210112080510-489259a85091/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20210124154548-22da62e12c0c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210303074136-134d130e1a04/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210330210617-4fbd30eecc44/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210403161142-5e06dd20ab57/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210423082822-04245dca01da/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210510120138-977fb7262007/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20210927094055-39ccf1dd6fa6/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20211007075335-d3039528d8ac/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20211020174200-9d6173849985/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20211216021012-1d35b9e2eb4e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20220209214540-3681064d5158/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220310020820-b874c991c1a5/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20220405052023-b1e9470b6e64/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220412211240-33da011f77ad/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20220908164124-27713097b956/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.5.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= 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.13.0 h1:Af8nKPmuFypiUBjVoU9V20FiaFXOcuZI21p0ycVYYGE= -golang.org/x/sys v0.13.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.14.0 h1:Vz7Qs629MkJkGyHxUlRHizWJRG2j8fbQKjELVSNhy7Q= +golang.org/x/sys v0.14.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/term v0.0.0-20201117132131-f5c789dd3221/go.mod h1:Nr5EML6q2oocZ2LXRh80K7BxOlk5/8JxuGnuhpl+muw= 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.13.0 h1:bb+I9cTfFazGW51MZqBVmZy7+JEJMouUHTUSKVQLBek= -golang.org/x/term v0.13.0/go.mod h1:LTmsnFJwVN6bCy1rVCoS+qHT1HhALEFxKncY3WNNh4U= +golang.org/x/term v0.14.0 h1:LGK9IlZ8T9jvdy6cTdfKUCltatMFOehAQo9SRC46UQ8= +golang.org/x/term v0.14.0/go.mod h1:TySc+nGkYR6qt8km8wUhuFRTVSMIX3XPR58y2lC8vww= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.1-0.20180807135948-17ff2d5776d2/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= @@ -1022,26 +895,22 @@ golang.org/x/text v0.3.5/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.7/go.mod h1:u+2+/6zg+i71rQMx5EYifcz6MCKuco9NR6JIITiCfzQ= golang.org/x/text v0.3.8/go.mod h1:E6s5w1FMmriuDzIBO73fBruAKo1PCIq6d2Q6DHfQ8WQ= -golang.org/x/text v0.13.0 h1:ablQoSUd0tRdKxZewP80B+BaqeKJuVhuRxj/dkrun3k= -golang.org/x/text v0.13.0/go.mod h1:TvPlkZtksWOMsz7fbANvkp4WM8x/WCo/om8BMLbz+aE= +golang.org/x/text v0.14.0 h1:ScX5w1eTa3QqT8oi6+ziP7dTV1S2+ALU0bI+0zXKWiQ= +golang.org/x/text v0.14.0/go.mod h1:18ZOQIKpY8NJVqYksKHtTdi31H5itFRjB5/qKTNYzSU= golang.org/x/time v0.0.0-20180412165947-fbb02b2291d2/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20181108054448-85acf8d2951c/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20201208040808-7e3f01d25324/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20210220033141-f8bda1e9f3ba/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= -golang.org/x/time v0.3.0 h1:rg5rLMjNzMS1RkNLzCG38eapWhnYLFYXDXj2gOlr8j4= -golang.org/x/time v0.3.0/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= +golang.org/x/time v0.4.0 h1:Z81tqI5ddIoXDPvVQ7/7CC9TnLM7ubaFG2qXYd5BbYY= +golang.org/x/time v0.4.0/go.mod h1:3BpzKBy/shNhVucY/MWOyx10tF3SFh9QdLuxbVysPQM= golang.org/x/tools v0.0.0-20180828015842-6cd1fcedba52/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20181030000716-a0a13e073c7b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20181030221726-6c7e314b6563/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= -golang.org/x/tools v0.0.0-20181221001348-537d06c36207/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20190114222345-bf090417da8b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20190226205152-f727befe758c/go.mod h1:9Yl7xja0Znq3iFh3HoIrodX9oNMXvdceNzlUR8zjMvY= golang.org/x/tools v0.0.0-20190311212946-11955173bddd/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= -golang.org/x/tools v0.0.0-20190327201419-c70d86f8b7cf/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= -golang.org/x/tools v0.0.0-20190328211700-ab21143f2384/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= golang.org/x/tools v0.0.0-20190425163242-31fd60d6bfdc/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q= -golang.org/x/tools v0.0.0-20190524140312-2c0ae7006135/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q= golang.org/x/tools v0.0.0-20190621195816-6e04913cbbac/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= golang.org/x/tools v0.0.0-20190823170909-c4a336ef6a2f/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20191029041327-9cc4af7d6b2c/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= @@ -1053,12 +922,10 @@ golang.org/x/tools v0.0.0-20200130002326-2f3ba24bd6e7/go.mod h1:TB2adYChydJhpapK golang.org/x/tools v0.0.0-20200619180055-7c47624df98f/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE= golang.org/x/tools v0.0.0-20201224043029-2b0845dc783e/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= golang.org/x/tools v0.0.0-20210106214847-113979e3529a/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= -golang.org/x/tools v0.1.1/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= -golang.org/x/tools v0.1.3/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= golang.org/x/tools v0.1.5/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= golang.org/x/tools v0.1.12/go.mod h1:hNGJHUnrk76NpqgfD5Aqm5Crs+Hm0VOH/i9J2+nxYbc= -golang.org/x/tools v0.13.0 h1:Iey4qkscZuv0VvIt8E0neZjtPVQFSc870HQ448QgEmQ= -golang.org/x/tools v0.13.0/go.mod h1:HvlwmtVNQAhOuCjW7xxvovg8wbNq7LwfXh/k7wXUl58= +golang.org/x/tools v0.14.0 h1:jvNa2pY0M4r62jkRQ6RwEZZyPcymeL9XZMLBbV7U2nc= +golang.org/x/tools v0.14.0/go.mod h1:uYBEerGOWcJyEORxN+Ek8+TT266gXkNlHdJBwexUsBg= golang.org/x/xerrors v0.0.0-20190410155217-1f06c39b4373/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20190513163551-3ee3066db522/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= @@ -1073,33 +940,21 @@ google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9Ywl google.golang.org/appengine v1.2.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= google.golang.org/appengine v1.3.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= -google.golang.org/genproto v0.0.0-20180518175338-11a468237815/go.mod h1:JiN7NxoALGmiZfu7CAH4rXhgtRTLTxftemlI0sWmxmc= google.golang.org/genproto v0.0.0-20180817151627-c66870c02cf8/go.mod h1:JiN7NxoALGmiZfu7CAH4rXhgtRTLTxftemlI0sWmxmc= google.golang.org/genproto v0.0.0-20180831171423-11092d34479b/go.mod h1:JiN7NxoALGmiZfu7CAH4rXhgtRTLTxftemlI0sWmxmc= google.golang.org/genproto v0.0.0-20181029155118-b69ba1387ce2/go.mod h1:JiN7NxoALGmiZfu7CAH4rXhgtRTLTxftemlI0sWmxmc= google.golang.org/genproto v0.0.0-20181202183823-bd91e49a0898/go.mod h1:7Ep/1NZk928CDR8SjdVbjWNpdIf6nzjE3BTgJDr2Atg= google.golang.org/genproto v0.0.0-20190306203927-b5d61aea6440/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE= -google.golang.org/genproto v0.0.0-20190819201941-24fa4b261c55/go.mod h1:DMBHOl98Agz4BDEuKkezgsaosCRResVns1a3J2ZsMNc= -google.golang.org/genproto v0.0.0-20200526211855-cb27e3aa2013/go.mod h1:NbSheEEYHJ7i3ixzK3sjbqSGDJWnxyFXZblF3eUsNvo= -google.golang.org/genproto v0.0.0-20210624195500-8bfb893ecb84/go.mod h1:SzzZ/N+nwJDaO1kznhnlzqS8ocJICar6hYhVyhi++24= -google.golang.org/grpc v1.12.0/go.mod h1:yo6s7OP7yaDglbqo1J04qKzAhqBH6lvTonzMVmEdcZw= google.golang.org/grpc v1.14.0/go.mod h1:yo6s7OP7yaDglbqo1J04qKzAhqBH6lvTonzMVmEdcZw= google.golang.org/grpc v1.16.0/go.mod h1:0JHn/cJsOMiMfNA9+DeHDlAU7KAAB5GDlYFpa9MZMio= google.golang.org/grpc v1.17.0/go.mod h1:6QZJwpn2B+Zp71q/5VxRsJ6NXXVCE5NRUHRo+f3cWCs= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= -google.golang.org/grpc v1.23.0/go.mod h1:Y5yQAOtifL1yxbo5wqy6BxZv8vAUGQwXBOALyacEbxg= -google.golang.org/grpc v1.25.1/go.mod h1:c3i+UQWmh7LiEpx4sFZnkU36qjEYZ0imhYfXVyQciAY= -google.golang.org/grpc v1.27.0/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8abTk= -google.golang.org/grpc v1.38.0/go.mod h1:NREThFqKR1f3iQ6oBuvc5LadQuXVGo9rkm5ZGrQdJfM= google.golang.org/protobuf v0.0.0-20200109180630-ec00e32a8dfd/go.mod h1:DFci5gLYBciE7Vtevhsrf46CRTquxDuWsQurQQe4oz8= google.golang.org/protobuf v0.0.0-20200221191635-4d8936d0db64/go.mod h1:kwYJMbMJ01Woi6D6+Kah6886xMZcty6N08ah7+eCXa0= google.golang.org/protobuf v0.0.0-20200228230310-ab0ca4ff8a60/go.mod h1:cfTl7dwQJ+fmap5saPgwCLgHXTUD7jkjRqWcaiX5VyM= google.golang.org/protobuf v1.20.1-0.20200309200217-e05f789c0967/go.mod h1:A+miEFZTKqfCUM6K7xSMQL9OKL/b6hQv+e19PK+JZNE= google.golang.org/protobuf v1.21.0/go.mod h1:47Nbq4nVaFHyn7ilMalzfO3qCViNmqZ2kzikPIcrTAo= -google.golang.org/protobuf v1.22.0/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU= google.golang.org/protobuf v1.23.0/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU= -google.golang.org/protobuf v1.23.1-0.20200526195155-81db48ad09cc/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU= -google.golang.org/protobuf v1.25.0/go.mod h1:9JNX74DMeImyA3h4bdi1ymwjUzf21/xIlbajtzgsN7c= 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.31.0 h1:g0LDEJHgrBl9N9r17Ru3sqWhkIx2NB67okBHPwC7hs8= @@ -1111,12 +966,8 @@ gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntN gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q= gopkg.in/errgo.v2 v2.1.0/go.mod h1:hNsd1EY+bozCKY1Ytp96fpM3vjJbqLJn88ws8XvfDNI= gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMys= -gopkg.in/go-playground/assert.v1 v1.2.1/go.mod h1:9RXL0bg/zibRAgZUYszZSwO/z8Y/a8bDuhia5mkpMnE= -gopkg.in/go-playground/validator.v8 v8.18.2/go.mod h1:RX2a/7Ha8BgOhfk7j780h4/u/RRjR0eouCJSH80/M2Y= gopkg.in/inconshreveable/log15.v2 v2.0.0-20180818164646-67afb5ed74ec/go.mod h1:aPpfJ7XW+gOuirDoZ8gHhLh3kZ1B08FtV2bbmy7Jv3s= gopkg.in/inf.v0 v0.9.1/go.mod h1:cWUDdTG/fYaXco+Dcufb5Vnc6Gp2YChqWtbxRZE0mXw= -gopkg.in/ini.v1 v1.51.1/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k= -gopkg.in/mgo.v2 v2.0.0-20180705113604-9856a29383ce/go.mod h1:yeKp02qBN3iKW1OzL3MGk2IdtZzaj7SFntXj72NppTA= gopkg.in/natefinch/lumberjack.v2 v2.0.0 h1:1Lc07Kr7qY4U2YPouBjpCLxpiyxIVoxqXgkXLknAOE8= gopkg.in/natefinch/lumberjack.v2 v2.0.0/go.mod h1:l0ndWWf7gzL7RNwBG7wST/UCcT4T24xpD6X8LsfU/+k= gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 h1:uRGJdciOHaEIrze2W8Q3AKkepLTh2hOroT7a+7czfdQ= @@ -1128,20 +979,18 @@ gopkg.in/yaml.v2 v2.2.8/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.3.0/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.4.0 h1:D8xgwECY7CYvx+Y2n4sBz93Jn9JRvxdiyyo8CTfuKaY= gopkg.in/yaml.v2 v2.4.0/go.mod h1:RDklbk79AGWmwhnvt/jBztapEOGDOx6ZbXqjP6csGnQ= -gopkg.in/yaml.v3 v3.0.0-20191120175047-4206685974f2/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= -gorm.io/driver/postgres v1.5.3 h1:qKGY5CPHOuj47K/VxbCXJfFvIUeqMSXXadqdCY+MbBU= -gorm.io/driver/postgres v1.5.3/go.mod h1:F+LtvlFhZT7UBiA81mC9W6Su3D4WUhSboc/36QZU0gk= +gorm.io/driver/postgres v1.5.4 h1:Iyrp9Meh3GmbSuyIAGyjkN+n9K+GHX9b9MqsTL4EJCo= +gorm.io/driver/postgres v1.5.4/go.mod h1:Bgo89+h0CRcdA33Y6frlaHHVuTdOf87pmyzwW9C/BH0= gorm.io/gorm v1.25.5 h1:zR9lOiiYf09VNh5Q1gphfyia1JpiClIWG9hQaxB/mls= gorm.io/gorm v1.25.5/go.mod h1:hbnx/Oo0ChWMn1BIhpy1oYozzpM15i4YPuHDmfYtwg8= grpc.go4.org v0.0.0-20170609214715-11d0a25b4919/go.mod h1:77eQGdRu53HpSqPFJFmuJdjuHRquDANNeA4x7B8WQ9o= honnef.co/go/tools v0.0.0-20180728063816-88497007e858/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= honnef.co/go/tools v0.0.0-20190102054323-c2f93a96b099/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= honnef.co/go/tools v0.0.0-20190106161140-3f1c8253044a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= -honnef.co/go/tools v0.0.0-20190523083050-ea95bdfd59fc/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= honnef.co/go/tools v0.0.1-2019.2.3/go.mod h1:a3bituU0lyd329TUQxRnasdCoJDkEUEAqEt0JzvZhAg= lukechampine.com/blake3 v1.2.1 h1:YuqqRuaqsGV71BV/nm9xlI0MKUv4QC54jQnBChWbGnI= lukechampine.com/blake3 v1.2.1/go.mod h1:0OFRp7fBtAylGVCO40o87sbupkyIGgbpv1+M1k1LM6k= diff --git a/indexer/api-ts/generated.ts b/indexer/api-ts/generated.ts index 9b19bb6da987c..7f9473cc55346 100644 --- a/indexer/api-ts/generated.ts +++ b/indexer/api-ts/generated.ts @@ -34,12 +34,12 @@ export interface WithdrawalItem { from: string; to: string; transactionHash: string; - messageHash: string; + crossDomainMessageHash: string; timestamp: number /* uint64 */; l2BlockHash: string; amount: string; - proofTransactionHash: string; - claimTransactionHash: string; + l1ProvenTxHash: string; + l1FinalizedTxHash: string; l1TokenAddress: string; l2TokenAddress: string; } @@ -51,3 +51,7 @@ export interface WithdrawalResponse { hasNextPage: boolean; items: WithdrawalItem[]; } +export interface BridgeSupplyView { + l1DepositSum: number /* float64 */; + l2WithdrawalSum: number /* float64 */; +} diff --git a/indexer/api/api.go b/indexer/api/api.go index 37a572515e266..cee6667618193 100644 --- a/indexer/api/api.go +++ b/indexer/api/api.go @@ -6,33 +6,25 @@ import ( "fmt" "net" "net/http" - "runtime/debug" "strconv" - "sync" + "sync/atomic" + "time" + + "github.com/go-chi/chi/v5" + "github.com/go-chi/chi/v5/middleware" + "github.com/prometheus/client_golang/prometheus" + + "github.com/ethereum/go-ethereum/log" "github.com/ethereum-optimism/optimism/indexer/api/routes" "github.com/ethereum-optimism/optimism/indexer/config" "github.com/ethereum-optimism/optimism/indexer/database" "github.com/ethereum-optimism/optimism/op-service/httputil" "github.com/ethereum-optimism/optimism/op-service/metrics" - "github.com/ethereum/go-ethereum/log" - "github.com/go-chi/chi/v5" - "github.com/go-chi/chi/v5/middleware" - "github.com/prometheus/client_golang/prometheus" ) const ethereumAddressRegex = `^0x[a-fA-F0-9]{40}$` -// Api ... Indexer API struct -// TODO : Structured error responses -type API struct { - log log.Logger - router *chi.Mux - serverConfig config.ServerConfig - metricsConfig config.ServerConfig - metricsRegistry *prometheus.Registry -} - const ( MetricsNamespace = "op_indexer_api" addressParam = "{address:%s}" @@ -43,8 +35,27 @@ const ( HealthPath = "/healthz" DepositsPath = "/api/v0/deposits/" WithdrawalsPath = "/api/v0/withdrawals/" + + SupplyPath = "/api/v0/supply" ) +// Api ... Indexer API struct +// TODO : Structured error responses +type APIService struct { + log log.Logger + router *chi.Mux + + bv database.BridgeTransfersView + dbClose func() error + + metricsRegistry *prometheus.Registry + + apiServer *httputil.HTTPServer + metricsServer *httputil.HTTPServer + + stopped atomic.Bool +} + // chiMetricsMiddleware ... Injects a metrics recorder into request processing middleware func chiMetricsMiddleware(rec metrics.HTTPRecorder) func(http.Handler) http.Handler { return func(next http.Handler) http.Handler { @@ -53,112 +64,116 @@ func chiMetricsMiddleware(rec metrics.HTTPRecorder) func(http.Handler) http.Hand } // NewApi ... Construct a new api instance -func NewApi(logger log.Logger, bv database.BridgeTransfersView, serverConfig config.ServerConfig, metricsConfig config.ServerConfig) *API { - // (1) Initialize dependencies - apiRouter := chi.NewRouter() - h := routes.NewRoutes(logger, bv, apiRouter) - - mr := metrics.NewRegistry() - promRecorder := metrics.NewPromHTTPRecorder(mr, MetricsNamespace) - - // (2) Inject routing middleware - apiRouter.Use(chiMetricsMiddleware(promRecorder)) - apiRouter.Use(middleware.Recoverer) - apiRouter.Use(middleware.Heartbeat(HealthPath)) +func NewApi(ctx context.Context, log log.Logger, cfg *Config) (*APIService, error) { + out := &APIService{log: log, metricsRegistry: metrics.NewRegistry()} + if err := out.initFromConfig(ctx, cfg); err != nil { + return nil, errors.Join(err, out.Stop(ctx)) // close any resources we may have opened already + } + return out, nil +} - // (3) Set GET routes - apiRouter.Get(fmt.Sprintf(DepositsPath+addressParam, ethereumAddressRegex), h.L1DepositsHandler) - apiRouter.Get(fmt.Sprintf(WithdrawalsPath+addressParam, ethereumAddressRegex), h.L2WithdrawalsHandler) +func (a *APIService) initFromConfig(ctx context.Context, cfg *Config) error { + if err := a.initDB(ctx, cfg.DB); err != nil { + return fmt.Errorf("failed to init DB: %w", err) + } + if err := a.startMetricsServer(cfg.MetricsServer); err != nil { + return fmt.Errorf("failed to start metrics server: %w", err) + } + a.initRouter(cfg.HTTPServer) + if err := a.startServer(cfg.HTTPServer); err != nil { + return fmt.Errorf("failed to start API server: %w", err) + } + return nil +} - return &API{log: logger, router: apiRouter, metricsRegistry: mr, serverConfig: serverConfig, metricsConfig: metricsConfig} +func (a *APIService) Start(ctx context.Context) error { + // Completed all setup-up jobs at init-time already, + // and the API service does not have any other special starting routines or background-jobs to start. + return nil } -// Run ... Runs the API server routines -func (a *API) Run(ctx context.Context) error { - var wg sync.WaitGroup - errCh := make(chan error, 2) - - // (1) Construct an inner function that will start a goroutine - // and handle any panics that occur on a shared error channel - processCtx, processCancel := context.WithCancel(ctx) - runProcess := func(start func(ctx context.Context) error) { - wg.Add(1) - go func() { - defer func() { - if err := recover(); err != nil { - a.log.Error("halting api on panic", "err", err) - debug.PrintStack() - errCh <- fmt.Errorf("panic: %v", err) - } - - processCancel() - wg.Done() - }() - - errCh <- start(processCtx) - }() +func (a *APIService) Stop(ctx context.Context) error { + var result error + if a.apiServer != nil { + if err := a.apiServer.Stop(ctx); err != nil { + result = errors.Join(result, fmt.Errorf("failed to stop API server: %w", err)) + } + } + if a.metricsServer != nil { + if err := a.metricsServer.Stop(ctx); err != nil { + result = errors.Join(result, fmt.Errorf("failed to stop metrics server: %w", err)) + } } + if a.dbClose != nil { + if err := a.dbClose(); err != nil { + result = errors.Join(result, fmt.Errorf("failed to close DB: %w", err)) + } + } + a.stopped.Store(true) + a.log.Info("API service shutdown complete") + return result +} - // (2) Start the API and metrics servers - runProcess(a.startServer) - runProcess(a.startMetricsServer) +func (a *APIService) Stopped() bool { + return a.stopped.Load() +} - // (3) Wait for all processes to complete - wg.Wait() +// Addr ... returns the address that the HTTP server is listening on (excl. http:// prefix, just the host and port) +func (a *APIService) Addr() string { + if a.apiServer == nil { + return "" + } + return a.apiServer.Addr().String() +} - err := <-errCh +func (a *APIService) initDB(ctx context.Context, connector DBConnector) error { + db, err := connector.OpenDB(ctx, a.log) if err != nil { - a.log.Error("api stopped", "err", err) - } else { - a.log.Info("api stopped") + return fmt.Errorf("failed to connect to databse: %w", err) } - - return err + a.dbClose = db.Closer + a.bv = db.BridgeTransfers + return nil } -// Port ... Returns the the port that server is listening on -func (a *API) Port() int { - return a.serverConfig.Port +func (a *APIService) initRouter(apiConfig config.ServerConfig) { + apiRouter := chi.NewRouter() + h := routes.NewRoutes(a.log, a.bv, apiRouter) + + promRecorder := metrics.NewPromHTTPRecorder(a.metricsRegistry, MetricsNamespace) + + apiRouter.Use(chiMetricsMiddleware(promRecorder)) + apiRouter.Use(middleware.Timeout(time.Duration(apiConfig.WriteTimeout) * time.Second)) + apiRouter.Use(middleware.Recoverer) + apiRouter.Use(middleware.Heartbeat(HealthPath)) + + apiRouter.Get(fmt.Sprintf(DepositsPath+addressParam, ethereumAddressRegex), h.L1DepositsHandler) + apiRouter.Get(fmt.Sprintf(WithdrawalsPath+addressParam, ethereumAddressRegex), h.L2WithdrawalsHandler) + apiRouter.Get(SupplyPath, h.SupplyView) + a.router = apiRouter } // startServer ... Starts the API server -func (a *API) startServer(ctx context.Context) error { - a.log.Debug("api server listening...", "port", a.serverConfig.Port) - addr := net.JoinHostPort(a.serverConfig.Host, strconv.Itoa(a.serverConfig.Port)) +func (a *APIService) startServer(serverConfig config.ServerConfig) error { + a.log.Debug("API server listening...", "port", serverConfig.Port) + addr := net.JoinHostPort(serverConfig.Host, strconv.Itoa(serverConfig.Port)) srv, err := httputil.StartHTTPServer(addr, a.router) if err != nil { return fmt.Errorf("failed to start API server: %w", err) } - - host, portStr, err := net.SplitHostPort(srv.Addr().String()) - if err != nil { - return errors.Join(err, srv.Close()) - } - port, err := strconv.Atoi(portStr) - if err != nil { - return errors.Join(err, srv.Close()) - } - - // Update the port in the config in case the OS chose a different port - // than the one we requested (e.g. using port 0 to fetch a random open port) - a.serverConfig.Host = host - a.serverConfig.Port = port - - <-ctx.Done() - if err := srv.Stop(context.Background()); err != nil { - return fmt.Errorf("failed to shutdown api server: %w", err) - } + a.log.Info("API server started", "addr", srv.Addr().String()) + a.apiServer = srv return nil } // startMetricsServer ... Starts the metrics server -func (a *API) startMetricsServer(ctx context.Context) error { - a.log.Debug("starting metrics server...", "port", a.metricsConfig.Port) - srv, err := metrics.StartServer(a.metricsRegistry, a.metricsConfig.Host, a.metricsConfig.Port) +func (a *APIService) startMetricsServer(metricsConfig config.ServerConfig) error { + a.log.Debug("starting metrics server...", "port", metricsConfig.Port) + srv, err := metrics.StartServer(a.metricsRegistry, metricsConfig.Host, metricsConfig.Port) if err != nil { return fmt.Errorf("failed to start metrics server: %w", err) } - <-ctx.Done() - defer a.log.Info("metrics server stopped") - return srv.Stop(context.Background()) + a.log.Info("Metrics server started", "addr", srv.Addr().String()) + a.metricsServer = srv + return nil } diff --git a/indexer/api/api_test.go b/indexer/api/api_test.go index 554fce28ce51b..4bfbc38907afd 100644 --- a/indexer/api/api_test.go +++ b/indexer/api/api_test.go @@ -1,6 +1,7 @@ package api import ( + "context" "encoding/json" "fmt" "net/http" @@ -24,11 +25,12 @@ var mockAddress = "0x4204204204204204204204204204204204204204" var apiConfig = config.ServerConfig{ Host: "localhost", - Port: 8080, + Port: 0, // random port, to allow parallel tests } + var metricsConfig = config.ServerConfig{ Host: "localhost", - Port: 7300, + Port: 0, // random port, to allow parallel tests } var ( @@ -93,10 +95,24 @@ func (mbv *MockBridgeTransfersView) L2BridgeWithdrawalsByAddress(address common. }, }, nil } + +func (mbv *MockBridgeTransfersView) L1BridgeDepositSum() (float64, error) { + return 69, nil +} +func (mbv *MockBridgeTransfersView) L2BridgeWithdrawalSum() (float64, error) { + return 420, nil +} + func TestHealthz(t *testing.T) { logger := testlog.Logger(t, log.LvlInfo) - api := NewApi(logger, &MockBridgeTransfersView{}, apiConfig, metricsConfig) - request, err := http.NewRequest("GET", "/healthz", nil) + cfg := &Config{ + DB: &TestDBConnector{BridgeTransfers: &MockBridgeTransfersView{}}, + HTTPServer: apiConfig, + MetricsServer: metricsConfig, + } + api, err := NewApi(context.Background(), logger, cfg) + require.NoError(t, err) + request, err := http.NewRequest("GET", "http://"+api.Addr()+"/healthz", nil) assert.Nil(t, err) responseRecorder := httptest.NewRecorder() @@ -107,8 +123,14 @@ func TestHealthz(t *testing.T) { func TestL1BridgeDepositsHandler(t *testing.T) { logger := testlog.Logger(t, log.LvlInfo) - api := NewApi(logger, &MockBridgeTransfersView{}, apiConfig, metricsConfig) - request, err := http.NewRequest("GET", fmt.Sprintf("/api/v0/deposits/%s", mockAddress), nil) + cfg := &Config{ + DB: &TestDBConnector{BridgeTransfers: &MockBridgeTransfersView{}}, + HTTPServer: apiConfig, + MetricsServer: metricsConfig, + } + api, err := NewApi(context.Background(), logger, cfg) + require.NoError(t, err) + request, err := http.NewRequest("GET", fmt.Sprintf("http://"+api.Addr()+"/api/v0/deposits/%s", mockAddress), nil) assert.Nil(t, err) responseRecorder := httptest.NewRecorder() @@ -130,8 +152,14 @@ func TestL1BridgeDepositsHandler(t *testing.T) { func TestL2BridgeWithdrawalsByAddressHandler(t *testing.T) { logger := testlog.Logger(t, log.LvlInfo) - api := NewApi(logger, &MockBridgeTransfersView{}, apiConfig, metricsConfig) - request, err := http.NewRequest("GET", fmt.Sprintf("/api/v0/withdrawals/%s", mockAddress), nil) + cfg := &Config{ + DB: &TestDBConnector{BridgeTransfers: &MockBridgeTransfersView{}}, + HTTPServer: apiConfig, + MetricsServer: metricsConfig, + } + api, err := NewApi(context.Background(), logger, cfg) + require.NoError(t, err) + request, err := http.NewRequest("GET", fmt.Sprintf("http://"+api.Addr()+"/api/v0/withdrawals/%s", mockAddress), nil) assert.Nil(t, err) responseRecorder := httptest.NewRecorder() @@ -149,8 +177,8 @@ func TestL2BridgeWithdrawalsByAddressHandler(t *testing.T) { assert.Equal(t, resp.Items[0].To, withdrawal.Tx.ToAddress.String()) assert.Equal(t, resp.Items[0].TransactionHash, common.HexToHash("0x789").String()) assert.Equal(t, resp.Items[0].Amount, withdrawal.Tx.Amount.String()) - assert.Equal(t, resp.Items[0].ProofTransactionHash, common.HexToHash("0x123").String()) - assert.Equal(t, resp.Items[0].ClaimTransactionHash, common.HexToHash("0x123").String()) + assert.Equal(t, resp.Items[0].L1ProvenTxHash, common.HexToHash("0x123").String()) + assert.Equal(t, resp.Items[0].L1FinalizedTxHash, common.HexToHash("0x123").String()) assert.Equal(t, resp.Items[0].L1TokenAddress, withdrawal.TokenPair.RemoteTokenAddress.String()) assert.Equal(t, resp.Items[0].L2TokenAddress, withdrawal.TokenPair.LocalTokenAddress.String()) assert.Equal(t, resp.Items[0].Timestamp, withdrawal.Tx.Timestamp) diff --git a/indexer/api/config.go b/indexer/api/config.go new file mode 100644 index 0000000000000..fccf8f86c20d1 --- /dev/null +++ b/indexer/api/config.go @@ -0,0 +1,60 @@ +package api + +import ( + "context" + "fmt" + + "github.com/ethereum/go-ethereum/log" + + "github.com/ethereum-optimism/optimism/indexer/config" + "github.com/ethereum-optimism/optimism/indexer/database" +) + +// DB represents the abstract DB access the API has. +type DB struct { + BridgeTransfers database.BridgeTransfersView + Closer func() error +} + +// DBConfigConnector implements a fully config based DBConnector +type DBConfigConnector struct { + config.DBConfig +} + +func (cfg *DBConfigConnector) OpenDB(ctx context.Context, log log.Logger) (*DB, error) { + db, err := database.NewDB(ctx, log, cfg.DBConfig) + if err != nil { + return nil, fmt.Errorf("failed to connect to databse: %w", err) + } + return &DB{ + BridgeTransfers: db.BridgeTransfers, + Closer: db.Close, + }, nil +} + +type TestDBConnector struct { + BridgeTransfers database.BridgeTransfersView +} + +func (tdb *TestDBConnector) OpenDB(ctx context.Context, log log.Logger) (*DB, error) { + return &DB{ + BridgeTransfers: tdb.BridgeTransfers, + Closer: func() error { + log.Info("API service closed test DB view") + return nil + }, + }, nil +} + +// DBConnector is an interface: the config may provide different ways to access the DB. +// This is implemented in tests to provide custom DB views, or share the DB with other services. +type DBConnector interface { + OpenDB(ctx context.Context, log log.Logger) (*DB, error) +} + +// Config for the API service +type Config struct { + DB DBConnector + HTTPServer config.ServerConfig + MetricsServer config.ServerConfig +} diff --git a/indexer/api/models/models.go b/indexer/api/models/models.go index 6ccdeae2f0573..b3e0964204bfa 100644 --- a/indexer/api/models/models.go +++ b/indexer/api/models/models.go @@ -1,5 +1,10 @@ package models +import ( + "github.com/ethereum-optimism/optimism/indexer/database" + "github.com/ethereum/go-ethereum/common" +) + // DepositItem ... Deposit item model for API responses type DepositItem struct { Guid string `json:"guid"` @@ -23,18 +28,18 @@ type DepositResponse struct { // WithdrawalItem ... Data model for API JSON response type WithdrawalItem struct { - Guid string `json:"guid"` - From string `json:"from"` - To string `json:"to"` - TransactionHash string `json:"transactionHash"` - MessageHash string `json:"messageHash"` - Timestamp uint64 `json:"timestamp"` - L2BlockHash string `json:"l2BlockHash"` - Amount string `json:"amount"` - ProofTransactionHash string `json:"proofTransactionHash"` - ClaimTransactionHash string `json:"claimTransactionHash"` - L1TokenAddress string `json:"l1TokenAddress"` - L2TokenAddress string `json:"l2TokenAddress"` + Guid string `json:"guid"` + From string `json:"from"` + To string `json:"to"` + TransactionHash string `json:"transactionHash"` + CrossDomainMessageHash string `json:"crossDomainMessageHash"` + Timestamp uint64 `json:"timestamp"` + L2BlockHash string `json:"l2BlockHash"` + Amount string `json:"amount"` + L1ProvenTxHash string `json:"l1ProvenTxHash"` + L1FinalizedTxHash string `json:"l1FinalizedTxHash"` + L1TokenAddress string `json:"l1TokenAddress"` + L2TokenAddress string `json:"l2TokenAddress"` } // WithdrawalResponse ... Data model for API JSON response @@ -43,3 +48,43 @@ type WithdrawalResponse struct { HasNextPage bool `json:"hasNextPage"` Items []WithdrawalItem `json:"items"` } + +type BridgeSupplyView struct { + L1DepositSum float64 `json:"l1DepositSum"` + L2WithdrawalSum float64 `json:"l2WithdrawalSum"` +} + +// FIXME make a pure function that returns a struct instead of newWithdrawalResponse +// newWithdrawalResponse ... Converts a database.L2BridgeWithdrawalsResponse to an api.WithdrawalResponse +func CreateWithdrawalResponse(withdrawals *database.L2BridgeWithdrawalsResponse) WithdrawalResponse { + items := make([]WithdrawalItem, len(withdrawals.Withdrawals)) + for i, withdrawal := range withdrawals.Withdrawals { + + cdh := withdrawal.L2BridgeWithdrawal.CrossDomainMessageHash + if cdh == nil { // Zero value indicates that the withdrawal didn't have a cross domain message + cdh = &common.Hash{0} + } + + item := WithdrawalItem{ + Guid: withdrawal.L2BridgeWithdrawal.TransactionWithdrawalHash.String(), + L2BlockHash: withdrawal.L2BlockHash.String(), + Timestamp: withdrawal.L2BridgeWithdrawal.Tx.Timestamp, + From: withdrawal.L2BridgeWithdrawal.Tx.FromAddress.String(), + To: withdrawal.L2BridgeWithdrawal.Tx.ToAddress.String(), + TransactionHash: withdrawal.L2TransactionHash.String(), + Amount: withdrawal.L2BridgeWithdrawal.Tx.Amount.String(), + CrossDomainMessageHash: cdh.String(), + L1ProvenTxHash: withdrawal.ProvenL1TransactionHash.String(), + L1FinalizedTxHash: withdrawal.FinalizedL1TransactionHash.String(), + L1TokenAddress: withdrawal.L2BridgeWithdrawal.TokenPair.RemoteTokenAddress.String(), + L2TokenAddress: withdrawal.L2BridgeWithdrawal.TokenPair.LocalTokenAddress.String(), + } + items[i] = item + } + + return WithdrawalResponse{ + Cursor: withdrawals.Cursor, + HasNextPage: withdrawals.HasNextPage, + Items: items, + } +} diff --git a/indexer/api/models/models_test.go b/indexer/api/models/models_test.go new file mode 100644 index 0000000000000..c2fe8a842c97d --- /dev/null +++ b/indexer/api/models/models_test.go @@ -0,0 +1,64 @@ +package models_test + +import ( + "fmt" + "reflect" + "testing" + + "github.com/ethereum-optimism/optimism/indexer/api/models" + "github.com/ethereum-optimism/optimism/indexer/database" + "github.com/ethereum/go-ethereum/common" + "github.com/stretchr/testify/require" +) + +func TestCreateWithdrawal(t *testing.T) { + // (1) Create a dummy database response object + + cdh := common.HexToHash("0x2") + dbWithdrawals := &database.L2BridgeWithdrawalsResponse{ + Withdrawals: []database.L2BridgeWithdrawalWithTransactionHashes{ + { + L2BridgeWithdrawal: database.L2BridgeWithdrawal{ + TransactionWithdrawalHash: common.HexToHash("0x1"), + BridgeTransfer: database.BridgeTransfer{ + CrossDomainMessageHash: &cdh, + Tx: database.Transaction{ + FromAddress: common.HexToAddress("0x3"), + ToAddress: common.HexToAddress("0x4"), + Timestamp: 5, + }, + TokenPair: database.TokenPair{ + LocalTokenAddress: common.HexToAddress("0x6"), + RemoteTokenAddress: common.HexToAddress("0x7"), + }, + }, + }, + }, + }, + } + + // (2) Create and validate response object + + response := models.CreateWithdrawalResponse(dbWithdrawals) + require.NotEmpty(t, response.Items) + require.Len(t, response.Items, 1) + + // (3) Use reflection to check that all fields in WithdrawalItem are populated correctly + + item := response.Items[0] + structType := reflect.TypeOf(item) + + structVal := reflect.ValueOf(item) + fieldNum := structVal.NumField() + + for i := 0; i < fieldNum; i++ { + field := structVal.Field(i) + fieldName := structType.Field(i).Name + + isSet := field.IsValid() && !field.IsZero() + + require.True(t, isSet, fmt.Sprintf("%s in not set", fieldName)) + + } + +} diff --git a/indexer/api/routes/supply.go b/indexer/api/routes/supply.go new file mode 100644 index 0000000000000..7f0ece832234a --- /dev/null +++ b/indexer/api/routes/supply.go @@ -0,0 +1,35 @@ +package routes + +import ( + "net/http" + + "github.com/ethereum-optimism/optimism/indexer/api/models" +) + +// SupplyView ... Handles /api/v0/supply GET requests +func (h Routes) SupplyView(w http.ResponseWriter, r *http.Request) { + + depositSum, err := h.view.L1BridgeDepositSum() + if err != nil { + http.Error(w, "internal server error reading deposits", http.StatusInternalServerError) + h.logger.Error("unable to read deposits from DB", "err", err.Error()) + return + } + + withdrawalSum, err := h.view.L2BridgeWithdrawalSum() + if err != nil { + http.Error(w, "internal server error reading withdrawals", http.StatusInternalServerError) + h.logger.Error("unable to read withdrawals from DB", "err", err.Error()) + return + } + + view := models.BridgeSupplyView{ + L1DepositSum: depositSum, + L2WithdrawalSum: withdrawalSum, + } + + err = jsonResponse(w, view, http.StatusOK) + if err != nil { + h.logger.Error("error writing response", "err", err) + } +} diff --git a/indexer/api/routes/withdrawals.go b/indexer/api/routes/withdrawals.go index 1fc2e1d841668..c408f2ab350db 100644 --- a/indexer/api/routes/withdrawals.go +++ b/indexer/api/routes/withdrawals.go @@ -4,37 +4,9 @@ import ( "net/http" "github.com/ethereum-optimism/optimism/indexer/api/models" - "github.com/ethereum-optimism/optimism/indexer/database" "github.com/go-chi/chi/v5" ) -// FIXME make a pure function that returns a struct instead of newWithdrawalResponse -// newWithdrawalResponse ... Converts a database.L2BridgeWithdrawalsResponse to an api.WithdrawalResponse -func newWithdrawalResponse(withdrawals *database.L2BridgeWithdrawalsResponse) models.WithdrawalResponse { - items := make([]models.WithdrawalItem, len(withdrawals.Withdrawals)) - for i, withdrawal := range withdrawals.Withdrawals { - item := models.WithdrawalItem{ - Guid: withdrawal.L2BridgeWithdrawal.TransactionWithdrawalHash.String(), - L2BlockHash: withdrawal.L2BlockHash.String(), - From: withdrawal.L2BridgeWithdrawal.Tx.FromAddress.String(), - To: withdrawal.L2BridgeWithdrawal.Tx.ToAddress.String(), - TransactionHash: withdrawal.L2TransactionHash.String(), - Amount: withdrawal.L2BridgeWithdrawal.Tx.Amount.String(), - ProofTransactionHash: withdrawal.ProvenL1TransactionHash.String(), - ClaimTransactionHash: withdrawal.FinalizedL1TransactionHash.String(), - L1TokenAddress: withdrawal.L2BridgeWithdrawal.TokenPair.RemoteTokenAddress.String(), - L2TokenAddress: withdrawal.L2BridgeWithdrawal.TokenPair.LocalTokenAddress.String(), - } - items[i] = item - } - - return models.WithdrawalResponse{ - Cursor: withdrawals.Cursor, - HasNextPage: withdrawals.HasNextPage, - Items: items, - } -} - // L2WithdrawalsHandler ... Handles /api/v0/withdrawals/{address} GET requests func (h Routes) L2WithdrawalsHandler(w http.ResponseWriter, r *http.Request) { addressValue := chi.URLParam(r, "address") @@ -68,7 +40,7 @@ func (h Routes) L2WithdrawalsHandler(w http.ResponseWriter, r *http.Request) { h.logger.Error("Unable to read withdrawals from DB", "err", err.Error()) return } - response := newWithdrawalResponse(withdrawals) + response := models.CreateWithdrawalResponse(withdrawals) err = jsonResponse(w, response, http.StatusOK) if err != nil { diff --git a/indexer/bigint/bigint.go b/indexer/bigint/bigint.go index 1cbc08c062f99..44adbb02f17e0 100644 --- a/indexer/bigint/bigint.go +++ b/indexer/bigint/bigint.go @@ -25,3 +25,9 @@ func Clamp(start, end *big.Int, size uint64) *big.Int { func Matcher(num int64) func(*big.Int) bool { return func(bi *big.Int) bool { return bi.Int64() == num } } + +func WeiToETH(wei *big.Int) *big.Float { + f := new(big.Float) + f.SetString(wei.String()) + return f.Quo(f, big.NewFloat(1e18)) +} diff --git a/indexer/client/client.go b/indexer/client/client.go index 567794d456bb6..6b0d1a7dbff4d 100644 --- a/indexer/client/client.go +++ b/indexer/client/client.go @@ -23,6 +23,7 @@ const ( healthz = "get_health" deposits = "get_deposits" withdrawals = "get_withdrawals" + sum = "get_sum" ) // Option ... Provides configuration through callback injection @@ -164,6 +165,25 @@ func (c *Client) GetAllDepositsByAddress(l1Address common.Address) ([]models.Dep } +// GetSupplyAssessment ... Returns an assessment of the current supply +// on both L1 and L2. This includes the individual sums of +// (L1/L2) deposits and withdrawals +func (c *Client) GetSupplyAssessment() (*models.BridgeSupplyView, error) { + url := c.cfg.BaseURL + api.SupplyPath + + resp, err := c.doRecordRequest(sum, url) + if err != nil { + return nil, err + } + + var bsv *models.BridgeSupplyView + if err := json.Unmarshal(resp, &bsv); err != nil { + return nil, err + } + + return bsv, nil +} + // GetAllWithdrawalsByAddress ... Gets all withdrawals provided a L2 address func (c *Client) GetAllWithdrawalsByAddress(l2Address common.Address) ([]models.WithdrawalItem, error) { var withdrawals []models.WithdrawalItem diff --git a/indexer/cmd/indexer/cli.go b/indexer/cmd/indexer/cli.go index db6f3831a019d..153cae9da4fc7 100644 --- a/indexer/cmd/indexer/cli.go +++ b/indexer/cmd/indexer/cli.go @@ -1,14 +1,19 @@ package main import ( + "context" + + "github.com/urfave/cli/v2" + + "github.com/ethereum/go-ethereum/params" + "github.com/ethereum-optimism/optimism/indexer" "github.com/ethereum-optimism/optimism/indexer/api" "github.com/ethereum-optimism/optimism/indexer/config" "github.com/ethereum-optimism/optimism/indexer/database" + "github.com/ethereum-optimism/optimism/op-service/cliapp" oplog "github.com/ethereum-optimism/optimism/op-service/log" - "github.com/ethereum/go-ethereum/params" - - "github.com/urfave/cli/v2" + "github.com/ethereum-optimism/optimism/op-service/opio" ) var ( @@ -27,68 +32,62 @@ var ( } ) -func runIndexer(ctx *cli.Context) error { +func runIndexer(ctx *cli.Context, shutdown context.CancelCauseFunc) (cliapp.Lifecycle, error) { log := oplog.NewLogger(oplog.AppOut(ctx), oplog.ReadCLIConfig(ctx)).New("role", "indexer") oplog.SetGlobalLogHandler(log.GetHandler()) + log.Info("running indexer...") + cfg, err := config.LoadConfig(log, ctx.String(ConfigFlag.Name)) if err != nil { log.Error("failed to load config", "err", err) - return err - } - - db, err := database.NewDB(log, cfg.DB) - if err != nil { - log.Error("failed to connect to database", "err", err) - return err + return nil, err } - defer db.Close() - indexer, err := indexer.NewIndexer(log, db, cfg.Chain, cfg.RPCs, cfg.HTTPServer, cfg.MetricsServer) - if err != nil { - log.Error("failed to create indexer", "err", err) - return err - } - - return indexer.Run(ctx.Context) + return indexer.NewIndexer(ctx.Context, log, &cfg, shutdown) } -func runApi(ctx *cli.Context) error { +func runApi(ctx *cli.Context, _ context.CancelCauseFunc) (cliapp.Lifecycle, error) { log := oplog.NewLogger(oplog.AppOut(ctx), oplog.ReadCLIConfig(ctx)).New("role", "api") oplog.SetGlobalLogHandler(log.GetHandler()) + log.Info("running api...") + cfg, err := config.LoadConfig(log, ctx.String(ConfigFlag.Name)) if err != nil { log.Error("failed to load config", "err", err) - return err + return nil, err } - db, err := database.NewDB(log, cfg.DB) - if err != nil { - log.Error("failed to connect to database", "err", err) - return err + apiCfg := &api.Config{ + DB: &api.DBConfigConnector{DBConfig: cfg.DB}, + HTTPServer: cfg.HTTPServer, + MetricsServer: cfg.MetricsServer, } - defer db.Close() - api := api.NewApi(log, db.BridgeTransfers, cfg.HTTPServer, cfg.MetricsServer) - return api.Run(ctx.Context) + return api.NewApi(ctx.Context, log, apiCfg) } func runMigrations(ctx *cli.Context) error { - log := oplog.NewLogger(oplog.AppOut(ctx), oplog.ReadCLIConfig(ctx)).New("role", "api") + // We don't maintain a complicated lifecycle here, just interrupt to shut down. + ctx.Context = opio.CancelOnInterrupt(ctx.Context) + + log := oplog.NewLogger(oplog.AppOut(ctx), oplog.ReadCLIConfig(ctx)).New("role", "migrations") oplog.SetGlobalLogHandler(log.GetHandler()) + log.Info("running migrations...") + cfg, err := config.LoadConfig(log, ctx.String(ConfigFlag.Name)) - migrationsDir := ctx.String(MigrationsFlag.Name) if err != nil { log.Error("failed to load config", "err", err) return err } - db, err := database.NewDB(log, cfg.DB) + db, err := database.NewDB(ctx.Context, log, cfg.DB) if err != nil { log.Error("failed to connect to database", "err", err) return err } defer db.Close() + migrationsDir := ctx.String(MigrationsFlag.Name) return db.ExecuteSQLMigration(migrationsDir) } @@ -106,13 +105,13 @@ func newCli(GitCommit string, GitDate string) *cli.App { Name: "api", Flags: flags, Description: "Runs the api service", - Action: runApi, + Action: cliapp.LifecycleCmd(runApi), }, { Name: "index", Flags: flags, Description: "Runs the indexing service", - Action: runIndexer, + Action: cliapp.LifecycleCmd(runIndexer), }, { Name: "migrate", diff --git a/indexer/cmd/indexer/main.go b/indexer/cmd/indexer/main.go index 1c6217beb1a53..341f10c4366b9 100644 --- a/indexer/cmd/indexer/main.go +++ b/indexer/cmd/indexer/main.go @@ -4,9 +4,10 @@ import ( "context" "os" + "github.com/ethereum/go-ethereum/log" + oplog "github.com/ethereum-optimism/optimism/op-service/log" "github.com/ethereum-optimism/optimism/op-service/opio" - "github.com/ethereum/go-ethereum/log" ) var ( @@ -15,17 +16,12 @@ var ( ) func main() { - // This is the most root context, used to propagate - // cancellations to all spawned application-level goroutines - ctx, cancel := context.WithCancel(context.Background()) - go func() { - opio.BlockOnInterrupts() - cancel() - }() - oplog.SetupDefaults() app := newCli(GitCommit, GitDate) + // sub-commands set up their individual interrupt lifecycles, which can block on the given interrupt as needed. + ctx := opio.WithInterruptBlocker(context.Background()) if err := app.RunContext(ctx, os.Args); err != nil { log.Error("application failed", "err", err) + os.Exit(1) } } diff --git a/indexer/config/config.go b/indexer/config/config.go index 8cef5058007be..831a26158e7f7 100644 --- a/indexer/config/config.go +++ b/indexer/config/config.go @@ -134,10 +134,11 @@ type DBConfig struct { Password string `toml:"password"` } -// Configures the a server +// Configures the server type ServerConfig struct { - Host string `toml:"host"` - Port int `toml:"port"` + Host string `toml:"host"` + Port int `toml:"port"` + WriteTimeout int `toml:"timeout"` } // LoadConfig loads the `indexer.toml` config file from a given path @@ -153,18 +154,25 @@ func LoadConfig(log log.Logger, path string) (Config, error) { data = []byte(os.ExpandEnv(string(data))) log.Debug("parsed config file", "data", string(data)) - if _, err := toml.Decode(string(data), &cfg); err != nil { + md, err := toml.Decode(string(data), &cfg) + if err != nil { log.Error("failed to decode config file", "err", err) return cfg, err } + if len(md.Undecoded()) > 0 { + log.Error("unknown fields in config file", "fields", md.Undecoded()) + err = fmt.Errorf("unknown fields in config file: %v", md.Undecoded()) + return cfg, err + } + if cfg.Chain.Preset == DevnetPresetId { preset, err := DevnetPreset() if err != nil { return cfg, err } - log.Info("loaded local devnet preset") + log.Info("detected preset", "preset", DevnetPresetId, "name", preset.Name) cfg.Chain = preset.ChainConfig } else if cfg.Chain.Preset != 0 { preset, ok := Presets[cfg.Chain.Preset] @@ -191,25 +199,21 @@ func LoadConfig(log log.Logger, path string) (Config, error) { // Defaults for any unset options if cfg.Chain.L1PollingInterval == 0 { - log.Info("setting default L1 polling interval", "interval", defaultLoopInterval) cfg.Chain.L1PollingInterval = defaultLoopInterval } if cfg.Chain.L2PollingInterval == 0 { - log.Info("setting default L2 polling interval", "interval", defaultLoopInterval) cfg.Chain.L2PollingInterval = defaultLoopInterval } if cfg.Chain.L1HeaderBufferSize == 0 { - log.Info("setting default L1 header buffer", "size", defaultHeaderBufferSize) cfg.Chain.L1HeaderBufferSize = defaultHeaderBufferSize } if cfg.Chain.L2HeaderBufferSize == 0 { - log.Info("setting default L2 header buffer", "size", defaultHeaderBufferSize) cfg.Chain.L2HeaderBufferSize = defaultHeaderBufferSize } - log.Info("loaded config", "config", cfg.Chain) + log.Info("loaded chain config", "config", cfg.Chain) return cfg, nil } diff --git a/indexer/config/config_test.go b/indexer/config/config_test.go index ee6bbc216b97c..4e0b0652c29d6 100644 --- a/indexer/config/config_test.go +++ b/indexer/config/config_test.go @@ -257,3 +257,49 @@ func TestLocalDevnet(t *testing.T) { require.Equal(t, devnetPreset.ChainConfig.L1Contracts, conf.Chain.L1Contracts) } + +func TestThrowsOnUnknownKeys(t *testing.T) { + logger := testlog.Logger(t, log.LvlInfo) + tmpfile, err := os.CreateTemp("", "test.toml") + require.NoError(t, err) + defer os.Remove(tmpfile.Name()) + defer tmpfile.Close() + + testData := ` + [chain] + unknown_key = 420 + preset = 420 + + [rpcs] + l1-rpc = "https://l1.example.com" + l2-rpc = "https://l2.example.com" + + [db] + another_unknownKey = 420 + host = "127.0.0.1" + port = 5432 + user = "postgres" + password = "postgres" + name = "indexer" + + [http] + host = "127.0.0.1" + port = 8080 + + [metrics] + host = "127.0.0.1" + port = 7300 + ` + + data := []byte(testData) + err = os.WriteFile(tmpfile.Name(), data, 0644) + require.NoError(t, err) + defer os.Remove(tmpfile.Name()) + + err = tmpfile.Close() + require.NoError(t, err) + + _, err = LoadConfig(logger, tmpfile.Name()) + require.Error(t, err) + require.Contains(t, err.Error(), "unknown fields in config file") +} diff --git a/indexer/database/blocks.go b/indexer/database/blocks.go index f1afcbc2c8939..4a01a216a488e 100644 --- a/indexer/database/blocks.go +++ b/indexer/database/blocks.go @@ -7,8 +7,10 @@ import ( "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/core/types" + "github.com/ethereum/go-ethereum/log" "gorm.io/gorm" + "gorm.io/gorm/clause" ) /** @@ -35,6 +37,10 @@ func BlockHeaderFromHeader(header *types.Header) BlockHeader { } } +func (b BlockHeader) String() string { + return fmt.Sprintf("{Hash: %s, Number: %s}", b.Hash, b.Number) +} + type L1BlockHeader struct { BlockHeader `gorm:"embedded"` } @@ -46,13 +52,13 @@ type L2BlockHeader struct { type BlocksView interface { L1BlockHeader(common.Hash) (*L1BlockHeader, error) L1BlockHeaderWithFilter(BlockHeader) (*L1BlockHeader, error) + L1BlockHeaderWithScope(func(db *gorm.DB) *gorm.DB) (*L1BlockHeader, error) L1LatestBlockHeader() (*L1BlockHeader, error) L2BlockHeader(common.Hash) (*L2BlockHeader, error) L2BlockHeaderWithFilter(BlockHeader) (*L2BlockHeader, error) + L2BlockHeaderWithScope(func(db *gorm.DB) *gorm.DB) (*L2BlockHeader, error) L2LatestBlockHeader() (*L2BlockHeader, error) - - LatestObservedEpoch(*big.Int, uint64) (*Epoch, error) } type BlocksDB interface { @@ -67,17 +73,23 @@ type BlocksDB interface { */ type blocksDB struct { + log log.Logger gorm *gorm.DB } -func newBlocksDB(db *gorm.DB) BlocksDB { - return &blocksDB{gorm: db} +func newBlocksDB(log log.Logger, db *gorm.DB) BlocksDB { + return &blocksDB{log: log.New("table", "blocks"), gorm: db} } // L1 func (db *blocksDB) StoreL1BlockHeaders(headers []L1BlockHeader) error { - result := db.gorm.CreateInBatches(&headers, batchInsertSize) + deduped := db.gorm.Clauses(clause.OnConflict{Columns: []clause.Column{{Name: "hash"}}, DoNothing: true}) + result := deduped.Create(&headers) + if result.Error == nil && int(result.RowsAffected) < len(headers) { + db.log.Warn("ignored L1 block duplicates", "duplicates", len(headers)-int(result.RowsAffected)) + } + return result.Error } @@ -86,8 +98,12 @@ func (db *blocksDB) L1BlockHeader(hash common.Hash) (*L1BlockHeader, error) { } func (db *blocksDB) L1BlockHeaderWithFilter(filter BlockHeader) (*L1BlockHeader, error) { + return db.L1BlockHeaderWithScope(func(gorm *gorm.DB) *gorm.DB { return gorm.Where(&filter) }) +} + +func (db *blocksDB) L1BlockHeaderWithScope(scope func(*gorm.DB) *gorm.DB) (*L1BlockHeader, error) { var l1Header L1BlockHeader - result := db.gorm.Where(&filter).Take(&l1Header) + result := db.gorm.Scopes(scope).Take(&l1Header) if result.Error != nil { if errors.Is(result.Error, gorm.ErrRecordNotFound) { return nil, nil @@ -115,7 +131,12 @@ func (db *blocksDB) L1LatestBlockHeader() (*L1BlockHeader, error) { // L2 func (db *blocksDB) StoreL2BlockHeaders(headers []L2BlockHeader) error { - result := db.gorm.CreateInBatches(&headers, batchInsertSize) + deduped := db.gorm.Clauses(clause.OnConflict{Columns: []clause.Column{{Name: "hash"}}, DoNothing: true}) + result := deduped.Create(&headers) + if result.Error == nil && int(result.RowsAffected) < len(headers) { + db.log.Warn("ignored L2 block duplicates", "duplicates", len(headers)-int(result.RowsAffected)) + } + return result.Error } @@ -124,8 +145,12 @@ func (db *blocksDB) L2BlockHeader(hash common.Hash) (*L2BlockHeader, error) { } func (db *blocksDB) L2BlockHeaderWithFilter(filter BlockHeader) (*L2BlockHeader, error) { + return db.L2BlockHeaderWithScope(func(gorm *gorm.DB) *gorm.DB { return gorm.Where(&filter) }) +} + +func (db *blocksDB) L2BlockHeaderWithScope(scope func(*gorm.DB) *gorm.DB) (*L2BlockHeader, error) { var l2Header L2BlockHeader - result := db.gorm.Where(&filter).Take(&l2Header) + result := db.gorm.Scopes(scope).Take(&l2Header) if result.Error != nil { if errors.Is(result.Error, gorm.ErrRecordNotFound) { return nil, nil @@ -148,103 +173,3 @@ func (db *blocksDB) L2LatestBlockHeader() (*L2BlockHeader, error) { return &l2Header, nil } - -// Auxiliary Methods on both L1 & L2 - -type Epoch struct { - L1BlockHeader L1BlockHeader `gorm:"embedded"` - L2BlockHeader L2BlockHeader `gorm:"embedded"` -} - -// LatestObservedEpoch return the marker for latest epoch, observed on L1 & L2, within -// the specified bounds. In other words this returns the latest indexed L1 block that has -// a corresponding indexed L2 block with a matching L1Origin (equal timestamps). -// -// If `fromL1Height` (inclusive) is not specified, the search will start from genesis and -// continue all the way to latest indexed heights if `maxL1Range == 0`. -// -// For more, see the protocol spec: -// - https://github.com/ethereum-optimism/optimism/blob/develop/specs/derivation.md -func (db *blocksDB) LatestObservedEpoch(fromL1Height *big.Int, maxL1Range uint64) (*Epoch, error) { - // We use timestamps since that translates to both L1 & L2 - var fromTimestamp, toTimestamp uint64 - - // Lower Bound (the default `fromTimestamp = l1_starting_height` (default=0) suffices genesis representation) - var header L1BlockHeader - if fromL1Height != nil { - result := db.gorm.Where("number = ?", fromL1Height).Take(&header) - // TODO - Embed logging to db - if result.Error != nil { - if errors.Is(result.Error, gorm.ErrRecordNotFound) { - return nil, nil - } - return nil, result.Error - } - - fromTimestamp = header.Timestamp - } else { - result := db.gorm.Order("number desc").Take(&header) - if result.Error != nil { - if errors.Is(result.Error, gorm.ErrRecordNotFound) { - return nil, nil - } - return nil, result.Error - } - - fromL1Height = header.Number - } - - // Upper Bound (lowest timestamp indexed between L1/L2 bounded by `maxL1Range`) - { - l1QueryFilter := fmt.Sprintf("timestamp >= %d", fromTimestamp) - if maxL1Range > 0 { - maxHeight := new(big.Int).Add(fromL1Height, big.NewInt(int64(maxL1Range))) - l1QueryFilter = fmt.Sprintf("%s AND number <= %d", l1QueryFilter, maxHeight) - } - - // Fetch most recent header from l1_block_headers table - var l1Header L1BlockHeader - result := db.gorm.Where(l1QueryFilter).Order("timestamp DESC").Take(&l1Header) - if result.Error != nil { - if errors.Is(result.Error, gorm.ErrRecordNotFound) { - return nil, nil - } - return nil, result.Error - } - - toTimestamp = l1Header.Timestamp - - // Fetch most recent header from l2_block_headers table - var l2Header L2BlockHeader - result = db.gorm.Where("timestamp <= ?", toTimestamp).Order("timestamp DESC").Take(&l2Header) - if result.Error != nil { - if errors.Is(result.Error, gorm.ErrRecordNotFound) { - return nil, nil - } - return nil, result.Error - } - - if l2Header.Timestamp < toTimestamp { - toTimestamp = l2Header.Timestamp - } - } - - // Search for the latest indexed epoch within range. This is a faster query than doing an INNER JOIN between - // l1_block_headers and l2_block_headers which requires a full table scan to compute the resulting table. - l1Query := db.gorm.Table("l1_block_headers").Where("timestamp >= ? AND timestamp <= ?", fromTimestamp, toTimestamp) - l2Query := db.gorm.Table("l2_block_headers").Where("timestamp >= ? AND timestamp <= ?", fromTimestamp, toTimestamp) - query := db.gorm.Raw(`SELECT * FROM (?) AS l1_block_headers, (?) AS l2_block_headers - WHERE l1_block_headers.timestamp = l2_block_headers.timestamp - ORDER BY l2_block_headers.number DESC LIMIT 1`, l1Query, l2Query) - - var epoch Epoch - result := query.Take(&epoch) - if result.Error != nil { - if errors.Is(result.Error, gorm.ErrRecordNotFound) { - return nil, nil - } - return nil, result.Error - } - - return &epoch, nil -} diff --git a/indexer/database/bridge_messages.go b/indexer/database/bridge_messages.go index 7ea8761412644..a468c5f4b1058 100644 --- a/indexer/database/bridge_messages.go +++ b/indexer/database/bridge_messages.go @@ -6,8 +6,10 @@ import ( "math/big" "gorm.io/gorm" + "gorm.io/gorm/clause" "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/log" "github.com/google/uuid" ) @@ -60,11 +62,12 @@ type BridgeMessagesDB interface { */ type bridgeMessagesDB struct { + log log.Logger gorm *gorm.DB } -func newBridgeMessagesDB(db *gorm.DB) BridgeMessagesDB { - return &bridgeMessagesDB{gorm: db} +func newBridgeMessagesDB(log log.Logger, db *gorm.DB) BridgeMessagesDB { + return &bridgeMessagesDB{log: log.New("table", "bridge_messages"), gorm: db} } /** @@ -72,7 +75,12 @@ func newBridgeMessagesDB(db *gorm.DB) BridgeMessagesDB { */ func (db bridgeMessagesDB) StoreL1BridgeMessages(messages []L1BridgeMessage) error { - result := db.gorm.CreateInBatches(&messages, batchInsertSize) + deduped := db.gorm.Clauses(clause.OnConflict{Columns: []clause.Column{{Name: "message_hash"}}, DoNothing: true}) + result := deduped.Create(&messages) + if result.Error == nil && int(result.RowsAffected) < len(messages) { + db.log.Warn("ignored L1 bridge message duplicates", "duplicates", len(messages)-int(result.RowsAffected)) + } + return result.Error } @@ -98,7 +106,13 @@ func (db bridgeMessagesDB) MarkRelayedL1BridgeMessage(messageHash common.Hash, r if err != nil { return err } else if message == nil { - return fmt.Errorf("L1BridgeMessage with message hash %s not found", messageHash) + return fmt.Errorf("L1BridgeMessage %s not found", messageHash) + } + + if message.RelayedMessageEventGUID != nil && message.RelayedMessageEventGUID.ID() == relayEvent.ID() { + return nil + } else if message.RelayedMessageEventGUID != nil { + return fmt.Errorf("relayed message %s re-relayed with a different event %d", messageHash, relayEvent) } message.RelayedMessageEventGUID = &relayEvent @@ -111,7 +125,12 @@ func (db bridgeMessagesDB) MarkRelayedL1BridgeMessage(messageHash common.Hash, r */ func (db bridgeMessagesDB) StoreL2BridgeMessages(messages []L2BridgeMessage) error { - result := db.gorm.CreateInBatches(&messages, batchInsertSize) + deduped := db.gorm.Clauses(clause.OnConflict{Columns: []clause.Column{{Name: "message_hash"}}, DoNothing: true}) + result := deduped.Create(&messages) + if result.Error == nil && int(result.RowsAffected) < len(messages) { + db.log.Warn("ignored L2 bridge message duplicates", "duplicates", len(messages)-int(result.RowsAffected)) + } + return result.Error } @@ -137,7 +156,13 @@ func (db bridgeMessagesDB) MarkRelayedL2BridgeMessage(messageHash common.Hash, r if err != nil { return err } else if message == nil { - return fmt.Errorf("L2BridgeMessage with message hash %s not found", messageHash) + return fmt.Errorf("L2BridgeMessage %s not found", messageHash) + } + + if message.RelayedMessageEventGUID != nil && message.RelayedMessageEventGUID.ID() == relayEvent.ID() { + return nil + } else if message.RelayedMessageEventGUID != nil { + return fmt.Errorf("relayed message %s re-relayed with a different event %s", messageHash, relayEvent) } message.RelayedMessageEventGUID = &relayEvent diff --git a/indexer/database/bridge_transactions.go b/indexer/database/bridge_transactions.go index f1213961610bb..011206cbe7781 100644 --- a/indexer/database/bridge_transactions.go +++ b/indexer/database/bridge_transactions.go @@ -7,8 +7,10 @@ import ( "github.com/google/uuid" "gorm.io/gorm" + "gorm.io/gorm/clause" "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/log" ) /** @@ -48,9 +50,11 @@ type L2TransactionWithdrawal struct { type BridgeTransactionsView interface { L1TransactionDeposit(common.Hash) (*L1TransactionDeposit, error) L1LatestBlockHeader() (*L1BlockHeader, error) + L1LatestFinalizedBlockHeader() (*L1BlockHeader, error) L2TransactionWithdrawal(common.Hash) (*L2TransactionWithdrawal, error) L2LatestBlockHeader() (*L2BlockHeader, error) + L2LatestFinalizedBlockHeader() (*L2BlockHeader, error) } type BridgeTransactionsDB interface { @@ -68,11 +72,12 @@ type BridgeTransactionsDB interface { */ type bridgeTransactionsDB struct { + log log.Logger gorm *gorm.DB } -func newBridgeTransactionsDB(db *gorm.DB) BridgeTransactionsDB { - return &bridgeTransactionsDB{gorm: db} +func newBridgeTransactionsDB(log log.Logger, db *gorm.DB) BridgeTransactionsDB { + return &bridgeTransactionsDB{log: log.New("table", "bridge_transactions"), gorm: db} } /** @@ -80,7 +85,12 @@ func newBridgeTransactionsDB(db *gorm.DB) BridgeTransactionsDB { */ func (db *bridgeTransactionsDB) StoreL1TransactionDeposits(deposits []L1TransactionDeposit) error { - result := db.gorm.CreateInBatches(&deposits, batchInsertSize) + deduped := db.gorm.Clauses(clause.OnConflict{Columns: []clause.Column{{Name: "source_hash"}}, DoNothing: true}) + result := deduped.Create(&deposits) + if result.Error == nil && int(result.RowsAffected) < len(deposits) { + db.log.Warn("ignored L1 tx deposit duplicates", "duplicates", len(deposits)-int(result.RowsAffected)) + } + return result.Error } @@ -98,23 +108,41 @@ func (db *bridgeTransactionsDB) L1TransactionDeposit(sourceHash common.Hash) (*L } func (db *bridgeTransactionsDB) L1LatestBlockHeader() (*L1BlockHeader, error) { - // Markers for an indexed bridge event - // L1: Latest Transaction Deposit, Latest Proven/Finalized Withdrawal - l1DepositQuery := db.gorm.Table("l1_transaction_deposits").Order("l1_transaction_deposits.timestamp DESC").Limit(1) - l1DepositQuery = l1DepositQuery.Joins("INNER JOIN l1_contract_events ON l1_contract_events.guid = l1_transaction_deposits.initiated_l1_event_guid") - l1DepositQuery = l1DepositQuery.Select("l1_contract_events.*") + // Latest Transaction Deposit + l1Query := db.gorm.Table("l1_transaction_deposits").Order("l1_transaction_deposits.timestamp DESC") + l1Query = l1Query.Joins("INNER JOIN l1_contract_events ON l1_contract_events.guid = l1_transaction_deposits.initiated_l1_event_guid") + l1Query = l1Query.Joins("INNER JOIN l1_block_headers ON l1_block_headers.hash = l1_contract_events.block_hash") + l1Query = l1Query.Select("l1_block_headers.*") - l1ProvenQuery := db.gorm.Table("l2_transaction_withdrawals") - l1ProvenQuery = l1ProvenQuery.Joins("INNER JOIN l1_contract_events ON l1_contract_events.guid = l2_transaction_withdrawals.proven_l1_event_guid") - l1ProvenQuery = l1ProvenQuery.Order("l1_contract_events.timestamp DESC").Select("l1_contract_events.*").Limit(1) + var l1Header L1BlockHeader + result := l1Query.Take(&l1Header) + if result.Error != nil { + if errors.Is(result.Error, gorm.ErrRecordNotFound) { + return nil, nil + } + return nil, result.Error + } + + return &l1Header, nil +} - l1FinalizedQuery := db.gorm.Table("l2_transaction_withdrawals") - l1FinalizedQuery = l1FinalizedQuery.Joins("INNER JOIN l1_contract_events ON l1_contract_events.guid = l2_transaction_withdrawals.proven_l1_event_guid") - l1FinalizedQuery = l1FinalizedQuery.Order("l1_contract_events.timestamp DESC").Select("l1_contract_events.*").Limit(1) +func (db *bridgeTransactionsDB) L1LatestFinalizedBlockHeader() (*L1BlockHeader, error) { + // A Proven, Finalized Event or Relayed Message + provenQuery := db.gorm.Table("l2_transaction_withdrawals").Order("timestamp DESC").Limit(1) + provenQuery = provenQuery.Joins("INNER JOIN l1_contract_events ON l1_contract_events.guid = l2_transaction_withdrawals.proven_l1_event_guid") + provenQuery = provenQuery.Order("l1_contract_events.timestamp DESC").Select("l1_contract_events.*") - l1Query := db.gorm.Table("((?) UNION (?) UNION (?)) AS latest_bridge_events", l1DepositQuery.Limit(1), l1ProvenQuery, l1FinalizedQuery) - l1Query = l1Query.Joins("INNER JOIN l1_block_headers ON l1_block_headers.hash = latest_bridge_events.block_hash") - l1Query = l1Query.Order("latest_bridge_events.timestamp DESC").Select("l1_block_headers.*") + finalizedQuery := db.gorm.Table("l2_transaction_withdrawals").Order("timestamp DESC").Limit(1) + finalizedQuery = finalizedQuery.Joins("INNER JOIN l1_contract_events ON l1_contract_events.guid = l2_transaction_withdrawals.proven_l1_event_guid") + finalizedQuery = finalizedQuery.Select("l1_contract_events.*") + + relayedQuery := db.gorm.Table("l2_bridge_messages").Order("timestamp DESC") + relayedQuery = relayedQuery.Joins("INNER JOIN l1_contract_events ON l1_contract_events.guid = l2_bridge_messages.relayed_message_event_guid") + relayedQuery = relayedQuery.Select("l1_contract_events.*") + + l1Query := db.gorm.Table("((?) UNION (?) UNION (?)) AS finalized_bridge_events", provenQuery, finalizedQuery, relayedQuery) + l1Query = l1Query.Joins("INNER JOIN l1_block_headers ON l1_block_headers.hash = finalized_bridge_events.block_hash") + l1Query = l1Query.Order("finalized_bridge_events.timestamp DESC").Select("l1_block_headers.*") var l1Header L1BlockHeader result := l1Query.Take(&l1Header) @@ -133,7 +161,12 @@ func (db *bridgeTransactionsDB) L1LatestBlockHeader() (*L1BlockHeader, error) { */ func (db *bridgeTransactionsDB) StoreL2TransactionWithdrawals(withdrawals []L2TransactionWithdrawal) error { - result := db.gorm.CreateInBatches(&withdrawals, batchInsertSize) + deduped := db.gorm.Clauses(clause.OnConflict{Columns: []clause.Column{{Name: "withdrawal_hash"}}, DoNothing: true}) + result := deduped.Create(&withdrawals) + if result.Error == nil && int(result.RowsAffected) < len(withdrawals) { + db.log.Warn("ignored L2 tx withdrawal duplicates", "duplicates", len(withdrawals)-int(result.RowsAffected)) + } + return result.Error } @@ -155,11 +188,16 @@ func (db *bridgeTransactionsDB) MarkL2TransactionWithdrawalProvenEvent(withdrawa withdrawal, err := db.L2TransactionWithdrawal(withdrawalHash) if err != nil { return err - } - if withdrawal == nil { + } else if withdrawal == nil { return fmt.Errorf("transaction withdrawal hash %s not found", withdrawalHash) } + if withdrawal.ProvenL1EventGUID != nil && withdrawal.ProvenL1EventGUID.ID() == provenL1EventGuid.ID() { + return nil + } else if withdrawal.ProvenL1EventGUID != nil { + return fmt.Errorf("proven withdrawal %s re-proven with a different event %s", withdrawalHash, provenL1EventGuid) + } + withdrawal.ProvenL1EventGUID = &provenL1EventGuid result := db.gorm.Save(&withdrawal) return result.Error @@ -170,14 +208,18 @@ func (db *bridgeTransactionsDB) MarkL2TransactionWithdrawalFinalizedEvent(withdr withdrawal, err := db.L2TransactionWithdrawal(withdrawalHash) if err != nil { return err - } - if withdrawal == nil { + } else if withdrawal == nil { return fmt.Errorf("transaction withdrawal hash %s not found", withdrawalHash) - } - if withdrawal.ProvenL1EventGUID == nil { + } else if withdrawal.ProvenL1EventGUID == nil { return fmt.Errorf("cannot mark unproven withdrawal hash %s as finalized", withdrawal.WithdrawalHash) } + if withdrawal.FinalizedL1EventGUID != nil && withdrawal.FinalizedL1EventGUID.ID() == finalizedL1EventGuid.ID() { + return nil + } else if withdrawal.FinalizedL1EventGUID != nil { + return fmt.Errorf("finalized withdrawal %s re-finalized with a different event %s", withdrawalHash, finalizedL1EventGuid) + } + withdrawal.FinalizedL1EventGUID = &finalizedL1EventGuid withdrawal.Succeeded = &succeeded result := db.gorm.Save(&withdrawal) @@ -229,3 +271,22 @@ func (db *bridgeTransactionsDB) L2LatestBlockHeader() (*L2BlockHeader, error) { return latestL2DepositHeader, nil } } + +func (db *bridgeTransactionsDB) L2LatestFinalizedBlockHeader() (*L2BlockHeader, error) { + // Only a Relayed message since we dont track L1 deposit inclusion status. + relayedQuery := db.gorm.Table("l1_bridge_messages").Order("timestamp DESC").Limit(1) + relayedQuery = relayedQuery.Joins("INNER JOIN l2_contract_events ON l2_contract_events.guid = l1_bridge_messages.relayed_message_event_guid") + relayedQuery = relayedQuery.Joins("INNER JOIN l2_block_headers ON l2_block_headers.hash = l2_contract_events.block_hash") + relayedQuery = relayedQuery.Select("l2_block_headers.*") + + var l2Header L2BlockHeader + result := relayedQuery.Take(&l2Header) + if result.Error != nil { + if errors.Is(result.Error, gorm.ErrRecordNotFound) { + return nil, nil + } + return nil, result.Error + } + + return &l2Header, nil +} diff --git a/indexer/database/bridge_transfers.go b/indexer/database/bridge_transfers.go index 2d4fac96f59d1..6704accf59119 100644 --- a/indexer/database/bridge_transfers.go +++ b/indexer/database/bridge_transfers.go @@ -5,9 +5,11 @@ import ( "fmt" "gorm.io/gorm" + "gorm.io/gorm/clause" "github.com/ethereum-optimism/optimism/op-bindings/predeploys" "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/log" ) var ( @@ -59,10 +61,12 @@ type L2BridgeWithdrawalWithTransactionHashes struct { type BridgeTransfersView interface { L1BridgeDeposit(common.Hash) (*L1BridgeDeposit, error) + L1BridgeDepositSum() (float64, error) L1BridgeDepositWithFilter(BridgeTransfer) (*L1BridgeDeposit, error) L1BridgeDepositsByAddress(common.Address, string, int) (*L1BridgeDepositsResponse, error) L2BridgeWithdrawal(common.Hash) (*L2BridgeWithdrawal, error) + L2BridgeWithdrawalSum() (float64, error) L2BridgeWithdrawalWithFilter(BridgeTransfer) (*L2BridgeWithdrawal, error) L2BridgeWithdrawalsByAddress(common.Address, string, int) (*L2BridgeWithdrawalsResponse, error) } @@ -79,11 +83,12 @@ type BridgeTransfersDB interface { */ type bridgeTransfersDB struct { + log log.Logger gorm *gorm.DB } -func newBridgeTransfersDB(db *gorm.DB) BridgeTransfersDB { - return &bridgeTransfersDB{gorm: db} +func newBridgeTransfersDB(log log.Logger, db *gorm.DB) BridgeTransfersDB { + return &bridgeTransfersDB{log: log.New("table", "bridge_transfers"), gorm: db} } /** @@ -91,7 +96,12 @@ func newBridgeTransfersDB(db *gorm.DB) BridgeTransfersDB { */ func (db *bridgeTransfersDB) StoreL1BridgeDeposits(deposits []L1BridgeDeposit) error { - result := db.gorm.CreateInBatches(&deposits, batchInsertSize) + deduped := db.gorm.Clauses(clause.OnConflict{Columns: []clause.Column{{Name: "transaction_source_hash"}}, DoNothing: true}) + result := deduped.Create(&deposits) + if result.Error == nil && int(result.RowsAffected) < len(deposits) { + db.log.Warn("ignored L1 bridge transfer duplicates", "duplicates", len(deposits)-int(result.RowsAffected)) + } + return result.Error } @@ -128,6 +138,17 @@ type L1BridgeDepositsResponse struct { HasNextPage bool } +// L1BridgeDepositSum ... returns the sum of all l1 bridge deposit mints in gwei +func (db *bridgeTransfersDB) L1BridgeDepositSum() (float64, error) { + var sum float64 + result := db.gorm.Model(&L1TransactionDeposit{}).Select("sum(amount)").Scan(&sum) + if result.Error != nil { + return 0, result.Error + } + + return sum, nil +} + // L1BridgeDepositsByAddress retrieves a list of deposits initiated by the specified address, // coupled with the L1/L2 transaction hashes that complete the bridge transaction. func (db *bridgeTransfersDB) L1BridgeDepositsByAddress(address common.Address, cursor string, limit int) (*L1BridgeDepositsResponse, error) { @@ -146,12 +167,11 @@ func (db *bridgeTransfersDB) L1BridgeDepositsByAddress(address common.Address, c cursorClause = fmt.Sprintf("l1_transaction_deposits.timestamp <= %d", txDeposit.Tx.Timestamp) } - // TODO join with l1_bridged_tokens and l2_bridged_tokens ethAddressString := predeploys.LegacyERC20ETHAddr.String() // Coalesce l1 transaction deposits that are simply ETH sends ethTransactionDeposits := db.gorm.Model(&L1TransactionDeposit{}) - ethTransactionDeposits = ethTransactionDeposits.Where(&Transaction{FromAddress: address}).Where("data = '0x' AND amount > 0") + ethTransactionDeposits = ethTransactionDeposits.Where(&Transaction{FromAddress: address}).Where("amount > 0") ethTransactionDeposits = ethTransactionDeposits.Joins("INNER JOIN l1_contract_events ON l1_contract_events.guid = initiated_l1_event_guid") ethTransactionDeposits = ethTransactionDeposits.Select(` from_address, to_address, amount, data, source_hash AS transaction_source_hash, @@ -204,7 +224,12 @@ l1_bridge_deposits.timestamp, cross_domain_message_hash, local_token_address, re */ func (db *bridgeTransfersDB) StoreL2BridgeWithdrawals(withdrawals []L2BridgeWithdrawal) error { - result := db.gorm.CreateInBatches(&withdrawals, batchInsertSize) + deduped := db.gorm.Clauses(clause.OnConflict{Columns: []clause.Column{{Name: "transaction_withdrawal_hash"}}, DoNothing: true}) + result := deduped.Create(&withdrawals) + if result.Error == nil && int(result.RowsAffected) < len(withdrawals) { + db.log.Warn("ignored L2 bridge transfer duplicates", "duplicates", len(withdrawals)-int(result.RowsAffected)) + } + return result.Error } @@ -221,6 +246,16 @@ func (db *bridgeTransfersDB) L2BridgeWithdrawal(txWithdrawalHash common.Hash) (* return &withdrawal, nil } +func (db *bridgeTransfersDB) L2BridgeWithdrawalSum() (float64, error) { + var sum float64 + result := db.gorm.Model(&L2TransactionWithdrawal{}).Select("sum(amount)").Scan(&sum) + if result.Error != nil { + return 0, result.Error + } + + return sum, nil +} + // L2BridgeWithdrawalWithFilter queries for a bridge withdrawal with set fields in the `BridgeTransfer` filter func (db *bridgeTransfersDB) L2BridgeWithdrawalWithFilter(filter BridgeTransfer) (*L2BridgeWithdrawal, error) { var withdrawal L2BridgeWithdrawal @@ -270,7 +305,7 @@ func (db *bridgeTransfersDB) L2BridgeWithdrawalsByAddress(address common.Address // Coalesce l2 transaction withdrawals that are simply ETH sends ethTransactionWithdrawals := db.gorm.Model(&L2TransactionWithdrawal{}) - ethTransactionWithdrawals = ethTransactionWithdrawals.Where(&Transaction{FromAddress: address}).Where(`data = '0x' AND amount > 0`) + ethTransactionWithdrawals = ethTransactionWithdrawals.Where(&Transaction{FromAddress: address}).Where("amount > 0") ethTransactionWithdrawals = ethTransactionWithdrawals.Joins("INNER JOIN l2_contract_events ON l2_contract_events.guid = l2_transaction_withdrawals.initiated_l2_event_guid") ethTransactionWithdrawals = ethTransactionWithdrawals.Joins("LEFT JOIN l1_contract_events AS proven_l1_events ON proven_l1_events.guid = l2_transaction_withdrawals.proven_l1_event_guid") ethTransactionWithdrawals = ethTransactionWithdrawals.Joins("LEFT JOIN l1_contract_events AS finalized_l1_events ON finalized_l1_events.guid = l2_transaction_withdrawals.finalized_l1_event_guid") diff --git a/indexer/database/contract_events.go b/indexer/database/contract_events.go index 33e4c0fcef093..48aa5a39f6197 100644 --- a/indexer/database/contract_events.go +++ b/indexer/database/contract_events.go @@ -6,9 +6,11 @@ import ( "math/big" "gorm.io/gorm" + "gorm.io/gorm/clause" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/core/types" + "github.com/ethereum/go-ethereum/log" "github.com/google/uuid" ) @@ -99,17 +101,25 @@ type ContractEventsDB interface { */ type contractEventsDB struct { + log log.Logger gorm *gorm.DB } -func newContractEventsDB(db *gorm.DB) ContractEventsDB { - return &contractEventsDB{gorm: db} +func newContractEventsDB(log log.Logger, db *gorm.DB) ContractEventsDB { + return &contractEventsDB{log: log.New("table", "events"), gorm: db} } // L1 func (db *contractEventsDB) StoreL1ContractEvents(events []L1ContractEvent) error { - result := db.gorm.CreateInBatches(&events, batchInsertSize) + // Since the block hash refers back to L1, we dont necessarily have to check + // that the RLP bytes match when doing conflict resolution. + deduped := db.gorm.Clauses(clause.OnConflict{OnConstraint: "l1_contract_events_block_hash_log_index_key", DoNothing: true}) + result := deduped.Create(&events) + if result.Error == nil && int(result.RowsAffected) < len(events) { + db.log.Warn("ignored L1 contract event duplicates", "duplicates", len(events)-int(result.RowsAffected)) + } + return result.Error } @@ -144,7 +154,7 @@ func (db *contractEventsDB) L1ContractEventsWithFilter(filter ContractEvent, fro query := db.gorm.Table("l1_contract_events").Where(&filter) query = query.Joins("INNER JOIN l1_block_headers ON l1_contract_events.block_hash = l1_block_headers.hash") query = query.Where("l1_block_headers.number >= ? AND l1_block_headers.number <= ?", fromHeight, toHeight) - query = query.Order("l1_block_headers.number ASC").Select("l1_contract_events.*") + query = query.Order("l1_block_headers.number ASC, l1_contract_events.log_index ASC").Select("l1_contract_events.*") // NOTE: We use `Find` here instead of `Scan` since `Scan` doesn't not support // model hooks like `ContractEvent#AfterFind`. Functionally they are the same @@ -176,7 +186,14 @@ func (db *contractEventsDB) L1LatestContractEventWithFilter(filter ContractEvent // L2 func (db *contractEventsDB) StoreL2ContractEvents(events []L2ContractEvent) error { - result := db.gorm.CreateInBatches(&events, batchInsertSize) + // Since the block hash refers back to L2, we dont necessarily have to check + // that the RLP bytes match when doing conflict resolution. + deduped := db.gorm.Clauses(clause.OnConflict{OnConstraint: "l2_contract_events_block_hash_log_index_key", DoNothing: true}) + result := deduped.Create(&events) + if result.Error == nil && int(result.RowsAffected) < len(events) { + db.log.Warn("ignored L2 contract event duplicates", "duplicates", len(events)-int(result.RowsAffected)) + } + return result.Error } @@ -211,7 +228,7 @@ func (db *contractEventsDB) L2ContractEventsWithFilter(filter ContractEvent, fro query := db.gorm.Table("l2_contract_events").Where(&filter) query = query.Joins("INNER JOIN l2_block_headers ON l2_contract_events.block_hash = l2_block_headers.hash") query = query.Where("l2_block_headers.number >= ? AND l2_block_headers.number <= ?", fromHeight, toHeight) - query = query.Order("l2_block_headers.number ASC").Select("l2_contract_events.*") + query = query.Order("l2_block_headers.number ASC, l2_contract_events.log_index ASC").Select("l2_contract_events.*") // NOTE: We use `Find` here instead of `Scan` since `Scan` doesn't not support // model hooks like `ContractEvent#AfterFind`. Functionally they are the same diff --git a/indexer/database/db.go b/indexer/database/db.go index de363224f238c..fdb8db253a041 100644 --- a/indexer/database/db.go +++ b/indexer/database/db.go @@ -10,6 +10,7 @@ import ( "github.com/ethereum-optimism/optimism/indexer/config" _ "github.com/ethereum-optimism/optimism/indexer/database/serializers" "github.com/ethereum-optimism/optimism/op-service/retry" + "github.com/pkg/errors" "github.com/ethereum/go-ethereum/log" @@ -18,16 +19,9 @@ import ( "gorm.io/gorm" ) -var ( - // The postgres parameter counter for a given query is stored via a uint16, - // resulting in a parameter limit of 65535. In order to avoid reaching this limit - // we'll utilize a batch size of 3k for inserts, well below as long as the the number - // of columns < 20. - batchInsertSize int = 3_000 -) - type DB struct { gorm *gorm.DB + log log.Logger Blocks BlocksDB ContractEvents ContractEventsDB @@ -36,8 +30,10 @@ type DB struct { BridgeTransactions BridgeTransactionsDB } -func NewDB(log log.Logger, dbConfig config.DBConfig) (*DB, error) { - retryStrategy := &retry.ExponentialStrategy{Min: 1000, Max: 20_000, MaxJitter: 250} +// NewDB connects to the configured DB, and provides client-bindings to it. +// The initial connection may fail, or the dial may be cancelled with the provided context. +func NewDB(ctx context.Context, log log.Logger, dbConfig config.DBConfig) (*DB, error) { + log = log.New("module", "db") dsn := fmt.Sprintf("host=%s dbname=%s sslmode=disable", dbConfig.Host, dbConfig.Name) if dbConfig.Port != 0 { @@ -51,11 +47,19 @@ func NewDB(log log.Logger, dbConfig config.DBConfig) (*DB, error) { } gormConfig := gorm.Config{ + Logger: newLogger(log), + // The indexer will explicitly manage the transactions SkipDefaultTransaction: true, - Logger: newLogger(log), + + // The postgres parameter counter for a given query is represented with uint16, + // resulting in a parameter limit of 65535. In order to avoid reaching this limit + // we'll utilize a batch size of 3k for inserts, well below the limit as long as + // the number of columns < 20. + CreateBatchSize: 3_000, } + retryStrategy := &retry.ExponentialStrategy{Min: 1000, Max: 20_000, MaxJitter: 250} gorm, err := retry.Do[*gorm.DB](context.Background(), 10, retryStrategy, func() (*gorm.DB, error) { gorm, err := gorm.Open(postgres.Open(dsn), &gormConfig) if err != nil { @@ -66,16 +70,17 @@ func NewDB(log log.Logger, dbConfig config.DBConfig) (*DB, error) { }) if err != nil { - return nil, fmt.Errorf("failed to connect to database after multiple retries: %w", err) + return nil, err } db := &DB{ gorm: gorm, - Blocks: newBlocksDB(gorm), - ContractEvents: newContractEventsDB(gorm), - BridgeTransfers: newBridgeTransfersDB(gorm), - BridgeMessages: newBridgeMessagesDB(gorm), - BridgeTransactions: newBridgeTransactionsDB(gorm), + log: log, + Blocks: newBlocksDB(log, gorm), + ContractEvents: newContractEventsDB(log, gorm), + BridgeTransfers: newBridgeTransfersDB(log, gorm), + BridgeMessages: newBridgeMessagesDB(log, gorm), + BridgeTransactions: newBridgeTransactionsDB(log, gorm), } return db, nil @@ -85,11 +90,21 @@ func NewDB(log log.Logger, dbConfig config.DBConfig) (*DB, error) { // transaction. If the supplied function errors, the transaction is rolled back. func (db *DB) Transaction(fn func(db *DB) error) error { return db.gorm.Transaction(func(tx *gorm.DB) error { - return fn(dbFromGormTx(tx)) + txDB := &DB{ + gorm: tx, + Blocks: newBlocksDB(db.log, tx), + ContractEvents: newContractEventsDB(db.log, tx), + BridgeTransfers: newBridgeTransfersDB(db.log, tx), + BridgeMessages: newBridgeMessagesDB(db.log, tx), + BridgeTransactions: newBridgeTransactionsDB(db.log, tx), + } + + return fn(txDB) }) } func (db *DB) Close() error { + db.log.Info("closing database") sql, err := db.gorm.DB() if err != nil { return err @@ -98,17 +113,6 @@ func (db *DB) Close() error { return sql.Close() } -func dbFromGormTx(tx *gorm.DB) *DB { - return &DB{ - gorm: tx, - Blocks: newBlocksDB(tx), - ContractEvents: newContractEventsDB(tx), - BridgeTransfers: newBridgeTransfersDB(tx), - BridgeMessages: newBridgeMessagesDB(tx), - BridgeTransactions: newBridgeTransactionsDB(tx), - } -} - func (db *DB) ExecuteSQLMigration(migrationsFolder string) error { err := filepath.Walk(migrationsFolder, func(path string, info os.FileInfo, err error) error { // Check for any walking error @@ -122,12 +126,14 @@ func (db *DB) ExecuteSQLMigration(migrationsFolder string) error { } // Read the migration file content + db.log.Info("reading sql file", "path", path) fileContent, readErr := os.ReadFile(path) if readErr != nil { return errors.Wrap(readErr, fmt.Sprintf("Error reading SQL file: %s", path)) } // Execute the migration + db.log.Info("executing sql file", "path", path) execErr := db.gorm.Exec(string(fileContent)).Error if execErr != nil { return errors.Wrap(execErr, fmt.Sprintf("Error executing SQL script: %s", path)) @@ -136,5 +142,6 @@ func (db *DB) ExecuteSQLMigration(migrationsFolder string) error { return nil }) + db.log.Info("finished migrations") return err } diff --git a/indexer/database/logger.go b/indexer/database/logger.go index 52870abda2f3d..5ff7c0894924e 100644 --- a/indexer/database/logger.go +++ b/indexer/database/logger.go @@ -14,7 +14,7 @@ import ( var ( _ logger.Interface = Logger{} - SlowThresholdMilliseconds = 200 + SlowThresholdMilliseconds int64 = 500 ) type Logger struct { @@ -22,7 +22,7 @@ type Logger struct { } func newLogger(log log.Logger) Logger { - return Logger{log.New("module", "db")} + return Logger{log} } func (l Logger) LogMode(lvl logger.LogLevel) logger.Interface { @@ -50,7 +50,7 @@ func (l Logger) Trace(ctx context.Context, begin time.Time, fc func() (sql strin sql = fmt.Sprintf("%sVALUES (...)", sql[:i]) } - if elapsedMs < 200 { + if elapsedMs < SlowThresholdMilliseconds { l.log.Debug("database operation", "duration_ms", elapsedMs, "rows_affected", rows, "sql", sql) } else { l.log.Warn("database operation", "duration_ms", elapsedMs, "rows_affected", rows, "sql", sql) diff --git a/indexer/database/mocks.go b/indexer/database/mocks.go index 6ad6f5c6e6e64..d6005185b1cb1 100644 --- a/indexer/database/mocks.go +++ b/indexer/database/mocks.go @@ -1,9 +1,8 @@ package database import ( - "math/big" - "github.com/ethereum/go-ethereum/common" + "gorm.io/gorm" "github.com/stretchr/testify/mock" ) @@ -27,6 +26,11 @@ func (m *MockBlocksView) L1BlockHeaderWithFilter(BlockHeader) (*L1BlockHeader, e return args.Get(0).(*L1BlockHeader), args.Error(1) } +func (m *MockBlocksView) L1BlockHeaderWithScope(func(*gorm.DB) *gorm.DB) (*L1BlockHeader, error) { + args := m.Called() + return args.Get(0).(*L1BlockHeader), args.Error(1) +} + func (m *MockBlocksView) L1LatestBlockHeader() (*L1BlockHeader, error) { args := m.Called() @@ -48,14 +52,14 @@ func (m *MockBlocksView) L2BlockHeaderWithFilter(BlockHeader) (*L2BlockHeader, e return args.Get(0).(*L2BlockHeader), args.Error(1) } -func (m *MockBlocksView) L2LatestBlockHeader() (*L2BlockHeader, error) { +func (m *MockBlocksView) L2BlockHeaderWithScope(func(*gorm.DB) *gorm.DB) (*L2BlockHeader, error) { args := m.Called() - return args.Get(0).(*L2BlockHeader), args.Error(1) + return args.Get(0).(*L2BlockHeader), args.Error(2) } -func (m *MockBlocksView) LatestObservedEpoch(*big.Int, uint64) (*Epoch, error) { +func (m *MockBlocksView) L2LatestBlockHeader() (*L2BlockHeader, error) { args := m.Called() - return args.Get(0).(*Epoch), args.Error(1) + return args.Get(0).(*L2BlockHeader), args.Error(1) } type MockBlocksDB struct { diff --git a/indexer/database/serializers/bytes.go b/indexer/database/serializers/bytes.go index 8113572dbd387..c00cc96030854 100644 --- a/indexer/database/serializers/bytes.go +++ b/indexer/database/serializers/bytes.go @@ -4,6 +4,7 @@ import ( "context" "fmt" "reflect" + "strings" "github.com/ethereum/go-ethereum/common/hexutil" "gorm.io/gorm/schema" @@ -70,5 +71,5 @@ func (BytesSerializer) Value(ctx context.Context, field *schema.Field, dst refle } hexStr := hexutil.Encode(fieldBytes.Bytes()) - return hexStr, nil + return strings.ToLower(hexStr), nil } diff --git a/indexer/database/serializers/rlp.go b/indexer/database/serializers/rlp.go index 0bcf7cd910a1c..9af5a28df82ab 100644 --- a/indexer/database/serializers/rlp.go +++ b/indexer/database/serializers/rlp.go @@ -4,6 +4,7 @@ import ( "context" "fmt" "reflect" + "strings" "github.com/ethereum/go-ethereum/common/hexutil" "github.com/ethereum/go-ethereum/rlp" @@ -52,5 +53,5 @@ func (RLPSerializer) Value(ctx context.Context, field *schema.Field, dst reflect } hexStr := hexutil.Encode(rlpBytes) - return hexStr, nil + return strings.ToLower(hexStr), nil } diff --git a/indexer/docker-compose.yml b/indexer/docker-compose.yml index bf8499ca458f8..77c0d86d925a0 100644 --- a/indexer/docker-compose.yml +++ b/indexer/docker-compose.yml @@ -58,7 +58,6 @@ services: depends_on: postgres: condition: service_healthy - depends_on: migrations: condition: service_started @@ -155,7 +154,7 @@ services: - MAINNET_BEDROCK=true - TRM_API_KEY=$TRM_API_KEY - GOOGLE_CLOUD_STORAGE_BUCKET_NAME=oplabs-dev-web-content - # Recommened to uncomment for local dev unless you need it + # Recommend to uncomment for local dev unless you need it #- BYPASS_EVENT_LOG_POLLER_BOOTSTRAP=true ports: - 7422:7300 diff --git a/indexer/e2e_tests/bridge_messages_e2e_test.go b/indexer/e2e_tests/bridge_messages_e2e_test.go index 577ae2af3ce66..34b3b579fb861 100644 --- a/indexer/e2e_tests/bridge_messages_e2e_test.go +++ b/indexer/e2e_tests/bridge_messages_e2e_test.go @@ -43,7 +43,7 @@ func TestE2EBridgeL1CrossDomainMessenger(t *testing.T) { // wait for processor catchup require.NoError(t, wait.For(context.Background(), 500*time.Millisecond, func() (bool, error) { - l1Header := testSuite.Indexer.BridgeProcessor.LatestL1Header + l1Header := testSuite.Indexer.BridgeProcessor.LastL1Header return l1Header != nil && l1Header.Number.Uint64() >= sentMsgReceipt.BlockNumber.Uint64(), nil })) @@ -77,7 +77,7 @@ func TestE2EBridgeL1CrossDomainMessenger(t *testing.T) { l2DepositReceipt, err := wait.ForReceiptOK(context.Background(), testSuite.L2Client, transaction.L2TransactionHash) require.NoError(t, err) require.NoError(t, wait.For(context.Background(), 500*time.Millisecond, func() (bool, error) { - l2Header := testSuite.Indexer.BridgeProcessor.LatestL2Header + l2Header := testSuite.Indexer.BridgeProcessor.LastFinalizedL2Header return l2Header != nil && l2Header.Number.Uint64() >= l2DepositReceipt.BlockNumber.Uint64(), nil })) @@ -130,7 +130,7 @@ func TestE2EBridgeL2CrossDomainMessenger(t *testing.T) { // wait for processor catchup require.NoError(t, wait.For(context.Background(), 500*time.Millisecond, func() (bool, error) { - l2Header := testSuite.Indexer.BridgeProcessor.LatestL2Header + l2Header := testSuite.Indexer.BridgeProcessor.LastL2Header return l2Header != nil && l2Header.Number.Uint64() >= sentMsgReceipt.BlockNumber.Uint64(), nil })) @@ -159,7 +159,7 @@ func TestE2EBridgeL2CrossDomainMessenger(t *testing.T) { // wait for processor catchup require.NoError(t, wait.For(context.Background(), 500*time.Millisecond, func() (bool, error) { - l1Header := testSuite.Indexer.BridgeProcessor.LatestL1Header + l1Header := testSuite.Indexer.BridgeProcessor.LastFinalizedL1Header return l1Header != nil && l1Header.Number.Uint64() >= finalizedReceipt.BlockNumber.Uint64(), nil })) diff --git a/indexer/e2e_tests/bridge_transactions_e2e_test.go b/indexer/e2e_tests/bridge_transactions_e2e_test.go index d703615016bf5..3e80f43773063 100644 --- a/indexer/e2e_tests/bridge_transactions_e2e_test.go +++ b/indexer/e2e_tests/bridge_transactions_e2e_test.go @@ -49,7 +49,7 @@ func TestE2EBridgeTransactionsOptimismPortalDeposits(t *testing.T) { // wait for processor catchup require.NoError(t, wait.For(context.Background(), 500*time.Millisecond, func() (bool, error) { - l1Header := testSuite.Indexer.BridgeProcessor.LatestL1Header + l1Header := testSuite.Indexer.BridgeProcessor.LastL1Header return l1Header != nil && l1Header.Number.Uint64() >= depositReceipt.BlockNumber.Uint64(), nil })) @@ -104,7 +104,7 @@ func TestE2EBridgeTransactionsL2ToL1MessagePasserWithdrawal(t *testing.T) { // wait for processor catchup require.NoError(t, wait.For(context.Background(), 500*time.Millisecond, func() (bool, error) { - l2Header := testSuite.Indexer.BridgeProcessor.LatestL2Header + l2Header := testSuite.Indexer.BridgeProcessor.LastL2Header return l2Header != nil && l2Header.Number.Uint64() >= withdrawReceipt.BlockNumber.Uint64(), nil })) @@ -134,7 +134,7 @@ func TestE2EBridgeTransactionsL2ToL1MessagePasserWithdrawal(t *testing.T) { withdrawParams, proveReceipt := op_e2e.ProveWithdrawal(t, *testSuite.OpCfg, testSuite.L1Client, testSuite.OpSys.EthInstances["sequencer"], testSuite.OpCfg.Secrets.Alice, withdrawReceipt) require.NoError(t, wait.For(context.Background(), 500*time.Millisecond, func() (bool, error) { - l1Header := testSuite.Indexer.BridgeProcessor.LatestL1Header + l1Header := testSuite.Indexer.BridgeProcessor.LastFinalizedL1Header return l1Header != nil && l1Header.Number.Uint64() >= proveReceipt.BlockNumber.Uint64(), nil })) @@ -152,7 +152,7 @@ func TestE2EBridgeTransactionsL2ToL1MessagePasserWithdrawal(t *testing.T) { finalizeReceipt := op_e2e.FinalizeWithdrawal(t, *testSuite.OpCfg, testSuite.L1Client, testSuite.OpCfg.Secrets.Alice, proveReceipt, withdrawParams) require.NoError(t, wait.For(context.Background(), 500*time.Millisecond, func() (bool, error) { - l1Header := testSuite.Indexer.BridgeProcessor.LatestL1Header + l1Header := testSuite.Indexer.BridgeProcessor.LastFinalizedL1Header return l1Header != nil && l1Header.Number.Uint64() >= finalizeReceipt.BlockNumber.Uint64(), nil })) @@ -194,7 +194,7 @@ func TestE2EBridgeTransactionsL2ToL1MessagePasserFailedWithdrawal(t *testing.T) // Prove&Finalize withdrawal _, finalizeReceipt := op_e2e.ProveAndFinalizeWithdrawal(t, *testSuite.OpCfg, testSuite.L1Client, testSuite.OpSys.EthInstances["sequencer"], testSuite.OpCfg.Secrets.Alice, withdrawReceipt) require.NoError(t, wait.For(context.Background(), 500*time.Millisecond, func() (bool, error) { - l1Header := testSuite.Indexer.BridgeProcessor.LatestL1Header + l1Header := testSuite.Indexer.BridgeProcessor.LastFinalizedL1Header return l1Header != nil && l1Header.Number.Uint64() >= finalizeReceipt.BlockNumber.Uint64(), nil })) diff --git a/indexer/e2e_tests/bridge_transfers_e2e_test.go b/indexer/e2e_tests/bridge_transfers_e2e_test.go index 1c7405b121b51..92124b5a13541 100644 --- a/indexer/e2e_tests/bridge_transfers_e2e_test.go +++ b/indexer/e2e_tests/bridge_transfers_e2e_test.go @@ -8,6 +8,7 @@ import ( "testing" "time" + "github.com/ethereum-optimism/optimism/indexer/bigint" e2etest_utils "github.com/ethereum-optimism/optimism/indexer/e2e_tests/utils" op_e2e "github.com/ethereum-optimism/optimism/op-e2e" "github.com/ethereum-optimism/optimism/op-e2e/e2eutils/transactions" @@ -47,7 +48,7 @@ func TestE2EBridgeTransfersStandardBridgeETHDeposit(t *testing.T) { // wait for processor catchup require.NoError(t, wait.For(context.Background(), 500*time.Millisecond, func() (bool, error) { - l1Header := testSuite.Indexer.BridgeProcessor.LatestL1Header + l1Header := testSuite.Indexer.BridgeProcessor.LastL1Header return l1Header != nil && l1Header.Number.Uint64() >= depositReceipt.BlockNumber.Uint64(), nil })) @@ -81,7 +82,7 @@ func TestE2EBridgeTransfersStandardBridgeETHDeposit(t *testing.T) { l2DepositReceipt, err := wait.ForReceiptOK(context.Background(), testSuite.L2Client, types.NewTx(depositInfo.DepositTx).Hash()) require.NoError(t, err) require.NoError(t, wait.For(context.Background(), 500*time.Millisecond, func() (bool, error) { - l2Header := testSuite.Indexer.BridgeProcessor.LatestL2Header + l2Header := testSuite.Indexer.BridgeProcessor.LastFinalizedL2Header return l2Header != nil && l2Header.Number.Uint64() >= l2DepositReceipt.BlockNumber.Uint64(), nil })) @@ -114,7 +115,7 @@ func TestE2EBridgeTransfersOptimismPortalETHReceive(t *testing.T) { // wait for processor catchup require.NoError(t, wait.For(context.Background(), 500*time.Millisecond, func() (bool, error) { - l1Header := testSuite.Indexer.BridgeProcessor.LatestL1Header + l1Header := testSuite.Indexer.BridgeProcessor.LastL1Header return l1Header != nil && l1Header.Number.Uint64() >= portalDepositReceipt.BlockNumber.Uint64(), nil })) @@ -140,7 +141,7 @@ func TestE2EBridgeTransfersOptimismPortalETHReceive(t *testing.T) { l2DepositReceipt, err := wait.ForReceiptOK(context.Background(), testSuite.L2Client, types.NewTx(depositInfo.DepositTx).Hash()) require.NoError(t, err) require.NoError(t, wait.For(context.Background(), 500*time.Millisecond, func() (bool, error) { - l2Header := testSuite.Indexer.BridgeProcessor.LatestL2Header + l2Header := testSuite.Indexer.BridgeProcessor.LastFinalizedL2Header return l2Header != nil && l2Header.Number.Uint64() >= l2DepositReceipt.BlockNumber.Uint64(), nil })) @@ -182,7 +183,7 @@ func TestE2EBridgeTransfersCursoredDeposits(t *testing.T) { // wait for processor catchup of the latest tx require.NoError(t, wait.For(context.Background(), 500*time.Millisecond, func() (bool, error) { - l1Header := testSuite.Indexer.BridgeProcessor.LatestL1Header + l1Header := testSuite.Indexer.BridgeProcessor.LastL1Header return l1Header != nil && l1Header.Number.Uint64() >= depositReceipts[2].BlockNumber.Uint64(), nil })) @@ -250,7 +251,7 @@ func TestE2EBridgeTransfersStandardBridgeETHWithdrawal(t *testing.T) { // wait for processor catchup require.NoError(t, wait.For(context.Background(), 500*time.Millisecond, func() (bool, error) { - l2Header := testSuite.Indexer.BridgeProcessor.LatestL2Header + l2Header := testSuite.Indexer.BridgeProcessor.LastL2Header return l2Header != nil && l2Header.Number.Uint64() >= withdrawReceipt.BlockNumber.Uint64(), nil })) @@ -288,7 +289,7 @@ func TestE2EBridgeTransfersStandardBridgeETHWithdrawal(t *testing.T) { // wait for processor catchup proveReceipt, finalizeReceipt := op_e2e.ProveAndFinalizeWithdrawal(t, *testSuite.OpCfg, testSuite.L1Client, testSuite.OpSys.EthInstances["sequencer"], testSuite.OpCfg.Secrets.Alice, withdrawReceipt) require.NoError(t, wait.For(context.Background(), 500*time.Millisecond, func() (bool, error) { - l1Header := testSuite.Indexer.BridgeProcessor.LatestL1Header + l1Header := testSuite.Indexer.BridgeProcessor.LastFinalizedL1Header return l1Header != nil && l1Header.Number.Uint64() >= finalizeReceipt.BlockNumber.Uint64(), nil })) @@ -334,7 +335,7 @@ func TestE2EBridgeTransfersL2ToL1MessagePasserETHReceive(t *testing.T) { // wait for processor catchup require.NoError(t, wait.For(context.Background(), 500*time.Millisecond, func() (bool, error) { - l2Header := testSuite.Indexer.BridgeProcessor.LatestL2Header + l2Header := testSuite.Indexer.BridgeProcessor.LastL2Header return l2Header != nil && l2Header.Number.Uint64() >= l2ToL1WithdrawReceipt.BlockNumber.Uint64(), nil })) @@ -367,7 +368,7 @@ func TestE2EBridgeTransfersL2ToL1MessagePasserETHReceive(t *testing.T) { // wait for processor catchup proveReceipt, finalizeReceipt := op_e2e.ProveAndFinalizeWithdrawal(t, *testSuite.OpCfg, testSuite.L1Client, testSuite.OpSys.EthInstances["sequencer"], testSuite.OpCfg.Secrets.Alice, l2ToL1WithdrawReceipt) require.NoError(t, wait.For(context.Background(), 500*time.Millisecond, func() (bool, error) { - l1Header := testSuite.Indexer.BridgeProcessor.LatestL1Header + l1Header := testSuite.Indexer.BridgeProcessor.LastFinalizedL1Header return l1Header != nil && l1Header.Number.Uint64() >= finalizeReceipt.BlockNumber.Uint64(), nil })) @@ -410,7 +411,7 @@ func TestE2EBridgeTransfersCursoredWithdrawals(t *testing.T) { // wait for processor catchup of the latest tx require.NoError(t, wait.For(context.Background(), 500*time.Millisecond, func() (bool, error) { - l2Header := testSuite.Indexer.BridgeProcessor.LatestL2Header + l2Header := testSuite.Indexer.BridgeProcessor.LastL2Header return l2Header != nil && l2Header.Number.Uint64() >= withdrawReceipts[2].BlockNumber.Uint64(), nil })) @@ -447,7 +448,7 @@ func TestE2EBridgeTransfersCursoredWithdrawals(t *testing.T) { } } -func TestClientGetWithdrawals(t *testing.T) { +func TestClientBridgeFunctions(t *testing.T) { testSuite := createE2ETestSuite(t) // (1) Generate contract bindings for the L1 and L2 standard bridges @@ -459,12 +460,16 @@ func TestClientGetWithdrawals(t *testing.T) { // (2) Create test actors that will deposit and withdraw using the standard bridge aliceAddr := testSuite.OpCfg.Secrets.Addresses().Alice bobAddr := testSuite.OpCfg.Secrets.Addresses().Bob + malAddr := testSuite.OpCfg.Secrets.Addresses().Mallory type actor struct { addr common.Address priv *ecdsa.PrivateKey } + mintSum := bigint.Zero + withdrawSum := bigint.Zero + actors := []actor{ { addr: aliceAddr, @@ -474,6 +479,10 @@ func TestClientGetWithdrawals(t *testing.T) { addr: bobAddr, priv: testSuite.OpCfg.Secrets.Bob, }, + { + addr: malAddr, + priv: testSuite.OpCfg.Secrets.Mallory, + }, } // (3) Iterate over each actor and deposit / withdraw @@ -488,21 +497,28 @@ func TestClientGetWithdrawals(t *testing.T) { l1Opts.Value = l2Opts.Value depositTx, err := optimismPortal.Receive(l1Opts) require.NoError(t, err) - _, err = wait.ForReceiptOK(context.Background(), testSuite.L1Client, depositTx.Hash()) + depositReceipt, err := wait.ForReceiptOK(context.Background(), testSuite.L1Client, depositTx.Hash()) require.NoError(t, err) + mintSum = new(big.Int).Add(mintSum, depositTx.Value()) + // (3.b) Initiate withdrawal transaction via L2ToL1MessagePasser contract l2ToL1MessagePasserWithdrawTx, err := l2ToL1MessagePasser.Receive(l2Opts) require.NoError(t, err) l2ToL1WithdrawReceipt, err := wait.ForReceiptOK(context.Background(), testSuite.L2Client, l2ToL1MessagePasserWithdrawTx.Hash()) require.NoError(t, err) - // (3.c) wait for indexer processor to catchup with the L2 block containing the withdrawal tx + // (3.c) wait for indexer processor to catchup with the L1 & L2 block containing the deposit & withdrawal tx require.NoError(t, wait.For(context.Background(), 500*time.Millisecond, func() (bool, error) { - l2Header := testSuite.Indexer.BridgeProcessor.LatestL2Header - return l2Header != nil && l2Header.Number.Uint64() >= l2ToL1WithdrawReceipt.BlockNumber.Uint64(), nil + l1Header := testSuite.Indexer.BridgeProcessor.LastL1Header + l2Header := testSuite.Indexer.BridgeProcessor.LastL2Header + seenL2 := l2Header != nil && l2Header.Number.Uint64() >= l2ToL1WithdrawReceipt.BlockNumber.Uint64() + seenL1 := l1Header != nil && l1Header.Number.Uint64() >= depositReceipt.BlockNumber.Uint64() + return seenL1 && seenL2, nil })) + withdrawSum = new(big.Int).Add(withdrawSum, l2ToL1MessagePasserWithdrawTx.Value()) + // (3.d) Ensure that withdrawal and deposit txs are retrievable via API deposits, err := testSuite.Client.GetAllDepositsByAddress(actor.addr) require.NoError(t, err) @@ -513,6 +529,17 @@ func TestClientGetWithdrawals(t *testing.T) { require.NoError(t, err) require.Len(t, withdrawals, 1) require.Equal(t, l2ToL1MessagePasserWithdrawTx.Hash().String(), withdrawals[0].TransactionHash) + } + // (4) Ensure that supply assessment is correct + assessment, err := testSuite.Client.GetSupplyAssessment() + require.NoError(t, err) + + mintFloat, _ := mintSum.Float64() + require.Equal(t, mintFloat, assessment.L1DepositSum) + + withdrawFloat, _ := withdrawSum.Float64() + require.Equal(t, withdrawFloat, assessment.L2WithdrawalSum) + } diff --git a/indexer/e2e_tests/setup.go b/indexer/e2e_tests/setup.go index ebd69112c8aa5..15126bd1fff8e 100644 --- a/indexer/e2e_tests/setup.go +++ b/indexer/e2e_tests/setup.go @@ -34,7 +34,7 @@ type E2ETestSuite struct { // API Client *client.Client - API *api.API + API *api.APIService // Indexer DB *database.DB @@ -73,7 +73,7 @@ func createE2ETestSuite(t *testing.T) E2ETestSuite { t.Cleanup(func() { opSys.Close() }) // Indexer Configuration and Start - indexerCfg := config.Config{ + indexerCfg := &config.Config{ DB: config.DBConfig{ Host: "127.0.0.1", Port: 5432, @@ -106,51 +106,40 @@ func createE2ETestSuite(t *testing.T) E2ETestSuite { // the system is running, mark this test for Parallel execution t.Parallel() - // provide a DB for the unit test. disable logging - silentLog := testlog.Logger(t, log.LvlInfo) - silentLog.SetHandler(log.DiscardHandler()) - db, err := database.NewDB(silentLog, indexerCfg.DB) - require.NoError(t, err) - t.Cleanup(func() { db.Close() }) - indexerLog := testlog.Logger(t, log.LvlInfo).New("role", "indexer") - indexer, err := indexer.NewIndexer(indexerLog, db, indexerCfg.Chain, indexerCfg.RPCs, indexerCfg.HTTPServer, indexerCfg.MetricsServer) + ix, err := indexer.NewIndexer(context.Background(), indexerLog, indexerCfg, func(cause error) { + if cause != nil { + t.Fatalf("indexer shut down with critical error: %v", cause) + } + }) require.NoError(t, err) - indexerCtx, indexerStop := context.WithCancel(context.Background()) - go func() { - err := indexer.Run(indexerCtx) - if err != nil { // panicking here ensures that the test will exit - // during service failure. Using t.Fail() wouldn't be caught - // until all awaiting routines finish which would never happen. - panic(err) - } - }() + require.NoError(t, ix.Start(context.Background()), "cleanly start indexer") - apiLog := testlog.Logger(t, log.LvlInfo).New("role", "indexer_api") + t.Cleanup(func() { + require.NoError(t, ix.Stop(context.Background()), "cleanly shut down indexer") + }) - apiCfg := config.ServerConfig{ - Host: "127.0.0.1", - Port: 0, - } + apiLog := testlog.Logger(t, log.LvlInfo).New("role", "indexer_api") - mCfg := config.ServerConfig{ - Host: "127.0.0.1", - Port: 0, + apiCfg := &api.Config{ + DB: &api.TestDBConnector{BridgeTransfers: ix.DB.BridgeTransfers}, // reuse the same DB + HTTPServer: config.ServerConfig{ + Host: "127.0.0.1", + Port: 0, + }, + MetricsServer: config.ServerConfig{ + Host: "127.0.0.1", + Port: 0, + }, } - api := api.NewApi(apiLog, db.BridgeTransfers, apiCfg, mCfg) - apiCtx, apiStop := context.WithCancel(context.Background()) - go func() { - err := api.Run(apiCtx) - if err != nil { - panic(err) - } - }() + apiService, err := api.NewApi(context.Background(), apiLog, apiCfg) + require.NoError(t, err, "create indexer API service") + require.NoError(t, apiService.Start(context.Background()), "start indexer API service") t.Cleanup(func() { - apiStop() - indexerStop() + require.NoError(t, apiService.Stop(context.Background()), "cleanly shut down indexer") }) // Wait for the API to start listening @@ -158,16 +147,15 @@ func createE2ETestSuite(t *testing.T) E2ETestSuite { client, err := client.NewClient(&client.Config{ PaginationLimit: 100, - BaseURL: fmt.Sprintf("http://%s:%d", apiCfg.Host, api.Port()), + BaseURL: "http://" + apiService.Addr(), }) - - require.NoError(t, err) + require.NoError(t, err, "must open indexer API client") return E2ETestSuite{ t: t, Client: client, - DB: db, - Indexer: indexer, + DB: ix.DB, + Indexer: ix, OpCfg: &opCfg, OpSys: opSys, L1Client: opSys.Clients["l1"], @@ -203,7 +191,7 @@ func setupTestDatabase(t *testing.T) string { silentLog := log.New() silentLog.SetHandler(log.DiscardHandler()) - db, err := database.NewDB(silentLog, dbConfig) + db, err := database.NewDB(context.Background(), silentLog, dbConfig) require.NoError(t, err) defer db.Close() diff --git a/indexer/etl/etl.go b/indexer/etl/etl.go index c69d1a6e73974..1938b3bceb894 100644 --- a/indexer/etl/etl.go +++ b/indexer/etl/etl.go @@ -3,14 +3,17 @@ package etl import ( "context" "errors" + "fmt" "math/big" "time" - "github.com/ethereum-optimism/optimism/indexer/node" "github.com/ethereum/go-ethereum" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/core/types" "github.com/ethereum/go-ethereum/log" + + "github.com/ethereum-optimism/optimism/indexer/node" + "github.com/ethereum-optimism/optimism/op-service/clock" ) type Config struct { @@ -30,9 +33,15 @@ type ETL struct { headerTraversal *node.HeaderTraversal contracts []common.Address - etlBatches chan ETLBatch + etlBatches chan *ETLBatch EthClient node.EthClient + + // A reference that'll stay populated between intervals + // in the event of failures in order to retry. + headers []types.Header + + worker *clock.LoopFn } type ETLBatch struct { @@ -45,47 +54,53 @@ type ETLBatch struct { HeadersWithLog map[common.Hash]bool } -func (etl *ETL) Start(ctx context.Context) error { - done := ctx.Done() - pollTicker := time.NewTicker(etl.loopInterval) - defer pollTicker.Stop() +// Start starts the ETL polling routine. The ETL work should be stopped with Close(). +func (etl *ETL) Start() error { + if etl.worker != nil { + return errors.New("already started") + } + etl.worker = clock.NewLoopFn(clock.SystemClock, etl.tick, func() error { + etl.log.Info("shutting down batch producer") + close(etl.etlBatches) // can close the channel now, to signal to the consumer that we're done + return nil + }, etl.loopInterval) + return nil +} - // A reference that'll stay populated between intervals - // in the event of failures in order to retry. - var headers []types.Header - - etl.log.Info("starting etl...") - for { - select { - case <-done: - etl.log.Info("stopping etl") - return nil - - case <-pollTicker.C: - done := etl.metrics.RecordInterval() - if len(headers) > 0 { - etl.log.Info("retrying previous batch") - } else { - newHeaders, err := etl.headerTraversal.NextFinalizedHeaders(etl.headerBufferSize) - if err != nil { - etl.log.Error("error querying for headers", "err", err) - } else if len(newHeaders) == 0 { - etl.log.Warn("no new headers. processor unexpectedly at head...") - } else { - headers = newHeaders - etl.metrics.RecordBatchHeaders(len(newHeaders)) - } - } - - // only clear the reference if we were able to process this batch - err := etl.processBatch(headers) - if err == nil { - headers = nil - } - - done(err) +func (etl *ETL) Close() error { + if etl.worker == nil { + return nil // worker was not running + } + return etl.worker.Close() +} + +func (etl *ETL) tick(_ context.Context) { + done := etl.metrics.RecordInterval() + if len(etl.headers) > 0 { + etl.log.Info("retrying previous batch") + } else { + newHeaders, err := etl.headerTraversal.NextHeaders(etl.headerBufferSize) + if err != nil { + etl.log.Error("error querying for headers", "err", err) + } else if len(newHeaders) == 0 { + etl.log.Warn("no new headers. etl at head?") + } else { + etl.headers = newHeaders + } + + latestHeader := etl.headerTraversal.LatestHeader() + if latestHeader != nil { + etl.metrics.RecordLatestHeight(latestHeader.Number) } } + + // only clear the reference if we were able to process this batch + err := etl.processBatch(etl.headers) + if err == nil { + etl.headers = nil + } + + done(err) } func (etl *ETL) processBatch(headers []types.Header) error { @@ -97,7 +112,6 @@ func (etl *ETL) processBatch(headers []types.Header) error { batchLog := etl.log.New("batch_start_block_number", firstHeader.Number, "batch_end_block_number", lastHeader.Number) batchLog.Info("extracting batch", "size", len(headers)) - etl.metrics.RecordBatchLatestHeight(lastHeader.Number) headerMap := make(map[common.Hash]*types.Header, len(headers)) for i := range headers { header := headers[i] @@ -105,31 +119,40 @@ func (etl *ETL) processBatch(headers []types.Header) error { } headersWithLog := make(map[common.Hash]bool, len(headers)) - logs, err := etl.EthClient.FilterLogs(ethereum.FilterQuery{FromBlock: firstHeader.Number, ToBlock: lastHeader.Number, Addresses: etl.contracts}) + filterQuery := ethereum.FilterQuery{FromBlock: firstHeader.Number, ToBlock: lastHeader.Number, Addresses: etl.contracts} + logs, err := etl.EthClient.FilterLogs(filterQuery) if err != nil { batchLog.Info("failed to extract logs", "err", err) return err } - if len(logs) > 0 { - batchLog.Info("detected logs", "size", len(logs)) + + if logs.ToBlockHeader.Number.Cmp(lastHeader.Number) != 0 { + // Warn and simply wait for the provider to synchronize state + batchLog.Warn("mismatch in FilterLog#ToBlock number", "queried_to_block_number", lastHeader.Number, "reported_to_block_number", logs.ToBlockHeader.Number) + return fmt.Errorf("mismatch in FilterLog#ToBlock number") + } else if logs.ToBlockHeader.Hash() != lastHeader.Hash() { + batchLog.Error("mismatch in FitlerLog#ToBlock block hash!!!", "queried_to_block_hash", lastHeader.Hash().String(), "reported_to_block_hash", logs.ToBlockHeader.Hash().String()) + return fmt.Errorf("mismatch in FitlerLog#ToBlock block hash!!!") + } + + if len(logs.Logs) > 0 { + batchLog.Info("detected logs", "size", len(logs.Logs)) } - for i := range logs { - log := logs[i] + for i := range logs.Logs { + log := logs.Logs[i] + headersWithLog[log.BlockHash] = true if _, ok := headerMap[log.BlockHash]; !ok { // NOTE. Definitely an error state if the none of the headers were re-orged out in between // the blocks and logs retrieval operations. Unlikely as long as the confirmation depth has // been appropriately set or when we get to natively handling reorgs. - batchLog.Error("log found with block hash not in the batch", "block_hash", logs[i].BlockHash, "log_index", logs[i].Index) + batchLog.Error("log found with block hash not in the batch", "block_hash", logs.Logs[i].BlockHash, "log_index", logs.Logs[i].Index) return errors.New("parsed log with a block hash not in the batch") } - - etl.metrics.RecordBatchLog(log.Address) - headersWithLog[log.BlockHash] = true } // ensure we use unique downstream references for the etl batch headersRef := headers - etl.etlBatches <- ETLBatch{Logger: batchLog, Headers: headersRef, HeaderMap: headerMap, Logs: logs, HeadersWithLog: headersWithLog} + etl.etlBatches <- &ETLBatch{Logger: batchLog, Headers: headersRef, HeaderMap: headerMap, Logs: logs.Logs, HeadersWithLog: headersWithLog} return nil } diff --git a/indexer/etl/l1_etl.go b/indexer/etl/l1_etl.go index a4613928b0773..7ccdaaf891571 100644 --- a/indexer/etl/l1_etl.go +++ b/indexer/etl/l1_etl.go @@ -8,26 +8,37 @@ import ( "sync" "time" + "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/core/types" + "github.com/ethereum/go-ethereum/log" + "github.com/ethereum-optimism/optimism/indexer/config" "github.com/ethereum-optimism/optimism/indexer/database" "github.com/ethereum-optimism/optimism/indexer/node" "github.com/ethereum-optimism/optimism/op-service/retry" - "github.com/ethereum/go-ethereum/common" - "github.com/ethereum/go-ethereum/core/types" - "github.com/ethereum/go-ethereum/log" + "github.com/ethereum-optimism/optimism/op-service/tasks" ) type L1ETL struct { ETL + LatestHeader *types.Header + + // the batch handler may do work that we can interrupt on shutdown + resourceCtx context.Context + resourceCancel context.CancelFunc + + tasks tasks.Group - db *database.DB - mu *sync.Mutex + db *database.DB + + mu sync.Mutex listeners []chan interface{} } // NewL1ETL creates a new L1ETL instance that will start indexing from different starting points // depending on the state of the database and the supplied start height. -func NewL1ETL(cfg Config, log log.Logger, db *database.DB, metrics Metricer, client node.EthClient, contracts config.L1Contracts) (*L1ETL, error) { +func NewL1ETL(cfg Config, log log.Logger, db *database.DB, metrics Metricer, client node.EthClient, + contracts config.L1Contracts, shutdown context.CancelCauseFunc) (*L1ETL, error) { log = log.New("etl", "l1") zeroAddr := common.Address{} @@ -71,8 +82,10 @@ func NewL1ETL(cfg Config, log log.Logger, db *database.DB, metrics Metricer, cli } // NOTE - The use of un-buffered channel here assumes that downstream consumers - // will be able to keep up with the rate of incoming batches - etlBatches := make(chan ETLBatch) + // will be able to keep up with the rate of incoming batches. + // When the producer closes the channel we stop consuming from it. + etlBatches := make(chan *ETLBatch) + etl := ETL{ loopInterval: time.Duration(cfg.LoopIntervalMsec) * time.Millisecond, headerBufferSize: uint64(cfg.HeaderBufferSize), @@ -86,81 +99,122 @@ func NewL1ETL(cfg Config, log log.Logger, db *database.DB, metrics Metricer, cli EthClient: client, } - return &L1ETL{ETL: etl, db: db, mu: new(sync.Mutex)}, nil + resCtx, resCancel := context.WithCancel(context.Background()) + return &L1ETL{ + ETL: etl, + LatestHeader: fromHeader, + + db: db, + resourceCtx: resCtx, + resourceCancel: resCancel, + tasks: tasks.Group{HandleCrit: func(err error) { + shutdown(fmt.Errorf("critical error in L1 ETL: %w", err)) + }}, + }, nil } -func (l1Etl *L1ETL) Start(ctx context.Context) error { - errCh := make(chan error, 1) - go func() { - errCh <- l1Etl.ETL.Start(ctx) - }() +func (l1Etl *L1ETL) Close() error { + var result error + // close the producer + if err := l1Etl.ETL.Close(); err != nil { + result = errors.Join(result, fmt.Errorf("failed to close internal ETL: %w", err)) + } + // tell the consumer it can stop what it's doing + l1Etl.resourceCancel() + // wait for consumer to pick up on closure of producer + if err := l1Etl.tasks.Wait(); err != nil { + result = errors.Join(result, fmt.Errorf("failed to await batch handler completion: %w", err)) + } + // close listeners + for i := range l1Etl.listeners { + close(l1Etl.listeners[i]) + } + return result +} - for { - select { - case err := <-errCh: - return err - - // Index incoming batches (only L1 blocks that have an emitted log) - case batch := <-l1Etl.etlBatches: - l1BlockHeaders := make([]database.L1BlockHeader, 0, len(batch.Headers)) - for i := range batch.Headers { - if _, ok := batch.HeadersWithLog[batch.Headers[i].Hash()]; ok { - l1BlockHeaders = append(l1BlockHeaders, database.L1BlockHeader{BlockHeader: database.BlockHeaderFromHeader(&batch.Headers[i])}) - } - } - if len(l1BlockHeaders) == 0 { - batch.Logger.Info("no l1 blocks with logs in batch") - continue - } +func (l1Etl *L1ETL) Start() error { + l1Etl.log.Info("starting etl...") - l1ContractEvents := make([]database.L1ContractEvent, len(batch.Logs)) - for i := range batch.Logs { - timestamp := batch.HeaderMap[batch.Logs[i].BlockHash].Time - l1ContractEvents[i] = database.L1ContractEvent{ContractEvent: database.ContractEventFromLog(&batch.Logs[i], timestamp)} + // start ETL batch producer + if err := l1Etl.ETL.Start(); err != nil { + return fmt.Errorf("failed to start internal ETL: %w", err) + } + // start ETL batch consumer + l1Etl.tasks.Go(func() error { + for batch := range l1Etl.etlBatches { + if err := l1Etl.handleBatch(batch); err != nil { + return fmt.Errorf("failed to handle batch, stopping L2 ETL: %w", err) } + } + l1Etl.log.Info("no more batches, shutting down batch handler") + return nil + }) + return nil +} - // Continually try to persist this batch. If it fails after 10 attempts, we simply error out - retryStrategy := &retry.ExponentialStrategy{Min: 1000, Max: 20_000, MaxJitter: 250} - if _, err := retry.Do[interface{}](ctx, 10, retryStrategy, func() (interface{}, error) { - if err := l1Etl.db.Transaction(func(tx *database.DB) error { - if err := tx.Blocks.StoreL1BlockHeaders(l1BlockHeaders); err != nil { - return err - } - // we must have logs if we have l1 blocks - if err := tx.ContractEvents.StoreL1ContractEvents(l1ContractEvents); err != nil { - return err - } - return nil - }); err != nil { - batch.Logger.Error("unable to persist batch", "err", err) - return nil, err - } - - l1Etl.ETL.metrics.RecordIndexedHeaders(len(l1BlockHeaders)) - l1Etl.ETL.metrics.RecordIndexedLatestHeight(l1BlockHeaders[len(l1BlockHeaders)-1].Number) - l1Etl.ETL.metrics.RecordIndexedLogs(len(l1ContractEvents)) - - // a-ok! - return nil, nil - }); err != nil { +func (l1Etl *L1ETL) handleBatch(batch *ETLBatch) error { + // Index incoming batches (only L1 blocks that have an emitted log) + l1BlockHeaders := make([]database.L1BlockHeader, 0, len(batch.Headers)) + for i := range batch.Headers { + if _, ok := batch.HeadersWithLog[batch.Headers[i].Hash()]; ok { + l1BlockHeaders = append(l1BlockHeaders, database.L1BlockHeader{BlockHeader: database.BlockHeaderFromHeader(&batch.Headers[i])}) + } + } + + if len(l1BlockHeaders) == 0 { + batch.Logger.Info("no l1 blocks with logs in batch") + return nil + } + + l1ContractEvents := make([]database.L1ContractEvent, len(batch.Logs)) + for i := range batch.Logs { + timestamp := batch.HeaderMap[batch.Logs[i].BlockHash].Time + l1ContractEvents[i] = database.L1ContractEvent{ContractEvent: database.ContractEventFromLog(&batch.Logs[i], timestamp)} + l1Etl.ETL.metrics.RecordIndexedLog(batch.Logs[i].Address) + } + + // Continually try to persist this batch. If it fails after 10 attempts, we simply error out + retryStrategy := &retry.ExponentialStrategy{Min: 1000, Max: 20_000, MaxJitter: 250} + if _, err := retry.Do[interface{}](l1Etl.resourceCtx, 10, retryStrategy, func() (interface{}, error) { + if err := l1Etl.db.Transaction(func(tx *database.DB) error { + if err := tx.Blocks.StoreL1BlockHeaders(l1BlockHeaders); err != nil { return err } - - batch.Logger.Info("indexed batch") - - // Notify Listeners - l1Etl.mu.Lock() - for i := range l1Etl.listeners { - select { - case l1Etl.listeners[i] <- struct{}{}: - default: - // do nothing if the listener hasn't picked - // up the previous notif - } + // we must have logs if we have l1 blocks + if err := tx.ContractEvents.StoreL1ContractEvents(l1ContractEvents); err != nil { + return err } - l1Etl.mu.Unlock() + return nil + }); err != nil { + batch.Logger.Error("unable to persist batch", "err", err) + return nil, fmt.Errorf("unable to persist batch: %w", err) + } + + l1Etl.ETL.metrics.RecordIndexedHeaders(len(l1BlockHeaders)) + l1Etl.ETL.metrics.RecordIndexedLatestHeight(l1BlockHeaders[len(l1BlockHeaders)-1].Number) + + // a-ok! + return nil, nil + }); err != nil { + return err + } + + batch.Logger.Info("indexed batch") + l1Etl.LatestHeader = &batch.Headers[len(batch.Headers)-1] + + // Notify Listeners + l1Etl.mu.Lock() + defer l1Etl.mu.Unlock() + for i := range l1Etl.listeners { + select { + case l1Etl.listeners[i] <- struct{}{}: + default: + // do nothing if the listener hasn't picked + // up the previous notif } } + + return nil } // Notify returns a channel that'll receive a value every time new data has diff --git a/indexer/etl/l1_etl_test.go b/indexer/etl/l1_etl_test.go index c64167f173cae..7ae204afe1230 100644 --- a/indexer/etl/l1_etl_test.go +++ b/indexer/etl/l1_etl_test.go @@ -62,7 +62,7 @@ func TestL1ETLConstruction(t *testing.T) { }, assertion: func(etl *L1ETL, err error) { require.NoError(t, err) - require.Equal(t, etl.headerTraversal.LastHeader().ParentHash, common.HexToHash("0x69")) + require.Equal(t, etl.headerTraversal.LastTraversedHeader().ParentHash, common.HexToHash("0x69")) }, }, { @@ -94,7 +94,7 @@ func TestL1ETLConstruction(t *testing.T) { }, assertion: func(etl *L1ETL, err error) { require.NoError(t, err) - header := etl.headerTraversal.LastHeader() + header := etl.headerTraversal.LastTraversedHeader() require.True(t, header.Number.Cmp(big.NewInt(69)) == 0) }, @@ -108,7 +108,9 @@ func TestL1ETLConstruction(t *testing.T) { logger := testlog.Logger(t, log.LvlInfo) cfg := Config{StartHeight: ts.start} - etl, err := NewL1ETL(cfg, logger, ts.db.DB, etlMetrics, ts.client, ts.contracts) + etl, err := NewL1ETL(cfg, logger, ts.db.DB, etlMetrics, ts.client, ts.contracts, func(cause error) { + t.Fatalf("crit error: %v", cause) + }) test.assertion(etl, err) }) } diff --git a/indexer/etl/l2_etl.go b/indexer/etl/l2_etl.go index 72dfff8c74556..fc1253e41beea 100644 --- a/indexer/etl/l2_etl.go +++ b/indexer/etl/l2_etl.go @@ -3,24 +3,39 @@ package etl import ( "context" "errors" + "fmt" + "sync" "time" + "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/core/types" + "github.com/ethereum/go-ethereum/log" + "github.com/ethereum-optimism/optimism/indexer/config" "github.com/ethereum-optimism/optimism/indexer/database" "github.com/ethereum-optimism/optimism/indexer/node" "github.com/ethereum-optimism/optimism/op-service/retry" - "github.com/ethereum/go-ethereum/common" - "github.com/ethereum/go-ethereum/core/types" - "github.com/ethereum/go-ethereum/log" + "github.com/ethereum-optimism/optimism/op-service/tasks" ) type L2ETL struct { ETL + LatestHeader *types.Header + + // the batch handler may do work that we can interrupt on shutdown + resourceCtx context.Context + resourceCancel context.CancelFunc + + tasks tasks.Group db *database.DB + + mu sync.Mutex + listeners []chan interface{} } -func NewL2ETL(cfg Config, log log.Logger, db *database.DB, metrics Metricer, client node.EthClient, contracts config.L2Contracts) (*L2ETL, error) { +func NewL2ETL(cfg Config, log log.Logger, db *database.DB, metrics Metricer, client node.EthClient, + contracts config.L2Contracts, shutdown context.CancelCauseFunc) (*L2ETL, error) { log = log.New("etl", "l2") zeroAddr := common.Address{} @@ -54,7 +69,7 @@ func NewL2ETL(cfg Config, log log.Logger, db *database.DB, metrics Metricer, cli log.Info("no indexed state, starting from genesis") } - etlBatches := make(chan ETLBatch) + etlBatches := make(chan *ETLBatch) etl := ETL{ loopInterval: time.Duration(cfg.LoopIntervalMsec) * time.Millisecond, headerBufferSize: uint64(cfg.HeaderBufferSize), @@ -68,64 +83,125 @@ func NewL2ETL(cfg Config, log log.Logger, db *database.DB, metrics Metricer, cli EthClient: client, } - return &L2ETL{ETL: etl, db: db}, nil + resCtx, resCancel := context.WithCancel(context.Background()) + return &L2ETL{ + ETL: etl, + LatestHeader: fromHeader, + + resourceCtx: resCtx, + resourceCancel: resCancel, + db: db, + tasks: tasks.Group{HandleCrit: func(err error) { + shutdown(fmt.Errorf("critical error in L2 ETL: %w", err)) + }}, + }, nil } -func (l2Etl *L2ETL) Start(ctx context.Context) error { - errCh := make(chan error, 1) - go func() { - errCh <- l2Etl.ETL.Start(ctx) - }() +func (l2Etl *L2ETL) Close() error { + var result error + // close the producer + if err := l2Etl.ETL.Close(); err != nil { + result = errors.Join(result, fmt.Errorf("failed to close internal ETL: %w", err)) + } + // tell the consumer it can stop what it's doing + l2Etl.resourceCancel() + // wait for consumer to pick up on closure of producer + if err := l2Etl.tasks.Wait(); err != nil { + result = errors.Join(result, fmt.Errorf("failed to await batch handler completion: %w", err)) + } + // close listeners + for i := range l2Etl.listeners { + close(l2Etl.listeners[i]) + } + return result +} - for { - select { - case err := <-errCh: - return err - - // Index incoming batches (all L2 Blocks) - case batch := <-l2Etl.etlBatches: - l2BlockHeaders := make([]database.L2BlockHeader, len(batch.Headers)) - for i := range batch.Headers { - l2BlockHeaders[i] = database.L2BlockHeader{BlockHeader: database.BlockHeaderFromHeader(&batch.Headers[i])} - } +func (l2Etl *L2ETL) Start() error { + l2Etl.log.Info("starting etl...") + + // start ETL batch producer + if err := l2Etl.ETL.Start(); err != nil { + return fmt.Errorf("failed to start internal ETL: %w", err) + } - l2ContractEvents := make([]database.L2ContractEvent, len(batch.Logs)) - for i := range batch.Logs { - timestamp := batch.HeaderMap[batch.Logs[i].BlockHash].Time - l2ContractEvents[i] = database.L2ContractEvent{ContractEvent: database.ContractEventFromLog(&batch.Logs[i], timestamp)} + // start ETL batch consumer + l2Etl.tasks.Go(func() error { + for batch := range l2Etl.etlBatches { + if err := l2Etl.handleBatch(batch); err != nil { + return fmt.Errorf("failed to handle batch, stopping L2 ETL: %w", err) } + } + l2Etl.log.Info("no more batches, shutting down batch handler") + return nil + }) + return nil +} - // Continually try to persist this batch. If it fails after 10 attempts, we simply error out - retryStrategy := &retry.ExponentialStrategy{Min: 1000, Max: 20_000, MaxJitter: 250} - if _, err := retry.Do[interface{}](ctx, 10, retryStrategy, func() (interface{}, error) { - if err := l2Etl.db.Transaction(func(tx *database.DB) error { - if err := tx.Blocks.StoreL2BlockHeaders(l2BlockHeaders); err != nil { - return err - } - if len(l2ContractEvents) > 0 { - if err := tx.ContractEvents.StoreL2ContractEvents(l2ContractEvents); err != nil { - return err - } - } - return nil - }); err != nil { - batch.Logger.Error("unable to persist batch", "err", err) - return nil, err - } +func (l2Etl *L2ETL) handleBatch(batch *ETLBatch) error { + l2BlockHeaders := make([]database.L2BlockHeader, len(batch.Headers)) + for i := range batch.Headers { + l2BlockHeaders[i] = database.L2BlockHeader{BlockHeader: database.BlockHeaderFromHeader(&batch.Headers[i])} + } - l2Etl.ETL.metrics.RecordIndexedHeaders(len(l2BlockHeaders)) - l2Etl.ETL.metrics.RecordIndexedLatestHeight(l2BlockHeaders[len(l2BlockHeaders)-1].Number) - if len(l2ContractEvents) > 0 { - l2Etl.ETL.metrics.RecordIndexedLogs(len(l2ContractEvents)) - } + l2ContractEvents := make([]database.L2ContractEvent, len(batch.Logs)) + for i := range batch.Logs { + timestamp := batch.HeaderMap[batch.Logs[i].BlockHash].Time + l2ContractEvents[i] = database.L2ContractEvent{ContractEvent: database.ContractEventFromLog(&batch.Logs[i], timestamp)} + l2Etl.ETL.metrics.RecordIndexedLog(batch.Logs[i].Address) + } - // a-ok! - return nil, nil - }); err != nil { + // Continually try to persist this batch. If it fails after 10 attempts, we simply error out + retryStrategy := &retry.ExponentialStrategy{Min: 1000, Max: 20_000, MaxJitter: 250} + if _, err := retry.Do[interface{}](l2Etl.resourceCtx, 10, retryStrategy, func() (interface{}, error) { + if err := l2Etl.db.Transaction(func(tx *database.DB) error { + if err := tx.Blocks.StoreL2BlockHeaders(l2BlockHeaders); err != nil { return err } + if len(l2ContractEvents) > 0 { + if err := tx.ContractEvents.StoreL2ContractEvents(l2ContractEvents); err != nil { + return err + } + } + return nil + }); err != nil { + batch.Logger.Error("unable to persist batch", "err", err) + return nil, err + } + + l2Etl.ETL.metrics.RecordIndexedHeaders(len(l2BlockHeaders)) + l2Etl.ETL.metrics.RecordIndexedLatestHeight(l2BlockHeaders[len(l2BlockHeaders)-1].Number) - batch.Logger.Info("indexed batch") + // a-ok! + return nil, nil + }); err != nil { + return err + } + + batch.Logger.Info("indexed batch") + l2Etl.LatestHeader = &batch.Headers[len(batch.Headers)-1] + + // Notify Listeners + l2Etl.mu.Lock() + defer l2Etl.mu.Unlock() + for i := range l2Etl.listeners { + select { + case l2Etl.listeners[i] <- struct{}{}: + default: + // do nothing if the listener hasn't picked + // up the previous notif } } + + return nil +} + +// Notify returns a channel that'll receive a value every time new data has +// been persisted by the L2ETL +func (l2Etl *L2ETL) Notify() <-chan interface{} { + receiver := make(chan interface{}) + l2Etl.mu.Lock() + defer l2Etl.mu.Unlock() + + l2Etl.listeners = append(l2Etl.listeners, receiver) + return receiver } diff --git a/indexer/etl/metrics.go b/indexer/etl/metrics.go index 5cc75ff0ecb8c..3a2e70ccc7701 100644 --- a/indexer/etl/metrics.go +++ b/indexer/etl/metrics.go @@ -9,35 +9,28 @@ import ( ) var ( - MetricsNamespace string = "etl" + MetricsNamespace string = "op_indexer_etl" ) type Metricer interface { RecordInterval() (done func(err error)) - - // Batch Extraction - RecordBatchLatestHeight(height *big.Int) - RecordBatchHeaders(size int) - RecordBatchLog(contractAddress common.Address) + RecordLatestHeight(height *big.Int) // Indexed Batches RecordIndexedLatestHeight(height *big.Int) RecordIndexedHeaders(size int) - RecordIndexedLogs(size int) + RecordIndexedLog(contractAddress common.Address) } type etlMetrics struct { intervalTick prometheus.Counter intervalDuration prometheus.Histogram - - batchFailures prometheus.Counter - batchLatestHeight prometheus.Gauge - batchHeaders prometheus.Counter - batchLogs *prometheus.CounterVec + intervalFailures prometheus.Counter + latestHeight prometheus.Gauge indexedLatestHeight prometheus.Gauge indexedHeaders prometheus.Counter - indexedLogs prometheus.Counter + indexedLogs *prometheus.CounterVec } func NewMetrics(registry *prometheus.Registry, subsystem string) Metricer { @@ -55,31 +48,17 @@ func NewMetrics(registry *prometheus.Registry, subsystem string) Metricer { Name: "interval_seconds", Help: "duration elapsed for during the processing loop", }), - batchFailures: factory.NewCounter(prometheus.CounterOpts{ - Namespace: MetricsNamespace, - Subsystem: subsystem, - Name: "failures_total", - Help: "number of times the etl encountered a failure to extract a batch", - }), - batchLatestHeight: factory.NewGauge(prometheus.GaugeOpts{ + intervalFailures: factory.NewCounter(prometheus.CounterOpts{ Namespace: MetricsNamespace, Subsystem: subsystem, - Name: "height", - Help: "the latest block height observed by an etl interval", + Name: "interval_failures_total", + Help: "number of times the etl encountered a failure during the processing loop", }), - batchHeaders: factory.NewCounter(prometheus.CounterOpts{ + latestHeight: factory.NewGauge(prometheus.GaugeOpts{ Namespace: MetricsNamespace, Subsystem: subsystem, - Name: "headers_total", - Help: "number of headers observed by the etl", - }), - batchLogs: factory.NewCounterVec(prometheus.CounterOpts{ - Namespace: MetricsNamespace, - Subsystem: subsystem, - Name: "logs_total", - Help: "number of logs observed by the etl", - }, []string{ - "contract", + Name: "latest_height", + Help: "the latest height reported by the connected client", }), indexedLatestHeight: factory.NewGauge(prometheus.GaugeOpts{ Namespace: MetricsNamespace, @@ -93,11 +72,13 @@ func NewMetrics(registry *prometheus.Registry, subsystem string) Metricer { Name: "indexed_headers_total", Help: "number of headers indexed by the etl", }), - indexedLogs: factory.NewCounter(prometheus.CounterOpts{ + indexedLogs: factory.NewCounterVec(prometheus.CounterOpts{ Namespace: MetricsNamespace, Subsystem: subsystem, Name: "indexed_logs_total", Help: "number of logs indexed by the etl", + }, []string{ + "contract", }), } } @@ -107,23 +88,14 @@ func (m *etlMetrics) RecordInterval() func(error) { timer := prometheus.NewTimer(m.intervalDuration) return func(err error) { if err != nil { - m.batchFailures.Inc() + m.intervalFailures.Inc() } - timer.ObserveDuration() } } -func (m *etlMetrics) RecordBatchLatestHeight(height *big.Int) { - m.batchLatestHeight.Set(float64(height.Uint64())) -} - -func (m *etlMetrics) RecordBatchHeaders(size int) { - m.batchHeaders.Add(float64(size)) -} - -func (m *etlMetrics) RecordBatchLog(contractAddress common.Address) { - m.batchLogs.WithLabelValues(contractAddress.String()).Inc() +func (m *etlMetrics) RecordLatestHeight(height *big.Int) { + m.latestHeight.Set(float64(height.Uint64())) } func (m *etlMetrics) RecordIndexedLatestHeight(height *big.Int) { @@ -134,6 +106,6 @@ func (m *etlMetrics) RecordIndexedHeaders(size int) { m.indexedHeaders.Add(float64(size)) } -func (m *etlMetrics) RecordIndexedLogs(size int) { - m.indexedLogs.Add(float64(size)) +func (m *etlMetrics) RecordIndexedLog(addr common.Address) { + m.indexedLogs.WithLabelValues(addr.String()).Inc() } diff --git a/indexer/indexer.go b/indexer/indexer.go index 07f5666506044..b2d01a2382b05 100644 --- a/indexer/indexer.go +++ b/indexer/indexer.go @@ -2,12 +2,12 @@ package indexer import ( "context" + "errors" "fmt" "math/big" "net" - "runtime/debug" "strconv" - "sync" + "sync/atomic" "github.com/ethereum/go-ethereum/log" @@ -30,149 +30,230 @@ import ( // indexing the configured L1 and L2 chains type Indexer struct { log log.Logger - db *database.DB + DB *database.DB + + l1Client node.EthClient + l2Client node.EthClient + + // api server only really serves a /health endpoint here, but this may change in the future + apiServer *httputil.HTTPServer + + metricsServer *httputil.HTTPServer - httpConfig config.ServerConfig - metricsConfig config.ServerConfig metricsRegistry *prometheus.Registry L1ETL *etl.L1ETL L2ETL *etl.L2ETL BridgeProcessor *processors.BridgeProcessor + + // shutdown requests the service that maintains the indexer to shut down, + // and provides the error-cause of the critical failure (if any). + shutdown context.CancelCauseFunc + + stopped atomic.Bool } // NewIndexer initializes an instance of the Indexer -func NewIndexer( - log log.Logger, - db *database.DB, - chainConfig config.ChainConfig, - rpcsConfig config.RPCsConfig, - httpConfig config.ServerConfig, - metricsConfig config.ServerConfig, -) (*Indexer, error) { - metricsRegistry := metrics.NewRegistry() - - // L1 - l1EthClient, err := node.DialEthClient(rpcsConfig.L1RPC, node.NewMetrics(metricsRegistry, "l1")) +func NewIndexer(ctx context.Context, log log.Logger, cfg *config.Config, shutdown context.CancelCauseFunc) (*Indexer, error) { + out := &Indexer{ + log: log, + metricsRegistry: metrics.NewRegistry(), + shutdown: shutdown, + } + if err := out.initFromConfig(ctx, cfg); err != nil { + return nil, errors.Join(err, out.Stop(ctx)) + } + return out, nil +} + +func (ix *Indexer) Start(ctx context.Context) error { + // If any of these services has a critical failure, + // the service can request a shutdown, while providing the error cause. + if err := ix.L1ETL.Start(); err != nil { + return fmt.Errorf("failed to start L1 ETL: %w", err) + } + if err := ix.L2ETL.Start(); err != nil { + return fmt.Errorf("failed to start L2 ETL: %w", err) + } + if err := ix.BridgeProcessor.Start(); err != nil { + return fmt.Errorf("failed to start bridge processor: %w", err) + } + return nil +} + +func (ix *Indexer) Stop(ctx context.Context) error { + var result error + + if ix.L1ETL != nil { + if err := ix.L1ETL.Close(); err != nil { + result = errors.Join(result, fmt.Errorf("failed to close L1 ETL: %w", err)) + } + } + + if ix.L2ETL != nil { + if err := ix.L2ETL.Close(); err != nil { + result = errors.Join(result, fmt.Errorf("failed to close L2 ETL: %w", err)) + } + } + + if ix.BridgeProcessor != nil { + if err := ix.BridgeProcessor.Close(); err != nil { + result = errors.Join(result, fmt.Errorf("failed to close bridge processor: %w", err)) + } + } + + // Now that the ETLs are closed, we can stop the RPC clients + if ix.l1Client != nil { + ix.l1Client.Close() + } + if ix.l2Client != nil { + ix.l2Client.Close() + } + + if ix.apiServer != nil { + if err := ix.apiServer.Close(); err != nil { + result = errors.Join(result, fmt.Errorf("failed to close indexer API server: %w", err)) + } + } + + // DB connection can be closed last, after all its potential users have shut down + if ix.DB != nil { + if err := ix.DB.Close(); err != nil { + result = errors.Join(result, fmt.Errorf("failed to close DB: %w", err)) + } + } + + if ix.metricsServer != nil { + if err := ix.metricsServer.Close(); err != nil { + result = errors.Join(result, fmt.Errorf("failed to close metrics server: %w", err)) + } + } + + ix.stopped.Store(true) + + ix.log.Info("indexer stopped") + + return result +} + +func (ix *Indexer) Stopped() bool { + return ix.stopped.Load() +} + +func (ix *Indexer) initFromConfig(ctx context.Context, cfg *config.Config) error { + if err := ix.initRPCClients(ctx, cfg.RPCs); err != nil { + return fmt.Errorf("failed to start RPC clients: %w", err) + } + if err := ix.initDB(ctx, cfg.DB); err != nil { + return fmt.Errorf("failed to init DB: %w", err) + } + if err := ix.initL1ETL(cfg.Chain); err != nil { + return fmt.Errorf("failed to init L1 ETL: %w", err) + } + if err := ix.initL2ETL(cfg.Chain); err != nil { + return fmt.Errorf("failed to init L2 ETL: %w", err) + } + if err := ix.initBridgeProcessor(cfg.Chain); err != nil { + return fmt.Errorf("failed to init Bridge-Processor: %w", err) + } + if err := ix.startHttpServer(ctx, cfg.HTTPServer); err != nil { + return fmt.Errorf("failed to start HTTP server: %w", err) + } + if err := ix.startMetricsServer(ctx, cfg.MetricsServer); err != nil { + return fmt.Errorf("failed to start Metrics server: %w", err) + } + return nil +} + +func (ix *Indexer) initRPCClients(ctx context.Context, rpcsConfig config.RPCsConfig) error { + l1EthClient, err := node.DialEthClient(ctx, rpcsConfig.L1RPC, node.NewMetrics(ix.metricsRegistry, "l1")) + if err != nil { + return fmt.Errorf("failed to dial L1 client: %w", err) + } + ix.l1Client = l1EthClient + + l2EthClient, err := node.DialEthClient(ctx, rpcsConfig.L2RPC, node.NewMetrics(ix.metricsRegistry, "l2")) + if err != nil { + return fmt.Errorf("failed to dial L2 client: %w", err) + } + ix.l2Client = l2EthClient + return nil +} + +func (ix *Indexer) initDB(ctx context.Context, cfg config.DBConfig) error { + db, err := database.NewDB(ctx, ix.log, cfg) if err != nil { - return nil, err + return fmt.Errorf("failed to connect to database: %w", err) } + ix.DB = db + return nil +} + +func (ix *Indexer) initL1ETL(chainConfig config.ChainConfig) error { l1Cfg := etl.Config{ LoopIntervalMsec: chainConfig.L1PollingInterval, HeaderBufferSize: chainConfig.L1HeaderBufferSize, ConfirmationDepth: big.NewInt(int64(chainConfig.L1ConfirmationDepth)), StartHeight: big.NewInt(int64(chainConfig.L1StartingHeight)), } - l1Etl, err := etl.NewL1ETL(l1Cfg, log, db, etl.NewMetrics(metricsRegistry, "l1"), l1EthClient, chainConfig.L1Contracts) + l1Etl, err := etl.NewL1ETL(l1Cfg, ix.log, ix.DB, etl.NewMetrics(ix.metricsRegistry, "l1"), + ix.l1Client, chainConfig.L1Contracts, ix.shutdown) if err != nil { - return nil, err + return err } + ix.L1ETL = l1Etl + return nil +} +func (ix *Indexer) initL2ETL(chainConfig config.ChainConfig) error { // L2 (defaults to predeploy contracts) - l2EthClient, err := node.DialEthClient(rpcsConfig.L2RPC, node.NewMetrics(metricsRegistry, "l2")) - if err != nil { - return nil, err - } l2Cfg := etl.Config{ LoopIntervalMsec: chainConfig.L2PollingInterval, HeaderBufferSize: chainConfig.L2HeaderBufferSize, ConfirmationDepth: big.NewInt(int64(chainConfig.L2ConfirmationDepth)), } - l2Etl, err := etl.NewL2ETL(l2Cfg, log, db, etl.NewMetrics(metricsRegistry, "l2"), l2EthClient, chainConfig.L2Contracts) + l2Etl, err := etl.NewL2ETL(l2Cfg, ix.log, ix.DB, etl.NewMetrics(ix.metricsRegistry, "l2"), + ix.l2Client, chainConfig.L2Contracts, ix.shutdown) if err != nil { - return nil, err + return err } + ix.L2ETL = l2Etl + return nil +} - // Bridge - bridgeProcessor, err := processors.NewBridgeProcessor(log, db, bridge.NewMetrics(metricsRegistry), l1Etl, chainConfig) +func (ix *Indexer) initBridgeProcessor(chainConfig config.ChainConfig) error { + bridgeProcessor, err := processors.NewBridgeProcessor( + ix.log, ix.DB, bridge.NewMetrics(ix.metricsRegistry), ix.L1ETL, ix.L2ETL, chainConfig, ix.shutdown) if err != nil { - return nil, err + return err } - - indexer := &Indexer{ - log: log, - db: db, - - httpConfig: httpConfig, - metricsConfig: metricsConfig, - metricsRegistry: metricsRegistry, - - L1ETL: l1Etl, - L2ETL: l2Etl, - BridgeProcessor: bridgeProcessor, - } - - return indexer, nil + ix.BridgeProcessor = bridgeProcessor + return nil } -func (i *Indexer) startHttpServer(ctx context.Context) error { - i.log.Debug("starting http server...", "port", i.httpConfig.Host) +func (ix *Indexer) startHttpServer(ctx context.Context, cfg config.ServerConfig) error { + ix.log.Debug("starting http server...", "port", cfg.Port) r := chi.NewRouter() r.Use(middleware.Heartbeat("/healthz")) - addr := net.JoinHostPort(i.httpConfig.Host, strconv.Itoa(i.httpConfig.Port)) + addr := net.JoinHostPort(cfg.Host, strconv.Itoa(cfg.Port)) srv, err := httputil.StartHTTPServer(addr, r) if err != nil { return fmt.Errorf("http server failed to start: %w", err) } - i.log.Info("http server started", "addr", srv.Addr()) - <-ctx.Done() - defer i.log.Info("http server stopped") - return srv.Stop(context.Background()) + ix.apiServer = srv + ix.log.Info("http server started", "addr", srv.Addr()) + return nil } -func (i *Indexer) startMetricsServer(ctx context.Context) error { - i.log.Debug("starting metrics server...", "port", i.metricsConfig.Port) - srv, err := metrics.StartServer(i.metricsRegistry, i.metricsConfig.Host, i.metricsConfig.Port) +func (ix *Indexer) startMetricsServer(ctx context.Context, cfg config.ServerConfig) error { + ix.log.Debug("starting metrics server...", "port", cfg.Port) + srv, err := metrics.StartServer(ix.metricsRegistry, cfg.Host, cfg.Port) if err != nil { return fmt.Errorf("metrics server failed to start: %w", err) } - i.log.Info("metrics server started", "addr", srv.Addr()) - <-ctx.Done() - defer i.log.Info("metrics server stopped") - return srv.Stop(context.Background()) -} - -// Start starts the indexing service on L1 and L2 chains -func (i *Indexer) Run(ctx context.Context) error { - var wg sync.WaitGroup - errCh := make(chan error, 5) - - // if any goroutine halts, we stop the entire indexer - processCtx, processCancel := context.WithCancel(ctx) - runProcess := func(start func(ctx context.Context) error) { - wg.Add(1) - go func() { - defer func() { - if err := recover(); err != nil { - i.log.Error("halting indexer on panic", "err", err) - debug.PrintStack() - errCh <- fmt.Errorf("panic: %v", err) - } - - processCancel() - wg.Done() - }() - - errCh <- start(processCtx) - }() - } - - // Kick off all the dependent routines - runProcess(i.L1ETL.Start) - runProcess(i.L2ETL.Start) - runProcess(i.BridgeProcessor.Start) - runProcess(i.startMetricsServer) - runProcess(i.startHttpServer) - wg.Wait() - - err := <-errCh - if err != nil { - i.log.Error("indexer stopped", "err", err) - } else { - i.log.Info("indexer stopped") - } - - return err + ix.metricsServer = srv + ix.log.Info("metrics server started", "addr", srv.Addr()) + return nil } diff --git a/indexer/indexer.toml b/indexer/indexer.toml index b85c2008df27e..3f18f6f3df5a3 100644 --- a/indexer/indexer.toml +++ b/indexer/indexer.toml @@ -29,6 +29,7 @@ name = "$INDEXER_DB_NAME" [http] host = "127.0.0.1" port = 8080 +timeout = 10 [metrics] host = "127.0.0.1" diff --git a/indexer/migrations/20230523_create_schema.sql b/indexer/migrations/20230523_create_schema.sql index b13eb9dc6fabb..3bd7138354e1b 100644 --- a/indexer/migrations/20230523_create_schema.sql +++ b/indexer/migrations/20230523_create_schema.sql @@ -63,6 +63,7 @@ CREATE INDEX IF NOT EXISTS l1_contract_events_timestamp ON l1_contract_events(ti CREATE INDEX IF NOT EXISTS l1_contract_events_block_hash ON l1_contract_events(block_hash); CREATE INDEX IF NOT EXISTS l1_contract_events_event_signature ON l1_contract_events(event_signature); CREATE INDEX IF NOT EXISTS l1_contract_events_contract_address ON l1_contract_events(contract_address); +ALTER TABLE l1_contract_events ADD UNIQUE (block_hash, log_index); CREATE TABLE IF NOT EXISTS l2_contract_events ( -- Searchable fields @@ -81,6 +82,7 @@ CREATE INDEX IF NOT EXISTS l2_contract_events_timestamp ON l2_contract_events(ti CREATE INDEX IF NOT EXISTS l2_contract_events_block_hash ON l2_contract_events(block_hash); CREATE INDEX IF NOT EXISTS l2_contract_events_event_signature ON l2_contract_events(event_signature); CREATE INDEX IF NOT EXISTS l2_contract_events_contract_address ON l2_contract_events(contract_address); +ALTER TABLE l2_contract_events ADD UNIQUE (block_hash, log_index); /** * BRIDGING DATA @@ -94,8 +96,8 @@ CREATE TABLE IF NOT EXISTS l1_transaction_deposits ( -- transaction data. NOTE: `to_address` is the recipient of funds transferred in value field of the -- L2 deposit transaction and not the amount minted on L1 from the source address. Hence the `amount` - -- column in this table does NOT indiciate the amount transferred to the recipient but instead funds - -- bridged from L1 into `from_address`. + -- column in this table does NOT indicate the amount transferred to the recipient but instead funds + -- bridged from L1 by the `from_address`. from_address VARCHAR NOT NULL, to_address VARCHAR NOT NULL, @@ -175,26 +177,6 @@ CREATE INDEX IF NOT EXISTS l2_bridge_messages_transaction_withdrawal_hash ON l2_ CREATE INDEX IF NOT EXISTS l2_bridge_messages_from_address ON l2_bridge_messages(from_address); -- StandardBridge -CREATE TABLE IF NOT EXISTS l1_bridged_tokens ( - address VARCHAR PRIMARY KEY, - bridge_address VARCHAR NOT NULL, - - name VARCHAR NOT NULL, - symbol VARCHAR NOT NULL, - decimals INTEGER NOT NULL CHECK (decimals >= 0 AND decimals <= 18) -); -CREATE TABLE IF NOT EXISTS l2_bridged_tokens ( - address VARCHAR PRIMARY KEY, - bridge_address VARCHAR NOT NULL, - - -- L1-L2 relationship is 1 to many so this is not necessarily unique - l1_token_address VARCHAR REFERENCES l1_bridged_tokens(address) ON DELETE CASCADE, - - name VARCHAR NOT NULL, - symbol VARCHAR NOT NULL, - decimals INTEGER NOT NULL CHECK (decimals >= 0 AND decimals <= 18) -); - CREATE TABLE IF NOT EXISTS l1_bridge_deposits ( transaction_source_hash VARCHAR PRIMARY KEY REFERENCES l1_transaction_deposits(source_hash) ON DELETE CASCADE, cross_domain_message_hash VARCHAR NOT NULL UNIQUE REFERENCES l1_bridge_messages(message_hash) ON DELETE CASCADE, @@ -202,8 +184,8 @@ CREATE TABLE IF NOT EXISTS l1_bridge_deposits ( -- Deposit information from_address VARCHAR NOT NULL, to_address VARCHAR NOT NULL, - local_token_address VARCHAR NOT NULL, -- REFERENCES l1_bridged_tokens(address), uncomment me in future pr - remote_token_address VARCHAR NOT NULL, -- REFERENCES l2_bridged_tokens(address), uncomment me in future pr + local_token_address VARCHAR NOT NULL, + remote_token_address VARCHAR NOT NULL, amount UINT256 NOT NULL, data VARCHAR NOT NULL, timestamp INTEGER NOT NULL CHECK (timestamp > 0) @@ -219,8 +201,8 @@ CREATE TABLE IF NOT EXISTS l2_bridge_withdrawals ( -- Withdrawal information from_address VARCHAR NOT NULL, to_address VARCHAR NOT NULL, - local_token_address VARCHAR NOT NULL, -- REFERENCES l2_bridged_tokens(address), uncomment me in future pr - remote_token_address VARCHAR NOT NULL, -- REFERENCES l1_bridged_tokens(address), uncomment me in future pr + local_token_address VARCHAR NOT NULL, + remote_token_address VARCHAR NOT NULL, amount UINT256 NOT NULL, data VARCHAR NOT NULL, timestamp INTEGER NOT NULL CHECK (timestamp > 0) diff --git a/indexer/node/client.go b/indexer/node/client.go index b566b459866fe..1ad6f0a21e0a0 100644 --- a/indexer/node/client.go +++ b/indexer/node/client.go @@ -7,6 +7,9 @@ import ( "math/big" "time" + "github.com/ethereum-optimism/optimism/op-service/client" + "github.com/ethereum-optimism/optimism/op-service/retry" + "github.com/ethereum/go-ethereum" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common/hexutil" @@ -19,6 +22,10 @@ const ( // startup to make a connection to the backend defaultDialTimeout = 5 * time.Second + // defaultDialAttempts is the default attempts a connection will be made + // before failing + defaultDialAttempts = 5 + // defaultRequestTimeout is the default duration the processor will // wait for a request to be fulfilled defaultRequestTimeout = 10 * time.Second @@ -32,28 +39,44 @@ type EthClient interface { TxByHash(common.Hash) (*types.Transaction, error) StorageHash(common.Address, *big.Int) (common.Hash, error) - FilterLogs(ethereum.FilterQuery) ([]types.Log, error) + FilterLogs(ethereum.FilterQuery) (Logs, error) + + // Close closes the underlying RPC connection. + // RPC close does not return any errors, but does shut down e.g. a websocket connection. + Close() } -type client struct { +type clnt struct { rpc RPC } -func DialEthClient(rpcUrl string, metrics Metricer) (EthClient, error) { - ctxwt, cancel := context.WithTimeout(context.Background(), defaultDialTimeout) +func DialEthClient(ctx context.Context, rpcUrl string, metrics Metricer) (EthClient, error) { + ctx, cancel := context.WithTimeout(ctx, defaultDialTimeout) defer cancel() - rpcClient, err := rpc.DialContext(ctxwt, rpcUrl) + bOff := retry.Exponential() + rpcClient, err := retry.Do(ctx, defaultDialAttempts, bOff, func() (*rpc.Client, error) { + if !client.IsURLAvailable(rpcUrl) { + return nil, fmt.Errorf("address unavailable (%s)", rpcUrl) + } + + client, err := rpc.DialContext(ctx, rpcUrl) + if err != nil { + return nil, fmt.Errorf("failed to dial address (%s): %w", rpcUrl, err) + } + + return client, nil + }) + if err != nil { return nil, err } - client := &client{rpc: NewRPC(rpcClient, metrics)} - return client, nil + return &clnt{rpc: NewRPC(rpcClient, metrics)}, nil } // BlockHeaderByHash retrieves the block header attributed to the supplied hash -func (c *client) BlockHeaderByHash(hash common.Hash) (*types.Header, error) { +func (c *clnt) BlockHeaderByHash(hash common.Hash) (*types.Header, error) { ctxwt, cancel := context.WithTimeout(context.Background(), defaultRequestTimeout) defer cancel() @@ -74,7 +97,7 @@ func (c *client) BlockHeaderByHash(hash common.Hash) (*types.Header, error) { } // BlockHeaderByNumber retrieves the block header attributed to the supplied height -func (c *client) BlockHeaderByNumber(number *big.Int) (*types.Header, error) { +func (c *clnt) BlockHeaderByNumber(number *big.Int) (*types.Header, error) { ctxwt, cancel := context.WithTimeout(context.Background(), defaultRequestTimeout) defer cancel() @@ -92,7 +115,7 @@ func (c *client) BlockHeaderByNumber(number *big.Int) (*types.Header, error) { // BlockHeadersByRange will retrieve block headers within the specified range -- inclusive. No restrictions // are placed on the range such as blocks in the "latest", "safe" or "finalized" states. If the specified // range is too large, `endHeight > latest`, the resulting list is truncated to the available headers -func (c *client) BlockHeadersByRange(startHeight, endHeight *big.Int) ([]types.Header, error) { +func (c *clnt) BlockHeadersByRange(startHeight, endHeight *big.Int) ([]types.Header, error) { // avoid the batch call if there's no range if startHeight.Cmp(endHeight) == 0 { header, err := c.BlockHeaderByNumber(startHeight) @@ -103,15 +126,12 @@ func (c *client) BlockHeadersByRange(startHeight, endHeight *big.Int) ([]types.H } count := new(big.Int).Sub(endHeight, startHeight).Uint64() + 1 + headers := make([]types.Header, count) batchElems := make([]rpc.BatchElem, count) + for i := uint64(0); i < count; i++ { height := new(big.Int).Add(startHeight, new(big.Int).SetUint64(i)) - batchElems[i] = rpc.BatchElem{ - Method: "eth_getBlockByNumber", - Args: []interface{}{toBlockNumArg(height), false}, - Result: new(types.Header), - Error: nil, - } + batchElems[i] = rpc.BatchElem{Method: "eth_getBlockByNumber", Args: []interface{}{toBlockNumArg(height), false}, Result: &headers[i]} } ctxwt, cancel := context.WithTimeout(context.Background(), defaultRequestTimeout) @@ -125,23 +145,21 @@ func (c *client) BlockHeadersByRange(startHeight, endHeight *big.Int) ([]types.H // - Ensure integrity that they build on top of each other // - Truncate out headers that do not exist (endHeight > "latest") size := 0 - headers := make([]types.Header, count) for i, batchElem := range batchElems { if batchElem.Error != nil { - return nil, batchElem.Error + if size == 0 { + return nil, batchElem.Error + } else { + break // try return whatever headers are available + } } else if batchElem.Result == nil { break } - header, ok := batchElem.Result.(*types.Header) - if !ok { - return nil, fmt.Errorf("unable to transform rpc response %v into types.Header", batchElem.Result) - } - if i > 0 && header.ParentHash != headers[i-1].Hash() { - return nil, fmt.Errorf("queried header %s does not follow parent %s", header.Hash(), headers[i-1].Hash()) + if i > 0 && headers[i].ParentHash != headers[i-1].Hash() { + return nil, fmt.Errorf("queried header %s does not follow parent %s", headers[i].Hash(), headers[i-1].Hash()) } - headers[i] = *header size = size + 1 } @@ -149,7 +167,7 @@ func (c *client) BlockHeadersByRange(startHeight, endHeight *big.Int) ([]types.H return headers, nil } -func (c *client) TxByHash(hash common.Hash) (*types.Transaction, error) { +func (c *clnt) TxByHash(hash common.Hash) (*types.Transaction, error) { ctxwt, cancel := context.WithTimeout(context.Background(), defaultRequestTimeout) defer cancel() @@ -165,7 +183,7 @@ func (c *client) TxByHash(hash common.Hash) (*types.Transaction, error) { } // StorageHash returns the sha3 of the storage root for the specified account -func (c *client) StorageHash(address common.Address, blockNumber *big.Int) (common.Hash, error) { +func (c *clnt) StorageHash(address common.Address, blockNumber *big.Int) (common.Hash, error) { ctxwt, cancel := context.WithTimeout(context.Background(), defaultRequestTimeout) defer cancel() @@ -178,19 +196,47 @@ func (c *client) StorageHash(address common.Address, blockNumber *big.Int) (comm return proof.StorageHash, nil } -// FilterLogs returns logs that fit the query parameters -func (c *client) FilterLogs(query ethereum.FilterQuery) ([]types.Log, error) { - ctxwt, cancel := context.WithTimeout(context.Background(), defaultRequestTimeout) - defer cancel() +func (c *clnt) Close() { + c.rpc.Close() +} - var result []types.Log +type Logs struct { + Logs []types.Log + ToBlockHeader *types.Header +} + +// FilterLogs returns logs that fit the query parameters. The underlying request is a batch +// request including `eth_getBlockByNumber` to allow the caller to check that connected +// node has the state necessary to fulfill this request +func (c *clnt) FilterLogs(query ethereum.FilterQuery) (Logs, error) { arg, err := toFilterArg(query) if err != nil { - return nil, err + return Logs{}, err } - err = c.rpc.CallContext(ctxwt, &result, "eth_getLogs", arg) - return result, err + var logs []types.Log + var header types.Header + + batchElems := make([]rpc.BatchElem, 2) + batchElems[0] = rpc.BatchElem{Method: "eth_getBlockByNumber", Args: []interface{}{toBlockNumArg(query.ToBlock), false}, Result: &header} + batchElems[1] = rpc.BatchElem{Method: "eth_getLogs", Args: []interface{}{arg}, Result: &logs} + + ctxwt, cancel := context.WithTimeout(context.Background(), defaultRequestTimeout) + defer cancel() + err = c.rpc.BatchCallContext(ctxwt, batchElems) + if err != nil { + return Logs{}, err + } + + if batchElems[0].Error != nil { + return Logs{}, fmt.Errorf("unable to query for the `FilterQuery#ToBlock` header: %w", batchElems[0].Error) + } + + if batchElems[1].Error != nil { + return Logs{}, fmt.Errorf("unable to query logs: %w", batchElems[1].Error) + } + + return Logs{Logs: logs, ToBlockHeader: &header}, nil } // Modeled off op-service/client.go. We can refactor this once the client/metrics portion @@ -243,10 +289,7 @@ func toBlockNumArg(number *big.Int) string { } func toFilterArg(q ethereum.FilterQuery) (interface{}, error) { - arg := map[string]interface{}{ - "address": q.Addresses, - "topics": q.Topics, - } + arg := map[string]interface{}{"address": q.Addresses, "topics": q.Topics} if q.BlockHash != nil { arg["blockHash"] = *q.BlockHash if q.FromBlock != nil || q.ToBlock != nil { diff --git a/indexer/node/client_test.go b/indexer/node/client_test.go new file mode 100644 index 0000000000000..78cf5b5b82a5f --- /dev/null +++ b/indexer/node/client_test.go @@ -0,0 +1,35 @@ +package node + +import ( + "context" + "fmt" + "net" + "strings" + "testing" + + "github.com/stretchr/testify/require" +) + +func TestDialEthClientUnavailable(t *testing.T) { + listener, err := net.Listen("tcp4", ":0") + require.NoError(t, err) + defer listener.Close() + + a := listener.Addr().String() + parts := strings.Split(a, ":") + addr := fmt.Sprintf("http://localhost:%s", parts[1]) + + metrics := &clientMetrics{} + + // available + _, err = DialEthClient(context.Background(), addr, metrics) + require.NoError(t, err) + + // :0 requests a new unbound port + _, err = DialEthClient(context.Background(), "http://localhost:0", metrics) + require.Error(t, err) + + // Fail open if we don't recognize the scheme + _, err = DialEthClient(context.Background(), "mailto://example.com", metrics) + require.Error(t, err) +} diff --git a/indexer/node/header_traversal.go b/indexer/node/header_traversal.go index e925747f21855..3546aa8d1e46c 100644 --- a/indexer/node/header_traversal.go +++ b/indexer/node/header_traversal.go @@ -17,38 +17,56 @@ var ( type HeaderTraversal struct { ethClient EthClient - lastHeader *types.Header + latestHeader *types.Header + lastTraversedHeader *types.Header + blockConfirmationDepth *big.Int } // NewHeaderTraversal instantiates a new instance of HeaderTraversal against the supplied rpc client. // The HeaderTraversal will start fetching blocks starting from the supplied header unless nil, indicating genesis. func NewHeaderTraversal(ethClient EthClient, fromHeader *types.Header, confDepth *big.Int) *HeaderTraversal { - return &HeaderTraversal{ethClient: ethClient, lastHeader: fromHeader, blockConfirmationDepth: confDepth} + return &HeaderTraversal{ + ethClient: ethClient, + lastTraversedHeader: fromHeader, + blockConfirmationDepth: confDepth, + } +} + +// LatestHeader returns the latest header reported by underlying eth client +// as headers are traversed via `NextHeaders`. +func (f *HeaderTraversal) LatestHeader() *types.Header { + return f.latestHeader } -// LastHeader returns the last header that was fetched by the HeaderTraversal -// This is useful for testing the state of the HeaderTraversal -func (f *HeaderTraversal) LastHeader() *types.Header { - return f.lastHeader +// LastTraversedHeader returns the last header traversed. +// - This is useful for testing the state of the HeaderTraversal +// - LastTraversedHeader may be << LatestHeader depending on the number +// headers traversed via `NextHeaders`. +func (f *HeaderTraversal) LastTraversedHeader() *types.Header { + return f.lastTraversedHeader } -// NextFinalizedHeaders retrieves the next set of headers that have been +// NextHeaders retrieves the next set of headers that have been // marked as finalized by the connected client, bounded by the supplied size -func (f *HeaderTraversal) NextFinalizedHeaders(maxSize uint64) ([]types.Header, error) { - latestBlockHeader, err := f.ethClient.BlockHeaderByNumber(nil) +func (f *HeaderTraversal) NextHeaders(maxSize uint64) ([]types.Header, error) { + latestHeader, err := f.ethClient.BlockHeaderByNumber(nil) if err != nil { return nil, fmt.Errorf("unable to query latest block: %w", err) + } else if latestHeader == nil { + return nil, fmt.Errorf("latest header unreported") + } else { + f.latestHeader = latestHeader } - endHeight := new(big.Int).Sub(latestBlockHeader.Number, f.blockConfirmationDepth) + endHeight := new(big.Int).Sub(latestHeader.Number, f.blockConfirmationDepth) if endHeight.Sign() < 0 { // No blocks with the provided confirmation depth available return nil, nil } - if f.lastHeader != nil { - cmp := f.lastHeader.Number.Cmp(endHeight) + if f.lastTraversedHeader != nil { + cmp := f.lastTraversedHeader.Number.Cmp(endHeight) if cmp == 0 { // We're synced to head and there are no new headers return nil, nil } else if cmp > 0 { @@ -57,8 +75,8 @@ func (f *HeaderTraversal) NextFinalizedHeaders(maxSize uint64) ([]types.Header, } nextHeight := bigint.Zero - if f.lastHeader != nil { - nextHeight = new(big.Int).Add(f.lastHeader.Number, bigint.One) + if f.lastTraversedHeader != nil { + nextHeight = new(big.Int).Add(f.lastTraversedHeader.Number, bigint.One) } // endHeight = (nextHeight - endHeight) <= maxSize @@ -71,12 +89,12 @@ func (f *HeaderTraversal) NextFinalizedHeaders(maxSize uint64) ([]types.Header, numHeaders := len(headers) if numHeaders == 0 { return nil, nil - } else if f.lastHeader != nil && headers[0].ParentHash != f.lastHeader.Hash() { + } else if f.lastTraversedHeader != nil && headers[0].ParentHash != f.lastTraversedHeader.Hash() { // The indexer's state is in an irrecoverable state relative to the provider. This // should never happen since the indexer is dealing with only finalized blocks. return nil, ErrHeaderTraversalAndProviderMismatchedState } - f.lastHeader = &headers[numHeaders-1] + f.lastTraversedHeader = &headers[numHeaders-1] return headers, nil } diff --git a/indexer/node/header_traversal_test.go b/indexer/node/header_traversal_test.go index 6358fc7c8eb00..603b8fdd3a970 100644 --- a/indexer/node/header_traversal_test.go +++ b/indexer/node/header_traversal_test.go @@ -33,44 +33,55 @@ func makeHeaders(numHeaders uint64, prevHeader *types.Header) []types.Header { return headers } -func TestHeaderTraversalNextFinalizedHeadersNoOp(t *testing.T) { +func TestHeaderTraversalNextHeadersNoOp(t *testing.T) { client := new(MockEthClient) // start from block 10 as the latest fetched block - lastHeader := &types.Header{Number: big.NewInt(10)} - headerTraversal := NewHeaderTraversal(client, lastHeader, bigint.Zero) + LastTraversedHeader := &types.Header{Number: big.NewInt(10)} + headerTraversal := NewHeaderTraversal(client, LastTraversedHeader, bigint.Zero) + + require.Nil(t, headerTraversal.LatestHeader()) + require.NotNil(t, headerTraversal.LastTraversedHeader()) // no new headers when matched with head - client.On("BlockHeaderByNumber", (*big.Int)(nil)).Return(lastHeader, nil) - headers, err := headerTraversal.NextFinalizedHeaders(100) + client.On("BlockHeaderByNumber", (*big.Int)(nil)).Return(LastTraversedHeader, nil) + headers, err := headerTraversal.NextHeaders(100) require.NoError(t, err) require.Empty(t, headers) + + require.NotNil(t, headerTraversal.LatestHeader()) + require.NotNil(t, headerTraversal.LastTraversedHeader()) + require.Equal(t, LastTraversedHeader.Number.Uint64(), headerTraversal.LatestHeader().Number.Uint64()) } -func TestHeaderTraversalNextFinalizedHeadersCursored(t *testing.T) { +func TestHeaderTraversalNextHeadersCursored(t *testing.T) { client := new(MockEthClient) // start from genesis headerTraversal := NewHeaderTraversal(client, nil, bigint.Zero) - // blocks [0..4] - headers := makeHeaders(5, nil) - client.On("BlockHeaderByNumber", (*big.Int)(nil)).Return(&headers[4], nil).Times(1) // Times so that we can override next - client.On("BlockHeadersByRange", mock.MatchedBy(bigint.Matcher(0)), mock.MatchedBy(bigint.Matcher(4))).Return(headers, nil) - headers, err := headerTraversal.NextFinalizedHeaders(5) + headers := makeHeaders(10, nil) + + // blocks [0..4]. Latest reported is 7 + client.On("BlockHeaderByNumber", (*big.Int)(nil)).Return(&headers[7], nil).Times(1) // Times so that we can override next + client.On("BlockHeadersByRange", mock.MatchedBy(bigint.Matcher(0)), mock.MatchedBy(bigint.Matcher(4))).Return(headers[:5], nil) + _, err := headerTraversal.NextHeaders(5) require.NoError(t, err) - require.Len(t, headers, 5) - // blocks [5..9] - headers = makeHeaders(5, &headers[len(headers)-1]) - client.On("BlockHeaderByNumber", (*big.Int)(nil)).Return(&headers[4], nil) - client.On("BlockHeadersByRange", mock.MatchedBy(bigint.Matcher(5)), mock.MatchedBy(bigint.Matcher(9))).Return(headers, nil) - headers, err = headerTraversal.NextFinalizedHeaders(5) + require.Equal(t, uint64(7), headerTraversal.LatestHeader().Number.Uint64()) + require.Equal(t, uint64(4), headerTraversal.LastTraversedHeader().Number.Uint64()) + + // blocks [5..9]. Latest Reported is 9 + client.On("BlockHeaderByNumber", (*big.Int)(nil)).Return(&headers[9], nil) + client.On("BlockHeadersByRange", mock.MatchedBy(bigint.Matcher(5)), mock.MatchedBy(bigint.Matcher(9))).Return(headers[5:], nil) + _, err = headerTraversal.NextHeaders(5) require.NoError(t, err) - require.Len(t, headers, 5) + + require.Equal(t, uint64(9), headerTraversal.LatestHeader().Number.Uint64()) + require.Equal(t, uint64(9), headerTraversal.LastTraversedHeader().Number.Uint64()) } -func TestHeaderTraversalNextFinalizedHeadersMaxSize(t *testing.T) { +func TestHeaderTraversalNextHeadersMaxSize(t *testing.T) { client := new(MockEthClient) // start from genesis @@ -82,16 +93,22 @@ func TestHeaderTraversalNextFinalizedHeadersMaxSize(t *testing.T) { // clamped by the supplied size headers := makeHeaders(5, nil) client.On("BlockHeadersByRange", mock.MatchedBy(bigint.Matcher(0)), mock.MatchedBy(bigint.Matcher(4))).Return(headers, nil) - headers, err := headerTraversal.NextFinalizedHeaders(5) + headers, err := headerTraversal.NextHeaders(5) require.NoError(t, err) require.Len(t, headers, 5) + require.Equal(t, uint64(100), headerTraversal.LatestHeader().Number.Uint64()) + require.Equal(t, uint64(4), headerTraversal.LastTraversedHeader().Number.Uint64()) + // clamped by the supplied size. FinalizedHeight == 100 headers = makeHeaders(10, &headers[len(headers)-1]) client.On("BlockHeadersByRange", mock.MatchedBy(bigint.Matcher(5)), mock.MatchedBy(bigint.Matcher(14))).Return(headers, nil) - headers, err = headerTraversal.NextFinalizedHeaders(10) + headers, err = headerTraversal.NextHeaders(10) require.NoError(t, err) require.Len(t, headers, 10) + + require.Equal(t, uint64(100), headerTraversal.LatestHeader().Number.Uint64()) + require.Equal(t, uint64(14), headerTraversal.LastTraversedHeader().Number.Uint64()) } func TestHeaderTraversalMismatchedProviderStateError(t *testing.T) { @@ -104,7 +121,7 @@ func TestHeaderTraversalMismatchedProviderStateError(t *testing.T) { headers := makeHeaders(5, nil) client.On("BlockHeaderByNumber", (*big.Int)(nil)).Return(&headers[4], nil).Times(1) // Times so that we can override next client.On("BlockHeadersByRange", mock.MatchedBy(bigint.Matcher(0)), mock.MatchedBy(bigint.Matcher(4))).Return(headers, nil) - headers, err := headerTraversal.NextFinalizedHeaders(5) + headers, err := headerTraversal.NextHeaders(5) require.NoError(t, err) require.Len(t, headers, 5) @@ -112,7 +129,7 @@ func TestHeaderTraversalMismatchedProviderStateError(t *testing.T) { headers = makeHeaders(5, nil) client.On("BlockHeaderByNumber", (*big.Int)(nil)).Return(&types.Header{Number: big.NewInt(9)}, nil) client.On("BlockHeadersByRange", mock.MatchedBy(bigint.Matcher(5)), mock.MatchedBy(bigint.Matcher(9))).Return(headers, nil) - headers, err = headerTraversal.NextFinalizedHeaders(5) + headers, err = headerTraversal.NextHeaders(5) require.Nil(t, headers) require.Equal(t, ErrHeaderTraversalAndProviderMismatchedState, err) } diff --git a/indexer/node/metrics.go b/indexer/node/metrics.go index 2304bc18d56af..55da6a127e55c 100644 --- a/indexer/node/metrics.go +++ b/indexer/node/metrics.go @@ -12,7 +12,7 @@ import ( ) var ( - MetricsNamespace = "rpc" + MetricsNamespace = "op_indexer_rpc" batchMethod = "" ) diff --git a/indexer/node/mocks.go b/indexer/node/mocks.go index 115a81767b2eb..e01c6fcb1bca0 100644 --- a/indexer/node/mocks.go +++ b/indexer/node/mocks.go @@ -41,7 +41,10 @@ func (m *MockEthClient) StorageHash(address common.Address, blockNumber *big.Int return args.Get(0).(common.Hash), args.Error(1) } -func (m *MockEthClient) FilterLogs(query ethereum.FilterQuery) ([]types.Log, error) { +func (m *MockEthClient) FilterLogs(query ethereum.FilterQuery) (Logs, error) { args := m.Called(query) - return args.Get(0).([]types.Log), args.Error(1) + return args.Get(0).(Logs), args.Error(1) +} + +func (m *MockEthClient) Close() { } diff --git a/indexer/processors/bridge.go b/indexer/processors/bridge.go index 3471b550a961b..bbaa78d75e0a2 100644 --- a/indexer/processors/bridge.go +++ b/indexer/processors/bridge.go @@ -3,31 +3,45 @@ package processors import ( "context" "errors" + "fmt" "math/big" + "gorm.io/gorm" + + "github.com/ethereum/go-ethereum/log" + "github.com/ethereum-optimism/optimism/indexer/bigint" "github.com/ethereum-optimism/optimism/indexer/config" "github.com/ethereum-optimism/optimism/indexer/database" "github.com/ethereum-optimism/optimism/indexer/etl" "github.com/ethereum-optimism/optimism/indexer/processors/bridge" - - "github.com/ethereum/go-ethereum/core/types" - "github.com/ethereum/go-ethereum/log" + "github.com/ethereum-optimism/optimism/op-service/tasks" ) +var blocksLimit = 10_000 + type BridgeProcessor struct { log log.Logger db *database.DB metrics bridge.Metricer + resourceCtx context.Context + resourceCancel context.CancelFunc + tasks tasks.Group + l1Etl *etl.L1ETL + l2Etl *etl.L2ETL chainConfig config.ChainConfig - LatestL1Header *types.Header - LatestL2Header *types.Header + LastL1Header *database.L1BlockHeader + LastL2Header *database.L2BlockHeader + + LastFinalizedL1Header *database.L1BlockHeader + LastFinalizedL2Header *database.L2BlockHeader } -func NewBridgeProcessor(log log.Logger, db *database.DB, metrics bridge.Metricer, l1Etl *etl.L1ETL, chainConfig config.ChainConfig) (*BridgeProcessor, error) { +func NewBridgeProcessor(log log.Logger, db *database.DB, metrics bridge.Metricer, l1Etl *etl.L1ETL, l2Etl *etl.L2ETL, + chainConfig config.ChainConfig, shutdown context.CancelCauseFunc) (*BridgeProcessor, error) { log = log.New("processor", "bridge") latestL1Header, err := db.BridgeTransactions.L1LatestBlockHeader() @@ -39,198 +53,336 @@ func NewBridgeProcessor(log log.Logger, db *database.DB, metrics bridge.Metricer return nil, err } - var l1Header, l2Header *types.Header - if latestL1Header == nil && latestL2Header == nil { - log.Info("no indexed state, starting from rollup genesis") - } else { - l1Height, l2Height := bigint.Zero, bigint.Zero - if latestL1Header != nil { - l1Height = latestL1Header.Number - l1Header = latestL1Header.RLPHeader.Header() - metrics.RecordLatestIndexedL1Height(l1Height) - } - if latestL2Header != nil { - l2Height = latestL2Header.Number - l2Header = latestL2Header.RLPHeader.Header() - metrics.RecordLatestIndexedL2Height(l2Height) - } - log.Info("detected latest indexed bridge state", "l1_block_number", l1Height, "l2_block_number", l2Height) + latestFinalizedL1Header, err := db.BridgeTransactions.L1LatestFinalizedBlockHeader() + if err != nil { + return nil, err + } + latestFinalizedL2Header, err := db.BridgeTransactions.L2LatestFinalizedBlockHeader() + if err != nil { + return nil, err } - return &BridgeProcessor{log, db, metrics, l1Etl, chainConfig, l1Header, l2Header}, nil + log.Info("detected indexed bridge state", + "l1_block", latestL1Header, "l2_block", latestL2Header, + "finalized_l1_block", latestFinalizedL1Header, "finalized_l2_block", latestFinalizedL2Header) + + resCtx, resCancel := context.WithCancel(context.Background()) + return &BridgeProcessor{ + log: log, + db: db, + metrics: metrics, + l1Etl: l1Etl, + l2Etl: l2Etl, + resourceCtx: resCtx, + resourceCancel: resCancel, + chainConfig: chainConfig, + LastL1Header: latestL1Header, + LastL2Header: latestL2Header, + LastFinalizedL1Header: latestFinalizedL1Header, + LastFinalizedL2Header: latestFinalizedL2Header, + tasks: tasks.Group{HandleCrit: func(err error) { + shutdown(fmt.Errorf("critical error in bridge processor: %w", err)) + }}, + }, nil } -func (b *BridgeProcessor) Start(ctx context.Context) error { - done := ctx.Done() - - // Fire off independently on startup to check for - // new data or if we've indexed new L1 data. - l1EtlUpdates := b.l1Etl.Notify() - startup := make(chan interface{}, 1) - startup <- nil - +func (b *BridgeProcessor) Start() error { b.log.Info("starting bridge processor...") - for { - select { - case <-done: - b.log.Info("stopping bridge processor") - return nil - - // Tickers - case <-startup: - case <-l1EtlUpdates: + + // start L1 worker + b.tasks.Go(func() error { + l1EtlUpdates := b.l1Etl.Notify() + for range l1EtlUpdates { + done := b.metrics.RecordL1Interval() + done(b.onL1Data()) + } + b.log.Info("no more l1 etl updates. shutting down l1 task") + return nil + }) + // start L2 worker + b.tasks.Go(func() error { + l2EtlUpdates := b.l2Etl.Notify() + for range l2EtlUpdates { + done := b.metrics.RecordL2Interval() + done(b.onL2Data()) } + b.log.Info("no more l2 etl updates. shutting down l2 task") + return nil + }) + return nil +} - done := b.metrics.RecordInterval() - done(b.run()) - } +func (b *BridgeProcessor) Close() error { + // signal that we can stop any ongoing work + b.resourceCancel() + // await the work to stop + return b.tasks.Wait() } -// Runs the processing loop. In order to ensure all seen bridge finalization events -// can be correlated with bridge initiated events, we establish a shared marker between -// L1 and L2 when processing events. The latest shared indexed time (epochs) between -// L1 and L2 serves as this shared marker. -func (b *BridgeProcessor) run() error { - // In the event where we have a large number of un-observed epochs, we cap the search - // of epochs by 10k. If this turns out to be a bottleneck, we can parallelize the processing - // of epochs to significantly speed up sync times. - maxEpochRange := uint64(10_000) - var lastEpoch *big.Int - if b.LatestL1Header != nil { - lastEpoch = b.LatestL1Header.Number - } - - latestEpoch, err := b.db.Blocks.LatestObservedEpoch(lastEpoch, maxEpochRange) - if err != nil { - return err - } else if latestEpoch == nil { - if b.LatestL1Header != nil || b.LatestL2Header != nil { - // Once we have some indexed state `latestEpoch != nil` as `LatestObservedEpoch` is inclusive in its search with the last provided epoch. - b.log.Error("bridge events indexed, but no observed epoch returned", "latest_bridge_l1_block_number", b.LatestL1Header.Number) - return errors.New("bridge events indexed, but no observed epoch returned") - } - b.log.Warn("no observed epochs available. waiting...") - return nil +// onL1Data will index new bridge events for the unvisited L1 state. As new L1 bridge events +// are processed, bridge finalization events can be processed on L2 in this same window. +func (b *BridgeProcessor) onL1Data() error { + latestL1Header := b.l1Etl.LatestHeader + b.log.Info("notified of new L1 state", "l1_etl_block_number", latestL1Header.Number) + + var errs error + if err := b.processInitiatedL1Events(); err != nil { + b.log.Error("failed to process initiated L1 events", "err", err) + errs = errors.Join(errs, err) } - if b.LatestL1Header != nil && latestEpoch.L1BlockHeader.Hash == b.LatestL1Header.Hash() { - b.log.Warn("all available epochs indexed", "latest_bridge_l1_block_number", b.LatestL1Header.Number) - return nil + // `LastFinalizedL2Header` and `LastL1Header` are mutated by the same routine and can + // safely be read without needing any sync primitives + if b.LastFinalizedL2Header == nil || b.LastFinalizedL2Header.Timestamp < b.LastL1Header.Timestamp { + if err := b.processFinalizedL2Events(); err != nil { + b.log.Error("failed to process finalized L2 events", "err", err) + errs = errors.Join(errs, err) + } } - // Integrity Checks + return errs +} - genesisL1Height := big.NewInt(int64(b.chainConfig.L1StartingHeight)) - if latestEpoch.L1BlockHeader.Number.Cmp(genesisL1Height) < 0 { - b.log.Error("L1 epoch less than starting L1 height observed", "l1_starting_number", genesisL1Height, "latest_epoch_number", latestEpoch.L1BlockHeader.Number) - return errors.New("L1 epoch less than starting L1 height observed") +// onL2Data will index new bridge events for the unvisited L2 state. As new L2 bridge events +// are processed, bridge finalization events can be processed on L1 in this same window. +func (b *BridgeProcessor) onL2Data() error { + if b.l2Etl.LatestHeader.Number.Cmp(bigint.Zero) == 0 { + return nil // skip genesis } - if b.LatestL1Header != nil && latestEpoch.L1BlockHeader.Number.Cmp(b.LatestL1Header.Number) <= 0 { - b.log.Error("non-increasing l1 block height observed", "latest_bridge_l1_block_number", b.LatestL1Header.Number, "latest_epoch_l1_block_number", latestEpoch.L1BlockHeader.Number) - return errors.New("non-increasing l1 block height observed") - } - if b.LatestL2Header != nil && latestEpoch.L2BlockHeader.Number.Cmp(b.LatestL2Header.Number) <= 0 { - b.log.Error("non-increasing l2 block height observed", "latest_bridge_l2_block_number", b.LatestL2Header.Number, "latest_epoch_l2_block_number", latestEpoch.L2BlockHeader.Number) - return errors.New("non-increasing l2 block height observed") + b.log.Info("notified of new L2 state", "l2_etl_block_number", b.l2Etl.LatestHeader.Number) + + var errs error + if err := b.processInitiatedL2Events(); err != nil { + b.log.Error("failed to process initiated L2 events", "err", err) + errs = errors.Join(errs, err) } - toL1Height, toL2Height := latestEpoch.L1BlockHeader.Number, latestEpoch.L2BlockHeader.Number - fromL1Height, fromL2Height := genesisL1Height, bigint.Zero - if b.LatestL1Header != nil { - fromL1Height = new(big.Int).Add(b.LatestL1Header.Number, bigint.One) + // `LastFinalizedL1Header` and `LastL2Header` are mutated by the same routine and can + // safely be read without needing any sync primitives + if b.LastFinalizedL1Header == nil || b.LastFinalizedL1Header.Timestamp < b.LastL2Header.Timestamp { + if err := b.processFinalizedL1Events(); err != nil { + b.log.Error("failed to process finalized L1 events", "err", err) + errs = errors.Join(errs, err) + } } - if b.LatestL2Header != nil { - fromL2Height = new(big.Int).Add(b.LatestL2Header.Number, bigint.One) + + return errs +} + +// Process Initiated Bridge Events + +func (b *BridgeProcessor) processInitiatedL1Events() error { + l1BridgeLog := b.log.New("bridge", "l1", "kind", "initiated") + lastL1BlockNumber := big.NewInt(int64(b.chainConfig.L1StartingHeight) - 1) + if b.LastL1Header != nil { + lastL1BlockNumber = b.LastL1Header.Number } - l1BedrockStartingHeight := big.NewInt(int64(b.chainConfig.L1BedrockStartingHeight)) - l2BedrockStartingHeight := big.NewInt(int64(b.chainConfig.L2BedrockStartingHeight)) + // Latest unobserved L1 state bounded by `blockLimits` blocks. Since this process is driven on new L1 data, + // we always expect this query to return a new result + latestL1HeaderScope := func(db *gorm.DB) *gorm.DB { + newQuery := db.Session(&gorm.Session{NewDB: true}) // fresh subquery + headers := newQuery.Model(database.L1BlockHeader{}).Where("number > ?", lastL1BlockNumber) + return db.Where("number = (?)", newQuery.Table("(?) as block_numbers", headers.Order("number ASC").Limit(blocksLimit)).Select("MAX(number)")) + } + latestL1Header, err := b.db.Blocks.L1BlockHeaderWithScope(latestL1HeaderScope) + if err != nil { + return fmt.Errorf("failed to query new L1 state: %w", err) + } else if latestL1Header == nil { + return fmt.Errorf("no new L1 state found") + } - batchLog := b.log.New("epoch_start_number", fromL1Height, "epoch_end_number", toL1Height) - batchLog.Info("unobserved epochs", "latest_l1_block_number", fromL1Height, "latest_l2_block_number", fromL2Height) + fromL1Height, toL1Height := new(big.Int).Add(lastL1BlockNumber, bigint.One), latestL1Header.Number if err := b.db.Transaction(func(tx *database.DB) error { - l1BridgeLog := b.log.New("bridge", "l1") - l2BridgeLog := b.log.New("bridge", "l2") - - // FOR OP-MAINNET, OP-GOERLI ONLY! Specially handle the existence of pre-bedrock blocks - if l1BedrockStartingHeight.Cmp(fromL1Height) > 0 { + l1BedrockStartingHeight := big.NewInt(int64(b.chainConfig.L1BedrockStartingHeight)) + if l1BedrockStartingHeight.Cmp(fromL1Height) > 0 { // OP Mainnet & OP Goerli Only. legacyFromL1Height, legacyToL1Height := fromL1Height, toL1Height - legacyFromL2Height, legacyToL2Height := fromL2Height, toL2Height if l1BedrockStartingHeight.Cmp(toL1Height) <= 0 { legacyToL1Height = new(big.Int).Sub(l1BedrockStartingHeight, bigint.One) - legacyToL2Height = new(big.Int).Sub(l2BedrockStartingHeight, bigint.One) } - l1BridgeLog = l1BridgeLog.New("mode", "legacy", "from_l1_block_number", legacyFromL1Height, "to_l1_block_number", legacyToL1Height) - l1BridgeLog.Info("scanning for bridge events") - - l2BridgeLog = l2BridgeLog.New("mode", "legacy", "from_l2_block_number", legacyFromL2Height, "to_l2_block_number", legacyToL2Height) - l2BridgeLog.Info("scanning for bridge events") - - // First, find all possible initiated bridge events - if err := bridge.LegacyL1ProcessInitiatedBridgeEvents(l1BridgeLog, tx, b.metrics, b.chainConfig.L1Contracts, legacyFromL1Height, legacyToL1Height); err != nil { - batchLog.Error("failed to index legacy l1 initiated bridge events", "err", err) - return err - } - if err := bridge.LegacyL2ProcessInitiatedBridgeEvents(l2BridgeLog, tx, b.metrics, b.chainConfig.L2Contracts, legacyFromL2Height, legacyToL2Height); err != nil { - batchLog.Error("failed to index legacy l2 initiated bridge events", "err", err) + legacyBridgeLog := l1BridgeLog.New("mode", "legacy", "from_block_number", legacyFromL1Height, "to_block_number", legacyToL1Height) + legacyBridgeLog.Info("scanning for initiated bridge events") + if err := bridge.LegacyL1ProcessInitiatedBridgeEvents(legacyBridgeLog, tx, b.metrics, b.chainConfig.L1Contracts, legacyFromL1Height, legacyToL1Height); err != nil { return err + } else if legacyToL1Height.Cmp(toL1Height) == 0 { + return nil // a-ok! Entire range was legacy blocks } + legacyBridgeLog.Info("detected switch to bedrock", "bedrock_block_number", l1BedrockStartingHeight) + fromL1Height = l1BedrockStartingHeight + } - // Now that all initiated events have been indexed, it is ensured that all finalization can find their counterpart. - if err := bridge.LegacyL1ProcessFinalizedBridgeEvents(l1BridgeLog, tx, b.metrics, b.l1Etl.EthClient, b.chainConfig.L1Contracts, legacyFromL1Height, legacyToL1Height); err != nil { - batchLog.Error("failed to index legacy l1 finalized bridge events", "err", err) - return err + l1BridgeLog = l1BridgeLog.New("from_block_number", fromL1Height, "to_block_number", toL1Height) + l1BridgeLog.Info("scanning for initiated bridge events") + return bridge.L1ProcessInitiatedBridgeEvents(l1BridgeLog, tx, b.metrics, b.chainConfig.L1Contracts, fromL1Height, toL1Height) + }); err != nil { + return err + } + + b.LastL1Header = latestL1Header + b.metrics.RecordL1LatestHeight(latestL1Header.Number) + return nil +} + +func (b *BridgeProcessor) processInitiatedL2Events() error { + l2BridgeLog := b.log.New("bridge", "l2", "kind", "initiated") + lastL2BlockNumber := bigint.Zero + if b.LastL2Header != nil { + lastL2BlockNumber = b.LastL2Header.Number + } + + // Latest unobserved L2 state bounded by `blockLimits` blocks. Since this process is driven by new L2 data, + // we always expect this query to return a new result + latestL2HeaderScope := func(db *gorm.DB) *gorm.DB { + newQuery := db.Session(&gorm.Session{NewDB: true}) // fresh subquery + headers := newQuery.Model(database.L2BlockHeader{}).Where("number > ?", lastL2BlockNumber) + return db.Where("number = (?)", newQuery.Table("(?) as block_numbers", headers.Order("number ASC").Limit(blocksLimit)).Select("MAX(number)")) + } + latestL2Header, err := b.db.Blocks.L2BlockHeaderWithScope(latestL2HeaderScope) + if err != nil { + return fmt.Errorf("failed to query new L2 state: %w", err) + } else if latestL2Header == nil { + return fmt.Errorf("no new L2 state found") + } + + fromL2Height, toL2Height := new(big.Int).Add(lastL2BlockNumber, bigint.One), latestL2Header.Number + if err := b.db.Transaction(func(tx *database.DB) error { + l2BedrockStartingHeight := big.NewInt(int64(b.chainConfig.L2BedrockStartingHeight)) + if l2BedrockStartingHeight.Cmp(fromL2Height) > 0 { // OP Mainnet & OP Goerli Only + legacyFromL2Height, legacyToL2Height := fromL2Height, toL2Height + if l2BedrockStartingHeight.Cmp(toL2Height) <= 0 { + legacyToL2Height = new(big.Int).Sub(l2BedrockStartingHeight, bigint.One) } - if err := bridge.LegacyL2ProcessFinalizedBridgeEvents(l2BridgeLog, tx, b.metrics, b.chainConfig.L2Contracts, legacyFromL2Height, legacyToL2Height); err != nil { - batchLog.Error("failed to index legacy l2l finalized bridge events", "err", err) + + legacyBridgeLog := l2BridgeLog.New("mode", "legacy", "from_block_number", legacyFromL2Height, "to_block_number", legacyToL2Height) + legacyBridgeLog.Info("scanning for initiated bridge events") + if err := bridge.LegacyL2ProcessInitiatedBridgeEvents(legacyBridgeLog, tx, b.metrics, b.chainConfig.L2Contracts, legacyFromL2Height, legacyToL2Height); err != nil { return err + } else if legacyToL2Height.Cmp(toL2Height) == 0 { + return nil // a-ok! Entire range was legacy blocks } + legacyBridgeLog.Info("detected switch to bedrock") + fromL2Height = l2BedrockStartingHeight + } + + l2BridgeLog = l2BridgeLog.New("from_block_number", fromL2Height, "to_block_number", toL2Height) + l2BridgeLog.Info("scanning for initiated bridge events") + return bridge.L2ProcessInitiatedBridgeEvents(l2BridgeLog, tx, b.metrics, b.chainConfig.L2Contracts, fromL2Height, toL2Height) + }); err != nil { + return err + } + + b.LastL2Header = latestL2Header + b.metrics.RecordL2LatestHeight(latestL2Header.Number) + return nil +} + +// Process Finalized Bridge Events + +func (b *BridgeProcessor) processFinalizedL1Events() error { + l1BridgeLog := b.log.New("bridge", "l1", "kind", "finalization") + lastFinalizedL1BlockNumber := big.NewInt(int64(b.chainConfig.L1StartingHeight) - 1) + if b.LastFinalizedL1Header != nil { + lastFinalizedL1BlockNumber = b.LastFinalizedL1Header.Number + } - if legacyToL1Height.Cmp(toL1Height) == 0 { - // a-ok! entire batch was legacy blocks - return nil + // Latest unfinalized L1 state bounded by `blockLimit` blocks that have had L2 bridge events indexed. Since L1 data + // is indexed independently of L2, there may not be new L1 state to finalized + latestL1HeaderScope := func(db *gorm.DB) *gorm.DB { + newQuery := db.Session(&gorm.Session{NewDB: true}) // fresh subquery + headers := newQuery.Model(database.L1BlockHeader{}).Where("number > ? AND timestamp <= ?", lastFinalizedL1BlockNumber, b.LastL2Header.Timestamp) + return db.Where("number = (?)", newQuery.Table("(?) as block_numbers", headers.Order("number ASC").Limit(blocksLimit)).Select("MAX(number)")) + } + latestL1Header, err := b.db.Blocks.L1BlockHeaderWithScope(latestL1HeaderScope) + if err != nil { + return fmt.Errorf("failed to query for latest unfinalized L1 state: %w", err) + } else if latestL1Header == nil { + l1BridgeLog.Debug("no new l1 state to finalize", "last_finalized_block_number", lastFinalizedL1BlockNumber) + return nil + } + + fromL1Height, toL1Height := new(big.Int).Add(lastFinalizedL1BlockNumber, bigint.One), latestL1Header.Number + if err := b.db.Transaction(func(tx *database.DB) error { + l1BedrockStartingHeight := big.NewInt(int64(b.chainConfig.L1BedrockStartingHeight)) + if l1BedrockStartingHeight.Cmp(fromL1Height) > 0 { + legacyFromL1Height, legacyToL1Height := fromL1Height, toL1Height + if l1BedrockStartingHeight.Cmp(toL1Height) <= 0 { + legacyToL1Height = new(big.Int).Sub(l1BedrockStartingHeight, bigint.One) } - batchLog.Info("detected switch to bedrock", "l1_bedrock_starting_height", l1BedrockStartingHeight, "l2_bedrock_starting_height", l2BedrockStartingHeight) + legacyBridgeLog := l1BridgeLog.New("mode", "legacy", "from_block_number", legacyFromL1Height, "to_block_number", legacyToL1Height) + legacyBridgeLog.Info("scanning for finalized bridge events") + if err := bridge.LegacyL1ProcessFinalizedBridgeEvents(legacyBridgeLog, tx, b.metrics, b.l1Etl.EthClient, b.chainConfig.L1Contracts, legacyFromL1Height, legacyToL1Height); err != nil { + return err + } else if legacyToL1Height.Cmp(toL1Height) == 0 { + return nil // a-ok! Entire range was legacy blocks + } + legacyBridgeLog.Info("detected switch to bedrock") fromL1Height = l1BedrockStartingHeight - fromL2Height = l2BedrockStartingHeight } - l1BridgeLog = l1BridgeLog.New("from_l1_block_number", fromL1Height, "to_l1_block_number", toL1Height) - l1BridgeLog.Info("scanning for bridge events") + l1BridgeLog = l1BridgeLog.New("from_block_number", fromL1Height, "to_block_number", toL1Height) + l1BridgeLog.Info("scanning for finalized bridge events") + return bridge.L1ProcessFinalizedBridgeEvents(l1BridgeLog, tx, b.metrics, b.chainConfig.L1Contracts, fromL1Height, toL1Height) + }); err != nil { + return err + } - l2BridgeLog = l2BridgeLog.New("from_l2_block_number", fromL2Height, "to_l2_block_number", toL2Height) - l2BridgeLog.Info("scanning for bridge events") + b.LastFinalizedL1Header = latestL1Header + b.metrics.RecordL1LatestFinalizedHeight(latestL1Header.Number) + return nil +} - // First, find all possible initiated bridge events - if err := bridge.L1ProcessInitiatedBridgeEvents(l1BridgeLog, tx, b.metrics, b.chainConfig.L1Contracts, fromL1Height, toL1Height); err != nil { - batchLog.Error("failed to index l1 initiated bridge events", "err", err) - return err - } - if err := bridge.L2ProcessInitiatedBridgeEvents(l2BridgeLog, tx, b.metrics, b.chainConfig.L2Contracts, fromL2Height, toL2Height); err != nil { - batchLog.Error("failed to index l2 initiated bridge events", "err", err) - return err - } +func (b *BridgeProcessor) processFinalizedL2Events() error { + l2BridgeLog := b.log.New("bridge", "l2", "kind", "finalization") + lastFinalizedL2BlockNumber := bigint.Zero + if b.LastFinalizedL2Header != nil { + lastFinalizedL2BlockNumber = b.LastFinalizedL2Header.Number + } - // Now all finalization events can find their counterpart. - if err := bridge.L1ProcessFinalizedBridgeEvents(l1BridgeLog, tx, b.metrics, b.chainConfig.L1Contracts, fromL1Height, toL1Height); err != nil { - batchLog.Error("failed to index l1 finalized bridge events", "err", err) - return err - } - if err := bridge.L2ProcessFinalizedBridgeEvents(l2BridgeLog, tx, b.metrics, b.chainConfig.L2Contracts, fromL2Height, toL2Height); err != nil { - batchLog.Error("failed to index l2 finalized bridge events", "err", err) - return err + // Latest unfinalized L2 state bounded by `blockLimit` blocks that have had L1 bridge events indexed. Since L2 data + // is indexed independently of L1, there may not be new L2 state to finalized + latestL2HeaderScope := func(db *gorm.DB) *gorm.DB { + newQuery := db.Session(&gorm.Session{NewDB: true}) // fresh subquery + headers := newQuery.Model(database.L2BlockHeader{}).Where("number > ? AND timestamp <= ?", lastFinalizedL2BlockNumber, b.LastL1Header.Timestamp) + return db.Where("number = (?)", newQuery.Table("(?) as block_numbers", headers.Order("number ASC").Limit(blocksLimit)).Select("MAX(number)")) + } + latestL2Header, err := b.db.Blocks.L2BlockHeaderWithScope(latestL2HeaderScope) + if err != nil { + return fmt.Errorf("failed to query for latest unfinalized L2 state: %w", err) + } else if latestL2Header == nil { + l2BridgeLog.Debug("no new l2 state to finalize", "last_finalized_block_number", lastFinalizedL2BlockNumber) + return nil + } + + fromL2Height, toL2Height := new(big.Int).Add(lastFinalizedL2BlockNumber, bigint.One), latestL2Header.Number + if err := b.db.Transaction(func(tx *database.DB) error { + l2BedrockStartingHeight := big.NewInt(int64(b.chainConfig.L2BedrockStartingHeight)) + if l2BedrockStartingHeight.Cmp(fromL2Height) > 0 { + legacyFromL2Height, legacyToL2Height := fromL2Height, toL2Height + if l2BedrockStartingHeight.Cmp(toL2Height) <= 0 { + legacyToL2Height = new(big.Int).Sub(l2BedrockStartingHeight, bigint.One) + } + + legacyBridgeLog := l2BridgeLog.New("mode", "legacy", "from_block_number", legacyFromL2Height, "to_block_number", legacyToL2Height) + legacyBridgeLog.Info("scanning for finalized bridge events") + if err := bridge.LegacyL2ProcessFinalizedBridgeEvents(legacyBridgeLog, tx, b.metrics, b.chainConfig.L2Contracts, legacyFromL2Height, legacyToL2Height); err != nil { + return err + } else if legacyToL2Height.Cmp(toL2Height) == 0 { + return nil // a-ok! Entire range was legacy blocks + } + legacyBridgeLog.Info("detected switch to bedrock", "bedrock_block_number", l2BedrockStartingHeight) + fromL2Height = l2BedrockStartingHeight } - // a-ok - return nil + l2BridgeLog = l2BridgeLog.New("from_block_number", fromL2Height, "to_block_number", toL2Height) + l2BridgeLog.Info("scanning for finalized bridge events") + return bridge.L2ProcessFinalizedBridgeEvents(l2BridgeLog, tx, b.metrics, b.chainConfig.L2Contracts, fromL2Height, toL2Height) }); err != nil { return err } - batchLog.Info("indexed bridge events", "latest_l1_block_number", toL1Height, "latest_l2_block_number", toL2Height) - b.LatestL1Header = latestEpoch.L1BlockHeader.RLPHeader.Header() - b.LatestL2Header = latestEpoch.L2BlockHeader.RLPHeader.Header() + b.LastFinalizedL2Header = latestL2Header + b.metrics.RecordL2LatestFinalizedHeight(latestL2Header.Number) return nil } diff --git a/indexer/processors/bridge/l1_bridge_processor.go b/indexer/processors/bridge/l1_bridge_processor.go index 931aa7b9dd677..9d587fbec4602 100644 --- a/indexer/processors/bridge/l1_bridge_processor.go +++ b/indexer/processors/bridge/l1_bridge_processor.go @@ -4,6 +4,7 @@ import ( "fmt" "math/big" + "github.com/ethereum-optimism/optimism/indexer/bigint" "github.com/ethereum-optimism/optimism/indexer/config" "github.com/ethereum-optimism/optimism/indexer/database" "github.com/ethereum-optimism/optimism/indexer/processors/contracts" @@ -28,11 +29,14 @@ func L1ProcessInitiatedBridgeEvents(log log.Logger, db *database.DB, metrics L1M log.Info("detected transaction deposits", "size", len(optimismPortalTxDeposits)) } + mintedGWEI := bigint.Zero portalDeposits := make(map[logKey]*contracts.OptimismPortalTransactionDepositEvent, len(optimismPortalTxDeposits)) transactionDeposits := make([]database.L1TransactionDeposit, len(optimismPortalTxDeposits)) for i := range optimismPortalTxDeposits { depositTx := optimismPortalTxDeposits[i] portalDeposits[logKey{depositTx.Event.BlockHash, depositTx.Event.LogIndex}] = &depositTx + mintedGWEI = new(big.Int).Add(mintedGWEI, depositTx.Tx.Amount) + transactionDeposits[i] = database.L1TransactionDeposit{ SourceHash: depositTx.DepositTx.SourceHash, L2TransactionHash: types.NewTx(depositTx.DepositTx).Hash(), @@ -41,11 +45,15 @@ func L1ProcessInitiatedBridgeEvents(log log.Logger, db *database.DB, metrics L1M Tx: depositTx.Tx, } } + if len(transactionDeposits) > 0 { if err := db.BridgeTransactions.StoreL1TransactionDeposits(transactionDeposits); err != nil { return err } - metrics.RecordL1TransactionDeposits(len(transactionDeposits)) + + // Convert to from wei to eth + mintedETH, _ := bigint.WeiToETH(mintedGWEI).Float64() + metrics.RecordL1TransactionDeposits(len(transactionDeposits), mintedETH) } // (2) L1CrossDomainMessenger @@ -66,11 +74,15 @@ func L1ProcessInitiatedBridgeEvents(log log.Logger, db *database.DB, metrics L1M // extract the deposit hash from the previous TransactionDepositedEvent portalDeposit, ok := portalDeposits[logKey{sentMessage.Event.BlockHash, sentMessage.Event.LogIndex - 1}] if !ok { - log.Error("expected TransactionDeposit preceding SentMessage event", "tx_hash", sentMessage.Event.TransactionHash.String()) return fmt.Errorf("expected TransactionDeposit preceding SentMessage event. tx_hash = %s", sentMessage.Event.TransactionHash.String()) + } else if portalDeposit.Event.TransactionHash != sentMessage.Event.TransactionHash { + return fmt.Errorf("correlated events tx hash mismatch. deposit_tx_hash = %s, message_tx_hash = %s", portalDeposit.Event.TransactionHash, sentMessage.Event.TransactionHash) } - bridgeMessages[i] = database.L1BridgeMessage{TransactionSourceHash: portalDeposit.DepositTx.SourceHash, BridgeMessage: sentMessage.BridgeMessage} + bridgeMessages[i] = database.L1BridgeMessage{ + TransactionSourceHash: portalDeposit.DepositTx.SourceHash, + BridgeMessage: sentMessage.BridgeMessage, + } } if len(bridgeMessages) > 0 { if err := db.BridgeMessages.StoreL1BridgeMessages(bridgeMessages); err != nil { @@ -96,17 +108,21 @@ func L1ProcessInitiatedBridgeEvents(log log.Logger, db *database.DB, metrics L1M // extract the cross domain message hash & deposit source hash from the following events portalDeposit, ok := portalDeposits[logKey{initiatedBridge.Event.BlockHash, initiatedBridge.Event.LogIndex + 1}] if !ok { - log.Error("expected TransactionDeposit following BridgeInitiated event", "tx_hash", initiatedBridge.Event.TransactionHash.String()) - return fmt.Errorf("expected TransactionDeposit following BridgeInitiated event. tx_hash = %s", initiatedBridge.Event.TransactionHash.String()) + return fmt.Errorf("expected TransactionDeposit following BridgeInitiated event. tx_hash = %s", initiatedBridge.Event.TransactionHash) + } else if portalDeposit.Event.TransactionHash != initiatedBridge.Event.TransactionHash { + return fmt.Errorf("correlated events tx hash mismatch, bridge_tx_hash = %s, deposit_tx_hash = %s", initiatedBridge.Event.TransactionHash, portalDeposit.Event.TransactionHash) } + sentMessage, ok := sentMessages[logKey{initiatedBridge.Event.BlockHash, initiatedBridge.Event.LogIndex + 2}] if !ok { - log.Error("expected SentMessage following TransactionDeposit event", "tx_hash", initiatedBridge.Event.TransactionHash.String()) - return fmt.Errorf("expected SentMessage following TransactionDeposit event. tx_hash = %s", initiatedBridge.Event.TransactionHash.String()) + return fmt.Errorf("expected SentMessage following BridgeInitiated event. tx_hash = %s", initiatedBridge.Event.TransactionHash) + } else if sentMessage.Event.TransactionHash != initiatedBridge.Event.TransactionHash { + return fmt.Errorf("correlated events tx hash mismatch. bridge_tx_hash = %s, message_tx_hash = %s", initiatedBridge.Event.TransactionHash, sentMessage.Event.TransactionHash) } - initiatedBridge.BridgeTransfer.CrossDomainMessageHash = &sentMessage.BridgeMessage.MessageHash bridgedTokens[initiatedBridge.BridgeTransfer.TokenPair.LocalTokenAddress]++ + + initiatedBridge.BridgeTransfer.CrossDomainMessageHash = &sentMessage.BridgeMessage.MessageHash bridgeDeposits[i] = database.L1BridgeDeposit{ TransactionSourceHash: portalDeposit.DepositTx.SourceHash, BridgeTransfer: initiatedBridge.BridgeTransfer, @@ -145,13 +161,11 @@ func L1ProcessFinalizedBridgeEvents(log log.Logger, db *database.DB, metrics L1M if err != nil { return err } else if withdrawal == nil { - log.Error("missing indexed withdrawal on proven event!", "tx_hash", proven.Event.TransactionHash.String()) - return fmt.Errorf("missing indexed withdrawal! tx_hash = %s", proven.Event.TransactionHash.String()) + return fmt.Errorf("missing indexed withdrawal! tx_hash = %s", proven.Event.TransactionHash) } if err := db.BridgeTransactions.MarkL2TransactionWithdrawalProvenEvent(proven.WithdrawalHash, provenWithdrawals[i].Event.GUID); err != nil { - log.Error("failed to mark withdrawal as proven", "err", err, "tx_hash", proven.Event.TransactionHash.String()) - return err + return fmt.Errorf("failed to mark withdrawal as proven. tx_hash = %s: %w", proven.Event.TransactionHash, err) } } if len(provenWithdrawals) > 0 { @@ -168,18 +182,16 @@ func L1ProcessFinalizedBridgeEvents(log log.Logger, db *database.DB, metrics L1M } for i := range finalizedWithdrawals { - finalized := finalizedWithdrawals[i] - withdrawal, err := db.BridgeTransactions.L2TransactionWithdrawal(finalized.WithdrawalHash) + finalizedWithdrawal := finalizedWithdrawals[i] + withdrawal, err := db.BridgeTransactions.L2TransactionWithdrawal(finalizedWithdrawal.WithdrawalHash) if err != nil { return err } else if withdrawal == nil { - log.Error("missing indexed withdrawal on finalization event!", "tx_hash", finalized.Event.TransactionHash.String()) - return fmt.Errorf("missing indexed withdrawal on finalization! tx_hash: %s", finalized.Event.TransactionHash.String()) + return fmt.Errorf("missing indexed withdrawal on finalization! tx_hash = %s", finalizedWithdrawal.Event.TransactionHash.String()) } - if err = db.BridgeTransactions.MarkL2TransactionWithdrawalFinalizedEvent(finalized.WithdrawalHash, finalized.Event.GUID, finalized.Success); err != nil { - log.Error("failed to mark withdrawal as finalized", "err", err, "tx_hash", finalized.Event.TransactionHash.String()) - return err + if err = db.BridgeTransactions.MarkL2TransactionWithdrawalFinalizedEvent(finalizedWithdrawal.WithdrawalHash, finalizedWithdrawal.Event.GUID, finalizedWithdrawal.Success); err != nil { + return fmt.Errorf("failed to mark withdrawal as finalized. tx_hash = %s: %w", finalizedWithdrawal.Event.TransactionHash, err) } } if len(finalizedWithdrawals) > 0 { @@ -195,21 +207,17 @@ func L1ProcessFinalizedBridgeEvents(log log.Logger, db *database.DB, metrics L1M log.Info("detected relayed messages", "size", len(crossDomainRelayedMessages)) } - relayedMessages := make(map[logKey]*contracts.CrossDomainMessengerRelayedMessageEvent, len(crossDomainRelayedMessages)) for i := range crossDomainRelayedMessages { relayed := crossDomainRelayedMessages[i] - relayedMessages[logKey{BlockHash: relayed.Event.BlockHash, LogIndex: relayed.Event.LogIndex}] = &relayed message, err := db.BridgeMessages.L2BridgeMessage(relayed.MessageHash) if err != nil { return err } else if message == nil { - log.Error("missing indexed L2CrossDomainMessenger message", "tx_hash", relayed.Event.TransactionHash.String()) - return fmt.Errorf("missing indexed L2CrossDomainMessager message. tx_hash %s", relayed.Event.TransactionHash.String()) + return fmt.Errorf("missing indexed L2CrossDomainMessager message! tx_hash = %s", relayed.Event.TransactionHash.String()) } if err := db.BridgeMessages.MarkRelayedL2BridgeMessage(relayed.MessageHash, relayed.Event.GUID); err != nil { - log.Error("failed to relay cross domain message", "err", err, "tx_hash", relayed.Event.TransactionHash.String()) - return err + return fmt.Errorf("failed to relay cross domain message. tx_hash = %s: %w", relayed.Event.TransactionHash, err) } } if len(crossDomainRelayedMessages) > 0 { @@ -217,37 +225,21 @@ func L1ProcessFinalizedBridgeEvents(log log.Logger, db *database.DB, metrics L1M } // (4) L1StandardBridge + // - Nothing actionable on the database. Since the StandardBridge is layered ontop of the + // CrossDomainMessenger, there's no need for any sanity or invariant checks as the previous step + // ensures a relayed message (finalized bridge) can be linked with a sent message (initiated bridge). finalizedBridges, err := contracts.StandardBridgeFinalizedEvents("l1", l1Contracts.L1StandardBridgeProxy, db, fromHeight, toHeight) if err != nil { return err } - if len(finalizedBridges) > 0 { - log.Info("detected finalized bridge withdrawals", "size", len(finalizedBridges)) - } finalizedTokens := make(map[common.Address]int) for i := range finalizedBridges { - // Nothing actionable on the database. However, we can treat the relayed message - // as an invariant by ensuring we can query for a deposit by the same hash finalizedBridge := finalizedBridges[i] - relayedMessage, ok := relayedMessages[logKey{finalizedBridge.Event.BlockHash, finalizedBridge.Event.LogIndex + 1}] - if !ok { - log.Error("expected RelayedMessage following BridgeFinalized event", "tx_hash", finalizedBridge.Event.TransactionHash.String()) - return fmt.Errorf("expected RelayedMessage following BridgeFinalized event. tx_hash = %s", finalizedBridge.Event.TransactionHash.String()) - } - - // Since the message hash is computed from the relayed message, this ensures the deposit fields must match - withdrawal, err := db.BridgeTransfers.L2BridgeWithdrawalWithFilter(database.BridgeTransfer{CrossDomainMessageHash: &relayedMessage.MessageHash}) - if err != nil { - return err - } else if withdrawal == nil { - log.Error("missing L2StandardBridge withdrawal on L1 finalization", "tx_hash", finalizedBridge.Event.TransactionHash.String()) - return fmt.Errorf("missing L2StandardBridge withdrawal on L1 finalization. tx_hash: %s", finalizedBridge.Event.TransactionHash.String()) - } - finalizedTokens[finalizedBridge.BridgeTransfer.TokenPair.LocalTokenAddress]++ } if len(finalizedBridges) > 0 { + log.Info("detected finalized bridge withdrawals", "size", len(finalizedBridges)) for tokenAddr, size := range finalizedTokens { metrics.RecordL1FinalizedBridgeTransfers(tokenAddr, size) } diff --git a/indexer/processors/bridge/l2_bridge_processor.go b/indexer/processors/bridge/l2_bridge_processor.go index 038f41cc41fbd..164a9c4be09b6 100644 --- a/indexer/processors/bridge/l2_bridge_processor.go +++ b/indexer/processors/bridge/l2_bridge_processor.go @@ -1,10 +1,10 @@ package bridge import ( - "errors" "fmt" "math/big" + "github.com/ethereum-optimism/optimism/indexer/bigint" "github.com/ethereum-optimism/optimism/indexer/config" "github.com/ethereum-optimism/optimism/indexer/database" "github.com/ethereum-optimism/optimism/indexer/processors/contracts" @@ -28,11 +28,14 @@ func L2ProcessInitiatedBridgeEvents(log log.Logger, db *database.DB, metrics L2M log.Info("detected transaction withdrawals", "size", len(l2ToL1MPMessagesPassed)) } + withdrawnWEI := bigint.Zero messagesPassed := make(map[logKey]*contracts.L2ToL1MessagePasserMessagePassed, len(l2ToL1MPMessagesPassed)) transactionWithdrawals := make([]database.L2TransactionWithdrawal, len(l2ToL1MPMessagesPassed)) for i := range l2ToL1MPMessagesPassed { messagePassed := l2ToL1MPMessagesPassed[i] messagesPassed[logKey{messagePassed.Event.BlockHash, messagePassed.Event.LogIndex}] = &messagePassed + withdrawnWEI = new(big.Int).Add(withdrawnWEI, messagePassed.Tx.Amount) + transactionWithdrawals[i] = database.L2TransactionWithdrawal{ WithdrawalHash: messagePassed.WithdrawalHash, InitiatedL2EventGUID: messagePassed.Event.GUID, @@ -45,7 +48,10 @@ func L2ProcessInitiatedBridgeEvents(log log.Logger, db *database.DB, metrics L2M if err := db.BridgeTransactions.StoreL2TransactionWithdrawals(transactionWithdrawals); err != nil { return err } - metrics.RecordL2TransactionWithdrawals(len(transactionWithdrawals)) + + // Convert the withdrawn WEI to ETH + withdrawnETH, _ := bigint.WeiToETH(withdrawnWEI).Float64() + metrics.RecordL2TransactionWithdrawals(len(transactionWithdrawals), withdrawnETH) } // (2) L2CrossDomainMessenger @@ -66,8 +72,9 @@ func L2ProcessInitiatedBridgeEvents(log log.Logger, db *database.DB, metrics L2M // extract the withdrawal hash from the previous MessagePassed event messagePassed, ok := messagesPassed[logKey{sentMessage.Event.BlockHash, sentMessage.Event.LogIndex - 1}] if !ok { - log.Error("expected MessagePassedEvent preceding SentMessage", "tx_hash", sentMessage.Event.TransactionHash.String()) - return fmt.Errorf("expected MessagePassedEvent preceding SentMessage. tx_hash = %s", sentMessage.Event.TransactionHash.String()) + return fmt.Errorf("expected MessagePassedEvent preceding SentMessage. tx_hash = %s", sentMessage.Event.TransactionHash) + } else if messagePassed.Event.TransactionHash != sentMessage.Event.TransactionHash { + return fmt.Errorf("correlated events tx hash mismatch. message_tx_hash = %s, withdraw_tx_hash = %s", sentMessage.Event.TransactionHash, messagePassed.Event.TransactionHash) } bridgeMessages[i] = database.L2BridgeMessage{TransactionWithdrawalHash: messagePassed.WithdrawalHash, BridgeMessage: sentMessage.BridgeMessage} @@ -93,20 +100,24 @@ func L2ProcessInitiatedBridgeEvents(log log.Logger, db *database.DB, metrics L2M for i := range initiatedBridges { initiatedBridge := initiatedBridges[i] - // extract the cross domain message hash & deposit source hash from the following events + // extract the cross domain message hash & withdraw hash from the following events messagePassed, ok := messagesPassed[logKey{initiatedBridge.Event.BlockHash, initiatedBridge.Event.LogIndex + 1}] if !ok { - log.Error("expected MessagePassed following BridgeInitiated event", "tx_hash", initiatedBridge.Event.TransactionHash.String()) - return fmt.Errorf("expected MessagePassed following BridgeInitiated event. tx_hash = %s", initiatedBridge.Event.TransactionHash.String()) + return fmt.Errorf("expected MessagePassed following BridgeInitiated event. tx_hash = %s", initiatedBridge.Event.TransactionHash) + } else if messagePassed.Event.TransactionHash != initiatedBridge.Event.TransactionHash { + return fmt.Errorf("correlated events tx hash mismatch. bridge_tx_hash = %s, withdraw_tx_hash = %s", initiatedBridge.Event.TransactionHash, messagePassed.Event.TransactionHash) } + sentMessage, ok := sentMessages[logKey{initiatedBridge.Event.BlockHash, initiatedBridge.Event.LogIndex + 2}] if !ok { - log.Error("expected SentMessage following MessagePassed event", "tx_hash", initiatedBridge.Event.TransactionHash.String()) - return fmt.Errorf("expected SentMessage following MessagePassed event. tx_hash = %s", initiatedBridge.Event.TransactionHash.String()) + return fmt.Errorf("expected SentMessage following BridgeInitiated event. tx_hash = %s", initiatedBridge.Event.TransactionHash) + } else if sentMessage.Event.TransactionHash != initiatedBridge.Event.TransactionHash { + return fmt.Errorf("correlated events tx hash mismatch. bridge_tx_hash = %s, message_tx_hash = %s", initiatedBridge.Event.TransactionHash, sentMessage.Event.TransactionHash) } - initiatedBridge.BridgeTransfer.CrossDomainMessageHash = &sentMessage.BridgeMessage.MessageHash bridgedTokens[initiatedBridge.BridgeTransfer.TokenPair.LocalTokenAddress]++ + + initiatedBridge.BridgeTransfer.CrossDomainMessageHash = &sentMessage.BridgeMessage.MessageHash bridgeWithdrawals[i] = database.L2BridgeWithdrawal{ TransactionWithdrawalHash: messagePassed.WithdrawalHash, BridgeTransfer: initiatedBridge.BridgeTransfer, @@ -141,59 +152,39 @@ func L2ProcessFinalizedBridgeEvents(log log.Logger, db *database.DB, metrics L2M log.Info("detected relayed messages", "size", len(crossDomainRelayedMessages)) } - relayedMessages := make(map[logKey]*contracts.CrossDomainMessengerRelayedMessageEvent, len(crossDomainRelayedMessages)) for i := range crossDomainRelayedMessages { relayed := crossDomainRelayedMessages[i] - relayedMessages[logKey{BlockHash: relayed.Event.BlockHash, LogIndex: relayed.Event.LogIndex}] = &relayed message, err := db.BridgeMessages.L1BridgeMessage(relayed.MessageHash) if err != nil { return err } else if message == nil { - log.Error("missing indexed L1CrossDomainMessenger message", "tx_hash", relayed.Event.TransactionHash.String()) - return fmt.Errorf("missing indexed L1CrossDomainMessager message. tx_hash = %s", relayed.Event.TransactionHash.String()) + return fmt.Errorf("missing indexed L1CrossDomainMessager message! tx_hash = %s", relayed.Event.TransactionHash) } if err := db.BridgeMessages.MarkRelayedL1BridgeMessage(relayed.MessageHash, relayed.Event.GUID); err != nil { - log.Error("failed to relay cross domain message", "err", err, "tx_hash", relayed.Event.TransactionHash.String()) - return err + return fmt.Errorf("failed to relay cross domain message. tx_hash = %s: %w", relayed.Event.TransactionHash, err) } } - if len(relayedMessages) > 0 { - metrics.RecordL2CrossDomainRelayedMessages(len(relayedMessages)) + if len(crossDomainRelayedMessages) > 0 { + metrics.RecordL2CrossDomainRelayedMessages(len(crossDomainRelayedMessages)) } // (2) L2StandardBridge + // - Nothing actionable on the database. Since the StandardBridge is layered ontop of the + // CrossDomainMessenger, there's no need for any sanity or invariant checks as the previous step + // ensures a relayed message (finalized bridge) can be linked with a sent message (initiated bridge). finalizedBridges, err := contracts.StandardBridgeFinalizedEvents("l2", l2Contracts.L2StandardBridge, db, fromHeight, toHeight) if err != nil { return err } - if len(finalizedBridges) > 0 { - log.Info("detected finalized bridge deposits", "size", len(finalizedBridges)) - } finalizedTokens := make(map[common.Address]int) for i := range finalizedBridges { - // Nothing actionable on the database. However, we can treat the relayed message - // as an invariant by ensuring we can query for a deposit by the same hash finalizedBridge := finalizedBridges[i] - relayedMessage, ok := relayedMessages[logKey{finalizedBridge.Event.BlockHash, finalizedBridge.Event.LogIndex + 1}] - if !ok { - log.Error("expected RelayedMessage following BridgeFinalized event", "tx_hash", finalizedBridge.Event.TransactionHash.String()) - return fmt.Errorf("expected RelayedMessage following BridgeFinalized event. tx_hash = %s", finalizedBridge.Event.TransactionHash.String()) - } - - // Since the message hash is computed from the relayed message, this ensures the withdrawal fields must match - deposit, err := db.BridgeTransfers.L1BridgeDepositWithFilter(database.BridgeTransfer{CrossDomainMessageHash: &relayedMessage.MessageHash}) - if err != nil { - return err - } else if deposit == nil { - log.Error("missing L1StandardBridge deposit on L2 finalization", "tx_hash", finalizedBridge.Event.TransactionHash.String()) - return errors.New("missing L1StandardBridge deposit on L2 finalization") - } - finalizedTokens[finalizedBridge.BridgeTransfer.TokenPair.LocalTokenAddress]++ } if len(finalizedBridges) > 0 { + log.Info("detected finalized bridge deposits", "size", len(finalizedBridges)) for tokenAddr, size := range finalizedTokens { metrics.RecordL2FinalizedBridgeTransfers(tokenAddr, size) } diff --git a/indexer/processors/bridge/legacy_bridge_processor.go b/indexer/processors/bridge/legacy_bridge_processor.go index ab34b2673cb76..c8d98d862f7a9 100644 --- a/indexer/processors/bridge/legacy_bridge_processor.go +++ b/indexer/processors/bridge/legacy_bridge_processor.go @@ -5,9 +5,9 @@ import ( "math/big" "github.com/ethereum/go-ethereum/common" - "github.com/ethereum/go-ethereum/crypto" "github.com/ethereum/go-ethereum/log" + "github.com/ethereum-optimism/optimism/indexer/bigint" "github.com/ethereum-optimism/optimism/indexer/config" "github.com/ethereum-optimism/optimism/indexer/database" "github.com/ethereum-optimism/optimism/indexer/node" @@ -31,17 +31,18 @@ func LegacyL1ProcessInitiatedBridgeEvents(log log.Logger, db *database.DB, metri log.Info("detected legacy transaction deposits", "size", len(ctcTxDepositEvents)) } + mintedWEI := bigint.Zero ctcTxDeposits := make(map[logKey]*contracts.LegacyCTCDepositEvent, len(ctcTxDepositEvents)) transactionDeposits := make([]database.L1TransactionDeposit, len(ctcTxDepositEvents)) for i := range ctcTxDepositEvents { deposit := ctcTxDepositEvents[i] ctcTxDeposits[logKey{deposit.Event.BlockHash, deposit.Event.LogIndex}] = &deposit - transactionDeposits[i] = database.L1TransactionDeposit{ - // We re-use the L2 Transaction hash as the source hash - // to remain consistent in the schema. - SourceHash: deposit.TxHash, - L2TransactionHash: deposit.TxHash, + mintedWEI = new(big.Int).Add(mintedWEI, deposit.Tx.Amount) + // We re-use the L2 Transaction hash as the source hash to remain consistent in the schema. + transactionDeposits[i] = database.L1TransactionDeposit{ + SourceHash: deposit.TxHash, + L2TransactionHash: deposit.TxHash, InitiatedL1EventGUID: deposit.Event.GUID, GasLimit: deposit.GasLimit, Tx: deposit.Tx, @@ -51,7 +52,9 @@ func LegacyL1ProcessInitiatedBridgeEvents(log log.Logger, db *database.DB, metri if err := db.BridgeTransactions.StoreL1TransactionDeposits(transactionDeposits); err != nil { return err } - metrics.RecordL1TransactionDeposits(len(transactionDeposits)) + + mintedETH, _ := bigint.WeiToETH(mintedWEI).Float64() + metrics.RecordL1TransactionDeposits(len(transactionDeposits), mintedETH) } // (2) L1CrossDomainMessenger @@ -72,8 +75,9 @@ func LegacyL1ProcessInitiatedBridgeEvents(log log.Logger, db *database.DB, metri // extract the deposit hash from the previous TransactionDepositedEvent ctcTxDeposit, ok := ctcTxDeposits[logKey{sentMessage.Event.BlockHash, sentMessage.Event.LogIndex - 1}] if !ok { - log.Error("missing transaction deposit for cross domain message", "tx_hash", sentMessage.Event.TransactionHash.String()) - return fmt.Errorf("missing preceding TransactionEnqueued for SentMessage event. tx_hash = %s", sentMessage.Event.TransactionHash.String()) + return fmt.Errorf("expected TransactionEnqueued preceding SentMessage event. tx_hash = %s", sentMessage.Event.TransactionHash) + } else if ctcTxDeposit.Event.TransactionHash != sentMessage.Event.TransactionHash { + return fmt.Errorf("correlated events tx hash mismatch. deposit_tx_hash = %s, message_tx_hash = %s", ctcTxDeposit.Event.TransactionHash, sentMessage.Event.TransactionHash) } bridgeMessages[i] = database.L1BridgeMessage{TransactionSourceHash: ctcTxDeposit.TxHash, BridgeMessage: sentMessage.BridgeMessage} @@ -104,13 +108,16 @@ func LegacyL1ProcessInitiatedBridgeEvents(log log.Logger, db *database.DB, metri // - Event Flow: TransactionEnqueued -> SentMessage -> DepositInitiated sentMessage, ok := sentMessages[logKey{initiatedBridge.Event.BlockHash, initiatedBridge.Event.LogIndex - 1}] if !ok { - log.Error("missing cross domain message for bridge transfer", "tx_hash", initiatedBridge.Event.TransactionHash.String()) - return fmt.Errorf("expected SentMessage preceding DepositInitiated event. tx_hash = %s", initiatedBridge.Event.TransactionHash.String()) + return fmt.Errorf("expected SentMessage preceding DepositInitiated event. tx_hash = %s", initiatedBridge.Event.TransactionHash) + } else if sentMessage.Event.TransactionHash != initiatedBridge.Event.TransactionHash { + return fmt.Errorf("correlated events tx hash mismatch. bridge_tx_hash = %s, message_tx_hash = %s", initiatedBridge.Event.TransactionHash, sentMessage.Event.TransactionHash) } + ctcTxDeposit, ok := ctcTxDeposits[logKey{initiatedBridge.Event.BlockHash, initiatedBridge.Event.LogIndex - 2}] if !ok { - log.Error("missing transaction deposit for bridge transfer", "tx_hash", initiatedBridge.Event.TransactionHash.String()) - return fmt.Errorf("expected TransactionEnqueued preceding DepostInitiated event. tx_hash = %s", initiatedBridge.Event.TransactionHash.String()) + return fmt.Errorf("expected TransactionEnqueued preceding BridgeInitiated event. tx_hash = %s", initiatedBridge.Event.TransactionHash) + } else if ctcTxDeposit.Event.TransactionHash != initiatedBridge.Event.TransactionHash { + return fmt.Errorf("correlated events tx hash mismatch. bridge_tx_hash = %s, deposit_tx_hash = %s", initiatedBridge.Event.TransactionHash, ctcTxDeposit.Event.TransactionHash) } initiatedBridge.BridgeTransfer.CrossDomainMessageHash = &sentMessage.BridgeMessage.MessageHash @@ -148,18 +155,22 @@ func LegacyL2ProcessInitiatedBridgeEvents(log log.Logger, db *database.DB, metri log.Info("detected legacy transaction withdrawals (via L2CrossDomainMessenger)", "size", len(crossDomainSentMessages)) } - sentMessages := make(map[logKey]*contracts.CrossDomainMessengerSentMessageEvent, len(crossDomainSentMessages)) + type sentMessageEvent struct { + *contracts.CrossDomainMessengerSentMessageEvent + WithdrawalHash common.Hash + } + + withdrawnWEI := bigint.Zero + sentMessages := make(map[logKey]sentMessageEvent, len(crossDomainSentMessages)) bridgeMessages := make([]database.L2BridgeMessage, len(crossDomainSentMessages)) transactionWithdrawals := make([]database.L2TransactionWithdrawal, len(crossDomainSentMessages)) for i := range crossDomainSentMessages { sentMessage := crossDomainSentMessages[i] - sentMessages[logKey{sentMessage.Event.BlockHash, sentMessage.Event.LogIndex}] = &sentMessage + withdrawnWEI = new(big.Int).Add(withdrawnWEI, sentMessage.BridgeMessage.Tx.Amount) - // To ensure consistency in the schema, we duplicate this as the "root" transaction withdrawal. The storage key in the message - // passer contract is sha3(calldata + sender). The sender always being the L2CrossDomainMessenger pre-bedrock. - withdrawalHash := crypto.Keccak256Hash(append(sentMessage.MessageCalldata, l2Contracts.L2CrossDomainMessenger[:]...)) + // We re-use the L2CrossDomainMessenger message hash as the withdrawal hash to remain consistent in the schema. transactionWithdrawals[i] = database.L2TransactionWithdrawal{ - WithdrawalHash: withdrawalHash, + WithdrawalHash: sentMessage.BridgeMessage.MessageHash, InitiatedL2EventGUID: sentMessage.Event.GUID, Nonce: sentMessage.BridgeMessage.Nonce, GasLimit: sentMessage.BridgeMessage.GasLimit, @@ -172,8 +183,9 @@ func LegacyL2ProcessInitiatedBridgeEvents(log log.Logger, db *database.DB, metri }, } + sentMessages[logKey{sentMessage.Event.BlockHash, sentMessage.Event.LogIndex}] = sentMessageEvent{&sentMessage, sentMessage.BridgeMessage.MessageHash} bridgeMessages[i] = database.L2BridgeMessage{ - TransactionWithdrawalHash: withdrawalHash, + TransactionWithdrawalHash: sentMessage.BridgeMessage.MessageHash, BridgeMessage: sentMessage.BridgeMessage, } } @@ -184,7 +196,9 @@ func LegacyL2ProcessInitiatedBridgeEvents(log log.Logger, db *database.DB, metri if err := db.BridgeMessages.StoreL2BridgeMessages(bridgeMessages); err != nil { return err } - metrics.RecordL2TransactionWithdrawals(len(transactionWithdrawals)) + + withdrawnETH, _ := bigint.WeiToETH(withdrawnWEI).Float64() + metrics.RecordL2TransactionWithdrawals(len(transactionWithdrawals), withdrawnETH) metrics.RecordL2CrossDomainSentMessages(len(bridgeMessages)) } @@ -207,14 +221,15 @@ func LegacyL2ProcessInitiatedBridgeEvents(log log.Logger, db *database.DB, metri // - Event Flow: TransactionEnqueued -> SentMessage -> DepositInitiated sentMessage, ok := sentMessages[logKey{initiatedBridge.Event.BlockHash, initiatedBridge.Event.LogIndex - 1}] if !ok { - log.Error("expected SentMessage preceding DepositInitiated event", "tx_hash", initiatedBridge.Event.TransactionHash.String()) - return fmt.Errorf("expected SentMessage preceding DepositInitiated event. tx_hash = %s", initiatedBridge.Event.TransactionHash) + return fmt.Errorf("expected SentMessage preceding BridgeInitiated event. tx_hash = %s", initiatedBridge.Event.TransactionHash) + } else if sentMessage.Event.TransactionHash != initiatedBridge.Event.TransactionHash { + return fmt.Errorf("correlated events tx hash mismatch. bridge_tx_hash = %s, message_tx_hash = %s", initiatedBridge.Event.TransactionHash, sentMessage.Event.TransactionHash) } - initiatedBridge.BridgeTransfer.CrossDomainMessageHash = &sentMessage.BridgeMessage.MessageHash bridgedTokens[initiatedBridge.BridgeTransfer.TokenPair.LocalTokenAddress]++ + initiatedBridge.BridgeTransfer.CrossDomainMessageHash = &sentMessage.BridgeMessage.MessageHash l2BridgeWithdrawals[i] = database.L2BridgeWithdrawal{ - TransactionWithdrawalHash: sentMessage.BridgeMessage.MessageHash, + TransactionWithdrawalHash: sentMessage.WithdrawalHash, BridgeTransfer: initiatedBridge.BridgeTransfer, } } @@ -259,17 +274,15 @@ func LegacyL1ProcessFinalizedBridgeEvents(log log.Logger, db *database.DB, metri // for OP-Mainnet pre-regensis withdrawals that no longer exist on L2. tx, err := l1Client.TxByHash(relayedMessage.Event.TransactionHash) if err != nil { - return err + return fmt.Errorf("unable to query legacy relayed. tx_hash = %s: %w", relayedMessage.Event.TransactionHash, err) } else if tx == nil { - log.Error("missing tx for relayed message", "tx_hash", relayedMessage.Event.TransactionHash.String()) - return fmt.Errorf("missing tx for relayed message. tx_hash = %s", relayedMessage.Event.TransactionHash.String()) + return fmt.Errorf("missing tx for relayed message! tx_hash = %s", relayedMessage.Event.TransactionHash) } relayMessageData := tx.Data()[4:] inputs, err := contracts.CrossDomainMessengerLegacyRelayMessageEncoding.Inputs.Unpack(relayMessageData) if err != nil || inputs == nil { - log.Error("failed to extract XDomainCallData from relayMessage transaction", "err", err, "tx_hash", relayedMessage.Event.TransactionHash.String()) - return fmt.Errorf("unable to extract XDomainCallData from relayMessage transaction. err = %w. tx_hash = %s", err, relayedMessage.Event.TransactionHash.String()) + return fmt.Errorf("unable to extract XDomainCallData from relayMessage transaction. tx_hash = %s: %w", relayedMessage.Event.TransactionHash, err) } // NOTE: Since OP-Mainnet is the only network to go through a regensis we can simply harcode the @@ -280,23 +293,19 @@ func LegacyL1ProcessFinalizedBridgeEvents(log log.Logger, db *database.DB, metri skippedPreRegenesisMessages++ continue } else { - log.Error("missing indexed legacy L2CrossDomainMessenger message", "tx_hash", relayedMessage.Event.TransactionHash.String()) - return fmt.Errorf("missing indexed L2CrossDomainMessager message. tx_hash %s", relayedMessage.Event.TransactionHash.String()) + return fmt.Errorf("missing indexed L2CrossDomainMessenger message! tx_hash = %s", relayedMessage.Event.TransactionHash) } } - // Mark the associated tx withdrawal as proven/finalized with the same event + // Mark the associated tx withdrawal as proven/finalized with the same event. The message hash is also the transaction withdrawal hash if err := db.BridgeTransactions.MarkL2TransactionWithdrawalProvenEvent(relayedMessage.MessageHash, relayedMessage.Event.GUID); err != nil { - log.Error("failed to mark withdrawal as proven", "err", err) - return err + return fmt.Errorf("failed to mark withdrawal as proven. tx_hash = %s: %w", relayedMessage.Event.TransactionHash, err) } if err := db.BridgeTransactions.MarkL2TransactionWithdrawalFinalizedEvent(relayedMessage.MessageHash, relayedMessage.Event.GUID, true); err != nil { - log.Error("failed to mark withdrawal as finalzed", "err", err) - return err + return fmt.Errorf("failed to mark withdrawal as finalized. tx_hash = %s: %w", relayedMessage.Event.TransactionHash, err) } if err := db.BridgeMessages.MarkRelayedL2BridgeMessage(relayedMessage.MessageHash, relayedMessage.Event.GUID); err != nil { - log.Error("failed to relay cross domain message", "err", err) - return err + return fmt.Errorf("failed to relay cross domain message. tx_hash = %s: %w", relayedMessage.Event.TransactionHash, err) } } if len(crossDomainRelayedMessages) > 0 { @@ -309,10 +318,12 @@ func LegacyL1ProcessFinalizedBridgeEvents(log log.Logger, db *database.DB, metri log.Warn("skipped pre-regensis relayed L2CrossDomainMessenger withdrawals", "size", skippedPreRegenesisMessages) } - // (2) L2StandardBridge -- no-op for now as there's nothing actionable to do here besides - // santiy checks which is not important for legacy code. Not worth extra code pre-bedrock. - // The message status is already tracked via the relayed bridge messed through the cross domain messenger. - // - NOTE: This means we dont increment metrics for finalized bridge transfers + // (2) L1StandardBridge + // - Nothing actionable on the database. Since the StandardBridge is layered ontop of the + // CrossDomainMessenger, there's no need for any sanity or invariant checks as the previous step + // ensures a relayed message (finalized bridge) can be linked with a sent message (initiated bridge). + + // - NOTE: Ignoring metrics for pre-bedrock transfers // a-ok! return nil @@ -338,23 +349,23 @@ func LegacyL2ProcessFinalizedBridgeEvents(log log.Logger, db *database.DB, metri if err != nil { return err } else if message == nil { - log.Error("missing indexed legacy L1CrossDomainMessenger message", "tx_hash", relayedMessage.Event.TransactionHash.String()) - return fmt.Errorf("missing indexed L1CrossDomainMessager message. tx_hash = %s", relayedMessage.Event.TransactionHash.String()) + return fmt.Errorf("missing indexed L1CrossDomainMessager message! tx_hash = %s", relayedMessage.Event.TransactionHash) } if err := db.BridgeMessages.MarkRelayedL1BridgeMessage(relayedMessage.MessageHash, relayedMessage.Event.GUID); err != nil { - log.Error("failed to relay cross domain message", "err", err) - return err + return fmt.Errorf("failed to relay cross domain message: %w", err) } } if len(crossDomainRelayedMessages) > 0 { metrics.RecordL2CrossDomainRelayedMessages(len(crossDomainRelayedMessages)) } - // (2) L2StandardBridge -- no-op for now as there's nothing actionable to do here besides - // santiy checks which is not important for legacy code. Not worth the extra code pre-bedorck. - // The message status is already tracked via the relayed bridge messed through the cross domain messenger. - // - NOTE: This means we dont increment metrics for finalized bridge transfers + // (2) L2StandardBridge + // - Nothing actionable on the database. Since the StandardBridge is layered ontop of the + // CrossDomainMessenger, there's no need for any sanity or invariant checks as the previous step + // ensures a relayed message (finalized bridge) can be linked with a sent message (initiated bridge). + + // - NOTE: Ignoring metrics for pre-bedrock transfers // a-ok! return nil diff --git a/indexer/processors/bridge/metrics.go b/indexer/processors/bridge/metrics.go index 98ec99e497a00..9dea9a897a84a 100644 --- a/indexer/processors/bridge/metrics.go +++ b/indexer/processors/bridge/metrics.go @@ -10,13 +10,15 @@ import ( ) var ( - MetricsNamespace string = "bridge" + MetricsNamespace string = "op_indexer_bridge" ) type L1Metricer interface { - RecordLatestIndexedL1Height(height *big.Int) + RecordL1Interval() (done func(err error)) + RecordL1LatestHeight(height *big.Int) + RecordL1LatestFinalizedHeight(height *big.Int) - RecordL1TransactionDeposits(size int) + RecordL1TransactionDeposits(size int, mintedETH float64) RecordL1ProvenWithdrawals(size int) RecordL1FinalizedWithdrawals(size int) @@ -28,9 +30,11 @@ type L1Metricer interface { } type L2Metricer interface { - RecordLatestIndexedL2Height(height *big.Int) + RecordL2Interval() (done func(err error)) + RecordL2LatestHeight(height *big.Int) + RecordL2LatestFinalizedHeight(height *big.Int) - RecordL2TransactionWithdrawals(size int) + RecordL2TransactionWithdrawals(size int, withdrawnETH float64) RecordL2CrossDomainSentMessages(size int) RecordL2CrossDomainRelayedMessages(size int) @@ -42,20 +46,19 @@ type L2Metricer interface { type Metricer interface { L1Metricer L2Metricer - - RecordInterval() (done func(err error)) } type bridgeMetrics struct { - intervalTick prometheus.Counter - intervalDuration prometheus.Histogram - intervalFailures prometheus.Counter + latestHeight *prometheus.GaugeVec - latestL1Height prometheus.Gauge - latestL2Height prometheus.Gauge + intervalTick *prometheus.CounterVec + intervalDuration *prometheus.HistogramVec + intervalFailures *prometheus.CounterVec txDeposits prometheus.Counter + txMintedETH prometheus.Counter txWithdrawals prometheus.Counter + txWithdrawnETH prometheus.Counter provenWithdrawals prometheus.Counter finalizedWithdrawals prometheus.Counter @@ -69,43 +72,56 @@ type bridgeMetrics struct { func NewMetrics(registry *prometheus.Registry) Metricer { factory := metrics.With(registry) return &bridgeMetrics{ - intervalTick: factory.NewCounter(prometheus.CounterOpts{ + intervalTick: factory.NewCounterVec(prometheus.CounterOpts{ Namespace: MetricsNamespace, Name: "intervals_total", Help: "number of times processing loop has run", + }, []string{ + "chain", }), - intervalDuration: factory.NewHistogram(prometheus.HistogramOpts{ + intervalDuration: factory.NewHistogramVec(prometheus.HistogramOpts{ Namespace: MetricsNamespace, Name: "interval_seconds", Help: "duration elapsed in the processing loop", + }, []string{ + "chain", }), - intervalFailures: factory.NewCounter(prometheus.CounterOpts{ + intervalFailures: factory.NewCounterVec(prometheus.CounterOpts{ Namespace: MetricsNamespace, - Name: "failures_total", + Name: "interval_failures_total", Help: "number of failures encountered", + }, []string{ + "chain", }), - latestL1Height: factory.NewGauge(prometheus.GaugeOpts{ + latestHeight: factory.NewGaugeVec(prometheus.GaugeOpts{ Namespace: MetricsNamespace, Subsystem: "l1", Name: "height", Help: "the latest processed l1 block height", - }), - latestL2Height: factory.NewGauge(prometheus.GaugeOpts{ - Namespace: MetricsNamespace, - Subsystem: "l2", - Name: "height", - Help: "the latest processed l2 block height", + }, []string{ + "chain", + "kind", }), txDeposits: factory.NewCounter(prometheus.CounterOpts{ Namespace: MetricsNamespace, Name: "tx_deposits", Help: "number of processed transactions deposited from l1", }), + txMintedETH: factory.NewCounter(prometheus.CounterOpts{ + Namespace: MetricsNamespace, + Name: "tx_minted_eth", + Help: "amount of eth bridged from l1", + }), txWithdrawals: factory.NewCounter(prometheus.CounterOpts{ Namespace: MetricsNamespace, Name: "tx_withdrawals", Help: "number of processed transactions withdrawn from l2", }), + txWithdrawnETH: factory.NewCounter(prometheus.CounterOpts{ + Namespace: MetricsNamespace, + Name: "tx_withdrawn_eth", + Help: "amount of eth withdrawn from l2", + }), provenWithdrawals: factory.NewCounter(prometheus.CounterOpts{ Namespace: MetricsNamespace, Name: "proven_withdrawals", @@ -149,25 +165,30 @@ func NewMetrics(registry *prometheus.Registry) Metricer { } } -func (m *bridgeMetrics) RecordInterval() func(error) { - m.intervalTick.Inc() - timer := prometheus.NewTimer(m.intervalDuration) +// L1Metricer + +func (m *bridgeMetrics) RecordL1Interval() func(error) { + m.intervalTick.WithLabelValues("l1").Inc() + timer := prometheus.NewTimer(m.intervalDuration.WithLabelValues("l1")) return func(err error) { timer.ObserveDuration() if err != nil { - m.intervalFailures.Inc() + m.intervalFailures.WithLabelValues("l1").Inc() } } } -// L1Metricer +func (m *bridgeMetrics) RecordL1LatestHeight(height *big.Int) { + m.latestHeight.WithLabelValues("l1", "initiated").Set(float64(height.Uint64())) +} -func (m *bridgeMetrics) RecordLatestIndexedL1Height(height *big.Int) { - m.latestL1Height.Set(float64(height.Uint64())) +func (m *bridgeMetrics) RecordL1LatestFinalizedHeight(height *big.Int) { + m.latestHeight.WithLabelValues("l1", "finalized").Set(float64(height.Uint64())) } -func (m *bridgeMetrics) RecordL1TransactionDeposits(size int) { +func (m *bridgeMetrics) RecordL1TransactionDeposits(size int, mintedETH float64) { m.txDeposits.Add(float64(size)) + m.txMintedETH.Add(mintedETH) } func (m *bridgeMetrics) RecordL1ProvenWithdrawals(size int) { @@ -196,12 +217,28 @@ func (m *bridgeMetrics) RecordL1FinalizedBridgeTransfers(tokenAddr common.Addres // L2Metricer -func (m *bridgeMetrics) RecordLatestIndexedL2Height(height *big.Int) { - m.latestL2Height.Set(float64(height.Uint64())) +func (m *bridgeMetrics) RecordL2Interval() func(error) { + m.intervalTick.WithLabelValues("l2").Inc() + timer := prometheus.NewTimer(m.intervalDuration.WithLabelValues("l2")) + return func(err error) { + timer.ObserveDuration() + if err != nil { + m.intervalFailures.WithLabelValues("l2").Inc() + } + } +} + +func (m *bridgeMetrics) RecordL2LatestHeight(height *big.Int) { + m.latestHeight.WithLabelValues("l2", "initiated").Set(float64(height.Uint64())) +} + +func (m *bridgeMetrics) RecordL2LatestFinalizedHeight(height *big.Int) { + m.latestHeight.WithLabelValues("l2", "finalized").Set(float64(height.Uint64())) } -func (m *bridgeMetrics) RecordL2TransactionWithdrawals(size int) { +func (m *bridgeMetrics) RecordL2TransactionWithdrawals(size int, withdrawnETH float64) { m.txWithdrawals.Add(float64(size)) + m.txWithdrawnETH.Add(withdrawnETH) } func (m *bridgeMetrics) RecordL2CrossDomainSentMessages(size int) { diff --git a/op-batcher/Dockerfile b/op-batcher/Dockerfile index bae7cb3473d77..6732ecc65678c 100644 --- a/op-batcher/Dockerfile +++ b/op-batcher/Dockerfile @@ -1,32 +1,9 @@ -FROM --platform=$BUILDPLATFORM golang:1.21.1-alpine3.18 as builder - -ARG VERSION=v0.0.0 - -RUN apk add --no-cache make gcc musl-dev linux-headers git jq bash - -COPY ./go.mod /app/go.mod -COPY ./go.sum /app/go.sum - -WORKDIR /app - -RUN go mod download - -# build op-batcher with the shared go.mod & go.sum files -COPY ./op-batcher /app/op-batcher -COPY ./op-bindings /app/op-bindings -COPY ./op-node /app/op-node -COPY ./op-service /app/op-service - -COPY ./.git /app/.git - -WORKDIR /app/op-batcher - -ARG TARGETOS TARGETARCH - -RUN make op-batcher VERSION="$VERSION" GOOS=$TARGETOS GOARCH=$TARGETARCH +ARG OP_STACK_GO_BUILDER=us-docker.pkg.dev/oplabs-tools-artifacts/images/op-stack-go:latest +FROM $OP_STACK_GO_BUILDER as builder +# See "make golang-docker" and /ops/docker/op-stack-go FROM alpine:3.18 -COPY --from=builder /app/op-batcher/bin/op-batcher /usr/local/bin +COPY --from=builder /usr/local/bin/op-batcher /usr/local/bin/op-batcher -ENTRYPOINT ["op-batcher"] +CMD ["op-batcher"] diff --git a/op-batcher/Dockerfile.dockerignore b/op-batcher/Dockerfile.dockerignore new file mode 100644 index 0000000000000..4f26140750a08 --- /dev/null +++ b/op-batcher/Dockerfile.dockerignore @@ -0,0 +1,2 @@ +# ignore everything but the dockerfile, the op-stack-go base image performs the build +* diff --git a/op-batcher/Makefile b/op-batcher/Makefile index 5b290580e3116..899eb16588d19 100644 --- a/op-batcher/Makefile +++ b/op-batcher/Makefile @@ -1,5 +1,5 @@ -GITCOMMIT := $(shell git rev-parse HEAD) -GITDATE := $(shell git show -s --format='%ct') +GITCOMMIT ?= $(shell git rev-parse HEAD) +GITDATE ?= $(shell git show -s --format='%ct') VERSION := v0.0.0 LDFLAGSSTRING +=-X main.GitCommit=$(GITCOMMIT) @@ -16,9 +16,6 @@ clean: test: go test -v ./... -lint: - golangci-lint run -E goimports,sqlclosecheck,bodyclose,asciicheck,misspell,errorlint --timeout 5m -e "errors.As" -e "errors.Is" ./... - fuzz: go test -run NOTAREALTEST -v -fuzztime 10s -fuzz FuzzChannelConfig_CheckTimeout ./batcher go test -run NOTAREALTEST -v -fuzztime 10s -fuzz FuzzDurationZero ./batcher @@ -33,5 +30,4 @@ fuzz: op-batcher \ clean \ test \ - lint \ fuzz diff --git a/op-batcher/batcher/batch_submitter.go b/op-batcher/batcher/batch_submitter.go index c2c4093972c16..8590d84b6a3d1 100644 --- a/op-batcher/batcher/batch_submitter.go +++ b/op-batcher/batcher/batch_submitter.go @@ -3,110 +3,32 @@ package batcher import ( "context" "fmt" - _ "net/http/pprof" "github.com/urfave/cli/v2" "github.com/ethereum-optimism/optimism/op-batcher/flags" - "github.com/ethereum-optimism/optimism/op-batcher/metrics" - "github.com/ethereum-optimism/optimism/op-batcher/rpc" opservice "github.com/ethereum-optimism/optimism/op-service" + "github.com/ethereum-optimism/optimism/op-service/cliapp" oplog "github.com/ethereum-optimism/optimism/op-service/log" - "github.com/ethereum-optimism/optimism/op-service/opio" - oppprof "github.com/ethereum-optimism/optimism/op-service/pprof" - oprpc "github.com/ethereum-optimism/optimism/op-service/rpc" ) -// Main is the entrypoint into the Batch Submitter. This method returns a -// closure that executes the service and blocks until the service exits. The use -// of a closure allows the parameters bound to the top-level main package, e.g. -// GitVersion, to be captured and used once the function is executed. -func Main(version string, cliCtx *cli.Context) error { - if err := flags.CheckRequired(cliCtx); err != nil { - return err - } - cfg := NewConfig(cliCtx) - if err := cfg.Check(); err != nil { - return fmt.Errorf("invalid CLI flags: %w", err) - } - - l := oplog.NewLogger(oplog.AppOut(cliCtx), cfg.LogConfig) - oplog.SetGlobalLogHandler(l.GetHandler()) - opservice.ValidateEnvVars(flags.EnvVarPrefix, flags.Flags, l) - procName := "default" - m := metrics.NewMetrics(procName) - l.Info("Initializing Batch Submitter") - - batchSubmitter, err := NewBatchSubmitterFromCLIConfig(cfg, l, m) - if err != nil { - l.Error("Unable to create Batch Submitter", "error", err) - return err - } - - if !cfg.Stopped { - if err := batchSubmitter.Start(); err != nil { - l.Error("Unable to start Batch Submitter", "error", err) - return err - } - } - - defer batchSubmitter.StopIfRunning(context.Background()) - - pprofConfig := cfg.PprofConfig - if pprofConfig.Enabled { - l.Debug("starting pprof", "addr", pprofConfig.ListenAddr, "port", pprofConfig.ListenPort) - pprofSrv, err := oppprof.StartServer(pprofConfig.ListenAddr, pprofConfig.ListenPort) - if err != nil { - l.Error("failed to start pprof server", "err", err) - return err +// Main is the entrypoint into the Batch Submitter. +// This method returns a cliapp.LifecycleAction, to create an op-service CLI-lifecycle-managed batch-submitter with. +func Main(version string) cliapp.LifecycleAction { + return func(cliCtx *cli.Context, closeApp context.CancelCauseFunc) (cliapp.Lifecycle, error) { + if err := flags.CheckRequired(cliCtx); err != nil { + return nil, err } - l.Info("started pprof server", "addr", pprofSrv.Addr()) - defer func() { - if err := pprofSrv.Stop(context.Background()); err != nil { - l.Error("failed to stop pprof server", "err", err) - } - }() - } - - metricsCfg := cfg.MetricsConfig - if metricsCfg.Enabled { - l.Debug("starting metrics server", "addr", metricsCfg.ListenAddr, "port", metricsCfg.ListenPort) - metricsSrv, err := m.Start(metricsCfg.ListenAddr, metricsCfg.ListenPort) - if err != nil { - return fmt.Errorf("failed to start metrics server: %w", err) + cfg := NewConfig(cliCtx) + if err := cfg.Check(); err != nil { + return nil, fmt.Errorf("invalid CLI flags: %w", err) } - l.Info("started metrics server", "addr", metricsSrv.Addr()) - defer func() { - if err := metricsSrv.Stop(context.Background()); err != nil { - l.Error("failed to stop pprof server", "err", err) - } - }() - ctx, cancel := context.WithCancel(context.Background()) - defer cancel() - m.StartBalanceMetrics(ctx, l, batchSubmitter.L1Client, batchSubmitter.TxManager.From()) - } - - server := oprpc.NewServer( - cfg.RPCFlag.ListenAddr, - cfg.RPCFlag.ListenPort, - version, - oprpc.WithLogger(l), - ) - if cfg.RPCFlag.EnableAdmin { - adminAPI := rpc.NewAdminAPI(batchSubmitter, &m.RPCMetrics, l) - server.AddAPI(rpc.GetAdminAPI(adminAPI)) - l.Info("Admin RPC enabled") - } - if err := server.Start(); err != nil { - return fmt.Errorf("error starting RPC server: %w", err) - } - m.RecordInfo(version) - m.RecordUp() + l := oplog.NewLogger(oplog.AppOut(cliCtx), cfg.LogConfig) + oplog.SetGlobalLogHandler(l.GetHandler()) + opservice.ValidateEnvVars(flags.EnvVarPrefix, flags.Flags, l) - opio.BlockOnInterrupts() - if err := server.Stop(); err != nil { - l.Error("Error shutting down http server: %w", err) + l.Info("Initializing Batch Submitter") + return BatcherServiceFromCLIConfig(cliCtx.Context, version, cfg, l) } - return nil } diff --git a/op-batcher/batcher/channel.go b/op-batcher/batcher/channel.go index d42679eb34d58..1d1eb2d5f568e 100644 --- a/op-batcher/batcher/channel.go +++ b/op-batcher/batcher/channel.go @@ -5,6 +5,7 @@ import ( "math" "github.com/ethereum-optimism/optimism/op-batcher/metrics" + "github.com/ethereum-optimism/optimism/op-node/rollup" "github.com/ethereum-optimism/optimism/op-node/rollup/derive" "github.com/ethereum-optimism/optimism/op-service/eth" "github.com/ethereum/go-ethereum/core/types" @@ -26,8 +27,8 @@ type channel struct { confirmedTransactions map[txID]eth.BlockID } -func newChannel(log log.Logger, metr metrics.Metricer, cfg ChannelConfig) (*channel, error) { - cb, err := newChannelBuilder(cfg) +func newChannel(log log.Logger, metr metrics.Metricer, cfg ChannelConfig, rcfg *rollup.Config) (*channel, error) { + cb, err := newChannelBuilder(cfg, rcfg) if err != nil { return nil, fmt.Errorf("creating new channel: %w", err) } diff --git a/op-batcher/batcher/channel_builder.go b/op-batcher/batcher/channel_builder.go index 551e5d96e6721..e336c90ad3d52 100644 --- a/op-batcher/batcher/channel_builder.go +++ b/op-batcher/batcher/channel_builder.go @@ -8,6 +8,7 @@ import ( "math" "github.com/ethereum-optimism/optimism/op-batcher/compressor" + "github.com/ethereum-optimism/optimism/op-node/rollup" "github.com/ethereum-optimism/optimism/op-node/rollup/derive" "github.com/ethereum/go-ethereum/core/types" ) @@ -58,6 +59,9 @@ type ChannelConfig struct { // CompressorConfig contains the configuration for creating new compressors. CompressorConfig compressor.Config + + // BatchType indicates whether the channel uses SingularBatch or SpanBatch. + BatchType uint } // Check validates the [ChannelConfig] parameters. @@ -83,6 +87,10 @@ func (cc *ChannelConfig) Check() error { return fmt.Errorf("max frame size %d is less than the minimum 23", cc.MaxFrameSize) } + if cc.BatchType > derive.SpanBatchType { + return fmt.Errorf("unrecognized batch type: %d", cc.BatchType) + } + return nil } @@ -114,7 +122,7 @@ type channelBuilder struct { // guaranteed to be a ChannelFullError wrapping the specific reason. fullErr error // current channel - co *derive.ChannelOut + co derive.ChannelOut // list of blocks in the channel. Saved in case the channel must be rebuilt blocks []*types.Block // frames data queue, to be send as txs @@ -127,12 +135,16 @@ type channelBuilder struct { // newChannelBuilder creates a new channel builder or returns an error if the // channel out could not be created. -func newChannelBuilder(cfg ChannelConfig) (*channelBuilder, error) { +func newChannelBuilder(cfg ChannelConfig, rcfg *rollup.Config) (*channelBuilder, error) { c, err := cfg.CompressorConfig.NewCompressor() if err != nil { return nil, err } - co, err := derive.NewChannelOut(c) + var spanBatchBuilder *derive.SpanBatchBuilder + if cfg.BatchType == derive.SpanBatchType { + spanBatchBuilder = derive.NewSpanBatchBuilder(rcfg.Genesis.L2Time, rcfg.L2ChainID) + } + co, err := derive.NewChannelOut(cfg.BatchType, c, spanBatchBuilder) if err != nil { return nil, err } @@ -194,12 +206,12 @@ func (c *channelBuilder) AddBlock(block *types.Block) (derive.L1BlockInfo, error return derive.L1BlockInfo{}, c.FullErr() } - batch, l1info, err := derive.BlockToBatch(block) + batch, l1info, err := derive.BlockToSingularBatch(block) if err != nil { return l1info, fmt.Errorf("converting block to batch: %w", err) } - if _, err = c.co.AddBatch(batch); errors.Is(err, derive.ErrTooManyRLPBytes) || errors.Is(err, derive.CompressorFullErr) { + if _, err = c.co.AddSingularBatch(batch, l1info.SequenceNumber); errors.Is(err, derive.ErrTooManyRLPBytes) || errors.Is(err, derive.CompressorFullErr) { c.setFullErr(err) return l1info, c.FullErr() } else if err != nil { @@ -252,7 +264,7 @@ func (c *channelBuilder) updateDurationTimeout(l1BlockNum uint64) { // derived from the batch's origin L1 block. The timeout is only moved forward // if the derived sequencer window timeout is earlier than the currently set // timeout. -func (c *channelBuilder) updateSwTimeout(batch *derive.BatchData) { +func (c *channelBuilder) updateSwTimeout(batch *derive.SingularBatch) { timeout := uint64(batch.EpochNum) + c.cfg.SeqWindowSize - c.cfg.SubSafetyMargin c.updateTimeout(timeout, ErrSeqWindowClose) } diff --git a/op-batcher/batcher/channel_builder_test.go b/op-batcher/batcher/channel_builder_test.go index 45ee5cef0bf0a..5ee5c5367134a 100644 --- a/op-batcher/batcher/channel_builder_test.go +++ b/op-batcher/batcher/channel_builder_test.go @@ -32,6 +32,12 @@ var defaultTestChannelConfig = ChannelConfig{ TargetNumFrames: 1, ApproxComprRatio: 0.4, }, + BatchType: derive.SingularBatchType, +} + +var defaultTestRollupConfig = rollup.Config{ + Genesis: rollup.Genesis{L2: eth.BlockID{Number: 0}}, + L2ChainID: big.NewInt(1234), } // TestChannelConfig_Check tests the [ChannelConfig] [Check] function. @@ -158,8 +164,9 @@ func newMiniL2BlockWithNumberParent(numTx int, number *big.Int, parent common.Ha // addTooManyBlocks adds blocks to the channel until it hits an error, // which is presumably ErrTooManyRLPBytes. func addTooManyBlocks(cb *channelBuilder) error { + rng := rand.New(rand.NewSource(1234)) for i := 0; i < 10_000; i++ { - block := newMiniL2Block(100) + block := dtest.RandomL2BlockWithChainId(rng, 1000, defaultTestRollupConfig.L2ChainID) _, err := cb.AddBlock(block) if err != nil { return err @@ -178,7 +185,7 @@ func FuzzDurationTimeoutZeroMaxChannelDuration(f *testing.F) { f.Fuzz(func(t *testing.T, l1BlockNum uint64) { channelConfig := defaultTestChannelConfig channelConfig.MaxChannelDuration = 0 - cb, err := newChannelBuilder(channelConfig) + cb, err := newChannelBuilder(channelConfig, nil) require.NoError(t, err) cb.timeout = 0 cb.updateDurationTimeout(l1BlockNum) @@ -201,7 +208,7 @@ func FuzzChannelBuilder_DurationZero(f *testing.F) { // Create the channel builder channelConfig := defaultTestChannelConfig channelConfig.MaxChannelDuration = maxChannelDuration - cb, err := newChannelBuilder(channelConfig) + cb, err := newChannelBuilder(channelConfig, nil) require.NoError(t, err) // Whenever the timeout is set to 0, the channel builder should have a duration timeout @@ -228,7 +235,7 @@ func FuzzDurationTimeoutMaxChannelDuration(f *testing.F) { // Create the channel builder channelConfig := defaultTestChannelConfig channelConfig.MaxChannelDuration = maxChannelDuration - cb, err := newChannelBuilder(channelConfig) + cb, err := newChannelBuilder(channelConfig, nil) require.NoError(t, err) // Whenever the timeout is greater than the l1BlockNum, @@ -262,7 +269,7 @@ func FuzzChannelCloseTimeout(f *testing.F) { channelConfig := defaultTestChannelConfig channelConfig.ChannelTimeout = channelTimeout channelConfig.SubSafetyMargin = subSafetyMargin - cb, err := newChannelBuilder(channelConfig) + cb, err := newChannelBuilder(channelConfig, nil) require.NoError(t, err) // Check the timeout @@ -290,7 +297,7 @@ func FuzzChannelZeroCloseTimeout(f *testing.F) { channelConfig := defaultTestChannelConfig channelConfig.ChannelTimeout = channelTimeout channelConfig.SubSafetyMargin = subSafetyMargin - cb, err := newChannelBuilder(channelConfig) + cb, err := newChannelBuilder(channelConfig, nil) require.NoError(t, err) // Check the timeout @@ -317,16 +324,12 @@ func FuzzSeqWindowClose(f *testing.F) { channelConfig := defaultTestChannelConfig channelConfig.SeqWindowSize = seqWindowSize channelConfig.SubSafetyMargin = subSafetyMargin - cb, err := newChannelBuilder(channelConfig) + cb, err := newChannelBuilder(channelConfig, nil) require.NoError(t, err) // Check the timeout cb.timeout = timeout - cb.updateSwTimeout(derive.NewSingularBatchData( - derive.SingularBatch{ - EpochNum: rollup.Epoch(epochNum), - }, - )) + cb.updateSwTimeout(&derive.SingularBatch{EpochNum: rollup.Epoch(epochNum)}) calculatedTimeout := epochNum + seqWindowSize - subSafetyMargin if timeout > calculatedTimeout && calculatedTimeout != 0 { cb.checkTimeout(calculatedTimeout) @@ -349,16 +352,12 @@ func FuzzSeqWindowZeroTimeoutClose(f *testing.F) { channelConfig := defaultTestChannelConfig channelConfig.SeqWindowSize = seqWindowSize channelConfig.SubSafetyMargin = subSafetyMargin - cb, err := newChannelBuilder(channelConfig) + cb, err := newChannelBuilder(channelConfig, nil) require.NoError(t, err) // Check the timeout cb.timeout = 0 - cb.updateSwTimeout(derive.NewSingularBatchData( - derive.SingularBatch{ - EpochNum: rollup.Epoch(epochNum), - }, - )) + cb.updateSwTimeout(&derive.SingularBatch{EpochNum: rollup.Epoch(epochNum)}) calculatedTimeout := epochNum + seqWindowSize - subSafetyMargin cb.checkTimeout(calculatedTimeout) if cb.timeout != 0 { @@ -367,12 +366,40 @@ func FuzzSeqWindowZeroTimeoutClose(f *testing.F) { }) } +func TestChannelBuilderBatchType(t *testing.T) { + tests := []struct { + name string + f func(t *testing.T, batchType uint) + }{ + {"ChannelBuilder_MaxRLPBytesPerChannel", ChannelBuilder_MaxRLPBytesPerChannel}, + {"ChannelBuilder_OutputFramesMaxFrameIndex", ChannelBuilder_OutputFramesMaxFrameIndex}, + {"ChannelBuilder_AddBlock", ChannelBuilder_AddBlock}, + {"ChannelBuilder_Reset", ChannelBuilder_Reset}, + {"ChannelBuilder_PendingFrames_TotalFrames", ChannelBuilder_PendingFrames_TotalFrames}, + {"ChannelBuilder_InputBytes", ChannelBuilder_InputBytes}, + {"ChannelBuilder_OutputBytes", ChannelBuilder_OutputBytes}, + } + for _, test := range tests { + test := test + t.Run(test.name+"_SingularBatch", func(t *testing.T) { + test.f(t, derive.SingularBatchType) + }) + } + + for _, test := range tests { + test := test + t.Run(test.name+"_SpanBatch", func(t *testing.T) { + test.f(t, derive.SpanBatchType) + }) + } +} + // TestChannelBuilder_NextFrame tests calling NextFrame on a ChannelBuilder with only one frame func TestChannelBuilder_NextFrame(t *testing.T) { channelConfig := defaultTestChannelConfig // Create a new channel builder - cb, err := newChannelBuilder(channelConfig) + cb, err := newChannelBuilder(channelConfig, nil) require.NoError(t, err) // Mock the internals of `channelBuilder.outputFrame` @@ -412,14 +439,14 @@ func TestChannelBuilder_OutputWrongFramePanic(t *testing.T) { channelConfig := defaultTestChannelConfig // Construct a channel builder - cb, err := newChannelBuilder(channelConfig) + cb, err := newChannelBuilder(channelConfig, nil) require.NoError(t, err) // Mock the internals of `channelBuilder.outputFrame` // to construct a single frame c, err := channelConfig.CompressorConfig.NewCompressor() require.NoError(t, err) - co, err := derive.NewChannelOut(c) + co, err := derive.NewChannelOut(derive.SingularBatchType, c, nil) require.NoError(t, err) var buf bytes.Buffer fn, err := co.OutputFrame(&buf, channelConfig.MaxFrameSize) @@ -445,7 +472,7 @@ func TestChannelBuilder_OutputFramesWorks(t *testing.T) { channelConfig.MaxFrameSize = 24 // Construct the channel builder - cb, err := newChannelBuilder(channelConfig) + cb, err := newChannelBuilder(channelConfig, nil) require.NoError(t, err) require.False(t, cb.IsFull()) require.Equal(t, 0, cb.PendingFrames()) @@ -480,17 +507,68 @@ func TestChannelBuilder_OutputFramesWorks(t *testing.T) { } } -// TestChannelBuilder_MaxRLPBytesPerChannel tests the [channelBuilder.OutputFrames] +// TestChannelBuilder_OutputFramesWorks tests the [ChannelBuilder] OutputFrames is successful. +func TestChannelBuilder_OutputFramesWorks_SpanBatch(t *testing.T) { + channelConfig := defaultTestChannelConfig + channelConfig.MaxFrameSize = 24 + channelConfig.CompressorConfig.TargetFrameSize = 50 + channelConfig.BatchType = derive.SpanBatchType + + // Construct the channel builder + cb, err := newChannelBuilder(channelConfig, &defaultTestRollupConfig) + require.NoError(t, err) + require.False(t, cb.IsFull()) + require.Equal(t, 0, cb.PendingFrames()) + + // Calling OutputFrames without having called [AddBlock] + // should return no error + require.NoError(t, cb.OutputFrames()) + + // There should be no ready bytes yet + require.Equal(t, 0, cb.co.ReadyBytes()) + + // fill up + for { + err = addMiniBlock(cb) + if err == nil { + require.False(t, cb.IsFull()) + // There should be no ready bytes until the channel is full + require.Equal(t, cb.co.ReadyBytes(), 0) + } else { + require.ErrorIs(t, err, derive.CompressorFullErr) + break + } + } + + require.True(t, cb.IsFull()) + // Check how many ready bytes + // There should be more than the max frame size ready + require.Greater(t, uint64(cb.co.ReadyBytes()), channelConfig.MaxFrameSize) + require.Equal(t, 0, cb.PendingFrames()) + + // We should be able to output the frames + require.NoError(t, cb.OutputFrames()) + + // There should be many frames in the channel builder now + require.Greater(t, cb.PendingFrames(), 1) + for i := 0; i < cb.numFrames-1; i++ { + require.Len(t, cb.frames[i].data, int(channelConfig.MaxFrameSize)) + } + require.LessOrEqual(t, len(cb.frames[len(cb.frames)-1].data), int(channelConfig.MaxFrameSize)) +} + +// ChannelBuilder_MaxRLPBytesPerChannel tests the [channelBuilder.OutputFrames] // function errors when the max RLP bytes per channel is reached. -func TestChannelBuilder_MaxRLPBytesPerChannel(t *testing.T) { +func ChannelBuilder_MaxRLPBytesPerChannel(t *testing.T, batchType uint) { t.Parallel() channelConfig := defaultTestChannelConfig channelConfig.MaxFrameSize = derive.MaxRLPBytesPerChannel * 2 channelConfig.CompressorConfig.TargetFrameSize = derive.MaxRLPBytesPerChannel * 2 channelConfig.CompressorConfig.ApproxComprRatio = 1 + channelConfig.BatchType = batchType // Construct the channel builder - cb, err := newChannelBuilder(channelConfig) + cb, err := newChannelBuilder(channelConfig, &defaultTestRollupConfig) require.NoError(t, err) // Add a block that overflows the [ChannelOut] @@ -498,61 +576,55 @@ func TestChannelBuilder_MaxRLPBytesPerChannel(t *testing.T) { require.ErrorIs(t, err, derive.ErrTooManyRLPBytes) } -// TestChannelBuilder_OutputFramesMaxFrameIndex tests the [ChannelBuilder.OutputFrames] +// ChannelBuilder_OutputFramesMaxFrameIndex tests the [ChannelBuilder.OutputFrames] // function errors when the max frame index is reached. -func TestChannelBuilder_OutputFramesMaxFrameIndex(t *testing.T) { +func ChannelBuilder_OutputFramesMaxFrameIndex(t *testing.T, batchType uint) { channelConfig := defaultTestChannelConfig channelConfig.MaxFrameSize = 24 - channelConfig.CompressorConfig.TargetNumFrames = math.MaxInt + channelConfig.CompressorConfig.TargetNumFrames = 6000 channelConfig.CompressorConfig.TargetFrameSize = 24 - channelConfig.CompressorConfig.ApproxComprRatio = 0 + channelConfig.CompressorConfig.ApproxComprRatio = 1 + channelConfig.BatchType = batchType + + rng := rand.New(rand.NewSource(123)) // Continuously add blocks until the max frame index is reached // This should cause the [channelBuilder.OutputFrames] function // to error - cb, err := newChannelBuilder(channelConfig) + cb, err := newChannelBuilder(channelConfig, &defaultTestRollupConfig) require.NoError(t, err) require.False(t, cb.IsFull()) require.Equal(t, 0, cb.PendingFrames()) for { - lBlock := types.NewBlock(&types.Header{ - BaseFee: common.Big0, - Difficulty: common.Big0, - Number: common.Big0, - }, nil, nil, nil, trie.NewStackTrie(nil)) - l1InfoTx, _ := derive.L1InfoDeposit(0, eth.BlockToInfo(lBlock), eth.SystemConfig{}, false) - txs := []*types.Transaction{types.NewTx(l1InfoTx)} - a := types.NewBlock(&types.Header{ - Number: big.NewInt(0), - }, txs, nil, nil, trie.NewStackTrie(nil)) + a := dtest.RandomL2BlockWithChainId(rng, 1, defaultTestRollupConfig.L2ChainID) _, err = cb.AddBlock(a) - require.NoError(t, cb.co.Flush()) if cb.IsFull() { fullErr := cb.FullErr() - require.ErrorIs(t, fullErr, ErrMaxFrameIndex) + require.ErrorIs(t, fullErr, derive.CompressorFullErr) break } require.NoError(t, err) - _ = cb.OutputFrames() - // Flushing so we can construct new frames - _ = cb.co.Flush() } + + _ = cb.OutputFrames() + require.ErrorIs(t, cb.FullErr(), ErrMaxFrameIndex) } -// TestChannelBuilder_AddBlock tests the AddBlock function -func TestChannelBuilder_AddBlock(t *testing.T) { +// ChannelBuilder_AddBlock tests the AddBlock function +func ChannelBuilder_AddBlock(t *testing.T, batchType uint) { channelConfig := defaultTestChannelConfig + channelConfig.BatchType = batchType // Lower the max frame size so that we can batch - channelConfig.MaxFrameSize = 30 + channelConfig.MaxFrameSize = 20 // Configure the Input Threshold params so we observe a full channel - channelConfig.CompressorConfig.TargetFrameSize = 30 + channelConfig.CompressorConfig.TargetFrameSize = 20 channelConfig.CompressorConfig.TargetNumFrames = 2 channelConfig.CompressorConfig.ApproxComprRatio = 1 // Construct the channel builder - cb, err := newChannelBuilder(channelConfig) + cb, err := newChannelBuilder(channelConfig, &defaultTestRollupConfig) require.NoError(t, err) // Add a nonsense block to the channel builder @@ -560,7 +632,11 @@ func TestChannelBuilder_AddBlock(t *testing.T) { require.NoError(t, cb.co.Flush()) // Check the fields reset in the AddBlock function - require.Equal(t, 74, cb.co.InputBytes()) + expectedInputBytes := 74 + if batchType == derive.SpanBatchType { + expectedInputBytes = 47 + } + require.Equal(t, expectedInputBytes, cb.co.InputBytes()) require.Equal(t, 1, len(cb.blocks)) require.Equal(t, 0, len(cb.frames)) require.True(t, cb.IsFull()) @@ -570,14 +646,18 @@ func TestChannelBuilder_AddBlock(t *testing.T) { require.ErrorIs(t, addMiniBlock(cb), derive.CompressorFullErr) } -// TestChannelBuilder_Reset tests the [Reset] function -func TestChannelBuilder_Reset(t *testing.T) { +// ChannelBuilder_Reset tests the [Reset] function +func ChannelBuilder_Reset(t *testing.T, batchType uint) { channelConfig := defaultTestChannelConfig + channelConfig.BatchType = batchType // Lower the max frame size so that we can batch channelConfig.MaxFrameSize = 24 + channelConfig.CompressorConfig.TargetNumFrames = 1 + channelConfig.CompressorConfig.TargetFrameSize = 24 + channelConfig.CompressorConfig.ApproxComprRatio = 1 - cb, err := newChannelBuilder(channelConfig) + cb, err := newChannelBuilder(channelConfig, &defaultTestRollupConfig) require.NoError(t, err) // Add a nonsense block to the channel builder @@ -590,20 +670,16 @@ func TestChannelBuilder_Reset(t *testing.T) { // Timeout should be updated in the AddBlock internal call to `updateSwTimeout` timeout := uint64(100) + cb.cfg.SeqWindowSize - cb.cfg.SubSafetyMargin require.Equal(t, timeout, cb.timeout) - require.NoError(t, cb.fullErr) + require.Error(t, cb.fullErr) // Output frames so we can set the channel builder frames require.NoError(t, cb.OutputFrames()) - // Add another block to increment the block count - require.NoError(t, addMiniBlock(cb)) - require.NoError(t, cb.co.Flush()) - // Check the fields reset in the Reset function - require.Equal(t, 2, len(cb.blocks)) - require.Greater(t, len(cb.frames), 1) + require.Equal(t, 1, len(cb.blocks)) require.Equal(t, timeout, cb.timeout) - require.NoError(t, cb.fullErr) + require.Error(t, cb.fullErr) + require.Greater(t, len(cb.frames), 1) // Reset the channel builder require.NoError(t, cb.Reset()) @@ -622,7 +698,7 @@ func TestBuilderRegisterL1Block(t *testing.T) { channelConfig := defaultTestChannelConfig // Construct the channel builder - cb, err := newChannelBuilder(channelConfig) + cb, err := newChannelBuilder(channelConfig, nil) require.NoError(t, err) // Assert params modified in RegisterL1Block @@ -645,7 +721,7 @@ func TestBuilderRegisterL1BlockZeroMaxChannelDuration(t *testing.T) { channelConfig.MaxChannelDuration = 0 // Construct the channel builder - cb, err := newChannelBuilder(channelConfig) + cb, err := newChannelBuilder(channelConfig, nil) require.NoError(t, err) // Assert params modified in RegisterL1Block @@ -666,7 +742,7 @@ func TestFramePublished(t *testing.T) { channelConfig := defaultTestChannelConfig // Construct the channel builder - cb, err := newChannelBuilder(channelConfig) + cb, err := newChannelBuilder(channelConfig, nil) require.NoError(t, err) // Let's say the block number is fed in as 100 @@ -682,8 +758,8 @@ func TestFramePublished(t *testing.T) { require.Equal(t, uint64(1000), cb.timeout) } -func TestChannelBuilder_PendingFrames_TotalFrames(t *testing.T) { - const tnf = 8 +func ChannelBuilder_PendingFrames_TotalFrames(t *testing.T, batchType uint) { + const tnf = 9 rng := rand.New(rand.NewSource(94572314)) require := require.New(t) cfg := defaultTestChannelConfig @@ -691,7 +767,8 @@ func TestChannelBuilder_PendingFrames_TotalFrames(t *testing.T) { cfg.MaxFrameSize = 1000 cfg.CompressorConfig.TargetNumFrames = tnf cfg.CompressorConfig.Kind = "shadow" - cb, err := newChannelBuilder(cfg) + cfg.BatchType = batchType + cb, err := newChannelBuilder(cfg, &defaultTestRollupConfig) require.NoError(err) // initial builder should be empty @@ -700,7 +777,7 @@ func TestChannelBuilder_PendingFrames_TotalFrames(t *testing.T) { // fill up for { - block, _ := dtest.RandomL2Block(rng, 4) + block := dtest.RandomL2BlockWithChainId(rng, 4, defaultTestRollupConfig.L2ChainID) _, err := cb.AddBlock(block) if cb.IsFull() { break @@ -725,25 +802,44 @@ func TestChannelBuilder_PendingFrames_TotalFrames(t *testing.T) { } } -func TestChannelBuilder_InputBytes(t *testing.T) { +func ChannelBuilder_InputBytes(t *testing.T, batchType uint) { require := require.New(t) rng := rand.New(rand.NewSource(4982432)) - cb, _ := defaultChannelBuilderSetup(t) + cfg := defaultTestChannelConfig + cfg.BatchType = batchType + var spanBatchBuilder *derive.SpanBatchBuilder + if batchType == derive.SpanBatchType { + chainId := big.NewInt(1234) + spanBatchBuilder = derive.NewSpanBatchBuilder(uint64(0), chainId) + } + cb, err := newChannelBuilder(cfg, &defaultTestRollupConfig) + require.NoError(err) require.Zero(cb.InputBytes()) var l int for i := 0; i < 5; i++ { - block := newMiniL2Block(rng.Intn(32)) - l += blockBatchRlpSize(t, block) - + block := dtest.RandomL2BlockWithChainId(rng, rng.Intn(32), defaultTestRollupConfig.L2ChainID) + if batchType == derive.SingularBatchType { + l += blockBatchRlpSize(t, block) + } else { + singularBatch, l1Info, err := derive.BlockToSingularBatch(block) + require.NoError(err) + spanBatchBuilder.AppendSingularBatch(singularBatch, l1Info.SequenceNumber) + rawSpanBatch, err := spanBatchBuilder.GetRawSpanBatch() + require.NoError(err) + batch := derive.NewBatchData(rawSpanBatch) + var buf bytes.Buffer + require.NoError(batch.EncodeRLP(&buf)) + l = buf.Len() + } _, err := cb.AddBlock(block) require.NoError(err) require.Equal(cb.InputBytes(), l) } } -func TestChannelBuilder_OutputBytes(t *testing.T) { +func ChannelBuilder_OutputBytes(t *testing.T, batchType uint) { require := require.New(t) rng := rand.New(rand.NewSource(9860372)) cfg := defaultTestChannelConfig @@ -751,13 +847,14 @@ func TestChannelBuilder_OutputBytes(t *testing.T) { cfg.MaxFrameSize = 1000 cfg.CompressorConfig.TargetNumFrames = 16 cfg.CompressorConfig.ApproxComprRatio = 1.0 - cb, err := newChannelBuilder(cfg) + cfg.BatchType = batchType + cb, err := newChannelBuilder(cfg, &defaultTestRollupConfig) require.NoError(err, "newChannelBuilder") require.Zero(cb.OutputBytes()) for { - block, _ := dtest.RandomL2Block(rng, rng.Intn(32)) + block := dtest.RandomL2BlockWithChainId(rng, rng.Intn(32), defaultTestRollupConfig.L2ChainID) _, err := cb.AddBlock(block) if errors.Is(err, derive.CompressorFullErr) { break @@ -778,17 +875,10 @@ func TestChannelBuilder_OutputBytes(t *testing.T) { require.Equal(cb.OutputBytes(), flen) } -func defaultChannelBuilderSetup(t *testing.T) (*channelBuilder, ChannelConfig) { - t.Helper() - cfg := defaultTestChannelConfig - cb, err := newChannelBuilder(cfg) - require.NoError(t, err, "newChannelBuilder") - return cb, cfg -} - func blockBatchRlpSize(t *testing.T, b *types.Block) int { t.Helper() - batch, _, err := derive.BlockToBatch(b) + singularBatch, _, err := derive.BlockToSingularBatch(b) + batch := derive.NewBatchData(singularBatch) require.NoError(t, err) var buf bytes.Buffer require.NoError(t, batch.EncodeRLP(&buf), "RLP-encoding batch") diff --git a/op-batcher/batcher/channel_manager.go b/op-batcher/batcher/channel_manager.go index 052b9dbe1e3c9..8100a3a2826ef 100644 --- a/op-batcher/batcher/channel_manager.go +++ b/op-batcher/batcher/channel_manager.go @@ -7,6 +7,7 @@ import ( "sync" "github.com/ethereum-optimism/optimism/op-batcher/metrics" + "github.com/ethereum-optimism/optimism/op-node/rollup" "github.com/ethereum-optimism/optimism/op-node/rollup/derive" "github.com/ethereum-optimism/optimism/op-service/eth" "github.com/ethereum/go-ethereum/common" @@ -28,6 +29,7 @@ type channelManager struct { log log.Logger metr metrics.Metricer cfg ChannelConfig + rcfg *rollup.Config // All blocks since the last request for new tx data. blocks []*types.Block @@ -45,17 +47,18 @@ type channelManager struct { closed bool } -func NewChannelManager(log log.Logger, metr metrics.Metricer, cfg ChannelConfig) *channelManager { +func NewChannelManager(log log.Logger, metr metrics.Metricer, cfg ChannelConfig, rcfg *rollup.Config) *channelManager { return &channelManager{ log: log, metr: metr, cfg: cfg, + rcfg: rcfg, txChannels: make(map[txID]*channel), } } // Clear clears the entire state of the channel manager. -// It is intended to be used after an L2 reorg. +// It is intended to be used before launching op-batcher and after an L2 reorg. func (s *channelManager) Clear() { s.mu.Lock() defer s.mu.Unlock() @@ -195,7 +198,7 @@ func (s *channelManager) ensureChannelWithSpace(l1Head eth.BlockID) error { return nil } - pc, err := newChannel(s.log, s.metr, s.cfg) + pc, err := newChannel(s.log, s.metr, s.cfg, s.rcfg) if err != nil { return fmt.Errorf("creating new channel: %w", err) } diff --git a/op-batcher/batcher/channel_manager_test.go b/op-batcher/batcher/channel_manager_test.go index 4621dde1bdb98..852961c75b9ac 100644 --- a/op-batcher/batcher/channel_manager_test.go +++ b/op-batcher/batcher/channel_manager_test.go @@ -9,6 +9,7 @@ import ( "github.com/ethereum-optimism/optimism/op-batcher/compressor" "github.com/ethereum-optimism/optimism/op-batcher/metrics" + "github.com/ethereum-optimism/optimism/op-node/rollup" "github.com/ethereum-optimism/optimism/op-node/rollup/derive" derivetest "github.com/ethereum-optimism/optimism/op-node/rollup/derive/test" "github.com/ethereum-optimism/optimism/op-service/eth" @@ -19,11 +20,41 @@ import ( "github.com/stretchr/testify/require" ) -// TestChannelManagerReturnsErrReorg ensures that the channel manager +func TestChannelManagerBatchType(t *testing.T) { + tests := []struct { + name string + f func(t *testing.T, batchType uint) + }{ + {"ChannelManagerReturnsErrReorg", ChannelManagerReturnsErrReorg}, + {"ChannelManagerReturnsErrReorgWhenDrained", ChannelManagerReturnsErrReorgWhenDrained}, + {"ChannelManager_Clear", ChannelManager_Clear}, + {"ChannelManager_TxResend", ChannelManager_TxResend}, + {"ChannelManagerCloseBeforeFirstUse", ChannelManagerCloseBeforeFirstUse}, + {"ChannelManagerCloseNoPendingChannel", ChannelManagerCloseNoPendingChannel}, + {"ChannelManagerClosePendingChannel", ChannelManagerClosePendingChannel}, + {"ChannelManagerCloseAllTxsFailed", ChannelManagerCloseAllTxsFailed}, + } + for _, test := range tests { + test := test + t.Run(test.name+"_SingularBatch", func(t *testing.T) { + test.f(t, derive.SingularBatchType) + }) + } + + for _, test := range tests { + test := test + t.Run(test.name+"_SpanBatch", func(t *testing.T) { + test.f(t, derive.SpanBatchType) + }) + } +} + +// ChannelManagerReturnsErrReorg ensures that the channel manager // detects a reorg when it has cached L1 blocks. -func TestChannelManagerReturnsErrReorg(t *testing.T) { +func ChannelManagerReturnsErrReorg(t *testing.T, batchType uint) { log := testlog.Logger(t, log.LvlCrit) - m := NewChannelManager(log, metrics.NoopMetrics, ChannelConfig{}) + m := NewChannelManager(log, metrics.NoopMetrics, ChannelConfig{BatchType: batchType}, &rollup.Config{}) + m.Clear() a := types.NewBlock(&types.Header{ Number: big.NewInt(0), @@ -49,9 +80,9 @@ func TestChannelManagerReturnsErrReorg(t *testing.T) { require.Equal(t, []*types.Block{a, b, c}, m.blocks) } -// TestChannelManagerReturnsErrReorgWhenDrained ensures that the channel manager +// ChannelManagerReturnsErrReorgWhenDrained ensures that the channel manager // detects a reorg even if it does not have any blocks inside it. -func TestChannelManagerReturnsErrReorgWhenDrained(t *testing.T) { +func ChannelManagerReturnsErrReorgWhenDrained(t *testing.T, batchType uint) { log := testlog.Logger(t, log.LvlCrit) m := NewChannelManager(log, metrics.NoopMetrics, ChannelConfig{ @@ -61,7 +92,11 @@ func TestChannelManagerReturnsErrReorgWhenDrained(t *testing.T) { TargetNumFrames: 1, ApproxComprRatio: 1.0, }, - }) + BatchType: batchType, + }, + &rollup.Config{}, + ) + m.Clear() a := newMiniL2Block(0) x := newMiniL2BlockWithNumberParent(0, big.NewInt(1), common.Hash{0xff}) @@ -76,8 +111,8 @@ func TestChannelManagerReturnsErrReorgWhenDrained(t *testing.T) { require.ErrorIs(t, m.AddL2Block(x), ErrReorg) } -// TestChannelManager_Clear tests clearing the channel manager. -func TestChannelManager_Clear(t *testing.T) { +// ChannelManager_Clear tests clearing the channel manager. +func ChannelManager_Clear(t *testing.T, batchType uint) { require := require.New(t) // Create a channel manager @@ -96,7 +131,10 @@ func TestChannelManager_Clear(t *testing.T) { TargetNumFrames: 1, ApproxComprRatio: 1.0, }, - }) + BatchType: batchType, + }, + &defaultTestRollupConfig, + ) // Channel Manager state should be empty by default require.Empty(m.blocks) @@ -104,9 +142,11 @@ func TestChannelManager_Clear(t *testing.T) { require.Nil(m.currentChannel) require.Empty(m.channelQueue) require.Empty(m.txChannels) + // Set the last block + m.Clear() // Add a block to the channel manager - a, _ := derivetest.RandomL2Block(rng, 4) + a := derivetest.RandomL2BlockWithChainId(rng, 4, defaultTestRollupConfig.L2ChainID) newL1Tip := a.Hash() l1BlockID := eth.BlockID{ Hash: a.Hash(), @@ -153,7 +193,7 @@ func TestChannelManager_Clear(t *testing.T) { require.Empty(m.txChannels) } -func TestChannelManager_TxResend(t *testing.T) { +func ChannelManager_TxResend(t *testing.T, batchType uint) { require := require.New(t) rng := rand.New(rand.NewSource(time.Now().UnixNano())) log := testlog.Logger(t, log.LvlError) @@ -165,9 +205,13 @@ func TestChannelManager_TxResend(t *testing.T) { TargetNumFrames: 1, ApproxComprRatio: 1.0, }, - }) + BatchType: batchType, + }, + &defaultTestRollupConfig, + ) + m.Clear() - a, _ := derivetest.RandomL2Block(rng, 4) + a := derivetest.RandomL2BlockWithChainId(rng, 4, defaultTestRollupConfig.L2ChainID) require.NoError(m.AddL2Block(a)) @@ -195,9 +239,9 @@ func TestChannelManager_TxResend(t *testing.T) { require.Len(fs, 1) } -// TestChannelManagerCloseBeforeFirstUse ensures that the channel manager +// ChannelManagerCloseBeforeFirstUse ensures that the channel manager // will not produce any frames if closed immediately. -func TestChannelManagerCloseBeforeFirstUse(t *testing.T) { +func ChannelManagerCloseBeforeFirstUse(t *testing.T, batchType uint) { require := require.New(t) rng := rand.New(rand.NewSource(time.Now().UnixNano())) log := testlog.Logger(t, log.LvlCrit) @@ -209,9 +253,13 @@ func TestChannelManagerCloseBeforeFirstUse(t *testing.T) { TargetFrameSize: 0, ApproxComprRatio: 1.0, }, - }) + BatchType: batchType, + }, + &defaultTestRollupConfig, + ) + m.Clear() - a, _ := derivetest.RandomL2Block(rng, 4) + a := derivetest.RandomL2BlockWithChainId(rng, 4, defaultTestRollupConfig.L2ChainID) m.Close() @@ -222,10 +270,10 @@ func TestChannelManagerCloseBeforeFirstUse(t *testing.T) { require.ErrorIs(err, io.EOF, "Expected closed channel manager to contain no tx data") } -// TestChannelManagerCloseNoPendingChannel ensures that the channel manager +// ChannelManagerCloseNoPendingChannel ensures that the channel manager // can gracefully close with no pending channels, and will not emit any new // channel frames. -func TestChannelManagerCloseNoPendingChannel(t *testing.T) { +func ChannelManagerCloseNoPendingChannel(t *testing.T, batchType uint) { require := require.New(t) log := testlog.Logger(t, log.LvlCrit) m := NewChannelManager(log, metrics.NoopMetrics, @@ -237,7 +285,11 @@ func TestChannelManagerCloseNoPendingChannel(t *testing.T) { TargetNumFrames: 1, ApproxComprRatio: 1.0, }, - }) + BatchType: batchType, + }, + &defaultTestRollupConfig, + ) + m.Clear() a := newMiniL2Block(0) b := newMiniL2BlockWithNumberParent(0, big.NewInt(1), a.Hash()) @@ -261,25 +313,37 @@ func TestChannelManagerCloseNoPendingChannel(t *testing.T) { require.ErrorIs(err, io.EOF, "Expected closed channel manager to return no new tx data") } -// TestChannelManagerCloseNoPendingChannel ensures that the channel manager +// ChannelManagerCloseNoPendingChannel ensures that the channel manager // can gracefully close with a pending channel, and will not produce any // new channel frames after this point. -func TestChannelManagerClosePendingChannel(t *testing.T) { +func ChannelManagerClosePendingChannel(t *testing.T, batchType uint) { require := require.New(t) + // The number of batch txs depends on compression of the random data, hence the static test RNG seed. + // Example of different RNG seed that creates less than 2 frames: 1698700588902821588 + rng := rand.New(rand.NewSource(123)) log := testlog.Logger(t, log.LvlCrit) m := NewChannelManager(log, metrics.NoopMetrics, ChannelConfig{ - MaxFrameSize: 1000, + MaxFrameSize: 10000, ChannelTimeout: 1000, CompressorConfig: compressor.Config{ - TargetNumFrames: 100, - TargetFrameSize: 1000, + TargetNumFrames: 1, + TargetFrameSize: 10000, ApproxComprRatio: 1.0, }, - }) + BatchType: batchType, + }, + &defaultTestRollupConfig, + ) + m.Clear() - a := newMiniL2Block(50_000) - b := newMiniL2BlockWithNumberParent(10, big.NewInt(1), a.Hash()) + numTx := 20 // Adjust number of txs to make 2 frames + a := derivetest.RandomL2BlockWithChainId(rng, numTx, defaultTestRollupConfig.L2ChainID) + b := derivetest.RandomL2BlockWithChainId(rng, 10, defaultTestRollupConfig.L2ChainID) + bHeader := b.Header() + bHeader.Number = new(big.Int).Add(a.Number(), big.NewInt(1)) + bHeader.ParentHash = a.Hash() + b = b.WithSeal(bHeader) err := m.AddL2Block(a) require.NoError(err, "Failed to add L2 block") @@ -306,11 +370,12 @@ func TestChannelManagerClosePendingChannel(t *testing.T) { require.ErrorIs(err, io.EOF, "Expected closed channel manager to produce no more tx data") } -// TestChannelManagerCloseAllTxsFailed ensures that the channel manager +// ChannelManagerCloseAllTxsFailed ensures that the channel manager // can gracefully close after producing transaction frames if none of these // have successfully landed on chain. -func TestChannelManagerCloseAllTxsFailed(t *testing.T) { +func ChannelManagerCloseAllTxsFailed(t *testing.T, batchType uint) { require := require.New(t) + rng := rand.New(rand.NewSource(time.Now().UnixNano())) log := testlog.Logger(t, log.LvlCrit) m := NewChannelManager(log, metrics.NoopMetrics, ChannelConfig{ @@ -321,9 +386,12 @@ func TestChannelManagerCloseAllTxsFailed(t *testing.T) { TargetFrameSize: 1000, ApproxComprRatio: 1.0, }, - }) + BatchType: batchType, + }, &defaultTestRollupConfig, + ) + m.Clear() - a := newMiniL2Block(50_000) + a := derivetest.RandomL2BlockWithChainId(rng, 50000, defaultTestRollupConfig.L2ChainID) err := m.AddL2Block(a) require.NoError(err, "Failed to add L2 block") diff --git a/op-batcher/batcher/channel_test.go b/op-batcher/batcher/channel_test.go index 0c5ce3b83babe..138416069767c 100644 --- a/op-batcher/batcher/channel_test.go +++ b/op-batcher/batcher/channel_test.go @@ -5,6 +5,7 @@ import ( "testing" "github.com/ethereum-optimism/optimism/op-batcher/metrics" + "github.com/ethereum-optimism/optimism/op-node/rollup" "github.com/ethereum-optimism/optimism/op-node/rollup/derive" "github.com/ethereum-optimism/optimism/op-service/eth" "github.com/ethereum-optimism/optimism/op-service/testlog" @@ -20,7 +21,8 @@ func TestChannelTimeout(t *testing.T) { log := testlog.Logger(t, log.LvlCrit) m := NewChannelManager(log, metrics.NoopMetrics, ChannelConfig{ ChannelTimeout: 100, - }) + }, &rollup.Config{}) + m.Clear() // Pending channel is nil so is cannot be timed out require.Nil(t, m.currentChannel) @@ -61,7 +63,8 @@ func TestChannelTimeout(t *testing.T) { // TestChannelNextTxData checks the nextTxData function. func TestChannelNextTxData(t *testing.T) { log := testlog.Logger(t, log.LvlCrit) - m := NewChannelManager(log, metrics.NoopMetrics, ChannelConfig{}) + m := NewChannelManager(log, metrics.NoopMetrics, ChannelConfig{}, &rollup.Config{}) + m.Clear() // Nil pending channel should return EOF returnedTxData, err := m.nextTxData(nil) @@ -109,7 +112,8 @@ func TestChannelTxConfirmed(t *testing.T) { // channels on confirmation. This would result in [TxConfirmed] // clearing confirmed transactions, and reseting the pendingChannels map ChannelTimeout: 10, - }) + }, &rollup.Config{}) + m.Clear() // Let's add a valid pending transaction to the channel manager // So we can demonstrate that TxConfirmed's correctness @@ -157,7 +161,8 @@ func TestChannelTxConfirmed(t *testing.T) { func TestChannelTxFailed(t *testing.T) { // Create a channel manager log := testlog.Logger(t, log.LvlCrit) - m := NewChannelManager(log, metrics.NoopMetrics, ChannelConfig{}) + m := NewChannelManager(log, metrics.NoopMetrics, ChannelConfig{}, &rollup.Config{}) + m.Clear() // Let's add a valid pending transaction to the channel // manager so we can demonstrate correctness diff --git a/op-batcher/batcher/config.go b/op-batcher/batcher/config.go index bad964eb99868..d4f34461f02da 100644 --- a/op-batcher/batcher/config.go +++ b/op-batcher/batcher/config.go @@ -3,52 +3,17 @@ package batcher import ( "time" - "github.com/ethereum/go-ethereum/ethclient" - "github.com/ethereum/go-ethereum/log" "github.com/urfave/cli/v2" "github.com/ethereum-optimism/optimism/op-batcher/compressor" "github.com/ethereum-optimism/optimism/op-batcher/flags" - "github.com/ethereum-optimism/optimism/op-batcher/metrics" - "github.com/ethereum-optimism/optimism/op-node/rollup" oplog "github.com/ethereum-optimism/optimism/op-service/log" opmetrics "github.com/ethereum-optimism/optimism/op-service/metrics" oppprof "github.com/ethereum-optimism/optimism/op-service/pprof" oprpc "github.com/ethereum-optimism/optimism/op-service/rpc" - "github.com/ethereum-optimism/optimism/op-service/sources" "github.com/ethereum-optimism/optimism/op-service/txmgr" ) -type Config struct { - log log.Logger - metr metrics.Metricer - L1Client *ethclient.Client - L2Client *ethclient.Client - RollupNode *sources.RollupClient - TxManager txmgr.TxManager - - NetworkTimeout time.Duration - PollInterval time.Duration - MaxPendingTransactions uint64 - - // RollupConfig is queried at startup - Rollup *rollup.Config - - // Channel builder parameters - Channel ChannelConfig -} - -// Check ensures that the [Config] is valid. -func (c *Config) Check() error { - if err := c.Rollup.Check(); err != nil { - return err - } - if err := c.Channel.Check(); err != nil { - return err - } - return nil -} - type CLIConfig struct { // L1EthRpc is the HTTP provider URL for L1. L1EthRpc string @@ -87,16 +52,18 @@ type CLIConfig struct { Stopped bool + BatchType uint + TxMgrConfig txmgr.CLIConfig LogConfig oplog.CLIConfig MetricsConfig opmetrics.CLIConfig PprofConfig oppprof.CLIConfig CompressorConfig compressor.CLIConfig - RPCFlag oprpc.CLIConfig + RPC oprpc.CLIConfig } -func (c CLIConfig) Check() error { - // TODO: check the sanity of flags loaded directly https://github.com/ethereum-optimism/optimism/issues/7512 +func (c *CLIConfig) Check() error { + // TODO(7512): check the sanity of flags loaded directly https://github.com/ethereum-optimism/optimism/issues/7512 if err := c.MetricsConfig.Check(); err != nil { return err @@ -107,15 +74,15 @@ func (c CLIConfig) Check() error { if err := c.TxMgrConfig.Check(); err != nil { return err } - if err := c.RPCFlag.Check(); err != nil { + if err := c.RPC.Check(); err != nil { return err } return nil } // NewConfig parses the Config from the provided flags or environment variables. -func NewConfig(ctx *cli.Context) CLIConfig { - return CLIConfig{ +func NewConfig(ctx *cli.Context) *CLIConfig { + return &CLIConfig{ /* Required Flags */ L1EthRpc: ctx.String(flags.L1EthRpcFlag.Name), L2EthRpc: ctx.String(flags.L2EthRpcFlag.Name), @@ -128,11 +95,12 @@ func NewConfig(ctx *cli.Context) CLIConfig { MaxChannelDuration: ctx.Uint64(flags.MaxChannelDurationFlag.Name), MaxL1TxSize: ctx.Uint64(flags.MaxL1TxSizeBytesFlag.Name), Stopped: ctx.Bool(flags.StoppedFlag.Name), + BatchType: ctx.Uint(flags.BatchTypeFlag.Name), TxMgrConfig: txmgr.ReadCLIConfig(ctx), LogConfig: oplog.ReadCLIConfig(ctx), MetricsConfig: opmetrics.ReadCLIConfig(ctx), PprofConfig: oppprof.ReadCLIConfig(ctx), CompressorConfig: compressor.ReadCLIConfig(ctx), - RPCFlag: oprpc.ReadCLIConfig(ctx), + RPC: oprpc.ReadCLIConfig(ctx), } } diff --git a/op-batcher/batcher/driver.go b/op-batcher/batcher/driver.go index bb53d5adfb9e8..54633060dac40 100644 --- a/op-batcher/batcher/driver.go +++ b/op-batcher/batcher/driver.go @@ -10,23 +10,50 @@ import ( "sync" "time" + "github.com/ethereum/go-ethereum/core" + "github.com/ethereum/go-ethereum/core/types" + "github.com/ethereum/go-ethereum/log" + "github.com/ethereum-optimism/optimism/op-batcher/metrics" + "github.com/ethereum-optimism/optimism/op-node/rollup" "github.com/ethereum-optimism/optimism/op-node/rollup/derive" - "github.com/ethereum-optimism/optimism/op-service/dial" "github.com/ethereum-optimism/optimism/op-service/eth" "github.com/ethereum-optimism/optimism/op-service/txmgr" - "github.com/ethereum/go-ethereum/core" - "github.com/ethereum/go-ethereum/core/types" - "github.com/ethereum/go-ethereum/log" ) +var ErrBatcherNotRunning = errors.New("batcher is not running") + +type L1Client interface { + HeaderByNumber(ctx context.Context, number *big.Int) (*types.Header, error) +} + +type L2Client interface { + BlockByNumber(ctx context.Context, number *big.Int) (*types.Block, error) +} + +type RollupClient interface { + SyncStatus(ctx context.Context) (*eth.SyncStatus, error) +} + +// DriverSetup is the collection of input/output interfaces and configuration that the driver operates on. +type DriverSetup struct { + Log log.Logger + Metr metrics.Metricer + RollupCfg *rollup.Config + Cfg BatcherConfig + Txmgr txmgr.TxManager + L1Client L1Client + L2Client L2Client + RollupClient RollupClient + Channel ChannelConfig +} + // BatchSubmitter encapsulates a service responsible for submitting L2 tx // batches to L1 for availability. type BatchSubmitter struct { - Config // directly embed the config + sources + DriverSetup - txMgr txmgr.TxManager - wg sync.WaitGroup + wg sync.WaitGroup shutdownCtx context.Context cancelShutdownCtx context.CancelFunc @@ -43,88 +70,16 @@ type BatchSubmitter struct { state *channelManager } -// NewBatchSubmitterFromCLIConfig initializes the BatchSubmitter, gathering any resources -// that will be needed during operation. -func NewBatchSubmitterFromCLIConfig(cfg CLIConfig, l log.Logger, m metrics.Metricer) (*BatchSubmitter, error) { - ctx := context.Background() - - // Connect to L1 and L2 providers. Perform these last since they are the - // most expensive. - l1Client, err := dial.DialEthClientWithTimeout(dial.DefaultDialTimeout, l, cfg.L1EthRpc) - if err != nil { - return nil, err - } - - l2Client, err := dial.DialEthClientWithTimeout(dial.DefaultDialTimeout, l, cfg.L2EthRpc) - if err != nil { - return nil, err - } - - rollupClient, err := dial.DialRollupClientWithTimeout(dial.DefaultDialTimeout, l, cfg.RollupRpc) - if err != nil { - return nil, err - } - - rcfg, err := rollupClient.RollupConfig(ctx) - if err != nil { - return nil, fmt.Errorf("querying rollup config: %w", err) - } - - txManager, err := txmgr.NewSimpleTxManager("batcher", l, m, cfg.TxMgrConfig) - if err != nil { - return nil, err - } - - batcherCfg := Config{ - L1Client: l1Client, - L2Client: l2Client, - RollupNode: rollupClient, - PollInterval: cfg.PollInterval, - MaxPendingTransactions: cfg.MaxPendingTransactions, - NetworkTimeout: cfg.TxMgrConfig.NetworkTimeout, - TxManager: txManager, - Rollup: rcfg, - Channel: ChannelConfig{ - SeqWindowSize: rcfg.SeqWindowSize, - ChannelTimeout: rcfg.ChannelTimeout, - MaxChannelDuration: cfg.MaxChannelDuration, - SubSafetyMargin: cfg.SubSafetyMargin, - MaxFrameSize: cfg.MaxL1TxSize - 1, // subtract 1 byte for version - CompressorConfig: cfg.CompressorConfig.Config(), - }, - } - - // Validate the batcher config - if err := batcherCfg.Check(); err != nil { - return nil, err - } - - return NewBatchSubmitter(ctx, batcherCfg, l, m) -} - -// NewBatchSubmitter initializes the BatchSubmitter, gathering any resources -// that will be needed during operation. -func NewBatchSubmitter(ctx context.Context, cfg Config, l log.Logger, m metrics.Metricer) (*BatchSubmitter, error) { - balance, err := cfg.L1Client.BalanceAt(ctx, cfg.TxManager.From(), nil) - if err != nil { - return nil, err - } - - cfg.log = l - cfg.log.Info("creating batch submitter", "submitter_addr", cfg.TxManager.From(), "submitter_bal", balance) - - cfg.metr = m - +// NewBatchSubmitter initializes the BatchSubmitter driver from a preconfigured DriverSetup +func NewBatchSubmitter(setup DriverSetup) *BatchSubmitter { return &BatchSubmitter{ - Config: cfg, - txMgr: cfg.TxManager, - state: NewChannelManager(l, m, cfg.Channel), - }, nil - + DriverSetup: setup, + state: NewChannelManager(setup.Log, setup.Metr, setup.Channel, setup.RollupCfg), + } } -func (l *BatchSubmitter) Start() error { - l.log.Info("Starting Batch Submitter") +func (l *BatchSubmitter) StartBatchSubmitting() error { + l.Log.Info("Starting Batch Submitter") l.mutex.Lock() defer l.mutex.Unlock() @@ -142,23 +97,27 @@ func (l *BatchSubmitter) Start() error { l.wg.Add(1) go l.loop() - l.log.Info("Batch Submitter started") - + l.Log.Info("Batch Submitter started") return nil } -func (l *BatchSubmitter) StopIfRunning(ctx context.Context) { - _ = l.Stop(ctx) +func (l *BatchSubmitter) StopBatchSubmittingIfRunning(ctx context.Context) error { + err := l.StopBatchSubmitting(ctx) + if errors.Is(err, ErrBatcherNotRunning) { + return nil + } + return err } -func (l *BatchSubmitter) Stop(ctx context.Context) error { - l.log.Info("Stopping Batch Submitter") +// StopBatchSubmitting stops the batch-submitter loop, and force-kills if the provided ctx is done. +func (l *BatchSubmitter) StopBatchSubmitting(ctx context.Context) error { + l.Log.Info("Stopping Batch Submitter") l.mutex.Lock() defer l.mutex.Unlock() if !l.running { - return errors.New("batcher is not running") + return ErrBatcherNotRunning } l.running = false @@ -175,8 +134,7 @@ func (l *BatchSubmitter) Stop(ctx context.Context) error { l.wg.Wait() l.cancelKillCtx() - l.log.Info("Batch Submitter stopped") - + l.Log.Info("Batch Submitter stopped") return nil } @@ -191,7 +149,7 @@ func (l *BatchSubmitter) Stop(ctx context.Context) error { func (l *BatchSubmitter) loadBlocksIntoState(ctx context.Context) error { start, end, err := l.calculateL2BlockRangeToStore(ctx) if err != nil { - l.log.Warn("Error calculating L2 block range", "err", err) + l.Log.Warn("Error calculating L2 block range", "err", err) return err } else if start.Number >= end.Number { return errors.New("start number is >= end number") @@ -202,30 +160,30 @@ func (l *BatchSubmitter) loadBlocksIntoState(ctx context.Context) error { for i := start.Number + 1; i < end.Number+1; i++ { block, err := l.loadBlockIntoState(ctx, i) if errors.Is(err, ErrReorg) { - l.log.Warn("Found L2 reorg", "block_number", i) + l.Log.Warn("Found L2 reorg", "block_number", i) l.lastStoredBlock = eth.BlockID{} return err } else if err != nil { - l.log.Warn("failed to load block into state", "err", err) + l.Log.Warn("failed to load block into state", "err", err) return err } l.lastStoredBlock = eth.ToBlockID(block) latestBlock = block } - l2ref, err := derive.L2BlockToBlockRef(latestBlock, &l.Rollup.Genesis) + l2ref, err := derive.L2BlockToBlockRef(latestBlock, &l.RollupCfg.Genesis) if err != nil { - l.log.Warn("Invalid L2 block loaded into state", "err", err) + l.Log.Warn("Invalid L2 block loaded into state", "err", err) return err } - l.metr.RecordL2BlocksLoaded(l2ref) + l.Metr.RecordL2BlocksLoaded(l2ref) return nil } // loadBlockIntoState fetches & stores a single block into `state`. It returns the block it loaded. func (l *BatchSubmitter) loadBlockIntoState(ctx context.Context, blockNumber uint64) (*types.Block, error) { - ctx, cancel := context.WithTimeout(ctx, l.NetworkTimeout) + ctx, cancel := context.WithTimeout(ctx, l.Cfg.NetworkTimeout) defer cancel() block, err := l.L2Client.BlockByNumber(ctx, new(big.Int).SetUint64(blockNumber)) if err != nil { @@ -236,16 +194,16 @@ func (l *BatchSubmitter) loadBlockIntoState(ctx context.Context, blockNumber uin return nil, fmt.Errorf("adding L2 block to state: %w", err) } - l.log.Info("added L2 block to local state", "block", eth.ToBlockID(block), "tx_count", len(block.Transactions()), "time", block.Time()) + l.Log.Info("added L2 block to local state", "block", eth.ToBlockID(block), "tx_count", len(block.Transactions()), "time", block.Time()) return block, nil } // calculateL2BlockRangeToStore determines the range (start,end] that should be loaded into the local state. // It also takes care of initializing some local state (i.e. will modify l.lastStoredBlock in certain conditions) func (l *BatchSubmitter) calculateL2BlockRangeToStore(ctx context.Context) (eth.BlockID, eth.BlockID, error) { - ctx, cancel := context.WithTimeout(ctx, l.NetworkTimeout) + ctx, cancel := context.WithTimeout(ctx, l.Cfg.NetworkTimeout) defer cancel() - syncStatus, err := l.RollupNode.SyncStatus(ctx) + syncStatus, err := l.RollupClient.SyncStatus(ctx) // Ensure that we have the sync status if err != nil { return eth.BlockID{}, eth.BlockID{}, fmt.Errorf("failed to get sync status: %w", err) @@ -257,10 +215,10 @@ func (l *BatchSubmitter) calculateL2BlockRangeToStore(ctx context.Context) (eth. // Check last stored to see if it needs to be set on startup OR set if is lagged behind. // It lagging implies that the op-node processed some batches that were submitted prior to the current instance of the batcher being alive. if l.lastStoredBlock == (eth.BlockID{}) { - l.log.Info("Starting batch-submitter work at safe-head", "safe", syncStatus.SafeL2) + l.Log.Info("Starting batch-submitter work at safe-head", "safe", syncStatus.SafeL2) l.lastStoredBlock = syncStatus.SafeL2.ID() } else if l.lastStoredBlock.Number < syncStatus.SafeL2.Number { - l.log.Warn("last submitted block lagged behind L2 safe head: batch submission will continue from the safe head now", "last", l.lastStoredBlock, "safe", syncStatus.SafeL2) + l.Log.Warn("last submitted block lagged behind L2 safe head: batch submission will continue from the safe head now", "last", l.lastStoredBlock, "safe", syncStatus.SafeL2) l.lastStoredBlock = syncStatus.SafeL2.ID() } @@ -286,11 +244,11 @@ func (l *BatchSubmitter) calculateL2BlockRangeToStore(ctx context.Context) (eth. func (l *BatchSubmitter) loop() { defer l.wg.Done() - ticker := time.NewTicker(l.PollInterval) + ticker := time.NewTicker(l.Cfg.PollInterval) defer ticker.Stop() receiptsCh := make(chan txmgr.TxReceipt[txData]) - queue := txmgr.NewQueue[txData](l.killCtx, l.txMgr, l.MaxPendingTransactions) + queue := txmgr.NewQueue[txData](l.killCtx, l.Txmgr, l.Cfg.MaxPendingTransactions) for { select { @@ -298,7 +256,7 @@ func (l *BatchSubmitter) loop() { if err := l.loadBlocksIntoState(l.shutdownCtx); errors.Is(err, ErrReorg) { err := l.state.Close() if err != nil { - l.log.Error("error closing the channel manager to handle a L2 reorg", "err", err) + l.Log.Error("error closing the channel manager to handle a L2 reorg", "err", err) } l.publishStateToL1(queue, receiptsCh, true) l.state.Clear() @@ -310,7 +268,7 @@ func (l *BatchSubmitter) loop() { case <-l.shutdownCtx.Done(): err := l.state.Close() if err != nil { - l.log.Error("error closing the channel manager", "err", err) + l.Log.Error("error closing the channel manager", "err", err) } l.publishStateToL1(queue, receiptsCh, true) return @@ -335,7 +293,7 @@ func (l *BatchSubmitter) publishStateToL1(queue *txmgr.Queue[txData], receiptsCh err := l.publishTxToL1(l.killCtx, queue, receiptsCh) if err != nil { if drain && err != io.EOF { - l.log.Error("error sending tx while draining state", "err", err) + l.Log.Error("error sending tx while draining state", "err", err) } return } @@ -357,7 +315,7 @@ func (l *BatchSubmitter) publishTxToL1(ctx context.Context, queue *txmgr.Queue[t // send all available transactions l1tip, err := l.l1Tip(ctx) if err != nil { - l.log.Error("Failed to query L1 tip", "error", err) + l.Log.Error("Failed to query L1 tip", "error", err) return err } l.recordL1Tip(l1tip) @@ -365,10 +323,10 @@ func (l *BatchSubmitter) publishTxToL1(ctx context.Context, queue *txmgr.Queue[t // Collect next transaction data txdata, err := l.state.TxData(l1tip.ID()) if err == io.EOF { - l.log.Trace("no transaction data available") + l.Log.Trace("no transaction data available") return err } else if err != nil { - l.log.Error("unable to get tx data", "err", err) + l.Log.Error("unable to get tx data", "err", err) return err } @@ -384,12 +342,12 @@ func (l *BatchSubmitter) sendTransaction(txdata txData, queue *txmgr.Queue[txDat data := txdata.Bytes() intrinsicGas, err := core.IntrinsicGas(data, nil, false, true, true, false) if err != nil { - l.log.Error("Failed to calculate intrinsic gas", "error", err) + l.Log.Error("Failed to calculate intrinsic gas", "error", err) return } candidate := txmgr.TxCandidate{ - To: &l.Rollup.BatchInboxAddress, + To: &l.RollupCfg.BatchInboxAddress, TxData: data, GasLimit: intrinsicGas, } @@ -399,10 +357,10 @@ func (l *BatchSubmitter) sendTransaction(txdata txData, queue *txmgr.Queue[txDat func (l *BatchSubmitter) handleReceipt(r txmgr.TxReceipt[txData]) { // Record TX Status if r.Err != nil { - l.log.Warn("unable to publish tx", "err", r.Err, "data_size", r.ID.Len()) + l.Log.Warn("unable to publish tx", "err", r.Err, "data_size", r.ID.Len()) l.recordFailedTx(r.ID.ID(), r.Err) } else { - l.log.Info("tx successfully published", "tx_hash", r.Receipt.TxHash, "data_size", r.ID.Len()) + l.Log.Info("tx successfully published", "tx_hash", r.Receipt.TxHash, "data_size", r.ID.Len()) l.recordConfirmedTx(r.ID.ID(), r.Receipt) } } @@ -412,16 +370,16 @@ func (l *BatchSubmitter) recordL1Tip(l1tip eth.L1BlockRef) { return } l.lastL1Tip = l1tip - l.metr.RecordLatestL1Block(l1tip) + l.Metr.RecordLatestL1Block(l1tip) } func (l *BatchSubmitter) recordFailedTx(id txID, err error) { - l.log.Warn("Failed to send transaction", "err", err) + l.Log.Warn("Failed to send transaction", "err", err) l.state.TxFailed(id) } func (l *BatchSubmitter) recordConfirmedTx(id txID, receipt *types.Receipt) { - l.log.Info("Transaction confirmed", "tx_hash", receipt.TxHash, "status", receipt.Status, "block_hash", receipt.BlockHash, "block_number", receipt.BlockNumber) + l.Log.Info("Transaction confirmed", "tx_hash", receipt.TxHash, "status", receipt.Status, "block_hash", receipt.BlockHash, "block_number", receipt.BlockNumber) l1block := eth.BlockID{Number: receipt.BlockNumber.Uint64(), Hash: receipt.BlockHash} l.state.TxConfirmed(id, l1block) } @@ -429,7 +387,7 @@ func (l *BatchSubmitter) recordConfirmedTx(id txID, receipt *types.Receipt) { // l1Tip gets the current L1 tip as a L1BlockRef. The passed context is assumed // to be a lifetime context, so it is internally wrapped with a network timeout. func (l *BatchSubmitter) l1Tip(ctx context.Context) (eth.L1BlockRef, error) { - tctx, cancel := context.WithTimeout(ctx, l.NetworkTimeout) + tctx, cancel := context.WithTimeout(ctx, l.Cfg.NetworkTimeout) defer cancel() head, err := l.L1Client.HeaderByNumber(tctx, nil) if err != nil { diff --git a/op-batcher/batcher/service.go b/op-batcher/batcher/service.go new file mode 100644 index 0000000000000..9af086a3143aa --- /dev/null +++ b/op-batcher/batcher/service.go @@ -0,0 +1,344 @@ +package batcher + +import ( + "context" + "errors" + "fmt" + "io" + "net" + _ "net/http/pprof" + "strconv" + "sync/atomic" + "time" + + "github.com/ethereum/go-ethereum/ethclient" + "github.com/ethereum/go-ethereum/log" + + "github.com/ethereum-optimism/optimism/op-batcher/metrics" + "github.com/ethereum-optimism/optimism/op-batcher/rpc" + "github.com/ethereum-optimism/optimism/op-node/rollup" + "github.com/ethereum-optimism/optimism/op-service/cliapp" + "github.com/ethereum-optimism/optimism/op-service/dial" + "github.com/ethereum-optimism/optimism/op-service/httputil" + opmetrics "github.com/ethereum-optimism/optimism/op-service/metrics" + oppprof "github.com/ethereum-optimism/optimism/op-service/pprof" + oprpc "github.com/ethereum-optimism/optimism/op-service/rpc" + "github.com/ethereum-optimism/optimism/op-service/sources" + "github.com/ethereum-optimism/optimism/op-service/txmgr" +) + +type BatcherConfig struct { + NetworkTimeout time.Duration + PollInterval time.Duration + MaxPendingTransactions uint64 +} + +// BatcherService represents a full batch-submitter instance and its resources, +// and conforms to the op-service CLI Lifecycle interface. +type BatcherService struct { + Log log.Logger + Metrics metrics.Metricer + L1Client *ethclient.Client + L2Client *ethclient.Client + RollupNode *sources.RollupClient + TxManager txmgr.TxManager + + BatcherConfig + + RollupConfig *rollup.Config + + // Channel builder parameters + Channel ChannelConfig + + driver *BatchSubmitter + + Version string + + pprofSrv *httputil.HTTPServer + metricsSrv *httputil.HTTPServer + rpcServer *oprpc.Server + + balanceMetricer io.Closer + + stopped atomic.Bool + + NotSubmittingOnStart bool +} + +// BatcherServiceFromCLIConfig creates a new BatcherService from a CLIConfig. +// The service components are fully started, except for the driver, +// which will not be submitting batches (if it was configured to) until the Start part of the lifecycle. +func BatcherServiceFromCLIConfig(ctx context.Context, version string, cfg *CLIConfig, log log.Logger) (*BatcherService, error) { + var bs BatcherService + if err := bs.initFromCLIConfig(ctx, version, cfg, log); err != nil { + return nil, errors.Join(err, bs.Stop(ctx)) // try to clean up our failed initialization attempt + } + return &bs, nil +} + +func (bs *BatcherService) initFromCLIConfig(ctx context.Context, version string, cfg *CLIConfig, log log.Logger) error { + bs.Version = version + bs.Log = log + bs.NotSubmittingOnStart = cfg.Stopped + + bs.initMetrics(cfg) + + bs.PollInterval = cfg.PollInterval + bs.MaxPendingTransactions = cfg.MaxPendingTransactions + bs.NetworkTimeout = cfg.TxMgrConfig.NetworkTimeout + + if err := bs.initRPCClients(ctx, cfg); err != nil { + return err + } + if err := bs.initRollupCfg(ctx); err != nil { + return fmt.Errorf("failed to load rollup config: %w", err) + } + if err := bs.initChannelConfig(cfg); err != nil { + return fmt.Errorf("failed to init channel config: %w", err) + } + if err := bs.initTxManager(cfg); err != nil { + return fmt.Errorf("failed to init Tx manager: %w", err) + } + bs.initBalanceMonitor(cfg) + if err := bs.initMetricsServer(cfg); err != nil { + return fmt.Errorf("failed to start metrics server: %w", err) + } + if err := bs.initPProf(cfg); err != nil { + return fmt.Errorf("failed to start pprof server: %w", err) + } + bs.initDriver() + if err := bs.initRPCServer(cfg); err != nil { + return fmt.Errorf("failed to start RPC server: %w", err) + } + + bs.Metrics.RecordInfo(bs.Version) + bs.Metrics.RecordUp() + return nil +} + +func (bs *BatcherService) initRPCClients(ctx context.Context, cfg *CLIConfig) error { + l1Client, err := dial.DialEthClientWithTimeout(ctx, dial.DefaultDialTimeout, bs.Log, cfg.L1EthRpc) + if err != nil { + return fmt.Errorf("failed to dial L1 RPC: %w", err) + } + bs.L1Client = l1Client + + l2Client, err := dial.DialEthClientWithTimeout(ctx, dial.DefaultDialTimeout, bs.Log, cfg.L2EthRpc) + if err != nil { + return fmt.Errorf("failed to dial L2 engine RPC: %w", err) + } + bs.L2Client = l2Client + + rollupClient, err := dial.DialRollupClientWithTimeout(ctx, dial.DefaultDialTimeout, bs.Log, cfg.RollupRpc) + if err != nil { + return fmt.Errorf("failed to dial L2 rollup-client RPC: %w", err) + } + bs.RollupNode = rollupClient + return nil +} + +func (bs *BatcherService) initMetrics(cfg *CLIConfig) { + if cfg.MetricsConfig.Enabled { + procName := "default" + bs.Metrics = metrics.NewMetrics(procName) + } else { + bs.Metrics = metrics.NoopMetrics + } +} + +// initBalanceMonitor depends on Metrics, L1Client and TxManager to start background-monitoring of the batcher balance. +func (bs *BatcherService) initBalanceMonitor(cfg *CLIConfig) { + if cfg.MetricsConfig.Enabled { + bs.balanceMetricer = bs.Metrics.StartBalanceMetrics(bs.Log, bs.L1Client, bs.TxManager.From()) + } +} + +func (bs *BatcherService) initRollupCfg(ctx context.Context) error { + rollupCfg, err := bs.RollupNode.RollupConfig(ctx) + if err != nil { + return fmt.Errorf("failed to retrieve rollup config: %w", err) + } + bs.RollupConfig = rollupCfg + if err := bs.RollupConfig.Check(); err != nil { + return fmt.Errorf("invalid rollup config: %w", err) + } + return nil +} + +func (bs *BatcherService) initChannelConfig(cfg *CLIConfig) error { + bs.Channel = ChannelConfig{ + SeqWindowSize: bs.RollupConfig.SeqWindowSize, + ChannelTimeout: bs.RollupConfig.ChannelTimeout, + MaxChannelDuration: cfg.MaxChannelDuration, + SubSafetyMargin: cfg.SubSafetyMargin, + MaxFrameSize: cfg.MaxL1TxSize - 1, // subtract 1 byte for version + CompressorConfig: cfg.CompressorConfig.Config(), + BatchType: cfg.BatchType, + } + if err := bs.Channel.Check(); err != nil { + return fmt.Errorf("invalid channel configuration: %w", err) + } + return nil +} + +func (bs *BatcherService) initTxManager(cfg *CLIConfig) error { + txManager, err := txmgr.NewSimpleTxManager("batcher", bs.Log, bs.Metrics, cfg.TxMgrConfig) + if err != nil { + return err + } + bs.TxManager = txManager + return nil +} + +func (bs *BatcherService) initPProf(cfg *CLIConfig) error { + if !cfg.PprofConfig.Enabled { + return nil + } + log.Debug("starting pprof server", "addr", net.JoinHostPort(cfg.PprofConfig.ListenAddr, strconv.Itoa(cfg.PprofConfig.ListenPort))) + srv, err := oppprof.StartServer(cfg.PprofConfig.ListenAddr, cfg.PprofConfig.ListenPort) + if err != nil { + return err + } + bs.pprofSrv = srv + log.Info("started pprof server", "addr", srv.Addr()) + return nil +} + +func (bs *BatcherService) initMetricsServer(cfg *CLIConfig) error { + if !cfg.MetricsConfig.Enabled { + bs.Log.Info("metrics disabled") + return nil + } + m, ok := bs.Metrics.(opmetrics.RegistryMetricer) + if !ok { + return fmt.Errorf("metrics were enabled, but metricer %T does not expose registry for metrics-server", bs.Metrics) + } + bs.Log.Debug("starting metrics server", "addr", cfg.MetricsConfig.ListenAddr, "port", cfg.MetricsConfig.ListenPort) + metricsSrv, err := opmetrics.StartServer(m.Registry(), cfg.MetricsConfig.ListenAddr, cfg.MetricsConfig.ListenPort) + if err != nil { + return fmt.Errorf("failed to start metrics server: %w", err) + } + bs.Log.Info("started metrics server", "addr", metricsSrv.Addr()) + bs.metricsSrv = metricsSrv + return nil +} + +func (bs *BatcherService) initDriver() { + bs.driver = NewBatchSubmitter(DriverSetup{ + Log: bs.Log, + Metr: bs.Metrics, + RollupCfg: bs.RollupConfig, + Cfg: bs.BatcherConfig, + Txmgr: bs.TxManager, + L1Client: bs.L1Client, + L2Client: bs.L2Client, + RollupClient: bs.RollupNode, + Channel: bs.Channel, + }) +} + +func (bs *BatcherService) initRPCServer(cfg *CLIConfig) error { + server := oprpc.NewServer( + cfg.RPC.ListenAddr, + cfg.RPC.ListenPort, + bs.Version, + oprpc.WithLogger(bs.Log), + ) + if cfg.RPC.EnableAdmin { + adminAPI := rpc.NewAdminAPI(bs.driver, bs.Metrics, bs.Log) + server.AddAPI(rpc.GetAdminAPI(adminAPI)) + bs.Log.Info("Admin RPC enabled") + } + bs.Log.Info("Starting JSON-RPC server") + if err := server.Start(); err != nil { + return fmt.Errorf("unable to start RPC server: %w", err) + } + bs.rpcServer = server + return nil +} + +// Start runs once upon start of the batcher lifecycle, +// and starts batch-submission work if the batcher is configured to start submit data on startup. +func (bs *BatcherService) Start(_ context.Context) error { + bs.driver.Log.Info("Starting batcher", "notSubmittingOnStart", bs.NotSubmittingOnStart) + + if !bs.NotSubmittingOnStart { + return bs.driver.StartBatchSubmitting() + } + return nil +} + +// Stopped returns if the service as a whole is stopped. +func (bs *BatcherService) Stopped() bool { + return bs.stopped.Load() +} + +// Kill is a convenience method to forcefully, non-gracefully, stop the BatcherService. +func (bs *BatcherService) Kill() error { + ctx, cancel := context.WithCancel(context.Background()) + cancel() + return bs.Stop(ctx) +} + +// Stop fully stops the batch-submitter and all its resources gracefully. After stopping, it cannot be restarted. +// See driver.StopBatchSubmitting to temporarily stop the batch submitter. +// If the provided ctx is cancelled, the stopping is forced, i.e. the batching work is killed non-gracefully. +func (bs *BatcherService) Stop(ctx context.Context) error { + if bs.stopped.Load() { + return errors.New("already stopped") + } + bs.Log.Info("Stopping batcher") + + var result error + if bs.driver != nil { + if err := bs.driver.StopBatchSubmittingIfRunning(ctx); err != nil { + result = errors.Join(result, fmt.Errorf("failed to stop batch submitting: %w", err)) + } + } + + if bs.rpcServer != nil { + // TODO(7685): the op-service RPC server is not built on top of op-service httputil Server, and has poor shutdown + if err := bs.rpcServer.Stop(); err != nil { + result = errors.Join(result, fmt.Errorf("failed to stop RPC server: %w", err)) + } + } + if bs.pprofSrv != nil { + if err := bs.pprofSrv.Stop(ctx); err != nil { + result = errors.Join(result, fmt.Errorf("failed to stop PProf server: %w", err)) + } + } + if bs.balanceMetricer != nil { + if err := bs.balanceMetricer.Close(); err != nil { + result = errors.Join(result, fmt.Errorf("failed to close balance metricer: %w", err)) + } + } + if bs.metricsSrv != nil { + if err := bs.metricsSrv.Stop(ctx); err != nil { + result = errors.Join(result, fmt.Errorf("failed to stop metrics server: %w", err)) + } + } + + if bs.L1Client != nil { + bs.L1Client.Close() + } + if bs.L2Client != nil { + bs.L2Client.Close() + } + if bs.RollupNode != nil { + bs.RollupNode.Close() + } + + if result == nil { + bs.stopped.Store(true) + bs.Log.Info("Batch Submitter stopped") + } + return result +} + +var _ cliapp.Lifecycle = (*BatcherService)(nil) + +// Driver returns the handler on the batch-submitter driver element, +// to start/stop/restart the batch-submission work, for use in testing. +func (bs *BatcherService) Driver() rpc.BatcherDriver { + return bs.driver +} diff --git a/op-batcher/cmd/main.go b/op-batcher/cmd/main.go index ff3579a37bf05..91e032ff36b4a 100644 --- a/op-batcher/cmd/main.go +++ b/op-batcher/cmd/main.go @@ -1,7 +1,7 @@ package main import ( - "fmt" + "context" "os" "github.com/urfave/cli/v2" @@ -9,9 +9,11 @@ import ( "github.com/ethereum-optimism/optimism/op-batcher/batcher" "github.com/ethereum-optimism/optimism/op-batcher/flags" "github.com/ethereum-optimism/optimism/op-batcher/metrics" + opservice "github.com/ethereum-optimism/optimism/op-service" "github.com/ethereum-optimism/optimism/op-service/cliapp" oplog "github.com/ethereum-optimism/optimism/op-service/log" "github.com/ethereum-optimism/optimism/op-service/metrics/doc" + "github.com/ethereum-optimism/optimism/op-service/opio" "github.com/ethereum/go-ethereum/log" ) @@ -26,11 +28,11 @@ func main() { app := cli.NewApp() app.Flags = cliapp.ProtectFlags(flags.Flags) - app.Version = fmt.Sprintf("%s-%s-%s", Version, GitCommit, GitDate) + app.Version = opservice.FormatVersion(Version, GitCommit, GitDate, "") app.Name = "op-batcher" app.Usage = "Batch Submitter Service" app.Description = "Service for generating and submitting L2 tx batches to L1" - app.Action = curryMain(Version) + app.Action = cliapp.LifecycleCmd(batcher.Main(Version)) app.Commands = []*cli.Command{ { Name: "doc", @@ -38,16 +40,9 @@ func main() { }, } - err := app.Run(os.Args) + ctx := opio.WithInterruptBlocker(context.Background()) + err := app.RunContext(ctx, os.Args) if err != nil { log.Crit("Application failed", "message", err) } } - -// curryMain transforms the batcher.Main function into an app.Action -// This is done to capture the Version of the batcher. -func curryMain(version string) func(ctx *cli.Context) error { - return func(ctx *cli.Context) error { - return batcher.Main(version, ctx) - } -} diff --git a/op-batcher/flags/flags.go b/op-batcher/flags/flags.go index 9b854f8d6bbb7..5e752d9d27481 100644 --- a/op-batcher/flags/flags.go +++ b/op-batcher/flags/flags.go @@ -76,6 +76,12 @@ var ( Usage: "Initialize the batcher in a stopped state. The batcher can be started using the admin_startBatcher RPC", EnvVars: prefixEnvVars("STOPPED"), } + BatchTypeFlag = &cli.UintFlag{ + Name: "batch-type", + Usage: "The batch type. 0 for SingularBatch and 1 for SpanBatch.", + Value: 0, + EnvVars: prefixEnvVars("BATCH_TYPE"), + } // Legacy Flags SequencerHDPathFlag = txmgr.SequencerHDPathFlag ) @@ -94,6 +100,7 @@ var optionalFlags = []cli.Flag{ MaxL1TxSizeBytesFlag, StoppedFlag, SequencerHDPathFlag, + BatchTypeFlag, } func init() { diff --git a/op-batcher/metrics/metrics.go b/op-batcher/metrics/metrics.go index dd0d2bcc17a92..4ce45d1e2c1ca 100644 --- a/op-batcher/metrics/metrics.go +++ b/op-batcher/metrics/metrics.go @@ -1,17 +1,17 @@ package metrics import ( - "context" + "io" + + "github.com/prometheus/client_golang/prometheus" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/core/types" "github.com/ethereum/go-ethereum/ethclient" "github.com/ethereum/go-ethereum/log" - "github.com/prometheus/client_golang/prometheus" "github.com/ethereum-optimism/optimism/op-node/rollup/derive" "github.com/ethereum-optimism/optimism/op-service/eth" - "github.com/ethereum-optimism/optimism/op-service/httputil" opmetrics "github.com/ethereum-optimism/optimism/op-service/metrics" txmetrics "github.com/ethereum-optimism/optimism/op-service/txmgr/metrics" ) @@ -28,6 +28,10 @@ type Metricer interface { // Record Tx metrics txmetrics.TxMetricer + opmetrics.RPCMetricer + + StartBalanceMetrics(l log.Logger, client *ethclient.Client, account common.Address) io.Closer + RecordLatestL1Block(l1ref eth.L1BlockRef) RecordL2BlocksLoaded(l2ref eth.L2BlockRef) RecordChannelOpened(id derive.ChannelID, numPendingBlocks int) @@ -79,6 +83,9 @@ type Metrics struct { var _ Metricer = (*Metrics)(nil) +// implements the Registry getter, for metrics HTTP server to hook into +var _ opmetrics.RegistryMetricer = (*Metrics)(nil) + func NewMetrics(procName string) *Metrics { if procName == "" { procName = "default" @@ -179,17 +186,16 @@ func NewMetrics(procName string) *Metrics { } } -func (m *Metrics) Start(host string, port int) (*httputil.HTTPServer, error) { - return opmetrics.StartServer(m.registry, host, port) +func (m *Metrics) Registry() *prometheus.Registry { + return m.registry } func (m *Metrics) Document() []opmetrics.DocumentedMetric { return m.factory.Document() } -func (m *Metrics) StartBalanceMetrics(ctx context.Context, - l log.Logger, client *ethclient.Client, account common.Address) { - opmetrics.LaunchBalanceMetrics(ctx, l, m.registry, m.ns, client, account) +func (m *Metrics) StartBalanceMetrics(l log.Logger, client *ethclient.Client, account common.Address) io.Closer { + return opmetrics.LaunchBalanceMetrics(l, m.registry, m.ns, client, account) } // RecordInfo sets a pseudo-metric that contains versioning and diff --git a/op-batcher/metrics/noop.go b/op-batcher/metrics/noop.go index 6a63ea066f1d1..dc68bebda7865 100644 --- a/op-batcher/metrics/noop.go +++ b/op-batcher/metrics/noop.go @@ -1,16 +1,23 @@ package metrics import ( + "io" + + "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/core/types" + "github.com/ethereum/go-ethereum/ethclient" + "github.com/ethereum/go-ethereum/log" + "github.com/ethereum-optimism/optimism/op-node/rollup/derive" "github.com/ethereum-optimism/optimism/op-service/eth" opmetrics "github.com/ethereum-optimism/optimism/op-service/metrics" txmetrics "github.com/ethereum-optimism/optimism/op-service/txmgr/metrics" - "github.com/ethereum/go-ethereum/core/types" ) type noopMetrics struct { opmetrics.NoopRefMetrics txmetrics.NoopTxMetrics + opmetrics.NoopRPCMetrics } var NoopMetrics Metricer = new(noopMetrics) @@ -35,3 +42,6 @@ func (*noopMetrics) RecordChannelTimedOut(derive.ChannelID) {} func (*noopMetrics) RecordBatchTxSubmitted() {} func (*noopMetrics) RecordBatchTxSuccess() {} func (*noopMetrics) RecordBatchTxFailed() {} +func (*noopMetrics) StartBalanceMetrics(log.Logger, *ethclient.Client, common.Address) io.Closer { + return nil +} diff --git a/op-batcher/rpc/api.go b/op-batcher/rpc/api.go index 309c9d3252c9e..3641e64def3f7 100644 --- a/op-batcher/rpc/api.go +++ b/op-batcher/rpc/api.go @@ -10,17 +10,17 @@ import ( "github.com/ethereum-optimism/optimism/op-service/rpc" ) -type batcherClient interface { - Start() error - Stop(ctx context.Context) error +type BatcherDriver interface { + StartBatchSubmitting() error + StopBatchSubmitting(ctx context.Context) error } type adminAPI struct { *rpc.CommonAdminAPI - b batcherClient + b BatcherDriver } -func NewAdminAPI(dr batcherClient, m metrics.RPCMetricer, log log.Logger) *adminAPI { +func NewAdminAPI(dr BatcherDriver, m metrics.RPCMetricer, log log.Logger) *adminAPI { return &adminAPI{ CommonAdminAPI: rpc.NewCommonAdminAPI(m, log), b: dr, @@ -35,9 +35,9 @@ func GetAdminAPI(api *adminAPI) gethrpc.API { } func (a *adminAPI) StartBatcher(_ context.Context) error { - return a.b.Start() + return a.b.StartBatchSubmitting() } func (a *adminAPI) StopBatcher(ctx context.Context) error { - return a.b.Stop(ctx) + return a.b.StopBatchSubmitting(ctx) } diff --git a/op-bindings/Makefile b/op-bindings/Makefile index 97b26890bc414..1a5b8360bfe18 100644 --- a/op-bindings/Makefile +++ b/op-bindings/Makefile @@ -26,9 +26,6 @@ bindings-build: -package $(pkg) \ -monorepo-base $(monorepo-base) -lint: - golangci-lint run -E goimports,sqlclosecheck,bodyclose,asciicheck,misspell,errorlint --timeout 5m -e "errors.As" -e "errors.Is" ./... - mkdir: mkdir -p $(pkg) diff --git a/op-bindings/bindings/alphabetvm.go b/op-bindings/bindings/alphabetvm.go index 3e0966b4b7692..67c960d916240 100644 --- a/op-bindings/bindings/alphabetvm.go +++ b/op-bindings/bindings/alphabetvm.go @@ -30,8 +30,8 @@ var ( // AlphabetVMMetaData contains all meta data concerning the AlphabetVM contract. var AlphabetVMMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"Claim\",\"name\":\"_absolutePrestate\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"oracle\",\"outputs\":[{\"internalType\":\"contractIPreimageOracle\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"_stateData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"name\":\"step\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"postState_\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", - Bin: "0x60a060405234801561001057600080fd5b50604051610a5d380380610a5d83398101604081905261002f91610090565b608081905260405161004090610083565b604051809103906000f08015801561005c573d6000803e3d6000fd5b50600080546001600160a01b0319166001600160a01b0392909216919091179055506100a9565b6106458061041883390190565b6000602082840312156100a257600080fd5b5051919050565b6080516103556100c3600039600060af01526103556000f3fe608060405234801561001057600080fd5b50600436106100365760003560e01c80637dc0d1d01461003b578063f8e0cb9614610085575b600080fd5b60005461005b9073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b610098610093366004610212565b6100a6565b60405190815260200161007c565b600080600060087f0000000000000000000000000000000000000000000000000000000000000000901b600888886040516100e292919061027e565b6040518091039020901b0361010857600091506101018688018861028e565b9050610127565b610114868801886102a7565b909250905081610123816102f8565b9250505b81610133826001610330565b604080516020810193909352820152606001604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f010000000000000000000000000000000000000000000000000000000000000017979650505050505050565b60008083601f8401126101db57600080fd5b50813567ffffffffffffffff8111156101f357600080fd5b60208301915083602082850101111561020b57600080fd5b9250929050565b6000806000806040858703121561022857600080fd5b843567ffffffffffffffff8082111561024057600080fd5b61024c888389016101c9565b9096509450602087013591508082111561026557600080fd5b50610272878288016101c9565b95989497509550505050565b8183823760009101908152919050565b6000602082840312156102a057600080fd5b5035919050565b600080604083850312156102ba57600080fd5b50508035926020909101359150565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203610329576103296102c9565b5060010190565b60008219821115610343576103436102c9565b50019056fea164736f6c634300080f000a608060405234801561001057600080fd5b50610625806100206000396000f3fe608060405234801561001057600080fd5b50600436106100725760003560e01c8063e03110e111610050578063e03110e114610106578063e15926111461012e578063fef2b4ed1461014357600080fd5b806361238bde146100775780638542cf50146100b55780639a1f5e7f146100f3575b600080fd5b6100a26100853660046104d1565b600160209081526000928352604080842090915290825290205481565b6040519081526020015b60405180910390f35b6100e36100c33660046104d1565b600260209081526000928352604080842090915290825290205460ff1681565b60405190151581526020016100ac565b6100a26101013660046104f3565b610163565b6101196101143660046104d1565b610236565b604080519283526020830191909152016100ac565b61014161013c366004610525565b610327565b005b6100a26101513660046105a1565b60006020819052908152604090205481565b600061016e85610430565b905061017b8360086105e9565b8211806101885750602083115b156101bf576040517ffe25498700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000602081815260c085901b82526008959095528251828252600286526040808320858452875280832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600190811790915584845287528083209483529386528382205581815293849052922055919050565b6000828152600260209081526040808320848452909152812054819060ff166102bf576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f7072652d696d616765206d757374206578697374000000000000000000000000604482015260640160405180910390fd5b50600083815260208181526040909120546102db8160086105e9565b6102e68560206105e9565b1061030457836102f78260086105e9565b6103019190610601565b91505b506000938452600160209081526040808620948652939052919092205492909150565b604435600080600883018611156103465763fe2549876000526004601cfd5b60c083901b6080526088838682378087017ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff80151908490207effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f02000000000000000000000000000000000000000000000000000000000000001760008181526002602090815260408083208b8452825280832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600190811790915584845282528083209a83529981528982209390935590815290819052959095209190915550505050565b7f01000000000000000000000000000000000000000000000000000000000000007effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8216176104cb81600090815233602052604090207effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f01000000000000000000000000000000000000000000000000000000000000001790565b92915050565b600080604083850312156104e457600080fd5b50508035926020909101359150565b6000806000806080858703121561050957600080fd5b5050823594602084013594506040840135936060013592509050565b60008060006040848603121561053a57600080fd5b83359250602084013567ffffffffffffffff8082111561055957600080fd5b818601915086601f83011261056d57600080fd5b81358181111561057c57600080fd5b87602082850101111561058e57600080fd5b6020830194508093505050509250925092565b6000602082840312156105b357600080fd5b5035919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600082198211156105fc576105fc6105ba565b500190565b600082821015610613576106136105ba565b50039056fea164736f6c634300080f000a", + ABI: "[{\"inputs\":[{\"internalType\":\"Claim\",\"name\":\"_absolutePrestate\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"oracle\",\"outputs\":[{\"internalType\":\"contractIPreimageOracle\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"_stateData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"step\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"postState_\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", + Bin: "0x60a060405234801561001057600080fd5b50604051610a7d380380610a7d83398101604081905261002f91610090565b608081905260405161004090610083565b604051809103906000f08015801561005c573d6000803e3d6000fd5b50600080546001600160a01b0319166001600160a01b0392909216919091179055506100a9565b61065c8061042183390190565b6000602082840312156100a257600080fd5b5051919050565b60805161035e6100c3600039600060af015261035e6000f3fe608060405234801561001057600080fd5b50600436106100365760003560e01c80637dc0d1d01461003b578063836e7b3214610085575b600080fd5b60005461005b9073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b610098610093366004610213565b6100a6565b60405190815260200161007c565b600080600060087f0000000000000000000000000000000000000000000000000000000000000000901b600889896040516100e2929190610287565b6040518091039020901b03610108576000915061010187890189610297565b9050610127565b610114878901896102b0565b90925090508161012381610301565b9250505b81610133826001610339565b604080516020810193909352820152606001604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f01000000000000000000000000000000000000000000000000000000000000001798975050505050505050565b60008083601f8401126101dc57600080fd5b50813567ffffffffffffffff8111156101f457600080fd5b60208301915083602082850101111561020c57600080fd5b9250929050565b60008060008060006060868803121561022b57600080fd5b853567ffffffffffffffff8082111561024357600080fd5b61024f89838a016101ca565b9097509550602088013591508082111561026857600080fd5b50610275888289016101ca565b96999598509660400135949350505050565b8183823760009101908152919050565b6000602082840312156102a957600080fd5b5035919050565b600080604083850312156102c357600080fd5b50508035926020909101359150565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203610332576103326102d2565b5060010190565b6000821982111561034c5761034c6102d2565b50019056fea164736f6c634300080f000a608060405234801561001057600080fd5b5061063c806100206000396000f3fe608060405234801561001057600080fd5b50600436106100725760003560e01c8063e03110e111610050578063e03110e114610106578063e15926111461012e578063fef2b4ed1461014357600080fd5b806361238bde146100775780638542cf50146100b5578063c0c220c9146100f3575b600080fd5b6100a26100853660046104df565b600160209081526000928352604080842090915290825290205481565b6040519081526020015b60405180910390f35b6100e36100c33660046104df565b600260209081526000928352604080842090915290825290205460ff1681565b60405190151581526020016100ac565b6100a2610101366004610501565b610163565b6101196101143660046104df565b610238565b604080519283526020830191909152016100ac565b61014161013c36600461053c565b610329565b005b6100a26101513660046105b8565b60006020819052908152604090205481565b600061016f8686610432565b905061017c836008610600565b8211806101895750602083115b156101c0576040517ffe25498700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000602081815260c085901b82526008959095528251828252600286526040808320858452875280832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660019081179091558484528752808320948352938652838220558181529384905292205592915050565b6000828152600260209081526040808320848452909152812054819060ff166102c1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f7072652d696d616765206d757374206578697374000000000000000000000000604482015260640160405180910390fd5b50600083815260208181526040909120546102dd816008610600565b6102e8856020610600565b1061030657836102f9826008610600565b6103039190610618565b91505b506000938452600160209081526040808620948652939052919092205492909150565b604435600080600883018611156103485763fe2549876000526004601cfd5b60c083901b6080526088838682378087017ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff80151908490207effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f02000000000000000000000000000000000000000000000000000000000000001760008181526002602090815260408083208b8452825280832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600190811790915584845282528083209a83529981528982209390935590815290819052959095209190915550505050565b7f01000000000000000000000000000000000000000000000000000000000000007effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8316176104d8818360408051600093845233602052918152606090922091527effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f01000000000000000000000000000000000000000000000000000000000000001790565b9392505050565b600080604083850312156104f257600080fd5b50508035926020909101359150565b600080600080600060a0868803121561051957600080fd5b505083359560208501359550604085013594606081013594506080013592509050565b60008060006040848603121561055157600080fd5b83359250602084013567ffffffffffffffff8082111561057057600080fd5b818601915086601f83011261058457600080fd5b81358181111561059357600080fd5b8760208285010111156105a557600080fd5b6020830194508093505050509250925092565b6000602082840312156105ca57600080fd5b5035919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60008219821115610613576106136105d1565b500190565b60008282101561062a5761062a6105d1565b50039056fea164736f6c634300080f000a", } // AlphabetVMABI is the input ABI used to generate the binding from. @@ -232,12 +232,12 @@ func (_AlphabetVM *AlphabetVMCallerSession) Oracle() (common.Address, error) { return _AlphabetVM.Contract.Oracle(&_AlphabetVM.CallOpts) } -// Step is a free data retrieval call binding the contract method 0xf8e0cb96. +// Step is a free data retrieval call binding the contract method 0x836e7b32. // -// Solidity: function step(bytes _stateData, bytes ) view returns(bytes32 postState_) -func (_AlphabetVM *AlphabetVMCaller) Step(opts *bind.CallOpts, _stateData []byte, arg1 []byte) ([32]byte, error) { +// Solidity: function step(bytes _stateData, bytes , uint256 ) view returns(bytes32 postState_) +func (_AlphabetVM *AlphabetVMCaller) Step(opts *bind.CallOpts, _stateData []byte, arg1 []byte, arg2 *big.Int) ([32]byte, error) { var out []interface{} - err := _AlphabetVM.contract.Call(opts, &out, "step", _stateData, arg1) + err := _AlphabetVM.contract.Call(opts, &out, "step", _stateData, arg1, arg2) if err != nil { return *new([32]byte), err @@ -249,16 +249,16 @@ func (_AlphabetVM *AlphabetVMCaller) Step(opts *bind.CallOpts, _stateData []byte } -// Step is a free data retrieval call binding the contract method 0xf8e0cb96. +// Step is a free data retrieval call binding the contract method 0x836e7b32. // -// Solidity: function step(bytes _stateData, bytes ) view returns(bytes32 postState_) -func (_AlphabetVM *AlphabetVMSession) Step(_stateData []byte, arg1 []byte) ([32]byte, error) { - return _AlphabetVM.Contract.Step(&_AlphabetVM.CallOpts, _stateData, arg1) +// Solidity: function step(bytes _stateData, bytes , uint256 ) view returns(bytes32 postState_) +func (_AlphabetVM *AlphabetVMSession) Step(_stateData []byte, arg1 []byte, arg2 *big.Int) ([32]byte, error) { + return _AlphabetVM.Contract.Step(&_AlphabetVM.CallOpts, _stateData, arg1, arg2) } -// Step is a free data retrieval call binding the contract method 0xf8e0cb96. +// Step is a free data retrieval call binding the contract method 0x836e7b32. // -// Solidity: function step(bytes _stateData, bytes ) view returns(bytes32 postState_) -func (_AlphabetVM *AlphabetVMCallerSession) Step(_stateData []byte, arg1 []byte) ([32]byte, error) { - return _AlphabetVM.Contract.Step(&_AlphabetVM.CallOpts, _stateData, arg1) +// Solidity: function step(bytes _stateData, bytes , uint256 ) view returns(bytes32 postState_) +func (_AlphabetVM *AlphabetVMCallerSession) Step(_stateData []byte, arg1 []byte, arg2 *big.Int) ([32]byte, error) { + return _AlphabetVM.Contract.Step(&_AlphabetVM.CallOpts, _stateData, arg1, arg2) } diff --git a/op-bindings/bindings/alphabetvm_more.go b/op-bindings/bindings/alphabetvm_more.go index 4f7b1d776df8b..78bacad2b0362 100644 --- a/op-bindings/bindings/alphabetvm_more.go +++ b/op-bindings/bindings/alphabetvm_more.go @@ -9,11 +9,11 @@ import ( "github.com/ethereum-optimism/optimism/op-bindings/solc" ) -const AlphabetVMStorageLayoutJSON = "{\"storage\":[{\"astId\":1000,\"contract\":\"test/FaultDisputeGame.t.sol:AlphabetVM\",\"label\":\"oracle\",\"offset\":0,\"slot\":\"0\",\"type\":\"t_contract(IPreimageOracle)1001\"}],\"types\":{\"t_contract(IPreimageOracle)1001\":{\"encoding\":\"inplace\",\"label\":\"contract IPreimageOracle\",\"numberOfBytes\":\"20\"}}}" +const AlphabetVMStorageLayoutJSON = "{\"storage\":[{\"astId\":1000,\"contract\":\"test/mocks/AlphabetVM.sol:AlphabetVM\",\"label\":\"oracle\",\"offset\":0,\"slot\":\"0\",\"type\":\"t_contract(IPreimageOracle)1001\"}],\"types\":{\"t_contract(IPreimageOracle)1001\":{\"encoding\":\"inplace\",\"label\":\"contract IPreimageOracle\",\"numberOfBytes\":\"20\"}}}" var AlphabetVMStorageLayout = new(solc.StorageLayout) -var AlphabetVMDeployedBin = "0x608060405234801561001057600080fd5b50600436106100365760003560e01c80637dc0d1d01461003b578063f8e0cb9614610085575b600080fd5b60005461005b9073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b610098610093366004610212565b6100a6565b60405190815260200161007c565b600080600060087f0000000000000000000000000000000000000000000000000000000000000000901b600888886040516100e292919061027e565b6040518091039020901b0361010857600091506101018688018861028e565b9050610127565b610114868801886102a7565b909250905081610123816102f8565b9250505b81610133826001610330565b604080516020810193909352820152606001604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f010000000000000000000000000000000000000000000000000000000000000017979650505050505050565b60008083601f8401126101db57600080fd5b50813567ffffffffffffffff8111156101f357600080fd5b60208301915083602082850101111561020b57600080fd5b9250929050565b6000806000806040858703121561022857600080fd5b843567ffffffffffffffff8082111561024057600080fd5b61024c888389016101c9565b9096509450602087013591508082111561026557600080fd5b50610272878288016101c9565b95989497509550505050565b8183823760009101908152919050565b6000602082840312156102a057600080fd5b5035919050565b600080604083850312156102ba57600080fd5b50508035926020909101359150565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203610329576103296102c9565b5060010190565b60008219821115610343576103436102c9565b50019056fea164736f6c634300080f000a" +var AlphabetVMDeployedBin = "0x608060405234801561001057600080fd5b50600436106100365760003560e01c80637dc0d1d01461003b578063836e7b3214610085575b600080fd5b60005461005b9073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b610098610093366004610213565b6100a6565b60405190815260200161007c565b600080600060087f0000000000000000000000000000000000000000000000000000000000000000901b600889896040516100e2929190610287565b6040518091039020901b03610108576000915061010187890189610297565b9050610127565b610114878901896102b0565b90925090508161012381610301565b9250505b81610133826001610339565b604080516020810193909352820152606001604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f01000000000000000000000000000000000000000000000000000000000000001798975050505050505050565b60008083601f8401126101dc57600080fd5b50813567ffffffffffffffff8111156101f457600080fd5b60208301915083602082850101111561020c57600080fd5b9250929050565b60008060008060006060868803121561022b57600080fd5b853567ffffffffffffffff8082111561024357600080fd5b61024f89838a016101ca565b9097509550602088013591508082111561026857600080fd5b50610275888289016101ca565b96999598509660400135949350505050565b8183823760009101908152919050565b6000602082840312156102a957600080fd5b5035919050565b600080604083850312156102c357600080fd5b50508035926020909101359150565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203610332576103326102d2565b5060010190565b6000821982111561034c5761034c6102d2565b50019056fea164736f6c634300080f000a" func init() { if err := json.Unmarshal([]byte(AlphabetVMStorageLayoutJSON), AlphabetVMStorageLayout); err != nil { diff --git a/op-bindings/bindings/basefeevault.go b/op-bindings/bindings/basefeevault.go index 4dde706554a9c..7fcfefc400ad3 100644 --- a/op-bindings/bindings/basefeevault.go +++ b/op-bindings/bindings/basefeevault.go @@ -31,7 +31,7 @@ var ( // BaseFeeVaultMetaData contains all meta data concerning the BaseFeeVault contract. var BaseFeeVaultMetaData = &bind.MetaData{ ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_recipient\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_minWithdrawalAmount\",\"type\":\"uint256\"},{\"internalType\":\"enumFeeVault.WithdrawalNetwork\",\"name\":\"_withdrawalNetwork\",\"type\":\"uint8\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"}],\"name\":\"Withdrawal\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"enumFeeVault.WithdrawalNetwork\",\"name\":\"withdrawalNetwork\",\"type\":\"uint8\"}],\"name\":\"Withdrawal\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MIN_WITHDRAWAL_AMOUNT\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"RECIPIENT\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"WITHDRAWAL_NETWORK\",\"outputs\":[{\"internalType\":\"enumFeeVault.WithdrawalNetwork\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"totalProcessed\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"version\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"withdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"stateMutability\":\"payable\",\"type\":\"receive\"}]", - Bin: "0x60e060405234801561001057600080fd5b506040516108d13803806108d183398101604081905261002f91610079565b6001600160a01b03831660a0526080829052828282806001811115610056576100566100cc565b60c081600181111561006a5761006a6100cc565b815250505050505050506100e2565b60008060006060848603121561008e57600080fd5b83516001600160a01b03811681146100a557600080fd5b602085015160408601519194509250600281106100c157600080fd5b809150509250925092565b634e487b7160e01b600052602160045260246000fd5b60805160a05160c051610790610141600039600081816101760152818161038901526103c40152600081816087015281816102d801528181610367015281816103fd01526105640152600081816101b701526101db01526107906000f3fe6080604052600436106100695760003560e01c806384411d651161004357806384411d6514610140578063d0e12f9014610164578063d3e5792b146101a557600080fd5b80630d9019e1146100755780633ccfd60b146100d357806354fd4d50146100ea57600080fd5b3661007057005b600080fd5b34801561008157600080fd5b506100a97f000000000000000000000000000000000000000000000000000000000000000081565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b3480156100df57600080fd5b506100e86101d9565b005b3480156100f657600080fd5b506101336040518060400160405280600581526020017f312e342e3000000000000000000000000000000000000000000000000000000081525081565b6040516100ca9190610630565b34801561014c57600080fd5b5061015660005481565b6040519081526020016100ca565b34801561017057600080fd5b506101987f000000000000000000000000000000000000000000000000000000000000000081565b6040516100ca91906106b4565b3480156101b157600080fd5b506101567f000000000000000000000000000000000000000000000000000000000000000081565b7f00000000000000000000000000000000000000000000000000000000000000004710156102b4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604a60248201527f4665655661756c743a207769746864726177616c20616d6f756e74206d75737460448201527f2062652067726561746572207468616e206d696e696d756d207769746864726160648201527f77616c20616d6f756e7400000000000000000000000000000000000000000000608482015260a4015b60405180910390fd5b6000479050806000808282546102ca91906106c8565b9091555050604080518281527f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff166020820152338183015290517fc8a211cc64b6ed1b50595a9fcb1932b6d1e5a6e8ef15b60e5b1f988ea9086bba9181900360600190a17f38e04cbeb8c10f8f568618aa75be0f10b6729b8b4237743b4de20cbcde2839ee817f0000000000000000000000000000000000000000000000000000000000000000337f00000000000000000000000000000000000000000000000000000000000000006040516103b89493929190610707565b60405180910390a160017f000000000000000000000000000000000000000000000000000000000000000060018111156103f4576103f461064a565b0361050d5760007f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff168260405160006040518083038185875af1925050503d8060008114610473576040519150601f19603f3d011682016040523d82523d6000602084013e610478565b606091505b5050905080610509576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603060248201527f4665655661756c743a206661696c656420746f2073656e642045544820746f2060448201527f4c322066656520726563697069656e740000000000000000000000000000000060648201526084016102ab565b5050565b604080516020810182526000815290517fe11013dd0000000000000000000000000000000000000000000000000000000081527342000000000000000000000000000000000000109163e11013dd918491610590917f0000000000000000000000000000000000000000000000000000000000000000916188b891600401610748565b6000604051808303818588803b1580156105a957600080fd5b505af11580156105bd573d6000803e3d6000fd5b505050505050565b6000815180845260005b818110156105eb576020818501810151868301820152016105cf565b818111156105fd576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60208152600061064360208301846105c5565b9392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b600281106106b0577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b9052565b602081016106c28284610679565b92915050565b60008219821115610702577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b500190565b84815273ffffffffffffffffffffffffffffffffffffffff8481166020830152831660408201526080810161073f6060830184610679565b95945050505050565b73ffffffffffffffffffffffffffffffffffffffff8416815263ffffffff8316602082015260606040820152600061073f60608301846105c556fea164736f6c634300080f000a", + Bin: "0x60e060405234801561001057600080fd5b506040516108d13803806108d183398101604081905261002f91610079565b6001600160a01b03831660a0526080829052828282806001811115610056576100566100cc565b60c081600181111561006a5761006a6100cc565b815250505050505050506100e2565b60008060006060848603121561008e57600080fd5b83516001600160a01b03811681146100a557600080fd5b602085015160408601519194509250600281106100c157600080fd5b809150509250925092565b634e487b7160e01b600052602160045260246000fd5b60805160a05160c051610790610141600039600081816101760152818161038901526103c40152600081816087015281816102d801528181610367015281816103fd01526105640152600081816101b701526101db01526107906000f3fe6080604052600436106100695760003560e01c806384411d651161004357806384411d6514610140578063d0e12f9014610164578063d3e5792b146101a557600080fd5b80630d9019e1146100755780633ccfd60b146100d357806354fd4d50146100ea57600080fd5b3661007057005b600080fd5b34801561008157600080fd5b506100a97f000000000000000000000000000000000000000000000000000000000000000081565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b3480156100df57600080fd5b506100e86101d9565b005b3480156100f657600080fd5b506101336040518060400160405280600581526020017f312e342e3100000000000000000000000000000000000000000000000000000081525081565b6040516100ca9190610630565b34801561014c57600080fd5b5061015660005481565b6040519081526020016100ca565b34801561017057600080fd5b506101987f000000000000000000000000000000000000000000000000000000000000000081565b6040516100ca91906106b4565b3480156101b157600080fd5b506101567f000000000000000000000000000000000000000000000000000000000000000081565b7f00000000000000000000000000000000000000000000000000000000000000004710156102b4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604a60248201527f4665655661756c743a207769746864726177616c20616d6f756e74206d75737460448201527f2062652067726561746572207468616e206d696e696d756d207769746864726160648201527f77616c20616d6f756e7400000000000000000000000000000000000000000000608482015260a4015b60405180910390fd5b6000479050806000808282546102ca91906106c8565b9091555050604080518281527f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff166020820152338183015290517fc8a211cc64b6ed1b50595a9fcb1932b6d1e5a6e8ef15b60e5b1f988ea9086bba9181900360600190a17f38e04cbeb8c10f8f568618aa75be0f10b6729b8b4237743b4de20cbcde2839ee817f0000000000000000000000000000000000000000000000000000000000000000337f00000000000000000000000000000000000000000000000000000000000000006040516103b89493929190610707565b60405180910390a160017f000000000000000000000000000000000000000000000000000000000000000060018111156103f4576103f461064a565b0361050d5760007f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff168260405160006040518083038185875af1925050503d8060008114610473576040519150601f19603f3d011682016040523d82523d6000602084013e610478565b606091505b5050905080610509576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603060248201527f4665655661756c743a206661696c656420746f2073656e642045544820746f2060448201527f4c322066656520726563697069656e740000000000000000000000000000000060648201526084016102ab565b5050565b604080516020810182526000815290517fe11013dd0000000000000000000000000000000000000000000000000000000081527342000000000000000000000000000000000000109163e11013dd918491610590917f0000000000000000000000000000000000000000000000000000000000000000916188b891600401610748565b6000604051808303818588803b1580156105a957600080fd5b505af11580156105bd573d6000803e3d6000fd5b505050505050565b6000815180845260005b818110156105eb576020818501810151868301820152016105cf565b818111156105fd576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60208152600061064360208301846105c5565b9392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b600281106106b0577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b9052565b602081016106c28284610679565b92915050565b60008219821115610702577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b500190565b84815273ffffffffffffffffffffffffffffffffffffffff8481166020830152831660408201526080810161073f6060830184610679565b95945050505050565b73ffffffffffffffffffffffffffffffffffffffff8416815263ffffffff8316602082015260606040820152600061073f60608301846105c556fea164736f6c634300080f000a", } // BaseFeeVaultABI is the input ABI used to generate the binding from. diff --git a/op-bindings/bindings/basefeevault_more.go b/op-bindings/bindings/basefeevault_more.go index 2041fbaf83604..e62ffc0e217aa 100644 --- a/op-bindings/bindings/basefeevault_more.go +++ b/op-bindings/bindings/basefeevault_more.go @@ -13,7 +13,7 @@ const BaseFeeVaultStorageLayoutJSON = "{\"storage\":[{\"astId\":1000,\"contract\ var BaseFeeVaultStorageLayout = new(solc.StorageLayout) -var BaseFeeVaultDeployedBin = "0x6080604052600436106100695760003560e01c806384411d651161004357806384411d6514610140578063d0e12f9014610164578063d3e5792b146101a557600080fd5b80630d9019e1146100755780633ccfd60b146100d357806354fd4d50146100ea57600080fd5b3661007057005b600080fd5b34801561008157600080fd5b506100a97f000000000000000000000000000000000000000000000000000000000000000081565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b3480156100df57600080fd5b506100e86101d9565b005b3480156100f657600080fd5b506101336040518060400160405280600581526020017f312e342e3000000000000000000000000000000000000000000000000000000081525081565b6040516100ca9190610630565b34801561014c57600080fd5b5061015660005481565b6040519081526020016100ca565b34801561017057600080fd5b506101987f000000000000000000000000000000000000000000000000000000000000000081565b6040516100ca91906106b4565b3480156101b157600080fd5b506101567f000000000000000000000000000000000000000000000000000000000000000081565b7f00000000000000000000000000000000000000000000000000000000000000004710156102b4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604a60248201527f4665655661756c743a207769746864726177616c20616d6f756e74206d75737460448201527f2062652067726561746572207468616e206d696e696d756d207769746864726160648201527f77616c20616d6f756e7400000000000000000000000000000000000000000000608482015260a4015b60405180910390fd5b6000479050806000808282546102ca91906106c8565b9091555050604080518281527f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff166020820152338183015290517fc8a211cc64b6ed1b50595a9fcb1932b6d1e5a6e8ef15b60e5b1f988ea9086bba9181900360600190a17f38e04cbeb8c10f8f568618aa75be0f10b6729b8b4237743b4de20cbcde2839ee817f0000000000000000000000000000000000000000000000000000000000000000337f00000000000000000000000000000000000000000000000000000000000000006040516103b89493929190610707565b60405180910390a160017f000000000000000000000000000000000000000000000000000000000000000060018111156103f4576103f461064a565b0361050d5760007f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff168260405160006040518083038185875af1925050503d8060008114610473576040519150601f19603f3d011682016040523d82523d6000602084013e610478565b606091505b5050905080610509576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603060248201527f4665655661756c743a206661696c656420746f2073656e642045544820746f2060448201527f4c322066656520726563697069656e740000000000000000000000000000000060648201526084016102ab565b5050565b604080516020810182526000815290517fe11013dd0000000000000000000000000000000000000000000000000000000081527342000000000000000000000000000000000000109163e11013dd918491610590917f0000000000000000000000000000000000000000000000000000000000000000916188b891600401610748565b6000604051808303818588803b1580156105a957600080fd5b505af11580156105bd573d6000803e3d6000fd5b505050505050565b6000815180845260005b818110156105eb576020818501810151868301820152016105cf565b818111156105fd576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60208152600061064360208301846105c5565b9392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b600281106106b0577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b9052565b602081016106c28284610679565b92915050565b60008219821115610702577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b500190565b84815273ffffffffffffffffffffffffffffffffffffffff8481166020830152831660408201526080810161073f6060830184610679565b95945050505050565b73ffffffffffffffffffffffffffffffffffffffff8416815263ffffffff8316602082015260606040820152600061073f60608301846105c556fea164736f6c634300080f000a" +var BaseFeeVaultDeployedBin = "0x6080604052600436106100695760003560e01c806384411d651161004357806384411d6514610140578063d0e12f9014610164578063d3e5792b146101a557600080fd5b80630d9019e1146100755780633ccfd60b146100d357806354fd4d50146100ea57600080fd5b3661007057005b600080fd5b34801561008157600080fd5b506100a97f000000000000000000000000000000000000000000000000000000000000000081565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b3480156100df57600080fd5b506100e86101d9565b005b3480156100f657600080fd5b506101336040518060400160405280600581526020017f312e342e3100000000000000000000000000000000000000000000000000000081525081565b6040516100ca9190610630565b34801561014c57600080fd5b5061015660005481565b6040519081526020016100ca565b34801561017057600080fd5b506101987f000000000000000000000000000000000000000000000000000000000000000081565b6040516100ca91906106b4565b3480156101b157600080fd5b506101567f000000000000000000000000000000000000000000000000000000000000000081565b7f00000000000000000000000000000000000000000000000000000000000000004710156102b4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604a60248201527f4665655661756c743a207769746864726177616c20616d6f756e74206d75737460448201527f2062652067726561746572207468616e206d696e696d756d207769746864726160648201527f77616c20616d6f756e7400000000000000000000000000000000000000000000608482015260a4015b60405180910390fd5b6000479050806000808282546102ca91906106c8565b9091555050604080518281527f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff166020820152338183015290517fc8a211cc64b6ed1b50595a9fcb1932b6d1e5a6e8ef15b60e5b1f988ea9086bba9181900360600190a17f38e04cbeb8c10f8f568618aa75be0f10b6729b8b4237743b4de20cbcde2839ee817f0000000000000000000000000000000000000000000000000000000000000000337f00000000000000000000000000000000000000000000000000000000000000006040516103b89493929190610707565b60405180910390a160017f000000000000000000000000000000000000000000000000000000000000000060018111156103f4576103f461064a565b0361050d5760007f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff168260405160006040518083038185875af1925050503d8060008114610473576040519150601f19603f3d011682016040523d82523d6000602084013e610478565b606091505b5050905080610509576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603060248201527f4665655661756c743a206661696c656420746f2073656e642045544820746f2060448201527f4c322066656520726563697069656e740000000000000000000000000000000060648201526084016102ab565b5050565b604080516020810182526000815290517fe11013dd0000000000000000000000000000000000000000000000000000000081527342000000000000000000000000000000000000109163e11013dd918491610590917f0000000000000000000000000000000000000000000000000000000000000000916188b891600401610748565b6000604051808303818588803b1580156105a957600080fd5b505af11580156105bd573d6000803e3d6000fd5b505050505050565b6000815180845260005b818110156105eb576020818501810151868301820152016105cf565b818111156105fd576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60208152600061064360208301846105c5565b9392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b600281106106b0577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b9052565b602081016106c28284610679565b92915050565b60008219821115610702577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b500190565b84815273ffffffffffffffffffffffffffffffffffffffff8481166020830152831660408201526080810161073f6060830184610679565b95945050505050565b73ffffffffffffffffffffffffffffffffffffffff8416815263ffffffff8316602082015260606040820152600061073f60608301846105c556fea164736f6c634300080f000a" func init() { if err := json.Unmarshal([]byte(BaseFeeVaultStorageLayoutJSON), BaseFeeVaultStorageLayout); err != nil { diff --git a/op-bindings/bindings/eas.go b/op-bindings/bindings/eas.go index 623166d4ec639..1b90df7089d23 100644 --- a/op-bindings/bindings/eas.go +++ b/op-bindings/bindings/eas.go @@ -128,7 +128,7 @@ type Signature struct { // EASMetaData contains all meta data concerning the EAS contract. var EASMetaData = &bind.MetaData{ ABI: "[{\"inputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"AccessDenied\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"AlreadyRevoked\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"AlreadyRevokedOffchain\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"AlreadyTimestamped\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DeadlineExpired\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientValue\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidAttestation\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidAttestations\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidExpirationTime\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidLength\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidNonce\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidOffset\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidRegistry\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidRevocation\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidRevocations\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSchema\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSignature\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidVerifier\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"Irrevocable\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NotFound\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NotPayable\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"WrongSchema\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"attester\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"uid\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"schemaUID\",\"type\":\"bytes32\"}],\"name\":\"Attested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldNonce\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newNonce\",\"type\":\"uint256\"}],\"name\":\"NonceIncreased\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"attester\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"uid\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"schemaUID\",\"type\":\"bytes32\"}],\"name\":\"Revoked\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"revoker\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"data\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"timestamp\",\"type\":\"uint64\"}],\"name\":\"RevokedOffchain\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"data\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"timestamp\",\"type\":\"uint64\"}],\"name\":\"Timestamped\",\"type\":\"event\"},{\"inputs\":[{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"schema\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"expirationTime\",\"type\":\"uint64\"},{\"internalType\":\"bool\",\"name\":\"revocable\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"refUID\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"internalType\":\"structAttestationRequestData\",\"name\":\"data\",\"type\":\"tuple\"}],\"internalType\":\"structAttestationRequest\",\"name\":\"request\",\"type\":\"tuple\"}],\"name\":\"attest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"schema\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"expirationTime\",\"type\":\"uint64\"},{\"internalType\":\"bool\",\"name\":\"revocable\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"refUID\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"internalType\":\"structAttestationRequestData\",\"name\":\"data\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint8\",\"name\":\"v\",\"type\":\"uint8\"},{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"s\",\"type\":\"bytes32\"}],\"internalType\":\"structSignature\",\"name\":\"signature\",\"type\":\"tuple\"},{\"internalType\":\"address\",\"name\":\"attester\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"deadline\",\"type\":\"uint64\"}],\"internalType\":\"structDelegatedAttestationRequest\",\"name\":\"delegatedRequest\",\"type\":\"tuple\"}],\"name\":\"attestByDelegation\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAttestTypeHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"uid\",\"type\":\"bytes32\"}],\"name\":\"getAttestation\",\"outputs\":[{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"uid\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"schema\",\"type\":\"bytes32\"},{\"internalType\":\"uint64\",\"name\":\"time\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"expirationTime\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"revocationTime\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"refUID\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"attester\",\"type\":\"address\"},{\"internalType\":\"bool\",\"name\":\"revocable\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"internalType\":\"structAttestation\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getDomainSeparator\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getName\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"getNonce\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"revoker\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"data\",\"type\":\"bytes32\"}],\"name\":\"getRevokeOffchain\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getRevokeTypeHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getSchemaRegistry\",\"outputs\":[{\"internalType\":\"contractISchemaRegistry\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"data\",\"type\":\"bytes32\"}],\"name\":\"getTimestamp\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"newNonce\",\"type\":\"uint256\"}],\"name\":\"increaseNonce\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"uid\",\"type\":\"bytes32\"}],\"name\":\"isAttestationValid\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"schema\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"expirationTime\",\"type\":\"uint64\"},{\"internalType\":\"bool\",\"name\":\"revocable\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"refUID\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"internalType\":\"structAttestationRequestData[]\",\"name\":\"data\",\"type\":\"tuple[]\"}],\"internalType\":\"structMultiAttestationRequest[]\",\"name\":\"multiRequests\",\"type\":\"tuple[]\"}],\"name\":\"multiAttest\",\"outputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"}],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"schema\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"expirationTime\",\"type\":\"uint64\"},{\"internalType\":\"bool\",\"name\":\"revocable\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"refUID\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"internalType\":\"structAttestationRequestData[]\",\"name\":\"data\",\"type\":\"tuple[]\"},{\"components\":[{\"internalType\":\"uint8\",\"name\":\"v\",\"type\":\"uint8\"},{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"s\",\"type\":\"bytes32\"}],\"internalType\":\"structSignature[]\",\"name\":\"signatures\",\"type\":\"tuple[]\"},{\"internalType\":\"address\",\"name\":\"attester\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"deadline\",\"type\":\"uint64\"}],\"internalType\":\"structMultiDelegatedAttestationRequest[]\",\"name\":\"multiDelegatedRequests\",\"type\":\"tuple[]\"}],\"name\":\"multiAttestByDelegation\",\"outputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"}],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"schema\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"uid\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"internalType\":\"structRevocationRequestData[]\",\"name\":\"data\",\"type\":\"tuple[]\"}],\"internalType\":\"structMultiRevocationRequest[]\",\"name\":\"multiRequests\",\"type\":\"tuple[]\"}],\"name\":\"multiRevoke\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"schema\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"uid\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"internalType\":\"structRevocationRequestData[]\",\"name\":\"data\",\"type\":\"tuple[]\"},{\"components\":[{\"internalType\":\"uint8\",\"name\":\"v\",\"type\":\"uint8\"},{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"s\",\"type\":\"bytes32\"}],\"internalType\":\"structSignature[]\",\"name\":\"signatures\",\"type\":\"tuple[]\"},{\"internalType\":\"address\",\"name\":\"revoker\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"deadline\",\"type\":\"uint64\"}],\"internalType\":\"structMultiDelegatedRevocationRequest[]\",\"name\":\"multiDelegatedRequests\",\"type\":\"tuple[]\"}],\"name\":\"multiRevokeByDelegation\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"data\",\"type\":\"bytes32[]\"}],\"name\":\"multiRevokeOffchain\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"data\",\"type\":\"bytes32[]\"}],\"name\":\"multiTimestamp\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"schema\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"uid\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"internalType\":\"structRevocationRequestData\",\"name\":\"data\",\"type\":\"tuple\"}],\"internalType\":\"structRevocationRequest\",\"name\":\"request\",\"type\":\"tuple\"}],\"name\":\"revoke\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"schema\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"uid\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"internalType\":\"structRevocationRequestData\",\"name\":\"data\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint8\",\"name\":\"v\",\"type\":\"uint8\"},{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"s\",\"type\":\"bytes32\"}],\"internalType\":\"structSignature\",\"name\":\"signature\",\"type\":\"tuple\"},{\"internalType\":\"address\",\"name\":\"revoker\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"deadline\",\"type\":\"uint64\"}],\"internalType\":\"structDelegatedRevocationRequest\",\"name\":\"delegatedRequest\",\"type\":\"tuple\"}],\"name\":\"revokeByDelegation\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"data\",\"type\":\"bytes32\"}],\"name\":\"revokeOffchain\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"data\",\"type\":\"bytes32\"}],\"name\":\"timestamp\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"version\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", - Bin: "0x61016060405234801561001157600080fd5b50604080518082018252600381526245415360e81b60208083019182528351808501855260058152640312e322e360dc1b908201529151812060e08190527fe374587661e69268352d25204d81b23ce801573f4b09f3545e69536dc085a37a6101008190524660a081815286517f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f818801819052818901959095526060810193909352608080840192909252308382018190528751808503909201825260c093840190975280519501949094209093529290915261012091909152516101405260805160a05160c05160e05161010051610120516101405161454d61014b600039600061073701526000612753015260006127a20152600061277d015260006126d6015260006127000152600061272a015261454d6000f3fe60806040526004361061018b5760003560e01c806395411525116100d6578063d45c44351161007f578063ed24911d11610059578063ed24911d146104fd578063f10b5cc814610512578063f17325e71461054157600080fd5b8063d45c443514610467578063e30bb5631461049e578063e71ff365146104dd57600080fd5b8063b469318d116100b0578063b469318d146103ba578063b83010d314610414578063cf190f341461044757600080fd5b80639541152514610367578063a3112a641461037a578063a6d4dbc7146103a757600080fd5b806344adc90e116101385780634d003070116101125780634d003070146102de57806354fd4d50146102fe57806379f7573a1461034757600080fd5b806344adc90e1461029857806346926267146102b85780634cb7e9e5146102cb57600080fd5b806317d7de7c1161016957806317d7de7c146102205780632d0335ab146102425780633c0427151461028557600080fd5b80630eabf6601461019057806312b11a17146101a557806313893f61146101e7575b600080fd5b6101a361019e366004613497565b610554565b005b3480156101b157600080fd5b507ff83bb2b0ede93a840239f7e701a54d9bc35f03701f51ae153d601c6947ff3d3f5b6040519081526020015b60405180910390f35b3480156101f357600080fd5b50610207610202366004613497565b6106eb565b60405167ffffffffffffffff90911681526020016101de565b34801561022c57600080fd5b50610235610730565b6040516101de9190613547565b34801561024e57600080fd5b506101d461025d36600461358c565b73ffffffffffffffffffffffffffffffffffffffff1660009081526020819052604090205490565b6101d46102933660046135a9565b610760565b6102ab6102a6366004613497565b610863565b6040516101de91906135e4565b6101a36102c6366004613628565b6109e4565b6101a36102d9366004613497565b610a68565b3480156102ea57600080fd5b506102076102f9366004613640565b610b4b565b34801561030a57600080fd5b506102356040518060400160405280600581526020017f312e332e3000000000000000000000000000000000000000000000000000000081525081565b34801561035357600080fd5b506101a3610362366004613640565b610b58565b6102ab610375366004613497565b610bef565b34801561038657600080fd5b5061039a610395366004613640565b610e62565b6040516101de9190613740565b6101a36103b5366004613753565b611025565b3480156103c657600080fd5b506102076103d5366004613766565b73ffffffffffffffffffffffffffffffffffffffff919091166000908152603460209081526040808320938352929052205467ffffffffffffffff1690565b34801561042057600080fd5b507f2d4116d8c9824e4c316453e5c2843a1885580374159ce8768603c49085ef424c6101d4565b34801561045357600080fd5b50610207610462366004613640565b6110ca565b34801561047357600080fd5b50610207610482366004613640565b60009081526033602052604090205467ffffffffffffffff1690565b3480156104aa57600080fd5b506104cd6104b9366004613640565b600090815260326020526040902054151590565b60405190151581526020016101de565b3480156104e957600080fd5b506102076104f8366004613497565b6110d8565b34801561050957600080fd5b506101d4611110565b34801561051e57600080fd5b5060405173420000000000000000000000000000000000002081526020016101de565b6101d461054f366004613792565b61111a565b348160005b818110156106e4577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82018114600086868481811061059a5761059a6137cd565b90506020028101906105ac91906137fc565b6105b590613a92565b60208101518051919250908015806105d257508260400151518114155b15610609576040517f947d5a8400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b818110156106ad576106a56040518060a001604052808660000151815260200185848151811061063e5761063e6137cd565b6020026020010151815260200186604001518481518110610661576106616137cd565b60200260200101518152602001866060015173ffffffffffffffffffffffffffffffffffffffff168152602001866080015167ffffffffffffffff168152506111d8565b60010161060c565b506106c383600001518385606001518a886113c5565b6106cd9088613bbc565b9650505050506106dd8160010190565b9050610559565b5050505050565b60004282825b818110156107245761071c3387878481811061070f5761070f6137cd565b90506020020135856119f4565b6001016106f1565b50909150505b92915050565b606061075b7f0000000000000000000000000000000000000000000000000000000000000000611af3565b905090565b600061077361076e83613cf1565b611c81565b604080516001808252818301909252600091816020015b6040805160c081018252600080825260208083018290529282018190526060808301829052608083015260a082015282527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90920191018161078a5790505090506107f86020840184613d6c565b61080190613da0565b81600081518110610814576108146137cd565b602090810291909101015261083d83358261083560c0870160a0880161358c565b346001611dfe565b60200151600081518110610853576108536137cd565b6020026020010151915050919050565b60608160008167ffffffffffffffff8111156108815761088161383a565b6040519080825280602002602001820160405280156108b457816020015b606081526020019060019003908161089f5790505b509050600034815b848110156109ce577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff85018114368989848181106108fc576108fc6137cd565b905060200281019061090e9190613dac565b905061091d6020820182613de0565b9050600003610958576040517f947d5a8400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061097d823561096c6020850185613de0565b61097591613e48565b338887611dfe565b805190915061098c9086613bbc565b945080602001518785815181106109a5576109a56137cd565b6020026020010181905250806020015151860195505050506109c78160010190565b90506108bc565b506109d98383612510565b979650505050505050565b604080516001808252818301909252600091816020015b60408051808201909152600080825260208201528152602001906001900390816109fb579050509050610a3636839003830160208401613ebc565b81600081518110610a4957610a496137cd565b6020908102919091010152610a63823582333460016113c5565b505050565b348160005b818110156106e4577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8201811436868684818110610aad57610aad6137cd565b9050602002810190610abf9190613dac565b9050610b2c8135610ad36020840184613ed8565b808060200260200160405190810160405280939291908181526020016000905b82821015610b1f57610b1060408302860136819003810190613ebc565b81526020019060010190610af3565b50505050503388866113c5565b610b369086613bbc565b94505050610b448160010190565b9050610a6d565b60004261072a83826125fa565b33600090815260208190526040902054808211610ba1576040517f756688fe00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152602081815260409182902084905581518381529081018490527f57b09af877df9068fd60a69d7b21f5576b8b38955812d6ae4ac52942f1e38fb7910160405180910390a15050565b60608160008167ffffffffffffffff811115610c0d57610c0d61383a565b604051908082528060200260200182016040528015610c4057816020015b6060815260200190600190039081610c2b5790505b509050600034815b848110156109ce577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8501811436898984818110610c8857610c886137cd565b9050602002810190610c9a91906137fc565b9050366000610cac6020840184613de0565b909250905080801580610ccd5750610cc76040850185613f40565b90508114155b15610d04576040517f947d5a8400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b81811015610de557610ddd6040518060a0016040528087600001358152602001868685818110610d3957610d396137cd565b9050602002810190610d4b9190613d6c565b610d5490613da0565b8152602001610d666040890189613f40565b85818110610d7657610d766137cd565b905060600201803603810190610d8c9190613fa7565b8152602001610da16080890160608a0161358c565b73ffffffffffffffffffffffffffffffffffffffff168152602001610dcc60a0890160808a01613fc3565b67ffffffffffffffff169052611c81565b600101610d07565b506000610e0e8535610df78587613e48565b610e076080890160608a0161358c565b8b8a611dfe565b8051909150610e1d9089613bbc565b975080602001518a8881518110610e3657610e366137cd565b602002602001018190525080602001515189019850505050505050610e5b8160010190565b9050610c48565b604080516101408101825260008082526020820181905291810182905260608082018390526080820183905260a0820183905260c0820183905260e0820183905261010082019290925261012081019190915260008281526032602090815260409182902082516101408101845281548152600182015492810192909252600281015467ffffffffffffffff808216948401949094526801000000000000000081048416606084015270010000000000000000000000000000000090049092166080820152600382015460a0820152600482015473ffffffffffffffffffffffffffffffffffffffff90811660c0830152600583015490811660e083015274010000000000000000000000000000000000000000900460ff16151561010082015260068201805491929161012084019190610f9c90613fde565b80601f0160208091040260200160405190810160405280929190818152602001828054610fc890613fde565b80156110155780601f10610fea57610100808354040283529160200191611015565b820191906000526020600020905b815481529060010190602001808311610ff857829003601f168201915b5050505050815250509050919050565b61103c6110373683900383018361402b565b6111d8565b604080516001808252818301909252600091816020015b604080518082019091526000808252602082015281526020019060019003908161105357905050905061108e36839003830160208401613ebc565b816000815181106110a1576110a16137cd565b6020908102919091010152610a638235826110c260e0860160c0870161358c565b3460016113c5565b60004261072a3384836119f4565b60004282825b81811015610724576111088686838181106110fb576110fb6137cd565b90506020020135846125fa565b6001016110de565b600061075b6126bc565b604080516001808252818301909252600091829190816020015b6040805160c081018252600080825260208083018290529282018190526060808301829052608083015260a082015282527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9092019101816111345790505090506111a26020840184613d6c565b6111ab90613da0565b816000815181106111be576111be6137cd565b602090810291909101015261083d83358233346001611dfe565b608081015167ffffffffffffffff161580159061120c57504267ffffffffffffffff16816080015167ffffffffffffffff16105b15611243576040517f1ab7da6b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6020808201516040808401518451835184860151606088015173ffffffffffffffffffffffffffffffffffffffff166000908152968790529386208054959693959394611313947f2d4116d8c9824e4c316453e5c2843a1885580374159ce8768603c49085ef424c949392876112b883614099565b909155506080808b015160408051602081019890985287019590955260608601939093529184015260a083015267ffffffffffffffff1660c082015260e0015b604051602081830303815290604052805190602001206127f0565b905061138984606001518284602001518560400151866000015160405160200161137593929190928352602083019190915260f81b7fff0000000000000000000000000000000000000000000000000000000000000016604082015260410190565b604051602081830303815290604052612803565b6113bf576040517f8baa579f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b50505050565b6040517fa2ea7c6e0000000000000000000000000000000000000000000000000000000081526004810186905260009081907342000000000000000000000000000000000000209063a2ea7c6e90602401600060405180830381865afa158015611433573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016820160405261147991908101906140d1565b80519091506114b4576040517fbf37b20e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b855160008167ffffffffffffffff8111156114d1576114d161383a565b60405190808252806020026020018201604052801561157057816020015b60408051610140810182526000808252602080830182905292820181905260608083018290526080830182905260a0830182905260c0830182905260e0830182905261010083019190915261012082015282527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9092019101816114ef5790505b50905060008267ffffffffffffffff81111561158e5761158e61383a565b6040519080825280602002602001820160405280156115b7578160200160208202803683370190505b50905060005b838110156119d65760008a82815181106115d9576115d96137cd565b6020908102919091018101518051600090815260329092526040909120805491925090611632576040517fc5723b5100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8c81600101541461166f576040517fbf37b20e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600581015473ffffffffffffffffffffffffffffffffffffffff8c81169116146116c5576040517f4ca8886700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600581015474010000000000000000000000000000000000000000900460ff1661171b576040517f157bd4c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6002810154700100000000000000000000000000000000900467ffffffffffffffff1615611775576040517f905e710700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b426002820180547fffffffffffffffff0000000000000000ffffffffffffffffffffffffffffffff811670010000000000000000000000000000000067ffffffffffffffff948516810291821793849055604080516101408101825287548152600188015460208201529386169286169290921791830191909152680100000000000000008304841660608301529091049091166080820152600382015460a0820152600482015473ffffffffffffffffffffffffffffffffffffffff90811660c0830152600583015490811660e083015274010000000000000000000000000000000000000000900460ff161515610100820152600682018054839161012084019161188190613fde565b80601f01602080910402602001604051908101604052809291908181526020018280546118ad90613fde565b80156118fa5780601f106118cf576101008083540402835291602001916118fa565b820191906000526020600020905b8154815290600101906020018083116118dd57829003601f168201915b505050505081525050858481518110611915576119156137cd565b60200260200101819052508160200151848481518110611937576119376137cd565b6020026020010181815250508c8b73ffffffffffffffffffffffffffffffffffffffff1686858151811061196d5761196d6137cd565b602002602001015160c0015173ffffffffffffffffffffffffffffffffffffffff167ff930a6e2523c9cc298691873087a740550b8fc85a0680830414c148ed927f61585600001516040516119c491815260200190565b60405180910390a450506001016115bd565b506119e684838360018b8b6129d2565b9a9950505050505050505050565b73ffffffffffffffffffffffffffffffffffffffff83166000908152603460209081526040808320858452918290529091205467ffffffffffffffff1615611a68576040517fec9d6eeb00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008381526020829052604080822080547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000001667ffffffffffffffff861690811790915590519091859173ffffffffffffffffffffffffffffffffffffffff8816917f92a1f7a41a7c585a8b09e25b195e225b1d43248daca46b0faf9e0792777a222991a450505050565b604080516020808252818301909252606091600091906020820181803683370190505090506000805b6020811015611bbe576000858260208110611b3957611b396137cd565b1a60f81b90507fff000000000000000000000000000000000000000000000000000000000000008116600003611b6f5750611bbe565b80848481518110611b8257611b826137cd565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053505060019182019101611b1c565b5060008167ffffffffffffffff811115611bda57611bda61383a565b6040519080825280601f01601f191660200182016040528015611c04576020820181803683370190505b50905060005b82811015611c7857838181518110611c2457611c246137cd565b602001015160f81c60f81b828281518110611c4157611c416137cd565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350600101611c0a565b50949350505050565b608081015167ffffffffffffffff1615801590611cb557504267ffffffffffffffff16816080015167ffffffffffffffff16105b15611cec576040517f1ab7da6b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208082015160408084015184518351848601518486015160608088015160808901518051908b012060a08a0151928c015173ffffffffffffffffffffffffffffffffffffffff1660009081529a8b9052978a208054999a97999798611313987ff83bb2b0ede93a840239f7e701a54d9bc35f03701f51ae153d601c6947ff3d3f989796959491928b611d7e83614099565b909155506080808f015160408051602081019c909c528b019990995273ffffffffffffffffffffffffffffffffffffffff90971660608a015267ffffffffffffffff9586169689019690965292151560a088015260c087019190915260e086015261010085015261012084019190915216610140820152610160016112f8565b60408051808201909152600081526060602082015284516040805180820190915260008152606060208201528167ffffffffffffffff811115611e4357611e4361383a565b604051908082528060200260200182016040528015611e6c578160200160208202803683370190505b5060208201526040517fa2ea7c6e000000000000000000000000000000000000000000000000000000008152600481018990526000907342000000000000000000000000000000000000209063a2ea7c6e90602401600060405180830381865afa158015611ede573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052611f2491908101906140d1565b8051909150611f5f576040517fbf37b20e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008367ffffffffffffffff811115611f7a57611f7a61383a565b60405190808252806020026020018201604052801561201957816020015b60408051610140810182526000808252602080830182905292820181905260608083018290526080830182905260a0830182905260c0830182905260e0830182905261010083019190915261012082015282527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff909201910181611f985790505b50905060008467ffffffffffffffff8111156120375761203761383a565b604051908082528060200260200182016040528015612060578160200160208202803683370190505b50905060005b858110156124ef5760008b8281518110612082576120826137cd565b60200260200101519050600067ffffffffffffffff16816020015167ffffffffffffffff16141580156120cd57504267ffffffffffffffff16816020015167ffffffffffffffff1611155b15612104576040517f08e8b93700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8460400151158015612117575080604001515b1561214e576040517f157bd4c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006040518061014001604052806000801b81526020018f81526020016121724290565b67ffffffffffffffff168152602001836020015167ffffffffffffffff168152602001600067ffffffffffffffff16815260200183606001518152602001836000015173ffffffffffffffffffffffffffffffffffffffff1681526020018d73ffffffffffffffffffffffffffffffffffffffff16815260200183604001511515815260200183608001518152509050600080600090505b6122148382612dc3565b600081815260326020526040902054909250156122335760010161220a565b81835260008281526032602090815260409182902085518155908501516001820155908401516002820180546060870151608088015167ffffffffffffffff908116700100000000000000000000000000000000027fffffffffffffffff0000000000000000ffffffffffffffffffffffffffffffff92821668010000000000000000027fffffffffffffffffffffffffffffffff000000000000000000000000000000009094169190951617919091171691909117905560a0840151600382015560c084015160048201805473ffffffffffffffffffffffffffffffffffffffff9283167fffffffffffffffffffffffff000000000000000000000000000000000000000090911617905560e0850151600583018054610100880151151574010000000000000000000000000000000000000000027fffffffffffffffffffffff000000000000000000000000000000000000000000909116929093169190911791909117905561012084015184919060068201906123b390826141f7565b50505060608401511561240a57606084015160009081526032602052604090205461240a576040517fc5723b5100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8287868151811061241d5761241d6137cd565b60200260200101819052508360a0015186868151811061243f5761243f6137cd565b6020026020010181815250508189602001518681518110612462576124626137cd565b6020026020010181815250508f8e73ffffffffffffffffffffffffffffffffffffffff16856000015173ffffffffffffffffffffffffffffffffffffffff167f8bf46bf4cfd674fa735a3d63ec1c9ad4153f033c290341f3a588b75685141b35856040516124d291815260200190565b60405180910390a4505050506124e88160010190565b9050612066565b506124ff83838360008c8c6129d2565b845250919998505050505050505050565b606060008267ffffffffffffffff81111561252d5761252d61383a565b604051908082528060200260200182016040528015612556578160200160208202803683370190505b508451909150600090815b818110156125ef57600087828151811061257d5761257d6137cd565b6020026020010151905060008151905060005b818110156125db578281815181106125aa576125aa6137cd565b60200260200101518787815181106125c4576125c46137cd565b602090810291909101015260019586019501612590565b5050506125e88160010190565b9050612561565b509195945050505050565b60008281526033602052604090205467ffffffffffffffff161561264a576040517f2e26794600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008281526033602052604080822080547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000001667ffffffffffffffff85169081179091559051909184917f5aafceeb1c7ad58e4a84898bdee37c02c0fc46e7d24e6b60e8209449f183459f9190a35050565b60003073ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614801561272257507f000000000000000000000000000000000000000000000000000000000000000046145b1561274c57507f000000000000000000000000000000000000000000000000000000000000000090565b50604080517f00000000000000000000000000000000000000000000000000000000000000006020808301919091527f0000000000000000000000000000000000000000000000000000000000000000828401527f000000000000000000000000000000000000000000000000000000000000000060608301524660808301523060a0808401919091528351808403909101815260c0909201909252805191012090565b600061072a6127fd6126bc565b83612e22565b60008060006128128585612e64565b9092509050600081600481111561282b5761282b614311565b14801561286357508573ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16145b15612873576001925050506129cb565b6000808773ffffffffffffffffffffffffffffffffffffffff16631626ba7e60e01b88886040516024016128a8929190614340565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009094169390931790925290516129319190614361565b600060405180830381855afa9150503d806000811461296c576040519150601f19603f3d011682016040523d82523d6000602084013e612971565b606091505b5091509150818015612984575080516020145b80156129c4575080517f1626ba7e00000000000000000000000000000000000000000000000000000000906129c29083016020908101908401614373565b145b9450505050505b9392505050565b84516000906001819003612a2a57612a2288886000815181106129f7576129f76137cd565b602002602001015188600081518110612a1257612a126137cd565b6020026020010151888888612ea9565b915050612db9565b602088015173ffffffffffffffffffffffffffffffffffffffff8116612acb5760005b82811015612ab057878181518110612a6757612a676137cd565b6020026020010151600014612aa8576040517f1574f9f300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600101612a4d565b508315612ac057612ac0856131c8565b600092505050612db9565b6000808273ffffffffffffffffffffffffffffffffffffffff1663ce46e0466040518163ffffffff1660e01b8152600401602060405180830381865afa158015612b19573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612b3d919061438c565b905060005b84811015612bfa5760008a8281518110612b5e57612b5e6137cd565b6020026020010151905080600003612b765750612bf2565b82612bad576040517f1574f9f300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b88811115612be7576040517f1101129400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b978890039792909201915b600101612b42565b508715612cd5576040517f88e5b2d900000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8416906388e5b2d9908490612c57908e908e906004016143a9565b60206040518083038185885af1158015612c75573d6000803e3d6000fd5b50505050506040513d601f19601f82011682018060405250810190612c9a919061438c565b612cd0576040517fbf2f3a8b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b612da4565b6040517f91db0b7e00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8416906391db0b7e908490612d2b908e908e906004016143a9565b60206040518083038185885af1158015612d49573d6000803e3d6000fd5b50505050506040513d601f19601f82011682018060405250810190612d6e919061438c565b612da4576040517fe8bee83900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8515612db357612db3876131c8565b50925050505b9695505050505050565b60208083015160c084015160e0850151604080870151606088015161010089015160a08a01516101208b01519451600099612e0499989796918c9101614462565b60405160208183030381529060405280519060200120905092915050565b6040517f190100000000000000000000000000000000000000000000000000000000000060208201526022810183905260428101829052600090606201612e04565b6000808251604103612e9a5760208301516040840151606085015160001a612e8e878285856131db565b94509450505050612ea2565b506000905060025b9250929050565b602086015160009073ffffffffffffffffffffffffffffffffffffffff8116612f1d578515612f04576040517f1574f9f300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8215612f1357612f13846131c8565b6000915050612db9565b8515613008578073ffffffffffffffffffffffffffffffffffffffff1663ce46e0466040518163ffffffff1660e01b8152600401602060405180830381865afa158015612f6e573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612f92919061438c565b612fc8576040517f1574f9f300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b83861115613002576040517f1101129400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b85840393505b84156130e0576040517fe49617e100000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82169063e49617e1908890613062908b90600401613740565b60206040518083038185885af1158015613080573d6000803e3d6000fd5b50505050506040513d601f19601f820116820180604052508101906130a5919061438c565b6130db576040517fccf3bb2700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6131ad565b6040517fe60c350500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82169063e60c3505908890613134908b90600401613740565b60206040518083038185885af1158015613152573d6000803e3d6000fd5b50505050506040513d601f19601f82011682018060405250810190613177919061438c565b6131ad576040517fbd8ba84d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b82156131bc576131bc846131c8565b50939695505050505050565b80156131d8576131d833826132f3565b50565b6000807f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a083111561321257506000905060036132ea565b8460ff16601b1415801561322a57508460ff16601c14155b1561323b57506000905060046132ea565b6040805160008082526020820180845289905260ff881692820192909252606081018690526080810185905260019060a0016020604051602081039080840390855afa15801561328f573d6000803e3d6000fd5b50506040517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0015191505073ffffffffffffffffffffffffffffffffffffffff81166132e3576000600192509250506132ea565b9150600090505b94509492505050565b80471015613362576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a20696e73756666696369656e742062616c616e636500000060448201526064015b60405180910390fd5b60008273ffffffffffffffffffffffffffffffffffffffff168260405160006040518083038185875af1925050503d80600081146133bc576040519150601f19603f3d011682016040523d82523d6000602084013e6133c1565b606091505b5050905080610a63576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603a60248201527f416464726573733a20756e61626c6520746f2073656e642076616c75652c207260448201527f6563697069656e74206d617920686176652072657665727465640000000000006064820152608401613359565b60008083601f84011261346457600080fd5b50813567ffffffffffffffff81111561347c57600080fd5b6020830191508360208260051b8501011115612ea257600080fd5b600080602083850312156134aa57600080fd5b823567ffffffffffffffff8111156134c157600080fd5b6134cd85828601613452565b90969095509350505050565b60005b838110156134f45781810151838201526020016134dc565b50506000910152565b600081518084526135158160208601602086016134d9565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b6020815260006129cb60208301846134fd565b73ffffffffffffffffffffffffffffffffffffffff811681146131d857600080fd5b80356135878161355a565b919050565b60006020828403121561359e57600080fd5b81356129cb8161355a565b6000602082840312156135bb57600080fd5b813567ffffffffffffffff8111156135d257600080fd5b820160e081850312156129cb57600080fd5b6020808252825182820181905260009190848201906040850190845b8181101561361c57835183529284019291840191600101613600565b50909695505050505050565b60006060828403121561363a57600080fd5b50919050565b60006020828403121561365257600080fd5b5035919050565b600061014082518452602083015160208501526040830151613687604086018267ffffffffffffffff169052565b5060608301516136a3606086018267ffffffffffffffff169052565b5060808301516136bf608086018267ffffffffffffffff169052565b5060a083015160a085015260c08301516136f160c086018273ffffffffffffffffffffffffffffffffffffffff169052565b5060e083015161371960e086018273ffffffffffffffffffffffffffffffffffffffff169052565b506101008381015115159085015261012080840151818601839052612db9838701826134fd565b6020815260006129cb6020830184613659565b6000610100828403121561363a57600080fd5b6000806040838503121561377957600080fd5b82356137848161355a565b946020939093013593505050565b6000602082840312156137a457600080fd5b813567ffffffffffffffff8111156137bb57600080fd5b8201604081850312156129cb57600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600082357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff6183360301811261383057600080fd5b9190910192915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60405160a0810167ffffffffffffffff8111828210171561388c5761388c61383a565b60405290565b60405160c0810167ffffffffffffffff8111828210171561388c5761388c61383a565b6040516080810167ffffffffffffffff8111828210171561388c5761388c61383a565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff8111828210171561391f5761391f61383a565b604052919050565b600067ffffffffffffffff8211156139415761394161383a565b5060051b60200190565b60006040828403121561395d57600080fd5b6040516040810181811067ffffffffffffffff821117156139805761398061383a565b604052823581526020928301359281019290925250919050565b6000606082840312156139ac57600080fd5b6040516060810181811067ffffffffffffffff821117156139cf576139cf61383a565b604052905080823560ff811681146139e657600080fd5b8082525060208301356020820152604083013560408201525092915050565b600082601f830112613a1657600080fd5b81356020613a2b613a2683613927565b6138d8565b82815260609283028501820192828201919087851115613a4a57600080fd5b8387015b85811015613a6d57613a60898261399a565b8452928401928101613a4e565b5090979650505050505050565b803567ffffffffffffffff8116811461358757600080fd5b600060a08236031215613aa457600080fd5b613aac613869565b8235815260208084013567ffffffffffffffff80821115613acc57600080fd5b9085019036601f830112613adf57600080fd5b8135613aed613a2682613927565b81815260069190911b83018401908481019036831115613b0c57600080fd5b938501935b82851015613b3557613b23368661394b565b82528582019150604085019450613b11565b80868801525050506040860135925080831115613b5157600080fd5b5050613b5f36828601613a05565b604083015250613b716060840161357c565b6060820152613b8260808401613a7a565b608082015292915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b8181038181111561072a5761072a613b8d565b80151581146131d857600080fd5b600067ffffffffffffffff821115613bf757613bf761383a565b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01660200190565b600060c08284031215613c3557600080fd5b613c3d613892565b90508135613c4a8161355a565b81526020613c59838201613a7a565b818301526040830135613c6b81613bcf565b604083015260608381013590830152608083013567ffffffffffffffff811115613c9457600080fd5b8301601f81018513613ca557600080fd5b8035613cb3613a2682613bdd565b8181528684838501011115613cc757600080fd5b818484018583013760008483830101528060808601525050505060a082013560a082015292915050565b600060e08236031215613d0357600080fd5b613d0b613869565b82358152602083013567ffffffffffffffff811115613d2957600080fd5b613d3536828601613c23565b602083015250613d48366040850161399a565b604082015260a0830135613d5b8161355a565b6060820152613b8260c08401613a7a565b600082357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff4183360301811261383057600080fd5b600061072a3683613c23565b600082357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc183360301811261383057600080fd5b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112613e1557600080fd5b83018035915067ffffffffffffffff821115613e3057600080fd5b6020019150600581901b3603821315612ea257600080fd5b6000613e56613a2684613927565b80848252602080830192508560051b850136811115613e7457600080fd5b855b81811015613eb057803567ffffffffffffffff811115613e965760008081fd5b613ea236828a01613c23565b865250938201938201613e76565b50919695505050505050565b600060408284031215613ece57600080fd5b6129cb838361394b565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112613f0d57600080fd5b83018035915067ffffffffffffffff821115613f2857600080fd5b6020019150600681901b3603821315612ea257600080fd5b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112613f7557600080fd5b83018035915067ffffffffffffffff821115613f9057600080fd5b6020019150606081023603821315612ea257600080fd5b600060608284031215613fb957600080fd5b6129cb838361399a565b600060208284031215613fd557600080fd5b6129cb82613a7a565b600181811c90821680613ff257607f821691505b60208210810361363a577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b6000610100828403121561403e57600080fd5b614046613869565b82358152614057846020850161394b565b6020820152614069846060850161399a565b604082015260c083013561407c8161355a565b606082015261408d60e08401613a7a565b60808201529392505050565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036140ca576140ca613b8d565b5060010190565b600060208083850312156140e457600080fd5b825167ffffffffffffffff808211156140fc57600080fd5b908401906080828703121561411057600080fd5b6141186138b5565b82518152838301516141298161355a565b81850152604083015161413b81613bcf565b604082015260608301518281111561415257600080fd5b80840193505086601f84011261416757600080fd5b82519150614177613a2683613bdd565b828152878584860101111561418b57600080fd5b61419a838683018787016134d9565b60608201529695505050505050565b601f821115610a6357600081815260208120601f850160051c810160208610156141d05750805b601f850160051c820191505b818110156141ef578281556001016141dc565b505050505050565b815167ffffffffffffffff8111156142115761421161383a565b6142258161421f8454613fde565b846141a9565b602080601f83116001811461427857600084156142425750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b1785556141ef565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b828110156142c5578886015182559484019460019091019084016142a6565b508582101561430157878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b82815260406020820152600061435960408301846134fd565b949350505050565b600082516138308184602087016134d9565b60006020828403121561438557600080fd5b5051919050565b60006020828403121561439e57600080fd5b81516129cb81613bcf565b6000604082016040835280855180835260608501915060608160051b8601019250602080880160005b8381101561441e577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa088870301855261440c868351613659565b955093820193908201906001016143d2565b50508584038187015286518085528782019482019350915060005b8281101561445557845184529381019392810192600101614439565b5091979650505050505050565b89815260007fffffffffffffffffffffffffffffffffffffffff000000000000000000000000808b60601b166020840152808a60601b166034840152507fffffffffffffffff000000000000000000000000000000000000000000000000808960c01b166048840152808860c01b1660508401525085151560f81b605883015284605983015283516144fb8160798501602088016134d9565b80830190507fffffffff000000000000000000000000000000000000000000000000000000008460e01b166079820152607d81019150509a995050505050505050505056fea164736f6c6343000813000a", + Bin: "0x61016060405234801561001157600080fd5b50604080518082018252600381526245415360e81b60208083019182528351808501855260058152640312e332e360dc1b908201529151812060e08190527f6a08c3e203132c561752255a4d52ffae85bb9c5d33cb3291520dea1b843563896101008190524660a081815286517f8b73c3c69bb8fe3d512ecc4cf759cc79239f7b179b0ffacaa9a75d522b39400f818801819052818901959095526060810193909352608080840192909252308382018190528751808503909201825260c093840190975280519501949094209093529290915261012091909152516101405260805160a05160c05160e05161010051610120516101405161457e61014b600039600061073701526000612784015260006127d3015260006127ae01526000612707015260006127310152600061275b015261457e6000f3fe60806040526004361061018b5760003560e01c806395411525116100d6578063d45c44351161007f578063ed24911d11610059578063ed24911d146104fd578063f10b5cc814610512578063f17325e71461054157600080fd5b8063d45c443514610467578063e30bb5631461049e578063e71ff365146104dd57600080fd5b8063b469318d116100b0578063b469318d146103ba578063b83010d314610414578063cf190f341461044757600080fd5b80639541152514610367578063a3112a641461037a578063a6d4dbc7146103a757600080fd5b806344adc90e116101385780634d003070116101125780634d003070146102de57806354fd4d50146102fe57806379f7573a1461034757600080fd5b806344adc90e1461029857806346926267146102b85780634cb7e9e5146102cb57600080fd5b806317d7de7c1161016957806317d7de7c146102205780632d0335ab146102425780633c0427151461028557600080fd5b80630eabf6601461019057806312b11a17146101a557806313893f61146101e7575b600080fd5b6101a361019e3660046134c8565b610554565b005b3480156101b157600080fd5b507ffeb2925a02bae3dae48d424a0437a2b6ac939aa9230ddc55a1a76f065d9880765b6040519081526020015b60405180910390f35b3480156101f357600080fd5b506102076102023660046134c8565b6106eb565b60405167ffffffffffffffff90911681526020016101de565b34801561022c57600080fd5b50610235610730565b6040516101de9190613578565b34801561024e57600080fd5b506101d461025d3660046135bd565b73ffffffffffffffffffffffffffffffffffffffff1660009081526020819052604090205490565b6101d46102933660046135da565b610760565b6102ab6102a63660046134c8565b610863565b6040516101de9190613615565b6101a36102c6366004613659565b6109e4565b6101a36102d93660046134c8565b610a68565b3480156102ea57600080fd5b506102076102f9366004613671565b610b4b565b34801561030a57600080fd5b506102356040518060400160405280600581526020017f312e342e3000000000000000000000000000000000000000000000000000000081525081565b34801561035357600080fd5b506101a3610362366004613671565b610b58565b6102ab6103753660046134c8565b610bef565b34801561038657600080fd5b5061039a610395366004613671565b610e62565b6040516101de9190613771565b6101a36103b5366004613784565b611025565b3480156103c657600080fd5b506102076103d5366004613797565b73ffffffffffffffffffffffffffffffffffffffff919091166000908152603460209081526040808320938352929052205467ffffffffffffffff1690565b34801561042057600080fd5b507fb5d556f07587ec0f08cf386545cc4362c702a001650c2058002615ee5c9d1e756101d4565b34801561045357600080fd5b50610207610462366004613671565b6110ca565b34801561047357600080fd5b50610207610482366004613671565b60009081526033602052604090205467ffffffffffffffff1690565b3480156104aa57600080fd5b506104cd6104b9366004613671565b600090815260326020526040902054151590565b60405190151581526020016101de565b3480156104e957600080fd5b506102076104f83660046134c8565b6110d8565b34801561050957600080fd5b506101d4611110565b34801561051e57600080fd5b5060405173420000000000000000000000000000000000002081526020016101de565b6101d461054f3660046137c3565b61111a565b348160005b818110156106e4577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82018114600086868481811061059a5761059a6137fe565b90506020028101906105ac919061382d565b6105b590613ac3565b60208101518051919250908015806105d257508260400151518114155b15610609576040517f947d5a8400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b818110156106ad576106a56040518060a001604052808660000151815260200185848151811061063e5761063e6137fe565b6020026020010151815260200186604001518481518110610661576106616137fe565b60200260200101518152602001866060015173ffffffffffffffffffffffffffffffffffffffff168152602001866080015167ffffffffffffffff168152506111d8565b60010161060c565b506106c383600001518385606001518a886113e9565b6106cd9088613bed565b9650505050506106dd8160010190565b9050610559565b5050505050565b60004282825b818110156107245761071c3387878481811061070f5761070f6137fe565b9050602002013585611a18565b6001016106f1565b50909150505b92915050565b606061075b7f0000000000000000000000000000000000000000000000000000000000000000611b17565b905090565b600061077361076e83613d22565b611ca5565b604080516001808252818301909252600091816020015b6040805160c081018252600080825260208083018290529282018190526060808301829052608083015260a082015282527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90920191018161078a5790505090506107f86020840184613d9d565b61080190613dd1565b81600081518110610814576108146137fe565b602090810291909101015261083d83358261083560c0870160a088016135bd565b346001611e2f565b60200151600081518110610853576108536137fe565b6020026020010151915050919050565b60608160008167ffffffffffffffff8111156108815761088161386b565b6040519080825280602002602001820160405280156108b457816020015b606081526020019060019003908161089f5790505b509050600034815b848110156109ce577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff85018114368989848181106108fc576108fc6137fe565b905060200281019061090e9190613ddd565b905061091d6020820182613e11565b9050600003610958576040517f947d5a8400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061097d823561096c6020850185613e11565b61097591613e79565b338887611e2f565b805190915061098c9086613bed565b945080602001518785815181106109a5576109a56137fe565b6020026020010181905250806020015151860195505050506109c78160010190565b90506108bc565b506109d98383612541565b979650505050505050565b604080516001808252818301909252600091816020015b60408051808201909152600080825260208201528152602001906001900390816109fb579050509050610a3636839003830160208401613eed565b81600081518110610a4957610a496137fe565b6020908102919091010152610a63823582333460016113e9565b505050565b348160005b818110156106e4577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8201811436868684818110610aad57610aad6137fe565b9050602002810190610abf9190613ddd565b9050610b2c8135610ad36020840184613f09565b808060200260200160405190810160405280939291908181526020016000905b82821015610b1f57610b1060408302860136819003810190613eed565b81526020019060010190610af3565b50505050503388866113e9565b610b369086613bed565b94505050610b448160010190565b9050610a6d565b60004261072a838261262b565b33600090815260208190526040902054808211610ba1576040517f756688fe00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152602081815260409182902084905581518381529081018490527f57b09af877df9068fd60a69d7b21f5576b8b38955812d6ae4ac52942f1e38fb7910160405180910390a15050565b60608160008167ffffffffffffffff811115610c0d57610c0d61386b565b604051908082528060200260200182016040528015610c4057816020015b6060815260200190600190039081610c2b5790505b509050600034815b848110156109ce577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8501811436898984818110610c8857610c886137fe565b9050602002810190610c9a919061382d565b9050366000610cac6020840184613e11565b909250905080801580610ccd5750610cc76040850185613f71565b90508114155b15610d04576040517f947d5a8400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b81811015610de557610ddd6040518060a0016040528087600001358152602001868685818110610d3957610d396137fe565b9050602002810190610d4b9190613d9d565b610d5490613dd1565b8152602001610d666040890189613f71565b85818110610d7657610d766137fe565b905060600201803603810190610d8c9190613fd8565b8152602001610da16080890160608a016135bd565b73ffffffffffffffffffffffffffffffffffffffff168152602001610dcc60a0890160808a01613ff4565b67ffffffffffffffff169052611ca5565b600101610d07565b506000610e0e8535610df78587613e79565b610e076080890160608a016135bd565b8b8a611e2f565b8051909150610e1d9089613bed565b975080602001518a8881518110610e3657610e366137fe565b602002602001018190525080602001515189019850505050505050610e5b8160010190565b9050610c48565b604080516101408101825260008082526020820181905291810182905260608082018390526080820183905260a0820183905260c0820183905260e0820183905261010082019290925261012081019190915260008281526032602090815260409182902082516101408101845281548152600182015492810192909252600281015467ffffffffffffffff808216948401949094526801000000000000000081048416606084015270010000000000000000000000000000000090049092166080820152600382015460a0820152600482015473ffffffffffffffffffffffffffffffffffffffff90811660c0830152600583015490811660e083015274010000000000000000000000000000000000000000900460ff16151561010082015260068201805491929161012084019190610f9c9061400f565b80601f0160208091040260200160405190810160405280929190818152602001828054610fc89061400f565b80156110155780601f10610fea57610100808354040283529160200191611015565b820191906000526020600020905b815481529060010190602001808311610ff857829003601f168201915b5050505050815250509050919050565b61103c6110373683900383018361405c565b6111d8565b604080516001808252818301909252600091816020015b604080518082019091526000808252602082015281526020019060019003908161105357905050905061108e36839003830160208401613eed565b816000815181106110a1576110a16137fe565b6020908102919091010152610a638235826110c260e0860160c087016135bd565b3460016113e9565b60004261072a338483611a18565b60004282825b81811015610724576111088686838181106110fb576110fb6137fe565b905060200201358461262b565b6001016110de565b600061075b6126ed565b604080516001808252818301909252600091829190816020015b6040805160c081018252600080825260208083018290529282018190526060808301829052608083015260a082015282527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9092019101816111345790505090506111a26020840184613d9d565b6111ab90613dd1565b816000815181106111be576111be6137fe565b602090810291909101015261083d83358233346001611e2f565b608081015167ffffffffffffffff161580159061120c57504267ffffffffffffffff16816080015167ffffffffffffffff16105b15611243576040517f1ab7da6b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6020808201516040808401516060850151855184518587015173ffffffffffffffffffffffffffffffffffffffff84166000908152978890529487208054969794969495611337957fb5d556f07587ec0f08cf386545cc4362c702a001650c2058002615ee5c9d1e7595949392886112ba836140ca565b909155506080808c015160408051602081019990995273ffffffffffffffffffffffffffffffffffffffff9097169688019690965260608701949094529285019190915260a084015260c083015267ffffffffffffffff1660e0820152610100015b60405160208183030381529060405280519060200120612821565b90506113ad84606001518284602001518560400151866000015160405160200161139993929190928352602083019190915260f81b7fff0000000000000000000000000000000000000000000000000000000000000016604082015260410190565b604051602081830303815290604052612834565b6113e3576040517f8baa579f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b50505050565b6040517fa2ea7c6e0000000000000000000000000000000000000000000000000000000081526004810186905260009081907342000000000000000000000000000000000000209063a2ea7c6e90602401600060405180830381865afa158015611457573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016820160405261149d9190810190614102565b80519091506114d8576040517fbf37b20e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b855160008167ffffffffffffffff8111156114f5576114f561386b565b60405190808252806020026020018201604052801561159457816020015b60408051610140810182526000808252602080830182905292820181905260608083018290526080830182905260a0830182905260c0830182905260e0830182905261010083019190915261012082015282527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9092019101816115135790505b50905060008267ffffffffffffffff8111156115b2576115b261386b565b6040519080825280602002602001820160405280156115db578160200160208202803683370190505b50905060005b838110156119fa5760008a82815181106115fd576115fd6137fe565b6020908102919091018101518051600090815260329092526040909120805491925090611656576040517fc5723b5100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8c816001015414611693576040517fbf37b20e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600581015473ffffffffffffffffffffffffffffffffffffffff8c81169116146116e9576040517f4ca8886700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600581015474010000000000000000000000000000000000000000900460ff1661173f576040517f157bd4c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6002810154700100000000000000000000000000000000900467ffffffffffffffff1615611799576040517f905e710700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b426002820180547fffffffffffffffff0000000000000000ffffffffffffffffffffffffffffffff811670010000000000000000000000000000000067ffffffffffffffff948516810291821793849055604080516101408101825287548152600188015460208201529386169286169290921791830191909152680100000000000000008304841660608301529091049091166080820152600382015460a0820152600482015473ffffffffffffffffffffffffffffffffffffffff90811660c0830152600583015490811660e083015274010000000000000000000000000000000000000000900460ff16151561010082015260068201805483916101208401916118a59061400f565b80601f01602080910402602001604051908101604052809291908181526020018280546118d19061400f565b801561191e5780601f106118f35761010080835404028352916020019161191e565b820191906000526020600020905b81548152906001019060200180831161190157829003601f168201915b505050505081525050858481518110611939576119396137fe565b6020026020010181905250816020015184848151811061195b5761195b6137fe565b6020026020010181815250508c8b73ffffffffffffffffffffffffffffffffffffffff16868581518110611991576119916137fe565b602002602001015160c0015173ffffffffffffffffffffffffffffffffffffffff167ff930a6e2523c9cc298691873087a740550b8fc85a0680830414c148ed927f61585600001516040516119e891815260200190565b60405180910390a450506001016115e1565b50611a0a84838360018b8b612a03565b9a9950505050505050505050565b73ffffffffffffffffffffffffffffffffffffffff83166000908152603460209081526040808320858452918290529091205467ffffffffffffffff1615611a8c576040517fec9d6eeb00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008381526020829052604080822080547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000001667ffffffffffffffff861690811790915590519091859173ffffffffffffffffffffffffffffffffffffffff8816917f92a1f7a41a7c585a8b09e25b195e225b1d43248daca46b0faf9e0792777a222991a450505050565b604080516020808252818301909252606091600091906020820181803683370190505090506000805b6020811015611be2576000858260208110611b5d57611b5d6137fe565b1a60f81b90507fff000000000000000000000000000000000000000000000000000000000000008116600003611b935750611be2565b80848481518110611ba657611ba66137fe565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053505060019182019101611b40565b5060008167ffffffffffffffff811115611bfe57611bfe61386b565b6040519080825280601f01601f191660200182016040528015611c28576020820181803683370190505b50905060005b82811015611c9c57838181518110611c4857611c486137fe565b602001015160f81c60f81b828281518110611c6557611c656137fe565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350600101611c2e565b50949350505050565b608081015167ffffffffffffffff1615801590611cd957504267ffffffffffffffff16816080015167ffffffffffffffff16105b15611d10576040517f1ab7da6b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6020808201516040808401516060808601518651855186880151868801519488015160808901518051908b012060a08a015173ffffffffffffffffffffffffffffffffffffffff871660009081529b8c9052988b2080549a9b989a9899611337997ffeb2925a02bae3dae48d424a0437a2b6ac939aa9230ddc55a1a76f065d988076999493928c611da0836140ca565b919050558e6080015160405160200161131c9b9a999897969594939291909a8b5273ffffffffffffffffffffffffffffffffffffffff998a1660208c015260408b019890985295909716606089015267ffffffffffffffff938416608089015291151560a088015260c087015260e0860152610100850193909352610120840152166101408201526101600190565b60408051808201909152600081526060602082015284516040805180820190915260008152606060208201528167ffffffffffffffff811115611e7457611e7461386b565b604051908082528060200260200182016040528015611e9d578160200160208202803683370190505b5060208201526040517fa2ea7c6e000000000000000000000000000000000000000000000000000000008152600481018990526000907342000000000000000000000000000000000000209063a2ea7c6e90602401600060405180830381865afa158015611f0f573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052611f559190810190614102565b8051909150611f90576040517fbf37b20e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008367ffffffffffffffff811115611fab57611fab61386b565b60405190808252806020026020018201604052801561204a57816020015b60408051610140810182526000808252602080830182905292820181905260608083018290526080830182905260a0830182905260c0830182905260e0830182905261010083019190915261012082015282527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff909201910181611fc95790505b50905060008467ffffffffffffffff8111156120685761206861386b565b604051908082528060200260200182016040528015612091578160200160208202803683370190505b50905060005b858110156125205760008b82815181106120b3576120b36137fe565b60200260200101519050600067ffffffffffffffff16816020015167ffffffffffffffff16141580156120fe57504267ffffffffffffffff16816020015167ffffffffffffffff1611155b15612135576040517f08e8b93700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8460400151158015612148575080604001515b1561217f576040517f157bd4c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006040518061014001604052806000801b81526020018f81526020016121a34290565b67ffffffffffffffff168152602001836020015167ffffffffffffffff168152602001600067ffffffffffffffff16815260200183606001518152602001836000015173ffffffffffffffffffffffffffffffffffffffff1681526020018d73ffffffffffffffffffffffffffffffffffffffff16815260200183604001511515815260200183608001518152509050600080600090505b6122458382612df4565b600081815260326020526040902054909250156122645760010161223b565b81835260008281526032602090815260409182902085518155908501516001820155908401516002820180546060870151608088015167ffffffffffffffff908116700100000000000000000000000000000000027fffffffffffffffff0000000000000000ffffffffffffffffffffffffffffffff92821668010000000000000000027fffffffffffffffffffffffffffffffff000000000000000000000000000000009094169190951617919091171691909117905560a0840151600382015560c084015160048201805473ffffffffffffffffffffffffffffffffffffffff9283167fffffffffffffffffffffffff000000000000000000000000000000000000000090911617905560e0850151600583018054610100880151151574010000000000000000000000000000000000000000027fffffffffffffffffffffff000000000000000000000000000000000000000000909116929093169190911791909117905561012084015184919060068201906123e49082614228565b50505060608401511561243b57606084015160009081526032602052604090205461243b576040517fc5723b5100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8287868151811061244e5761244e6137fe565b60200260200101819052508360a00151868681518110612470576124706137fe565b6020026020010181815250508189602001518681518110612493576124936137fe565b6020026020010181815250508f8e73ffffffffffffffffffffffffffffffffffffffff16856000015173ffffffffffffffffffffffffffffffffffffffff167f8bf46bf4cfd674fa735a3d63ec1c9ad4153f033c290341f3a588b75685141b358560405161250391815260200190565b60405180910390a4505050506125198160010190565b9050612097565b5061253083838360008c8c612a03565b845250919998505050505050505050565b606060008267ffffffffffffffff81111561255e5761255e61386b565b604051908082528060200260200182016040528015612587578160200160208202803683370190505b508451909150600090815b818110156126205760008782815181106125ae576125ae6137fe565b6020026020010151905060008151905060005b8181101561260c578281815181106125db576125db6137fe565b60200260200101518787815181106125f5576125f56137fe565b6020908102919091010152600195860195016125c1565b5050506126198160010190565b9050612592565b509195945050505050565b60008281526033602052604090205467ffffffffffffffff161561267b576040517f2e26794600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008281526033602052604080822080547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000001667ffffffffffffffff85169081179091559051909184917f5aafceeb1c7ad58e4a84898bdee37c02c0fc46e7d24e6b60e8209449f183459f9190a35050565b60003073ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614801561275357507f000000000000000000000000000000000000000000000000000000000000000046145b1561277d57507f000000000000000000000000000000000000000000000000000000000000000090565b50604080517f00000000000000000000000000000000000000000000000000000000000000006020808301919091527f0000000000000000000000000000000000000000000000000000000000000000828401527f000000000000000000000000000000000000000000000000000000000000000060608301524660808301523060a0808401919091528351808403909101815260c0909201909252805191012090565b600061072a61282e6126ed565b83612e53565b60008060006128438585612e95565b9092509050600081600481111561285c5761285c614342565b14801561289457508573ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16145b156128a4576001925050506129fc565b6000808773ffffffffffffffffffffffffffffffffffffffff16631626ba7e60e01b88886040516024016128d9929190614371565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009094169390931790925290516129629190614392565b600060405180830381855afa9150503d806000811461299d576040519150601f19603f3d011682016040523d82523d6000602084013e6129a2565b606091505b50915091508180156129b5575080516020145b80156129f5575080517f1626ba7e00000000000000000000000000000000000000000000000000000000906129f390830160209081019084016143a4565b145b9450505050505b9392505050565b84516000906001819003612a5b57612a538888600081518110612a2857612a286137fe565b602002602001015188600081518110612a4357612a436137fe565b6020026020010151888888612eda565b915050612dea565b602088015173ffffffffffffffffffffffffffffffffffffffff8116612afc5760005b82811015612ae157878181518110612a9857612a986137fe565b6020026020010151600014612ad9576040517f1574f9f300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600101612a7e565b508315612af157612af1856131f9565b600092505050612dea565b6000808273ffffffffffffffffffffffffffffffffffffffff1663ce46e0466040518163ffffffff1660e01b8152600401602060405180830381865afa158015612b4a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612b6e91906143bd565b905060005b84811015612c2b5760008a8281518110612b8f57612b8f6137fe565b6020026020010151905080600003612ba75750612c23565b82612bde576040517f1574f9f300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b88811115612c18576040517f1101129400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b978890039792909201915b600101612b73565b508715612d06576040517f88e5b2d900000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8416906388e5b2d9908490612c88908e908e906004016143da565b60206040518083038185885af1158015612ca6573d6000803e3d6000fd5b50505050506040513d601f19601f82011682018060405250810190612ccb91906143bd565b612d01576040517fbf2f3a8b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b612dd5565b6040517f91db0b7e00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8416906391db0b7e908490612d5c908e908e906004016143da565b60206040518083038185885af1158015612d7a573d6000803e3d6000fd5b50505050506040513d601f19601f82011682018060405250810190612d9f91906143bd565b612dd5576040517fe8bee83900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8515612de457612de4876131f9565b50925050505b9695505050505050565b60208083015160c084015160e0850151604080870151606088015161010089015160a08a01516101208b01519451600099612e3599989796918c9101614493565b60405160208183030381529060405280519060200120905092915050565b6040517f190100000000000000000000000000000000000000000000000000000000000060208201526022810183905260428101829052600090606201612e35565b6000808251604103612ecb5760208301516040840151606085015160001a612ebf8782858561320c565b94509450505050612ed3565b506000905060025b9250929050565b602086015160009073ffffffffffffffffffffffffffffffffffffffff8116612f4e578515612f35576040517f1574f9f300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8215612f4457612f44846131f9565b6000915050612dea565b8515613039578073ffffffffffffffffffffffffffffffffffffffff1663ce46e0466040518163ffffffff1660e01b8152600401602060405180830381865afa158015612f9f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612fc391906143bd565b612ff9576040517f1574f9f300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b83861115613033576040517f1101129400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b85840393505b8415613111576040517fe49617e100000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82169063e49617e1908890613093908b90600401613771565b60206040518083038185885af11580156130b1573d6000803e3d6000fd5b50505050506040513d601f19601f820116820180604052508101906130d691906143bd565b61310c576040517fccf3bb2700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6131de565b6040517fe60c350500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82169063e60c3505908890613165908b90600401613771565b60206040518083038185885af1158015613183573d6000803e3d6000fd5b50505050506040513d601f19601f820116820180604052508101906131a891906143bd565b6131de576040517fbd8ba84d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b82156131ed576131ed846131f9565b50939695505050505050565b8015613209576132093382613324565b50565b6000807f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a0831115613243575060009050600361331b565b8460ff16601b1415801561325b57508460ff16601c14155b1561326c575060009050600461331b565b6040805160008082526020820180845289905260ff881692820192909252606081018690526080810185905260019060a0016020604051602081039080840390855afa1580156132c0573d6000803e3d6000fd5b50506040517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0015191505073ffffffffffffffffffffffffffffffffffffffff81166133145760006001925092505061331b565b9150600090505b94509492505050565b80471015613393576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a20696e73756666696369656e742062616c616e636500000060448201526064015b60405180910390fd5b60008273ffffffffffffffffffffffffffffffffffffffff168260405160006040518083038185875af1925050503d80600081146133ed576040519150601f19603f3d011682016040523d82523d6000602084013e6133f2565b606091505b5050905080610a63576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603a60248201527f416464726573733a20756e61626c6520746f2073656e642076616c75652c207260448201527f6563697069656e74206d61792068617665207265766572746564000000000000606482015260840161338a565b60008083601f84011261349557600080fd5b50813567ffffffffffffffff8111156134ad57600080fd5b6020830191508360208260051b8501011115612ed357600080fd5b600080602083850312156134db57600080fd5b823567ffffffffffffffff8111156134f257600080fd5b6134fe85828601613483565b90969095509350505050565b60005b8381101561352557818101518382015260200161350d565b50506000910152565b6000815180845261354681602086016020860161350a565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b6020815260006129fc602083018461352e565b73ffffffffffffffffffffffffffffffffffffffff8116811461320957600080fd5b80356135b88161358b565b919050565b6000602082840312156135cf57600080fd5b81356129fc8161358b565b6000602082840312156135ec57600080fd5b813567ffffffffffffffff81111561360357600080fd5b820160e081850312156129fc57600080fd5b6020808252825182820181905260009190848201906040850190845b8181101561364d57835183529284019291840191600101613631565b50909695505050505050565b60006060828403121561366b57600080fd5b50919050565b60006020828403121561368357600080fd5b5035919050565b6000610140825184526020830151602085015260408301516136b8604086018267ffffffffffffffff169052565b5060608301516136d4606086018267ffffffffffffffff169052565b5060808301516136f0608086018267ffffffffffffffff169052565b5060a083015160a085015260c083015161372260c086018273ffffffffffffffffffffffffffffffffffffffff169052565b5060e083015161374a60e086018273ffffffffffffffffffffffffffffffffffffffff169052565b506101008381015115159085015261012080840151818601839052612dea8387018261352e565b6020815260006129fc602083018461368a565b6000610100828403121561366b57600080fd5b600080604083850312156137aa57600080fd5b82356137b58161358b565b946020939093013593505050565b6000602082840312156137d557600080fd5b813567ffffffffffffffff8111156137ec57600080fd5b8201604081850312156129fc57600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600082357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff6183360301811261386157600080fd5b9190910192915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60405160a0810167ffffffffffffffff811182821017156138bd576138bd61386b565b60405290565b60405160c0810167ffffffffffffffff811182821017156138bd576138bd61386b565b6040516080810167ffffffffffffffff811182821017156138bd576138bd61386b565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156139505761395061386b565b604052919050565b600067ffffffffffffffff8211156139725761397261386b565b5060051b60200190565b60006040828403121561398e57600080fd5b6040516040810181811067ffffffffffffffff821117156139b1576139b161386b565b604052823581526020928301359281019290925250919050565b6000606082840312156139dd57600080fd5b6040516060810181811067ffffffffffffffff82111715613a0057613a0061386b565b604052905080823560ff81168114613a1757600080fd5b8082525060208301356020820152604083013560408201525092915050565b600082601f830112613a4757600080fd5b81356020613a5c613a5783613958565b613909565b82815260609283028501820192828201919087851115613a7b57600080fd5b8387015b85811015613a9e57613a9189826139cb565b8452928401928101613a7f565b5090979650505050505050565b803567ffffffffffffffff811681146135b857600080fd5b600060a08236031215613ad557600080fd5b613add61389a565b8235815260208084013567ffffffffffffffff80821115613afd57600080fd5b9085019036601f830112613b1057600080fd5b8135613b1e613a5782613958565b81815260069190911b83018401908481019036831115613b3d57600080fd5b938501935b82851015613b6657613b54368661397c565b82528582019150604085019450613b42565b80868801525050506040860135925080831115613b8257600080fd5b5050613b9036828601613a36565b604083015250613ba2606084016135ad565b6060820152613bb360808401613aab565b608082015292915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b8181038181111561072a5761072a613bbe565b801515811461320957600080fd5b600067ffffffffffffffff821115613c2857613c2861386b565b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01660200190565b600060c08284031215613c6657600080fd5b613c6e6138c3565b90508135613c7b8161358b565b81526020613c8a838201613aab565b818301526040830135613c9c81613c00565b604083015260608381013590830152608083013567ffffffffffffffff811115613cc557600080fd5b8301601f81018513613cd657600080fd5b8035613ce4613a5782613c0e565b8181528684838501011115613cf857600080fd5b818484018583013760008483830101528060808601525050505060a082013560a082015292915050565b600060e08236031215613d3457600080fd5b613d3c61389a565b82358152602083013567ffffffffffffffff811115613d5a57600080fd5b613d6636828601613c54565b602083015250613d7936604085016139cb565b604082015260a0830135613d8c8161358b565b6060820152613bb360c08401613aab565b600082357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff4183360301811261386157600080fd5b600061072a3683613c54565b600082357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc183360301811261386157600080fd5b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112613e4657600080fd5b83018035915067ffffffffffffffff821115613e6157600080fd5b6020019150600581901b3603821315612ed357600080fd5b6000613e87613a5784613958565b80848252602080830192508560051b850136811115613ea557600080fd5b855b81811015613ee157803567ffffffffffffffff811115613ec75760008081fd5b613ed336828a01613c54565b865250938201938201613ea7565b50919695505050505050565b600060408284031215613eff57600080fd5b6129fc838361397c565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112613f3e57600080fd5b83018035915067ffffffffffffffff821115613f5957600080fd5b6020019150600681901b3603821315612ed357600080fd5b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112613fa657600080fd5b83018035915067ffffffffffffffff821115613fc157600080fd5b6020019150606081023603821315612ed357600080fd5b600060608284031215613fea57600080fd5b6129fc83836139cb565b60006020828403121561400657600080fd5b6129fc82613aab565b600181811c9082168061402357607f821691505b60208210810361366b577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b6000610100828403121561406f57600080fd5b61407761389a565b82358152614088846020850161397c565b602082015261409a84606085016139cb565b604082015260c08301356140ad8161358b565b60608201526140be60e08401613aab565b60808201529392505050565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036140fb576140fb613bbe565b5060010190565b6000602080838503121561411557600080fd5b825167ffffffffffffffff8082111561412d57600080fd5b908401906080828703121561414157600080fd5b6141496138e6565b825181528383015161415a8161358b565b81850152604083015161416c81613c00565b604082015260608301518281111561418357600080fd5b80840193505086601f84011261419857600080fd5b825191506141a8613a5783613c0e565b82815287858486010111156141bc57600080fd5b6141cb8386830187870161350a565b60608201529695505050505050565b601f821115610a6357600081815260208120601f850160051c810160208610156142015750805b601f850160051c820191505b818110156142205782815560010161420d565b505050505050565b815167ffffffffffffffff8111156142425761424261386b565b61425681614250845461400f565b846141da565b602080601f8311600181146142a957600084156142735750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b178555614220565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b828110156142f6578886015182559484019460019091019084016142d7565b508582101561433257878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b82815260406020820152600061438a604083018461352e565b949350505050565b6000825161386181846020870161350a565b6000602082840312156143b657600080fd5b5051919050565b6000602082840312156143cf57600080fd5b81516129fc81613c00565b6000604082016040835280855180835260608501915060608160051b8601019250602080880160005b8381101561444f577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa088870301855261443d86835161368a565b95509382019390820190600101614403565b50508584038187015286518085528782019482019350915060005b828110156144865784518452938101939281019260010161446a565b5091979650505050505050565b89815260007fffffffffffffffffffffffffffffffffffffffff000000000000000000000000808b60601b166020840152808a60601b166034840152507fffffffffffffffff000000000000000000000000000000000000000000000000808960c01b166048840152808860c01b1660508401525085151560f81b6058830152846059830152835161452c81607985016020880161350a565b80830190507fffffffff000000000000000000000000000000000000000000000000000000008460e01b166079820152607d81019150509a995050505050505050505056fea164736f6c6343000813000a", } // EASABI is the input ABI used to generate the binding from. diff --git a/op-bindings/bindings/eas_more.go b/op-bindings/bindings/eas_more.go index 56cb953e5b848..93a4d7a3e2ff9 100644 --- a/op-bindings/bindings/eas_more.go +++ b/op-bindings/bindings/eas_more.go @@ -13,7 +13,7 @@ const EASStorageLayoutJSON = "{\"storage\":[{\"astId\":1000,\"contract\":\"src/E var EASStorageLayout = new(solc.StorageLayout) -var EASDeployedBin = "0x60806040526004361061018b5760003560e01c806395411525116100d6578063d45c44351161007f578063ed24911d11610059578063ed24911d146104fd578063f10b5cc814610512578063f17325e71461054157600080fd5b8063d45c443514610467578063e30bb5631461049e578063e71ff365146104dd57600080fd5b8063b469318d116100b0578063b469318d146103ba578063b83010d314610414578063cf190f341461044757600080fd5b80639541152514610367578063a3112a641461037a578063a6d4dbc7146103a757600080fd5b806344adc90e116101385780634d003070116101125780634d003070146102de57806354fd4d50146102fe57806379f7573a1461034757600080fd5b806344adc90e1461029857806346926267146102b85780634cb7e9e5146102cb57600080fd5b806317d7de7c1161016957806317d7de7c146102205780632d0335ab146102425780633c0427151461028557600080fd5b80630eabf6601461019057806312b11a17146101a557806313893f61146101e7575b600080fd5b6101a361019e366004613497565b610554565b005b3480156101b157600080fd5b507ff83bb2b0ede93a840239f7e701a54d9bc35f03701f51ae153d601c6947ff3d3f5b6040519081526020015b60405180910390f35b3480156101f357600080fd5b50610207610202366004613497565b6106eb565b60405167ffffffffffffffff90911681526020016101de565b34801561022c57600080fd5b50610235610730565b6040516101de9190613547565b34801561024e57600080fd5b506101d461025d36600461358c565b73ffffffffffffffffffffffffffffffffffffffff1660009081526020819052604090205490565b6101d46102933660046135a9565b610760565b6102ab6102a6366004613497565b610863565b6040516101de91906135e4565b6101a36102c6366004613628565b6109e4565b6101a36102d9366004613497565b610a68565b3480156102ea57600080fd5b506102076102f9366004613640565b610b4b565b34801561030a57600080fd5b506102356040518060400160405280600581526020017f312e332e3000000000000000000000000000000000000000000000000000000081525081565b34801561035357600080fd5b506101a3610362366004613640565b610b58565b6102ab610375366004613497565b610bef565b34801561038657600080fd5b5061039a610395366004613640565b610e62565b6040516101de9190613740565b6101a36103b5366004613753565b611025565b3480156103c657600080fd5b506102076103d5366004613766565b73ffffffffffffffffffffffffffffffffffffffff919091166000908152603460209081526040808320938352929052205467ffffffffffffffff1690565b34801561042057600080fd5b507f2d4116d8c9824e4c316453e5c2843a1885580374159ce8768603c49085ef424c6101d4565b34801561045357600080fd5b50610207610462366004613640565b6110ca565b34801561047357600080fd5b50610207610482366004613640565b60009081526033602052604090205467ffffffffffffffff1690565b3480156104aa57600080fd5b506104cd6104b9366004613640565b600090815260326020526040902054151590565b60405190151581526020016101de565b3480156104e957600080fd5b506102076104f8366004613497565b6110d8565b34801561050957600080fd5b506101d4611110565b34801561051e57600080fd5b5060405173420000000000000000000000000000000000002081526020016101de565b6101d461054f366004613792565b61111a565b348160005b818110156106e4577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82018114600086868481811061059a5761059a6137cd565b90506020028101906105ac91906137fc565b6105b590613a92565b60208101518051919250908015806105d257508260400151518114155b15610609576040517f947d5a8400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b818110156106ad576106a56040518060a001604052808660000151815260200185848151811061063e5761063e6137cd565b6020026020010151815260200186604001518481518110610661576106616137cd565b60200260200101518152602001866060015173ffffffffffffffffffffffffffffffffffffffff168152602001866080015167ffffffffffffffff168152506111d8565b60010161060c565b506106c383600001518385606001518a886113c5565b6106cd9088613bbc565b9650505050506106dd8160010190565b9050610559565b5050505050565b60004282825b818110156107245761071c3387878481811061070f5761070f6137cd565b90506020020135856119f4565b6001016106f1565b50909150505b92915050565b606061075b7f0000000000000000000000000000000000000000000000000000000000000000611af3565b905090565b600061077361076e83613cf1565b611c81565b604080516001808252818301909252600091816020015b6040805160c081018252600080825260208083018290529282018190526060808301829052608083015260a082015282527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90920191018161078a5790505090506107f86020840184613d6c565b61080190613da0565b81600081518110610814576108146137cd565b602090810291909101015261083d83358261083560c0870160a0880161358c565b346001611dfe565b60200151600081518110610853576108536137cd565b6020026020010151915050919050565b60608160008167ffffffffffffffff8111156108815761088161383a565b6040519080825280602002602001820160405280156108b457816020015b606081526020019060019003908161089f5790505b509050600034815b848110156109ce577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff85018114368989848181106108fc576108fc6137cd565b905060200281019061090e9190613dac565b905061091d6020820182613de0565b9050600003610958576040517f947d5a8400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061097d823561096c6020850185613de0565b61097591613e48565b338887611dfe565b805190915061098c9086613bbc565b945080602001518785815181106109a5576109a56137cd565b6020026020010181905250806020015151860195505050506109c78160010190565b90506108bc565b506109d98383612510565b979650505050505050565b604080516001808252818301909252600091816020015b60408051808201909152600080825260208201528152602001906001900390816109fb579050509050610a3636839003830160208401613ebc565b81600081518110610a4957610a496137cd565b6020908102919091010152610a63823582333460016113c5565b505050565b348160005b818110156106e4577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8201811436868684818110610aad57610aad6137cd565b9050602002810190610abf9190613dac565b9050610b2c8135610ad36020840184613ed8565b808060200260200160405190810160405280939291908181526020016000905b82821015610b1f57610b1060408302860136819003810190613ebc565b81526020019060010190610af3565b50505050503388866113c5565b610b369086613bbc565b94505050610b448160010190565b9050610a6d565b60004261072a83826125fa565b33600090815260208190526040902054808211610ba1576040517f756688fe00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152602081815260409182902084905581518381529081018490527f57b09af877df9068fd60a69d7b21f5576b8b38955812d6ae4ac52942f1e38fb7910160405180910390a15050565b60608160008167ffffffffffffffff811115610c0d57610c0d61383a565b604051908082528060200260200182016040528015610c4057816020015b6060815260200190600190039081610c2b5790505b509050600034815b848110156109ce577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8501811436898984818110610c8857610c886137cd565b9050602002810190610c9a91906137fc565b9050366000610cac6020840184613de0565b909250905080801580610ccd5750610cc76040850185613f40565b90508114155b15610d04576040517f947d5a8400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b81811015610de557610ddd6040518060a0016040528087600001358152602001868685818110610d3957610d396137cd565b9050602002810190610d4b9190613d6c565b610d5490613da0565b8152602001610d666040890189613f40565b85818110610d7657610d766137cd565b905060600201803603810190610d8c9190613fa7565b8152602001610da16080890160608a0161358c565b73ffffffffffffffffffffffffffffffffffffffff168152602001610dcc60a0890160808a01613fc3565b67ffffffffffffffff169052611c81565b600101610d07565b506000610e0e8535610df78587613e48565b610e076080890160608a0161358c565b8b8a611dfe565b8051909150610e1d9089613bbc565b975080602001518a8881518110610e3657610e366137cd565b602002602001018190525080602001515189019850505050505050610e5b8160010190565b9050610c48565b604080516101408101825260008082526020820181905291810182905260608082018390526080820183905260a0820183905260c0820183905260e0820183905261010082019290925261012081019190915260008281526032602090815260409182902082516101408101845281548152600182015492810192909252600281015467ffffffffffffffff808216948401949094526801000000000000000081048416606084015270010000000000000000000000000000000090049092166080820152600382015460a0820152600482015473ffffffffffffffffffffffffffffffffffffffff90811660c0830152600583015490811660e083015274010000000000000000000000000000000000000000900460ff16151561010082015260068201805491929161012084019190610f9c90613fde565b80601f0160208091040260200160405190810160405280929190818152602001828054610fc890613fde565b80156110155780601f10610fea57610100808354040283529160200191611015565b820191906000526020600020905b815481529060010190602001808311610ff857829003601f168201915b5050505050815250509050919050565b61103c6110373683900383018361402b565b6111d8565b604080516001808252818301909252600091816020015b604080518082019091526000808252602082015281526020019060019003908161105357905050905061108e36839003830160208401613ebc565b816000815181106110a1576110a16137cd565b6020908102919091010152610a638235826110c260e0860160c0870161358c565b3460016113c5565b60004261072a3384836119f4565b60004282825b81811015610724576111088686838181106110fb576110fb6137cd565b90506020020135846125fa565b6001016110de565b600061075b6126bc565b604080516001808252818301909252600091829190816020015b6040805160c081018252600080825260208083018290529282018190526060808301829052608083015260a082015282527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9092019101816111345790505090506111a26020840184613d6c565b6111ab90613da0565b816000815181106111be576111be6137cd565b602090810291909101015261083d83358233346001611dfe565b608081015167ffffffffffffffff161580159061120c57504267ffffffffffffffff16816080015167ffffffffffffffff16105b15611243576040517f1ab7da6b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6020808201516040808401518451835184860151606088015173ffffffffffffffffffffffffffffffffffffffff166000908152968790529386208054959693959394611313947f2d4116d8c9824e4c316453e5c2843a1885580374159ce8768603c49085ef424c949392876112b883614099565b909155506080808b015160408051602081019890985287019590955260608601939093529184015260a083015267ffffffffffffffff1660c082015260e0015b604051602081830303815290604052805190602001206127f0565b905061138984606001518284602001518560400151866000015160405160200161137593929190928352602083019190915260f81b7fff0000000000000000000000000000000000000000000000000000000000000016604082015260410190565b604051602081830303815290604052612803565b6113bf576040517f8baa579f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b50505050565b6040517fa2ea7c6e0000000000000000000000000000000000000000000000000000000081526004810186905260009081907342000000000000000000000000000000000000209063a2ea7c6e90602401600060405180830381865afa158015611433573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016820160405261147991908101906140d1565b80519091506114b4576040517fbf37b20e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b855160008167ffffffffffffffff8111156114d1576114d161383a565b60405190808252806020026020018201604052801561157057816020015b60408051610140810182526000808252602080830182905292820181905260608083018290526080830182905260a0830182905260c0830182905260e0830182905261010083019190915261012082015282527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9092019101816114ef5790505b50905060008267ffffffffffffffff81111561158e5761158e61383a565b6040519080825280602002602001820160405280156115b7578160200160208202803683370190505b50905060005b838110156119d65760008a82815181106115d9576115d96137cd565b6020908102919091018101518051600090815260329092526040909120805491925090611632576040517fc5723b5100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8c81600101541461166f576040517fbf37b20e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600581015473ffffffffffffffffffffffffffffffffffffffff8c81169116146116c5576040517f4ca8886700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600581015474010000000000000000000000000000000000000000900460ff1661171b576040517f157bd4c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6002810154700100000000000000000000000000000000900467ffffffffffffffff1615611775576040517f905e710700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b426002820180547fffffffffffffffff0000000000000000ffffffffffffffffffffffffffffffff811670010000000000000000000000000000000067ffffffffffffffff948516810291821793849055604080516101408101825287548152600188015460208201529386169286169290921791830191909152680100000000000000008304841660608301529091049091166080820152600382015460a0820152600482015473ffffffffffffffffffffffffffffffffffffffff90811660c0830152600583015490811660e083015274010000000000000000000000000000000000000000900460ff161515610100820152600682018054839161012084019161188190613fde565b80601f01602080910402602001604051908101604052809291908181526020018280546118ad90613fde565b80156118fa5780601f106118cf576101008083540402835291602001916118fa565b820191906000526020600020905b8154815290600101906020018083116118dd57829003601f168201915b505050505081525050858481518110611915576119156137cd565b60200260200101819052508160200151848481518110611937576119376137cd565b6020026020010181815250508c8b73ffffffffffffffffffffffffffffffffffffffff1686858151811061196d5761196d6137cd565b602002602001015160c0015173ffffffffffffffffffffffffffffffffffffffff167ff930a6e2523c9cc298691873087a740550b8fc85a0680830414c148ed927f61585600001516040516119c491815260200190565b60405180910390a450506001016115bd565b506119e684838360018b8b6129d2565b9a9950505050505050505050565b73ffffffffffffffffffffffffffffffffffffffff83166000908152603460209081526040808320858452918290529091205467ffffffffffffffff1615611a68576040517fec9d6eeb00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008381526020829052604080822080547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000001667ffffffffffffffff861690811790915590519091859173ffffffffffffffffffffffffffffffffffffffff8816917f92a1f7a41a7c585a8b09e25b195e225b1d43248daca46b0faf9e0792777a222991a450505050565b604080516020808252818301909252606091600091906020820181803683370190505090506000805b6020811015611bbe576000858260208110611b3957611b396137cd565b1a60f81b90507fff000000000000000000000000000000000000000000000000000000000000008116600003611b6f5750611bbe565b80848481518110611b8257611b826137cd565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053505060019182019101611b1c565b5060008167ffffffffffffffff811115611bda57611bda61383a565b6040519080825280601f01601f191660200182016040528015611c04576020820181803683370190505b50905060005b82811015611c7857838181518110611c2457611c246137cd565b602001015160f81c60f81b828281518110611c4157611c416137cd565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350600101611c0a565b50949350505050565b608081015167ffffffffffffffff1615801590611cb557504267ffffffffffffffff16816080015167ffffffffffffffff16105b15611cec576040517f1ab7da6b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208082015160408084015184518351848601518486015160608088015160808901518051908b012060a08a0151928c015173ffffffffffffffffffffffffffffffffffffffff1660009081529a8b9052978a208054999a97999798611313987ff83bb2b0ede93a840239f7e701a54d9bc35f03701f51ae153d601c6947ff3d3f989796959491928b611d7e83614099565b909155506080808f015160408051602081019c909c528b019990995273ffffffffffffffffffffffffffffffffffffffff90971660608a015267ffffffffffffffff9586169689019690965292151560a088015260c087019190915260e086015261010085015261012084019190915216610140820152610160016112f8565b60408051808201909152600081526060602082015284516040805180820190915260008152606060208201528167ffffffffffffffff811115611e4357611e4361383a565b604051908082528060200260200182016040528015611e6c578160200160208202803683370190505b5060208201526040517fa2ea7c6e000000000000000000000000000000000000000000000000000000008152600481018990526000907342000000000000000000000000000000000000209063a2ea7c6e90602401600060405180830381865afa158015611ede573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052611f2491908101906140d1565b8051909150611f5f576040517fbf37b20e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008367ffffffffffffffff811115611f7a57611f7a61383a565b60405190808252806020026020018201604052801561201957816020015b60408051610140810182526000808252602080830182905292820181905260608083018290526080830182905260a0830182905260c0830182905260e0830182905261010083019190915261012082015282527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff909201910181611f985790505b50905060008467ffffffffffffffff8111156120375761203761383a565b604051908082528060200260200182016040528015612060578160200160208202803683370190505b50905060005b858110156124ef5760008b8281518110612082576120826137cd565b60200260200101519050600067ffffffffffffffff16816020015167ffffffffffffffff16141580156120cd57504267ffffffffffffffff16816020015167ffffffffffffffff1611155b15612104576040517f08e8b93700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8460400151158015612117575080604001515b1561214e576040517f157bd4c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006040518061014001604052806000801b81526020018f81526020016121724290565b67ffffffffffffffff168152602001836020015167ffffffffffffffff168152602001600067ffffffffffffffff16815260200183606001518152602001836000015173ffffffffffffffffffffffffffffffffffffffff1681526020018d73ffffffffffffffffffffffffffffffffffffffff16815260200183604001511515815260200183608001518152509050600080600090505b6122148382612dc3565b600081815260326020526040902054909250156122335760010161220a565b81835260008281526032602090815260409182902085518155908501516001820155908401516002820180546060870151608088015167ffffffffffffffff908116700100000000000000000000000000000000027fffffffffffffffff0000000000000000ffffffffffffffffffffffffffffffff92821668010000000000000000027fffffffffffffffffffffffffffffffff000000000000000000000000000000009094169190951617919091171691909117905560a0840151600382015560c084015160048201805473ffffffffffffffffffffffffffffffffffffffff9283167fffffffffffffffffffffffff000000000000000000000000000000000000000090911617905560e0850151600583018054610100880151151574010000000000000000000000000000000000000000027fffffffffffffffffffffff000000000000000000000000000000000000000000909116929093169190911791909117905561012084015184919060068201906123b390826141f7565b50505060608401511561240a57606084015160009081526032602052604090205461240a576040517fc5723b5100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8287868151811061241d5761241d6137cd565b60200260200101819052508360a0015186868151811061243f5761243f6137cd565b6020026020010181815250508189602001518681518110612462576124626137cd565b6020026020010181815250508f8e73ffffffffffffffffffffffffffffffffffffffff16856000015173ffffffffffffffffffffffffffffffffffffffff167f8bf46bf4cfd674fa735a3d63ec1c9ad4153f033c290341f3a588b75685141b35856040516124d291815260200190565b60405180910390a4505050506124e88160010190565b9050612066565b506124ff83838360008c8c6129d2565b845250919998505050505050505050565b606060008267ffffffffffffffff81111561252d5761252d61383a565b604051908082528060200260200182016040528015612556578160200160208202803683370190505b508451909150600090815b818110156125ef57600087828151811061257d5761257d6137cd565b6020026020010151905060008151905060005b818110156125db578281815181106125aa576125aa6137cd565b60200260200101518787815181106125c4576125c46137cd565b602090810291909101015260019586019501612590565b5050506125e88160010190565b9050612561565b509195945050505050565b60008281526033602052604090205467ffffffffffffffff161561264a576040517f2e26794600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008281526033602052604080822080547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000001667ffffffffffffffff85169081179091559051909184917f5aafceeb1c7ad58e4a84898bdee37c02c0fc46e7d24e6b60e8209449f183459f9190a35050565b60003073ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614801561272257507f000000000000000000000000000000000000000000000000000000000000000046145b1561274c57507f000000000000000000000000000000000000000000000000000000000000000090565b50604080517f00000000000000000000000000000000000000000000000000000000000000006020808301919091527f0000000000000000000000000000000000000000000000000000000000000000828401527f000000000000000000000000000000000000000000000000000000000000000060608301524660808301523060a0808401919091528351808403909101815260c0909201909252805191012090565b600061072a6127fd6126bc565b83612e22565b60008060006128128585612e64565b9092509050600081600481111561282b5761282b614311565b14801561286357508573ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16145b15612873576001925050506129cb565b6000808773ffffffffffffffffffffffffffffffffffffffff16631626ba7e60e01b88886040516024016128a8929190614340565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009094169390931790925290516129319190614361565b600060405180830381855afa9150503d806000811461296c576040519150601f19603f3d011682016040523d82523d6000602084013e612971565b606091505b5091509150818015612984575080516020145b80156129c4575080517f1626ba7e00000000000000000000000000000000000000000000000000000000906129c29083016020908101908401614373565b145b9450505050505b9392505050565b84516000906001819003612a2a57612a2288886000815181106129f7576129f76137cd565b602002602001015188600081518110612a1257612a126137cd565b6020026020010151888888612ea9565b915050612db9565b602088015173ffffffffffffffffffffffffffffffffffffffff8116612acb5760005b82811015612ab057878181518110612a6757612a676137cd565b6020026020010151600014612aa8576040517f1574f9f300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600101612a4d565b508315612ac057612ac0856131c8565b600092505050612db9565b6000808273ffffffffffffffffffffffffffffffffffffffff1663ce46e0466040518163ffffffff1660e01b8152600401602060405180830381865afa158015612b19573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612b3d919061438c565b905060005b84811015612bfa5760008a8281518110612b5e57612b5e6137cd565b6020026020010151905080600003612b765750612bf2565b82612bad576040517f1574f9f300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b88811115612be7576040517f1101129400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b978890039792909201915b600101612b42565b508715612cd5576040517f88e5b2d900000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8416906388e5b2d9908490612c57908e908e906004016143a9565b60206040518083038185885af1158015612c75573d6000803e3d6000fd5b50505050506040513d601f19601f82011682018060405250810190612c9a919061438c565b612cd0576040517fbf2f3a8b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b612da4565b6040517f91db0b7e00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8416906391db0b7e908490612d2b908e908e906004016143a9565b60206040518083038185885af1158015612d49573d6000803e3d6000fd5b50505050506040513d601f19601f82011682018060405250810190612d6e919061438c565b612da4576040517fe8bee83900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8515612db357612db3876131c8565b50925050505b9695505050505050565b60208083015160c084015160e0850151604080870151606088015161010089015160a08a01516101208b01519451600099612e0499989796918c9101614462565b60405160208183030381529060405280519060200120905092915050565b6040517f190100000000000000000000000000000000000000000000000000000000000060208201526022810183905260428101829052600090606201612e04565b6000808251604103612e9a5760208301516040840151606085015160001a612e8e878285856131db565b94509450505050612ea2565b506000905060025b9250929050565b602086015160009073ffffffffffffffffffffffffffffffffffffffff8116612f1d578515612f04576040517f1574f9f300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8215612f1357612f13846131c8565b6000915050612db9565b8515613008578073ffffffffffffffffffffffffffffffffffffffff1663ce46e0466040518163ffffffff1660e01b8152600401602060405180830381865afa158015612f6e573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612f92919061438c565b612fc8576040517f1574f9f300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b83861115613002576040517f1101129400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b85840393505b84156130e0576040517fe49617e100000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82169063e49617e1908890613062908b90600401613740565b60206040518083038185885af1158015613080573d6000803e3d6000fd5b50505050506040513d601f19601f820116820180604052508101906130a5919061438c565b6130db576040517fccf3bb2700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6131ad565b6040517fe60c350500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82169063e60c3505908890613134908b90600401613740565b60206040518083038185885af1158015613152573d6000803e3d6000fd5b50505050506040513d601f19601f82011682018060405250810190613177919061438c565b6131ad576040517fbd8ba84d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b82156131bc576131bc846131c8565b50939695505050505050565b80156131d8576131d833826132f3565b50565b6000807f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a083111561321257506000905060036132ea565b8460ff16601b1415801561322a57508460ff16601c14155b1561323b57506000905060046132ea565b6040805160008082526020820180845289905260ff881692820192909252606081018690526080810185905260019060a0016020604051602081039080840390855afa15801561328f573d6000803e3d6000fd5b50506040517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0015191505073ffffffffffffffffffffffffffffffffffffffff81166132e3576000600192509250506132ea565b9150600090505b94509492505050565b80471015613362576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a20696e73756666696369656e742062616c616e636500000060448201526064015b60405180910390fd5b60008273ffffffffffffffffffffffffffffffffffffffff168260405160006040518083038185875af1925050503d80600081146133bc576040519150601f19603f3d011682016040523d82523d6000602084013e6133c1565b606091505b5050905080610a63576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603a60248201527f416464726573733a20756e61626c6520746f2073656e642076616c75652c207260448201527f6563697069656e74206d617920686176652072657665727465640000000000006064820152608401613359565b60008083601f84011261346457600080fd5b50813567ffffffffffffffff81111561347c57600080fd5b6020830191508360208260051b8501011115612ea257600080fd5b600080602083850312156134aa57600080fd5b823567ffffffffffffffff8111156134c157600080fd5b6134cd85828601613452565b90969095509350505050565b60005b838110156134f45781810151838201526020016134dc565b50506000910152565b600081518084526135158160208601602086016134d9565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b6020815260006129cb60208301846134fd565b73ffffffffffffffffffffffffffffffffffffffff811681146131d857600080fd5b80356135878161355a565b919050565b60006020828403121561359e57600080fd5b81356129cb8161355a565b6000602082840312156135bb57600080fd5b813567ffffffffffffffff8111156135d257600080fd5b820160e081850312156129cb57600080fd5b6020808252825182820181905260009190848201906040850190845b8181101561361c57835183529284019291840191600101613600565b50909695505050505050565b60006060828403121561363a57600080fd5b50919050565b60006020828403121561365257600080fd5b5035919050565b600061014082518452602083015160208501526040830151613687604086018267ffffffffffffffff169052565b5060608301516136a3606086018267ffffffffffffffff169052565b5060808301516136bf608086018267ffffffffffffffff169052565b5060a083015160a085015260c08301516136f160c086018273ffffffffffffffffffffffffffffffffffffffff169052565b5060e083015161371960e086018273ffffffffffffffffffffffffffffffffffffffff169052565b506101008381015115159085015261012080840151818601839052612db9838701826134fd565b6020815260006129cb6020830184613659565b6000610100828403121561363a57600080fd5b6000806040838503121561377957600080fd5b82356137848161355a565b946020939093013593505050565b6000602082840312156137a457600080fd5b813567ffffffffffffffff8111156137bb57600080fd5b8201604081850312156129cb57600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600082357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff6183360301811261383057600080fd5b9190910192915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60405160a0810167ffffffffffffffff8111828210171561388c5761388c61383a565b60405290565b60405160c0810167ffffffffffffffff8111828210171561388c5761388c61383a565b6040516080810167ffffffffffffffff8111828210171561388c5761388c61383a565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff8111828210171561391f5761391f61383a565b604052919050565b600067ffffffffffffffff8211156139415761394161383a565b5060051b60200190565b60006040828403121561395d57600080fd5b6040516040810181811067ffffffffffffffff821117156139805761398061383a565b604052823581526020928301359281019290925250919050565b6000606082840312156139ac57600080fd5b6040516060810181811067ffffffffffffffff821117156139cf576139cf61383a565b604052905080823560ff811681146139e657600080fd5b8082525060208301356020820152604083013560408201525092915050565b600082601f830112613a1657600080fd5b81356020613a2b613a2683613927565b6138d8565b82815260609283028501820192828201919087851115613a4a57600080fd5b8387015b85811015613a6d57613a60898261399a565b8452928401928101613a4e565b5090979650505050505050565b803567ffffffffffffffff8116811461358757600080fd5b600060a08236031215613aa457600080fd5b613aac613869565b8235815260208084013567ffffffffffffffff80821115613acc57600080fd5b9085019036601f830112613adf57600080fd5b8135613aed613a2682613927565b81815260069190911b83018401908481019036831115613b0c57600080fd5b938501935b82851015613b3557613b23368661394b565b82528582019150604085019450613b11565b80868801525050506040860135925080831115613b5157600080fd5b5050613b5f36828601613a05565b604083015250613b716060840161357c565b6060820152613b8260808401613a7a565b608082015292915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b8181038181111561072a5761072a613b8d565b80151581146131d857600080fd5b600067ffffffffffffffff821115613bf757613bf761383a565b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01660200190565b600060c08284031215613c3557600080fd5b613c3d613892565b90508135613c4a8161355a565b81526020613c59838201613a7a565b818301526040830135613c6b81613bcf565b604083015260608381013590830152608083013567ffffffffffffffff811115613c9457600080fd5b8301601f81018513613ca557600080fd5b8035613cb3613a2682613bdd565b8181528684838501011115613cc757600080fd5b818484018583013760008483830101528060808601525050505060a082013560a082015292915050565b600060e08236031215613d0357600080fd5b613d0b613869565b82358152602083013567ffffffffffffffff811115613d2957600080fd5b613d3536828601613c23565b602083015250613d48366040850161399a565b604082015260a0830135613d5b8161355a565b6060820152613b8260c08401613a7a565b600082357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff4183360301811261383057600080fd5b600061072a3683613c23565b600082357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc183360301811261383057600080fd5b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112613e1557600080fd5b83018035915067ffffffffffffffff821115613e3057600080fd5b6020019150600581901b3603821315612ea257600080fd5b6000613e56613a2684613927565b80848252602080830192508560051b850136811115613e7457600080fd5b855b81811015613eb057803567ffffffffffffffff811115613e965760008081fd5b613ea236828a01613c23565b865250938201938201613e76565b50919695505050505050565b600060408284031215613ece57600080fd5b6129cb838361394b565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112613f0d57600080fd5b83018035915067ffffffffffffffff821115613f2857600080fd5b6020019150600681901b3603821315612ea257600080fd5b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112613f7557600080fd5b83018035915067ffffffffffffffff821115613f9057600080fd5b6020019150606081023603821315612ea257600080fd5b600060608284031215613fb957600080fd5b6129cb838361399a565b600060208284031215613fd557600080fd5b6129cb82613a7a565b600181811c90821680613ff257607f821691505b60208210810361363a577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b6000610100828403121561403e57600080fd5b614046613869565b82358152614057846020850161394b565b6020820152614069846060850161399a565b604082015260c083013561407c8161355a565b606082015261408d60e08401613a7a565b60808201529392505050565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036140ca576140ca613b8d565b5060010190565b600060208083850312156140e457600080fd5b825167ffffffffffffffff808211156140fc57600080fd5b908401906080828703121561411057600080fd5b6141186138b5565b82518152838301516141298161355a565b81850152604083015161413b81613bcf565b604082015260608301518281111561415257600080fd5b80840193505086601f84011261416757600080fd5b82519150614177613a2683613bdd565b828152878584860101111561418b57600080fd5b61419a838683018787016134d9565b60608201529695505050505050565b601f821115610a6357600081815260208120601f850160051c810160208610156141d05750805b601f850160051c820191505b818110156141ef578281556001016141dc565b505050505050565b815167ffffffffffffffff8111156142115761421161383a565b6142258161421f8454613fde565b846141a9565b602080601f83116001811461427857600084156142425750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b1785556141ef565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b828110156142c5578886015182559484019460019091019084016142a6565b508582101561430157878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b82815260406020820152600061435960408301846134fd565b949350505050565b600082516138308184602087016134d9565b60006020828403121561438557600080fd5b5051919050565b60006020828403121561439e57600080fd5b81516129cb81613bcf565b6000604082016040835280855180835260608501915060608160051b8601019250602080880160005b8381101561441e577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa088870301855261440c868351613659565b955093820193908201906001016143d2565b50508584038187015286518085528782019482019350915060005b8281101561445557845184529381019392810192600101614439565b5091979650505050505050565b89815260007fffffffffffffffffffffffffffffffffffffffff000000000000000000000000808b60601b166020840152808a60601b166034840152507fffffffffffffffff000000000000000000000000000000000000000000000000808960c01b166048840152808860c01b1660508401525085151560f81b605883015284605983015283516144fb8160798501602088016134d9565b80830190507fffffffff000000000000000000000000000000000000000000000000000000008460e01b166079820152607d81019150509a995050505050505050505056fea164736f6c6343000813000a" +var EASDeployedBin = "0x60806040526004361061018b5760003560e01c806395411525116100d6578063d45c44351161007f578063ed24911d11610059578063ed24911d146104fd578063f10b5cc814610512578063f17325e71461054157600080fd5b8063d45c443514610467578063e30bb5631461049e578063e71ff365146104dd57600080fd5b8063b469318d116100b0578063b469318d146103ba578063b83010d314610414578063cf190f341461044757600080fd5b80639541152514610367578063a3112a641461037a578063a6d4dbc7146103a757600080fd5b806344adc90e116101385780634d003070116101125780634d003070146102de57806354fd4d50146102fe57806379f7573a1461034757600080fd5b806344adc90e1461029857806346926267146102b85780634cb7e9e5146102cb57600080fd5b806317d7de7c1161016957806317d7de7c146102205780632d0335ab146102425780633c0427151461028557600080fd5b80630eabf6601461019057806312b11a17146101a557806313893f61146101e7575b600080fd5b6101a361019e3660046134c8565b610554565b005b3480156101b157600080fd5b507ffeb2925a02bae3dae48d424a0437a2b6ac939aa9230ddc55a1a76f065d9880765b6040519081526020015b60405180910390f35b3480156101f357600080fd5b506102076102023660046134c8565b6106eb565b60405167ffffffffffffffff90911681526020016101de565b34801561022c57600080fd5b50610235610730565b6040516101de9190613578565b34801561024e57600080fd5b506101d461025d3660046135bd565b73ffffffffffffffffffffffffffffffffffffffff1660009081526020819052604090205490565b6101d46102933660046135da565b610760565b6102ab6102a63660046134c8565b610863565b6040516101de9190613615565b6101a36102c6366004613659565b6109e4565b6101a36102d93660046134c8565b610a68565b3480156102ea57600080fd5b506102076102f9366004613671565b610b4b565b34801561030a57600080fd5b506102356040518060400160405280600581526020017f312e342e3000000000000000000000000000000000000000000000000000000081525081565b34801561035357600080fd5b506101a3610362366004613671565b610b58565b6102ab6103753660046134c8565b610bef565b34801561038657600080fd5b5061039a610395366004613671565b610e62565b6040516101de9190613771565b6101a36103b5366004613784565b611025565b3480156103c657600080fd5b506102076103d5366004613797565b73ffffffffffffffffffffffffffffffffffffffff919091166000908152603460209081526040808320938352929052205467ffffffffffffffff1690565b34801561042057600080fd5b507fb5d556f07587ec0f08cf386545cc4362c702a001650c2058002615ee5c9d1e756101d4565b34801561045357600080fd5b50610207610462366004613671565b6110ca565b34801561047357600080fd5b50610207610482366004613671565b60009081526033602052604090205467ffffffffffffffff1690565b3480156104aa57600080fd5b506104cd6104b9366004613671565b600090815260326020526040902054151590565b60405190151581526020016101de565b3480156104e957600080fd5b506102076104f83660046134c8565b6110d8565b34801561050957600080fd5b506101d4611110565b34801561051e57600080fd5b5060405173420000000000000000000000000000000000002081526020016101de565b6101d461054f3660046137c3565b61111a565b348160005b818110156106e4577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82018114600086868481811061059a5761059a6137fe565b90506020028101906105ac919061382d565b6105b590613ac3565b60208101518051919250908015806105d257508260400151518114155b15610609576040517f947d5a8400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b818110156106ad576106a56040518060a001604052808660000151815260200185848151811061063e5761063e6137fe565b6020026020010151815260200186604001518481518110610661576106616137fe565b60200260200101518152602001866060015173ffffffffffffffffffffffffffffffffffffffff168152602001866080015167ffffffffffffffff168152506111d8565b60010161060c565b506106c383600001518385606001518a886113e9565b6106cd9088613bed565b9650505050506106dd8160010190565b9050610559565b5050505050565b60004282825b818110156107245761071c3387878481811061070f5761070f6137fe565b9050602002013585611a18565b6001016106f1565b50909150505b92915050565b606061075b7f0000000000000000000000000000000000000000000000000000000000000000611b17565b905090565b600061077361076e83613d22565b611ca5565b604080516001808252818301909252600091816020015b6040805160c081018252600080825260208083018290529282018190526060808301829052608083015260a082015282527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90920191018161078a5790505090506107f86020840184613d9d565b61080190613dd1565b81600081518110610814576108146137fe565b602090810291909101015261083d83358261083560c0870160a088016135bd565b346001611e2f565b60200151600081518110610853576108536137fe565b6020026020010151915050919050565b60608160008167ffffffffffffffff8111156108815761088161386b565b6040519080825280602002602001820160405280156108b457816020015b606081526020019060019003908161089f5790505b509050600034815b848110156109ce577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff85018114368989848181106108fc576108fc6137fe565b905060200281019061090e9190613ddd565b905061091d6020820182613e11565b9050600003610958576040517f947d5a8400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061097d823561096c6020850185613e11565b61097591613e79565b338887611e2f565b805190915061098c9086613bed565b945080602001518785815181106109a5576109a56137fe565b6020026020010181905250806020015151860195505050506109c78160010190565b90506108bc565b506109d98383612541565b979650505050505050565b604080516001808252818301909252600091816020015b60408051808201909152600080825260208201528152602001906001900390816109fb579050509050610a3636839003830160208401613eed565b81600081518110610a4957610a496137fe565b6020908102919091010152610a63823582333460016113e9565b505050565b348160005b818110156106e4577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8201811436868684818110610aad57610aad6137fe565b9050602002810190610abf9190613ddd565b9050610b2c8135610ad36020840184613f09565b808060200260200160405190810160405280939291908181526020016000905b82821015610b1f57610b1060408302860136819003810190613eed565b81526020019060010190610af3565b50505050503388866113e9565b610b369086613bed565b94505050610b448160010190565b9050610a6d565b60004261072a838261262b565b33600090815260208190526040902054808211610ba1576040517f756688fe00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152602081815260409182902084905581518381529081018490527f57b09af877df9068fd60a69d7b21f5576b8b38955812d6ae4ac52942f1e38fb7910160405180910390a15050565b60608160008167ffffffffffffffff811115610c0d57610c0d61386b565b604051908082528060200260200182016040528015610c4057816020015b6060815260200190600190039081610c2b5790505b509050600034815b848110156109ce577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8501811436898984818110610c8857610c886137fe565b9050602002810190610c9a919061382d565b9050366000610cac6020840184613e11565b909250905080801580610ccd5750610cc76040850185613f71565b90508114155b15610d04576040517f947d5a8400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b81811015610de557610ddd6040518060a0016040528087600001358152602001868685818110610d3957610d396137fe565b9050602002810190610d4b9190613d9d565b610d5490613dd1565b8152602001610d666040890189613f71565b85818110610d7657610d766137fe565b905060600201803603810190610d8c9190613fd8565b8152602001610da16080890160608a016135bd565b73ffffffffffffffffffffffffffffffffffffffff168152602001610dcc60a0890160808a01613ff4565b67ffffffffffffffff169052611ca5565b600101610d07565b506000610e0e8535610df78587613e79565b610e076080890160608a016135bd565b8b8a611e2f565b8051909150610e1d9089613bed565b975080602001518a8881518110610e3657610e366137fe565b602002602001018190525080602001515189019850505050505050610e5b8160010190565b9050610c48565b604080516101408101825260008082526020820181905291810182905260608082018390526080820183905260a0820183905260c0820183905260e0820183905261010082019290925261012081019190915260008281526032602090815260409182902082516101408101845281548152600182015492810192909252600281015467ffffffffffffffff808216948401949094526801000000000000000081048416606084015270010000000000000000000000000000000090049092166080820152600382015460a0820152600482015473ffffffffffffffffffffffffffffffffffffffff90811660c0830152600583015490811660e083015274010000000000000000000000000000000000000000900460ff16151561010082015260068201805491929161012084019190610f9c9061400f565b80601f0160208091040260200160405190810160405280929190818152602001828054610fc89061400f565b80156110155780601f10610fea57610100808354040283529160200191611015565b820191906000526020600020905b815481529060010190602001808311610ff857829003601f168201915b5050505050815250509050919050565b61103c6110373683900383018361405c565b6111d8565b604080516001808252818301909252600091816020015b604080518082019091526000808252602082015281526020019060019003908161105357905050905061108e36839003830160208401613eed565b816000815181106110a1576110a16137fe565b6020908102919091010152610a638235826110c260e0860160c087016135bd565b3460016113e9565b60004261072a338483611a18565b60004282825b81811015610724576111088686838181106110fb576110fb6137fe565b905060200201358461262b565b6001016110de565b600061075b6126ed565b604080516001808252818301909252600091829190816020015b6040805160c081018252600080825260208083018290529282018190526060808301829052608083015260a082015282527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9092019101816111345790505090506111a26020840184613d9d565b6111ab90613dd1565b816000815181106111be576111be6137fe565b602090810291909101015261083d83358233346001611e2f565b608081015167ffffffffffffffff161580159061120c57504267ffffffffffffffff16816080015167ffffffffffffffff16105b15611243576040517f1ab7da6b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6020808201516040808401516060850151855184518587015173ffffffffffffffffffffffffffffffffffffffff84166000908152978890529487208054969794969495611337957fb5d556f07587ec0f08cf386545cc4362c702a001650c2058002615ee5c9d1e7595949392886112ba836140ca565b909155506080808c015160408051602081019990995273ffffffffffffffffffffffffffffffffffffffff9097169688019690965260608701949094529285019190915260a084015260c083015267ffffffffffffffff1660e0820152610100015b60405160208183030381529060405280519060200120612821565b90506113ad84606001518284602001518560400151866000015160405160200161139993929190928352602083019190915260f81b7fff0000000000000000000000000000000000000000000000000000000000000016604082015260410190565b604051602081830303815290604052612834565b6113e3576040517f8baa579f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b50505050565b6040517fa2ea7c6e0000000000000000000000000000000000000000000000000000000081526004810186905260009081907342000000000000000000000000000000000000209063a2ea7c6e90602401600060405180830381865afa158015611457573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016820160405261149d9190810190614102565b80519091506114d8576040517fbf37b20e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b855160008167ffffffffffffffff8111156114f5576114f561386b565b60405190808252806020026020018201604052801561159457816020015b60408051610140810182526000808252602080830182905292820181905260608083018290526080830182905260a0830182905260c0830182905260e0830182905261010083019190915261012082015282527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9092019101816115135790505b50905060008267ffffffffffffffff8111156115b2576115b261386b565b6040519080825280602002602001820160405280156115db578160200160208202803683370190505b50905060005b838110156119fa5760008a82815181106115fd576115fd6137fe565b6020908102919091018101518051600090815260329092526040909120805491925090611656576040517fc5723b5100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8c816001015414611693576040517fbf37b20e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600581015473ffffffffffffffffffffffffffffffffffffffff8c81169116146116e9576040517f4ca8886700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600581015474010000000000000000000000000000000000000000900460ff1661173f576040517f157bd4c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6002810154700100000000000000000000000000000000900467ffffffffffffffff1615611799576040517f905e710700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b426002820180547fffffffffffffffff0000000000000000ffffffffffffffffffffffffffffffff811670010000000000000000000000000000000067ffffffffffffffff948516810291821793849055604080516101408101825287548152600188015460208201529386169286169290921791830191909152680100000000000000008304841660608301529091049091166080820152600382015460a0820152600482015473ffffffffffffffffffffffffffffffffffffffff90811660c0830152600583015490811660e083015274010000000000000000000000000000000000000000900460ff16151561010082015260068201805483916101208401916118a59061400f565b80601f01602080910402602001604051908101604052809291908181526020018280546118d19061400f565b801561191e5780601f106118f35761010080835404028352916020019161191e565b820191906000526020600020905b81548152906001019060200180831161190157829003601f168201915b505050505081525050858481518110611939576119396137fe565b6020026020010181905250816020015184848151811061195b5761195b6137fe565b6020026020010181815250508c8b73ffffffffffffffffffffffffffffffffffffffff16868581518110611991576119916137fe565b602002602001015160c0015173ffffffffffffffffffffffffffffffffffffffff167ff930a6e2523c9cc298691873087a740550b8fc85a0680830414c148ed927f61585600001516040516119e891815260200190565b60405180910390a450506001016115e1565b50611a0a84838360018b8b612a03565b9a9950505050505050505050565b73ffffffffffffffffffffffffffffffffffffffff83166000908152603460209081526040808320858452918290529091205467ffffffffffffffff1615611a8c576040517fec9d6eeb00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008381526020829052604080822080547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000001667ffffffffffffffff861690811790915590519091859173ffffffffffffffffffffffffffffffffffffffff8816917f92a1f7a41a7c585a8b09e25b195e225b1d43248daca46b0faf9e0792777a222991a450505050565b604080516020808252818301909252606091600091906020820181803683370190505090506000805b6020811015611be2576000858260208110611b5d57611b5d6137fe565b1a60f81b90507fff000000000000000000000000000000000000000000000000000000000000008116600003611b935750611be2565b80848481518110611ba657611ba66137fe565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053505060019182019101611b40565b5060008167ffffffffffffffff811115611bfe57611bfe61386b565b6040519080825280601f01601f191660200182016040528015611c28576020820181803683370190505b50905060005b82811015611c9c57838181518110611c4857611c486137fe565b602001015160f81c60f81b828281518110611c6557611c656137fe565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350600101611c2e565b50949350505050565b608081015167ffffffffffffffff1615801590611cd957504267ffffffffffffffff16816080015167ffffffffffffffff16105b15611d10576040517f1ab7da6b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6020808201516040808401516060808601518651855186880151868801519488015160808901518051908b012060a08a015173ffffffffffffffffffffffffffffffffffffffff871660009081529b8c9052988b2080549a9b989a9899611337997ffeb2925a02bae3dae48d424a0437a2b6ac939aa9230ddc55a1a76f065d988076999493928c611da0836140ca565b919050558e6080015160405160200161131c9b9a999897969594939291909a8b5273ffffffffffffffffffffffffffffffffffffffff998a1660208c015260408b019890985295909716606089015267ffffffffffffffff938416608089015291151560a088015260c087015260e0860152610100850193909352610120840152166101408201526101600190565b60408051808201909152600081526060602082015284516040805180820190915260008152606060208201528167ffffffffffffffff811115611e7457611e7461386b565b604051908082528060200260200182016040528015611e9d578160200160208202803683370190505b5060208201526040517fa2ea7c6e000000000000000000000000000000000000000000000000000000008152600481018990526000907342000000000000000000000000000000000000209063a2ea7c6e90602401600060405180830381865afa158015611f0f573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052611f559190810190614102565b8051909150611f90576040517fbf37b20e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008367ffffffffffffffff811115611fab57611fab61386b565b60405190808252806020026020018201604052801561204a57816020015b60408051610140810182526000808252602080830182905292820181905260608083018290526080830182905260a0830182905260c0830182905260e0830182905261010083019190915261012082015282527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff909201910181611fc95790505b50905060008467ffffffffffffffff8111156120685761206861386b565b604051908082528060200260200182016040528015612091578160200160208202803683370190505b50905060005b858110156125205760008b82815181106120b3576120b36137fe565b60200260200101519050600067ffffffffffffffff16816020015167ffffffffffffffff16141580156120fe57504267ffffffffffffffff16816020015167ffffffffffffffff1611155b15612135576040517f08e8b93700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8460400151158015612148575080604001515b1561217f576040517f157bd4c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006040518061014001604052806000801b81526020018f81526020016121a34290565b67ffffffffffffffff168152602001836020015167ffffffffffffffff168152602001600067ffffffffffffffff16815260200183606001518152602001836000015173ffffffffffffffffffffffffffffffffffffffff1681526020018d73ffffffffffffffffffffffffffffffffffffffff16815260200183604001511515815260200183608001518152509050600080600090505b6122458382612df4565b600081815260326020526040902054909250156122645760010161223b565b81835260008281526032602090815260409182902085518155908501516001820155908401516002820180546060870151608088015167ffffffffffffffff908116700100000000000000000000000000000000027fffffffffffffffff0000000000000000ffffffffffffffffffffffffffffffff92821668010000000000000000027fffffffffffffffffffffffffffffffff000000000000000000000000000000009094169190951617919091171691909117905560a0840151600382015560c084015160048201805473ffffffffffffffffffffffffffffffffffffffff9283167fffffffffffffffffffffffff000000000000000000000000000000000000000090911617905560e0850151600583018054610100880151151574010000000000000000000000000000000000000000027fffffffffffffffffffffff000000000000000000000000000000000000000000909116929093169190911791909117905561012084015184919060068201906123e49082614228565b50505060608401511561243b57606084015160009081526032602052604090205461243b576040517fc5723b5100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8287868151811061244e5761244e6137fe565b60200260200101819052508360a00151868681518110612470576124706137fe565b6020026020010181815250508189602001518681518110612493576124936137fe565b6020026020010181815250508f8e73ffffffffffffffffffffffffffffffffffffffff16856000015173ffffffffffffffffffffffffffffffffffffffff167f8bf46bf4cfd674fa735a3d63ec1c9ad4153f033c290341f3a588b75685141b358560405161250391815260200190565b60405180910390a4505050506125198160010190565b9050612097565b5061253083838360008c8c612a03565b845250919998505050505050505050565b606060008267ffffffffffffffff81111561255e5761255e61386b565b604051908082528060200260200182016040528015612587578160200160208202803683370190505b508451909150600090815b818110156126205760008782815181106125ae576125ae6137fe565b6020026020010151905060008151905060005b8181101561260c578281815181106125db576125db6137fe565b60200260200101518787815181106125f5576125f56137fe565b6020908102919091010152600195860195016125c1565b5050506126198160010190565b9050612592565b509195945050505050565b60008281526033602052604090205467ffffffffffffffff161561267b576040517f2e26794600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008281526033602052604080822080547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000001667ffffffffffffffff85169081179091559051909184917f5aafceeb1c7ad58e4a84898bdee37c02c0fc46e7d24e6b60e8209449f183459f9190a35050565b60003073ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614801561275357507f000000000000000000000000000000000000000000000000000000000000000046145b1561277d57507f000000000000000000000000000000000000000000000000000000000000000090565b50604080517f00000000000000000000000000000000000000000000000000000000000000006020808301919091527f0000000000000000000000000000000000000000000000000000000000000000828401527f000000000000000000000000000000000000000000000000000000000000000060608301524660808301523060a0808401919091528351808403909101815260c0909201909252805191012090565b600061072a61282e6126ed565b83612e53565b60008060006128438585612e95565b9092509050600081600481111561285c5761285c614342565b14801561289457508573ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16145b156128a4576001925050506129fc565b6000808773ffffffffffffffffffffffffffffffffffffffff16631626ba7e60e01b88886040516024016128d9929190614371565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009094169390931790925290516129629190614392565b600060405180830381855afa9150503d806000811461299d576040519150601f19603f3d011682016040523d82523d6000602084013e6129a2565b606091505b50915091508180156129b5575080516020145b80156129f5575080517f1626ba7e00000000000000000000000000000000000000000000000000000000906129f390830160209081019084016143a4565b145b9450505050505b9392505050565b84516000906001819003612a5b57612a538888600081518110612a2857612a286137fe565b602002602001015188600081518110612a4357612a436137fe565b6020026020010151888888612eda565b915050612dea565b602088015173ffffffffffffffffffffffffffffffffffffffff8116612afc5760005b82811015612ae157878181518110612a9857612a986137fe565b6020026020010151600014612ad9576040517f1574f9f300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600101612a7e565b508315612af157612af1856131f9565b600092505050612dea565b6000808273ffffffffffffffffffffffffffffffffffffffff1663ce46e0466040518163ffffffff1660e01b8152600401602060405180830381865afa158015612b4a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612b6e91906143bd565b905060005b84811015612c2b5760008a8281518110612b8f57612b8f6137fe565b6020026020010151905080600003612ba75750612c23565b82612bde576040517f1574f9f300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b88811115612c18576040517f1101129400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b978890039792909201915b600101612b73565b508715612d06576040517f88e5b2d900000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8416906388e5b2d9908490612c88908e908e906004016143da565b60206040518083038185885af1158015612ca6573d6000803e3d6000fd5b50505050506040513d601f19601f82011682018060405250810190612ccb91906143bd565b612d01576040517fbf2f3a8b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b612dd5565b6040517f91db0b7e00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8416906391db0b7e908490612d5c908e908e906004016143da565b60206040518083038185885af1158015612d7a573d6000803e3d6000fd5b50505050506040513d601f19601f82011682018060405250810190612d9f91906143bd565b612dd5576040517fe8bee83900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8515612de457612de4876131f9565b50925050505b9695505050505050565b60208083015160c084015160e0850151604080870151606088015161010089015160a08a01516101208b01519451600099612e3599989796918c9101614493565b60405160208183030381529060405280519060200120905092915050565b6040517f190100000000000000000000000000000000000000000000000000000000000060208201526022810183905260428101829052600090606201612e35565b6000808251604103612ecb5760208301516040840151606085015160001a612ebf8782858561320c565b94509450505050612ed3565b506000905060025b9250929050565b602086015160009073ffffffffffffffffffffffffffffffffffffffff8116612f4e578515612f35576040517f1574f9f300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8215612f4457612f44846131f9565b6000915050612dea565b8515613039578073ffffffffffffffffffffffffffffffffffffffff1663ce46e0466040518163ffffffff1660e01b8152600401602060405180830381865afa158015612f9f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612fc391906143bd565b612ff9576040517f1574f9f300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b83861115613033576040517f1101129400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b85840393505b8415613111576040517fe49617e100000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82169063e49617e1908890613093908b90600401613771565b60206040518083038185885af11580156130b1573d6000803e3d6000fd5b50505050506040513d601f19601f820116820180604052508101906130d691906143bd565b61310c576040517fccf3bb2700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6131de565b6040517fe60c350500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82169063e60c3505908890613165908b90600401613771565b60206040518083038185885af1158015613183573d6000803e3d6000fd5b50505050506040513d601f19601f820116820180604052508101906131a891906143bd565b6131de576040517fbd8ba84d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b82156131ed576131ed846131f9565b50939695505050505050565b8015613209576132093382613324565b50565b6000807f7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a0831115613243575060009050600361331b565b8460ff16601b1415801561325b57508460ff16601c14155b1561326c575060009050600461331b565b6040805160008082526020820180845289905260ff881692820192909252606081018690526080810185905260019060a0016020604051602081039080840390855afa1580156132c0573d6000803e3d6000fd5b50506040517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0015191505073ffffffffffffffffffffffffffffffffffffffff81166133145760006001925092505061331b565b9150600090505b94509492505050565b80471015613393576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a20696e73756666696369656e742062616c616e636500000060448201526064015b60405180910390fd5b60008273ffffffffffffffffffffffffffffffffffffffff168260405160006040518083038185875af1925050503d80600081146133ed576040519150601f19603f3d011682016040523d82523d6000602084013e6133f2565b606091505b5050905080610a63576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603a60248201527f416464726573733a20756e61626c6520746f2073656e642076616c75652c207260448201527f6563697069656e74206d61792068617665207265766572746564000000000000606482015260840161338a565b60008083601f84011261349557600080fd5b50813567ffffffffffffffff8111156134ad57600080fd5b6020830191508360208260051b8501011115612ed357600080fd5b600080602083850312156134db57600080fd5b823567ffffffffffffffff8111156134f257600080fd5b6134fe85828601613483565b90969095509350505050565b60005b8381101561352557818101518382015260200161350d565b50506000910152565b6000815180845261354681602086016020860161350a565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b6020815260006129fc602083018461352e565b73ffffffffffffffffffffffffffffffffffffffff8116811461320957600080fd5b80356135b88161358b565b919050565b6000602082840312156135cf57600080fd5b81356129fc8161358b565b6000602082840312156135ec57600080fd5b813567ffffffffffffffff81111561360357600080fd5b820160e081850312156129fc57600080fd5b6020808252825182820181905260009190848201906040850190845b8181101561364d57835183529284019291840191600101613631565b50909695505050505050565b60006060828403121561366b57600080fd5b50919050565b60006020828403121561368357600080fd5b5035919050565b6000610140825184526020830151602085015260408301516136b8604086018267ffffffffffffffff169052565b5060608301516136d4606086018267ffffffffffffffff169052565b5060808301516136f0608086018267ffffffffffffffff169052565b5060a083015160a085015260c083015161372260c086018273ffffffffffffffffffffffffffffffffffffffff169052565b5060e083015161374a60e086018273ffffffffffffffffffffffffffffffffffffffff169052565b506101008381015115159085015261012080840151818601839052612dea8387018261352e565b6020815260006129fc602083018461368a565b6000610100828403121561366b57600080fd5b600080604083850312156137aa57600080fd5b82356137b58161358b565b946020939093013593505050565b6000602082840312156137d557600080fd5b813567ffffffffffffffff8111156137ec57600080fd5b8201604081850312156129fc57600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600082357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff6183360301811261386157600080fd5b9190910192915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60405160a0810167ffffffffffffffff811182821017156138bd576138bd61386b565b60405290565b60405160c0810167ffffffffffffffff811182821017156138bd576138bd61386b565b6040516080810167ffffffffffffffff811182821017156138bd576138bd61386b565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156139505761395061386b565b604052919050565b600067ffffffffffffffff8211156139725761397261386b565b5060051b60200190565b60006040828403121561398e57600080fd5b6040516040810181811067ffffffffffffffff821117156139b1576139b161386b565b604052823581526020928301359281019290925250919050565b6000606082840312156139dd57600080fd5b6040516060810181811067ffffffffffffffff82111715613a0057613a0061386b565b604052905080823560ff81168114613a1757600080fd5b8082525060208301356020820152604083013560408201525092915050565b600082601f830112613a4757600080fd5b81356020613a5c613a5783613958565b613909565b82815260609283028501820192828201919087851115613a7b57600080fd5b8387015b85811015613a9e57613a9189826139cb565b8452928401928101613a7f565b5090979650505050505050565b803567ffffffffffffffff811681146135b857600080fd5b600060a08236031215613ad557600080fd5b613add61389a565b8235815260208084013567ffffffffffffffff80821115613afd57600080fd5b9085019036601f830112613b1057600080fd5b8135613b1e613a5782613958565b81815260069190911b83018401908481019036831115613b3d57600080fd5b938501935b82851015613b6657613b54368661397c565b82528582019150604085019450613b42565b80868801525050506040860135925080831115613b8257600080fd5b5050613b9036828601613a36565b604083015250613ba2606084016135ad565b6060820152613bb360808401613aab565b608082015292915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b8181038181111561072a5761072a613bbe565b801515811461320957600080fd5b600067ffffffffffffffff821115613c2857613c2861386b565b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01660200190565b600060c08284031215613c6657600080fd5b613c6e6138c3565b90508135613c7b8161358b565b81526020613c8a838201613aab565b818301526040830135613c9c81613c00565b604083015260608381013590830152608083013567ffffffffffffffff811115613cc557600080fd5b8301601f81018513613cd657600080fd5b8035613ce4613a5782613c0e565b8181528684838501011115613cf857600080fd5b818484018583013760008483830101528060808601525050505060a082013560a082015292915050565b600060e08236031215613d3457600080fd5b613d3c61389a565b82358152602083013567ffffffffffffffff811115613d5a57600080fd5b613d6636828601613c54565b602083015250613d7936604085016139cb565b604082015260a0830135613d8c8161358b565b6060820152613bb360c08401613aab565b600082357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff4183360301811261386157600080fd5b600061072a3683613c54565b600082357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc183360301811261386157600080fd5b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112613e4657600080fd5b83018035915067ffffffffffffffff821115613e6157600080fd5b6020019150600581901b3603821315612ed357600080fd5b6000613e87613a5784613958565b80848252602080830192508560051b850136811115613ea557600080fd5b855b81811015613ee157803567ffffffffffffffff811115613ec75760008081fd5b613ed336828a01613c54565b865250938201938201613ea7565b50919695505050505050565b600060408284031215613eff57600080fd5b6129fc838361397c565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112613f3e57600080fd5b83018035915067ffffffffffffffff821115613f5957600080fd5b6020019150600681901b3603821315612ed357600080fd5b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112613fa657600080fd5b83018035915067ffffffffffffffff821115613fc157600080fd5b6020019150606081023603821315612ed357600080fd5b600060608284031215613fea57600080fd5b6129fc83836139cb565b60006020828403121561400657600080fd5b6129fc82613aab565b600181811c9082168061402357607f821691505b60208210810361366b577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b6000610100828403121561406f57600080fd5b61407761389a565b82358152614088846020850161397c565b602082015261409a84606085016139cb565b604082015260c08301356140ad8161358b565b60608201526140be60e08401613aab565b60808201529392505050565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036140fb576140fb613bbe565b5060010190565b6000602080838503121561411557600080fd5b825167ffffffffffffffff8082111561412d57600080fd5b908401906080828703121561414157600080fd5b6141496138e6565b825181528383015161415a8161358b565b81850152604083015161416c81613c00565b604082015260608301518281111561418357600080fd5b80840193505086601f84011261419857600080fd5b825191506141a8613a5783613c0e565b82815287858486010111156141bc57600080fd5b6141cb8386830187870161350a565b60608201529695505050505050565b601f821115610a6357600081815260208120601f850160051c810160208610156142015750805b601f850160051c820191505b818110156142205782815560010161420d565b505050505050565b815167ffffffffffffffff8111156142425761424261386b565b61425681614250845461400f565b846141da565b602080601f8311600181146142a957600084156142735750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b178555614220565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b828110156142f6578886015182559484019460019091019084016142d7565b508582101561433257878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b82815260406020820152600061438a604083018461352e565b949350505050565b6000825161386181846020870161350a565b6000602082840312156143b657600080fd5b5051919050565b6000602082840312156143cf57600080fd5b81516129fc81613c00565b6000604082016040835280855180835260608501915060608160051b8601019250602080880160005b8381101561444f577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa088870301855261443d86835161368a565b95509382019390820190600101614403565b50508584038187015286518085528782019482019350915060005b828110156144865784518452938101939281019260010161446a565b5091979650505050505050565b89815260007fffffffffffffffffffffffffffffffffffffffff000000000000000000000000808b60601b166020840152808a60601b166034840152507fffffffffffffffff000000000000000000000000000000000000000000000000808960c01b166048840152808860c01b1660508401525085151560f81b6058830152846059830152835161452c81607985016020880161350a565b80830190507fffffffff000000000000000000000000000000000000000000000000000000008460e01b166079820152607d81019150509a995050505050505050505056fea164736f6c6343000813000a" func init() { if err := json.Unmarshal([]byte(EASStorageLayoutJSON), EASStorageLayout); err != nil { diff --git a/op-bindings/bindings/faultdisputegame.go b/op-bindings/bindings/faultdisputegame.go index b2b9ee9c1e6e1..9790cadb0d559 100644 --- a/op-bindings/bindings/faultdisputegame.go +++ b/op-bindings/bindings/faultdisputegame.go @@ -37,8 +37,8 @@ type IFaultDisputeGameOutputProposal struct { // FaultDisputeGameMetaData contains all meta data concerning the FaultDisputeGame contract. var FaultDisputeGameMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"GameType\",\"name\":\"_gameType\",\"type\":\"uint8\"},{\"internalType\":\"Claim\",\"name\":\"_absolutePrestate\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"_maxGameDepth\",\"type\":\"uint256\"},{\"internalType\":\"Duration\",\"name\":\"_gameDuration\",\"type\":\"uint64\"},{\"internalType\":\"contractIBigStepper\",\"name\":\"_vm\",\"type\":\"address\"},{\"internalType\":\"contractL2OutputOracle\",\"name\":\"_l2oo\",\"type\":\"address\"},{\"internalType\":\"contractBlockOracle\",\"name\":\"_blockOracle\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"CannotDefendRootClaim\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ClaimAlreadyExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ClaimAlreadyResolved\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ClockNotExpired\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ClockTimeExceeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GameDepthExceeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GameNotInProgress\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidParent\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidPrestate\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"L1HeadTooOld\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OutOfOrderResolution\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"Claim\",\"name\":\"rootClaim\",\"type\":\"bytes32\"}],\"name\":\"UnexpectedRootClaim\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ValidStep\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"parentIndex\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"Claim\",\"name\":\"claim\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"claimant\",\"type\":\"address\"}],\"name\":\"Move\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"enumGameStatus\",\"name\":\"status\",\"type\":\"uint8\"}],\"name\":\"Resolved\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"ABSOLUTE_PRESTATE\",\"outputs\":[{\"internalType\":\"Claim\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"BLOCK_ORACLE\",\"outputs\":[{\"internalType\":\"contractBlockOracle\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"GAME_DURATION\",\"outputs\":[{\"internalType\":\"Duration\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"L2_OUTPUT_ORACLE\",\"outputs\":[{\"internalType\":\"contractL2OutputOracle\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MAX_GAME_DEPTH\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"VM\",\"outputs\":[{\"internalType\":\"contractIBigStepper\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_ident\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_partOffset\",\"type\":\"uint256\"}],\"name\":\"addLocalData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_parentIndex\",\"type\":\"uint256\"},{\"internalType\":\"Claim\",\"name\":\"_claim\",\"type\":\"bytes32\"}],\"name\":\"attack\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"bondManager\",\"outputs\":[{\"internalType\":\"contractIBondManager\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"claimData\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"parentIndex\",\"type\":\"uint32\"},{\"internalType\":\"bool\",\"name\":\"countered\",\"type\":\"bool\"},{\"internalType\":\"Claim\",\"name\":\"claim\",\"type\":\"bytes32\"},{\"internalType\":\"Position\",\"name\":\"position\",\"type\":\"uint128\"},{\"internalType\":\"Clock\",\"name\":\"clock\",\"type\":\"uint128\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"claimDataLen\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"len_\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createdAt\",\"outputs\":[{\"internalType\":\"Timestamp\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_parentIndex\",\"type\":\"uint256\"},{\"internalType\":\"Claim\",\"name\":\"_claim\",\"type\":\"bytes32\"}],\"name\":\"defend\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"extraData\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"extraData_\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"gameData\",\"outputs\":[{\"internalType\":\"GameType\",\"name\":\"gameType_\",\"type\":\"uint8\"},{\"internalType\":\"Claim\",\"name\":\"rootClaim_\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"extraData_\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"gameType\",\"outputs\":[{\"internalType\":\"GameType\",\"name\":\"gameType_\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"initialize\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"l1BlockNumber\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"l1BlockNumber_\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"l1Head\",\"outputs\":[{\"internalType\":\"Hash\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"l2BlockNumber\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"l2BlockNumber_\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_challengeIndex\",\"type\":\"uint256\"},{\"internalType\":\"Claim\",\"name\":\"_claim\",\"type\":\"bytes32\"},{\"internalType\":\"bool\",\"name\":\"_isAttack\",\"type\":\"bool\"}],\"name\":\"move\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"proposals\",\"outputs\":[{\"components\":[{\"internalType\":\"uint128\",\"name\":\"index\",\"type\":\"uint128\"},{\"internalType\":\"uint128\",\"name\":\"l2BlockNumber\",\"type\":\"uint128\"},{\"internalType\":\"Hash\",\"name\":\"outputRoot\",\"type\":\"bytes32\"}],\"internalType\":\"structIFaultDisputeGame.OutputProposal\",\"name\":\"starting\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint128\",\"name\":\"index\",\"type\":\"uint128\"},{\"internalType\":\"uint128\",\"name\":\"l2BlockNumber\",\"type\":\"uint128\"},{\"internalType\":\"Hash\",\"name\":\"outputRoot\",\"type\":\"bytes32\"}],\"internalType\":\"structIFaultDisputeGame.OutputProposal\",\"name\":\"disputed\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"resolve\",\"outputs\":[{\"internalType\":\"enumGameStatus\",\"name\":\"status_\",\"type\":\"uint8\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_claimIndex\",\"type\":\"uint256\"}],\"name\":\"resolveClaim\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"rootClaim\",\"outputs\":[{\"internalType\":\"Claim\",\"name\":\"rootClaim_\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"status\",\"outputs\":[{\"internalType\":\"enumGameStatus\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_claimIndex\",\"type\":\"uint256\"},{\"internalType\":\"bool\",\"name\":\"_isAttack\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"_stateData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"_proof\",\"type\":\"bytes\"}],\"name\":\"step\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"version\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", - Bin: "0x6101606040523480156200001257600080fd5b5060405162002b1f38038062002b1f83398101604081905262000035916200008f565b60ff9096166101405260809490945260a0929092526001600160401b031660c0526001600160a01b0390811660e05290811661010052166101205262000133565b6001600160a01b03811681146200008c57600080fd5b50565b600080600080600080600060e0888a031215620000ab57600080fd5b875160ff81168114620000bd57600080fd5b602089015160408a015160608b015192995090975095506001600160401b0381168114620000ea57600080fd5b6080890151909450620000fd8162000076565b60a0890151909350620001108162000076565b60c0890151909250620001238162000076565b8091505092959891949750929550565b60805160a05160c05160e05161010051610120516101405161293d620001e2600039600081816105610152611c3b01526000818161036901526114bc0152600081816105da015281816112890152818161135d015261143601526000818161052b0152818161079701526119ba01526000818161060e01528181610d850152611d2a01526000818161033501528181610bc401526117b901526000818161022c0152611915015261293d6000f3fe6080604052600436106101b75760003560e01c80638129fc1c116100ec578063c31b29ce1161008a578063cf09e0d011610064578063cf09e0d0146106c0578063d8cc1a3c146106e1578063fa24f74314610701578063fdffbb281461072557600080fd5b8063c31b29ce146105fc578063c55cd0c714610649578063c6f0308c1461065c57600080fd5b806392931298116100c65780639293129814610519578063bbdc02db1461054d578063bcef3b551461058b578063c0c3a092146105c857600080fd5b80638129fc1c146104af5780638980e0cc146104c45780638b85902b146104d957600080fd5b80634778efe81161015957806355ef20e61161013357806355ef20e6146103e1578063609d333414610471578063632247ea146104865780636361506d1461049957600080fd5b80634778efe814610323578063529184c91461035757806354fd4d501461038b57600080fd5b80632810e1d6116101955780632810e1d61461025c578063298c90051461027157806335fef567146102b1578063363cc427146102c457600080fd5b80631e27052a146101bc578063200d2ed2146101de578063266198f91461021a575b600080fd5b3480156101c857600080fd5b506101dc6101d736600461228f565b610738565b005b3480156101ea57600080fd5b506000546102049068010000000000000000900460ff1681565b60405161021191906122e0565b60405180910390f35b34801561022657600080fd5b5061024e7f000000000000000000000000000000000000000000000000000000000000000081565b604051908152602001610211565b34801561026857600080fd5b506102046108f7565b34801561027d57600080fd5b50367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c90036040013561024e565b6101dc6102bf36600461228f565b610a5b565b3480156102d057600080fd5b506000546102fe906901000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610211565b34801561032f57600080fd5b5061024e7f000000000000000000000000000000000000000000000000000000000000000081565b34801561036357600080fd5b506102fe7f000000000000000000000000000000000000000000000000000000000000000081565b34801561039757600080fd5b506103d46040518060400160405280600681526020017f302e302e3130000000000000000000000000000000000000000000000000000081525081565b604051610211919061238c565b3480156103ed57600080fd5b5060408051606080820183526003546fffffffffffffffffffffffffffffffff808216845270010000000000000000000000000000000091829004811660208086019190915260045485870152855193840186526005548083168552929092041690820152600654928101929092526104639182565b6040516102119291906123a6565b34801561047d57600080fd5b506103d4610a6b565b6101dc61049436600461240f565b610a79565b3480156104a557600080fd5b5061024e60015481565b3480156104bb57600080fd5b506101dc61108f565b3480156104d057600080fd5b5060025461024e565b3480156104e557600080fd5b50367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c90036020013561024e565b34801561052557600080fd5b506102fe7f000000000000000000000000000000000000000000000000000000000000000081565b34801561055957600080fd5b5060405160ff7f0000000000000000000000000000000000000000000000000000000000000000168152602001610211565b34801561059757600080fd5b50367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c90033561024e565b3480156105d457600080fd5b506102fe7f000000000000000000000000000000000000000000000000000000000000000081565b34801561060857600080fd5b506106307f000000000000000000000000000000000000000000000000000000000000000081565b60405167ffffffffffffffff9091168152602001610211565b6101dc61065736600461228f565b611693565b34801561066857600080fd5b5061067c610677366004612444565b61169f565b6040805163ffffffff90961686529315156020860152928401919091526fffffffffffffffffffffffffffffffff908116606084015216608082015260a001610211565b3480156106cc57600080fd5b506000546106309067ffffffffffffffff1681565b3480156106ed57600080fd5b506101dc6106fc3660046124a6565b611710565b34801561070d57600080fd5b50610716611c39565b60405161021193929190612530565b6101dc610733366004612444565b611c96565b6000805468010000000000000000900460ff16600281111561075c5761075c6122b1565b14610793576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60007f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16637dc0d1d06040518163ffffffff1660e01b8152600401602060405180830381865afa158015610800573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610824919061255b565b7f9a1f5e7f00000000000000000000000000000000000000000000000000000000601c81905260208590529091506000846001811461088b5760028114610895576003811461089f57600481146108a957600581146108b95763ff137e656000526004601cfd5b60015491506108c0565b60045491506108c0565b60065491506108c0565b60035460801c60c01b91506108c0565b4660c01b91505b50604052600160038511811b6005031b60605260808390526000806084601c82865af16108f1573d6000803e3d6000fd5b50505050565b60008060005468010000000000000000900460ff16600281111561091d5761091d6122b1565b14610954576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60095460ff16610990576040517f9a07664600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60026000815481106109a4576109a4612591565b6000918252602090912060039091020154640100000000900460ff166109cb5760026109ce565b60015b6000805491925082917fffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff1668010000000000000000836002811115610a1557610a156122b1565b021790556002811115610a2a57610a2a6122b1565b6040517f5e186f09b9c93491f14e277eea7faa5de6a2d4bda75a79af7a3684fbfb42da6090600090a290565b905090565b610a6782826000610a79565b5050565b6060610a5660206040611fc7565b6000805468010000000000000000900460ff166002811115610a9d57610a9d6122b1565b14610ad4576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b82158015610ae0575080155b15610b17576040517fa42637bc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060028481548110610b2c57610b2c612591565b600091825260208083206040805160a081018252600394909402909101805463ffffffff808216865264010000000090910460ff16151593850193909352600181015491840191909152600201546fffffffffffffffffffffffffffffffff80821660608501819052700100000000000000000000000000000000909204166080840152919350610bc09190859061205e16565b90507f0000000000000000000000000000000000000000000000000000000000000000610c7f826fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b67ffffffffffffffff161115610cc1576040517f56f57b2b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b815160009063ffffffff90811614610d21576002836000015163ffffffff1681548110610cf057610cf0612591565b906000526020600020906003020160020160109054906101000a90046fffffffffffffffffffffffffffffffff1690505b608083015160009067ffffffffffffffff1667ffffffffffffffff1642610d5a846fffffffffffffffffffffffffffffffff1660401c90565b67ffffffffffffffff16610d6e91906125ef565b610d789190612607565b9050677fffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000060011c1667ffffffffffffffff82161115610deb576040517f3381d11400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000604082901b42176000888152608086901b6fffffffffffffffffffffffffffffffff8b1617602052604081209192509060008181526007602052604090205490915060ff1615610e69576040517f80497e3b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600081815260076020908152604080832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155815160a08101835263ffffffff808f1682529381018581529281018d81526fffffffffffffffffffffffffffffffff808c16606084019081528982166080850190815260028054808801825599819052945160039099027f405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5ace8101805498511515640100000000027fffffffffffffffffffffffffffffffffffffffffffffffffffffff00000000009099169a909916999099179690961790965590517f405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5acf8701559351925184167001000000000000000000000000000000000292909316919091177f405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5ad09093019290925580548b908110610fe157610fe1612591565b6000918252602080832060039092029091018054931515640100000000027fffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff909416939093179092558a815260089091526040902060025461104590600190612607565b8154600181018355600092835260208320015560405133918a918c917f9b3245740ec3b155098a55be84957a4da13eaf7f14a8bc6f53126c0b9350f2be91a4505050505050505050565b367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c90033560001a60018114806110cf575060ff81166002145b611135576040517ff40239db000000000000000000000000000000000000000000000000000000008152367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c900335600482015260240160405180910390fd5b600080547fffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000164267ffffffffffffffff161781556040805160a08101825263ffffffff815260208101929092526002919081016111ba7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe369081013560f01c90033590565b815260016020820152604001426fffffffffffffffffffffffffffffffff9081169091528254600181810185556000948552602080862085516003909402018054918601511515640100000000027fffffffffffffffffffffffffffffffffffffffffffffffffffffff000000000090921663ffffffff909416939093171782556040840151908201556060830151608090930151821670010000000000000000000000000000000002929091169190911760029091015573ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016637f0064206112e360207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe369081013560f01c9003013590565b6040518263ffffffff1660e01b815260040161130191815260200190565b602060405180830381865afa15801561131e573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611342919061261e565b9050600073ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001663a25ae55761138d600185612607565b6040518263ffffffff1660e01b81526004016113ab91815260200190565b606060405180830381865afa1580156113c8573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113ec9190612686565b6040517fa25ae5570000000000000000000000000000000000000000000000000000000081526004810184905290915060009073ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000169063a25ae55790602401606060405180830381865afa15801561147d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114a19190612686565b9050600073ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000166399d548aa367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c9003604001356040518263ffffffff1660e01b815260040161152d91815260200190565b6040805180830381865afa158015611549573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061156d9190612712565b905081602001516fffffffffffffffffffffffffffffffff16816020015167ffffffffffffffff16116115cc576040517f13809ba500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160a0810182529081908101806115e7600189612607565b6fffffffffffffffffffffffffffffffff908116825260408881015182166020808501919091529851928101929092529183528051606081018252978216885285810151821688880152945187860152908501959095528051805181860151908716700100000000000000000000000000000000918816820217600355908401516004559084015180519481015194861694909516029290921760055591909101516006555160015550565b610a6782826001610a79565b600281815481106116af57600080fd5b600091825260209091206003909102018054600182015460029092015463ffffffff8216935064010000000090910460ff1691906fffffffffffffffffffffffffffffffff8082169170010000000000000000000000000000000090041685565b6000805468010000000000000000900460ff166002811115611734576117346122b1565b1461176b576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006002878154811061178057611780612591565b6000918252602082206003919091020160028101549092506fffffffffffffffffffffffffffffffff16908715821760011b90506117df7f000000000000000000000000000000000000000000000000000000000000000060016125ef565b61187b826fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b67ffffffffffffffff16146118bc576040517f5f53dd9800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600080891561193f576118e0836fffffffffffffffffffffffffffffffff16612066565b67ffffffffffffffff16156119135761190a6118fd600186612799565b865463ffffffff1661210c565b60010154611935565b7f00000000000000000000000000000000000000000000000000000000000000005b9150849050611959565b846001015491506119568460016118fd91906127ca565b90505b600882901b60088a8a6040516119709291906127fe565b6040518091039020901b146119b1576040517f696550ff00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600081600101547f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663f8e0cb968c8c8c8c6040518563ffffffff1660e01b8152600401611a179493929190612857565b6020604051808303816000875af1158015611a36573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611a5a919061261e565b600284810154929091149250600091611b05906fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b611ba1886fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b611bab9190612889565b611bb591906128aa565b67ffffffffffffffff161590508115158103611bfd576040517ffb4e40dd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505084547fffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff166401000000001790945550505050505050505050565b7f0000000000000000000000000000000000000000000000000000000000000000367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c9003356060611c8f610a6b565b9050909192565b6000805468010000000000000000900460ff166002811115611cba57611cba6122b1565b14611cf1576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060028281548110611d0657611d06612591565b60009182526020909120600260039092020190810154909150677fffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000060011c1690611d7690700100000000000000000000000000000000900467ffffffffffffffff1642612607565b6002830154611da69190700100000000000000000000000000000000900460401c67ffffffffffffffff166125ef565b11611ddd576040517ff2440b5300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260086020526040902082158015611dfb575060095460ff165b15611e32576040517ff1a9458100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8054158015611e4057508215155b15611e77576040517ff1a9458100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000805b8254811015611f45576000838281548110611e9857611e98612591565b6000918252602080832090910154808352600890915260409091205490915015611eee576040517f9a07664600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060028281548110611f0357611f03612591565b600091825260209091206003909102018054909150640100000000900460ff16611f3257600193505050611f45565b505080611f3e906128f8565b9050611e7b565b5082547fffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff16640100000000821515021783556000848152600860205260408120611f8e91612255565b836000036108f157600980547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600117905550505050565b60606000611ffe84367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c90036125ef565b90508267ffffffffffffffff1667ffffffffffffffff81111561202357612023612637565b6040519080825280601f01601f19166020018201604052801561204d576020820181803683370190505b509150828160208401375092915050565b151760011b90565b6000806120f3837e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b600167ffffffffffffffff919091161b90920392915050565b60008061212a846fffffffffffffffffffffffffffffffff166121a9565b90506002838154811061213f5761213f612591565b906000526020600020906003020191505b60028201546fffffffffffffffffffffffffffffffff8281169116146121a257815460028054909163ffffffff1690811061218d5761218d612591565b90600052602060002090600302019150612150565b5092915050565b6000811960018301168161223d827e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b67ffffffffffffffff169390931c8015179392505050565b50805460008255906000526020600020908101906122739190612276565b50565b5b8082111561228b5760008155600101612277565b5090565b600080604083850312156122a257600080fd5b50508035926020909101359150565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b602081016003831061231b577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b91905290565b6000815180845260005b818110156123475760208185018101518683018201520161232b565b81811115612359576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60208152600061239f6020830184612321565b9392505050565b82516fffffffffffffffffffffffffffffffff90811682526020808501518216818401526040808601518185015284518316606085015290840151909116608083015282015160a082015260c0810161239f565b8035801515811461240a57600080fd5b919050565b60008060006060848603121561242457600080fd5b833592506020840135915061243b604085016123fa565b90509250925092565b60006020828403121561245657600080fd5b5035919050565b60008083601f84011261246f57600080fd5b50813567ffffffffffffffff81111561248757600080fd5b60208301915083602082850101111561249f57600080fd5b9250929050565b600080600080600080608087890312156124bf57600080fd5b863595506124cf602088016123fa565b9450604087013567ffffffffffffffff808211156124ec57600080fd5b6124f88a838b0161245d565b9096509450606089013591508082111561251157600080fd5b5061251e89828a0161245d565b979a9699509497509295939492505050565b60ff841681528260208201526060604082015260006125526060830184612321565b95945050505050565b60006020828403121561256d57600080fd5b815173ffffffffffffffffffffffffffffffffffffffff8116811461239f57600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60008219821115612602576126026125c0565b500190565b600082821015612619576126196125c0565b500390565b60006020828403121561263057600080fd5b5051919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b80516fffffffffffffffffffffffffffffffff8116811461240a57600080fd5b60006060828403121561269857600080fd5b6040516060810181811067ffffffffffffffff821117156126e2577f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604052825181526126f560208401612666565b602082015261270660408401612666565b60408201529392505050565b60006040828403121561272457600080fd5b6040516040810167ffffffffffffffff828210818311171561276f577f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b816040528451835260208501519150808216821461278c57600080fd5b5060208201529392505050565b60006fffffffffffffffffffffffffffffffff838116908316818110156127c2576127c26125c0565b039392505050565b60006fffffffffffffffffffffffffffffffff8083168185168083038211156127f5576127f56125c0565b01949350505050565b8183823760009101908152919050565b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b60408152600061286b60408301868861280e565b828103602084015261287e81858761280e565b979650505050505050565b600067ffffffffffffffff838116908316818110156127c2576127c26125c0565b600067ffffffffffffffff808416806128ec577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b92169190910692915050565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203612929576129296125c0565b506001019056fea164736f6c634300080f000a", + ABI: "[{\"inputs\":[{\"internalType\":\"GameType\",\"name\":\"_gameType\",\"type\":\"uint8\"},{\"internalType\":\"Claim\",\"name\":\"_absolutePrestate\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"_maxGameDepth\",\"type\":\"uint256\"},{\"internalType\":\"Duration\",\"name\":\"_gameDuration\",\"type\":\"uint64\"},{\"internalType\":\"contractIBigStepper\",\"name\":\"_vm\",\"type\":\"address\"},{\"internalType\":\"contractL2OutputOracle\",\"name\":\"_l2oo\",\"type\":\"address\"},{\"internalType\":\"contractBlockOracle\",\"name\":\"_blockOracle\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"CannotDefendRootClaim\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ClaimAlreadyExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ClaimAlreadyResolved\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ClockNotExpired\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ClockTimeExceeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GameDepthExceeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GameNotInProgress\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidParent\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidPrestate\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"L1HeadTooOld\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OutOfOrderResolution\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"Claim\",\"name\":\"rootClaim\",\"type\":\"bytes32\"}],\"name\":\"UnexpectedRootClaim\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ValidStep\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"parentIndex\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"Claim\",\"name\":\"claim\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"claimant\",\"type\":\"address\"}],\"name\":\"Move\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"enumGameStatus\",\"name\":\"status\",\"type\":\"uint8\"}],\"name\":\"Resolved\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"ABSOLUTE_PRESTATE\",\"outputs\":[{\"internalType\":\"Claim\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"BLOCK_ORACLE\",\"outputs\":[{\"internalType\":\"contractBlockOracle\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"GAME_DURATION\",\"outputs\":[{\"internalType\":\"Duration\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"L2_OUTPUT_ORACLE\",\"outputs\":[{\"internalType\":\"contractL2OutputOracle\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MAX_GAME_DEPTH\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"VM\",\"outputs\":[{\"internalType\":\"contractIBigStepper\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_ident\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_l2BlockNumber\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_partOffset\",\"type\":\"uint256\"}],\"name\":\"addLocalData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_parentIndex\",\"type\":\"uint256\"},{\"internalType\":\"Claim\",\"name\":\"_claim\",\"type\":\"bytes32\"}],\"name\":\"attack\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"bondManager\",\"outputs\":[{\"internalType\":\"contractIBondManager\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"claimData\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"parentIndex\",\"type\":\"uint32\"},{\"internalType\":\"bool\",\"name\":\"countered\",\"type\":\"bool\"},{\"internalType\":\"Claim\",\"name\":\"claim\",\"type\":\"bytes32\"},{\"internalType\":\"Position\",\"name\":\"position\",\"type\":\"uint128\"},{\"internalType\":\"Clock\",\"name\":\"clock\",\"type\":\"uint128\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"claimDataLen\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"len_\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createdAt\",\"outputs\":[{\"internalType\":\"Timestamp\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_parentIndex\",\"type\":\"uint256\"},{\"internalType\":\"Claim\",\"name\":\"_claim\",\"type\":\"bytes32\"}],\"name\":\"defend\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"extraData\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"extraData_\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"gameData\",\"outputs\":[{\"internalType\":\"GameType\",\"name\":\"gameType_\",\"type\":\"uint8\"},{\"internalType\":\"Claim\",\"name\":\"rootClaim_\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"extraData_\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"gameType\",\"outputs\":[{\"internalType\":\"GameType\",\"name\":\"gameType_\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"initialize\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"l1BlockNumber\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"l1BlockNumber_\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"l1Head\",\"outputs\":[{\"internalType\":\"Hash\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"l2BlockNumber\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"l2BlockNumber_\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_challengeIndex\",\"type\":\"uint256\"},{\"internalType\":\"Claim\",\"name\":\"_claim\",\"type\":\"bytes32\"},{\"internalType\":\"bool\",\"name\":\"_isAttack\",\"type\":\"bool\"}],\"name\":\"move\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"proposals\",\"outputs\":[{\"components\":[{\"internalType\":\"uint128\",\"name\":\"index\",\"type\":\"uint128\"},{\"internalType\":\"uint128\",\"name\":\"l2BlockNumber\",\"type\":\"uint128\"},{\"internalType\":\"Hash\",\"name\":\"outputRoot\",\"type\":\"bytes32\"}],\"internalType\":\"structIFaultDisputeGame.OutputProposal\",\"name\":\"starting\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint128\",\"name\":\"index\",\"type\":\"uint128\"},{\"internalType\":\"uint128\",\"name\":\"l2BlockNumber\",\"type\":\"uint128\"},{\"internalType\":\"Hash\",\"name\":\"outputRoot\",\"type\":\"bytes32\"}],\"internalType\":\"structIFaultDisputeGame.OutputProposal\",\"name\":\"disputed\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"resolve\",\"outputs\":[{\"internalType\":\"enumGameStatus\",\"name\":\"status_\",\"type\":\"uint8\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_claimIndex\",\"type\":\"uint256\"}],\"name\":\"resolveClaim\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"rootClaim\",\"outputs\":[{\"internalType\":\"Claim\",\"name\":\"rootClaim_\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"status\",\"outputs\":[{\"internalType\":\"enumGameStatus\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_claimIndex\",\"type\":\"uint256\"},{\"internalType\":\"bool\",\"name\":\"_isAttack\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"_stateData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"_proof\",\"type\":\"bytes\"}],\"name\":\"step\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"version\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", + Bin: "0x6101606040523480156200001257600080fd5b5060405162002b5d38038062002b5d83398101604081905262000035916200008f565b60ff9096166101405260809490945260a0929092526001600160401b031660c0526001600160a01b0390811660e05290811661010052166101205262000133565b6001600160a01b03811681146200008c57600080fd5b50565b600080600080600080600060e0888a031215620000ab57600080fd5b875160ff81168114620000bd57600080fd5b602089015160408a015160608b015192995090975095506001600160401b0381168114620000ea57600080fd5b6080890151909450620000fd8162000076565b60a0890151909350620001108162000076565b60c0890151909250620001238162000076565b8091505092959891949750929550565b60805160a05160c05160e05161010051610120516101405161297b620001e2600039600081816105410152611c4401526000818161034901526112fd0152600081816105ba015281816110ca0152818161119e015261127701526000818161050b015281816117fb0152611adc0152600081816105ee01528181610bc60152611d3301526000818161031501528181610a0501526115fa01526000818161020a0152611756015261297b6000f3fe6080604052600436106101b75760003560e01c80638980e0cc116100ec578063c55cd0c71161008a578063d8cc1a3c11610064578063d8cc1a3c146106c1578063f8f43ff6146106e1578063fa24f74314610701578063fdffbb281461072557600080fd5b8063c55cd0c714610629578063c6f0308c1461063c578063cf09e0d0146106a057600080fd5b8063bbdc02db116100c6578063bbdc02db1461052d578063bcef3b551461056b578063c0c3a092146105a8578063c31b29ce146105dc57600080fd5b80638980e0cc146104a45780638b85902b146104b957806392931298146104f957600080fd5b8063529184c911610159578063609d333411610133578063609d333414610451578063632247ea146104665780636361506d146104795780638129fc1c1461048f57600080fd5b8063529184c91461033757806354fd4d501461036b57806355ef20e6146103c157600080fd5b8063298c900511610195578063298c90051461024f57806335fef5671461028f578063363cc427146102a45780634778efe81461030357600080fd5b8063200d2ed2146101bc578063266198f9146101f85780632810e1d61461023a575b600080fd5b3480156101c857600080fd5b506000546101e29068010000000000000000900460ff1681565b6040516101ef91906122c8565b60405180910390f35b34801561020457600080fd5b5061022c7f000000000000000000000000000000000000000000000000000000000000000081565b6040519081526020016101ef565b34801561024657600080fd5b506101e2610738565b34801561025b57600080fd5b50367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c90036040013561022c565b6102a261029d366004612309565b61089c565b005b3480156102b057600080fd5b506000546102de906901000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020016101ef565b34801561030f57600080fd5b5061022c7f000000000000000000000000000000000000000000000000000000000000000081565b34801561034357600080fd5b506102de7f000000000000000000000000000000000000000000000000000000000000000081565b34801561037757600080fd5b506103b46040518060400160405280600681526020017f302e302e3131000000000000000000000000000000000000000000000000000081525081565b6040516101ef9190612396565b3480156103cd57600080fd5b5060408051606080820183526003546fffffffffffffffffffffffffffffffff808216845270010000000000000000000000000000000091829004811660208086019190915260045485870152855193840186526005548083168552929092041690820152600654928101929092526104439182565b6040516101ef9291906123b0565b34801561045d57600080fd5b506103b46108ac565b6102a2610474366004612419565b6108ba565b34801561048557600080fd5b5061022c60015481565b34801561049b57600080fd5b506102a2610ed0565b3480156104b057600080fd5b5060025461022c565b3480156104c557600080fd5b50367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c90036020013561022c565b34801561050557600080fd5b506102de7f000000000000000000000000000000000000000000000000000000000000000081565b34801561053957600080fd5b5060405160ff7f00000000000000000000000000000000000000000000000000000000000000001681526020016101ef565b34801561057757600080fd5b50367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c90033561022c565b3480156105b457600080fd5b506102de7f000000000000000000000000000000000000000000000000000000000000000081565b3480156105e857600080fd5b506106107f000000000000000000000000000000000000000000000000000000000000000081565b60405167ffffffffffffffff90911681526020016101ef565b6102a2610637366004612309565b6114d4565b34801561064857600080fd5b5061065c61065736600461244e565b6114e0565b6040805163ffffffff90961686529315156020860152928401919091526fffffffffffffffffffffffffffffffff908116606084015216608082015260a0016101ef565b3480156106ac57600080fd5b506000546106109067ffffffffffffffff1681565b3480156106cd57600080fd5b506102a26106dc3660046124b0565b611551565b3480156106ed57600080fd5b506102a26106fc36600461253a565b611a7d565b34801561070d57600080fd5b50610716611c42565b6040516101ef93929190612566565b6102a261073336600461244e565b611c9f565b60008060005468010000000000000000900460ff16600281111561075e5761075e612299565b14610795576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60095460ff166107d1576040517f9a07664600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60026000815481106107e5576107e5612591565b6000918252602090912060039091020154640100000000900460ff1661080c57600261080f565b60015b6000805491925082917fffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff166801000000000000000083600281111561085657610856612299565b02179055600281111561086b5761086b612299565b6040517f5e186f09b9c93491f14e277eea7faa5de6a2d4bda75a79af7a3684fbfb42da6090600090a290565b905090565b6108a8828260006108ba565b5050565b606061089760206040611fd1565b6000805468010000000000000000900460ff1660028111156108de576108de612299565b14610915576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b82158015610921575080155b15610958576040517fa42637bc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006002848154811061096d5761096d612591565b600091825260208083206040805160a081018252600394909402909101805463ffffffff808216865264010000000090910460ff16151593850193909352600181015491840191909152600201546fffffffffffffffffffffffffffffffff80821660608501819052700100000000000000000000000000000000909204166080840152919350610a019190859061206816565b90507f0000000000000000000000000000000000000000000000000000000000000000610ac0826fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b67ffffffffffffffff161115610b02576040517f56f57b2b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b815160009063ffffffff90811614610b62576002836000015163ffffffff1681548110610b3157610b31612591565b906000526020600020906003020160020160109054906101000a90046fffffffffffffffffffffffffffffffff1690505b608083015160009067ffffffffffffffff1667ffffffffffffffff1642610b9b846fffffffffffffffffffffffffffffffff1660401c90565b67ffffffffffffffff16610baf91906125ef565b610bb99190612607565b9050677fffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000060011c1667ffffffffffffffff82161115610c2c576040517f3381d11400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000604082901b42176000888152608086901b6fffffffffffffffffffffffffffffffff8b1617602052604081209192509060008181526007602052604090205490915060ff1615610caa576040517f80497e3b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600081815260076020908152604080832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155815160a08101835263ffffffff808f1682529381018581529281018d81526fffffffffffffffffffffffffffffffff808c16606084019081528982166080850190815260028054808801825599819052945160039099027f405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5ace8101805498511515640100000000027fffffffffffffffffffffffffffffffffffffffffffffffffffffff00000000009099169a909916999099179690961790965590517f405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5acf8701559351925184167001000000000000000000000000000000000292909316919091177f405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5ad09093019290925580548b908110610e2257610e22612591565b6000918252602080832060039092029091018054931515640100000000027fffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff909416939093179092558a8152600890915260409020600254610e8690600190612607565b8154600181018355600092835260208320015560405133918a918c917f9b3245740ec3b155098a55be84957a4da13eaf7f14a8bc6f53126c0b9350f2be91a4505050505050505050565b367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c90033560001a6001811480610f10575060ff81166002145b610f76576040517ff40239db000000000000000000000000000000000000000000000000000000008152367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c900335600482015260240160405180910390fd5b600080547fffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000164267ffffffffffffffff161781556040805160a08101825263ffffffff81526020810192909252600291908101610ffb7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe369081013560f01c90033590565b815260016020820152604001426fffffffffffffffffffffffffffffffff9081169091528254600181810185556000948552602080862085516003909402018054918601511515640100000000027fffffffffffffffffffffffffffffffffffffffffffffffffffffff000000000090921663ffffffff909416939093171782556040840151908201556060830151608090930151821670010000000000000000000000000000000002929091169190911760029091015573ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016637f00642061112460207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe369081013560f01c9003013590565b6040518263ffffffff1660e01b815260040161114291815260200190565b602060405180830381865afa15801561115f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611183919061261e565b9050600073ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001663a25ae5576111ce600185612607565b6040518263ffffffff1660e01b81526004016111ec91815260200190565b606060405180830381865afa158015611209573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061122d9190612686565b6040517fa25ae5570000000000000000000000000000000000000000000000000000000081526004810184905290915060009073ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000169063a25ae55790602401606060405180830381865afa1580156112be573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906112e29190612686565b9050600073ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000166399d548aa367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c9003604001356040518263ffffffff1660e01b815260040161136e91815260200190565b6040805180830381865afa15801561138a573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113ae9190612712565b905081602001516fffffffffffffffffffffffffffffffff16816020015167ffffffffffffffff161161140d576040517f13809ba500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160a081018252908190810180611428600189612607565b6fffffffffffffffffffffffffffffffff908116825260408881015182166020808501919091529851928101929092529183528051606081018252978216885285810151821688880152945187860152908501959095528051805181860151908716700100000000000000000000000000000000918816820217600355908401516004559084015180519481015194861694909516029290921760055591909101516006555160015550565b6108a8828260016108ba565b600281815481106114f057600080fd5b600091825260209091206003909102018054600182015460029092015463ffffffff8216935064010000000090910460ff1691906fffffffffffffffffffffffffffffffff8082169170010000000000000000000000000000000090041685565b6000805468010000000000000000900460ff16600281111561157557611575612299565b146115ac576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000600287815481106115c1576115c1612591565b6000918252602082206003919091020160028101549092506fffffffffffffffffffffffffffffffff16908715821760011b90506116207f000000000000000000000000000000000000000000000000000000000000000060016125ef565b6116bc826fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b67ffffffffffffffff16146116fd576040517f5f53dd9800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600080891561178057611721836fffffffffffffffffffffffffffffffff16612070565b67ffffffffffffffff16156117545761174b61173e600186612799565b865463ffffffff16612116565b60010154611776565b7f00000000000000000000000000000000000000000000000000000000000000005b915084905061179a565b8460010154915061179784600161173e91906127ca565b90505b600882901b60088a8a6040516117b19291906127fe565b6040518091039020901b146117f2576040517f696550ff00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600081600101547f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663836e7b328c8c8c8c60006040518663ffffffff1660e01b815260040161185b959493929190612857565b6020604051808303816000875af115801561187a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061189e919061261e565b600284810154929091149250600091611949906fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b6119e5886fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b6119ef9190612891565b6119f991906128b2565b67ffffffffffffffff161590508115158103611a41576040517ffb4e40dd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505084547fffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff166401000000001790945550505050505050505050565b6000805468010000000000000000900460ff166002811115611aa157611aa1612299565b14611ad8576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60007f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16637dc0d1d06040518163ffffffff1660e01b8152600401602060405180830381865afa158015611b45573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611b699190612900565b7fc0c220c900000000000000000000000000000000000000000000000000000000601c8190526020869052604085905290915060008560018114611bd55760028114611bdf5760038114611be95760048114611bf35760058114611c035763ff137e656000526004601cfd5b6001549150611c0a565b6004549150611c0a565b6006549150611c0a565b60035460801c60c01b9150611c0a565b4660c01b91505b50606052600160038611811b6005031b60805260a083905260008060a4601c82865af1611c3b573d6000803e3d6000fd5b5050505050565b7f0000000000000000000000000000000000000000000000000000000000000000367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c9003356060611c986108ac565b9050909192565b6000805468010000000000000000900460ff166002811115611cc357611cc3612299565b14611cfa576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060028281548110611d0f57611d0f612591565b60009182526020909120600260039092020190810154909150677fffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000060011c1690611d7f90700100000000000000000000000000000000900467ffffffffffffffff1642612607565b6002830154611daf9190700100000000000000000000000000000000900460401c67ffffffffffffffff166125ef565b11611de6576040517ff2440b5300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260086020526040902082158015611e04575060095460ff165b15611e3b576040517ff1a9458100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8054158015611e4957508215155b15611e80576040517ff1a9458100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000805b8254811015611f4e576000838281548110611ea157611ea1612591565b6000918252602080832090910154808352600890915260409091205490915015611ef7576040517f9a07664600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060028281548110611f0c57611f0c612591565b600091825260209091206003909102018054909150640100000000900460ff16611f3b57600193505050611f4e565b505080611f4790612936565b9050611e84565b5082547fffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff16640100000000821515021783556000848152600860205260408120611f979161225f565b83600003611fcb57600980547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790555b50505050565b6060600061200884367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c90036125ef565b90508267ffffffffffffffff1667ffffffffffffffff81111561202d5761202d612637565b6040519080825280601f01601f191660200182016040528015612057576020820181803683370190505b509150828160208401375092915050565b151760011b90565b6000806120fd837e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b600167ffffffffffffffff919091161b90920392915050565b600080612134846fffffffffffffffffffffffffffffffff166121b3565b90506002838154811061214957612149612591565b906000526020600020906003020191505b60028201546fffffffffffffffffffffffffffffffff8281169116146121ac57815460028054909163ffffffff1690811061219757612197612591565b9060005260206000209060030201915061215a565b5092915050565b60008119600183011681612247827e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b67ffffffffffffffff169390931c8015179392505050565b508054600082559060005260206000209081019061227d9190612280565b50565b5b808211156122955760008155600101612281565b5090565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b6020810160038310612303577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b91905290565b6000806040838503121561231c57600080fd5b50508035926020909101359150565b6000815180845260005b8181101561235157602081850181015186830182015201612335565b81811115612363576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b6020815260006123a9602083018461232b565b9392505050565b82516fffffffffffffffffffffffffffffffff90811682526020808501518216818401526040808601518185015284518316606085015290840151909116608083015282015160a082015260c081016123a9565b8035801515811461241457600080fd5b919050565b60008060006060848603121561242e57600080fd5b833592506020840135915061244560408501612404565b90509250925092565b60006020828403121561246057600080fd5b5035919050565b60008083601f84011261247957600080fd5b50813567ffffffffffffffff81111561249157600080fd5b6020830191508360208285010111156124a957600080fd5b9250929050565b600080600080600080608087890312156124c957600080fd5b863595506124d960208801612404565b9450604087013567ffffffffffffffff808211156124f657600080fd5b6125028a838b01612467565b9096509450606089013591508082111561251b57600080fd5b5061252889828a01612467565b979a9699509497509295939492505050565b60008060006060848603121561254f57600080fd5b505081359360208301359350604090920135919050565b60ff84168152826020820152606060408201526000612588606083018461232b565b95945050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60008219821115612602576126026125c0565b500190565b600082821015612619576126196125c0565b500390565b60006020828403121561263057600080fd5b5051919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b80516fffffffffffffffffffffffffffffffff8116811461241457600080fd5b60006060828403121561269857600080fd5b6040516060810181811067ffffffffffffffff821117156126e2577f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604052825181526126f560208401612666565b602082015261270660408401612666565b60408201529392505050565b60006040828403121561272457600080fd5b6040516040810167ffffffffffffffff828210818311171561276f577f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b816040528451835260208501519150808216821461278c57600080fd5b5060208201529392505050565b60006fffffffffffffffffffffffffffffffff838116908316818110156127c2576127c26125c0565b039392505050565b60006fffffffffffffffffffffffffffffffff8083168185168083038211156127f5576127f56125c0565b01949350505050565b8183823760009101908152919050565b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b60608152600061286b60608301878961280e565b828103602084015261287e81868861280e565b9150508260408301529695505050505050565b600067ffffffffffffffff838116908316818110156127c2576127c26125c0565b600067ffffffffffffffff808416806128f4577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b92169190910692915050565b60006020828403121561291257600080fd5b815173ffffffffffffffffffffffffffffffffffffffff811681146123a957600080fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203612967576129676125c0565b506001019056fea164736f6c634300080f000a", } // FaultDisputeGameABI is the input ABI used to generate the binding from. @@ -890,25 +890,25 @@ func (_FaultDisputeGame *FaultDisputeGameCallerSession) Version() (string, error return _FaultDisputeGame.Contract.Version(&_FaultDisputeGame.CallOpts) } -// AddLocalData is a paid mutator transaction binding the contract method 0x1e27052a. +// AddLocalData is a paid mutator transaction binding the contract method 0xf8f43ff6. // -// Solidity: function addLocalData(uint256 _ident, uint256 _partOffset) returns() -func (_FaultDisputeGame *FaultDisputeGameTransactor) AddLocalData(opts *bind.TransactOpts, _ident *big.Int, _partOffset *big.Int) (*types.Transaction, error) { - return _FaultDisputeGame.contract.Transact(opts, "addLocalData", _ident, _partOffset) +// Solidity: function addLocalData(uint256 _ident, uint256 _l2BlockNumber, uint256 _partOffset) returns() +func (_FaultDisputeGame *FaultDisputeGameTransactor) AddLocalData(opts *bind.TransactOpts, _ident *big.Int, _l2BlockNumber *big.Int, _partOffset *big.Int) (*types.Transaction, error) { + return _FaultDisputeGame.contract.Transact(opts, "addLocalData", _ident, _l2BlockNumber, _partOffset) } -// AddLocalData is a paid mutator transaction binding the contract method 0x1e27052a. +// AddLocalData is a paid mutator transaction binding the contract method 0xf8f43ff6. // -// Solidity: function addLocalData(uint256 _ident, uint256 _partOffset) returns() -func (_FaultDisputeGame *FaultDisputeGameSession) AddLocalData(_ident *big.Int, _partOffset *big.Int) (*types.Transaction, error) { - return _FaultDisputeGame.Contract.AddLocalData(&_FaultDisputeGame.TransactOpts, _ident, _partOffset) +// Solidity: function addLocalData(uint256 _ident, uint256 _l2BlockNumber, uint256 _partOffset) returns() +func (_FaultDisputeGame *FaultDisputeGameSession) AddLocalData(_ident *big.Int, _l2BlockNumber *big.Int, _partOffset *big.Int) (*types.Transaction, error) { + return _FaultDisputeGame.Contract.AddLocalData(&_FaultDisputeGame.TransactOpts, _ident, _l2BlockNumber, _partOffset) } -// AddLocalData is a paid mutator transaction binding the contract method 0x1e27052a. +// AddLocalData is a paid mutator transaction binding the contract method 0xf8f43ff6. // -// Solidity: function addLocalData(uint256 _ident, uint256 _partOffset) returns() -func (_FaultDisputeGame *FaultDisputeGameTransactorSession) AddLocalData(_ident *big.Int, _partOffset *big.Int) (*types.Transaction, error) { - return _FaultDisputeGame.Contract.AddLocalData(&_FaultDisputeGame.TransactOpts, _ident, _partOffset) +// Solidity: function addLocalData(uint256 _ident, uint256 _l2BlockNumber, uint256 _partOffset) returns() +func (_FaultDisputeGame *FaultDisputeGameTransactorSession) AddLocalData(_ident *big.Int, _l2BlockNumber *big.Int, _partOffset *big.Int) (*types.Transaction, error) { + return _FaultDisputeGame.Contract.AddLocalData(&_FaultDisputeGame.TransactOpts, _ident, _l2BlockNumber, _partOffset) } // Attack is a paid mutator transaction binding the contract method 0xc55cd0c7. diff --git a/op-bindings/bindings/faultdisputegame_more.go b/op-bindings/bindings/faultdisputegame_more.go index 026123fba2196..896757e12c846 100644 --- a/op-bindings/bindings/faultdisputegame_more.go +++ b/op-bindings/bindings/faultdisputegame_more.go @@ -13,7 +13,7 @@ const FaultDisputeGameStorageLayoutJSON = "{\"storage\":[{\"astId\":1000,\"contr var FaultDisputeGameStorageLayout = new(solc.StorageLayout) -var FaultDisputeGameDeployedBin = "0x6080604052600436106101b75760003560e01c80638129fc1c116100ec578063c31b29ce1161008a578063cf09e0d011610064578063cf09e0d0146106c0578063d8cc1a3c146106e1578063fa24f74314610701578063fdffbb281461072557600080fd5b8063c31b29ce146105fc578063c55cd0c714610649578063c6f0308c1461065c57600080fd5b806392931298116100c65780639293129814610519578063bbdc02db1461054d578063bcef3b551461058b578063c0c3a092146105c857600080fd5b80638129fc1c146104af5780638980e0cc146104c45780638b85902b146104d957600080fd5b80634778efe81161015957806355ef20e61161013357806355ef20e6146103e1578063609d333414610471578063632247ea146104865780636361506d1461049957600080fd5b80634778efe814610323578063529184c91461035757806354fd4d501461038b57600080fd5b80632810e1d6116101955780632810e1d61461025c578063298c90051461027157806335fef567146102b1578063363cc427146102c457600080fd5b80631e27052a146101bc578063200d2ed2146101de578063266198f91461021a575b600080fd5b3480156101c857600080fd5b506101dc6101d736600461228f565b610738565b005b3480156101ea57600080fd5b506000546102049068010000000000000000900460ff1681565b60405161021191906122e0565b60405180910390f35b34801561022657600080fd5b5061024e7f000000000000000000000000000000000000000000000000000000000000000081565b604051908152602001610211565b34801561026857600080fd5b506102046108f7565b34801561027d57600080fd5b50367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c90036040013561024e565b6101dc6102bf36600461228f565b610a5b565b3480156102d057600080fd5b506000546102fe906901000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610211565b34801561032f57600080fd5b5061024e7f000000000000000000000000000000000000000000000000000000000000000081565b34801561036357600080fd5b506102fe7f000000000000000000000000000000000000000000000000000000000000000081565b34801561039757600080fd5b506103d46040518060400160405280600681526020017f302e302e3130000000000000000000000000000000000000000000000000000081525081565b604051610211919061238c565b3480156103ed57600080fd5b5060408051606080820183526003546fffffffffffffffffffffffffffffffff808216845270010000000000000000000000000000000091829004811660208086019190915260045485870152855193840186526005548083168552929092041690820152600654928101929092526104639182565b6040516102119291906123a6565b34801561047d57600080fd5b506103d4610a6b565b6101dc61049436600461240f565b610a79565b3480156104a557600080fd5b5061024e60015481565b3480156104bb57600080fd5b506101dc61108f565b3480156104d057600080fd5b5060025461024e565b3480156104e557600080fd5b50367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c90036020013561024e565b34801561052557600080fd5b506102fe7f000000000000000000000000000000000000000000000000000000000000000081565b34801561055957600080fd5b5060405160ff7f0000000000000000000000000000000000000000000000000000000000000000168152602001610211565b34801561059757600080fd5b50367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c90033561024e565b3480156105d457600080fd5b506102fe7f000000000000000000000000000000000000000000000000000000000000000081565b34801561060857600080fd5b506106307f000000000000000000000000000000000000000000000000000000000000000081565b60405167ffffffffffffffff9091168152602001610211565b6101dc61065736600461228f565b611693565b34801561066857600080fd5b5061067c610677366004612444565b61169f565b6040805163ffffffff90961686529315156020860152928401919091526fffffffffffffffffffffffffffffffff908116606084015216608082015260a001610211565b3480156106cc57600080fd5b506000546106309067ffffffffffffffff1681565b3480156106ed57600080fd5b506101dc6106fc3660046124a6565b611710565b34801561070d57600080fd5b50610716611c39565b60405161021193929190612530565b6101dc610733366004612444565b611c96565b6000805468010000000000000000900460ff16600281111561075c5761075c6122b1565b14610793576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60007f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16637dc0d1d06040518163ffffffff1660e01b8152600401602060405180830381865afa158015610800573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610824919061255b565b7f9a1f5e7f00000000000000000000000000000000000000000000000000000000601c81905260208590529091506000846001811461088b5760028114610895576003811461089f57600481146108a957600581146108b95763ff137e656000526004601cfd5b60015491506108c0565b60045491506108c0565b60065491506108c0565b60035460801c60c01b91506108c0565b4660c01b91505b50604052600160038511811b6005031b60605260808390526000806084601c82865af16108f1573d6000803e3d6000fd5b50505050565b60008060005468010000000000000000900460ff16600281111561091d5761091d6122b1565b14610954576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60095460ff16610990576040517f9a07664600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60026000815481106109a4576109a4612591565b6000918252602090912060039091020154640100000000900460ff166109cb5760026109ce565b60015b6000805491925082917fffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff1668010000000000000000836002811115610a1557610a156122b1565b021790556002811115610a2a57610a2a6122b1565b6040517f5e186f09b9c93491f14e277eea7faa5de6a2d4bda75a79af7a3684fbfb42da6090600090a290565b905090565b610a6782826000610a79565b5050565b6060610a5660206040611fc7565b6000805468010000000000000000900460ff166002811115610a9d57610a9d6122b1565b14610ad4576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b82158015610ae0575080155b15610b17576040517fa42637bc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060028481548110610b2c57610b2c612591565b600091825260208083206040805160a081018252600394909402909101805463ffffffff808216865264010000000090910460ff16151593850193909352600181015491840191909152600201546fffffffffffffffffffffffffffffffff80821660608501819052700100000000000000000000000000000000909204166080840152919350610bc09190859061205e16565b90507f0000000000000000000000000000000000000000000000000000000000000000610c7f826fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b67ffffffffffffffff161115610cc1576040517f56f57b2b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b815160009063ffffffff90811614610d21576002836000015163ffffffff1681548110610cf057610cf0612591565b906000526020600020906003020160020160109054906101000a90046fffffffffffffffffffffffffffffffff1690505b608083015160009067ffffffffffffffff1667ffffffffffffffff1642610d5a846fffffffffffffffffffffffffffffffff1660401c90565b67ffffffffffffffff16610d6e91906125ef565b610d789190612607565b9050677fffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000060011c1667ffffffffffffffff82161115610deb576040517f3381d11400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000604082901b42176000888152608086901b6fffffffffffffffffffffffffffffffff8b1617602052604081209192509060008181526007602052604090205490915060ff1615610e69576040517f80497e3b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600081815260076020908152604080832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155815160a08101835263ffffffff808f1682529381018581529281018d81526fffffffffffffffffffffffffffffffff808c16606084019081528982166080850190815260028054808801825599819052945160039099027f405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5ace8101805498511515640100000000027fffffffffffffffffffffffffffffffffffffffffffffffffffffff00000000009099169a909916999099179690961790965590517f405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5acf8701559351925184167001000000000000000000000000000000000292909316919091177f405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5ad09093019290925580548b908110610fe157610fe1612591565b6000918252602080832060039092029091018054931515640100000000027fffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff909416939093179092558a815260089091526040902060025461104590600190612607565b8154600181018355600092835260208320015560405133918a918c917f9b3245740ec3b155098a55be84957a4da13eaf7f14a8bc6f53126c0b9350f2be91a4505050505050505050565b367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c90033560001a60018114806110cf575060ff81166002145b611135576040517ff40239db000000000000000000000000000000000000000000000000000000008152367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c900335600482015260240160405180910390fd5b600080547fffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000164267ffffffffffffffff161781556040805160a08101825263ffffffff815260208101929092526002919081016111ba7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe369081013560f01c90033590565b815260016020820152604001426fffffffffffffffffffffffffffffffff9081169091528254600181810185556000948552602080862085516003909402018054918601511515640100000000027fffffffffffffffffffffffffffffffffffffffffffffffffffffff000000000090921663ffffffff909416939093171782556040840151908201556060830151608090930151821670010000000000000000000000000000000002929091169190911760029091015573ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016637f0064206112e360207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe369081013560f01c9003013590565b6040518263ffffffff1660e01b815260040161130191815260200190565b602060405180830381865afa15801561131e573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611342919061261e565b9050600073ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001663a25ae55761138d600185612607565b6040518263ffffffff1660e01b81526004016113ab91815260200190565b606060405180830381865afa1580156113c8573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113ec9190612686565b6040517fa25ae5570000000000000000000000000000000000000000000000000000000081526004810184905290915060009073ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000169063a25ae55790602401606060405180830381865afa15801561147d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114a19190612686565b9050600073ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000166399d548aa367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c9003604001356040518263ffffffff1660e01b815260040161152d91815260200190565b6040805180830381865afa158015611549573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061156d9190612712565b905081602001516fffffffffffffffffffffffffffffffff16816020015167ffffffffffffffff16116115cc576040517f13809ba500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160a0810182529081908101806115e7600189612607565b6fffffffffffffffffffffffffffffffff908116825260408881015182166020808501919091529851928101929092529183528051606081018252978216885285810151821688880152945187860152908501959095528051805181860151908716700100000000000000000000000000000000918816820217600355908401516004559084015180519481015194861694909516029290921760055591909101516006555160015550565b610a6782826001610a79565b600281815481106116af57600080fd5b600091825260209091206003909102018054600182015460029092015463ffffffff8216935064010000000090910460ff1691906fffffffffffffffffffffffffffffffff8082169170010000000000000000000000000000000090041685565b6000805468010000000000000000900460ff166002811115611734576117346122b1565b1461176b576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006002878154811061178057611780612591565b6000918252602082206003919091020160028101549092506fffffffffffffffffffffffffffffffff16908715821760011b90506117df7f000000000000000000000000000000000000000000000000000000000000000060016125ef565b61187b826fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b67ffffffffffffffff16146118bc576040517f5f53dd9800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600080891561193f576118e0836fffffffffffffffffffffffffffffffff16612066565b67ffffffffffffffff16156119135761190a6118fd600186612799565b865463ffffffff1661210c565b60010154611935565b7f00000000000000000000000000000000000000000000000000000000000000005b9150849050611959565b846001015491506119568460016118fd91906127ca565b90505b600882901b60088a8a6040516119709291906127fe565b6040518091039020901b146119b1576040517f696550ff00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600081600101547f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663f8e0cb968c8c8c8c6040518563ffffffff1660e01b8152600401611a179493929190612857565b6020604051808303816000875af1158015611a36573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611a5a919061261e565b600284810154929091149250600091611b05906fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b611ba1886fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b611bab9190612889565b611bb591906128aa565b67ffffffffffffffff161590508115158103611bfd576040517ffb4e40dd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505084547fffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff166401000000001790945550505050505050505050565b7f0000000000000000000000000000000000000000000000000000000000000000367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c9003356060611c8f610a6b565b9050909192565b6000805468010000000000000000900460ff166002811115611cba57611cba6122b1565b14611cf1576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060028281548110611d0657611d06612591565b60009182526020909120600260039092020190810154909150677fffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000060011c1690611d7690700100000000000000000000000000000000900467ffffffffffffffff1642612607565b6002830154611da69190700100000000000000000000000000000000900460401c67ffffffffffffffff166125ef565b11611ddd576040517ff2440b5300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260086020526040902082158015611dfb575060095460ff165b15611e32576040517ff1a9458100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8054158015611e4057508215155b15611e77576040517ff1a9458100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000805b8254811015611f45576000838281548110611e9857611e98612591565b6000918252602080832090910154808352600890915260409091205490915015611eee576040517f9a07664600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060028281548110611f0357611f03612591565b600091825260209091206003909102018054909150640100000000900460ff16611f3257600193505050611f45565b505080611f3e906128f8565b9050611e7b565b5082547fffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff16640100000000821515021783556000848152600860205260408120611f8e91612255565b836000036108f157600980547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600117905550505050565b60606000611ffe84367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c90036125ef565b90508267ffffffffffffffff1667ffffffffffffffff81111561202357612023612637565b6040519080825280601f01601f19166020018201604052801561204d576020820181803683370190505b509150828160208401375092915050565b151760011b90565b6000806120f3837e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b600167ffffffffffffffff919091161b90920392915050565b60008061212a846fffffffffffffffffffffffffffffffff166121a9565b90506002838154811061213f5761213f612591565b906000526020600020906003020191505b60028201546fffffffffffffffffffffffffffffffff8281169116146121a257815460028054909163ffffffff1690811061218d5761218d612591565b90600052602060002090600302019150612150565b5092915050565b6000811960018301168161223d827e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b67ffffffffffffffff169390931c8015179392505050565b50805460008255906000526020600020908101906122739190612276565b50565b5b8082111561228b5760008155600101612277565b5090565b600080604083850312156122a257600080fd5b50508035926020909101359150565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b602081016003831061231b577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b91905290565b6000815180845260005b818110156123475760208185018101518683018201520161232b565b81811115612359576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60208152600061239f6020830184612321565b9392505050565b82516fffffffffffffffffffffffffffffffff90811682526020808501518216818401526040808601518185015284518316606085015290840151909116608083015282015160a082015260c0810161239f565b8035801515811461240a57600080fd5b919050565b60008060006060848603121561242457600080fd5b833592506020840135915061243b604085016123fa565b90509250925092565b60006020828403121561245657600080fd5b5035919050565b60008083601f84011261246f57600080fd5b50813567ffffffffffffffff81111561248757600080fd5b60208301915083602082850101111561249f57600080fd5b9250929050565b600080600080600080608087890312156124bf57600080fd5b863595506124cf602088016123fa565b9450604087013567ffffffffffffffff808211156124ec57600080fd5b6124f88a838b0161245d565b9096509450606089013591508082111561251157600080fd5b5061251e89828a0161245d565b979a9699509497509295939492505050565b60ff841681528260208201526060604082015260006125526060830184612321565b95945050505050565b60006020828403121561256d57600080fd5b815173ffffffffffffffffffffffffffffffffffffffff8116811461239f57600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60008219821115612602576126026125c0565b500190565b600082821015612619576126196125c0565b500390565b60006020828403121561263057600080fd5b5051919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b80516fffffffffffffffffffffffffffffffff8116811461240a57600080fd5b60006060828403121561269857600080fd5b6040516060810181811067ffffffffffffffff821117156126e2577f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604052825181526126f560208401612666565b602082015261270660408401612666565b60408201529392505050565b60006040828403121561272457600080fd5b6040516040810167ffffffffffffffff828210818311171561276f577f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b816040528451835260208501519150808216821461278c57600080fd5b5060208201529392505050565b60006fffffffffffffffffffffffffffffffff838116908316818110156127c2576127c26125c0565b039392505050565b60006fffffffffffffffffffffffffffffffff8083168185168083038211156127f5576127f56125c0565b01949350505050565b8183823760009101908152919050565b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b60408152600061286b60408301868861280e565b828103602084015261287e81858761280e565b979650505050505050565b600067ffffffffffffffff838116908316818110156127c2576127c26125c0565b600067ffffffffffffffff808416806128ec577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b92169190910692915050565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203612929576129296125c0565b506001019056fea164736f6c634300080f000a" +var FaultDisputeGameDeployedBin = "0x6080604052600436106101b75760003560e01c80638980e0cc116100ec578063c55cd0c71161008a578063d8cc1a3c11610064578063d8cc1a3c146106c1578063f8f43ff6146106e1578063fa24f74314610701578063fdffbb281461072557600080fd5b8063c55cd0c714610629578063c6f0308c1461063c578063cf09e0d0146106a057600080fd5b8063bbdc02db116100c6578063bbdc02db1461052d578063bcef3b551461056b578063c0c3a092146105a8578063c31b29ce146105dc57600080fd5b80638980e0cc146104a45780638b85902b146104b957806392931298146104f957600080fd5b8063529184c911610159578063609d333411610133578063609d333414610451578063632247ea146104665780636361506d146104795780638129fc1c1461048f57600080fd5b8063529184c91461033757806354fd4d501461036b57806355ef20e6146103c157600080fd5b8063298c900511610195578063298c90051461024f57806335fef5671461028f578063363cc427146102a45780634778efe81461030357600080fd5b8063200d2ed2146101bc578063266198f9146101f85780632810e1d61461023a575b600080fd5b3480156101c857600080fd5b506000546101e29068010000000000000000900460ff1681565b6040516101ef91906122c8565b60405180910390f35b34801561020457600080fd5b5061022c7f000000000000000000000000000000000000000000000000000000000000000081565b6040519081526020016101ef565b34801561024657600080fd5b506101e2610738565b34801561025b57600080fd5b50367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c90036040013561022c565b6102a261029d366004612309565b61089c565b005b3480156102b057600080fd5b506000546102de906901000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020016101ef565b34801561030f57600080fd5b5061022c7f000000000000000000000000000000000000000000000000000000000000000081565b34801561034357600080fd5b506102de7f000000000000000000000000000000000000000000000000000000000000000081565b34801561037757600080fd5b506103b46040518060400160405280600681526020017f302e302e3131000000000000000000000000000000000000000000000000000081525081565b6040516101ef9190612396565b3480156103cd57600080fd5b5060408051606080820183526003546fffffffffffffffffffffffffffffffff808216845270010000000000000000000000000000000091829004811660208086019190915260045485870152855193840186526005548083168552929092041690820152600654928101929092526104439182565b6040516101ef9291906123b0565b34801561045d57600080fd5b506103b46108ac565b6102a2610474366004612419565b6108ba565b34801561048557600080fd5b5061022c60015481565b34801561049b57600080fd5b506102a2610ed0565b3480156104b057600080fd5b5060025461022c565b3480156104c557600080fd5b50367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c90036020013561022c565b34801561050557600080fd5b506102de7f000000000000000000000000000000000000000000000000000000000000000081565b34801561053957600080fd5b5060405160ff7f00000000000000000000000000000000000000000000000000000000000000001681526020016101ef565b34801561057757600080fd5b50367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c90033561022c565b3480156105b457600080fd5b506102de7f000000000000000000000000000000000000000000000000000000000000000081565b3480156105e857600080fd5b506106107f000000000000000000000000000000000000000000000000000000000000000081565b60405167ffffffffffffffff90911681526020016101ef565b6102a2610637366004612309565b6114d4565b34801561064857600080fd5b5061065c61065736600461244e565b6114e0565b6040805163ffffffff90961686529315156020860152928401919091526fffffffffffffffffffffffffffffffff908116606084015216608082015260a0016101ef565b3480156106ac57600080fd5b506000546106109067ffffffffffffffff1681565b3480156106cd57600080fd5b506102a26106dc3660046124b0565b611551565b3480156106ed57600080fd5b506102a26106fc36600461253a565b611a7d565b34801561070d57600080fd5b50610716611c42565b6040516101ef93929190612566565b6102a261073336600461244e565b611c9f565b60008060005468010000000000000000900460ff16600281111561075e5761075e612299565b14610795576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60095460ff166107d1576040517f9a07664600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60026000815481106107e5576107e5612591565b6000918252602090912060039091020154640100000000900460ff1661080c57600261080f565b60015b6000805491925082917fffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff166801000000000000000083600281111561085657610856612299565b02179055600281111561086b5761086b612299565b6040517f5e186f09b9c93491f14e277eea7faa5de6a2d4bda75a79af7a3684fbfb42da6090600090a290565b905090565b6108a8828260006108ba565b5050565b606061089760206040611fd1565b6000805468010000000000000000900460ff1660028111156108de576108de612299565b14610915576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b82158015610921575080155b15610958576040517fa42637bc00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006002848154811061096d5761096d612591565b600091825260208083206040805160a081018252600394909402909101805463ffffffff808216865264010000000090910460ff16151593850193909352600181015491840191909152600201546fffffffffffffffffffffffffffffffff80821660608501819052700100000000000000000000000000000000909204166080840152919350610a019190859061206816565b90507f0000000000000000000000000000000000000000000000000000000000000000610ac0826fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b67ffffffffffffffff161115610b02576040517f56f57b2b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b815160009063ffffffff90811614610b62576002836000015163ffffffff1681548110610b3157610b31612591565b906000526020600020906003020160020160109054906101000a90046fffffffffffffffffffffffffffffffff1690505b608083015160009067ffffffffffffffff1667ffffffffffffffff1642610b9b846fffffffffffffffffffffffffffffffff1660401c90565b67ffffffffffffffff16610baf91906125ef565b610bb99190612607565b9050677fffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000060011c1667ffffffffffffffff82161115610c2c576040517f3381d11400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000604082901b42176000888152608086901b6fffffffffffffffffffffffffffffffff8b1617602052604081209192509060008181526007602052604090205490915060ff1615610caa576040517f80497e3b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600081815260076020908152604080832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155815160a08101835263ffffffff808f1682529381018581529281018d81526fffffffffffffffffffffffffffffffff808c16606084019081528982166080850190815260028054808801825599819052945160039099027f405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5ace8101805498511515640100000000027fffffffffffffffffffffffffffffffffffffffffffffffffffffff00000000009099169a909916999099179690961790965590517f405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5acf8701559351925184167001000000000000000000000000000000000292909316919091177f405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5ad09093019290925580548b908110610e2257610e22612591565b6000918252602080832060039092029091018054931515640100000000027fffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff909416939093179092558a8152600890915260409020600254610e8690600190612607565b8154600181018355600092835260208320015560405133918a918c917f9b3245740ec3b155098a55be84957a4da13eaf7f14a8bc6f53126c0b9350f2be91a4505050505050505050565b367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c90033560001a6001811480610f10575060ff81166002145b610f76576040517ff40239db000000000000000000000000000000000000000000000000000000008152367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c900335600482015260240160405180910390fd5b600080547fffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000164267ffffffffffffffff161781556040805160a08101825263ffffffff81526020810192909252600291908101610ffb7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe369081013560f01c90033590565b815260016020820152604001426fffffffffffffffffffffffffffffffff9081169091528254600181810185556000948552602080862085516003909402018054918601511515640100000000027fffffffffffffffffffffffffffffffffffffffffffffffffffffff000000000090921663ffffffff909416939093171782556040840151908201556060830151608090930151821670010000000000000000000000000000000002929091169190911760029091015573ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016637f00642061112460207ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe369081013560f01c9003013590565b6040518263ffffffff1660e01b815260040161114291815260200190565b602060405180830381865afa15801561115f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611183919061261e565b9050600073ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001663a25ae5576111ce600185612607565b6040518263ffffffff1660e01b81526004016111ec91815260200190565b606060405180830381865afa158015611209573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061122d9190612686565b6040517fa25ae5570000000000000000000000000000000000000000000000000000000081526004810184905290915060009073ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000169063a25ae55790602401606060405180830381865afa1580156112be573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906112e29190612686565b9050600073ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000166399d548aa367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c9003604001356040518263ffffffff1660e01b815260040161136e91815260200190565b6040805180830381865afa15801561138a573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113ae9190612712565b905081602001516fffffffffffffffffffffffffffffffff16816020015167ffffffffffffffff161161140d576040517f13809ba500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160a081018252908190810180611428600189612607565b6fffffffffffffffffffffffffffffffff908116825260408881015182166020808501919091529851928101929092529183528051606081018252978216885285810151821688880152945187860152908501959095528051805181860151908716700100000000000000000000000000000000918816820217600355908401516004559084015180519481015194861694909516029290921760055591909101516006555160015550565b6108a8828260016108ba565b600281815481106114f057600080fd5b600091825260209091206003909102018054600182015460029092015463ffffffff8216935064010000000090910460ff1691906fffffffffffffffffffffffffffffffff8082169170010000000000000000000000000000000090041685565b6000805468010000000000000000900460ff16600281111561157557611575612299565b146115ac576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000600287815481106115c1576115c1612591565b6000918252602082206003919091020160028101549092506fffffffffffffffffffffffffffffffff16908715821760011b90506116207f000000000000000000000000000000000000000000000000000000000000000060016125ef565b6116bc826fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b67ffffffffffffffff16146116fd576040517f5f53dd9800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600080891561178057611721836fffffffffffffffffffffffffffffffff16612070565b67ffffffffffffffff16156117545761174b61173e600186612799565b865463ffffffff16612116565b60010154611776565b7f00000000000000000000000000000000000000000000000000000000000000005b915084905061179a565b8460010154915061179784600161173e91906127ca565b90505b600882901b60088a8a6040516117b19291906127fe565b6040518091039020901b146117f2576040517f696550ff00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600081600101547f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663836e7b328c8c8c8c60006040518663ffffffff1660e01b815260040161185b959493929190612857565b6020604051808303816000875af115801561187a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061189e919061261e565b600284810154929091149250600091611949906fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b6119e5886fffffffffffffffffffffffffffffffff167e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b6119ef9190612891565b6119f991906128b2565b67ffffffffffffffff161590508115158103611a41576040517ffb4e40dd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505084547fffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff166401000000001790945550505050505050505050565b6000805468010000000000000000900460ff166002811115611aa157611aa1612299565b14611ad8576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60007f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16637dc0d1d06040518163ffffffff1660e01b8152600401602060405180830381865afa158015611b45573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611b699190612900565b7fc0c220c900000000000000000000000000000000000000000000000000000000601c8190526020869052604085905290915060008560018114611bd55760028114611bdf5760038114611be95760048114611bf35760058114611c035763ff137e656000526004601cfd5b6001549150611c0a565b6004549150611c0a565b6006549150611c0a565b60035460801c60c01b9150611c0a565b4660c01b91505b50606052600160038611811b6005031b60805260a083905260008060a4601c82865af1611c3b573d6000803e3d6000fd5b5050505050565b7f0000000000000000000000000000000000000000000000000000000000000000367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c9003356060611c986108ac565b9050909192565b6000805468010000000000000000900460ff166002811115611cc357611cc3612299565b14611cfa576040517f67fe195000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060028281548110611d0f57611d0f612591565b60009182526020909120600260039092020190810154909150677fffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000060011c1690611d7f90700100000000000000000000000000000000900467ffffffffffffffff1642612607565b6002830154611daf9190700100000000000000000000000000000000900460401c67ffffffffffffffff166125ef565b11611de6576040517ff2440b5300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260086020526040902082158015611e04575060095460ff165b15611e3b576040517ff1a9458100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8054158015611e4957508215155b15611e80576040517ff1a9458100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000805b8254811015611f4e576000838281548110611ea157611ea1612591565b6000918252602080832090910154808352600890915260409091205490915015611ef7576040517f9a07664600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060028281548110611f0c57611f0c612591565b600091825260209091206003909102018054909150640100000000900460ff16611f3b57600193505050611f4e565b505080611f4790612936565b9050611e84565b5082547fffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff16640100000000821515021783556000848152600860205260408120611f979161225f565b83600003611fcb57600980547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790555b50505050565b6060600061200884367ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe81013560f01c90036125ef565b90508267ffffffffffffffff1667ffffffffffffffff81111561202d5761202d612637565b6040519080825280601f01601f191660200182016040528015612057576020820181803683370190505b509150828160208401375092915050565b151760011b90565b6000806120fd837e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b600167ffffffffffffffff919091161b90920392915050565b600080612134846fffffffffffffffffffffffffffffffff166121b3565b90506002838154811061214957612149612591565b906000526020600020906003020191505b60028201546fffffffffffffffffffffffffffffffff8281169116146121ac57815460028054909163ffffffff1690811061219757612197612591565b9060005260206000209060030201915061215a565b5092915050565b60008119600183011681612247827e09010a0d15021d0b0e10121619031e080c141c0f111807131b17061a05041f7f07c4acdd0000000000000000000000000000000000000000000000000000000067ffffffffffffffff831160061b83811c63ffffffff1060051b1792831c600181901c17600281901c17600481901c17600881901c17601081901c170260fb1c1a1790565b67ffffffffffffffff169390931c8015179392505050565b508054600082559060005260206000209081019061227d9190612280565b50565b5b808211156122955760008155600101612281565b5090565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b6020810160038310612303577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b91905290565b6000806040838503121561231c57600080fd5b50508035926020909101359150565b6000815180845260005b8181101561235157602081850181015186830182015201612335565b81811115612363576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b6020815260006123a9602083018461232b565b9392505050565b82516fffffffffffffffffffffffffffffffff90811682526020808501518216818401526040808601518185015284518316606085015290840151909116608083015282015160a082015260c081016123a9565b8035801515811461241457600080fd5b919050565b60008060006060848603121561242e57600080fd5b833592506020840135915061244560408501612404565b90509250925092565b60006020828403121561246057600080fd5b5035919050565b60008083601f84011261247957600080fd5b50813567ffffffffffffffff81111561249157600080fd5b6020830191508360208285010111156124a957600080fd5b9250929050565b600080600080600080608087890312156124c957600080fd5b863595506124d960208801612404565b9450604087013567ffffffffffffffff808211156124f657600080fd5b6125028a838b01612467565b9096509450606089013591508082111561251b57600080fd5b5061252889828a01612467565b979a9699509497509295939492505050565b60008060006060848603121561254f57600080fd5b505081359360208301359350604090920135919050565b60ff84168152826020820152606060408201526000612588606083018461232b565b95945050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60008219821115612602576126026125c0565b500190565b600082821015612619576126196125c0565b500390565b60006020828403121561263057600080fd5b5051919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b80516fffffffffffffffffffffffffffffffff8116811461241457600080fd5b60006060828403121561269857600080fd5b6040516060810181811067ffffffffffffffff821117156126e2577f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604052825181526126f560208401612666565b602082015261270660408401612666565b60408201529392505050565b60006040828403121561272457600080fd5b6040516040810167ffffffffffffffff828210818311171561276f577f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b816040528451835260208501519150808216821461278c57600080fd5b5060208201529392505050565b60006fffffffffffffffffffffffffffffffff838116908316818110156127c2576127c26125c0565b039392505050565b60006fffffffffffffffffffffffffffffffff8083168185168083038211156127f5576127f56125c0565b01949350505050565b8183823760009101908152919050565b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b60608152600061286b60608301878961280e565b828103602084015261287e81868861280e565b9150508260408301529695505050505050565b600067ffffffffffffffff838116908316818110156127c2576127c26125c0565b600067ffffffffffffffff808416806128f4577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b92169190910692915050565b60006020828403121561291257600080fd5b815173ffffffffffffffffffffffffffffffffffffffff811681146123a957600080fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203612967576129676125c0565b506001019056fea164736f6c634300080f000a" func init() { if err := json.Unmarshal([]byte(FaultDisputeGameStorageLayoutJSON), FaultDisputeGameStorageLayout); err != nil { diff --git a/op-bindings/bindings/l1crossdomainmessenger.go b/op-bindings/bindings/l1crossdomainmessenger.go index ccc641c594fea..9ad96309297e5 100644 --- a/op-bindings/bindings/l1crossdomainmessenger.go +++ b/op-bindings/bindings/l1crossdomainmessenger.go @@ -31,7 +31,7 @@ var ( // L1CrossDomainMessengerMetaData contains all meta data concerning the L1CrossDomainMessenger contract. var L1CrossDomainMessengerMetaData = &bind.MetaData{ ABI: "[{\"inputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"msgHash\",\"type\":\"bytes32\"}],\"name\":\"FailedRelayedMessage\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"version\",\"type\":\"uint8\"}],\"name\":\"Initialized\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"msgHash\",\"type\":\"bytes32\"}],\"name\":\"RelayedMessage\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"message\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"messageNonce\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"}],\"name\":\"SentMessage\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"SentMessageExtension1\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MESSAGE_VERSION\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MIN_GAS_CALLDATA_OVERHEAD\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MIN_GAS_DYNAMIC_OVERHEAD_DENOMINATOR\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MIN_GAS_DYNAMIC_OVERHEAD_NUMERATOR\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"OTHER_MESSENGER\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"PORTAL\",\"outputs\":[{\"internalType\":\"contractOptimismPortal\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"RELAY_CALL_OVERHEAD\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"RELAY_CONSTANT_OVERHEAD\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"RELAY_GAS_CHECK_BUFFER\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"RELAY_RESERVED_GAS\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"_message\",\"type\":\"bytes\"},{\"internalType\":\"uint32\",\"name\":\"_minGasLimit\",\"type\":\"uint32\"}],\"name\":\"baseGas\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"failedMessages\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"contractOptimismPortal\",\"name\":\"_portal\",\"type\":\"address\"}],\"name\":\"initialize\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"messageNonce\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"portal\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_nonce\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"_sender\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_target\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_value\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_minGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"_message\",\"type\":\"bytes\"}],\"name\":\"relayMessage\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_target\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"_message\",\"type\":\"bytes\"},{\"internalType\":\"uint32\",\"name\":\"_minGasLimit\",\"type\":\"uint32\"}],\"name\":\"sendMessage\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"successfulMessages\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"version\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"xDomainMessageSender\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", - Bin: "0x60a06040523480156200001157600080fd5b507342000000000000000000000000000000000000076080526200003660006200003c565b620001ea565b600054600390600160a81b900460ff1615801562000068575060005460ff808316600160a01b90920416105b620000d15760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084015b60405180910390fd5b60008054600160a81b61ffff60a01b19909116600160a01b60ff85160260ff60a81b19161717905560f980546001600160a01b0319166001600160a01b0384161790556200011e62000165565b6000805460ff60a81b1916905560405160ff821681527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050565b600054600160a81b900460ff16620001d45760405162461bcd60e51b815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201526a6e697469616c697a696e6760a81b6064820152608401620000c8565b60cc80546001600160a01b03191661dead179055565b608051611cee620002146000396000818161033b0152818161048a01526114ef0152611cee6000f3fe60806040526004361061015f5760003560e01c80636e296e45116100c0578063b1b1b20911610074578063c4d66de811610059578063c4d66de8146103ed578063d764ad0b1461040d578063ecc704281461042057600080fd5b8063b1b1b2091461039d578063b28ade25146103cd57600080fd5b80638cbeeef2116100a55780638cbeeef2146102505780639fce812c14610329578063a4e7f8bd1461035d57600080fd5b80636e296e45146102fd57806383a740741461031257600080fd5b80633f827a5a1161011757806354fd4d50116100fc57806354fd4d50146102665780635644cfdf146102bc5780636425666b146102d257600080fd5b80633f827a5a146102285780634c1d6a691461025057600080fd5b80630ff754ea116101485780630ff754ea146101ac5780632828d7e8146101fe5780633dbb202b1461021357600080fd5b8063028f85f7146101645780630c56849814610197575b600080fd5b34801561017057600080fd5b50610179601081565b60405167ffffffffffffffff90911681526020015b60405180910390f35b3480156101a357600080fd5b50610179603f81565b3480156101b857600080fd5b5060f9546101d99073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161018e565b34801561020a57600080fd5b50610179604081565b6102266102213660046117ba565b610485565b005b34801561023457600080fd5b5061023d600181565b60405161ffff909116815260200161018e565b34801561025c57600080fd5b50610179619c4081565b34801561027257600080fd5b506102af6040518060400160405280600581526020017f312e372e3000000000000000000000000000000000000000000000000000000081525081565b60405161018e919061188c565b3480156102c857600080fd5b5061017961138881565b3480156102de57600080fd5b5060f95473ffffffffffffffffffffffffffffffffffffffff166101d9565b34801561030957600080fd5b506101d96106e9565b34801561031e57600080fd5b5061017962030d4081565b34801561033557600080fd5b506101d97f000000000000000000000000000000000000000000000000000000000000000081565b34801561036957600080fd5b5061038d6103783660046118a6565b60ce6020526000908152604090205460ff1681565b604051901515815260200161018e565b3480156103a957600080fd5b5061038d6103b83660046118a6565b60cb6020526000908152604090205460ff1681565b3480156103d957600080fd5b506101796103e83660046118bf565b6107d5565b3480156103f957600080fd5b50610226610408366004611913565b610843565b61022661041b366004611930565b610a47565b34801561042c57600080fd5b5061047760cd547dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e010000000000000000000000000000000000000000000000000000000000001790565b60405190815260200161018e565b6105be7f00000000000000000000000000000000000000000000000000000000000000006104b48585856107d5565b347fd764ad0b0000000000000000000000000000000000000000000000000000000061052060cd547dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e010000000000000000000000000000000000000000000000000000000000001790565b338a34898c8c60405160240161053c97969594939291906119ff565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff00000000000000000000000000000000000000000000000000000000909316929092179091526112d3565b8373ffffffffffffffffffffffffffffffffffffffff167fcb0f7ffd78f9aee47a248fae8db181db6eee833039123e026dcbff529522e52a33858561064360cd547dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e010000000000000000000000000000000000000000000000000000000000001790565b86604051610655959493929190611a5e565b60405180910390a260405134815233907f8ebb2ec2465bdb2a06a66fc37a0963af8a2a6a1479d81d56fdb8cbb98096d5469060200160405180910390a2505060cd80547dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff808216600101167fffff0000000000000000000000000000000000000000000000000000000000009091161790555050565b60cc5460009073ffffffffffffffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff2153016107b8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603560248201527f43726f7373446f6d61696e4d657373656e6765723a2078446f6d61696e4d657360448201527f7361676553656e646572206973206e6f7420736574000000000000000000000060648201526084015b60405180910390fd5b5060cc5473ffffffffffffffffffffffffffffffffffffffff1690565b6000611388619c4080603f6107f1604063ffffffff8816611adb565b6107fb9190611b0b565b610806601088611adb565b6108139062030d40611b59565b61081d9190611b59565b6108279190611b59565b6108319190611b59565b61083b9190611b59565b949350505050565b6000546003907501000000000000000000000000000000000000000000900460ff16158015610891575060005460ff8083167401000000000000000000000000000000000000000090920416105b61091d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a656400000000000000000000000000000000000060648201526084016107af565b6000805475010000000000000000000000000000000000000000007fffffffffffffffffffff0000ffffffffffffffffffffffffffffffffffffffff9091167401000000000000000000000000000000000000000060ff8516027fffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff161717905560f980547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff84161790556109e561136c565b600080547fffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff16905560405160ff821681527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050565b60f087901c60028110610b02576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604d60248201527f43726f7373446f6d61696e4d657373656e6765723a206f6e6c7920766572736960448201527f6f6e2030206f722031206d657373616765732061726520737570706f7274656460648201527f20617420746869732074696d6500000000000000000000000000000000000000608482015260a4016107af565b8061ffff16600003610bf7576000610b53878986868080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508f9250611445915050565b600081815260cb602052604090205490915060ff1615610bf5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f43726f7373446f6d61696e4d657373656e6765723a206c65676163792077697460448201527f6864726177616c20616c72656164792072656c6179656400000000000000000060648201526084016107af565b505b6000610c3d898989898989898080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061146492505050565b9050610c47611487565b15610c7f57853414610c5b57610c5b611b85565b600081815260ce602052604090205460ff1615610c7a57610c7a611b85565b610dd1565b3415610d33576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152605060248201527f43726f7373446f6d61696e4d657373656e6765723a2076616c7565206d75737460448201527f206265207a65726f20756e6c657373206d6573736167652069732066726f6d2060648201527f612073797374656d206164647265737300000000000000000000000000000000608482015260a4016107af565b600081815260ce602052604090205460ff16610dd1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603060248201527f43726f7373446f6d61696e4d657373656e6765723a206d65737361676520636160448201527f6e6e6f74206265207265706c617965640000000000000000000000000000000060648201526084016107af565b610dda8761157d565b15610e8d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604360248201527f43726f7373446f6d61696e4d657373656e6765723a2063616e6e6f742073656e60448201527f64206d65737361676520746f20626c6f636b65642073797374656d206164647260648201527f6573730000000000000000000000000000000000000000000000000000000000608482015260a4016107af565b600081815260cb602052604090205460ff1615610f2c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603660248201527f43726f7373446f6d61696e4d657373656e6765723a206d65737361676520686160448201527f7320616c7265616479206265656e2072656c617965640000000000000000000060648201526084016107af565b610f4d85610f3e611388619c40611b59565b67ffffffffffffffff166115c3565b1580610f73575060cc5473ffffffffffffffffffffffffffffffffffffffff1661dead14155b1561108c57600081815260ce602052604080822080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790555182917f99d0e048484baa1b1540b1367cb128acd7ab2946d1ed91ec10e3c85e4bf51b8f91a27fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff3201611085576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602d60248201527f43726f7373446f6d61696e4d657373656e6765723a206661696c656420746f2060448201527f72656c6179206d6573736167650000000000000000000000000000000000000060648201526084016107af565b50506112c5565b60cc80547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff8a16179055600061111d88619c405a6110e09190611bb4565b8988888080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506115e192505050565b60cc80547fffffffffffffffffffffffff00000000000000000000000000000000000000001661dead179055905080156111b457600082815260cb602052604080822080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790555183917f4641df4a962071e12719d8c8c8e5ac7fc4d97b927346a3d7a335b1f7517e133c91a26112c1565b600082815260ce602052604080822080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790555183917f99d0e048484baa1b1540b1367cb128acd7ab2946d1ed91ec10e3c85e4bf51b8f91a27fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff32016112c1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602d60248201527f43726f7373446f6d61696e4d657373656e6765723a206661696c656420746f2060448201527f72656c6179206d6573736167650000000000000000000000000000000000000060648201526084016107af565b5050505b50505050505050565b905090565b60f9546040517fe9e05c4200000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff9091169063e9e05c42908490611334908890839089906000908990600401611bcb565b6000604051808303818588803b15801561134d57600080fd5b505af1158015611361573d6000803e3d6000fd5b505050505050505050565b6000547501000000000000000000000000000000000000000000900460ff16611417576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e6700000000000000000000000000000000000000000060648201526084016107af565b60cc80547fffffffffffffffffffffffff00000000000000000000000000000000000000001661dead179055565b6000611453858585856115fb565b805190602001209050949350505050565b6000611474878787878787611694565b8051906020012090509695505050505050565b60f95460009073ffffffffffffffffffffffffffffffffffffffff16331480156112ce575060f954604080517f9bf62d82000000000000000000000000000000000000000000000000000000008152905173ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000008116931691639bf62d829160048083019260209291908290030181865afa15801561153d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906115619190611c23565b73ffffffffffffffffffffffffffffffffffffffff1614905090565b600073ffffffffffffffffffffffffffffffffffffffff82163014806115bd575060f95473ffffffffffffffffffffffffffffffffffffffff8381169116145b92915050565b600080603f83619c4001026040850201603f5a021015949350505050565b600080600080845160208601878a8af19695505050505050565b6060848484846040516024016116149493929190611c40565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fcbd4ece9000000000000000000000000000000000000000000000000000000001790529050949350505050565b60608686868686866040516024016116b196959493929190611c8a565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fd764ad0b0000000000000000000000000000000000000000000000000000000017905290509695505050505050565b73ffffffffffffffffffffffffffffffffffffffff8116811461175557600080fd5b50565b60008083601f84011261176a57600080fd5b50813567ffffffffffffffff81111561178257600080fd5b60208301915083602082850101111561179a57600080fd5b9250929050565b803563ffffffff811681146117b557600080fd5b919050565b600080600080606085870312156117d057600080fd5b84356117db81611733565b9350602085013567ffffffffffffffff8111156117f757600080fd5b61180387828801611758565b90945092506118169050604086016117a1565b905092959194509250565b6000815180845260005b818110156118475760208185018101518683018201520161182b565b81811115611859576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60208152600061189f6020830184611821565b9392505050565b6000602082840312156118b857600080fd5b5035919050565b6000806000604084860312156118d457600080fd5b833567ffffffffffffffff8111156118eb57600080fd5b6118f786828701611758565b909450925061190a9050602085016117a1565b90509250925092565b60006020828403121561192557600080fd5b813561189f81611733565b600080600080600080600060c0888a03121561194b57600080fd5b87359650602088013561195d81611733565b9550604088013561196d81611733565b9450606088013593506080880135925060a088013567ffffffffffffffff81111561199757600080fd5b6119a38a828b01611758565b989b979a50959850939692959293505050565b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b878152600073ffffffffffffffffffffffffffffffffffffffff808916602084015280881660408401525085606083015263ffffffff8516608083015260c060a0830152611a5160c0830184866119b6565b9998505050505050505050565b73ffffffffffffffffffffffffffffffffffffffff86168152608060208201526000611a8e6080830186886119b6565b905083604083015263ffffffff831660608301529695505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600067ffffffffffffffff80831681851681830481118215151615611b0257611b02611aac565b02949350505050565b600067ffffffffffffffff80841680611b4d577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b92169190910492915050565b600067ffffffffffffffff808316818516808303821115611b7c57611b7c611aac565b01949350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052600160045260246000fd5b600082821015611bc657611bc6611aac565b500390565b73ffffffffffffffffffffffffffffffffffffffff8616815284602082015267ffffffffffffffff84166040820152821515606082015260a060808201526000611c1860a0830184611821565b979650505050505050565b600060208284031215611c3557600080fd5b815161189f81611733565b600073ffffffffffffffffffffffffffffffffffffffff808716835280861660208401525060806040830152611c796080830185611821565b905082606083015295945050505050565b868152600073ffffffffffffffffffffffffffffffffffffffff808816602084015280871660408401525084606083015283608083015260c060a0830152611cd560c0830184611821565b9897505050505050505056fea164736f6c634300080f000a", + Bin: "0x60a06040523480156200001157600080fd5b507342000000000000000000000000000000000000076080526200003660006200003c565b620001ea565b600054600390600160a81b900460ff1615801562000068575060005460ff808316600160a01b90920416105b620000d15760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084015b60405180910390fd5b60008054600160a81b61ffff60a01b19909116600160a01b60ff85160260ff60a81b19161717905560f980546001600160a01b0319166001600160a01b0384161790556200011e62000165565b6000805460ff60a81b1916905560405160ff821681527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050565b600054600160a81b900460ff16620001d45760405162461bcd60e51b815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201526a6e697469616c697a696e6760a81b6064820152608401620000c8565b60cc80546001600160a01b03191661dead179055565b608051611cee620002146000396000818161033b0152818161048a01526114ef0152611cee6000f3fe60806040526004361061015f5760003560e01c80636e296e45116100c0578063b1b1b20911610074578063c4d66de811610059578063c4d66de8146103ed578063d764ad0b1461040d578063ecc704281461042057600080fd5b8063b1b1b2091461039d578063b28ade25146103cd57600080fd5b80638cbeeef2116100a55780638cbeeef2146102505780639fce812c14610329578063a4e7f8bd1461035d57600080fd5b80636e296e45146102fd57806383a740741461031257600080fd5b80633f827a5a1161011757806354fd4d50116100fc57806354fd4d50146102665780635644cfdf146102bc5780636425666b146102d257600080fd5b80633f827a5a146102285780634c1d6a691461025057600080fd5b80630ff754ea116101485780630ff754ea146101ac5780632828d7e8146101fe5780633dbb202b1461021357600080fd5b8063028f85f7146101645780630c56849814610197575b600080fd5b34801561017057600080fd5b50610179601081565b60405167ffffffffffffffff90911681526020015b60405180910390f35b3480156101a357600080fd5b50610179603f81565b3480156101b857600080fd5b5060f9546101d99073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161018e565b34801561020a57600080fd5b50610179604081565b6102266102213660046117ba565b610485565b005b34801561023457600080fd5b5061023d600181565b60405161ffff909116815260200161018e565b34801561025c57600080fd5b50610179619c4081565b34801561027257600080fd5b506102af6040518060400160405280600581526020017f312e372e3100000000000000000000000000000000000000000000000000000081525081565b60405161018e919061188c565b3480156102c857600080fd5b5061017961138881565b3480156102de57600080fd5b5060f95473ffffffffffffffffffffffffffffffffffffffff166101d9565b34801561030957600080fd5b506101d96106e9565b34801561031e57600080fd5b5061017962030d4081565b34801561033557600080fd5b506101d97f000000000000000000000000000000000000000000000000000000000000000081565b34801561036957600080fd5b5061038d6103783660046118a6565b60ce6020526000908152604090205460ff1681565b604051901515815260200161018e565b3480156103a957600080fd5b5061038d6103b83660046118a6565b60cb6020526000908152604090205460ff1681565b3480156103d957600080fd5b506101796103e83660046118bf565b6107d5565b3480156103f957600080fd5b50610226610408366004611913565b610843565b61022661041b366004611930565b610a47565b34801561042c57600080fd5b5061047760cd547dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e010000000000000000000000000000000000000000000000000000000000001790565b60405190815260200161018e565b6105be7f00000000000000000000000000000000000000000000000000000000000000006104b48585856107d5565b347fd764ad0b0000000000000000000000000000000000000000000000000000000061052060cd547dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e010000000000000000000000000000000000000000000000000000000000001790565b338a34898c8c60405160240161053c97969594939291906119ff565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff00000000000000000000000000000000000000000000000000000000909316929092179091526112d3565b8373ffffffffffffffffffffffffffffffffffffffff167fcb0f7ffd78f9aee47a248fae8db181db6eee833039123e026dcbff529522e52a33858561064360cd547dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e010000000000000000000000000000000000000000000000000000000000001790565b86604051610655959493929190611a5e565b60405180910390a260405134815233907f8ebb2ec2465bdb2a06a66fc37a0963af8a2a6a1479d81d56fdb8cbb98096d5469060200160405180910390a2505060cd80547dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff808216600101167fffff0000000000000000000000000000000000000000000000000000000000009091161790555050565b60cc5460009073ffffffffffffffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff2153016107b8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603560248201527f43726f7373446f6d61696e4d657373656e6765723a2078446f6d61696e4d657360448201527f7361676553656e646572206973206e6f7420736574000000000000000000000060648201526084015b60405180910390fd5b5060cc5473ffffffffffffffffffffffffffffffffffffffff1690565b6000611388619c4080603f6107f1604063ffffffff8816611adb565b6107fb9190611b0b565b610806601088611adb565b6108139062030d40611b59565b61081d9190611b59565b6108279190611b59565b6108319190611b59565b61083b9190611b59565b949350505050565b6000546003907501000000000000000000000000000000000000000000900460ff16158015610891575060005460ff8083167401000000000000000000000000000000000000000090920416105b61091d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a656400000000000000000000000000000000000060648201526084016107af565b6000805475010000000000000000000000000000000000000000007fffffffffffffffffffff0000ffffffffffffffffffffffffffffffffffffffff9091167401000000000000000000000000000000000000000060ff8516027fffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff161717905560f980547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff84161790556109e561136c565b600080547fffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff16905560405160ff821681527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050565b60f087901c60028110610b02576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604d60248201527f43726f7373446f6d61696e4d657373656e6765723a206f6e6c7920766572736960448201527f6f6e2030206f722031206d657373616765732061726520737570706f7274656460648201527f20617420746869732074696d6500000000000000000000000000000000000000608482015260a4016107af565b8061ffff16600003610bf7576000610b53878986868080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508f9250611445915050565b600081815260cb602052604090205490915060ff1615610bf5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f43726f7373446f6d61696e4d657373656e6765723a206c65676163792077697460448201527f6864726177616c20616c72656164792072656c6179656400000000000000000060648201526084016107af565b505b6000610c3d898989898989898080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061146492505050565b9050610c47611487565b15610c7f57853414610c5b57610c5b611b85565b600081815260ce602052604090205460ff1615610c7a57610c7a611b85565b610dd1565b3415610d33576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152605060248201527f43726f7373446f6d61696e4d657373656e6765723a2076616c7565206d75737460448201527f206265207a65726f20756e6c657373206d6573736167652069732066726f6d2060648201527f612073797374656d206164647265737300000000000000000000000000000000608482015260a4016107af565b600081815260ce602052604090205460ff16610dd1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603060248201527f43726f7373446f6d61696e4d657373656e6765723a206d65737361676520636160448201527f6e6e6f74206265207265706c617965640000000000000000000000000000000060648201526084016107af565b610dda8761157d565b15610e8d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604360248201527f43726f7373446f6d61696e4d657373656e6765723a2063616e6e6f742073656e60448201527f64206d65737361676520746f20626c6f636b65642073797374656d206164647260648201527f6573730000000000000000000000000000000000000000000000000000000000608482015260a4016107af565b600081815260cb602052604090205460ff1615610f2c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603660248201527f43726f7373446f6d61696e4d657373656e6765723a206d65737361676520686160448201527f7320616c7265616479206265656e2072656c617965640000000000000000000060648201526084016107af565b610f4d85610f3e611388619c40611b59565b67ffffffffffffffff166115c3565b1580610f73575060cc5473ffffffffffffffffffffffffffffffffffffffff1661dead14155b1561108c57600081815260ce602052604080822080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790555182917f99d0e048484baa1b1540b1367cb128acd7ab2946d1ed91ec10e3c85e4bf51b8f91a27fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff3201611085576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602d60248201527f43726f7373446f6d61696e4d657373656e6765723a206661696c656420746f2060448201527f72656c6179206d6573736167650000000000000000000000000000000000000060648201526084016107af565b50506112c5565b60cc80547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff8a16179055600061111d88619c405a6110e09190611bb4565b8988888080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506115e192505050565b60cc80547fffffffffffffffffffffffff00000000000000000000000000000000000000001661dead179055905080156111b457600082815260cb602052604080822080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790555183917f4641df4a962071e12719d8c8c8e5ac7fc4d97b927346a3d7a335b1f7517e133c91a26112c1565b600082815260ce602052604080822080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790555183917f99d0e048484baa1b1540b1367cb128acd7ab2946d1ed91ec10e3c85e4bf51b8f91a27fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff32016112c1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602d60248201527f43726f7373446f6d61696e4d657373656e6765723a206661696c656420746f2060448201527f72656c6179206d6573736167650000000000000000000000000000000000000060648201526084016107af565b5050505b50505050505050565b905090565b60f9546040517fe9e05c4200000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff9091169063e9e05c42908490611334908890839089906000908990600401611bcb565b6000604051808303818588803b15801561134d57600080fd5b505af1158015611361573d6000803e3d6000fd5b505050505050505050565b6000547501000000000000000000000000000000000000000000900460ff16611417576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e6700000000000000000000000000000000000000000060648201526084016107af565b60cc80547fffffffffffffffffffffffff00000000000000000000000000000000000000001661dead179055565b6000611453858585856115fb565b805190602001209050949350505050565b6000611474878787878787611694565b8051906020012090509695505050505050565b60f95460009073ffffffffffffffffffffffffffffffffffffffff16331480156112ce575060f954604080517f9bf62d82000000000000000000000000000000000000000000000000000000008152905173ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000008116931691639bf62d829160048083019260209291908290030181865afa15801561153d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906115619190611c23565b73ffffffffffffffffffffffffffffffffffffffff1614905090565b600073ffffffffffffffffffffffffffffffffffffffff82163014806115bd575060f95473ffffffffffffffffffffffffffffffffffffffff8381169116145b92915050565b600080603f83619c4001026040850201603f5a021015949350505050565b600080600080845160208601878a8af19695505050505050565b6060848484846040516024016116149493929190611c40565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fcbd4ece9000000000000000000000000000000000000000000000000000000001790529050949350505050565b60608686868686866040516024016116b196959493929190611c8a565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fd764ad0b0000000000000000000000000000000000000000000000000000000017905290509695505050505050565b73ffffffffffffffffffffffffffffffffffffffff8116811461175557600080fd5b50565b60008083601f84011261176a57600080fd5b50813567ffffffffffffffff81111561178257600080fd5b60208301915083602082850101111561179a57600080fd5b9250929050565b803563ffffffff811681146117b557600080fd5b919050565b600080600080606085870312156117d057600080fd5b84356117db81611733565b9350602085013567ffffffffffffffff8111156117f757600080fd5b61180387828801611758565b90945092506118169050604086016117a1565b905092959194509250565b6000815180845260005b818110156118475760208185018101518683018201520161182b565b81811115611859576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60208152600061189f6020830184611821565b9392505050565b6000602082840312156118b857600080fd5b5035919050565b6000806000604084860312156118d457600080fd5b833567ffffffffffffffff8111156118eb57600080fd5b6118f786828701611758565b909450925061190a9050602085016117a1565b90509250925092565b60006020828403121561192557600080fd5b813561189f81611733565b600080600080600080600060c0888a03121561194b57600080fd5b87359650602088013561195d81611733565b9550604088013561196d81611733565b9450606088013593506080880135925060a088013567ffffffffffffffff81111561199757600080fd5b6119a38a828b01611758565b989b979a50959850939692959293505050565b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b878152600073ffffffffffffffffffffffffffffffffffffffff808916602084015280881660408401525085606083015263ffffffff8516608083015260c060a0830152611a5160c0830184866119b6565b9998505050505050505050565b73ffffffffffffffffffffffffffffffffffffffff86168152608060208201526000611a8e6080830186886119b6565b905083604083015263ffffffff831660608301529695505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600067ffffffffffffffff80831681851681830481118215151615611b0257611b02611aac565b02949350505050565b600067ffffffffffffffff80841680611b4d577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b92169190910492915050565b600067ffffffffffffffff808316818516808303821115611b7c57611b7c611aac565b01949350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052600160045260246000fd5b600082821015611bc657611bc6611aac565b500390565b73ffffffffffffffffffffffffffffffffffffffff8616815284602082015267ffffffffffffffff84166040820152821515606082015260a060808201526000611c1860a0830184611821565b979650505050505050565b600060208284031215611c3557600080fd5b815161189f81611733565b600073ffffffffffffffffffffffffffffffffffffffff808716835280861660208401525060806040830152611c796080830185611821565b905082606083015295945050505050565b868152600073ffffffffffffffffffffffffffffffffffffffff808816602084015280871660408401525084606083015283608083015260c060a0830152611cd560c0830184611821565b9897505050505050505056fea164736f6c634300080f000a", } // L1CrossDomainMessengerABI is the input ABI used to generate the binding from. diff --git a/op-bindings/bindings/l1crossdomainmessenger_more.go b/op-bindings/bindings/l1crossdomainmessenger_more.go index a23e6ea792dd6..66a1c93bbe6f8 100644 --- a/op-bindings/bindings/l1crossdomainmessenger_more.go +++ b/op-bindings/bindings/l1crossdomainmessenger_more.go @@ -13,7 +13,7 @@ const L1CrossDomainMessengerStorageLayoutJSON = "{\"storage\":[{\"astId\":1000,\ var L1CrossDomainMessengerStorageLayout = new(solc.StorageLayout) -var L1CrossDomainMessengerDeployedBin = "0x60806040526004361061015f5760003560e01c80636e296e45116100c0578063b1b1b20911610074578063c4d66de811610059578063c4d66de8146103ed578063d764ad0b1461040d578063ecc704281461042057600080fd5b8063b1b1b2091461039d578063b28ade25146103cd57600080fd5b80638cbeeef2116100a55780638cbeeef2146102505780639fce812c14610329578063a4e7f8bd1461035d57600080fd5b80636e296e45146102fd57806383a740741461031257600080fd5b80633f827a5a1161011757806354fd4d50116100fc57806354fd4d50146102665780635644cfdf146102bc5780636425666b146102d257600080fd5b80633f827a5a146102285780634c1d6a691461025057600080fd5b80630ff754ea116101485780630ff754ea146101ac5780632828d7e8146101fe5780633dbb202b1461021357600080fd5b8063028f85f7146101645780630c56849814610197575b600080fd5b34801561017057600080fd5b50610179601081565b60405167ffffffffffffffff90911681526020015b60405180910390f35b3480156101a357600080fd5b50610179603f81565b3480156101b857600080fd5b5060f9546101d99073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161018e565b34801561020a57600080fd5b50610179604081565b6102266102213660046117ba565b610485565b005b34801561023457600080fd5b5061023d600181565b60405161ffff909116815260200161018e565b34801561025c57600080fd5b50610179619c4081565b34801561027257600080fd5b506102af6040518060400160405280600581526020017f312e372e3000000000000000000000000000000000000000000000000000000081525081565b60405161018e919061188c565b3480156102c857600080fd5b5061017961138881565b3480156102de57600080fd5b5060f95473ffffffffffffffffffffffffffffffffffffffff166101d9565b34801561030957600080fd5b506101d96106e9565b34801561031e57600080fd5b5061017962030d4081565b34801561033557600080fd5b506101d97f000000000000000000000000000000000000000000000000000000000000000081565b34801561036957600080fd5b5061038d6103783660046118a6565b60ce6020526000908152604090205460ff1681565b604051901515815260200161018e565b3480156103a957600080fd5b5061038d6103b83660046118a6565b60cb6020526000908152604090205460ff1681565b3480156103d957600080fd5b506101796103e83660046118bf565b6107d5565b3480156103f957600080fd5b50610226610408366004611913565b610843565b61022661041b366004611930565b610a47565b34801561042c57600080fd5b5061047760cd547dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e010000000000000000000000000000000000000000000000000000000000001790565b60405190815260200161018e565b6105be7f00000000000000000000000000000000000000000000000000000000000000006104b48585856107d5565b347fd764ad0b0000000000000000000000000000000000000000000000000000000061052060cd547dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e010000000000000000000000000000000000000000000000000000000000001790565b338a34898c8c60405160240161053c97969594939291906119ff565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff00000000000000000000000000000000000000000000000000000000909316929092179091526112d3565b8373ffffffffffffffffffffffffffffffffffffffff167fcb0f7ffd78f9aee47a248fae8db181db6eee833039123e026dcbff529522e52a33858561064360cd547dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e010000000000000000000000000000000000000000000000000000000000001790565b86604051610655959493929190611a5e565b60405180910390a260405134815233907f8ebb2ec2465bdb2a06a66fc37a0963af8a2a6a1479d81d56fdb8cbb98096d5469060200160405180910390a2505060cd80547dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff808216600101167fffff0000000000000000000000000000000000000000000000000000000000009091161790555050565b60cc5460009073ffffffffffffffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff2153016107b8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603560248201527f43726f7373446f6d61696e4d657373656e6765723a2078446f6d61696e4d657360448201527f7361676553656e646572206973206e6f7420736574000000000000000000000060648201526084015b60405180910390fd5b5060cc5473ffffffffffffffffffffffffffffffffffffffff1690565b6000611388619c4080603f6107f1604063ffffffff8816611adb565b6107fb9190611b0b565b610806601088611adb565b6108139062030d40611b59565b61081d9190611b59565b6108279190611b59565b6108319190611b59565b61083b9190611b59565b949350505050565b6000546003907501000000000000000000000000000000000000000000900460ff16158015610891575060005460ff8083167401000000000000000000000000000000000000000090920416105b61091d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a656400000000000000000000000000000000000060648201526084016107af565b6000805475010000000000000000000000000000000000000000007fffffffffffffffffffff0000ffffffffffffffffffffffffffffffffffffffff9091167401000000000000000000000000000000000000000060ff8516027fffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff161717905560f980547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff84161790556109e561136c565b600080547fffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff16905560405160ff821681527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050565b60f087901c60028110610b02576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604d60248201527f43726f7373446f6d61696e4d657373656e6765723a206f6e6c7920766572736960448201527f6f6e2030206f722031206d657373616765732061726520737570706f7274656460648201527f20617420746869732074696d6500000000000000000000000000000000000000608482015260a4016107af565b8061ffff16600003610bf7576000610b53878986868080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508f9250611445915050565b600081815260cb602052604090205490915060ff1615610bf5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f43726f7373446f6d61696e4d657373656e6765723a206c65676163792077697460448201527f6864726177616c20616c72656164792072656c6179656400000000000000000060648201526084016107af565b505b6000610c3d898989898989898080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061146492505050565b9050610c47611487565b15610c7f57853414610c5b57610c5b611b85565b600081815260ce602052604090205460ff1615610c7a57610c7a611b85565b610dd1565b3415610d33576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152605060248201527f43726f7373446f6d61696e4d657373656e6765723a2076616c7565206d75737460448201527f206265207a65726f20756e6c657373206d6573736167652069732066726f6d2060648201527f612073797374656d206164647265737300000000000000000000000000000000608482015260a4016107af565b600081815260ce602052604090205460ff16610dd1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603060248201527f43726f7373446f6d61696e4d657373656e6765723a206d65737361676520636160448201527f6e6e6f74206265207265706c617965640000000000000000000000000000000060648201526084016107af565b610dda8761157d565b15610e8d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604360248201527f43726f7373446f6d61696e4d657373656e6765723a2063616e6e6f742073656e60448201527f64206d65737361676520746f20626c6f636b65642073797374656d206164647260648201527f6573730000000000000000000000000000000000000000000000000000000000608482015260a4016107af565b600081815260cb602052604090205460ff1615610f2c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603660248201527f43726f7373446f6d61696e4d657373656e6765723a206d65737361676520686160448201527f7320616c7265616479206265656e2072656c617965640000000000000000000060648201526084016107af565b610f4d85610f3e611388619c40611b59565b67ffffffffffffffff166115c3565b1580610f73575060cc5473ffffffffffffffffffffffffffffffffffffffff1661dead14155b1561108c57600081815260ce602052604080822080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790555182917f99d0e048484baa1b1540b1367cb128acd7ab2946d1ed91ec10e3c85e4bf51b8f91a27fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff3201611085576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602d60248201527f43726f7373446f6d61696e4d657373656e6765723a206661696c656420746f2060448201527f72656c6179206d6573736167650000000000000000000000000000000000000060648201526084016107af565b50506112c5565b60cc80547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff8a16179055600061111d88619c405a6110e09190611bb4565b8988888080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506115e192505050565b60cc80547fffffffffffffffffffffffff00000000000000000000000000000000000000001661dead179055905080156111b457600082815260cb602052604080822080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790555183917f4641df4a962071e12719d8c8c8e5ac7fc4d97b927346a3d7a335b1f7517e133c91a26112c1565b600082815260ce602052604080822080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790555183917f99d0e048484baa1b1540b1367cb128acd7ab2946d1ed91ec10e3c85e4bf51b8f91a27fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff32016112c1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602d60248201527f43726f7373446f6d61696e4d657373656e6765723a206661696c656420746f2060448201527f72656c6179206d6573736167650000000000000000000000000000000000000060648201526084016107af565b5050505b50505050505050565b905090565b60f9546040517fe9e05c4200000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff9091169063e9e05c42908490611334908890839089906000908990600401611bcb565b6000604051808303818588803b15801561134d57600080fd5b505af1158015611361573d6000803e3d6000fd5b505050505050505050565b6000547501000000000000000000000000000000000000000000900460ff16611417576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e6700000000000000000000000000000000000000000060648201526084016107af565b60cc80547fffffffffffffffffffffffff00000000000000000000000000000000000000001661dead179055565b6000611453858585856115fb565b805190602001209050949350505050565b6000611474878787878787611694565b8051906020012090509695505050505050565b60f95460009073ffffffffffffffffffffffffffffffffffffffff16331480156112ce575060f954604080517f9bf62d82000000000000000000000000000000000000000000000000000000008152905173ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000008116931691639bf62d829160048083019260209291908290030181865afa15801561153d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906115619190611c23565b73ffffffffffffffffffffffffffffffffffffffff1614905090565b600073ffffffffffffffffffffffffffffffffffffffff82163014806115bd575060f95473ffffffffffffffffffffffffffffffffffffffff8381169116145b92915050565b600080603f83619c4001026040850201603f5a021015949350505050565b600080600080845160208601878a8af19695505050505050565b6060848484846040516024016116149493929190611c40565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fcbd4ece9000000000000000000000000000000000000000000000000000000001790529050949350505050565b60608686868686866040516024016116b196959493929190611c8a565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fd764ad0b0000000000000000000000000000000000000000000000000000000017905290509695505050505050565b73ffffffffffffffffffffffffffffffffffffffff8116811461175557600080fd5b50565b60008083601f84011261176a57600080fd5b50813567ffffffffffffffff81111561178257600080fd5b60208301915083602082850101111561179a57600080fd5b9250929050565b803563ffffffff811681146117b557600080fd5b919050565b600080600080606085870312156117d057600080fd5b84356117db81611733565b9350602085013567ffffffffffffffff8111156117f757600080fd5b61180387828801611758565b90945092506118169050604086016117a1565b905092959194509250565b6000815180845260005b818110156118475760208185018101518683018201520161182b565b81811115611859576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60208152600061189f6020830184611821565b9392505050565b6000602082840312156118b857600080fd5b5035919050565b6000806000604084860312156118d457600080fd5b833567ffffffffffffffff8111156118eb57600080fd5b6118f786828701611758565b909450925061190a9050602085016117a1565b90509250925092565b60006020828403121561192557600080fd5b813561189f81611733565b600080600080600080600060c0888a03121561194b57600080fd5b87359650602088013561195d81611733565b9550604088013561196d81611733565b9450606088013593506080880135925060a088013567ffffffffffffffff81111561199757600080fd5b6119a38a828b01611758565b989b979a50959850939692959293505050565b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b878152600073ffffffffffffffffffffffffffffffffffffffff808916602084015280881660408401525085606083015263ffffffff8516608083015260c060a0830152611a5160c0830184866119b6565b9998505050505050505050565b73ffffffffffffffffffffffffffffffffffffffff86168152608060208201526000611a8e6080830186886119b6565b905083604083015263ffffffff831660608301529695505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600067ffffffffffffffff80831681851681830481118215151615611b0257611b02611aac565b02949350505050565b600067ffffffffffffffff80841680611b4d577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b92169190910492915050565b600067ffffffffffffffff808316818516808303821115611b7c57611b7c611aac565b01949350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052600160045260246000fd5b600082821015611bc657611bc6611aac565b500390565b73ffffffffffffffffffffffffffffffffffffffff8616815284602082015267ffffffffffffffff84166040820152821515606082015260a060808201526000611c1860a0830184611821565b979650505050505050565b600060208284031215611c3557600080fd5b815161189f81611733565b600073ffffffffffffffffffffffffffffffffffffffff808716835280861660208401525060806040830152611c796080830185611821565b905082606083015295945050505050565b868152600073ffffffffffffffffffffffffffffffffffffffff808816602084015280871660408401525084606083015283608083015260c060a0830152611cd560c0830184611821565b9897505050505050505056fea164736f6c634300080f000a" +var L1CrossDomainMessengerDeployedBin = "0x60806040526004361061015f5760003560e01c80636e296e45116100c0578063b1b1b20911610074578063c4d66de811610059578063c4d66de8146103ed578063d764ad0b1461040d578063ecc704281461042057600080fd5b8063b1b1b2091461039d578063b28ade25146103cd57600080fd5b80638cbeeef2116100a55780638cbeeef2146102505780639fce812c14610329578063a4e7f8bd1461035d57600080fd5b80636e296e45146102fd57806383a740741461031257600080fd5b80633f827a5a1161011757806354fd4d50116100fc57806354fd4d50146102665780635644cfdf146102bc5780636425666b146102d257600080fd5b80633f827a5a146102285780634c1d6a691461025057600080fd5b80630ff754ea116101485780630ff754ea146101ac5780632828d7e8146101fe5780633dbb202b1461021357600080fd5b8063028f85f7146101645780630c56849814610197575b600080fd5b34801561017057600080fd5b50610179601081565b60405167ffffffffffffffff90911681526020015b60405180910390f35b3480156101a357600080fd5b50610179603f81565b3480156101b857600080fd5b5060f9546101d99073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161018e565b34801561020a57600080fd5b50610179604081565b6102266102213660046117ba565b610485565b005b34801561023457600080fd5b5061023d600181565b60405161ffff909116815260200161018e565b34801561025c57600080fd5b50610179619c4081565b34801561027257600080fd5b506102af6040518060400160405280600581526020017f312e372e3100000000000000000000000000000000000000000000000000000081525081565b60405161018e919061188c565b3480156102c857600080fd5b5061017961138881565b3480156102de57600080fd5b5060f95473ffffffffffffffffffffffffffffffffffffffff166101d9565b34801561030957600080fd5b506101d96106e9565b34801561031e57600080fd5b5061017962030d4081565b34801561033557600080fd5b506101d97f000000000000000000000000000000000000000000000000000000000000000081565b34801561036957600080fd5b5061038d6103783660046118a6565b60ce6020526000908152604090205460ff1681565b604051901515815260200161018e565b3480156103a957600080fd5b5061038d6103b83660046118a6565b60cb6020526000908152604090205460ff1681565b3480156103d957600080fd5b506101796103e83660046118bf565b6107d5565b3480156103f957600080fd5b50610226610408366004611913565b610843565b61022661041b366004611930565b610a47565b34801561042c57600080fd5b5061047760cd547dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e010000000000000000000000000000000000000000000000000000000000001790565b60405190815260200161018e565b6105be7f00000000000000000000000000000000000000000000000000000000000000006104b48585856107d5565b347fd764ad0b0000000000000000000000000000000000000000000000000000000061052060cd547dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e010000000000000000000000000000000000000000000000000000000000001790565b338a34898c8c60405160240161053c97969594939291906119ff565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff00000000000000000000000000000000000000000000000000000000909316929092179091526112d3565b8373ffffffffffffffffffffffffffffffffffffffff167fcb0f7ffd78f9aee47a248fae8db181db6eee833039123e026dcbff529522e52a33858561064360cd547dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e010000000000000000000000000000000000000000000000000000000000001790565b86604051610655959493929190611a5e565b60405180910390a260405134815233907f8ebb2ec2465bdb2a06a66fc37a0963af8a2a6a1479d81d56fdb8cbb98096d5469060200160405180910390a2505060cd80547dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff808216600101167fffff0000000000000000000000000000000000000000000000000000000000009091161790555050565b60cc5460009073ffffffffffffffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff2153016107b8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603560248201527f43726f7373446f6d61696e4d657373656e6765723a2078446f6d61696e4d657360448201527f7361676553656e646572206973206e6f7420736574000000000000000000000060648201526084015b60405180910390fd5b5060cc5473ffffffffffffffffffffffffffffffffffffffff1690565b6000611388619c4080603f6107f1604063ffffffff8816611adb565b6107fb9190611b0b565b610806601088611adb565b6108139062030d40611b59565b61081d9190611b59565b6108279190611b59565b6108319190611b59565b61083b9190611b59565b949350505050565b6000546003907501000000000000000000000000000000000000000000900460ff16158015610891575060005460ff8083167401000000000000000000000000000000000000000090920416105b61091d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a656400000000000000000000000000000000000060648201526084016107af565b6000805475010000000000000000000000000000000000000000007fffffffffffffffffffff0000ffffffffffffffffffffffffffffffffffffffff9091167401000000000000000000000000000000000000000060ff8516027fffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff161717905560f980547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff84161790556109e561136c565b600080547fffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff16905560405160ff821681527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050565b60f087901c60028110610b02576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604d60248201527f43726f7373446f6d61696e4d657373656e6765723a206f6e6c7920766572736960448201527f6f6e2030206f722031206d657373616765732061726520737570706f7274656460648201527f20617420746869732074696d6500000000000000000000000000000000000000608482015260a4016107af565b8061ffff16600003610bf7576000610b53878986868080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508f9250611445915050565b600081815260cb602052604090205490915060ff1615610bf5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f43726f7373446f6d61696e4d657373656e6765723a206c65676163792077697460448201527f6864726177616c20616c72656164792072656c6179656400000000000000000060648201526084016107af565b505b6000610c3d898989898989898080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061146492505050565b9050610c47611487565b15610c7f57853414610c5b57610c5b611b85565b600081815260ce602052604090205460ff1615610c7a57610c7a611b85565b610dd1565b3415610d33576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152605060248201527f43726f7373446f6d61696e4d657373656e6765723a2076616c7565206d75737460448201527f206265207a65726f20756e6c657373206d6573736167652069732066726f6d2060648201527f612073797374656d206164647265737300000000000000000000000000000000608482015260a4016107af565b600081815260ce602052604090205460ff16610dd1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603060248201527f43726f7373446f6d61696e4d657373656e6765723a206d65737361676520636160448201527f6e6e6f74206265207265706c617965640000000000000000000000000000000060648201526084016107af565b610dda8761157d565b15610e8d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604360248201527f43726f7373446f6d61696e4d657373656e6765723a2063616e6e6f742073656e60448201527f64206d65737361676520746f20626c6f636b65642073797374656d206164647260648201527f6573730000000000000000000000000000000000000000000000000000000000608482015260a4016107af565b600081815260cb602052604090205460ff1615610f2c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603660248201527f43726f7373446f6d61696e4d657373656e6765723a206d65737361676520686160448201527f7320616c7265616479206265656e2072656c617965640000000000000000000060648201526084016107af565b610f4d85610f3e611388619c40611b59565b67ffffffffffffffff166115c3565b1580610f73575060cc5473ffffffffffffffffffffffffffffffffffffffff1661dead14155b1561108c57600081815260ce602052604080822080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790555182917f99d0e048484baa1b1540b1367cb128acd7ab2946d1ed91ec10e3c85e4bf51b8f91a27fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff3201611085576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602d60248201527f43726f7373446f6d61696e4d657373656e6765723a206661696c656420746f2060448201527f72656c6179206d6573736167650000000000000000000000000000000000000060648201526084016107af565b50506112c5565b60cc80547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff8a16179055600061111d88619c405a6110e09190611bb4565b8988888080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506115e192505050565b60cc80547fffffffffffffffffffffffff00000000000000000000000000000000000000001661dead179055905080156111b457600082815260cb602052604080822080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790555183917f4641df4a962071e12719d8c8c8e5ac7fc4d97b927346a3d7a335b1f7517e133c91a26112c1565b600082815260ce602052604080822080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790555183917f99d0e048484baa1b1540b1367cb128acd7ab2946d1ed91ec10e3c85e4bf51b8f91a27fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff32016112c1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602d60248201527f43726f7373446f6d61696e4d657373656e6765723a206661696c656420746f2060448201527f72656c6179206d6573736167650000000000000000000000000000000000000060648201526084016107af565b5050505b50505050505050565b905090565b60f9546040517fe9e05c4200000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff9091169063e9e05c42908490611334908890839089906000908990600401611bcb565b6000604051808303818588803b15801561134d57600080fd5b505af1158015611361573d6000803e3d6000fd5b505050505050505050565b6000547501000000000000000000000000000000000000000000900460ff16611417576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e6700000000000000000000000000000000000000000060648201526084016107af565b60cc80547fffffffffffffffffffffffff00000000000000000000000000000000000000001661dead179055565b6000611453858585856115fb565b805190602001209050949350505050565b6000611474878787878787611694565b8051906020012090509695505050505050565b60f95460009073ffffffffffffffffffffffffffffffffffffffff16331480156112ce575060f954604080517f9bf62d82000000000000000000000000000000000000000000000000000000008152905173ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000008116931691639bf62d829160048083019260209291908290030181865afa15801561153d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906115619190611c23565b73ffffffffffffffffffffffffffffffffffffffff1614905090565b600073ffffffffffffffffffffffffffffffffffffffff82163014806115bd575060f95473ffffffffffffffffffffffffffffffffffffffff8381169116145b92915050565b600080603f83619c4001026040850201603f5a021015949350505050565b600080600080845160208601878a8af19695505050505050565b6060848484846040516024016116149493929190611c40565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fcbd4ece9000000000000000000000000000000000000000000000000000000001790529050949350505050565b60608686868686866040516024016116b196959493929190611c8a565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fd764ad0b0000000000000000000000000000000000000000000000000000000017905290509695505050505050565b73ffffffffffffffffffffffffffffffffffffffff8116811461175557600080fd5b50565b60008083601f84011261176a57600080fd5b50813567ffffffffffffffff81111561178257600080fd5b60208301915083602082850101111561179a57600080fd5b9250929050565b803563ffffffff811681146117b557600080fd5b919050565b600080600080606085870312156117d057600080fd5b84356117db81611733565b9350602085013567ffffffffffffffff8111156117f757600080fd5b61180387828801611758565b90945092506118169050604086016117a1565b905092959194509250565b6000815180845260005b818110156118475760208185018101518683018201520161182b565b81811115611859576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60208152600061189f6020830184611821565b9392505050565b6000602082840312156118b857600080fd5b5035919050565b6000806000604084860312156118d457600080fd5b833567ffffffffffffffff8111156118eb57600080fd5b6118f786828701611758565b909450925061190a9050602085016117a1565b90509250925092565b60006020828403121561192557600080fd5b813561189f81611733565b600080600080600080600060c0888a03121561194b57600080fd5b87359650602088013561195d81611733565b9550604088013561196d81611733565b9450606088013593506080880135925060a088013567ffffffffffffffff81111561199757600080fd5b6119a38a828b01611758565b989b979a50959850939692959293505050565b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b878152600073ffffffffffffffffffffffffffffffffffffffff808916602084015280881660408401525085606083015263ffffffff8516608083015260c060a0830152611a5160c0830184866119b6565b9998505050505050505050565b73ffffffffffffffffffffffffffffffffffffffff86168152608060208201526000611a8e6080830186886119b6565b905083604083015263ffffffff831660608301529695505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600067ffffffffffffffff80831681851681830481118215151615611b0257611b02611aac565b02949350505050565b600067ffffffffffffffff80841680611b4d577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b92169190910492915050565b600067ffffffffffffffff808316818516808303821115611b7c57611b7c611aac565b01949350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052600160045260246000fd5b600082821015611bc657611bc6611aac565b500390565b73ffffffffffffffffffffffffffffffffffffffff8616815284602082015267ffffffffffffffff84166040820152821515606082015260a060808201526000611c1860a0830184611821565b979650505050505050565b600060208284031215611c3557600080fd5b815161189f81611733565b600073ffffffffffffffffffffffffffffffffffffffff808716835280861660208401525060806040830152611c796080830185611821565b905082606083015295945050505050565b868152600073ffffffffffffffffffffffffffffffffffffffff808816602084015280871660408401525084606083015283608083015260c060a0830152611cd560c0830184611821565b9897505050505050505056fea164736f6c634300080f000a" func init() { if err := json.Unmarshal([]byte(L1CrossDomainMessengerStorageLayoutJSON), L1CrossDomainMessengerStorageLayout); err != nil { diff --git a/op-bindings/bindings/l1erc721bridge.go b/op-bindings/bindings/l1erc721bridge.go index f2431a632fc15..ad0349dbd1d50 100644 --- a/op-bindings/bindings/l1erc721bridge.go +++ b/op-bindings/bindings/l1erc721bridge.go @@ -31,7 +31,7 @@ var ( // L1ERC721BridgeMetaData contains all meta data concerning the L1ERC721Bridge contract. var L1ERC721BridgeMetaData = &bind.MetaData{ ABI: "[{\"inputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"localToken\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"remoteToken\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"tokenId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"ERC721BridgeFinalized\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"localToken\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"remoteToken\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"tokenId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"ERC721BridgeInitiated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"version\",\"type\":\"uint8\"}],\"name\":\"Initialized\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MESSENGER\",\"outputs\":[{\"internalType\":\"contractCrossDomainMessenger\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"OTHER_BRIDGE\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_localToken\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_remoteToken\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_tokenId\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"_minGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"_extraData\",\"type\":\"bytes\"}],\"name\":\"bridgeERC721\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_localToken\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_remoteToken\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_tokenId\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"_minGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"_extraData\",\"type\":\"bytes\"}],\"name\":\"bridgeERC721To\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"deposits\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_localToken\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_remoteToken\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_tokenId\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"_extraData\",\"type\":\"bytes\"}],\"name\":\"finalizeBridgeERC721\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"contractCrossDomainMessenger\",\"name\":\"_messenger\",\"type\":\"address\"}],\"name\":\"initialize\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"messenger\",\"outputs\":[{\"internalType\":\"contractCrossDomainMessenger\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"otherBridge\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"version\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", - Bin: "0x60a060405234801561001057600080fd5b50734200000000000000000000000000000000000014610034565b60405180910390fd5b6001600160a01b031660805261004a600061004f565b6101cb565b600054600390610100900460ff16158015610071575060005460ff8083169116105b6100d45760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b606482015260840161002b565b6000805461ffff191660ff8316176101001790556100f182610136565b6000805461ff001916905560405160ff821681527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050565b600054610100900460ff166101a15760405162461bcd60e51b815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201526a6e697469616c697a696e6760a81b606482015260840161002b565b600080546001600160a01b03909216620100000262010000600160b01b0319909216919091179055565b6080516112116101fb600039600081816101cd0152818161023b015281816103350152610bf101526112116000f3fe608060405234801561001057600080fd5b50600436106100be5760003560e01c80637f46ddb211610076578063aa5574521161005b578063aa55745214610213578063c4d66de814610226578063c89701a21461023957600080fd5b80637f46ddb2146101c8578063927ede2d146101ef57600080fd5b806354fd4d50116100a757806354fd4d50146101285780635d93a3fc14610171578063761f4493146101b557600080fd5b80633687011a146100c35780633cb747bf146100d8575b600080fd5b6100d66100d1366004610e47565b61025f565b005b6000546100fe9062010000900473ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b6101646040518060400160405280600581526020017f312e342e3000000000000000000000000000000000000000000000000000000081525081565b60405161011f9190610f35565b6101a561017f366004610f4f565b603160209081526000938452604080852082529284528284209052825290205460ff1681565b604051901515815260200161011f565b6100d66101c3366004610f90565b61030b565b6100fe7f000000000000000000000000000000000000000000000000000000000000000081565b60005462010000900473ffffffffffffffffffffffffffffffffffffffff166100fe565b6100d6610221366004611028565b610776565b6100d661023436600461109f565b610832565b7f00000000000000000000000000000000000000000000000000000000000000006100fe565b333b156102f3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602d60248201527f4552433732314272696467653a206163636f756e74206973206e6f742065787460448201527f65726e616c6c79206f776e65640000000000000000000000000000000000000060648201526084015b60405180910390fd5b610303868633338888888861097c565b505050505050565b60005462010000900473ffffffffffffffffffffffffffffffffffffffff163314801561041357507f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16600060029054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16636e296e456040518163ffffffff1660e01b8152600401602060405180830381865afa1580156103d7573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906103fb91906110bc565b73ffffffffffffffffffffffffffffffffffffffff16145b61049f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603f60248201527f4552433732314272696467653a2066756e6374696f6e2063616e206f6e6c792060448201527f62652063616c6c65642066726f6d20746865206f74686572206272696467650060648201526084016102ea565b3073ffffffffffffffffffffffffffffffffffffffff881603610544576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602a60248201527f4c314552433732314272696467653a206c6f63616c20746f6b656e2063616e6e60448201527f6f742062652073656c660000000000000000000000000000000000000000000060648201526084016102ea565b73ffffffffffffffffffffffffffffffffffffffff8088166000908152603160209081526040808320938a1683529281528282208683529052205460ff161515600114610613576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603960248201527f4c314552433732314272696467653a20546f6b656e204944206973206e6f742060448201527f657363726f77656420696e20746865204c31204272696467650000000000000060648201526084016102ea565b73ffffffffffffffffffffffffffffffffffffffff87811660008181526031602090815260408083208b8616845282528083208884529091529081902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00169055517f42842e0e000000000000000000000000000000000000000000000000000000008152306004820152918616602483015260448201859052906342842e0e90606401600060405180830381600087803b1580156106d357600080fd5b505af11580156106e7573d6000803e3d6000fd5b505050508473ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff168873ffffffffffffffffffffffffffffffffffffffff167f1f39bf6707b5d608453e0ae4c067b562bcc4c85c0f562ef5d2c774d2e7f131ac878787876040516107659493929190611122565b60405180910390a450505050505050565b73ffffffffffffffffffffffffffffffffffffffff8516610819576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603060248201527f4552433732314272696467653a206e667420726563697069656e742063616e6e60448201527f6f7420626520616464726573732830290000000000000000000000000000000060648201526084016102ea565b610829878733888888888861097c565b50505050505050565b600054600390610100900460ff16158015610854575060005460ff8083169116105b6108e0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a656400000000000000000000000000000000000060648201526084016102ea565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001660ff83161761010017905561091a82610cdc565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff16905560405160ff821681527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050565b73ffffffffffffffffffffffffffffffffffffffff8716610a1f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603160248201527f4c314552433732314272696467653a2072656d6f746520746f6b656e2063616e60448201527f6e6f74206265206164647265737328302900000000000000000000000000000060648201526084016102ea565b600063761f449360e01b888a8989898888604051602401610a469796959493929190611162565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152602080830180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff00000000000000000000000000000000000000000000000000000000959095169490941790935273ffffffffffffffffffffffffffffffffffffffff8c81166000818152603186528381208e8416825286528381208b82529095529382902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600117905590517f23b872dd000000000000000000000000000000000000000000000000000000008152908a166004820152306024820152604481018890529092506323b872dd90606401600060405180830381600087803b158015610b8657600080fd5b505af1158015610b9a573d6000803e3d6000fd5b50506000546040517f3dbb202b0000000000000000000000000000000000000000000000000000000081526201000090910473ffffffffffffffffffffffffffffffffffffffff169250633dbb202b9150610c1d907f000000000000000000000000000000000000000000000000000000000000000090859089906004016111bf565b600060405180830381600087803b158015610c3757600080fd5b505af1158015610c4b573d6000803e3d6000fd5b505050508673ffffffffffffffffffffffffffffffffffffffff168873ffffffffffffffffffffffffffffffffffffffff168a73ffffffffffffffffffffffffffffffffffffffff167fb7460e2a880f256ebef3406116ff3eee0cee51ebccdc2a40698f87ebb2e9c1a589898888604051610cc99493929190611122565b60405180910390a4505050505050505050565b600054610100900460ff16610d73576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e6700000000000000000000000000000000000000000060648201526084016102ea565b6000805473ffffffffffffffffffffffffffffffffffffffff90921662010000027fffffffffffffffffffff0000000000000000000000000000000000000000ffff909216919091179055565b73ffffffffffffffffffffffffffffffffffffffff81168114610de257600080fd5b50565b803563ffffffff81168114610df957600080fd5b919050565b60008083601f840112610e1057600080fd5b50813567ffffffffffffffff811115610e2857600080fd5b602083019150836020828501011115610e4057600080fd5b9250929050565b60008060008060008060a08789031215610e6057600080fd5b8635610e6b81610dc0565b95506020870135610e7b81610dc0565b945060408701359350610e9060608801610de5565b9250608087013567ffffffffffffffff811115610eac57600080fd5b610eb889828a01610dfe565b979a9699509497509295939492505050565b6000815180845260005b81811015610ef057602081850181015186830182015201610ed4565b81811115610f02576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b602081526000610f486020830184610eca565b9392505050565b600080600060608486031215610f6457600080fd5b8335610f6f81610dc0565b92506020840135610f7f81610dc0565b929592945050506040919091013590565b600080600080600080600060c0888a031215610fab57600080fd5b8735610fb681610dc0565b96506020880135610fc681610dc0565b95506040880135610fd681610dc0565b94506060880135610fe681610dc0565b93506080880135925060a088013567ffffffffffffffff81111561100957600080fd5b6110158a828b01610dfe565b989b979a50959850939692959293505050565b600080600080600080600060c0888a03121561104357600080fd5b873561104e81610dc0565b9650602088013561105e81610dc0565b9550604088013561106e81610dc0565b94506060880135935061108360808901610de5565b925060a088013567ffffffffffffffff81111561100957600080fd5b6000602082840312156110b157600080fd5b8135610f4881610dc0565b6000602082840312156110ce57600080fd5b8151610f4881610dc0565b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b73ffffffffffffffffffffffffffffffffffffffff851681528360208201526060604082015260006111586060830184866110d9565b9695505050505050565b600073ffffffffffffffffffffffffffffffffffffffff808a1683528089166020840152808816604084015280871660608401525084608083015260c060a08301526111b260c0830184866110d9565b9998505050505050505050565b73ffffffffffffffffffffffffffffffffffffffff841681526060602082015260006111ee6060830185610eca565b905063ffffffff8316604083015294935050505056fea164736f6c634300080f000a", + Bin: "0x60a060405234801561001057600080fd5b50734200000000000000000000000000000000000014610034565b60405180910390fd5b6001600160a01b031660805261004a600061004f565b6101cb565b600054600390610100900460ff16158015610071575060005460ff8083169116105b6100d45760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b606482015260840161002b565b6000805461ffff191660ff8316176101001790556100f182610136565b6000805461ff001916905560405160ff821681527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050565b600054610100900460ff166101a15760405162461bcd60e51b815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201526a6e697469616c697a696e6760a81b606482015260840161002b565b600080546001600160a01b03909216620100000262010000600160b01b0319909216919091179055565b6080516112116101fb600039600081816101cd0152818161023b015281816103350152610bf101526112116000f3fe608060405234801561001057600080fd5b50600436106100be5760003560e01c80637f46ddb211610076578063aa5574521161005b578063aa55745214610213578063c4d66de814610226578063c89701a21461023957600080fd5b80637f46ddb2146101c8578063927ede2d146101ef57600080fd5b806354fd4d50116100a757806354fd4d50146101285780635d93a3fc14610171578063761f4493146101b557600080fd5b80633687011a146100c35780633cb747bf146100d8575b600080fd5b6100d66100d1366004610e47565b61025f565b005b6000546100fe9062010000900473ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b6101646040518060400160405280600581526020017f312e342e3100000000000000000000000000000000000000000000000000000081525081565b60405161011f9190610f35565b6101a561017f366004610f4f565b603160209081526000938452604080852082529284528284209052825290205460ff1681565b604051901515815260200161011f565b6100d66101c3366004610f90565b61030b565b6100fe7f000000000000000000000000000000000000000000000000000000000000000081565b60005462010000900473ffffffffffffffffffffffffffffffffffffffff166100fe565b6100d6610221366004611028565b610776565b6100d661023436600461109f565b610832565b7f00000000000000000000000000000000000000000000000000000000000000006100fe565b333b156102f3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602d60248201527f4552433732314272696467653a206163636f756e74206973206e6f742065787460448201527f65726e616c6c79206f776e65640000000000000000000000000000000000000060648201526084015b60405180910390fd5b610303868633338888888861097c565b505050505050565b60005462010000900473ffffffffffffffffffffffffffffffffffffffff163314801561041357507f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16600060029054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16636e296e456040518163ffffffff1660e01b8152600401602060405180830381865afa1580156103d7573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906103fb91906110bc565b73ffffffffffffffffffffffffffffffffffffffff16145b61049f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603f60248201527f4552433732314272696467653a2066756e6374696f6e2063616e206f6e6c792060448201527f62652063616c6c65642066726f6d20746865206f74686572206272696467650060648201526084016102ea565b3073ffffffffffffffffffffffffffffffffffffffff881603610544576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602a60248201527f4c314552433732314272696467653a206c6f63616c20746f6b656e2063616e6e60448201527f6f742062652073656c660000000000000000000000000000000000000000000060648201526084016102ea565b73ffffffffffffffffffffffffffffffffffffffff8088166000908152603160209081526040808320938a1683529281528282208683529052205460ff161515600114610613576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603960248201527f4c314552433732314272696467653a20546f6b656e204944206973206e6f742060448201527f657363726f77656420696e20746865204c31204272696467650000000000000060648201526084016102ea565b73ffffffffffffffffffffffffffffffffffffffff87811660008181526031602090815260408083208b8616845282528083208884529091529081902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00169055517f42842e0e000000000000000000000000000000000000000000000000000000008152306004820152918616602483015260448201859052906342842e0e90606401600060405180830381600087803b1580156106d357600080fd5b505af11580156106e7573d6000803e3d6000fd5b505050508473ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff168873ffffffffffffffffffffffffffffffffffffffff167f1f39bf6707b5d608453e0ae4c067b562bcc4c85c0f562ef5d2c774d2e7f131ac878787876040516107659493929190611122565b60405180910390a450505050505050565b73ffffffffffffffffffffffffffffffffffffffff8516610819576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603060248201527f4552433732314272696467653a206e667420726563697069656e742063616e6e60448201527f6f7420626520616464726573732830290000000000000000000000000000000060648201526084016102ea565b610829878733888888888861097c565b50505050505050565b600054600390610100900460ff16158015610854575060005460ff8083169116105b6108e0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a656400000000000000000000000000000000000060648201526084016102ea565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001660ff83161761010017905561091a82610cdc565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff16905560405160ff821681527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050565b73ffffffffffffffffffffffffffffffffffffffff8716610a1f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603160248201527f4c314552433732314272696467653a2072656d6f746520746f6b656e2063616e60448201527f6e6f74206265206164647265737328302900000000000000000000000000000060648201526084016102ea565b600063761f449360e01b888a8989898888604051602401610a469796959493929190611162565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152602080830180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff00000000000000000000000000000000000000000000000000000000959095169490941790935273ffffffffffffffffffffffffffffffffffffffff8c81166000818152603186528381208e8416825286528381208b82529095529382902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600117905590517f23b872dd000000000000000000000000000000000000000000000000000000008152908a166004820152306024820152604481018890529092506323b872dd90606401600060405180830381600087803b158015610b8657600080fd5b505af1158015610b9a573d6000803e3d6000fd5b50506000546040517f3dbb202b0000000000000000000000000000000000000000000000000000000081526201000090910473ffffffffffffffffffffffffffffffffffffffff169250633dbb202b9150610c1d907f000000000000000000000000000000000000000000000000000000000000000090859089906004016111bf565b600060405180830381600087803b158015610c3757600080fd5b505af1158015610c4b573d6000803e3d6000fd5b505050508673ffffffffffffffffffffffffffffffffffffffff168873ffffffffffffffffffffffffffffffffffffffff168a73ffffffffffffffffffffffffffffffffffffffff167fb7460e2a880f256ebef3406116ff3eee0cee51ebccdc2a40698f87ebb2e9c1a589898888604051610cc99493929190611122565b60405180910390a4505050505050505050565b600054610100900460ff16610d73576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e6700000000000000000000000000000000000000000060648201526084016102ea565b6000805473ffffffffffffffffffffffffffffffffffffffff90921662010000027fffffffffffffffffffff0000000000000000000000000000000000000000ffff909216919091179055565b73ffffffffffffffffffffffffffffffffffffffff81168114610de257600080fd5b50565b803563ffffffff81168114610df957600080fd5b919050565b60008083601f840112610e1057600080fd5b50813567ffffffffffffffff811115610e2857600080fd5b602083019150836020828501011115610e4057600080fd5b9250929050565b60008060008060008060a08789031215610e6057600080fd5b8635610e6b81610dc0565b95506020870135610e7b81610dc0565b945060408701359350610e9060608801610de5565b9250608087013567ffffffffffffffff811115610eac57600080fd5b610eb889828a01610dfe565b979a9699509497509295939492505050565b6000815180845260005b81811015610ef057602081850181015186830182015201610ed4565b81811115610f02576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b602081526000610f486020830184610eca565b9392505050565b600080600060608486031215610f6457600080fd5b8335610f6f81610dc0565b92506020840135610f7f81610dc0565b929592945050506040919091013590565b600080600080600080600060c0888a031215610fab57600080fd5b8735610fb681610dc0565b96506020880135610fc681610dc0565b95506040880135610fd681610dc0565b94506060880135610fe681610dc0565b93506080880135925060a088013567ffffffffffffffff81111561100957600080fd5b6110158a828b01610dfe565b989b979a50959850939692959293505050565b600080600080600080600060c0888a03121561104357600080fd5b873561104e81610dc0565b9650602088013561105e81610dc0565b9550604088013561106e81610dc0565b94506060880135935061108360808901610de5565b925060a088013567ffffffffffffffff81111561100957600080fd5b6000602082840312156110b157600080fd5b8135610f4881610dc0565b6000602082840312156110ce57600080fd5b8151610f4881610dc0565b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b73ffffffffffffffffffffffffffffffffffffffff851681528360208201526060604082015260006111586060830184866110d9565b9695505050505050565b600073ffffffffffffffffffffffffffffffffffffffff808a1683528089166020840152808816604084015280871660608401525084608083015260c060a08301526111b260c0830184866110d9565b9998505050505050505050565b73ffffffffffffffffffffffffffffffffffffffff841681526060602082015260006111ee6060830185610eca565b905063ffffffff8316604083015294935050505056fea164736f6c634300080f000a", } // L1ERC721BridgeABI is the input ABI used to generate the binding from. diff --git a/op-bindings/bindings/l1erc721bridge_more.go b/op-bindings/bindings/l1erc721bridge_more.go index 2f1bb34be50bf..eac99b59ec12e 100644 --- a/op-bindings/bindings/l1erc721bridge_more.go +++ b/op-bindings/bindings/l1erc721bridge_more.go @@ -13,7 +13,7 @@ const L1ERC721BridgeStorageLayoutJSON = "{\"storage\":[{\"astId\":1000,\"contrac var L1ERC721BridgeStorageLayout = new(solc.StorageLayout) -var L1ERC721BridgeDeployedBin = "0x608060405234801561001057600080fd5b50600436106100be5760003560e01c80637f46ddb211610076578063aa5574521161005b578063aa55745214610213578063c4d66de814610226578063c89701a21461023957600080fd5b80637f46ddb2146101c8578063927ede2d146101ef57600080fd5b806354fd4d50116100a757806354fd4d50146101285780635d93a3fc14610171578063761f4493146101b557600080fd5b80633687011a146100c35780633cb747bf146100d8575b600080fd5b6100d66100d1366004610e47565b61025f565b005b6000546100fe9062010000900473ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b6101646040518060400160405280600581526020017f312e342e3000000000000000000000000000000000000000000000000000000081525081565b60405161011f9190610f35565b6101a561017f366004610f4f565b603160209081526000938452604080852082529284528284209052825290205460ff1681565b604051901515815260200161011f565b6100d66101c3366004610f90565b61030b565b6100fe7f000000000000000000000000000000000000000000000000000000000000000081565b60005462010000900473ffffffffffffffffffffffffffffffffffffffff166100fe565b6100d6610221366004611028565b610776565b6100d661023436600461109f565b610832565b7f00000000000000000000000000000000000000000000000000000000000000006100fe565b333b156102f3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602d60248201527f4552433732314272696467653a206163636f756e74206973206e6f742065787460448201527f65726e616c6c79206f776e65640000000000000000000000000000000000000060648201526084015b60405180910390fd5b610303868633338888888861097c565b505050505050565b60005462010000900473ffffffffffffffffffffffffffffffffffffffff163314801561041357507f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16600060029054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16636e296e456040518163ffffffff1660e01b8152600401602060405180830381865afa1580156103d7573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906103fb91906110bc565b73ffffffffffffffffffffffffffffffffffffffff16145b61049f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603f60248201527f4552433732314272696467653a2066756e6374696f6e2063616e206f6e6c792060448201527f62652063616c6c65642066726f6d20746865206f74686572206272696467650060648201526084016102ea565b3073ffffffffffffffffffffffffffffffffffffffff881603610544576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602a60248201527f4c314552433732314272696467653a206c6f63616c20746f6b656e2063616e6e60448201527f6f742062652073656c660000000000000000000000000000000000000000000060648201526084016102ea565b73ffffffffffffffffffffffffffffffffffffffff8088166000908152603160209081526040808320938a1683529281528282208683529052205460ff161515600114610613576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603960248201527f4c314552433732314272696467653a20546f6b656e204944206973206e6f742060448201527f657363726f77656420696e20746865204c31204272696467650000000000000060648201526084016102ea565b73ffffffffffffffffffffffffffffffffffffffff87811660008181526031602090815260408083208b8616845282528083208884529091529081902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00169055517f42842e0e000000000000000000000000000000000000000000000000000000008152306004820152918616602483015260448201859052906342842e0e90606401600060405180830381600087803b1580156106d357600080fd5b505af11580156106e7573d6000803e3d6000fd5b505050508473ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff168873ffffffffffffffffffffffffffffffffffffffff167f1f39bf6707b5d608453e0ae4c067b562bcc4c85c0f562ef5d2c774d2e7f131ac878787876040516107659493929190611122565b60405180910390a450505050505050565b73ffffffffffffffffffffffffffffffffffffffff8516610819576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603060248201527f4552433732314272696467653a206e667420726563697069656e742063616e6e60448201527f6f7420626520616464726573732830290000000000000000000000000000000060648201526084016102ea565b610829878733888888888861097c565b50505050505050565b600054600390610100900460ff16158015610854575060005460ff8083169116105b6108e0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a656400000000000000000000000000000000000060648201526084016102ea565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001660ff83161761010017905561091a82610cdc565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff16905560405160ff821681527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050565b73ffffffffffffffffffffffffffffffffffffffff8716610a1f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603160248201527f4c314552433732314272696467653a2072656d6f746520746f6b656e2063616e60448201527f6e6f74206265206164647265737328302900000000000000000000000000000060648201526084016102ea565b600063761f449360e01b888a8989898888604051602401610a469796959493929190611162565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152602080830180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff00000000000000000000000000000000000000000000000000000000959095169490941790935273ffffffffffffffffffffffffffffffffffffffff8c81166000818152603186528381208e8416825286528381208b82529095529382902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600117905590517f23b872dd000000000000000000000000000000000000000000000000000000008152908a166004820152306024820152604481018890529092506323b872dd90606401600060405180830381600087803b158015610b8657600080fd5b505af1158015610b9a573d6000803e3d6000fd5b50506000546040517f3dbb202b0000000000000000000000000000000000000000000000000000000081526201000090910473ffffffffffffffffffffffffffffffffffffffff169250633dbb202b9150610c1d907f000000000000000000000000000000000000000000000000000000000000000090859089906004016111bf565b600060405180830381600087803b158015610c3757600080fd5b505af1158015610c4b573d6000803e3d6000fd5b505050508673ffffffffffffffffffffffffffffffffffffffff168873ffffffffffffffffffffffffffffffffffffffff168a73ffffffffffffffffffffffffffffffffffffffff167fb7460e2a880f256ebef3406116ff3eee0cee51ebccdc2a40698f87ebb2e9c1a589898888604051610cc99493929190611122565b60405180910390a4505050505050505050565b600054610100900460ff16610d73576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e6700000000000000000000000000000000000000000060648201526084016102ea565b6000805473ffffffffffffffffffffffffffffffffffffffff90921662010000027fffffffffffffffffffff0000000000000000000000000000000000000000ffff909216919091179055565b73ffffffffffffffffffffffffffffffffffffffff81168114610de257600080fd5b50565b803563ffffffff81168114610df957600080fd5b919050565b60008083601f840112610e1057600080fd5b50813567ffffffffffffffff811115610e2857600080fd5b602083019150836020828501011115610e4057600080fd5b9250929050565b60008060008060008060a08789031215610e6057600080fd5b8635610e6b81610dc0565b95506020870135610e7b81610dc0565b945060408701359350610e9060608801610de5565b9250608087013567ffffffffffffffff811115610eac57600080fd5b610eb889828a01610dfe565b979a9699509497509295939492505050565b6000815180845260005b81811015610ef057602081850181015186830182015201610ed4565b81811115610f02576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b602081526000610f486020830184610eca565b9392505050565b600080600060608486031215610f6457600080fd5b8335610f6f81610dc0565b92506020840135610f7f81610dc0565b929592945050506040919091013590565b600080600080600080600060c0888a031215610fab57600080fd5b8735610fb681610dc0565b96506020880135610fc681610dc0565b95506040880135610fd681610dc0565b94506060880135610fe681610dc0565b93506080880135925060a088013567ffffffffffffffff81111561100957600080fd5b6110158a828b01610dfe565b989b979a50959850939692959293505050565b600080600080600080600060c0888a03121561104357600080fd5b873561104e81610dc0565b9650602088013561105e81610dc0565b9550604088013561106e81610dc0565b94506060880135935061108360808901610de5565b925060a088013567ffffffffffffffff81111561100957600080fd5b6000602082840312156110b157600080fd5b8135610f4881610dc0565b6000602082840312156110ce57600080fd5b8151610f4881610dc0565b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b73ffffffffffffffffffffffffffffffffffffffff851681528360208201526060604082015260006111586060830184866110d9565b9695505050505050565b600073ffffffffffffffffffffffffffffffffffffffff808a1683528089166020840152808816604084015280871660608401525084608083015260c060a08301526111b260c0830184866110d9565b9998505050505050505050565b73ffffffffffffffffffffffffffffffffffffffff841681526060602082015260006111ee6060830185610eca565b905063ffffffff8316604083015294935050505056fea164736f6c634300080f000a" +var L1ERC721BridgeDeployedBin = "0x608060405234801561001057600080fd5b50600436106100be5760003560e01c80637f46ddb211610076578063aa5574521161005b578063aa55745214610213578063c4d66de814610226578063c89701a21461023957600080fd5b80637f46ddb2146101c8578063927ede2d146101ef57600080fd5b806354fd4d50116100a757806354fd4d50146101285780635d93a3fc14610171578063761f4493146101b557600080fd5b80633687011a146100c35780633cb747bf146100d8575b600080fd5b6100d66100d1366004610e47565b61025f565b005b6000546100fe9062010000900473ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b6101646040518060400160405280600581526020017f312e342e3100000000000000000000000000000000000000000000000000000081525081565b60405161011f9190610f35565b6101a561017f366004610f4f565b603160209081526000938452604080852082529284528284209052825290205460ff1681565b604051901515815260200161011f565b6100d66101c3366004610f90565b61030b565b6100fe7f000000000000000000000000000000000000000000000000000000000000000081565b60005462010000900473ffffffffffffffffffffffffffffffffffffffff166100fe565b6100d6610221366004611028565b610776565b6100d661023436600461109f565b610832565b7f00000000000000000000000000000000000000000000000000000000000000006100fe565b333b156102f3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602d60248201527f4552433732314272696467653a206163636f756e74206973206e6f742065787460448201527f65726e616c6c79206f776e65640000000000000000000000000000000000000060648201526084015b60405180910390fd5b610303868633338888888861097c565b505050505050565b60005462010000900473ffffffffffffffffffffffffffffffffffffffff163314801561041357507f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16600060029054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16636e296e456040518163ffffffff1660e01b8152600401602060405180830381865afa1580156103d7573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906103fb91906110bc565b73ffffffffffffffffffffffffffffffffffffffff16145b61049f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603f60248201527f4552433732314272696467653a2066756e6374696f6e2063616e206f6e6c792060448201527f62652063616c6c65642066726f6d20746865206f74686572206272696467650060648201526084016102ea565b3073ffffffffffffffffffffffffffffffffffffffff881603610544576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602a60248201527f4c314552433732314272696467653a206c6f63616c20746f6b656e2063616e6e60448201527f6f742062652073656c660000000000000000000000000000000000000000000060648201526084016102ea565b73ffffffffffffffffffffffffffffffffffffffff8088166000908152603160209081526040808320938a1683529281528282208683529052205460ff161515600114610613576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603960248201527f4c314552433732314272696467653a20546f6b656e204944206973206e6f742060448201527f657363726f77656420696e20746865204c31204272696467650000000000000060648201526084016102ea565b73ffffffffffffffffffffffffffffffffffffffff87811660008181526031602090815260408083208b8616845282528083208884529091529081902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00169055517f42842e0e000000000000000000000000000000000000000000000000000000008152306004820152918616602483015260448201859052906342842e0e90606401600060405180830381600087803b1580156106d357600080fd5b505af11580156106e7573d6000803e3d6000fd5b505050508473ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff168873ffffffffffffffffffffffffffffffffffffffff167f1f39bf6707b5d608453e0ae4c067b562bcc4c85c0f562ef5d2c774d2e7f131ac878787876040516107659493929190611122565b60405180910390a450505050505050565b73ffffffffffffffffffffffffffffffffffffffff8516610819576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603060248201527f4552433732314272696467653a206e667420726563697069656e742063616e6e60448201527f6f7420626520616464726573732830290000000000000000000000000000000060648201526084016102ea565b610829878733888888888861097c565b50505050505050565b600054600390610100900460ff16158015610854575060005460ff8083169116105b6108e0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a656400000000000000000000000000000000000060648201526084016102ea565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001660ff83161761010017905561091a82610cdc565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff16905560405160ff821681527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050565b73ffffffffffffffffffffffffffffffffffffffff8716610a1f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603160248201527f4c314552433732314272696467653a2072656d6f746520746f6b656e2063616e60448201527f6e6f74206265206164647265737328302900000000000000000000000000000060648201526084016102ea565b600063761f449360e01b888a8989898888604051602401610a469796959493929190611162565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152602080830180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff00000000000000000000000000000000000000000000000000000000959095169490941790935273ffffffffffffffffffffffffffffffffffffffff8c81166000818152603186528381208e8416825286528381208b82529095529382902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600117905590517f23b872dd000000000000000000000000000000000000000000000000000000008152908a166004820152306024820152604481018890529092506323b872dd90606401600060405180830381600087803b158015610b8657600080fd5b505af1158015610b9a573d6000803e3d6000fd5b50506000546040517f3dbb202b0000000000000000000000000000000000000000000000000000000081526201000090910473ffffffffffffffffffffffffffffffffffffffff169250633dbb202b9150610c1d907f000000000000000000000000000000000000000000000000000000000000000090859089906004016111bf565b600060405180830381600087803b158015610c3757600080fd5b505af1158015610c4b573d6000803e3d6000fd5b505050508673ffffffffffffffffffffffffffffffffffffffff168873ffffffffffffffffffffffffffffffffffffffff168a73ffffffffffffffffffffffffffffffffffffffff167fb7460e2a880f256ebef3406116ff3eee0cee51ebccdc2a40698f87ebb2e9c1a589898888604051610cc99493929190611122565b60405180910390a4505050505050505050565b600054610100900460ff16610d73576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e6700000000000000000000000000000000000000000060648201526084016102ea565b6000805473ffffffffffffffffffffffffffffffffffffffff90921662010000027fffffffffffffffffffff0000000000000000000000000000000000000000ffff909216919091179055565b73ffffffffffffffffffffffffffffffffffffffff81168114610de257600080fd5b50565b803563ffffffff81168114610df957600080fd5b919050565b60008083601f840112610e1057600080fd5b50813567ffffffffffffffff811115610e2857600080fd5b602083019150836020828501011115610e4057600080fd5b9250929050565b60008060008060008060a08789031215610e6057600080fd5b8635610e6b81610dc0565b95506020870135610e7b81610dc0565b945060408701359350610e9060608801610de5565b9250608087013567ffffffffffffffff811115610eac57600080fd5b610eb889828a01610dfe565b979a9699509497509295939492505050565b6000815180845260005b81811015610ef057602081850181015186830182015201610ed4565b81811115610f02576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b602081526000610f486020830184610eca565b9392505050565b600080600060608486031215610f6457600080fd5b8335610f6f81610dc0565b92506020840135610f7f81610dc0565b929592945050506040919091013590565b600080600080600080600060c0888a031215610fab57600080fd5b8735610fb681610dc0565b96506020880135610fc681610dc0565b95506040880135610fd681610dc0565b94506060880135610fe681610dc0565b93506080880135925060a088013567ffffffffffffffff81111561100957600080fd5b6110158a828b01610dfe565b989b979a50959850939692959293505050565b600080600080600080600060c0888a03121561104357600080fd5b873561104e81610dc0565b9650602088013561105e81610dc0565b9550604088013561106e81610dc0565b94506060880135935061108360808901610de5565b925060a088013567ffffffffffffffff81111561100957600080fd5b6000602082840312156110b157600080fd5b8135610f4881610dc0565b6000602082840312156110ce57600080fd5b8151610f4881610dc0565b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b73ffffffffffffffffffffffffffffffffffffffff851681528360208201526060604082015260006111586060830184866110d9565b9695505050505050565b600073ffffffffffffffffffffffffffffffffffffffff808a1683528089166020840152808816604084015280871660608401525084608083015260c060a08301526111b260c0830184866110d9565b9998505050505050505050565b73ffffffffffffffffffffffffffffffffffffffff841681526060602082015260006111ee6060830185610eca565b905063ffffffff8316604083015294935050505056fea164736f6c634300080f000a" func init() { if err := json.Unmarshal([]byte(L1ERC721BridgeStorageLayoutJSON), L1ERC721BridgeStorageLayout); err != nil { diff --git a/op-bindings/bindings/l1feevault.go b/op-bindings/bindings/l1feevault.go index 06dfba5be42b4..f237699183125 100644 --- a/op-bindings/bindings/l1feevault.go +++ b/op-bindings/bindings/l1feevault.go @@ -31,7 +31,7 @@ var ( // L1FeeVaultMetaData contains all meta data concerning the L1FeeVault contract. var L1FeeVaultMetaData = &bind.MetaData{ ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_recipient\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_minWithdrawalAmount\",\"type\":\"uint256\"},{\"internalType\":\"enumFeeVault.WithdrawalNetwork\",\"name\":\"_withdrawalNetwork\",\"type\":\"uint8\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"}],\"name\":\"Withdrawal\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"enumFeeVault.WithdrawalNetwork\",\"name\":\"withdrawalNetwork\",\"type\":\"uint8\"}],\"name\":\"Withdrawal\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MIN_WITHDRAWAL_AMOUNT\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"RECIPIENT\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"WITHDRAWAL_NETWORK\",\"outputs\":[{\"internalType\":\"enumFeeVault.WithdrawalNetwork\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"totalProcessed\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"version\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"withdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"stateMutability\":\"payable\",\"type\":\"receive\"}]", - Bin: "0x60e060405234801561001057600080fd5b506040516108d13803806108d183398101604081905261002f91610079565b6001600160a01b03831660a0526080829052828282806001811115610056576100566100cc565b60c081600181111561006a5761006a6100cc565b815250505050505050506100e2565b60008060006060848603121561008e57600080fd5b83516001600160a01b03811681146100a557600080fd5b602085015160408601519194509250600281106100c157600080fd5b809150509250925092565b634e487b7160e01b600052602160045260246000fd5b60805160a05160c051610790610141600039600081816101760152818161038901526103c40152600081816087015281816102d801528181610367015281816103fd01526105640152600081816101b701526101db01526107906000f3fe6080604052600436106100695760003560e01c806384411d651161004357806384411d6514610140578063d0e12f9014610164578063d3e5792b146101a557600080fd5b80630d9019e1146100755780633ccfd60b146100d357806354fd4d50146100ea57600080fd5b3661007057005b600080fd5b34801561008157600080fd5b506100a97f000000000000000000000000000000000000000000000000000000000000000081565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b3480156100df57600080fd5b506100e86101d9565b005b3480156100f657600080fd5b506101336040518060400160405280600581526020017f312e342e3000000000000000000000000000000000000000000000000000000081525081565b6040516100ca9190610630565b34801561014c57600080fd5b5061015660005481565b6040519081526020016100ca565b34801561017057600080fd5b506101987f000000000000000000000000000000000000000000000000000000000000000081565b6040516100ca91906106b4565b3480156101b157600080fd5b506101567f000000000000000000000000000000000000000000000000000000000000000081565b7f00000000000000000000000000000000000000000000000000000000000000004710156102b4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604a60248201527f4665655661756c743a207769746864726177616c20616d6f756e74206d75737460448201527f2062652067726561746572207468616e206d696e696d756d207769746864726160648201527f77616c20616d6f756e7400000000000000000000000000000000000000000000608482015260a4015b60405180910390fd5b6000479050806000808282546102ca91906106c8565b9091555050604080518281527f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff166020820152338183015290517fc8a211cc64b6ed1b50595a9fcb1932b6d1e5a6e8ef15b60e5b1f988ea9086bba9181900360600190a17f38e04cbeb8c10f8f568618aa75be0f10b6729b8b4237743b4de20cbcde2839ee817f0000000000000000000000000000000000000000000000000000000000000000337f00000000000000000000000000000000000000000000000000000000000000006040516103b89493929190610707565b60405180910390a160017f000000000000000000000000000000000000000000000000000000000000000060018111156103f4576103f461064a565b0361050d5760007f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff168260405160006040518083038185875af1925050503d8060008114610473576040519150601f19603f3d011682016040523d82523d6000602084013e610478565b606091505b5050905080610509576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603060248201527f4665655661756c743a206661696c656420746f2073656e642045544820746f2060448201527f4c322066656520726563697069656e740000000000000000000000000000000060648201526084016102ab565b5050565b604080516020810182526000815290517fe11013dd0000000000000000000000000000000000000000000000000000000081527342000000000000000000000000000000000000109163e11013dd918491610590917f0000000000000000000000000000000000000000000000000000000000000000916188b891600401610748565b6000604051808303818588803b1580156105a957600080fd5b505af11580156105bd573d6000803e3d6000fd5b505050505050565b6000815180845260005b818110156105eb576020818501810151868301820152016105cf565b818111156105fd576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60208152600061064360208301846105c5565b9392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b600281106106b0577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b9052565b602081016106c28284610679565b92915050565b60008219821115610702577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b500190565b84815273ffffffffffffffffffffffffffffffffffffffff8481166020830152831660408201526080810161073f6060830184610679565b95945050505050565b73ffffffffffffffffffffffffffffffffffffffff8416815263ffffffff8316602082015260606040820152600061073f60608301846105c556fea164736f6c634300080f000a", + Bin: "0x60e060405234801561001057600080fd5b506040516108d13803806108d183398101604081905261002f91610079565b6001600160a01b03831660a0526080829052828282806001811115610056576100566100cc565b60c081600181111561006a5761006a6100cc565b815250505050505050506100e2565b60008060006060848603121561008e57600080fd5b83516001600160a01b03811681146100a557600080fd5b602085015160408601519194509250600281106100c157600080fd5b809150509250925092565b634e487b7160e01b600052602160045260246000fd5b60805160a05160c051610790610141600039600081816101760152818161038901526103c40152600081816087015281816102d801528181610367015281816103fd01526105640152600081816101b701526101db01526107906000f3fe6080604052600436106100695760003560e01c806384411d651161004357806384411d6514610140578063d0e12f9014610164578063d3e5792b146101a557600080fd5b80630d9019e1146100755780633ccfd60b146100d357806354fd4d50146100ea57600080fd5b3661007057005b600080fd5b34801561008157600080fd5b506100a97f000000000000000000000000000000000000000000000000000000000000000081565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b3480156100df57600080fd5b506100e86101d9565b005b3480156100f657600080fd5b506101336040518060400160405280600581526020017f312e342e3100000000000000000000000000000000000000000000000000000081525081565b6040516100ca9190610630565b34801561014c57600080fd5b5061015660005481565b6040519081526020016100ca565b34801561017057600080fd5b506101987f000000000000000000000000000000000000000000000000000000000000000081565b6040516100ca91906106b4565b3480156101b157600080fd5b506101567f000000000000000000000000000000000000000000000000000000000000000081565b7f00000000000000000000000000000000000000000000000000000000000000004710156102b4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604a60248201527f4665655661756c743a207769746864726177616c20616d6f756e74206d75737460448201527f2062652067726561746572207468616e206d696e696d756d207769746864726160648201527f77616c20616d6f756e7400000000000000000000000000000000000000000000608482015260a4015b60405180910390fd5b6000479050806000808282546102ca91906106c8565b9091555050604080518281527f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff166020820152338183015290517fc8a211cc64b6ed1b50595a9fcb1932b6d1e5a6e8ef15b60e5b1f988ea9086bba9181900360600190a17f38e04cbeb8c10f8f568618aa75be0f10b6729b8b4237743b4de20cbcde2839ee817f0000000000000000000000000000000000000000000000000000000000000000337f00000000000000000000000000000000000000000000000000000000000000006040516103b89493929190610707565b60405180910390a160017f000000000000000000000000000000000000000000000000000000000000000060018111156103f4576103f461064a565b0361050d5760007f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff168260405160006040518083038185875af1925050503d8060008114610473576040519150601f19603f3d011682016040523d82523d6000602084013e610478565b606091505b5050905080610509576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603060248201527f4665655661756c743a206661696c656420746f2073656e642045544820746f2060448201527f4c322066656520726563697069656e740000000000000000000000000000000060648201526084016102ab565b5050565b604080516020810182526000815290517fe11013dd0000000000000000000000000000000000000000000000000000000081527342000000000000000000000000000000000000109163e11013dd918491610590917f0000000000000000000000000000000000000000000000000000000000000000916188b891600401610748565b6000604051808303818588803b1580156105a957600080fd5b505af11580156105bd573d6000803e3d6000fd5b505050505050565b6000815180845260005b818110156105eb576020818501810151868301820152016105cf565b818111156105fd576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60208152600061064360208301846105c5565b9392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b600281106106b0577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b9052565b602081016106c28284610679565b92915050565b60008219821115610702577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b500190565b84815273ffffffffffffffffffffffffffffffffffffffff8481166020830152831660408201526080810161073f6060830184610679565b95945050505050565b73ffffffffffffffffffffffffffffffffffffffff8416815263ffffffff8316602082015260606040820152600061073f60608301846105c556fea164736f6c634300080f000a", } // L1FeeVaultABI is the input ABI used to generate the binding from. diff --git a/op-bindings/bindings/l1feevault_more.go b/op-bindings/bindings/l1feevault_more.go index e34a437e90b1b..8f6fe05076ab7 100644 --- a/op-bindings/bindings/l1feevault_more.go +++ b/op-bindings/bindings/l1feevault_more.go @@ -13,7 +13,7 @@ const L1FeeVaultStorageLayoutJSON = "{\"storage\":[{\"astId\":1000,\"contract\": var L1FeeVaultStorageLayout = new(solc.StorageLayout) -var L1FeeVaultDeployedBin = "0x6080604052600436106100695760003560e01c806384411d651161004357806384411d6514610140578063d0e12f9014610164578063d3e5792b146101a557600080fd5b80630d9019e1146100755780633ccfd60b146100d357806354fd4d50146100ea57600080fd5b3661007057005b600080fd5b34801561008157600080fd5b506100a97f000000000000000000000000000000000000000000000000000000000000000081565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b3480156100df57600080fd5b506100e86101d9565b005b3480156100f657600080fd5b506101336040518060400160405280600581526020017f312e342e3000000000000000000000000000000000000000000000000000000081525081565b6040516100ca9190610630565b34801561014c57600080fd5b5061015660005481565b6040519081526020016100ca565b34801561017057600080fd5b506101987f000000000000000000000000000000000000000000000000000000000000000081565b6040516100ca91906106b4565b3480156101b157600080fd5b506101567f000000000000000000000000000000000000000000000000000000000000000081565b7f00000000000000000000000000000000000000000000000000000000000000004710156102b4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604a60248201527f4665655661756c743a207769746864726177616c20616d6f756e74206d75737460448201527f2062652067726561746572207468616e206d696e696d756d207769746864726160648201527f77616c20616d6f756e7400000000000000000000000000000000000000000000608482015260a4015b60405180910390fd5b6000479050806000808282546102ca91906106c8565b9091555050604080518281527f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff166020820152338183015290517fc8a211cc64b6ed1b50595a9fcb1932b6d1e5a6e8ef15b60e5b1f988ea9086bba9181900360600190a17f38e04cbeb8c10f8f568618aa75be0f10b6729b8b4237743b4de20cbcde2839ee817f0000000000000000000000000000000000000000000000000000000000000000337f00000000000000000000000000000000000000000000000000000000000000006040516103b89493929190610707565b60405180910390a160017f000000000000000000000000000000000000000000000000000000000000000060018111156103f4576103f461064a565b0361050d5760007f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff168260405160006040518083038185875af1925050503d8060008114610473576040519150601f19603f3d011682016040523d82523d6000602084013e610478565b606091505b5050905080610509576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603060248201527f4665655661756c743a206661696c656420746f2073656e642045544820746f2060448201527f4c322066656520726563697069656e740000000000000000000000000000000060648201526084016102ab565b5050565b604080516020810182526000815290517fe11013dd0000000000000000000000000000000000000000000000000000000081527342000000000000000000000000000000000000109163e11013dd918491610590917f0000000000000000000000000000000000000000000000000000000000000000916188b891600401610748565b6000604051808303818588803b1580156105a957600080fd5b505af11580156105bd573d6000803e3d6000fd5b505050505050565b6000815180845260005b818110156105eb576020818501810151868301820152016105cf565b818111156105fd576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60208152600061064360208301846105c5565b9392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b600281106106b0577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b9052565b602081016106c28284610679565b92915050565b60008219821115610702577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b500190565b84815273ffffffffffffffffffffffffffffffffffffffff8481166020830152831660408201526080810161073f6060830184610679565b95945050505050565b73ffffffffffffffffffffffffffffffffffffffff8416815263ffffffff8316602082015260606040820152600061073f60608301846105c556fea164736f6c634300080f000a" +var L1FeeVaultDeployedBin = "0x6080604052600436106100695760003560e01c806384411d651161004357806384411d6514610140578063d0e12f9014610164578063d3e5792b146101a557600080fd5b80630d9019e1146100755780633ccfd60b146100d357806354fd4d50146100ea57600080fd5b3661007057005b600080fd5b34801561008157600080fd5b506100a97f000000000000000000000000000000000000000000000000000000000000000081565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b3480156100df57600080fd5b506100e86101d9565b005b3480156100f657600080fd5b506101336040518060400160405280600581526020017f312e342e3100000000000000000000000000000000000000000000000000000081525081565b6040516100ca9190610630565b34801561014c57600080fd5b5061015660005481565b6040519081526020016100ca565b34801561017057600080fd5b506101987f000000000000000000000000000000000000000000000000000000000000000081565b6040516100ca91906106b4565b3480156101b157600080fd5b506101567f000000000000000000000000000000000000000000000000000000000000000081565b7f00000000000000000000000000000000000000000000000000000000000000004710156102b4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604a60248201527f4665655661756c743a207769746864726177616c20616d6f756e74206d75737460448201527f2062652067726561746572207468616e206d696e696d756d207769746864726160648201527f77616c20616d6f756e7400000000000000000000000000000000000000000000608482015260a4015b60405180910390fd5b6000479050806000808282546102ca91906106c8565b9091555050604080518281527f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff166020820152338183015290517fc8a211cc64b6ed1b50595a9fcb1932b6d1e5a6e8ef15b60e5b1f988ea9086bba9181900360600190a17f38e04cbeb8c10f8f568618aa75be0f10b6729b8b4237743b4de20cbcde2839ee817f0000000000000000000000000000000000000000000000000000000000000000337f00000000000000000000000000000000000000000000000000000000000000006040516103b89493929190610707565b60405180910390a160017f000000000000000000000000000000000000000000000000000000000000000060018111156103f4576103f461064a565b0361050d5760007f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff168260405160006040518083038185875af1925050503d8060008114610473576040519150601f19603f3d011682016040523d82523d6000602084013e610478565b606091505b5050905080610509576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603060248201527f4665655661756c743a206661696c656420746f2073656e642045544820746f2060448201527f4c322066656520726563697069656e740000000000000000000000000000000060648201526084016102ab565b5050565b604080516020810182526000815290517fe11013dd0000000000000000000000000000000000000000000000000000000081527342000000000000000000000000000000000000109163e11013dd918491610590917f0000000000000000000000000000000000000000000000000000000000000000916188b891600401610748565b6000604051808303818588803b1580156105a957600080fd5b505af11580156105bd573d6000803e3d6000fd5b505050505050565b6000815180845260005b818110156105eb576020818501810151868301820152016105cf565b818111156105fd576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60208152600061064360208301846105c5565b9392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b600281106106b0577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b9052565b602081016106c28284610679565b92915050565b60008219821115610702577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b500190565b84815273ffffffffffffffffffffffffffffffffffffffff8481166020830152831660408201526080810161073f6060830184610679565b95945050505050565b73ffffffffffffffffffffffffffffffffffffffff8416815263ffffffff8316602082015260606040820152600061073f60608301846105c556fea164736f6c634300080f000a" func init() { if err := json.Unmarshal([]byte(L1FeeVaultStorageLayoutJSON), L1FeeVaultStorageLayout); err != nil { diff --git a/op-bindings/bindings/l1standardbridge.go b/op-bindings/bindings/l1standardbridge.go index c37716de88d94..2031025574855 100644 --- a/op-bindings/bindings/l1standardbridge.go +++ b/op-bindings/bindings/l1standardbridge.go @@ -31,7 +31,7 @@ var ( // L1StandardBridgeMetaData contains all meta data concerning the L1StandardBridge contract. var L1StandardBridgeMetaData = &bind.MetaData{ ABI: "[{\"inputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"localToken\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"remoteToken\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"ERC20BridgeFinalized\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"localToken\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"remoteToken\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"ERC20BridgeInitiated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"l1Token\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"l2Token\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"ERC20DepositInitiated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"l1Token\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"l2Token\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"ERC20WithdrawalFinalized\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"ETHBridgeFinalized\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"ETHBridgeInitiated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"ETHDepositInitiated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"ETHWithdrawalFinalized\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"version\",\"type\":\"uint8\"}],\"name\":\"Initialized\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MESSENGER\",\"outputs\":[{\"internalType\":\"contractCrossDomainMessenger\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"OTHER_BRIDGE\",\"outputs\":[{\"internalType\":\"contractStandardBridge\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_localToken\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_remoteToken\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"_minGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"_extraData\",\"type\":\"bytes\"}],\"name\":\"bridgeERC20\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_localToken\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_remoteToken\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"_minGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"_extraData\",\"type\":\"bytes\"}],\"name\":\"bridgeERC20To\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"_minGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"_extraData\",\"type\":\"bytes\"}],\"name\":\"bridgeETH\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_to\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"_minGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"_extraData\",\"type\":\"bytes\"}],\"name\":\"bridgeETHTo\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_l1Token\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_l2Token\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"_minGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"_extraData\",\"type\":\"bytes\"}],\"name\":\"depositERC20\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_l1Token\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_l2Token\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"_minGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"_extraData\",\"type\":\"bytes\"}],\"name\":\"depositERC20To\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"_minGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"_extraData\",\"type\":\"bytes\"}],\"name\":\"depositETH\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_to\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"_minGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"_extraData\",\"type\":\"bytes\"}],\"name\":\"depositETHTo\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"name\":\"deposits\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_localToken\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_remoteToken\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"_extraData\",\"type\":\"bytes\"}],\"name\":\"finalizeBridgeERC20\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"_extraData\",\"type\":\"bytes\"}],\"name\":\"finalizeBridgeETH\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_l1Token\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_l2Token\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"_extraData\",\"type\":\"bytes\"}],\"name\":\"finalizeERC20Withdrawal\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"_extraData\",\"type\":\"bytes\"}],\"name\":\"finalizeETHWithdrawal\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"contractCrossDomainMessenger\",\"name\":\"_messenger\",\"type\":\"address\"}],\"name\":\"initialize\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"l2TokenBridge\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"messenger\",\"outputs\":[{\"internalType\":\"contractCrossDomainMessenger\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"otherBridge\",\"outputs\":[{\"internalType\":\"contractStandardBridge\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"version\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"stateMutability\":\"payable\",\"type\":\"receive\"}]", - Bin: "0x60a06040523480156200001157600080fd5b507342000000000000000000000000000000000000106080526200003660006200003c565b620001bb565b600054600390610100900460ff161580156200005f575060005460ff8083169116105b620000c85760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084015b60405180910390fd5b6000805461ffff191660ff831617610100179055620000e7826200012c565b6000805461ff001916905560405160ff821681527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050565b600054610100900460ff16620001995760405162461bcd60e51b815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201526a6e697469616c697a696e6760a81b6064820152608401620000bf565b600380546001600160a01b0319166001600160a01b0392909216919091179055565b608051612a44620001fa60003960008181610379015281816104300152818161057001528181610a22015281816113d80152611a8b0152612a446000f3fe6080604052600436106101635760003560e01c806387087623116100c0578063a9f9e67511610074578063c4d66de811610059578063c4d66de8146104c5578063c89701a214610421578063e11013dd146104e557600080fd5b8063a9f9e67514610492578063b1a1a882146104b257600080fd5b806391c49bf8116100a557806391c49bf814610421578063927ede2d146104545780639a2ac6d51461047f57600080fd5b806387087623146103bb5780638f601f66146103db57600080fd5b8063540abf731161011757806358a997f6116100fc57806358a997f6146103475780637f46ddb214610367578063838b25201461039b57600080fd5b8063540abf73146102d157806354fd4d50146102f157600080fd5b80631532ec34116101485780631532ec34146102545780631635f5fd146102675780633cb747bf1461027a57600080fd5b80630166a07a1461022157806309fc88431461024157600080fd5b3661021c57333b156101fc576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20616e20454f4100000000000000000060648201526084015b60405180910390fd5b61021a333362030d40604051806020016040528060008152506104f8565b005b600080fd5b34801561022d57600080fd5b5061021a61023c36600461248b565b61050b565b61021a61024f36600461253c565b6108d2565b61021a61026236600461258f565b6109a9565b61021a61027536600461258f565b6109bd565b34801561028657600080fd5b506003546102a79073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b3480156102dd57600080fd5b5061021a6102ec366004612602565b610e33565b3480156102fd57600080fd5b5061033a6040518060400160405280600581526020017f312e342e3000000000000000000000000000000000000000000000000000000081525081565b6040516102c891906126ef565b34801561035357600080fd5b5061021a610362366004612702565b610e78565b34801561037357600080fd5b506102a77f000000000000000000000000000000000000000000000000000000000000000081565b3480156103a757600080fd5b5061021a6103b6366004612602565b610f4c565b3480156103c757600080fd5b5061021a6103d6366004612702565b610f91565b3480156103e757600080fd5b506104136103f6366004612785565b600260209081526000928352604080842090915290825290205481565b6040519081526020016102c8565b34801561042d57600080fd5b507f00000000000000000000000000000000000000000000000000000000000000006102a7565b34801561046057600080fd5b5060035473ffffffffffffffffffffffffffffffffffffffff166102a7565b61021a61048d3660046127be565b611065565b34801561049e57600080fd5b5061021a6104ad36600461248b565b6110a7565b61021a6104c036600461253c565b6110b6565b3480156104d157600080fd5b5061021a6104e0366004612821565b611187565b61021a6104f33660046127be565b6112d1565b6105058484348585611314565b50505050565b60035473ffffffffffffffffffffffffffffffffffffffff16331480156105fa5750600354604080517f6e296e45000000000000000000000000000000000000000000000000000000008152905173ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000008116931691636e296e459160048083019260209291908290030181865afa1580156105be573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906105e2919061283e565b73ffffffffffffffffffffffffffffffffffffffff16145b6106ac576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604160248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20746865206f7468657220627269646760648201527f6500000000000000000000000000000000000000000000000000000000000000608482015260a4016101f3565b6106b5876114fa565b15610803576106c4878761155c565b610776576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604a60248201527f5374616e646172644272696467653a2077726f6e672072656d6f746520746f6b60448201527f656e20666f72204f7074696d69736d204d696e7461626c65204552433230206c60648201527f6f63616c20746f6b656e00000000000000000000000000000000000000000000608482015260a4016101f3565b6040517f40c10f1900000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8581166004830152602482018590528816906340c10f1990604401600060405180830381600087803b1580156107e657600080fd5b505af11580156107fa573d6000803e3d6000fd5b50505050610885565b73ffffffffffffffffffffffffffffffffffffffff8088166000908152600260209081526040808320938a168352929052205461084190849061288a565b73ffffffffffffffffffffffffffffffffffffffff8089166000818152600260209081526040808320948c168352939052919091209190915561088590858561167c565b6108c9878787878787878080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061175092505050565b50505050505050565b333b15610961576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20616e20454f4100000000000000000060648201526084016101f3565b6109a43333348686868080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061131492505050565b505050565b6109b685858585856109bd565b5050505050565b60035473ffffffffffffffffffffffffffffffffffffffff1633148015610aac5750600354604080517f6e296e45000000000000000000000000000000000000000000000000000000008152905173ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000008116931691636e296e459160048083019260209291908290030181865afa158015610a70573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a94919061283e565b73ffffffffffffffffffffffffffffffffffffffff16145b610b5e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604160248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20746865206f7468657220627269646760648201527f6500000000000000000000000000000000000000000000000000000000000000608482015260a4016101f3565b823414610bed576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603a60248201527f5374616e646172644272696467653a20616d6f756e742073656e7420646f657360448201527f206e6f74206d6174636820616d6f756e7420726571756972656400000000000060648201526084016101f3565b3073ffffffffffffffffffffffffffffffffffffffff851603610c92576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f5374616e646172644272696467653a2063616e6e6f742073656e6420746f207360448201527f656c66000000000000000000000000000000000000000000000000000000000060648201526084016101f3565b60035473ffffffffffffffffffffffffffffffffffffffff90811690851603610d3d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602860248201527f5374616e646172644272696467653a2063616e6e6f742073656e6420746f206d60448201527f657373656e67657200000000000000000000000000000000000000000000000060648201526084016101f3565b610d7f85858585858080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506117de92505050565b6000610d9c855a8660405180602001604052806000815250611851565b905080610e2b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f5374616e646172644272696467653a20455448207472616e736665722066616960448201527f6c6564000000000000000000000000000000000000000000000000000000000060648201526084016101f3565b505050505050565b6108c987873388888888888080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061186b92505050565b333b15610f07576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20616e20454f4100000000000000000060648201526084016101f3565b610e2b86863333888888888080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250611bb392505050565b6108c987873388888888888080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250611bb392505050565b333b15611020576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20616e20454f4100000000000000000060648201526084016101f3565b610e2b86863333888888888080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061186b92505050565b61050533858585858080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506104f892505050565b6108c98787878787878761050b565b333b15611145576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20616e20454f4100000000000000000060648201526084016101f3565b6109a433338585858080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506104f892505050565b600054600390610100900460ff161580156111a9575060005460ff8083169116105b611235576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a656400000000000000000000000000000000000060648201526084016101f3565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001660ff83161761010017905561126f82611bc2565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff16905560405160ff821681527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050565b6105053385348686868080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061131492505050565b8234146113a3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603e60248201527f5374616e646172644272696467653a206272696467696e6720455448206d757360448201527f7420696e636c7564652073756666696369656e74204554482076616c7565000060648201526084016101f3565b6113af85858584611ca0565b60035460405173ffffffffffffffffffffffffffffffffffffffff90911690633dbb202b9085907f0000000000000000000000000000000000000000000000000000000000000000907f1635f5fd000000000000000000000000000000000000000000000000000000009061142e908b908b9086908a906024016128a1565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009485161790525160e086901b90921682526114c1929188906004016128ea565b6000604051808303818588803b1580156114da57600080fd5b505af11580156114ee573d6000803e3d6000fd5b50505050505050505050565b6000611526827f1d1d8b6300000000000000000000000000000000000000000000000000000000611d13565b806115565750611556827fec4fc8e300000000000000000000000000000000000000000000000000000000611d13565b92915050565b6000611588837f1d1d8b6300000000000000000000000000000000000000000000000000000000611d13565b15611631578273ffffffffffffffffffffffffffffffffffffffff1663c01e1bd66040518163ffffffff1660e01b8152600401602060405180830381865afa1580156115d8573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906115fc919061283e565b73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16149050611556565b8273ffffffffffffffffffffffffffffffffffffffff1663d6c0b2c46040518163ffffffff1660e01b8152600401602060405180830381865afa1580156115d8573d6000803e3d6000fd5b60405173ffffffffffffffffffffffffffffffffffffffff83166024820152604481018290526109a49084907fa9059cbb00000000000000000000000000000000000000000000000000000000906064015b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff0000000000000000000000000000000000000000000000000000000090931692909217909152611d36565b8373ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff167f3ceee06c1e37648fcbb6ed52e17b3e1f275a1f8c7b22a84b2b84732431e046b38686866040516117c89392919061292f565b60405180910390a4610e2b868686868686611e42565b8273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167f2ac69ee804d9a7a0984249f508dfab7cb2534b465b6ce1580f99a38ba9c5e631848460405161183d92919061296d565b60405180910390a361050584848484611eca565b600080600080845160208601878a8af19695505050505050565b611874876114fa565b156119c257611883878761155c565b611935576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604a60248201527f5374616e646172644272696467653a2077726f6e672072656d6f746520746f6b60448201527f656e20666f72204f7074696d69736d204d696e7461626c65204552433230206c60648201527f6f63616c20746f6b656e00000000000000000000000000000000000000000000608482015260a4016101f3565b6040517f9dc29fac00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015260248201859052881690639dc29fac90604401600060405180830381600087803b1580156119a557600080fd5b505af11580156119b9573d6000803e3d6000fd5b50505050611a56565b6119e473ffffffffffffffffffffffffffffffffffffffff8816863086611f37565b73ffffffffffffffffffffffffffffffffffffffff8088166000908152600260209081526040808320938a1683529290522054611a22908490612986565b73ffffffffffffffffffffffffffffffffffffffff8089166000908152600260209081526040808320938b16835292905220555b611a64878787878786611f95565b60035460405173ffffffffffffffffffffffffffffffffffffffff90911690633dbb202b907f0000000000000000000000000000000000000000000000000000000000000000907f0166a07a0000000000000000000000000000000000000000000000000000000090611ae5908b908d908c908c908c908b9060240161299e565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009485161790525160e085901b9092168252611b78929187906004016128ea565b600060405180830381600087803b158015611b9257600080fd5b505af1158015611ba6573d6000803e3d6000fd5b5050505050505050505050565b6108c98787878787878761186b565b600054610100900460ff16611c59576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e6700000000000000000000000000000000000000000060648201526084016101f3565b600380547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b8273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167f35d79ab81f2b2017e19afb5c5571778877782d7a8786f5907f93b0f4702f4f238484604051611cff92919061296d565b60405180910390a361050584848484612023565b6000611d1e83612082565b8015611d2f5750611d2f83836120e6565b9392505050565b6000611d98826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c65648152508573ffffffffffffffffffffffffffffffffffffffff166121b59092919063ffffffff16565b8051909150156109a45780806020019051810190611db691906129f9565b6109a4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e60448201527f6f7420737563636565640000000000000000000000000000000000000000000060648201526084016101f3565b8373ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff167fd59c65b35445225835c83f50b6ede06a7be047d22e357073e250d9af537518cd868686604051611eba9392919061292f565b60405180910390a4505050505050565b8273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167f31b2166ff604fc5672ea5df08a78081d2bc6d746cadce880747f3643d819e83d8484604051611f2992919061296d565b60405180910390a350505050565b60405173ffffffffffffffffffffffffffffffffffffffff808516602483015283166044820152606481018290526105059085907f23b872dd00000000000000000000000000000000000000000000000000000000906084016116ce565b8373ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff167f718594027abd4eaed59f95162563e0cc6d0e8d5b86b1c7be8b1b0ac3343d039686868660405161200d9392919061292f565b60405180910390a4610e2b8686868686866121cc565b8273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167f2849b43074093a05396b6f2a937dee8565b15a48a7b3d4bffb732a5017380af58484604051611f2992919061296d565b60006120ae827f01ffc9a7000000000000000000000000000000000000000000000000000000006120e6565b801561155657506120df827fffffffff000000000000000000000000000000000000000000000000000000006120e6565b1592915050565b604080517fffffffff000000000000000000000000000000000000000000000000000000008316602480830191909152825180830390910181526044909101909152602080820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f01ffc9a700000000000000000000000000000000000000000000000000000000178152825160009392849283928392918391908a617530fa92503d9150600051905082801561219e575060208210155b80156121aa5750600081115b979650505050505050565b60606121c48484600085612244565b949350505050565b8373ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff167f7ff126db8024424bbfd9826e8ab82ff59136289ea440b04b39a0df1b03b9cabf868686604051611eba9392919061292f565b6060824710156122d6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f60448201527f722063616c6c000000000000000000000000000000000000000000000000000060648201526084016101f3565b73ffffffffffffffffffffffffffffffffffffffff85163b612354576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064016101f3565b6000808673ffffffffffffffffffffffffffffffffffffffff16858760405161237d9190612a1b565b60006040518083038185875af1925050503d80600081146123ba576040519150601f19603f3d011682016040523d82523d6000602084013e6123bf565b606091505b50915091506121aa828286606083156123d9575081611d2f565b8251156123e95782518084602001fd5b816040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016101f391906126ef565b73ffffffffffffffffffffffffffffffffffffffff8116811461243f57600080fd5b50565b60008083601f84011261245457600080fd5b50813567ffffffffffffffff81111561246c57600080fd5b60208301915083602082850101111561248457600080fd5b9250929050565b600080600080600080600060c0888a0312156124a657600080fd5b87356124b18161241d565b965060208801356124c18161241d565b955060408801356124d18161241d565b945060608801356124e18161241d565b93506080880135925060a088013567ffffffffffffffff81111561250457600080fd5b6125108a828b01612442565b989b979a50959850939692959293505050565b803563ffffffff8116811461253757600080fd5b919050565b60008060006040848603121561255157600080fd5b61255a84612523565b9250602084013567ffffffffffffffff81111561257657600080fd5b61258286828701612442565b9497909650939450505050565b6000806000806000608086880312156125a757600080fd5b85356125b28161241d565b945060208601356125c28161241d565b935060408601359250606086013567ffffffffffffffff8111156125e557600080fd5b6125f188828901612442565b969995985093965092949392505050565b600080600080600080600060c0888a03121561261d57600080fd5b87356126288161241d565b965060208801356126388161241d565b955060408801356126488161241d565b94506060880135935061265d60808901612523565b925060a088013567ffffffffffffffff81111561250457600080fd5b60005b8381101561269457818101518382015260200161267c565b838111156105055750506000910152565b600081518084526126bd816020860160208601612679565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b602081526000611d2f60208301846126a5565b60008060008060008060a0878903121561271b57600080fd5b86356127268161241d565b955060208701356127368161241d565b94506040870135935061274b60608801612523565b9250608087013567ffffffffffffffff81111561276757600080fd5b61277389828a01612442565b979a9699509497509295939492505050565b6000806040838503121561279857600080fd5b82356127a38161241d565b915060208301356127b38161241d565b809150509250929050565b600080600080606085870312156127d457600080fd5b84356127df8161241d565b93506127ed60208601612523565b9250604085013567ffffffffffffffff81111561280957600080fd5b61281587828801612442565b95989497509550505050565b60006020828403121561283357600080fd5b8135611d2f8161241d565b60006020828403121561285057600080fd5b8151611d2f8161241d565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60008282101561289c5761289c61285b565b500390565b600073ffffffffffffffffffffffffffffffffffffffff8087168352808616602084015250836040830152608060608301526128e060808301846126a5565b9695505050505050565b73ffffffffffffffffffffffffffffffffffffffff8416815260606020820152600061291960608301856126a5565b905063ffffffff83166040830152949350505050565b73ffffffffffffffffffffffffffffffffffffffff8416815282602082015260606040820152600061296460608301846126a5565b95945050505050565b8281526040602082015260006121c460408301846126a5565b600082198211156129995761299961285b565b500190565b600073ffffffffffffffffffffffffffffffffffffffff80891683528088166020840152808716604084015280861660608401525083608083015260c060a08301526129ed60c08301846126a5565b98975050505050505050565b600060208284031215612a0b57600080fd5b81518015158114611d2f57600080fd5b60008251612a2d818460208701612679565b919091019291505056fea164736f6c634300080f000a", + Bin: "0x60a06040523480156200001157600080fd5b507342000000000000000000000000000000000000106080526200003660006200003c565b620001bb565b600054600390610100900460ff161580156200005f575060005460ff8083169116105b620000c85760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084015b60405180910390fd5b6000805461ffff191660ff831617610100179055620000e7826200012c565b6000805461ff001916905560405160ff821681527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050565b600054610100900460ff16620001995760405162461bcd60e51b815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201526a6e697469616c697a696e6760a81b6064820152608401620000bf565b600380546001600160a01b0319166001600160a01b0392909216919091179055565b608051612a44620001fa60003960008181610379015281816104300152818161057001528181610a22015281816113d80152611a8b0152612a446000f3fe6080604052600436106101635760003560e01c806387087623116100c0578063a9f9e67511610074578063c4d66de811610059578063c4d66de8146104c5578063c89701a214610421578063e11013dd146104e557600080fd5b8063a9f9e67514610492578063b1a1a882146104b257600080fd5b806391c49bf8116100a557806391c49bf814610421578063927ede2d146104545780639a2ac6d51461047f57600080fd5b806387087623146103bb5780638f601f66146103db57600080fd5b8063540abf731161011757806358a997f6116100fc57806358a997f6146103475780637f46ddb214610367578063838b25201461039b57600080fd5b8063540abf73146102d157806354fd4d50146102f157600080fd5b80631532ec34116101485780631532ec34146102545780631635f5fd146102675780633cb747bf1461027a57600080fd5b80630166a07a1461022157806309fc88431461024157600080fd5b3661021c57333b156101fc576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20616e20454f4100000000000000000060648201526084015b60405180910390fd5b61021a333362030d40604051806020016040528060008152506104f8565b005b600080fd5b34801561022d57600080fd5b5061021a61023c36600461248b565b61050b565b61021a61024f36600461253c565b6108d2565b61021a61026236600461258f565b6109a9565b61021a61027536600461258f565b6109bd565b34801561028657600080fd5b506003546102a79073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b3480156102dd57600080fd5b5061021a6102ec366004612602565b610e33565b3480156102fd57600080fd5b5061033a6040518060400160405280600581526020017f312e342e3100000000000000000000000000000000000000000000000000000081525081565b6040516102c891906126ef565b34801561035357600080fd5b5061021a610362366004612702565b610e78565b34801561037357600080fd5b506102a77f000000000000000000000000000000000000000000000000000000000000000081565b3480156103a757600080fd5b5061021a6103b6366004612602565b610f4c565b3480156103c757600080fd5b5061021a6103d6366004612702565b610f91565b3480156103e757600080fd5b506104136103f6366004612785565b600260209081526000928352604080842090915290825290205481565b6040519081526020016102c8565b34801561042d57600080fd5b507f00000000000000000000000000000000000000000000000000000000000000006102a7565b34801561046057600080fd5b5060035473ffffffffffffffffffffffffffffffffffffffff166102a7565b61021a61048d3660046127be565b611065565b34801561049e57600080fd5b5061021a6104ad36600461248b565b6110a7565b61021a6104c036600461253c565b6110b6565b3480156104d157600080fd5b5061021a6104e0366004612821565b611187565b61021a6104f33660046127be565b6112d1565b6105058484348585611314565b50505050565b60035473ffffffffffffffffffffffffffffffffffffffff16331480156105fa5750600354604080517f6e296e45000000000000000000000000000000000000000000000000000000008152905173ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000008116931691636e296e459160048083019260209291908290030181865afa1580156105be573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906105e2919061283e565b73ffffffffffffffffffffffffffffffffffffffff16145b6106ac576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604160248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20746865206f7468657220627269646760648201527f6500000000000000000000000000000000000000000000000000000000000000608482015260a4016101f3565b6106b5876114fa565b15610803576106c4878761155c565b610776576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604a60248201527f5374616e646172644272696467653a2077726f6e672072656d6f746520746f6b60448201527f656e20666f72204f7074696d69736d204d696e7461626c65204552433230206c60648201527f6f63616c20746f6b656e00000000000000000000000000000000000000000000608482015260a4016101f3565b6040517f40c10f1900000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8581166004830152602482018590528816906340c10f1990604401600060405180830381600087803b1580156107e657600080fd5b505af11580156107fa573d6000803e3d6000fd5b50505050610885565b73ffffffffffffffffffffffffffffffffffffffff8088166000908152600260209081526040808320938a168352929052205461084190849061288a565b73ffffffffffffffffffffffffffffffffffffffff8089166000818152600260209081526040808320948c168352939052919091209190915561088590858561167c565b6108c9878787878787878080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061175092505050565b50505050505050565b333b15610961576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20616e20454f4100000000000000000060648201526084016101f3565b6109a43333348686868080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061131492505050565b505050565b6109b685858585856109bd565b5050505050565b60035473ffffffffffffffffffffffffffffffffffffffff1633148015610aac5750600354604080517f6e296e45000000000000000000000000000000000000000000000000000000008152905173ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000008116931691636e296e459160048083019260209291908290030181865afa158015610a70573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a94919061283e565b73ffffffffffffffffffffffffffffffffffffffff16145b610b5e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604160248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20746865206f7468657220627269646760648201527f6500000000000000000000000000000000000000000000000000000000000000608482015260a4016101f3565b823414610bed576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603a60248201527f5374616e646172644272696467653a20616d6f756e742073656e7420646f657360448201527f206e6f74206d6174636820616d6f756e7420726571756972656400000000000060648201526084016101f3565b3073ffffffffffffffffffffffffffffffffffffffff851603610c92576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f5374616e646172644272696467653a2063616e6e6f742073656e6420746f207360448201527f656c66000000000000000000000000000000000000000000000000000000000060648201526084016101f3565b60035473ffffffffffffffffffffffffffffffffffffffff90811690851603610d3d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602860248201527f5374616e646172644272696467653a2063616e6e6f742073656e6420746f206d60448201527f657373656e67657200000000000000000000000000000000000000000000000060648201526084016101f3565b610d7f85858585858080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506117de92505050565b6000610d9c855a8660405180602001604052806000815250611851565b905080610e2b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f5374616e646172644272696467653a20455448207472616e736665722066616960448201527f6c6564000000000000000000000000000000000000000000000000000000000060648201526084016101f3565b505050505050565b6108c987873388888888888080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061186b92505050565b333b15610f07576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20616e20454f4100000000000000000060648201526084016101f3565b610e2b86863333888888888080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250611bb392505050565b6108c987873388888888888080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250611bb392505050565b333b15611020576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20616e20454f4100000000000000000060648201526084016101f3565b610e2b86863333888888888080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061186b92505050565b61050533858585858080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506104f892505050565b6108c98787878787878761050b565b333b15611145576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20616e20454f4100000000000000000060648201526084016101f3565b6109a433338585858080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506104f892505050565b600054600390610100900460ff161580156111a9575060005460ff8083169116105b611235576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a656400000000000000000000000000000000000060648201526084016101f3565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001660ff83161761010017905561126f82611bc2565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff16905560405160ff821681527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050565b6105053385348686868080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061131492505050565b8234146113a3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603e60248201527f5374616e646172644272696467653a206272696467696e6720455448206d757360448201527f7420696e636c7564652073756666696369656e74204554482076616c7565000060648201526084016101f3565b6113af85858584611ca0565b60035460405173ffffffffffffffffffffffffffffffffffffffff90911690633dbb202b9085907f0000000000000000000000000000000000000000000000000000000000000000907f1635f5fd000000000000000000000000000000000000000000000000000000009061142e908b908b9086908a906024016128a1565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009485161790525160e086901b90921682526114c1929188906004016128ea565b6000604051808303818588803b1580156114da57600080fd5b505af11580156114ee573d6000803e3d6000fd5b50505050505050505050565b6000611526827f1d1d8b6300000000000000000000000000000000000000000000000000000000611d13565b806115565750611556827fec4fc8e300000000000000000000000000000000000000000000000000000000611d13565b92915050565b6000611588837f1d1d8b6300000000000000000000000000000000000000000000000000000000611d13565b15611631578273ffffffffffffffffffffffffffffffffffffffff1663c01e1bd66040518163ffffffff1660e01b8152600401602060405180830381865afa1580156115d8573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906115fc919061283e565b73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16149050611556565b8273ffffffffffffffffffffffffffffffffffffffff1663d6c0b2c46040518163ffffffff1660e01b8152600401602060405180830381865afa1580156115d8573d6000803e3d6000fd5b60405173ffffffffffffffffffffffffffffffffffffffff83166024820152604481018290526109a49084907fa9059cbb00000000000000000000000000000000000000000000000000000000906064015b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff0000000000000000000000000000000000000000000000000000000090931692909217909152611d36565b8373ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff167f3ceee06c1e37648fcbb6ed52e17b3e1f275a1f8c7b22a84b2b84732431e046b38686866040516117c89392919061292f565b60405180910390a4610e2b868686868686611e42565b8273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167f2ac69ee804d9a7a0984249f508dfab7cb2534b465b6ce1580f99a38ba9c5e631848460405161183d92919061296d565b60405180910390a361050584848484611eca565b600080600080845160208601878a8af19695505050505050565b611874876114fa565b156119c257611883878761155c565b611935576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604a60248201527f5374616e646172644272696467653a2077726f6e672072656d6f746520746f6b60448201527f656e20666f72204f7074696d69736d204d696e7461626c65204552433230206c60648201527f6f63616c20746f6b656e00000000000000000000000000000000000000000000608482015260a4016101f3565b6040517f9dc29fac00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015260248201859052881690639dc29fac90604401600060405180830381600087803b1580156119a557600080fd5b505af11580156119b9573d6000803e3d6000fd5b50505050611a56565b6119e473ffffffffffffffffffffffffffffffffffffffff8816863086611f37565b73ffffffffffffffffffffffffffffffffffffffff8088166000908152600260209081526040808320938a1683529290522054611a22908490612986565b73ffffffffffffffffffffffffffffffffffffffff8089166000908152600260209081526040808320938b16835292905220555b611a64878787878786611f95565b60035460405173ffffffffffffffffffffffffffffffffffffffff90911690633dbb202b907f0000000000000000000000000000000000000000000000000000000000000000907f0166a07a0000000000000000000000000000000000000000000000000000000090611ae5908b908d908c908c908c908b9060240161299e565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009485161790525160e085901b9092168252611b78929187906004016128ea565b600060405180830381600087803b158015611b9257600080fd5b505af1158015611ba6573d6000803e3d6000fd5b5050505050505050505050565b6108c98787878787878761186b565b600054610100900460ff16611c59576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e6700000000000000000000000000000000000000000060648201526084016101f3565b600380547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b8273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167f35d79ab81f2b2017e19afb5c5571778877782d7a8786f5907f93b0f4702f4f238484604051611cff92919061296d565b60405180910390a361050584848484612023565b6000611d1e83612082565b8015611d2f5750611d2f83836120e6565b9392505050565b6000611d98826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c65648152508573ffffffffffffffffffffffffffffffffffffffff166121b59092919063ffffffff16565b8051909150156109a45780806020019051810190611db691906129f9565b6109a4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e60448201527f6f7420737563636565640000000000000000000000000000000000000000000060648201526084016101f3565b8373ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff167fd59c65b35445225835c83f50b6ede06a7be047d22e357073e250d9af537518cd868686604051611eba9392919061292f565b60405180910390a4505050505050565b8273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167f31b2166ff604fc5672ea5df08a78081d2bc6d746cadce880747f3643d819e83d8484604051611f2992919061296d565b60405180910390a350505050565b60405173ffffffffffffffffffffffffffffffffffffffff808516602483015283166044820152606481018290526105059085907f23b872dd00000000000000000000000000000000000000000000000000000000906084016116ce565b8373ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff167f718594027abd4eaed59f95162563e0cc6d0e8d5b86b1c7be8b1b0ac3343d039686868660405161200d9392919061292f565b60405180910390a4610e2b8686868686866121cc565b8273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167f2849b43074093a05396b6f2a937dee8565b15a48a7b3d4bffb732a5017380af58484604051611f2992919061296d565b60006120ae827f01ffc9a7000000000000000000000000000000000000000000000000000000006120e6565b801561155657506120df827fffffffff000000000000000000000000000000000000000000000000000000006120e6565b1592915050565b604080517fffffffff000000000000000000000000000000000000000000000000000000008316602480830191909152825180830390910181526044909101909152602080820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f01ffc9a700000000000000000000000000000000000000000000000000000000178152825160009392849283928392918391908a617530fa92503d9150600051905082801561219e575060208210155b80156121aa5750600081115b979650505050505050565b60606121c48484600085612244565b949350505050565b8373ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff167f7ff126db8024424bbfd9826e8ab82ff59136289ea440b04b39a0df1b03b9cabf868686604051611eba9392919061292f565b6060824710156122d6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f60448201527f722063616c6c000000000000000000000000000000000000000000000000000060648201526084016101f3565b73ffffffffffffffffffffffffffffffffffffffff85163b612354576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064016101f3565b6000808673ffffffffffffffffffffffffffffffffffffffff16858760405161237d9190612a1b565b60006040518083038185875af1925050503d80600081146123ba576040519150601f19603f3d011682016040523d82523d6000602084013e6123bf565b606091505b50915091506121aa828286606083156123d9575081611d2f565b8251156123e95782518084602001fd5b816040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016101f391906126ef565b73ffffffffffffffffffffffffffffffffffffffff8116811461243f57600080fd5b50565b60008083601f84011261245457600080fd5b50813567ffffffffffffffff81111561246c57600080fd5b60208301915083602082850101111561248457600080fd5b9250929050565b600080600080600080600060c0888a0312156124a657600080fd5b87356124b18161241d565b965060208801356124c18161241d565b955060408801356124d18161241d565b945060608801356124e18161241d565b93506080880135925060a088013567ffffffffffffffff81111561250457600080fd5b6125108a828b01612442565b989b979a50959850939692959293505050565b803563ffffffff8116811461253757600080fd5b919050565b60008060006040848603121561255157600080fd5b61255a84612523565b9250602084013567ffffffffffffffff81111561257657600080fd5b61258286828701612442565b9497909650939450505050565b6000806000806000608086880312156125a757600080fd5b85356125b28161241d565b945060208601356125c28161241d565b935060408601359250606086013567ffffffffffffffff8111156125e557600080fd5b6125f188828901612442565b969995985093965092949392505050565b600080600080600080600060c0888a03121561261d57600080fd5b87356126288161241d565b965060208801356126388161241d565b955060408801356126488161241d565b94506060880135935061265d60808901612523565b925060a088013567ffffffffffffffff81111561250457600080fd5b60005b8381101561269457818101518382015260200161267c565b838111156105055750506000910152565b600081518084526126bd816020860160208601612679565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b602081526000611d2f60208301846126a5565b60008060008060008060a0878903121561271b57600080fd5b86356127268161241d565b955060208701356127368161241d565b94506040870135935061274b60608801612523565b9250608087013567ffffffffffffffff81111561276757600080fd5b61277389828a01612442565b979a9699509497509295939492505050565b6000806040838503121561279857600080fd5b82356127a38161241d565b915060208301356127b38161241d565b809150509250929050565b600080600080606085870312156127d457600080fd5b84356127df8161241d565b93506127ed60208601612523565b9250604085013567ffffffffffffffff81111561280957600080fd5b61281587828801612442565b95989497509550505050565b60006020828403121561283357600080fd5b8135611d2f8161241d565b60006020828403121561285057600080fd5b8151611d2f8161241d565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60008282101561289c5761289c61285b565b500390565b600073ffffffffffffffffffffffffffffffffffffffff8087168352808616602084015250836040830152608060608301526128e060808301846126a5565b9695505050505050565b73ffffffffffffffffffffffffffffffffffffffff8416815260606020820152600061291960608301856126a5565b905063ffffffff83166040830152949350505050565b73ffffffffffffffffffffffffffffffffffffffff8416815282602082015260606040820152600061296460608301846126a5565b95945050505050565b8281526040602082015260006121c460408301846126a5565b600082198211156129995761299961285b565b500190565b600073ffffffffffffffffffffffffffffffffffffffff80891683528088166020840152808716604084015280861660608401525083608083015260c060a08301526129ed60c08301846126a5565b98975050505050505050565b600060208284031215612a0b57600080fd5b81518015158114611d2f57600080fd5b60008251612a2d818460208701612679565b919091019291505056fea164736f6c634300080f000a", } // L1StandardBridgeABI is the input ABI used to generate the binding from. diff --git a/op-bindings/bindings/l1standardbridge_more.go b/op-bindings/bindings/l1standardbridge_more.go index 374ea4fcf6d92..8d2d77be4957d 100644 --- a/op-bindings/bindings/l1standardbridge_more.go +++ b/op-bindings/bindings/l1standardbridge_more.go @@ -13,7 +13,7 @@ const L1StandardBridgeStorageLayoutJSON = "{\"storage\":[{\"astId\":1000,\"contr var L1StandardBridgeStorageLayout = new(solc.StorageLayout) -var L1StandardBridgeDeployedBin = "0x6080604052600436106101635760003560e01c806387087623116100c0578063a9f9e67511610074578063c4d66de811610059578063c4d66de8146104c5578063c89701a214610421578063e11013dd146104e557600080fd5b8063a9f9e67514610492578063b1a1a882146104b257600080fd5b806391c49bf8116100a557806391c49bf814610421578063927ede2d146104545780639a2ac6d51461047f57600080fd5b806387087623146103bb5780638f601f66146103db57600080fd5b8063540abf731161011757806358a997f6116100fc57806358a997f6146103475780637f46ddb214610367578063838b25201461039b57600080fd5b8063540abf73146102d157806354fd4d50146102f157600080fd5b80631532ec34116101485780631532ec34146102545780631635f5fd146102675780633cb747bf1461027a57600080fd5b80630166a07a1461022157806309fc88431461024157600080fd5b3661021c57333b156101fc576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20616e20454f4100000000000000000060648201526084015b60405180910390fd5b61021a333362030d40604051806020016040528060008152506104f8565b005b600080fd5b34801561022d57600080fd5b5061021a61023c36600461248b565b61050b565b61021a61024f36600461253c565b6108d2565b61021a61026236600461258f565b6109a9565b61021a61027536600461258f565b6109bd565b34801561028657600080fd5b506003546102a79073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b3480156102dd57600080fd5b5061021a6102ec366004612602565b610e33565b3480156102fd57600080fd5b5061033a6040518060400160405280600581526020017f312e342e3000000000000000000000000000000000000000000000000000000081525081565b6040516102c891906126ef565b34801561035357600080fd5b5061021a610362366004612702565b610e78565b34801561037357600080fd5b506102a77f000000000000000000000000000000000000000000000000000000000000000081565b3480156103a757600080fd5b5061021a6103b6366004612602565b610f4c565b3480156103c757600080fd5b5061021a6103d6366004612702565b610f91565b3480156103e757600080fd5b506104136103f6366004612785565b600260209081526000928352604080842090915290825290205481565b6040519081526020016102c8565b34801561042d57600080fd5b507f00000000000000000000000000000000000000000000000000000000000000006102a7565b34801561046057600080fd5b5060035473ffffffffffffffffffffffffffffffffffffffff166102a7565b61021a61048d3660046127be565b611065565b34801561049e57600080fd5b5061021a6104ad36600461248b565b6110a7565b61021a6104c036600461253c565b6110b6565b3480156104d157600080fd5b5061021a6104e0366004612821565b611187565b61021a6104f33660046127be565b6112d1565b6105058484348585611314565b50505050565b60035473ffffffffffffffffffffffffffffffffffffffff16331480156105fa5750600354604080517f6e296e45000000000000000000000000000000000000000000000000000000008152905173ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000008116931691636e296e459160048083019260209291908290030181865afa1580156105be573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906105e2919061283e565b73ffffffffffffffffffffffffffffffffffffffff16145b6106ac576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604160248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20746865206f7468657220627269646760648201527f6500000000000000000000000000000000000000000000000000000000000000608482015260a4016101f3565b6106b5876114fa565b15610803576106c4878761155c565b610776576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604a60248201527f5374616e646172644272696467653a2077726f6e672072656d6f746520746f6b60448201527f656e20666f72204f7074696d69736d204d696e7461626c65204552433230206c60648201527f6f63616c20746f6b656e00000000000000000000000000000000000000000000608482015260a4016101f3565b6040517f40c10f1900000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8581166004830152602482018590528816906340c10f1990604401600060405180830381600087803b1580156107e657600080fd5b505af11580156107fa573d6000803e3d6000fd5b50505050610885565b73ffffffffffffffffffffffffffffffffffffffff8088166000908152600260209081526040808320938a168352929052205461084190849061288a565b73ffffffffffffffffffffffffffffffffffffffff8089166000818152600260209081526040808320948c168352939052919091209190915561088590858561167c565b6108c9878787878787878080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061175092505050565b50505050505050565b333b15610961576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20616e20454f4100000000000000000060648201526084016101f3565b6109a43333348686868080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061131492505050565b505050565b6109b685858585856109bd565b5050505050565b60035473ffffffffffffffffffffffffffffffffffffffff1633148015610aac5750600354604080517f6e296e45000000000000000000000000000000000000000000000000000000008152905173ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000008116931691636e296e459160048083019260209291908290030181865afa158015610a70573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a94919061283e565b73ffffffffffffffffffffffffffffffffffffffff16145b610b5e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604160248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20746865206f7468657220627269646760648201527f6500000000000000000000000000000000000000000000000000000000000000608482015260a4016101f3565b823414610bed576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603a60248201527f5374616e646172644272696467653a20616d6f756e742073656e7420646f657360448201527f206e6f74206d6174636820616d6f756e7420726571756972656400000000000060648201526084016101f3565b3073ffffffffffffffffffffffffffffffffffffffff851603610c92576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f5374616e646172644272696467653a2063616e6e6f742073656e6420746f207360448201527f656c66000000000000000000000000000000000000000000000000000000000060648201526084016101f3565b60035473ffffffffffffffffffffffffffffffffffffffff90811690851603610d3d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602860248201527f5374616e646172644272696467653a2063616e6e6f742073656e6420746f206d60448201527f657373656e67657200000000000000000000000000000000000000000000000060648201526084016101f3565b610d7f85858585858080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506117de92505050565b6000610d9c855a8660405180602001604052806000815250611851565b905080610e2b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f5374616e646172644272696467653a20455448207472616e736665722066616960448201527f6c6564000000000000000000000000000000000000000000000000000000000060648201526084016101f3565b505050505050565b6108c987873388888888888080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061186b92505050565b333b15610f07576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20616e20454f4100000000000000000060648201526084016101f3565b610e2b86863333888888888080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250611bb392505050565b6108c987873388888888888080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250611bb392505050565b333b15611020576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20616e20454f4100000000000000000060648201526084016101f3565b610e2b86863333888888888080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061186b92505050565b61050533858585858080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506104f892505050565b6108c98787878787878761050b565b333b15611145576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20616e20454f4100000000000000000060648201526084016101f3565b6109a433338585858080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506104f892505050565b600054600390610100900460ff161580156111a9575060005460ff8083169116105b611235576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a656400000000000000000000000000000000000060648201526084016101f3565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001660ff83161761010017905561126f82611bc2565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff16905560405160ff821681527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050565b6105053385348686868080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061131492505050565b8234146113a3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603e60248201527f5374616e646172644272696467653a206272696467696e6720455448206d757360448201527f7420696e636c7564652073756666696369656e74204554482076616c7565000060648201526084016101f3565b6113af85858584611ca0565b60035460405173ffffffffffffffffffffffffffffffffffffffff90911690633dbb202b9085907f0000000000000000000000000000000000000000000000000000000000000000907f1635f5fd000000000000000000000000000000000000000000000000000000009061142e908b908b9086908a906024016128a1565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009485161790525160e086901b90921682526114c1929188906004016128ea565b6000604051808303818588803b1580156114da57600080fd5b505af11580156114ee573d6000803e3d6000fd5b50505050505050505050565b6000611526827f1d1d8b6300000000000000000000000000000000000000000000000000000000611d13565b806115565750611556827fec4fc8e300000000000000000000000000000000000000000000000000000000611d13565b92915050565b6000611588837f1d1d8b6300000000000000000000000000000000000000000000000000000000611d13565b15611631578273ffffffffffffffffffffffffffffffffffffffff1663c01e1bd66040518163ffffffff1660e01b8152600401602060405180830381865afa1580156115d8573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906115fc919061283e565b73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16149050611556565b8273ffffffffffffffffffffffffffffffffffffffff1663d6c0b2c46040518163ffffffff1660e01b8152600401602060405180830381865afa1580156115d8573d6000803e3d6000fd5b60405173ffffffffffffffffffffffffffffffffffffffff83166024820152604481018290526109a49084907fa9059cbb00000000000000000000000000000000000000000000000000000000906064015b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff0000000000000000000000000000000000000000000000000000000090931692909217909152611d36565b8373ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff167f3ceee06c1e37648fcbb6ed52e17b3e1f275a1f8c7b22a84b2b84732431e046b38686866040516117c89392919061292f565b60405180910390a4610e2b868686868686611e42565b8273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167f2ac69ee804d9a7a0984249f508dfab7cb2534b465b6ce1580f99a38ba9c5e631848460405161183d92919061296d565b60405180910390a361050584848484611eca565b600080600080845160208601878a8af19695505050505050565b611874876114fa565b156119c257611883878761155c565b611935576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604a60248201527f5374616e646172644272696467653a2077726f6e672072656d6f746520746f6b60448201527f656e20666f72204f7074696d69736d204d696e7461626c65204552433230206c60648201527f6f63616c20746f6b656e00000000000000000000000000000000000000000000608482015260a4016101f3565b6040517f9dc29fac00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015260248201859052881690639dc29fac90604401600060405180830381600087803b1580156119a557600080fd5b505af11580156119b9573d6000803e3d6000fd5b50505050611a56565b6119e473ffffffffffffffffffffffffffffffffffffffff8816863086611f37565b73ffffffffffffffffffffffffffffffffffffffff8088166000908152600260209081526040808320938a1683529290522054611a22908490612986565b73ffffffffffffffffffffffffffffffffffffffff8089166000908152600260209081526040808320938b16835292905220555b611a64878787878786611f95565b60035460405173ffffffffffffffffffffffffffffffffffffffff90911690633dbb202b907f0000000000000000000000000000000000000000000000000000000000000000907f0166a07a0000000000000000000000000000000000000000000000000000000090611ae5908b908d908c908c908c908b9060240161299e565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009485161790525160e085901b9092168252611b78929187906004016128ea565b600060405180830381600087803b158015611b9257600080fd5b505af1158015611ba6573d6000803e3d6000fd5b5050505050505050505050565b6108c98787878787878761186b565b600054610100900460ff16611c59576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e6700000000000000000000000000000000000000000060648201526084016101f3565b600380547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b8273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167f35d79ab81f2b2017e19afb5c5571778877782d7a8786f5907f93b0f4702f4f238484604051611cff92919061296d565b60405180910390a361050584848484612023565b6000611d1e83612082565b8015611d2f5750611d2f83836120e6565b9392505050565b6000611d98826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c65648152508573ffffffffffffffffffffffffffffffffffffffff166121b59092919063ffffffff16565b8051909150156109a45780806020019051810190611db691906129f9565b6109a4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e60448201527f6f7420737563636565640000000000000000000000000000000000000000000060648201526084016101f3565b8373ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff167fd59c65b35445225835c83f50b6ede06a7be047d22e357073e250d9af537518cd868686604051611eba9392919061292f565b60405180910390a4505050505050565b8273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167f31b2166ff604fc5672ea5df08a78081d2bc6d746cadce880747f3643d819e83d8484604051611f2992919061296d565b60405180910390a350505050565b60405173ffffffffffffffffffffffffffffffffffffffff808516602483015283166044820152606481018290526105059085907f23b872dd00000000000000000000000000000000000000000000000000000000906084016116ce565b8373ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff167f718594027abd4eaed59f95162563e0cc6d0e8d5b86b1c7be8b1b0ac3343d039686868660405161200d9392919061292f565b60405180910390a4610e2b8686868686866121cc565b8273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167f2849b43074093a05396b6f2a937dee8565b15a48a7b3d4bffb732a5017380af58484604051611f2992919061296d565b60006120ae827f01ffc9a7000000000000000000000000000000000000000000000000000000006120e6565b801561155657506120df827fffffffff000000000000000000000000000000000000000000000000000000006120e6565b1592915050565b604080517fffffffff000000000000000000000000000000000000000000000000000000008316602480830191909152825180830390910181526044909101909152602080820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f01ffc9a700000000000000000000000000000000000000000000000000000000178152825160009392849283928392918391908a617530fa92503d9150600051905082801561219e575060208210155b80156121aa5750600081115b979650505050505050565b60606121c48484600085612244565b949350505050565b8373ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff167f7ff126db8024424bbfd9826e8ab82ff59136289ea440b04b39a0df1b03b9cabf868686604051611eba9392919061292f565b6060824710156122d6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f60448201527f722063616c6c000000000000000000000000000000000000000000000000000060648201526084016101f3565b73ffffffffffffffffffffffffffffffffffffffff85163b612354576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064016101f3565b6000808673ffffffffffffffffffffffffffffffffffffffff16858760405161237d9190612a1b565b60006040518083038185875af1925050503d80600081146123ba576040519150601f19603f3d011682016040523d82523d6000602084013e6123bf565b606091505b50915091506121aa828286606083156123d9575081611d2f565b8251156123e95782518084602001fd5b816040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016101f391906126ef565b73ffffffffffffffffffffffffffffffffffffffff8116811461243f57600080fd5b50565b60008083601f84011261245457600080fd5b50813567ffffffffffffffff81111561246c57600080fd5b60208301915083602082850101111561248457600080fd5b9250929050565b600080600080600080600060c0888a0312156124a657600080fd5b87356124b18161241d565b965060208801356124c18161241d565b955060408801356124d18161241d565b945060608801356124e18161241d565b93506080880135925060a088013567ffffffffffffffff81111561250457600080fd5b6125108a828b01612442565b989b979a50959850939692959293505050565b803563ffffffff8116811461253757600080fd5b919050565b60008060006040848603121561255157600080fd5b61255a84612523565b9250602084013567ffffffffffffffff81111561257657600080fd5b61258286828701612442565b9497909650939450505050565b6000806000806000608086880312156125a757600080fd5b85356125b28161241d565b945060208601356125c28161241d565b935060408601359250606086013567ffffffffffffffff8111156125e557600080fd5b6125f188828901612442565b969995985093965092949392505050565b600080600080600080600060c0888a03121561261d57600080fd5b87356126288161241d565b965060208801356126388161241d565b955060408801356126488161241d565b94506060880135935061265d60808901612523565b925060a088013567ffffffffffffffff81111561250457600080fd5b60005b8381101561269457818101518382015260200161267c565b838111156105055750506000910152565b600081518084526126bd816020860160208601612679565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b602081526000611d2f60208301846126a5565b60008060008060008060a0878903121561271b57600080fd5b86356127268161241d565b955060208701356127368161241d565b94506040870135935061274b60608801612523565b9250608087013567ffffffffffffffff81111561276757600080fd5b61277389828a01612442565b979a9699509497509295939492505050565b6000806040838503121561279857600080fd5b82356127a38161241d565b915060208301356127b38161241d565b809150509250929050565b600080600080606085870312156127d457600080fd5b84356127df8161241d565b93506127ed60208601612523565b9250604085013567ffffffffffffffff81111561280957600080fd5b61281587828801612442565b95989497509550505050565b60006020828403121561283357600080fd5b8135611d2f8161241d565b60006020828403121561285057600080fd5b8151611d2f8161241d565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60008282101561289c5761289c61285b565b500390565b600073ffffffffffffffffffffffffffffffffffffffff8087168352808616602084015250836040830152608060608301526128e060808301846126a5565b9695505050505050565b73ffffffffffffffffffffffffffffffffffffffff8416815260606020820152600061291960608301856126a5565b905063ffffffff83166040830152949350505050565b73ffffffffffffffffffffffffffffffffffffffff8416815282602082015260606040820152600061296460608301846126a5565b95945050505050565b8281526040602082015260006121c460408301846126a5565b600082198211156129995761299961285b565b500190565b600073ffffffffffffffffffffffffffffffffffffffff80891683528088166020840152808716604084015280861660608401525083608083015260c060a08301526129ed60c08301846126a5565b98975050505050505050565b600060208284031215612a0b57600080fd5b81518015158114611d2f57600080fd5b60008251612a2d818460208701612679565b919091019291505056fea164736f6c634300080f000a" +var L1StandardBridgeDeployedBin = "0x6080604052600436106101635760003560e01c806387087623116100c0578063a9f9e67511610074578063c4d66de811610059578063c4d66de8146104c5578063c89701a214610421578063e11013dd146104e557600080fd5b8063a9f9e67514610492578063b1a1a882146104b257600080fd5b806391c49bf8116100a557806391c49bf814610421578063927ede2d146104545780639a2ac6d51461047f57600080fd5b806387087623146103bb5780638f601f66146103db57600080fd5b8063540abf731161011757806358a997f6116100fc57806358a997f6146103475780637f46ddb214610367578063838b25201461039b57600080fd5b8063540abf73146102d157806354fd4d50146102f157600080fd5b80631532ec34116101485780631532ec34146102545780631635f5fd146102675780633cb747bf1461027a57600080fd5b80630166a07a1461022157806309fc88431461024157600080fd5b3661021c57333b156101fc576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20616e20454f4100000000000000000060648201526084015b60405180910390fd5b61021a333362030d40604051806020016040528060008152506104f8565b005b600080fd5b34801561022d57600080fd5b5061021a61023c36600461248b565b61050b565b61021a61024f36600461253c565b6108d2565b61021a61026236600461258f565b6109a9565b61021a61027536600461258f565b6109bd565b34801561028657600080fd5b506003546102a79073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b3480156102dd57600080fd5b5061021a6102ec366004612602565b610e33565b3480156102fd57600080fd5b5061033a6040518060400160405280600581526020017f312e342e3100000000000000000000000000000000000000000000000000000081525081565b6040516102c891906126ef565b34801561035357600080fd5b5061021a610362366004612702565b610e78565b34801561037357600080fd5b506102a77f000000000000000000000000000000000000000000000000000000000000000081565b3480156103a757600080fd5b5061021a6103b6366004612602565b610f4c565b3480156103c757600080fd5b5061021a6103d6366004612702565b610f91565b3480156103e757600080fd5b506104136103f6366004612785565b600260209081526000928352604080842090915290825290205481565b6040519081526020016102c8565b34801561042d57600080fd5b507f00000000000000000000000000000000000000000000000000000000000000006102a7565b34801561046057600080fd5b5060035473ffffffffffffffffffffffffffffffffffffffff166102a7565b61021a61048d3660046127be565b611065565b34801561049e57600080fd5b5061021a6104ad36600461248b565b6110a7565b61021a6104c036600461253c565b6110b6565b3480156104d157600080fd5b5061021a6104e0366004612821565b611187565b61021a6104f33660046127be565b6112d1565b6105058484348585611314565b50505050565b60035473ffffffffffffffffffffffffffffffffffffffff16331480156105fa5750600354604080517f6e296e45000000000000000000000000000000000000000000000000000000008152905173ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000008116931691636e296e459160048083019260209291908290030181865afa1580156105be573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906105e2919061283e565b73ffffffffffffffffffffffffffffffffffffffff16145b6106ac576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604160248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20746865206f7468657220627269646760648201527f6500000000000000000000000000000000000000000000000000000000000000608482015260a4016101f3565b6106b5876114fa565b15610803576106c4878761155c565b610776576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604a60248201527f5374616e646172644272696467653a2077726f6e672072656d6f746520746f6b60448201527f656e20666f72204f7074696d69736d204d696e7461626c65204552433230206c60648201527f6f63616c20746f6b656e00000000000000000000000000000000000000000000608482015260a4016101f3565b6040517f40c10f1900000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8581166004830152602482018590528816906340c10f1990604401600060405180830381600087803b1580156107e657600080fd5b505af11580156107fa573d6000803e3d6000fd5b50505050610885565b73ffffffffffffffffffffffffffffffffffffffff8088166000908152600260209081526040808320938a168352929052205461084190849061288a565b73ffffffffffffffffffffffffffffffffffffffff8089166000818152600260209081526040808320948c168352939052919091209190915561088590858561167c565b6108c9878787878787878080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061175092505050565b50505050505050565b333b15610961576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20616e20454f4100000000000000000060648201526084016101f3565b6109a43333348686868080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061131492505050565b505050565b6109b685858585856109bd565b5050505050565b60035473ffffffffffffffffffffffffffffffffffffffff1633148015610aac5750600354604080517f6e296e45000000000000000000000000000000000000000000000000000000008152905173ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000008116931691636e296e459160048083019260209291908290030181865afa158015610a70573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a94919061283e565b73ffffffffffffffffffffffffffffffffffffffff16145b610b5e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604160248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20746865206f7468657220627269646760648201527f6500000000000000000000000000000000000000000000000000000000000000608482015260a4016101f3565b823414610bed576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603a60248201527f5374616e646172644272696467653a20616d6f756e742073656e7420646f657360448201527f206e6f74206d6174636820616d6f756e7420726571756972656400000000000060648201526084016101f3565b3073ffffffffffffffffffffffffffffffffffffffff851603610c92576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f5374616e646172644272696467653a2063616e6e6f742073656e6420746f207360448201527f656c66000000000000000000000000000000000000000000000000000000000060648201526084016101f3565b60035473ffffffffffffffffffffffffffffffffffffffff90811690851603610d3d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602860248201527f5374616e646172644272696467653a2063616e6e6f742073656e6420746f206d60448201527f657373656e67657200000000000000000000000000000000000000000000000060648201526084016101f3565b610d7f85858585858080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506117de92505050565b6000610d9c855a8660405180602001604052806000815250611851565b905080610e2b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f5374616e646172644272696467653a20455448207472616e736665722066616960448201527f6c6564000000000000000000000000000000000000000000000000000000000060648201526084016101f3565b505050505050565b6108c987873388888888888080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061186b92505050565b333b15610f07576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20616e20454f4100000000000000000060648201526084016101f3565b610e2b86863333888888888080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250611bb392505050565b6108c987873388888888888080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250611bb392505050565b333b15611020576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20616e20454f4100000000000000000060648201526084016101f3565b610e2b86863333888888888080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061186b92505050565b61050533858585858080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506104f892505050565b6108c98787878787878761050b565b333b15611145576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20616e20454f4100000000000000000060648201526084016101f3565b6109a433338585858080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506104f892505050565b600054600390610100900460ff161580156111a9575060005460ff8083169116105b611235576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a656400000000000000000000000000000000000060648201526084016101f3565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001660ff83161761010017905561126f82611bc2565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff16905560405160ff821681527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050565b6105053385348686868080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061131492505050565b8234146113a3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603e60248201527f5374616e646172644272696467653a206272696467696e6720455448206d757360448201527f7420696e636c7564652073756666696369656e74204554482076616c7565000060648201526084016101f3565b6113af85858584611ca0565b60035460405173ffffffffffffffffffffffffffffffffffffffff90911690633dbb202b9085907f0000000000000000000000000000000000000000000000000000000000000000907f1635f5fd000000000000000000000000000000000000000000000000000000009061142e908b908b9086908a906024016128a1565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009485161790525160e086901b90921682526114c1929188906004016128ea565b6000604051808303818588803b1580156114da57600080fd5b505af11580156114ee573d6000803e3d6000fd5b50505050505050505050565b6000611526827f1d1d8b6300000000000000000000000000000000000000000000000000000000611d13565b806115565750611556827fec4fc8e300000000000000000000000000000000000000000000000000000000611d13565b92915050565b6000611588837f1d1d8b6300000000000000000000000000000000000000000000000000000000611d13565b15611631578273ffffffffffffffffffffffffffffffffffffffff1663c01e1bd66040518163ffffffff1660e01b8152600401602060405180830381865afa1580156115d8573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906115fc919061283e565b73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16149050611556565b8273ffffffffffffffffffffffffffffffffffffffff1663d6c0b2c46040518163ffffffff1660e01b8152600401602060405180830381865afa1580156115d8573d6000803e3d6000fd5b60405173ffffffffffffffffffffffffffffffffffffffff83166024820152604481018290526109a49084907fa9059cbb00000000000000000000000000000000000000000000000000000000906064015b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff0000000000000000000000000000000000000000000000000000000090931692909217909152611d36565b8373ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff167f3ceee06c1e37648fcbb6ed52e17b3e1f275a1f8c7b22a84b2b84732431e046b38686866040516117c89392919061292f565b60405180910390a4610e2b868686868686611e42565b8273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167f2ac69ee804d9a7a0984249f508dfab7cb2534b465b6ce1580f99a38ba9c5e631848460405161183d92919061296d565b60405180910390a361050584848484611eca565b600080600080845160208601878a8af19695505050505050565b611874876114fa565b156119c257611883878761155c565b611935576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604a60248201527f5374616e646172644272696467653a2077726f6e672072656d6f746520746f6b60448201527f656e20666f72204f7074696d69736d204d696e7461626c65204552433230206c60648201527f6f63616c20746f6b656e00000000000000000000000000000000000000000000608482015260a4016101f3565b6040517f9dc29fac00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015260248201859052881690639dc29fac90604401600060405180830381600087803b1580156119a557600080fd5b505af11580156119b9573d6000803e3d6000fd5b50505050611a56565b6119e473ffffffffffffffffffffffffffffffffffffffff8816863086611f37565b73ffffffffffffffffffffffffffffffffffffffff8088166000908152600260209081526040808320938a1683529290522054611a22908490612986565b73ffffffffffffffffffffffffffffffffffffffff8089166000908152600260209081526040808320938b16835292905220555b611a64878787878786611f95565b60035460405173ffffffffffffffffffffffffffffffffffffffff90911690633dbb202b907f0000000000000000000000000000000000000000000000000000000000000000907f0166a07a0000000000000000000000000000000000000000000000000000000090611ae5908b908d908c908c908c908b9060240161299e565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009485161790525160e085901b9092168252611b78929187906004016128ea565b600060405180830381600087803b158015611b9257600080fd5b505af1158015611ba6573d6000803e3d6000fd5b5050505050505050505050565b6108c98787878787878761186b565b600054610100900460ff16611c59576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e6700000000000000000000000000000000000000000060648201526084016101f3565b600380547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b8273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167f35d79ab81f2b2017e19afb5c5571778877782d7a8786f5907f93b0f4702f4f238484604051611cff92919061296d565b60405180910390a361050584848484612023565b6000611d1e83612082565b8015611d2f5750611d2f83836120e6565b9392505050565b6000611d98826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c65648152508573ffffffffffffffffffffffffffffffffffffffff166121b59092919063ffffffff16565b8051909150156109a45780806020019051810190611db691906129f9565b6109a4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e60448201527f6f7420737563636565640000000000000000000000000000000000000000000060648201526084016101f3565b8373ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff167fd59c65b35445225835c83f50b6ede06a7be047d22e357073e250d9af537518cd868686604051611eba9392919061292f565b60405180910390a4505050505050565b8273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167f31b2166ff604fc5672ea5df08a78081d2bc6d746cadce880747f3643d819e83d8484604051611f2992919061296d565b60405180910390a350505050565b60405173ffffffffffffffffffffffffffffffffffffffff808516602483015283166044820152606481018290526105059085907f23b872dd00000000000000000000000000000000000000000000000000000000906084016116ce565b8373ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff167f718594027abd4eaed59f95162563e0cc6d0e8d5b86b1c7be8b1b0ac3343d039686868660405161200d9392919061292f565b60405180910390a4610e2b8686868686866121cc565b8273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167f2849b43074093a05396b6f2a937dee8565b15a48a7b3d4bffb732a5017380af58484604051611f2992919061296d565b60006120ae827f01ffc9a7000000000000000000000000000000000000000000000000000000006120e6565b801561155657506120df827fffffffff000000000000000000000000000000000000000000000000000000006120e6565b1592915050565b604080517fffffffff000000000000000000000000000000000000000000000000000000008316602480830191909152825180830390910181526044909101909152602080820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f01ffc9a700000000000000000000000000000000000000000000000000000000178152825160009392849283928392918391908a617530fa92503d9150600051905082801561219e575060208210155b80156121aa5750600081115b979650505050505050565b60606121c48484600085612244565b949350505050565b8373ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff167f7ff126db8024424bbfd9826e8ab82ff59136289ea440b04b39a0df1b03b9cabf868686604051611eba9392919061292f565b6060824710156122d6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f60448201527f722063616c6c000000000000000000000000000000000000000000000000000060648201526084016101f3565b73ffffffffffffffffffffffffffffffffffffffff85163b612354576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064016101f3565b6000808673ffffffffffffffffffffffffffffffffffffffff16858760405161237d9190612a1b565b60006040518083038185875af1925050503d80600081146123ba576040519150601f19603f3d011682016040523d82523d6000602084013e6123bf565b606091505b50915091506121aa828286606083156123d9575081611d2f565b8251156123e95782518084602001fd5b816040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016101f391906126ef565b73ffffffffffffffffffffffffffffffffffffffff8116811461243f57600080fd5b50565b60008083601f84011261245457600080fd5b50813567ffffffffffffffff81111561246c57600080fd5b60208301915083602082850101111561248457600080fd5b9250929050565b600080600080600080600060c0888a0312156124a657600080fd5b87356124b18161241d565b965060208801356124c18161241d565b955060408801356124d18161241d565b945060608801356124e18161241d565b93506080880135925060a088013567ffffffffffffffff81111561250457600080fd5b6125108a828b01612442565b989b979a50959850939692959293505050565b803563ffffffff8116811461253757600080fd5b919050565b60008060006040848603121561255157600080fd5b61255a84612523565b9250602084013567ffffffffffffffff81111561257657600080fd5b61258286828701612442565b9497909650939450505050565b6000806000806000608086880312156125a757600080fd5b85356125b28161241d565b945060208601356125c28161241d565b935060408601359250606086013567ffffffffffffffff8111156125e557600080fd5b6125f188828901612442565b969995985093965092949392505050565b600080600080600080600060c0888a03121561261d57600080fd5b87356126288161241d565b965060208801356126388161241d565b955060408801356126488161241d565b94506060880135935061265d60808901612523565b925060a088013567ffffffffffffffff81111561250457600080fd5b60005b8381101561269457818101518382015260200161267c565b838111156105055750506000910152565b600081518084526126bd816020860160208601612679565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b602081526000611d2f60208301846126a5565b60008060008060008060a0878903121561271b57600080fd5b86356127268161241d565b955060208701356127368161241d565b94506040870135935061274b60608801612523565b9250608087013567ffffffffffffffff81111561276757600080fd5b61277389828a01612442565b979a9699509497509295939492505050565b6000806040838503121561279857600080fd5b82356127a38161241d565b915060208301356127b38161241d565b809150509250929050565b600080600080606085870312156127d457600080fd5b84356127df8161241d565b93506127ed60208601612523565b9250604085013567ffffffffffffffff81111561280957600080fd5b61281587828801612442565b95989497509550505050565b60006020828403121561283357600080fd5b8135611d2f8161241d565b60006020828403121561285057600080fd5b8151611d2f8161241d565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60008282101561289c5761289c61285b565b500390565b600073ffffffffffffffffffffffffffffffffffffffff8087168352808616602084015250836040830152608060608301526128e060808301846126a5565b9695505050505050565b73ffffffffffffffffffffffffffffffffffffffff8416815260606020820152600061291960608301856126a5565b905063ffffffff83166040830152949350505050565b73ffffffffffffffffffffffffffffffffffffffff8416815282602082015260606040820152600061296460608301846126a5565b95945050505050565b8281526040602082015260006121c460408301846126a5565b600082198211156129995761299961285b565b500190565b600073ffffffffffffffffffffffffffffffffffffffff80891683528088166020840152808716604084015280861660608401525083608083015260c060a08301526129ed60c08301846126a5565b98975050505050505050565b600060208284031215612a0b57600080fd5b81518015158114611d2f57600080fd5b60008251612a2d818460208701612679565b919091019291505056fea164736f6c634300080f000a" func init() { if err := json.Unmarshal([]byte(L1StandardBridgeStorageLayoutJSON), L1StandardBridgeStorageLayout); err != nil { diff --git a/op-bindings/bindings/l2crossdomainmessenger.go b/op-bindings/bindings/l2crossdomainmessenger.go index 26bc69cfd2391..8c7a5d6236e1c 100644 --- a/op-bindings/bindings/l2crossdomainmessenger.go +++ b/op-bindings/bindings/l2crossdomainmessenger.go @@ -31,7 +31,7 @@ var ( // L2CrossDomainMessengerMetaData contains all meta data concerning the L2CrossDomainMessenger contract. var L2CrossDomainMessengerMetaData = &bind.MetaData{ ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_l1CrossDomainMessenger\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"msgHash\",\"type\":\"bytes32\"}],\"name\":\"FailedRelayedMessage\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"version\",\"type\":\"uint8\"}],\"name\":\"Initialized\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"msgHash\",\"type\":\"bytes32\"}],\"name\":\"RelayedMessage\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"message\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"messageNonce\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"}],\"name\":\"SentMessage\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"SentMessageExtension1\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MESSAGE_VERSION\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MIN_GAS_CALLDATA_OVERHEAD\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MIN_GAS_DYNAMIC_OVERHEAD_DENOMINATOR\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MIN_GAS_DYNAMIC_OVERHEAD_NUMERATOR\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"OTHER_MESSENGER\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"RELAY_CALL_OVERHEAD\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"RELAY_CONSTANT_OVERHEAD\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"RELAY_GAS_CHECK_BUFFER\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"RELAY_RESERVED_GAS\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"_message\",\"type\":\"bytes\"},{\"internalType\":\"uint32\",\"name\":\"_minGasLimit\",\"type\":\"uint32\"}],\"name\":\"baseGas\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"failedMessages\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"initialize\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"l1CrossDomainMessenger\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"messageNonce\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_nonce\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"_sender\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_target\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_value\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_minGasLimit\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"_message\",\"type\":\"bytes\"}],\"name\":\"relayMessage\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_target\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"_message\",\"type\":\"bytes\"},{\"internalType\":\"uint32\",\"name\":\"_minGasLimit\",\"type\":\"uint32\"}],\"name\":\"sendMessage\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"successfulMessages\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"version\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"xDomainMessageSender\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", - Bin: "0x60a06040523480156200001157600080fd5b5060405162001db738038062001db78339810160408190526200003491620001e4565b6001600160a01b0381166080526200004b62000052565b5062000216565b600054600290600160a81b900460ff161580156200007e575060005460ff808316600160a01b90920416105b620000e75760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084015b60405180910390fd5b6000805460ff60a81b1960ff8416600160a01b021661ffff60a01b1990911617600160a81b179055620001196200015f565b6000805460ff60a81b1916905560405160ff821681527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a150565b600054600160a81b900460ff16620001ce5760405162461bcd60e51b815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201526a6e697469616c697a696e6760a81b6064820152608401620000de565b60cc80546001600160a01b03191661dead179055565b600060208284031215620001f757600080fd5b81516001600160a01b03811681146200020f57600080fd5b9392505050565b608051611b7062000247600039600081816102dd0152818161034e0152818161043f0152610bef0152611b706000f3fe6080604052600436106101445760003560e01c80638129fc1c116100c0578063a711986911610074578063b28ade2511610059578063b28ade25146103a2578063d764ad0b146103c2578063ecc70428146103d557600080fd5b8063a71198691461033f578063b1b1b2091461037257600080fd5b80638cbeeef2116100a55780638cbeeef2146101e35780639fce812c146102cb578063a4e7f8bd146102ff57600080fd5b80638129fc1c1461029f57806383a74074146102b457600080fd5b80633f827a5a1161011757806354fd4d50116100fc57806354fd4d50146101f95780635644cfdf1461024f5780636e296e451461026557600080fd5b80633f827a5a146101bb5780634c1d6a69146101e357600080fd5b8063028f85f7146101495780630c5684981461017c5780632828d7e8146101915780633dbb202b146101a6575b600080fd5b34801561015557600080fd5b5061015e601081565b60405167ffffffffffffffff90911681526020015b60405180910390f35b34801561018857600080fd5b5061015e603f81565b34801561019d57600080fd5b5061015e604081565b6101b96101b436600461168c565b61043a565b005b3480156101c757600080fd5b506101d0600181565b60405161ffff9091168152602001610173565b3480156101ef57600080fd5b5061015e619c4081565b34801561020557600080fd5b506102426040518060400160405280600581526020017f312e362e3000000000000000000000000000000000000000000000000000000081525081565b604051610173919061175c565b34801561025b57600080fd5b5061015e61138881565b34801561027157600080fd5b5061027a61069e565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610173565b3480156102ab57600080fd5b506101b961078a565b3480156102c057600080fd5b5061015e62030d4081565b3480156102d757600080fd5b5061027a7f000000000000000000000000000000000000000000000000000000000000000081565b34801561030b57600080fd5b5061032f61031a366004611776565b60ce6020526000908152604090205460ff1681565b6040519015158152602001610173565b34801561034b57600080fd5b507f000000000000000000000000000000000000000000000000000000000000000061027a565b34801561037e57600080fd5b5061032f61038d366004611776565b60cb6020526000908152604090205460ff1681565b3480156103ae57600080fd5b5061015e6103bd36600461178f565b61094d565b6101b96103d03660046117e3565b6109bb565b3480156103e157600080fd5b5061042c60cd547dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e010000000000000000000000000000000000000000000000000000000000001790565b604051908152602001610173565b6105737f000000000000000000000000000000000000000000000000000000000000000061046985858561094d565b347fd764ad0b000000000000000000000000000000000000000000000000000000006104d560cd547dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e010000000000000000000000000000000000000000000000000000000000001790565b338a34898c8c6040516024016104f197969594939291906118ae565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff0000000000000000000000000000000000000000000000000000000090931692909217909152611298565b8373ffffffffffffffffffffffffffffffffffffffff167fcb0f7ffd78f9aee47a248fae8db181db6eee833039123e026dcbff529522e52a3385856105f860cd547dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e010000000000000000000000000000000000000000000000000000000000001790565b8660405161060a95949392919061190d565b60405180910390a260405134815233907f8ebb2ec2465bdb2a06a66fc37a0963af8a2a6a1479d81d56fdb8cbb98096d5469060200160405180910390a2505060cd80547dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff808216600101167fffff0000000000000000000000000000000000000000000000000000000000009091161790555050565b60cc5460009073ffffffffffffffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff21530161076d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603560248201527f43726f7373446f6d61696e4d657373656e6765723a2078446f6d61696e4d657360448201527f7361676553656e646572206973206e6f7420736574000000000000000000000060648201526084015b60405180910390fd5b5060cc5473ffffffffffffffffffffffffffffffffffffffff1690565b6000546002907501000000000000000000000000000000000000000000900460ff161580156107d8575060005460ff8083167401000000000000000000000000000000000000000090920416105b610864576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a65640000000000000000000000000000000000006064820152608401610764565b600080547fffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff60ff84167401000000000000000000000000000000000000000002167fffffffffffffffffffff0000ffffffffffffffffffffffffffffffffffffffff9091161775010000000000000000000000000000000000000000001790556108ec611326565b600080547fffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff16905560405160ff821681527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a150565b6000611388619c4080603f610969604063ffffffff881661198a565b61097391906119ba565b61097e60108861198a565b61098b9062030d40611a08565b6109959190611a08565b61099f9190611a08565b6109a99190611a08565b6109b39190611a08565b949350505050565b60f087901c60028110610a76576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604d60248201527f43726f7373446f6d61696e4d657373656e6765723a206f6e6c7920766572736960448201527f6f6e2030206f722031206d657373616765732061726520737570706f7274656460648201527f20617420746869732074696d6500000000000000000000000000000000000000608482015260a401610764565b8061ffff16600003610b6b576000610ac7878986868080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508f92506113ff915050565b600081815260cb602052604090205490915060ff1615610b69576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f43726f7373446f6d61696e4d657373656e6765723a206c65676163792077697460448201527f6864726177616c20616c72656164792072656c617965640000000000000000006064820152608401610764565b505b6000610bb1898989898989898080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061141e92505050565b905073ffffffffffffffffffffffffffffffffffffffff7fffffffffffffffffffffffffeeeeffffffffffffffffffffffffffffffffeeef330181167f000000000000000000000000000000000000000000000000000000000000000090911603610c4957853414610c2557610c25611a34565b600081815260ce602052604090205460ff1615610c4457610c44611a34565b610d9b565b3415610cfd576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152605060248201527f43726f7373446f6d61696e4d657373656e6765723a2076616c7565206d75737460448201527f206265207a65726f20756e6c657373206d6573736167652069732066726f6d2060648201527f612073797374656d206164647265737300000000000000000000000000000000608482015260a401610764565b600081815260ce602052604090205460ff16610d9b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603060248201527f43726f7373446f6d61696e4d657373656e6765723a206d65737361676520636160448201527f6e6e6f74206265207265706c61796564000000000000000000000000000000006064820152608401610764565b610da487611441565b15610e57576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604360248201527f43726f7373446f6d61696e4d657373656e6765723a2063616e6e6f742073656e60448201527f64206d65737361676520746f20626c6f636b65642073797374656d206164647260648201527f6573730000000000000000000000000000000000000000000000000000000000608482015260a401610764565b600081815260cb602052604090205460ff1615610ef6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603660248201527f43726f7373446f6d61696e4d657373656e6765723a206d65737361676520686160448201527f7320616c7265616479206265656e2072656c61796564000000000000000000006064820152608401610764565b610f1785610f08611388619c40611a08565b67ffffffffffffffff16611496565b1580610f3d575060cc5473ffffffffffffffffffffffffffffffffffffffff1661dead14155b1561105657600081815260ce602052604080822080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790555182917f99d0e048484baa1b1540b1367cb128acd7ab2946d1ed91ec10e3c85e4bf51b8f91a27fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff320161104f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602d60248201527f43726f7373446f6d61696e4d657373656e6765723a206661696c656420746f2060448201527f72656c6179206d657373616765000000000000000000000000000000000000006064820152608401610764565b505061128f565b60cc80547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff8a1617905560006110e788619c405a6110aa9190611a63565b8988888080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506114b492505050565b60cc80547fffffffffffffffffffffffff00000000000000000000000000000000000000001661dead1790559050801561117e57600082815260cb602052604080822080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790555183917f4641df4a962071e12719d8c8c8e5ac7fc4d97b927346a3d7a335b1f7517e133c91a261128b565b600082815260ce602052604080822080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790555183917f99d0e048484baa1b1540b1367cb128acd7ab2946d1ed91ec10e3c85e4bf51b8f91a27fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff320161128b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602d60248201527f43726f7373446f6d61696e4d657373656e6765723a206661696c656420746f2060448201527f72656c6179206d657373616765000000000000000000000000000000000000006064820152608401610764565b5050505b50505050505050565b6040517fc2b3e5ac0000000000000000000000000000000000000000000000000000000081527342000000000000000000000000000000000000169063c2b3e5ac9084906112ee90889088908790600401611a7a565b6000604051808303818588803b15801561130757600080fd5b505af115801561131b573d6000803e3d6000fd5b505050505050505050565b6000547501000000000000000000000000000000000000000000900460ff166113d1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e670000000000000000000000000000000000000000006064820152608401610764565b60cc80547fffffffffffffffffffffffff00000000000000000000000000000000000000001661dead179055565b600061140d858585856114ce565b805190602001209050949350505050565b600061142e878787878787611567565b8051906020012090509695505050505050565b600073ffffffffffffffffffffffffffffffffffffffff8216301480611490575073ffffffffffffffffffffffffffffffffffffffff8216734200000000000000000000000000000000000016145b92915050565b600080603f83619c4001026040850201603f5a021015949350505050565b600080600080845160208601878a8af19695505050505050565b6060848484846040516024016114e79493929190611ac2565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fcbd4ece9000000000000000000000000000000000000000000000000000000001790529050949350505050565b606086868686868660405160240161158496959493929190611b0c565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fd764ad0b0000000000000000000000000000000000000000000000000000000017905290509695505050505050565b803573ffffffffffffffffffffffffffffffffffffffff8116811461162a57600080fd5b919050565b60008083601f84011261164157600080fd5b50813567ffffffffffffffff81111561165957600080fd5b60208301915083602082850101111561167157600080fd5b9250929050565b803563ffffffff8116811461162a57600080fd5b600080600080606085870312156116a257600080fd5b6116ab85611606565b9350602085013567ffffffffffffffff8111156116c757600080fd5b6116d38782880161162f565b90945092506116e6905060408601611678565b905092959194509250565b6000815180845260005b81811015611717576020818501810151868301820152016116fb565b81811115611729576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60208152600061176f60208301846116f1565b9392505050565b60006020828403121561178857600080fd5b5035919050565b6000806000604084860312156117a457600080fd5b833567ffffffffffffffff8111156117bb57600080fd5b6117c78682870161162f565b90945092506117da905060208501611678565b90509250925092565b600080600080600080600060c0888a0312156117fe57600080fd5b8735965061180e60208901611606565b955061181c60408901611606565b9450606088013593506080880135925060a088013567ffffffffffffffff81111561184657600080fd5b6118528a828b0161162f565b989b979a50959850939692959293505050565b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b878152600073ffffffffffffffffffffffffffffffffffffffff808916602084015280881660408401525085606083015263ffffffff8516608083015260c060a083015261190060c083018486611865565b9998505050505050505050565b73ffffffffffffffffffffffffffffffffffffffff8616815260806020820152600061193d608083018688611865565b905083604083015263ffffffff831660608301529695505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600067ffffffffffffffff808316818516818304811182151516156119b1576119b161195b565b02949350505050565b600067ffffffffffffffff808416806119fc577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b92169190910492915050565b600067ffffffffffffffff808316818516808303821115611a2b57611a2b61195b565b01949350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052600160045260246000fd5b600082821015611a7557611a7561195b565b500390565b73ffffffffffffffffffffffffffffffffffffffff8416815267ffffffffffffffff83166020820152606060408201526000611ab960608301846116f1565b95945050505050565b600073ffffffffffffffffffffffffffffffffffffffff808716835280861660208401525060806040830152611afb60808301856116f1565b905082606083015295945050505050565b868152600073ffffffffffffffffffffffffffffffffffffffff808816602084015280871660408401525084606083015283608083015260c060a0830152611b5760c08301846116f1565b9897505050505050505056fea164736f6c634300080f000a", + Bin: "0x60a06040523480156200001157600080fd5b5060405162001db738038062001db78339810160408190526200003491620001e4565b6001600160a01b0381166080526200004b62000052565b5062000216565b600054600390600160a81b900460ff161580156200007e575060005460ff808316600160a01b90920416105b620000e75760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084015b60405180910390fd5b6000805460ff60a81b1960ff8416600160a01b021661ffff60a01b1990911617600160a81b179055620001196200015f565b6000805460ff60a81b1916905560405160ff821681527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a150565b600054600160a81b900460ff16620001ce5760405162461bcd60e51b815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201526a6e697469616c697a696e6760a81b6064820152608401620000de565b60cc80546001600160a01b03191661dead179055565b600060208284031215620001f757600080fd5b81516001600160a01b03811681146200020f57600080fd5b9392505050565b608051611b7062000247600039600081816102dd0152818161034e0152818161043f0152610bef0152611b706000f3fe6080604052600436106101445760003560e01c80638129fc1c116100c0578063a711986911610074578063b28ade2511610059578063b28ade25146103a2578063d764ad0b146103c2578063ecc70428146103d557600080fd5b8063a71198691461033f578063b1b1b2091461037257600080fd5b80638cbeeef2116100a55780638cbeeef2146101e35780639fce812c146102cb578063a4e7f8bd146102ff57600080fd5b80638129fc1c1461029f57806383a74074146102b457600080fd5b80633f827a5a1161011757806354fd4d50116100fc57806354fd4d50146101f95780635644cfdf1461024f5780636e296e451461026557600080fd5b80633f827a5a146101bb5780634c1d6a69146101e357600080fd5b8063028f85f7146101495780630c5684981461017c5780632828d7e8146101915780633dbb202b146101a6575b600080fd5b34801561015557600080fd5b5061015e601081565b60405167ffffffffffffffff90911681526020015b60405180910390f35b34801561018857600080fd5b5061015e603f81565b34801561019d57600080fd5b5061015e604081565b6101b96101b436600461168c565b61043a565b005b3480156101c757600080fd5b506101d0600181565b60405161ffff9091168152602001610173565b3480156101ef57600080fd5b5061015e619c4081565b34801561020557600080fd5b506102426040518060400160405280600581526020017f312e372e3000000000000000000000000000000000000000000000000000000081525081565b604051610173919061175c565b34801561025b57600080fd5b5061015e61138881565b34801561027157600080fd5b5061027a61069e565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610173565b3480156102ab57600080fd5b506101b961078a565b3480156102c057600080fd5b5061015e62030d4081565b3480156102d757600080fd5b5061027a7f000000000000000000000000000000000000000000000000000000000000000081565b34801561030b57600080fd5b5061032f61031a366004611776565b60ce6020526000908152604090205460ff1681565b6040519015158152602001610173565b34801561034b57600080fd5b507f000000000000000000000000000000000000000000000000000000000000000061027a565b34801561037e57600080fd5b5061032f61038d366004611776565b60cb6020526000908152604090205460ff1681565b3480156103ae57600080fd5b5061015e6103bd36600461178f565b61094d565b6101b96103d03660046117e3565b6109bb565b3480156103e157600080fd5b5061042c60cd547dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e010000000000000000000000000000000000000000000000000000000000001790565b604051908152602001610173565b6105737f000000000000000000000000000000000000000000000000000000000000000061046985858561094d565b347fd764ad0b000000000000000000000000000000000000000000000000000000006104d560cd547dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e010000000000000000000000000000000000000000000000000000000000001790565b338a34898c8c6040516024016104f197969594939291906118ae565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff0000000000000000000000000000000000000000000000000000000090931692909217909152611298565b8373ffffffffffffffffffffffffffffffffffffffff167fcb0f7ffd78f9aee47a248fae8db181db6eee833039123e026dcbff529522e52a3385856105f860cd547dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e010000000000000000000000000000000000000000000000000000000000001790565b8660405161060a95949392919061190d565b60405180910390a260405134815233907f8ebb2ec2465bdb2a06a66fc37a0963af8a2a6a1479d81d56fdb8cbb98096d5469060200160405180910390a2505060cd80547dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff808216600101167fffff0000000000000000000000000000000000000000000000000000000000009091161790555050565b60cc5460009073ffffffffffffffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff21530161076d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603560248201527f43726f7373446f6d61696e4d657373656e6765723a2078446f6d61696e4d657360448201527f7361676553656e646572206973206e6f7420736574000000000000000000000060648201526084015b60405180910390fd5b5060cc5473ffffffffffffffffffffffffffffffffffffffff1690565b6000546003907501000000000000000000000000000000000000000000900460ff161580156107d8575060005460ff8083167401000000000000000000000000000000000000000090920416105b610864576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a65640000000000000000000000000000000000006064820152608401610764565b600080547fffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff60ff84167401000000000000000000000000000000000000000002167fffffffffffffffffffff0000ffffffffffffffffffffffffffffffffffffffff9091161775010000000000000000000000000000000000000000001790556108ec611326565b600080547fffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff16905560405160ff821681527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a150565b6000611388619c4080603f610969604063ffffffff881661198a565b61097391906119ba565b61097e60108861198a565b61098b9062030d40611a08565b6109959190611a08565b61099f9190611a08565b6109a99190611a08565b6109b39190611a08565b949350505050565b60f087901c60028110610a76576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604d60248201527f43726f7373446f6d61696e4d657373656e6765723a206f6e6c7920766572736960448201527f6f6e2030206f722031206d657373616765732061726520737570706f7274656460648201527f20617420746869732074696d6500000000000000000000000000000000000000608482015260a401610764565b8061ffff16600003610b6b576000610ac7878986868080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508f92506113ff915050565b600081815260cb602052604090205490915060ff1615610b69576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f43726f7373446f6d61696e4d657373656e6765723a206c65676163792077697460448201527f6864726177616c20616c72656164792072656c617965640000000000000000006064820152608401610764565b505b6000610bb1898989898989898080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061141e92505050565b905073ffffffffffffffffffffffffffffffffffffffff7fffffffffffffffffffffffffeeeeffffffffffffffffffffffffffffffffeeef330181167f000000000000000000000000000000000000000000000000000000000000000090911603610c4957853414610c2557610c25611a34565b600081815260ce602052604090205460ff1615610c4457610c44611a34565b610d9b565b3415610cfd576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152605060248201527f43726f7373446f6d61696e4d657373656e6765723a2076616c7565206d75737460448201527f206265207a65726f20756e6c657373206d6573736167652069732066726f6d2060648201527f612073797374656d206164647265737300000000000000000000000000000000608482015260a401610764565b600081815260ce602052604090205460ff16610d9b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603060248201527f43726f7373446f6d61696e4d657373656e6765723a206d65737361676520636160448201527f6e6e6f74206265207265706c61796564000000000000000000000000000000006064820152608401610764565b610da487611441565b15610e57576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604360248201527f43726f7373446f6d61696e4d657373656e6765723a2063616e6e6f742073656e60448201527f64206d65737361676520746f20626c6f636b65642073797374656d206164647260648201527f6573730000000000000000000000000000000000000000000000000000000000608482015260a401610764565b600081815260cb602052604090205460ff1615610ef6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603660248201527f43726f7373446f6d61696e4d657373656e6765723a206d65737361676520686160448201527f7320616c7265616479206265656e2072656c61796564000000000000000000006064820152608401610764565b610f1785610f08611388619c40611a08565b67ffffffffffffffff16611496565b1580610f3d575060cc5473ffffffffffffffffffffffffffffffffffffffff1661dead14155b1561105657600081815260ce602052604080822080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790555182917f99d0e048484baa1b1540b1367cb128acd7ab2946d1ed91ec10e3c85e4bf51b8f91a27fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff320161104f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602d60248201527f43726f7373446f6d61696e4d657373656e6765723a206661696c656420746f2060448201527f72656c6179206d657373616765000000000000000000000000000000000000006064820152608401610764565b505061128f565b60cc80547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff8a1617905560006110e788619c405a6110aa9190611a63565b8988888080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506114b492505050565b60cc80547fffffffffffffffffffffffff00000000000000000000000000000000000000001661dead1790559050801561117e57600082815260cb602052604080822080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790555183917f4641df4a962071e12719d8c8c8e5ac7fc4d97b927346a3d7a335b1f7517e133c91a261128b565b600082815260ce602052604080822080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790555183917f99d0e048484baa1b1540b1367cb128acd7ab2946d1ed91ec10e3c85e4bf51b8f91a27fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff320161128b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602d60248201527f43726f7373446f6d61696e4d657373656e6765723a206661696c656420746f2060448201527f72656c6179206d657373616765000000000000000000000000000000000000006064820152608401610764565b5050505b50505050505050565b6040517fc2b3e5ac0000000000000000000000000000000000000000000000000000000081527342000000000000000000000000000000000000169063c2b3e5ac9084906112ee90889088908790600401611a7a565b6000604051808303818588803b15801561130757600080fd5b505af115801561131b573d6000803e3d6000fd5b505050505050505050565b6000547501000000000000000000000000000000000000000000900460ff166113d1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e670000000000000000000000000000000000000000006064820152608401610764565b60cc80547fffffffffffffffffffffffff00000000000000000000000000000000000000001661dead179055565b600061140d858585856114ce565b805190602001209050949350505050565b600061142e878787878787611567565b8051906020012090509695505050505050565b600073ffffffffffffffffffffffffffffffffffffffff8216301480611490575073ffffffffffffffffffffffffffffffffffffffff8216734200000000000000000000000000000000000016145b92915050565b600080603f83619c4001026040850201603f5a021015949350505050565b600080600080845160208601878a8af19695505050505050565b6060848484846040516024016114e79493929190611ac2565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fcbd4ece9000000000000000000000000000000000000000000000000000000001790529050949350505050565b606086868686868660405160240161158496959493929190611b0c565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fd764ad0b0000000000000000000000000000000000000000000000000000000017905290509695505050505050565b803573ffffffffffffffffffffffffffffffffffffffff8116811461162a57600080fd5b919050565b60008083601f84011261164157600080fd5b50813567ffffffffffffffff81111561165957600080fd5b60208301915083602082850101111561167157600080fd5b9250929050565b803563ffffffff8116811461162a57600080fd5b600080600080606085870312156116a257600080fd5b6116ab85611606565b9350602085013567ffffffffffffffff8111156116c757600080fd5b6116d38782880161162f565b90945092506116e6905060408601611678565b905092959194509250565b6000815180845260005b81811015611717576020818501810151868301820152016116fb565b81811115611729576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60208152600061176f60208301846116f1565b9392505050565b60006020828403121561178857600080fd5b5035919050565b6000806000604084860312156117a457600080fd5b833567ffffffffffffffff8111156117bb57600080fd5b6117c78682870161162f565b90945092506117da905060208501611678565b90509250925092565b600080600080600080600060c0888a0312156117fe57600080fd5b8735965061180e60208901611606565b955061181c60408901611606565b9450606088013593506080880135925060a088013567ffffffffffffffff81111561184657600080fd5b6118528a828b0161162f565b989b979a50959850939692959293505050565b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b878152600073ffffffffffffffffffffffffffffffffffffffff808916602084015280881660408401525085606083015263ffffffff8516608083015260c060a083015261190060c083018486611865565b9998505050505050505050565b73ffffffffffffffffffffffffffffffffffffffff8616815260806020820152600061193d608083018688611865565b905083604083015263ffffffff831660608301529695505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600067ffffffffffffffff808316818516818304811182151516156119b1576119b161195b565b02949350505050565b600067ffffffffffffffff808416806119fc577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b92169190910492915050565b600067ffffffffffffffff808316818516808303821115611a2b57611a2b61195b565b01949350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052600160045260246000fd5b600082821015611a7557611a7561195b565b500390565b73ffffffffffffffffffffffffffffffffffffffff8416815267ffffffffffffffff83166020820152606060408201526000611ab960608301846116f1565b95945050505050565b600073ffffffffffffffffffffffffffffffffffffffff808716835280861660208401525060806040830152611afb60808301856116f1565b905082606083015295945050505050565b868152600073ffffffffffffffffffffffffffffffffffffffff808816602084015280871660408401525084606083015283608083015260c060a0830152611b5760c08301846116f1565b9897505050505050505056fea164736f6c634300080f000a", } // L2CrossDomainMessengerABI is the input ABI used to generate the binding from. diff --git a/op-bindings/bindings/l2crossdomainmessenger_more.go b/op-bindings/bindings/l2crossdomainmessenger_more.go index 30939b96a2212..8f2263d3f3d3a 100644 --- a/op-bindings/bindings/l2crossdomainmessenger_more.go +++ b/op-bindings/bindings/l2crossdomainmessenger_more.go @@ -13,7 +13,7 @@ const L2CrossDomainMessengerStorageLayoutJSON = "{\"storage\":[{\"astId\":1000,\ var L2CrossDomainMessengerStorageLayout = new(solc.StorageLayout) -var L2CrossDomainMessengerDeployedBin = "0x6080604052600436106101445760003560e01c80638129fc1c116100c0578063a711986911610074578063b28ade2511610059578063b28ade25146103a2578063d764ad0b146103c2578063ecc70428146103d557600080fd5b8063a71198691461033f578063b1b1b2091461037257600080fd5b80638cbeeef2116100a55780638cbeeef2146101e35780639fce812c146102cb578063a4e7f8bd146102ff57600080fd5b80638129fc1c1461029f57806383a74074146102b457600080fd5b80633f827a5a1161011757806354fd4d50116100fc57806354fd4d50146101f95780635644cfdf1461024f5780636e296e451461026557600080fd5b80633f827a5a146101bb5780634c1d6a69146101e357600080fd5b8063028f85f7146101495780630c5684981461017c5780632828d7e8146101915780633dbb202b146101a6575b600080fd5b34801561015557600080fd5b5061015e601081565b60405167ffffffffffffffff90911681526020015b60405180910390f35b34801561018857600080fd5b5061015e603f81565b34801561019d57600080fd5b5061015e604081565b6101b96101b436600461168c565b61043a565b005b3480156101c757600080fd5b506101d0600181565b60405161ffff9091168152602001610173565b3480156101ef57600080fd5b5061015e619c4081565b34801561020557600080fd5b506102426040518060400160405280600581526020017f312e362e3000000000000000000000000000000000000000000000000000000081525081565b604051610173919061175c565b34801561025b57600080fd5b5061015e61138881565b34801561027157600080fd5b5061027a61069e565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610173565b3480156102ab57600080fd5b506101b961078a565b3480156102c057600080fd5b5061015e62030d4081565b3480156102d757600080fd5b5061027a7f000000000000000000000000000000000000000000000000000000000000000081565b34801561030b57600080fd5b5061032f61031a366004611776565b60ce6020526000908152604090205460ff1681565b6040519015158152602001610173565b34801561034b57600080fd5b507f000000000000000000000000000000000000000000000000000000000000000061027a565b34801561037e57600080fd5b5061032f61038d366004611776565b60cb6020526000908152604090205460ff1681565b3480156103ae57600080fd5b5061015e6103bd36600461178f565b61094d565b6101b96103d03660046117e3565b6109bb565b3480156103e157600080fd5b5061042c60cd547dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e010000000000000000000000000000000000000000000000000000000000001790565b604051908152602001610173565b6105737f000000000000000000000000000000000000000000000000000000000000000061046985858561094d565b347fd764ad0b000000000000000000000000000000000000000000000000000000006104d560cd547dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e010000000000000000000000000000000000000000000000000000000000001790565b338a34898c8c6040516024016104f197969594939291906118ae565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff0000000000000000000000000000000000000000000000000000000090931692909217909152611298565b8373ffffffffffffffffffffffffffffffffffffffff167fcb0f7ffd78f9aee47a248fae8db181db6eee833039123e026dcbff529522e52a3385856105f860cd547dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e010000000000000000000000000000000000000000000000000000000000001790565b8660405161060a95949392919061190d565b60405180910390a260405134815233907f8ebb2ec2465bdb2a06a66fc37a0963af8a2a6a1479d81d56fdb8cbb98096d5469060200160405180910390a2505060cd80547dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff808216600101167fffff0000000000000000000000000000000000000000000000000000000000009091161790555050565b60cc5460009073ffffffffffffffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff21530161076d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603560248201527f43726f7373446f6d61696e4d657373656e6765723a2078446f6d61696e4d657360448201527f7361676553656e646572206973206e6f7420736574000000000000000000000060648201526084015b60405180910390fd5b5060cc5473ffffffffffffffffffffffffffffffffffffffff1690565b6000546002907501000000000000000000000000000000000000000000900460ff161580156107d8575060005460ff8083167401000000000000000000000000000000000000000090920416105b610864576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a65640000000000000000000000000000000000006064820152608401610764565b600080547fffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff60ff84167401000000000000000000000000000000000000000002167fffffffffffffffffffff0000ffffffffffffffffffffffffffffffffffffffff9091161775010000000000000000000000000000000000000000001790556108ec611326565b600080547fffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff16905560405160ff821681527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a150565b6000611388619c4080603f610969604063ffffffff881661198a565b61097391906119ba565b61097e60108861198a565b61098b9062030d40611a08565b6109959190611a08565b61099f9190611a08565b6109a99190611a08565b6109b39190611a08565b949350505050565b60f087901c60028110610a76576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604d60248201527f43726f7373446f6d61696e4d657373656e6765723a206f6e6c7920766572736960448201527f6f6e2030206f722031206d657373616765732061726520737570706f7274656460648201527f20617420746869732074696d6500000000000000000000000000000000000000608482015260a401610764565b8061ffff16600003610b6b576000610ac7878986868080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508f92506113ff915050565b600081815260cb602052604090205490915060ff1615610b69576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f43726f7373446f6d61696e4d657373656e6765723a206c65676163792077697460448201527f6864726177616c20616c72656164792072656c617965640000000000000000006064820152608401610764565b505b6000610bb1898989898989898080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061141e92505050565b905073ffffffffffffffffffffffffffffffffffffffff7fffffffffffffffffffffffffeeeeffffffffffffffffffffffffffffffffeeef330181167f000000000000000000000000000000000000000000000000000000000000000090911603610c4957853414610c2557610c25611a34565b600081815260ce602052604090205460ff1615610c4457610c44611a34565b610d9b565b3415610cfd576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152605060248201527f43726f7373446f6d61696e4d657373656e6765723a2076616c7565206d75737460448201527f206265207a65726f20756e6c657373206d6573736167652069732066726f6d2060648201527f612073797374656d206164647265737300000000000000000000000000000000608482015260a401610764565b600081815260ce602052604090205460ff16610d9b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603060248201527f43726f7373446f6d61696e4d657373656e6765723a206d65737361676520636160448201527f6e6e6f74206265207265706c61796564000000000000000000000000000000006064820152608401610764565b610da487611441565b15610e57576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604360248201527f43726f7373446f6d61696e4d657373656e6765723a2063616e6e6f742073656e60448201527f64206d65737361676520746f20626c6f636b65642073797374656d206164647260648201527f6573730000000000000000000000000000000000000000000000000000000000608482015260a401610764565b600081815260cb602052604090205460ff1615610ef6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603660248201527f43726f7373446f6d61696e4d657373656e6765723a206d65737361676520686160448201527f7320616c7265616479206265656e2072656c61796564000000000000000000006064820152608401610764565b610f1785610f08611388619c40611a08565b67ffffffffffffffff16611496565b1580610f3d575060cc5473ffffffffffffffffffffffffffffffffffffffff1661dead14155b1561105657600081815260ce602052604080822080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790555182917f99d0e048484baa1b1540b1367cb128acd7ab2946d1ed91ec10e3c85e4bf51b8f91a27fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff320161104f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602d60248201527f43726f7373446f6d61696e4d657373656e6765723a206661696c656420746f2060448201527f72656c6179206d657373616765000000000000000000000000000000000000006064820152608401610764565b505061128f565b60cc80547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff8a1617905560006110e788619c405a6110aa9190611a63565b8988888080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506114b492505050565b60cc80547fffffffffffffffffffffffff00000000000000000000000000000000000000001661dead1790559050801561117e57600082815260cb602052604080822080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790555183917f4641df4a962071e12719d8c8c8e5ac7fc4d97b927346a3d7a335b1f7517e133c91a261128b565b600082815260ce602052604080822080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790555183917f99d0e048484baa1b1540b1367cb128acd7ab2946d1ed91ec10e3c85e4bf51b8f91a27fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff320161128b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602d60248201527f43726f7373446f6d61696e4d657373656e6765723a206661696c656420746f2060448201527f72656c6179206d657373616765000000000000000000000000000000000000006064820152608401610764565b5050505b50505050505050565b6040517fc2b3e5ac0000000000000000000000000000000000000000000000000000000081527342000000000000000000000000000000000000169063c2b3e5ac9084906112ee90889088908790600401611a7a565b6000604051808303818588803b15801561130757600080fd5b505af115801561131b573d6000803e3d6000fd5b505050505050505050565b6000547501000000000000000000000000000000000000000000900460ff166113d1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e670000000000000000000000000000000000000000006064820152608401610764565b60cc80547fffffffffffffffffffffffff00000000000000000000000000000000000000001661dead179055565b600061140d858585856114ce565b805190602001209050949350505050565b600061142e878787878787611567565b8051906020012090509695505050505050565b600073ffffffffffffffffffffffffffffffffffffffff8216301480611490575073ffffffffffffffffffffffffffffffffffffffff8216734200000000000000000000000000000000000016145b92915050565b600080603f83619c4001026040850201603f5a021015949350505050565b600080600080845160208601878a8af19695505050505050565b6060848484846040516024016114e79493929190611ac2565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fcbd4ece9000000000000000000000000000000000000000000000000000000001790529050949350505050565b606086868686868660405160240161158496959493929190611b0c565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fd764ad0b0000000000000000000000000000000000000000000000000000000017905290509695505050505050565b803573ffffffffffffffffffffffffffffffffffffffff8116811461162a57600080fd5b919050565b60008083601f84011261164157600080fd5b50813567ffffffffffffffff81111561165957600080fd5b60208301915083602082850101111561167157600080fd5b9250929050565b803563ffffffff8116811461162a57600080fd5b600080600080606085870312156116a257600080fd5b6116ab85611606565b9350602085013567ffffffffffffffff8111156116c757600080fd5b6116d38782880161162f565b90945092506116e6905060408601611678565b905092959194509250565b6000815180845260005b81811015611717576020818501810151868301820152016116fb565b81811115611729576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60208152600061176f60208301846116f1565b9392505050565b60006020828403121561178857600080fd5b5035919050565b6000806000604084860312156117a457600080fd5b833567ffffffffffffffff8111156117bb57600080fd5b6117c78682870161162f565b90945092506117da905060208501611678565b90509250925092565b600080600080600080600060c0888a0312156117fe57600080fd5b8735965061180e60208901611606565b955061181c60408901611606565b9450606088013593506080880135925060a088013567ffffffffffffffff81111561184657600080fd5b6118528a828b0161162f565b989b979a50959850939692959293505050565b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b878152600073ffffffffffffffffffffffffffffffffffffffff808916602084015280881660408401525085606083015263ffffffff8516608083015260c060a083015261190060c083018486611865565b9998505050505050505050565b73ffffffffffffffffffffffffffffffffffffffff8616815260806020820152600061193d608083018688611865565b905083604083015263ffffffff831660608301529695505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600067ffffffffffffffff808316818516818304811182151516156119b1576119b161195b565b02949350505050565b600067ffffffffffffffff808416806119fc577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b92169190910492915050565b600067ffffffffffffffff808316818516808303821115611a2b57611a2b61195b565b01949350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052600160045260246000fd5b600082821015611a7557611a7561195b565b500390565b73ffffffffffffffffffffffffffffffffffffffff8416815267ffffffffffffffff83166020820152606060408201526000611ab960608301846116f1565b95945050505050565b600073ffffffffffffffffffffffffffffffffffffffff808716835280861660208401525060806040830152611afb60808301856116f1565b905082606083015295945050505050565b868152600073ffffffffffffffffffffffffffffffffffffffff808816602084015280871660408401525084606083015283608083015260c060a0830152611b5760c08301846116f1565b9897505050505050505056fea164736f6c634300080f000a" +var L2CrossDomainMessengerDeployedBin = "0x6080604052600436106101445760003560e01c80638129fc1c116100c0578063a711986911610074578063b28ade2511610059578063b28ade25146103a2578063d764ad0b146103c2578063ecc70428146103d557600080fd5b8063a71198691461033f578063b1b1b2091461037257600080fd5b80638cbeeef2116100a55780638cbeeef2146101e35780639fce812c146102cb578063a4e7f8bd146102ff57600080fd5b80638129fc1c1461029f57806383a74074146102b457600080fd5b80633f827a5a1161011757806354fd4d50116100fc57806354fd4d50146101f95780635644cfdf1461024f5780636e296e451461026557600080fd5b80633f827a5a146101bb5780634c1d6a69146101e357600080fd5b8063028f85f7146101495780630c5684981461017c5780632828d7e8146101915780633dbb202b146101a6575b600080fd5b34801561015557600080fd5b5061015e601081565b60405167ffffffffffffffff90911681526020015b60405180910390f35b34801561018857600080fd5b5061015e603f81565b34801561019d57600080fd5b5061015e604081565b6101b96101b436600461168c565b61043a565b005b3480156101c757600080fd5b506101d0600181565b60405161ffff9091168152602001610173565b3480156101ef57600080fd5b5061015e619c4081565b34801561020557600080fd5b506102426040518060400160405280600581526020017f312e372e3000000000000000000000000000000000000000000000000000000081525081565b604051610173919061175c565b34801561025b57600080fd5b5061015e61138881565b34801561027157600080fd5b5061027a61069e565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610173565b3480156102ab57600080fd5b506101b961078a565b3480156102c057600080fd5b5061015e62030d4081565b3480156102d757600080fd5b5061027a7f000000000000000000000000000000000000000000000000000000000000000081565b34801561030b57600080fd5b5061032f61031a366004611776565b60ce6020526000908152604090205460ff1681565b6040519015158152602001610173565b34801561034b57600080fd5b507f000000000000000000000000000000000000000000000000000000000000000061027a565b34801561037e57600080fd5b5061032f61038d366004611776565b60cb6020526000908152604090205460ff1681565b3480156103ae57600080fd5b5061015e6103bd36600461178f565b61094d565b6101b96103d03660046117e3565b6109bb565b3480156103e157600080fd5b5061042c60cd547dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e010000000000000000000000000000000000000000000000000000000000001790565b604051908152602001610173565b6105737f000000000000000000000000000000000000000000000000000000000000000061046985858561094d565b347fd764ad0b000000000000000000000000000000000000000000000000000000006104d560cd547dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e010000000000000000000000000000000000000000000000000000000000001790565b338a34898c8c6040516024016104f197969594939291906118ae565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff0000000000000000000000000000000000000000000000000000000090931692909217909152611298565b8373ffffffffffffffffffffffffffffffffffffffff167fcb0f7ffd78f9aee47a248fae8db181db6eee833039123e026dcbff529522e52a3385856105f860cd547dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e010000000000000000000000000000000000000000000000000000000000001790565b8660405161060a95949392919061190d565b60405180910390a260405134815233907f8ebb2ec2465bdb2a06a66fc37a0963af8a2a6a1479d81d56fdb8cbb98096d5469060200160405180910390a2505060cd80547dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff808216600101167fffff0000000000000000000000000000000000000000000000000000000000009091161790555050565b60cc5460009073ffffffffffffffffffffffffffffffffffffffff167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff21530161076d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603560248201527f43726f7373446f6d61696e4d657373656e6765723a2078446f6d61696e4d657360448201527f7361676553656e646572206973206e6f7420736574000000000000000000000060648201526084015b60405180910390fd5b5060cc5473ffffffffffffffffffffffffffffffffffffffff1690565b6000546003907501000000000000000000000000000000000000000000900460ff161580156107d8575060005460ff8083167401000000000000000000000000000000000000000090920416105b610864576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a65640000000000000000000000000000000000006064820152608401610764565b600080547fffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff60ff84167401000000000000000000000000000000000000000002167fffffffffffffffffffff0000ffffffffffffffffffffffffffffffffffffffff9091161775010000000000000000000000000000000000000000001790556108ec611326565b600080547fffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff16905560405160ff821681527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a150565b6000611388619c4080603f610969604063ffffffff881661198a565b61097391906119ba565b61097e60108861198a565b61098b9062030d40611a08565b6109959190611a08565b61099f9190611a08565b6109a99190611a08565b6109b39190611a08565b949350505050565b60f087901c60028110610a76576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604d60248201527f43726f7373446f6d61696e4d657373656e6765723a206f6e6c7920766572736960448201527f6f6e2030206f722031206d657373616765732061726520737570706f7274656460648201527f20617420746869732074696d6500000000000000000000000000000000000000608482015260a401610764565b8061ffff16600003610b6b576000610ac7878986868080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508f92506113ff915050565b600081815260cb602052604090205490915060ff1615610b69576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f43726f7373446f6d61696e4d657373656e6765723a206c65676163792077697460448201527f6864726177616c20616c72656164792072656c617965640000000000000000006064820152608401610764565b505b6000610bb1898989898989898080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061141e92505050565b905073ffffffffffffffffffffffffffffffffffffffff7fffffffffffffffffffffffffeeeeffffffffffffffffffffffffffffffffeeef330181167f000000000000000000000000000000000000000000000000000000000000000090911603610c4957853414610c2557610c25611a34565b600081815260ce602052604090205460ff1615610c4457610c44611a34565b610d9b565b3415610cfd576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152605060248201527f43726f7373446f6d61696e4d657373656e6765723a2076616c7565206d75737460448201527f206265207a65726f20756e6c657373206d6573736167652069732066726f6d2060648201527f612073797374656d206164647265737300000000000000000000000000000000608482015260a401610764565b600081815260ce602052604090205460ff16610d9b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603060248201527f43726f7373446f6d61696e4d657373656e6765723a206d65737361676520636160448201527f6e6e6f74206265207265706c61796564000000000000000000000000000000006064820152608401610764565b610da487611441565b15610e57576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604360248201527f43726f7373446f6d61696e4d657373656e6765723a2063616e6e6f742073656e60448201527f64206d65737361676520746f20626c6f636b65642073797374656d206164647260648201527f6573730000000000000000000000000000000000000000000000000000000000608482015260a401610764565b600081815260cb602052604090205460ff1615610ef6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603660248201527f43726f7373446f6d61696e4d657373656e6765723a206d65737361676520686160448201527f7320616c7265616479206265656e2072656c61796564000000000000000000006064820152608401610764565b610f1785610f08611388619c40611a08565b67ffffffffffffffff16611496565b1580610f3d575060cc5473ffffffffffffffffffffffffffffffffffffffff1661dead14155b1561105657600081815260ce602052604080822080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790555182917f99d0e048484baa1b1540b1367cb128acd7ab2946d1ed91ec10e3c85e4bf51b8f91a27fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff320161104f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602d60248201527f43726f7373446f6d61696e4d657373656e6765723a206661696c656420746f2060448201527f72656c6179206d657373616765000000000000000000000000000000000000006064820152608401610764565b505061128f565b60cc80547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff8a1617905560006110e788619c405a6110aa9190611a63565b8988888080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506114b492505050565b60cc80547fffffffffffffffffffffffff00000000000000000000000000000000000000001661dead1790559050801561117e57600082815260cb602052604080822080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790555183917f4641df4a962071e12719d8c8c8e5ac7fc4d97b927346a3d7a335b1f7517e133c91a261128b565b600082815260ce602052604080822080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790555183917f99d0e048484baa1b1540b1367cb128acd7ab2946d1ed91ec10e3c85e4bf51b8f91a27fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff320161128b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602d60248201527f43726f7373446f6d61696e4d657373656e6765723a206661696c656420746f2060448201527f72656c6179206d657373616765000000000000000000000000000000000000006064820152608401610764565b5050505b50505050505050565b6040517fc2b3e5ac0000000000000000000000000000000000000000000000000000000081527342000000000000000000000000000000000000169063c2b3e5ac9084906112ee90889088908790600401611a7a565b6000604051808303818588803b15801561130757600080fd5b505af115801561131b573d6000803e3d6000fd5b505050505050505050565b6000547501000000000000000000000000000000000000000000900460ff166113d1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e670000000000000000000000000000000000000000006064820152608401610764565b60cc80547fffffffffffffffffffffffff00000000000000000000000000000000000000001661dead179055565b600061140d858585856114ce565b805190602001209050949350505050565b600061142e878787878787611567565b8051906020012090509695505050505050565b600073ffffffffffffffffffffffffffffffffffffffff8216301480611490575073ffffffffffffffffffffffffffffffffffffffff8216734200000000000000000000000000000000000016145b92915050565b600080603f83619c4001026040850201603f5a021015949350505050565b600080600080845160208601878a8af19695505050505050565b6060848484846040516024016114e79493929190611ac2565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fcbd4ece9000000000000000000000000000000000000000000000000000000001790529050949350505050565b606086868686868660405160240161158496959493929190611b0c565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fd764ad0b0000000000000000000000000000000000000000000000000000000017905290509695505050505050565b803573ffffffffffffffffffffffffffffffffffffffff8116811461162a57600080fd5b919050565b60008083601f84011261164157600080fd5b50813567ffffffffffffffff81111561165957600080fd5b60208301915083602082850101111561167157600080fd5b9250929050565b803563ffffffff8116811461162a57600080fd5b600080600080606085870312156116a257600080fd5b6116ab85611606565b9350602085013567ffffffffffffffff8111156116c757600080fd5b6116d38782880161162f565b90945092506116e6905060408601611678565b905092959194509250565b6000815180845260005b81811015611717576020818501810151868301820152016116fb565b81811115611729576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60208152600061176f60208301846116f1565b9392505050565b60006020828403121561178857600080fd5b5035919050565b6000806000604084860312156117a457600080fd5b833567ffffffffffffffff8111156117bb57600080fd5b6117c78682870161162f565b90945092506117da905060208501611678565b90509250925092565b600080600080600080600060c0888a0312156117fe57600080fd5b8735965061180e60208901611606565b955061181c60408901611606565b9450606088013593506080880135925060a088013567ffffffffffffffff81111561184657600080fd5b6118528a828b0161162f565b989b979a50959850939692959293505050565b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b878152600073ffffffffffffffffffffffffffffffffffffffff808916602084015280881660408401525085606083015263ffffffff8516608083015260c060a083015261190060c083018486611865565b9998505050505050505050565b73ffffffffffffffffffffffffffffffffffffffff8616815260806020820152600061193d608083018688611865565b905083604083015263ffffffff831660608301529695505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600067ffffffffffffffff808316818516818304811182151516156119b1576119b161195b565b02949350505050565b600067ffffffffffffffff808416806119fc577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b92169190910492915050565b600067ffffffffffffffff808316818516808303821115611a2b57611a2b61195b565b01949350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052600160045260246000fd5b600082821015611a7557611a7561195b565b500390565b73ffffffffffffffffffffffffffffffffffffffff8416815267ffffffffffffffff83166020820152606060408201526000611ab960608301846116f1565b95945050505050565b600073ffffffffffffffffffffffffffffffffffffffff808716835280861660208401525060806040830152611afb60808301856116f1565b905082606083015295945050505050565b868152600073ffffffffffffffffffffffffffffffffffffffff808816602084015280871660408401525084606083015283608083015260c060a0830152611b5760c08301846116f1565b9897505050505050505056fea164736f6c634300080f000a" func init() { if err := json.Unmarshal([]byte(L2CrossDomainMessengerStorageLayoutJSON), L2CrossDomainMessengerStorageLayout); err != nil { diff --git a/op-bindings/bindings/l2erc721bridge.go b/op-bindings/bindings/l2erc721bridge.go index db87f16e923df..edb9c6030f5ab 100644 --- a/op-bindings/bindings/l2erc721bridge.go +++ b/op-bindings/bindings/l2erc721bridge.go @@ -30,8 +30,8 @@ var ( // L2ERC721BridgeMetaData contains all meta data concerning the L2ERC721Bridge contract. var L2ERC721BridgeMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_otherBridge\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"localToken\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"remoteToken\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"tokenId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"ERC721BridgeFinalized\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"localToken\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"remoteToken\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"tokenId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"ERC721BridgeInitiated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"version\",\"type\":\"uint8\"}],\"name\":\"Initialized\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MESSENGER\",\"outputs\":[{\"internalType\":\"contractCrossDomainMessenger\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"OTHER_BRIDGE\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_localToken\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_remoteToken\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_tokenId\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"_minGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"_extraData\",\"type\":\"bytes\"}],\"name\":\"bridgeERC721\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_localToken\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_remoteToken\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_tokenId\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"_minGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"_extraData\",\"type\":\"bytes\"}],\"name\":\"bridgeERC721To\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_localToken\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_remoteToken\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_tokenId\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"_extraData\",\"type\":\"bytes\"}],\"name\":\"finalizeBridgeERC721\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"contractCrossDomainMessenger\",\"name\":\"_messenger\",\"type\":\"address\"}],\"name\":\"initialize\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"messenger\",\"outputs\":[{\"internalType\":\"contractCrossDomainMessenger\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"otherBridge\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"version\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", - Bin: "0x60a06040523480156200001157600080fd5b506040516200187f3803806200187f83398101604081905262000034916200024b565b806001600160a01b038116620000a95760405162461bcd60e51b815260206004820152602f60248201527f4552433732314272696467653a206f74686572206272696467652063616e6e6f60448201526e74206265206164647265737328302960881b60648201526084015b60405180910390fd5b6001600160a01b0316608052620000c16000620000c8565b506200027d565b600054600290610100900460ff16158015620000eb575060005460ff8083169116105b620001505760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401620000a0565b6000805461ffff191660ff8316176101001790556200016f82620001b4565b6000805461ff001916905560405160ff821681527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050565b600054610100900460ff16620002215760405162461bcd60e51b815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201526a6e697469616c697a696e6760a81b6064820152608401620000a0565b600080546001600160a01b03909216620100000262010000600160b01b0319909216919091179055565b6000602082840312156200025e57600080fd5b81516001600160a01b03811681146200027657600080fd5b9392505050565b6080516115d1620002ae6000396000818161016e015281816101dc015281816102d60152610ea101526115d16000f3fe608060405234801561001057600080fd5b50600436106100a35760003560e01c80637f46ddb211610076578063aa5574521161005b578063aa557452146101b4578063c4d66de8146101c7578063c89701a2146101da57600080fd5b80637f46ddb214610169578063927ede2d1461019057600080fd5b80633687011a146100a85780633cb747bf146100bd57806354fd4d501461010d578063761f449314610156575b600080fd5b6100bb6100b636600461124f565b610200565b005b6000546100e39062010000900473ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b6101496040518060400160405280600581526020017f312e332e3000000000000000000000000000000000000000000000000000000081525081565b604051610104919061133d565b6100bb610164366004611350565b6102ac565b6100e37f000000000000000000000000000000000000000000000000000000000000000081565b60005462010000900473ffffffffffffffffffffffffffffffffffffffff166100e3565b6100bb6101c23660046113e8565b6107fd565b6100bb6101d536600461145f565b6108b9565b7f00000000000000000000000000000000000000000000000000000000000000006100e3565b333b15610294576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602d60248201527f4552433732314272696467653a206163636f756e74206973206e6f742065787460448201527f65726e616c6c79206f776e65640000000000000000000000000000000000000060648201526084015b60405180910390fd5b6102a48686333388888888610a03565b505050505050565b60005462010000900473ffffffffffffffffffffffffffffffffffffffff16331480156103b457507f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16600060029054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16636e296e456040518163ffffffff1660e01b8152600401602060405180830381865afa158015610378573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061039c919061147c565b73ffffffffffffffffffffffffffffffffffffffff16145b610440576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603f60248201527f4552433732314272696467653a2066756e6374696f6e2063616e206f6e6c792060448201527f62652063616c6c65642066726f6d20746865206f746865722062726964676500606482015260840161028b565b3073ffffffffffffffffffffffffffffffffffffffff8816036104e5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602a60248201527f4c324552433732314272696467653a206c6f63616c20746f6b656e2063616e6e60448201527f6f742062652073656c6600000000000000000000000000000000000000000000606482015260840161028b565b61050f877f74259ebf00000000000000000000000000000000000000000000000000000000610f8d565b61059b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603660248201527f4c324552433732314272696467653a206c6f63616c20746f6b656e20696e746560448201527f7266616365206973206e6f7420636f6d706c69616e7400000000000000000000606482015260840161028b565b8673ffffffffffffffffffffffffffffffffffffffff1663d6c0b2c46040518163ffffffff1660e01b8152600401602060405180830381865afa1580156105e6573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061060a919061147c565b73ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff16146106ea576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604b60248201527f4c324552433732314272696467653a2077726f6e672072656d6f746520746f6b60448201527f656e20666f72204f7074696d69736d204d696e7461626c65204552433732312060648201527f6c6f63616c20746f6b656e000000000000000000000000000000000000000000608482015260a40161028b565b6040517fa144819400000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff85811660048301526024820185905288169063a144819490604401600060405180830381600087803b15801561075a57600080fd5b505af115801561076e573d6000803e3d6000fd5b505050508473ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff168873ffffffffffffffffffffffffffffffffffffffff167f1f39bf6707b5d608453e0ae4c067b562bcc4c85c0f562ef5d2c774d2e7f131ac878787876040516107ec94939291906114e2565b60405180910390a450505050505050565b73ffffffffffffffffffffffffffffffffffffffff85166108a0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603060248201527f4552433732314272696467653a206e667420726563697069656e742063616e6e60448201527f6f74206265206164647265737328302900000000000000000000000000000000606482015260840161028b565b6108b08787338888888888610a03565b50505050505050565b600054600290610100900460ff161580156108db575060005460ff8083169116105b610967576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a6564000000000000000000000000000000000000606482015260840161028b565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001660ff8316176101001790556109a182610fb0565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff16905560405160ff821681527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050565b73ffffffffffffffffffffffffffffffffffffffff8716610aa6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603160248201527f4c324552433732314272696467653a2072656d6f746520746f6b656e2063616e60448201527f6e6f742062652061646472657373283029000000000000000000000000000000606482015260840161028b565b6040517f6352211e0000000000000000000000000000000000000000000000000000000081526004810185905273ffffffffffffffffffffffffffffffffffffffff891690636352211e90602401602060405180830381865afa158015610b11573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b35919061147c565b73ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614610bef576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603e60248201527f4c324552433732314272696467653a205769746864726177616c206973206e6f60448201527f74206265696e6720696e69746961746564206279204e4654206f776e65720000606482015260840161028b565b60008873ffffffffffffffffffffffffffffffffffffffff1663d6c0b2c46040518163ffffffff1660e01b8152600401602060405180830381865afa158015610c3c573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c60919061147c565b90508773ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1614610d1d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f4c324552433732314272696467653a2072656d6f746520746f6b656e20646f6560448201527f73206e6f74206d6174636820676976656e2076616c7565000000000000000000606482015260840161028b565b6040517f9dc29fac00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8881166004830152602482018790528a1690639dc29fac90604401600060405180830381600087803b158015610d8d57600080fd5b505af1158015610da1573d6000803e3d6000fd5b50505050600063761f449360e01b828b8a8a8a8989604051602401610dcc9796959493929190611522565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009094169390931790925260005491517f3dbb202b00000000000000000000000000000000000000000000000000000000815290925073ffffffffffffffffffffffffffffffffffffffff620100009092049190911690633dbb202b90610ecd907f00000000000000000000000000000000000000000000000000000000000000009085908a9060040161157f565b600060405180830381600087803b158015610ee757600080fd5b505af1158015610efb573d6000803e3d6000fd5b505050508773ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff168b73ffffffffffffffffffffffffffffffffffffffff167fb7460e2a880f256ebef3406116ff3eee0cee51ebccdc2a40698f87ebb2e9c1a58a8a8989604051610f7994939291906114e2565b60405180910390a450505050505050505050565b6000610f9883611094565b8015610fa95750610fa983836110f9565b9392505050565b600054610100900460ff16611047576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e67000000000000000000000000000000000000000000606482015260840161028b565b6000805473ffffffffffffffffffffffffffffffffffffffff90921662010000027fffffffffffffffffffff0000000000000000000000000000000000000000ffff909216919091179055565b60006110c0827f01ffc9a7000000000000000000000000000000000000000000000000000000006110f9565b80156110f357506110f1827fffffffff000000000000000000000000000000000000000000000000000000006110f9565b155b92915050565b604080517fffffffff000000000000000000000000000000000000000000000000000000008316602480830191909152825180830390910181526044909101909152602080820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f01ffc9a700000000000000000000000000000000000000000000000000000000178152825160009392849283928392918391908a617530fa92503d915060005190508280156111b1575060208210155b80156111bd5750600081115b979650505050505050565b73ffffffffffffffffffffffffffffffffffffffff811681146111ea57600080fd5b50565b803563ffffffff8116811461120157600080fd5b919050565b60008083601f84011261121857600080fd5b50813567ffffffffffffffff81111561123057600080fd5b60208301915083602082850101111561124857600080fd5b9250929050565b60008060008060008060a0878903121561126857600080fd5b8635611273816111c8565b95506020870135611283816111c8565b945060408701359350611298606088016111ed565b9250608087013567ffffffffffffffff8111156112b457600080fd5b6112c089828a01611206565b979a9699509497509295939492505050565b6000815180845260005b818110156112f8576020818501810151868301820152016112dc565b8181111561130a576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b602081526000610fa960208301846112d2565b600080600080600080600060c0888a03121561136b57600080fd5b8735611376816111c8565b96506020880135611386816111c8565b95506040880135611396816111c8565b945060608801356113a6816111c8565b93506080880135925060a088013567ffffffffffffffff8111156113c957600080fd5b6113d58a828b01611206565b989b979a50959850939692959293505050565b600080600080600080600060c0888a03121561140357600080fd5b873561140e816111c8565b9650602088013561141e816111c8565b9550604088013561142e816111c8565b945060608801359350611443608089016111ed565b925060a088013567ffffffffffffffff8111156113c957600080fd5b60006020828403121561147157600080fd5b8135610fa9816111c8565b60006020828403121561148e57600080fd5b8151610fa9816111c8565b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b73ffffffffffffffffffffffffffffffffffffffff85168152836020820152606060408201526000611518606083018486611499565b9695505050505050565b600073ffffffffffffffffffffffffffffffffffffffff808a1683528089166020840152808816604084015280871660608401525084608083015260c060a083015261157260c083018486611499565b9998505050505050505050565b73ffffffffffffffffffffffffffffffffffffffff841681526060602082015260006115ae60608301856112d2565b905063ffffffff8316604083015294935050505056fea164736f6c634300080f000a", + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_otherBridge\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"localToken\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"remoteToken\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"tokenId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"ERC721BridgeFinalized\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"localToken\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"remoteToken\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"tokenId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"ERC721BridgeInitiated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"version\",\"type\":\"uint8\"}],\"name\":\"Initialized\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MESSENGER\",\"outputs\":[{\"internalType\":\"contractCrossDomainMessenger\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"OTHER_BRIDGE\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_localToken\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_remoteToken\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_tokenId\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"_minGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"_extraData\",\"type\":\"bytes\"}],\"name\":\"bridgeERC721\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_localToken\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_remoteToken\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_tokenId\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"_minGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"_extraData\",\"type\":\"bytes\"}],\"name\":\"bridgeERC721To\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_localToken\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_remoteToken\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_tokenId\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"_extraData\",\"type\":\"bytes\"}],\"name\":\"finalizeBridgeERC721\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"initialize\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"messenger\",\"outputs\":[{\"internalType\":\"contractCrossDomainMessenger\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"otherBridge\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"version\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", + Bin: "0x60a06040523480156200001157600080fd5b506040516200187b3803806200187b83398101604081905262000034916200025c565b806001600160a01b038116620000a95760405162461bcd60e51b815260206004820152602f60248201527f4552433732314272696467653a206f74686572206272696467652063616e6e6f60448201526e74206265206164647265737328302960881b60648201526084015b60405180910390fd5b6001600160a01b0316608052620000bf620000c6565b506200028e565b600054600390610100900460ff16158015620000e9575060005460ff8083169116105b6200014e5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b6064820152608401620000a0565b6000805461ffff191660ff83161761010017905562000181734200000000000000000000000000000000000007620001c5565b6000805461ff001916905560405160ff821681527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a150565b600054610100900460ff16620002325760405162461bcd60e51b815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201526a6e697469616c697a696e6760a81b6064820152608401620000a0565b600080546001600160a01b03909216620100000262010000600160b01b0319909216919091179055565b6000602082840312156200026f57600080fd5b81516001600160a01b03811681146200028757600080fd5b9392505050565b6080516115bc620002bf6000396000818161016e015281816101d1015281816102cb0152610ea901526115bc6000f3fe608060405234801561001057600080fd5b50600436106100a35760003560e01c80637f46ddb211610076578063927ede2d1161005b578063927ede2d14610198578063aa557452146101bc578063c89701a2146101cf57600080fd5b80637f46ddb2146101695780638129fc1c1461019057600080fd5b80633687011a146100a85780633cb747bf146100bd57806354fd4d501461010d578063761f449314610156575b600080fd5b6100bb6100b6366004611257565b6101f5565b005b6000546100e39062010000900473ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b6101496040518060400160405280600581526020017f312e342e3000000000000000000000000000000000000000000000000000000081525081565b6040516101049190611345565b6100bb610164366004611358565b6102a1565b6100e37f000000000000000000000000000000000000000000000000000000000000000081565b6100bb6107f2565b60005462010000900473ffffffffffffffffffffffffffffffffffffffff166100e3565b6100bb6101ca3660046113f0565b61094f565b7f00000000000000000000000000000000000000000000000000000000000000006100e3565b333b15610289576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602d60248201527f4552433732314272696467653a206163636f756e74206973206e6f742065787460448201527f65726e616c6c79206f776e65640000000000000000000000000000000000000060648201526084015b60405180910390fd5b6102998686333388888888610a0b565b505050505050565b60005462010000900473ffffffffffffffffffffffffffffffffffffffff16331480156103a957507f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16600060029054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16636e296e456040518163ffffffff1660e01b8152600401602060405180830381865afa15801561036d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906103919190611467565b73ffffffffffffffffffffffffffffffffffffffff16145b610435576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603f60248201527f4552433732314272696467653a2066756e6374696f6e2063616e206f6e6c792060448201527f62652063616c6c65642066726f6d20746865206f7468657220627269646765006064820152608401610280565b3073ffffffffffffffffffffffffffffffffffffffff8816036104da576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602a60248201527f4c324552433732314272696467653a206c6f63616c20746f6b656e2063616e6e60448201527f6f742062652073656c66000000000000000000000000000000000000000000006064820152608401610280565b610504877f74259ebf00000000000000000000000000000000000000000000000000000000610f95565b610590576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603660248201527f4c324552433732314272696467653a206c6f63616c20746f6b656e20696e746560448201527f7266616365206973206e6f7420636f6d706c69616e74000000000000000000006064820152608401610280565b8673ffffffffffffffffffffffffffffffffffffffff1663d6c0b2c46040518163ffffffff1660e01b8152600401602060405180830381865afa1580156105db573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906105ff9190611467565b73ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff16146106df576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604b60248201527f4c324552433732314272696467653a2077726f6e672072656d6f746520746f6b60448201527f656e20666f72204f7074696d69736d204d696e7461626c65204552433732312060648201527f6c6f63616c20746f6b656e000000000000000000000000000000000000000000608482015260a401610280565b6040517fa144819400000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff85811660048301526024820185905288169063a144819490604401600060405180830381600087803b15801561074f57600080fd5b505af1158015610763573d6000803e3d6000fd5b505050508473ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff168873ffffffffffffffffffffffffffffffffffffffff167f1f39bf6707b5d608453e0ae4c067b562bcc4c85c0f562ef5d2c774d2e7f131ac878787876040516107e194939291906114cd565b60405180910390a450505050505050565b600054600390610100900460ff16158015610814575060005460ff8083169116105b6108a0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a65640000000000000000000000000000000000006064820152608401610280565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001660ff8316176101001790556108ee734200000000000000000000000000000000000007610fb8565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff16905560405160ff821681527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a150565b73ffffffffffffffffffffffffffffffffffffffff85166109f2576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603060248201527f4552433732314272696467653a206e667420726563697069656e742063616e6e60448201527f6f742062652061646472657373283029000000000000000000000000000000006064820152608401610280565b610a028787338888888888610a0b565b50505050505050565b73ffffffffffffffffffffffffffffffffffffffff8716610aae576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603160248201527f4c324552433732314272696467653a2072656d6f746520746f6b656e2063616e60448201527f6e6f7420626520616464726573732830290000000000000000000000000000006064820152608401610280565b6040517f6352211e0000000000000000000000000000000000000000000000000000000081526004810185905273ffffffffffffffffffffffffffffffffffffffff891690636352211e90602401602060405180830381865afa158015610b19573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b3d9190611467565b73ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614610bf7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603e60248201527f4c324552433732314272696467653a205769746864726177616c206973206e6f60448201527f74206265696e6720696e69746961746564206279204e4654206f776e657200006064820152608401610280565b60008873ffffffffffffffffffffffffffffffffffffffff1663d6c0b2c46040518163ffffffff1660e01b8152600401602060405180830381865afa158015610c44573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c689190611467565b90508773ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1614610d25576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f4c324552433732314272696467653a2072656d6f746520746f6b656e20646f6560448201527f73206e6f74206d6174636820676976656e2076616c75650000000000000000006064820152608401610280565b6040517f9dc29fac00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8881166004830152602482018790528a1690639dc29fac90604401600060405180830381600087803b158015610d9557600080fd5b505af1158015610da9573d6000803e3d6000fd5b50505050600063761f449360e01b828b8a8a8a8989604051602401610dd4979695949392919061150d565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009094169390931790925260005491517f3dbb202b00000000000000000000000000000000000000000000000000000000815290925073ffffffffffffffffffffffffffffffffffffffff620100009092049190911690633dbb202b90610ed5907f00000000000000000000000000000000000000000000000000000000000000009085908a9060040161156a565b600060405180830381600087803b158015610eef57600080fd5b505af1158015610f03573d6000803e3d6000fd5b505050508773ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff168b73ffffffffffffffffffffffffffffffffffffffff167fb7460e2a880f256ebef3406116ff3eee0cee51ebccdc2a40698f87ebb2e9c1a58a8a8989604051610f8194939291906114cd565b60405180910390a450505050505050505050565b6000610fa08361109c565b8015610fb15750610fb18383611101565b9392505050565b600054610100900460ff1661104f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e670000000000000000000000000000000000000000006064820152608401610280565b6000805473ffffffffffffffffffffffffffffffffffffffff90921662010000027fffffffffffffffffffff0000000000000000000000000000000000000000ffff909216919091179055565b60006110c8827f01ffc9a700000000000000000000000000000000000000000000000000000000611101565b80156110fb57506110f9827fffffffff00000000000000000000000000000000000000000000000000000000611101565b155b92915050565b604080517fffffffff000000000000000000000000000000000000000000000000000000008316602480830191909152825180830390910181526044909101909152602080820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f01ffc9a700000000000000000000000000000000000000000000000000000000178152825160009392849283928392918391908a617530fa92503d915060005190508280156111b9575060208210155b80156111c55750600081115b979650505050505050565b73ffffffffffffffffffffffffffffffffffffffff811681146111f257600080fd5b50565b803563ffffffff8116811461120957600080fd5b919050565b60008083601f84011261122057600080fd5b50813567ffffffffffffffff81111561123857600080fd5b60208301915083602082850101111561125057600080fd5b9250929050565b60008060008060008060a0878903121561127057600080fd5b863561127b816111d0565b9550602087013561128b816111d0565b9450604087013593506112a0606088016111f5565b9250608087013567ffffffffffffffff8111156112bc57600080fd5b6112c889828a0161120e565b979a9699509497509295939492505050565b6000815180845260005b81811015611300576020818501810151868301820152016112e4565b81811115611312576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b602081526000610fb160208301846112da565b600080600080600080600060c0888a03121561137357600080fd5b873561137e816111d0565b9650602088013561138e816111d0565b9550604088013561139e816111d0565b945060608801356113ae816111d0565b93506080880135925060a088013567ffffffffffffffff8111156113d157600080fd5b6113dd8a828b0161120e565b989b979a50959850939692959293505050565b600080600080600080600060c0888a03121561140b57600080fd5b8735611416816111d0565b96506020880135611426816111d0565b95506040880135611436816111d0565b94506060880135935061144b608089016111f5565b925060a088013567ffffffffffffffff8111156113d157600080fd5b60006020828403121561147957600080fd5b8151610fb1816111d0565b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b73ffffffffffffffffffffffffffffffffffffffff85168152836020820152606060408201526000611503606083018486611484565b9695505050505050565b600073ffffffffffffffffffffffffffffffffffffffff808a1683528089166020840152808816604084015280871660608401525084608083015260c060a083015261155d60c083018486611484565b9998505050505050505050565b73ffffffffffffffffffffffffffffffffffffffff8416815260606020820152600061159960608301856112da565b905063ffffffff8316604083015294935050505056fea164736f6c634300080f000a", } // L2ERC721BridgeABI is the input ABI used to generate the binding from. @@ -419,25 +419,25 @@ func (_L2ERC721Bridge *L2ERC721BridgeTransactorSession) FinalizeBridgeERC721(_lo return _L2ERC721Bridge.Contract.FinalizeBridgeERC721(&_L2ERC721Bridge.TransactOpts, _localToken, _remoteToken, _from, _to, _tokenId, _extraData) } -// Initialize is a paid mutator transaction binding the contract method 0xc4d66de8. +// Initialize is a paid mutator transaction binding the contract method 0x8129fc1c. // -// Solidity: function initialize(address _messenger) returns() -func (_L2ERC721Bridge *L2ERC721BridgeTransactor) Initialize(opts *bind.TransactOpts, _messenger common.Address) (*types.Transaction, error) { - return _L2ERC721Bridge.contract.Transact(opts, "initialize", _messenger) +// Solidity: function initialize() returns() +func (_L2ERC721Bridge *L2ERC721BridgeTransactor) Initialize(opts *bind.TransactOpts) (*types.Transaction, error) { + return _L2ERC721Bridge.contract.Transact(opts, "initialize") } -// Initialize is a paid mutator transaction binding the contract method 0xc4d66de8. +// Initialize is a paid mutator transaction binding the contract method 0x8129fc1c. // -// Solidity: function initialize(address _messenger) returns() -func (_L2ERC721Bridge *L2ERC721BridgeSession) Initialize(_messenger common.Address) (*types.Transaction, error) { - return _L2ERC721Bridge.Contract.Initialize(&_L2ERC721Bridge.TransactOpts, _messenger) +// Solidity: function initialize() returns() +func (_L2ERC721Bridge *L2ERC721BridgeSession) Initialize() (*types.Transaction, error) { + return _L2ERC721Bridge.Contract.Initialize(&_L2ERC721Bridge.TransactOpts) } -// Initialize is a paid mutator transaction binding the contract method 0xc4d66de8. +// Initialize is a paid mutator transaction binding the contract method 0x8129fc1c. // -// Solidity: function initialize(address _messenger) returns() -func (_L2ERC721Bridge *L2ERC721BridgeTransactorSession) Initialize(_messenger common.Address) (*types.Transaction, error) { - return _L2ERC721Bridge.Contract.Initialize(&_L2ERC721Bridge.TransactOpts, _messenger) +// Solidity: function initialize() returns() +func (_L2ERC721Bridge *L2ERC721BridgeTransactorSession) Initialize() (*types.Transaction, error) { + return _L2ERC721Bridge.Contract.Initialize(&_L2ERC721Bridge.TransactOpts) } // L2ERC721BridgeERC721BridgeFinalizedIterator is returned from FilterERC721BridgeFinalized and is used to iterate over the raw logs and unpacked data for ERC721BridgeFinalized events raised by the L2ERC721Bridge contract. diff --git a/op-bindings/bindings/l2erc721bridge_more.go b/op-bindings/bindings/l2erc721bridge_more.go index 117575ffb5aa6..2f568f57cdfc2 100644 --- a/op-bindings/bindings/l2erc721bridge_more.go +++ b/op-bindings/bindings/l2erc721bridge_more.go @@ -13,7 +13,7 @@ const L2ERC721BridgeStorageLayoutJSON = "{\"storage\":[{\"astId\":1000,\"contrac var L2ERC721BridgeStorageLayout = new(solc.StorageLayout) -var L2ERC721BridgeDeployedBin = "0x608060405234801561001057600080fd5b50600436106100a35760003560e01c80637f46ddb211610076578063aa5574521161005b578063aa557452146101b4578063c4d66de8146101c7578063c89701a2146101da57600080fd5b80637f46ddb214610169578063927ede2d1461019057600080fd5b80633687011a146100a85780633cb747bf146100bd57806354fd4d501461010d578063761f449314610156575b600080fd5b6100bb6100b636600461124f565b610200565b005b6000546100e39062010000900473ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b6101496040518060400160405280600581526020017f312e332e3000000000000000000000000000000000000000000000000000000081525081565b604051610104919061133d565b6100bb610164366004611350565b6102ac565b6100e37f000000000000000000000000000000000000000000000000000000000000000081565b60005462010000900473ffffffffffffffffffffffffffffffffffffffff166100e3565b6100bb6101c23660046113e8565b6107fd565b6100bb6101d536600461145f565b6108b9565b7f00000000000000000000000000000000000000000000000000000000000000006100e3565b333b15610294576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602d60248201527f4552433732314272696467653a206163636f756e74206973206e6f742065787460448201527f65726e616c6c79206f776e65640000000000000000000000000000000000000060648201526084015b60405180910390fd5b6102a48686333388888888610a03565b505050505050565b60005462010000900473ffffffffffffffffffffffffffffffffffffffff16331480156103b457507f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16600060029054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16636e296e456040518163ffffffff1660e01b8152600401602060405180830381865afa158015610378573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061039c919061147c565b73ffffffffffffffffffffffffffffffffffffffff16145b610440576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603f60248201527f4552433732314272696467653a2066756e6374696f6e2063616e206f6e6c792060448201527f62652063616c6c65642066726f6d20746865206f746865722062726964676500606482015260840161028b565b3073ffffffffffffffffffffffffffffffffffffffff8816036104e5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602a60248201527f4c324552433732314272696467653a206c6f63616c20746f6b656e2063616e6e60448201527f6f742062652073656c6600000000000000000000000000000000000000000000606482015260840161028b565b61050f877f74259ebf00000000000000000000000000000000000000000000000000000000610f8d565b61059b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603660248201527f4c324552433732314272696467653a206c6f63616c20746f6b656e20696e746560448201527f7266616365206973206e6f7420636f6d706c69616e7400000000000000000000606482015260840161028b565b8673ffffffffffffffffffffffffffffffffffffffff1663d6c0b2c46040518163ffffffff1660e01b8152600401602060405180830381865afa1580156105e6573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061060a919061147c565b73ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff16146106ea576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604b60248201527f4c324552433732314272696467653a2077726f6e672072656d6f746520746f6b60448201527f656e20666f72204f7074696d69736d204d696e7461626c65204552433732312060648201527f6c6f63616c20746f6b656e000000000000000000000000000000000000000000608482015260a40161028b565b6040517fa144819400000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff85811660048301526024820185905288169063a144819490604401600060405180830381600087803b15801561075a57600080fd5b505af115801561076e573d6000803e3d6000fd5b505050508473ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff168873ffffffffffffffffffffffffffffffffffffffff167f1f39bf6707b5d608453e0ae4c067b562bcc4c85c0f562ef5d2c774d2e7f131ac878787876040516107ec94939291906114e2565b60405180910390a450505050505050565b73ffffffffffffffffffffffffffffffffffffffff85166108a0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603060248201527f4552433732314272696467653a206e667420726563697069656e742063616e6e60448201527f6f74206265206164647265737328302900000000000000000000000000000000606482015260840161028b565b6108b08787338888888888610a03565b50505050505050565b600054600290610100900460ff161580156108db575060005460ff8083169116105b610967576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a6564000000000000000000000000000000000000606482015260840161028b565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001660ff8316176101001790556109a182610fb0565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff16905560405160ff821681527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050565b73ffffffffffffffffffffffffffffffffffffffff8716610aa6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603160248201527f4c324552433732314272696467653a2072656d6f746520746f6b656e2063616e60448201527f6e6f742062652061646472657373283029000000000000000000000000000000606482015260840161028b565b6040517f6352211e0000000000000000000000000000000000000000000000000000000081526004810185905273ffffffffffffffffffffffffffffffffffffffff891690636352211e90602401602060405180830381865afa158015610b11573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b35919061147c565b73ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614610bef576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603e60248201527f4c324552433732314272696467653a205769746864726177616c206973206e6f60448201527f74206265696e6720696e69746961746564206279204e4654206f776e65720000606482015260840161028b565b60008873ffffffffffffffffffffffffffffffffffffffff1663d6c0b2c46040518163ffffffff1660e01b8152600401602060405180830381865afa158015610c3c573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c60919061147c565b90508773ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1614610d1d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f4c324552433732314272696467653a2072656d6f746520746f6b656e20646f6560448201527f73206e6f74206d6174636820676976656e2076616c7565000000000000000000606482015260840161028b565b6040517f9dc29fac00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8881166004830152602482018790528a1690639dc29fac90604401600060405180830381600087803b158015610d8d57600080fd5b505af1158015610da1573d6000803e3d6000fd5b50505050600063761f449360e01b828b8a8a8a8989604051602401610dcc9796959493929190611522565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009094169390931790925260005491517f3dbb202b00000000000000000000000000000000000000000000000000000000815290925073ffffffffffffffffffffffffffffffffffffffff620100009092049190911690633dbb202b90610ecd907f00000000000000000000000000000000000000000000000000000000000000009085908a9060040161157f565b600060405180830381600087803b158015610ee757600080fd5b505af1158015610efb573d6000803e3d6000fd5b505050508773ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff168b73ffffffffffffffffffffffffffffffffffffffff167fb7460e2a880f256ebef3406116ff3eee0cee51ebccdc2a40698f87ebb2e9c1a58a8a8989604051610f7994939291906114e2565b60405180910390a450505050505050505050565b6000610f9883611094565b8015610fa95750610fa983836110f9565b9392505050565b600054610100900460ff16611047576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e67000000000000000000000000000000000000000000606482015260840161028b565b6000805473ffffffffffffffffffffffffffffffffffffffff90921662010000027fffffffffffffffffffff0000000000000000000000000000000000000000ffff909216919091179055565b60006110c0827f01ffc9a7000000000000000000000000000000000000000000000000000000006110f9565b80156110f357506110f1827fffffffff000000000000000000000000000000000000000000000000000000006110f9565b155b92915050565b604080517fffffffff000000000000000000000000000000000000000000000000000000008316602480830191909152825180830390910181526044909101909152602080820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f01ffc9a700000000000000000000000000000000000000000000000000000000178152825160009392849283928392918391908a617530fa92503d915060005190508280156111b1575060208210155b80156111bd5750600081115b979650505050505050565b73ffffffffffffffffffffffffffffffffffffffff811681146111ea57600080fd5b50565b803563ffffffff8116811461120157600080fd5b919050565b60008083601f84011261121857600080fd5b50813567ffffffffffffffff81111561123057600080fd5b60208301915083602082850101111561124857600080fd5b9250929050565b60008060008060008060a0878903121561126857600080fd5b8635611273816111c8565b95506020870135611283816111c8565b945060408701359350611298606088016111ed565b9250608087013567ffffffffffffffff8111156112b457600080fd5b6112c089828a01611206565b979a9699509497509295939492505050565b6000815180845260005b818110156112f8576020818501810151868301820152016112dc565b8181111561130a576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b602081526000610fa960208301846112d2565b600080600080600080600060c0888a03121561136b57600080fd5b8735611376816111c8565b96506020880135611386816111c8565b95506040880135611396816111c8565b945060608801356113a6816111c8565b93506080880135925060a088013567ffffffffffffffff8111156113c957600080fd5b6113d58a828b01611206565b989b979a50959850939692959293505050565b600080600080600080600060c0888a03121561140357600080fd5b873561140e816111c8565b9650602088013561141e816111c8565b9550604088013561142e816111c8565b945060608801359350611443608089016111ed565b925060a088013567ffffffffffffffff8111156113c957600080fd5b60006020828403121561147157600080fd5b8135610fa9816111c8565b60006020828403121561148e57600080fd5b8151610fa9816111c8565b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b73ffffffffffffffffffffffffffffffffffffffff85168152836020820152606060408201526000611518606083018486611499565b9695505050505050565b600073ffffffffffffffffffffffffffffffffffffffff808a1683528089166020840152808816604084015280871660608401525084608083015260c060a083015261157260c083018486611499565b9998505050505050505050565b73ffffffffffffffffffffffffffffffffffffffff841681526060602082015260006115ae60608301856112d2565b905063ffffffff8316604083015294935050505056fea164736f6c634300080f000a" +var L2ERC721BridgeDeployedBin = "0x608060405234801561001057600080fd5b50600436106100a35760003560e01c80637f46ddb211610076578063927ede2d1161005b578063927ede2d14610198578063aa557452146101bc578063c89701a2146101cf57600080fd5b80637f46ddb2146101695780638129fc1c1461019057600080fd5b80633687011a146100a85780633cb747bf146100bd57806354fd4d501461010d578063761f449314610156575b600080fd5b6100bb6100b6366004611257565b6101f5565b005b6000546100e39062010000900473ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b6101496040518060400160405280600581526020017f312e342e3000000000000000000000000000000000000000000000000000000081525081565b6040516101049190611345565b6100bb610164366004611358565b6102a1565b6100e37f000000000000000000000000000000000000000000000000000000000000000081565b6100bb6107f2565b60005462010000900473ffffffffffffffffffffffffffffffffffffffff166100e3565b6100bb6101ca3660046113f0565b61094f565b7f00000000000000000000000000000000000000000000000000000000000000006100e3565b333b15610289576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602d60248201527f4552433732314272696467653a206163636f756e74206973206e6f742065787460448201527f65726e616c6c79206f776e65640000000000000000000000000000000000000060648201526084015b60405180910390fd5b6102998686333388888888610a0b565b505050505050565b60005462010000900473ffffffffffffffffffffffffffffffffffffffff16331480156103a957507f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16600060029054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16636e296e456040518163ffffffff1660e01b8152600401602060405180830381865afa15801561036d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906103919190611467565b73ffffffffffffffffffffffffffffffffffffffff16145b610435576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603f60248201527f4552433732314272696467653a2066756e6374696f6e2063616e206f6e6c792060448201527f62652063616c6c65642066726f6d20746865206f7468657220627269646765006064820152608401610280565b3073ffffffffffffffffffffffffffffffffffffffff8816036104da576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602a60248201527f4c324552433732314272696467653a206c6f63616c20746f6b656e2063616e6e60448201527f6f742062652073656c66000000000000000000000000000000000000000000006064820152608401610280565b610504877f74259ebf00000000000000000000000000000000000000000000000000000000610f95565b610590576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603660248201527f4c324552433732314272696467653a206c6f63616c20746f6b656e20696e746560448201527f7266616365206973206e6f7420636f6d706c69616e74000000000000000000006064820152608401610280565b8673ffffffffffffffffffffffffffffffffffffffff1663d6c0b2c46040518163ffffffff1660e01b8152600401602060405180830381865afa1580156105db573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906105ff9190611467565b73ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff16146106df576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604b60248201527f4c324552433732314272696467653a2077726f6e672072656d6f746520746f6b60448201527f656e20666f72204f7074696d69736d204d696e7461626c65204552433732312060648201527f6c6f63616c20746f6b656e000000000000000000000000000000000000000000608482015260a401610280565b6040517fa144819400000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff85811660048301526024820185905288169063a144819490604401600060405180830381600087803b15801561074f57600080fd5b505af1158015610763573d6000803e3d6000fd5b505050508473ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff168873ffffffffffffffffffffffffffffffffffffffff167f1f39bf6707b5d608453e0ae4c067b562bcc4c85c0f562ef5d2c774d2e7f131ac878787876040516107e194939291906114cd565b60405180910390a450505050505050565b600054600390610100900460ff16158015610814575060005460ff8083169116105b6108a0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a65640000000000000000000000000000000000006064820152608401610280565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001660ff8316176101001790556108ee734200000000000000000000000000000000000007610fb8565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff16905560405160ff821681527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a150565b73ffffffffffffffffffffffffffffffffffffffff85166109f2576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603060248201527f4552433732314272696467653a206e667420726563697069656e742063616e6e60448201527f6f742062652061646472657373283029000000000000000000000000000000006064820152608401610280565b610a028787338888888888610a0b565b50505050505050565b73ffffffffffffffffffffffffffffffffffffffff8716610aae576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603160248201527f4c324552433732314272696467653a2072656d6f746520746f6b656e2063616e60448201527f6e6f7420626520616464726573732830290000000000000000000000000000006064820152608401610280565b6040517f6352211e0000000000000000000000000000000000000000000000000000000081526004810185905273ffffffffffffffffffffffffffffffffffffffff891690636352211e90602401602060405180830381865afa158015610b19573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b3d9190611467565b73ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff1614610bf7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603e60248201527f4c324552433732314272696467653a205769746864726177616c206973206e6f60448201527f74206265696e6720696e69746961746564206279204e4654206f776e657200006064820152608401610280565b60008873ffffffffffffffffffffffffffffffffffffffff1663d6c0b2c46040518163ffffffff1660e01b8152600401602060405180830381865afa158015610c44573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c689190611467565b90508773ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1614610d25576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f4c324552433732314272696467653a2072656d6f746520746f6b656e20646f6560448201527f73206e6f74206d6174636820676976656e2076616c75650000000000000000006064820152608401610280565b6040517f9dc29fac00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8881166004830152602482018790528a1690639dc29fac90604401600060405180830381600087803b158015610d9557600080fd5b505af1158015610da9573d6000803e3d6000fd5b50505050600063761f449360e01b828b8a8a8a8989604051602401610dd4979695949392919061150d565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009094169390931790925260005491517f3dbb202b00000000000000000000000000000000000000000000000000000000815290925073ffffffffffffffffffffffffffffffffffffffff620100009092049190911690633dbb202b90610ed5907f00000000000000000000000000000000000000000000000000000000000000009085908a9060040161156a565b600060405180830381600087803b158015610eef57600080fd5b505af1158015610f03573d6000803e3d6000fd5b505050508773ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff168b73ffffffffffffffffffffffffffffffffffffffff167fb7460e2a880f256ebef3406116ff3eee0cee51ebccdc2a40698f87ebb2e9c1a58a8a8989604051610f8194939291906114cd565b60405180910390a450505050505050505050565b6000610fa08361109c565b8015610fb15750610fb18383611101565b9392505050565b600054610100900460ff1661104f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e670000000000000000000000000000000000000000006064820152608401610280565b6000805473ffffffffffffffffffffffffffffffffffffffff90921662010000027fffffffffffffffffffff0000000000000000000000000000000000000000ffff909216919091179055565b60006110c8827f01ffc9a700000000000000000000000000000000000000000000000000000000611101565b80156110fb57506110f9827fffffffff00000000000000000000000000000000000000000000000000000000611101565b155b92915050565b604080517fffffffff000000000000000000000000000000000000000000000000000000008316602480830191909152825180830390910181526044909101909152602080820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f01ffc9a700000000000000000000000000000000000000000000000000000000178152825160009392849283928392918391908a617530fa92503d915060005190508280156111b9575060208210155b80156111c55750600081115b979650505050505050565b73ffffffffffffffffffffffffffffffffffffffff811681146111f257600080fd5b50565b803563ffffffff8116811461120957600080fd5b919050565b60008083601f84011261122057600080fd5b50813567ffffffffffffffff81111561123857600080fd5b60208301915083602082850101111561125057600080fd5b9250929050565b60008060008060008060a0878903121561127057600080fd5b863561127b816111d0565b9550602087013561128b816111d0565b9450604087013593506112a0606088016111f5565b9250608087013567ffffffffffffffff8111156112bc57600080fd5b6112c889828a0161120e565b979a9699509497509295939492505050565b6000815180845260005b81811015611300576020818501810151868301820152016112e4565b81811115611312576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b602081526000610fb160208301846112da565b600080600080600080600060c0888a03121561137357600080fd5b873561137e816111d0565b9650602088013561138e816111d0565b9550604088013561139e816111d0565b945060608801356113ae816111d0565b93506080880135925060a088013567ffffffffffffffff8111156113d157600080fd5b6113dd8a828b0161120e565b989b979a50959850939692959293505050565b600080600080600080600060c0888a03121561140b57600080fd5b8735611416816111d0565b96506020880135611426816111d0565b95506040880135611436816111d0565b94506060880135935061144b608089016111f5565b925060a088013567ffffffffffffffff8111156113d157600080fd5b60006020828403121561147957600080fd5b8151610fb1816111d0565b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b73ffffffffffffffffffffffffffffffffffffffff85168152836020820152606060408201526000611503606083018486611484565b9695505050505050565b600073ffffffffffffffffffffffffffffffffffffffff808a1683528089166020840152808816604084015280871660608401525084608083015260c060a083015261155d60c083018486611484565b9998505050505050505050565b73ffffffffffffffffffffffffffffffffffffffff8416815260606020820152600061159960608301856112da565b905063ffffffff8316604083015294935050505056fea164736f6c634300080f000a" func init() { if err := json.Unmarshal([]byte(L2ERC721BridgeStorageLayoutJSON), L2ERC721BridgeStorageLayout); err != nil { diff --git a/op-bindings/bindings/l2standardbridge.go b/op-bindings/bindings/l2standardbridge.go index 560bafbf72068..4e12122873eeb 100644 --- a/op-bindings/bindings/l2standardbridge.go +++ b/op-bindings/bindings/l2standardbridge.go @@ -31,7 +31,7 @@ var ( // L2StandardBridgeMetaData contains all meta data concerning the L2StandardBridge contract. var L2StandardBridgeMetaData = &bind.MetaData{ ABI: "[{\"inputs\":[{\"internalType\":\"contractStandardBridge\",\"name\":\"_otherBridge\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"l1Token\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"l2Token\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"DepositFinalized\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"localToken\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"remoteToken\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"ERC20BridgeFinalized\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"localToken\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"remoteToken\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"ERC20BridgeInitiated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"ETHBridgeFinalized\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"ETHBridgeInitiated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"version\",\"type\":\"uint8\"}],\"name\":\"Initialized\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"l1Token\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"l2Token\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"WithdrawalInitiated\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MESSENGER\",\"outputs\":[{\"internalType\":\"contractCrossDomainMessenger\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"OTHER_BRIDGE\",\"outputs\":[{\"internalType\":\"contractStandardBridge\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_localToken\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_remoteToken\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"_minGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"_extraData\",\"type\":\"bytes\"}],\"name\":\"bridgeERC20\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_localToken\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_remoteToken\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"_minGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"_extraData\",\"type\":\"bytes\"}],\"name\":\"bridgeERC20To\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"_minGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"_extraData\",\"type\":\"bytes\"}],\"name\":\"bridgeETH\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_to\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"_minGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"_extraData\",\"type\":\"bytes\"}],\"name\":\"bridgeETHTo\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"name\":\"deposits\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_localToken\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_remoteToken\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"_extraData\",\"type\":\"bytes\"}],\"name\":\"finalizeBridgeERC20\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"_extraData\",\"type\":\"bytes\"}],\"name\":\"finalizeBridgeETH\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_l1Token\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_l2Token\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"_extraData\",\"type\":\"bytes\"}],\"name\":\"finalizeDeposit\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"initialize\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"l1TokenBridge\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"messenger\",\"outputs\":[{\"internalType\":\"contractCrossDomainMessenger\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"otherBridge\",\"outputs\":[{\"internalType\":\"contractStandardBridge\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"version\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_l2Token\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"_minGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"_extraData\",\"type\":\"bytes\"}],\"name\":\"withdraw\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_l2Token\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"_minGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"_extraData\",\"type\":\"bytes\"}],\"name\":\"withdrawTo\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"stateMutability\":\"payable\",\"type\":\"receive\"}]", - Bin: "0x60a06040523480156200001157600080fd5b5060405162002c8538038062002c858339810160408190526200003491620001e4565b6001600160a01b0381166080526200004b62000052565b5062000216565b600054600290610100900460ff1615801562000075575060005460ff8083169116105b620000de5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084015b60405180910390fd5b6000805461ffff191660ff8316176101001790556200011173420000000000000000000000000000000000000762000155565b6000805461ff001916905560405160ff821681527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a150565b600054610100900460ff16620001c25760405162461bcd60e51b815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201526a6e697469616c697a696e6760a81b6064820152608401620000d5565b600380546001600160a01b0319166001600160a01b0392909216919091179055565b600060208284031215620001f757600080fd5b81516001600160a01b03811681146200020f57600080fd5b9392505050565b608051612a30620002556000396000818161024e015281816103600152818161058e01528181610a230152818161134001526116820152612a306000f3fe6080604052600436106101125760003560e01c8063662a633a116100a55780638f601f6611610074578063a3a7954811610059578063a3a7954814610428578063c89701a21461023f578063e11013dd1461043b57600080fd5b80638f601f66146103b7578063927ede2d146103fd57600080fd5b8063662a633a1461033b5780637f46ddb21461034e5780638129fc1c14610382578063870876231461039757600080fd5b806336c717c1116100e157806336c717c11461023f5780633cb747bf14610298578063540abf73146102c557806354fd4d50146102e557600080fd5b80630166a07a146101e657806309fc8843146102065780631635f5fd1461021957806332b7006d1461022c57600080fd5b366101e157333b156101ab576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20616e20454f4100000000000000000060648201526084015b60405180910390fd5b6101df73deaddeaddeaddeaddeaddeaddeaddeaddead000033333462030d406040518060200160405280600081525061044e565b005b600080fd5b3480156101f257600080fd5b506101df610201366004612440565b610529565b6101df6102143660046124f1565b6108e7565b6101df610227366004612544565b6109be565b6101df61023a3660046125b7565b610e2c565b34801561024b57600080fd5b507f00000000000000000000000000000000000000000000000000000000000000005b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b3480156102a457600080fd5b5060035461026e9073ffffffffffffffffffffffffffffffffffffffff1681565b3480156102d157600080fd5b506101df6102e036600461260b565b610f06565b3480156102f157600080fd5b5061032e6040518060400160405280600581526020017f312e332e3000000000000000000000000000000000000000000000000000000081525081565b60405161028f91906126f8565b6101df610349366004612440565b610f4b565b34801561035a57600080fd5b5061026e7f000000000000000000000000000000000000000000000000000000000000000081565b34801561038e57600080fd5b506101df610fbe565b3480156103a357600080fd5b506101df6103b236600461270b565b61111b565b3480156103c357600080fd5b506103ef6103d236600461278e565b600260209081526000928352604080842090915290825290205481565b60405190815260200161028f565b34801561040957600080fd5b5060035473ffffffffffffffffffffffffffffffffffffffff1661026e565b6101df61043636600461270b565b6111ef565b6101df6104493660046127c7565b611233565b7fffffffffffffffffffffffff215221522152215221522152215221522153000073ffffffffffffffffffffffffffffffffffffffff87160161049d57610498858585858561127c565b610521565b60008673ffffffffffffffffffffffffffffffffffffffff1663c01e1bd66040518163ffffffff1660e01b8152600401602060405180830381865afa1580156104ea573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061050e919061282a565b905061051f87828888888888611462565b505b505050505050565b60035473ffffffffffffffffffffffffffffffffffffffff16331480156106185750600354604080517f6e296e45000000000000000000000000000000000000000000000000000000008152905173ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000008116931691636e296e459160048083019260209291908290030181865afa1580156105dc573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610600919061282a565b73ffffffffffffffffffffffffffffffffffffffff16145b6106ca576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604160248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20746865206f7468657220627269646760648201527f6500000000000000000000000000000000000000000000000000000000000000608482015260a4016101a2565b6106d3876117aa565b15610821576106e2878761180c565b610794576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604a60248201527f5374616e646172644272696467653a2077726f6e672072656d6f746520746f6b60448201527f656e20666f72204f7074696d69736d204d696e7461626c65204552433230206c60648201527f6f63616c20746f6b656e00000000000000000000000000000000000000000000608482015260a4016101a2565b6040517f40c10f1900000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8581166004830152602482018590528816906340c10f1990604401600060405180830381600087803b15801561080457600080fd5b505af1158015610818573d6000803e3d6000fd5b505050506108a3565b73ffffffffffffffffffffffffffffffffffffffff8088166000908152600260209081526040808320938a168352929052205461085f908490612876565b73ffffffffffffffffffffffffffffffffffffffff8089166000818152600260209081526040808320948c16835293905291909120919091556108a390858561192c565b61051f878787878787878080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250611a0092505050565b333b15610976576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20616e20454f4100000000000000000060648201526084016101a2565b6109b93333348686868080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061127c92505050565b505050565b60035473ffffffffffffffffffffffffffffffffffffffff1633148015610aad5750600354604080517f6e296e45000000000000000000000000000000000000000000000000000000008152905173ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000008116931691636e296e459160048083019260209291908290030181865afa158015610a71573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a95919061282a565b73ffffffffffffffffffffffffffffffffffffffff16145b610b5f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604160248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20746865206f7468657220627269646760648201527f6500000000000000000000000000000000000000000000000000000000000000608482015260a4016101a2565b823414610bee576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603a60248201527f5374616e646172644272696467653a20616d6f756e742073656e7420646f657360448201527f206e6f74206d6174636820616d6f756e7420726571756972656400000000000060648201526084016101a2565b3073ffffffffffffffffffffffffffffffffffffffff851603610c93576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f5374616e646172644272696467653a2063616e6e6f742073656e6420746f207360448201527f656c66000000000000000000000000000000000000000000000000000000000060648201526084016101a2565b60035473ffffffffffffffffffffffffffffffffffffffff90811690851603610d3e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602860248201527f5374616e646172644272696467653a2063616e6e6f742073656e6420746f206d60448201527f657373656e67657200000000000000000000000000000000000000000000000060648201526084016101a2565b610d8085858585858080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250611a8e92505050565b6000610d9d855a8660405180602001604052806000815250611b2f565b905080610521576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f5374616e646172644272696467653a20455448207472616e736665722066616960448201527f6c6564000000000000000000000000000000000000000000000000000000000060648201526084016101a2565b333b15610ebb576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20616e20454f4100000000000000000060648201526084016101a2565b610eff853333878787878080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061044e92505050565b5050505050565b61051f87873388888888888080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061146292505050565b73ffffffffffffffffffffffffffffffffffffffff8716158015610f98575073ffffffffffffffffffffffffffffffffffffffff861673deaddeaddeaddeaddeaddeaddeaddeaddead0000145b15610faf57610faa85858585856109be565b61051f565b61051f86888787878787610529565b600054600290610100900460ff16158015610fe0575060005460ff8083169116105b61106c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a656400000000000000000000000000000000000060648201526084016101a2565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001660ff8316176101001790556110ba734200000000000000000000000000000000000007611b49565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff16905560405160ff821681527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a150565b333b156111aa576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20616e20454f4100000000000000000060648201526084016101a2565b61052186863333888888888080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061146292505050565b610521863387878787878080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061044e92505050565b6112763385348686868080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061127c92505050565b50505050565b82341461130b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603e60248201527f5374616e646172644272696467653a206272696467696e6720455448206d757360448201527f7420696e636c7564652073756666696369656e74204554482076616c7565000060648201526084016101a2565b61131785858584611c27565b60035460405173ffffffffffffffffffffffffffffffffffffffff90911690633dbb202b9085907f0000000000000000000000000000000000000000000000000000000000000000907f1635f5fd0000000000000000000000000000000000000000000000000000000090611396908b908b9086908a9060240161288d565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009485161790525160e086901b9092168252611429929188906004016128d6565b6000604051808303818588803b15801561144257600080fd5b505af1158015611456573d6000803e3d6000fd5b50505050505050505050565b61146b876117aa565b156115b95761147a878761180c565b61152c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604a60248201527f5374616e646172644272696467653a2077726f6e672072656d6f746520746f6b60448201527f656e20666f72204f7074696d69736d204d696e7461626c65204552433230206c60648201527f6f63616c20746f6b656e00000000000000000000000000000000000000000000608482015260a4016101a2565b6040517f9dc29fac00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015260248201859052881690639dc29fac90604401600060405180830381600087803b15801561159c57600080fd5b505af11580156115b0573d6000803e3d6000fd5b5050505061164d565b6115db73ffffffffffffffffffffffffffffffffffffffff8816863086611cc8565b73ffffffffffffffffffffffffffffffffffffffff8088166000908152600260209081526040808320938a168352929052205461161990849061291b565b73ffffffffffffffffffffffffffffffffffffffff8089166000908152600260209081526040808320938b16835292905220555b61165b878787878786611d26565b60035460405173ffffffffffffffffffffffffffffffffffffffff90911690633dbb202b907f0000000000000000000000000000000000000000000000000000000000000000907f0166a07a00000000000000000000000000000000000000000000000000000000906116dc908b908d908c908c908c908b90602401612933565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009485161790525160e085901b909216825261176f929187906004016128d6565b600060405180830381600087803b15801561178957600080fd5b505af115801561179d573d6000803e3d6000fd5b5050505050505050505050565b60006117d6827f1d1d8b6300000000000000000000000000000000000000000000000000000000611db4565b806118065750611806827fec4fc8e300000000000000000000000000000000000000000000000000000000611db4565b92915050565b6000611838837f1d1d8b6300000000000000000000000000000000000000000000000000000000611db4565b156118e1578273ffffffffffffffffffffffffffffffffffffffff1663c01e1bd66040518163ffffffff1660e01b8152600401602060405180830381865afa158015611888573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906118ac919061282a565b73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16149050611806565b8273ffffffffffffffffffffffffffffffffffffffff1663d6c0b2c46040518163ffffffff1660e01b8152600401602060405180830381865afa158015611888573d6000803e3d6000fd5b60405173ffffffffffffffffffffffffffffffffffffffff83166024820152604481018290526109b99084907fa9059cbb00000000000000000000000000000000000000000000000000000000906064015b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff0000000000000000000000000000000000000000000000000000000090931692909217909152611dd7565b8373ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff167fb0444523268717a02698be47d0803aa7468c00acbed2f8bd93a0459cde61dd89868686604051611a789392919061298e565b60405180910390a4610521868686868686611ee3565b8373ffffffffffffffffffffffffffffffffffffffff1673deaddeaddeaddeaddeaddeaddeaddeaddead000073ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fb0444523268717a02698be47d0803aa7468c00acbed2f8bd93a0459cde61dd89868686604051611b1b9392919061298e565b60405180910390a461127684848484611f6b565b600080600080845160208601878a8af19695505050505050565b600054610100900460ff16611be0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e6700000000000000000000000000000000000000000060648201526084016101a2565b600380547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b8373ffffffffffffffffffffffffffffffffffffffff1673deaddeaddeaddeaddeaddeaddeaddeaddead000073ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167f73d170910aba9e6d50b102db522b1dbcd796216f5128b445aa2135272886497e868686604051611cb49392919061298e565b60405180910390a461127684848484611fd8565b60405173ffffffffffffffffffffffffffffffffffffffff808516602483015283166044820152606481018290526112769085907f23b872dd000000000000000000000000000000000000000000000000000000009060840161197e565b8373ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff167f73d170910aba9e6d50b102db522b1dbcd796216f5128b445aa2135272886497e868686604051611d9e9392919061298e565b60405180910390a4610521868686868686612037565b6000611dbf836120af565b8015611dd05750611dd08383612113565b9392505050565b6000611e39826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c65648152508573ffffffffffffffffffffffffffffffffffffffff166121e29092919063ffffffff16565b8051909150156109b95780806020019051810190611e5791906129cc565b6109b9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e60448201527f6f7420737563636565640000000000000000000000000000000000000000000060648201526084016101a2565b8373ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff167fd59c65b35445225835c83f50b6ede06a7be047d22e357073e250d9af537518cd868686604051611f5b9392919061298e565b60405180910390a4505050505050565b8273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167f31b2166ff604fc5672ea5df08a78081d2bc6d746cadce880747f3643d819e83d8484604051611fca9291906129ee565b60405180910390a350505050565b8273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167f2849b43074093a05396b6f2a937dee8565b15a48a7b3d4bffb732a5017380af58484604051611fca9291906129ee565b8373ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff167f7ff126db8024424bbfd9826e8ab82ff59136289ea440b04b39a0df1b03b9cabf868686604051611f5b9392919061298e565b60006120db827f01ffc9a700000000000000000000000000000000000000000000000000000000612113565b8015611806575061210c827fffffffff00000000000000000000000000000000000000000000000000000000612113565b1592915050565b604080517fffffffff000000000000000000000000000000000000000000000000000000008316602480830191909152825180830390910181526044909101909152602080820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f01ffc9a700000000000000000000000000000000000000000000000000000000178152825160009392849283928392918391908a617530fa92503d915060005190508280156121cb575060208210155b80156121d75750600081115b979650505050505050565b60606121f184846000856121f9565b949350505050565b60608247101561228b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f60448201527f722063616c6c000000000000000000000000000000000000000000000000000060648201526084016101a2565b73ffffffffffffffffffffffffffffffffffffffff85163b612309576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064016101a2565b6000808673ffffffffffffffffffffffffffffffffffffffff1685876040516123329190612a07565b60006040518083038185875af1925050503d806000811461236f576040519150601f19603f3d011682016040523d82523d6000602084013e612374565b606091505b50915091506121d78282866060831561238e575081611dd0565b82511561239e5782518084602001fd5b816040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016101a291906126f8565b73ffffffffffffffffffffffffffffffffffffffff811681146123f457600080fd5b50565b60008083601f84011261240957600080fd5b50813567ffffffffffffffff81111561242157600080fd5b60208301915083602082850101111561243957600080fd5b9250929050565b600080600080600080600060c0888a03121561245b57600080fd5b8735612466816123d2565b96506020880135612476816123d2565b95506040880135612486816123d2565b94506060880135612496816123d2565b93506080880135925060a088013567ffffffffffffffff8111156124b957600080fd5b6124c58a828b016123f7565b989b979a50959850939692959293505050565b803563ffffffff811681146124ec57600080fd5b919050565b60008060006040848603121561250657600080fd5b61250f846124d8565b9250602084013567ffffffffffffffff81111561252b57600080fd5b612537868287016123f7565b9497909650939450505050565b60008060008060006080868803121561255c57600080fd5b8535612567816123d2565b94506020860135612577816123d2565b935060408601359250606086013567ffffffffffffffff81111561259a57600080fd5b6125a6888289016123f7565b969995985093965092949392505050565b6000806000806000608086880312156125cf57600080fd5b85356125da816123d2565b9450602086013593506125ef604087016124d8565b9250606086013567ffffffffffffffff81111561259a57600080fd5b600080600080600080600060c0888a03121561262657600080fd5b8735612631816123d2565b96506020880135612641816123d2565b95506040880135612651816123d2565b945060608801359350612666608089016124d8565b925060a088013567ffffffffffffffff8111156124b957600080fd5b60005b8381101561269d578181015183820152602001612685565b838111156112765750506000910152565b600081518084526126c6816020860160208601612682565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b602081526000611dd060208301846126ae565b60008060008060008060a0878903121561272457600080fd5b863561272f816123d2565b9550602087013561273f816123d2565b945060408701359350612754606088016124d8565b9250608087013567ffffffffffffffff81111561277057600080fd5b61277c89828a016123f7565b979a9699509497509295939492505050565b600080604083850312156127a157600080fd5b82356127ac816123d2565b915060208301356127bc816123d2565b809150509250929050565b600080600080606085870312156127dd57600080fd5b84356127e8816123d2565b93506127f6602086016124d8565b9250604085013567ffffffffffffffff81111561281257600080fd5b61281e878288016123f7565b95989497509550505050565b60006020828403121561283c57600080fd5b8151611dd0816123d2565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60008282101561288857612888612847565b500390565b600073ffffffffffffffffffffffffffffffffffffffff8087168352808616602084015250836040830152608060608301526128cc60808301846126ae565b9695505050505050565b73ffffffffffffffffffffffffffffffffffffffff8416815260606020820152600061290560608301856126ae565b905063ffffffff83166040830152949350505050565b6000821982111561292e5761292e612847565b500190565b600073ffffffffffffffffffffffffffffffffffffffff80891683528088166020840152808716604084015280861660608401525083608083015260c060a083015261298260c08301846126ae565b98975050505050505050565b73ffffffffffffffffffffffffffffffffffffffff841681528260208201526060604082015260006129c360608301846126ae565b95945050505050565b6000602082840312156129de57600080fd5b81518015158114611dd057600080fd5b8281526040602082015260006121f160408301846126ae565b60008251612a19818460208701612682565b919091019291505056fea164736f6c634300080f000a", + Bin: "0x60a06040523480156200001157600080fd5b5060405162002c8538038062002c858339810160408190526200003491620001e4565b6001600160a01b0381166080526200004b62000052565b5062000216565b600054600390610100900460ff1615801562000075575060005460ff8083169116105b620000de5760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084015b60405180910390fd5b6000805461ffff191660ff8316176101001790556200011173420000000000000000000000000000000000000762000155565b6000805461ff001916905560405160ff821681527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a150565b600054610100900460ff16620001c25760405162461bcd60e51b815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201526a6e697469616c697a696e6760a81b6064820152608401620000d5565b600380546001600160a01b0319166001600160a01b0392909216919091179055565b600060208284031215620001f757600080fd5b81516001600160a01b03811681146200020f57600080fd5b9392505050565b608051612a30620002556000396000818161024e015281816103600152818161058e01528181610a230152818161134001526116820152612a306000f3fe6080604052600436106101125760003560e01c8063662a633a116100a55780638f601f6611610074578063a3a7954811610059578063a3a7954814610428578063c89701a21461023f578063e11013dd1461043b57600080fd5b80638f601f66146103b7578063927ede2d146103fd57600080fd5b8063662a633a1461033b5780637f46ddb21461034e5780638129fc1c14610382578063870876231461039757600080fd5b806336c717c1116100e157806336c717c11461023f5780633cb747bf14610298578063540abf73146102c557806354fd4d50146102e557600080fd5b80630166a07a146101e657806309fc8843146102065780631635f5fd1461021957806332b7006d1461022c57600080fd5b366101e157333b156101ab576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20616e20454f4100000000000000000060648201526084015b60405180910390fd5b6101df73deaddeaddeaddeaddeaddeaddeaddeaddead000033333462030d406040518060200160405280600081525061044e565b005b600080fd5b3480156101f257600080fd5b506101df610201366004612440565b610529565b6101df6102143660046124f1565b6108e7565b6101df610227366004612544565b6109be565b6101df61023a3660046125b7565b610e2c565b34801561024b57600080fd5b507f00000000000000000000000000000000000000000000000000000000000000005b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b3480156102a457600080fd5b5060035461026e9073ffffffffffffffffffffffffffffffffffffffff1681565b3480156102d157600080fd5b506101df6102e036600461260b565b610f06565b3480156102f157600080fd5b5061032e6040518060400160405280600581526020017f312e342e3000000000000000000000000000000000000000000000000000000081525081565b60405161028f91906126f8565b6101df610349366004612440565b610f4b565b34801561035a57600080fd5b5061026e7f000000000000000000000000000000000000000000000000000000000000000081565b34801561038e57600080fd5b506101df610fbe565b3480156103a357600080fd5b506101df6103b236600461270b565b61111b565b3480156103c357600080fd5b506103ef6103d236600461278e565b600260209081526000928352604080842090915290825290205481565b60405190815260200161028f565b34801561040957600080fd5b5060035473ffffffffffffffffffffffffffffffffffffffff1661026e565b6101df61043636600461270b565b6111ef565b6101df6104493660046127c7565b611233565b7fffffffffffffffffffffffff215221522152215221522152215221522153000073ffffffffffffffffffffffffffffffffffffffff87160161049d57610498858585858561127c565b610521565b60008673ffffffffffffffffffffffffffffffffffffffff1663c01e1bd66040518163ffffffff1660e01b8152600401602060405180830381865afa1580156104ea573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061050e919061282a565b905061051f87828888888888611462565b505b505050505050565b60035473ffffffffffffffffffffffffffffffffffffffff16331480156106185750600354604080517f6e296e45000000000000000000000000000000000000000000000000000000008152905173ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000008116931691636e296e459160048083019260209291908290030181865afa1580156105dc573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610600919061282a565b73ffffffffffffffffffffffffffffffffffffffff16145b6106ca576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604160248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20746865206f7468657220627269646760648201527f6500000000000000000000000000000000000000000000000000000000000000608482015260a4016101a2565b6106d3876117aa565b15610821576106e2878761180c565b610794576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604a60248201527f5374616e646172644272696467653a2077726f6e672072656d6f746520746f6b60448201527f656e20666f72204f7074696d69736d204d696e7461626c65204552433230206c60648201527f6f63616c20746f6b656e00000000000000000000000000000000000000000000608482015260a4016101a2565b6040517f40c10f1900000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8581166004830152602482018590528816906340c10f1990604401600060405180830381600087803b15801561080457600080fd5b505af1158015610818573d6000803e3d6000fd5b505050506108a3565b73ffffffffffffffffffffffffffffffffffffffff8088166000908152600260209081526040808320938a168352929052205461085f908490612876565b73ffffffffffffffffffffffffffffffffffffffff8089166000818152600260209081526040808320948c16835293905291909120919091556108a390858561192c565b61051f878787878787878080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250611a0092505050565b333b15610976576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20616e20454f4100000000000000000060648201526084016101a2565b6109b93333348686868080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061127c92505050565b505050565b60035473ffffffffffffffffffffffffffffffffffffffff1633148015610aad5750600354604080517f6e296e45000000000000000000000000000000000000000000000000000000008152905173ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000008116931691636e296e459160048083019260209291908290030181865afa158015610a71573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a95919061282a565b73ffffffffffffffffffffffffffffffffffffffff16145b610b5f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604160248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20746865206f7468657220627269646760648201527f6500000000000000000000000000000000000000000000000000000000000000608482015260a4016101a2565b823414610bee576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603a60248201527f5374616e646172644272696467653a20616d6f756e742073656e7420646f657360448201527f206e6f74206d6174636820616d6f756e7420726571756972656400000000000060648201526084016101a2565b3073ffffffffffffffffffffffffffffffffffffffff851603610c93576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f5374616e646172644272696467653a2063616e6e6f742073656e6420746f207360448201527f656c66000000000000000000000000000000000000000000000000000000000060648201526084016101a2565b60035473ffffffffffffffffffffffffffffffffffffffff90811690851603610d3e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602860248201527f5374616e646172644272696467653a2063616e6e6f742073656e6420746f206d60448201527f657373656e67657200000000000000000000000000000000000000000000000060648201526084016101a2565b610d8085858585858080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250611a8e92505050565b6000610d9d855a8660405180602001604052806000815250611b2f565b905080610521576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f5374616e646172644272696467653a20455448207472616e736665722066616960448201527f6c6564000000000000000000000000000000000000000000000000000000000060648201526084016101a2565b333b15610ebb576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20616e20454f4100000000000000000060648201526084016101a2565b610eff853333878787878080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061044e92505050565b5050505050565b61051f87873388888888888080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061146292505050565b73ffffffffffffffffffffffffffffffffffffffff8716158015610f98575073ffffffffffffffffffffffffffffffffffffffff861673deaddeaddeaddeaddeaddeaddeaddeaddead0000145b15610faf57610faa85858585856109be565b61051f565b61051f86888787878787610529565b600054600390610100900460ff16158015610fe0575060005460ff8083169116105b61106c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a656400000000000000000000000000000000000060648201526084016101a2565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001660ff8316176101001790556110ba734200000000000000000000000000000000000007611b49565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff16905560405160ff821681527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a150565b333b156111aa576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20616e20454f4100000000000000000060648201526084016101a2565b61052186863333888888888080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061146292505050565b610521863387878787878080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061044e92505050565b6112763385348686868080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061127c92505050565b50505050565b82341461130b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603e60248201527f5374616e646172644272696467653a206272696467696e6720455448206d757360448201527f7420696e636c7564652073756666696369656e74204554482076616c7565000060648201526084016101a2565b61131785858584611c27565b60035460405173ffffffffffffffffffffffffffffffffffffffff90911690633dbb202b9085907f0000000000000000000000000000000000000000000000000000000000000000907f1635f5fd0000000000000000000000000000000000000000000000000000000090611396908b908b9086908a9060240161288d565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009485161790525160e086901b9092168252611429929188906004016128d6565b6000604051808303818588803b15801561144257600080fd5b505af1158015611456573d6000803e3d6000fd5b50505050505050505050565b61146b876117aa565b156115b95761147a878761180c565b61152c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604a60248201527f5374616e646172644272696467653a2077726f6e672072656d6f746520746f6b60448201527f656e20666f72204f7074696d69736d204d696e7461626c65204552433230206c60648201527f6f63616c20746f6b656e00000000000000000000000000000000000000000000608482015260a4016101a2565b6040517f9dc29fac00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015260248201859052881690639dc29fac90604401600060405180830381600087803b15801561159c57600080fd5b505af11580156115b0573d6000803e3d6000fd5b5050505061164d565b6115db73ffffffffffffffffffffffffffffffffffffffff8816863086611cc8565b73ffffffffffffffffffffffffffffffffffffffff8088166000908152600260209081526040808320938a168352929052205461161990849061291b565b73ffffffffffffffffffffffffffffffffffffffff8089166000908152600260209081526040808320938b16835292905220555b61165b878787878786611d26565b60035460405173ffffffffffffffffffffffffffffffffffffffff90911690633dbb202b907f0000000000000000000000000000000000000000000000000000000000000000907f0166a07a00000000000000000000000000000000000000000000000000000000906116dc908b908d908c908c908c908b90602401612933565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009485161790525160e085901b909216825261176f929187906004016128d6565b600060405180830381600087803b15801561178957600080fd5b505af115801561179d573d6000803e3d6000fd5b5050505050505050505050565b60006117d6827f1d1d8b6300000000000000000000000000000000000000000000000000000000611db4565b806118065750611806827fec4fc8e300000000000000000000000000000000000000000000000000000000611db4565b92915050565b6000611838837f1d1d8b6300000000000000000000000000000000000000000000000000000000611db4565b156118e1578273ffffffffffffffffffffffffffffffffffffffff1663c01e1bd66040518163ffffffff1660e01b8152600401602060405180830381865afa158015611888573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906118ac919061282a565b73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16149050611806565b8273ffffffffffffffffffffffffffffffffffffffff1663d6c0b2c46040518163ffffffff1660e01b8152600401602060405180830381865afa158015611888573d6000803e3d6000fd5b60405173ffffffffffffffffffffffffffffffffffffffff83166024820152604481018290526109b99084907fa9059cbb00000000000000000000000000000000000000000000000000000000906064015b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff0000000000000000000000000000000000000000000000000000000090931692909217909152611dd7565b8373ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff167fb0444523268717a02698be47d0803aa7468c00acbed2f8bd93a0459cde61dd89868686604051611a789392919061298e565b60405180910390a4610521868686868686611ee3565b8373ffffffffffffffffffffffffffffffffffffffff1673deaddeaddeaddeaddeaddeaddeaddeaddead000073ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fb0444523268717a02698be47d0803aa7468c00acbed2f8bd93a0459cde61dd89868686604051611b1b9392919061298e565b60405180910390a461127684848484611f6b565b600080600080845160208601878a8af19695505050505050565b600054610100900460ff16611be0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e6700000000000000000000000000000000000000000060648201526084016101a2565b600380547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b8373ffffffffffffffffffffffffffffffffffffffff1673deaddeaddeaddeaddeaddeaddeaddeaddead000073ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167f73d170910aba9e6d50b102db522b1dbcd796216f5128b445aa2135272886497e868686604051611cb49392919061298e565b60405180910390a461127684848484611fd8565b60405173ffffffffffffffffffffffffffffffffffffffff808516602483015283166044820152606481018290526112769085907f23b872dd000000000000000000000000000000000000000000000000000000009060840161197e565b8373ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff167f73d170910aba9e6d50b102db522b1dbcd796216f5128b445aa2135272886497e868686604051611d9e9392919061298e565b60405180910390a4610521868686868686612037565b6000611dbf836120af565b8015611dd05750611dd08383612113565b9392505050565b6000611e39826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c65648152508573ffffffffffffffffffffffffffffffffffffffff166121e29092919063ffffffff16565b8051909150156109b95780806020019051810190611e5791906129cc565b6109b9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e60448201527f6f7420737563636565640000000000000000000000000000000000000000000060648201526084016101a2565b8373ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff167fd59c65b35445225835c83f50b6ede06a7be047d22e357073e250d9af537518cd868686604051611f5b9392919061298e565b60405180910390a4505050505050565b8273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167f31b2166ff604fc5672ea5df08a78081d2bc6d746cadce880747f3643d819e83d8484604051611fca9291906129ee565b60405180910390a350505050565b8273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167f2849b43074093a05396b6f2a937dee8565b15a48a7b3d4bffb732a5017380af58484604051611fca9291906129ee565b8373ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff167f7ff126db8024424bbfd9826e8ab82ff59136289ea440b04b39a0df1b03b9cabf868686604051611f5b9392919061298e565b60006120db827f01ffc9a700000000000000000000000000000000000000000000000000000000612113565b8015611806575061210c827fffffffff00000000000000000000000000000000000000000000000000000000612113565b1592915050565b604080517fffffffff000000000000000000000000000000000000000000000000000000008316602480830191909152825180830390910181526044909101909152602080820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f01ffc9a700000000000000000000000000000000000000000000000000000000178152825160009392849283928392918391908a617530fa92503d915060005190508280156121cb575060208210155b80156121d75750600081115b979650505050505050565b60606121f184846000856121f9565b949350505050565b60608247101561228b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f60448201527f722063616c6c000000000000000000000000000000000000000000000000000060648201526084016101a2565b73ffffffffffffffffffffffffffffffffffffffff85163b612309576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064016101a2565b6000808673ffffffffffffffffffffffffffffffffffffffff1685876040516123329190612a07565b60006040518083038185875af1925050503d806000811461236f576040519150601f19603f3d011682016040523d82523d6000602084013e612374565b606091505b50915091506121d78282866060831561238e575081611dd0565b82511561239e5782518084602001fd5b816040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016101a291906126f8565b73ffffffffffffffffffffffffffffffffffffffff811681146123f457600080fd5b50565b60008083601f84011261240957600080fd5b50813567ffffffffffffffff81111561242157600080fd5b60208301915083602082850101111561243957600080fd5b9250929050565b600080600080600080600060c0888a03121561245b57600080fd5b8735612466816123d2565b96506020880135612476816123d2565b95506040880135612486816123d2565b94506060880135612496816123d2565b93506080880135925060a088013567ffffffffffffffff8111156124b957600080fd5b6124c58a828b016123f7565b989b979a50959850939692959293505050565b803563ffffffff811681146124ec57600080fd5b919050565b60008060006040848603121561250657600080fd5b61250f846124d8565b9250602084013567ffffffffffffffff81111561252b57600080fd5b612537868287016123f7565b9497909650939450505050565b60008060008060006080868803121561255c57600080fd5b8535612567816123d2565b94506020860135612577816123d2565b935060408601359250606086013567ffffffffffffffff81111561259a57600080fd5b6125a6888289016123f7565b969995985093965092949392505050565b6000806000806000608086880312156125cf57600080fd5b85356125da816123d2565b9450602086013593506125ef604087016124d8565b9250606086013567ffffffffffffffff81111561259a57600080fd5b600080600080600080600060c0888a03121561262657600080fd5b8735612631816123d2565b96506020880135612641816123d2565b95506040880135612651816123d2565b945060608801359350612666608089016124d8565b925060a088013567ffffffffffffffff8111156124b957600080fd5b60005b8381101561269d578181015183820152602001612685565b838111156112765750506000910152565b600081518084526126c6816020860160208601612682565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b602081526000611dd060208301846126ae565b60008060008060008060a0878903121561272457600080fd5b863561272f816123d2565b9550602087013561273f816123d2565b945060408701359350612754606088016124d8565b9250608087013567ffffffffffffffff81111561277057600080fd5b61277c89828a016123f7565b979a9699509497509295939492505050565b600080604083850312156127a157600080fd5b82356127ac816123d2565b915060208301356127bc816123d2565b809150509250929050565b600080600080606085870312156127dd57600080fd5b84356127e8816123d2565b93506127f6602086016124d8565b9250604085013567ffffffffffffffff81111561281257600080fd5b61281e878288016123f7565b95989497509550505050565b60006020828403121561283c57600080fd5b8151611dd0816123d2565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60008282101561288857612888612847565b500390565b600073ffffffffffffffffffffffffffffffffffffffff8087168352808616602084015250836040830152608060608301526128cc60808301846126ae565b9695505050505050565b73ffffffffffffffffffffffffffffffffffffffff8416815260606020820152600061290560608301856126ae565b905063ffffffff83166040830152949350505050565b6000821982111561292e5761292e612847565b500190565b600073ffffffffffffffffffffffffffffffffffffffff80891683528088166020840152808716604084015280861660608401525083608083015260c060a083015261298260c08301846126ae565b98975050505050505050565b73ffffffffffffffffffffffffffffffffffffffff841681528260208201526060604082015260006129c360608301846126ae565b95945050505050565b6000602082840312156129de57600080fd5b81518015158114611dd057600080fd5b8281526040602082015260006121f160408301846126ae565b60008251612a19818460208701612682565b919091019291505056fea164736f6c634300080f000a", } // L2StandardBridgeABI is the input ABI used to generate the binding from. diff --git a/op-bindings/bindings/l2standardbridge_more.go b/op-bindings/bindings/l2standardbridge_more.go index cff9b79dd3c45..7ef9a32d886b1 100644 --- a/op-bindings/bindings/l2standardbridge_more.go +++ b/op-bindings/bindings/l2standardbridge_more.go @@ -13,7 +13,7 @@ const L2StandardBridgeStorageLayoutJSON = "{\"storage\":[{\"astId\":1000,\"contr var L2StandardBridgeStorageLayout = new(solc.StorageLayout) -var L2StandardBridgeDeployedBin = "0x6080604052600436106101125760003560e01c8063662a633a116100a55780638f601f6611610074578063a3a7954811610059578063a3a7954814610428578063c89701a21461023f578063e11013dd1461043b57600080fd5b80638f601f66146103b7578063927ede2d146103fd57600080fd5b8063662a633a1461033b5780637f46ddb21461034e5780638129fc1c14610382578063870876231461039757600080fd5b806336c717c1116100e157806336c717c11461023f5780633cb747bf14610298578063540abf73146102c557806354fd4d50146102e557600080fd5b80630166a07a146101e657806309fc8843146102065780631635f5fd1461021957806332b7006d1461022c57600080fd5b366101e157333b156101ab576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20616e20454f4100000000000000000060648201526084015b60405180910390fd5b6101df73deaddeaddeaddeaddeaddeaddeaddeaddead000033333462030d406040518060200160405280600081525061044e565b005b600080fd5b3480156101f257600080fd5b506101df610201366004612440565b610529565b6101df6102143660046124f1565b6108e7565b6101df610227366004612544565b6109be565b6101df61023a3660046125b7565b610e2c565b34801561024b57600080fd5b507f00000000000000000000000000000000000000000000000000000000000000005b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b3480156102a457600080fd5b5060035461026e9073ffffffffffffffffffffffffffffffffffffffff1681565b3480156102d157600080fd5b506101df6102e036600461260b565b610f06565b3480156102f157600080fd5b5061032e6040518060400160405280600581526020017f312e332e3000000000000000000000000000000000000000000000000000000081525081565b60405161028f91906126f8565b6101df610349366004612440565b610f4b565b34801561035a57600080fd5b5061026e7f000000000000000000000000000000000000000000000000000000000000000081565b34801561038e57600080fd5b506101df610fbe565b3480156103a357600080fd5b506101df6103b236600461270b565b61111b565b3480156103c357600080fd5b506103ef6103d236600461278e565b600260209081526000928352604080842090915290825290205481565b60405190815260200161028f565b34801561040957600080fd5b5060035473ffffffffffffffffffffffffffffffffffffffff1661026e565b6101df61043636600461270b565b6111ef565b6101df6104493660046127c7565b611233565b7fffffffffffffffffffffffff215221522152215221522152215221522153000073ffffffffffffffffffffffffffffffffffffffff87160161049d57610498858585858561127c565b610521565b60008673ffffffffffffffffffffffffffffffffffffffff1663c01e1bd66040518163ffffffff1660e01b8152600401602060405180830381865afa1580156104ea573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061050e919061282a565b905061051f87828888888888611462565b505b505050505050565b60035473ffffffffffffffffffffffffffffffffffffffff16331480156106185750600354604080517f6e296e45000000000000000000000000000000000000000000000000000000008152905173ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000008116931691636e296e459160048083019260209291908290030181865afa1580156105dc573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610600919061282a565b73ffffffffffffffffffffffffffffffffffffffff16145b6106ca576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604160248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20746865206f7468657220627269646760648201527f6500000000000000000000000000000000000000000000000000000000000000608482015260a4016101a2565b6106d3876117aa565b15610821576106e2878761180c565b610794576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604a60248201527f5374616e646172644272696467653a2077726f6e672072656d6f746520746f6b60448201527f656e20666f72204f7074696d69736d204d696e7461626c65204552433230206c60648201527f6f63616c20746f6b656e00000000000000000000000000000000000000000000608482015260a4016101a2565b6040517f40c10f1900000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8581166004830152602482018590528816906340c10f1990604401600060405180830381600087803b15801561080457600080fd5b505af1158015610818573d6000803e3d6000fd5b505050506108a3565b73ffffffffffffffffffffffffffffffffffffffff8088166000908152600260209081526040808320938a168352929052205461085f908490612876565b73ffffffffffffffffffffffffffffffffffffffff8089166000818152600260209081526040808320948c16835293905291909120919091556108a390858561192c565b61051f878787878787878080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250611a0092505050565b333b15610976576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20616e20454f4100000000000000000060648201526084016101a2565b6109b93333348686868080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061127c92505050565b505050565b60035473ffffffffffffffffffffffffffffffffffffffff1633148015610aad5750600354604080517f6e296e45000000000000000000000000000000000000000000000000000000008152905173ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000008116931691636e296e459160048083019260209291908290030181865afa158015610a71573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a95919061282a565b73ffffffffffffffffffffffffffffffffffffffff16145b610b5f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604160248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20746865206f7468657220627269646760648201527f6500000000000000000000000000000000000000000000000000000000000000608482015260a4016101a2565b823414610bee576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603a60248201527f5374616e646172644272696467653a20616d6f756e742073656e7420646f657360448201527f206e6f74206d6174636820616d6f756e7420726571756972656400000000000060648201526084016101a2565b3073ffffffffffffffffffffffffffffffffffffffff851603610c93576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f5374616e646172644272696467653a2063616e6e6f742073656e6420746f207360448201527f656c66000000000000000000000000000000000000000000000000000000000060648201526084016101a2565b60035473ffffffffffffffffffffffffffffffffffffffff90811690851603610d3e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602860248201527f5374616e646172644272696467653a2063616e6e6f742073656e6420746f206d60448201527f657373656e67657200000000000000000000000000000000000000000000000060648201526084016101a2565b610d8085858585858080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250611a8e92505050565b6000610d9d855a8660405180602001604052806000815250611b2f565b905080610521576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f5374616e646172644272696467653a20455448207472616e736665722066616960448201527f6c6564000000000000000000000000000000000000000000000000000000000060648201526084016101a2565b333b15610ebb576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20616e20454f4100000000000000000060648201526084016101a2565b610eff853333878787878080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061044e92505050565b5050505050565b61051f87873388888888888080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061146292505050565b73ffffffffffffffffffffffffffffffffffffffff8716158015610f98575073ffffffffffffffffffffffffffffffffffffffff861673deaddeaddeaddeaddeaddeaddeaddeaddead0000145b15610faf57610faa85858585856109be565b61051f565b61051f86888787878787610529565b600054600290610100900460ff16158015610fe0575060005460ff8083169116105b61106c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a656400000000000000000000000000000000000060648201526084016101a2565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001660ff8316176101001790556110ba734200000000000000000000000000000000000007611b49565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff16905560405160ff821681527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a150565b333b156111aa576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20616e20454f4100000000000000000060648201526084016101a2565b61052186863333888888888080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061146292505050565b610521863387878787878080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061044e92505050565b6112763385348686868080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061127c92505050565b50505050565b82341461130b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603e60248201527f5374616e646172644272696467653a206272696467696e6720455448206d757360448201527f7420696e636c7564652073756666696369656e74204554482076616c7565000060648201526084016101a2565b61131785858584611c27565b60035460405173ffffffffffffffffffffffffffffffffffffffff90911690633dbb202b9085907f0000000000000000000000000000000000000000000000000000000000000000907f1635f5fd0000000000000000000000000000000000000000000000000000000090611396908b908b9086908a9060240161288d565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009485161790525160e086901b9092168252611429929188906004016128d6565b6000604051808303818588803b15801561144257600080fd5b505af1158015611456573d6000803e3d6000fd5b50505050505050505050565b61146b876117aa565b156115b95761147a878761180c565b61152c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604a60248201527f5374616e646172644272696467653a2077726f6e672072656d6f746520746f6b60448201527f656e20666f72204f7074696d69736d204d696e7461626c65204552433230206c60648201527f6f63616c20746f6b656e00000000000000000000000000000000000000000000608482015260a4016101a2565b6040517f9dc29fac00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015260248201859052881690639dc29fac90604401600060405180830381600087803b15801561159c57600080fd5b505af11580156115b0573d6000803e3d6000fd5b5050505061164d565b6115db73ffffffffffffffffffffffffffffffffffffffff8816863086611cc8565b73ffffffffffffffffffffffffffffffffffffffff8088166000908152600260209081526040808320938a168352929052205461161990849061291b565b73ffffffffffffffffffffffffffffffffffffffff8089166000908152600260209081526040808320938b16835292905220555b61165b878787878786611d26565b60035460405173ffffffffffffffffffffffffffffffffffffffff90911690633dbb202b907f0000000000000000000000000000000000000000000000000000000000000000907f0166a07a00000000000000000000000000000000000000000000000000000000906116dc908b908d908c908c908c908b90602401612933565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009485161790525160e085901b909216825261176f929187906004016128d6565b600060405180830381600087803b15801561178957600080fd5b505af115801561179d573d6000803e3d6000fd5b5050505050505050505050565b60006117d6827f1d1d8b6300000000000000000000000000000000000000000000000000000000611db4565b806118065750611806827fec4fc8e300000000000000000000000000000000000000000000000000000000611db4565b92915050565b6000611838837f1d1d8b6300000000000000000000000000000000000000000000000000000000611db4565b156118e1578273ffffffffffffffffffffffffffffffffffffffff1663c01e1bd66040518163ffffffff1660e01b8152600401602060405180830381865afa158015611888573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906118ac919061282a565b73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16149050611806565b8273ffffffffffffffffffffffffffffffffffffffff1663d6c0b2c46040518163ffffffff1660e01b8152600401602060405180830381865afa158015611888573d6000803e3d6000fd5b60405173ffffffffffffffffffffffffffffffffffffffff83166024820152604481018290526109b99084907fa9059cbb00000000000000000000000000000000000000000000000000000000906064015b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff0000000000000000000000000000000000000000000000000000000090931692909217909152611dd7565b8373ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff167fb0444523268717a02698be47d0803aa7468c00acbed2f8bd93a0459cde61dd89868686604051611a789392919061298e565b60405180910390a4610521868686868686611ee3565b8373ffffffffffffffffffffffffffffffffffffffff1673deaddeaddeaddeaddeaddeaddeaddeaddead000073ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fb0444523268717a02698be47d0803aa7468c00acbed2f8bd93a0459cde61dd89868686604051611b1b9392919061298e565b60405180910390a461127684848484611f6b565b600080600080845160208601878a8af19695505050505050565b600054610100900460ff16611be0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e6700000000000000000000000000000000000000000060648201526084016101a2565b600380547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b8373ffffffffffffffffffffffffffffffffffffffff1673deaddeaddeaddeaddeaddeaddeaddeaddead000073ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167f73d170910aba9e6d50b102db522b1dbcd796216f5128b445aa2135272886497e868686604051611cb49392919061298e565b60405180910390a461127684848484611fd8565b60405173ffffffffffffffffffffffffffffffffffffffff808516602483015283166044820152606481018290526112769085907f23b872dd000000000000000000000000000000000000000000000000000000009060840161197e565b8373ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff167f73d170910aba9e6d50b102db522b1dbcd796216f5128b445aa2135272886497e868686604051611d9e9392919061298e565b60405180910390a4610521868686868686612037565b6000611dbf836120af565b8015611dd05750611dd08383612113565b9392505050565b6000611e39826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c65648152508573ffffffffffffffffffffffffffffffffffffffff166121e29092919063ffffffff16565b8051909150156109b95780806020019051810190611e5791906129cc565b6109b9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e60448201527f6f7420737563636565640000000000000000000000000000000000000000000060648201526084016101a2565b8373ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff167fd59c65b35445225835c83f50b6ede06a7be047d22e357073e250d9af537518cd868686604051611f5b9392919061298e565b60405180910390a4505050505050565b8273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167f31b2166ff604fc5672ea5df08a78081d2bc6d746cadce880747f3643d819e83d8484604051611fca9291906129ee565b60405180910390a350505050565b8273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167f2849b43074093a05396b6f2a937dee8565b15a48a7b3d4bffb732a5017380af58484604051611fca9291906129ee565b8373ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff167f7ff126db8024424bbfd9826e8ab82ff59136289ea440b04b39a0df1b03b9cabf868686604051611f5b9392919061298e565b60006120db827f01ffc9a700000000000000000000000000000000000000000000000000000000612113565b8015611806575061210c827fffffffff00000000000000000000000000000000000000000000000000000000612113565b1592915050565b604080517fffffffff000000000000000000000000000000000000000000000000000000008316602480830191909152825180830390910181526044909101909152602080820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f01ffc9a700000000000000000000000000000000000000000000000000000000178152825160009392849283928392918391908a617530fa92503d915060005190508280156121cb575060208210155b80156121d75750600081115b979650505050505050565b60606121f184846000856121f9565b949350505050565b60608247101561228b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f60448201527f722063616c6c000000000000000000000000000000000000000000000000000060648201526084016101a2565b73ffffffffffffffffffffffffffffffffffffffff85163b612309576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064016101a2565b6000808673ffffffffffffffffffffffffffffffffffffffff1685876040516123329190612a07565b60006040518083038185875af1925050503d806000811461236f576040519150601f19603f3d011682016040523d82523d6000602084013e612374565b606091505b50915091506121d78282866060831561238e575081611dd0565b82511561239e5782518084602001fd5b816040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016101a291906126f8565b73ffffffffffffffffffffffffffffffffffffffff811681146123f457600080fd5b50565b60008083601f84011261240957600080fd5b50813567ffffffffffffffff81111561242157600080fd5b60208301915083602082850101111561243957600080fd5b9250929050565b600080600080600080600060c0888a03121561245b57600080fd5b8735612466816123d2565b96506020880135612476816123d2565b95506040880135612486816123d2565b94506060880135612496816123d2565b93506080880135925060a088013567ffffffffffffffff8111156124b957600080fd5b6124c58a828b016123f7565b989b979a50959850939692959293505050565b803563ffffffff811681146124ec57600080fd5b919050565b60008060006040848603121561250657600080fd5b61250f846124d8565b9250602084013567ffffffffffffffff81111561252b57600080fd5b612537868287016123f7565b9497909650939450505050565b60008060008060006080868803121561255c57600080fd5b8535612567816123d2565b94506020860135612577816123d2565b935060408601359250606086013567ffffffffffffffff81111561259a57600080fd5b6125a6888289016123f7565b969995985093965092949392505050565b6000806000806000608086880312156125cf57600080fd5b85356125da816123d2565b9450602086013593506125ef604087016124d8565b9250606086013567ffffffffffffffff81111561259a57600080fd5b600080600080600080600060c0888a03121561262657600080fd5b8735612631816123d2565b96506020880135612641816123d2565b95506040880135612651816123d2565b945060608801359350612666608089016124d8565b925060a088013567ffffffffffffffff8111156124b957600080fd5b60005b8381101561269d578181015183820152602001612685565b838111156112765750506000910152565b600081518084526126c6816020860160208601612682565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b602081526000611dd060208301846126ae565b60008060008060008060a0878903121561272457600080fd5b863561272f816123d2565b9550602087013561273f816123d2565b945060408701359350612754606088016124d8565b9250608087013567ffffffffffffffff81111561277057600080fd5b61277c89828a016123f7565b979a9699509497509295939492505050565b600080604083850312156127a157600080fd5b82356127ac816123d2565b915060208301356127bc816123d2565b809150509250929050565b600080600080606085870312156127dd57600080fd5b84356127e8816123d2565b93506127f6602086016124d8565b9250604085013567ffffffffffffffff81111561281257600080fd5b61281e878288016123f7565b95989497509550505050565b60006020828403121561283c57600080fd5b8151611dd0816123d2565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60008282101561288857612888612847565b500390565b600073ffffffffffffffffffffffffffffffffffffffff8087168352808616602084015250836040830152608060608301526128cc60808301846126ae565b9695505050505050565b73ffffffffffffffffffffffffffffffffffffffff8416815260606020820152600061290560608301856126ae565b905063ffffffff83166040830152949350505050565b6000821982111561292e5761292e612847565b500190565b600073ffffffffffffffffffffffffffffffffffffffff80891683528088166020840152808716604084015280861660608401525083608083015260c060a083015261298260c08301846126ae565b98975050505050505050565b73ffffffffffffffffffffffffffffffffffffffff841681528260208201526060604082015260006129c360608301846126ae565b95945050505050565b6000602082840312156129de57600080fd5b81518015158114611dd057600080fd5b8281526040602082015260006121f160408301846126ae565b60008251612a19818460208701612682565b919091019291505056fea164736f6c634300080f000a" +var L2StandardBridgeDeployedBin = "0x6080604052600436106101125760003560e01c8063662a633a116100a55780638f601f6611610074578063a3a7954811610059578063a3a7954814610428578063c89701a21461023f578063e11013dd1461043b57600080fd5b80638f601f66146103b7578063927ede2d146103fd57600080fd5b8063662a633a1461033b5780637f46ddb21461034e5780638129fc1c14610382578063870876231461039757600080fd5b806336c717c1116100e157806336c717c11461023f5780633cb747bf14610298578063540abf73146102c557806354fd4d50146102e557600080fd5b80630166a07a146101e657806309fc8843146102065780631635f5fd1461021957806332b7006d1461022c57600080fd5b366101e157333b156101ab576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20616e20454f4100000000000000000060648201526084015b60405180910390fd5b6101df73deaddeaddeaddeaddeaddeaddeaddeaddead000033333462030d406040518060200160405280600081525061044e565b005b600080fd5b3480156101f257600080fd5b506101df610201366004612440565b610529565b6101df6102143660046124f1565b6108e7565b6101df610227366004612544565b6109be565b6101df61023a3660046125b7565b610e2c565b34801561024b57600080fd5b507f00000000000000000000000000000000000000000000000000000000000000005b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b3480156102a457600080fd5b5060035461026e9073ffffffffffffffffffffffffffffffffffffffff1681565b3480156102d157600080fd5b506101df6102e036600461260b565b610f06565b3480156102f157600080fd5b5061032e6040518060400160405280600581526020017f312e342e3000000000000000000000000000000000000000000000000000000081525081565b60405161028f91906126f8565b6101df610349366004612440565b610f4b565b34801561035a57600080fd5b5061026e7f000000000000000000000000000000000000000000000000000000000000000081565b34801561038e57600080fd5b506101df610fbe565b3480156103a357600080fd5b506101df6103b236600461270b565b61111b565b3480156103c357600080fd5b506103ef6103d236600461278e565b600260209081526000928352604080842090915290825290205481565b60405190815260200161028f565b34801561040957600080fd5b5060035473ffffffffffffffffffffffffffffffffffffffff1661026e565b6101df61043636600461270b565b6111ef565b6101df6104493660046127c7565b611233565b7fffffffffffffffffffffffff215221522152215221522152215221522153000073ffffffffffffffffffffffffffffffffffffffff87160161049d57610498858585858561127c565b610521565b60008673ffffffffffffffffffffffffffffffffffffffff1663c01e1bd66040518163ffffffff1660e01b8152600401602060405180830381865afa1580156104ea573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061050e919061282a565b905061051f87828888888888611462565b505b505050505050565b60035473ffffffffffffffffffffffffffffffffffffffff16331480156106185750600354604080517f6e296e45000000000000000000000000000000000000000000000000000000008152905173ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000008116931691636e296e459160048083019260209291908290030181865afa1580156105dc573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610600919061282a565b73ffffffffffffffffffffffffffffffffffffffff16145b6106ca576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604160248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20746865206f7468657220627269646760648201527f6500000000000000000000000000000000000000000000000000000000000000608482015260a4016101a2565b6106d3876117aa565b15610821576106e2878761180c565b610794576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604a60248201527f5374616e646172644272696467653a2077726f6e672072656d6f746520746f6b60448201527f656e20666f72204f7074696d69736d204d696e7461626c65204552433230206c60648201527f6f63616c20746f6b656e00000000000000000000000000000000000000000000608482015260a4016101a2565b6040517f40c10f1900000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8581166004830152602482018590528816906340c10f1990604401600060405180830381600087803b15801561080457600080fd5b505af1158015610818573d6000803e3d6000fd5b505050506108a3565b73ffffffffffffffffffffffffffffffffffffffff8088166000908152600260209081526040808320938a168352929052205461085f908490612876565b73ffffffffffffffffffffffffffffffffffffffff8089166000818152600260209081526040808320948c16835293905291909120919091556108a390858561192c565b61051f878787878787878080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250611a0092505050565b333b15610976576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20616e20454f4100000000000000000060648201526084016101a2565b6109b93333348686868080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061127c92505050565b505050565b60035473ffffffffffffffffffffffffffffffffffffffff1633148015610aad5750600354604080517f6e296e45000000000000000000000000000000000000000000000000000000008152905173ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000008116931691636e296e459160048083019260209291908290030181865afa158015610a71573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a95919061282a565b73ffffffffffffffffffffffffffffffffffffffff16145b610b5f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604160248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20746865206f7468657220627269646760648201527f6500000000000000000000000000000000000000000000000000000000000000608482015260a4016101a2565b823414610bee576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603a60248201527f5374616e646172644272696467653a20616d6f756e742073656e7420646f657360448201527f206e6f74206d6174636820616d6f756e7420726571756972656400000000000060648201526084016101a2565b3073ffffffffffffffffffffffffffffffffffffffff851603610c93576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f5374616e646172644272696467653a2063616e6e6f742073656e6420746f207360448201527f656c66000000000000000000000000000000000000000000000000000000000060648201526084016101a2565b60035473ffffffffffffffffffffffffffffffffffffffff90811690851603610d3e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602860248201527f5374616e646172644272696467653a2063616e6e6f742073656e6420746f206d60448201527f657373656e67657200000000000000000000000000000000000000000000000060648201526084016101a2565b610d8085858585858080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250611a8e92505050565b6000610d9d855a8660405180602001604052806000815250611b2f565b905080610521576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f5374616e646172644272696467653a20455448207472616e736665722066616960448201527f6c6564000000000000000000000000000000000000000000000000000000000060648201526084016101a2565b333b15610ebb576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20616e20454f4100000000000000000060648201526084016101a2565b610eff853333878787878080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061044e92505050565b5050505050565b61051f87873388888888888080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061146292505050565b73ffffffffffffffffffffffffffffffffffffffff8716158015610f98575073ffffffffffffffffffffffffffffffffffffffff861673deaddeaddeaddeaddeaddeaddeaddeaddead0000145b15610faf57610faa85858585856109be565b61051f565b61051f86888787878787610529565b600054600390610100900460ff16158015610fe0575060005460ff8083169116105b61106c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a656400000000000000000000000000000000000060648201526084016101a2565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001660ff8316176101001790556110ba734200000000000000000000000000000000000007611b49565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff16905560405160ff821681527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a150565b333b156111aa576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603760248201527f5374616e646172644272696467653a2066756e6374696f6e2063616e206f6e6c60448201527f792062652063616c6c65642066726f6d20616e20454f4100000000000000000060648201526084016101a2565b61052186863333888888888080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061146292505050565b610521863387878787878080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061044e92505050565b6112763385348686868080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061127c92505050565b50505050565b82341461130b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603e60248201527f5374616e646172644272696467653a206272696467696e6720455448206d757360448201527f7420696e636c7564652073756666696369656e74204554482076616c7565000060648201526084016101a2565b61131785858584611c27565b60035460405173ffffffffffffffffffffffffffffffffffffffff90911690633dbb202b9085907f0000000000000000000000000000000000000000000000000000000000000000907f1635f5fd0000000000000000000000000000000000000000000000000000000090611396908b908b9086908a9060240161288d565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009485161790525160e086901b9092168252611429929188906004016128d6565b6000604051808303818588803b15801561144257600080fd5b505af1158015611456573d6000803e3d6000fd5b50505050505050505050565b61146b876117aa565b156115b95761147a878761180c565b61152c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604a60248201527f5374616e646172644272696467653a2077726f6e672072656d6f746520746f6b60448201527f656e20666f72204f7074696d69736d204d696e7461626c65204552433230206c60648201527f6f63616c20746f6b656e00000000000000000000000000000000000000000000608482015260a4016101a2565b6040517f9dc29fac00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015260248201859052881690639dc29fac90604401600060405180830381600087803b15801561159c57600080fd5b505af11580156115b0573d6000803e3d6000fd5b5050505061164d565b6115db73ffffffffffffffffffffffffffffffffffffffff8816863086611cc8565b73ffffffffffffffffffffffffffffffffffffffff8088166000908152600260209081526040808320938a168352929052205461161990849061291b565b73ffffffffffffffffffffffffffffffffffffffff8089166000908152600260209081526040808320938b16835292905220555b61165b878787878786611d26565b60035460405173ffffffffffffffffffffffffffffffffffffffff90911690633dbb202b907f0000000000000000000000000000000000000000000000000000000000000000907f0166a07a00000000000000000000000000000000000000000000000000000000906116dc908b908d908c908c908c908b90602401612933565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009485161790525160e085901b909216825261176f929187906004016128d6565b600060405180830381600087803b15801561178957600080fd5b505af115801561179d573d6000803e3d6000fd5b5050505050505050505050565b60006117d6827f1d1d8b6300000000000000000000000000000000000000000000000000000000611db4565b806118065750611806827fec4fc8e300000000000000000000000000000000000000000000000000000000611db4565b92915050565b6000611838837f1d1d8b6300000000000000000000000000000000000000000000000000000000611db4565b156118e1578273ffffffffffffffffffffffffffffffffffffffff1663c01e1bd66040518163ffffffff1660e01b8152600401602060405180830381865afa158015611888573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906118ac919061282a565b73ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16149050611806565b8273ffffffffffffffffffffffffffffffffffffffff1663d6c0b2c46040518163ffffffff1660e01b8152600401602060405180830381865afa158015611888573d6000803e3d6000fd5b60405173ffffffffffffffffffffffffffffffffffffffff83166024820152604481018290526109b99084907fa9059cbb00000000000000000000000000000000000000000000000000000000906064015b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff0000000000000000000000000000000000000000000000000000000090931692909217909152611dd7565b8373ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff167fb0444523268717a02698be47d0803aa7468c00acbed2f8bd93a0459cde61dd89868686604051611a789392919061298e565b60405180910390a4610521868686868686611ee3565b8373ffffffffffffffffffffffffffffffffffffffff1673deaddeaddeaddeaddeaddeaddeaddeaddead000073ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fb0444523268717a02698be47d0803aa7468c00acbed2f8bd93a0459cde61dd89868686604051611b1b9392919061298e565b60405180910390a461127684848484611f6b565b600080600080845160208601878a8af19695505050505050565b600054610100900460ff16611be0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e6700000000000000000000000000000000000000000060648201526084016101a2565b600380547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b8373ffffffffffffffffffffffffffffffffffffffff1673deaddeaddeaddeaddeaddeaddeaddeaddead000073ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167f73d170910aba9e6d50b102db522b1dbcd796216f5128b445aa2135272886497e868686604051611cb49392919061298e565b60405180910390a461127684848484611fd8565b60405173ffffffffffffffffffffffffffffffffffffffff808516602483015283166044820152606481018290526112769085907f23b872dd000000000000000000000000000000000000000000000000000000009060840161197e565b8373ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff167f73d170910aba9e6d50b102db522b1dbcd796216f5128b445aa2135272886497e868686604051611d9e9392919061298e565b60405180910390a4610521868686868686612037565b6000611dbf836120af565b8015611dd05750611dd08383612113565b9392505050565b6000611e39826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c65648152508573ffffffffffffffffffffffffffffffffffffffff166121e29092919063ffffffff16565b8051909150156109b95780806020019051810190611e5791906129cc565b6109b9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e60448201527f6f7420737563636565640000000000000000000000000000000000000000000060648201526084016101a2565b8373ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff167fd59c65b35445225835c83f50b6ede06a7be047d22e357073e250d9af537518cd868686604051611f5b9392919061298e565b60405180910390a4505050505050565b8273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167f31b2166ff604fc5672ea5df08a78081d2bc6d746cadce880747f3643d819e83d8484604051611fca9291906129ee565b60405180910390a350505050565b8273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167f2849b43074093a05396b6f2a937dee8565b15a48a7b3d4bffb732a5017380af58484604051611fca9291906129ee565b8373ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff167f7ff126db8024424bbfd9826e8ab82ff59136289ea440b04b39a0df1b03b9cabf868686604051611f5b9392919061298e565b60006120db827f01ffc9a700000000000000000000000000000000000000000000000000000000612113565b8015611806575061210c827fffffffff00000000000000000000000000000000000000000000000000000000612113565b1592915050565b604080517fffffffff000000000000000000000000000000000000000000000000000000008316602480830191909152825180830390910181526044909101909152602080820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f01ffc9a700000000000000000000000000000000000000000000000000000000178152825160009392849283928392918391908a617530fa92503d915060005190508280156121cb575060208210155b80156121d75750600081115b979650505050505050565b60606121f184846000856121f9565b949350505050565b60608247101561228b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f60448201527f722063616c6c000000000000000000000000000000000000000000000000000060648201526084016101a2565b73ffffffffffffffffffffffffffffffffffffffff85163b612309576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064016101a2565b6000808673ffffffffffffffffffffffffffffffffffffffff1685876040516123329190612a07565b60006040518083038185875af1925050503d806000811461236f576040519150601f19603f3d011682016040523d82523d6000602084013e612374565b606091505b50915091506121d78282866060831561238e575081611dd0565b82511561239e5782518084602001fd5b816040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016101a291906126f8565b73ffffffffffffffffffffffffffffffffffffffff811681146123f457600080fd5b50565b60008083601f84011261240957600080fd5b50813567ffffffffffffffff81111561242157600080fd5b60208301915083602082850101111561243957600080fd5b9250929050565b600080600080600080600060c0888a03121561245b57600080fd5b8735612466816123d2565b96506020880135612476816123d2565b95506040880135612486816123d2565b94506060880135612496816123d2565b93506080880135925060a088013567ffffffffffffffff8111156124b957600080fd5b6124c58a828b016123f7565b989b979a50959850939692959293505050565b803563ffffffff811681146124ec57600080fd5b919050565b60008060006040848603121561250657600080fd5b61250f846124d8565b9250602084013567ffffffffffffffff81111561252b57600080fd5b612537868287016123f7565b9497909650939450505050565b60008060008060006080868803121561255c57600080fd5b8535612567816123d2565b94506020860135612577816123d2565b935060408601359250606086013567ffffffffffffffff81111561259a57600080fd5b6125a6888289016123f7565b969995985093965092949392505050565b6000806000806000608086880312156125cf57600080fd5b85356125da816123d2565b9450602086013593506125ef604087016124d8565b9250606086013567ffffffffffffffff81111561259a57600080fd5b600080600080600080600060c0888a03121561262657600080fd5b8735612631816123d2565b96506020880135612641816123d2565b95506040880135612651816123d2565b945060608801359350612666608089016124d8565b925060a088013567ffffffffffffffff8111156124b957600080fd5b60005b8381101561269d578181015183820152602001612685565b838111156112765750506000910152565b600081518084526126c6816020860160208601612682565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b602081526000611dd060208301846126ae565b60008060008060008060a0878903121561272457600080fd5b863561272f816123d2565b9550602087013561273f816123d2565b945060408701359350612754606088016124d8565b9250608087013567ffffffffffffffff81111561277057600080fd5b61277c89828a016123f7565b979a9699509497509295939492505050565b600080604083850312156127a157600080fd5b82356127ac816123d2565b915060208301356127bc816123d2565b809150509250929050565b600080600080606085870312156127dd57600080fd5b84356127e8816123d2565b93506127f6602086016124d8565b9250604085013567ffffffffffffffff81111561281257600080fd5b61281e878288016123f7565b95989497509550505050565b60006020828403121561283c57600080fd5b8151611dd0816123d2565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60008282101561288857612888612847565b500390565b600073ffffffffffffffffffffffffffffffffffffffff8087168352808616602084015250836040830152608060608301526128cc60808301846126ae565b9695505050505050565b73ffffffffffffffffffffffffffffffffffffffff8416815260606020820152600061290560608301856126ae565b905063ffffffff83166040830152949350505050565b6000821982111561292e5761292e612847565b500190565b600073ffffffffffffffffffffffffffffffffffffffff80891683528088166020840152808716604084015280861660608401525083608083015260c060a083015261298260c08301846126ae565b98975050505050505050565b73ffffffffffffffffffffffffffffffffffffffff841681528260208201526060604082015260006129c360608301846126ae565b95945050505050565b6000602082840312156129de57600080fd5b81518015158114611dd057600080fd5b8281526040602082015260006121f160408301846126ae565b60008251612a19818460208701612682565b919091019291505056fea164736f6c634300080f000a" func init() { if err := json.Unmarshal([]byte(L2StandardBridgeStorageLayoutJSON), L2StandardBridgeStorageLayout); err != nil { diff --git a/op-bindings/bindings/legacyerc20eth.go b/op-bindings/bindings/legacyerc20eth.go index 6b0cf74b9d2f3..7b433a8206fee 100644 --- a/op-bindings/bindings/legacyerc20eth.go +++ b/op-bindings/bindings/legacyerc20eth.go @@ -31,7 +31,7 @@ var ( // LegacyERC20ETHMetaData contains all meta data concerning the LegacyERC20ETH contract. var LegacyERC20ETHMetaData = &bind.MetaData{ ABI: "[{\"inputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Approval\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"Burn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"Mint\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Transfer\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"BRIDGE\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"REMOTE_TOKEN\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"}],\"name\":\"allowance\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"approve\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_who\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"bridge\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"burn\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"decimals\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"decreaseAllowance\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"increaseAllowance\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"l1Token\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"l2Bridge\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"mint\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"name\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"remoteToken\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes4\",\"name\":\"_interfaceId\",\"type\":\"bytes4\"}],\"name\":\"supportsInterface\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"symbol\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"totalSupply\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"transfer\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"transferFrom\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"version\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", - Bin: "0x6101406040523480156200001257600080fd5b5073420000000000000000000000000000000000001060006040518060400160405280600581526020016422ba3432b960d91b8152506040518060400160405280600381526020016208aa8960eb1b8152506012600160026000858581600390816200007f919062000167565b5060046200008e828262000167565b50505060809290925260a05260c0526001600160a01b0393841660e0529390921661010052505060ff166101205262000233565b634e487b7160e01b600052604160045260246000fd5b600181811c90821680620000ed57607f821691505b6020821081036200010e57634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200016257600081815260208120601f850160051c810160208610156200013d5750805b601f850160051c820191505b818110156200015e5782815560010162000149565b5050505b505050565b81516001600160401b03811115620001835762000183620000c2565b6200019b81620001948454620000d8565b8462000114565b602080601f831160018114620001d35760008415620001ba5750858301515b600019600386901b1c1916600185901b1785556200015e565b600085815260208120601f198616915b828110156200020457888601518255948401946001909101908401620001e3565b5085821015620002235787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b60805160a05160c05160e0516101005161012051610e79620002916000396000610244015260008181610309015261039e0152600081816101a9015261032f015260006107a40152600061077b015260006107520152610e796000f3fe608060405234801561001057600080fd5b50600436106101775760003560e01c806370a08231116100d8578063ae1f6aaf1161008c578063dd62ed3e11610066578063dd62ed3e14610353578063e78cea9214610307578063ee9a31a21461039957600080fd5b8063ae1f6aaf14610307578063c01e1bd61461032d578063d6c0b2c41461032d57600080fd5b80639dc29fac116100bd5780639dc29fac146102ce578063a457c2d7146102e1578063a9059cbb146102f457600080fd5b806370a082311461029e57806395d89b41146102c657600080fd5b806323b872dd1161012f5780633950935111610114578063395093511461026e57806340c10f191461028157806354fd4d501461029657600080fd5b806323b872dd1461022a578063313ce5671461023d57600080fd5b806306fdde031161016057806306fdde03146101f0578063095ea7b31461020557806318160ddd1461021857600080fd5b806301ffc9a71461017c578063033964be146101a4575b600080fd5b61018f61018a366004610ab1565b6103c0565b60405190151581526020015b60405180910390f35b6101cb7f000000000000000000000000000000000000000000000000000000000000000081565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161019b565b6101f86104b1565b60405161019b9190610b2a565b61018f610213366004610ba4565b610543565b6002545b60405190815260200161019b565b61018f610238366004610bce565b6105d3565b60405160ff7f000000000000000000000000000000000000000000000000000000000000000016815260200161019b565b61018f61027c366004610ba4565b61065e565b61029461028f366004610ba4565b6106e9565b005b6101f861074b565b61021c6102ac366004610c0a565b73ffffffffffffffffffffffffffffffffffffffff163190565b6101f86107ee565b6102946102dc366004610ba4565b6107fd565b61018f6102ef366004610ba4565b61085f565b61018f610302366004610ba4565b6108ea565b7f00000000000000000000000000000000000000000000000000000000000000006101cb565b7f00000000000000000000000000000000000000000000000000000000000000006101cb565b61021c610361366004610c25565b73ffffffffffffffffffffffffffffffffffffffff918216600090815260016020908152604080832093909416825291909152205490565b6101cb7f000000000000000000000000000000000000000000000000000000000000000081565b60007f01ffc9a7000000000000000000000000000000000000000000000000000000007f1d1d8b63000000000000000000000000000000000000000000000000000000007fec4fc8e3000000000000000000000000000000000000000000000000000000007fffffffff00000000000000000000000000000000000000000000000000000000851683148061047957507fffffffff00000000000000000000000000000000000000000000000000000000858116908316145b806104a857507fffffffff00000000000000000000000000000000000000000000000000000000858116908216145b95945050505050565b6060600380546104c090610c58565b80601f01602080910402602001604051908101604052809291908181526020018280546104ec90610c58565b80156105395780601f1061050e57610100808354040283529160200191610539565b820191906000526020600020905b81548152906001019060200180831161051c57829003601f168201915b5050505050905090565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f4c656761637945524332304554483a20617070726f766520697320646973616260448201527f6c6564000000000000000000000000000000000000000000000000000000000060648201526000906084015b60405180910390fd5b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602860248201527f4c656761637945524332304554483a207472616e7366657246726f6d2069732060448201527f64697361626c656400000000000000000000000000000000000000000000000060648201526000906084016105ca565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602d60248201527f4c656761637945524332304554483a20696e637265617365416c6c6f77616e6360448201527f652069732064697361626c65640000000000000000000000000000000000000060648201526000906084016105ca565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4c656761637945524332304554483a206d696e742069732064697361626c656460448201526064016105ca565b60606107767f0000000000000000000000000000000000000000000000000000000000000000610974565b61079f7f0000000000000000000000000000000000000000000000000000000000000000610974565b6107c87f0000000000000000000000000000000000000000000000000000000000000000610974565b6040516020016107da93929190610cab565b604051602081830303815290604052905090565b6060600480546104c090610c58565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4c656761637945524332304554483a206275726e2069732064697361626c656460448201526064016105ca565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602d60248201527f4c656761637945524332304554483a206465637265617365416c6c6f77616e6360448201527f652069732064697361626c65640000000000000000000000000000000000000060648201526000906084016105ca565b6040517f08c379a0000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f4c656761637945524332304554483a207472616e73666572206973206469736160448201527f626c65640000000000000000000000000000000000000000000000000000000060648201526000906084016105ca565b6060816000036109b757505060408051808201909152600181527f3000000000000000000000000000000000000000000000000000000000000000602082015290565b8160005b81156109e157806109cb81610d50565b91506109da9050600a83610db7565b91506109bb565b60008167ffffffffffffffff8111156109fc576109fc610dcb565b6040519080825280601f01601f191660200182016040528015610a26576020820181803683370190505b5090505b8415610aa957610a3b600183610dfa565b9150610a48600a86610e11565b610a53906030610e25565b60f81b818381518110610a6857610a68610e3d565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350610aa2600a86610db7565b9450610a2a565b949350505050565b600060208284031215610ac357600080fd5b81357fffffffff0000000000000000000000000000000000000000000000000000000081168114610af357600080fd5b9392505050565b60005b83811015610b15578181015183820152602001610afd565b83811115610b24576000848401525b50505050565b6020815260008251806020840152610b49816040850160208701610afa565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169190910160400192915050565b803573ffffffffffffffffffffffffffffffffffffffff81168114610b9f57600080fd5b919050565b60008060408385031215610bb757600080fd5b610bc083610b7b565b946020939093013593505050565b600080600060608486031215610be357600080fd5b610bec84610b7b565b9250610bfa60208501610b7b565b9150604084013590509250925092565b600060208284031215610c1c57600080fd5b610af382610b7b565b60008060408385031215610c3857600080fd5b610c4183610b7b565b9150610c4f60208401610b7b565b90509250929050565b600181811c90821680610c6c57607f821691505b602082108103610ca5577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b60008451610cbd818460208901610afa565b80830190507f2e000000000000000000000000000000000000000000000000000000000000008082528551610cf9816001850160208a01610afa565b60019201918201528351610d14816002840160208801610afa565b0160020195945050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203610d8157610d81610d21565b5060010190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600082610dc657610dc6610d88565b500490565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b600082821015610e0c57610e0c610d21565b500390565b600082610e2057610e20610d88565b500690565b60008219821115610e3857610e38610d21565b500190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fdfea164736f6c634300080f000a", + Bin: "0x60e06040523480156200001157600080fd5b5073420000000000000000000000000000000000001060006040518060400160405280600581526020016422ba3432b960d91b8152506040518060400160405280600381526020016208aa8960eb1b81525060128282816003908162000078919062000152565b50600462000087828262000152565b5050506001600160a01b039384166080529390921660a052505060ff1660c0526200021e565b634e487b7160e01b600052604160045260246000fd5b600181811c90821680620000d857607f821691505b602082108103620000f957634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200014d57600081815260208120601f850160051c81016020861015620001285750805b601f850160051c820191505b81811015620001495782815560010162000134565b5050505b505050565b81516001600160401b038111156200016e576200016e620000ad565b62000186816200017f8454620000c3565b84620000ff565b602080601f831160018114620001be5760008415620001a55750858301515b600019600386901b1c1916600185901b17855562000149565b600085815260208120601f198616915b82811015620001ef57888601518255948401946001909101908401620001ce565b50858210156200020e5787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b60805160a05160c051610afe6200025c600039600061024401526000818161033d01526103d20152600081816101a901526103630152610afe6000f3fe608060405234801561001057600080fd5b50600436106101775760003560e01c806370a08231116100d8578063ae1f6aaf1161008c578063dd62ed3e11610066578063dd62ed3e14610387578063e78cea921461033b578063ee9a31a2146103cd57600080fd5b8063ae1f6aaf1461033b578063c01e1bd614610361578063d6c0b2c41461036157600080fd5b80639dc29fac116100bd5780639dc29fac14610302578063a457c2d714610315578063a9059cbb1461032857600080fd5b806370a08231146102d257806395d89b41146102fa57600080fd5b806323b872dd1161012f5780633950935111610114578063395093511461026e57806340c10f191461028157806354fd4d501461029657600080fd5b806323b872dd1461022a578063313ce5671461023d57600080fd5b806306fdde031161016057806306fdde03146101f0578063095ea7b31461020557806318160ddd1461021857600080fd5b806301ffc9a71461017c578063033964be146101a4575b600080fd5b61018f61018a366004610905565b6103f4565b60405190151581526020015b60405180910390f35b6101cb7f000000000000000000000000000000000000000000000000000000000000000081565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161019b565b6101f86104e5565b60405161019b919061094e565b61018f6102133660046109ea565b610577565b6002545b60405190815260200161019b565b61018f610238366004610a14565b610607565b60405160ff7f000000000000000000000000000000000000000000000000000000000000000016815260200161019b565b61018f61027c3660046109ea565b610692565b61029461028f3660046109ea565b61071d565b005b6101f86040518060400160405280600581526020017f312e332e3000000000000000000000000000000000000000000000000000000081525081565b61021c6102e0366004610a50565b73ffffffffffffffffffffffffffffffffffffffff163190565b6101f861077f565b6102946103103660046109ea565b61078e565b61018f6103233660046109ea565b6107f0565b61018f6103363660046109ea565b61087b565b7f00000000000000000000000000000000000000000000000000000000000000006101cb565b7f00000000000000000000000000000000000000000000000000000000000000006101cb565b61021c610395366004610a6b565b73ffffffffffffffffffffffffffffffffffffffff918216600090815260016020908152604080832093909416825291909152205490565b6101cb7f000000000000000000000000000000000000000000000000000000000000000081565b60007f01ffc9a7000000000000000000000000000000000000000000000000000000007f1d1d8b63000000000000000000000000000000000000000000000000000000007fec4fc8e3000000000000000000000000000000000000000000000000000000007fffffffff0000000000000000000000000000000000000000000000000000000085168314806104ad57507fffffffff00000000000000000000000000000000000000000000000000000000858116908316145b806104dc57507fffffffff00000000000000000000000000000000000000000000000000000000858116908216145b95945050505050565b6060600380546104f490610a9e565b80601f016020809104026020016040519081016040528092919081815260200182805461052090610a9e565b801561056d5780601f106105425761010080835404028352916020019161056d565b820191906000526020600020905b81548152906001019060200180831161055057829003601f168201915b5050505050905090565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f4c656761637945524332304554483a20617070726f766520697320646973616260448201527f6c6564000000000000000000000000000000000000000000000000000000000060648201526000906084015b60405180910390fd5b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602860248201527f4c656761637945524332304554483a207472616e7366657246726f6d2069732060448201527f64697361626c656400000000000000000000000000000000000000000000000060648201526000906084016105fe565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602d60248201527f4c656761637945524332304554483a20696e637265617365416c6c6f77616e6360448201527f652069732064697361626c65640000000000000000000000000000000000000060648201526000906084016105fe565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4c656761637945524332304554483a206d696e742069732064697361626c656460448201526064016105fe565b6060600480546104f490610a9e565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4c656761637945524332304554483a206275726e2069732064697361626c656460448201526064016105fe565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602d60248201527f4c656761637945524332304554483a206465637265617365416c6c6f77616e6360448201527f652069732064697361626c65640000000000000000000000000000000000000060648201526000906084016105fe565b6040517f08c379a0000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f4c656761637945524332304554483a207472616e73666572206973206469736160448201527f626c65640000000000000000000000000000000000000000000000000000000060648201526000906084016105fe565b60006020828403121561091757600080fd5b81357fffffffff000000000000000000000000000000000000000000000000000000008116811461094757600080fd5b9392505050565b600060208083528351808285015260005b8181101561097b5785810183015185820160400152820161095f565b8181111561098d576000604083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016929092016040019392505050565b803573ffffffffffffffffffffffffffffffffffffffff811681146109e557600080fd5b919050565b600080604083850312156109fd57600080fd5b610a06836109c1565b946020939093013593505050565b600080600060608486031215610a2957600080fd5b610a32846109c1565b9250610a40602085016109c1565b9150604084013590509250925092565b600060208284031215610a6257600080fd5b610947826109c1565b60008060408385031215610a7e57600080fd5b610a87836109c1565b9150610a95602084016109c1565b90509250929050565b600181811c90821680610ab257607f821691505b602082108103610aeb577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b5091905056fea164736f6c634300080f000a", } // LegacyERC20ETHABI is the input ABI used to generate the binding from. diff --git a/op-bindings/bindings/legacyerc20eth_more.go b/op-bindings/bindings/legacyerc20eth_more.go index cb79ddddc2c82..146d22f90323d 100644 --- a/op-bindings/bindings/legacyerc20eth_more.go +++ b/op-bindings/bindings/legacyerc20eth_more.go @@ -13,7 +13,7 @@ const LegacyERC20ETHStorageLayoutJSON = "{\"storage\":[{\"astId\":1000,\"contrac var LegacyERC20ETHStorageLayout = new(solc.StorageLayout) -var LegacyERC20ETHDeployedBin = "0x608060405234801561001057600080fd5b50600436106101775760003560e01c806370a08231116100d8578063ae1f6aaf1161008c578063dd62ed3e11610066578063dd62ed3e14610353578063e78cea9214610307578063ee9a31a21461039957600080fd5b8063ae1f6aaf14610307578063c01e1bd61461032d578063d6c0b2c41461032d57600080fd5b80639dc29fac116100bd5780639dc29fac146102ce578063a457c2d7146102e1578063a9059cbb146102f457600080fd5b806370a082311461029e57806395d89b41146102c657600080fd5b806323b872dd1161012f5780633950935111610114578063395093511461026e57806340c10f191461028157806354fd4d501461029657600080fd5b806323b872dd1461022a578063313ce5671461023d57600080fd5b806306fdde031161016057806306fdde03146101f0578063095ea7b31461020557806318160ddd1461021857600080fd5b806301ffc9a71461017c578063033964be146101a4575b600080fd5b61018f61018a366004610ab1565b6103c0565b60405190151581526020015b60405180910390f35b6101cb7f000000000000000000000000000000000000000000000000000000000000000081565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161019b565b6101f86104b1565b60405161019b9190610b2a565b61018f610213366004610ba4565b610543565b6002545b60405190815260200161019b565b61018f610238366004610bce565b6105d3565b60405160ff7f000000000000000000000000000000000000000000000000000000000000000016815260200161019b565b61018f61027c366004610ba4565b61065e565b61029461028f366004610ba4565b6106e9565b005b6101f861074b565b61021c6102ac366004610c0a565b73ffffffffffffffffffffffffffffffffffffffff163190565b6101f86107ee565b6102946102dc366004610ba4565b6107fd565b61018f6102ef366004610ba4565b61085f565b61018f610302366004610ba4565b6108ea565b7f00000000000000000000000000000000000000000000000000000000000000006101cb565b7f00000000000000000000000000000000000000000000000000000000000000006101cb565b61021c610361366004610c25565b73ffffffffffffffffffffffffffffffffffffffff918216600090815260016020908152604080832093909416825291909152205490565b6101cb7f000000000000000000000000000000000000000000000000000000000000000081565b60007f01ffc9a7000000000000000000000000000000000000000000000000000000007f1d1d8b63000000000000000000000000000000000000000000000000000000007fec4fc8e3000000000000000000000000000000000000000000000000000000007fffffffff00000000000000000000000000000000000000000000000000000000851683148061047957507fffffffff00000000000000000000000000000000000000000000000000000000858116908316145b806104a857507fffffffff00000000000000000000000000000000000000000000000000000000858116908216145b95945050505050565b6060600380546104c090610c58565b80601f01602080910402602001604051908101604052809291908181526020018280546104ec90610c58565b80156105395780601f1061050e57610100808354040283529160200191610539565b820191906000526020600020905b81548152906001019060200180831161051c57829003601f168201915b5050505050905090565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f4c656761637945524332304554483a20617070726f766520697320646973616260448201527f6c6564000000000000000000000000000000000000000000000000000000000060648201526000906084015b60405180910390fd5b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602860248201527f4c656761637945524332304554483a207472616e7366657246726f6d2069732060448201527f64697361626c656400000000000000000000000000000000000000000000000060648201526000906084016105ca565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602d60248201527f4c656761637945524332304554483a20696e637265617365416c6c6f77616e6360448201527f652069732064697361626c65640000000000000000000000000000000000000060648201526000906084016105ca565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4c656761637945524332304554483a206d696e742069732064697361626c656460448201526064016105ca565b60606107767f0000000000000000000000000000000000000000000000000000000000000000610974565b61079f7f0000000000000000000000000000000000000000000000000000000000000000610974565b6107c87f0000000000000000000000000000000000000000000000000000000000000000610974565b6040516020016107da93929190610cab565b604051602081830303815290604052905090565b6060600480546104c090610c58565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4c656761637945524332304554483a206275726e2069732064697361626c656460448201526064016105ca565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602d60248201527f4c656761637945524332304554483a206465637265617365416c6c6f77616e6360448201527f652069732064697361626c65640000000000000000000000000000000000000060648201526000906084016105ca565b6040517f08c379a0000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f4c656761637945524332304554483a207472616e73666572206973206469736160448201527f626c65640000000000000000000000000000000000000000000000000000000060648201526000906084016105ca565b6060816000036109b757505060408051808201909152600181527f3000000000000000000000000000000000000000000000000000000000000000602082015290565b8160005b81156109e157806109cb81610d50565b91506109da9050600a83610db7565b91506109bb565b60008167ffffffffffffffff8111156109fc576109fc610dcb565b6040519080825280601f01601f191660200182016040528015610a26576020820181803683370190505b5090505b8415610aa957610a3b600183610dfa565b9150610a48600a86610e11565b610a53906030610e25565b60f81b818381518110610a6857610a68610e3d565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350610aa2600a86610db7565b9450610a2a565b949350505050565b600060208284031215610ac357600080fd5b81357fffffffff0000000000000000000000000000000000000000000000000000000081168114610af357600080fd5b9392505050565b60005b83811015610b15578181015183820152602001610afd565b83811115610b24576000848401525b50505050565b6020815260008251806020840152610b49816040850160208701610afa565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169190910160400192915050565b803573ffffffffffffffffffffffffffffffffffffffff81168114610b9f57600080fd5b919050565b60008060408385031215610bb757600080fd5b610bc083610b7b565b946020939093013593505050565b600080600060608486031215610be357600080fd5b610bec84610b7b565b9250610bfa60208501610b7b565b9150604084013590509250925092565b600060208284031215610c1c57600080fd5b610af382610b7b565b60008060408385031215610c3857600080fd5b610c4183610b7b565b9150610c4f60208401610b7b565b90509250929050565b600181811c90821680610c6c57607f821691505b602082108103610ca5577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b60008451610cbd818460208901610afa565b80830190507f2e000000000000000000000000000000000000000000000000000000000000008082528551610cf9816001850160208a01610afa565b60019201918201528351610d14816002840160208801610afa565b0160020195945050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203610d8157610d81610d21565b5060010190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600082610dc657610dc6610d88565b500490565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b600082821015610e0c57610e0c610d21565b500390565b600082610e2057610e20610d88565b500690565b60008219821115610e3857610e38610d21565b500190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fdfea164736f6c634300080f000a" +var LegacyERC20ETHDeployedBin = "0x608060405234801561001057600080fd5b50600436106101775760003560e01c806370a08231116100d8578063ae1f6aaf1161008c578063dd62ed3e11610066578063dd62ed3e14610387578063e78cea921461033b578063ee9a31a2146103cd57600080fd5b8063ae1f6aaf1461033b578063c01e1bd614610361578063d6c0b2c41461036157600080fd5b80639dc29fac116100bd5780639dc29fac14610302578063a457c2d714610315578063a9059cbb1461032857600080fd5b806370a08231146102d257806395d89b41146102fa57600080fd5b806323b872dd1161012f5780633950935111610114578063395093511461026e57806340c10f191461028157806354fd4d501461029657600080fd5b806323b872dd1461022a578063313ce5671461023d57600080fd5b806306fdde031161016057806306fdde03146101f0578063095ea7b31461020557806318160ddd1461021857600080fd5b806301ffc9a71461017c578063033964be146101a4575b600080fd5b61018f61018a366004610905565b6103f4565b60405190151581526020015b60405180910390f35b6101cb7f000000000000000000000000000000000000000000000000000000000000000081565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161019b565b6101f86104e5565b60405161019b919061094e565b61018f6102133660046109ea565b610577565b6002545b60405190815260200161019b565b61018f610238366004610a14565b610607565b60405160ff7f000000000000000000000000000000000000000000000000000000000000000016815260200161019b565b61018f61027c3660046109ea565b610692565b61029461028f3660046109ea565b61071d565b005b6101f86040518060400160405280600581526020017f312e332e3000000000000000000000000000000000000000000000000000000081525081565b61021c6102e0366004610a50565b73ffffffffffffffffffffffffffffffffffffffff163190565b6101f861077f565b6102946103103660046109ea565b61078e565b61018f6103233660046109ea565b6107f0565b61018f6103363660046109ea565b61087b565b7f00000000000000000000000000000000000000000000000000000000000000006101cb565b7f00000000000000000000000000000000000000000000000000000000000000006101cb565b61021c610395366004610a6b565b73ffffffffffffffffffffffffffffffffffffffff918216600090815260016020908152604080832093909416825291909152205490565b6101cb7f000000000000000000000000000000000000000000000000000000000000000081565b60007f01ffc9a7000000000000000000000000000000000000000000000000000000007f1d1d8b63000000000000000000000000000000000000000000000000000000007fec4fc8e3000000000000000000000000000000000000000000000000000000007fffffffff0000000000000000000000000000000000000000000000000000000085168314806104ad57507fffffffff00000000000000000000000000000000000000000000000000000000858116908316145b806104dc57507fffffffff00000000000000000000000000000000000000000000000000000000858116908216145b95945050505050565b6060600380546104f490610a9e565b80601f016020809104026020016040519081016040528092919081815260200182805461052090610a9e565b801561056d5780601f106105425761010080835404028352916020019161056d565b820191906000526020600020905b81548152906001019060200180831161055057829003601f168201915b5050505050905090565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f4c656761637945524332304554483a20617070726f766520697320646973616260448201527f6c6564000000000000000000000000000000000000000000000000000000000060648201526000906084015b60405180910390fd5b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602860248201527f4c656761637945524332304554483a207472616e7366657246726f6d2069732060448201527f64697361626c656400000000000000000000000000000000000000000000000060648201526000906084016105fe565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602d60248201527f4c656761637945524332304554483a20696e637265617365416c6c6f77616e6360448201527f652069732064697361626c65640000000000000000000000000000000000000060648201526000906084016105fe565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4c656761637945524332304554483a206d696e742069732064697361626c656460448201526064016105fe565b6060600480546104f490610a9e565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4c656761637945524332304554483a206275726e2069732064697361626c656460448201526064016105fe565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602d60248201527f4c656761637945524332304554483a206465637265617365416c6c6f77616e6360448201527f652069732064697361626c65640000000000000000000000000000000000000060648201526000906084016105fe565b6040517f08c379a0000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f4c656761637945524332304554483a207472616e73666572206973206469736160448201527f626c65640000000000000000000000000000000000000000000000000000000060648201526000906084016105fe565b60006020828403121561091757600080fd5b81357fffffffff000000000000000000000000000000000000000000000000000000008116811461094757600080fd5b9392505050565b600060208083528351808285015260005b8181101561097b5785810183015185820160400152820161095f565b8181111561098d576000604083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016929092016040019392505050565b803573ffffffffffffffffffffffffffffffffffffffff811681146109e557600080fd5b919050565b600080604083850312156109fd57600080fd5b610a06836109c1565b946020939093013593505050565b600080600060608486031215610a2957600080fd5b610a32846109c1565b9250610a40602085016109c1565b9150604084013590509250925092565b600060208284031215610a6257600080fd5b610947826109c1565b60008060408385031215610a7e57600080fd5b610a87836109c1565b9150610a95602084016109c1565b90509250929050565b600181811c90821680610ab257607f821691505b602082108103610aeb577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b5091905056fea164736f6c634300080f000a" func init() { if err := json.Unmarshal([]byte(LegacyERC20ETHStorageLayoutJSON), LegacyERC20ETHStorageLayout); err != nil { diff --git a/op-bindings/bindings/mips.go b/op-bindings/bindings/mips.go index cba792eb62919..29f26ac738874 100644 --- a/op-bindings/bindings/mips.go +++ b/op-bindings/bindings/mips.go @@ -30,8 +30,8 @@ var ( // MIPSMetaData contains all meta data concerning the MIPS contract. var MIPSMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"contractIPreimageOracle\",\"name\":\"_oracle\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"BRK_START\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"oracle\",\"outputs\":[{\"internalType\":\"contractIPreimageOracle\",\"name\":\"oracle_\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"stateData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"proof\",\"type\":\"bytes\"}],\"name\":\"step\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60a060405234801561001057600080fd5b50604051611eb2380380611eb283398101604081905261002f91610040565b6001600160a01b0316608052610070565b60006020828403121561005257600080fd5b81516001600160a01b038116811461006957600080fd5b9392505050565b608051611e2161009160003960008181608501526115e70152611e216000f3fe608060405234801561001057600080fd5b50600436106100415760003560e01c8063155633fe146100465780637dc0d1d01461006b578063f8e0cb96146100af575b600080fd5b610051634000000081565b60405163ffffffff90911681526020015b60405180910390f35b60405173ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168152602001610062565b6100c26100bd366004611d26565b6100d0565b604051908152602001610062565b60006100da611c53565b608081146100e757600080fd5b604051610600146100f757600080fd5b6064861461010457600080fd5b610184841461011257600080fd5b8535608052602086013560a052604086013560e090811c60c09081526044880135821c82526048880135821c61010052604c880135821c610120526050880135821c61014052605488013590911c61016052605887013560f890811c610180526059880135901c6101a052605a870135901c6101c0526102006101e0819052606287019060005b60208110156101bd57823560e01c8252600490920191602090910190600101610199565b505050806101200151156101db576101d3610619565b915050610611565b6101408101805160010167ffffffffffffffff16905260608101516000906102039082610735565b9050603f601a82901c16600281148061022257508063ffffffff166003145b156102775760006002836303ffffff1663ffffffff16901b846080015163f00000001617905061026c8263ffffffff1660021461026057601f610263565b60005b60ff16826107f1565b945050505050610611565b6101608301516000908190601f601086901c81169190601587901c16602081106102a3576102a3611d92565b602002015192508063ffffffff851615806102c457508463ffffffff16601c145b156102fb578661016001518263ffffffff16602081106102e6576102e6611d92565b6020020151925050601f600b86901c166103b7565b60208563ffffffff16101561035d578463ffffffff16600c148061032557508463ffffffff16600d145b8061033657508463ffffffff16600e145b15610347578561ffff1692506103b7565b6103568661ffff1660106108eb565b92506103b7565b60288563ffffffff1610158061037957508463ffffffff166022145b8061038a57508463ffffffff166026145b156103b7578661016001518263ffffffff16602081106103ac576103ac611d92565b602002015192508190505b60048563ffffffff16101580156103d4575060088563ffffffff16105b806103e557508463ffffffff166001145b15610404576103f68587848761095e565b975050505050505050610611565b63ffffffff6000602087831610610469576104248861ffff1660106108eb565b9095019463fffffffc861661043a816001610735565b915060288863ffffffff161015801561045a57508763ffffffff16603014155b1561046757809250600093505b505b600061047789888885610b6e565b63ffffffff9081169150603f8a1690891615801561049c575060088163ffffffff1610155b80156104ae5750601c8163ffffffff16105b1561058a578063ffffffff16600814806104ce57508063ffffffff166009145b15610505576104f38163ffffffff166008146104ea57856104ed565b60005b896107f1565b9b505050505050505050505050610611565b8063ffffffff16600a03610525576104f3858963ffffffff8a16156112f2565b8063ffffffff16600b03610546576104f3858963ffffffff8a1615156112f2565b8063ffffffff16600c0361055c576104f36113d8565b60108163ffffffff16101580156105795750601c8163ffffffff16105b1561058a576104f38189898861190c565b8863ffffffff1660381480156105a5575063ffffffff861615155b156105da5760018b61016001518763ffffffff16602081106105c9576105c9611d92565b63ffffffff90921660209290920201525b8363ffffffff1663ffffffff146105f7576105f784600184611b06565b610603858360016112f2565b9b5050505050505050505050505b949350505050565b60408051608051815260a051602082015260dc519181019190915260fc51604482015261011c51604882015261013c51604c82015261015c51605082015261017c5160548201526101805161019f5160588301526101a0516101bf5160598401526101d851605a840152600092610200929091606283019190855b60208110156106b857601c8601518452602090950194600490930192600101610694565b506000835283830384a06000945080600181146106d85760039550610700565b8280156106f057600181146106f957600296506106fe565b600096506106fe565b600196505b505b50505081900390207effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1660f89190911b17919050565b60008061074183611baa565b9050600384161561075157600080fd5b6020810190358460051c8160005b601b8110156107b75760208501943583821c6001168015610787576001811461079c576107ad565b600084815260208390526040902093506107ad565b600082815260208590526040902093505b505060010161075f565b5060805191508181146107d257630badf00d60005260206000fd5b5050601f94909416601c0360031b9390931c63ffffffff169392505050565b60006107fb611c53565b60809050806060015160040163ffffffff16816080015163ffffffff1614610884576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f6a756d7020696e2064656c617920736c6f74000000000000000000000000000060448201526064015b60405180910390fd5b60608101805160808301805163ffffffff9081169093528583169052908516156108da57806008018261016001518663ffffffff16602081106108c9576108c9611d92565b63ffffffff90921660209290920201525b6108e2610619565b95945050505050565b600063ffffffff8381167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff80850183169190911c821615159160016020869003821681901b830191861691821b92911b018261094857600061094a565b815b90861663ffffffff16179250505092915050565b6000610968611c53565b608090506000816060015160040163ffffffff16826080015163ffffffff16146109ee576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f6272616e636820696e2064656c617920736c6f74000000000000000000000000604482015260640161087b565b8663ffffffff1660041480610a0957508663ffffffff166005145b15610a855760008261016001518663ffffffff1660208110610a2d57610a2d611d92565b602002015190508063ffffffff168563ffffffff16148015610a5557508763ffffffff166004145b80610a7d57508063ffffffff168563ffffffff1614158015610a7d57508763ffffffff166005145b915050610b02565b8663ffffffff16600603610aa25760008460030b13159050610b02565b8663ffffffff16600703610abe5760008460030b139050610b02565b8663ffffffff16600103610b0257601f601087901c166000819003610ae75760008560030b1291505b8063ffffffff16600103610b005760008560030b121591505b505b606082018051608084015163ffffffff169091528115610b48576002610b2d8861ffff1660106108eb565b63ffffffff90811690911b8201600401166080840152610b5a565b60808301805160040163ffffffff1690525b610b62610619565b98975050505050505050565b6000603f601a86901c16801580610b9d575060088163ffffffff1610158015610b9d5750600f8163ffffffff16105b15610ff357603f86168160088114610be45760098114610bed57600a8114610bf657600b8114610bff57600c8114610c0857600d8114610c1157600e8114610c1a57610c1f565b60209150610c1f565b60219150610c1f565b602a9150610c1f565b602b9150610c1f565b60249150610c1f565b60259150610c1f565b602691505b508063ffffffff16600003610c465750505063ffffffff8216601f600686901c161b610611565b8063ffffffff16600203610c6c5750505063ffffffff8216601f600686901c161c610611565b8063ffffffff16600303610ca257601f600688901c16610c9863ffffffff8716821c60208390036108eb565b9350505050610611565b8063ffffffff16600403610cc45750505063ffffffff8216601f84161b610611565b8063ffffffff16600603610ce65750505063ffffffff8216601f84161c610611565b8063ffffffff16600703610d1957610d108663ffffffff168663ffffffff16901c876020036108eb565b92505050610611565b8063ffffffff16600803610d31578592505050610611565b8063ffffffff16600903610d49578592505050610611565b8063ffffffff16600a03610d61578592505050610611565b8063ffffffff16600b03610d79578592505050610611565b8063ffffffff16600c03610d91578592505050610611565b8063ffffffff16600f03610da9578592505050610611565b8063ffffffff16601003610dc1578592505050610611565b8063ffffffff16601103610dd9578592505050610611565b8063ffffffff16601203610df1578592505050610611565b8063ffffffff16601303610e09578592505050610611565b8063ffffffff16601803610e21578592505050610611565b8063ffffffff16601903610e39578592505050610611565b8063ffffffff16601a03610e51578592505050610611565b8063ffffffff16601b03610e69578592505050610611565b8063ffffffff16602003610e8257505050828201610611565b8063ffffffff16602103610e9b57505050828201610611565b8063ffffffff16602203610eb457505050818303610611565b8063ffffffff16602303610ecd57505050818303610611565b8063ffffffff16602403610ee657505050828216610611565b8063ffffffff16602503610eff57505050828217610611565b8063ffffffff16602603610f1857505050828218610611565b8063ffffffff16602703610f325750505082821719610611565b8063ffffffff16602a03610f63578460030b8660030b12610f54576000610f57565b60015b60ff1692505050610611565b8063ffffffff16602b03610f8b578463ffffffff168663ffffffff1610610f54576000610f57565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601360248201527f696e76616c696420696e737472756374696f6e00000000000000000000000000604482015260640161087b565b50610f8b565b8063ffffffff16601c0361107757603f8616600281900361101957505050828202610611565b8063ffffffff166020148061103457508063ffffffff166021145b15610fed578063ffffffff1660200361104b579419945b60005b638000000087161561106d576401fffffffe600197881b16960161104e565b9250610611915050565b8063ffffffff16600f0361109957505065ffffffff0000601083901b16610611565b8063ffffffff166020036110cd576101d38560031660080260180363ffffffff168463ffffffff16901c60ff1660086108eb565b8063ffffffff16602103611102576101d38560021660080260100363ffffffff168463ffffffff16901c61ffff1660106108eb565b8063ffffffff1660220361113157505063ffffffff60086003851602811681811b198416918316901b17610611565b8063ffffffff166023036111485782915050610611565b8063ffffffff1660240361117a578460031660080260180363ffffffff168363ffffffff16901c60ff16915050610611565b8063ffffffff166025036111ad578460021660080260100363ffffffff168363ffffffff16901c61ffff16915050610611565b8063ffffffff166026036111df57505063ffffffff60086003851602601803811681811c198416918316901c17610611565b8063ffffffff1660280361121557505060ff63ffffffff60086003861602601803811682811b9091188316918416901b17610611565b8063ffffffff1660290361124c57505061ffff63ffffffff60086002861602601003811682811b9091188316918416901b17610611565b8063ffffffff16602a0361127b57505063ffffffff60086003851602811681811c198316918416901c17610611565b8063ffffffff16602b036112925783915050610611565b8063ffffffff16602e036112c457505063ffffffff60086003851602601803811681811b198316918416901b17610611565b8063ffffffff166030036112db5782915050610611565b8063ffffffff16603803610f8b5783915050610611565b60006112fc611c53565b506080602063ffffffff86161061136f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f76616c6964207265676973746572000000000000000000000000000000000000604482015260640161087b565b63ffffffff8516158015906113815750825b156113b557838161016001518663ffffffff16602081106113a4576113a4611d92565b63ffffffff90921660209290920201525b60808101805163ffffffff808216606085015260049091011690526108e2610619565b60006113e2611c53565b506101e051604081015160808083015160a084015160c09094015191936000928392919063ffffffff8616610ffa0361145c5781610fff81161561142b57610fff811661100003015b8363ffffffff166000036114525760e08801805163ffffffff838201169091529550611456565b8395505b506118cb565b8563ffffffff16610fcd0361147757634000000094506118cb565b8563ffffffff166110180361148f57600194506118cb565b8563ffffffff16611096036114c457600161012088015260ff83166101008801526114b8610619565b97505050505050505090565b8563ffffffff16610fa30361172e5763ffffffff8316156118cb577ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffb63ffffffff8416016116e857600061151f8363fffffffc166001610735565b60208901519091508060001a60010361158c5761158981600090815233602052604090207effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f01000000000000000000000000000000000000000000000000000000000000001790565b90505b6040808a015190517fe03110e10000000000000000000000000000000000000000000000000000000081526004810183905263ffffffff9091166024820152600090819073ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000169063e03110e1906044016040805180830381865afa15801561162d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906116519190611dc1565b91509150600386168060040382811015611669578092505b5081861015611676578591505b8260088302610100031c9250826008828460040303021b9250600180600883600403021b036001806008858560040303021b039150811981169050838119871617955050506116cd8663fffffffc16600186611b06565b60408b018051820163ffffffff169052975061172992505050565b7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffd63ffffffff84160161171d578094506118cb565b63ffffffff9450600993505b6118cb565b8563ffffffff16610fa40361181f5763ffffffff831660011480611758575063ffffffff83166002145b80611769575063ffffffff83166004145b15611776578094506118cb565b7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa63ffffffff84160161171d5760006117b68363fffffffc166001610735565b602089015190915060038416600403838110156117d1578093505b83900360089081029290921c7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600193850293841b0116911b176020880152600060408801529350836118cb565b8563ffffffff16610fd7036118cb578163ffffffff166003036118bf5763ffffffff83161580611855575063ffffffff83166005145b80611866575063ffffffff83166003145b1561187457600094506118cb565b63ffffffff83166001148061188f575063ffffffff83166002145b806118a0575063ffffffff83166006145b806118b1575063ffffffff83166004145b1561171d57600194506118cb565b63ffffffff9450601693505b6101608701805163ffffffff808816604090920191909152905185821660e09091015260808801805180831660608b015260040190911690526114b8610619565b6000611916611c53565b506080600063ffffffff8716601003611934575060c0810151611a9d565b8663ffffffff166011036119535763ffffffff861660c0830152611a9d565b8663ffffffff1660120361196c575060a0810151611a9d565b8663ffffffff1660130361198b5763ffffffff861660a0830152611a9d565b8663ffffffff166018036119bf5763ffffffff600387810b9087900b02602081901c821660c08501521660a0830152611a9d565b8663ffffffff166019036119f05763ffffffff86811681871602602081901c821660c08501521660a0830152611a9d565b8663ffffffff16601a03611a46578460030b8660030b81611a1357611a13611de5565b0763ffffffff1660c0830152600385810b9087900b81611a3557611a35611de5565b0563ffffffff1660a0830152611a9d565b8663ffffffff16601b03611a9d578463ffffffff168663ffffffff1681611a6f57611a6f611de5565b0663ffffffff90811660c084015285811690871681611a9057611a90611de5565b0463ffffffff1660a08301525b63ffffffff841615611ad857808261016001518563ffffffff1660208110611ac757611ac7611d92565b63ffffffff90921660209290920201525b60808201805163ffffffff80821660608601526004909101169052611afb610619565b979650505050505050565b6000611b1183611baa565b90506003841615611b2157600080fd5b6020810190601f8516601c0360031b83811b913563ffffffff90911b1916178460051c60005b601b811015611b9f5760208401933582821c6001168015611b6f5760018114611b8457611b95565b60008581526020839052604090209450611b95565b600082815260208690526040902094505b5050600101611b47565b505060805250505050565b60ff811661038002610184810190369061050401811015611c4d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f636865636b207468617420746865726520697320656e6f7567682063616c6c6460448201527f6174610000000000000000000000000000000000000000000000000000000000606482015260840161087b565b50919050565b6040805161018081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e08101829052610100810182905261012081018290526101408101919091526101608101611cb9611cbe565b905290565b6040518061040001604052806020906020820280368337509192915050565b60008083601f840112611cef57600080fd5b50813567ffffffffffffffff811115611d0757600080fd5b602083019150836020828501011115611d1f57600080fd5b9250929050565b60008060008060408587031215611d3c57600080fd5b843567ffffffffffffffff80821115611d5457600080fd5b611d6088838901611cdd565b90965094506020870135915080821115611d7957600080fd5b50611d8687828801611cdd565b95989497509550505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60008060408385031215611dd457600080fd5b505080516020909101519092909150565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fdfea164736f6c634300080f000a", + ABI: "[{\"inputs\":[{\"internalType\":\"contractIPreimageOracle\",\"name\":\"_oracle\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"BRK_START\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"oracle\",\"outputs\":[{\"internalType\":\"contractIPreimageOracle\",\"name\":\"oracle_\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"_stateData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"_proof\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"_localContext\",\"type\":\"uint256\"}],\"name\":\"step\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60a060405234801561001057600080fd5b50604051611ec2380380611ec283398101604081905261002f91610040565b6001600160a01b0316608052610070565b60006020828403121561005257600080fd5b81516001600160a01b038116811461006957600080fd5b9392505050565b608051611e3161009160003960008181608501526115ef0152611e316000f3fe608060405234801561001057600080fd5b50600436106100415760003560e01c8063155633fe146100465780637dc0d1d01461006b578063836e7b32146100af575b600080fd5b610051634000000081565b60405163ffffffff90911681526020015b60405180910390f35b60405173ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168152602001610062565b6100c26100bd366004611d2e565b6100d0565b604051908152602001610062565b60006100da611c5b565b608081146100e757600080fd5b604051610600146100f757600080fd5b6084871461010457600080fd5b6101a4851461011257600080fd5b8635608052602087013560a052604087013560e090811c60c09081526044890135821c82526048890135821c61010052604c890135821c610120526050890135821c61014052605489013590911c61016052605888013560f890811c610180526059890135901c6101a052605a880135901c6101c0526102006101e0819052606288019060005b60208110156101bd57823560e01c8252600490920191602090910190600101610199565b505050806101200151156101db576101d361061b565b915050610612565b6101408101805160010167ffffffffffffffff16905260608101516000906102039082610737565b9050603f601a82901c16600281148061022257508063ffffffff166003145b156102775760006002836303ffffff1663ffffffff16901b846080015163f00000001617905061026c8263ffffffff1660021461026057601f610263565b60005b60ff16826107f3565b945050505050610612565b6101608301516000908190601f601086901c81169190601587901c16602081106102a3576102a3611da2565b602002015192508063ffffffff851615806102c457508463ffffffff16601c145b156102fb578661016001518263ffffffff16602081106102e6576102e6611da2565b6020020151925050601f600b86901c166103b7565b60208563ffffffff16101561035d578463ffffffff16600c148061032557508463ffffffff16600d145b8061033657508463ffffffff16600e145b15610347578561ffff1692506103b7565b6103568661ffff1660106108e4565b92506103b7565b60288563ffffffff1610158061037957508463ffffffff166022145b8061038a57508463ffffffff166026145b156103b7578661016001518263ffffffff16602081106103ac576103ac611da2565b602002015192508190505b60048563ffffffff16101580156103d4575060088563ffffffff16105b806103e557508463ffffffff166001145b15610404576103f685878487610957565b975050505050505050610612565b63ffffffff6000602087831610610469576104248861ffff1660106108e4565b9095019463fffffffc861661043a816001610737565b915060288863ffffffff161015801561045a57508763ffffffff16603014155b1561046757809250600093505b505b600061047789888885610b67565b63ffffffff9081169150603f8a1690891615801561049c575060088163ffffffff1610155b80156104ae5750601c8163ffffffff16105b1561058b578063ffffffff16600814806104ce57508063ffffffff166009145b15610505576104f38163ffffffff166008146104ea57856104ed565b60005b896107f3565b9b505050505050505050505050610612565b8063ffffffff16600a03610525576104f3858963ffffffff8a16156112f7565b8063ffffffff16600b03610546576104f3858963ffffffff8a1615156112f7565b8063ffffffff16600c0361055d576104f38d6113dd565b60108163ffffffff161015801561057a5750601c8163ffffffff16105b1561058b576104f381898988611914565b8863ffffffff1660381480156105a6575063ffffffff861615155b156105db5760018b61016001518763ffffffff16602081106105ca576105ca611da2565b63ffffffff90921660209290920201525b8363ffffffff1663ffffffff146105f8576105f884600184611b0e565b610604858360016112f7565b9b5050505050505050505050505b95945050505050565b60408051608051815260a051602082015260dc519181019190915260fc51604482015261011c51604882015261013c51604c82015261015c51605082015261017c5160548201526101805161019f5160588301526101a0516101bf5160598401526101d851605a840152600092610200929091606283019190855b60208110156106ba57601c8601518452602090950194600490930192600101610696565b506000835283830384a06000945080600181146106da5760039550610702565b8280156106f257600181146106fb5760029650610700565b60009650610700565b600196505b505b50505081900390207effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1660f89190911b17919050565b60008061074383611bb2565b9050600384161561075357600080fd5b6020810190358460051c8160005b601b8110156107b95760208501943583821c6001168015610789576001811461079e576107af565b600084815260208390526040902093506107af565b600082815260208590526040902093505b5050600101610761565b5060805191508181146107d457630badf00d60005260206000fd5b5050601f94909416601c0360031b9390931c63ffffffff169392505050565b60006107fd611c5b565b60809050806060015160040163ffffffff16816080015163ffffffff1614610886576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f6a756d7020696e2064656c617920736c6f74000000000000000000000000000060448201526064015b60405180910390fd5b60608101805160808301805163ffffffff9081169093528583169052908516156108dc57806008018261016001518663ffffffff16602081106108cb576108cb611da2565b63ffffffff90921660209290920201525b61061261061b565b600063ffffffff8381167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff80850183169190911c821615159160016020869003821681901b830191861691821b92911b0182610941576000610943565b815b90861663ffffffff16179250505092915050565b6000610961611c5b565b608090506000816060015160040163ffffffff16826080015163ffffffff16146109e7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f6272616e636820696e2064656c617920736c6f74000000000000000000000000604482015260640161087d565b8663ffffffff1660041480610a0257508663ffffffff166005145b15610a7e5760008261016001518663ffffffff1660208110610a2657610a26611da2565b602002015190508063ffffffff168563ffffffff16148015610a4e57508763ffffffff166004145b80610a7657508063ffffffff168563ffffffff1614158015610a7657508763ffffffff166005145b915050610afb565b8663ffffffff16600603610a9b5760008460030b13159050610afb565b8663ffffffff16600703610ab75760008460030b139050610afb565b8663ffffffff16600103610afb57601f601087901c166000819003610ae05760008560030b1291505b8063ffffffff16600103610af95760008560030b121591505b505b606082018051608084015163ffffffff169091528115610b41576002610b268861ffff1660106108e4565b63ffffffff90811690911b8201600401166080840152610b53565b60808301805160040163ffffffff1690525b610b5b61061b565b98975050505050505050565b6000603f601a86901c16801580610b96575060088163ffffffff1610158015610b965750600f8163ffffffff16105b15610fec57603f86168160088114610bdd5760098114610be657600a8114610bef57600b8114610bf857600c8114610c0157600d8114610c0a57600e8114610c1357610c18565b60209150610c18565b60219150610c18565b602a9150610c18565b602b9150610c18565b60249150610c18565b60259150610c18565b602691505b508063ffffffff16600003610c3f5750505063ffffffff8216601f600686901c161b6112ef565b8063ffffffff16600203610c655750505063ffffffff8216601f600686901c161c6112ef565b8063ffffffff16600303610c9b57601f600688901c16610c9163ffffffff8716821c60208390036108e4565b93505050506112ef565b8063ffffffff16600403610cbd5750505063ffffffff8216601f84161b6112ef565b8063ffffffff16600603610cdf5750505063ffffffff8216601f84161c6112ef565b8063ffffffff16600703610d1257610d098663ffffffff168663ffffffff16901c876020036108e4565b925050506112ef565b8063ffffffff16600803610d2a5785925050506112ef565b8063ffffffff16600903610d425785925050506112ef565b8063ffffffff16600a03610d5a5785925050506112ef565b8063ffffffff16600b03610d725785925050506112ef565b8063ffffffff16600c03610d8a5785925050506112ef565b8063ffffffff16600f03610da25785925050506112ef565b8063ffffffff16601003610dba5785925050506112ef565b8063ffffffff16601103610dd25785925050506112ef565b8063ffffffff16601203610dea5785925050506112ef565b8063ffffffff16601303610e025785925050506112ef565b8063ffffffff16601803610e1a5785925050506112ef565b8063ffffffff16601903610e325785925050506112ef565b8063ffffffff16601a03610e4a5785925050506112ef565b8063ffffffff16601b03610e625785925050506112ef565b8063ffffffff16602003610e7b575050508282016112ef565b8063ffffffff16602103610e94575050508282016112ef565b8063ffffffff16602203610ead575050508183036112ef565b8063ffffffff16602303610ec6575050508183036112ef565b8063ffffffff16602403610edf575050508282166112ef565b8063ffffffff16602503610ef8575050508282176112ef565b8063ffffffff16602603610f11575050508282186112ef565b8063ffffffff16602703610f2b57505050828217196112ef565b8063ffffffff16602a03610f5c578460030b8660030b12610f4d576000610f50565b60015b60ff16925050506112ef565b8063ffffffff16602b03610f84578463ffffffff168663ffffffff1610610f4d576000610f50565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601360248201527f696e76616c696420696e737472756374696f6e00000000000000000000000000604482015260640161087d565b50610f84565b8063ffffffff16601c0361107057603f86166002819003611012575050508282026112ef565b8063ffffffff166020148061102d57508063ffffffff166021145b15610fe6578063ffffffff16602003611044579419945b60005b6380000000871615611066576401fffffffe600197881b169601611047565b92506112ef915050565b8063ffffffff16600f0361109257505065ffffffff0000601083901b166112ef565b8063ffffffff166020036110ce576110c68560031660080260180363ffffffff168463ffffffff16901c60ff1660086108e4565b9150506112ef565b8063ffffffff16602103611103576110c68560021660080260100363ffffffff168463ffffffff16901c61ffff1660106108e4565b8063ffffffff1660220361113257505063ffffffff60086003851602811681811b198416918316901b176112ef565b8063ffffffff1660230361114957829150506112ef565b8063ffffffff1660240361117b578460031660080260180363ffffffff168363ffffffff16901c60ff169150506112ef565b8063ffffffff166025036111ae578460021660080260100363ffffffff168363ffffffff16901c61ffff169150506112ef565b8063ffffffff166026036111e057505063ffffffff60086003851602601803811681811c198416918316901c176112ef565b8063ffffffff1660280361121657505060ff63ffffffff60086003861602601803811682811b9091188316918416901b176112ef565b8063ffffffff1660290361124d57505061ffff63ffffffff60086002861602601003811682811b9091188316918416901b176112ef565b8063ffffffff16602a0361127c57505063ffffffff60086003851602811681811c198316918416901c176112ef565b8063ffffffff16602b0361129357839150506112ef565b8063ffffffff16602e036112c557505063ffffffff60086003851602601803811681811b198316918416901b176112ef565b8063ffffffff166030036112dc57829150506112ef565b8063ffffffff16603803610f8457839150505b949350505050565b6000611301611c5b565b506080602063ffffffff861610611374576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f76616c6964207265676973746572000000000000000000000000000000000000604482015260640161087d565b63ffffffff8516158015906113865750825b156113ba57838161016001518663ffffffff16602081106113a9576113a9611da2565b63ffffffff90921660209290920201525b60808101805163ffffffff8082166060850152600490910116905261061261061b565b60006113e7611c5b565b506101e051604081015160808083015160a084015160c09094015191936000928392919063ffffffff8616610ffa036114615781610fff81161561143057610fff811661100003015b8363ffffffff166000036114575760e08801805163ffffffff83820116909152955061145b565b8395505b506118d3565b8563ffffffff16610fcd0361147c57634000000094506118d3565b8563ffffffff166110180361149457600194506118d3565b8563ffffffff16611096036114ca57600161012088015260ff83166101008801526114bd61061b565b9998505050505050505050565b8563ffffffff16610fa3036117365763ffffffff8316156118d3577ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffb63ffffffff8416016116f05760006115258363fffffffc166001610737565b60208901519091508060001a60010361159457604080516000838152336020528d83526060902091527effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f01000000000000000000000000000000000000000000000000000000000000001790505b6040808a015190517fe03110e10000000000000000000000000000000000000000000000000000000081526004810183905263ffffffff9091166024820152600090819073ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000169063e03110e1906044016040805180830381865afa158015611635573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906116599190611dd1565b91509150600386168060040382811015611671578092505b508186101561167e578591505b8260088302610100031c9250826008828460040303021b9250600180600883600403021b036001806008858560040303021b039150811981169050838119871617955050506116d58663fffffffc16600186611b0e565b60408b018051820163ffffffff169052975061173192505050565b7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffd63ffffffff841601611725578094506118d3565b63ffffffff9450600993505b6118d3565b8563ffffffff16610fa4036118275763ffffffff831660011480611760575063ffffffff83166002145b80611771575063ffffffff83166004145b1561177e578094506118d3565b7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa63ffffffff8416016117255760006117be8363fffffffc166001610737565b602089015190915060038416600403838110156117d9578093505b83900360089081029290921c7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600193850293841b0116911b176020880152600060408801529350836118d3565b8563ffffffff16610fd7036118d3578163ffffffff166003036118c75763ffffffff8316158061185d575063ffffffff83166005145b8061186e575063ffffffff83166003145b1561187c57600094506118d3565b63ffffffff831660011480611897575063ffffffff83166002145b806118a8575063ffffffff83166006145b806118b9575063ffffffff83166004145b1561172557600194506118d3565b63ffffffff9450601693505b6101608701805163ffffffff808816604090920191909152905185821660e09091015260808801805180831660608b015260040190911690526114bd61061b565b600061191e611c5b565b506080600063ffffffff871660100361193c575060c0810151611aa5565b8663ffffffff1660110361195b5763ffffffff861660c0830152611aa5565b8663ffffffff16601203611974575060a0810151611aa5565b8663ffffffff166013036119935763ffffffff861660a0830152611aa5565b8663ffffffff166018036119c75763ffffffff600387810b9087900b02602081901c821660c08501521660a0830152611aa5565b8663ffffffff166019036119f85763ffffffff86811681871602602081901c821660c08501521660a0830152611aa5565b8663ffffffff16601a03611a4e578460030b8660030b81611a1b57611a1b611df5565b0763ffffffff1660c0830152600385810b9087900b81611a3d57611a3d611df5565b0563ffffffff1660a0830152611aa5565b8663ffffffff16601b03611aa5578463ffffffff168663ffffffff1681611a7757611a77611df5565b0663ffffffff90811660c084015285811690871681611a9857611a98611df5565b0463ffffffff1660a08301525b63ffffffff841615611ae057808261016001518563ffffffff1660208110611acf57611acf611da2565b63ffffffff90921660209290920201525b60808201805163ffffffff80821660608601526004909101169052611b0361061b565b979650505050505050565b6000611b1983611bb2565b90506003841615611b2957600080fd5b6020810190601f8516601c0360031b83811b913563ffffffff90911b1916178460051c60005b601b811015611ba75760208401933582821c6001168015611b775760018114611b8c57611b9d565b60008581526020839052604090209450611b9d565b600082815260208690526040902094505b5050600101611b4f565b505060805250505050565b60ff8116610380026101a4810190369061052401811015611c55576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f636865636b207468617420746865726520697320656e6f7567682063616c6c6460448201527f6174610000000000000000000000000000000000000000000000000000000000606482015260840161087d565b50919050565b6040805161018081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e08101829052610100810182905261012081018290526101408101919091526101608101611cc1611cc6565b905290565b6040518061040001604052806020906020820280368337509192915050565b60008083601f840112611cf757600080fd5b50813567ffffffffffffffff811115611d0f57600080fd5b602083019150836020828501011115611d2757600080fd5b9250929050565b600080600080600060608688031215611d4657600080fd5b853567ffffffffffffffff80821115611d5e57600080fd5b611d6a89838a01611ce5565b90975095506020880135915080821115611d8357600080fd5b50611d9088828901611ce5565b96999598509660400135949350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60008060408385031215611de457600080fd5b505080516020909101519092909150565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fdfea164736f6c634300080f000a", } // MIPSABI is the input ABI used to generate the binding from. @@ -263,23 +263,23 @@ func (_MIPS *MIPSCallerSession) Oracle() (common.Address, error) { return _MIPS.Contract.Oracle(&_MIPS.CallOpts) } -// Step is a paid mutator transaction binding the contract method 0xf8e0cb96. +// Step is a paid mutator transaction binding the contract method 0x836e7b32. // -// Solidity: function step(bytes stateData, bytes proof) returns(bytes32) -func (_MIPS *MIPSTransactor) Step(opts *bind.TransactOpts, stateData []byte, proof []byte) (*types.Transaction, error) { - return _MIPS.contract.Transact(opts, "step", stateData, proof) +// Solidity: function step(bytes _stateData, bytes _proof, uint256 _localContext) returns(bytes32) +func (_MIPS *MIPSTransactor) Step(opts *bind.TransactOpts, _stateData []byte, _proof []byte, _localContext *big.Int) (*types.Transaction, error) { + return _MIPS.contract.Transact(opts, "step", _stateData, _proof, _localContext) } -// Step is a paid mutator transaction binding the contract method 0xf8e0cb96. +// Step is a paid mutator transaction binding the contract method 0x836e7b32. // -// Solidity: function step(bytes stateData, bytes proof) returns(bytes32) -func (_MIPS *MIPSSession) Step(stateData []byte, proof []byte) (*types.Transaction, error) { - return _MIPS.Contract.Step(&_MIPS.TransactOpts, stateData, proof) +// Solidity: function step(bytes _stateData, bytes _proof, uint256 _localContext) returns(bytes32) +func (_MIPS *MIPSSession) Step(_stateData []byte, _proof []byte, _localContext *big.Int) (*types.Transaction, error) { + return _MIPS.Contract.Step(&_MIPS.TransactOpts, _stateData, _proof, _localContext) } -// Step is a paid mutator transaction binding the contract method 0xf8e0cb96. +// Step is a paid mutator transaction binding the contract method 0x836e7b32. // -// Solidity: function step(bytes stateData, bytes proof) returns(bytes32) -func (_MIPS *MIPSTransactorSession) Step(stateData []byte, proof []byte) (*types.Transaction, error) { - return _MIPS.Contract.Step(&_MIPS.TransactOpts, stateData, proof) +// Solidity: function step(bytes _stateData, bytes _proof, uint256 _localContext) returns(bytes32) +func (_MIPS *MIPSTransactorSession) Step(_stateData []byte, _proof []byte, _localContext *big.Int) (*types.Transaction, error) { + return _MIPS.Contract.Step(&_MIPS.TransactOpts, _stateData, _proof, _localContext) } diff --git a/op-bindings/bindings/mips_more.go b/op-bindings/bindings/mips_more.go index 032ea0965d291..4c3c10e1238a2 100644 --- a/op-bindings/bindings/mips_more.go +++ b/op-bindings/bindings/mips_more.go @@ -13,9 +13,9 @@ const MIPSStorageLayoutJSON = "{\"storage\":null,\"types\":{}}" var MIPSStorageLayout = new(solc.StorageLayout) -var MIPSDeployedBin = "0x608060405234801561001057600080fd5b50600436106100415760003560e01c8063155633fe146100465780637dc0d1d01461006b578063f8e0cb96146100af575b600080fd5b610051634000000081565b60405163ffffffff90911681526020015b60405180910390f35b60405173ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168152602001610062565b6100c26100bd366004611d26565b6100d0565b604051908152602001610062565b60006100da611c53565b608081146100e757600080fd5b604051610600146100f757600080fd5b6064861461010457600080fd5b610184841461011257600080fd5b8535608052602086013560a052604086013560e090811c60c09081526044880135821c82526048880135821c61010052604c880135821c610120526050880135821c61014052605488013590911c61016052605887013560f890811c610180526059880135901c6101a052605a870135901c6101c0526102006101e0819052606287019060005b60208110156101bd57823560e01c8252600490920191602090910190600101610199565b505050806101200151156101db576101d3610619565b915050610611565b6101408101805160010167ffffffffffffffff16905260608101516000906102039082610735565b9050603f601a82901c16600281148061022257508063ffffffff166003145b156102775760006002836303ffffff1663ffffffff16901b846080015163f00000001617905061026c8263ffffffff1660021461026057601f610263565b60005b60ff16826107f1565b945050505050610611565b6101608301516000908190601f601086901c81169190601587901c16602081106102a3576102a3611d92565b602002015192508063ffffffff851615806102c457508463ffffffff16601c145b156102fb578661016001518263ffffffff16602081106102e6576102e6611d92565b6020020151925050601f600b86901c166103b7565b60208563ffffffff16101561035d578463ffffffff16600c148061032557508463ffffffff16600d145b8061033657508463ffffffff16600e145b15610347578561ffff1692506103b7565b6103568661ffff1660106108eb565b92506103b7565b60288563ffffffff1610158061037957508463ffffffff166022145b8061038a57508463ffffffff166026145b156103b7578661016001518263ffffffff16602081106103ac576103ac611d92565b602002015192508190505b60048563ffffffff16101580156103d4575060088563ffffffff16105b806103e557508463ffffffff166001145b15610404576103f68587848761095e565b975050505050505050610611565b63ffffffff6000602087831610610469576104248861ffff1660106108eb565b9095019463fffffffc861661043a816001610735565b915060288863ffffffff161015801561045a57508763ffffffff16603014155b1561046757809250600093505b505b600061047789888885610b6e565b63ffffffff9081169150603f8a1690891615801561049c575060088163ffffffff1610155b80156104ae5750601c8163ffffffff16105b1561058a578063ffffffff16600814806104ce57508063ffffffff166009145b15610505576104f38163ffffffff166008146104ea57856104ed565b60005b896107f1565b9b505050505050505050505050610611565b8063ffffffff16600a03610525576104f3858963ffffffff8a16156112f2565b8063ffffffff16600b03610546576104f3858963ffffffff8a1615156112f2565b8063ffffffff16600c0361055c576104f36113d8565b60108163ffffffff16101580156105795750601c8163ffffffff16105b1561058a576104f38189898861190c565b8863ffffffff1660381480156105a5575063ffffffff861615155b156105da5760018b61016001518763ffffffff16602081106105c9576105c9611d92565b63ffffffff90921660209290920201525b8363ffffffff1663ffffffff146105f7576105f784600184611b06565b610603858360016112f2565b9b5050505050505050505050505b949350505050565b60408051608051815260a051602082015260dc519181019190915260fc51604482015261011c51604882015261013c51604c82015261015c51605082015261017c5160548201526101805161019f5160588301526101a0516101bf5160598401526101d851605a840152600092610200929091606283019190855b60208110156106b857601c8601518452602090950194600490930192600101610694565b506000835283830384a06000945080600181146106d85760039550610700565b8280156106f057600181146106f957600296506106fe565b600096506106fe565b600196505b505b50505081900390207effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1660f89190911b17919050565b60008061074183611baa565b9050600384161561075157600080fd5b6020810190358460051c8160005b601b8110156107b75760208501943583821c6001168015610787576001811461079c576107ad565b600084815260208390526040902093506107ad565b600082815260208590526040902093505b505060010161075f565b5060805191508181146107d257630badf00d60005260206000fd5b5050601f94909416601c0360031b9390931c63ffffffff169392505050565b60006107fb611c53565b60809050806060015160040163ffffffff16816080015163ffffffff1614610884576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f6a756d7020696e2064656c617920736c6f74000000000000000000000000000060448201526064015b60405180910390fd5b60608101805160808301805163ffffffff9081169093528583169052908516156108da57806008018261016001518663ffffffff16602081106108c9576108c9611d92565b63ffffffff90921660209290920201525b6108e2610619565b95945050505050565b600063ffffffff8381167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff80850183169190911c821615159160016020869003821681901b830191861691821b92911b018261094857600061094a565b815b90861663ffffffff16179250505092915050565b6000610968611c53565b608090506000816060015160040163ffffffff16826080015163ffffffff16146109ee576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f6272616e636820696e2064656c617920736c6f74000000000000000000000000604482015260640161087b565b8663ffffffff1660041480610a0957508663ffffffff166005145b15610a855760008261016001518663ffffffff1660208110610a2d57610a2d611d92565b602002015190508063ffffffff168563ffffffff16148015610a5557508763ffffffff166004145b80610a7d57508063ffffffff168563ffffffff1614158015610a7d57508763ffffffff166005145b915050610b02565b8663ffffffff16600603610aa25760008460030b13159050610b02565b8663ffffffff16600703610abe5760008460030b139050610b02565b8663ffffffff16600103610b0257601f601087901c166000819003610ae75760008560030b1291505b8063ffffffff16600103610b005760008560030b121591505b505b606082018051608084015163ffffffff169091528115610b48576002610b2d8861ffff1660106108eb565b63ffffffff90811690911b8201600401166080840152610b5a565b60808301805160040163ffffffff1690525b610b62610619565b98975050505050505050565b6000603f601a86901c16801580610b9d575060088163ffffffff1610158015610b9d5750600f8163ffffffff16105b15610ff357603f86168160088114610be45760098114610bed57600a8114610bf657600b8114610bff57600c8114610c0857600d8114610c1157600e8114610c1a57610c1f565b60209150610c1f565b60219150610c1f565b602a9150610c1f565b602b9150610c1f565b60249150610c1f565b60259150610c1f565b602691505b508063ffffffff16600003610c465750505063ffffffff8216601f600686901c161b610611565b8063ffffffff16600203610c6c5750505063ffffffff8216601f600686901c161c610611565b8063ffffffff16600303610ca257601f600688901c16610c9863ffffffff8716821c60208390036108eb565b9350505050610611565b8063ffffffff16600403610cc45750505063ffffffff8216601f84161b610611565b8063ffffffff16600603610ce65750505063ffffffff8216601f84161c610611565b8063ffffffff16600703610d1957610d108663ffffffff168663ffffffff16901c876020036108eb565b92505050610611565b8063ffffffff16600803610d31578592505050610611565b8063ffffffff16600903610d49578592505050610611565b8063ffffffff16600a03610d61578592505050610611565b8063ffffffff16600b03610d79578592505050610611565b8063ffffffff16600c03610d91578592505050610611565b8063ffffffff16600f03610da9578592505050610611565b8063ffffffff16601003610dc1578592505050610611565b8063ffffffff16601103610dd9578592505050610611565b8063ffffffff16601203610df1578592505050610611565b8063ffffffff16601303610e09578592505050610611565b8063ffffffff16601803610e21578592505050610611565b8063ffffffff16601903610e39578592505050610611565b8063ffffffff16601a03610e51578592505050610611565b8063ffffffff16601b03610e69578592505050610611565b8063ffffffff16602003610e8257505050828201610611565b8063ffffffff16602103610e9b57505050828201610611565b8063ffffffff16602203610eb457505050818303610611565b8063ffffffff16602303610ecd57505050818303610611565b8063ffffffff16602403610ee657505050828216610611565b8063ffffffff16602503610eff57505050828217610611565b8063ffffffff16602603610f1857505050828218610611565b8063ffffffff16602703610f325750505082821719610611565b8063ffffffff16602a03610f63578460030b8660030b12610f54576000610f57565b60015b60ff1692505050610611565b8063ffffffff16602b03610f8b578463ffffffff168663ffffffff1610610f54576000610f57565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601360248201527f696e76616c696420696e737472756374696f6e00000000000000000000000000604482015260640161087b565b50610f8b565b8063ffffffff16601c0361107757603f8616600281900361101957505050828202610611565b8063ffffffff166020148061103457508063ffffffff166021145b15610fed578063ffffffff1660200361104b579419945b60005b638000000087161561106d576401fffffffe600197881b16960161104e565b9250610611915050565b8063ffffffff16600f0361109957505065ffffffff0000601083901b16610611565b8063ffffffff166020036110cd576101d38560031660080260180363ffffffff168463ffffffff16901c60ff1660086108eb565b8063ffffffff16602103611102576101d38560021660080260100363ffffffff168463ffffffff16901c61ffff1660106108eb565b8063ffffffff1660220361113157505063ffffffff60086003851602811681811b198416918316901b17610611565b8063ffffffff166023036111485782915050610611565b8063ffffffff1660240361117a578460031660080260180363ffffffff168363ffffffff16901c60ff16915050610611565b8063ffffffff166025036111ad578460021660080260100363ffffffff168363ffffffff16901c61ffff16915050610611565b8063ffffffff166026036111df57505063ffffffff60086003851602601803811681811c198416918316901c17610611565b8063ffffffff1660280361121557505060ff63ffffffff60086003861602601803811682811b9091188316918416901b17610611565b8063ffffffff1660290361124c57505061ffff63ffffffff60086002861602601003811682811b9091188316918416901b17610611565b8063ffffffff16602a0361127b57505063ffffffff60086003851602811681811c198316918416901c17610611565b8063ffffffff16602b036112925783915050610611565b8063ffffffff16602e036112c457505063ffffffff60086003851602601803811681811b198316918416901b17610611565b8063ffffffff166030036112db5782915050610611565b8063ffffffff16603803610f8b5783915050610611565b60006112fc611c53565b506080602063ffffffff86161061136f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f76616c6964207265676973746572000000000000000000000000000000000000604482015260640161087b565b63ffffffff8516158015906113815750825b156113b557838161016001518663ffffffff16602081106113a4576113a4611d92565b63ffffffff90921660209290920201525b60808101805163ffffffff808216606085015260049091011690526108e2610619565b60006113e2611c53565b506101e051604081015160808083015160a084015160c09094015191936000928392919063ffffffff8616610ffa0361145c5781610fff81161561142b57610fff811661100003015b8363ffffffff166000036114525760e08801805163ffffffff838201169091529550611456565b8395505b506118cb565b8563ffffffff16610fcd0361147757634000000094506118cb565b8563ffffffff166110180361148f57600194506118cb565b8563ffffffff16611096036114c457600161012088015260ff83166101008801526114b8610619565b97505050505050505090565b8563ffffffff16610fa30361172e5763ffffffff8316156118cb577ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffb63ffffffff8416016116e857600061151f8363fffffffc166001610735565b60208901519091508060001a60010361158c5761158981600090815233602052604090207effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f01000000000000000000000000000000000000000000000000000000000000001790565b90505b6040808a015190517fe03110e10000000000000000000000000000000000000000000000000000000081526004810183905263ffffffff9091166024820152600090819073ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000169063e03110e1906044016040805180830381865afa15801561162d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906116519190611dc1565b91509150600386168060040382811015611669578092505b5081861015611676578591505b8260088302610100031c9250826008828460040303021b9250600180600883600403021b036001806008858560040303021b039150811981169050838119871617955050506116cd8663fffffffc16600186611b06565b60408b018051820163ffffffff169052975061172992505050565b7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffd63ffffffff84160161171d578094506118cb565b63ffffffff9450600993505b6118cb565b8563ffffffff16610fa40361181f5763ffffffff831660011480611758575063ffffffff83166002145b80611769575063ffffffff83166004145b15611776578094506118cb565b7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa63ffffffff84160161171d5760006117b68363fffffffc166001610735565b602089015190915060038416600403838110156117d1578093505b83900360089081029290921c7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600193850293841b0116911b176020880152600060408801529350836118cb565b8563ffffffff16610fd7036118cb578163ffffffff166003036118bf5763ffffffff83161580611855575063ffffffff83166005145b80611866575063ffffffff83166003145b1561187457600094506118cb565b63ffffffff83166001148061188f575063ffffffff83166002145b806118a0575063ffffffff83166006145b806118b1575063ffffffff83166004145b1561171d57600194506118cb565b63ffffffff9450601693505b6101608701805163ffffffff808816604090920191909152905185821660e09091015260808801805180831660608b015260040190911690526114b8610619565b6000611916611c53565b506080600063ffffffff8716601003611934575060c0810151611a9d565b8663ffffffff166011036119535763ffffffff861660c0830152611a9d565b8663ffffffff1660120361196c575060a0810151611a9d565b8663ffffffff1660130361198b5763ffffffff861660a0830152611a9d565b8663ffffffff166018036119bf5763ffffffff600387810b9087900b02602081901c821660c08501521660a0830152611a9d565b8663ffffffff166019036119f05763ffffffff86811681871602602081901c821660c08501521660a0830152611a9d565b8663ffffffff16601a03611a46578460030b8660030b81611a1357611a13611de5565b0763ffffffff1660c0830152600385810b9087900b81611a3557611a35611de5565b0563ffffffff1660a0830152611a9d565b8663ffffffff16601b03611a9d578463ffffffff168663ffffffff1681611a6f57611a6f611de5565b0663ffffffff90811660c084015285811690871681611a9057611a90611de5565b0463ffffffff1660a08301525b63ffffffff841615611ad857808261016001518563ffffffff1660208110611ac757611ac7611d92565b63ffffffff90921660209290920201525b60808201805163ffffffff80821660608601526004909101169052611afb610619565b979650505050505050565b6000611b1183611baa565b90506003841615611b2157600080fd5b6020810190601f8516601c0360031b83811b913563ffffffff90911b1916178460051c60005b601b811015611b9f5760208401933582821c6001168015611b6f5760018114611b8457611b95565b60008581526020839052604090209450611b95565b600082815260208690526040902094505b5050600101611b47565b505060805250505050565b60ff811661038002610184810190369061050401811015611c4d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f636865636b207468617420746865726520697320656e6f7567682063616c6c6460448201527f6174610000000000000000000000000000000000000000000000000000000000606482015260840161087b565b50919050565b6040805161018081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e08101829052610100810182905261012081018290526101408101919091526101608101611cb9611cbe565b905290565b6040518061040001604052806020906020820280368337509192915050565b60008083601f840112611cef57600080fd5b50813567ffffffffffffffff811115611d0757600080fd5b602083019150836020828501011115611d1f57600080fd5b9250929050565b60008060008060408587031215611d3c57600080fd5b843567ffffffffffffffff80821115611d5457600080fd5b611d6088838901611cdd565b90965094506020870135915080821115611d7957600080fd5b50611d8687828801611cdd565b95989497509550505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60008060408385031215611dd457600080fd5b505080516020909101519092909150565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fdfea164736f6c634300080f000a" +var MIPSDeployedBin = "0x608060405234801561001057600080fd5b50600436106100415760003560e01c8063155633fe146100465780637dc0d1d01461006b578063836e7b32146100af575b600080fd5b610051634000000081565b60405163ffffffff90911681526020015b60405180910390f35b60405173ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168152602001610062565b6100c26100bd366004611d2e565b6100d0565b604051908152602001610062565b60006100da611c5b565b608081146100e757600080fd5b604051610600146100f757600080fd5b6084871461010457600080fd5b6101a4851461011257600080fd5b8635608052602087013560a052604087013560e090811c60c09081526044890135821c82526048890135821c61010052604c890135821c610120526050890135821c61014052605489013590911c61016052605888013560f890811c610180526059890135901c6101a052605a880135901c6101c0526102006101e0819052606288019060005b60208110156101bd57823560e01c8252600490920191602090910190600101610199565b505050806101200151156101db576101d361061b565b915050610612565b6101408101805160010167ffffffffffffffff16905260608101516000906102039082610737565b9050603f601a82901c16600281148061022257508063ffffffff166003145b156102775760006002836303ffffff1663ffffffff16901b846080015163f00000001617905061026c8263ffffffff1660021461026057601f610263565b60005b60ff16826107f3565b945050505050610612565b6101608301516000908190601f601086901c81169190601587901c16602081106102a3576102a3611da2565b602002015192508063ffffffff851615806102c457508463ffffffff16601c145b156102fb578661016001518263ffffffff16602081106102e6576102e6611da2565b6020020151925050601f600b86901c166103b7565b60208563ffffffff16101561035d578463ffffffff16600c148061032557508463ffffffff16600d145b8061033657508463ffffffff16600e145b15610347578561ffff1692506103b7565b6103568661ffff1660106108e4565b92506103b7565b60288563ffffffff1610158061037957508463ffffffff166022145b8061038a57508463ffffffff166026145b156103b7578661016001518263ffffffff16602081106103ac576103ac611da2565b602002015192508190505b60048563ffffffff16101580156103d4575060088563ffffffff16105b806103e557508463ffffffff166001145b15610404576103f685878487610957565b975050505050505050610612565b63ffffffff6000602087831610610469576104248861ffff1660106108e4565b9095019463fffffffc861661043a816001610737565b915060288863ffffffff161015801561045a57508763ffffffff16603014155b1561046757809250600093505b505b600061047789888885610b67565b63ffffffff9081169150603f8a1690891615801561049c575060088163ffffffff1610155b80156104ae5750601c8163ffffffff16105b1561058b578063ffffffff16600814806104ce57508063ffffffff166009145b15610505576104f38163ffffffff166008146104ea57856104ed565b60005b896107f3565b9b505050505050505050505050610612565b8063ffffffff16600a03610525576104f3858963ffffffff8a16156112f7565b8063ffffffff16600b03610546576104f3858963ffffffff8a1615156112f7565b8063ffffffff16600c0361055d576104f38d6113dd565b60108163ffffffff161015801561057a5750601c8163ffffffff16105b1561058b576104f381898988611914565b8863ffffffff1660381480156105a6575063ffffffff861615155b156105db5760018b61016001518763ffffffff16602081106105ca576105ca611da2565b63ffffffff90921660209290920201525b8363ffffffff1663ffffffff146105f8576105f884600184611b0e565b610604858360016112f7565b9b5050505050505050505050505b95945050505050565b60408051608051815260a051602082015260dc519181019190915260fc51604482015261011c51604882015261013c51604c82015261015c51605082015261017c5160548201526101805161019f5160588301526101a0516101bf5160598401526101d851605a840152600092610200929091606283019190855b60208110156106ba57601c8601518452602090950194600490930192600101610696565b506000835283830384a06000945080600181146106da5760039550610702565b8280156106f257600181146106fb5760029650610700565b60009650610700565b600196505b505b50505081900390207effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1660f89190911b17919050565b60008061074383611bb2565b9050600384161561075357600080fd5b6020810190358460051c8160005b601b8110156107b95760208501943583821c6001168015610789576001811461079e576107af565b600084815260208390526040902093506107af565b600082815260208590526040902093505b5050600101610761565b5060805191508181146107d457630badf00d60005260206000fd5b5050601f94909416601c0360031b9390931c63ffffffff169392505050565b60006107fd611c5b565b60809050806060015160040163ffffffff16816080015163ffffffff1614610886576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f6a756d7020696e2064656c617920736c6f74000000000000000000000000000060448201526064015b60405180910390fd5b60608101805160808301805163ffffffff9081169093528583169052908516156108dc57806008018261016001518663ffffffff16602081106108cb576108cb611da2565b63ffffffff90921660209290920201525b61061261061b565b600063ffffffff8381167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff80850183169190911c821615159160016020869003821681901b830191861691821b92911b0182610941576000610943565b815b90861663ffffffff16179250505092915050565b6000610961611c5b565b608090506000816060015160040163ffffffff16826080015163ffffffff16146109e7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f6272616e636820696e2064656c617920736c6f74000000000000000000000000604482015260640161087d565b8663ffffffff1660041480610a0257508663ffffffff166005145b15610a7e5760008261016001518663ffffffff1660208110610a2657610a26611da2565b602002015190508063ffffffff168563ffffffff16148015610a4e57508763ffffffff166004145b80610a7657508063ffffffff168563ffffffff1614158015610a7657508763ffffffff166005145b915050610afb565b8663ffffffff16600603610a9b5760008460030b13159050610afb565b8663ffffffff16600703610ab75760008460030b139050610afb565b8663ffffffff16600103610afb57601f601087901c166000819003610ae05760008560030b1291505b8063ffffffff16600103610af95760008560030b121591505b505b606082018051608084015163ffffffff169091528115610b41576002610b268861ffff1660106108e4565b63ffffffff90811690911b8201600401166080840152610b53565b60808301805160040163ffffffff1690525b610b5b61061b565b98975050505050505050565b6000603f601a86901c16801580610b96575060088163ffffffff1610158015610b965750600f8163ffffffff16105b15610fec57603f86168160088114610bdd5760098114610be657600a8114610bef57600b8114610bf857600c8114610c0157600d8114610c0a57600e8114610c1357610c18565b60209150610c18565b60219150610c18565b602a9150610c18565b602b9150610c18565b60249150610c18565b60259150610c18565b602691505b508063ffffffff16600003610c3f5750505063ffffffff8216601f600686901c161b6112ef565b8063ffffffff16600203610c655750505063ffffffff8216601f600686901c161c6112ef565b8063ffffffff16600303610c9b57601f600688901c16610c9163ffffffff8716821c60208390036108e4565b93505050506112ef565b8063ffffffff16600403610cbd5750505063ffffffff8216601f84161b6112ef565b8063ffffffff16600603610cdf5750505063ffffffff8216601f84161c6112ef565b8063ffffffff16600703610d1257610d098663ffffffff168663ffffffff16901c876020036108e4565b925050506112ef565b8063ffffffff16600803610d2a5785925050506112ef565b8063ffffffff16600903610d425785925050506112ef565b8063ffffffff16600a03610d5a5785925050506112ef565b8063ffffffff16600b03610d725785925050506112ef565b8063ffffffff16600c03610d8a5785925050506112ef565b8063ffffffff16600f03610da25785925050506112ef565b8063ffffffff16601003610dba5785925050506112ef565b8063ffffffff16601103610dd25785925050506112ef565b8063ffffffff16601203610dea5785925050506112ef565b8063ffffffff16601303610e025785925050506112ef565b8063ffffffff16601803610e1a5785925050506112ef565b8063ffffffff16601903610e325785925050506112ef565b8063ffffffff16601a03610e4a5785925050506112ef565b8063ffffffff16601b03610e625785925050506112ef565b8063ffffffff16602003610e7b575050508282016112ef565b8063ffffffff16602103610e94575050508282016112ef565b8063ffffffff16602203610ead575050508183036112ef565b8063ffffffff16602303610ec6575050508183036112ef565b8063ffffffff16602403610edf575050508282166112ef565b8063ffffffff16602503610ef8575050508282176112ef565b8063ffffffff16602603610f11575050508282186112ef565b8063ffffffff16602703610f2b57505050828217196112ef565b8063ffffffff16602a03610f5c578460030b8660030b12610f4d576000610f50565b60015b60ff16925050506112ef565b8063ffffffff16602b03610f84578463ffffffff168663ffffffff1610610f4d576000610f50565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601360248201527f696e76616c696420696e737472756374696f6e00000000000000000000000000604482015260640161087d565b50610f84565b8063ffffffff16601c0361107057603f86166002819003611012575050508282026112ef565b8063ffffffff166020148061102d57508063ffffffff166021145b15610fe6578063ffffffff16602003611044579419945b60005b6380000000871615611066576401fffffffe600197881b169601611047565b92506112ef915050565b8063ffffffff16600f0361109257505065ffffffff0000601083901b166112ef565b8063ffffffff166020036110ce576110c68560031660080260180363ffffffff168463ffffffff16901c60ff1660086108e4565b9150506112ef565b8063ffffffff16602103611103576110c68560021660080260100363ffffffff168463ffffffff16901c61ffff1660106108e4565b8063ffffffff1660220361113257505063ffffffff60086003851602811681811b198416918316901b176112ef565b8063ffffffff1660230361114957829150506112ef565b8063ffffffff1660240361117b578460031660080260180363ffffffff168363ffffffff16901c60ff169150506112ef565b8063ffffffff166025036111ae578460021660080260100363ffffffff168363ffffffff16901c61ffff169150506112ef565b8063ffffffff166026036111e057505063ffffffff60086003851602601803811681811c198416918316901c176112ef565b8063ffffffff1660280361121657505060ff63ffffffff60086003861602601803811682811b9091188316918416901b176112ef565b8063ffffffff1660290361124d57505061ffff63ffffffff60086002861602601003811682811b9091188316918416901b176112ef565b8063ffffffff16602a0361127c57505063ffffffff60086003851602811681811c198316918416901c176112ef565b8063ffffffff16602b0361129357839150506112ef565b8063ffffffff16602e036112c557505063ffffffff60086003851602601803811681811b198316918416901b176112ef565b8063ffffffff166030036112dc57829150506112ef565b8063ffffffff16603803610f8457839150505b949350505050565b6000611301611c5b565b506080602063ffffffff861610611374576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600e60248201527f76616c6964207265676973746572000000000000000000000000000000000000604482015260640161087d565b63ffffffff8516158015906113865750825b156113ba57838161016001518663ffffffff16602081106113a9576113a9611da2565b63ffffffff90921660209290920201525b60808101805163ffffffff8082166060850152600490910116905261061261061b565b60006113e7611c5b565b506101e051604081015160808083015160a084015160c09094015191936000928392919063ffffffff8616610ffa036114615781610fff81161561143057610fff811661100003015b8363ffffffff166000036114575760e08801805163ffffffff83820116909152955061145b565b8395505b506118d3565b8563ffffffff16610fcd0361147c57634000000094506118d3565b8563ffffffff166110180361149457600194506118d3565b8563ffffffff16611096036114ca57600161012088015260ff83166101008801526114bd61061b565b9998505050505050505050565b8563ffffffff16610fa3036117365763ffffffff8316156118d3577ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffb63ffffffff8416016116f05760006115258363fffffffc166001610737565b60208901519091508060001a60010361159457604080516000838152336020528d83526060902091527effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f01000000000000000000000000000000000000000000000000000000000000001790505b6040808a015190517fe03110e10000000000000000000000000000000000000000000000000000000081526004810183905263ffffffff9091166024820152600090819073ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000169063e03110e1906044016040805180830381865afa158015611635573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906116599190611dd1565b91509150600386168060040382811015611671578092505b508186101561167e578591505b8260088302610100031c9250826008828460040303021b9250600180600883600403021b036001806008858560040303021b039150811981169050838119871617955050506116d58663fffffffc16600186611b0e565b60408b018051820163ffffffff169052975061173192505050565b7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffd63ffffffff841601611725578094506118d3565b63ffffffff9450600993505b6118d3565b8563ffffffff16610fa4036118275763ffffffff831660011480611760575063ffffffff83166002145b80611771575063ffffffff83166004145b1561177e578094506118d3565b7ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa63ffffffff8416016117255760006117be8363fffffffc166001610737565b602089015190915060038416600403838110156117d9578093505b83900360089081029290921c7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600193850293841b0116911b176020880152600060408801529350836118d3565b8563ffffffff16610fd7036118d3578163ffffffff166003036118c75763ffffffff8316158061185d575063ffffffff83166005145b8061186e575063ffffffff83166003145b1561187c57600094506118d3565b63ffffffff831660011480611897575063ffffffff83166002145b806118a8575063ffffffff83166006145b806118b9575063ffffffff83166004145b1561172557600194506118d3565b63ffffffff9450601693505b6101608701805163ffffffff808816604090920191909152905185821660e09091015260808801805180831660608b015260040190911690526114bd61061b565b600061191e611c5b565b506080600063ffffffff871660100361193c575060c0810151611aa5565b8663ffffffff1660110361195b5763ffffffff861660c0830152611aa5565b8663ffffffff16601203611974575060a0810151611aa5565b8663ffffffff166013036119935763ffffffff861660a0830152611aa5565b8663ffffffff166018036119c75763ffffffff600387810b9087900b02602081901c821660c08501521660a0830152611aa5565b8663ffffffff166019036119f85763ffffffff86811681871602602081901c821660c08501521660a0830152611aa5565b8663ffffffff16601a03611a4e578460030b8660030b81611a1b57611a1b611df5565b0763ffffffff1660c0830152600385810b9087900b81611a3d57611a3d611df5565b0563ffffffff1660a0830152611aa5565b8663ffffffff16601b03611aa5578463ffffffff168663ffffffff1681611a7757611a77611df5565b0663ffffffff90811660c084015285811690871681611a9857611a98611df5565b0463ffffffff1660a08301525b63ffffffff841615611ae057808261016001518563ffffffff1660208110611acf57611acf611da2565b63ffffffff90921660209290920201525b60808201805163ffffffff80821660608601526004909101169052611b0361061b565b979650505050505050565b6000611b1983611bb2565b90506003841615611b2957600080fd5b6020810190601f8516601c0360031b83811b913563ffffffff90911b1916178460051c60005b601b811015611ba75760208401933582821c6001168015611b775760018114611b8c57611b9d565b60008581526020839052604090209450611b9d565b600082815260208690526040902094505b5050600101611b4f565b505060805250505050565b60ff8116610380026101a4810190369061052401811015611c55576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f636865636b207468617420746865726520697320656e6f7567682063616c6c6460448201527f6174610000000000000000000000000000000000000000000000000000000000606482015260840161087d565b50919050565b6040805161018081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e08101829052610100810182905261012081018290526101408101919091526101608101611cc1611cc6565b905290565b6040518061040001604052806020906020820280368337509192915050565b60008083601f840112611cf757600080fd5b50813567ffffffffffffffff811115611d0f57600080fd5b602083019150836020828501011115611d2757600080fd5b9250929050565b600080600080600060608688031215611d4657600080fd5b853567ffffffffffffffff80821115611d5e57600080fd5b611d6a89838a01611ce5565b90975095506020880135915080821115611d8357600080fd5b50611d9088828901611ce5565b96999598509660400135949350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60008060408385031215611de457600080fd5b505080516020909101519092909150565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fdfea164736f6c634300080f000a" -var MIPSDeployedSourceMap = "1131:39568:128:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1710:45;;1745:10;1710:45;;;;;188:10:286;176:23;;;158:42;;146:2;131:18;1710:45:128;;;;;;;;2448:99;;;412:42:286;2534:6:128;400:55:286;382:74;;370:2;355:18;2448:99:128;211:251:286;25579:6339:128;;;;;;:::i;:::-;;:::i;:::-;;;1687:25:286;;;1675:2;1660:18;25579:6339:128;1541:177:286;25579:6339:128;25657:7;25700:18;;:::i;:::-;25847:4;25840:5;25837:15;25827:134;;25941:1;25938;25931:12;25827:134;25997:4;25991:11;26004;25988:28;25978:137;;26095:1;26092;26085:12;25978:137;26163:3;26145:16;26142:25;26132:150;;26262:1;26259;26252:12;26132:150;26326:3;26312:12;26309:21;26299:145;;26424:1;26421;26414:12;26299:145;26704:24;;27048:4;26750:20;27106:2;26808:21;;26704:24;26866:18;26750:20;26808:21;;;26704:24;26681:21;26677:52;;;26866:18;26750:20;;;26808:21;;;26704:24;26677:52;;26750:20;;26808:21;;;26704:24;26677:52;;26866:18;26750:20;26808:21;;;26704:24;26677:52;;26866:18;26750:20;26808:21;;;26704:24;26677:52;;26866:18;26750:20;26808:21;;;26704:24;26677:52;;;26866:18;26750:20;26808:21;;;26704:24;26681:21;26677:52;;;26866:18;26750:20;26808:21;;;26704:24;26677:52;;26866:18;26750:20;26808:21;;;26704:24;26677:52;;26866:18;26750:20;27724:10;26866:18;27714:21;;;26808;;;;27822:1;27807:77;27832:2;27829:1;27826:9;27807:77;;;26704:24;;26681:21;26677:52;26750:20;;27880:1;26808:21;;;;26692:2;26866:18;;;;27850:1;27843:9;27807:77;;;27811:14;;;27962:5;:12;;;27958:71;;;28001:13;:11;:13::i;:::-;27994:20;;;;;27958:71;28043:10;;;:15;;28057:1;28043:15;;;;;28128:8;;;;-1:-1:-1;;28120:20:128;;-1:-1:-1;28120:7:128;:20::i;:::-;28106:34;-1:-1:-1;28170:10:128;28178:2;28170:10;;;;28247:1;28237:11;;;:26;;;28252:6;:11;;28262:1;28252:11;28237:26;28233:310;;;28393:13;28462:1;28440:4;28447:10;28440:17;28439:24;;;;28410:5;:12;;;28425:10;28410:25;28409:54;28393:70;;28488:40;28499:6;:11;;28509:1;28499:11;:20;;28517:2;28499:20;;;28513:1;28499:20;28488:40;;28521:6;28488:10;:40::i;:::-;28481:47;;;;;;;;28233:310;28792:15;;;;28587:9;;;;28724:4;28718:2;28710:10;;;28709:19;;;28792:15;28817:2;28809:10;;;28808:19;28792:36;;;;;;;:::i;:::-;;;;;;-1:-1:-1;28857:5:128;28881:11;;;;;:29;;;28896:6;:14;;28906:4;28896:14;28881:29;28877:832;;;28973:5;:15;;;28989:5;28973:22;;;;;;;;;:::i;:::-;;;;;;-1:-1:-1;;29036:4:128;29030:2;29022:10;;;29021:19;28877:832;;;29074:4;29065:6;:13;;;29061:648;;;29195:6;:13;;29205:3;29195:13;:30;;;;29212:6;:13;;29222:3;29212:13;29195:30;:47;;;;29229:6;:13;;29239:3;29229:13;29195:47;29191:253;;;29305:4;29312:6;29305:13;29300:18;;29061:648;;29191:253;29404:21;29407:4;29414:6;29407:13;29422:2;29404;:21::i;:::-;29399:26;;29061:648;;;29478:4;29468:6;:14;;;;:32;;;;29486:6;:14;;29496:4;29486:14;29468:32;:50;;;;29504:6;:14;;29514:4;29504:14;29468:50;29464:245;;;29588:5;:15;;;29604:5;29588:22;;;;;;;;;:::i;:::-;;;;;29583:27;;29689:5;29681:13;;29464:245;29738:1;29728:6;:11;;;;:25;;;;;29752:1;29743:6;:10;;;29728:25;29727:42;;;;29758:6;:11;;29768:1;29758:11;29727:42;29723:125;;;29796:37;29809:6;29817:4;29823:5;29830:2;29796:12;:37::i;:::-;29789:44;;;;;;;;;;;29723:125;29881:13;29862:16;30033:4;30023:14;;;;30019:446;;30102:21;30105:4;30112:6;30105:13;30120:2;30102;:21::i;:::-;30096:27;;;;30160:10;30155:15;;30194:16;30155:15;30208:1;30194:7;:16::i;:::-;30188:22;;30242:4;30232:6;:14;;;;:32;;;;;30250:6;:14;;30260:4;30250:14;;30232:32;30228:223;;;30329:4;30317:16;;30431:1;30423:9;;30228:223;30039:426;30019:446;30498:10;30511:26;30519:4;30525:2;30529;30533:3;30511:7;:26::i;:::-;30540:10;30511:39;;;;-1:-1:-1;30636:4:128;30629:11;;;30668;;;:24;;;;;30691:1;30683:4;:9;;;;30668:24;:39;;;;;30703:4;30696;:11;;;30668:39;30664:847;;;30731:4;:9;;30739:1;30731:9;:22;;;;30744:4;:9;;30752:1;30744:9;30731:22;30727:144;;;30815:37;30826:4;:9;;30834:1;30826:9;:21;;30842:5;30826:21;;;30838:1;30826:21;30849:2;30815:10;:37::i;:::-;30808:44;;;;;;;;;;;;;;;30727:144;30893:4;:11;;30901:3;30893:11;30889:121;;30963:28;30972:5;30979:2;30983:7;;;;30963:8;:28::i;30889:121::-;31031:4;:11;;31039:3;31031:11;31027:121;;31101:28;31110:5;31117:2;31121:7;;;;;31101:8;:28::i;31027:121::-;31218:4;:11;;31226:3;31218:11;31214:80;;31260:15;:13;:15::i;31214:80::-;31397:4;31389;:12;;;;:27;;;;;31412:4;31405;:11;;;31389:27;31385:112;;;31447:31;31458:4;31464:2;31468;31472:5;31447:10;:31::i;31385:112::-;31571:6;:14;;31581:4;31571:14;:28;;;;-1:-1:-1;31589:10:128;;;;;31571:28;31567:93;;;31644:1;31619:5;:15;;;31635:5;31619:22;;;;;;;;;:::i;:::-;:26;;;;:22;;;;;;:26;31567:93;31706:9;:26;;31719:13;31706:26;31702:92;;31752:27;31761:9;31772:1;31775:3;31752:8;:27::i;:::-;31875:26;31884:5;31891:3;31896:4;31875:8;:26::i;:::-;31868:33;;;;;;;;;;;;;25579:6339;;;;;;;:::o;3087:2334::-;3634:4;3628:11;;3550:4;3353:31;3342:43;;3413:13;3353:31;3752:2;3452:13;;3342:43;3359:24;3353:31;3452:13;;;3342:43;;;;3359:24;3353:31;3452:13;;;3342:43;3359:24;3353:31;3452:13;;;3342:43;3359:24;3353:31;3452:13;;;3342:43;3359:24;3353:31;3452:13;;;3342:43;3359:24;3353:31;3452:13;;;3342:43;3413:13;4180:11;3359:24;3353:31;3452:13;;;3342:43;3413:13;4275:11;3359:24;3353:31;3452:13;;;3342:43;3359:24;3353:31;3452:13;;;3342:43;3128:12;;4415:13;;3628:11;;3452:13;;;;4180:11;3128:12;4495:84;4520:2;4517:1;4514:9;4495:84;;;3369:13;3359:24;;3353:31;3342:43;;3373:2;3413:13;;;;4575:1;3452:13;;;;4538:1;4531:9;4495:84;;;4499:14;4642:1;4638:2;4631:13;4737:5;4733:2;4729:14;4722:5;4717:27;4811:1;4797:15;;4832:6;4856:1;4851:273;;;;5191:1;5181:11;;4825:369;;4851:273;4883:8;4941:22;;;;5020:1;5015:22;;;;5107:1;5097:11;;4876:234;;4941:22;4960:1;4950:11;;4941:22;;5015;5034:1;5024:11;;4876:234;;4825:369;-1:-1:-1;;;5317:14:128;;;5300:32;;5360:19;5356:30;5392:3;5388:16;;;;5353:52;;3087:2334;-1:-1:-1;3087:2334:128:o;21634:1831::-;21707:11;21818:14;21835:24;21847:11;21835;:24::i;:::-;21818:41;;21967:1;21960:5;21956:13;21953:33;;;21982:1;21979;21972:12;21953:33;22115:2;22103:15;;;22056:20;22545:5;22542:1;22538:13;22580:4;22616:1;22601:343;22626:2;22623:1;22620:9;22601:343;;;22749:2;22737:15;;;22686:20;22784:12;;;22798:1;22780:20;22821:42;;;;22889:1;22884:42;;;;22773:153;;22821:42;22279:1;22272:12;;;22312:2;22305:13;;;22357:2;22344:16;;22830:31;;22821:42;;22884;22279:1;22272:12;;;22312:2;22305:13;;;22357:2;22344:16;;22893:31;;22773:153;-1:-1:-1;;22644:1:128;22637:9;22601:343;;;22605:14;23054:4;23048:11;23033:26;;23140:7;23134:4;23131:17;23121:124;;23182:10;23179:1;23172:21;23224:2;23221:1;23214:13;23121:124;-1:-1:-1;;23372:2:128;23361:14;;;;23349:10;23345:31;23342:1;23338:39;23406:16;;;;23424:10;23402:33;;21634:1831;-1:-1:-1;;;21634:1831:128:o;18744:823::-;18813:12;18900:18;;:::i;:::-;18968:4;18959:13;;19020:5;:8;;;19031:1;19020:12;19004:28;;:5;:12;;;:28;;;19000:95;;19052:28;;;;;2114:2:286;19052:28:128;;;2096:21:286;2153:2;2133:18;;;2126:30;2192:20;2172:18;;;2165:48;2230:18;;19052:28:128;;;;;;;;19000:95;19184:8;;;;;19217:12;;;;;19206:23;;;;;;;19243:20;;;;;19184:8;19375:13;;;19371:90;;19436:6;19445:1;19436:10;19408:5;:15;;;19424:8;19408:25;;;;;;;;;:::i;:::-;:38;;;;:25;;;;;;:38;19371:90;19537:13;:11;:13::i;:::-;19530:20;18744:823;-1:-1:-1;;;;;18744:823:128:o;2645:339::-;2706:11;2770:18;;;;2779:8;;;;2770:18;;;;;;2769:25;;;;;2786:1;2833:2;:9;;;2827:16;;;;;2826:22;;2825:32;;;;;;;2887:9;;2886:15;2769:25;2944:21;;2964:1;2944:21;;;2955:6;2944:21;2929:11;;;;;:37;;-1:-1:-1;;;2645:339:128;;;;:::o;13620:2026::-;13717:12;13803:18;;:::i;:::-;13871:4;13862:13;;13903:17;13963:5;:8;;;13974:1;13963:12;13947:28;;:5;:12;;;:28;;;13943:97;;13995:30;;;;;2461:2:286;13995:30:128;;;2443:21:286;2500:2;2480:18;;;2473:30;2539:22;2519:18;;;2512:50;2579:18;;13995:30:128;2259:344:286;13943:97:128;14110:7;:12;;14121:1;14110:12;:28;;;;14126:7;:12;;14137:1;14126:12;14110:28;14106:947;;;14158:9;14170:5;:15;;;14186:6;14170:23;;;;;;;;;:::i;:::-;;;;;14158:35;;14234:2;14227:9;;:3;:9;;;:25;;;;;14240:7;:12;;14251:1;14240:12;14227:25;14226:58;;;;14265:2;14258:9;;:3;:9;;;;:25;;;;;14271:7;:12;;14282:1;14271:12;14258:25;14211:73;;14140:159;14106:947;;;14396:7;:12;;14407:1;14396:12;14392:661;;14457:1;14449:3;14443:15;;;;14428:30;;14392:661;;;14561:7;:12;;14572:1;14561:12;14557:496;;14621:1;14614:3;14608:14;;;14593:29;;14557:496;;;14742:7;:12;;14753:1;14742:12;14738:315;;14830:4;14824:2;14815:11;;;14814:20;14800:10;14857:8;;;14853:84;;14917:1;14910:3;14904:14;;;14889:29;;14853:84;14958:3;:8;;14965:1;14958:8;14954:85;;15019:1;15011:3;15005:15;;;;14990:30;;14954:85;14756:297;14738:315;15129:8;;;;;15207:12;;;;15196:23;;;;;15363:178;;;;15454:1;15428:22;15431:5;15439:6;15431:14;15447:2;15428;:22::i;:::-;:27;;;;;;;15414:42;;15423:1;15414:42;15399:57;:12;;;:57;15363:178;;;15510:12;;;;;15525:1;15510:16;15495:31;;;;15363:178;15616:13;:11;:13::i;:::-;15609:20;13620:2026;-1:-1:-1;;;;;;;;13620:2026:128:o;31964:8733::-;32051:10;32113;32121:2;32113:10;;;;32152:11;;;:44;;;32178:1;32168:6;:11;;;;:27;;;;;32192:3;32183:6;:12;;;32168:27;32148:8490;;;32237:4;32230:11;;32361:6;32421:3;32416:25;;;;32496:3;32491:25;;;;32570:3;32565:25;;;;32645:3;32640:25;;;;32719:3;32714:25;;;;32792:3;32787:25;;;;32866:3;32861:25;;;;32354:532;;32416:25;32435:4;32427:12;;32416:25;;32491;32510:4;32502:12;;32491:25;;32565;32584:4;32576:12;;32565:25;;32640;32659:4;32651:12;;32640:25;;32714;32733:4;32725:12;;32714:25;;32787;32806:4;32798:12;;32787:25;;32861;32880:4;32872:12;;32354:532;;32949:4;:12;;32957:4;32949:12;32945:4023;;-1:-1:-1;;;33000:9:128;32992:26;;33013:4;33008:1;33000:9;;;32999:18;32992:26;32985:33;;32945:4023;33086:4;:12;;33094:4;33086:12;33082:3886;;-1:-1:-1;;;33137:9:128;33129:26;;33150:4;33145:1;33137:9;;;33136:18;33129:26;33122:33;;33082:3886;33223:4;:12;;33231:4;33223:12;33219:3749;;33288:4;33283:1;33275:9;;;33274:18;33321:27;33275:9;33324:11;;;;33337:2;:10;;;33321:2;:27::i;:::-;33314:34;;;;;;;33219:3749;33417:4;:12;;33425:4;33417:12;33413:3555;;-1:-1:-1;;;33460:17:128;;;33472:4;33467:9;;33460:17;33453:24;;33413:3555;33546:4;:11;;33554:3;33546:11;33542:3426;;-1:-1:-1;;;33588:17:128;;;33600:4;33595:9;;33588:17;33581:24;;33542:3426;33674:4;:12;;33682:4;33674:12;33670:3298;;33717:21;33726:2;33720:8;;:2;:8;;;;33735:2;33730;:7;33717:2;:21::i;:::-;33710:28;;;;;;33670:3298;33987:4;:12;;33995:4;33987:12;33983:2985;;34030:2;34023:9;;;;;;33983:2985;34101:4;:12;;34109:4;34101:12;34097:2871;;34144:2;34137:9;;;;;;34097:2871;34215:4;:12;;34223:4;34215:12;34211:2757;;34258:2;34251:9;;;;;;34211:2757;34329:4;:12;;34337:4;34329:12;34325:2643;;34372:2;34365:9;;;;;;34325:2643;34446:4;:12;;34454:4;34446:12;34442:2526;;34489:2;34482:9;;;;;;34442:2526;34606:4;:12;;34614:4;34606:12;34602:2366;;34649:2;34642:9;;;;;;34602:2366;34720:4;:12;;34728:4;34720:12;34716:2252;;34763:2;34756:9;;;;;;34716:2252;34834:4;:12;;34842:4;34834:12;34830:2138;;34877:2;34870:9;;;;;;34830:2138;34948:4;:12;;34956:4;34948:12;34944:2024;;34991:2;34984:9;;;;;;34944:2024;35062:4;:12;;35070:4;35062:12;35058:1910;;35105:2;35098:9;;;;;;35058:1910;35176:4;:12;;35184:4;35176:12;35172:1796;;35219:2;35212:9;;;;;;35172:1796;35291:4;:12;;35299:4;35291:12;35287:1681;;35334:2;35327:9;;;;;;35287:1681;35404:4;:12;;35412:4;35404:12;35400:1568;;35447:2;35440:9;;;;;;35400:1568;35518:4;:12;;35526:4;35518:12;35514:1454;;35561:2;35554:9;;;;;;35514:1454;35710:4;:12;;35718:4;35710:12;35706:1262;;-1:-1:-1;;;35754:7:128;;;35746:16;;35706:1262;35831:4;:12;;35839:4;35831:12;35827:1141;;-1:-1:-1;;;35875:7:128;;;35867:16;;35827:1141;35951:4;:12;;35959:4;35951:12;35947:1021;;-1:-1:-1;;;35995:7:128;;;35987:16;;35947:1021;36072:4;:12;;36080:4;36072:12;36068:900;;-1:-1:-1;;;36116:7:128;;;36108:16;;36068:900;36192:4;:12;;36200:4;36192:12;36188:780;;-1:-1:-1;;;36236:7:128;;;36228:16;;36188:780;36311:4;:12;;36319:4;36311:12;36307:661;;-1:-1:-1;;;36355:7:128;;;36347:16;;36307:661;36431:4;:12;;36439:4;36431:12;36427:541;;-1:-1:-1;;;36475:7:128;;;36467:16;;36427:541;36551:4;:12;;36559:4;36551:12;36547:421;;-1:-1:-1;;;36596:7:128;;;36594:10;36587:17;;36547:421;36673:4;:12;;36681:4;36673:12;36669:299;;36734:2;36716:21;;36722:2;36716:21;;;:29;;36744:1;36716:29;;;36740:1;36716:29;36709:36;;;;;;;;36669:299;36815:4;:12;;36823:4;36815:12;36811:157;;36863:2;36858:7;;:2;:7;;;:15;;36872:1;36858:15;;36811:157;36920:29;;;;;2810:2:286;36920:29:128;;;2792:21:286;2849:2;2829:18;;;2822:30;2888:21;2868:18;;;2861:49;2927:18;;36920:29:128;2608:343:286;36811:157:128;32198:4784;32148:8490;;;37038:6;:14;;37048:4;37038:14;37034:3590;;37097:4;37090:11;;37172:3;37164:11;;;37160:549;;-1:-1:-1;;;37217:21:128;;;37203:36;;37160:549;37324:4;:12;;37332:4;37324:12;:28;;;;37340:4;:12;;37348:4;37340:12;37324:28;37320:389;;;37384:4;:12;;37392:4;37384:12;37380:83;;37433:3;;;37380:83;37488:8;37526:127;37538:10;37533:15;;:20;37526:127;;37618:8;37585:3;37618:8;;;;;37585:3;37526:127;;;37685:1;-1:-1:-1;37678:8:128;;-1:-1:-1;;37678:8:128;37034:3590;37776:6;:14;;37786:4;37776:14;37772:2852;;-1:-1:-1;;37821:8:128;37827:2;37821:8;;;;37814:15;;37772:2852;37896:6;:14;;37906:4;37896:14;37892:2732;;37941:42;37959:2;37964:1;37959:6;37969:1;37958:12;37953:2;:17;37945:26;;:3;:26;;;;37975:4;37944:35;37981:1;37941:2;:42::i;37892:2732::-;38050:6;:14;;38060:4;38050:14;38046:2578;;38095:45;38113:2;38118:1;38113:6;38123:1;38112:12;38107:2;:17;38099:26;;:3;:26;;;;38129:6;38098:37;38137:2;38095;:45::i;38046:2578::-;38208:6;:14;;38218:4;38208:14;38204:2420;;-1:-1:-1;;38259:21:128;38278:1;38273;38268:6;;38267:12;38259:21;;38316:36;;;38387:5;38382:10;;38259:21;;;;;38381:18;38374:25;;38204:2420;38466:6;:14;;38476:4;38466:14;38462:2162;;38511:3;38504:10;;;;;38462:2162;38582:6;:14;;38592:4;38582:14;38578:2046;;38642:2;38647:1;38642:6;38652:1;38641:12;38636:2;:17;38628:26;;:3;:26;;;;38658:4;38627:35;38620:42;;;;;38578:2046;38731:6;:14;;38741:4;38731:14;38727:1897;;38791:2;38796:1;38791:6;38801:1;38790:12;38785:2;:17;38777:26;;:3;:26;;;;38807:6;38776:37;38769:44;;;;;38727:1897;38882:6;:14;;38892:4;38882:14;38878:1746;;-1:-1:-1;;38933:26:128;38957:1;38952;38947:6;;38946:12;38941:2;:17;38933:26;;38995:41;;;39071:5;39066:10;;38933:26;;;;;39065:18;39058:25;;38878:1746;39151:6;:14;;39161:4;39151:14;39147:1477;;-1:-1:-1;;39208:4:128;39202:34;39234:1;39229;39224:6;;39223:12;39218:2;:17;39202:34;;39292:27;;;39272:48;;;39350:10;;39203:9;;;39202:34;;39349:18;39342:25;;39147:1477;39435:6;:14;;39445:4;39435:14;39431:1193;;-1:-1:-1;;39492:6:128;39486:36;39520:1;39515;39510:6;;39509:12;39504:2;:17;39486:36;;39578:29;;;39558:50;;;39638:10;;39487:11;;;39486:36;;39637:18;39630:25;;39431:1193;39724:6;:14;;39734:4;39724:14;39720:904;;-1:-1:-1;;39775:20:128;39793:1;39788;39783:6;;39782:12;39775:20;;39831:36;;;39903:5;39897:11;;39775:20;;;;;39896:19;39889:26;;39720:904;39983:6;:14;;39993:4;39983:14;39979:645;;40028:2;40021:9;;;;;39979:645;40099:6;:14;;40109:4;40099:14;40095:529;;-1:-1:-1;;40150:25:128;40173:1;40168;40163:6;;40162:12;40157:2;:17;40150:25;;40211:41;;;40288:5;40282:11;;40150:25;;;;;40281:19;40274:26;;40095:529;40367:6;:14;;40377:4;40367:14;40363:261;;40412:3;40405:10;;;;;40363:261;40482:6;:14;;40492:4;40482:14;40478:146;;40527:2;40520:9;;;;;19848:782;19934:12;20021:18;;:::i;:::-;-1:-1:-1;20089:4:128;20196:2;20184:14;;;;20176:41;;;;;;;3158:2:286;20176:41:128;;;3140:21:286;3197:2;3177:18;;;3170:30;3236:16;3216:18;;;3209:44;3270:18;;20176:41:128;2956:338:286;20176:41:128;20313:14;;;;;;;:30;;;20331:12;20313:30;20309:102;;;20392:4;20363:5;:15;;;20379:9;20363:26;;;;;;;;;:::i;:::-;:33;;;;:26;;;;;;:33;20309:102;20466:12;;;;;20455:23;;;;:8;;;:23;20522:1;20507:16;;;20492:31;;;20600:13;:11;:13::i;5506:7728::-;5549:12;5635:18;;:::i;:::-;-1:-1:-1;5813:15:128;;:18;;;;5703:4;5973:18;;;;6017;;;;6061;;;;;5703:4;;5793:17;;;;5973:18;6017;6151;;;6165:4;6151:18;6147:6777;;6201:2;6230:4;6225:9;;:14;6221:144;;6341:4;6336:9;;6328:4;:18;6322:24;6221:144;6386:2;:7;;6392:1;6386:7;6382:161;;6422:10;;;;;6454:16;;;;;;;;6422:10;-1:-1:-1;6382:161:128;;;6522:2;6517:7;;6382:161;6171:386;6147:6777;;;6659:10;:18;;6673:4;6659:18;6655:6269;;1745:10;6697:14;;6655:6269;;;6795:10;:18;;6809:4;6795:18;6791:6133;;6838:1;6833:6;;6791:6133;;;6963:10;:18;;6977:4;6963:18;6959:5965;;7016:4;7001:12;;;:19;7038:26;;;:14;;;:26;7089:13;:11;:13::i;:::-;7082:20;;;;;;;;;5506:7728;:::o;6959:5965::-;7228:10;:18;;7242:4;7228:18;7224:5700;;7379:14;;;7375:2708;7224:5700;7375:2708;7549:22;;;;;7545:2538;;7674:10;7687:27;7695:2;7700:10;7695:15;7712:1;7687:7;:27::i;:::-;7798:17;;;;7674:40;;-1:-1:-1;7798:17:128;7776:19;7948:14;7967:1;7942:26;7938:131;;8010:36;8034:11;1277:21:129;1426:15;;;1467:8;1461:4;1454:22;1595:4;1582:18;;1602:19;1578:44;1624:11;1575:61;;1222:430;8010:36:128;7996:50;;7938:131;8155:20;;;;;8122:54;;;;;;;;3472:25:286;;;8122:54:128;3533:23:286;;;3513:18;;;3506:51;8091:11:128;;;;8122:19;:6;:19;;;;3445:18:286;;8122:54:128;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;8090:86;;;;8403:1;8399:2;8395:10;8500:9;8497:1;8493:17;8582:6;8575:5;8572:17;8569:40;;;8602:5;8592:15;;8569:40;;8685:6;8681:2;8678:14;8675:34;;;8705:2;8695:12;;8675:34;8811:3;8806:1;8798:6;8794:14;8789:3;8785:24;8781:34;8774:41;;8911:3;8907:1;8895:9;8886:6;8883:1;8879:14;8875:30;8871:38;8867:48;8860:55;;9066:1;9062;9058;9046:9;9043:1;9039:17;9035:25;9031:33;9027:41;9193:1;9189;9185;9176:6;9164:9;9161:1;9157:17;9153:30;9149:38;9145:46;9141:54;9123:72;;9324:10;9320:15;9314:4;9310:26;9302:34;;9440:3;9432:4;9428:9;9423:3;9419:19;9416:28;9409:35;;;;9586:33;9595:2;9600:10;9595:15;9612:1;9615:3;9586:8;:33::i;:::-;9641:20;;;:38;;;;;;;;;-1:-1:-1;7545:2538:128;;-1:-1:-1;;;7545:2538:128;;9798:18;;;;;9794:289;;9968:2;9963:7;;7224:5700;;9794:289;10022:10;10017:15;;2053:3;10054:10;;9794:289;7224:5700;;;10212:10;:18;;10226:4;10212:18;10208:2716;;10366:15;;;1824:1;10366:15;;:34;;-1:-1:-1;10385:15:128;;;1859:1;10385:15;10366:34;:57;;;-1:-1:-1;10404:19:128;;;1936:1;10404:19;10366:57;10362:1593;;;10452:2;10447:7;;10208:2716;;10362:1593;10578:23;;;;;10574:1381;;10625:10;10638:27;10646:2;10651:10;10646:15;10663:1;10638:7;:27::i;:::-;10741:17;;;;10625:40;;-1:-1:-1;10984:1:128;10976:10;;11078:1;11074:17;11153:13;;;11150:32;;;11175:5;11169:11;;11150:32;11461:14;;;11267:1;11457:22;;;11453:32;;;;11350:26;11374:1;11259:10;;;11354:18;;;11350:26;11449:43;11255:20;;11557:12;11685:17;;;:23;11753:1;11730:20;;;:24;11263:2;-1:-1:-1;11263:2:128;7224:5700;;10208:2716;12157:10;:18;;12171:4;12157:18;12153:771;;12267:2;:7;;12273:1;12267:7;12263:647;;12360:14;;;;;:40;;-1:-1:-1;12378:22:128;;;1978:1;12378:22;12360:40;:62;;;-1:-1:-1;12404:18:128;;;1897:1;12404:18;12360:62;12356:404;;;12455:1;12450:6;;12263:647;;12356:404;12501:15;;;1824:1;12501:15;;:34;;-1:-1:-1;12520:15:128;;;1859:1;12520:15;12501:34;:61;;;-1:-1:-1;12539:23:128;;;2021:1;12539:23;12501:61;:84;;;-1:-1:-1;12566:19:128;;;1936:1;12566:19;12501:84;12497:263;;;12618:1;12613:6;;7224:5700;;12263:647;12811:10;12806:15;;2087:4;12843:11;;12263:647;12999:15;;;;;:23;;;;:18;;;;:23;;;;13036:15;;:23;;;:18;;;;:23;-1:-1:-1;13125:12:128;;;;13114:23;;;:8;;;:23;13181:1;13166:16;13151:31;;;;;13204:13;:11;:13::i;15972:2480::-;16066:12;16152:18;;:::i;:::-;-1:-1:-1;16220:4:128;16252:10;16360:13;;;16369:4;16360:13;16356:1705;;-1:-1:-1;16399:8:128;;;;16356:1705;;;16518:5;:13;;16527:4;16518:13;16514:1547;;16551:14;;;:8;;;:14;16514:1547;;;16681:5;:13;;16690:4;16681:13;16677:1384;;-1:-1:-1;16720:8:128;;;;16677:1384;;;16839:5;:13;;16848:4;16839:13;16835:1226;;16872:14;;;:8;;;:14;16835:1226;;;17013:5;:13;;17022:4;17013:13;17009:1052;;17140:9;17086:17;17066;;;17086;;;;17066:37;17147:2;17140:9;;;;;17122:8;;;:28;17168:22;:8;;;:22;17009:1052;;;17327:5;:13;;17336:4;17327:13;17323:738;;17394:11;17380;;;17394;;;17380:25;17449:2;17442:9;;;;;17424:8;;;:28;17470:22;:8;;;:22;17323:738;;;17651:5;:13;;17660:4;17651:13;17647:414;;17721:3;17702:23;;17708:3;17702:23;;;;;;;:::i;:::-;;17684:42;;:8;;;:42;17762:23;;;;;;;;;;;;;:::i;:::-;;17744:42;;:8;;;:42;17647:414;;;17955:5;:13;;17964:4;17955:13;17951:110;;18005:3;17999:9;;:3;:9;;;;;;;:::i;:::-;;17988:20;;;;:8;;;:20;18037:9;;;;;;;;;;;:::i;:::-;;18026:20;;:8;;;:20;17951:110;18154:14;;;;18150:85;;18217:3;18188:5;:15;;;18204:9;18188:26;;;;;;;;;:::i;:::-;:32;;;;:26;;;;;;:32;18150:85;18289:12;;;;;18278:23;;;;:8;;;:23;18345:1;18330:16;;;18315:31;;;18422:13;:11;:13::i;:::-;18415:20;15972:2480;-1:-1:-1;;;;;;;15972:2480:128:o;23801:1654::-;23977:14;23994:24;24006:11;23994;:24::i;:::-;23977:41;;24126:1;24119:5;24115:13;24112:33;;;24141:1;24138;24131:12;24112:33;24280:2;24474:15;;;24299:2;24288:14;;24276:10;24272:31;24269:1;24265:39;24430:16;;;24215:20;;24415:10;24404:22;;;24400:27;24390:38;24387:60;24916:5;24913:1;24909:13;24987:1;24972:343;24997:2;24994:1;24991:9;24972:343;;;25120:2;25108:15;;;25057:20;25155:12;;;25169:1;25151:20;25192:42;;;;25260:1;25255:42;;;;25144:153;;25192:42;22279:1;22272:12;;;22312:2;22305:13;;;22357:2;22344:16;;25201:31;;25192:42;;25255;22279:1;22272:12;;;22312:2;22305:13;;;22357:2;22344:16;;25264:31;;25144:153;-1:-1:-1;;25015:1:128;25008:9;24972:343;;;-1:-1:-1;;25414:4:128;25407:18;-1:-1:-1;;;;23801:1654:128:o;20834:586::-;21156:20;;;21180:7;21156:32;21149:3;:40;;;21262:14;;21317:17;;21311:24;;;21303:72;;;;;;;4209:2:286;21303:72:128;;;4191:21:286;4248:2;4228:18;;;4221:30;4287:34;4267:18;;;4260:62;4358:5;4338:18;;;4331:33;4381:19;;21303:72:128;4007:399:286;21303:72:128;21389:14;20834:586;;;:::o;-1:-1:-1:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;:::o;:::-;;;;;;;;;;;;;;;;;;;;;;;;:::o;467:347:286:-;518:8;528:6;582:3;575:4;567:6;563:17;559:27;549:55;;600:1;597;590:12;549:55;-1:-1:-1;623:20:286;;666:18;655:30;;652:50;;;698:1;695;688:12;652:50;735:4;727:6;723:17;711:29;;787:3;780:4;771:6;763;759:19;755:30;752:39;749:59;;;804:1;801;794:12;749:59;467:347;;;;;:::o;819:717::-;909:6;917;925;933;986:2;974:9;965:7;961:23;957:32;954:52;;;1002:1;999;992:12;954:52;1042:9;1029:23;1071:18;1112:2;1104:6;1101:14;1098:34;;;1128:1;1125;1118:12;1098:34;1167:58;1217:7;1208:6;1197:9;1193:22;1167:58;:::i;:::-;1244:8;;-1:-1:-1;1141:84:286;-1:-1:-1;1332:2:286;1317:18;;1304:32;;-1:-1:-1;1348:16:286;;;1345:36;;;1377:1;1374;1367:12;1345:36;;1416:60;1468:7;1457:8;1446:9;1442:24;1416:60;:::i;:::-;819:717;;;;-1:-1:-1;1495:8:286;-1:-1:-1;;;;819:717:286:o;1723:184::-;1775:77;1772:1;1765:88;1872:4;1869:1;1862:15;1896:4;1893:1;1886:15;3568:245;3647:6;3655;3708:2;3696:9;3687:7;3683:23;3679:32;3676:52;;;3724:1;3721;3714:12;3676:52;-1:-1:-1;;3747:16:286;;3803:2;3788:18;;;3782:25;3747:16;;3782:25;;-1:-1:-1;3568:245:286:o;3818:184::-;3870:77;3867:1;3860:88;3967:4;3964:1;3957:15;3991:4;3988:1;3981:15" +var MIPSDeployedSourceMap = "1131:40054:138:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1710:45;;1745:10;1710:45;;;;;188:10:311;176:23;;;158:42;;146:2;131:18;1710:45:138;;;;;;;;2448:99;;;412:42:311;2534:6:138;400:55:311;382:74;;370:2;355:18;2448:99:138;211:251:311;26025:6379:138;;;;;;:::i;:::-;;:::i;:::-;;;1755:25:311;;;1743:2;1728:18;26025:6379:138;1609:177:311;26025:6379:138;26128:7;26171:18;;:::i;:::-;26318:4;26311:5;26308:15;26298:134;;26412:1;26409;26402:12;26298:134;26468:4;26462:11;26475:10;26459:27;26449:136;;26565:1;26562;26555:12;26449:136;26634:3;26615:17;26612:26;26602:151;;26733:1;26730;26723:12;26602:151;26798:3;26783:13;26780:22;26770:146;;26896:1;26893;26886:12;26770:146;27176:24;;27521:4;27222:20;27579:2;27280:21;;27176:24;27338:18;27222:20;27280:21;;;27176:24;27153:21;27149:52;;;27338:18;27222:20;;;27280:21;;;27176:24;27149:52;;27222:20;;27280:21;;;27176:24;27149:52;;27338:18;27222:20;27280:21;;;27176:24;27149:52;;27338:18;27222:20;27280:21;;;27176:24;27149:52;;27338:18;27222:20;27280:21;;;27176:24;27149:52;;;27338:18;27222:20;27280:21;;;27176:24;27153:21;27149:52;;;27338:18;27222:20;27280:21;;;27176:24;27149:52;;27338:18;27222:20;27280:21;;;27176:24;27149:52;;27338:18;27222:20;28197:10;27338:18;28187:21;;;27280;;;;28295:1;28280:77;28305:2;28302:1;28299:9;28280:77;;;27176:24;;27153:21;27149:52;27222:20;;28353:1;27280:21;;;;27164:2;27338:18;;;;28323:1;28316:9;28280:77;;;28284:14;;;28435:5;:12;;;28431:71;;;28474:13;:11;:13::i;:::-;28467:20;;;;;28431:71;28516:10;;;:15;;28530:1;28516:15;;;;;28601:8;;;;-1:-1:-1;;28593:20:138;;-1:-1:-1;28593:7:138;:20::i;:::-;28579:34;-1:-1:-1;28643:10:138;28651:2;28643:10;;;;28720:1;28710:11;;;:26;;;28725:6;:11;;28735:1;28725:11;28710:26;28706:310;;;28866:13;28935:1;28913:4;28920:10;28913:17;28912:24;;;;28883:5;:12;;;28898:10;28883:25;28882:54;28866:70;;28961:40;28972:6;:11;;28982:1;28972:11;:20;;28990:2;28972:20;;;28986:1;28972:20;28961:40;;28994:6;28961:10;:40::i;:::-;28954:47;;;;;;;;28706:310;29265:15;;;;29060:9;;;;29197:4;29191:2;29183:10;;;29182:19;;;29265:15;29290:2;29282:10;;;29281:19;29265:36;;;;;;;:::i;:::-;;;;;;-1:-1:-1;29330:5:138;29354:11;;;;;:29;;;29369:6;:14;;29379:4;29369:14;29354:29;29350:832;;;29446:5;:15;;;29462:5;29446:22;;;;;;;;;:::i;:::-;;;;;;-1:-1:-1;;29509:4:138;29503:2;29495:10;;;29494:19;29350:832;;;29547:4;29538:6;:13;;;29534:648;;;29668:6;:13;;29678:3;29668:13;:30;;;;29685:6;:13;;29695:3;29685:13;29668:30;:47;;;;29702:6;:13;;29712:3;29702:13;29668:47;29664:253;;;29778:4;29785:6;29778:13;29773:18;;29534:648;;29664:253;29877:21;29880:4;29887:6;29880:13;29895:2;29877;:21::i;:::-;29872:26;;29534:648;;;29951:4;29941:6;:14;;;;:32;;;;29959:6;:14;;29969:4;29959:14;29941:32;:50;;;;29977:6;:14;;29987:4;29977:14;29941:50;29937:245;;;30061:5;:15;;;30077:5;30061:22;;;;;;;;;:::i;:::-;;;;;30056:27;;30162:5;30154:13;;29937:245;30211:1;30201:6;:11;;;;:25;;;;;30225:1;30216:6;:10;;;30201:25;30200:42;;;;30231:6;:11;;30241:1;30231:11;30200:42;30196:125;;;30269:37;30282:6;30290:4;30296:5;30303:2;30269:12;:37::i;:::-;30262:44;;;;;;;;;;;30196:125;30354:13;30335:16;30506:4;30496:14;;;;30492:446;;30575:21;30578:4;30585:6;30578:13;30593:2;30575;:21::i;:::-;30569:27;;;;30633:10;30628:15;;30667:16;30628:15;30681:1;30667:7;:16::i;:::-;30661:22;;30715:4;30705:6;:14;;;;:32;;;;;30723:6;:14;;30733:4;30723:14;;30705:32;30701:223;;;30802:4;30790:16;;30904:1;30896:9;;30701:223;30512:426;30492:446;30971:10;30984:26;30992:4;30998:2;31002;31006:3;30984:7;:26::i;:::-;31013:10;30984:39;;;;-1:-1:-1;31109:4:138;31102:11;;;31141;;;:24;;;;;31164:1;31156:4;:9;;;;31141:24;:39;;;;;31176:4;31169;:11;;;31141:39;31137:860;;;31204:4;:9;;31212:1;31204:9;:22;;;;31217:4;:9;;31225:1;31217:9;31204:22;31200:144;;;31288:37;31299:4;:9;;31307:1;31299:9;:21;;31315:5;31299:21;;;31311:1;31299:21;31322:2;31288:10;:37::i;:::-;31281:44;;;;;;;;;;;;;;;31200:144;31366:4;:11;;31374:3;31366:11;31362:121;;31436:28;31445:5;31452:2;31456:7;;;;31436:8;:28::i;31362:121::-;31504:4;:11;;31512:3;31504:11;31500:121;;31574:28;31583:5;31590:2;31594:7;;;;;31574:8;:28::i;31500:121::-;31691:4;:11;;31699:3;31691:11;31687:93;;31733:28;31747:13;31733;:28::i;31687:93::-;31883:4;31875;:12;;;;:27;;;;;31898:4;31891;:11;;;31875:27;31871:112;;;31933:31;31944:4;31950:2;31954;31958:5;31933:10;:31::i;31871:112::-;32057:6;:14;;32067:4;32057:14;:28;;;;-1:-1:-1;32075:10:138;;;;;32057:28;32053:93;;;32130:1;32105:5;:15;;;32121:5;32105:22;;;;;;;;;:::i;:::-;:26;;;;:22;;;;;;:26;32053:93;32192:9;:26;;32205:13;32192:26;32188:92;;32238:27;32247:9;32258:1;32261:3;32238:8;:27::i;:::-;32361:26;32370:5;32377:3;32382:4;32361:8;:26::i;:::-;32354:33;;;;;;;;;;;;;26025:6379;;;;;;;;:::o;3087:2334::-;3634:4;3628:11;;3550:4;3353:31;3342:43;;3413:13;3353:31;3752:2;3452:13;;3342:43;3359:24;3353:31;3452:13;;;3342:43;;;;3359:24;3353:31;3452:13;;;3342:43;3359:24;3353:31;3452:13;;;3342:43;3359:24;3353:31;3452:13;;;3342:43;3359:24;3353:31;3452:13;;;3342:43;3359:24;3353:31;3452:13;;;3342:43;3413:13;4180:11;3359:24;3353:31;3452:13;;;3342:43;3413:13;4275:11;3359:24;3353:31;3452:13;;;3342:43;3359:24;3353:31;3452:13;;;3342:43;3128:12;;4415:13;;3628:11;;3452:13;;;;4180:11;3128:12;4495:84;4520:2;4517:1;4514:9;4495:84;;;3369:13;3359:24;;3353:31;3342:43;;3373:2;3413:13;;;;4575:1;3452:13;;;;4538:1;4531:9;4495:84;;;4499:14;4642:1;4638:2;4631:13;4737:5;4733:2;4729:14;4722:5;4717:27;4811:1;4797:15;;4832:6;4856:1;4851:273;;;;5191:1;5181:11;;4825:369;;4851:273;4883:8;4941:22;;;;5020:1;5015:22;;;;5107:1;5097:11;;4876:234;;4941:22;4960:1;4950:11;;4941:22;;5015;5034:1;5024:11;;4876:234;;4825:369;-1:-1:-1;;;5317:14:138;;;5300:32;;5360:19;5356:30;5392:3;5388:16;;;;5353:52;;3087:2334;-1:-1:-1;3087:2334:138:o;21746:1831::-;21819:11;21930:14;21947:24;21959:11;21947;:24::i;:::-;21930:41;;22079:1;22072:5;22068:13;22065:33;;;22094:1;22091;22084:12;22065:33;22227:2;22215:15;;;22168:20;22657:5;22654:1;22650:13;22692:4;22728:1;22713:343;22738:2;22735:1;22732:9;22713:343;;;22861:2;22849:15;;;22798:20;22896:12;;;22910:1;22892:20;22933:42;;;;23001:1;22996:42;;;;22885:153;;22933:42;22391:1;22384:12;;;22424:2;22417:13;;;22469:2;22456:16;;22942:31;;22933:42;;22996;22391:1;22384:12;;;22424:2;22417:13;;;22469:2;22456:16;;23005:31;;22885:153;-1:-1:-1;;22756:1:138;22749:9;22713:343;;;22717:14;23166:4;23160:11;23145:26;;23252:7;23246:4;23243:17;23233:124;;23294:10;23291:1;23284:21;23336:2;23333:1;23326:13;23233:124;-1:-1:-1;;23484:2:138;23473:14;;;;23461:10;23457:31;23454:1;23450:39;23518:16;;;;23536:10;23514:33;;21746:1831;-1:-1:-1;;;21746:1831:138:o;18856:823::-;18925:12;19012:18;;:::i;:::-;19080:4;19071:13;;19132:5;:8;;;19143:1;19132:12;19116:28;;:5;:12;;;:28;;;19112:95;;19164:28;;;;;2182:2:311;19164:28:138;;;2164:21:311;2221:2;2201:18;;;2194:30;2260:20;2240:18;;;2233:48;2298:18;;19164:28:138;;;;;;;;19112:95;19296:8;;;;;19329:12;;;;;19318:23;;;;;;;19355:20;;;;;19296:8;19487:13;;;19483:90;;19548:6;19557:1;19548:10;19520:5;:15;;;19536:8;19520:25;;;;;;;;;:::i;:::-;:38;;;;:25;;;;;;:38;19483:90;19649:13;:11;:13::i;2645:339::-;2706:11;2770:18;;;;2779:8;;;;2770:18;;;;;;2769:25;;;;;2786:1;2833:2;:9;;;2827:16;;;;;2826:22;;2825:32;;;;;;;2887:9;;2886:15;2769:25;2944:21;;2964:1;2944:21;;;2955:6;2944:21;2929:11;;;;;:37;;-1:-1:-1;;;2645:339:138;;;;:::o;13732:2026::-;13829:12;13915:18;;:::i;:::-;13983:4;13974:13;;14015:17;14075:5;:8;;;14086:1;14075:12;14059:28;;:5;:12;;;:28;;;14055:97;;14107:30;;;;;2529:2:311;14107:30:138;;;2511:21:311;2568:2;2548:18;;;2541:30;2607:22;2587:18;;;2580:50;2647:18;;14107:30:138;2327:344:311;14055:97:138;14222:7;:12;;14233:1;14222:12;:28;;;;14238:7;:12;;14249:1;14238:12;14222:28;14218:947;;;14270:9;14282:5;:15;;;14298:6;14282:23;;;;;;;;;:::i;:::-;;;;;14270:35;;14346:2;14339:9;;:3;:9;;;:25;;;;;14352:7;:12;;14363:1;14352:12;14339:25;14338:58;;;;14377:2;14370:9;;:3;:9;;;;:25;;;;;14383:7;:12;;14394:1;14383:12;14370:25;14323:73;;14252:159;14218:947;;;14508:7;:12;;14519:1;14508:12;14504:661;;14569:1;14561:3;14555:15;;;;14540:30;;14504:661;;;14673:7;:12;;14684:1;14673:12;14669:496;;14733:1;14726:3;14720:14;;;14705:29;;14669:496;;;14854:7;:12;;14865:1;14854:12;14850:315;;14942:4;14936:2;14927:11;;;14926:20;14912:10;14969:8;;;14965:84;;15029:1;15022:3;15016:14;;;15001:29;;14965:84;15070:3;:8;;15077:1;15070:8;15066:85;;15131:1;15123:3;15117:15;;;;15102:30;;15066:85;14868:297;14850:315;15241:8;;;;;15319:12;;;;15308:23;;;;;15475:178;;;;15566:1;15540:22;15543:5;15551:6;15543:14;15559:2;15540;:22::i;:::-;:27;;;;;;;15526:42;;15535:1;15526:42;15511:57;:12;;;:57;15475:178;;;15622:12;;;;;15637:1;15622:16;15607:31;;;;15475:178;15728:13;:11;:13::i;:::-;15721:20;13732:2026;-1:-1:-1;;;;;;;;13732:2026:138:o;32450:8733::-;32537:10;32599;32607:2;32599:10;;;;32638:11;;;:44;;;32664:1;32654:6;:11;;;;:27;;;;;32678:3;32669:6;:12;;;32654:27;32634:8490;;;32723:4;32716:11;;32847:6;32907:3;32902:25;;;;32982:3;32977:25;;;;33056:3;33051:25;;;;33131:3;33126:25;;;;33205:3;33200:25;;;;33278:3;33273:25;;;;33352:3;33347:25;;;;32840:532;;32902:25;32921:4;32913:12;;32902:25;;32977;32996:4;32988:12;;32977:25;;33051;33070:4;33062:12;;33051:25;;33126;33145:4;33137:12;;33126:25;;33200;33219:4;33211:12;;33200:25;;33273;33292:4;33284:12;;33273:25;;33347;33366:4;33358:12;;32840:532;;33435:4;:12;;33443:4;33435:12;33431:4023;;-1:-1:-1;;;33486:9:138;33478:26;;33499:4;33494:1;33486:9;;;33485:18;33478:26;33471:33;;33431:4023;33572:4;:12;;33580:4;33572:12;33568:3886;;-1:-1:-1;;;33623:9:138;33615:26;;33636:4;33631:1;33623:9;;;33622:18;33615:26;33608:33;;33568:3886;33709:4;:12;;33717:4;33709:12;33705:3749;;33774:4;33769:1;33761:9;;;33760:18;33807:27;33761:9;33810:11;;;;33823:2;:10;;;33807:2;:27::i;:::-;33800:34;;;;;;;33705:3749;33903:4;:12;;33911:4;33903:12;33899:3555;;-1:-1:-1;;;33946:17:138;;;33958:4;33953:9;;33946:17;33939:24;;33899:3555;34032:4;:11;;34040:3;34032:11;34028:3426;;-1:-1:-1;;;34074:17:138;;;34086:4;34081:9;;34074:17;34067:24;;34028:3426;34160:4;:12;;34168:4;34160:12;34156:3298;;34203:21;34212:2;34206:8;;:2;:8;;;;34221:2;34216;:7;34203:2;:21::i;:::-;34196:28;;;;;;34156:3298;34473:4;:12;;34481:4;34473:12;34469:2985;;34516:2;34509:9;;;;;;34469:2985;34587:4;:12;;34595:4;34587:12;34583:2871;;34630:2;34623:9;;;;;;34583:2871;34701:4;:12;;34709:4;34701:12;34697:2757;;34744:2;34737:9;;;;;;34697:2757;34815:4;:12;;34823:4;34815:12;34811:2643;;34858:2;34851:9;;;;;;34811:2643;34932:4;:12;;34940:4;34932:12;34928:2526;;34975:2;34968:9;;;;;;34928:2526;35092:4;:12;;35100:4;35092:12;35088:2366;;35135:2;35128:9;;;;;;35088:2366;35206:4;:12;;35214:4;35206:12;35202:2252;;35249:2;35242:9;;;;;;35202:2252;35320:4;:12;;35328:4;35320:12;35316:2138;;35363:2;35356:9;;;;;;35316:2138;35434:4;:12;;35442:4;35434:12;35430:2024;;35477:2;35470:9;;;;;;35430:2024;35548:4;:12;;35556:4;35548:12;35544:1910;;35591:2;35584:9;;;;;;35544:1910;35662:4;:12;;35670:4;35662:12;35658:1796;;35705:2;35698:9;;;;;;35658:1796;35777:4;:12;;35785:4;35777:12;35773:1681;;35820:2;35813:9;;;;;;35773:1681;35890:4;:12;;35898:4;35890:12;35886:1568;;35933:2;35926:9;;;;;;35886:1568;36004:4;:12;;36012:4;36004:12;36000:1454;;36047:2;36040:9;;;;;;36000:1454;36196:4;:12;;36204:4;36196:12;36192:1262;;-1:-1:-1;;;36240:7:138;;;36232:16;;36192:1262;36317:4;:12;;36325:4;36317:12;36313:1141;;-1:-1:-1;;;36361:7:138;;;36353:16;;36313:1141;36437:4;:12;;36445:4;36437:12;36433:1021;;-1:-1:-1;;;36481:7:138;;;36473:16;;36433:1021;36558:4;:12;;36566:4;36558:12;36554:900;;-1:-1:-1;;;36602:7:138;;;36594:16;;36554:900;36678:4;:12;;36686:4;36678:12;36674:780;;-1:-1:-1;;;36722:7:138;;;36714:16;;36674:780;36797:4;:12;;36805:4;36797:12;36793:661;;-1:-1:-1;;;36841:7:138;;;36833:16;;36793:661;36917:4;:12;;36925:4;36917:12;36913:541;;-1:-1:-1;;;36961:7:138;;;36953:16;;36913:541;37037:4;:12;;37045:4;37037:12;37033:421;;-1:-1:-1;;;37082:7:138;;;37080:10;37073:17;;37033:421;37159:4;:12;;37167:4;37159:12;37155:299;;37220:2;37202:21;;37208:2;37202:21;;;:29;;37230:1;37202:29;;;37226:1;37202:29;37195:36;;;;;;;;37155:299;37301:4;:12;;37309:4;37301:12;37297:157;;37349:2;37344:7;;:2;:7;;;:15;;37358:1;37344:15;;37297:157;37406:29;;;;;2878:2:311;37406:29:138;;;2860:21:311;2917:2;2897:18;;;2890:30;2956:21;2936:18;;;2929:49;2995:18;;37406:29:138;2676:343:311;37297:157:138;32684:4784;32634:8490;;;37524:6;:14;;37534:4;37524:14;37520:3590;;37583:4;37576:11;;37658:3;37650:11;;;37646:549;;-1:-1:-1;;;37703:21:138;;;37689:36;;37646:549;37810:4;:12;;37818:4;37810:12;:28;;;;37826:4;:12;;37834:4;37826:12;37810:28;37806:389;;;37870:4;:12;;37878:4;37870:12;37866:83;;37919:3;;;37866:83;37974:8;38012:127;38024:10;38019:15;;:20;38012:127;;38104:8;38071:3;38104:8;;;;;38071:3;38012:127;;;38171:1;-1:-1:-1;38164:8:138;;-1:-1:-1;;38164:8:138;37520:3590;38262:6;:14;;38272:4;38262:14;38258:2852;;-1:-1:-1;;38307:8:138;38313:2;38307:8;;;;38300:15;;38258:2852;38382:6;:14;;38392:4;38382:14;38378:2732;;38427:42;38445:2;38450:1;38445:6;38455:1;38444:12;38439:2;:17;38431:26;;:3;:26;;;;38461:4;38430:35;38467:1;38427:2;:42::i;:::-;38420:49;;;;;38378:2732;38536:6;:14;;38546:4;38536:14;38532:2578;;38581:45;38599:2;38604:1;38599:6;38609:1;38598:12;38593:2;:17;38585:26;;:3;:26;;;;38615:6;38584:37;38623:2;38581;:45::i;38532:2578::-;38694:6;:14;;38704:4;38694:14;38690:2420;;-1:-1:-1;;38745:21:138;38764:1;38759;38754:6;;38753:12;38745:21;;38802:36;;;38873:5;38868:10;;38745:21;;;;;38867:18;38860:25;;38690:2420;38952:6;:14;;38962:4;38952:14;38948:2162;;38997:3;38990:10;;;;;38948:2162;39068:6;:14;;39078:4;39068:14;39064:2046;;39128:2;39133:1;39128:6;39138:1;39127:12;39122:2;:17;39114:26;;:3;:26;;;;39144:4;39113:35;39106:42;;;;;39064:2046;39217:6;:14;;39227:4;39217:14;39213:1897;;39277:2;39282:1;39277:6;39287:1;39276:12;39271:2;:17;39263:26;;:3;:26;;;;39293:6;39262:37;39255:44;;;;;39213:1897;39368:6;:14;;39378:4;39368:14;39364:1746;;-1:-1:-1;;39419:26:138;39443:1;39438;39433:6;;39432:12;39427:2;:17;39419:26;;39481:41;;;39557:5;39552:10;;39419:26;;;;;39551:18;39544:25;;39364:1746;39637:6;:14;;39647:4;39637:14;39633:1477;;-1:-1:-1;;39694:4:138;39688:34;39720:1;39715;39710:6;;39709:12;39704:2;:17;39688:34;;39778:27;;;39758:48;;;39836:10;;39689:9;;;39688:34;;39835:18;39828:25;;39633:1477;39921:6;:14;;39931:4;39921:14;39917:1193;;-1:-1:-1;;39978:6:138;39972:36;40006:1;40001;39996:6;;39995:12;39990:2;:17;39972:36;;40064:29;;;40044:50;;;40124:10;;39973:11;;;39972:36;;40123:18;40116:25;;39917:1193;40210:6;:14;;40220:4;40210:14;40206:904;;-1:-1:-1;;40261:20:138;40279:1;40274;40269:6;;40268:12;40261:20;;40317:36;;;40389:5;40383:11;;40261:20;;;;;40382:19;40375:26;;40206:904;40469:6;:14;;40479:4;40469:14;40465:645;;40514:2;40507:9;;;;;40465:645;40585:6;:14;;40595:4;40585:14;40581:529;;-1:-1:-1;;40636:25:138;40659:1;40654;40649:6;;40648:12;40643:2;:17;40636:25;;40697:41;;;40774:5;40768:11;;40636:25;;;;;40767:19;40760:26;;40581:529;40853:6;:14;;40863:4;40853:14;40849:261;;40898:3;40891:10;;;;;40849:261;40968:6;:14;;40978:4;40968:14;40964:146;;41013:2;41006:9;;;32450:8733;;;;;;;:::o;19960:782::-;20046:12;20133:18;;:::i;:::-;-1:-1:-1;20201:4:138;20308:2;20296:14;;;;20288:41;;;;;;;3226:2:311;20288:41:138;;;3208:21:311;3265:2;3245:18;;;3238:30;3304:16;3284:18;;;3277:44;3338:18;;20288:41:138;3024:338:311;20288:41:138;20425:14;;;;;;;:30;;;20443:12;20425:30;20421:102;;;20504:4;20475:5;:15;;;20491:9;20475:26;;;;;;;;;:::i;:::-;:33;;;;:26;;;;;;:33;20421:102;20578:12;;;;;20567:23;;;;:8;;;:23;20634:1;20619:16;;;20604:31;;;20712:13;:11;:13::i;5582:7764::-;5646:12;5732:18;;:::i;:::-;-1:-1:-1;5910:15:138;;:18;;;;5800:4;6070:18;;;;6114;;;;6158;;;;;5800:4;;5890:17;;;;6070:18;6114;6248;;;6262:4;6248:18;6244:6792;;6298:2;6327:4;6322:9;;:14;6318:144;;6438:4;6433:9;;6425:4;:18;6419:24;6318:144;6483:2;:7;;6489:1;6483:7;6479:161;;6519:10;;;;;6551:16;;;;;;;;6519:10;-1:-1:-1;6479:161:138;;;6619:2;6614:7;;6479:161;6268:386;6244:6792;;;6756:10;:18;;6770:4;6756:18;6752:6284;;1745:10;6794:14;;6752:6284;;;6892:10;:18;;6906:4;6892:18;6888:6148;;6935:1;6930:6;;6888:6148;;;7060:10;:18;;7074:4;7060:18;7056:5980;;7113:4;7098:12;;;:19;7135:26;;;:14;;;:26;7186:13;:11;:13::i;:::-;7179:20;5582:7764;-1:-1:-1;;;;;;;;;5582:7764:138:o;7056:5980::-;7325:10;:18;;7339:4;7325:18;7321:5715;;7476:14;;;7472:2723;7321:5715;7472:2723;7646:22;;;;;7642:2553;;7771:10;7784:27;7792:2;7797:10;7792:15;7809:1;7784:7;:27::i;:::-;7895:17;;;;7771:40;;-1:-1:-1;7895:17:138;7873:19;8045:14;8064:1;8039:26;8035:146;;1676:4:139;1670:11;;1533:21;1787:15;;;1828:8;1822:4;1815:22;1850:27;;;1996:4;1983:18;;2098:17;;2003:19;1979:44;2025:11;1976:61;8093:65:138;;8035:146;8267:20;;;;;8234:54;;;;;;;;3540:25:311;;;8234:54:138;3601:23:311;;;3581:18;;;3574:51;8203:11:138;;;;8234:19;:6;:19;;;;3513:18:311;;8234:54:138;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;8202:86;;;;8515:1;8511:2;8507:10;8612:9;8609:1;8605:17;8694:6;8687:5;8684:17;8681:40;;;8714:5;8704:15;;8681:40;;8797:6;8793:2;8790:14;8787:34;;;8817:2;8807:12;;8787:34;8923:3;8918:1;8910:6;8906:14;8901:3;8897:24;8893:34;8886:41;;9023:3;9019:1;9007:9;8998:6;8995:1;8991:14;8987:30;8983:38;8979:48;8972:55;;9178:1;9174;9170;9158:9;9155:1;9151:17;9147:25;9143:33;9139:41;9305:1;9301;9297;9288:6;9276:9;9273:1;9269:17;9265:30;9261:38;9257:46;9253:54;9235:72;;9436:10;9432:15;9426:4;9422:26;9414:34;;9552:3;9544:4;9540:9;9535:3;9531:19;9528:28;9521:35;;;;9698:33;9707:2;9712:10;9707:15;9724:1;9727:3;9698:8;:33::i;:::-;9753:20;;;:38;;;;;;;;;-1:-1:-1;7642:2553:138;;-1:-1:-1;;;7642:2553:138;;9910:18;;;;;9906:289;;10080:2;10075:7;;7321:5715;;9906:289;10134:10;10129:15;;2053:3;10166:10;;9906:289;7321:5715;;;10324:10;:18;;10338:4;10324:18;10320:2716;;10478:15;;;1824:1;10478:15;;:34;;-1:-1:-1;10497:15:138;;;1859:1;10497:15;10478:34;:57;;;-1:-1:-1;10516:19:138;;;1936:1;10516:19;10478:57;10474:1593;;;10564:2;10559:7;;10320:2716;;10474:1593;10690:23;;;;;10686:1381;;10737:10;10750:27;10758:2;10763:10;10758:15;10775:1;10750:7;:27::i;:::-;10853:17;;;;10737:40;;-1:-1:-1;11096:1:138;11088:10;;11190:1;11186:17;11265:13;;;11262:32;;;11287:5;11281:11;;11262:32;11573:14;;;11379:1;11569:22;;;11565:32;;;;11462:26;11486:1;11371:10;;;11466:18;;;11462:26;11561:43;11367:20;;11669:12;11797:17;;;:23;11865:1;11842:20;;;:24;11375:2;-1:-1:-1;11375:2:138;7321:5715;;10320:2716;12269:10;:18;;12283:4;12269:18;12265:771;;12379:2;:7;;12385:1;12379:7;12375:647;;12472:14;;;;;:40;;-1:-1:-1;12490:22:138;;;1978:1;12490:22;12472:40;:62;;;-1:-1:-1;12516:18:138;;;1897:1;12516:18;12472:62;12468:404;;;12567:1;12562:6;;12375:647;;12468:404;12613:15;;;1824:1;12613:15;;:34;;-1:-1:-1;12632:15:138;;;1859:1;12632:15;12613:34;:61;;;-1:-1:-1;12651:23:138;;;2021:1;12651:23;12613:61;:84;;;-1:-1:-1;12678:19:138;;;1936:1;12678:19;12613:84;12609:263;;;12730:1;12725:6;;7321:5715;;12375:647;12923:10;12918:15;;2087:4;12955:11;;12375:647;13111:15;;;;;:23;;;;:18;;;;:23;;;;13148:15;;:23;;;:18;;;;:23;-1:-1:-1;13237:12:138;;;;13226:23;;;:8;;;:23;13293:1;13278:16;13263:31;;;;;13316:13;:11;:13::i;16084:2480::-;16178:12;16264:18;;:::i;:::-;-1:-1:-1;16332:4:138;16364:10;16472:13;;;16481:4;16472:13;16468:1705;;-1:-1:-1;16511:8:138;;;;16468:1705;;;16630:5;:13;;16639:4;16630:13;16626:1547;;16663:14;;;:8;;;:14;16626:1547;;;16793:5;:13;;16802:4;16793:13;16789:1384;;-1:-1:-1;16832:8:138;;;;16789:1384;;;16951:5;:13;;16960:4;16951:13;16947:1226;;16984:14;;;:8;;;:14;16947:1226;;;17125:5;:13;;17134:4;17125:13;17121:1052;;17252:9;17198:17;17178;;;17198;;;;17178:37;17259:2;17252:9;;;;;17234:8;;;:28;17280:22;:8;;;:22;17121:1052;;;17439:5;:13;;17448:4;17439:13;17435:738;;17506:11;17492;;;17506;;;17492:25;17561:2;17554:9;;;;;17536:8;;;:28;17582:22;:8;;;:22;17435:738;;;17763:5;:13;;17772:4;17763:13;17759:414;;17833:3;17814:23;;17820:3;17814:23;;;;;;;:::i;:::-;;17796:42;;:8;;;:42;17874:23;;;;;;;;;;;;;:::i;:::-;;17856:42;;:8;;;:42;17759:414;;;18067:5;:13;;18076:4;18067:13;18063:110;;18117:3;18111:9;;:3;:9;;;;;;;:::i;:::-;;18100:20;;;;:8;;;:20;18149:9;;;;;;;;;;;:::i;:::-;;18138:20;;:8;;;:20;18063:110;18266:14;;;;18262:85;;18329:3;18300:5;:15;;;18316:9;18300:26;;;;;;;;;:::i;:::-;:32;;;;:26;;;;;;:32;18262:85;18401:12;;;;;18390:23;;;;:8;;;:23;18457:1;18442:16;;;18427:31;;;18534:13;:11;:13::i;:::-;18527:20;16084:2480;-1:-1:-1;;;;;;;16084:2480:138:o;23913:1654::-;24089:14;24106:24;24118:11;24106;:24::i;:::-;24089:41;;24238:1;24231:5;24227:13;24224:33;;;24253:1;24250;24243:12;24224:33;24392:2;24586:15;;;24411:2;24400:14;;24388:10;24384:31;24381:1;24377:39;24542:16;;;24327:20;;24527:10;24516:22;;;24512:27;24502:38;24499:60;25028:5;25025:1;25021:13;25099:1;25084:343;25109:2;25106:1;25103:9;25084:343;;;25232:2;25220:15;;;25169:20;25267:12;;;25281:1;25263:20;25304:42;;;;25372:1;25367:42;;;;25256:153;;25304:42;22391:1;22384:12;;;22424:2;22417:13;;;22469:2;22456:16;;25313:31;;25304:42;;25367;22391:1;22384:12;;;22424:2;22417:13;;;22469:2;22456:16;;25376:31;;25256:153;-1:-1:-1;;25127:1:138;25120:9;25084:343;;;-1:-1:-1;;25526:4:138;25519:18;-1:-1:-1;;;;23913:1654:138:o;20946:586::-;21268:20;;;21292:7;21268:32;21261:3;:40;;;21374:14;;21429:17;;21423:24;;;21415:72;;;;;;;4277:2:311;21415:72:138;;;4259:21:311;4316:2;4296:18;;;4289:30;4355:34;4335:18;;;4328:62;4426:5;4406:18;;;4399:33;4449:19;;21415:72:138;4075:399:311;21415:72:138;21501:14;20946:586;;;:::o;-1:-1:-1:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;:::o;:::-;;;;;;;;;;;;;;;;;;;;;;;;:::o;467:347:311:-;518:8;528:6;582:3;575:4;567:6;563:17;559:27;549:55;;600:1;597;590:12;549:55;-1:-1:-1;623:20:311;;666:18;655:30;;652:50;;;698:1;695;688:12;652:50;735:4;727:6;723:17;711:29;;787:3;780:4;771:6;763;759:19;755:30;752:39;749:59;;;804:1;801;794:12;749:59;467:347;;;;;:::o;819:785::-;918:6;926;934;942;950;1003:2;991:9;982:7;978:23;974:32;971:52;;;1019:1;1016;1009:12;971:52;1059:9;1046:23;1088:18;1129:2;1121:6;1118:14;1115:34;;;1145:1;1142;1135:12;1115:34;1184:58;1234:7;1225:6;1214:9;1210:22;1184:58;:::i;:::-;1261:8;;-1:-1:-1;1158:84:311;-1:-1:-1;1349:2:311;1334:18;;1321:32;;-1:-1:-1;1365:16:311;;;1362:36;;;1394:1;1391;1384:12;1362:36;;1433:60;1485:7;1474:8;1463:9;1459:24;1433:60;:::i;:::-;819:785;;;;-1:-1:-1;1512:8:311;1594:2;1579:18;1566:32;;819:785;-1:-1:-1;;;;819:785:311:o;1791:184::-;1843:77;1840:1;1833:88;1940:4;1937:1;1930:15;1964:4;1961:1;1954:15;3636:245;3715:6;3723;3776:2;3764:9;3755:7;3751:23;3747:32;3744:52;;;3792:1;3789;3782:12;3744:52;-1:-1:-1;;3815:16:311;;3871:2;3856:18;;;3850:25;3815:16;;3850:25;;-1:-1:-1;3636:245:311:o;3886:184::-;3938:77;3935:1;3928:88;4035:4;4032:1;4025:15;4059:4;4056:1;4049:15" func init() { if err := json.Unmarshal([]byte(MIPSStorageLayoutJSON), MIPSStorageLayout); err != nil { diff --git a/op-bindings/bindings/optimismmintableerc20.go b/op-bindings/bindings/optimismmintableerc20.go index 835592aacbbca..f9ac81a2a95ab 100644 --- a/op-bindings/bindings/optimismmintableerc20.go +++ b/op-bindings/bindings/optimismmintableerc20.go @@ -31,7 +31,7 @@ var ( // OptimismMintableERC20MetaData contains all meta data concerning the OptimismMintableERC20 contract. var OptimismMintableERC20MetaData = &bind.MetaData{ ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_bridge\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_remoteToken\",\"type\":\"address\"},{\"internalType\":\"string\",\"name\":\"_name\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"_symbol\",\"type\":\"string\"},{\"internalType\":\"uint8\",\"name\":\"_decimals\",\"type\":\"uint8\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Approval\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"Burn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"Mint\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Transfer\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"BRIDGE\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"REMOTE_TOKEN\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"}],\"name\":\"allowance\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"approve\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"bridge\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_from\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"burn\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"decimals\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"subtractedValue\",\"type\":\"uint256\"}],\"name\":\"decreaseAllowance\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"addedValue\",\"type\":\"uint256\"}],\"name\":\"increaseAllowance\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"l1Token\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"l2Bridge\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"mint\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"name\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"remoteToken\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes4\",\"name\":\"_interfaceId\",\"type\":\"bytes4\"}],\"name\":\"supportsInterface\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"symbol\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"totalSupply\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transfer\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transferFrom\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"version\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", - Bin: "0x6101406040523480156200001257600080fd5b5060405162001ad838038062001ad8833981016040819052620000359162000178565b600160026000858560036200004b8382620002b3565b5060046200005a8282620002b3565b50505060809290925260a05260c0526001600160a01b0393841660e0529390921661010052505060ff16610120526200037f565b80516001600160a01b0381168114620000a657600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b600082601f830112620000d357600080fd5b81516001600160401b0380821115620000f057620000f0620000ab565b604051601f8301601f19908116603f011681019082821181831017156200011b576200011b620000ab565b816040528381526020925086838588010111156200013857600080fd5b600091505b838210156200015c57858201830151818301840152908201906200013d565b838211156200016e5760008385830101525b9695505050505050565b600080600080600060a086880312156200019157600080fd5b6200019c866200008e565b9450620001ac602087016200008e565b60408701519094506001600160401b0380821115620001ca57600080fd5b620001d889838a01620000c1565b94506060880151915080821115620001ef57600080fd5b50620001fe88828901620000c1565b925050608086015160ff811681146200021657600080fd5b809150509295509295909350565b600181811c908216806200023957607f821691505b6020821081036200025a57634e487b7160e01b600052602260045260246000fd5b50919050565b601f821115620002ae57600081815260208120601f850160051c81016020861015620002895750805b601f850160051c820191505b81811015620002aa5782815560010162000295565b5050505b505050565b81516001600160401b03811115620002cf57620002cf620000ab565b620002e781620002e0845462000224565b8462000260565b602080601f8311600181146200031f5760008415620003065750858301515b600019600386901b1c1916600185901b178555620002aa565b600085815260208120601f198616915b8281101562000350578886015182559484019460019091019084016200032f565b50858210156200036f5787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b60805160a05160c05160e05161010051610120516116ed620003eb6000396000610244015260008181610317015281816103ac015281816105f101526107cb0152600081816101a9015261033d0152600061075a015260006107310152600061070801526116ed6000f3fe608060405234801561001057600080fd5b50600436106101775760003560e01c806370a08231116100d8578063ae1f6aaf1161008c578063dd62ed3e11610066578063dd62ed3e14610361578063e78cea9214610315578063ee9a31a2146103a757600080fd5b8063ae1f6aaf14610315578063c01e1bd61461033b578063d6c0b2c41461033b57600080fd5b80639dc29fac116100bd5780639dc29fac146102dc578063a457c2d7146102ef578063a9059cbb1461030257600080fd5b806370a082311461029e57806395d89b41146102d457600080fd5b806323b872dd1161012f5780633950935111610114578063395093511461026e57806340c10f191461028157806354fd4d501461029657600080fd5b806323b872dd1461022a578063313ce5671461023d57600080fd5b806306fdde031161016057806306fdde03146101f0578063095ea7b31461020557806318160ddd1461021857600080fd5b806301ffc9a71461017c578063033964be146101a4575b600080fd5b61018f61018a366004611329565b6103ce565b60405190151581526020015b60405180910390f35b6101cb7f000000000000000000000000000000000000000000000000000000000000000081565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161019b565b6101f86104bf565b60405161019b919061139e565b61018f610213366004611418565b610551565b6002545b60405190815260200161019b565b61018f610238366004611442565b610569565b60405160ff7f000000000000000000000000000000000000000000000000000000000000000016815260200161019b565b61018f61027c366004611418565b61058d565b61029461028f366004611418565b6105d9565b005b6101f8610701565b61021c6102ac36600461147e565b73ffffffffffffffffffffffffffffffffffffffff1660009081526020819052604090205490565b6101f86107a4565b6102946102ea366004611418565b6107b3565b61018f6102fd366004611418565b6108ca565b61018f610310366004611418565b61099b565b7f00000000000000000000000000000000000000000000000000000000000000006101cb565b7f00000000000000000000000000000000000000000000000000000000000000006101cb565b61021c61036f366004611499565b73ffffffffffffffffffffffffffffffffffffffff918216600090815260016020908152604080832093909416825291909152205490565b6101cb7f000000000000000000000000000000000000000000000000000000000000000081565b60007f01ffc9a7000000000000000000000000000000000000000000000000000000007f1d1d8b63000000000000000000000000000000000000000000000000000000007fec4fc8e3000000000000000000000000000000000000000000000000000000007fffffffff00000000000000000000000000000000000000000000000000000000851683148061048757507fffffffff00000000000000000000000000000000000000000000000000000000858116908316145b806104b657507fffffffff00000000000000000000000000000000000000000000000000000000858116908216145b95945050505050565b6060600380546104ce906114cc565b80601f01602080910402602001604051908101604052809291908181526020018280546104fa906114cc565b80156105475780601f1061051c57610100808354040283529160200191610547565b820191906000526020600020905b81548152906001019060200180831161052a57829003601f168201915b5050505050905090565b60003361055f8185856109a9565b5060019392505050565b600033610577858285610b5d565b610582858585610c34565b506001949350505050565b33600081815260016020908152604080832073ffffffffffffffffffffffffffffffffffffffff8716845290915281205490919061055f90829086906105d490879061154e565b6109a9565b3373ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016146106a3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603460248201527f4f7074696d69736d4d696e7461626c6545524332303a206f6e6c79206272696460448201527f67652063616e206d696e7420616e64206275726e00000000000000000000000060648201526084015b60405180910390fd5b6106ad8282610ee7565b8173ffffffffffffffffffffffffffffffffffffffff167f0f6798a560793a54c3bcfe86a93cde1e73087d944c0ea20544137d4121396885826040516106f591815260200190565b60405180910390a25050565b606061072c7f0000000000000000000000000000000000000000000000000000000000000000611007565b6107557f0000000000000000000000000000000000000000000000000000000000000000611007565b61077e7f0000000000000000000000000000000000000000000000000000000000000000611007565b60405160200161079093929190611566565b604051602081830303815290604052905090565b6060600480546104ce906114cc565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610878576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603460248201527f4f7074696d69736d4d696e7461626c6545524332303a206f6e6c79206272696460448201527f67652063616e206d696e7420616e64206275726e000000000000000000000000606482015260840161069a565b6108828282611144565b8173ffffffffffffffffffffffffffffffffffffffff167fcc16f5dbb4873280815c1ee09dbd06736cffcc184412cf7a71a0fdb75d397ca5826040516106f591815260200190565b33600081815260016020908152604080832073ffffffffffffffffffffffffffffffffffffffff871684529091528120549091908381101561098e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602560248201527f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f7760448201527f207a65726f000000000000000000000000000000000000000000000000000000606482015260840161069a565b61058282868684036109a9565b60003361055f818585610c34565b73ffffffffffffffffffffffffffffffffffffffff8316610a4b576040517f08c379a0000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f45524332303a20617070726f76652066726f6d20746865207a65726f2061646460448201527f7265737300000000000000000000000000000000000000000000000000000000606482015260840161069a565b73ffffffffffffffffffffffffffffffffffffffff8216610aee576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602260248201527f45524332303a20617070726f766520746f20746865207a65726f20616464726560448201527f7373000000000000000000000000000000000000000000000000000000000000606482015260840161069a565b73ffffffffffffffffffffffffffffffffffffffff83811660008181526001602090815260408083209487168084529482529182902085905590518481527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92591015b60405180910390a3505050565b73ffffffffffffffffffffffffffffffffffffffff8381166000908152600160209081526040808320938616835292905220547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8114610c2e5781811015610c21576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f45524332303a20696e73756666696369656e7420616c6c6f77616e6365000000604482015260640161069a565b610c2e84848484036109a9565b50505050565b73ffffffffffffffffffffffffffffffffffffffff8316610cd7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602560248201527f45524332303a207472616e736665722066726f6d20746865207a65726f20616460448201527f6472657373000000000000000000000000000000000000000000000000000000606482015260840161069a565b73ffffffffffffffffffffffffffffffffffffffff8216610d7a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260448201527f6573730000000000000000000000000000000000000000000000000000000000606482015260840161069a565b73ffffffffffffffffffffffffffffffffffffffff831660009081526020819052604090205481811015610e30576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f45524332303a207472616e7366657220616d6f756e742065786365656473206260448201527f616c616e63650000000000000000000000000000000000000000000000000000606482015260840161069a565b73ffffffffffffffffffffffffffffffffffffffff808516600090815260208190526040808220858503905591851681529081208054849290610e7490849061154e565b925050819055508273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef84604051610eda91815260200190565b60405180910390a3610c2e565b73ffffffffffffffffffffffffffffffffffffffff8216610f64576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f206164647265737300604482015260640161069a565b8060026000828254610f76919061154e565b909155505073ffffffffffffffffffffffffffffffffffffffff821660009081526020819052604081208054839290610fb090849061154e565b909155505060405181815273ffffffffffffffffffffffffffffffffffffffff8316906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9060200160405180910390a35050565b60608160000361104a57505060408051808201909152600181527f3000000000000000000000000000000000000000000000000000000000000000602082015290565b8160005b8115611074578061105e816115dc565b915061106d9050600a83611643565b915061104e565b60008167ffffffffffffffff81111561108f5761108f611657565b6040519080825280601f01601f1916602001820160405280156110b9576020820181803683370190505b5090505b841561113c576110ce600183611686565b91506110db600a8661169d565b6110e690603061154e565b60f81b8183815181106110fb576110fb6116b1565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350611135600a86611643565b94506110bd565b949350505050565b73ffffffffffffffffffffffffffffffffffffffff82166111e7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602160248201527f45524332303a206275726e2066726f6d20746865207a65726f2061646472657360448201527f7300000000000000000000000000000000000000000000000000000000000000606482015260840161069a565b73ffffffffffffffffffffffffffffffffffffffff82166000908152602081905260409020548181101561129d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602260248201527f45524332303a206275726e20616d6f756e7420657863656564732062616c616e60448201527f6365000000000000000000000000000000000000000000000000000000000000606482015260840161069a565b73ffffffffffffffffffffffffffffffffffffffff831660009081526020819052604081208383039055600280548492906112d9908490611686565b909155505060405182815260009073ffffffffffffffffffffffffffffffffffffffff8516907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef90602001610b50565b60006020828403121561133b57600080fd5b81357fffffffff000000000000000000000000000000000000000000000000000000008116811461136b57600080fd5b9392505050565b60005b8381101561138d578181015183820152602001611375565b83811115610c2e5750506000910152565b60208152600082518060208401526113bd816040850160208701611372565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169190910160400192915050565b803573ffffffffffffffffffffffffffffffffffffffff8116811461141357600080fd5b919050565b6000806040838503121561142b57600080fd5b611434836113ef565b946020939093013593505050565b60008060006060848603121561145757600080fd5b611460846113ef565b925061146e602085016113ef565b9150604084013590509250925092565b60006020828403121561149057600080fd5b61136b826113ef565b600080604083850312156114ac57600080fd5b6114b5836113ef565b91506114c3602084016113ef565b90509250929050565b600181811c908216806114e057607f821691505b602082108103611519577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600082198211156115615761156161151f565b500190565b60008451611578818460208901611372565b80830190507f2e0000000000000000000000000000000000000000000000000000000000000080825285516115b4816001850160208a01611372565b600192019182015283516115cf816002840160208801611372565b0160020195945050505050565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361160d5761160d61151f565b5060010190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b60008261165257611652611614565b500490565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6000828210156116985761169861151f565b500390565b6000826116ac576116ac611614565b500690565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fdfea164736f6c634300080f000a", + Bin: "0x60e06040523480156200001157600080fd5b506040516200178a3803806200178a833981016040819052620000349162000163565b828260036200004483826200029e565b5060046200005382826200029e565b5050506001600160a01b039384166080529390921660a052505060ff1660c0526200036a565b80516001600160a01b03811681146200009157600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b600082601f830112620000be57600080fd5b81516001600160401b0380821115620000db57620000db62000096565b604051601f8301601f19908116603f0116810190828211818310171562000106576200010662000096565b816040528381526020925086838588010111156200012357600080fd5b600091505b8382101562000147578582018301518183018401529082019062000128565b83821115620001595760008385830101525b9695505050505050565b600080600080600060a086880312156200017c57600080fd5b620001878662000079565b9450620001976020870162000079565b60408701519094506001600160401b0380821115620001b557600080fd5b620001c389838a01620000ac565b94506060880151915080821115620001da57600080fd5b50620001e988828901620000ac565b925050608086015160ff811681146200020157600080fd5b809150509295509295909350565b600181811c908216806200022457607f821691505b6020821081036200024557634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200029957600081815260208120601f850160051c81016020861015620002745750805b601f850160051c820191505b81811015620002955782815560010162000280565b5050505b505050565b81516001600160401b03811115620002ba57620002ba62000096565b620002d281620002cb84546200020f565b846200024b565b602080601f8311600181146200030a5760008415620002f15750858301515b600019600386901b1c1916600185901b17855562000295565b600085815260208120601f198616915b828110156200033b578886015182559484019460019091019084016200031a565b50858210156200035a5787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b60805160a05160c0516113d4620003b6600039600061024401526000818161034b015281816103e001528181610625015261075c0152600081816101a9015261037101526113d46000f3fe608060405234801561001057600080fd5b50600436106101775760003560e01c806370a08231116100d8578063ae1f6aaf1161008c578063dd62ed3e11610066578063dd62ed3e14610395578063e78cea9214610349578063ee9a31a2146103db57600080fd5b8063ae1f6aaf14610349578063c01e1bd61461036f578063d6c0b2c41461036f57600080fd5b80639dc29fac116100bd5780639dc29fac14610310578063a457c2d714610323578063a9059cbb1461033657600080fd5b806370a08231146102d257806395d89b411461030857600080fd5b806323b872dd1161012f5780633950935111610114578063395093511461026e57806340c10f191461028157806354fd4d501461029657600080fd5b806323b872dd1461022a578063313ce5671461023d57600080fd5b806306fdde031161016057806306fdde03146101f0578063095ea7b31461020557806318160ddd1461021857600080fd5b806301ffc9a71461017c578063033964be146101a4575b600080fd5b61018f61018a36600461117d565b610402565b60405190151581526020015b60405180910390f35b6101cb7f000000000000000000000000000000000000000000000000000000000000000081565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161019b565b6101f86104f3565b60405161019b91906111c6565b61018f610213366004611262565b610585565b6002545b60405190815260200161019b565b61018f61023836600461128c565b61059d565b60405160ff7f000000000000000000000000000000000000000000000000000000000000000016815260200161019b565b61018f61027c366004611262565b6105c1565b61029461028f366004611262565b61060d565b005b6101f86040518060400160405280600581526020017f312e332e3000000000000000000000000000000000000000000000000000000081525081565b61021c6102e03660046112c8565b73ffffffffffffffffffffffffffffffffffffffff1660009081526020819052604090205490565b6101f8610735565b61029461031e366004611262565b610744565b61018f610331366004611262565b61085b565b61018f610344366004611262565b61092c565b7f00000000000000000000000000000000000000000000000000000000000000006101cb565b7f00000000000000000000000000000000000000000000000000000000000000006101cb565b61021c6103a33660046112e3565b73ffffffffffffffffffffffffffffffffffffffff918216600090815260016020908152604080832093909416825291909152205490565b6101cb7f000000000000000000000000000000000000000000000000000000000000000081565b60007f01ffc9a7000000000000000000000000000000000000000000000000000000007f1d1d8b63000000000000000000000000000000000000000000000000000000007fec4fc8e3000000000000000000000000000000000000000000000000000000007fffffffff0000000000000000000000000000000000000000000000000000000085168314806104bb57507fffffffff00000000000000000000000000000000000000000000000000000000858116908316145b806104ea57507fffffffff00000000000000000000000000000000000000000000000000000000858116908216145b95945050505050565b60606003805461050290611316565b80601f016020809104026020016040519081016040528092919081815260200182805461052e90611316565b801561057b5780601f106105505761010080835404028352916020019161057b565b820191906000526020600020905b81548152906001019060200180831161055e57829003601f168201915b5050505050905090565b60003361059381858561093a565b5060019392505050565b6000336105ab858285610aee565b6105b6858585610bc5565b506001949350505050565b33600081815260016020908152604080832073ffffffffffffffffffffffffffffffffffffffff871684529091528120549091906105939082908690610608908790611398565b61093a565b3373ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016146106d7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603460248201527f4f7074696d69736d4d696e7461626c6545524332303a206f6e6c79206272696460448201527f67652063616e206d696e7420616e64206275726e00000000000000000000000060648201526084015b60405180910390fd5b6106e18282610e78565b8173ffffffffffffffffffffffffffffffffffffffff167f0f6798a560793a54c3bcfe86a93cde1e73087d944c0ea20544137d41213968858260405161072991815260200190565b60405180910390a25050565b60606004805461050290611316565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610809576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603460248201527f4f7074696d69736d4d696e7461626c6545524332303a206f6e6c79206272696460448201527f67652063616e206d696e7420616e64206275726e00000000000000000000000060648201526084016106ce565b6108138282610f98565b8173ffffffffffffffffffffffffffffffffffffffff167fcc16f5dbb4873280815c1ee09dbd06736cffcc184412cf7a71a0fdb75d397ca58260405161072991815260200190565b33600081815260016020908152604080832073ffffffffffffffffffffffffffffffffffffffff871684529091528120549091908381101561091f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602560248201527f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f7760448201527f207a65726f00000000000000000000000000000000000000000000000000000060648201526084016106ce565b6105b6828686840361093a565b600033610593818585610bc5565b73ffffffffffffffffffffffffffffffffffffffff83166109dc576040517f08c379a0000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f45524332303a20617070726f76652066726f6d20746865207a65726f2061646460448201527f726573730000000000000000000000000000000000000000000000000000000060648201526084016106ce565b73ffffffffffffffffffffffffffffffffffffffff8216610a7f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602260248201527f45524332303a20617070726f766520746f20746865207a65726f20616464726560448201527f737300000000000000000000000000000000000000000000000000000000000060648201526084016106ce565b73ffffffffffffffffffffffffffffffffffffffff83811660008181526001602090815260408083209487168084529482529182902085905590518481527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92591015b60405180910390a3505050565b73ffffffffffffffffffffffffffffffffffffffff8381166000908152600160209081526040808320938616835292905220547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8114610bbf5781811015610bb2576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f45524332303a20696e73756666696369656e7420616c6c6f77616e636500000060448201526064016106ce565b610bbf848484840361093a565b50505050565b73ffffffffffffffffffffffffffffffffffffffff8316610c68576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602560248201527f45524332303a207472616e736665722066726f6d20746865207a65726f20616460448201527f647265737300000000000000000000000000000000000000000000000000000060648201526084016106ce565b73ffffffffffffffffffffffffffffffffffffffff8216610d0b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260448201527f657373000000000000000000000000000000000000000000000000000000000060648201526084016106ce565b73ffffffffffffffffffffffffffffffffffffffff831660009081526020819052604090205481811015610dc1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f45524332303a207472616e7366657220616d6f756e742065786365656473206260448201527f616c616e6365000000000000000000000000000000000000000000000000000060648201526084016106ce565b73ffffffffffffffffffffffffffffffffffffffff808516600090815260208190526040808220858503905591851681529081208054849290610e05908490611398565b925050819055508273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef84604051610e6b91815260200190565b60405180910390a3610bbf565b73ffffffffffffffffffffffffffffffffffffffff8216610ef5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f20616464726573730060448201526064016106ce565b8060026000828254610f079190611398565b909155505073ffffffffffffffffffffffffffffffffffffffff821660009081526020819052604081208054839290610f41908490611398565b909155505060405181815273ffffffffffffffffffffffffffffffffffffffff8316906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9060200160405180910390a35050565b73ffffffffffffffffffffffffffffffffffffffff821661103b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602160248201527f45524332303a206275726e2066726f6d20746865207a65726f2061646472657360448201527f730000000000000000000000000000000000000000000000000000000000000060648201526084016106ce565b73ffffffffffffffffffffffffffffffffffffffff8216600090815260208190526040902054818110156110f1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602260248201527f45524332303a206275726e20616d6f756e7420657863656564732062616c616e60448201527f636500000000000000000000000000000000000000000000000000000000000060648201526084016106ce565b73ffffffffffffffffffffffffffffffffffffffff8316600090815260208190526040812083830390556002805484929061112d9084906113b0565b909155505060405182815260009073ffffffffffffffffffffffffffffffffffffffff8516907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef90602001610ae1565b60006020828403121561118f57600080fd5b81357fffffffff00000000000000000000000000000000000000000000000000000000811681146111bf57600080fd5b9392505050565b600060208083528351808285015260005b818110156111f3578581018301518582016040015282016111d7565b81811115611205576000604083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016929092016040019392505050565b803573ffffffffffffffffffffffffffffffffffffffff8116811461125d57600080fd5b919050565b6000806040838503121561127557600080fd5b61127e83611239565b946020939093013593505050565b6000806000606084860312156112a157600080fd5b6112aa84611239565b92506112b860208501611239565b9150604084013590509250925092565b6000602082840312156112da57600080fd5b6111bf82611239565b600080604083850312156112f657600080fd5b6112ff83611239565b915061130d60208401611239565b90509250929050565b600181811c9082168061132a57607f821691505b602082108103611363577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600082198211156113ab576113ab611369565b500190565b6000828210156113c2576113c2611369565b50039056fea164736f6c634300080f000a", } // OptimismMintableERC20ABI is the input ABI used to generate the binding from. diff --git a/op-bindings/bindings/optimismmintableerc20_more.go b/op-bindings/bindings/optimismmintableerc20_more.go index 9370be0182c4a..4a6e59f67e882 100644 --- a/op-bindings/bindings/optimismmintableerc20_more.go +++ b/op-bindings/bindings/optimismmintableerc20_more.go @@ -13,7 +13,7 @@ const OptimismMintableERC20StorageLayoutJSON = "{\"storage\":[{\"astId\":1000,\" var OptimismMintableERC20StorageLayout = new(solc.StorageLayout) -var OptimismMintableERC20DeployedBin = "0x608060405234801561001057600080fd5b50600436106101775760003560e01c806370a08231116100d8578063ae1f6aaf1161008c578063dd62ed3e11610066578063dd62ed3e14610361578063e78cea9214610315578063ee9a31a2146103a757600080fd5b8063ae1f6aaf14610315578063c01e1bd61461033b578063d6c0b2c41461033b57600080fd5b80639dc29fac116100bd5780639dc29fac146102dc578063a457c2d7146102ef578063a9059cbb1461030257600080fd5b806370a082311461029e57806395d89b41146102d457600080fd5b806323b872dd1161012f5780633950935111610114578063395093511461026e57806340c10f191461028157806354fd4d501461029657600080fd5b806323b872dd1461022a578063313ce5671461023d57600080fd5b806306fdde031161016057806306fdde03146101f0578063095ea7b31461020557806318160ddd1461021857600080fd5b806301ffc9a71461017c578063033964be146101a4575b600080fd5b61018f61018a366004611329565b6103ce565b60405190151581526020015b60405180910390f35b6101cb7f000000000000000000000000000000000000000000000000000000000000000081565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161019b565b6101f86104bf565b60405161019b919061139e565b61018f610213366004611418565b610551565b6002545b60405190815260200161019b565b61018f610238366004611442565b610569565b60405160ff7f000000000000000000000000000000000000000000000000000000000000000016815260200161019b565b61018f61027c366004611418565b61058d565b61029461028f366004611418565b6105d9565b005b6101f8610701565b61021c6102ac36600461147e565b73ffffffffffffffffffffffffffffffffffffffff1660009081526020819052604090205490565b6101f86107a4565b6102946102ea366004611418565b6107b3565b61018f6102fd366004611418565b6108ca565b61018f610310366004611418565b61099b565b7f00000000000000000000000000000000000000000000000000000000000000006101cb565b7f00000000000000000000000000000000000000000000000000000000000000006101cb565b61021c61036f366004611499565b73ffffffffffffffffffffffffffffffffffffffff918216600090815260016020908152604080832093909416825291909152205490565b6101cb7f000000000000000000000000000000000000000000000000000000000000000081565b60007f01ffc9a7000000000000000000000000000000000000000000000000000000007f1d1d8b63000000000000000000000000000000000000000000000000000000007fec4fc8e3000000000000000000000000000000000000000000000000000000007fffffffff00000000000000000000000000000000000000000000000000000000851683148061048757507fffffffff00000000000000000000000000000000000000000000000000000000858116908316145b806104b657507fffffffff00000000000000000000000000000000000000000000000000000000858116908216145b95945050505050565b6060600380546104ce906114cc565b80601f01602080910402602001604051908101604052809291908181526020018280546104fa906114cc565b80156105475780601f1061051c57610100808354040283529160200191610547565b820191906000526020600020905b81548152906001019060200180831161052a57829003601f168201915b5050505050905090565b60003361055f8185856109a9565b5060019392505050565b600033610577858285610b5d565b610582858585610c34565b506001949350505050565b33600081815260016020908152604080832073ffffffffffffffffffffffffffffffffffffffff8716845290915281205490919061055f90829086906105d490879061154e565b6109a9565b3373ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016146106a3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603460248201527f4f7074696d69736d4d696e7461626c6545524332303a206f6e6c79206272696460448201527f67652063616e206d696e7420616e64206275726e00000000000000000000000060648201526084015b60405180910390fd5b6106ad8282610ee7565b8173ffffffffffffffffffffffffffffffffffffffff167f0f6798a560793a54c3bcfe86a93cde1e73087d944c0ea20544137d4121396885826040516106f591815260200190565b60405180910390a25050565b606061072c7f0000000000000000000000000000000000000000000000000000000000000000611007565b6107557f0000000000000000000000000000000000000000000000000000000000000000611007565b61077e7f0000000000000000000000000000000000000000000000000000000000000000611007565b60405160200161079093929190611566565b604051602081830303815290604052905090565b6060600480546104ce906114cc565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610878576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603460248201527f4f7074696d69736d4d696e7461626c6545524332303a206f6e6c79206272696460448201527f67652063616e206d696e7420616e64206275726e000000000000000000000000606482015260840161069a565b6108828282611144565b8173ffffffffffffffffffffffffffffffffffffffff167fcc16f5dbb4873280815c1ee09dbd06736cffcc184412cf7a71a0fdb75d397ca5826040516106f591815260200190565b33600081815260016020908152604080832073ffffffffffffffffffffffffffffffffffffffff871684529091528120549091908381101561098e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602560248201527f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f7760448201527f207a65726f000000000000000000000000000000000000000000000000000000606482015260840161069a565b61058282868684036109a9565b60003361055f818585610c34565b73ffffffffffffffffffffffffffffffffffffffff8316610a4b576040517f08c379a0000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f45524332303a20617070726f76652066726f6d20746865207a65726f2061646460448201527f7265737300000000000000000000000000000000000000000000000000000000606482015260840161069a565b73ffffffffffffffffffffffffffffffffffffffff8216610aee576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602260248201527f45524332303a20617070726f766520746f20746865207a65726f20616464726560448201527f7373000000000000000000000000000000000000000000000000000000000000606482015260840161069a565b73ffffffffffffffffffffffffffffffffffffffff83811660008181526001602090815260408083209487168084529482529182902085905590518481527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92591015b60405180910390a3505050565b73ffffffffffffffffffffffffffffffffffffffff8381166000908152600160209081526040808320938616835292905220547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8114610c2e5781811015610c21576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f45524332303a20696e73756666696369656e7420616c6c6f77616e6365000000604482015260640161069a565b610c2e84848484036109a9565b50505050565b73ffffffffffffffffffffffffffffffffffffffff8316610cd7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602560248201527f45524332303a207472616e736665722066726f6d20746865207a65726f20616460448201527f6472657373000000000000000000000000000000000000000000000000000000606482015260840161069a565b73ffffffffffffffffffffffffffffffffffffffff8216610d7a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260448201527f6573730000000000000000000000000000000000000000000000000000000000606482015260840161069a565b73ffffffffffffffffffffffffffffffffffffffff831660009081526020819052604090205481811015610e30576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f45524332303a207472616e7366657220616d6f756e742065786365656473206260448201527f616c616e63650000000000000000000000000000000000000000000000000000606482015260840161069a565b73ffffffffffffffffffffffffffffffffffffffff808516600090815260208190526040808220858503905591851681529081208054849290610e7490849061154e565b925050819055508273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef84604051610eda91815260200190565b60405180910390a3610c2e565b73ffffffffffffffffffffffffffffffffffffffff8216610f64576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f206164647265737300604482015260640161069a565b8060026000828254610f76919061154e565b909155505073ffffffffffffffffffffffffffffffffffffffff821660009081526020819052604081208054839290610fb090849061154e565b909155505060405181815273ffffffffffffffffffffffffffffffffffffffff8316906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9060200160405180910390a35050565b60608160000361104a57505060408051808201909152600181527f3000000000000000000000000000000000000000000000000000000000000000602082015290565b8160005b8115611074578061105e816115dc565b915061106d9050600a83611643565b915061104e565b60008167ffffffffffffffff81111561108f5761108f611657565b6040519080825280601f01601f1916602001820160405280156110b9576020820181803683370190505b5090505b841561113c576110ce600183611686565b91506110db600a8661169d565b6110e690603061154e565b60f81b8183815181106110fb576110fb6116b1565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350611135600a86611643565b94506110bd565b949350505050565b73ffffffffffffffffffffffffffffffffffffffff82166111e7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602160248201527f45524332303a206275726e2066726f6d20746865207a65726f2061646472657360448201527f7300000000000000000000000000000000000000000000000000000000000000606482015260840161069a565b73ffffffffffffffffffffffffffffffffffffffff82166000908152602081905260409020548181101561129d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602260248201527f45524332303a206275726e20616d6f756e7420657863656564732062616c616e60448201527f6365000000000000000000000000000000000000000000000000000000000000606482015260840161069a565b73ffffffffffffffffffffffffffffffffffffffff831660009081526020819052604081208383039055600280548492906112d9908490611686565b909155505060405182815260009073ffffffffffffffffffffffffffffffffffffffff8516907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef90602001610b50565b60006020828403121561133b57600080fd5b81357fffffffff000000000000000000000000000000000000000000000000000000008116811461136b57600080fd5b9392505050565b60005b8381101561138d578181015183820152602001611375565b83811115610c2e5750506000910152565b60208152600082518060208401526113bd816040850160208701611372565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169190910160400192915050565b803573ffffffffffffffffffffffffffffffffffffffff8116811461141357600080fd5b919050565b6000806040838503121561142b57600080fd5b611434836113ef565b946020939093013593505050565b60008060006060848603121561145757600080fd5b611460846113ef565b925061146e602085016113ef565b9150604084013590509250925092565b60006020828403121561149057600080fd5b61136b826113ef565b600080604083850312156114ac57600080fd5b6114b5836113ef565b91506114c3602084016113ef565b90509250929050565b600181811c908216806114e057607f821691505b602082108103611519577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600082198211156115615761156161151f565b500190565b60008451611578818460208901611372565b80830190507f2e0000000000000000000000000000000000000000000000000000000000000080825285516115b4816001850160208a01611372565b600192019182015283516115cf816002840160208801611372565b0160020195945050505050565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361160d5761160d61151f565b5060010190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b60008261165257611652611614565b500490565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6000828210156116985761169861151f565b500390565b6000826116ac576116ac611614565b500690565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fdfea164736f6c634300080f000a" +var OptimismMintableERC20DeployedBin = "0x608060405234801561001057600080fd5b50600436106101775760003560e01c806370a08231116100d8578063ae1f6aaf1161008c578063dd62ed3e11610066578063dd62ed3e14610395578063e78cea9214610349578063ee9a31a2146103db57600080fd5b8063ae1f6aaf14610349578063c01e1bd61461036f578063d6c0b2c41461036f57600080fd5b80639dc29fac116100bd5780639dc29fac14610310578063a457c2d714610323578063a9059cbb1461033657600080fd5b806370a08231146102d257806395d89b411461030857600080fd5b806323b872dd1161012f5780633950935111610114578063395093511461026e57806340c10f191461028157806354fd4d501461029657600080fd5b806323b872dd1461022a578063313ce5671461023d57600080fd5b806306fdde031161016057806306fdde03146101f0578063095ea7b31461020557806318160ddd1461021857600080fd5b806301ffc9a71461017c578063033964be146101a4575b600080fd5b61018f61018a36600461117d565b610402565b60405190151581526020015b60405180910390f35b6101cb7f000000000000000000000000000000000000000000000000000000000000000081565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161019b565b6101f86104f3565b60405161019b91906111c6565b61018f610213366004611262565b610585565b6002545b60405190815260200161019b565b61018f61023836600461128c565b61059d565b60405160ff7f000000000000000000000000000000000000000000000000000000000000000016815260200161019b565b61018f61027c366004611262565b6105c1565b61029461028f366004611262565b61060d565b005b6101f86040518060400160405280600581526020017f312e332e3000000000000000000000000000000000000000000000000000000081525081565b61021c6102e03660046112c8565b73ffffffffffffffffffffffffffffffffffffffff1660009081526020819052604090205490565b6101f8610735565b61029461031e366004611262565b610744565b61018f610331366004611262565b61085b565b61018f610344366004611262565b61092c565b7f00000000000000000000000000000000000000000000000000000000000000006101cb565b7f00000000000000000000000000000000000000000000000000000000000000006101cb565b61021c6103a33660046112e3565b73ffffffffffffffffffffffffffffffffffffffff918216600090815260016020908152604080832093909416825291909152205490565b6101cb7f000000000000000000000000000000000000000000000000000000000000000081565b60007f01ffc9a7000000000000000000000000000000000000000000000000000000007f1d1d8b63000000000000000000000000000000000000000000000000000000007fec4fc8e3000000000000000000000000000000000000000000000000000000007fffffffff0000000000000000000000000000000000000000000000000000000085168314806104bb57507fffffffff00000000000000000000000000000000000000000000000000000000858116908316145b806104ea57507fffffffff00000000000000000000000000000000000000000000000000000000858116908216145b95945050505050565b60606003805461050290611316565b80601f016020809104026020016040519081016040528092919081815260200182805461052e90611316565b801561057b5780601f106105505761010080835404028352916020019161057b565b820191906000526020600020905b81548152906001019060200180831161055e57829003601f168201915b5050505050905090565b60003361059381858561093a565b5060019392505050565b6000336105ab858285610aee565b6105b6858585610bc5565b506001949350505050565b33600081815260016020908152604080832073ffffffffffffffffffffffffffffffffffffffff871684529091528120549091906105939082908690610608908790611398565b61093a565b3373ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016146106d7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603460248201527f4f7074696d69736d4d696e7461626c6545524332303a206f6e6c79206272696460448201527f67652063616e206d696e7420616e64206275726e00000000000000000000000060648201526084015b60405180910390fd5b6106e18282610e78565b8173ffffffffffffffffffffffffffffffffffffffff167f0f6798a560793a54c3bcfe86a93cde1e73087d944c0ea20544137d41213968858260405161072991815260200190565b60405180910390a25050565b60606004805461050290611316565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610809576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603460248201527f4f7074696d69736d4d696e7461626c6545524332303a206f6e6c79206272696460448201527f67652063616e206d696e7420616e64206275726e00000000000000000000000060648201526084016106ce565b6108138282610f98565b8173ffffffffffffffffffffffffffffffffffffffff167fcc16f5dbb4873280815c1ee09dbd06736cffcc184412cf7a71a0fdb75d397ca58260405161072991815260200190565b33600081815260016020908152604080832073ffffffffffffffffffffffffffffffffffffffff871684529091528120549091908381101561091f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602560248201527f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f7760448201527f207a65726f00000000000000000000000000000000000000000000000000000060648201526084016106ce565b6105b6828686840361093a565b600033610593818585610bc5565b73ffffffffffffffffffffffffffffffffffffffff83166109dc576040517f08c379a0000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f45524332303a20617070726f76652066726f6d20746865207a65726f2061646460448201527f726573730000000000000000000000000000000000000000000000000000000060648201526084016106ce565b73ffffffffffffffffffffffffffffffffffffffff8216610a7f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602260248201527f45524332303a20617070726f766520746f20746865207a65726f20616464726560448201527f737300000000000000000000000000000000000000000000000000000000000060648201526084016106ce565b73ffffffffffffffffffffffffffffffffffffffff83811660008181526001602090815260408083209487168084529482529182902085905590518481527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92591015b60405180910390a3505050565b73ffffffffffffffffffffffffffffffffffffffff8381166000908152600160209081526040808320938616835292905220547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8114610bbf5781811015610bb2576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f45524332303a20696e73756666696369656e7420616c6c6f77616e636500000060448201526064016106ce565b610bbf848484840361093a565b50505050565b73ffffffffffffffffffffffffffffffffffffffff8316610c68576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602560248201527f45524332303a207472616e736665722066726f6d20746865207a65726f20616460448201527f647265737300000000000000000000000000000000000000000000000000000060648201526084016106ce565b73ffffffffffffffffffffffffffffffffffffffff8216610d0b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260448201527f657373000000000000000000000000000000000000000000000000000000000060648201526084016106ce565b73ffffffffffffffffffffffffffffffffffffffff831660009081526020819052604090205481811015610dc1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f45524332303a207472616e7366657220616d6f756e742065786365656473206260448201527f616c616e6365000000000000000000000000000000000000000000000000000060648201526084016106ce565b73ffffffffffffffffffffffffffffffffffffffff808516600090815260208190526040808220858503905591851681529081208054849290610e05908490611398565b925050819055508273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef84604051610e6b91815260200190565b60405180910390a3610bbf565b73ffffffffffffffffffffffffffffffffffffffff8216610ef5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f20616464726573730060448201526064016106ce565b8060026000828254610f079190611398565b909155505073ffffffffffffffffffffffffffffffffffffffff821660009081526020819052604081208054839290610f41908490611398565b909155505060405181815273ffffffffffffffffffffffffffffffffffffffff8316906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9060200160405180910390a35050565b73ffffffffffffffffffffffffffffffffffffffff821661103b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602160248201527f45524332303a206275726e2066726f6d20746865207a65726f2061646472657360448201527f730000000000000000000000000000000000000000000000000000000000000060648201526084016106ce565b73ffffffffffffffffffffffffffffffffffffffff8216600090815260208190526040902054818110156110f1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602260248201527f45524332303a206275726e20616d6f756e7420657863656564732062616c616e60448201527f636500000000000000000000000000000000000000000000000000000000000060648201526084016106ce565b73ffffffffffffffffffffffffffffffffffffffff8316600090815260208190526040812083830390556002805484929061112d9084906113b0565b909155505060405182815260009073ffffffffffffffffffffffffffffffffffffffff8516907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef90602001610ae1565b60006020828403121561118f57600080fd5b81357fffffffff00000000000000000000000000000000000000000000000000000000811681146111bf57600080fd5b9392505050565b600060208083528351808285015260005b818110156111f3578581018301518582016040015282016111d7565b81811115611205576000604083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016929092016040019392505050565b803573ffffffffffffffffffffffffffffffffffffffff8116811461125d57600080fd5b919050565b6000806040838503121561127557600080fd5b61127e83611239565b946020939093013593505050565b6000806000606084860312156112a157600080fd5b6112aa84611239565b92506112b860208501611239565b9150604084013590509250925092565b6000602082840312156112da57600080fd5b6111bf82611239565b600080604083850312156112f657600080fd5b6112ff83611239565b915061130d60208401611239565b90509250929050565b600181811c9082168061132a57607f821691505b602082108103611363577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600082198211156113ab576113ab611369565b500190565b6000828210156113c2576113c2611369565b50039056fea164736f6c634300080f000a" func init() { if err := json.Unmarshal([]byte(OptimismMintableERC20StorageLayoutJSON), OptimismMintableERC20StorageLayout); err != nil { diff --git a/op-bindings/bindings/optimismmintableerc20factory.go b/op-bindings/bindings/optimismmintableerc20factory.go index 8fc54d850a895..597a71b641ca1 100644 --- a/op-bindings/bindings/optimismmintableerc20factory.go +++ b/op-bindings/bindings/optimismmintableerc20factory.go @@ -31,7 +31,7 @@ var ( // OptimismMintableERC20FactoryMetaData contains all meta data concerning the OptimismMintableERC20Factory contract. var OptimismMintableERC20FactoryMetaData = &bind.MetaData{ ABI: "[{\"inputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"version\",\"type\":\"uint8\"}],\"name\":\"Initialized\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"localToken\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"remoteToken\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"deployer\",\"type\":\"address\"}],\"name\":\"OptimismMintableERC20Created\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"remoteToken\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"localToken\",\"type\":\"address\"}],\"name\":\"StandardL2TokenCreated\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"BRIDGE\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"bridge\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_remoteToken\",\"type\":\"address\"},{\"internalType\":\"string\",\"name\":\"_name\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"_symbol\",\"type\":\"string\"}],\"name\":\"createOptimismMintableERC20\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_remoteToken\",\"type\":\"address\"},{\"internalType\":\"string\",\"name\":\"_name\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"_symbol\",\"type\":\"string\"},{\"internalType\":\"uint8\",\"name\":\"_decimals\",\"type\":\"uint8\"}],\"name\":\"createOptimismMintableERC20WithDecimals\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_remoteToken\",\"type\":\"address\"},{\"internalType\":\"string\",\"name\":\"_name\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"_symbol\",\"type\":\"string\"}],\"name\":\"createStandardL2Token\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_bridge\",\"type\":\"address\"}],\"name\":\"initialize\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"version\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", - Bin: "0x608060405234801561001057600080fd5b5061001b6000610020565b610118565b600054600390610100900460ff16158015610042575060005460ff8083169116105b6100a95760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b606482015260840160405180910390fd5b6000805461010060ff841661ffff19909216821717610100600160b01b03191661ff0019620100006001600160a01b0387160216179091556040519081527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050565b6123cf806101276000396000f3fe60806040523480156200001157600080fd5b5060043610620000875760003560e01c8063c4d66de81162000062578063c4d66de81462000135578063ce5ac90f146200014e578063e78cea921462000165578063ee9a31a2146200018c57600080fd5b806354fd4d50146200008c578063896f93d114620000e15780638cf0629c146200011e575b600080fd5b620000c96040518060400160405280600581526020017f312e362e3000000000000000000000000000000000000000000000000000000081525081565b604051620000d89190620005d1565b60405180910390f35b620000f8620000f2366004620006f9565b620001b1565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001620000d8565b620000f86200012f36600462000776565b620001c8565b6200014c620001463660046200080d565b620003c6565b005b620000f86200015f366004620006f9565b62000544565b600054620000f89062010000900473ffffffffffffffffffffffffffffffffffffffff1681565b60005462010000900473ffffffffffffffffffffffffffffffffffffffff16620000f8565b6000620001c084848462000544565b949350505050565b600073ffffffffffffffffffffffffffffffffffffffff851662000273576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603f60248201527f4f7074696d69736d4d696e7461626c654552433230466163746f72793a206d7560448201527f73742070726f766964652072656d6f746520746f6b656e20616464726573730060648201526084015b60405180910390fd5b6000858585856040516020016200028e94939291906200082b565b604051602081830303815290604052805190602001209050600081600060029054906101000a900473ffffffffffffffffffffffffffffffffffffffff1688888888604051620002de9062000555565b620002ee95949392919062000885565b8190604051809103906000f59050801580156200030f573d6000803e3d6000fd5b5090508073ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff167fceeb8e7d520d7f3b65fc11a262b91066940193b05d4f93df07cfdced0eb551cf60405160405180910390a360405133815273ffffffffffffffffffffffffffffffffffffffff80891691908316907f52fe89dd5930f343d25650b62fd367bae47088bcddffd2a88350a6ecdd620cdb9060200160405180910390a39695505050505050565b600054600390610100900460ff16158015620003e9575060005460ff8083169116105b62000477576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a656400000000000000000000000000000000000060648201526084016200026a565b6000805461010060ff84167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00009092168217177fffffffffffffffffffff000000000000000000000000000000000000000000ff167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff6201000073ffffffffffffffffffffffffffffffffffffffff87160216179091556040519081527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050565b6000620001c08484846012620001c8565b611ad880620008eb83390190565b6000815180845260005b818110156200058b576020818501810151868301820152016200056d565b818111156200059e576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b602081526000620005e6602083018462000563565b9392505050565b803573ffffffffffffffffffffffffffffffffffffffff811681146200061257600080fd5b919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b600082601f8301126200065857600080fd5b813567ffffffffffffffff8082111562000676576200067662000617565b604051601f83017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f01168101908282118183101715620006bf57620006bf62000617565b81604052838152866020858801011115620006d957600080fd5b836020870160208301376000602085830101528094505050505092915050565b6000806000606084860312156200070f57600080fd5b6200071a84620005ed565b9250602084013567ffffffffffffffff808211156200073857600080fd5b620007468783880162000646565b935060408601359150808211156200075d57600080fd5b506200076c8682870162000646565b9150509250925092565b600080600080608085870312156200078d57600080fd5b6200079885620005ed565b9350602085013567ffffffffffffffff80821115620007b657600080fd5b620007c48883890162000646565b94506040870135915080821115620007db57600080fd5b50620007ea8782880162000646565b925050606085013560ff811681146200080257600080fd5b939692955090935050565b6000602082840312156200082057600080fd5b620005e682620005ed565b73ffffffffffffffffffffffffffffffffffffffff851681526080602082015260006200085c608083018662000563565b828103604084015262000870818662000563565b91505060ff8316606083015295945050505050565b600073ffffffffffffffffffffffffffffffffffffffff808816835280871660208401525060a06040830152620008c060a083018662000563565b8281036060840152620008d4818662000563565b91505060ff83166080830152969550505050505056fe6101406040523480156200001257600080fd5b5060405162001ad838038062001ad8833981016040819052620000359162000178565b600160026000858560036200004b8382620002b3565b5060046200005a8282620002b3565b50505060809290925260a05260c0526001600160a01b0393841660e0529390921661010052505060ff16610120526200037f565b80516001600160a01b0381168114620000a657600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b600082601f830112620000d357600080fd5b81516001600160401b0380821115620000f057620000f0620000ab565b604051601f8301601f19908116603f011681019082821181831017156200011b576200011b620000ab565b816040528381526020925086838588010111156200013857600080fd5b600091505b838210156200015c57858201830151818301840152908201906200013d565b838211156200016e5760008385830101525b9695505050505050565b600080600080600060a086880312156200019157600080fd5b6200019c866200008e565b9450620001ac602087016200008e565b60408701519094506001600160401b0380821115620001ca57600080fd5b620001d889838a01620000c1565b94506060880151915080821115620001ef57600080fd5b50620001fe88828901620000c1565b925050608086015160ff811681146200021657600080fd5b809150509295509295909350565b600181811c908216806200023957607f821691505b6020821081036200025a57634e487b7160e01b600052602260045260246000fd5b50919050565b601f821115620002ae57600081815260208120601f850160051c81016020861015620002895750805b601f850160051c820191505b81811015620002aa5782815560010162000295565b5050505b505050565b81516001600160401b03811115620002cf57620002cf620000ab565b620002e781620002e0845462000224565b8462000260565b602080601f8311600181146200031f5760008415620003065750858301515b600019600386901b1c1916600185901b178555620002aa565b600085815260208120601f198616915b8281101562000350578886015182559484019460019091019084016200032f565b50858210156200036f5787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b60805160a05160c05160e05161010051610120516116ed620003eb6000396000610244015260008181610317015281816103ac015281816105f101526107cb0152600081816101a9015261033d0152600061075a015260006107310152600061070801526116ed6000f3fe608060405234801561001057600080fd5b50600436106101775760003560e01c806370a08231116100d8578063ae1f6aaf1161008c578063dd62ed3e11610066578063dd62ed3e14610361578063e78cea9214610315578063ee9a31a2146103a757600080fd5b8063ae1f6aaf14610315578063c01e1bd61461033b578063d6c0b2c41461033b57600080fd5b80639dc29fac116100bd5780639dc29fac146102dc578063a457c2d7146102ef578063a9059cbb1461030257600080fd5b806370a082311461029e57806395d89b41146102d457600080fd5b806323b872dd1161012f5780633950935111610114578063395093511461026e57806340c10f191461028157806354fd4d501461029657600080fd5b806323b872dd1461022a578063313ce5671461023d57600080fd5b806306fdde031161016057806306fdde03146101f0578063095ea7b31461020557806318160ddd1461021857600080fd5b806301ffc9a71461017c578063033964be146101a4575b600080fd5b61018f61018a366004611329565b6103ce565b60405190151581526020015b60405180910390f35b6101cb7f000000000000000000000000000000000000000000000000000000000000000081565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161019b565b6101f86104bf565b60405161019b919061139e565b61018f610213366004611418565b610551565b6002545b60405190815260200161019b565b61018f610238366004611442565b610569565b60405160ff7f000000000000000000000000000000000000000000000000000000000000000016815260200161019b565b61018f61027c366004611418565b61058d565b61029461028f366004611418565b6105d9565b005b6101f8610701565b61021c6102ac36600461147e565b73ffffffffffffffffffffffffffffffffffffffff1660009081526020819052604090205490565b6101f86107a4565b6102946102ea366004611418565b6107b3565b61018f6102fd366004611418565b6108ca565b61018f610310366004611418565b61099b565b7f00000000000000000000000000000000000000000000000000000000000000006101cb565b7f00000000000000000000000000000000000000000000000000000000000000006101cb565b61021c61036f366004611499565b73ffffffffffffffffffffffffffffffffffffffff918216600090815260016020908152604080832093909416825291909152205490565b6101cb7f000000000000000000000000000000000000000000000000000000000000000081565b60007f01ffc9a7000000000000000000000000000000000000000000000000000000007f1d1d8b63000000000000000000000000000000000000000000000000000000007fec4fc8e3000000000000000000000000000000000000000000000000000000007fffffffff00000000000000000000000000000000000000000000000000000000851683148061048757507fffffffff00000000000000000000000000000000000000000000000000000000858116908316145b806104b657507fffffffff00000000000000000000000000000000000000000000000000000000858116908216145b95945050505050565b6060600380546104ce906114cc565b80601f01602080910402602001604051908101604052809291908181526020018280546104fa906114cc565b80156105475780601f1061051c57610100808354040283529160200191610547565b820191906000526020600020905b81548152906001019060200180831161052a57829003601f168201915b5050505050905090565b60003361055f8185856109a9565b5060019392505050565b600033610577858285610b5d565b610582858585610c34565b506001949350505050565b33600081815260016020908152604080832073ffffffffffffffffffffffffffffffffffffffff8716845290915281205490919061055f90829086906105d490879061154e565b6109a9565b3373ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016146106a3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603460248201527f4f7074696d69736d4d696e7461626c6545524332303a206f6e6c79206272696460448201527f67652063616e206d696e7420616e64206275726e00000000000000000000000060648201526084015b60405180910390fd5b6106ad8282610ee7565b8173ffffffffffffffffffffffffffffffffffffffff167f0f6798a560793a54c3bcfe86a93cde1e73087d944c0ea20544137d4121396885826040516106f591815260200190565b60405180910390a25050565b606061072c7f0000000000000000000000000000000000000000000000000000000000000000611007565b6107557f0000000000000000000000000000000000000000000000000000000000000000611007565b61077e7f0000000000000000000000000000000000000000000000000000000000000000611007565b60405160200161079093929190611566565b604051602081830303815290604052905090565b6060600480546104ce906114cc565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610878576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603460248201527f4f7074696d69736d4d696e7461626c6545524332303a206f6e6c79206272696460448201527f67652063616e206d696e7420616e64206275726e000000000000000000000000606482015260840161069a565b6108828282611144565b8173ffffffffffffffffffffffffffffffffffffffff167fcc16f5dbb4873280815c1ee09dbd06736cffcc184412cf7a71a0fdb75d397ca5826040516106f591815260200190565b33600081815260016020908152604080832073ffffffffffffffffffffffffffffffffffffffff871684529091528120549091908381101561098e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602560248201527f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f7760448201527f207a65726f000000000000000000000000000000000000000000000000000000606482015260840161069a565b61058282868684036109a9565b60003361055f818585610c34565b73ffffffffffffffffffffffffffffffffffffffff8316610a4b576040517f08c379a0000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f45524332303a20617070726f76652066726f6d20746865207a65726f2061646460448201527f7265737300000000000000000000000000000000000000000000000000000000606482015260840161069a565b73ffffffffffffffffffffffffffffffffffffffff8216610aee576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602260248201527f45524332303a20617070726f766520746f20746865207a65726f20616464726560448201527f7373000000000000000000000000000000000000000000000000000000000000606482015260840161069a565b73ffffffffffffffffffffffffffffffffffffffff83811660008181526001602090815260408083209487168084529482529182902085905590518481527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92591015b60405180910390a3505050565b73ffffffffffffffffffffffffffffffffffffffff8381166000908152600160209081526040808320938616835292905220547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8114610c2e5781811015610c21576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f45524332303a20696e73756666696369656e7420616c6c6f77616e6365000000604482015260640161069a565b610c2e84848484036109a9565b50505050565b73ffffffffffffffffffffffffffffffffffffffff8316610cd7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602560248201527f45524332303a207472616e736665722066726f6d20746865207a65726f20616460448201527f6472657373000000000000000000000000000000000000000000000000000000606482015260840161069a565b73ffffffffffffffffffffffffffffffffffffffff8216610d7a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260448201527f6573730000000000000000000000000000000000000000000000000000000000606482015260840161069a565b73ffffffffffffffffffffffffffffffffffffffff831660009081526020819052604090205481811015610e30576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f45524332303a207472616e7366657220616d6f756e742065786365656473206260448201527f616c616e63650000000000000000000000000000000000000000000000000000606482015260840161069a565b73ffffffffffffffffffffffffffffffffffffffff808516600090815260208190526040808220858503905591851681529081208054849290610e7490849061154e565b925050819055508273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef84604051610eda91815260200190565b60405180910390a3610c2e565b73ffffffffffffffffffffffffffffffffffffffff8216610f64576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f206164647265737300604482015260640161069a565b8060026000828254610f76919061154e565b909155505073ffffffffffffffffffffffffffffffffffffffff821660009081526020819052604081208054839290610fb090849061154e565b909155505060405181815273ffffffffffffffffffffffffffffffffffffffff8316906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9060200160405180910390a35050565b60608160000361104a57505060408051808201909152600181527f3000000000000000000000000000000000000000000000000000000000000000602082015290565b8160005b8115611074578061105e816115dc565b915061106d9050600a83611643565b915061104e565b60008167ffffffffffffffff81111561108f5761108f611657565b6040519080825280601f01601f1916602001820160405280156110b9576020820181803683370190505b5090505b841561113c576110ce600183611686565b91506110db600a8661169d565b6110e690603061154e565b60f81b8183815181106110fb576110fb6116b1565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350611135600a86611643565b94506110bd565b949350505050565b73ffffffffffffffffffffffffffffffffffffffff82166111e7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602160248201527f45524332303a206275726e2066726f6d20746865207a65726f2061646472657360448201527f7300000000000000000000000000000000000000000000000000000000000000606482015260840161069a565b73ffffffffffffffffffffffffffffffffffffffff82166000908152602081905260409020548181101561129d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602260248201527f45524332303a206275726e20616d6f756e7420657863656564732062616c616e60448201527f6365000000000000000000000000000000000000000000000000000000000000606482015260840161069a565b73ffffffffffffffffffffffffffffffffffffffff831660009081526020819052604081208383039055600280548492906112d9908490611686565b909155505060405182815260009073ffffffffffffffffffffffffffffffffffffffff8516907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef90602001610b50565b60006020828403121561133b57600080fd5b81357fffffffff000000000000000000000000000000000000000000000000000000008116811461136b57600080fd5b9392505050565b60005b8381101561138d578181015183820152602001611375565b83811115610c2e5750506000910152565b60208152600082518060208401526113bd816040850160208701611372565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169190910160400192915050565b803573ffffffffffffffffffffffffffffffffffffffff8116811461141357600080fd5b919050565b6000806040838503121561142b57600080fd5b611434836113ef565b946020939093013593505050565b60008060006060848603121561145757600080fd5b611460846113ef565b925061146e602085016113ef565b9150604084013590509250925092565b60006020828403121561149057600080fd5b61136b826113ef565b600080604083850312156114ac57600080fd5b6114b5836113ef565b91506114c3602084016113ef565b90509250929050565b600181811c908216806114e057607f821691505b602082108103611519577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600082198211156115615761156161151f565b500190565b60008451611578818460208901611372565b80830190507f2e0000000000000000000000000000000000000000000000000000000000000080825285516115b4816001850160208a01611372565b600192019182015283516115cf816002840160208801611372565b0160020195945050505050565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361160d5761160d61151f565b5060010190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b60008261165257611652611614565b500490565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6000828210156116985761169861151f565b500390565b6000826116ac576116ac611614565b500690565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fdfea164736f6c634300080f000aa164736f6c634300080f000a", + Bin: "0x608060405234801561001057600080fd5b5061001b6000610020565b610118565b600054600390610100900460ff16158015610042575060005460ff8083169116105b6100a95760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b606482015260840160405180910390fd5b6000805461010060ff841661ffff19909216821717610100600160b01b03191661ff0019620100006001600160a01b0387160216179091556040519081527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050565b612081806101276000396000f3fe60806040523480156200001157600080fd5b5060043610620000875760003560e01c8063c4d66de81162000062578063c4d66de81462000135578063ce5ac90f146200014e578063e78cea921462000165578063ee9a31a2146200018c57600080fd5b806354fd4d50146200008c578063896f93d114620000e15780638cf0629c146200011e575b600080fd5b620000c96040518060400160405280600581526020017f312e372e3000000000000000000000000000000000000000000000000000000081525081565b604051620000d89190620005d1565b60405180910390f35b620000f8620000f2366004620006f9565b620001b1565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001620000d8565b620000f86200012f36600462000776565b620001c8565b6200014c620001463660046200080d565b620003c6565b005b620000f86200015f366004620006f9565b62000544565b600054620000f89062010000900473ffffffffffffffffffffffffffffffffffffffff1681565b60005462010000900473ffffffffffffffffffffffffffffffffffffffff16620000f8565b6000620001c084848462000544565b949350505050565b600073ffffffffffffffffffffffffffffffffffffffff851662000273576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603f60248201527f4f7074696d69736d4d696e7461626c654552433230466163746f72793a206d7560448201527f73742070726f766964652072656d6f746520746f6b656e20616464726573730060648201526084015b60405180910390fd5b6000858585856040516020016200028e94939291906200082b565b604051602081830303815290604052805190602001209050600081600060029054906101000a900473ffffffffffffffffffffffffffffffffffffffff1688888888604051620002de9062000555565b620002ee95949392919062000885565b8190604051809103906000f59050801580156200030f573d6000803e3d6000fd5b5090508073ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff167fceeb8e7d520d7f3b65fc11a262b91066940193b05d4f93df07cfdced0eb551cf60405160405180910390a360405133815273ffffffffffffffffffffffffffffffffffffffff80891691908316907f52fe89dd5930f343d25650b62fd367bae47088bcddffd2a88350a6ecdd620cdb9060200160405180910390a39695505050505050565b600054600390610100900460ff16158015620003e9575060005460ff8083169116105b62000477576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a656400000000000000000000000000000000000060648201526084016200026a565b6000805461010060ff84167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00009092168217177fffffffffffffffffffff000000000000000000000000000000000000000000ff167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff6201000073ffffffffffffffffffffffffffffffffffffffff87160216179091556040519081527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050565b6000620001c08484846012620001c8565b61178a80620008eb83390190565b6000815180845260005b818110156200058b576020818501810151868301820152016200056d565b818111156200059e576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b602081526000620005e6602083018462000563565b9392505050565b803573ffffffffffffffffffffffffffffffffffffffff811681146200061257600080fd5b919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b600082601f8301126200065857600080fd5b813567ffffffffffffffff8082111562000676576200067662000617565b604051601f83017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f01168101908282118183101715620006bf57620006bf62000617565b81604052838152866020858801011115620006d957600080fd5b836020870160208301376000602085830101528094505050505092915050565b6000806000606084860312156200070f57600080fd5b6200071a84620005ed565b9250602084013567ffffffffffffffff808211156200073857600080fd5b620007468783880162000646565b935060408601359150808211156200075d57600080fd5b506200076c8682870162000646565b9150509250925092565b600080600080608085870312156200078d57600080fd5b6200079885620005ed565b9350602085013567ffffffffffffffff80821115620007b657600080fd5b620007c48883890162000646565b94506040870135915080821115620007db57600080fd5b50620007ea8782880162000646565b925050606085013560ff811681146200080257600080fd5b939692955090935050565b6000602082840312156200082057600080fd5b620005e682620005ed565b73ffffffffffffffffffffffffffffffffffffffff851681526080602082015260006200085c608083018662000563565b828103604084015262000870818662000563565b91505060ff8316606083015295945050505050565b600073ffffffffffffffffffffffffffffffffffffffff808816835280871660208401525060a06040830152620008c060a083018662000563565b8281036060840152620008d4818662000563565b91505060ff83166080830152969550505050505056fe60e06040523480156200001157600080fd5b506040516200178a3803806200178a833981016040819052620000349162000163565b828260036200004483826200029e565b5060046200005382826200029e565b5050506001600160a01b039384166080529390921660a052505060ff1660c0526200036a565b80516001600160a01b03811681146200009157600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b600082601f830112620000be57600080fd5b81516001600160401b0380821115620000db57620000db62000096565b604051601f8301601f19908116603f0116810190828211818310171562000106576200010662000096565b816040528381526020925086838588010111156200012357600080fd5b600091505b8382101562000147578582018301518183018401529082019062000128565b83821115620001595760008385830101525b9695505050505050565b600080600080600060a086880312156200017c57600080fd5b620001878662000079565b9450620001976020870162000079565b60408701519094506001600160401b0380821115620001b557600080fd5b620001c389838a01620000ac565b94506060880151915080821115620001da57600080fd5b50620001e988828901620000ac565b925050608086015160ff811681146200020157600080fd5b809150509295509295909350565b600181811c908216806200022457607f821691505b6020821081036200024557634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200029957600081815260208120601f850160051c81016020861015620002745750805b601f850160051c820191505b81811015620002955782815560010162000280565b5050505b505050565b81516001600160401b03811115620002ba57620002ba62000096565b620002d281620002cb84546200020f565b846200024b565b602080601f8311600181146200030a5760008415620002f15750858301515b600019600386901b1c1916600185901b17855562000295565b600085815260208120601f198616915b828110156200033b578886015182559484019460019091019084016200031a565b50858210156200035a5787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b60805160a05160c0516113d4620003b6600039600061024401526000818161034b015281816103e001528181610625015261075c0152600081816101a9015261037101526113d46000f3fe608060405234801561001057600080fd5b50600436106101775760003560e01c806370a08231116100d8578063ae1f6aaf1161008c578063dd62ed3e11610066578063dd62ed3e14610395578063e78cea9214610349578063ee9a31a2146103db57600080fd5b8063ae1f6aaf14610349578063c01e1bd61461036f578063d6c0b2c41461036f57600080fd5b80639dc29fac116100bd5780639dc29fac14610310578063a457c2d714610323578063a9059cbb1461033657600080fd5b806370a08231146102d257806395d89b411461030857600080fd5b806323b872dd1161012f5780633950935111610114578063395093511461026e57806340c10f191461028157806354fd4d501461029657600080fd5b806323b872dd1461022a578063313ce5671461023d57600080fd5b806306fdde031161016057806306fdde03146101f0578063095ea7b31461020557806318160ddd1461021857600080fd5b806301ffc9a71461017c578063033964be146101a4575b600080fd5b61018f61018a36600461117d565b610402565b60405190151581526020015b60405180910390f35b6101cb7f000000000000000000000000000000000000000000000000000000000000000081565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161019b565b6101f86104f3565b60405161019b91906111c6565b61018f610213366004611262565b610585565b6002545b60405190815260200161019b565b61018f61023836600461128c565b61059d565b60405160ff7f000000000000000000000000000000000000000000000000000000000000000016815260200161019b565b61018f61027c366004611262565b6105c1565b61029461028f366004611262565b61060d565b005b6101f86040518060400160405280600581526020017f312e332e3000000000000000000000000000000000000000000000000000000081525081565b61021c6102e03660046112c8565b73ffffffffffffffffffffffffffffffffffffffff1660009081526020819052604090205490565b6101f8610735565b61029461031e366004611262565b610744565b61018f610331366004611262565b61085b565b61018f610344366004611262565b61092c565b7f00000000000000000000000000000000000000000000000000000000000000006101cb565b7f00000000000000000000000000000000000000000000000000000000000000006101cb565b61021c6103a33660046112e3565b73ffffffffffffffffffffffffffffffffffffffff918216600090815260016020908152604080832093909416825291909152205490565b6101cb7f000000000000000000000000000000000000000000000000000000000000000081565b60007f01ffc9a7000000000000000000000000000000000000000000000000000000007f1d1d8b63000000000000000000000000000000000000000000000000000000007fec4fc8e3000000000000000000000000000000000000000000000000000000007fffffffff0000000000000000000000000000000000000000000000000000000085168314806104bb57507fffffffff00000000000000000000000000000000000000000000000000000000858116908316145b806104ea57507fffffffff00000000000000000000000000000000000000000000000000000000858116908216145b95945050505050565b60606003805461050290611316565b80601f016020809104026020016040519081016040528092919081815260200182805461052e90611316565b801561057b5780601f106105505761010080835404028352916020019161057b565b820191906000526020600020905b81548152906001019060200180831161055e57829003601f168201915b5050505050905090565b60003361059381858561093a565b5060019392505050565b6000336105ab858285610aee565b6105b6858585610bc5565b506001949350505050565b33600081815260016020908152604080832073ffffffffffffffffffffffffffffffffffffffff871684529091528120549091906105939082908690610608908790611398565b61093a565b3373ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016146106d7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603460248201527f4f7074696d69736d4d696e7461626c6545524332303a206f6e6c79206272696460448201527f67652063616e206d696e7420616e64206275726e00000000000000000000000060648201526084015b60405180910390fd5b6106e18282610e78565b8173ffffffffffffffffffffffffffffffffffffffff167f0f6798a560793a54c3bcfe86a93cde1e73087d944c0ea20544137d41213968858260405161072991815260200190565b60405180910390a25050565b60606004805461050290611316565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610809576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603460248201527f4f7074696d69736d4d696e7461626c6545524332303a206f6e6c79206272696460448201527f67652063616e206d696e7420616e64206275726e00000000000000000000000060648201526084016106ce565b6108138282610f98565b8173ffffffffffffffffffffffffffffffffffffffff167fcc16f5dbb4873280815c1ee09dbd06736cffcc184412cf7a71a0fdb75d397ca58260405161072991815260200190565b33600081815260016020908152604080832073ffffffffffffffffffffffffffffffffffffffff871684529091528120549091908381101561091f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602560248201527f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f7760448201527f207a65726f00000000000000000000000000000000000000000000000000000060648201526084016106ce565b6105b6828686840361093a565b600033610593818585610bc5565b73ffffffffffffffffffffffffffffffffffffffff83166109dc576040517f08c379a0000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f45524332303a20617070726f76652066726f6d20746865207a65726f2061646460448201527f726573730000000000000000000000000000000000000000000000000000000060648201526084016106ce565b73ffffffffffffffffffffffffffffffffffffffff8216610a7f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602260248201527f45524332303a20617070726f766520746f20746865207a65726f20616464726560448201527f737300000000000000000000000000000000000000000000000000000000000060648201526084016106ce565b73ffffffffffffffffffffffffffffffffffffffff83811660008181526001602090815260408083209487168084529482529182902085905590518481527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92591015b60405180910390a3505050565b73ffffffffffffffffffffffffffffffffffffffff8381166000908152600160209081526040808320938616835292905220547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8114610bbf5781811015610bb2576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f45524332303a20696e73756666696369656e7420616c6c6f77616e636500000060448201526064016106ce565b610bbf848484840361093a565b50505050565b73ffffffffffffffffffffffffffffffffffffffff8316610c68576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602560248201527f45524332303a207472616e736665722066726f6d20746865207a65726f20616460448201527f647265737300000000000000000000000000000000000000000000000000000060648201526084016106ce565b73ffffffffffffffffffffffffffffffffffffffff8216610d0b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260448201527f657373000000000000000000000000000000000000000000000000000000000060648201526084016106ce565b73ffffffffffffffffffffffffffffffffffffffff831660009081526020819052604090205481811015610dc1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f45524332303a207472616e7366657220616d6f756e742065786365656473206260448201527f616c616e6365000000000000000000000000000000000000000000000000000060648201526084016106ce565b73ffffffffffffffffffffffffffffffffffffffff808516600090815260208190526040808220858503905591851681529081208054849290610e05908490611398565b925050819055508273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef84604051610e6b91815260200190565b60405180910390a3610bbf565b73ffffffffffffffffffffffffffffffffffffffff8216610ef5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f20616464726573730060448201526064016106ce565b8060026000828254610f079190611398565b909155505073ffffffffffffffffffffffffffffffffffffffff821660009081526020819052604081208054839290610f41908490611398565b909155505060405181815273ffffffffffffffffffffffffffffffffffffffff8316906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9060200160405180910390a35050565b73ffffffffffffffffffffffffffffffffffffffff821661103b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602160248201527f45524332303a206275726e2066726f6d20746865207a65726f2061646472657360448201527f730000000000000000000000000000000000000000000000000000000000000060648201526084016106ce565b73ffffffffffffffffffffffffffffffffffffffff8216600090815260208190526040902054818110156110f1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602260248201527f45524332303a206275726e20616d6f756e7420657863656564732062616c616e60448201527f636500000000000000000000000000000000000000000000000000000000000060648201526084016106ce565b73ffffffffffffffffffffffffffffffffffffffff8316600090815260208190526040812083830390556002805484929061112d9084906113b0565b909155505060405182815260009073ffffffffffffffffffffffffffffffffffffffff8516907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef90602001610ae1565b60006020828403121561118f57600080fd5b81357fffffffff00000000000000000000000000000000000000000000000000000000811681146111bf57600080fd5b9392505050565b600060208083528351808285015260005b818110156111f3578581018301518582016040015282016111d7565b81811115611205576000604083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016929092016040019392505050565b803573ffffffffffffffffffffffffffffffffffffffff8116811461125d57600080fd5b919050565b6000806040838503121561127557600080fd5b61127e83611239565b946020939093013593505050565b6000806000606084860312156112a157600080fd5b6112aa84611239565b92506112b860208501611239565b9150604084013590509250925092565b6000602082840312156112da57600080fd5b6111bf82611239565b600080604083850312156112f657600080fd5b6112ff83611239565b915061130d60208401611239565b90509250929050565b600181811c9082168061132a57607f821691505b602082108103611363577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600082198211156113ab576113ab611369565b500190565b6000828210156113c2576113c2611369565b50039056fea164736f6c634300080f000aa164736f6c634300080f000a", } // OptimismMintableERC20FactoryABI is the input ABI used to generate the binding from. diff --git a/op-bindings/bindings/optimismmintableerc20factory_more.go b/op-bindings/bindings/optimismmintableerc20factory_more.go index 9f4b0da369108..955da8c91ed51 100644 --- a/op-bindings/bindings/optimismmintableerc20factory_more.go +++ b/op-bindings/bindings/optimismmintableerc20factory_more.go @@ -13,7 +13,7 @@ const OptimismMintableERC20FactoryStorageLayoutJSON = "{\"storage\":[{\"astId\": var OptimismMintableERC20FactoryStorageLayout = new(solc.StorageLayout) -var OptimismMintableERC20FactoryDeployedBin = "0x60806040523480156200001157600080fd5b5060043610620000875760003560e01c8063c4d66de81162000062578063c4d66de81462000135578063ce5ac90f146200014e578063e78cea921462000165578063ee9a31a2146200018c57600080fd5b806354fd4d50146200008c578063896f93d114620000e15780638cf0629c146200011e575b600080fd5b620000c96040518060400160405280600581526020017f312e362e3000000000000000000000000000000000000000000000000000000081525081565b604051620000d89190620005d1565b60405180910390f35b620000f8620000f2366004620006f9565b620001b1565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001620000d8565b620000f86200012f36600462000776565b620001c8565b6200014c620001463660046200080d565b620003c6565b005b620000f86200015f366004620006f9565b62000544565b600054620000f89062010000900473ffffffffffffffffffffffffffffffffffffffff1681565b60005462010000900473ffffffffffffffffffffffffffffffffffffffff16620000f8565b6000620001c084848462000544565b949350505050565b600073ffffffffffffffffffffffffffffffffffffffff851662000273576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603f60248201527f4f7074696d69736d4d696e7461626c654552433230466163746f72793a206d7560448201527f73742070726f766964652072656d6f746520746f6b656e20616464726573730060648201526084015b60405180910390fd5b6000858585856040516020016200028e94939291906200082b565b604051602081830303815290604052805190602001209050600081600060029054906101000a900473ffffffffffffffffffffffffffffffffffffffff1688888888604051620002de9062000555565b620002ee95949392919062000885565b8190604051809103906000f59050801580156200030f573d6000803e3d6000fd5b5090508073ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff167fceeb8e7d520d7f3b65fc11a262b91066940193b05d4f93df07cfdced0eb551cf60405160405180910390a360405133815273ffffffffffffffffffffffffffffffffffffffff80891691908316907f52fe89dd5930f343d25650b62fd367bae47088bcddffd2a88350a6ecdd620cdb9060200160405180910390a39695505050505050565b600054600390610100900460ff16158015620003e9575060005460ff8083169116105b62000477576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a656400000000000000000000000000000000000060648201526084016200026a565b6000805461010060ff84167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00009092168217177fffffffffffffffffffff000000000000000000000000000000000000000000ff167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff6201000073ffffffffffffffffffffffffffffffffffffffff87160216179091556040519081527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050565b6000620001c08484846012620001c8565b611ad880620008eb83390190565b6000815180845260005b818110156200058b576020818501810151868301820152016200056d565b818111156200059e576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b602081526000620005e6602083018462000563565b9392505050565b803573ffffffffffffffffffffffffffffffffffffffff811681146200061257600080fd5b919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b600082601f8301126200065857600080fd5b813567ffffffffffffffff8082111562000676576200067662000617565b604051601f83017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f01168101908282118183101715620006bf57620006bf62000617565b81604052838152866020858801011115620006d957600080fd5b836020870160208301376000602085830101528094505050505092915050565b6000806000606084860312156200070f57600080fd5b6200071a84620005ed565b9250602084013567ffffffffffffffff808211156200073857600080fd5b620007468783880162000646565b935060408601359150808211156200075d57600080fd5b506200076c8682870162000646565b9150509250925092565b600080600080608085870312156200078d57600080fd5b6200079885620005ed565b9350602085013567ffffffffffffffff80821115620007b657600080fd5b620007c48883890162000646565b94506040870135915080821115620007db57600080fd5b50620007ea8782880162000646565b925050606085013560ff811681146200080257600080fd5b939692955090935050565b6000602082840312156200082057600080fd5b620005e682620005ed565b73ffffffffffffffffffffffffffffffffffffffff851681526080602082015260006200085c608083018662000563565b828103604084015262000870818662000563565b91505060ff8316606083015295945050505050565b600073ffffffffffffffffffffffffffffffffffffffff808816835280871660208401525060a06040830152620008c060a083018662000563565b8281036060840152620008d4818662000563565b91505060ff83166080830152969550505050505056fe6101406040523480156200001257600080fd5b5060405162001ad838038062001ad8833981016040819052620000359162000178565b600160026000858560036200004b8382620002b3565b5060046200005a8282620002b3565b50505060809290925260a05260c0526001600160a01b0393841660e0529390921661010052505060ff16610120526200037f565b80516001600160a01b0381168114620000a657600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b600082601f830112620000d357600080fd5b81516001600160401b0380821115620000f057620000f0620000ab565b604051601f8301601f19908116603f011681019082821181831017156200011b576200011b620000ab565b816040528381526020925086838588010111156200013857600080fd5b600091505b838210156200015c57858201830151818301840152908201906200013d565b838211156200016e5760008385830101525b9695505050505050565b600080600080600060a086880312156200019157600080fd5b6200019c866200008e565b9450620001ac602087016200008e565b60408701519094506001600160401b0380821115620001ca57600080fd5b620001d889838a01620000c1565b94506060880151915080821115620001ef57600080fd5b50620001fe88828901620000c1565b925050608086015160ff811681146200021657600080fd5b809150509295509295909350565b600181811c908216806200023957607f821691505b6020821081036200025a57634e487b7160e01b600052602260045260246000fd5b50919050565b601f821115620002ae57600081815260208120601f850160051c81016020861015620002895750805b601f850160051c820191505b81811015620002aa5782815560010162000295565b5050505b505050565b81516001600160401b03811115620002cf57620002cf620000ab565b620002e781620002e0845462000224565b8462000260565b602080601f8311600181146200031f5760008415620003065750858301515b600019600386901b1c1916600185901b178555620002aa565b600085815260208120601f198616915b8281101562000350578886015182559484019460019091019084016200032f565b50858210156200036f5787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b60805160a05160c05160e05161010051610120516116ed620003eb6000396000610244015260008181610317015281816103ac015281816105f101526107cb0152600081816101a9015261033d0152600061075a015260006107310152600061070801526116ed6000f3fe608060405234801561001057600080fd5b50600436106101775760003560e01c806370a08231116100d8578063ae1f6aaf1161008c578063dd62ed3e11610066578063dd62ed3e14610361578063e78cea9214610315578063ee9a31a2146103a757600080fd5b8063ae1f6aaf14610315578063c01e1bd61461033b578063d6c0b2c41461033b57600080fd5b80639dc29fac116100bd5780639dc29fac146102dc578063a457c2d7146102ef578063a9059cbb1461030257600080fd5b806370a082311461029e57806395d89b41146102d457600080fd5b806323b872dd1161012f5780633950935111610114578063395093511461026e57806340c10f191461028157806354fd4d501461029657600080fd5b806323b872dd1461022a578063313ce5671461023d57600080fd5b806306fdde031161016057806306fdde03146101f0578063095ea7b31461020557806318160ddd1461021857600080fd5b806301ffc9a71461017c578063033964be146101a4575b600080fd5b61018f61018a366004611329565b6103ce565b60405190151581526020015b60405180910390f35b6101cb7f000000000000000000000000000000000000000000000000000000000000000081565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161019b565b6101f86104bf565b60405161019b919061139e565b61018f610213366004611418565b610551565b6002545b60405190815260200161019b565b61018f610238366004611442565b610569565b60405160ff7f000000000000000000000000000000000000000000000000000000000000000016815260200161019b565b61018f61027c366004611418565b61058d565b61029461028f366004611418565b6105d9565b005b6101f8610701565b61021c6102ac36600461147e565b73ffffffffffffffffffffffffffffffffffffffff1660009081526020819052604090205490565b6101f86107a4565b6102946102ea366004611418565b6107b3565b61018f6102fd366004611418565b6108ca565b61018f610310366004611418565b61099b565b7f00000000000000000000000000000000000000000000000000000000000000006101cb565b7f00000000000000000000000000000000000000000000000000000000000000006101cb565b61021c61036f366004611499565b73ffffffffffffffffffffffffffffffffffffffff918216600090815260016020908152604080832093909416825291909152205490565b6101cb7f000000000000000000000000000000000000000000000000000000000000000081565b60007f01ffc9a7000000000000000000000000000000000000000000000000000000007f1d1d8b63000000000000000000000000000000000000000000000000000000007fec4fc8e3000000000000000000000000000000000000000000000000000000007fffffffff00000000000000000000000000000000000000000000000000000000851683148061048757507fffffffff00000000000000000000000000000000000000000000000000000000858116908316145b806104b657507fffffffff00000000000000000000000000000000000000000000000000000000858116908216145b95945050505050565b6060600380546104ce906114cc565b80601f01602080910402602001604051908101604052809291908181526020018280546104fa906114cc565b80156105475780601f1061051c57610100808354040283529160200191610547565b820191906000526020600020905b81548152906001019060200180831161052a57829003601f168201915b5050505050905090565b60003361055f8185856109a9565b5060019392505050565b600033610577858285610b5d565b610582858585610c34565b506001949350505050565b33600081815260016020908152604080832073ffffffffffffffffffffffffffffffffffffffff8716845290915281205490919061055f90829086906105d490879061154e565b6109a9565b3373ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016146106a3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603460248201527f4f7074696d69736d4d696e7461626c6545524332303a206f6e6c79206272696460448201527f67652063616e206d696e7420616e64206275726e00000000000000000000000060648201526084015b60405180910390fd5b6106ad8282610ee7565b8173ffffffffffffffffffffffffffffffffffffffff167f0f6798a560793a54c3bcfe86a93cde1e73087d944c0ea20544137d4121396885826040516106f591815260200190565b60405180910390a25050565b606061072c7f0000000000000000000000000000000000000000000000000000000000000000611007565b6107557f0000000000000000000000000000000000000000000000000000000000000000611007565b61077e7f0000000000000000000000000000000000000000000000000000000000000000611007565b60405160200161079093929190611566565b604051602081830303815290604052905090565b6060600480546104ce906114cc565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610878576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603460248201527f4f7074696d69736d4d696e7461626c6545524332303a206f6e6c79206272696460448201527f67652063616e206d696e7420616e64206275726e000000000000000000000000606482015260840161069a565b6108828282611144565b8173ffffffffffffffffffffffffffffffffffffffff167fcc16f5dbb4873280815c1ee09dbd06736cffcc184412cf7a71a0fdb75d397ca5826040516106f591815260200190565b33600081815260016020908152604080832073ffffffffffffffffffffffffffffffffffffffff871684529091528120549091908381101561098e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602560248201527f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f7760448201527f207a65726f000000000000000000000000000000000000000000000000000000606482015260840161069a565b61058282868684036109a9565b60003361055f818585610c34565b73ffffffffffffffffffffffffffffffffffffffff8316610a4b576040517f08c379a0000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f45524332303a20617070726f76652066726f6d20746865207a65726f2061646460448201527f7265737300000000000000000000000000000000000000000000000000000000606482015260840161069a565b73ffffffffffffffffffffffffffffffffffffffff8216610aee576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602260248201527f45524332303a20617070726f766520746f20746865207a65726f20616464726560448201527f7373000000000000000000000000000000000000000000000000000000000000606482015260840161069a565b73ffffffffffffffffffffffffffffffffffffffff83811660008181526001602090815260408083209487168084529482529182902085905590518481527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92591015b60405180910390a3505050565b73ffffffffffffffffffffffffffffffffffffffff8381166000908152600160209081526040808320938616835292905220547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8114610c2e5781811015610c21576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f45524332303a20696e73756666696369656e7420616c6c6f77616e6365000000604482015260640161069a565b610c2e84848484036109a9565b50505050565b73ffffffffffffffffffffffffffffffffffffffff8316610cd7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602560248201527f45524332303a207472616e736665722066726f6d20746865207a65726f20616460448201527f6472657373000000000000000000000000000000000000000000000000000000606482015260840161069a565b73ffffffffffffffffffffffffffffffffffffffff8216610d7a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260448201527f6573730000000000000000000000000000000000000000000000000000000000606482015260840161069a565b73ffffffffffffffffffffffffffffffffffffffff831660009081526020819052604090205481811015610e30576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f45524332303a207472616e7366657220616d6f756e742065786365656473206260448201527f616c616e63650000000000000000000000000000000000000000000000000000606482015260840161069a565b73ffffffffffffffffffffffffffffffffffffffff808516600090815260208190526040808220858503905591851681529081208054849290610e7490849061154e565b925050819055508273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef84604051610eda91815260200190565b60405180910390a3610c2e565b73ffffffffffffffffffffffffffffffffffffffff8216610f64576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f206164647265737300604482015260640161069a565b8060026000828254610f76919061154e565b909155505073ffffffffffffffffffffffffffffffffffffffff821660009081526020819052604081208054839290610fb090849061154e565b909155505060405181815273ffffffffffffffffffffffffffffffffffffffff8316906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9060200160405180910390a35050565b60608160000361104a57505060408051808201909152600181527f3000000000000000000000000000000000000000000000000000000000000000602082015290565b8160005b8115611074578061105e816115dc565b915061106d9050600a83611643565b915061104e565b60008167ffffffffffffffff81111561108f5761108f611657565b6040519080825280601f01601f1916602001820160405280156110b9576020820181803683370190505b5090505b841561113c576110ce600183611686565b91506110db600a8661169d565b6110e690603061154e565b60f81b8183815181106110fb576110fb6116b1565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350611135600a86611643565b94506110bd565b949350505050565b73ffffffffffffffffffffffffffffffffffffffff82166111e7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602160248201527f45524332303a206275726e2066726f6d20746865207a65726f2061646472657360448201527f7300000000000000000000000000000000000000000000000000000000000000606482015260840161069a565b73ffffffffffffffffffffffffffffffffffffffff82166000908152602081905260409020548181101561129d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602260248201527f45524332303a206275726e20616d6f756e7420657863656564732062616c616e60448201527f6365000000000000000000000000000000000000000000000000000000000000606482015260840161069a565b73ffffffffffffffffffffffffffffffffffffffff831660009081526020819052604081208383039055600280548492906112d9908490611686565b909155505060405182815260009073ffffffffffffffffffffffffffffffffffffffff8516907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef90602001610b50565b60006020828403121561133b57600080fd5b81357fffffffff000000000000000000000000000000000000000000000000000000008116811461136b57600080fd5b9392505050565b60005b8381101561138d578181015183820152602001611375565b83811115610c2e5750506000910152565b60208152600082518060208401526113bd816040850160208701611372565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169190910160400192915050565b803573ffffffffffffffffffffffffffffffffffffffff8116811461141357600080fd5b919050565b6000806040838503121561142b57600080fd5b611434836113ef565b946020939093013593505050565b60008060006060848603121561145757600080fd5b611460846113ef565b925061146e602085016113ef565b9150604084013590509250925092565b60006020828403121561149057600080fd5b61136b826113ef565b600080604083850312156114ac57600080fd5b6114b5836113ef565b91506114c3602084016113ef565b90509250929050565b600181811c908216806114e057607f821691505b602082108103611519577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600082198211156115615761156161151f565b500190565b60008451611578818460208901611372565b80830190507f2e0000000000000000000000000000000000000000000000000000000000000080825285516115b4816001850160208a01611372565b600192019182015283516115cf816002840160208801611372565b0160020195945050505050565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361160d5761160d61151f565b5060010190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b60008261165257611652611614565b500490565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6000828210156116985761169861151f565b500390565b6000826116ac576116ac611614565b500690565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fdfea164736f6c634300080f000aa164736f6c634300080f000a" +var OptimismMintableERC20FactoryDeployedBin = "0x60806040523480156200001157600080fd5b5060043610620000875760003560e01c8063c4d66de81162000062578063c4d66de81462000135578063ce5ac90f146200014e578063e78cea921462000165578063ee9a31a2146200018c57600080fd5b806354fd4d50146200008c578063896f93d114620000e15780638cf0629c146200011e575b600080fd5b620000c96040518060400160405280600581526020017f312e372e3000000000000000000000000000000000000000000000000000000081525081565b604051620000d89190620005d1565b60405180910390f35b620000f8620000f2366004620006f9565b620001b1565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001620000d8565b620000f86200012f36600462000776565b620001c8565b6200014c620001463660046200080d565b620003c6565b005b620000f86200015f366004620006f9565b62000544565b600054620000f89062010000900473ffffffffffffffffffffffffffffffffffffffff1681565b60005462010000900473ffffffffffffffffffffffffffffffffffffffff16620000f8565b6000620001c084848462000544565b949350505050565b600073ffffffffffffffffffffffffffffffffffffffff851662000273576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603f60248201527f4f7074696d69736d4d696e7461626c654552433230466163746f72793a206d7560448201527f73742070726f766964652072656d6f746520746f6b656e20616464726573730060648201526084015b60405180910390fd5b6000858585856040516020016200028e94939291906200082b565b604051602081830303815290604052805190602001209050600081600060029054906101000a900473ffffffffffffffffffffffffffffffffffffffff1688888888604051620002de9062000555565b620002ee95949392919062000885565b8190604051809103906000f59050801580156200030f573d6000803e3d6000fd5b5090508073ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff167fceeb8e7d520d7f3b65fc11a262b91066940193b05d4f93df07cfdced0eb551cf60405160405180910390a360405133815273ffffffffffffffffffffffffffffffffffffffff80891691908316907f52fe89dd5930f343d25650b62fd367bae47088bcddffd2a88350a6ecdd620cdb9060200160405180910390a39695505050505050565b600054600390610100900460ff16158015620003e9575060005460ff8083169116105b62000477576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a656400000000000000000000000000000000000060648201526084016200026a565b6000805461010060ff84167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00009092168217177fffffffffffffffffffff000000000000000000000000000000000000000000ff167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff6201000073ffffffffffffffffffffffffffffffffffffffff87160216179091556040519081527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15050565b6000620001c08484846012620001c8565b61178a80620008eb83390190565b6000815180845260005b818110156200058b576020818501810151868301820152016200056d565b818111156200059e576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b602081526000620005e6602083018462000563565b9392505050565b803573ffffffffffffffffffffffffffffffffffffffff811681146200061257600080fd5b919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b600082601f8301126200065857600080fd5b813567ffffffffffffffff8082111562000676576200067662000617565b604051601f83017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f01168101908282118183101715620006bf57620006bf62000617565b81604052838152866020858801011115620006d957600080fd5b836020870160208301376000602085830101528094505050505092915050565b6000806000606084860312156200070f57600080fd5b6200071a84620005ed565b9250602084013567ffffffffffffffff808211156200073857600080fd5b620007468783880162000646565b935060408601359150808211156200075d57600080fd5b506200076c8682870162000646565b9150509250925092565b600080600080608085870312156200078d57600080fd5b6200079885620005ed565b9350602085013567ffffffffffffffff80821115620007b657600080fd5b620007c48883890162000646565b94506040870135915080821115620007db57600080fd5b50620007ea8782880162000646565b925050606085013560ff811681146200080257600080fd5b939692955090935050565b6000602082840312156200082057600080fd5b620005e682620005ed565b73ffffffffffffffffffffffffffffffffffffffff851681526080602082015260006200085c608083018662000563565b828103604084015262000870818662000563565b91505060ff8316606083015295945050505050565b600073ffffffffffffffffffffffffffffffffffffffff808816835280871660208401525060a06040830152620008c060a083018662000563565b8281036060840152620008d4818662000563565b91505060ff83166080830152969550505050505056fe60e06040523480156200001157600080fd5b506040516200178a3803806200178a833981016040819052620000349162000163565b828260036200004483826200029e565b5060046200005382826200029e565b5050506001600160a01b039384166080529390921660a052505060ff1660c0526200036a565b80516001600160a01b03811681146200009157600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b600082601f830112620000be57600080fd5b81516001600160401b0380821115620000db57620000db62000096565b604051601f8301601f19908116603f0116810190828211818310171562000106576200010662000096565b816040528381526020925086838588010111156200012357600080fd5b600091505b8382101562000147578582018301518183018401529082019062000128565b83821115620001595760008385830101525b9695505050505050565b600080600080600060a086880312156200017c57600080fd5b620001878662000079565b9450620001976020870162000079565b60408701519094506001600160401b0380821115620001b557600080fd5b620001c389838a01620000ac565b94506060880151915080821115620001da57600080fd5b50620001e988828901620000ac565b925050608086015160ff811681146200020157600080fd5b809150509295509295909350565b600181811c908216806200022457607f821691505b6020821081036200024557634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200029957600081815260208120601f850160051c81016020861015620002745750805b601f850160051c820191505b81811015620002955782815560010162000280565b5050505b505050565b81516001600160401b03811115620002ba57620002ba62000096565b620002d281620002cb84546200020f565b846200024b565b602080601f8311600181146200030a5760008415620002f15750858301515b600019600386901b1c1916600185901b17855562000295565b600085815260208120601f198616915b828110156200033b578886015182559484019460019091019084016200031a565b50858210156200035a5787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b60805160a05160c0516113d4620003b6600039600061024401526000818161034b015281816103e001528181610625015261075c0152600081816101a9015261037101526113d46000f3fe608060405234801561001057600080fd5b50600436106101775760003560e01c806370a08231116100d8578063ae1f6aaf1161008c578063dd62ed3e11610066578063dd62ed3e14610395578063e78cea9214610349578063ee9a31a2146103db57600080fd5b8063ae1f6aaf14610349578063c01e1bd61461036f578063d6c0b2c41461036f57600080fd5b80639dc29fac116100bd5780639dc29fac14610310578063a457c2d714610323578063a9059cbb1461033657600080fd5b806370a08231146102d257806395d89b411461030857600080fd5b806323b872dd1161012f5780633950935111610114578063395093511461026e57806340c10f191461028157806354fd4d501461029657600080fd5b806323b872dd1461022a578063313ce5671461023d57600080fd5b806306fdde031161016057806306fdde03146101f0578063095ea7b31461020557806318160ddd1461021857600080fd5b806301ffc9a71461017c578063033964be146101a4575b600080fd5b61018f61018a36600461117d565b610402565b60405190151581526020015b60405180910390f35b6101cb7f000000000000000000000000000000000000000000000000000000000000000081565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161019b565b6101f86104f3565b60405161019b91906111c6565b61018f610213366004611262565b610585565b6002545b60405190815260200161019b565b61018f61023836600461128c565b61059d565b60405160ff7f000000000000000000000000000000000000000000000000000000000000000016815260200161019b565b61018f61027c366004611262565b6105c1565b61029461028f366004611262565b61060d565b005b6101f86040518060400160405280600581526020017f312e332e3000000000000000000000000000000000000000000000000000000081525081565b61021c6102e03660046112c8565b73ffffffffffffffffffffffffffffffffffffffff1660009081526020819052604090205490565b6101f8610735565b61029461031e366004611262565b610744565b61018f610331366004611262565b61085b565b61018f610344366004611262565b61092c565b7f00000000000000000000000000000000000000000000000000000000000000006101cb565b7f00000000000000000000000000000000000000000000000000000000000000006101cb565b61021c6103a33660046112e3565b73ffffffffffffffffffffffffffffffffffffffff918216600090815260016020908152604080832093909416825291909152205490565b6101cb7f000000000000000000000000000000000000000000000000000000000000000081565b60007f01ffc9a7000000000000000000000000000000000000000000000000000000007f1d1d8b63000000000000000000000000000000000000000000000000000000007fec4fc8e3000000000000000000000000000000000000000000000000000000007fffffffff0000000000000000000000000000000000000000000000000000000085168314806104bb57507fffffffff00000000000000000000000000000000000000000000000000000000858116908316145b806104ea57507fffffffff00000000000000000000000000000000000000000000000000000000858116908216145b95945050505050565b60606003805461050290611316565b80601f016020809104026020016040519081016040528092919081815260200182805461052e90611316565b801561057b5780601f106105505761010080835404028352916020019161057b565b820191906000526020600020905b81548152906001019060200180831161055e57829003601f168201915b5050505050905090565b60003361059381858561093a565b5060019392505050565b6000336105ab858285610aee565b6105b6858585610bc5565b506001949350505050565b33600081815260016020908152604080832073ffffffffffffffffffffffffffffffffffffffff871684529091528120549091906105939082908690610608908790611398565b61093a565b3373ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016146106d7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603460248201527f4f7074696d69736d4d696e7461626c6545524332303a206f6e6c79206272696460448201527f67652063616e206d696e7420616e64206275726e00000000000000000000000060648201526084015b60405180910390fd5b6106e18282610e78565b8173ffffffffffffffffffffffffffffffffffffffff167f0f6798a560793a54c3bcfe86a93cde1e73087d944c0ea20544137d41213968858260405161072991815260200190565b60405180910390a25050565b60606004805461050290611316565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610809576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603460248201527f4f7074696d69736d4d696e7461626c6545524332303a206f6e6c79206272696460448201527f67652063616e206d696e7420616e64206275726e00000000000000000000000060648201526084016106ce565b6108138282610f98565b8173ffffffffffffffffffffffffffffffffffffffff167fcc16f5dbb4873280815c1ee09dbd06736cffcc184412cf7a71a0fdb75d397ca58260405161072991815260200190565b33600081815260016020908152604080832073ffffffffffffffffffffffffffffffffffffffff871684529091528120549091908381101561091f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602560248201527f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f7760448201527f207a65726f00000000000000000000000000000000000000000000000000000060648201526084016106ce565b6105b6828686840361093a565b600033610593818585610bc5565b73ffffffffffffffffffffffffffffffffffffffff83166109dc576040517f08c379a0000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f45524332303a20617070726f76652066726f6d20746865207a65726f2061646460448201527f726573730000000000000000000000000000000000000000000000000000000060648201526084016106ce565b73ffffffffffffffffffffffffffffffffffffffff8216610a7f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602260248201527f45524332303a20617070726f766520746f20746865207a65726f20616464726560448201527f737300000000000000000000000000000000000000000000000000000000000060648201526084016106ce565b73ffffffffffffffffffffffffffffffffffffffff83811660008181526001602090815260408083209487168084529482529182902085905590518481527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92591015b60405180910390a3505050565b73ffffffffffffffffffffffffffffffffffffffff8381166000908152600160209081526040808320938616835292905220547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8114610bbf5781811015610bb2576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f45524332303a20696e73756666696369656e7420616c6c6f77616e636500000060448201526064016106ce565b610bbf848484840361093a565b50505050565b73ffffffffffffffffffffffffffffffffffffffff8316610c68576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602560248201527f45524332303a207472616e736665722066726f6d20746865207a65726f20616460448201527f647265737300000000000000000000000000000000000000000000000000000060648201526084016106ce565b73ffffffffffffffffffffffffffffffffffffffff8216610d0b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260448201527f657373000000000000000000000000000000000000000000000000000000000060648201526084016106ce565b73ffffffffffffffffffffffffffffffffffffffff831660009081526020819052604090205481811015610dc1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f45524332303a207472616e7366657220616d6f756e742065786365656473206260448201527f616c616e6365000000000000000000000000000000000000000000000000000060648201526084016106ce565b73ffffffffffffffffffffffffffffffffffffffff808516600090815260208190526040808220858503905591851681529081208054849290610e05908490611398565b925050819055508273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef84604051610e6b91815260200190565b60405180910390a3610bbf565b73ffffffffffffffffffffffffffffffffffffffff8216610ef5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f20616464726573730060448201526064016106ce565b8060026000828254610f079190611398565b909155505073ffffffffffffffffffffffffffffffffffffffff821660009081526020819052604081208054839290610f41908490611398565b909155505060405181815273ffffffffffffffffffffffffffffffffffffffff8316906000907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef9060200160405180910390a35050565b73ffffffffffffffffffffffffffffffffffffffff821661103b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602160248201527f45524332303a206275726e2066726f6d20746865207a65726f2061646472657360448201527f730000000000000000000000000000000000000000000000000000000000000060648201526084016106ce565b73ffffffffffffffffffffffffffffffffffffffff8216600090815260208190526040902054818110156110f1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602260248201527f45524332303a206275726e20616d6f756e7420657863656564732062616c616e60448201527f636500000000000000000000000000000000000000000000000000000000000060648201526084016106ce565b73ffffffffffffffffffffffffffffffffffffffff8316600090815260208190526040812083830390556002805484929061112d9084906113b0565b909155505060405182815260009073ffffffffffffffffffffffffffffffffffffffff8516907fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef90602001610ae1565b60006020828403121561118f57600080fd5b81357fffffffff00000000000000000000000000000000000000000000000000000000811681146111bf57600080fd5b9392505050565b600060208083528351808285015260005b818110156111f3578581018301518582016040015282016111d7565b81811115611205576000604083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016929092016040019392505050565b803573ffffffffffffffffffffffffffffffffffffffff8116811461125d57600080fd5b919050565b6000806040838503121561127557600080fd5b61127e83611239565b946020939093013593505050565b6000806000606084860312156112a157600080fd5b6112aa84611239565b92506112b860208501611239565b9150604084013590509250925092565b6000602082840312156112da57600080fd5b6111bf82611239565b600080604083850312156112f657600080fd5b6112ff83611239565b915061130d60208401611239565b90509250929050565b600181811c9082168061132a57607f821691505b602082108103611363577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600082198211156113ab576113ab611369565b500190565b6000828210156113c2576113c2611369565b50039056fea164736f6c634300080f000aa164736f6c634300080f000a" func init() { if err := json.Unmarshal([]byte(OptimismMintableERC20FactoryStorageLayoutJSON), OptimismMintableERC20FactoryStorageLayout); err != nil { diff --git a/op-bindings/bindings/preimageoracle.go b/op-bindings/bindings/preimageoracle.go index fd34e81b3bceb..1a2e196af20d0 100644 --- a/op-bindings/bindings/preimageoracle.go +++ b/op-bindings/bindings/preimageoracle.go @@ -30,8 +30,8 @@ var ( // PreimageOracleMetaData contains all meta data concerning the PreimageOracle contract. var PreimageOracleMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[],\"name\":\"PartOffsetOOB\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_partOffset\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"_preimage\",\"type\":\"bytes\"}],\"name\":\"loadKeccak256PreimagePart\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_ident\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"_word\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"_size\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_partOffset\",\"type\":\"uint256\"}],\"name\":\"loadLocalData\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"key_\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"preimageLengths\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"preimagePartOk\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"preimageParts\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"_key\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"_offset\",\"type\":\"uint256\"}],\"name\":\"readPreimage\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"dat_\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"datLen_\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", - Bin: "0x608060405234801561001057600080fd5b50610625806100206000396000f3fe608060405234801561001057600080fd5b50600436106100725760003560e01c8063e03110e111610050578063e03110e114610106578063e15926111461012e578063fef2b4ed1461014357600080fd5b806361238bde146100775780638542cf50146100b55780639a1f5e7f146100f3575b600080fd5b6100a26100853660046104d1565b600160209081526000928352604080842090915290825290205481565b6040519081526020015b60405180910390f35b6100e36100c33660046104d1565b600260209081526000928352604080842090915290825290205460ff1681565b60405190151581526020016100ac565b6100a26101013660046104f3565b610163565b6101196101143660046104d1565b610236565b604080519283526020830191909152016100ac565b61014161013c366004610525565b610327565b005b6100a26101513660046105a1565b60006020819052908152604090205481565b600061016e85610430565b905061017b8360086105e9565b8211806101885750602083115b156101bf576040517ffe25498700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000602081815260c085901b82526008959095528251828252600286526040808320858452875280832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600190811790915584845287528083209483529386528382205581815293849052922055919050565b6000828152600260209081526040808320848452909152812054819060ff166102bf576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f7072652d696d616765206d757374206578697374000000000000000000000000604482015260640160405180910390fd5b50600083815260208181526040909120546102db8160086105e9565b6102e68560206105e9565b1061030457836102f78260086105e9565b6103019190610601565b91505b506000938452600160209081526040808620948652939052919092205492909150565b604435600080600883018611156103465763fe2549876000526004601cfd5b60c083901b6080526088838682378087017ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff80151908490207effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f02000000000000000000000000000000000000000000000000000000000000001760008181526002602090815260408083208b8452825280832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600190811790915584845282528083209a83529981528982209390935590815290819052959095209190915550505050565b7f01000000000000000000000000000000000000000000000000000000000000007effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8216176104cb81600090815233602052604090207effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f01000000000000000000000000000000000000000000000000000000000000001790565b92915050565b600080604083850312156104e457600080fd5b50508035926020909101359150565b6000806000806080858703121561050957600080fd5b5050823594602084013594506040840135936060013592509050565b60008060006040848603121561053a57600080fd5b83359250602084013567ffffffffffffffff8082111561055957600080fd5b818601915086601f83011261056d57600080fd5b81358181111561057c57600080fd5b87602082850101111561058e57600080fd5b6020830194508093505050509250925092565b6000602082840312156105b357600080fd5b5035919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600082198211156105fc576105fc6105ba565b500190565b600082821015610613576106136105ba565b50039056fea164736f6c634300080f000a", + ABI: "[{\"inputs\":[],\"name\":\"PartOffsetOOB\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_partOffset\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"_preimage\",\"type\":\"bytes\"}],\"name\":\"loadKeccak256PreimagePart\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_ident\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_localContext\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"_word\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"_size\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_partOffset\",\"type\":\"uint256\"}],\"name\":\"loadLocalData\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"key_\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"preimageLengths\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"preimagePartOk\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"preimageParts\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"_key\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"_offset\",\"type\":\"uint256\"}],\"name\":\"readPreimage\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"dat_\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"datLen_\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", + Bin: "0x608060405234801561001057600080fd5b5061063c806100206000396000f3fe608060405234801561001057600080fd5b50600436106100725760003560e01c8063e03110e111610050578063e03110e114610106578063e15926111461012e578063fef2b4ed1461014357600080fd5b806361238bde146100775780638542cf50146100b5578063c0c220c9146100f3575b600080fd5b6100a26100853660046104df565b600160209081526000928352604080842090915290825290205481565b6040519081526020015b60405180910390f35b6100e36100c33660046104df565b600260209081526000928352604080842090915290825290205460ff1681565b60405190151581526020016100ac565b6100a2610101366004610501565b610163565b6101196101143660046104df565b610238565b604080519283526020830191909152016100ac565b61014161013c36600461053c565b610329565b005b6100a26101513660046105b8565b60006020819052908152604090205481565b600061016f8686610432565b905061017c836008610600565b8211806101895750602083115b156101c0576040517ffe25498700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000602081815260c085901b82526008959095528251828252600286526040808320858452875280832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660019081179091558484528752808320948352938652838220558181529384905292205592915050565b6000828152600260209081526040808320848452909152812054819060ff166102c1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f7072652d696d616765206d757374206578697374000000000000000000000000604482015260640160405180910390fd5b50600083815260208181526040909120546102dd816008610600565b6102e8856020610600565b1061030657836102f9826008610600565b6103039190610618565b91505b506000938452600160209081526040808620948652939052919092205492909150565b604435600080600883018611156103485763fe2549876000526004601cfd5b60c083901b6080526088838682378087017ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff80151908490207effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f02000000000000000000000000000000000000000000000000000000000000001760008181526002602090815260408083208b8452825280832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600190811790915584845282528083209a83529981528982209390935590815290819052959095209190915550505050565b7f01000000000000000000000000000000000000000000000000000000000000007effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8316176104d8818360408051600093845233602052918152606090922091527effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f01000000000000000000000000000000000000000000000000000000000000001790565b9392505050565b600080604083850312156104f257600080fd5b50508035926020909101359150565b600080600080600060a0868803121561051957600080fd5b505083359560208501359550604085013594606081013594506080013592509050565b60008060006040848603121561055157600080fd5b83359250602084013567ffffffffffffffff8082111561057057600080fd5b818601915086601f83011261058457600080fd5b81358181111561059357600080fd5b8760208285010111156105a557600080fd5b6020830194508093505050509250925092565b6000602082840312156105ca57600080fd5b5035919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60008219821115610613576106136105d1565b500190565b60008282101561062a5761062a6105d1565b50039056fea164736f6c634300080f000a", } // PreimageOracleABI is the input ABI used to generate the binding from. @@ -360,23 +360,23 @@ func (_PreimageOracle *PreimageOracleTransactorSession) LoadKeccak256PreimagePar return _PreimageOracle.Contract.LoadKeccak256PreimagePart(&_PreimageOracle.TransactOpts, _partOffset, _preimage) } -// LoadLocalData is a paid mutator transaction binding the contract method 0x9a1f5e7f. +// LoadLocalData is a paid mutator transaction binding the contract method 0xc0c220c9. // -// Solidity: function loadLocalData(uint256 _ident, bytes32 _word, uint256 _size, uint256 _partOffset) returns(bytes32 key_) -func (_PreimageOracle *PreimageOracleTransactor) LoadLocalData(opts *bind.TransactOpts, _ident *big.Int, _word [32]byte, _size *big.Int, _partOffset *big.Int) (*types.Transaction, error) { - return _PreimageOracle.contract.Transact(opts, "loadLocalData", _ident, _word, _size, _partOffset) +// Solidity: function loadLocalData(uint256 _ident, uint256 _localContext, bytes32 _word, uint256 _size, uint256 _partOffset) returns(bytes32 key_) +func (_PreimageOracle *PreimageOracleTransactor) LoadLocalData(opts *bind.TransactOpts, _ident *big.Int, _localContext *big.Int, _word [32]byte, _size *big.Int, _partOffset *big.Int) (*types.Transaction, error) { + return _PreimageOracle.contract.Transact(opts, "loadLocalData", _ident, _localContext, _word, _size, _partOffset) } -// LoadLocalData is a paid mutator transaction binding the contract method 0x9a1f5e7f. +// LoadLocalData is a paid mutator transaction binding the contract method 0xc0c220c9. // -// Solidity: function loadLocalData(uint256 _ident, bytes32 _word, uint256 _size, uint256 _partOffset) returns(bytes32 key_) -func (_PreimageOracle *PreimageOracleSession) LoadLocalData(_ident *big.Int, _word [32]byte, _size *big.Int, _partOffset *big.Int) (*types.Transaction, error) { - return _PreimageOracle.Contract.LoadLocalData(&_PreimageOracle.TransactOpts, _ident, _word, _size, _partOffset) +// Solidity: function loadLocalData(uint256 _ident, uint256 _localContext, bytes32 _word, uint256 _size, uint256 _partOffset) returns(bytes32 key_) +func (_PreimageOracle *PreimageOracleSession) LoadLocalData(_ident *big.Int, _localContext *big.Int, _word [32]byte, _size *big.Int, _partOffset *big.Int) (*types.Transaction, error) { + return _PreimageOracle.Contract.LoadLocalData(&_PreimageOracle.TransactOpts, _ident, _localContext, _word, _size, _partOffset) } -// LoadLocalData is a paid mutator transaction binding the contract method 0x9a1f5e7f. +// LoadLocalData is a paid mutator transaction binding the contract method 0xc0c220c9. // -// Solidity: function loadLocalData(uint256 _ident, bytes32 _word, uint256 _size, uint256 _partOffset) returns(bytes32 key_) -func (_PreimageOracle *PreimageOracleTransactorSession) LoadLocalData(_ident *big.Int, _word [32]byte, _size *big.Int, _partOffset *big.Int) (*types.Transaction, error) { - return _PreimageOracle.Contract.LoadLocalData(&_PreimageOracle.TransactOpts, _ident, _word, _size, _partOffset) +// Solidity: function loadLocalData(uint256 _ident, uint256 _localContext, bytes32 _word, uint256 _size, uint256 _partOffset) returns(bytes32 key_) +func (_PreimageOracle *PreimageOracleTransactorSession) LoadLocalData(_ident *big.Int, _localContext *big.Int, _word [32]byte, _size *big.Int, _partOffset *big.Int) (*types.Transaction, error) { + return _PreimageOracle.Contract.LoadLocalData(&_PreimageOracle.TransactOpts, _ident, _localContext, _word, _size, _partOffset) } diff --git a/op-bindings/bindings/preimageoracle_more.go b/op-bindings/bindings/preimageoracle_more.go index 6dd0f727e0dc3..5873170c26d66 100644 --- a/op-bindings/bindings/preimageoracle_more.go +++ b/op-bindings/bindings/preimageoracle_more.go @@ -13,9 +13,9 @@ const PreimageOracleStorageLayoutJSON = "{\"storage\":[{\"astId\":1000,\"contrac var PreimageOracleStorageLayout = new(solc.StorageLayout) -var PreimageOracleDeployedBin = "0x608060405234801561001057600080fd5b50600436106100725760003560e01c8063e03110e111610050578063e03110e114610106578063e15926111461012e578063fef2b4ed1461014357600080fd5b806361238bde146100775780638542cf50146100b55780639a1f5e7f146100f3575b600080fd5b6100a26100853660046104d1565b600160209081526000928352604080842090915290825290205481565b6040519081526020015b60405180910390f35b6100e36100c33660046104d1565b600260209081526000928352604080842090915290825290205460ff1681565b60405190151581526020016100ac565b6100a26101013660046104f3565b610163565b6101196101143660046104d1565b610236565b604080519283526020830191909152016100ac565b61014161013c366004610525565b610327565b005b6100a26101513660046105a1565b60006020819052908152604090205481565b600061016e85610430565b905061017b8360086105e9565b8211806101885750602083115b156101bf576040517ffe25498700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000602081815260c085901b82526008959095528251828252600286526040808320858452875280832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600190811790915584845287528083209483529386528382205581815293849052922055919050565b6000828152600260209081526040808320848452909152812054819060ff166102bf576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f7072652d696d616765206d757374206578697374000000000000000000000000604482015260640160405180910390fd5b50600083815260208181526040909120546102db8160086105e9565b6102e68560206105e9565b1061030457836102f78260086105e9565b6103019190610601565b91505b506000938452600160209081526040808620948652939052919092205492909150565b604435600080600883018611156103465763fe2549876000526004601cfd5b60c083901b6080526088838682378087017ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff80151908490207effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f02000000000000000000000000000000000000000000000000000000000000001760008181526002602090815260408083208b8452825280832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600190811790915584845282528083209a83529981528982209390935590815290819052959095209190915550505050565b7f01000000000000000000000000000000000000000000000000000000000000007effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8216176104cb81600090815233602052604090207effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f01000000000000000000000000000000000000000000000000000000000000001790565b92915050565b600080604083850312156104e457600080fd5b50508035926020909101359150565b6000806000806080858703121561050957600080fd5b5050823594602084013594506040840135936060013592509050565b60008060006040848603121561053a57600080fd5b83359250602084013567ffffffffffffffff8082111561055957600080fd5b818601915086601f83011261056d57600080fd5b81358181111561057c57600080fd5b87602082850101111561058e57600080fd5b6020830194508093505050509250925092565b6000602082840312156105b357600080fd5b5035919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600082198211156105fc576105fc6105ba565b500190565b600082821015610613576106136105ba565b50039056fea164736f6c634300080f000a" +var PreimageOracleDeployedBin = "0x608060405234801561001057600080fd5b50600436106100725760003560e01c8063e03110e111610050578063e03110e114610106578063e15926111461012e578063fef2b4ed1461014357600080fd5b806361238bde146100775780638542cf50146100b5578063c0c220c9146100f3575b600080fd5b6100a26100853660046104df565b600160209081526000928352604080842090915290825290205481565b6040519081526020015b60405180910390f35b6100e36100c33660046104df565b600260209081526000928352604080842090915290825290205460ff1681565b60405190151581526020016100ac565b6100a2610101366004610501565b610163565b6101196101143660046104df565b610238565b604080519283526020830191909152016100ac565b61014161013c36600461053c565b610329565b005b6100a26101513660046105b8565b60006020819052908152604090205481565b600061016f8686610432565b905061017c836008610600565b8211806101895750602083115b156101c0576040517ffe25498700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000602081815260c085901b82526008959095528251828252600286526040808320858452875280832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660019081179091558484528752808320948352938652838220558181529384905292205592915050565b6000828152600260209081526040808320848452909152812054819060ff166102c1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f7072652d696d616765206d757374206578697374000000000000000000000000604482015260640160405180910390fd5b50600083815260208181526040909120546102dd816008610600565b6102e8856020610600565b1061030657836102f9826008610600565b6103039190610618565b91505b506000938452600160209081526040808620948652939052919092205492909150565b604435600080600883018611156103485763fe2549876000526004601cfd5b60c083901b6080526088838682378087017ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff80151908490207effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f02000000000000000000000000000000000000000000000000000000000000001760008181526002602090815260408083208b8452825280832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600190811790915584845282528083209a83529981528982209390935590815290819052959095209190915550505050565b7f01000000000000000000000000000000000000000000000000000000000000007effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8316176104d8818360408051600093845233602052918152606090922091527effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167f01000000000000000000000000000000000000000000000000000000000000001790565b9392505050565b600080604083850312156104f257600080fd5b50508035926020909101359150565b600080600080600060a0868803121561051957600080fd5b505083359560208501359550604085013594606081013594506080013592509050565b60008060006040848603121561055157600080fd5b83359250602084013567ffffffffffffffff8082111561057057600080fd5b818601915086601f83011261058457600080fd5b81358181111561059357600080fd5b8760208285010111156105a557600080fd5b6020830194508093505050509250925092565b6000602082840312156105ca57600080fd5b5035919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60008219821115610613576106136105d1565b500190565b60008282101561062a5761062a6105d1565b50039056fea164736f6c634300080f000a" -var PreimageOracleDeployedSourceMap = "306:3865:130:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;537:68;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;413:25:286;;;401:2;386:18;537:68:130;;;;;;;;680:66;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;614:14:286;;607:22;589:41;;577:2;562:18;680:66:130;449:187:286;1367:1165:130;;;;;;:::i;:::-;;:::i;789:536::-;;;;;;:::i;:::-;;:::i;:::-;;;;1205:25:286;;;1261:2;1246:18;;1239:34;;;;1178:18;789:536:130;1031:248:286;2574:1595:130;;;;;;:::i;:::-;;:::i;:::-;;419:50;;;;;;:::i;:::-;;;;;;;;;;;;;;;1367:1165;1529:12;1634:36;1663:6;1634:28;:36::i;:::-;1627:43;-1:-1:-1;1764:9:130;:5;1772:1;1764:9;:::i;:::-;1750:11;:23;:37;;;;1785:2;1777:5;:10;1750:37;1746:90;;;1810:15;;;;;;;;;;;;;;1746:90;1905:12;2005:4;1998:18;;;2106:3;2102:15;;;2089:29;;2138:4;2131:19;;;;2240:18;;2330:20;;;:14;:20;;;;;;:33;;;;;;;;:40;;;;2366:4;2330:40;;;;;;2380:19;;;;;;;;:32;;;;;;;;;:39;2496:21;;;;;;;;;:29;2345:4;1367:1165;-1:-1:-1;1367:1165:130:o;789:536::-;865:12;914:20;;;:14;:20;;;;;;;;:29;;;;;;;;;865:12;;914:29;;906:62;;;;;;;2839:2:286;906:62:130;;;2821:21:286;2878:2;2858:18;;;2851:30;2917:22;2897:18;;;2890:50;2957:18;;906:62:130;;;;;;;;-1:-1:-1;1099:14:130;1116:21;;;1087:2;1116:21;;;;;;;;1167:10;1116:21;1176:1;1167:10;:::i;:::-;1151:12;:7;1161:2;1151:12;:::i;:::-;:26;1147:87;;1216:7;1203:10;:6;1212:1;1203:10;:::i;:::-;:20;;;;:::i;:::-;1193:30;;1147:87;-1:-1:-1;1290:19:130;;;;:13;:19;;;;;;;;:28;;;;;;;;;;;;789:536;;-1:-1:-1;789:536:130:o;2574:1595::-;2870:4;2857:18;2675:12;;2999:1;2989:12;;2973:29;;2970:210;;;3074:10;3071:1;3064:21;3164:1;3158:4;3151:15;2970:210;3423:3;3419:14;;;3323:4;3407:27;3454:11;3428:4;3573:16;3454:11;3555:41;3786:29;;;3790:11;3786:29;3780:36;3838:20;;;;3985:19;3978:27;4007:11;3975:44;4038:19;;;;4016:1;4038:19;;;;;;;;:32;;;;;;;;:39;;;;4073:4;4038:39;;;;;;4087:18;;;;;;;;:31;;;;;;;;;:38;;;;4135:20;;;;;;;;;;;:27;;;;-1:-1:-1;;;;2574:1595:130:o;492:353:129:-;752:11;777:19;765:32;;749:49;824:14;749:49;1277:21;1426:15;;;1467:8;1461:4;1454:22;1595:4;1582:18;;1602:19;1578:44;1624:11;1575:61;;1222:430;824:14;817:21;492:353;-1:-1:-1;;492:353:129:o;14:248:286:-;82:6;90;143:2;131:9;122:7;118:23;114:32;111:52;;;159:1;156;149:12;111:52;-1:-1:-1;;182:23:286;;;252:2;237:18;;;224:32;;-1:-1:-1;14:248:286:o;641:385::-;727:6;735;743;751;804:3;792:9;783:7;779:23;775:33;772:53;;;821:1;818;811:12;772:53;-1:-1:-1;;844:23:286;;;914:2;899:18;;886:32;;-1:-1:-1;965:2:286;950:18;;937:32;;1016:2;1001:18;988:32;;-1:-1:-1;641:385:286;-1:-1:-1;641:385:286:o;1284:659::-;1363:6;1371;1379;1432:2;1420:9;1411:7;1407:23;1403:32;1400:52;;;1448:1;1445;1438:12;1400:52;1484:9;1471:23;1461:33;;1545:2;1534:9;1530:18;1517:32;1568:18;1609:2;1601:6;1598:14;1595:34;;;1625:1;1622;1615:12;1595:34;1663:6;1652:9;1648:22;1638:32;;1708:7;1701:4;1697:2;1693:13;1689:27;1679:55;;1730:1;1727;1720:12;1679:55;1770:2;1757:16;1796:2;1788:6;1785:14;1782:34;;;1812:1;1809;1802:12;1782:34;1857:7;1852:2;1843:6;1839:2;1835:15;1831:24;1828:37;1825:57;;;1878:1;1875;1868:12;1825:57;1909:2;1905;1901:11;1891:21;;1931:6;1921:16;;;;;1284:659;;;;;:::o;1948:180::-;2007:6;2060:2;2048:9;2039:7;2035:23;2031:32;2028:52;;;2076:1;2073;2066:12;2028:52;-1:-1:-1;2099:23:286;;1948:180;-1:-1:-1;1948:180:286:o;2315:184::-;2367:77;2364:1;2357:88;2464:4;2461:1;2454:15;2488:4;2485:1;2478:15;2504:128;2544:3;2575:1;2571:6;2568:1;2565:13;2562:39;;;2581:18;;:::i;:::-;-1:-1:-1;2617:9:286;;2504:128::o;2986:125::-;3026:4;3054:1;3051;3048:8;3045:34;;;3059:18;;:::i;:::-;-1:-1:-1;3096:9:286;;2986:125::o" +var PreimageOracleDeployedSourceMap = "306:3911:140:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;537:68;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;413:25:311;;;401:2;386:18;537:68:140;;;;;;;;680:66;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;614:14:311;;607:22;589:41;;577:2;562:18;680:66:140;449:187:311;1367:1211:140;;;;;;:::i;:::-;;:::i;789:536::-;;;;;;:::i;:::-;;:::i;:::-;;;;1274:25:311;;;1330:2;1315:18;;1308:34;;;;1247:18;789:536:140;1100:248:311;2620:1595:140;;;;;;:::i;:::-;;:::i;:::-;;419:50;;;;;;:::i;:::-;;;;;;;;;;;;;;;1367:1211;1560:12;1665:51;1694:6;1702:13;1665:28;:51::i;:::-;1658:58;-1:-1:-1;1810:9:140;:5;1818:1;1810:9;:::i;:::-;1796:11;:23;:37;;;;1831:2;1823:5;:10;1796:37;1792:90;;;1856:15;;;;;;;;;;;;;;1792:90;1951:12;2051:4;2044:18;;;2152:3;2148:15;;;2135:29;;2184:4;2177:19;;;;2286:18;;2376:20;;;:14;:20;;;;;;:33;;;;;;;;:40;;;;2412:4;2376:40;;;;;;2426:19;;;;;;;;:32;;;;;;;;;:39;2542:21;;;;;;;;;:29;2391:4;1367:1211;-1:-1:-1;;1367:1211:140:o;789:536::-;865:12;914:20;;;:14;:20;;;;;;;;:29;;;;;;;;;865:12;;914:29;;906:62;;;;;;;2908:2:311;906:62:140;;;2890:21:311;2947:2;2927:18;;;2920:30;2986:22;2966:18;;;2959:50;3026:18;;906:62:140;;;;;;;;-1:-1:-1;1099:14:140;1116:21;;;1087:2;1116:21;;;;;;;;1167:10;1116:21;1176:1;1167:10;:::i;:::-;1151:12;:7;1161:2;1151:12;:::i;:::-;:26;1147:87;;1216:7;1203:10;:6;1212:1;1203:10;:::i;:::-;:20;;;;:::i;:::-;1193:30;;1147:87;-1:-1:-1;1290:19:140;;;;:13;:19;;;;;;;;:28;;;;;;;;;;;;789:536;;-1:-1:-1;789:536:140:o;2620:1595::-;2916:4;2903:18;2721:12;;3045:1;3035:12;;3019:29;;3016:210;;;3120:10;3117:1;3110:21;3210:1;3204:4;3197:15;3016:210;3469:3;3465:14;;;3369:4;3453:27;3500:11;3474:4;3619:16;3500:11;3601:41;3832:29;;;3836:11;3832:29;3826:36;3884:20;;;;4031:19;4024:27;4053:11;4021:44;4084:19;;;;4062:1;4084:19;;;;;;;;:32;;;;;;;;:39;;;;4119:4;4084:39;;;;;;4133:18;;;;;;;;:31;;;;;;;;;:38;;;;4181:20;;;;;;;;;;;:27;;;;-1:-1:-1;;;;2620:1595:140:o;552:449:139:-;835:11;860:19;848:32;;832:49;965:29;832:49;980:13;1676:4;1670:11;;1533:21;1787:15;;;1828:8;1822:4;1815:22;1850:27;;;1996:4;1983:18;;;2098:17;;2003:19;1979:44;2025:11;1976:61;;1455:676;965:29;958:36;552:449;-1:-1:-1;;;552:449:139:o;14:248:311:-;82:6;90;143:2;131:9;122:7;118:23;114:32;111:52;;;159:1;156;149:12;111:52;-1:-1:-1;;182:23:311;;;252:2;237:18;;;224:32;;-1:-1:-1;14:248:311:o;641:454::-;736:6;744;752;760;768;821:3;809:9;800:7;796:23;792:33;789:53;;;838:1;835;828:12;789:53;-1:-1:-1;;861:23:311;;;931:2;916:18;;903:32;;-1:-1:-1;982:2:311;967:18;;954:32;;1033:2;1018:18;;1005:32;;-1:-1:-1;1084:3:311;1069:19;1056:33;;-1:-1:-1;641:454:311;-1:-1:-1;641:454:311:o;1353:659::-;1432:6;1440;1448;1501:2;1489:9;1480:7;1476:23;1472:32;1469:52;;;1517:1;1514;1507:12;1469:52;1553:9;1540:23;1530:33;;1614:2;1603:9;1599:18;1586:32;1637:18;1678:2;1670:6;1667:14;1664:34;;;1694:1;1691;1684:12;1664:34;1732:6;1721:9;1717:22;1707:32;;1777:7;1770:4;1766:2;1762:13;1758:27;1748:55;;1799:1;1796;1789:12;1748:55;1839:2;1826:16;1865:2;1857:6;1854:14;1851:34;;;1881:1;1878;1871:12;1851:34;1926:7;1921:2;1912:6;1908:2;1904:15;1900:24;1897:37;1894:57;;;1947:1;1944;1937:12;1894:57;1978:2;1974;1970:11;1960:21;;2000:6;1990:16;;;;;1353:659;;;;;:::o;2017:180::-;2076:6;2129:2;2117:9;2108:7;2104:23;2100:32;2097:52;;;2145:1;2142;2135:12;2097:52;-1:-1:-1;2168:23:311;;2017:180;-1:-1:-1;2017:180:311:o;2384:184::-;2436:77;2433:1;2426:88;2533:4;2530:1;2523:15;2557:4;2554:1;2547:15;2573:128;2613:3;2644:1;2640:6;2637:1;2634:13;2631:39;;;2650:18;;:::i;:::-;-1:-1:-1;2686:9:311;;2573:128::o;3055:125::-;3095:4;3123:1;3120;3117:8;3114:34;;;3128:18;;:::i;:::-;-1:-1:-1;3165:9:311;;3055:125::o" func init() { if err := json.Unmarshal([]byte(PreimageOracleStorageLayoutJSON), PreimageOracleStorageLayout); err != nil { diff --git a/op-bindings/bindings/sequencerfeevault.go b/op-bindings/bindings/sequencerfeevault.go index 02eb3283fcbbb..10c70e4e1aa87 100644 --- a/op-bindings/bindings/sequencerfeevault.go +++ b/op-bindings/bindings/sequencerfeevault.go @@ -31,7 +31,7 @@ var ( // SequencerFeeVaultMetaData contains all meta data concerning the SequencerFeeVault contract. var SequencerFeeVaultMetaData = &bind.MetaData{ ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_recipient\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_minWithdrawalAmount\",\"type\":\"uint256\"},{\"internalType\":\"enumFeeVault.WithdrawalNetwork\",\"name\":\"_withdrawalNetwork\",\"type\":\"uint8\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"}],\"name\":\"Withdrawal\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"enumFeeVault.WithdrawalNetwork\",\"name\":\"withdrawalNetwork\",\"type\":\"uint8\"}],\"name\":\"Withdrawal\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MIN_WITHDRAWAL_AMOUNT\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"RECIPIENT\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"WITHDRAWAL_NETWORK\",\"outputs\":[{\"internalType\":\"enumFeeVault.WithdrawalNetwork\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"l1FeeWallet\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"totalProcessed\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"version\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"withdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"stateMutability\":\"payable\",\"type\":\"receive\"}]", - Bin: "0x60e060405234801561001057600080fd5b5060405161091638038061091683398101604081905261002f91610079565b6001600160a01b03831660a0526080829052828282806001811115610056576100566100cc565b60c081600181111561006a5761006a6100cc565b815250505050505050506100e2565b60008060006060848603121561008e57600080fd5b83516001600160a01b03811681146100a557600080fd5b602085015160408601519194509250600281106100c157600080fd5b809150509250925092565b634e487b7160e01b600052602160045260246000fd5b60805160a05160c0516107ce61014860003960008181610181015281816103c701526104020152600081816092015281816101f301528181610316015281816103a50152818161043b01526105a20152600081816101c2015261021901526107ce6000f3fe6080604052600436106100745760003560e01c806384411d651161004e57806384411d651461014b578063d0e12f901461016f578063d3e5792b146101b0578063d4ff9218146101e457600080fd5b80630d9019e1146100805780633ccfd60b146100de57806354fd4d50146100f557600080fd5b3661007b57005b600080fd5b34801561008c57600080fd5b506100b47f000000000000000000000000000000000000000000000000000000000000000081565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b3480156100ea57600080fd5b506100f3610217565b005b34801561010157600080fd5b5061013e6040518060400160405280600581526020017f312e342e3000000000000000000000000000000000000000000000000000000081525081565b6040516100d5919061066e565b34801561015757600080fd5b5061016160005481565b6040519081526020016100d5565b34801561017b57600080fd5b506101a37f000000000000000000000000000000000000000000000000000000000000000081565b6040516100d591906106f2565b3480156101bc57600080fd5b506101617f000000000000000000000000000000000000000000000000000000000000000081565b3480156101f057600080fd5b507f00000000000000000000000000000000000000000000000000000000000000006100b4565b7f00000000000000000000000000000000000000000000000000000000000000004710156102f2576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604a60248201527f4665655661756c743a207769746864726177616c20616d6f756e74206d75737460448201527f2062652067726561746572207468616e206d696e696d756d207769746864726160648201527f77616c20616d6f756e7400000000000000000000000000000000000000000000608482015260a4015b60405180910390fd5b6000479050806000808282546103089190610706565b9091555050604080518281527f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff166020820152338183015290517fc8a211cc64b6ed1b50595a9fcb1932b6d1e5a6e8ef15b60e5b1f988ea9086bba9181900360600190a17f38e04cbeb8c10f8f568618aa75be0f10b6729b8b4237743b4de20cbcde2839ee817f0000000000000000000000000000000000000000000000000000000000000000337f00000000000000000000000000000000000000000000000000000000000000006040516103f69493929190610745565b60405180910390a160017f0000000000000000000000000000000000000000000000000000000000000000600181111561043257610432610688565b0361054b5760007f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff168260405160006040518083038185875af1925050503d80600081146104b1576040519150601f19603f3d011682016040523d82523d6000602084013e6104b6565b606091505b5050905080610547576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603060248201527f4665655661756c743a206661696c656420746f2073656e642045544820746f2060448201527f4c322066656520726563697069656e740000000000000000000000000000000060648201526084016102e9565b5050565b604080516020810182526000815290517fe11013dd0000000000000000000000000000000000000000000000000000000081527342000000000000000000000000000000000000109163e11013dd9184916105ce917f0000000000000000000000000000000000000000000000000000000000000000916188b891600401610786565b6000604051808303818588803b1580156105e757600080fd5b505af11580156105fb573d6000803e3d6000fd5b505050505050565b6000815180845260005b818110156106295760208185018101518683018201520161060d565b8181111561063b576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b6020815260006106816020830184610603565b9392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b600281106106ee577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b9052565b6020810161070082846106b7565b92915050565b60008219821115610740577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b500190565b84815273ffffffffffffffffffffffffffffffffffffffff8481166020830152831660408201526080810161077d60608301846106b7565b95945050505050565b73ffffffffffffffffffffffffffffffffffffffff8416815263ffffffff8316602082015260606040820152600061077d606083018461060356fea164736f6c634300080f000a", + Bin: "0x60e060405234801561001057600080fd5b5060405161091638038061091683398101604081905261002f91610079565b6001600160a01b03831660a0526080829052828282806001811115610056576100566100cc565b60c081600181111561006a5761006a6100cc565b815250505050505050506100e2565b60008060006060848603121561008e57600080fd5b83516001600160a01b03811681146100a557600080fd5b602085015160408601519194509250600281106100c157600080fd5b809150509250925092565b634e487b7160e01b600052602160045260246000fd5b60805160a05160c0516107ce61014860003960008181610181015281816103c701526104020152600081816092015281816101f301528181610316015281816103a50152818161043b01526105a20152600081816101c2015261021901526107ce6000f3fe6080604052600436106100745760003560e01c806384411d651161004e57806384411d651461014b578063d0e12f901461016f578063d3e5792b146101b0578063d4ff9218146101e457600080fd5b80630d9019e1146100805780633ccfd60b146100de57806354fd4d50146100f557600080fd5b3661007b57005b600080fd5b34801561008c57600080fd5b506100b47f000000000000000000000000000000000000000000000000000000000000000081565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b3480156100ea57600080fd5b506100f3610217565b005b34801561010157600080fd5b5061013e6040518060400160405280600581526020017f312e342e3100000000000000000000000000000000000000000000000000000081525081565b6040516100d5919061066e565b34801561015757600080fd5b5061016160005481565b6040519081526020016100d5565b34801561017b57600080fd5b506101a37f000000000000000000000000000000000000000000000000000000000000000081565b6040516100d591906106f2565b3480156101bc57600080fd5b506101617f000000000000000000000000000000000000000000000000000000000000000081565b3480156101f057600080fd5b507f00000000000000000000000000000000000000000000000000000000000000006100b4565b7f00000000000000000000000000000000000000000000000000000000000000004710156102f2576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604a60248201527f4665655661756c743a207769746864726177616c20616d6f756e74206d75737460448201527f2062652067726561746572207468616e206d696e696d756d207769746864726160648201527f77616c20616d6f756e7400000000000000000000000000000000000000000000608482015260a4015b60405180910390fd5b6000479050806000808282546103089190610706565b9091555050604080518281527f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff166020820152338183015290517fc8a211cc64b6ed1b50595a9fcb1932b6d1e5a6e8ef15b60e5b1f988ea9086bba9181900360600190a17f38e04cbeb8c10f8f568618aa75be0f10b6729b8b4237743b4de20cbcde2839ee817f0000000000000000000000000000000000000000000000000000000000000000337f00000000000000000000000000000000000000000000000000000000000000006040516103f69493929190610745565b60405180910390a160017f0000000000000000000000000000000000000000000000000000000000000000600181111561043257610432610688565b0361054b5760007f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff168260405160006040518083038185875af1925050503d80600081146104b1576040519150601f19603f3d011682016040523d82523d6000602084013e6104b6565b606091505b5050905080610547576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603060248201527f4665655661756c743a206661696c656420746f2073656e642045544820746f2060448201527f4c322066656520726563697069656e740000000000000000000000000000000060648201526084016102e9565b5050565b604080516020810182526000815290517fe11013dd0000000000000000000000000000000000000000000000000000000081527342000000000000000000000000000000000000109163e11013dd9184916105ce917f0000000000000000000000000000000000000000000000000000000000000000916188b891600401610786565b6000604051808303818588803b1580156105e757600080fd5b505af11580156105fb573d6000803e3d6000fd5b505050505050565b6000815180845260005b818110156106295760208185018101518683018201520161060d565b8181111561063b576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b6020815260006106816020830184610603565b9392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b600281106106ee577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b9052565b6020810161070082846106b7565b92915050565b60008219821115610740577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b500190565b84815273ffffffffffffffffffffffffffffffffffffffff8481166020830152831660408201526080810161077d60608301846106b7565b95945050505050565b73ffffffffffffffffffffffffffffffffffffffff8416815263ffffffff8316602082015260606040820152600061077d606083018461060356fea164736f6c634300080f000a", } // SequencerFeeVaultABI is the input ABI used to generate the binding from. diff --git a/op-bindings/bindings/sequencerfeevault_more.go b/op-bindings/bindings/sequencerfeevault_more.go index aec1d556b7c24..0b1afa812db2e 100644 --- a/op-bindings/bindings/sequencerfeevault_more.go +++ b/op-bindings/bindings/sequencerfeevault_more.go @@ -13,7 +13,7 @@ const SequencerFeeVaultStorageLayoutJSON = "{\"storage\":[{\"astId\":1000,\"cont var SequencerFeeVaultStorageLayout = new(solc.StorageLayout) -var SequencerFeeVaultDeployedBin = "0x6080604052600436106100745760003560e01c806384411d651161004e57806384411d651461014b578063d0e12f901461016f578063d3e5792b146101b0578063d4ff9218146101e457600080fd5b80630d9019e1146100805780633ccfd60b146100de57806354fd4d50146100f557600080fd5b3661007b57005b600080fd5b34801561008c57600080fd5b506100b47f000000000000000000000000000000000000000000000000000000000000000081565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b3480156100ea57600080fd5b506100f3610217565b005b34801561010157600080fd5b5061013e6040518060400160405280600581526020017f312e342e3000000000000000000000000000000000000000000000000000000081525081565b6040516100d5919061066e565b34801561015757600080fd5b5061016160005481565b6040519081526020016100d5565b34801561017b57600080fd5b506101a37f000000000000000000000000000000000000000000000000000000000000000081565b6040516100d591906106f2565b3480156101bc57600080fd5b506101617f000000000000000000000000000000000000000000000000000000000000000081565b3480156101f057600080fd5b507f00000000000000000000000000000000000000000000000000000000000000006100b4565b7f00000000000000000000000000000000000000000000000000000000000000004710156102f2576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604a60248201527f4665655661756c743a207769746864726177616c20616d6f756e74206d75737460448201527f2062652067726561746572207468616e206d696e696d756d207769746864726160648201527f77616c20616d6f756e7400000000000000000000000000000000000000000000608482015260a4015b60405180910390fd5b6000479050806000808282546103089190610706565b9091555050604080518281527f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff166020820152338183015290517fc8a211cc64b6ed1b50595a9fcb1932b6d1e5a6e8ef15b60e5b1f988ea9086bba9181900360600190a17f38e04cbeb8c10f8f568618aa75be0f10b6729b8b4237743b4de20cbcde2839ee817f0000000000000000000000000000000000000000000000000000000000000000337f00000000000000000000000000000000000000000000000000000000000000006040516103f69493929190610745565b60405180910390a160017f0000000000000000000000000000000000000000000000000000000000000000600181111561043257610432610688565b0361054b5760007f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff168260405160006040518083038185875af1925050503d80600081146104b1576040519150601f19603f3d011682016040523d82523d6000602084013e6104b6565b606091505b5050905080610547576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603060248201527f4665655661756c743a206661696c656420746f2073656e642045544820746f2060448201527f4c322066656520726563697069656e740000000000000000000000000000000060648201526084016102e9565b5050565b604080516020810182526000815290517fe11013dd0000000000000000000000000000000000000000000000000000000081527342000000000000000000000000000000000000109163e11013dd9184916105ce917f0000000000000000000000000000000000000000000000000000000000000000916188b891600401610786565b6000604051808303818588803b1580156105e757600080fd5b505af11580156105fb573d6000803e3d6000fd5b505050505050565b6000815180845260005b818110156106295760208185018101518683018201520161060d565b8181111561063b576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b6020815260006106816020830184610603565b9392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b600281106106ee577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b9052565b6020810161070082846106b7565b92915050565b60008219821115610740577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b500190565b84815273ffffffffffffffffffffffffffffffffffffffff8481166020830152831660408201526080810161077d60608301846106b7565b95945050505050565b73ffffffffffffffffffffffffffffffffffffffff8416815263ffffffff8316602082015260606040820152600061077d606083018461060356fea164736f6c634300080f000a" +var SequencerFeeVaultDeployedBin = "0x6080604052600436106100745760003560e01c806384411d651161004e57806384411d651461014b578063d0e12f901461016f578063d3e5792b146101b0578063d4ff9218146101e457600080fd5b80630d9019e1146100805780633ccfd60b146100de57806354fd4d50146100f557600080fd5b3661007b57005b600080fd5b34801561008c57600080fd5b506100b47f000000000000000000000000000000000000000000000000000000000000000081565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b3480156100ea57600080fd5b506100f3610217565b005b34801561010157600080fd5b5061013e6040518060400160405280600581526020017f312e342e3100000000000000000000000000000000000000000000000000000081525081565b6040516100d5919061066e565b34801561015757600080fd5b5061016160005481565b6040519081526020016100d5565b34801561017b57600080fd5b506101a37f000000000000000000000000000000000000000000000000000000000000000081565b6040516100d591906106f2565b3480156101bc57600080fd5b506101617f000000000000000000000000000000000000000000000000000000000000000081565b3480156101f057600080fd5b507f00000000000000000000000000000000000000000000000000000000000000006100b4565b7f00000000000000000000000000000000000000000000000000000000000000004710156102f2576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152604a60248201527f4665655661756c743a207769746864726177616c20616d6f756e74206d75737460448201527f2062652067726561746572207468616e206d696e696d756d207769746864726160648201527f77616c20616d6f756e7400000000000000000000000000000000000000000000608482015260a4015b60405180910390fd5b6000479050806000808282546103089190610706565b9091555050604080518281527f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff166020820152338183015290517fc8a211cc64b6ed1b50595a9fcb1932b6d1e5a6e8ef15b60e5b1f988ea9086bba9181900360600190a17f38e04cbeb8c10f8f568618aa75be0f10b6729b8b4237743b4de20cbcde2839ee817f0000000000000000000000000000000000000000000000000000000000000000337f00000000000000000000000000000000000000000000000000000000000000006040516103f69493929190610745565b60405180910390a160017f0000000000000000000000000000000000000000000000000000000000000000600181111561043257610432610688565b0361054b5760007f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff168260405160006040518083038185875af1925050503d80600081146104b1576040519150601f19603f3d011682016040523d82523d6000602084013e6104b6565b606091505b5050905080610547576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603060248201527f4665655661756c743a206661696c656420746f2073656e642045544820746f2060448201527f4c322066656520726563697069656e740000000000000000000000000000000060648201526084016102e9565b5050565b604080516020810182526000815290517fe11013dd0000000000000000000000000000000000000000000000000000000081527342000000000000000000000000000000000000109163e11013dd9184916105ce917f0000000000000000000000000000000000000000000000000000000000000000916188b891600401610786565b6000604051808303818588803b1580156105e757600080fd5b505af11580156105fb573d6000803e3d6000fd5b505050505050565b6000815180845260005b818110156106295760208185018101518683018201520161060d565b8181111561063b576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b6020815260006106816020830184610603565b9392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b600281106106ee577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b9052565b6020810161070082846106b7565b92915050565b60008219821115610740577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b500190565b84815273ffffffffffffffffffffffffffffffffffffffff8481166020830152831660408201526080810161077d60608301846106b7565b95945050505050565b73ffffffffffffffffffffffffffffffffffffffff8416815263ffffffff8316602082015260606040820152600061077d606083018461060356fea164736f6c634300080f000a" func init() { if err := json.Unmarshal([]byte(SequencerFeeVaultStorageLayoutJSON), SequencerFeeVaultStorageLayout); err != nil { diff --git a/op-bindings/bindings/storagesetter.go b/op-bindings/bindings/storagesetter.go index 91d46a33c0112..a827255c97ed3 100644 --- a/op-bindings/bindings/storagesetter.go +++ b/op-bindings/bindings/storagesetter.go @@ -28,10 +28,16 @@ var ( _ = event.NewSubscription ) +// StorageSetterSlot is an auto generated low-level Go binding around an user-defined struct. +type StorageSetterSlot struct { + Key [32]byte + Value [32]byte +} + // StorageSetterMetaData contains all meta data concerning the StorageSetter contract. var StorageSetterMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"_slot\",\"type\":\"bytes32\"}],\"name\":\"getAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"_slot\",\"type\":\"bytes32\"}],\"name\":\"getBytes32\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"_slot\",\"type\":\"bytes32\"}],\"name\":\"getUint\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"_slot\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"_address\",\"type\":\"address\"}],\"name\":\"setAddress\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"_slot\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"_value\",\"type\":\"bytes32\"}],\"name\":\"setBytes32\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"_slot\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"_value\",\"type\":\"uint256\"}],\"name\":\"setUint\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"version\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", - Bin: "0x608060405234801561001057600080fd5b5061025a806100206000396000f3fe608060405234801561001057600080fd5b506004361061007d5760003560e01c8063a6ed563e1161005b578063a6ed563e1461011c578063bd02d0f51461011c578063ca446dd914610138578063e2a4853a146100bf57600080fd5b806321f8a721146100825780634e91db08146100bf57806354fd4d50146100d3575b600080fd5b610095610090366004610156565b610146565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b6100d16100cd36600461016f565b9055565b005b61010f6040518060400160405280600581526020017f312e302e3000000000000000000000000000000000000000000000000000000081525081565b6040516100b69190610191565b61012a610090366004610156565b6040519081526020016100b6565b6100d16100cd366004610204565b6000610150825490565b92915050565b60006020828403121561016857600080fd5b5035919050565b6000806040838503121561018257600080fd5b50508035926020909101359150565b600060208083528351808285015260005b818110156101be578581018301518582016040015282016101a2565b818111156101d0576000604083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016929092016040019392505050565b6000806040838503121561021757600080fd5b82359150602083013573ffffffffffffffffffffffffffffffffffffffff8116811461024257600080fd5b80915050925092905056fea164736f6c634300080f000a", + ABI: "[{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"_slot\",\"type\":\"bytes32\"}],\"name\":\"getAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"_slot\",\"type\":\"bytes32\"}],\"name\":\"getBytes32\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"_slot\",\"type\":\"bytes32\"}],\"name\":\"getUint\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"_slot\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"_address\",\"type\":\"address\"}],\"name\":\"setAddress\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"key\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"value\",\"type\":\"bytes32\"}],\"internalType\":\"structStorageSetter.Slot[]\",\"name\":\"slots\",\"type\":\"tuple[]\"}],\"name\":\"setBytes32\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"_slot\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"_value\",\"type\":\"bytes32\"}],\"name\":\"setBytes32\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"_slot\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"_value\",\"type\":\"uint256\"}],\"name\":\"setUint\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"version\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", + Bin: "0x608060405234801561001057600080fd5b506103de806100206000396000f3fe608060405234801561001057600080fd5b50600436106100885760003560e01c8063a6ed563e1161005b578063a6ed563e1461013a578063bd02d0f51461013a578063ca446dd914610156578063e2a4853a146100df57600080fd5b80630528afe21461008d57806321f8a721146100a25780634e91db08146100df57806354fd4d50146100f1575b600080fd5b6100a061009b3660046101d7565b610164565b005b6100b56100b036600461024c565b6101c7565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b6100a06100ed366004610265565b9055565b61012d6040518060400160405280600581526020017f312e312e3000000000000000000000000000000000000000000000000000000081525081565b6040516100d69190610287565b6101486100b036600461024c565b6040519081526020016100d6565b6100a06100ed3660046102fa565b8060005b818110156101c1576101af84848381811061018557610185610343565b905060400201600001358585848181106101a1576101a1610343565b905060400201602001359055565b806101b981610372565b915050610168565b50505050565b60006101d1825490565b92915050565b600080602083850312156101ea57600080fd5b823567ffffffffffffffff8082111561020257600080fd5b818501915085601f83011261021657600080fd5b81358181111561022557600080fd5b8660208260061b850101111561023a57600080fd5b60209290920196919550909350505050565b60006020828403121561025e57600080fd5b5035919050565b6000806040838503121561027857600080fd5b50508035926020909101359150565b600060208083528351808285015260005b818110156102b457858101830151858201604001528201610298565b818111156102c6576000604083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016929092016040019392505050565b6000806040838503121561030d57600080fd5b82359150602083013573ffffffffffffffffffffffffffffffffffffffff8116811461033857600080fd5b809150509250929050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036103ca577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b506001019056fea164736f6c634300080f000a", } // StorageSetterABI is the input ABI used to generate the binding from. @@ -346,25 +352,46 @@ func (_StorageSetter *StorageSetterTransactorSession) SetAddress(_slot [32]byte, return _StorageSetter.Contract.SetAddress(&_StorageSetter.TransactOpts, _slot, _address) } -// SetBytes32 is a paid mutator transaction binding the contract method 0x4e91db08. +// SetBytes32 is a paid mutator transaction binding the contract method 0x0528afe2. +// +// Solidity: function setBytes32((bytes32,bytes32)[] slots) returns() +func (_StorageSetter *StorageSetterTransactor) SetBytes32(opts *bind.TransactOpts, slots []StorageSetterSlot) (*types.Transaction, error) { + return _StorageSetter.contract.Transact(opts, "setBytes32", slots) +} + +// SetBytes32 is a paid mutator transaction binding the contract method 0x0528afe2. +// +// Solidity: function setBytes32((bytes32,bytes32)[] slots) returns() +func (_StorageSetter *StorageSetterSession) SetBytes32(slots []StorageSetterSlot) (*types.Transaction, error) { + return _StorageSetter.Contract.SetBytes32(&_StorageSetter.TransactOpts, slots) +} + +// SetBytes32 is a paid mutator transaction binding the contract method 0x0528afe2. +// +// Solidity: function setBytes32((bytes32,bytes32)[] slots) returns() +func (_StorageSetter *StorageSetterTransactorSession) SetBytes32(slots []StorageSetterSlot) (*types.Transaction, error) { + return _StorageSetter.Contract.SetBytes32(&_StorageSetter.TransactOpts, slots) +} + +// SetBytes320 is a paid mutator transaction binding the contract method 0x4e91db08. // // Solidity: function setBytes32(bytes32 _slot, bytes32 _value) returns() -func (_StorageSetter *StorageSetterTransactor) SetBytes32(opts *bind.TransactOpts, _slot [32]byte, _value [32]byte) (*types.Transaction, error) { - return _StorageSetter.contract.Transact(opts, "setBytes32", _slot, _value) +func (_StorageSetter *StorageSetterTransactor) SetBytes320(opts *bind.TransactOpts, _slot [32]byte, _value [32]byte) (*types.Transaction, error) { + return _StorageSetter.contract.Transact(opts, "setBytes320", _slot, _value) } -// SetBytes32 is a paid mutator transaction binding the contract method 0x4e91db08. +// SetBytes320 is a paid mutator transaction binding the contract method 0x4e91db08. // // Solidity: function setBytes32(bytes32 _slot, bytes32 _value) returns() -func (_StorageSetter *StorageSetterSession) SetBytes32(_slot [32]byte, _value [32]byte) (*types.Transaction, error) { - return _StorageSetter.Contract.SetBytes32(&_StorageSetter.TransactOpts, _slot, _value) +func (_StorageSetter *StorageSetterSession) SetBytes320(_slot [32]byte, _value [32]byte) (*types.Transaction, error) { + return _StorageSetter.Contract.SetBytes320(&_StorageSetter.TransactOpts, _slot, _value) } -// SetBytes32 is a paid mutator transaction binding the contract method 0x4e91db08. +// SetBytes320 is a paid mutator transaction binding the contract method 0x4e91db08. // // Solidity: function setBytes32(bytes32 _slot, bytes32 _value) returns() -func (_StorageSetter *StorageSetterTransactorSession) SetBytes32(_slot [32]byte, _value [32]byte) (*types.Transaction, error) { - return _StorageSetter.Contract.SetBytes32(&_StorageSetter.TransactOpts, _slot, _value) +func (_StorageSetter *StorageSetterTransactorSession) SetBytes320(_slot [32]byte, _value [32]byte) (*types.Transaction, error) { + return _StorageSetter.Contract.SetBytes320(&_StorageSetter.TransactOpts, _slot, _value) } // SetUint is a paid mutator transaction binding the contract method 0xe2a4853a. diff --git a/op-bindings/bindings/storagesetter_more.go b/op-bindings/bindings/storagesetter_more.go index c7315ea6721d0..723e719700b8a 100644 --- a/op-bindings/bindings/storagesetter_more.go +++ b/op-bindings/bindings/storagesetter_more.go @@ -13,7 +13,7 @@ const StorageSetterStorageLayoutJSON = "{\"storage\":null,\"types\":{}}" var StorageSetterStorageLayout = new(solc.StorageLayout) -var StorageSetterDeployedBin = "0x608060405234801561001057600080fd5b506004361061007d5760003560e01c8063a6ed563e1161005b578063a6ed563e1461011c578063bd02d0f51461011c578063ca446dd914610138578063e2a4853a146100bf57600080fd5b806321f8a721146100825780634e91db08146100bf57806354fd4d50146100d3575b600080fd5b610095610090366004610156565b610146565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b6100d16100cd36600461016f565b9055565b005b61010f6040518060400160405280600581526020017f312e302e3000000000000000000000000000000000000000000000000000000081525081565b6040516100b69190610191565b61012a610090366004610156565b6040519081526020016100b6565b6100d16100cd366004610204565b6000610150825490565b92915050565b60006020828403121561016857600080fd5b5035919050565b6000806040838503121561018257600080fd5b50508035926020909101359150565b600060208083528351808285015260005b818110156101be578581018301518582016040015282016101a2565b818111156101d0576000604083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016929092016040019392505050565b6000806040838503121561021757600080fd5b82359150602083013573ffffffffffffffffffffffffffffffffffffffff8116811461024257600080fd5b80915050925092905056fea164736f6c634300080f000a" +var StorageSetterDeployedBin = "0x608060405234801561001057600080fd5b50600436106100885760003560e01c8063a6ed563e1161005b578063a6ed563e1461013a578063bd02d0f51461013a578063ca446dd914610156578063e2a4853a146100df57600080fd5b80630528afe21461008d57806321f8a721146100a25780634e91db08146100df57806354fd4d50146100f1575b600080fd5b6100a061009b3660046101d7565b610164565b005b6100b56100b036600461024c565b6101c7565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b6100a06100ed366004610265565b9055565b61012d6040518060400160405280600581526020017f312e312e3000000000000000000000000000000000000000000000000000000081525081565b6040516100d69190610287565b6101486100b036600461024c565b6040519081526020016100d6565b6100a06100ed3660046102fa565b8060005b818110156101c1576101af84848381811061018557610185610343565b905060400201600001358585848181106101a1576101a1610343565b905060400201602001359055565b806101b981610372565b915050610168565b50505050565b60006101d1825490565b92915050565b600080602083850312156101ea57600080fd5b823567ffffffffffffffff8082111561020257600080fd5b818501915085601f83011261021657600080fd5b81358181111561022557600080fd5b8660208260061b850101111561023a57600080fd5b60209290920196919550909350505050565b60006020828403121561025e57600080fd5b5035919050565b6000806040838503121561027857600080fd5b50508035926020909101359150565b600060208083528351808285015260005b818110156102b457858101830151858201604001528201610298565b818111156102c6576000604083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016929092016040019392505050565b6000806040838503121561030d57600080fd5b82359150602083013573ffffffffffffffffffffffffffffffffffffffff8116811461033857600080fd5b809150509250929050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036103ca577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b506001019056fea164736f6c634300080f000a" func init() { if err := json.Unmarshal([]byte(StorageSetterStorageLayoutJSON), StorageSetterStorageLayout); err != nil { diff --git a/op-bootnode/Makefile b/op-bootnode/Makefile index 43d0dfc1ff727..e30dad5b1a993 100644 --- a/op-bootnode/Makefile +++ b/op-bootnode/Makefile @@ -1,5 +1,5 @@ -GITCOMMIT := $(shell git rev-parse HEAD) -GITDATE := $(shell git show -s --format='%ct') +GITCOMMIT ?= $(shell git rev-parse HEAD) +GITDATE ?= $(shell git show -s --format='%ct') VERSION := v0.0.0 LDFLAGSSTRING +=-X main.GitCommit=$(GITCOMMIT) @@ -16,11 +16,7 @@ clean: test: go test -v ./... -lint: - golangci-lint run -E goimports,sqlclosecheck,bodyclose,asciicheck,misspell,errorlint --timeout 5m -e "errors.As" -e "errors.Is" ./... - .PHONY: \ op-bootnode \ clean \ - test \ - lint + test diff --git a/op-chain-ops/Makefile b/op-chain-ops/Makefile index a4a93dc329a62..7a017a4fb59af 100644 --- a/op-chain-ops/Makefile +++ b/op-chain-ops/Makefile @@ -6,9 +6,6 @@ check-l2: test: go test ./... -lint: - golangci-lint run -E goimports,sqlclosecheck,bodyclose,asciicheck,misspell,errorlint --timeout 5m -e "errors.As" -e "errors.Is" ./... - fuzz: go test -run NOTAREALTEST -v -fuzztime 10s -fuzz=FuzzEncodeDecodeWithdrawal ./crossdomain go test -run NOTAREALTEST -v -fuzztime 10s -fuzz=FuzzEncodeDecodeLegacyWithdrawal ./crossdomain diff --git a/op-chain-ops/cmd/check-canyon/main.go b/op-chain-ops/cmd/check-canyon/main.go new file mode 100644 index 0000000000000..c6deeb87ced1e --- /dev/null +++ b/op-chain-ops/cmd/check-canyon/main.go @@ -0,0 +1,272 @@ +package main + +import ( + "bytes" + "context" + "errors" + "flag" + "fmt" + "math/big" + "os" + + "github.com/ethereum-optimism/optimism/op-node/rollup" + "github.com/ethereum-optimism/optimism/op-service/client" + "github.com/ethereum-optimism/optimism/op-service/eth" + "github.com/ethereum-optimism/optimism/op-service/sources" + + "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/common/math" + "github.com/ethereum/go-ethereum/core/types" + "github.com/ethereum/go-ethereum/crypto" + "github.com/ethereum/go-ethereum/ethclient" + "github.com/ethereum/go-ethereum/log" + "github.com/ethereum/go-ethereum/trie" +) + +func CalcBaseFee(parent eth.BlockInfo, elasticity uint64, canyonActive bool) *big.Int { + denomUint := uint64(50) + if canyonActive { + denomUint = uint64(250) + } + parentGasTarget := parent.GasLimit() / elasticity + // If the parent gasUsed is the same as the target, the baseFee remains unchanged. + if parent.GasUsed() == parentGasTarget { + return new(big.Int).Set(parent.BaseFee()) + } + + var ( + num = new(big.Int) + denom = new(big.Int) + ) + + if parent.GasUsed() > parentGasTarget { + // If the parent block used more gas than its target, the baseFee should increase. + // max(1, parentBaseFee * gasUsedDelta / parentGasTarget / baseFeeChangeDenominator) + num.SetUint64(parent.GasUsed() - parentGasTarget) + num.Mul(num, parent.BaseFee()) + num.Div(num, denom.SetUint64(parentGasTarget)) + num.Div(num, denom.SetUint64(denomUint)) + baseFeeDelta := math.BigMax(num, common.Big1) + + return num.Add(parent.BaseFee(), baseFeeDelta) + } else { + // Otherwise if the parent block used less gas than its target, the baseFee should decrease. + // max(0, parentBaseFee * gasUsedDelta / parentGasTarget / baseFeeChangeDenominator) + num.SetUint64(parentGasTarget - parent.GasUsed()) + num.Mul(num, parent.BaseFee()) + num.Div(num, denom.SetUint64(parentGasTarget)) + num.Div(num, denom.SetUint64(denomUint)) + baseFee := num.Sub(parent.BaseFee(), num) + + return math.BigMax(baseFee, common.Big0) + } +} + +func ManuallyEncodeReceipts(receipts types.Receipts, canyonActive bool) [][]byte { + v := uint64(1) + for _, receipt := range receipts { + if receipt.Type == types.DepositTxType { + if canyonActive { + receipt.DepositReceiptVersion = &v + } else { + receipt.DepositReceiptVersion = nil + } + + } + } + var out [][]byte + for i := range receipts { + var buf bytes.Buffer + receipts.EncodeIndex(i, &buf) + out = append(out, buf.Bytes()) + } + return out +} + +type rawReceipts [][]byte + +func (s rawReceipts) Len() int { return len(s) } +func (s rawReceipts) EncodeIndex(i int, w *bytes.Buffer) { + w.Write(s[i]) +} +func HashList(list [][]byte) common.Hash { + hasher := trie.NewStackTrie(nil) + return types.DeriveSha(rawReceipts(list), hasher) +} + +type L2Client interface { + BlockByNumber(context.Context, *big.Int) (*types.Block, error) + CodeAt(context.Context, common.Address, *big.Int) ([]byte, error) + InfoByNumber(context.Context, uint64) (eth.BlockInfo, error) + FetchReceipts(context.Context, common.Hash) (eth.BlockInfo, types.Receipts, error) +} + +type Client struct { + *ethclient.Client + *sources.L1Client +} + +type Args struct { + Number uint64 + Elasticity uint64 + Client L2Client +} + +func ValidateReceipts(ctx Args, canyonActive bool) error { + block, err := ctx.Client.InfoByNumber(context.Background(), ctx.Number) + if err != nil { + return err + } + + _, receipts, err := ctx.Client.FetchReceipts(context.Background(), block.Hash()) + if err != nil { + return err + } + + have := block.ReceiptHash() + want := HashList(ManuallyEncodeReceipts(receipts, canyonActive)) + + if have != want { + return fmt.Errorf("Receipts do not look correct. canyonActive: %v. have: %v, want: %v", canyonActive, have, want) + } + + return nil +} + +func Validate1559Params(ctx Args, canyonActive bool) error { + block, err := ctx.Client.InfoByNumber(context.Background(), ctx.Number) + if err != nil { + return err + } + + parent, err := ctx.Client.InfoByNumber(context.Background(), ctx.Number-1) + if err != nil { + return err + } + + want := CalcBaseFee(parent, ctx.Elasticity, canyonActive) + have := block.BaseFee() + + if have.Cmp(want) != 0 { + return fmt.Errorf("BaseFee does not match. canyonActive: %v. have: %v, want: %v", canyonActive, have, want) + } + + return nil +} + +func ValidateWithdrawals(ctx Args, canyonActive bool) error { + block, err := ctx.Client.BlockByNumber(context.Background(), new(big.Int).SetUint64(ctx.Number)) + if err != nil { + return err + } + + if canyonActive && block.Withdrawals() == nil { + return errors.New("No nonwithdrawals in a canyon block") + } else if canyonActive && len(block.Withdrawals()) > 0 { + return errors.New("Withdrawals length is not zero in a canyon block") + } else if !canyonActive && block.Withdrawals() != nil { + return errors.New("Withdrawals in a pre-canyon block") + } + return nil +} + +func ValidateCreate2Deployer(ctx Args, canyonActive bool) error { + addr := common.HexToAddress("0x13b0D85CcB8bf860b6b79AF3029fCA081AE9beF2") + code, err := ctx.Client.CodeAt(context.Background(), addr, new(big.Int).SetUint64(ctx.Number)) + if err != nil { + return err + } + codeHash := crypto.Keccak256Hash(code) + expectedCodeHash := common.HexToHash("0xb0550b5b431e30d38000efb7107aaa0ade03d48a7198a140edda9d27134468b2") + + if canyonActive && codeHash != expectedCodeHash { + return fmt.Errorf("Canyon active but code hash does not match. have: %v, want: %v", codeHash, expectedCodeHash) + } else if !canyonActive && codeHash == expectedCodeHash { + return fmt.Errorf("Canyon not active but code hashes do match. codeHash: %v", codeHash) + } + + return nil +} + +// CheckActivation takes a function f which determines in a specific block follows the rules of a fork. +func CheckActivation(f func(Args, bool) error, ctx Args, forkActivated bool, valid *bool) { + if err := f(ctx, forkActivated); err != nil { + log.Error("Block did not follow fork rules", "err", err) + *valid = false + } +} + +// CheckInactivation takes a function f which determines in a specific block follows the rules of a fork. +// It passes the oppose value of forkActivated & asserts that an error is returned. +func CheckInactivation(f func(Args, bool) error, ctx Args, forkActivated bool, valid *bool) { + if err := f(ctx, !forkActivated); err == nil { + log.Error("Block followed the wrong side of the fork rules") + *valid = false + } +} + +func main() { + logger := log.New() + + // Define the flag variables + var ( + canyonActive bool + number uint64 + elasticity uint64 + rpcURL string + ) + + valid := true + + // Define and parse the command-line flags + flag.BoolVar(&canyonActive, "canyon", false, "Set this flag to assert canyon behavior") + flag.Uint64Var(&number, "number", 31, "Block number to check") + flag.Uint64Var(&elasticity, "elasticity", 6, "Specify the EIP-1559 elasticity. 6 on mainnet/sepolia. 10 on goerli") + flag.StringVar(&rpcURL, "rpc-url", "http://localhost:8545", "Specify the L2 ETH RPC URL") + + // Parse the command-line arguments + flag.Parse() + + l2RPC, err := client.NewRPC(context.Background(), logger, rpcURL, client.WithDialBackoff(10)) + if err != nil { + log.Crit("Error creating RPC", "err", err) + } + c := &rollup.Config{SeqWindowSize: 10} + l2Cfg := sources.L1ClientDefaultConfig(c, true, sources.RPCKindBasic) + sourceClient, err := sources.NewL1Client(l2RPC, logger, nil, l2Cfg) + if err != nil { + log.Crit("Error creating RPC", "err", err) + } + ethClient, err := ethclient.Dial(rpcURL) + if err != nil { + log.Crit("Error creating RPC", "err", err) + } + + client := Client{ethClient, sourceClient} + + ctx := Args{ + Number: number, + Elasticity: elasticity, + Client: client, + } + + CheckActivation(ValidateReceipts, ctx, canyonActive, &valid) + CheckInactivation(ValidateReceipts, ctx, canyonActive, &valid) + + CheckActivation(Validate1559Params, ctx, canyonActive, &valid) + // Don't check in-activation for 1559 b/c at low basefees the two cannot be differentiated + + CheckActivation(ValidateWithdrawals, ctx, canyonActive, &valid) + CheckInactivation(ValidateWithdrawals, ctx, canyonActive, &valid) + + CheckActivation(ValidateCreate2Deployer, ctx, canyonActive, &valid) + CheckInactivation(ValidateCreate2Deployer, ctx, canyonActive, &valid) + + if !valid { + os.Exit(1) + } else if canyonActive { + log.Info(fmt.Sprintf("Successfully validated block %v as a Canyon block", number)) + } else { + log.Info(fmt.Sprintf("Successfully validated block %v as a Pre-Canyon block", number)) + } +} diff --git a/op-chain-ops/cmd/op-upgrade/README.md b/op-chain-ops/cmd/op-upgrade/README.md index d4e65542e21d3..9e62f9c1955ea 100644 --- a/op-chain-ops/cmd/op-upgrade/README.md +++ b/op-chain-ops/cmd/op-upgrade/README.md @@ -34,5 +34,5 @@ be read out of the directory as needed. #### Outfile -The file that the bundle shoudl be written to. If omitted, the file +The file that the bundle should be written to. If omitted, the file will be written to stdout. diff --git a/op-chain-ops/cmd/op-upgrade/main.go b/op-chain-ops/cmd/op-upgrade/main.go index aec5c07addfbe..7fdf67c8967e3 100644 --- a/op-chain-ops/cmd/op-upgrade/main.go +++ b/op-chain-ops/cmd/op-upgrade/main.go @@ -112,7 +112,7 @@ func entrypoint(ctx *cli.Context) error { name, _ := toDeployConfigName(chainConfig) config, err := genesis.NewDeployConfigWithNetwork(name, deployConfig) if err != nil { - log.Warn("Cannot find deploy config for network", "name", chainConfig.Name, "deploy-config-name", name, "path", deployConfig) + log.Warn("Cannot find deploy config for network", "name", chainConfig.Name, "deploy-config-name", name, "path", deployConfig, "err", err) } if config != nil { diff --git a/op-chain-ops/genesis/config.go b/op-chain-ops/genesis/config.go index da4981bce74f1..242e5c45ce7e8 100644 --- a/op-chain-ops/genesis/config.go +++ b/op-chain-ops/genesis/config.go @@ -26,6 +26,11 @@ import ( "github.com/ethereum-optimism/optimism/op-service/eth" ) +// initialzedValue represents the `Initializable` contract value. It should be kept in +// sync with the constant in `Constants.sol`. +// https://github.com/ethereum-optimism/optimism/blob/develop/packages/contracts-bedrock/src/libraries/Constants.sol +const initializedValue = 3 + var ( ErrInvalidDeployConfig = errors.New("invalid deploy config") ErrInvalidImmutablesConfig = errors.New("invalid immutables config") @@ -107,8 +112,11 @@ type DeployConfig struct { L2GenesisBlockBaseFeePerGas *hexutil.Big `json:"l2GenesisBlockBaseFeePerGas"` // L2GenesisRegolithTimeOffset is the number of seconds after genesis block that Regolith hard fork activates. - // Set it to 0 to activate at genesis. Nil to disable regolith. + // Set it to 0 to activate at genesis. Nil to disable Regolith. L2GenesisRegolithTimeOffset *hexutil.Uint64 `json:"l2GenesisRegolithTimeOffset,omitempty"` + // L2GenesisCanyonTimeOffset is the number of seconds after genesis block that Canyon hard fork activates. + // Set it to 0 to activate at genesis. Nil to disable Canyon. + L2GenesisCanyonTimeOffset *hexutil.Uint64 `json:"L2GenesisCanyonTimeOffset,omitempty"` // L2GenesisSpanBatchTimeOffset is the number of seconds after genesis block that Span Batch hard fork activates. // Set it to 0 to activate at genesis. Nil to disable SpanBatch. L2GenesisSpanBatchTimeOffset *hexutil.Uint64 `json:"l2GenesisSpanBatchTimeOffset,omitempty"` @@ -177,6 +185,8 @@ type DeployConfig struct { EIP1559Elasticity uint64 `json:"eip1559Elasticity"` // EIP1559Denominator is the denominator of EIP1559 base fee market. EIP1559Denominator uint64 `json:"eip1559Denominator"` + // EIP1559DenominatorCanyon is the denominator of EIP1559 base fee market when Canyon is active. + EIP1559DenominatorCanyon uint64 `json:"eip1559DenominatorCanyon"` // SystemConfigStartBlock represents the block at which the op-node should start syncing // from. It is an override to set this value on legacy networks where it is not set by // default. It can be removed once all networks have this value set in their storage. @@ -310,6 +320,9 @@ func (d *DeployConfig) Check() error { if d.EIP1559Denominator == 0 { return fmt.Errorf("%w: EIP1559Denominator cannot be 0", ErrInvalidDeployConfig) } + if d.L2GenesisCanyonTimeOffset != nil && d.EIP1559DenominatorCanyon == 0 { + return fmt.Errorf("%w: EIP1559DenominatorCanyon cannot be 0 if Canyon is activated", ErrInvalidDeployConfig) + } if d.EIP1559Elasticity == 0 { return fmt.Errorf("%w: EIP1559Elasticity cannot be 0", ErrInvalidDeployConfig) } @@ -375,41 +388,28 @@ func (d *DeployConfig) SetDeployments(deployments *L1Deployments) { } // GetDeployedAddresses will get the deployed addresses of deployed L1 contracts -// required for the L2 genesis creation. Legacy systems use the `Proxy__` prefix -// while modern systems use the `Proxy` suffix. First check for the legacy -// deployments so that this works with upgrading a system. +// required for the L2 genesis creation. func (d *DeployConfig) GetDeployedAddresses(hh *hardhat.Hardhat) error { - var err error - if d.L1StandardBridgeProxy == (common.Address{}) { - var l1StandardBridgeProxyDeployment *hardhat.Deployment - l1StandardBridgeProxyDeployment, err = hh.GetDeployment("Proxy__OVM_L1StandardBridge") - if errors.Is(err, hardhat.ErrCannotFindDeployment) { - l1StandardBridgeProxyDeployment, err = hh.GetDeployment("L1StandardBridgeProxy") - if err != nil { - return err - } + l1StandardBridgeProxyDeployment, err := hh.GetDeployment("L1StandardBridgeProxy") + if err != nil { + return fmt.Errorf("cannot find L1StandardBridgeProxy artifact: %w", err) } d.L1StandardBridgeProxy = l1StandardBridgeProxyDeployment.Address } if d.L1CrossDomainMessengerProxy == (common.Address{}) { - var l1CrossDomainMessengerProxyDeployment *hardhat.Deployment - l1CrossDomainMessengerProxyDeployment, err = hh.GetDeployment("Proxy__OVM_L1CrossDomainMessenger") - if errors.Is(err, hardhat.ErrCannotFindDeployment) { - l1CrossDomainMessengerProxyDeployment, err = hh.GetDeployment("L1CrossDomainMessengerProxy") - if err != nil { - return err - } + l1CrossDomainMessengerProxyDeployment, err := hh.GetDeployment("L1CrossDomainMessengerProxy") + if err != nil { + return fmt.Errorf("cannot find L1CrossDomainMessengerProxy artifact: %w", err) } d.L1CrossDomainMessengerProxy = l1CrossDomainMessengerProxyDeployment.Address } if d.L1ERC721BridgeProxy == (common.Address{}) { - // There is no legacy deployment of this contract l1ERC721BridgeProxyDeployment, err := hh.GetDeployment("L1ERC721BridgeProxy") if err != nil { - return err + return fmt.Errorf("cannot find L1ERC721BridgeProxy artifact: %w", err) } d.L1ERC721BridgeProxy = l1ERC721BridgeProxyDeployment.Address } @@ -417,7 +417,7 @@ func (d *DeployConfig) GetDeployedAddresses(hh *hardhat.Hardhat) error { if d.SystemConfigProxy == (common.Address{}) { systemConfigProxyDeployment, err := hh.GetDeployment("SystemConfigProxy") if err != nil { - return err + return fmt.Errorf("cannot find SystemConfigProxy artifact: %w", err) } d.SystemConfigProxy = systemConfigProxyDeployment.Address } @@ -425,7 +425,7 @@ func (d *DeployConfig) GetDeployedAddresses(hh *hardhat.Hardhat) error { if d.OptimismPortalProxy == (common.Address{}) { optimismPortalProxyDeployment, err := hh.GetDeployment("OptimismPortalProxy") if err != nil { - return err + return fmt.Errorf("cannot find OptimismPortalProxy artifact: %w", err) } d.OptimismPortalProxy = optimismPortalProxyDeployment.Address } @@ -444,6 +444,17 @@ func (d *DeployConfig) RegolithTime(genesisTime uint64) *uint64 { return &v } +func (d *DeployConfig) CanyonTime(genesisTime uint64) *uint64 { + if d.L2GenesisCanyonTimeOffset == nil { + return nil + } + v := uint64(0) + if offset := *d.L2GenesisCanyonTimeOffset; offset > 0 { + v = genesisTime + uint64(offset) + } + return &v +} + func (d *DeployConfig) SpanBatchTime(genesisTime uint64) *uint64 { if d.L2GenesisSpanBatchTimeOffset == nil { return nil @@ -492,6 +503,7 @@ func (d *DeployConfig) RollupConfig(l1StartBlock *types.Block, l2GenesisBlockHas DepositContractAddress: d.OptimismPortalProxy, L1SystemConfigAddress: d.SystemConfigProxy, RegolithTime: d.RegolithTime(l1StartBlock.Time()), + CanyonTime: d.CanyonTime(l1StartBlock.Time()), SpanBatchTime: d.SpanBatchTime(l1StartBlock.Time()), }, nil } @@ -708,13 +720,13 @@ func NewL2StorageConfig(config *DeployConfig, block *types.Block) (state.Storage "msgNonce": 0, } storage["L2CrossDomainMessenger"] = state.StorageValues{ - "_initialized": 1, + "_initialized": initializedValue, "_initializing": false, "xDomainMsgSender": "0x000000000000000000000000000000000000dEaD", "msgNonce": 0, } storage["L2StandardBridge"] = state.StorageValues{ - "_initialized": 2, + "_initialized": initializedValue, "_initializing": false, "messenger": predeploys.L2CrossDomainMessengerAddr, } @@ -724,7 +736,7 @@ func NewL2StorageConfig(config *DeployConfig, block *types.Block) (state.Storage "basefee": block.BaseFee(), "hash": block.Hash(), "sequenceNumber": 0, - "batcherHash": config.BatchSenderAddress.Hash(), + "batcherHash": eth.AddressAsLeftPaddedHash(config.BatchSenderAddress), "l1FeeOverhead": config.GasPriceOracleOverhead, "l1FeeScalar": config.GasPriceOracleScalar, } @@ -749,12 +761,12 @@ func NewL2StorageConfig(config *DeployConfig, block *types.Block) (state.Storage } storage["L2ERC721Bridge"] = state.StorageValues{ "messenger": predeploys.L2CrossDomainMessengerAddr, - "_initialized": 2, + "_initialized": initializedValue, "_initializing": false, } storage["OptimismMintableERC20Factory"] = state.StorageValues{ "bridge": predeploys.L2StandardBridgeAddr, - "_initialized": 2, + "_initialized": initializedValue, "_initializing": false, } return storage, nil diff --git a/op-chain-ops/genesis/config_test.go b/op-chain-ops/genesis/config_test.go index 77aafa476db70..026cf509d2449 100644 --- a/op-chain-ops/genesis/config_test.go +++ b/op-chain-ops/genesis/config_test.go @@ -49,6 +49,18 @@ func TestRegolithTimeAsOffset(t *testing.T) { require.Equal(t, uint64(1500+5000), *config.RegolithTime(5000)) } +func TestCanyonTimeZero(t *testing.T) { + canyonOffset := hexutil.Uint64(0) + config := &DeployConfig{L2GenesisCanyonTimeOffset: &canyonOffset} + require.Equal(t, uint64(0), *config.CanyonTime(1234)) +} + +func TestCanyonTimeOffset(t *testing.T) { + canyonOffset := hexutil.Uint64(1500) + config := &DeployConfig{L2GenesisCanyonTimeOffset: &canyonOffset} + require.Equal(t, uint64(1234+1500), *config.CanyonTime(1234)) +} + // TestCopy will copy a DeployConfig and ensure that the copy is equal to the original. func TestCopy(t *testing.T) { b, err := os.ReadFile("testdata/test-deploy-config-full.json") diff --git a/op-chain-ops/genesis/genesis.go b/op-chain-ops/genesis/genesis.go index 289c63c8ec6cc..c4aef7d943175 100644 --- a/op-chain-ops/genesis/genesis.go +++ b/op-chain-ops/genesis/genesis.go @@ -31,6 +31,10 @@ func NewL2Genesis(config *DeployConfig, block *types.Block) (*core.Genesis, erro if eip1559Denom == 0 { eip1559Denom = 50 } + eip1559DenomCanyon := config.EIP1559DenominatorCanyon + if eip1559DenomCanyon == 0 { + eip1559DenomCanyon = 250 + } eip1559Elasticity := config.EIP1559Elasticity if eip1559Elasticity == 0 { eip1559Elasticity = 10 @@ -58,9 +62,12 @@ func NewL2Genesis(config *DeployConfig, block *types.Block) (*core.Genesis, erro TerminalTotalDifficultyPassed: true, BedrockBlock: new(big.Int).SetUint64(uint64(config.L2GenesisBlockNumber)), RegolithTime: config.RegolithTime(block.Time()), + CanyonTime: config.CanyonTime(block.Time()), + ShanghaiTime: config.CanyonTime(block.Time()), Optimism: ¶ms.OptimismConfig{ - EIP1559Denominator: eip1559Denom, - EIP1559Elasticity: eip1559Elasticity, + EIP1559Denominator: eip1559Denom, + EIP1559Elasticity: eip1559Elasticity, + EIP1559DenominatorCanyon: eip1559DenomCanyon, }, } diff --git a/op-chain-ops/genesis/layer_one_test.go b/op-chain-ops/genesis/layer_one_test.go index cb3451661bbbd..be328632f9da2 100644 --- a/op-chain-ops/genesis/layer_one_test.go +++ b/op-chain-ops/genesis/layer_one_test.go @@ -14,6 +14,7 @@ import ( "github.com/ethereum-optimism/optimism/op-bindings/bindings" "github.com/ethereum-optimism/optimism/op-bindings/predeploys" "github.com/ethereum-optimism/optimism/op-chain-ops/deployer" + "github.com/ethereum-optimism/optimism/op-service/eth" "github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/accounts/abi/bind/backends" "github.com/ethereum/go-ethereum/core/state" @@ -118,7 +119,7 @@ func TestBuildL1DeveloperGenesis(t *testing.T) { require.Equal(t, scalar.Uint64(), config.GasPriceOracleScalar) batcherHash, err := sysCfg.BatcherHash(&bind.CallOpts{}) require.NoError(t, err) - require.Equal(t, common.Hash(batcherHash), config.BatchSenderAddress.Hash()) + require.Equal(t, common.Hash(batcherHash), eth.AddressAsLeftPaddedHash(config.BatchSenderAddress)) gasLimit, err := sysCfg.GasLimit(&bind.CallOpts{}) require.NoError(t, err) require.Equal(t, gasLimit, uint64(config.L2GenesisBlockGasLimit)) diff --git a/op-chain-ops/genesis/layer_two.go b/op-chain-ops/genesis/layer_two.go index af08dd0c6ccdc..a728d30132efc 100644 --- a/op-chain-ops/genesis/layer_two.go +++ b/op-chain-ops/genesis/layer_two.go @@ -10,6 +10,7 @@ import ( "github.com/ethereum-optimism/optimism/op-bindings/predeploys" "github.com/ethereum-optimism/optimism/op-chain-ops/immutables" "github.com/ethereum-optimism/optimism/op-chain-ops/state" + "github.com/ethereum-optimism/optimism/op-service/eth" ) // BuildL2DeveloperGenesis will build the L2 genesis block. @@ -62,7 +63,7 @@ func BuildL2Genesis(config *DeployConfig, l1StartBlock *types.Block) (*core.Gene return nil, fmt.Errorf("error converting to code namespace: %w", err) } db.CreateAccount(codeAddr) - db.SetState(addr, ImplementationSlot, codeAddr.Hash()) + db.SetState(addr, ImplementationSlot, eth.AddressAsLeftPaddedHash(codeAddr)) log.Info("Set proxy", "name", name, "address", addr, "implementation", codeAddr) } else { db.DeleteState(addr, AdminSlot) diff --git a/op-chain-ops/genesis/layer_two_test.go b/op-chain-ops/genesis/layer_two_test.go index f81b1a09a8abb..f941a982fddc4 100644 --- a/op-chain-ops/genesis/layer_two_test.go +++ b/op-chain-ops/genesis/layer_two_test.go @@ -18,6 +18,7 @@ import ( "github.com/ethereum-optimism/optimism/op-bindings/bindings" "github.com/ethereum-optimism/optimism/op-bindings/predeploys" "github.com/ethereum-optimism/optimism/op-chain-ops/genesis" + "github.com/ethereum-optimism/optimism/op-service/eth" ) var writeFile bool @@ -58,7 +59,7 @@ func testBuildL2Genesis(t *testing.T, config *genesis.DeployConfig) *core.Genesi (!config.EnableGovernance && addr == predeploys.GovernanceTokenAddr) if isProxy { require.Equal(t, true, ok, name) - require.Equal(t, predeploys.ProxyAdminAddr.Hash(), adminSlot) + require.Equal(t, eth.AddressAsLeftPaddedHash(predeploys.ProxyAdminAddr), adminSlot) require.Equal(t, proxyBytecode, account.Code) } else { require.Equal(t, false, ok, name) diff --git a/op-chain-ops/genesis/setters.go b/op-chain-ops/genesis/setters.go index 1490ea2f287d2..7f7172a55cd85 100644 --- a/op-chain-ops/genesis/setters.go +++ b/op-chain-ops/genesis/setters.go @@ -4,13 +4,14 @@ import ( "errors" "math/big" - "github.com/ethereum-optimism/optimism/op-bindings/bindings" - - "github.com/ethereum-optimism/optimism/op-chain-ops/immutables" - "github.com/ethereum-optimism/optimism/op-chain-ops/state" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/core/vm" "github.com/ethereum/go-ethereum/log" + + "github.com/ethereum-optimism/optimism/op-bindings/bindings" + "github.com/ethereum-optimism/optimism/op-chain-ops/immutables" + "github.com/ethereum-optimism/optimism/op-chain-ops/state" + "github.com/ethereum-optimism/optimism/op-service/eth" ) // PrecompileCount represents the number of precompile addresses @@ -46,7 +47,7 @@ func setProxies(db vm.StateDB, proxyAdminAddr common.Address, namespace *big.Int } db.SetCode(addr, depBytecode) - db.SetState(addr, AdminSlot, proxyAdminAddr.Hash()) + db.SetState(addr, AdminSlot, eth.AddressAsLeftPaddedHash(proxyAdminAddr)) log.Trace("Set proxy", "address", addr, "admin", proxyAdminAddr) } diff --git a/op-chain-ops/genesis/testdata/test-deploy-config-full.json b/op-chain-ops/genesis/testdata/test-deploy-config-full.json index e496fce29090e..d2f7b980ddae6 100644 --- a/op-chain-ops/genesis/testdata/test-deploy-config-full.json +++ b/op-chain-ops/genesis/testdata/test-deploy-config-full.json @@ -62,6 +62,7 @@ "governanceTokenOwner": "0x0000000000000000000000000000000000000333", "deploymentWaitConfirmations": 1, "eip1559Denominator": 8, + "eip1559DenominatorCanyon": 12, "eip1559Elasticity": 2, "fundDevAccounts": true, "faultGameAbsolutePrestate": "0x0000000000000000000000000000000000000000000000000000000000000000", diff --git a/op-chain-ops/state/encoding.go b/op-chain-ops/state/encoding.go index 5e98aba83d29f..041599bf42327 100644 --- a/op-chain-ops/state/encoding.go +++ b/op-chain-ops/state/encoding.go @@ -8,11 +8,12 @@ import ( "regexp" "strings" - "github.com/ethereum-optimism/optimism/op-bindings/solc" - "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common/hexutil" "github.com/ethereum/go-ethereum/crypto" + + "github.com/ethereum-optimism/optimism/op-bindings/solc" + "github.com/ethereum-optimism/optimism/op-service/eth" ) // EncodeStorageKeyValue encodes the key value pair that is stored in state @@ -330,20 +331,20 @@ func encodeAddressValue(value any) (common.Hash, error) { if !ok { return common.Hash{}, errInvalidType } - return address.Hash(), nil + return eth.AddressAsLeftPaddedHash(*address), nil } else { address, ok := value.(common.Address) if !ok { return common.Hash{}, errInvalidType } - return address.Hash(), nil + return eth.AddressAsLeftPaddedHash(address), nil } case "string": address, ok := value.(string) if !ok { return common.Hash{}, errInvalidType } - return common.HexToAddress(address).Hash(), nil + return eth.AddressAsLeftPaddedHash(common.HexToAddress(address)), nil default: return common.Hash{}, errInvalidType } diff --git a/op-challenger/Dockerfile b/op-challenger/Dockerfile index b234dae70e2cf..ad57e2b52b6fa 100644 --- a/op-challenger/Dockerfile +++ b/op-challenger/Dockerfile @@ -1,56 +1,17 @@ -FROM --platform=$BUILDPLATFORM golang:1.21.1-alpine3.18 as builder - -ARG VERSION=v0.0.0 - -RUN apk add --no-cache make gcc musl-dev linux-headers git jq bash - -COPY ./go.mod /app/go.mod -COPY ./go.sum /app/go.sum - -WORKDIR /app - -RUN go mod download - -# build op-challenger with the shared go.mod & go.sum files -COPY ./op-challenger /app/op-challenger -COPY ./op-program /app/op-program -COPY ./op-preimage /app/op-preimage -COPY ./op-bindings /app/op-bindings -COPY ./op-node /app/op-node -COPY ./op-service /app/op-service -COPY ./.git /app/.git - -# Copy cannon and its dependencies -COPY ./cannon /app/cannon -COPY ./op-preimage /app/op-preimage -COPY ./op-chain-ops /app/op-chain-ops - -WORKDIR /app/op-program - -ARG TARGETOS TARGETARCH - -RUN make op-program-host VERSION="$VERSION" GOOS=$TARGETOS GOARCH=$TARGETARCH - -WORKDIR /app/cannon - -ARG TARGETOS TARGETARCH - -RUN make cannon VERSION="$VERSION" GOOS=$TARGETOS GOARCH=$TARGETARCH - -WORKDIR /app/op-challenger - -RUN make op-challenger VERSION="$VERSION" GOOS=$TARGETOS GOARCH=$TARGETARCH +ARG OP_STACK_GO_BUILDER=us-docker.pkg.dev/oplabs-tools-artifacts/images/op-stack-go:latest +FROM $OP_STACK_GO_BUILDER as builder +# See "make golang-docker" and /ops/docker/op-stack-go FROM alpine:3.18 # Make the bundled op-program the default cannon server -COPY --from=builder /app/op-program/bin/op-program /usr/local/bin +COPY --from=builder /usr/local/bin/op-program /usr/local/bin/op-program ENV OP_CHALLENGER_CANNON_SERVER /usr/local/bin/op-program # Make the bundled cannon the default cannon executable -COPY --from=builder /app/cannon/bin/cannon /usr/local/bin +COPY --from=builder /usr/local/bin/cannon /usr/local/bin/cannon ENV OP_CHALLENGER_CANNON_BIN /usr/local/bin/cannon -COPY --from=builder /app/op-challenger/bin/op-challenger /usr/local/bin +COPY --from=builder /usr/local/bin/op-challenger /usr/local/bin/op-challenger CMD ["op-challenger"] diff --git a/op-challenger/Dockerfile.dockerignore b/op-challenger/Dockerfile.dockerignore new file mode 100644 index 0000000000000..4f26140750a08 --- /dev/null +++ b/op-challenger/Dockerfile.dockerignore @@ -0,0 +1,2 @@ +# ignore everything but the dockerfile, the op-stack-go base image performs the build +* diff --git a/op-challenger/Makefile b/op-challenger/Makefile index 009790c2b99bf..eadb663e88cd8 100644 --- a/op-challenger/Makefile +++ b/op-challenger/Makefile @@ -1,5 +1,5 @@ -GITCOMMIT := $(shell git rev-parse HEAD) -GITDATE := $(shell git show -s --format='%ct') +GITCOMMIT ?= $(shell git rev-parse HEAD) +GITDATE ?= $(shell git show -s --format='%ct') VERSION := v0.0.0 LDFLAGSSTRING +=-X main.GitCommit=$(GITCOMMIT) @@ -16,9 +16,6 @@ clean: test: go test -v ./... -lint: - golangci-lint run -E goimports,sqlclosecheck,bodyclose,asciicheck,misspell,errorlint --timeout 5m -e "errors.As" -e "errors.Is" ./... - visualize: ./scripts/visualize.sh diff --git a/op-challenger/cmd/main.go b/op-challenger/cmd/main.go index f33ac22d7de2e..7909b834ba9f1 100644 --- a/op-challenger/cmd/main.go +++ b/op-challenger/cmd/main.go @@ -5,6 +5,7 @@ import ( "os" op_challenger "github.com/ethereum-optimism/optimism/op-challenger" + opservice "github.com/ethereum-optimism/optimism/op-service" "github.com/ethereum/go-ethereum/log" "github.com/urfave/cli/v2" @@ -21,19 +22,7 @@ var ( ) // VersionWithMeta holds the textual version string including the metadata. -var VersionWithMeta = func() string { - v := version.Version - if GitCommit != "" { - v += "-" + GitCommit[:8] - } - if GitDate != "" { - v += "-" + GitDate - } - if version.Meta != "" { - v += "-" + version.Meta - } - return v -}() +var VersionWithMeta = opservice.FormatVersion(version.Version, GitCommit, GitDate, version.Meta) func main() { args := os.Args diff --git a/op-challenger/cmd/main_test.go b/op-challenger/cmd/main_test.go index 2ba686b3e60c6..6c48087985b7d 100644 --- a/op-challenger/cmd/main_test.go +++ b/op-challenger/cmd/main_test.go @@ -7,7 +7,6 @@ import ( "time" "github.com/ethereum-optimism/optimism/op-challenger/config" - "github.com/ethereum-optimism/optimism/op-node/chaincfg" "github.com/ethereum-optimism/optimism/op-service/txmgr" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/log" @@ -17,8 +16,8 @@ import ( var ( l1EthRpc = "http://example.com:8545" gameFactoryAddressValue = "0xbb00000000000000000000000000000000000000" - cannonNetwork = chaincfg.AvailableNetworks()[0] - otherCannonNetwork = chaincfg.AvailableNetworks()[1] + cannonNetwork = "op-mainnet" + otherCannonNetwork = "op-goerli" cannonBin = "./bin/cannon" cannonServer = "./bin/op-program" cannonPreState = "./pre.json" @@ -46,14 +45,14 @@ func TestLogLevel(t *testing.T) { func TestDefaultCLIOptionsMatchDefaultConfig(t *testing.T) { cfg := configForArgs(t, addRequiredArgs(config.TraceTypeAlphabet)) - defaultCfg := config.NewConfig(common.HexToAddress(gameFactoryAddressValue), l1EthRpc, config.TraceTypeAlphabet, true, datadir) + defaultCfg := config.NewConfig(common.HexToAddress(gameFactoryAddressValue), l1EthRpc, true, datadir, config.TraceTypeAlphabet) // Add in the extra CLI options required when using alphabet trace type defaultCfg.AlphabetTrace = alphabetTrace require.Equal(t, defaultCfg, cfg) } func TestDefaultConfigIsValid(t *testing.T) { - cfg := config.NewConfig(common.HexToAddress(gameFactoryAddressValue), l1EthRpc, config.TraceTypeAlphabet, true, datadir) + cfg := config.NewConfig(common.HexToAddress(gameFactoryAddressValue), l1EthRpc, true, datadir, config.TraceTypeAlphabet) // Add in options that are required based on the specific trace type // To avoid needing to specify unused options, these aren't included in the params for NewConfig cfg.AlphabetTrace = alphabetTrace @@ -82,7 +81,7 @@ func TestTraceType(t *testing.T) { traceType := traceType t.Run("Valid_"+traceType.String(), func(t *testing.T) { cfg := configForArgs(t, addRequiredArgs(traceType)) - require.Equal(t, traceType, cfg.TraceType) + require.Equal(t, []config.TraceType{traceType}, cfg.TraceTypes) }) } @@ -91,6 +90,41 @@ func TestTraceType(t *testing.T) { }) } +func TestMultipleTraceTypes(t *testing.T) { + t.Run("WithAllOptions", func(t *testing.T) { + argsMap := requiredArgs(config.TraceTypeCannon) + addRequiredOutputCannonArgs(argsMap) + addRequiredAlphabetArgs(argsMap) + args := toArgList(argsMap) + // Add extra trace types (cannon is already specified) + args = append(args, + "--trace-type", config.TraceTypeOutputCannon.String(), + "--trace-type", config.TraceTypeAlphabet.String()) + cfg := configForArgs(t, args) + require.Equal(t, []config.TraceType{config.TraceTypeCannon, config.TraceTypeOutputCannon, config.TraceTypeAlphabet}, cfg.TraceTypes) + }) + t.Run("WithSomeOptions", func(t *testing.T) { + argsMap := requiredArgs(config.TraceTypeCannon) + addRequiredAlphabetArgs(argsMap) + args := toArgList(argsMap) + // Add extra trace types (cannon is already specified) + args = append(args, + "--trace-type", config.TraceTypeAlphabet.String()) + cfg := configForArgs(t, args) + require.Equal(t, []config.TraceType{config.TraceTypeCannon, config.TraceTypeAlphabet}, cfg.TraceTypes) + }) + + t.Run("SpecifySameOptionMultipleTimes", func(t *testing.T) { + argsMap := requiredArgs(config.TraceTypeCannon) + args := toArgList(argsMap) + // Add cannon trace type again + args = append(args, "--trace-type", config.TraceTypeCannon.String()) + // We're fine with the same option being listed multiple times, just deduplicate them. + cfg := configForArgs(t, args) + require.Equal(t, []config.TraceType{config.TraceTypeCannon}, cfg.TraceTypes) + }) +} + func TestGameFactoryAddress(t *testing.T) { t.Run("Required", func(t *testing.T) { verifyArgsInvalid(t, "flag game-factory-address is required", addRequiredArgsExcept(config.TraceTypeAlphabet, "--game-factory-address")) @@ -441,20 +475,32 @@ func requiredArgs(traceType config.TraceType) map[string]string { } switch traceType { case config.TraceTypeAlphabet: - args["--alphabet"] = alphabetTrace - case config.TraceTypeCannon, config.TraceTypeOutputCannon: - args["--cannon-network"] = cannonNetwork - args["--cannon-bin"] = cannonBin - args["--cannon-server"] = cannonServer - args["--cannon-prestate"] = cannonPreState - args["--cannon-l2"] = cannonL2 - } - if traceType == config.TraceTypeOutputCannon { - args["--rollup-rpc"] = rollupRpc + addRequiredAlphabetArgs(args) + case config.TraceTypeCannon: + addRequiredCannonArgs(args) + case config.TraceTypeOutputCannon: + addRequiredOutputCannonArgs(args) } return args } +func addRequiredAlphabetArgs(args map[string]string) { + args["--alphabet"] = alphabetTrace +} + +func addRequiredOutputCannonArgs(args map[string]string) { + addRequiredCannonArgs(args) + args["--rollup-rpc"] = rollupRpc +} + +func addRequiredCannonArgs(args map[string]string) { + args["--cannon-network"] = cannonNetwork + args["--cannon-bin"] = cannonBin + args["--cannon-server"] = cannonServer + args["--cannon-prestate"] = cannonPreState + args["--cannon-l2"] = cannonL2 +} + func toArgList(req map[string]string) []string { var combined []string for name, value := range req { diff --git a/op-challenger/config/config.go b/op-challenger/config/config.go index 2c226fcc2f999..801a7433e3fd6 100644 --- a/op-challenger/config/config.go +++ b/op-challenger/config/config.go @@ -4,6 +4,7 @@ import ( "errors" "fmt" "runtime" + "slices" "time" "github.com/ethereum/go-ethereum/common" @@ -15,7 +16,7 @@ import ( ) var ( - ErrMissingTraceType = errors.New("missing trace type") + ErrMissingTraceType = errors.New("no supported trace types specified") ErrMissingDatadir = errors.New("missing datadir") ErrMaxConcurrencyZero = errors.New("max concurrency must not be 0") ErrMissingCannonL2 = errors.New("missing cannon L2") @@ -108,7 +109,7 @@ type Config struct { MaxConcurrency uint // Maximum number of threads to use when progressing games PollInterval time.Duration // Polling interval for latest-block subscription when using an HTTP RPC provider - TraceType TraceType // Type of trace + TraceTypes []TraceType // Type of traces supported // Specific to the alphabet trace provider AlphabetTrace string // String for the AlphabetTraceProvider @@ -135,9 +136,9 @@ type Config struct { func NewConfig( gameFactoryAddress common.Address, l1EthRpc string, - traceType TraceType, agreeWithProposedOutput bool, datadir string, + supportedTraceTypes ...TraceType, ) Config { return Config{ L1EthRpc: l1EthRpc, @@ -147,7 +148,7 @@ func NewConfig( AgreeWithProposedOutput: agreeWithProposedOutput, - TraceType: traceType, + TraceTypes: supportedTraceTypes, TxMgrConfig: txmgr.NewCLIConfig(l1EthRpc, txmgr.DefaultChallengerFlagValues), MetricsConfig: opmetrics.DefaultCLIConfig(), @@ -161,6 +162,10 @@ func NewConfig( } } +func (c Config) TraceTypeEnabled(t TraceType) bool { + return slices.Contains(c.TraceTypes, t) +} + func (c Config) Check() error { if c.L1EthRpc == "" { return ErrMissingL1EthRPC @@ -168,7 +173,7 @@ func (c Config) Check() error { if c.GameFactoryAddress == (common.Address{}) { return ErrMissingGameFactoryAddress } - if c.TraceType == "" { + if len(c.TraceTypes) == 0 { return ErrMissingTraceType } if c.Datadir == "" { @@ -177,12 +182,12 @@ func (c Config) Check() error { if c.MaxConcurrency == 0 { return ErrMaxConcurrencyZero } - if c.TraceType == TraceTypeOutputCannon { + if c.TraceTypeEnabled(TraceTypeOutputCannon) { if c.RollupRpc == "" { return ErrMissingRollupRpc } } - if c.TraceType == TraceTypeCannon || c.TraceType == TraceTypeOutputCannon { + if c.TraceTypeEnabled(TraceTypeCannon) || c.TraceTypeEnabled(TraceTypeOutputCannon) { if c.CannonBin == "" { return ErrMissingCannonBin } @@ -220,7 +225,7 @@ func (c Config) Check() error { return ErrMissingCannonInfoFreq } } - if c.TraceType == TraceTypeAlphabet && c.AlphabetTrace == "" { + if c.TraceTypeEnabled(TraceTypeAlphabet) && c.AlphabetTrace == "" { return ErrMissingAlphabetTrace } if err := c.TxMgrConfig.Check(); err != nil { diff --git a/op-challenger/config/config_test.go b/op-challenger/config/config_test.go index 84f8a0e977dd8..c5d32db2eaa00 100644 --- a/op-challenger/config/config_test.go +++ b/op-challenger/config/config_test.go @@ -25,7 +25,7 @@ var ( ) func validConfig(traceType TraceType) Config { - cfg := NewConfig(validGameFactoryAddress, validL1EthRpc, traceType, agreeWithProposedOutput, validDatadir) + cfg := NewConfig(validGameFactoryAddress, validL1EthRpc, agreeWithProposedOutput, validDatadir, traceType) switch traceType { case TraceTypeAlphabet: cfg.AlphabetTrace = validAlphabetTrace @@ -194,3 +194,26 @@ func TestNetworkMustBeValid(t *testing.T) { cfg.CannonNetwork = "unknown" require.ErrorIs(t, cfg.Check(), ErrCannonNetworkUnknown) } + +func TestRequireConfigForAllSupportedTraceTypes(t *testing.T) { + cfg := validConfig(TraceTypeCannon) + cfg.TraceTypes = []TraceType{TraceTypeCannon, TraceTypeOutputCannon, TraceTypeAlphabet} + // Set all required options and check its valid + cfg.RollupRpc = validRollupRpc + cfg.AlphabetTrace = validAlphabetTrace + require.NoError(t, cfg.Check()) + + // Require output cannon specific args + cfg.RollupRpc = "" + require.ErrorIs(t, cfg.Check(), ErrMissingRollupRpc) + cfg.RollupRpc = validRollupRpc + + // Require cannon specific args + cfg.CannonL2 = "" + require.ErrorIs(t, cfg.Check(), ErrMissingCannonL2) + cfg.CannonL2 = validCannonL2 + + // Require alphabet specific args + cfg.AlphabetTrace = "" + require.ErrorIs(t, cfg.Check(), ErrMissingAlphabetTrace) +} diff --git a/op-challenger/flags/flags.go b/op-challenger/flags/flags.go index 0d79abaeb41a2..4704cde41bfb3 100644 --- a/op-challenger/flags/flags.go +++ b/op-challenger/flags/flags.go @@ -3,6 +3,7 @@ package flags import ( "fmt" "runtime" + "slices" "strings" "github.com/ethereum/go-ethereum/common" @@ -44,14 +45,10 @@ var ( "If empty, the challenger will play all games.", EnvVars: prefixEnvVars("GAME_ALLOWLIST"), } - TraceTypeFlag = &cli.GenericFlag{ + TraceTypeFlag = &cli.StringSliceFlag{ Name: "trace-type", - Usage: "The trace type. Valid options: " + openum.EnumString(config.TraceTypes), + Usage: "The trace types to support. Valid options: " + openum.EnumString(config.TraceTypes), EnvVars: prefixEnvVars("TRACE_TYPE"), - Value: func() *config.TraceType { - out := config.TraceType("") // No default value - return &out - }(), } AgreeWithProposedOutputFlag = &cli.BoolFlag{ Name: "agree-with-proposed-output", @@ -210,38 +207,57 @@ func CheckCannonFlags(ctx *cli.Context) error { return nil } -func CheckRequired(ctx *cli.Context) error { +func CheckRequired(ctx *cli.Context, traceTypes []config.TraceType) error { for _, f := range requiredFlags { if !ctx.IsSet(f.Names()[0]) { return fmt.Errorf("flag %s is required", f.Names()[0]) } } - gameType := config.TraceType(strings.ToLower(ctx.String(TraceTypeFlag.Name))) - switch gameType { - case config.TraceTypeCannon: - if err := CheckCannonFlags(ctx); err != nil { - return err - } - case config.TraceTypeAlphabet: - if !ctx.IsSet(AlphabetFlag.Name) { - return fmt.Errorf("flag %s is required", "alphabet") + for _, traceType := range traceTypes { + switch traceType { + case config.TraceTypeCannon: + if err := CheckCannonFlags(ctx); err != nil { + return err + } + case config.TraceTypeAlphabet: + if !ctx.IsSet(AlphabetFlag.Name) { + return fmt.Errorf("flag %s is required", "alphabet") + } + case config.TraceTypeOutputCannon: + if err := CheckCannonFlags(ctx); err != nil { + return err + } + if !ctx.IsSet(RollupRpcFlag.Name) { + return fmt.Errorf("flag %s is required", RollupRpcFlag.Name) + } + default: + return fmt.Errorf("invalid trace type. must be one of %v", config.TraceTypes) } - case config.TraceTypeOutputCannon: - if err := CheckCannonFlags(ctx); err != nil { - return err + } + return nil +} + +func parseTraceTypes(ctx *cli.Context) ([]config.TraceType, error) { + var traceTypes []config.TraceType + for _, typeName := range ctx.StringSlice(TraceTypeFlag.Name) { + traceType := new(config.TraceType) + if err := traceType.Set(typeName); err != nil { + return nil, err } - if !ctx.IsSet(RollupRpcFlag.Name) { - return fmt.Errorf("flag %s is required", RollupRpcFlag.Name) + if !slices.Contains(traceTypes, *traceType) { + traceTypes = append(traceTypes, *traceType) } - default: - return fmt.Errorf("invalid trace type. must be one of %v", config.TraceTypes) } - return nil + return traceTypes, nil } // NewConfigFromCLI parses the Config from the provided flags or environment variables. func NewConfigFromCLI(ctx *cli.Context) (*config.Config, error) { - if err := CheckRequired(ctx); err != nil { + traceTypes, err := parseTraceTypes(ctx) + if err != nil { + return nil, err + } + if err := CheckRequired(ctx, traceTypes); err != nil { return nil, err } gameFactoryAddress, err := opservice.ParseAddress(ctx.String(FactoryAddressFlag.Name)) @@ -263,8 +279,6 @@ func NewConfigFromCLI(ctx *cli.Context) (*config.Config, error) { metricsConfig := opmetrics.ReadCLIConfig(ctx) pprofConfig := oppprof.ReadCLIConfig(ctx) - traceTypeFlag := config.TraceType(strings.ToLower(ctx.String(TraceTypeFlag.Name))) - maxConcurrency := ctx.Uint(MaxConcurrencyFlag.Name) if maxConcurrency == 0 { return nil, fmt.Errorf("%v must not be 0", MaxConcurrencyFlag.Name) @@ -272,7 +286,7 @@ func NewConfigFromCLI(ctx *cli.Context) (*config.Config, error) { return &config.Config{ // Required Flags L1EthRpc: ctx.String(L1EthRpcFlag.Name), - TraceType: traceTypeFlag, + TraceTypes: traceTypes, GameFactoryAddress: gameFactoryAddress, GameAllowlist: allowedGames, GameWindow: ctx.Duration(GameWindowFlag.Name), diff --git a/op-challenger/game/fault/agent.go b/op-challenger/game/fault/agent.go index a650a3b2a095b..2279226f8bd8d 100644 --- a/op-challenger/game/fault/agent.go +++ b/op-challenger/game/fault/agent.go @@ -25,7 +25,7 @@ type Responder interface { } type ClaimLoader interface { - FetchClaims(ctx context.Context) ([]types.Claim, error) + GetAllClaims(ctx context.Context) ([]types.Claim, error) } type Agent struct { @@ -39,7 +39,7 @@ type Agent struct { log log.Logger } -func NewAgent(m metrics.Metricer, loader ClaimLoader, maxDepth int, trace types.TraceProvider, responder Responder, updater types.OracleUpdater, agreeWithProposedOutput bool, log log.Logger) *Agent { +func NewAgent(m metrics.Metricer, loader ClaimLoader, maxDepth int, trace types.TraceAccessor, responder Responder, updater types.OracleUpdater, agreeWithProposedOutput bool, log log.Logger) *Agent { return &Agent{ metrics: m, solver: solver.NewGameSolver(maxDepth, trace), @@ -136,7 +136,7 @@ func (a *Agent) tryResolve(ctx context.Context) bool { var errNoResolvableClaims = errors.New("no resolvable claims") func (a *Agent) tryResolveClaims(ctx context.Context) error { - claims, err := a.loader.FetchClaims(ctx) + claims, err := a.loader.GetAllClaims(ctx) if err != nil { return fmt.Errorf("failed to fetch claims: %w", err) } @@ -189,7 +189,7 @@ func (a *Agent) resolveClaims(ctx context.Context) error { // newGameFromContracts initializes a new game state from the state in the contract func (a *Agent) newGameFromContracts(ctx context.Context) (types.Game, error) { - claims, err := a.loader.FetchClaims(ctx) + claims, err := a.loader.GetAllClaims(ctx) if err != nil { return nil, fmt.Errorf("failed to fetch claims: %w", err) } diff --git a/op-challenger/game/fault/agent_test.go b/op-challenger/game/fault/agent_test.go index c6b1904c74b17..c9dec73148aae 100644 --- a/op-challenger/game/fault/agent_test.go +++ b/op-challenger/game/fault/agent_test.go @@ -5,6 +5,7 @@ import ( "errors" "testing" + "github.com/ethereum-optimism/optimism/op-challenger/game/fault/trace" "github.com/stretchr/testify/require" "github.com/ethereum/go-ethereum/log" @@ -112,10 +113,10 @@ func setupTestAgent(t *testing.T, agreeWithProposedOutput bool) (*Agent, *stubCl logger := testlog.Logger(t, log.LvlInfo) claimLoader := &stubClaimLoader{} depth := 4 - trace := alphabet.NewTraceProvider("abcd", uint64(depth)) + provider := alphabet.NewTraceProvider("abcd", uint64(depth)) responder := &stubResponder{} updater := &stubUpdater{} - agent := NewAgent(metrics.NoopMetrics, claimLoader, depth, trace, responder, updater, agreeWithProposedOutput, logger) + agent := NewAgent(metrics.NoopMetrics, claimLoader, depth, trace.NewSimpleTraceAccessor(provider), responder, updater, agreeWithProposedOutput, logger) return agent, claimLoader, responder } @@ -124,7 +125,7 @@ type stubClaimLoader struct { claims []types.Claim } -func (s *stubClaimLoader) FetchClaims(ctx context.Context) ([]types.Claim, error) { +func (s *stubClaimLoader) GetAllClaims(ctx context.Context) ([]types.Claim, error) { s.callCount++ return s.claims, nil } diff --git a/op-challenger/game/fault/contracts/faultdisputegame.go b/op-challenger/game/fault/contracts/faultdisputegame.go new file mode 100644 index 0000000000000..d5094e9ed1aa4 --- /dev/null +++ b/op-challenger/game/fault/contracts/faultdisputegame.go @@ -0,0 +1,214 @@ +package contracts + +import ( + "context" + "fmt" + "math/big" + + "github.com/ethereum-optimism/optimism/op-bindings/bindings" + "github.com/ethereum-optimism/optimism/op-challenger/game/fault/types" + gameTypes "github.com/ethereum-optimism/optimism/op-challenger/game/types" + "github.com/ethereum-optimism/optimism/op-service/sources/batching" + "github.com/ethereum-optimism/optimism/op-service/txmgr" + "github.com/ethereum/go-ethereum/common" +) + +const ( + methodGameDuration = "GAME_DURATION" + methodMaxGameDepth = "MAX_GAME_DEPTH" + methodAbsolutePrestate = "ABSOLUTE_PRESTATE" + methodStatus = "status" + methodClaimCount = "claimDataLen" + methodClaim = "claimData" + methodL1Head = "l1Head" + methodProposals = "proposals" + methodResolve = "resolve" + methodResolveClaim = "resolveClaim" + methodAttack = "attack" + methodDefend = "defend" + methodStep = "step" +) + +type FaultDisputeGameContract struct { + multiCaller *batching.MultiCaller + contract *batching.BoundContract +} + +type Proposal struct { + Index *big.Int + L2BlockNumber *big.Int + OutputRoot common.Hash +} + +func NewFaultDisputeGameContract(addr common.Address, caller *batching.MultiCaller) (*FaultDisputeGameContract, error) { + fdgAbi, err := bindings.FaultDisputeGameMetaData.GetAbi() + if err != nil { + return nil, fmt.Errorf("failed to load fault dispute game ABI: %w", err) + } + + return &FaultDisputeGameContract{ + multiCaller: caller, + contract: batching.NewBoundContract(fdgAbi, addr), + }, nil +} + +func (f *FaultDisputeGameContract) GetGameDuration(ctx context.Context) (uint64, error) { + result, err := f.multiCaller.SingleCall(ctx, batching.BlockLatest, f.contract.Call(methodGameDuration)) + if err != nil { + return 0, fmt.Errorf("failed to fetch game duration: %w", err) + } + return result.GetUint64(0), nil +} + +func (f *FaultDisputeGameContract) GetMaxGameDepth(ctx context.Context) (uint64, error) { + result, err := f.multiCaller.SingleCall(ctx, batching.BlockLatest, f.contract.Call(methodMaxGameDepth)) + if err != nil { + return 0, fmt.Errorf("failed to fetch max game depth: %w", err) + } + return result.GetBigInt(0).Uint64(), nil +} + +func (f *FaultDisputeGameContract) GetAbsolutePrestateHash(ctx context.Context) (common.Hash, error) { + result, err := f.multiCaller.SingleCall(ctx, batching.BlockLatest, f.contract.Call(methodAbsolutePrestate)) + if err != nil { + return common.Hash{}, fmt.Errorf("failed to fetch absolute prestate hash: %w", err) + } + return result.GetHash(0), nil +} + +func (f *FaultDisputeGameContract) GetL1Head(ctx context.Context) (common.Hash, error) { + result, err := f.multiCaller.SingleCall(ctx, batching.BlockLatest, f.contract.Call(methodL1Head)) + if err != nil { + return common.Hash{}, fmt.Errorf("failed to fetch L1 head: %w", err) + } + return result.GetHash(0), nil +} + +// GetProposals returns the agreed and disputed proposals +func (f *FaultDisputeGameContract) GetProposals(ctx context.Context) (Proposal, Proposal, error) { + result, err := f.multiCaller.SingleCall(ctx, batching.BlockLatest, f.contract.Call(methodProposals)) + if err != nil { + return Proposal{}, Proposal{}, fmt.Errorf("failed to fetch proposals: %w", err) + } + + var agreed, disputed Proposal + result.GetStruct(0, &agreed) + result.GetStruct(1, &disputed) + return agreed, disputed, nil +} + +func (f *FaultDisputeGameContract) GetStatus(ctx context.Context) (gameTypes.GameStatus, error) { + result, err := f.multiCaller.SingleCall(ctx, batching.BlockLatest, f.contract.Call(methodStatus)) + if err != nil { + return 0, fmt.Errorf("failed to fetch status: %w", err) + } + return gameTypes.GameStatusFromUint8(result.GetUint8(0)) +} + +func (f *FaultDisputeGameContract) GetClaimCount(ctx context.Context) (uint64, error) { + result, err := f.multiCaller.SingleCall(ctx, batching.BlockLatest, f.contract.Call(methodClaimCount)) + if err != nil { + return 0, fmt.Errorf("failed to fetch claim count: %w", err) + } + return result.GetBigInt(0).Uint64(), nil +} + +func (f *FaultDisputeGameContract) GetClaim(ctx context.Context, idx uint64) (types.Claim, error) { + result, err := f.multiCaller.SingleCall(ctx, batching.BlockLatest, f.contract.Call(methodClaim, new(big.Int).SetUint64(idx))) + if err != nil { + return types.Claim{}, fmt.Errorf("failed to fetch claim %v: %w", idx, err) + } + return f.decodeClaim(result, int(idx)), nil +} + +func (f *FaultDisputeGameContract) GetAllClaims(ctx context.Context) ([]types.Claim, error) { + count, err := f.GetClaimCount(ctx) + if err != nil { + return nil, fmt.Errorf("failed to load claim count: %w", err) + } + + calls := make([]*batching.ContractCall, count) + for i := uint64(0); i < count; i++ { + calls[i] = f.contract.Call(methodClaim, new(big.Int).SetUint64(i)) + } + + results, err := f.multiCaller.Call(ctx, batching.BlockLatest, calls...) + if err != nil { + return nil, fmt.Errorf("failed to fetch claim data: %w", err) + } + + var claims []types.Claim + for idx, result := range results { + claims = append(claims, f.decodeClaim(result, idx)) + } + return claims, nil +} + +func (f *FaultDisputeGameContract) AttackTx(parentContractIndex uint64, pivot common.Hash) (txmgr.TxCandidate, error) { + call := f.contract.Call(methodAttack, new(big.Int).SetUint64(parentContractIndex), pivot) + return call.ToTxCandidate() +} + +func (f *FaultDisputeGameContract) DefendTx(parentContractIndex uint64, pivot common.Hash) (txmgr.TxCandidate, error) { + call := f.contract.Call(methodDefend, new(big.Int).SetUint64(parentContractIndex), pivot) + return call.ToTxCandidate() +} + +func (f *FaultDisputeGameContract) StepTx(claimIdx uint64, isAttack bool, stateData []byte, proof []byte) (txmgr.TxCandidate, error) { + call := f.contract.Call(methodStep, new(big.Int).SetUint64(claimIdx), isAttack, stateData, proof) + return call.ToTxCandidate() +} + +func (f *FaultDisputeGameContract) CallResolveClaim(ctx context.Context, claimIdx uint64) error { + call := f.resolveClaimCall(claimIdx) + _, err := f.multiCaller.SingleCall(ctx, batching.BlockLatest, call) + if err != nil { + return fmt.Errorf("failed to call resolve claim: %w", err) + } + return nil +} + +func (f *FaultDisputeGameContract) ResolveClaimTx(claimIdx uint64) (txmgr.TxCandidate, error) { + call := f.resolveClaimCall(claimIdx) + return call.ToTxCandidate() +} + +func (f *FaultDisputeGameContract) resolveClaimCall(claimIdx uint64) *batching.ContractCall { + return f.contract.Call(methodResolveClaim, new(big.Int).SetUint64(claimIdx)) +} + +func (f *FaultDisputeGameContract) CallResolve(ctx context.Context) (gameTypes.GameStatus, error) { + call := f.resolveCall() + result, err := f.multiCaller.SingleCall(ctx, batching.BlockLatest, call) + if err != nil { + return gameTypes.GameStatusInProgress, fmt.Errorf("failed to call resolve: %w", err) + } + return gameTypes.GameStatusFromUint8(result.GetUint8(0)) +} + +func (f *FaultDisputeGameContract) ResolveTx() (txmgr.TxCandidate, error) { + call := f.resolveCall() + return call.ToTxCandidate() +} + +func (f *FaultDisputeGameContract) resolveCall() *batching.ContractCall { + return f.contract.Call(methodResolve) +} + +func (f *FaultDisputeGameContract) decodeClaim(result *batching.CallResult, contractIndex int) types.Claim { + parentIndex := result.GetUint32(0) + countered := result.GetBool(1) + claim := result.GetHash(2) + position := result.GetBigInt(3) + clock := result.GetBigInt(4) + return types.Claim{ + ClaimData: types.ClaimData{ + Value: claim, + Position: types.NewPositionFromGIndex(position), + }, + Countered: countered, + Clock: clock.Uint64(), + ContractIndex: contractIndex, + ParentContractIndex: int(parentIndex), + } +} diff --git a/op-challenger/game/fault/contracts/faultdisputegame_test.go b/op-challenger/game/fault/contracts/faultdisputegame_test.go new file mode 100644 index 0000000000000..641a5bf97e80b --- /dev/null +++ b/op-challenger/game/fault/contracts/faultdisputegame_test.go @@ -0,0 +1,261 @@ +package contracts + +import ( + "context" + "math" + "math/big" + "testing" + + "github.com/ethereum-optimism/optimism/op-bindings/bindings" + faultTypes "github.com/ethereum-optimism/optimism/op-challenger/game/fault/types" + "github.com/ethereum-optimism/optimism/op-challenger/game/types" + "github.com/ethereum-optimism/optimism/op-service/sources/batching" + batchingTest "github.com/ethereum-optimism/optimism/op-service/sources/batching/test" + "github.com/ethereum/go-ethereum/common" + "github.com/stretchr/testify/require" +) + +func TestSimpleGetters(t *testing.T) { + tests := []struct { + method string + args []interface{} + result interface{} + expected interface{} // Defaults to expecting the same as result + call func(game *FaultDisputeGameContract) (any, error) + }{ + { + method: methodStatus, + result: types.GameStatusChallengerWon, + call: func(game *FaultDisputeGameContract) (any, error) { + return game.GetStatus(context.Background()) + }, + }, + { + method: methodGameDuration, + result: uint64(5566), + call: func(game *FaultDisputeGameContract) (any, error) { + return game.GetGameDuration(context.Background()) + }, + }, + { + method: methodMaxGameDepth, + result: big.NewInt(128), + expected: uint64(128), + call: func(game *FaultDisputeGameContract) (any, error) { + return game.GetMaxGameDepth(context.Background()) + }, + }, + { + method: methodAbsolutePrestate, + result: common.Hash{0xab}, + call: func(game *FaultDisputeGameContract) (any, error) { + return game.GetAbsolutePrestateHash(context.Background()) + }, + }, + { + method: methodClaimCount, + result: big.NewInt(9876), + expected: uint64(9876), + call: func(game *FaultDisputeGameContract) (any, error) { + return game.GetClaimCount(context.Background()) + }, + }, + { + method: methodL1Head, + result: common.Hash{0xdd, 0xbb}, + call: func(game *FaultDisputeGameContract) (any, error) { + return game.GetL1Head(context.Background()) + }, + }, + { + method: methodResolve, + result: types.GameStatusInProgress, + call: func(game *FaultDisputeGameContract) (any, error) { + return game.CallResolve(context.Background()) + }, + }, + } + for _, test := range tests { + test := test + t.Run(test.method, func(t *testing.T) { + stubRpc, game := setup(t) + stubRpc.SetResponse(test.method, batching.BlockLatest, nil, []interface{}{test.result}) + status, err := test.call(game) + require.NoError(t, err) + expected := test.expected + if expected == nil { + expected = test.result + } + require.Equal(t, expected, status) + }) + } +} + +func TestGetProposals(t *testing.T) { + stubRpc, game := setup(t) + agreedIndex := big.NewInt(5) + agreedBlockNum := big.NewInt(6) + agreedRoot := common.Hash{0xaa} + disputedIndex := big.NewInt(7) + disputedBlockNum := big.NewInt(8) + disputedRoot := common.Hash{0xdd} + agreed := Proposal{ + Index: agreedIndex, + L2BlockNumber: agreedBlockNum, + OutputRoot: agreedRoot, + } + disputed := Proposal{ + Index: disputedIndex, + L2BlockNumber: disputedBlockNum, + OutputRoot: disputedRoot, + } + stubRpc.SetResponse(methodProposals, batching.BlockLatest, []interface{}{}, []interface{}{ + agreed, disputed, + }) + actualAgreed, actualDisputed, err := game.GetProposals(context.Background()) + require.NoError(t, err) + require.Equal(t, agreed, actualAgreed) + require.Equal(t, disputed, actualDisputed) +} + +func TestGetClaim(t *testing.T) { + stubRpc, game := setup(t) + idx := big.NewInt(2) + parentIndex := uint32(1) + countered := true + value := common.Hash{0xab} + position := big.NewInt(2) + clock := big.NewInt(1234) + stubRpc.SetResponse(methodClaim, batching.BlockLatest, []interface{}{idx}, []interface{}{parentIndex, countered, value, position, clock}) + status, err := game.GetClaim(context.Background(), idx.Uint64()) + require.NoError(t, err) + require.Equal(t, faultTypes.Claim{ + ClaimData: faultTypes.ClaimData{ + Value: value, + Position: faultTypes.NewPositionFromGIndex(position), + }, + Countered: true, + Clock: 1234, + ContractIndex: int(idx.Uint64()), + ParentContractIndex: 1, + }, status) +} + +func TestGetAllClaims(t *testing.T) { + stubRpc, game := setup(t) + claim0 := faultTypes.Claim{ + ClaimData: faultTypes.ClaimData{ + Value: common.Hash{0xaa}, + Position: faultTypes.NewPositionFromGIndex(big.NewInt(1)), + }, + Countered: true, + Clock: 1234, + ContractIndex: 0, + ParentContractIndex: math.MaxUint32, + } + claim1 := faultTypes.Claim{ + ClaimData: faultTypes.ClaimData{ + Value: common.Hash{0xab}, + Position: faultTypes.NewPositionFromGIndex(big.NewInt(2)), + }, + Countered: true, + Clock: 4455, + ContractIndex: 1, + ParentContractIndex: 0, + } + claim2 := faultTypes.Claim{ + ClaimData: faultTypes.ClaimData{ + Value: common.Hash{0xbb}, + Position: faultTypes.NewPositionFromGIndex(big.NewInt(6)), + }, + Countered: false, + Clock: 7777, + ContractIndex: 2, + ParentContractIndex: 1, + } + expectedClaims := []faultTypes.Claim{claim0, claim1, claim2} + stubRpc.SetResponse(methodClaimCount, batching.BlockLatest, nil, []interface{}{big.NewInt(int64(len(expectedClaims)))}) + for _, claim := range expectedClaims { + expectGetClaim(stubRpc, claim) + } + claims, err := game.GetAllClaims(context.Background()) + require.NoError(t, err) + require.Equal(t, expectedClaims, claims) +} + +func TestCallResolveClaim(t *testing.T) { + stubRpc, game := setup(t) + stubRpc.SetResponse(methodResolveClaim, batching.BlockLatest, []interface{}{big.NewInt(123)}, nil) + err := game.CallResolveClaim(context.Background(), 123) + require.NoError(t, err) +} + +func TestResolveClaimTx(t *testing.T) { + stubRpc, game := setup(t) + stubRpc.SetResponse(methodResolveClaim, batching.BlockLatest, []interface{}{big.NewInt(123)}, nil) + tx, err := game.ResolveClaimTx(123) + require.NoError(t, err) + stubRpc.VerifyTxCandidate(tx) +} + +func TestResolveTx(t *testing.T) { + stubRpc, game := setup(t) + stubRpc.SetResponse(methodResolve, batching.BlockLatest, nil, nil) + tx, err := game.ResolveTx() + require.NoError(t, err) + stubRpc.VerifyTxCandidate(tx) +} + +func TestAttackTx(t *testing.T) { + stubRpc, game := setup(t) + value := common.Hash{0xaa} + stubRpc.SetResponse(methodAttack, batching.BlockLatest, []interface{}{big.NewInt(111), value}, nil) + tx, err := game.AttackTx(111, value) + require.NoError(t, err) + stubRpc.VerifyTxCandidate(tx) +} + +func TestDefendTx(t *testing.T) { + stubRpc, game := setup(t) + value := common.Hash{0xaa} + stubRpc.SetResponse(methodDefend, batching.BlockLatest, []interface{}{big.NewInt(111), value}, nil) + tx, err := game.DefendTx(111, value) + require.NoError(t, err) + stubRpc.VerifyTxCandidate(tx) +} + +func TestStepTx(t *testing.T) { + stubRpc, game := setup(t) + stateData := []byte{1, 2, 3} + proofData := []byte{4, 5, 6, 7, 8, 9} + stubRpc.SetResponse(methodStep, batching.BlockLatest, []interface{}{big.NewInt(111), true, stateData, proofData}, nil) + tx, err := game.StepTx(111, true, stateData, proofData) + require.NoError(t, err) + stubRpc.VerifyTxCandidate(tx) +} + +func expectGetClaim(stubRpc *batchingTest.AbiBasedRpc, claim faultTypes.Claim) { + stubRpc.SetResponse( + methodClaim, + batching.BlockLatest, + []interface{}{big.NewInt(int64(claim.ContractIndex))}, + []interface{}{ + uint32(claim.ParentContractIndex), + claim.Countered, + claim.Value, + claim.Position.ToGIndex(), + big.NewInt(int64(claim.Clock)), + }) +} + +func setup(t *testing.T) (*batchingTest.AbiBasedRpc, *FaultDisputeGameContract) { + fdgAbi, err := bindings.FaultDisputeGameMetaData.GetAbi() + require.NoError(t, err) + address := common.HexToAddress("0x24112842371dFC380576ebb09Ae16Cb6B6caD7CB") + + stubRpc := batchingTest.NewAbiBasedRpc(t, fdgAbi, address) + caller := batching.NewMultiCaller(stubRpc, 100) + game, err := NewFaultDisputeGameContract(address, caller) + require.NoError(t, err) + return stubRpc, game +} diff --git a/op-challenger/game/fault/contracts/gamefactory.go b/op-challenger/game/fault/contracts/gamefactory.go new file mode 100644 index 0000000000000..7b74ba533ade9 --- /dev/null +++ b/op-challenger/game/fault/contracts/gamefactory.go @@ -0,0 +1,60 @@ +package contracts + +import ( + "context" + "fmt" + "math/big" + + "github.com/ethereum-optimism/optimism/op-bindings/bindings" + "github.com/ethereum-optimism/optimism/op-challenger/game/types" + "github.com/ethereum-optimism/optimism/op-service/sources/batching" + "github.com/ethereum/go-ethereum/common" +) + +const ( + methodGameCount = "gameCount" + methodGameAtIndex = "gameAtIndex" +) + +type DisputeGameFactoryContract struct { + multiCaller *batching.MultiCaller + contract *batching.BoundContract +} + +func NewDisputeGameFactoryContract(addr common.Address, caller *batching.MultiCaller) (*DisputeGameFactoryContract, error) { + factoryAbi, err := bindings.DisputeGameFactoryMetaData.GetAbi() + if err != nil { + return nil, fmt.Errorf("failed to load dispute game factory ABI: %w", err) + } + return &DisputeGameFactoryContract{ + multiCaller: caller, + contract: batching.NewBoundContract(factoryAbi, addr), + }, nil +} + +func (f *DisputeGameFactoryContract) GetGameCount(ctx context.Context, blockNum uint64) (uint64, error) { + result, err := f.multiCaller.SingleCall(ctx, batching.BlockByNumber(blockNum), f.contract.Call(methodGameCount)) + if err != nil { + return 0, fmt.Errorf("failed to load game count: %w", err) + } + return result.GetBigInt(0).Uint64(), nil +} + +func (f *DisputeGameFactoryContract) GetGame(ctx context.Context, idx uint64, blockNum uint64) (types.GameMetadata, error) { + result, err := f.multiCaller.SingleCall(ctx, batching.BlockByNumber(blockNum), f.contract.Call(methodGameAtIndex, new(big.Int).SetUint64(idx))) + if err != nil { + return types.GameMetadata{}, fmt.Errorf("failed to load game %v: %w", idx, err) + } + return f.decodeGame(result), nil +} + +func (f *DisputeGameFactoryContract) decodeGame(result *batching.CallResult) types.GameMetadata { + gameType := result.GetUint8(0) + timestamp := result.GetUint64(1) + proxy := result.GetAddress(2) + return types.GameMetadata{ + GameType: gameType, + Timestamp: timestamp, + Proxy: proxy, + } +} diff --git a/op-challenger/game/fault/contracts/gamefactory_test.go b/op-challenger/game/fault/contracts/gamefactory_test.go new file mode 100644 index 0000000000000..15888cc419708 --- /dev/null +++ b/op-challenger/game/fault/contracts/gamefactory_test.go @@ -0,0 +1,99 @@ +package contracts + +import ( + "context" + "math/big" + "testing" + + "github.com/ethereum-optimism/optimism/op-bindings/bindings" + "github.com/ethereum-optimism/optimism/op-challenger/game/types" + "github.com/ethereum-optimism/optimism/op-service/sources/batching" + batchingTest "github.com/ethereum-optimism/optimism/op-service/sources/batching/test" + "github.com/ethereum/go-ethereum/common" + "github.com/stretchr/testify/require" +) + +func TestDisputeGameFactorySimpleGetters(t *testing.T) { + blockNum := uint64(23) + tests := []struct { + method string + args []interface{} + result interface{} + expected interface{} // Defaults to expecting the same as result + call func(game *DisputeGameFactoryContract) (any, error) + }{ + { + method: methodGameCount, + result: big.NewInt(9876), + expected: uint64(9876), + call: func(game *DisputeGameFactoryContract) (any, error) { + return game.GetGameCount(context.Background(), blockNum) + }, + }, + } + for _, test := range tests { + test := test + t.Run(test.method, func(t *testing.T) { + stubRpc, factory := setupDisputeGameFactoryTest(t) + stubRpc.SetResponse(test.method, batching.BlockByNumber(blockNum), nil, []interface{}{test.result}) + status, err := test.call(factory) + require.NoError(t, err) + expected := test.expected + if expected == nil { + expected = test.result + } + require.Equal(t, expected, status) + }) + } +} + +func TestLoadGame(t *testing.T) { + blockNum := uint64(23) + stubRpc, factory := setupDisputeGameFactoryTest(t) + game0 := types.GameMetadata{ + GameType: 0, + Timestamp: 1234, + Proxy: common.Address{0xaa}, + } + game1 := types.GameMetadata{ + GameType: 1, + Timestamp: 5678, + Proxy: common.Address{0xbb}, + } + game2 := types.GameMetadata{ + GameType: 99, + Timestamp: 9988, + Proxy: common.Address{0xcc}, + } + expectedGames := []types.GameMetadata{game0, game1, game2} + for idx, expected := range expectedGames { + expectGetGame(stubRpc, idx, blockNum, expected) + actual, err := factory.GetGame(context.Background(), uint64(idx), blockNum) + require.NoError(t, err) + require.Equal(t, expected, actual) + } +} + +func expectGetGame(stubRpc *batchingTest.AbiBasedRpc, idx int, blockNum uint64, game types.GameMetadata) { + stubRpc.SetResponse( + methodGameAtIndex, + batching.BlockByNumber(blockNum), + []interface{}{big.NewInt(int64(idx))}, + []interface{}{ + game.GameType, + game.Timestamp, + game.Proxy, + }) +} + +func setupDisputeGameFactoryTest(t *testing.T) (*batchingTest.AbiBasedRpc, *DisputeGameFactoryContract) { + fdgAbi, err := bindings.DisputeGameFactoryMetaData.GetAbi() + require.NoError(t, err) + address := common.HexToAddress("0x24112842371dFC380576ebb09Ae16Cb6B6caD7CB") + + stubRpc := batchingTest.NewAbiBasedRpc(t, fdgAbi, address) + caller := batching.NewMultiCaller(stubRpc, 100) + factory, err := NewDisputeGameFactoryContract(address, caller) + require.NoError(t, err) + return stubRpc, factory +} diff --git a/op-challenger/game/fault/loader.go b/op-challenger/game/fault/loader.go deleted file mode 100644 index 35cca96fe73eb..0000000000000 --- a/op-challenger/game/fault/loader.go +++ /dev/null @@ -1,153 +0,0 @@ -package fault - -import ( - "context" - "math/big" - - "github.com/ethereum-optimism/optimism/op-bindings/bindings" - "github.com/ethereum-optimism/optimism/op-challenger/game/fault/types" - gameTypes "github.com/ethereum-optimism/optimism/op-challenger/game/types" - - "github.com/ethereum/go-ethereum/accounts/abi/bind" - "github.com/ethereum/go-ethereum/common" -) - -// MinimalFaultDisputeGameCaller is a minimal interface around [bindings.FaultDisputeGameCaller]. -// This needs to be updated if the [bindings.FaultDisputeGameCaller] interface changes. -type MinimalFaultDisputeGameCaller interface { - ClaimData(opts *bind.CallOpts, arg0 *big.Int) (struct { - ParentIndex uint32 - Countered bool - Claim [32]byte - Position *big.Int - Clock *big.Int - }, error) - Status(opts *bind.CallOpts) (uint8, error) - ClaimDataLen(opts *bind.CallOpts) (*big.Int, error) - MAXGAMEDEPTH(opts *bind.CallOpts) (*big.Int, error) - ABSOLUTEPRESTATE(opts *bind.CallOpts) ([32]byte, error) -} - -// loader pulls in fault dispute game claim data periodically and over subscriptions. -type loader struct { - caller MinimalFaultDisputeGameCaller -} - -// NewLoader creates a new [loader]. -func NewLoader(caller MinimalFaultDisputeGameCaller) *loader { - return &loader{ - caller: caller, - } -} - -// NewLoaderFromBindings creates a new [loader] from a [bindings.FaultDisputeGameCaller]. -func NewLoaderFromBindings(fdgAddr common.Address, client bind.ContractCaller) (*loader, error) { - caller, err := bindings.NewFaultDisputeGameCaller(fdgAddr, client) - if err != nil { - return nil, err - } - return NewLoader(caller), nil -} - -// GetGameStatus returns the current game status. -func (l *loader) GetGameStatus(ctx context.Context) (gameTypes.GameStatus, error) { - status, err := l.caller.Status(&bind.CallOpts{Context: ctx}) - return gameTypes.GameStatus(status), err -} - -// GetClaimCount returns the number of claims in the game. -func (l *loader) GetClaimCount(ctx context.Context) (uint64, error) { - count, err := l.caller.ClaimDataLen(&bind.CallOpts{Context: ctx}) - if err != nil { - return 0, err - } - return count.Uint64(), nil -} - -// FetchGameDepth fetches the game depth from the fault dispute game. -func (l *loader) FetchGameDepth(ctx context.Context) (uint64, error) { - callOpts := bind.CallOpts{ - Context: ctx, - } - - gameDepth, err := l.caller.MAXGAMEDEPTH(&callOpts) - if err != nil { - return 0, err - } - - return gameDepth.Uint64(), nil -} - -// fetchClaim fetches a single [Claim] with a hydrated parent. -func (l *loader) fetchClaim(ctx context.Context, arrIndex uint64) (types.Claim, error) { - callOpts := bind.CallOpts{ - Context: ctx, - } - - fetchedClaim, err := l.caller.ClaimData(&callOpts, new(big.Int).SetUint64(arrIndex)) - if err != nil { - return types.Claim{}, err - } - - claim := types.Claim{ - ClaimData: types.ClaimData{ - Value: fetchedClaim.Claim, - Position: types.NewPositionFromGIndex(fetchedClaim.Position), - }, - Countered: fetchedClaim.Countered, - Clock: fetchedClaim.Clock.Uint64(), - ContractIndex: int(arrIndex), - ParentContractIndex: int(fetchedClaim.ParentIndex), - } - - if !claim.IsRootPosition() { - parentIndex := uint64(fetchedClaim.ParentIndex) - parentClaim, err := l.caller.ClaimData(&callOpts, new(big.Int).SetUint64(parentIndex)) - if err != nil { - return types.Claim{}, err - } - claim.Parent = types.ClaimData{ - Value: parentClaim.Claim, - Position: types.NewPositionFromGIndex(parentClaim.Position), - } - } - - return claim, nil -} - -// FetchClaims fetches all claims from the fault dispute game. -func (l *loader) FetchClaims(ctx context.Context) ([]types.Claim, error) { - // Get the current claim count. - claimCount, err := l.caller.ClaimDataLen(&bind.CallOpts{ - Context: ctx, - }) - if err != nil { - return nil, err - } - - // Fetch each claim and build a list. - claimList := make([]types.Claim, claimCount.Uint64()) - for i := uint64(0); i < claimCount.Uint64(); i++ { - claim, err := l.fetchClaim(ctx, i) - if err != nil { - return nil, err - } - claimList[i] = claim - } - - return claimList, nil -} - -// FetchAbsolutePrestateHash fetches the hashed absolute prestate from the fault dispute game. -func (l *loader) FetchAbsolutePrestateHash(ctx context.Context) (common.Hash, error) { - callOpts := bind.CallOpts{ - Context: ctx, - } - - absolutePrestate, err := l.caller.ABSOLUTEPRESTATE(&callOpts) - if err != nil { - return common.Hash{}, err - } - - return absolutePrestate, nil -} diff --git a/op-challenger/game/fault/loader_test.go b/op-challenger/game/fault/loader_test.go deleted file mode 100644 index 79ad721cf2c56..0000000000000 --- a/op-challenger/game/fault/loader_test.go +++ /dev/null @@ -1,274 +0,0 @@ -package fault - -import ( - "context" - "fmt" - "math/big" - "testing" - - "github.com/ethereum-optimism/optimism/op-challenger/game/fault/types" - gameTypes "github.com/ethereum-optimism/optimism/op-challenger/game/types" - - "github.com/ethereum/go-ethereum/accounts/abi/bind" - "github.com/ethereum/go-ethereum/common" - "github.com/stretchr/testify/require" -) - -var ( - mockClaimDataError = fmt.Errorf("claim data errored") - mockClaimLenError = fmt.Errorf("claim len errored") - mockMaxGameDepthError = fmt.Errorf("max game depth errored") - mockPrestateError = fmt.Errorf("prestate errored") - mockStatusError = fmt.Errorf("status errored") -) - -// TestLoader_GetGameStatus tests fetching the game status. -func TestLoader_GetGameStatus(t *testing.T) { - tests := []struct { - name string - status uint8 - expectedError bool - }{ - { - name: "challenger won status", - status: uint8(gameTypes.GameStatusChallengerWon), - }, - { - name: "defender won status", - status: uint8(gameTypes.GameStatusDefenderWon), - }, - { - name: "in progress status", - status: uint8(gameTypes.GameStatusInProgress), - }, - { - name: "error bubbled up", - expectedError: true, - }, - } - - for _, test := range tests { - t.Run(test.name, func(t *testing.T) { - mockCaller := newMockCaller() - mockCaller.status = test.status - mockCaller.statusError = test.expectedError - loader := NewLoader(mockCaller) - status, err := loader.GetGameStatus(context.Background()) - if test.expectedError { - require.ErrorIs(t, err, mockStatusError) - } else { - require.NoError(t, err) - require.Equal(t, gameTypes.GameStatus(test.status), status) - } - }) - } -} - -// TestLoader_FetchGameDepth tests fetching the game depth. -func TestLoader_FetchGameDepth(t *testing.T) { - t.Run("Succeeds", func(t *testing.T) { - mockCaller := newMockCaller() - mockCaller.maxGameDepth = 10 - loader := NewLoader(mockCaller) - depth, err := loader.FetchGameDepth(context.Background()) - require.NoError(t, err) - require.Equal(t, uint64(10), depth) - }) - - t.Run("Errors", func(t *testing.T) { - mockCaller := newMockCaller() - mockCaller.maxGameDepthError = true - loader := NewLoader(mockCaller) - depth, err := loader.FetchGameDepth(context.Background()) - require.ErrorIs(t, mockMaxGameDepthError, err) - require.Equal(t, depth, uint64(0)) - }) -} - -// TestLoader_FetchAbsolutePrestateHash tests fetching the absolute prestate hash. -func TestLoader_FetchAbsolutePrestateHash(t *testing.T) { - t.Run("Succeeds", func(t *testing.T) { - mockCaller := newMockCaller() - loader := NewLoader(mockCaller) - prestate, err := loader.FetchAbsolutePrestateHash(context.Background()) - require.NoError(t, err) - require.ElementsMatch(t, common.HexToHash("0xdEad"), prestate) - }) - - t.Run("Errors", func(t *testing.T) { - mockCaller := newMockCaller() - mockCaller.prestateError = true - loader := NewLoader(mockCaller) - prestate, err := loader.FetchAbsolutePrestateHash(context.Background()) - require.Error(t, err) - require.ElementsMatch(t, common.Hash{}, prestate) - }) -} - -// TestLoader_FetchClaims tests fetching claims. -func TestLoader_FetchClaims(t *testing.T) { - t.Run("Succeeds", func(t *testing.T) { - mockCaller := newMockCaller() - expectedClaims := mockCaller.returnClaims - loader := NewLoader(mockCaller) - claims, err := loader.FetchClaims(context.Background()) - require.NoError(t, err) - require.ElementsMatch(t, []types.Claim{ - { - ClaimData: types.ClaimData{ - Value: expectedClaims[0].Claim, - Position: types.NewPositionFromGIndex(expectedClaims[0].Position), - }, - Countered: false, - Clock: uint64(0), - ContractIndex: 0, - }, - { - ClaimData: types.ClaimData{ - Value: expectedClaims[1].Claim, - Position: types.NewPositionFromGIndex(expectedClaims[1].Position), - }, - Parent: types.ClaimData{ - Value: expectedClaims[0].Claim, - Position: types.NewPositionFromGIndex(expectedClaims[0].Position), - }, - Countered: false, - Clock: uint64(0), - ContractIndex: 1, - ParentContractIndex: 0, - }, - { - ClaimData: types.ClaimData{ - Value: expectedClaims[2].Claim, - Position: types.NewPositionFromGIndex(expectedClaims[2].Position), - }, - Parent: types.ClaimData{ - Value: expectedClaims[1].Claim, - Position: types.NewPositionFromGIndex(expectedClaims[1].Position), - }, - Countered: false, - Clock: uint64(0), - ContractIndex: 2, - ParentContractIndex: 1, - }, - }, claims) - }) - - t.Run("Claim Data Errors", func(t *testing.T) { - mockCaller := newMockCaller() - mockCaller.claimDataError = true - loader := NewLoader(mockCaller) - claims, err := loader.FetchClaims(context.Background()) - require.ErrorIs(t, err, mockClaimDataError) - require.Empty(t, claims) - }) - - t.Run("Claim Len Errors", func(t *testing.T) { - mockCaller := newMockCaller() - mockCaller.claimLenError = true - loader := NewLoader(mockCaller) - claims, err := loader.FetchClaims(context.Background()) - require.ErrorIs(t, err, mockClaimLenError) - require.Empty(t, claims) - }) -} - -type mockCaller struct { - claimDataError bool - claimLenError bool - maxGameDepthError bool - prestateError bool - statusError bool - maxGameDepth uint64 - currentIndex uint64 - status uint8 - returnClaims []struct { - ParentIndex uint32 - Countered bool - Claim [32]byte - Position *big.Int - Clock *big.Int - } -} - -func newMockCaller() *mockCaller { - return &mockCaller{ - returnClaims: []struct { - ParentIndex uint32 - Countered bool - Claim [32]byte - Position *big.Int - Clock *big.Int - }{ - { - Claim: [32]byte{0x00}, - Position: big.NewInt(1), - Countered: false, - Clock: big.NewInt(0), - }, - { - Claim: [32]byte{0x01}, - Position: big.NewInt(2), - Countered: false, - Clock: big.NewInt(0), - ParentIndex: 0, - }, - { - Claim: [32]byte{0x02}, - Position: big.NewInt(3), - Countered: false, - Clock: big.NewInt(0), - ParentIndex: 1, - }, - }, - } -} - -func (m *mockCaller) ClaimData(opts *bind.CallOpts, arg0 *big.Int) (struct { - ParentIndex uint32 - Countered bool - Claim [32]byte - Position *big.Int - Clock *big.Int -}, error) { - if m.claimDataError { - return struct { - ParentIndex uint32 - Countered bool - Claim [32]byte - Position *big.Int - Clock *big.Int - }{}, mockClaimDataError - } - returnClaim := m.returnClaims[arg0.Uint64()] - m.currentIndex++ - return returnClaim, nil -} - -func (m *mockCaller) Status(opts *bind.CallOpts) (uint8, error) { - if m.statusError { - return 0, mockStatusError - } - return m.status, nil -} - -func (m *mockCaller) ClaimDataLen(opts *bind.CallOpts) (*big.Int, error) { - if m.claimLenError { - return big.NewInt(0), mockClaimLenError - } - return big.NewInt(int64(len(m.returnClaims))), nil -} - -func (m *mockCaller) MAXGAMEDEPTH(opts *bind.CallOpts) (*big.Int, error) { - if m.maxGameDepthError { - return nil, mockMaxGameDepthError - } - return big.NewInt(int64(m.maxGameDepth)), nil -} - -func (m *mockCaller) ABSOLUTEPRESTATE(opts *bind.CallOpts) ([32]byte, error) { - if m.prestateError { - return [32]byte{}, mockPrestateError - } - return common.HexToHash("0xdEad"), nil -} diff --git a/op-challenger/game/fault/player.go b/op-challenger/game/fault/player.go index eb7444161bae0..13570d9336949 100644 --- a/op-challenger/game/fault/player.go +++ b/op-challenger/game/fault/player.go @@ -5,27 +5,30 @@ import ( "context" "fmt" - "github.com/ethereum-optimism/optimism/op-bindings/bindings" "github.com/ethereum-optimism/optimism/op-challenger/config" + "github.com/ethereum-optimism/optimism/op-challenger/game/fault/contracts" "github.com/ethereum-optimism/optimism/op-challenger/game/fault/responder" - "github.com/ethereum-optimism/optimism/op-challenger/game/fault/trace/alphabet" - "github.com/ethereum-optimism/optimism/op-challenger/game/fault/trace/cannon" "github.com/ethereum-optimism/optimism/op-challenger/game/fault/types" gameTypes "github.com/ethereum-optimism/optimism/op-challenger/game/types" "github.com/ethereum-optimism/optimism/op-challenger/metrics" + "github.com/ethereum-optimism/optimism/op-service/sources/batching" "github.com/ethereum-optimism/optimism/op-service/txmgr" - "github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/ethclient" "github.com/ethereum/go-ethereum/log" ) type actor func(ctx context.Context) error type GameInfo interface { - GetGameStatus(context.Context) (gameTypes.GameStatus, error) + GetStatus(context.Context) (gameTypes.GameStatus, error) GetClaimCount(context.Context) (uint64, error) } +// gameValidator checks that the specific game instance is compatible with the configuration. +// Typically, this is done by verifying the absolute prestate of the game matches the local absolute prestate. +type gameValidator func(ctx context.Context, gameContract *contracts.FaultDisputeGameContract) error + type GamePlayer struct { act actor agreeWithProposedOutput bool @@ -34,6 +37,8 @@ type GamePlayer struct { status gameTypes.GameStatus } +type resourceCreator func(addr common.Address, contract *contracts.FaultDisputeGameContract, gameDepth uint64, dir string) (types.TraceAccessor, types.OracleUpdater, gameValidator, error) + func NewGamePlayer( ctx context.Context, logger log.Logger, @@ -42,17 +47,16 @@ func NewGamePlayer( dir string, addr common.Address, txMgr txmgr.TxManager, - client bind.ContractCaller, + client *ethclient.Client, + creator resourceCreator, ) (*GamePlayer, error) { logger = logger.New("game", addr) - contract, err := bindings.NewFaultDisputeGameCaller(addr, client) + loader, err := contracts.NewFaultDisputeGameContract(addr, batching.NewMultiCaller(client.Client(), batching.DefaultBatchSize)) if err != nil { - return nil, fmt.Errorf("failed to bind the fault dispute game contract: %w", err) + return nil, fmt.Errorf("failed to create fault dispute game contract wrapper: %w", err) } - loader := NewLoader(contract) - - status, err := loader.GetGameStatus(ctx) + status, err := loader.GetStatus(ctx) if err != nil { return nil, fmt.Errorf("failed to fetch game status: %w", err) } @@ -71,42 +75,28 @@ func NewGamePlayer( }, nil } - gameDepth, err := loader.FetchGameDepth(ctx) + gameDepth, err := loader.GetMaxGameDepth(ctx) if err != nil { return nil, fmt.Errorf("failed to fetch the game depth: %w", err) } - var provider types.TraceProvider - var updater types.OracleUpdater - switch cfg.TraceType { - case config.TraceTypeCannon: - cannonProvider, err := cannon.NewTraceProvider(ctx, logger, m, cfg, client, dir, addr, gameDepth) - if err != nil { - return nil, fmt.Errorf("create cannon trace provider: %w", err) - } - provider = cannonProvider - updater, err = cannon.NewOracleUpdater(ctx, logger, txMgr, addr, client) - if err != nil { - return nil, fmt.Errorf("failed to create the cannon updater: %w", err) - } - case config.TraceTypeAlphabet: - provider = alphabet.NewTraceProvider(cfg.AlphabetTrace, gameDepth) - updater = alphabet.NewOracleUpdater(logger) - default: - return nil, fmt.Errorf("unsupported trace type: %v", cfg.TraceType) + accessor, updater, validator, err := creator(addr, loader, gameDepth, dir) + if err != nil { + return nil, fmt.Errorf("failed to create trace accessor: %w", err) } - if err := ValidateAbsolutePrestate(ctx, provider, loader); err != nil { + if err := validator(ctx, loader); err != nil { return nil, fmt.Errorf("failed to validate absolute prestate: %w", err) } - responder, err := responder.NewFaultResponder(logger, txMgr, addr) + responder, err := responder.NewFaultResponder(logger, txMgr, loader) if err != nil { return nil, fmt.Errorf("failed to create the responder: %w", err) } + agent := NewAgent(m, loader, int(gameDepth), accessor, responder, updater, cfg.AgreeWithProposedOutput, logger) return &GamePlayer{ - act: NewAgent(m, loader, int(gameDepth), provider, responder, updater, cfg.AgreeWithProposedOutput, logger).Act, + act: agent.Act, agreeWithProposedOutput: cfg.AgreeWithProposedOutput, loader: loader, logger: logger, @@ -128,7 +118,7 @@ func (g *GamePlayer) ProgressGame(ctx context.Context) gameTypes.GameStatus { if err := g.act(ctx); err != nil { g.logger.Error("Error when acting on game", "err", err) } - status, err := g.loader.GetGameStatus(ctx) + status, err := g.loader.GetStatus(ctx) if err != nil { g.logger.Warn("Unable to retrieve game status", "err", err) return gameTypes.GameStatusInProgress @@ -162,7 +152,7 @@ func (g *GamePlayer) logGameStatus(ctx context.Context, status gameTypes.GameSta } type PrestateLoader interface { - FetchAbsolutePrestateHash(ctx context.Context) (common.Hash, error) + GetAbsolutePrestateHash(ctx context.Context) (common.Hash, error) } // ValidateAbsolutePrestate validates the absolute prestate of the fault game. @@ -171,7 +161,7 @@ func ValidateAbsolutePrestate(ctx context.Context, trace types.TraceProvider, lo if err != nil { return fmt.Errorf("failed to get the trace provider's absolute prestate: %w", err) } - onchainPrestate, err := loader.FetchAbsolutePrestateHash(ctx) + onchainPrestate, err := loader.GetAbsolutePrestateHash(ctx) if err != nil { return fmt.Errorf("failed to get the onchain absolute prestate: %w", err) } diff --git a/op-challenger/game/fault/player_test.go b/op-challenger/game/fault/player_test.go index 3ed906c94f626..7375e2146d8af 100644 --- a/op-challenger/game/fault/player_test.go +++ b/op-challenger/game/fault/player_test.go @@ -181,7 +181,7 @@ func (s *stubGameState) Act(ctx context.Context) error { return s.actErr } -func (s *stubGameState) GetGameStatus(ctx context.Context) (gameTypes.GameStatus, error) { +func (s *stubGameState) GetStatus(ctx context.Context) (gameTypes.GameStatus, error) { return s.status, nil } @@ -234,7 +234,7 @@ func newMockPrestateLoader(prestateError bool, prestate common.Hash) *mockLoader prestate: prestate, } } -func (m *mockLoader) FetchAbsolutePrestateHash(ctx context.Context) (common.Hash, error) { +func (m *mockLoader) GetAbsolutePrestateHash(ctx context.Context) (common.Hash, error) { if m.prestateError { return common.Hash{}, mockLoaderError } diff --git a/op-challenger/game/fault/register.go b/op-challenger/game/fault/register.go new file mode 100644 index 0000000000000..d3388f20692f5 --- /dev/null +++ b/op-challenger/game/fault/register.go @@ -0,0 +1,74 @@ +package fault + +import ( + "context" + "fmt" + + "github.com/ethereum-optimism/optimism/op-challenger/config" + "github.com/ethereum-optimism/optimism/op-challenger/game/fault/contracts" + "github.com/ethereum-optimism/optimism/op-challenger/game/fault/trace" + "github.com/ethereum-optimism/optimism/op-challenger/game/fault/trace/alphabet" + "github.com/ethereum-optimism/optimism/op-challenger/game/fault/trace/cannon" + faultTypes "github.com/ethereum-optimism/optimism/op-challenger/game/fault/types" + "github.com/ethereum-optimism/optimism/op-challenger/game/scheduler" + "github.com/ethereum-optimism/optimism/op-challenger/game/types" + "github.com/ethereum-optimism/optimism/op-challenger/metrics" + "github.com/ethereum-optimism/optimism/op-service/txmgr" + "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/ethclient" + "github.com/ethereum/go-ethereum/log" +) + +var ( + cannonGameType = uint8(0) + alphabetGameType = uint8(255) +) + +type Registry interface { + RegisterGameType(gameType uint8, creator scheduler.PlayerCreator) +} + +func RegisterGameTypes( + registry Registry, + ctx context.Context, + logger log.Logger, + m metrics.Metricer, + cfg *config.Config, + txMgr txmgr.TxManager, + client *ethclient.Client, +) { + if cfg.TraceTypeEnabled(config.TraceTypeCannon) { + resourceCreator := func(addr common.Address, contract *contracts.FaultDisputeGameContract, gameDepth uint64, dir string) (faultTypes.TraceAccessor, faultTypes.OracleUpdater, gameValidator, error) { + provider, err := cannon.NewTraceProvider(ctx, logger, m, cfg, contract, dir, gameDepth) + if err != nil { + return nil, nil, nil, fmt.Errorf("create cannon trace provider: %w", err) + } + updater, err := cannon.NewOracleUpdater(ctx, logger, txMgr, addr, client) + if err != nil { + return nil, nil, nil, fmt.Errorf("failed to create the cannon updater: %w", err) + } + validator := func(ctx context.Context, contract *contracts.FaultDisputeGameContract) error { + return ValidateAbsolutePrestate(ctx, provider, contract) + } + return trace.NewSimpleTraceAccessor(provider), updater, validator, nil + } + playerCreator := func(game types.GameMetadata, dir string) (scheduler.GamePlayer, error) { + return NewGamePlayer(ctx, logger, m, cfg, dir, game.Proxy, txMgr, client, resourceCreator) + } + registry.RegisterGameType(cannonGameType, playerCreator) + } + if cfg.TraceTypeEnabled(config.TraceTypeAlphabet) { + resourceCreator := func(addr common.Address, contract *contracts.FaultDisputeGameContract, gameDepth uint64, dir string) (faultTypes.TraceAccessor, faultTypes.OracleUpdater, gameValidator, error) { + provider := alphabet.NewTraceProvider(cfg.AlphabetTrace, gameDepth) + updater := alphabet.NewOracleUpdater(logger) + validator := func(ctx context.Context, contract *contracts.FaultDisputeGameContract) error { + return ValidateAbsolutePrestate(ctx, provider, contract) + } + return trace.NewSimpleTraceAccessor(provider), updater, validator, nil + } + playerCreator := func(game types.GameMetadata, dir string) (scheduler.GamePlayer, error) { + return NewGamePlayer(ctx, logger, m, cfg, dir, game.Proxy, txMgr, client, resourceCreator) + } + registry.RegisterGameType(alphabetGameType, playerCreator) + } +} diff --git a/op-challenger/game/fault/responder/abi_test.go b/op-challenger/game/fault/responder/abi_test.go deleted file mode 100644 index 1c550e6da3b56..0000000000000 --- a/op-challenger/game/fault/responder/abi_test.go +++ /dev/null @@ -1,104 +0,0 @@ -package responder - -import ( - "math/big" - "testing" - - "github.com/ethereum-optimism/optimism/op-bindings/bindings" - "github.com/ethereum/go-ethereum/accounts/abi/bind" - "github.com/ethereum/go-ethereum/accounts/abi/bind/backends" - "github.com/ethereum/go-ethereum/common" - "github.com/ethereum/go-ethereum/core" - "github.com/ethereum/go-ethereum/crypto" - "github.com/ethereum/go-ethereum/params" - "github.com/stretchr/testify/require" -) - -// setupFaultDisputeGame deploys the FaultDisputeGame contract to a simulated backend -func setupFaultDisputeGame() (common.Address, *bind.TransactOpts, *backends.SimulatedBackend, *bindings.FaultDisputeGame, error) { - privateKey, err := crypto.GenerateKey() - from := crypto.PubkeyToAddress(privateKey.PublicKey) - if err != nil { - return common.Address{}, nil, nil, nil, err - } - opts, err := bind.NewKeyedTransactorWithChainID(privateKey, big.NewInt(1337)) - if err != nil { - return common.Address{}, nil, nil, nil, err - } - backend := backends.NewSimulatedBackend( - core.GenesisAlloc{from: {Balance: big.NewInt(params.Ether)}}, - 50_000_000, - ) - - blockHashOracle, _, _, err := bindings.DeployBlockOracle(opts, backend) - if err != nil { - return common.Address{}, nil, nil, nil, err - } - - _, _, contract, err := bindings.DeployFaultDisputeGame( - opts, - backend, - uint8(0), // Game Type ID - [32]byte{0x01}, // Absolute Prestate Claim - big.NewInt(15), // Max Game Depth - uint64(604800), // 7 days - common.Address{0xdd}, // VM - common.Address{0xee}, // L2OutputOracle (Not used in Alphabet Game) - blockHashOracle, // Block hash oracle - ) - if err != nil { - return common.Address{}, nil, nil, nil, err - } - return from, opts, backend, contract, nil -} - -// TestBuildFaultDefendData ensures that the manual ABI packing is the same as going through the bound contract. -func TestBuildFaultDefendData(t *testing.T) { - _, opts, _, contract, err := setupFaultDisputeGame() - require.NoError(t, err) - - resp, _ := newTestFaultResponder(t) - - data, err := resp.buildFaultDefendData(1, [32]byte{0x02, 0x03}) - require.NoError(t, err) - - opts.GasLimit = 100_000 - tx, err := contract.Defend(opts, big.NewInt(1), [32]byte{0x02, 0x03}) - require.NoError(t, err) - - require.Equal(t, data, tx.Data()) -} - -// TestBuildFaultAttackData ensures that the manual ABI packing is the same as going through the bound contract. -func TestBuildFaultAttackData(t *testing.T) { - _, opts, _, contract, err := setupFaultDisputeGame() - require.NoError(t, err) - - resp, _ := newTestFaultResponder(t) - - data, err := resp.buildFaultAttackData(1, [32]byte{0x02, 0x03}) - require.NoError(t, err) - - opts.GasLimit = 100_000 - tx, err := contract.Attack(opts, big.NewInt(1), [32]byte{0x02, 0x03}) - require.NoError(t, err) - - require.Equal(t, data, tx.Data()) -} - -// TestBuildFaultStepData ensures that the manual ABI packing is the same as going through the bound contract. -func TestBuildFaultStepData(t *testing.T) { - _, opts, _, contract, err := setupFaultDisputeGame() - require.NoError(t, err) - - resp, _ := newTestFaultResponder(t) - - data, err := resp.buildStepTxData(2, false, []byte{0x01}, []byte{0x02}) - require.NoError(t, err) - - opts.GasLimit = 100_000 - tx, err := contract.Step(opts, big.NewInt(2), false, []byte{0x01}, []byte{0x02}) - require.NoError(t, err) - - require.Equal(t, data, tx.Data()) -} diff --git a/op-challenger/game/fault/responder/responder.go b/op-challenger/game/fault/responder/responder.go index 07350b3e22c45..d4eb6104d298c 100644 --- a/op-challenger/game/fault/responder/responder.go +++ b/op-challenger/game/fault/responder/responder.go @@ -2,153 +2,97 @@ package responder import ( "context" - "math/big" - "github.com/ethereum-optimism/optimism/op-bindings/bindings" "github.com/ethereum-optimism/optimism/op-challenger/game/fault/types" gameTypes "github.com/ethereum-optimism/optimism/op-challenger/game/types" "github.com/ethereum-optimism/optimism/op-service/txmgr" - - "github.com/ethereum/go-ethereum" - "github.com/ethereum/go-ethereum/accounts/abi" "github.com/ethereum/go-ethereum/common" + ethtypes "github.com/ethereum/go-ethereum/core/types" "github.com/ethereum/go-ethereum/log" ) +type GameContract interface { + CallResolve(ctx context.Context) (gameTypes.GameStatus, error) + ResolveTx() (txmgr.TxCandidate, error) + CallResolveClaim(ctx context.Context, claimIdx uint64) error + ResolveClaimTx(claimIdx uint64) (txmgr.TxCandidate, error) + AttackTx(parentContractIndex uint64, pivot common.Hash) (txmgr.TxCandidate, error) + DefendTx(parentContractIndex uint64, pivot common.Hash) (txmgr.TxCandidate, error) + StepTx(claimIdx uint64, isAttack bool, stateData []byte, proof []byte) (txmgr.TxCandidate, error) +} + // FaultResponder implements the [Responder] interface to send onchain transactions. type FaultResponder struct { log log.Logger - txMgr txmgr.TxManager - - fdgAddr common.Address - fdgAbi *abi.ABI + txMgr txmgr.TxManager + contract GameContract } // NewFaultResponder returns a new [FaultResponder]. -func NewFaultResponder(logger log.Logger, txManagr txmgr.TxManager, fdgAddr common.Address) (*FaultResponder, error) { - fdgAbi, err := bindings.FaultDisputeGameMetaData.GetAbi() - if err != nil { - return nil, err - } +func NewFaultResponder(logger log.Logger, txMgr txmgr.TxManager, contract GameContract) (*FaultResponder, error) { return &FaultResponder{ - log: logger, - txMgr: txManagr, - fdgAddr: fdgAddr, - fdgAbi: fdgAbi, + log: logger, + txMgr: txMgr, + contract: contract, }, nil } -// buildFaultDefendData creates the transaction data for the Defend function. -func (r *FaultResponder) buildFaultDefendData(parentContractIndex int, pivot [32]byte) ([]byte, error) { - return r.fdgAbi.Pack( - "defend", - big.NewInt(int64(parentContractIndex)), - pivot, - ) -} - -// buildFaultAttackData creates the transaction data for the Attack function. -func (r *FaultResponder) buildFaultAttackData(parentContractIndex int, pivot [32]byte) ([]byte, error) { - return r.fdgAbi.Pack( - "attack", - big.NewInt(int64(parentContractIndex)), - pivot, - ) -} - -// buildResolveData creates the transaction data for the Resolve function. -func (r *FaultResponder) buildResolveData() ([]byte, error) { - return r.fdgAbi.Pack("resolve") -} - // CallResolve determines if the resolve function on the fault dispute game contract // would succeed. Returns the game status if the call would succeed, errors otherwise. func (r *FaultResponder) CallResolve(ctx context.Context) (gameTypes.GameStatus, error) { - txData, err := r.buildResolveData() - if err != nil { - return gameTypes.GameStatusInProgress, err - } - res, err := r.txMgr.Call(ctx, ethereum.CallMsg{ - To: &r.fdgAddr, - Data: txData, - }, nil) - if err != nil { - return gameTypes.GameStatusInProgress, err - } - var status uint8 - if err = r.fdgAbi.UnpackIntoInterface(&status, "resolve", res); err != nil { - return gameTypes.GameStatusInProgress, err - } - return gameTypes.GameStatusFromUint8(status) + return r.contract.CallResolve(ctx) } // Resolve executes a resolve transaction to resolve a fault dispute game. func (r *FaultResponder) Resolve(ctx context.Context) error { - txData, err := r.buildResolveData() + candidate, err := r.contract.ResolveTx() if err != nil { return err } - return r.sendTxAndWait(ctx, txData) -} - -// buildResolveClaimData creates the transaction data for the ResolveClaim function. -func (r *FaultResponder) buildResolveClaimData(claimIdx uint64) ([]byte, error) { - return r.fdgAbi.Pack("resolveClaim", big.NewInt(int64(claimIdx))) + return r.sendTxAndWait(ctx, candidate) } // CallResolveClaim determines if the resolveClaim function on the fault dispute game contract // would succeed. func (r *FaultResponder) CallResolveClaim(ctx context.Context, claimIdx uint64) error { - txData, err := r.buildResolveClaimData(claimIdx) - if err != nil { - return err - } - _, err = r.txMgr.Call(ctx, ethereum.CallMsg{ - To: &r.fdgAddr, - Data: txData, - }, nil) - return err + return r.contract.CallResolveClaim(ctx, claimIdx) } // ResolveClaim executes a resolveClaim transaction to resolve a fault dispute game. func (r *FaultResponder) ResolveClaim(ctx context.Context, claimIdx uint64) error { - txData, err := r.buildResolveClaimData(claimIdx) + candidate, err := r.contract.ResolveClaimTx(claimIdx) if err != nil { return err } - return r.sendTxAndWait(ctx, txData) + return r.sendTxAndWait(ctx, candidate) } func (r *FaultResponder) PerformAction(ctx context.Context, action types.Action) error { - var txData []byte + var candidate txmgr.TxCandidate var err error switch action.Type { case types.ActionTypeMove: if action.IsAttack { - txData, err = r.buildFaultAttackData(action.ParentIdx, action.Value) + candidate, err = r.contract.AttackTx(uint64(action.ParentIdx), action.Value) } else { - txData, err = r.buildFaultDefendData(action.ParentIdx, action.Value) + candidate, err = r.contract.DefendTx(uint64(action.ParentIdx), action.Value) } case types.ActionTypeStep: - txData, err = r.buildStepTxData(uint64(action.ParentIdx), action.IsAttack, action.PreState, action.ProofData) + candidate, err = r.contract.StepTx(uint64(action.ParentIdx), action.IsAttack, action.PreState, action.ProofData) } if err != nil { return err } - return r.sendTxAndWait(ctx, txData) + return r.sendTxAndWait(ctx, candidate) } // sendTxAndWait sends a transaction through the [txmgr] and waits for a receipt. // This sets the tx GasLimit to 0, performing gas estimation online through the [txmgr]. -func (r *FaultResponder) sendTxAndWait(ctx context.Context, txData []byte) error { - receipt, err := r.txMgr.Send(ctx, txmgr.TxCandidate{ - To: &r.fdgAddr, - TxData: txData, - GasLimit: 0, - }) +func (r *FaultResponder) sendTxAndWait(ctx context.Context, candidate txmgr.TxCandidate) error { + receipt, err := r.txMgr.Send(ctx, candidate) if err != nil { return err } @@ -159,14 +103,3 @@ func (r *FaultResponder) sendTxAndWait(ctx context.Context, txData []byte) error } return nil } - -// buildStepTxData creates the transaction data for the step function. -func (r *FaultResponder) buildStepTxData(claimIdx uint64, isAttack bool, stateData []byte, proof []byte) ([]byte, error) { - return r.fdgAbi.Pack( - "step", - big.NewInt(int64(claimIdx)), - isAttack, - stateData, - proof, - ) -} diff --git a/op-challenger/game/fault/responder/responder_test.go b/op-challenger/game/fault/responder/responder_test.go index facb1ad2d33af..de77b02c675ea 100644 --- a/op-challenger/game/fault/responder/responder_test.go +++ b/op-challenger/game/fault/responder/responder_test.go @@ -3,16 +3,13 @@ package responder import ( "context" "errors" - "math/big" "testing" - "github.com/ethereum-optimism/optimism/op-bindings/bindings" "github.com/ethereum-optimism/optimism/op-challenger/game/fault/types" gameTypes "github.com/ethereum-optimism/optimism/op-challenger/game/types" "github.com/ethereum-optimism/optimism/op-service/testlog" "github.com/ethereum-optimism/optimism/op-service/txmgr" - "github.com/ethereum/go-ethereum" "github.com/ethereum/go-ethereum/common" ethtypes "github.com/ethereum/go-ethereum/core/types" "github.com/ethereum/go-ethereum/log" @@ -21,44 +18,34 @@ import ( ) var ( - mockFdgAddress = common.HexToAddress("0x1234") - mockSendError = errors.New("mock send error") - mockCallError = errors.New("mock call error") + mockSendError = errors.New("mock send error") + mockCallError = errors.New("mock call error") ) // TestCallResolve tests the [Responder.CallResolve]. func TestCallResolve(t *testing.T) { t.Run("SendFails", func(t *testing.T) { - responder, mockTxMgr := newTestFaultResponder(t) - mockTxMgr.callFails = true + responder, _, contract := newTestFaultResponder(t) + contract.callFails = true status, err := responder.CallResolve(context.Background()) require.ErrorIs(t, err, mockCallError) require.Equal(t, gameTypes.GameStatusInProgress, status) - require.Equal(t, 0, mockTxMgr.calls) - }) - - t.Run("UnpackFails", func(t *testing.T) { - responder, mockTxMgr := newTestFaultResponder(t) - mockTxMgr.callBytes = []byte{0x00, 0x01} - status, err := responder.CallResolve(context.Background()) - require.Error(t, err) - require.Equal(t, gameTypes.GameStatusInProgress, status) - require.Equal(t, 1, mockTxMgr.calls) + require.Equal(t, 0, contract.calls) }) t.Run("Success", func(t *testing.T) { - responder, mockTxMgr := newTestFaultResponder(t) + responder, _, contract := newTestFaultResponder(t) status, err := responder.CallResolve(context.Background()) require.NoError(t, err) require.Equal(t, gameTypes.GameStatusInProgress, status) - require.Equal(t, 1, mockTxMgr.calls) + require.Equal(t, 1, contract.calls) }) } // TestResolve tests the [Responder.Resolve] method. func TestResolve(t *testing.T) { t.Run("SendFails", func(t *testing.T) { - responder, mockTxMgr := newTestFaultResponder(t) + responder, mockTxMgr, _ := newTestFaultResponder(t) mockTxMgr.sendFails = true err := responder.Resolve(context.Background()) require.ErrorIs(t, err, mockSendError) @@ -66,7 +53,7 @@ func TestResolve(t *testing.T) { }) t.Run("Success", func(t *testing.T) { - responder, mockTxMgr := newTestFaultResponder(t) + responder, mockTxMgr, _ := newTestFaultResponder(t) err := responder.Resolve(context.Background()) require.NoError(t, err) require.Equal(t, 1, mockTxMgr.sends) @@ -75,24 +62,24 @@ func TestResolve(t *testing.T) { func TestCallResolveClaim(t *testing.T) { t.Run("SendFails", func(t *testing.T) { - responder, mockTxMgr := newTestFaultResponder(t) - mockTxMgr.callFails = true + responder, _, contract := newTestFaultResponder(t) + contract.callFails = true err := responder.CallResolveClaim(context.Background(), 0) require.ErrorIs(t, err, mockCallError) - require.Equal(t, 0, mockTxMgr.calls) + require.Equal(t, 0, contract.calls) }) t.Run("Success", func(t *testing.T) { - responder, mockTxMgr := newTestFaultResponder(t) + responder, _, contract := newTestFaultResponder(t) err := responder.CallResolveClaim(context.Background(), 0) require.NoError(t, err) - require.Equal(t, 1, mockTxMgr.calls) + require.Equal(t, 1, contract.calls) }) } func TestResolveClaim(t *testing.T) { t.Run("SendFails", func(t *testing.T) { - responder, mockTxMgr := newTestFaultResponder(t) + responder, mockTxMgr, _ := newTestFaultResponder(t) mockTxMgr.sendFails = true err := responder.ResolveClaim(context.Background(), 0) require.ErrorIs(t, err, mockSendError) @@ -100,7 +87,7 @@ func TestResolveClaim(t *testing.T) { }) t.Run("Success", func(t *testing.T) { - responder, mockTxMgr := newTestFaultResponder(t) + responder, mockTxMgr, _ := newTestFaultResponder(t) err := responder.ResolveClaim(context.Background(), 0) require.NoError(t, err) require.Equal(t, 1, mockTxMgr.sends) @@ -110,7 +97,7 @@ func TestResolveClaim(t *testing.T) { // TestRespond tests the [Responder.Respond] method. func TestPerformAction(t *testing.T) { t.Run("send fails", func(t *testing.T) { - responder, mockTxMgr := newTestFaultResponder(t) + responder, mockTxMgr, _ := newTestFaultResponder(t) mockTxMgr.sendFails = true err := responder.PerformAction(context.Background(), types.Action{ Type: types.ActionTypeMove, @@ -123,7 +110,7 @@ func TestPerformAction(t *testing.T) { }) t.Run("sends response", func(t *testing.T) { - responder, mockTxMgr := newTestFaultResponder(t) + responder, mockTxMgr, _ := newTestFaultResponder(t) err := responder.PerformAction(context.Background(), types.Action{ Type: types.ActionTypeMove, ParentIdx: 123, @@ -135,7 +122,7 @@ func TestPerformAction(t *testing.T) { }) t.Run("attack", func(t *testing.T) { - responder, mockTxMgr := newTestFaultResponder(t) + responder, mockTxMgr, contract := newTestFaultResponder(t) action := types.Action{ Type: types.ActionTypeMove, ParentIdx: 123, @@ -145,18 +132,13 @@ func TestPerformAction(t *testing.T) { err := responder.PerformAction(context.Background(), action) require.NoError(t, err) - // Pack the tx data manually. - fdgAbi, err := bindings.FaultDisputeGameMetaData.GetAbi() - require.NoError(t, err) - expected, err := fdgAbi.Pack("attack", big.NewInt(int64(action.ParentIdx)), action.Value) - require.NoError(t, err) - require.Len(t, mockTxMgr.sent, 1) - require.Equal(t, expected, mockTxMgr.sent[0].TxData) + require.EqualValues(t, []interface{}{uint64(action.ParentIdx), action.Value}, contract.attackArgs) + require.Equal(t, ([]byte)("attack"), mockTxMgr.sent[0].TxData) }) t.Run("defend", func(t *testing.T) { - responder, mockTxMgr := newTestFaultResponder(t) + responder, mockTxMgr, contract := newTestFaultResponder(t) action := types.Action{ Type: types.ActionTypeMove, ParentIdx: 123, @@ -166,18 +148,13 @@ func TestPerformAction(t *testing.T) { err := responder.PerformAction(context.Background(), action) require.NoError(t, err) - // Pack the tx data manually. - fdgAbi, err := bindings.FaultDisputeGameMetaData.GetAbi() - require.NoError(t, err) - expected, err := fdgAbi.Pack("defend", big.NewInt(int64(action.ParentIdx)), action.Value) - require.NoError(t, err) - require.Len(t, mockTxMgr.sent, 1) - require.Equal(t, expected, mockTxMgr.sent[0].TxData) + require.EqualValues(t, []interface{}{uint64(action.ParentIdx), action.Value}, contract.defendArgs) + require.Equal(t, ([]byte)("defend"), mockTxMgr.sent[0].TxData) }) t.Run("step", func(t *testing.T) { - responder, mockTxMgr := newTestFaultResponder(t) + responder, mockTxMgr, contract := newTestFaultResponder(t) action := types.Action{ Type: types.ActionTypeStep, ParentIdx: 123, @@ -188,36 +165,29 @@ func TestPerformAction(t *testing.T) { err := responder.PerformAction(context.Background(), action) require.NoError(t, err) - // Pack the tx data manually. - fdgAbi, err := bindings.FaultDisputeGameMetaData.GetAbi() - require.NoError(t, err) - expected, err := fdgAbi.Pack("step", big.NewInt(int64(action.ParentIdx)), true, action.PreState, action.ProofData) - require.NoError(t, err) - require.Len(t, mockTxMgr.sent, 1) - require.Equal(t, expected, mockTxMgr.sent[0].TxData) + require.EqualValues(t, []interface{}{uint64(action.ParentIdx), action.IsAttack, action.PreState, action.ProofData}, contract.stepArgs) + require.Equal(t, ([]byte)("step"), mockTxMgr.sent[0].TxData) }) } -func newTestFaultResponder(t *testing.T) (*FaultResponder, *mockTxManager) { +func newTestFaultResponder(t *testing.T) (*FaultResponder, *mockTxManager, *mockContract) { log := testlog.Logger(t, log.LvlError) mockTxMgr := &mockTxManager{} - responder, err := NewFaultResponder(log, mockTxMgr, mockFdgAddress) + contract := &mockContract{} + responder, err := NewFaultResponder(log, mockTxMgr, contract) require.NoError(t, err) - return responder, mockTxMgr + return responder, mockTxMgr, contract } type mockTxManager struct { from common.Address sends int sent []txmgr.TxCandidate - calls int sendFails bool - callFails bool - callBytes []byte } -func (m *mockTxManager) Send(ctx context.Context, candidate txmgr.TxCandidate) (*ethtypes.Receipt, error) { +func (m *mockTxManager) Send(_ context.Context, candidate txmgr.TxCandidate) (*ethtypes.Receipt, error) { if m.sendFails { return nil, mockSendError } @@ -230,23 +200,57 @@ func (m *mockTxManager) Send(ctx context.Context, candidate txmgr.TxCandidate) ( ), nil } -func (m *mockTxManager) Call(_ context.Context, _ ethereum.CallMsg, _ *big.Int) ([]byte, error) { +func (m *mockTxManager) BlockNumber(_ context.Context) (uint64, error) { + panic("not implemented") +} + +func (m *mockTxManager) From() common.Address { + return m.from +} + +type mockContract struct { + calls int + callFails bool + attackArgs []interface{} + defendArgs []interface{} + stepArgs []interface{} +} + +func (m *mockContract) CallResolve(_ context.Context) (gameTypes.GameStatus, error) { if m.callFails { - return nil, mockCallError + return gameTypes.GameStatusInProgress, mockCallError } m.calls++ - if m.callBytes != nil { - return m.callBytes, nil + return gameTypes.GameStatusInProgress, nil +} + +func (m *mockContract) ResolveTx() (txmgr.TxCandidate, error) { + return txmgr.TxCandidate{}, nil +} + +func (m *mockContract) CallResolveClaim(_ context.Context, _ uint64) error { + if m.callFails { + return mockCallError } - return common.Hex2Bytes( - "0000000000000000000000000000000000000000000000000000000000000000", - ), nil + m.calls++ + return nil } -func (m *mockTxManager) BlockNumber(ctx context.Context) (uint64, error) { - panic("not implemented") +func (m *mockContract) ResolveClaimTx(_ uint64) (txmgr.TxCandidate, error) { + return txmgr.TxCandidate{}, nil } -func (m *mockTxManager) From() common.Address { - return m.from +func (m *mockContract) AttackTx(parentClaimId uint64, claim common.Hash) (txmgr.TxCandidate, error) { + m.attackArgs = []interface{}{parentClaimId, claim} + return txmgr.TxCandidate{TxData: ([]byte)("attack")}, nil +} + +func (m *mockContract) DefendTx(parentClaimId uint64, claim common.Hash) (txmgr.TxCandidate, error) { + m.defendArgs = []interface{}{parentClaimId, claim} + return txmgr.TxCandidate{TxData: ([]byte)("defend")}, nil +} + +func (m *mockContract) StepTx(claimIdx uint64, isAttack bool, stateData []byte, proofData []byte) (txmgr.TxCandidate, error) { + m.stepArgs = []interface{}{claimIdx, isAttack, stateData, proofData} + return txmgr.TxCandidate{TxData: ([]byte)("step")}, nil } diff --git a/op-challenger/game/fault/solver/game_solver.go b/op-challenger/game/fault/solver/game_solver.go index adf9f0a846ed9..d4734ae6df8b3 100644 --- a/op-challenger/game/fault/solver/game_solver.go +++ b/op-challenger/game/fault/solver/game_solver.go @@ -12,7 +12,7 @@ type GameSolver struct { claimSolver *claimSolver } -func NewGameSolver(gameDepth int, trace types.TraceProvider) *GameSolver { +func NewGameSolver(gameDepth int, trace types.TraceAccessor) *GameSolver { return &GameSolver{ claimSolver: newClaimSolver(gameDepth, trace), } @@ -49,7 +49,7 @@ func (s *GameSolver) calculateStep(ctx context.Context, game types.Game, claim t return nil, nil } step, err := s.claimSolver.AttemptStep(ctx, game, claim) - if err == ErrStepIgnoreInvalidPath { + if errors.Is(err, ErrStepIgnoreInvalidPath) { return nil, nil } if err != nil { @@ -78,7 +78,7 @@ func (s *GameSolver) calculateMove(ctx context.Context, game types.Game, claim t } return &types.Action{ Type: types.ActionTypeMove, - IsAttack: !move.DefendsParent(), + IsAttack: !game.DefendsParent(*move), ParentIdx: move.ParentContractIndex, Value: move.Value, }, nil diff --git a/op-challenger/game/fault/solver/game_solver_test.go b/op-challenger/game/fault/solver/game_solver_test.go index c1e6699e53bf2..fe201fd30a328 100644 --- a/op-challenger/game/fault/solver/game_solver_test.go +++ b/op-challenger/game/fault/solver/game_solver_test.go @@ -6,6 +6,7 @@ import ( "testing" faulttest "github.com/ethereum-optimism/optimism/op-challenger/game/fault/test" + "github.com/ethereum-optimism/optimism/op-challenger/game/fault/trace" "github.com/ethereum/go-ethereum/common" "github.com/stretchr/testify/require" ) @@ -113,7 +114,7 @@ func TestCalculateNextActions(t *testing.T) { i, claim.Position.ToGIndex(), claim.Position.TraceIndex(maxDepth), claim.ParentContractIndex, claim.Countered, claim.Value) } - solver := NewGameSolver(maxDepth, claimBuilder.CorrectTraceProvider()) + solver := NewGameSolver(maxDepth, trace.NewSimpleTraceAccessor(claimBuilder.CorrectTraceProvider())) actions, err := solver.CalculateNextActions(context.Background(), game) require.NoError(t, err) for i, action := range actions { diff --git a/op-challenger/game/fault/solver/solver.go b/op-challenger/game/fault/solver/solver.go index 0f8f3a35ba00d..18e3fd6ba3f23 100644 --- a/op-challenger/game/fault/solver/solver.go +++ b/op-challenger/game/fault/solver/solver.go @@ -7,7 +7,6 @@ import ( "fmt" "github.com/ethereum-optimism/optimism/op-challenger/game/fault/types" - "github.com/ethereum/go-ethereum/common" ) var ( @@ -18,14 +17,14 @@ var ( // claimSolver uses a [TraceProvider] to determine the moves to make in a dispute game. type claimSolver struct { - trace types.TraceProvider + trace types.TraceAccessor gameDepth int } // newClaimSolver creates a new [claimSolver] using the provided [TraceProvider]. -func newClaimSolver(gameDepth int, traceProvider types.TraceProvider) *claimSolver { +func newClaimSolver(gameDepth int, trace types.TraceAccessor) *claimSolver { return &claimSolver{ - traceProvider, + trace, gameDepth, } } @@ -53,14 +52,14 @@ func (s *claimSolver) NextMove(ctx context.Context, claim types.Claim, game type } } - agree, err := s.agreeWithClaim(ctx, claim.ClaimData) + agree, err := s.agreeWithClaim(ctx, game, claim) if err != nil { return nil, err } if agree { - return s.defend(ctx, claim) + return s.defend(ctx, game, claim) } else { - return s.attack(ctx, claim) + return s.attack(ctx, game, claim) } } @@ -93,27 +92,24 @@ func (s *claimSolver) AttemptStep(ctx context.Context, game types.Game, claim ty return StepData{}, ErrStepIgnoreInvalidPath } - claimCorrect, err := s.agreeWithClaim(ctx, claim.ClaimData) + claimCorrect, err := s.agreeWithClaim(ctx, game, claim) if err != nil { return StepData{}, err } - var preState []byte - var proofData []byte - var oracleData *types.PreimageOracleData + var position types.Position if !claimCorrect { // Attack the claim by executing step index, so we need to get the pre-state of that index - preState, proofData, oracleData, err = s.trace.GetStepData(ctx, claim.Position) - if err != nil { - return StepData{}, err - } + position = claim.Position } else { - // We agree with the claim so Defend and use this claim as the starting point to - // execute the step after. Thus we need the pre-state of the next step. - preState, proofData, oracleData, err = s.trace.GetStepData(ctx, claim.MoveRight()) - if err != nil { - return StepData{}, err - } + // Defend and use this claim as the starting point to execute the step after. + // Thus, we need the pre-state of the next step. + position = claim.Position.MoveRight() + } + + preState, proofData, oracleData, err := s.trace.GetStepData(ctx, game, claim, position) + if err != nil { + return StepData{}, err } return StepData{ @@ -126,62 +122,58 @@ func (s *claimSolver) AttemptStep(ctx context.Context, game types.Game, claim ty } // attack returns a response that attacks the claim. -func (s *claimSolver) attack(ctx context.Context, claim types.Claim) (*types.Claim, error) { +func (s *claimSolver) attack(ctx context.Context, game types.Game, claim types.Claim) (*types.Claim, error) { position := claim.Attack() - value, err := s.traceAtPosition(ctx, position) + value, err := s.trace.Get(ctx, game, claim, position) if err != nil { return nil, fmt.Errorf("attack claim: %w", err) } return &types.Claim{ ClaimData: types.ClaimData{Value: value, Position: position}, - Parent: claim.ClaimData, ParentContractIndex: claim.ContractIndex, }, nil } // defend returns a response that defends the claim. -func (s *claimSolver) defend(ctx context.Context, claim types.Claim) (*types.Claim, error) { +func (s *claimSolver) defend(ctx context.Context, game types.Game, claim types.Claim) (*types.Claim, error) { if claim.IsRoot() { return nil, nil } position := claim.Defend() - value, err := s.traceAtPosition(ctx, position) + value, err := s.trace.Get(ctx, game, claim, position) if err != nil { return nil, fmt.Errorf("defend claim: %w", err) } return &types.Claim{ ClaimData: types.ClaimData{Value: value, Position: position}, - Parent: claim.ClaimData, ParentContractIndex: claim.ContractIndex, }, nil } // agreeWithClaim returns true if the claim is correct according to the internal [TraceProvider]. -func (s *claimSolver) agreeWithClaim(ctx context.Context, claim types.ClaimData) (bool, error) { - ourValue, err := s.traceAtPosition(ctx, claim.Position) +func (s *claimSolver) agreeWithClaim(ctx context.Context, game types.Game, claim types.Claim) (bool, error) { + ourValue, err := s.trace.Get(ctx, game, claim, claim.Position) return bytes.Equal(ourValue[:], claim.Value[:]), err } -// traceAtPosition returns the [common.Hash] from internal [TraceProvider] at the given [Position]. -func (s *claimSolver) traceAtPosition(ctx context.Context, p types.Position) (common.Hash, error) { - return s.trace.Get(ctx, p) -} - // agreeWithClaimPath returns true if the every other claim in the path to root is correct according to the internal [TraceProvider]. func (s *claimSolver) agreeWithClaimPath(ctx context.Context, game types.Game, claim types.Claim) (bool, error) { - agree, err := s.agreeWithClaim(ctx, claim.ClaimData) + agree, err := s.agreeWithClaim(ctx, game, claim) if err != nil { return false, err } if !agree { return false, nil } - if claim.IsRoot() || claim.Parent.IsRootPosition() { + if claim.IsRoot() { return true, nil } parent, err := game.GetParent(claim) if err != nil { - return false, err + return false, fmt.Errorf("failed to get parent of claim %v: %w", claim.ContractIndex, err) + } + if parent.IsRoot() { + return true, nil } grandParent, err := game.GetParent(parent) if err != nil { diff --git a/op-challenger/game/fault/solver/solver_test.go b/op-challenger/game/fault/solver/solver_test.go index 764a81b1962e9..de0899b55fd9e 100644 --- a/op-challenger/game/fault/solver/solver_test.go +++ b/op-challenger/game/fault/solver/solver_test.go @@ -6,6 +6,7 @@ import ( "testing" faulttest "github.com/ethereum-optimism/optimism/op-challenger/game/fault/test" + "github.com/ethereum-optimism/optimism/op-challenger/game/fault/trace" "github.com/ethereum-optimism/optimism/op-challenger/game/fault/types" "github.com/ethereum/go-ethereum/common" "github.com/stretchr/testify/require" @@ -161,7 +162,7 @@ func TestAttemptStep(t *testing.T) { t.Run(tableTest.name, func(t *testing.T) { builder := claimBuilder.GameBuilder(tableTest.agreeWithOutputRoot, !tableTest.agreeWithOutputRoot) tableTest.setupGame(builder) - alphabetSolver := newClaimSolver(maxDepth, claimBuilder.CorrectTraceProvider()) + alphabetSolver := newClaimSolver(maxDepth, trace.NewSimpleTraceAccessor(claimBuilder.CorrectTraceProvider())) game := builder.Game claims := game.Claims() lastClaim := claims[len(claims)-1] diff --git a/op-challenger/game/fault/test/alphabet.go b/op-challenger/game/fault/test/alphabet.go index 8fba90100e1b8..3ae75c0943e53 100644 --- a/op-challenger/game/fault/test/alphabet.go +++ b/op-challenger/game/fault/test/alphabet.go @@ -33,6 +33,6 @@ func (a *alphabetWithProofProvider) GetStepData(ctx context.Context, i types.Pos return nil, nil, nil, err } traceIndex := i.TraceIndex(int(a.depth)).Uint64() - data := types.NewPreimageOracleData([]byte{byte(traceIndex)}, []byte{byte(traceIndex - 1)}, uint32(traceIndex-1)) + data := types.NewPreimageOracleData(0, []byte{byte(traceIndex)}, []byte{byte(traceIndex - 1)}, uint32(traceIndex-1)) return preimage, []byte{byte(traceIndex - 1)}, data, nil } diff --git a/op-challenger/game/fault/test/claim_builder.go b/op-challenger/game/fault/test/claim_builder.go index d0c648267c857..7bb6e19b7c493 100644 --- a/op-challenger/game/fault/test/claim_builder.go +++ b/op-challenger/game/fault/test/claim_builder.go @@ -85,17 +85,12 @@ func (c *ClaimBuilder) CreateRootClaim(correct bool) types.Claim { } func (c *ClaimBuilder) CreateLeafClaim(traceIndex *big.Int, correct bool) types.Claim { - parentPos := types.NewPosition(c.maxDepth-1, common.Big0) pos := types.NewPosition(c.maxDepth, traceIndex) return types.Claim{ ClaimData: types.ClaimData{ Value: c.claim(pos, correct), Position: pos, }, - Parent: types.ClaimData{ - Value: c.claim(parentPos, !correct), - Position: parentPos, - }, } } @@ -106,7 +101,6 @@ func (c *ClaimBuilder) AttackClaim(claim types.Claim, correct bool) types.Claim Value: c.claim(pos, correct), Position: pos, }, - Parent: claim.ClaimData, ParentContractIndex: claim.ContractIndex, } } @@ -118,7 +112,6 @@ func (c *ClaimBuilder) AttackClaimWithValue(claim types.Claim, value common.Hash Value: value, Position: pos, }, - Parent: claim.ClaimData, ParentContractIndex: claim.ContractIndex, } } @@ -130,7 +123,6 @@ func (c *ClaimBuilder) DefendClaim(claim types.Claim, correct bool) types.Claim Value: c.claim(pos, correct), Position: pos, }, - Parent: claim.ClaimData, ParentContractIndex: claim.ContractIndex, } } @@ -142,7 +134,6 @@ func (c *ClaimBuilder) DefendClaimWithValue(claim types.Claim, value common.Hash Value: value, Position: pos, }, - Parent: claim.ClaimData, ParentContractIndex: claim.ContractIndex, } } diff --git a/op-challenger/game/fault/trace/access.go b/op-challenger/game/fault/trace/access.go new file mode 100644 index 0000000000000..fb024045d0b98 --- /dev/null +++ b/op-challenger/game/fault/trace/access.go @@ -0,0 +1,39 @@ +package trace + +import ( + "context" + + "github.com/ethereum-optimism/optimism/op-challenger/game/fault/types" + "github.com/ethereum/go-ethereum/common" +) + +type ProviderCreator func(ctx context.Context, pre types.Claim, post types.Claim) (types.TraceProvider, error) + +func NewSimpleTraceAccessor(trace types.TraceProvider) *Accessor { + selector := func(_ context.Context, _ types.Game, _ types.Claim, _ types.Position) (types.TraceProvider, error) { + return trace, nil + } + return &Accessor{selector} +} + +type Accessor struct { + selector func(ctx context.Context, game types.Game, ref types.Claim, pos types.Position) (types.TraceProvider, error) +} + +func (t *Accessor) Get(ctx context.Context, game types.Game, ref types.Claim, pos types.Position) (common.Hash, error) { + provider, err := t.selector(ctx, game, ref, pos) + if err != nil { + return common.Hash{}, err + } + return provider.Get(ctx, pos) +} + +func (t *Accessor) GetStepData(ctx context.Context, game types.Game, ref types.Claim, pos types.Position) (prestate []byte, proofData []byte, preimageData *types.PreimageOracleData, err error) { + provider, err := t.selector(ctx, game, ref, pos) + if err != nil { + return nil, nil, nil, err + } + return provider.GetStepData(ctx, pos) +} + +var _ types.TraceAccessor = (*Accessor)(nil) diff --git a/op-challenger/game/fault/trace/access_test.go b/op-challenger/game/fault/trace/access_test.go new file mode 100644 index 0000000000000..0e5365316aa6f --- /dev/null +++ b/op-challenger/game/fault/trace/access_test.go @@ -0,0 +1,70 @@ +package trace + +import ( + "context" + "fmt" + "math/big" + "testing" + + "github.com/ethereum-optimism/optimism/op-challenger/game/fault/test" + "github.com/ethereum-optimism/optimism/op-challenger/game/fault/trace/alphabet" + "github.com/ethereum-optimism/optimism/op-challenger/game/fault/types" + "github.com/stretchr/testify/require" +) + +func TestAccessor_UsesSelector(t *testing.T) { + ctx := context.Background() + depth := uint64(4) + provider1 := test.NewAlphabetWithProofProvider(t, int(depth), nil) + provider2 := alphabet.NewTraceProvider("qrstuv", depth) + claim := types.Claim{} + game := types.NewGameState(true, []types.Claim{claim}, depth) + pos1 := types.NewPositionFromGIndex(big.NewInt(4)) + pos2 := types.NewPositionFromGIndex(big.NewInt(6)) + + accessor := &Accessor{ + selector: func(ctx context.Context, actualGame types.Game, ref types.Claim, pos types.Position) (types.TraceProvider, error) { + require.Equal(t, game, actualGame) + require.Equal(t, claim, ref) + + if pos == pos1 { + return provider1, nil + } else if pos == pos2 { + return provider2, nil + } + return nil, fmt.Errorf("incorrect position requested: %v", pos) + }, + } + + t.Run("Get", func(t *testing.T) { + actual, err := accessor.Get(ctx, game, claim, pos1) + require.NoError(t, err) + expected, err := provider1.Get(ctx, pos1) + require.NoError(t, err) + require.Equal(t, expected, actual) + + actual, err = accessor.Get(ctx, game, claim, pos2) + require.NoError(t, err) + expected, err = provider2.Get(ctx, pos2) + require.NoError(t, err) + require.Equal(t, expected, actual) + }) + + t.Run("GetStepData", func(t *testing.T) { + actualPrestate, actualProofData, actualPreimageData, err := accessor.GetStepData(ctx, game, claim, pos1) + require.NoError(t, err) + expectedPrestate, expectedProofData, expectedPreimageData, err := provider1.GetStepData(ctx, pos1) + require.NoError(t, err) + require.Equal(t, expectedPrestate, actualPrestate) + require.Equal(t, expectedProofData, actualProofData) + require.Equal(t, expectedPreimageData, actualPreimageData) + + actualPrestate, actualProofData, actualPreimageData, err = accessor.GetStepData(ctx, game, claim, pos2) + require.NoError(t, err) + expectedPrestate, expectedProofData, expectedPreimageData, err = provider2.GetStepData(ctx, pos2) + require.NoError(t, err) + require.Equal(t, expectedPrestate, actualPrestate) + require.Equal(t, expectedProofData, actualProofData) + require.Equal(t, expectedPreimageData, actualPreimageData) + }) +} diff --git a/op-challenger/game/fault/trace/alphabet/provider.go b/op-challenger/game/fault/trace/alphabet/provider.go index 9297642507360..ac64a6da6639f 100644 --- a/op-challenger/game/fault/trace/alphabet/provider.go +++ b/op-challenger/game/fault/trace/alphabet/provider.go @@ -14,6 +14,7 @@ import ( var ( ErrIndexTooLarge = errors.New("index is larger than the maximum index") + absolutePrestate = common.Hex2Bytes("0000000000000000000000000000000000000000000000000000000000000060") ) // AlphabetTraceProvider is a [TraceProvider] that provides claims for specific @@ -36,11 +37,7 @@ func NewTraceProvider(state string, depth uint64) *AlphabetTraceProvider { func (ap *AlphabetTraceProvider) GetStepData(ctx context.Context, i types.Position) ([]byte, []byte, *types.PreimageOracleData, error) { traceIndex := i.TraceIndex(int(ap.depth)) if traceIndex.Cmp(common.Big0) == 0 { - prestate, err := ap.AbsolutePreState(ctx) - if err != nil { - return nil, nil, nil, err - } - return prestate, []byte{}, nil, nil + return absolutePrestate, []byte{}, nil, nil } // We want the pre-state which is the value prior to the one requested traceIndex = traceIndex.Sub(traceIndex, big.NewInt(1)) @@ -67,17 +64,8 @@ func (ap *AlphabetTraceProvider) Get(ctx context.Context, i types.Position) (com return alphabetStateHash(claimBytes), nil } -// AbsolutePreState returns the absolute pre-state for the alphabet trace. -func (ap *AlphabetTraceProvider) AbsolutePreState(ctx context.Context) ([]byte, error) { - return common.Hex2Bytes("0000000000000000000000000000000000000000000000000000000000000060"), nil -} - -func (ap *AlphabetTraceProvider) AbsolutePreStateCommitment(ctx context.Context) (common.Hash, error) { - prestate, err := ap.AbsolutePreState(ctx) - if err != nil { - return common.Hash{}, err - } - hash := common.BytesToHash(crypto.Keccak256(prestate)) +func (ap *AlphabetTraceProvider) AbsolutePreStateCommitment(_ context.Context) (common.Hash, error) { + hash := common.BytesToHash(crypto.Keccak256(absolutePrestate)) hash[0] = mipsevm.VMStatusUnfinished return hash, nil } diff --git a/op-challenger/game/fault/trace/cannon/executor_test.go b/op-challenger/game/fault/trace/cannon/executor_test.go index a37c3132b0c71..38e2fc909c610 100644 --- a/op-challenger/game/fault/trace/cannon/executor_test.go +++ b/op-challenger/game/fault/trace/cannon/executor_test.go @@ -24,7 +24,7 @@ func TestGenerateProof(t *testing.T) { input := "starting.json" tempDir := t.TempDir() dir := filepath.Join(tempDir, "gameDir") - cfg := config.NewConfig(common.Address{0xbb}, "http://localhost:8888", config.TraceTypeCannon, true, tempDir) + cfg := config.NewConfig(common.Address{0xbb}, "http://localhost:8888", true, tempDir, config.TraceTypeCannon) cfg.CannonAbsolutePreState = "pre.json" cfg.CannonBin = "./bin/cannon" cfg.CannonServer = "./bin/op-program" diff --git a/op-challenger/game/fault/trace/cannon/local.go b/op-challenger/game/fault/trace/cannon/local.go index ac766af9de4ac..37ad65b8c62be 100644 --- a/op-challenger/game/fault/trace/cannon/local.go +++ b/op-challenger/game/fault/trace/cannon/local.go @@ -5,8 +5,7 @@ import ( "fmt" "math/big" - "github.com/ethereum-optimism/optimism/op-bindings/bindings" - "github.com/ethereum/go-ethereum/accounts/abi/bind" + "github.com/ethereum-optimism/optimism/op-challenger/game/fault/contracts" "github.com/ethereum/go-ethereum/common" ethtypes "github.com/ethereum/go-ethereum/core/types" ) @@ -25,26 +24,20 @@ type L2DataSource interface { } type GameInputsSource interface { - L1Head(opts *bind.CallOpts) ([32]byte, error) - Proposals(opts *bind.CallOpts) (struct { - Starting bindings.IFaultDisputeGameOutputProposal - Disputed bindings.IFaultDisputeGameOutputProposal - }, error) + GetL1Head(ctx context.Context) (common.Hash, error) + GetProposals(ctx context.Context) (agreed contracts.Proposal, disputed contracts.Proposal, err error) } -func fetchLocalInputs(ctx context.Context, gameAddr common.Address, caller GameInputsSource, l2Client L2DataSource) (LocalGameInputs, error) { - opts := &bind.CallOpts{Context: ctx} - l1Head, err := caller.L1Head(opts) +func fetchLocalInputs(ctx context.Context, caller GameInputsSource, l2Client L2DataSource) (LocalGameInputs, error) { + l1Head, err := caller.GetL1Head(ctx) if err != nil { - return LocalGameInputs{}, fmt.Errorf("fetch L1 head for game %v: %w", gameAddr, err) + return LocalGameInputs{}, fmt.Errorf("fetch L1 head: %w", err) } - proposals, err := caller.Proposals(opts) + agreedOutput, claimedOutput, err := caller.GetProposals(ctx) if err != nil { return LocalGameInputs{}, fmt.Errorf("fetch proposals: %w", err) } - claimedOutput := proposals.Disputed - agreedOutput := proposals.Starting agreedHeader, err := l2Client.HeaderByNumber(ctx, agreedOutput.L2BlockNumber) if err != nil { return LocalGameInputs{}, fmt.Errorf("fetch L2 block header %v: %w", agreedOutput.L2BlockNumber, err) diff --git a/op-challenger/game/fault/trace/cannon/local_test.go b/op-challenger/game/fault/trace/cannon/local_test.go index 087e4f04748d9..76e76fea768d0 100644 --- a/op-challenger/game/fault/trace/cannon/local_test.go +++ b/op-challenger/game/fault/trace/cannon/local_test.go @@ -5,9 +5,8 @@ import ( "math/big" "testing" - "github.com/ethereum-optimism/optimism/op-bindings/bindings" + "github.com/ethereum-optimism/optimism/op-challenger/game/fault/contracts" "github.com/ethereum/go-ethereum" - "github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/common" ethtypes "github.com/ethereum/go-ethereum/core/types" "github.com/stretchr/testify/require" @@ -15,15 +14,14 @@ import ( func TestFetchLocalInputs(t *testing.T) { ctx := context.Background() - gameAddr := common.Address{0xab} - l1Client := &mockGameInputsSource{ + contract := &mockGameInputsSource{ l1Head: common.Hash{0xcc}, - starting: bindings.IFaultDisputeGameOutputProposal{ + starting: contracts.Proposal{ Index: big.NewInt(6), L2BlockNumber: big.NewInt(2222), OutputRoot: common.Hash{0xdd}, }, - disputed: bindings.IFaultDisputeGameOutputProposal{ + disputed: contracts.Proposal{ Index: big.NewInt(7), L2BlockNumber: big.NewInt(3333), OutputRoot: common.Hash{0xee}, @@ -32,41 +30,32 @@ func TestFetchLocalInputs(t *testing.T) { l2Client := &mockL2DataSource{ chainID: big.NewInt(88422), header: ethtypes.Header{ - Number: l1Client.starting.L2BlockNumber, + Number: contract.starting.L2BlockNumber, }, } - inputs, err := fetchLocalInputs(ctx, gameAddr, l1Client, l2Client) + inputs, err := fetchLocalInputs(ctx, contract, l2Client) require.NoError(t, err) - require.Equal(t, l1Client.l1Head, inputs.L1Head) + require.Equal(t, contract.l1Head, inputs.L1Head) require.Equal(t, l2Client.header.Hash(), inputs.L2Head) - require.EqualValues(t, l1Client.starting.OutputRoot, inputs.L2OutputRoot) - require.EqualValues(t, l1Client.disputed.OutputRoot, inputs.L2Claim) - require.Equal(t, l1Client.disputed.L2BlockNumber, inputs.L2BlockNumber) + require.EqualValues(t, contract.starting.OutputRoot, inputs.L2OutputRoot) + require.EqualValues(t, contract.disputed.OutputRoot, inputs.L2Claim) + require.Equal(t, contract.disputed.L2BlockNumber, inputs.L2BlockNumber) } type mockGameInputsSource struct { l1Head common.Hash - starting bindings.IFaultDisputeGameOutputProposal - disputed bindings.IFaultDisputeGameOutputProposal + starting contracts.Proposal + disputed contracts.Proposal } -func (s *mockGameInputsSource) L1Head(opts *bind.CallOpts) ([32]byte, error) { +func (s *mockGameInputsSource) GetL1Head(_ context.Context) (common.Hash, error) { return s.l1Head, nil } -func (s *mockGameInputsSource) Proposals(opts *bind.CallOpts) (struct { - Starting bindings.IFaultDisputeGameOutputProposal - Disputed bindings.IFaultDisputeGameOutputProposal -}, error) { - return struct { - Starting bindings.IFaultDisputeGameOutputProposal - Disputed bindings.IFaultDisputeGameOutputProposal - }{ - Starting: s.starting, - Disputed: s.disputed, - }, nil +func (s *mockGameInputsSource) GetProposals(_ context.Context) (contracts.Proposal, contracts.Proposal, error) { + return s.starting, s.disputed, nil } type mockL2DataSource struct { diff --git a/op-challenger/game/fault/trace/cannon/provider.go b/op-challenger/game/fault/trace/cannon/provider.go index 41d088fc5970a..0a727c5f8648f 100644 --- a/op-challenger/game/fault/trace/cannon/provider.go +++ b/op-challenger/game/fault/trace/cannon/provider.go @@ -8,11 +8,10 @@ import ( "os" "path/filepath" - "github.com/ethereum-optimism/optimism/op-bindings/bindings" "github.com/ethereum-optimism/optimism/op-challenger/config" + "github.com/ethereum-optimism/optimism/op-challenger/game/fault/contracts" "github.com/ethereum-optimism/optimism/op-challenger/game/fault/types" "github.com/ethereum-optimism/optimism/op-service/ioutil" - "github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common/hexutil" "github.com/ethereum/go-ethereum/ethclient" @@ -56,17 +55,13 @@ type CannonTraceProvider struct { lastStep uint64 } -func NewTraceProvider(ctx context.Context, logger log.Logger, m CannonMetricer, cfg *config.Config, l1Client bind.ContractCaller, dir string, gameAddr common.Address, gameDepth uint64) (*CannonTraceProvider, error) { +func NewTraceProvider(ctx context.Context, logger log.Logger, m CannonMetricer, cfg *config.Config, gameContract *contracts.FaultDisputeGameContract, dir string, gameDepth uint64) (*CannonTraceProvider, error) { l2Client, err := ethclient.DialContext(ctx, cfg.CannonL2) if err != nil { return nil, fmt.Errorf("dial l2 client %v: %w", cfg.CannonL2, err) } defer l2Client.Close() // Not needed after fetching the inputs - gameCaller, err := bindings.NewFaultDisputeGameCaller(gameAddr, l1Client) - if err != nil { - return nil, fmt.Errorf("create caller for game %v: %w", gameAddr, err) - } - localInputs, err := fetchLocalInputs(ctx, gameAddr, gameCaller, l2Client) + localInputs, err := fetchLocalInputs(ctx, gameContract, l2Client) if err != nil { return nil, fmt.Errorf("fetch local game inputs: %w", err) } @@ -123,12 +118,13 @@ func (p *CannonTraceProvider) GetStepData(ctx context.Context, pos types.Positio } var oracleData *types.PreimageOracleData if len(proof.OracleKey) > 0 { - oracleData = types.NewPreimageOracleData(proof.OracleKey, proof.OracleValue, proof.OracleOffset) + // TODO(client-pod#104): Replace the LocalContext `0` argument below with the correct local context. + oracleData = types.NewPreimageOracleData(0, proof.OracleKey, proof.OracleValue, proof.OracleOffset) } return value, data, oracleData, nil } -func (p *CannonTraceProvider) AbsolutePreState(ctx context.Context) ([]byte, error) { +func (p *CannonTraceProvider) absolutePreState() ([]byte, error) { state, err := parseState(p.prestate) if err != nil { return nil, fmt.Errorf("cannot load absolute pre-state: %w", err) @@ -136,8 +132,8 @@ func (p *CannonTraceProvider) AbsolutePreState(ctx context.Context) ([]byte, err return state.EncodeWitness(), nil } -func (p *CannonTraceProvider) AbsolutePreStateCommitment(ctx context.Context) (common.Hash, error) { - state, err := p.AbsolutePreState(ctx) +func (p *CannonTraceProvider) AbsolutePreStateCommitment(_ context.Context) (common.Hash, error) { + state, err := p.absolutePreState() if err != nil { return common.Hash{}, fmt.Errorf("cannot load absolute pre-state: %w", err) } diff --git a/op-challenger/game/fault/trace/cannon/provider_test.go b/op-challenger/game/fault/trace/cannon/provider_test.go index 4671c0516e911..fdf969345e298 100644 --- a/op-challenger/game/fault/trace/cannon/provider_test.go +++ b/op-challenger/game/fault/trace/cannon/provider_test.go @@ -124,7 +124,7 @@ func TestGetStepData(t *testing.T) { require.EqualValues(t, generator.proof.StateData, preimage) require.EqualValues(t, generator.proof.ProofData, proof) - expectedData := types.NewPreimageOracleData(generator.proof.OracleKey, generator.proof.OracleValue, generator.proof.OracleOffset) + expectedData := types.NewPreimageOracleData(0, generator.proof.OracleKey, generator.proof.OracleValue, generator.proof.OracleOffset) require.EqualValues(t, expectedData, data) }) @@ -216,28 +216,28 @@ func TestGetStepData(t *testing.T) { }) } -func TestAbsolutePreState(t *testing.T) { +func TestAbsolutePreStateCommitment(t *testing.T) { dataDir := t.TempDir() prestate := "state.json" t.Run("StateUnavailable", func(t *testing.T) { provider, _ := setupWithTestData(t, "/dir/does/not/exist", prestate) - _, err := provider.AbsolutePreState(context.Background()) + _, err := provider.AbsolutePreStateCommitment(context.Background()) require.ErrorIs(t, err, os.ErrNotExist) }) t.Run("InvalidStateFile", func(t *testing.T) { setupPreState(t, dataDir, "invalid.json") provider, _ := setupWithTestData(t, dataDir, prestate) - _, err := provider.AbsolutePreState(context.Background()) + _, err := provider.AbsolutePreStateCommitment(context.Background()) require.ErrorContains(t, err, "invalid mipsevm state") }) t.Run("ExpectedAbsolutePreState", func(t *testing.T) { setupPreState(t, dataDir, "state.json") provider, _ := setupWithTestData(t, dataDir, prestate) - preState, err := provider.AbsolutePreState(context.Background()) + actual, err := provider.AbsolutePreStateCommitment(context.Background()) require.NoError(t, err) state := mipsevm.State{ Memory: mipsevm.NewMemory(), @@ -253,7 +253,9 @@ func TestAbsolutePreState(t *testing.T) { Step: 0, Registers: [32]uint32{}, } - require.Equal(t, []byte(state.EncodeWitness()), preState) + expected, err := state.EncodeWitness().StateHash() + require.NoError(t, err) + require.Equal(t, expected, actual) }) } diff --git a/op-challenger/game/fault/trace/cannon/updater.go b/op-challenger/game/fault/trace/cannon/updater.go index 5451b9e28ee36..f684689ce83f8 100644 --- a/op-challenger/game/fault/trace/cannon/updater.go +++ b/op-challenger/game/fault/trace/cannon/updater.go @@ -118,6 +118,7 @@ func (u *cannonUpdater) BuildLocalOracleData(data *types.PreimageOracleData) ([] return u.fdgAbi.Pack( "addLocalData", data.GetIdent(), + big.NewInt(int64(data.LocalContext)), big.NewInt(int64(data.OracleOffset)), ) } diff --git a/op-challenger/game/fault/trace/cannon/updater_test.go b/op-challenger/game/fault/trace/cannon/updater_test.go index 31cc389801917..1dddad4e11ea1 100644 --- a/op-challenger/game/fault/trace/cannon/updater_test.go +++ b/op-challenger/game/fault/trace/cannon/updater_test.go @@ -3,14 +3,13 @@ package cannon import ( "context" "errors" - "math/big" "testing" + "github.com/ethereum-optimism/optimism/op-bindings/bindings" "github.com/ethereum-optimism/optimism/op-challenger/game/fault/types" "github.com/ethereum-optimism/optimism/op-service/testlog" "github.com/ethereum-optimism/optimism/op-service/txmgr" - "github.com/ethereum/go-ethereum" ethtypes "github.com/ethereum/go-ethereum/core/types" "github.com/ethereum/go-ethereum/common" @@ -46,10 +45,6 @@ func (m *mockTxManager) Send(ctx context.Context, candidate txmgr.TxCandidate) ( ), nil } -func (m *mockTxManager) Call(_ context.Context, _ ethereum.CallMsg, _ *big.Int) ([]byte, error) { - panic("not implemented") -} - func (m *mockTxManager) BlockNumber(ctx context.Context) (uint64, error) { panic("not implemented") } @@ -104,12 +99,15 @@ func TestCannonUpdater_BuildLocalOracleData(t *testing.T) { txData, err := updater.BuildLocalOracleData(oracleData) require.NoError(t, err) - var addLocalDataBytes4 = crypto.Keccak256([]byte("addLocalData(uint256,uint256)"))[:4] + fdgAbi, err := bindings.FaultDisputeGameMetaData.GetAbi() + require.NoError(t, err) + addLocalDataBytes4 := fdgAbi.Methods["addLocalData"].ID[:4] // Pack the tx data manually. var expected []byte expected = append(expected, addLocalDataBytes4...) expected = append(expected, common.Hex2Bytes("00aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")...) + expected = append(expected, common.Hex2Bytes("0000000000000000000000000000000000000000000000000000000000000000")...) expected = append(expected, common.Hex2Bytes("0000000000000000000000000000000000000000000000000000000000000007")...) require.Equal(t, expected, txData) diff --git a/op-challenger/game/fault/trace/outputs/provider.go b/op-challenger/game/fault/trace/outputs/provider.go index d1f6d4c0089d6..4d20c2a1e64a5 100644 --- a/op-challenger/game/fault/trace/outputs/provider.go +++ b/op-challenger/game/fault/trace/outputs/provider.go @@ -34,7 +34,7 @@ type OutputTraceProvider struct { } func NewTraceProvider(ctx context.Context, logger log.Logger, rollupRpc string, gameDepth, prestateBlock, poststateBlock uint64) (*OutputTraceProvider, error) { - rollupClient, err := dial.DialRollupClientWithTimeout(dial.DefaultDialTimeout, logger, rollupRpc) + rollupClient, err := dial.DialRollupClientWithTimeout(ctx, dial.DefaultDialTimeout, logger, rollupRpc) if err != nil { return nil, err } diff --git a/op-challenger/game/fault/trace/split/provider.go b/op-challenger/game/fault/trace/split/provider.go index 6d61c8ab9a138..eb77f198116c9 100644 --- a/op-challenger/game/fault/trace/split/provider.go +++ b/op-challenger/game/fault/trace/split/provider.go @@ -56,11 +56,6 @@ func (s *SplitTraceProvider) AbsolutePreStateCommitment(ctx context.Context) (ha return s.bottomProvider.AbsolutePreStateCommitment(ctx) } -// AbsolutePreState routes the AbsolutePreState request to the lowest internal [types.TraceProvider]. -func (s *SplitTraceProvider) AbsolutePreState(ctx context.Context) (preimage []byte, err error) { - return s.bottomProvider.AbsolutePreState(ctx) -} - // GetStepData routes the GetStepData request to the lowest internal [types.TraceProvider]. func (s *SplitTraceProvider) GetStepData(ctx context.Context, pos types.Position) (prestate []byte, proofData []byte, preimageData *types.PreimageOracleData, err error) { ancestorDepth, provider := s.providerForDepth(uint64(pos.Depth())) diff --git a/op-challenger/game/fault/trace/split/provider_test.go b/op-challenger/game/fault/trace/split/provider_test.go index 2845bfc66cb4a..b63ab6d933495 100644 --- a/op-challenger/game/fault/trace/split/provider_test.go +++ b/op-challenger/game/fault/trace/split/provider_test.go @@ -64,24 +64,6 @@ func TestAbsolutePreStateCommitment(t *testing.T) { }) } -func TestAbsolutePreState(t *testing.T) { - t.Run("ErrorBubblesUp", func(t *testing.T) { - mockOutputProvider := mockTraceProvider{absolutePreStateError: mockGetError} - splitProvider := newSplitTraceProvider(t, nil, &mockOutputProvider, 40) - _, err := splitProvider.AbsolutePreState(context.Background()) - require.ErrorIs(t, err, mockGetError) - }) - - t.Run("ReturnsCorrectPreimageData", func(t *testing.T) { - expectedPreimage := []byte{1, 2, 3, 4} - mockOutputProvider := mockTraceProvider{preImageData: expectedPreimage} - splitProvider := newSplitTraceProvider(t, nil, &mockOutputProvider, 40) - output, err := splitProvider.AbsolutePreState(context.Background()) - require.NoError(t, err) - require.Equal(t, expectedPreimage, output) - }) -} - func TestGetStepData(t *testing.T) { t.Run("ErrorBubblesUp", func(t *testing.T) { mockOutputProvider := mockTraceProvider{getStepDataError: mockGetError} diff --git a/op-challenger/game/fault/trace/translate.go b/op-challenger/game/fault/trace/translate.go new file mode 100644 index 0000000000000..fbe8b58c544fc --- /dev/null +++ b/op-challenger/game/fault/trace/translate.go @@ -0,0 +1,42 @@ +package trace + +import ( + "context" + + "github.com/ethereum-optimism/optimism/op-challenger/game/fault/types" + "github.com/ethereum/go-ethereum/common" +) + +type translatingProvider struct { + parentDepth uint64 + provider types.TraceProvider +} + +func Translate(provider types.TraceProvider, parentDepth uint64) types.TraceProvider { + return &translatingProvider{ + parentDepth: parentDepth, + provider: provider, + } +} + +func (p translatingProvider) Get(ctx context.Context, pos types.Position) (common.Hash, error) { + relativePos, err := pos.RelativeToAncestorAtDepth(p.parentDepth) + if err != nil { + return common.Hash{}, err + } + return p.provider.Get(ctx, relativePos) +} + +func (p translatingProvider) GetStepData(ctx context.Context, pos types.Position) (prestate []byte, proofData []byte, preimageData *types.PreimageOracleData, err error) { + relativePos, err := pos.RelativeToAncestorAtDepth(p.parentDepth) + if err != nil { + return nil, nil, nil, err + } + return p.provider.GetStepData(ctx, relativePos) +} + +func (p translatingProvider) AbsolutePreStateCommitment(ctx context.Context) (hash common.Hash, err error) { + return p.provider.AbsolutePreStateCommitment(ctx) +} + +var _ types.TraceProvider = (*translatingProvider)(nil) diff --git a/op-challenger/game/fault/trace/translate_test.go b/op-challenger/game/fault/trace/translate_test.go new file mode 100644 index 0000000000000..b60e3e6fdb6ec --- /dev/null +++ b/op-challenger/game/fault/trace/translate_test.go @@ -0,0 +1,60 @@ +package trace + +import ( + "context" + "math/big" + "testing" + + "github.com/ethereum-optimism/optimism/op-challenger/game/fault/trace/alphabet" + "github.com/ethereum-optimism/optimism/op-challenger/game/fault/types" + "github.com/stretchr/testify/require" +) + +func TestTranslate(t *testing.T) { + orig := alphabet.NewTraceProvider("abcdefghij", 4) + translated := Translate(orig, 3) + // All nodes on the first translated layer, map to GIndex 1 + for i := int64(8); i <= 15; i++ { + requireSameValue(t, orig, 1, translated, i) + } + // Nodes on the second translated layer map to GIndex 2 and 3 alternately + for i := int64(16); i <= 31; i += 2 { + requireSameValue(t, orig, 2, translated, i) + requireSameValue(t, orig, 3, translated, i+1) + } + // Nodes on the third translated layer map to GIndex 4, 5, 6 and 7 + for i := int64(32); i <= 61; i += 4 { + requireSameValue(t, orig, 4, translated, i) + requireSameValue(t, orig, 5, translated, i+1) + requireSameValue(t, orig, 6, translated, i+2) + requireSameValue(t, orig, 7, translated, i+3) + } +} + +func requireSameValue(t *testing.T, a types.TraceProvider, aGIdx int64, b types.TraceProvider, bGIdx int64) { + // Check Get returns the same results + aValue, err := a.Get(context.Background(), types.NewPositionFromGIndex(big.NewInt(aGIdx))) + require.NoError(t, err) + bValue, err := b.Get(context.Background(), types.NewPositionFromGIndex(big.NewInt(bGIdx))) + require.NoError(t, err) + require.Equal(t, aValue, bValue) + + // Check GetStepData returns the same results + aPrestate, aProofData, aPreimageData, err := a.GetStepData(context.Background(), types.NewPositionFromGIndex(big.NewInt(aGIdx))) + require.NoError(t, err) + bPrestate, bProofData, bPreimageData, err := b.GetStepData(context.Background(), types.NewPositionFromGIndex(big.NewInt(bGIdx))) + require.NoError(t, err) + require.Equal(t, aPrestate, bPrestate) + require.Equal(t, aProofData, bProofData) + require.Equal(t, aPreimageData, bPreimageData) +} + +func TestTranslate_AbsolutePreStateCommitment(t *testing.T) { + orig := alphabet.NewTraceProvider("abcdefghij", 4) + translated := Translate(orig, 3) + origValue, err := orig.AbsolutePreStateCommitment(context.Background()) + require.NoError(t, err) + translatedValue, err := translated.AbsolutePreStateCommitment(context.Background()) + require.NoError(t, err) + require.Equal(t, origValue, translatedValue) +} diff --git a/op-challenger/game/fault/types/game.go b/op-challenger/game/fault/types/game.go index 4ef18b93cf519..2f6fd994c2f31 100644 --- a/op-challenger/game/fault/types/game.go +++ b/op-challenger/game/fault/types/game.go @@ -24,6 +24,10 @@ type Game interface { // GetParent returns the parent of the provided claim. GetParent(claim Claim) (Claim, error) + // DefendsParent returns true if and only if the claim is a defense (i.e. goes right) of + // its parent. + DefendsParent(claim Claim) bool + // IsDuplicate returns true if the provided [Claim] already exists in the game state // referencing the same parent claim IsDuplicate(claim Claim) bool @@ -102,6 +106,14 @@ func (g *gameState) GetParent(claim Claim) (Claim, error) { return *parent, nil } +func (g *gameState) DefendsParent(claim Claim) bool { + parent := g.getParent(claim) + if parent == nil { + return false + } + return claim.RightOf(parent.Position) +} + func (g *gameState) getParent(claim Claim) *Claim { if claim.IsRoot() { return nil diff --git a/op-challenger/game/fault/types/game_test.go b/op-challenger/game/fault/types/game_test.go index ec6467ca77851..22ef7e0d5504b 100644 --- a/op-challenger/game/fault/types/game_test.go +++ b/op-challenger/game/fault/types/game_test.go @@ -25,7 +25,6 @@ func createTestClaims() (Claim, Claim, Claim, Claim) { Value: common.HexToHash("0x0000000000000000000000000000000000000000000000000000000000000364"), Position: NewPosition(1, common.Big0), }, - Parent: root.ClaimData, ContractIndex: 1, ParentContractIndex: 0, } @@ -34,7 +33,6 @@ func createTestClaims() (Claim, Claim, Claim, Claim) { Value: common.HexToHash("0x0000000000000000000000000000000000000000000000000000000000000578"), Position: NewPosition(2, big.NewInt(2)), }, - Parent: top.ClaimData, ContractIndex: 2, ParentContractIndex: 1, } @@ -44,7 +42,6 @@ func createTestClaims() (Claim, Claim, Claim, Claim) { Value: common.HexToHash("0x0000000000000000000000000000000000000000000000000000000000000465"), Position: NewPosition(3, big.NewInt(4)), }, - Parent: middle.ClaimData, ContractIndex: 3, ParentContractIndex: 2, } @@ -75,3 +72,78 @@ func TestGame_Claims(t *testing.T) { actual := g.Claims() require.ElementsMatch(t, expected, actual) } + +func TestGame_DefendsParent(t *testing.T) { + tests := []struct { + name string + game *gameState + expected bool + }{ + { + name: "LeftChildAttacks", + game: buildGameWithClaim(big.NewInt(2), big.NewInt(1)), + expected: false, + }, + { + name: "RightChildDoesntDefend", + game: buildGameWithClaim(big.NewInt(3), big.NewInt(1)), + expected: false, + }, + { + name: "SubChildDoesntDefend", + game: buildGameWithClaim(big.NewInt(4), big.NewInt(1)), + expected: false, + }, + { + name: "SubSecondChildDoesntDefend", + game: buildGameWithClaim(big.NewInt(5), big.NewInt(1)), + expected: false, + }, + { + name: "RightLeftChildDefendsParent", + game: buildGameWithClaim(big.NewInt(6), big.NewInt(1)), + expected: true, + }, + { + name: "SubThirdChildDefends", + game: buildGameWithClaim(big.NewInt(7), big.NewInt(1)), + expected: true, + }, + { + name: "RootDoesntDefend", + game: NewGameState(false, []Claim{ + { + ClaimData: ClaimData{ + Position: NewPositionFromGIndex(big.NewInt(0)), + }, + ContractIndex: 0, + }, + }, testMaxDepth), + expected: false, + }, + } + + for _, test := range tests { + t.Run(test.name, func(t *testing.T) { + claims := test.game.Claims() + require.Equal(t, test.expected, test.game.DefendsParent(claims[len(claims)-1])) + }) + } +} + +func buildGameWithClaim(claimGIndex *big.Int, parentGIndex *big.Int) *gameState { + parentClaim := Claim{ + ClaimData: ClaimData{ + Position: NewPositionFromGIndex(parentGIndex), + }, + ContractIndex: 0, + } + claim := Claim{ + ClaimData: ClaimData{ + Position: NewPositionFromGIndex(claimGIndex), + }, + ContractIndex: 1, + ParentContractIndex: 0, + } + return NewGameState(false, []Claim{parentClaim, claim}, testMaxDepth) +} diff --git a/op-challenger/game/fault/types/types.go b/op-challenger/game/fault/types/types.go index 2c39ef66f7d5e..a29e28bc162b1 100644 --- a/op-challenger/game/fault/types/types.go +++ b/op-challenger/game/fault/types/types.go @@ -16,19 +16,15 @@ var ( // to load into the onchain oracle. type PreimageOracleData struct { IsLocal bool + LocalContext uint64 OracleKey []byte OracleData []byte OracleOffset uint32 } -// GetType returns the type for the preimage oracle data. -func (p *PreimageOracleData) GetType() *big.Int { - return big.NewInt(int64(p.OracleKey[0])) -} - // GetIdent returns the ident for the preimage oracle data. func (p *PreimageOracleData) GetIdent() *big.Int { - return big.NewInt(0).SetBytes(p.OracleKey[1:]) + return new(big.Int).SetBytes(p.OracleKey[1:]) } // GetPreimageWithoutSize returns the preimage for the preimage oracle data. @@ -37,9 +33,10 @@ func (p *PreimageOracleData) GetPreimageWithoutSize() []byte { } // NewPreimageOracleData creates a new [PreimageOracleData] instance. -func NewPreimageOracleData(key []byte, data []byte, offset uint32) *PreimageOracleData { +func NewPreimageOracleData(lctx uint64, key []byte, data []byte, offset uint32) *PreimageOracleData { return &PreimageOracleData{ IsLocal: len(key) > 0 && key[0] == byte(1), + LocalContext: lctx, OracleKey: key, OracleData: data, OracleOffset: offset, @@ -60,6 +57,18 @@ type OracleUpdater interface { UpdateOracle(ctx context.Context, data *PreimageOracleData) error } +// TraceAccessor defines an interface to request data from a TraceProvider with additional context for the game position. +// This can be used to implement split games where lower layers of the game may have different values depending on claims +// at higher levels in the game. +type TraceAccessor interface { + // Get returns the claim value at the requested position, evaluated in the context of the specified claim (ref). + Get(ctx context.Context, game Game, ref Claim, pos Position) (common.Hash, error) + + // GetStepData returns the data required to execute the step at the specified position, + // evaluated in the context of the specified claim (ref). + GetStepData(ctx context.Context, game Game, ref Claim, pos Position) (prestate []byte, proofData []byte, preimageData *PreimageOracleData, err error) +} + // TraceProvider is a generic way to get a claim value at a specific step in the trace. type TraceProvider interface { // Get returns the claim value at the requested index. @@ -72,9 +81,6 @@ type TraceProvider interface { // The prestate returned from GetStepData for trace 10 should be the pre-image of the claim from trace 9 GetStepData(ctx context.Context, i Position) (prestate []byte, proofData []byte, preimageData *PreimageOracleData, err error) - // AbsolutePreState is the pre-image value of the trace that transitions to the trace value at index 0 - AbsolutePreState(ctx context.Context) (preimage []byte, err error) - // AbsolutePreStateCommitment is the commitment of the pre-image value of the trace that transitions to the trace value at index 0 AbsolutePreStateCommitment(ctx context.Context) (hash common.Hash, err error) } @@ -104,7 +110,6 @@ type Claim struct { // to be changed/removed to avoid invalid/stale contract state. Countered bool Clock uint64 - Parent ClaimData // Location of the claim & it's parent inside the contract. Does not exist // for claims that have not made it to the contract. ContractIndex int @@ -115,9 +120,3 @@ type Claim struct { func (c *Claim) IsRoot() bool { return c.Position.IsRootPosition() } - -// DefendsParent returns true if the the claim is a defense (i.e. goes right) of the -// parent. It returns false if the claim is an attack (i.e. goes left) of the parent. -func (c *Claim) DefendsParent() bool { - return c.RightOf(c.Parent.Position) -} diff --git a/op-challenger/game/fault/types/types_test.go b/op-challenger/game/fault/types/types_test.go index c45ec00a2f6e7..a155612481fb6 100644 --- a/op-challenger/game/fault/types/types_test.go +++ b/op-challenger/game/fault/types/types_test.go @@ -9,16 +9,18 @@ import ( func TestNewPreimageOracleData(t *testing.T) { t.Run("LocalData", func(t *testing.T) { - data := NewPreimageOracleData([]byte{1, 2, 3}, []byte{4, 5, 6}, 7) + data := NewPreimageOracleData(1, []byte{1, 2, 3}, []byte{4, 5, 6}, 7) require.True(t, data.IsLocal) + require.Equal(t, uint64(1), data.LocalContext) require.Equal(t, []byte{1, 2, 3}, data.OracleKey) require.Equal(t, []byte{4, 5, 6}, data.OracleData) require.Equal(t, uint32(7), data.OracleOffset) }) t.Run("GlobalData", func(t *testing.T) { - data := NewPreimageOracleData([]byte{0, 2, 3}, []byte{4, 5, 6}, 7) + data := NewPreimageOracleData(1, []byte{0, 2, 3}, []byte{4, 5, 6}, 7) require.False(t, data.IsLocal) + require.Equal(t, uint64(1), data.LocalContext) require.Equal(t, []byte{0, 2, 3}, data.OracleKey) require.Equal(t, []byte{4, 5, 6}, data.OracleData) require.Equal(t, uint32(7), data.OracleOffset) @@ -54,59 +56,3 @@ func TestIsRootPosition(t *testing.T) { }) } } - -func buildClaim(gindex *big.Int, parentGIndex *big.Int) Claim { - return Claim{ - ClaimData: ClaimData{ - Position: NewPositionFromGIndex(gindex), - }, - Parent: ClaimData{ - Position: NewPositionFromGIndex(parentGIndex), - }, - } -} - -func TestDefendsParent(t *testing.T) { - tests := []struct { - name string - claim Claim - expected bool - }{ - { - name: "LeftChildAttacks", - claim: buildClaim(big.NewInt(2), big.NewInt(1)), - expected: false, - }, - { - name: "RightChildDoesntDefend", - claim: buildClaim(big.NewInt(3), big.NewInt(1)), - expected: false, - }, - { - name: "SubChildDoesntDefend", - claim: buildClaim(big.NewInt(4), big.NewInt(1)), - expected: false, - }, - { - name: "SubSecondChildDoesntDefend", - claim: buildClaim(big.NewInt(5), big.NewInt(1)), - expected: false, - }, - { - name: "RightLeftChildDefendsParent", - claim: buildClaim(big.NewInt(6), big.NewInt(1)), - expected: true, - }, - { - name: "SubThirdChildDefends", - claim: buildClaim(big.NewInt(7), big.NewInt(1)), - expected: true, - }, - } - - for _, test := range tests { - t.Run(test.name, func(t *testing.T) { - require.Equal(t, test.expected, test.claim.DefendsParent()) - }) - } -} diff --git a/op-challenger/game/loader/game_loader.go b/op-challenger/game/loader/game_loader.go index d5afee62ebc04..12b126cfc0543 100644 --- a/op-challenger/game/loader/game_loader.go +++ b/op-challenger/game/loader/game_loader.go @@ -4,11 +4,8 @@ import ( "context" "errors" "fmt" - "math/big" "github.com/ethereum-optimism/optimism/op-challenger/game/types" - "github.com/ethereum/go-ethereum/accounts/abi/bind" - "github.com/ethereum/go-ethereum/common" ) var ( @@ -18,12 +15,8 @@ var ( // MinimalDisputeGameFactoryCaller is a minimal interface around [bindings.DisputeGameFactoryCaller]. // This needs to be updated if the [bindings.DisputeGameFactoryCaller] interface changes. type MinimalDisputeGameFactoryCaller interface { - GameCount(opts *bind.CallOpts) (*big.Int, error) - GameAtIndex(opts *bind.CallOpts, _index *big.Int) (struct { - GameType uint8 - Timestamp uint64 - Proxy common.Address - }, error) + GetGameCount(ctx context.Context, blockNum uint64) (uint64, error) + GetGame(ctx context.Context, idx uint64, blockNum uint64) (types.GameMetadata, error) } type GameLoader struct { @@ -38,27 +31,17 @@ func NewGameLoader(caller MinimalDisputeGameFactoryCaller) *GameLoader { } // FetchAllGamesAtBlock fetches all dispute games from the factory at a given block number. -func (l *GameLoader) FetchAllGamesAtBlock(ctx context.Context, earliestTimestamp uint64, blockNumber *big.Int) ([]types.GameMetadata, error) { - if blockNumber == nil { - return nil, ErrMissingBlockNumber - } - callOpts := &bind.CallOpts{ - Context: ctx, - BlockNumber: blockNumber, - } - gameCount, err := l.caller.GameCount(callOpts) +func (l *GameLoader) FetchAllGamesAtBlock(ctx context.Context, earliestTimestamp uint64, blockNumber uint64) ([]types.GameMetadata, error) { + gameCount, err := l.caller.GetGameCount(ctx, blockNumber) if err != nil { return nil, fmt.Errorf("failed to fetch game count: %w", err) } - games := make([]types.GameMetadata, 0) - if gameCount.Uint64() == 0 { - return games, nil - } - for i := gameCount.Uint64(); i > 0; i-- { - game, err := l.caller.GameAtIndex(callOpts, big.NewInt(int64(i-1))) + games := make([]types.GameMetadata, 0, gameCount) + for i := gameCount; i > 0; i-- { + game, err := l.caller.GetGame(ctx, i-1, blockNumber) if err != nil { - return nil, fmt.Errorf("failed to fetch game at index %d: %w", i, err) + return nil, fmt.Errorf("failed to fetch game at index %d: %w", i-1, err) } if game.Timestamp < earliestTimestamp { break diff --git a/op-challenger/game/loader/game_loader_test.go b/op-challenger/game/loader/game_loader_test.go index 1c6959be3b85d..ac25d0b0cf9c9 100644 --- a/op-challenger/game/loader/game_loader_test.go +++ b/op-challenger/game/loader/game_loader_test.go @@ -7,7 +7,6 @@ import ( "testing" "github.com/ethereum-optimism/optimism/op-challenger/game/types" - "github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/common" "github.com/stretchr/testify/require" ) @@ -25,44 +24,39 @@ func TestGameLoader_FetchAllGames(t *testing.T) { name string caller *mockMinimalDisputeGameFactoryCaller earliest uint64 - blockNumber *big.Int + blockNumber uint64 expectedErr error expectedLen int }{ { name: "success", caller: newMockMinimalDisputeGameFactoryCaller(10, false, false), - blockNumber: big.NewInt(1), + blockNumber: 1, expectedLen: 10, }, { name: "expired game ignored", caller: newMockMinimalDisputeGameFactoryCaller(10, false, false), earliest: 500, - blockNumber: big.NewInt(1), + blockNumber: 1, expectedLen: 5, }, { name: "game count error", caller: newMockMinimalDisputeGameFactoryCaller(10, true, false), - blockNumber: big.NewInt(1), + blockNumber: 1, expectedErr: gameCountErr, }, { name: "game index error", caller: newMockMinimalDisputeGameFactoryCaller(10, false, true), - blockNumber: big.NewInt(1), + blockNumber: 1, expectedErr: gameIndexErr, }, { name: "no games", caller: newMockMinimalDisputeGameFactoryCaller(0, false, false), - blockNumber: big.NewInt(1), - }, - { - name: "missing block number", - caller: newMockMinimalDisputeGameFactoryCaller(0, false, false), - expectedErr: ErrMissingBlockNumber, + blockNumber: 1, }, } @@ -144,20 +138,15 @@ func newMockMinimalDisputeGameFactoryCaller(count uint64, gameCountErr bool, ind } } -func (m *mockMinimalDisputeGameFactoryCaller) GameCount(opts *bind.CallOpts) (*big.Int, error) { +func (m *mockMinimalDisputeGameFactoryCaller) GetGameCount(_ context.Context, blockNum uint64) (uint64, error) { if m.gameCountErr { - return nil, gameCountErr + return 0, gameCountErr } - return big.NewInt(int64(m.gameCount)), nil + return m.gameCount, nil } -func (m *mockMinimalDisputeGameFactoryCaller) GameAtIndex(opts *bind.CallOpts, _index *big.Int) (struct { - GameType uint8 - Timestamp uint64 - Proxy common.Address -}, error) { - index := _index.Uint64() +func (m *mockMinimalDisputeGameFactoryCaller) GetGame(_ context.Context, index uint64, blockNum uint64) (types.GameMetadata, error) { if m.indexErrors[index] { return struct { GameType uint8 @@ -166,13 +155,5 @@ func (m *mockMinimalDisputeGameFactoryCaller) GameAtIndex(opts *bind.CallOpts, _ }{}, gameIndexErr } - return struct { - GameType uint8 - Timestamp uint64 - Proxy common.Address - }{ - GameType: m.games[index].GameType, - Timestamp: m.games[index].Timestamp, - Proxy: m.games[index].Proxy, - }, nil + return m.games[index], nil } diff --git a/op-challenger/game/monitor.go b/op-challenger/game/monitor.go index b6ddc64adceaa..e217bf040ff8a 100644 --- a/op-challenger/game/monitor.go +++ b/op-challenger/game/monitor.go @@ -4,7 +4,6 @@ import ( "context" "errors" "fmt" - "math/big" "time" "github.com/ethereum-optimism/optimism/op-challenger/game/scheduler" @@ -23,7 +22,7 @@ type blockNumberFetcher func(ctx context.Context) (uint64, error) // gameSource loads information about the games available to play type gameSource interface { - FetchAllGamesAtBlock(ctx context.Context, earliest uint64, blockNumber *big.Int) ([]types.GameMetadata, error) + FetchAllGamesAtBlock(ctx context.Context, earliest uint64, blockNumber uint64) ([]types.GameMetadata, error) } type gameScheduler interface { @@ -101,7 +100,7 @@ func (m *gameMonitor) minGameTimestamp() uint64 { } func (m *gameMonitor) progressGames(ctx context.Context, blockNum uint64) error { - games, err := m.source.FetchAllGamesAtBlock(ctx, m.minGameTimestamp(), new(big.Int).SetUint64(blockNum)) + games, err := m.source.FetchAllGamesAtBlock(ctx, m.minGameTimestamp(), blockNum) if err != nil { return fmt.Errorf("failed to load games: %w", err) } @@ -141,6 +140,7 @@ func (m *gameMonitor) MonitorGames(ctx context.Context) error { for { select { case <-ctx.Done(): + m.l1HeadsSub.Unsubscribe() return nil case err, ok := <-m.l1HeadsSub.Err(): if !ok { diff --git a/op-challenger/game/monitor_test.go b/op-challenger/game/monitor_test.go index b869dad350f60..e800bd64e8ac7 100644 --- a/op-challenger/game/monitor_test.go +++ b/op-challenger/game/monitor_test.go @@ -100,7 +100,8 @@ func TestMonitorGames(t *testing.T) { defer cancel() go func() { - waitErr := wait.For(context.Background(), 100*time.Millisecond, func() (bool, error) { + // Wait for the subscription to be created + waitErr := wait.For(context.Background(), 5*time.Second, func() (bool, error) { return mockHeadSource.sub != nil, nil }) require.NoError(t, waitErr) @@ -229,7 +230,7 @@ type stubGameSource struct { func (s *stubGameSource) FetchAllGamesAtBlock( ctx context.Context, earliest uint64, - blockNumber *big.Int, + blockNumber uint64, ) ([]types.GameMetadata, error) { return s.games, nil } diff --git a/op-challenger/game/registry/registry.go b/op-challenger/game/registry/registry.go new file mode 100644 index 0000000000000..8f9b71d21388b --- /dev/null +++ b/op-challenger/game/registry/registry.go @@ -0,0 +1,41 @@ +package registry + +import ( + "errors" + "fmt" + + "github.com/ethereum-optimism/optimism/op-challenger/game/scheduler" + "github.com/ethereum-optimism/optimism/op-challenger/game/types" +) + +var ( + ErrUnsupportedGameType = errors.New("unsupported game type") +) + +type GameTypeRegistry struct { + types map[uint8]scheduler.PlayerCreator +} + +func NewGameTypeRegistry() *GameTypeRegistry { + return &GameTypeRegistry{ + types: make(map[uint8]scheduler.PlayerCreator), + } +} + +// RegisterGameType registers a scheduler.PlayerCreator to use for a specific game type. +// Panics if the same game type is registered multiple times, since this indicates a significant programmer error. +func (r *GameTypeRegistry) RegisterGameType(gameType uint8, creator scheduler.PlayerCreator) { + if _, ok := r.types[gameType]; ok { + panic(fmt.Errorf("duplicate creator registered for game type: %v", gameType)) + } + r.types[gameType] = creator +} + +// CreatePlayer creates a new game player for the given game, using the specified directory for persisting data. +func (r *GameTypeRegistry) CreatePlayer(game types.GameMetadata, dir string) (scheduler.GamePlayer, error) { + creator, ok := r.types[game.GameType] + if !ok { + return nil, fmt.Errorf("%w: %v", ErrUnsupportedGameType, game.GameType) + } + return creator(game, dir) +} diff --git a/op-challenger/game/registry/registry_test.go b/op-challenger/game/registry/registry_test.go new file mode 100644 index 0000000000000..9f8c81b85d990 --- /dev/null +++ b/op-challenger/game/registry/registry_test.go @@ -0,0 +1,40 @@ +package registry + +import ( + "testing" + + "github.com/ethereum-optimism/optimism/op-challenger/game/scheduler" + "github.com/ethereum-optimism/optimism/op-challenger/game/scheduler/test" + "github.com/ethereum-optimism/optimism/op-challenger/game/types" + "github.com/stretchr/testify/require" +) + +func TestUnknownGameType(t *testing.T) { + registry := NewGameTypeRegistry() + player, err := registry.CreatePlayer(types.GameMetadata{GameType: 0}, "") + require.ErrorIs(t, err, ErrUnsupportedGameType) + require.Nil(t, player) +} + +func TestKnownGameType(t *testing.T) { + registry := NewGameTypeRegistry() + expectedPlayer := &test.StubGamePlayer{} + creator := func(game types.GameMetadata, dir string) (scheduler.GamePlayer, error) { + return expectedPlayer, nil + } + registry.RegisterGameType(0, creator) + player, err := registry.CreatePlayer(types.GameMetadata{GameType: 0}, "") + require.NoError(t, err) + require.Same(t, expectedPlayer, player) +} + +func TestPanicsOnDuplicateGameType(t *testing.T) { + registry := NewGameTypeRegistry() + creator := func(game types.GameMetadata, dir string) (scheduler.GamePlayer, error) { + return nil, nil + } + registry.RegisterGameType(0, creator) + require.Panics(t, func() { + registry.RegisterGameType(0, creator) + }) +} diff --git a/op-challenger/game/scheduler/coordinator_test.go b/op-challenger/game/scheduler/coordinator_test.go index ab2b58bc40fcf..697a84df20a98 100644 --- a/op-challenger/game/scheduler/coordinator_test.go +++ b/op-challenger/game/scheduler/coordinator_test.go @@ -5,6 +5,7 @@ import ( "fmt" "testing" + "github.com/ethereum-optimism/optimism/op-challenger/game/scheduler/test" "github.com/ethereum-optimism/optimism/op-challenger/game/types" "github.com/ethereum-optimism/optimism/op-challenger/metrics" "github.com/ethereum-optimism/optimism/op-service/testlog" @@ -30,7 +31,7 @@ func TestScheduleNewGames(t *testing.T) { players = append(players, j.player) } for addr, player := range games.created { - require.Equal(t, disk.DirForGame(addr), player.dir, "should use allocated directory") + require.Equal(t, disk.DirForGame(addr), player.Dir, "should use allocated directory") require.Containsf(t, players, player, "should have created a job for player %v", addr) } } @@ -233,34 +234,18 @@ func setupCoordinatorTest(t *testing.T, bufferSize int) (*coordinator, <-chan jo resultQueue := make(chan job, bufferSize) games := &createdGames{ t: t, - created: make(map[common.Address]*stubGame), + created: make(map[common.Address]*test.StubGamePlayer), } disk := &stubDiskManager{gameDirExists: make(map[common.Address]bool)} c := newCoordinator(logger, metrics.NoopMetrics, workQueue, resultQueue, games.CreateGame, disk) return c, workQueue, resultQueue, games, disk } -type stubGame struct { - addr common.Address - progressCount int - status types.GameStatus - dir string -} - -func (g *stubGame) ProgressGame(_ context.Context) types.GameStatus { - g.progressCount++ - return g.status -} - -func (g *stubGame) Status() types.GameStatus { - return g.status -} - type createdGames struct { t *testing.T createCompleted common.Address creationFails common.Address - created map[common.Address]*stubGame + created map[common.Address]*test.StubGamePlayer } func (c *createdGames) CreateGame(fdg types.GameMetadata, dir string) (GamePlayer, error) { @@ -275,10 +260,10 @@ func (c *createdGames) CreateGame(fdg types.GameMetadata, dir string) (GamePlaye if addr == c.createCompleted { status = types.GameStatusDefenderWon } - game := &stubGame{ - addr: addr, - status: status, - dir: dir, + game := &test.StubGamePlayer{ + Addr: addr, + StatusValue: status, + Dir: dir, } c.created[addr] = game return game, nil diff --git a/op-challenger/game/scheduler/scheduler_test.go b/op-challenger/game/scheduler/scheduler_test.go index e10176b52a92c..3635f1c7b37fb 100644 --- a/op-challenger/game/scheduler/scheduler_test.go +++ b/op-challenger/game/scheduler/scheduler_test.go @@ -4,6 +4,7 @@ import ( "context" "testing" + "github.com/ethereum-optimism/optimism/op-challenger/game/scheduler/test" "github.com/ethereum-optimism/optimism/op-challenger/game/types" "github.com/ethereum-optimism/optimism/op-challenger/metrics" "github.com/ethereum-optimism/optimism/op-service/testlog" @@ -16,7 +17,7 @@ func TestSchedulerProcessesGames(t *testing.T) { logger := testlog.Logger(t, log.LvlInfo) ctx := context.Background() createPlayer := func(g types.GameMetadata, dir string) (GamePlayer, error) { - return &stubPlayer{}, nil + return &test.StubGamePlayer{}, nil } removeExceptCalls := make(chan []common.Address) disk := &trackingDiskManager{removeExceptCalls: removeExceptCalls} @@ -44,7 +45,7 @@ func TestSchedulerProcessesGames(t *testing.T) { func TestReturnBusyWhenScheduleQueueFull(t *testing.T) { logger := testlog.Logger(t, log.LvlInfo) createPlayer := func(game types.GameMetadata, dir string) (GamePlayer, error) { - return &stubPlayer{}, nil + return &test.StubGamePlayer{}, nil } removeExceptCalls := make(chan []common.Address) disk := &trackingDiskManager{removeExceptCalls: removeExceptCalls} diff --git a/op-challenger/game/scheduler/test/stub_player.go b/op-challenger/game/scheduler/test/stub_player.go new file mode 100644 index 0000000000000..b465d0c34f0ce --- /dev/null +++ b/op-challenger/game/scheduler/test/stub_player.go @@ -0,0 +1,24 @@ +package test + +import ( + "context" + + "github.com/ethereum-optimism/optimism/op-challenger/game/types" + "github.com/ethereum/go-ethereum/common" +) + +type StubGamePlayer struct { + Addr common.Address + ProgressCount int + StatusValue types.GameStatus + Dir string +} + +func (g *StubGamePlayer) ProgressGame(_ context.Context) types.GameStatus { + g.ProgressCount++ + return g.StatusValue +} + +func (g *StubGamePlayer) Status() types.GameStatus { + return g.StatusValue +} diff --git a/op-challenger/game/scheduler/worker_test.go b/op-challenger/game/scheduler/worker_test.go index 662c418c8522f..330c553dde9d2 100644 --- a/op-challenger/game/scheduler/worker_test.go +++ b/op-challenger/game/scheduler/worker_test.go @@ -6,6 +6,7 @@ import ( "testing" "time" + "github.com/ethereum-optimism/optimism/op-challenger/game/scheduler/test" "github.com/ethereum-optimism/optimism/op-challenger/game/types" "github.com/ethereum-optimism/optimism/op-e2e/e2eutils/wait" @@ -24,7 +25,7 @@ func TestWorkerShouldProcessJobsUntilContextDone(t *testing.T) { go progressGames(ctx, in, out, &wg, ms.ThreadActive, ms.ThreadIdle) in <- job{ - player: &stubPlayer{status: types.GameStatusInProgress}, + player: &test.StubGamePlayer{StatusValue: types.GameStatusInProgress}, } waitErr := wait.For(context.Background(), 100*time.Millisecond, func() (bool, error) { return ms.activeCalls >= 1, nil @@ -34,7 +35,7 @@ func TestWorkerShouldProcessJobsUntilContextDone(t *testing.T) { require.Equal(t, ms.idleCalls, 1) in <- job{ - player: &stubPlayer{status: types.GameStatusDefenderWon}, + player: &test.StubGamePlayer{StatusValue: types.GameStatusDefenderWon}, } waitErr = wait.For(context.Background(), 100*time.Millisecond, func() (bool, error) { return ms.activeCalls >= 2, nil @@ -67,18 +68,6 @@ func (m *metricSink) ThreadIdle() { m.idleCalls++ } -type stubPlayer struct { - status types.GameStatus -} - -func (s *stubPlayer) ProgressGame(ctx context.Context) types.GameStatus { - return s.status -} - -func (s *stubPlayer) Status() types.GameStatus { - return s.status -} - func readWithTimeout[T any](t *testing.T, ch <-chan T) T { ctx, cancel := context.WithTimeout(context.Background(), 10*time.Second) defer cancel() diff --git a/op-challenger/game/service.go b/op-challenger/game/service.go index 5b73a928eaa74..7c43447dd87bb 100644 --- a/op-challenger/game/service.go +++ b/op-challenger/game/service.go @@ -5,12 +5,12 @@ import ( "errors" "fmt" - "github.com/ethereum-optimism/optimism/op-bindings/bindings" "github.com/ethereum-optimism/optimism/op-challenger/config" "github.com/ethereum-optimism/optimism/op-challenger/game/fault" + "github.com/ethereum-optimism/optimism/op-challenger/game/fault/contracts" "github.com/ethereum-optimism/optimism/op-challenger/game/loader" + "github.com/ethereum-optimism/optimism/op-challenger/game/registry" "github.com/ethereum-optimism/optimism/op-challenger/game/scheduler" - "github.com/ethereum-optimism/optimism/op-challenger/game/types" "github.com/ethereum-optimism/optimism/op-challenger/metrics" "github.com/ethereum-optimism/optimism/op-challenger/version" opClient "github.com/ethereum-optimism/optimism/op-service/client" @@ -18,6 +18,7 @@ import ( "github.com/ethereum-optimism/optimism/op-service/dial" "github.com/ethereum-optimism/optimism/op-service/httputil" oppprof "github.com/ethereum-optimism/optimism/op-service/pprof" + "github.com/ethereum-optimism/optimism/op-service/sources/batching" "github.com/ethereum-optimism/optimism/op-service/txmgr" "github.com/ethereum/go-ethereum/log" ) @@ -55,7 +56,7 @@ func NewService(ctx context.Context, logger log.Logger, cfg *config.Config) (*Se return nil, fmt.Errorf("failed to create the transaction manager: %w", err) } - l1Client, err := dial.DialEthClientWithTimeout(dial.DefaultDialTimeout, logger, cfg.L1EthRpc) + l1Client, err := dial.DialEthClientWithTimeout(ctx, dial.DefaultDialTimeout, logger, cfg.L1EthRpc) if err != nil { return nil, fmt.Errorf("failed to dial L1: %w", err) } @@ -88,21 +89,22 @@ func NewService(ctx context.Context, logger log.Logger, cfg *config.Config) (*Se m.StartBalanceMetrics(ctx, logger, l1Client, txMgr.From()) } - factoryContract, err := bindings.NewDisputeGameFactory(cfg.GameFactoryAddress, l1Client) + factoryContract, err := contracts.NewDisputeGameFactoryContract(cfg.GameFactoryAddress, batching.NewMultiCaller(l1Client.Client(), batching.DefaultBatchSize)) if err != nil { return nil, errors.Join(fmt.Errorf("failed to bind the fault dispute game factory contract: %w", err), s.Stop(ctx)) } loader := loader.NewGameLoader(factoryContract) + gameTypeRegistry := registry.NewGameTypeRegistry() + fault.RegisterGameTypes(gameTypeRegistry, ctx, logger, m, cfg, txMgr, l1Client) + disk := newDiskManager(cfg.Datadir) s.sched = scheduler.NewScheduler( logger, m, disk, cfg.MaxConcurrency, - func(game types.GameMetadata, dir string) (scheduler.GamePlayer, error) { - return fault.NewGamePlayer(ctx, logger, m, cfg, dir, game.Proxy, txMgr, l1Client) - }) + gameTypeRegistry.CreatePlayer) pollClient, err := opClient.NewRPCWithClient(ctx, logger, cfg.L1EthRpc, opClient.NewBaseRPCClient(l1Client.Client()), cfg.PollInterval) if err != nil { diff --git a/op-challenger/metrics/metrics.go b/op-challenger/metrics/metrics.go index 707894ceb49ca..30ca2ab15dfa1 100644 --- a/op-challenger/metrics/metrics.go +++ b/op-challenger/metrics/metrics.go @@ -133,7 +133,12 @@ func (m *Metrics) StartBalanceMetrics( client *ethclient.Client, account common.Address, ) { - opmetrics.LaunchBalanceMetrics(ctx, l, m.registry, m.ns, client, account) + // TODO(7684): util was refactored to close, but ctx is still being used by caller for shutdown + balanceMetric := opmetrics.LaunchBalanceMetrics(l, m.registry, m.ns, client, account) + go func() { + <-ctx.Done() + _ = balanceMetric.Close() + }() } // RecordInfo sets a pseudo-metric that contains versioning and diff --git a/op-challenger/scripts/alphabet/init_game.sh b/op-challenger/scripts/alphabet/init_game.sh index 5a0db7b025405..29f1dfe2feb43 100755 --- a/op-challenger/scripts/alphabet/init_game.sh +++ b/op-challenger/scripts/alphabet/init_game.sh @@ -63,6 +63,6 @@ done # Alphabet game claim construction: keccak256(abi.encode(trace_index, trace[trace_index])) ROOT_CLAIM=$(cast keccak $(cast abi-encode "f(uint256,uint256)" 15 122)) # Replace the first byte of the claim with the invalid vm status indicator -ROOT_CLAIM="0x01${ROOT_CLAIM:4:60}" +ROOT_CLAIM="0x01${ROOT_CLAIM:4}" GAME_TYPE=255 ${SOURCE_DIR}/../create_game.sh http://localhost:8545 "${DISPUTE_GAME_FACTORY}" "${ROOT_CLAIM}" --private-key "${DEVNET_SPONSOR}" diff --git a/op-challenger/scripts/create_game.sh b/op-challenger/scripts/create_game.sh index 151c7cc81aa31..f435fb09e5a77 100755 --- a/op-challenger/scripts/create_game.sh +++ b/op-challenger/scripts/create_game.sh @@ -27,7 +27,7 @@ BLOCK_ORACLE_ADDR=$(cast call --rpc-url "${RPC}" "${GAME_IMPL_ADDR}" 'BLOCK_ORAC echo "Block Oracle: ${BLOCK_ORACLE_ADDR}" # Get the L2 block number of the latest output proposal. This is the proposal that will be disputed by the created game. -L2_BLOCK_NUM=$(cast call --rpc-url "${RPC}" "${L2OO_ADDR}" 'latestBlockNumber() public view returns (uint256)') +L2_BLOCK_NUM=$(cast call --rpc-url "${RPC}" "${L2OO_ADDR}" 'latestBlockNumber() returns(uint256)') echo "L2 Block Number: ${L2_BLOCK_NUM}" # Create a checkpoint in the block oracle to commit to the current L1 head. diff --git a/op-e2e/Makefile b/op-e2e/Makefile index c4f897cdc97d5..1f880be22503a 100644 --- a/op-e2e/Makefile +++ b/op-e2e/Makefile @@ -21,7 +21,7 @@ test-ws: pre-test test-http: pre-test OP_E2E_USE_HTTP=true $(go_test) $(go_test_flags) ./... -.PHONY: test-ws +.PHONY: test-http cannon-prestate: make -C .. cannon-prestate @@ -51,7 +51,3 @@ clean: rm -r ../.devnet rm -r ../op-program/bin .PHONY: clean - -lint: - golangci-lint run -E goimports,sqlclosecheck,bodyclose,asciicheck,misspell,errorlint --timeout 5m -e "errors.As" -e "errors.Is" ./... -.PHONY: lint diff --git a/op-e2e/actions/blocktime_test.go b/op-e2e/actions/blocktime_test.go index 2f3cf8d46381c..440b982a72ae8 100644 --- a/op-e2e/actions/blocktime_test.go +++ b/op-e2e/actions/blocktime_test.go @@ -6,20 +6,47 @@ import ( "github.com/ethereum-optimism/optimism/op-e2e/e2eutils" "github.com/ethereum-optimism/optimism/op-service/testlog" + "github.com/ethereum/go-ethereum/common/hexutil" "github.com/ethereum/go-ethereum/core/types" "github.com/ethereum/go-ethereum/log" "github.com/ethereum/go-ethereum/params" "github.com/stretchr/testify/require" ) -// TestBatchInLastPossibleBlocks tests that the derivation pipeline +// TestBlockTimeBatchType run each blocktime-related test case in singular batch mode and span batch mode. +func TestBlockTimeBatchType(t *testing.T) { + tests := []struct { + name string + f func(gt *testing.T, spanBatchTimeOffset *hexutil.Uint64) + }{ + {"BatchInLastPossibleBlocks", BatchInLastPossibleBlocks}, + {"LargeL1Gaps", LargeL1Gaps}, + } + for _, test := range tests { + test := test + t.Run(test.name+"_SingularBatch", func(t *testing.T) { + test.f(t, nil) + }) + } + + spanBatchTimeOffset := hexutil.Uint64(0) + for _, test := range tests { + test := test + t.Run(test.name+"_SpanBatch", func(t *testing.T) { + test.f(t, &spanBatchTimeOffset) + }) + } +} + +// BatchInLastPossibleBlocks tests that the derivation pipeline // accepts a batch that is included in the last possible L1 block // where there are also no other batches included in the sequence // window. // This is a regression test against the bug fixed in PR #4566 -func TestBatchInLastPossibleBlocks(gt *testing.T) { +func BatchInLastPossibleBlocks(gt *testing.T, spanBatchTimeOffset *hexutil.Uint64) { t := NewDefaultTesting(gt) dp := e2eutils.MakeDeployParams(t, defaultRollupTestParams) + dp.DeployConfig.L2GenesisSpanBatchTimeOffset = spanBatchTimeOffset dp.DeployConfig.SequencerWindowSize = 4 dp.DeployConfig.L2BlockTime = 2 @@ -116,7 +143,7 @@ func TestBatchInLastPossibleBlocks(gt *testing.T) { verifyChainStateOnSequencer(12, 23, 11, 17, 8) } -// TestLargeL1Gaps tests the case that there is a gap between two L1 blocks which +// LargeL1Gaps tests the case that there is a gap between two L1 blocks which // is larger than the sequencer drift. // This test has the following parameters: // L1 Block time: 4s. L2 Block time: 2s. Sequencer Drift: 32s @@ -127,13 +154,14 @@ func TestBatchInLastPossibleBlocks(gt *testing.T) { // Then it generates 3 more L1 blocks. // At this point it can verify that the batches where properly generated. // Note: It batches submits when possible. -func TestLargeL1Gaps(gt *testing.T) { +func LargeL1Gaps(gt *testing.T, spanBatchTimeOffset *hexutil.Uint64) { t := NewDefaultTesting(gt) dp := e2eutils.MakeDeployParams(t, defaultRollupTestParams) dp.DeployConfig.L1BlockTime = 4 dp.DeployConfig.L2BlockTime = 2 dp.DeployConfig.SequencerWindowSize = 4 dp.DeployConfig.MaxSequencerDrift = 32 + dp.DeployConfig.L2GenesisSpanBatchTimeOffset = spanBatchTimeOffset sd := e2eutils.Setup(t, dp, defaultAlloc) log := testlog.Logger(t, log.LvlDebug) diff --git a/op-e2e/actions/dencun_fork_test.go b/op-e2e/actions/dencun_fork_test.go new file mode 100644 index 0000000000000..7b01a92a5210b --- /dev/null +++ b/op-e2e/actions/dencun_fork_test.go @@ -0,0 +1,53 @@ +package actions + +import ( + "testing" + + "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/log" + "github.com/stretchr/testify/require" + + "github.com/ethereum-optimism/optimism/op-e2e/e2eutils" + "github.com/ethereum-optimism/optimism/op-service/testlog" +) + +func TestDencunL1Fork(gt *testing.T) { + t := NewDefaultTesting(gt) + dp := e2eutils.MakeDeployParams(t, defaultRollupTestParams) + sd := e2eutils.Setup(t, dp, defaultAlloc) + activation := sd.L1Cfg.Timestamp + 24 + sd.L1Cfg.Config.CancunTime = &activation + log := testlog.Logger(t, log.LvlDebug) + _, _, miner, sequencer, _, verifier, _, batcher := setupReorgTestActors(t, dp, sd, log) + + l1Head := miner.l1Chain.CurrentBlock() + require.False(t, sd.L1Cfg.Config.IsCancun(l1Head.Number, l1Head.Time), "Cancun not active yet") + + // start op-nodes + sequencer.ActL2PipelineFull(t) + verifier.ActL2PipelineFull(t) + + // build empty L1 blocks, crossing the fork boundary + miner.ActL1SetFeeRecipient(common.Address{'A', 0}) + miner.ActEmptyBlock(t) + miner.ActEmptyBlock(t) // Cancun activates here + miner.ActEmptyBlock(t) + // verify Cancun is active + l1Head = miner.l1Chain.CurrentBlock() + require.True(t, sd.L1Cfg.Config.IsCancun(l1Head.Number, l1Head.Time), "Cancun active") + + // build L2 chain up to and including L2 blocks referencing Cancun L1 blocks + sequencer.ActL1HeadSignal(t) + sequencer.ActBuildToL1Head(t) + miner.ActL1StartBlock(12)(t) + batcher.ActSubmitAll(t) + miner.ActL1IncludeTx(batcher.batcherAddr)(t) + miner.ActL1EndBlock(t) + + // sync verifier + verifier.ActL1HeadSignal(t) + verifier.ActL2PipelineFull(t) + // verify verifier accepted Cancun L1 inputs + require.Equal(t, l1Head.Hash(), verifier.SyncStatus().SafeL2.L1Origin.Hash, "verifier synced L1 chain that includes Cancun headers") + require.Equal(t, sequencer.SyncStatus().UnsafeL2, verifier.SyncStatus().UnsafeL2, "verifier and sequencer agree") +} diff --git a/op-e2e/actions/garbage_channel_out.go b/op-e2e/actions/garbage_channel_out.go index a2e5535b1074f..34056abdf714b 100644 --- a/op-e2e/actions/garbage_channel_out.go +++ b/op-e2e/actions/garbage_channel_out.go @@ -61,8 +61,11 @@ type ChannelOutIface interface { OutputFrame(w *bytes.Buffer, maxSize uint64) (uint16, error) } -// Compile-time check for ChannelOutIface interface implementation for the ChannelOut type. -var _ ChannelOutIface = (*derive.ChannelOut)(nil) +// Compile-time check for ChannelOutIface interface implementation for the SingularChannelOut type. +var _ ChannelOutIface = (*derive.SingularChannelOut)(nil) + +// Compile-time check for ChannelOutIface interface implementation for the SpanChannelOut type. +var _ ChannelOutIface = (*derive.SpanChannelOut)(nil) // Compile-time check for ChannelOutIface interface implementation for the GarbageChannelOut type. var _ ChannelOutIface = (*GarbageChannelOut)(nil) @@ -252,13 +255,13 @@ func blockToBatch(block *types.Block) (*derive.BatchData, error) { return nil, fmt.Errorf("could not parse the L1 Info deposit: %w", err) } - return &derive.BatchData{ - SingularBatch: derive.SingularBatch{ - ParentHash: block.ParentHash(), - EpochNum: rollup.Epoch(l1Info.Number), - EpochHash: l1Info.BlockHash, - Timestamp: block.Time(), - Transactions: opaqueTxs, - }, - }, nil + singularBatch := &derive.SingularBatch{ + ParentHash: block.ParentHash(), + EpochNum: rollup.Epoch(l1Info.Number), + EpochHash: l1Info.BlockHash, + Timestamp: block.Time(), + Transactions: opaqueTxs, + } + + return derive.NewBatchData(singularBatch), nil } diff --git a/op-e2e/actions/l1_miner.go b/op-e2e/actions/l1_miner.go index 70c5059a16c06..56f508d095d2c 100644 --- a/op-e2e/actions/l1_miner.go +++ b/op-e2e/actions/l1_miner.go @@ -67,7 +67,7 @@ func (s *L1Miner) ActL1StartBlock(timeDelta uint64) Action { MixDigest: common.Hash{}, // TODO: maybe randomize this (prev-randao value) } if s.l1Cfg.Config.IsLondon(header.Number) { - header.BaseFee = eip1559.CalcBaseFee(s.l1Cfg.Config, parent) + header.BaseFee = eip1559.CalcBaseFee(s.l1Cfg.Config, parent, header.Time) // At the transition, double the gas limit so the gas target is equal to the old gas limit. if !s.l1Cfg.Config.IsLondon(parent.Number) { header.GasLimit = parent.GasLimit * s.l1Cfg.Config.ElasticityMultiplier() @@ -76,6 +76,13 @@ func (s *L1Miner) ActL1StartBlock(timeDelta uint64) Action { if s.l1Cfg.Config.IsShanghai(header.Number, header.Time) { header.WithdrawalsHash = &types.EmptyWithdrawalsHash } + if s.l1Cfg.Config.IsCancun(header.Number, header.Time) { + var root common.Hash + var zero uint64 + header.BlobGasUsed = &zero + header.ExcessBlobGas = &zero + header.ParentBeaconRoot = &root + } s.l1Building = true s.l1BuildingHeader = header @@ -95,14 +102,12 @@ func (s *L1Miner) ActL1IncludeTx(from common.Address) Action { t.InvalidAction("no tx inclusion when not building l1 block") return } - i := s.pendingIndices[from] - txs, q := s.eth.TxPool().ContentFrom(from) - if uint64(len(txs)) <= i { - t.Fatalf("no pending txs from %s, and have %d unprocessable queued txs from this account", from, len(q)) + getPendingIndex := func(from common.Address) uint64 { + return s.pendingIndices[from] } - tx := txs[i] + tx := firstValidTx(t, from, getPendingIndex, s.eth.TxPool().ContentFrom, s.EthClient().NonceAt) s.IncludeTx(t, tx) - s.pendingIndices[from] = i + 1 // won't retry the tx + s.pendingIndices[from] = s.pendingIndices[from] + 1 // won't retry the tx } } diff --git a/op-e2e/actions/l1_replica.go b/op-e2e/actions/l1_replica.go index b0dbef2a20365..8456e30223d34 100644 --- a/op-e2e/actions/l1_replica.go +++ b/op-e2e/actions/l1_replica.go @@ -180,7 +180,7 @@ func (s *L1Replica) RPCClient() client.RPC { } func (s *L1Replica) L1Client(t Testing, cfg *rollup.Config) *sources.L1Client { - l1F, err := sources.NewL1Client(s.RPCClient(), s.log, nil, sources.L1ClientDefaultConfig(cfg, false, sources.RPCKindBasic)) + l1F, err := sources.NewL1Client(s.RPCClient(), s.log, nil, sources.L1ClientDefaultConfig(cfg, false, sources.RPCKindStandard)) require.NoError(t, err) return l1F } diff --git a/op-e2e/actions/l1_replica_test.go b/op-e2e/actions/l1_replica_test.go index 35d2aee2d27a9..fa12159f7ea69 100644 --- a/op-e2e/actions/l1_replica_test.go +++ b/op-e2e/actions/l1_replica_test.go @@ -42,7 +42,7 @@ func TestL1Replica_ActL1RPCFail(gt *testing.T) { // mock an RPC failure replica.ActL1RPCFail(t) // check RPC failure - l1Cl, err := sources.NewL1Client(replica.RPCClient(), log, nil, sources.L1ClientDefaultConfig(sd.RollupCfg, false, sources.RPCKindBasic)) + l1Cl, err := sources.NewL1Client(replica.RPCClient(), log, nil, sources.L1ClientDefaultConfig(sd.RollupCfg, false, sources.RPCKindStandard)) require.NoError(t, err) _, err = l1Cl.InfoByLabel(t.Ctx(), eth.Unsafe) require.ErrorContains(t, err, "mock") diff --git a/op-e2e/actions/l2_batcher.go b/op-e2e/actions/l2_batcher.go index 57d5864571f04..4ed14c139383e 100644 --- a/op-e2e/actions/l2_batcher.go +++ b/op-e2e/actions/l2_batcher.go @@ -46,6 +46,10 @@ type BatcherCfg struct { GarbageCfg *GarbageChannelCfg } +type L2BlockRefs interface { + L2BlockRefByHash(ctx context.Context, hash common.Hash) (eth.L2BlockRef, error) +} + // L2Batcher buffers and submits L2 batches to L1. // // TODO: note the batcher shares little logic/state with actual op-batcher, @@ -59,24 +63,26 @@ type L2Batcher struct { syncStatusAPI SyncStatusAPI l2 BlocksAPI l1 L1TxAPI + engCl L2BlockRefs l1Signer types.Signer l2ChannelOut ChannelOutIface l2Submitting bool // when the channel out is being submitted, and not safe to write to without resetting - l2BufferedBlock eth.BlockID - l2SubmittedBlock eth.BlockID + l2BufferedBlock eth.L2BlockRef + l2SubmittedBlock eth.L2BlockRef l2BatcherCfg *BatcherCfg batcherAddr common.Address } -func NewL2Batcher(log log.Logger, rollupCfg *rollup.Config, batcherCfg *BatcherCfg, api SyncStatusAPI, l1 L1TxAPI, l2 BlocksAPI) *L2Batcher { +func NewL2Batcher(log log.Logger, rollupCfg *rollup.Config, batcherCfg *BatcherCfg, api SyncStatusAPI, l1 L1TxAPI, l2 BlocksAPI, engCl L2BlockRefs) *L2Batcher { return &L2Batcher{ log: log, rollupCfg: rollupCfg, syncStatusAPI: api, l1: l1, l2: l2, + engCl: engCl, l2BatcherCfg: batcherCfg, l1Signer: types.LatestSignerForChainID(rollupCfg.L1ChainID), batcherAddr: crypto.PubkeyToAddress(batcherCfg.BatcherKey.PublicKey), @@ -103,31 +109,39 @@ func (s *L2Batcher) Buffer(t Testing) error { syncStatus, err := s.syncStatusAPI.SyncStatus(t.Ctx()) require.NoError(t, err, "no sync status error") // If we just started, start at safe-head - if s.l2SubmittedBlock == (eth.BlockID{}) { + if s.l2SubmittedBlock == (eth.L2BlockRef{}) { s.log.Info("Starting batch-submitter work at safe-head", "safe", syncStatus.SafeL2) - s.l2SubmittedBlock = syncStatus.SafeL2.ID() - s.l2BufferedBlock = syncStatus.SafeL2.ID() + s.l2SubmittedBlock = syncStatus.SafeL2 + s.l2BufferedBlock = syncStatus.SafeL2 s.l2ChannelOut = nil } // If it's lagging behind, catch it up. if s.l2SubmittedBlock.Number < syncStatus.SafeL2.Number { s.log.Warn("last submitted block lagged behind L2 safe head: batch submission will continue from the safe head now", "last", s.l2SubmittedBlock, "safe", syncStatus.SafeL2) - s.l2SubmittedBlock = syncStatus.SafeL2.ID() - s.l2BufferedBlock = syncStatus.SafeL2.ID() + s.l2SubmittedBlock = syncStatus.SafeL2 + s.l2BufferedBlock = syncStatus.SafeL2 s.l2ChannelOut = nil } // Add the next unsafe block to the channel if s.l2BufferedBlock.Number >= syncStatus.UnsafeL2.Number { if s.l2BufferedBlock.Number > syncStatus.UnsafeL2.Number || s.l2BufferedBlock.Hash != syncStatus.UnsafeL2.Hash { s.log.Error("detected a reorg in L2 chain vs previous buffered information, resetting to safe head now", "safe_head", syncStatus.SafeL2) - s.l2SubmittedBlock = syncStatus.SafeL2.ID() - s.l2BufferedBlock = syncStatus.SafeL2.ID() + s.l2SubmittedBlock = syncStatus.SafeL2 + s.l2BufferedBlock = syncStatus.SafeL2 s.l2ChannelOut = nil } else { s.log.Info("nothing left to submit") return nil } } + block, err := s.l2.BlockByNumber(t.Ctx(), big.NewInt(int64(s.l2BufferedBlock.Number+1))) + require.NoError(t, err, "need l2 block %d from sync status", s.l2SubmittedBlock.Number+1) + if block.ParentHash() != s.l2BufferedBlock.Hash { + s.log.Error("detected a reorg in L2 chain vs previous submitted information, resetting to safe head now", "safe_head", syncStatus.SafeL2) + s.l2SubmittedBlock = syncStatus.SafeL2 + s.l2BufferedBlock = syncStatus.SafeL2 + s.l2ChannelOut = nil + } // Create channel if we don't have one yet if s.l2ChannelOut == nil { var ch ChannelOutIface @@ -140,23 +154,24 @@ func (s *L2Batcher) Buffer(t Testing) error { ApproxComprRatio: 1, }) require.NoError(t, e, "failed to create compressor") - ch, err = derive.NewChannelOut(c) + + var batchType uint = derive.SingularBatchType + var spanBatchBuilder *derive.SpanBatchBuilder = nil + if s.rollupCfg.IsSpanBatch(block.Time()) { + batchType = derive.SpanBatchType + spanBatchBuilder = derive.NewSpanBatchBuilder(s.rollupCfg.Genesis.L2Time, s.rollupCfg.L2ChainID) + } + ch, err = derive.NewChannelOut(batchType, c, spanBatchBuilder) } require.NoError(t, err, "failed to create channel") s.l2ChannelOut = ch } - block, err := s.l2.BlockByNumber(t.Ctx(), big.NewInt(int64(s.l2BufferedBlock.Number+1))) - require.NoError(t, err, "need l2 block %d from sync status", s.l2SubmittedBlock.Number+1) - if block.ParentHash() != s.l2BufferedBlock.Hash { - s.log.Error("detected a reorg in L2 chain vs previous submitted information, resetting to safe head now", "safe_head", syncStatus.SafeL2) - s.l2SubmittedBlock = syncStatus.SafeL2.ID() - s.l2BufferedBlock = syncStatus.SafeL2.ID() - s.l2ChannelOut = nil - } if _, err := s.l2ChannelOut.AddBlock(block); err != nil { // should always succeed return err } - s.l2BufferedBlock = eth.ToBlockID(block) + ref, err := s.engCl.L2BlockRefByHash(t.Ctx(), block.Hash()) + require.NoError(t, err, "failed to get L2BlockRef") + s.l2BufferedBlock = ref return nil } diff --git a/op-e2e/actions/l2_batcher_test.go b/op-e2e/actions/l2_batcher_test.go index aa986dcd80cc5..a9ecbc322995e 100644 --- a/op-e2e/actions/l2_batcher_test.go +++ b/op-e2e/actions/l2_batcher_test.go @@ -7,6 +7,7 @@ import ( "testing" "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/common/hexutil" "github.com/ethereum/go-ethereum/core" "github.com/ethereum/go-ethereum/core/types" "github.com/ethereum/go-ethereum/log" @@ -20,7 +21,36 @@ import ( "github.com/ethereum-optimism/optimism/op-service/testlog" ) -func TestBatcher(gt *testing.T) { +// TestL2BatcherBatchType run each batcher-related test case in singular batch mode and span batch mode. +func TestL2BatcherBatchType(t *testing.T) { + tests := []struct { + name string + f func(gt *testing.T, spanBatchTimeOffset *hexutil.Uint64) + }{ + {"NormalBatcher", NormalBatcher}, + {"L2Finalization", L2Finalization}, + {"L2FinalizationWithSparseL1", L2FinalizationWithSparseL1}, + {"GarbageBatch", GarbageBatch}, + {"ExtendedTimeWithoutL1Batches", ExtendedTimeWithoutL1Batches}, + {"BigL2Txs", BigL2Txs}, + } + for _, test := range tests { + test := test + t.Run(test.name+"_SingularBatch", func(t *testing.T) { + test.f(t, nil) + }) + } + + spanBatchTimeOffset := hexutil.Uint64(0) + for _, test := range tests { + test := test + t.Run(test.name+"_SpanBatch", func(t *testing.T) { + test.f(t, &spanBatchTimeOffset) + }) + } +} + +func NormalBatcher(gt *testing.T, spanBatchTimeOffset *hexutil.Uint64) { t := NewDefaultTesting(gt) p := &e2eutils.TestParams{ MaxSequencerDrift: 20, // larger than L1 block time we simulate in this test (12) @@ -29,6 +59,7 @@ func TestBatcher(gt *testing.T) { L1BlockTime: 12, } dp := e2eutils.MakeDeployParams(t, p) + dp.DeployConfig.L2GenesisSpanBatchTimeOffset = spanBatchTimeOffset sd := e2eutils.Setup(t, dp, defaultAlloc) log := testlog.Logger(t, log.LvlDebug) miner, seqEngine, sequencer := setupSequencerTest(t, sd, log) @@ -39,7 +70,7 @@ func TestBatcher(gt *testing.T) { MinL1TxSize: 0, MaxL1TxSize: 128_000, BatcherKey: dp.Secrets.Batcher, - }, rollupSeqCl, miner.EthClient(), seqEngine.EthClient()) + }, rollupSeqCl, miner.EthClient(), seqEngine.EthClient(), seqEngine.EngineClient(t, sd.RollupCfg)) // Alice makes a L2 tx cl := seqEngine.EthClient() @@ -55,7 +86,7 @@ func TestBatcher(gt *testing.T) { To: &dp.Addresses.Bob, Value: e2eutils.Ether(2), }) - require.NoError(gt, cl.SendTransaction(t.Ctx(), tx)) + require.NoError(t, cl.SendTransaction(t.Ctx(), tx)) sequencer.ActL2PipelineFull(t) verifier.ActL2PipelineFull(t) @@ -97,9 +128,10 @@ func TestBatcher(gt *testing.T) { require.NotNil(t, vTx) } -func TestL2Finalization(gt *testing.T) { +func L2Finalization(gt *testing.T, spanBatchTimeOffset *hexutil.Uint64) { t := NewDefaultTesting(gt) dp := e2eutils.MakeDeployParams(t, defaultRollupTestParams) + dp.DeployConfig.L2GenesisSpanBatchTimeOffset = spanBatchTimeOffset sd := e2eutils.Setup(t, dp, defaultAlloc) log := testlog.Logger(t, log.LvlDebug) miner, engine, sequencer := setupSequencerTest(t, sd, log) @@ -137,7 +169,7 @@ func TestL2Finalization(gt *testing.T) { MinL1TxSize: 0, MaxL1TxSize: 128_000, BatcherKey: dp.Secrets.Batcher, - }, sequencer.RollupClient(), miner.EthClient(), engine.EthClient()) + }, sequencer.RollupClient(), miner.EthClient(), engine.EthClient(), engine.EngineClient(t, sd.RollupCfg)) heightToSubmit := sequencer.SyncStatus().UnsafeL2.Number @@ -202,10 +234,11 @@ func TestL2Finalization(gt *testing.T) { require.Equal(t, heightToSubmit, sequencer.SyncStatus().FinalizedL2.Number, "unknown/bad finalized L1 blocks are ignored") } -// TestL2FinalizationWithSparseL1 tests that safe L2 blocks can be finalized even if we do not regularly get a L1 finalization signal -func TestL2FinalizationWithSparseL1(gt *testing.T) { +// L2FinalizationWithSparseL1 tests that safe L2 blocks can be finalized even if we do not regularly get a L1 finalization signal +func L2FinalizationWithSparseL1(gt *testing.T, spanBatchTimeOffset *hexutil.Uint64) { t := NewDefaultTesting(gt) dp := e2eutils.MakeDeployParams(t, defaultRollupTestParams) + dp.DeployConfig.L2GenesisSpanBatchTimeOffset = spanBatchTimeOffset sd := e2eutils.Setup(t, dp, defaultAlloc) log := testlog.Logger(t, log.LvlDebug) miner, engine, sequencer := setupSequencerTest(t, sd, log) @@ -223,7 +256,7 @@ func TestL2FinalizationWithSparseL1(gt *testing.T) { MinL1TxSize: 0, MaxL1TxSize: 128_000, BatcherKey: dp.Secrets.Batcher, - }, sequencer.RollupClient(), miner.EthClient(), engine.EthClient()) + }, sequencer.RollupClient(), miner.EthClient(), engine.EthClient(), engine.EngineClient(t, sd.RollupCfg)) batcher.ActSubmitAll(t) // include in L1 @@ -258,13 +291,14 @@ func TestL2FinalizationWithSparseL1(gt *testing.T) { require.Equal(t, finalStatus.FinalizedL2.Number, finalStatus.UnsafeL2.Number, "sequencer submitted its L2 block and it finalized") } -// TestGarbageBatch tests the behavior of an invalid/malformed output channel frame containing +// GarbageBatch tests the behavior of an invalid/malformed output channel frame containing // valid batches being submitted to the batch inbox. These batches should always be rejected // and the safe L2 head should remain unaltered. -func TestGarbageBatch(gt *testing.T) { +func GarbageBatch(gt *testing.T, spanBatchTimeOffset *hexutil.Uint64) { t := NewDefaultTesting(gt) p := defaultRollupTestParams dp := e2eutils.MakeDeployParams(t, p) + dp.DeployConfig.L2GenesisSpanBatchTimeOffset = spanBatchTimeOffset for _, garbageKind := range GarbageKinds { sd := e2eutils.Setup(t, dp, defaultAlloc) log := testlog.Logger(t, log.LvlError) @@ -287,7 +321,7 @@ func TestGarbageBatch(gt *testing.T) { } } - batcher := NewL2Batcher(log, sd.RollupCfg, batcherCfg, sequencer.RollupClient(), miner.EthClient(), engine.EthClient()) + batcher := NewL2Batcher(log, sd.RollupCfg, batcherCfg, sequencer.RollupClient(), miner.EthClient(), engine.EthClient(), engine.EngineClient(t, sd.RollupCfg)) sequencer.ActL2PipelineFull(t) verifier.ActL2PipelineFull(t) @@ -340,7 +374,7 @@ func TestGarbageBatch(gt *testing.T) { } } -func TestExtendedTimeWithoutL1Batches(gt *testing.T) { +func ExtendedTimeWithoutL1Batches(gt *testing.T, spanBatchTimeOffset *hexutil.Uint64) { t := NewDefaultTesting(gt) p := &e2eutils.TestParams{ MaxSequencerDrift: 20, // larger than L1 block time we simulate in this test (12) @@ -349,6 +383,7 @@ func TestExtendedTimeWithoutL1Batches(gt *testing.T) { L1BlockTime: 12, } dp := e2eutils.MakeDeployParams(t, p) + dp.DeployConfig.L2GenesisSpanBatchTimeOffset = spanBatchTimeOffset sd := e2eutils.Setup(t, dp, defaultAlloc) log := testlog.Logger(t, log.LvlError) miner, engine, sequencer := setupSequencerTest(t, sd, log) @@ -359,7 +394,7 @@ func TestExtendedTimeWithoutL1Batches(gt *testing.T) { MinL1TxSize: 0, MaxL1TxSize: 128_000, BatcherKey: dp.Secrets.Batcher, - }, sequencer.RollupClient(), miner.EthClient(), engine.EthClient()) + }, sequencer.RollupClient(), miner.EthClient(), engine.EthClient(), engine.EngineClient(t, sd.RollupCfg)) sequencer.ActL2PipelineFull(t) verifier.ActL2PipelineFull(t) @@ -386,7 +421,7 @@ func TestExtendedTimeWithoutL1Batches(gt *testing.T) { require.Equal(t, sequencer.L2Unsafe(), sequencer.L2Safe(), "same for sequencer") } -// TestBigL2Txs tests a high-throughput case with constrained batcher: +// BigL2Txs tests a high-throughput case with constrained batcher: // - Fill 40 L2 blocks to near max-capacity, with txs of 120 KB each // - Buffer the L2 blocks into channels together as much as possible, submit data-txs only when necessary // (just before crossing the max RLP channel size) @@ -398,7 +433,7 @@ func TestExtendedTimeWithoutL1Batches(gt *testing.T) { // The goal of this test is to quickly run through an otherwise very slow process of submitting and including lots of data. // This does not test the batcher code, but is really focused at testing the batcher utils // and channel-decoding verifier code in the derive package. -func TestBigL2Txs(gt *testing.T) { +func BigL2Txs(gt *testing.T, spanBatchTimeOffset *hexutil.Uint64) { t := NewDefaultTesting(gt) p := &e2eutils.TestParams{ MaxSequencerDrift: 100, @@ -407,6 +442,7 @@ func TestBigL2Txs(gt *testing.T) { L1BlockTime: 12, } dp := e2eutils.MakeDeployParams(t, p) + dp.DeployConfig.L2GenesisSpanBatchTimeOffset = spanBatchTimeOffset sd := e2eutils.Setup(t, dp, defaultAlloc) log := testlog.Logger(t, log.LvlInfo) miner, engine, sequencer := setupSequencerTest(t, sd, log) @@ -417,7 +453,7 @@ func TestBigL2Txs(gt *testing.T) { MinL1TxSize: 0, MaxL1TxSize: 40_000, // try a small batch size, to force the data to be split between more frames BatcherKey: dp.Secrets.Batcher, - }, sequencer.RollupClient(), miner.EthClient(), engine.EthClient()) + }, sequencer.RollupClient(), miner.EthClient(), engine.EthClient(), engine.EngineClient(t, sd.RollupCfg)) sequencer.ActL2PipelineFull(t) @@ -464,13 +500,13 @@ func TestBigL2Txs(gt *testing.T) { Value: big.NewInt(0), Data: data, }) - require.NoError(gt, cl.SendTransaction(t.Ctx(), tx)) + require.NoError(t, cl.SendTransaction(t.Ctx(), tx)) engine.ActL2IncludeTx(dp.Addresses.Alice)(t) } sequencer.ActL2EndBlock(t) for batcher.l2BufferedBlock.Number < sequencer.SyncStatus().UnsafeL2.Number { // if we run out of space, close the channel and submit all the txs - if err := batcher.Buffer(t); errors.Is(err, derive.ErrTooManyRLPBytes) { + if err := batcher.Buffer(t); errors.Is(err, derive.ErrTooManyRLPBytes) || errors.Is(err, derive.CompressorFullErr) { log.Info("flushing filled channel to batch txs", "id", batcher.l2ChannelOut.ID()) batcher.ActL2ChannelClose(t) for batcher.l2ChannelOut != nil { diff --git a/op-e2e/actions/l2_engine.go b/op-e2e/actions/l2_engine.go index 33669ec6afcca..d1230ec8b7c57 100644 --- a/op-e2e/actions/l2_engine.go +++ b/op-e2e/actions/l2_engine.go @@ -1,12 +1,9 @@ package actions import ( - "context" "errors" - "time" "github.com/ethereum-optimism/optimism/op-e2e/e2eutils" - "github.com/ethereum-optimism/optimism/op-e2e/e2eutils/wait" "github.com/ethereum-optimism/optimism/op-program/client/l2/engineapi" "github.com/stretchr/testify/require" @@ -179,22 +176,8 @@ func (e *L2Engine) ActL2IncludeTx(from common.Address) Action { return } - var i uint64 - var txs []*types.Transaction - var q []*types.Transaction - // Wait for the tx to be in the pending tx queue - ctx, cancel := context.WithTimeout(context.Background(), 30*time.Second) - defer cancel() - err := wait.For(ctx, time.Second, func() (bool, error) { - i = e.engineApi.PendingIndices(from) - txs, q = e.eth.TxPool().ContentFrom(from) - return uint64(len(txs)) > i, nil - }) - require.NoError(t, err, - "no pending txs from %s, and have %d unprocessable queued txs from this account: %w", from, len(q), err) - - tx := txs[i] - err = e.engineApi.IncludeTx(tx, from) + tx := firstValidTx(t, from, e.engineApi.PendingIndices, e.eth.TxPool().ContentFrom, e.EthClient().NonceAt) + err := e.engineApi.IncludeTx(tx, from) if errors.Is(err, engineapi.ErrNotBuildingBlock) { t.InvalidAction(err.Error()) } else if errors.Is(err, engineapi.ErrUsesTooMuchGas) { diff --git a/op-e2e/actions/l2_engine_test.go b/op-e2e/actions/l2_engine_test.go index 4499848811b44..fc48a49e5262a 100644 --- a/op-e2e/actions/l2_engine_test.go +++ b/op-e2e/actions/l2_engine_test.go @@ -46,7 +46,7 @@ func TestL2EngineAPI(gt *testing.T) { chainA, _ := core.GenerateChain(sd.L2Cfg.Config, genesisBlock, consensus, db, 1, func(i int, gen *core.BlockGen) { gen.SetCoinbase(common.Address{'A'}) }) - payloadA, err := eth.BlockAsPayload(chainA[0]) + payloadA, err := eth.BlockAsPayload(chainA[0], sd.RollupCfg.CanyonTime) require.NoError(t, err) // apply the payload @@ -69,7 +69,7 @@ func TestL2EngineAPI(gt *testing.T) { chainB, _ := core.GenerateChain(sd.L2Cfg.Config, genesisBlock, consensus, db, 1, func(i int, gen *core.BlockGen) { gen.SetCoinbase(common.Address{'B'}) }) - payloadB, err := eth.BlockAsPayload(chainB[0]) + payloadB, err := eth.BlockAsPayload(chainB[0], sd.RollupCfg.CanyonTime) require.NoError(t, err) // apply the payload @@ -125,18 +125,26 @@ func TestL2EngineAPIBlockBuilding(gt *testing.T) { l2Cl, err := sources.NewEngineClient(engine.RPCClient(), log, nil, sources.EngineClientDefaultConfig(sd.RollupCfg)) require.NoError(t, err) + nextBlockTime := eth.Uint64Quantity(parent.Time) + 2 + + var w *types.Withdrawals + if sd.RollupCfg.IsCanyon(uint64(nextBlockTime)) { + w = &types.Withdrawals{} + } + // Now let's ask the engine to build a block fcRes, err := l2Cl.ForkchoiceUpdate(t.Ctx(), ð.ForkchoiceState{ HeadBlockHash: parent.Hash(), SafeBlockHash: genesisBlock.Hash(), FinalizedBlockHash: genesisBlock.Hash(), }, ð.PayloadAttributes{ - Timestamp: eth.Uint64Quantity(parent.Time) + 2, + Timestamp: nextBlockTime, PrevRandao: eth.Bytes32{}, SuggestedFeeRecipient: common.Address{'C'}, Transactions: nil, NoTxPool: false, GasLimit: (*eth.Uint64Quantity)(&sd.RollupCfg.Genesis.SystemConfig.GasLimit), + Withdrawals: w, }) require.NoError(t, err) require.Equal(t, fcRes.PayloadStatus.Status, eth.ExecutionValid) diff --git a/op-e2e/actions/l2_proposer.go b/op-e2e/actions/l2_proposer.go index 5eae624915f85..8086fb2cf5d2a 100644 --- a/op-e2e/actions/l2_proposer.go +++ b/op-e2e/actions/l2_proposer.go @@ -48,9 +48,6 @@ type fakeTxMgr struct { func (f fakeTxMgr) From() common.Address { return f.from } -func (f fakeTxMgr) Call(_ context.Context, _ ethereum.CallMsg, _ *big.Int) ([]byte, error) { - panic("unimplemented") -} func (f fakeTxMgr) BlockNumber(_ context.Context) (uint64, error) { panic("unimplemented") } diff --git a/op-e2e/actions/l2_proposer_test.go b/op-e2e/actions/l2_proposer_test.go index 5e1f51a33db54..44654ebd9769e 100644 --- a/op-e2e/actions/l2_proposer_test.go +++ b/op-e2e/actions/l2_proposer_test.go @@ -4,6 +4,7 @@ import ( "testing" "github.com/ethereum/go-ethereum/accounts/abi/bind" + "github.com/ethereum/go-ethereum/common/hexutil" "github.com/ethereum/go-ethereum/core/types" "github.com/ethereum/go-ethereum/log" "github.com/stretchr/testify/require" @@ -14,9 +15,34 @@ import ( "github.com/ethereum-optimism/optimism/op-service/testlog" ) -func TestProposer(gt *testing.T) { +// TestProposerBatchType run each proposer-related test case in singular batch mode and span batch mode. +func TestProposerBatchType(t *testing.T) { + tests := []struct { + name string + f func(gt *testing.T, spanBatchTimeOffset *hexutil.Uint64) + }{ + {"RunProposerTest", RunProposerTest}, + } + for _, test := range tests { + test := test + t.Run(test.name+"_SingularBatch", func(t *testing.T) { + test.f(t, nil) + }) + } + + spanBatchTimeOffset := hexutil.Uint64(0) + for _, test := range tests { + test := test + t.Run(test.name+"_SpanBatch", func(t *testing.T) { + test.f(t, &spanBatchTimeOffset) + }) + } +} + +func RunProposerTest(gt *testing.T, spanBatchTimeOffset *hexutil.Uint64) { t := NewDefaultTesting(gt) dp := e2eutils.MakeDeployParams(t, defaultRollupTestParams) + dp.DeployConfig.L2GenesisSpanBatchTimeOffset = spanBatchTimeOffset sd := e2eutils.Setup(t, dp, defaultAlloc) log := testlog.Logger(t, log.LvlDebug) miner, seqEngine, sequencer := setupSequencerTest(t, sd, log) @@ -26,7 +52,7 @@ func TestProposer(gt *testing.T) { MinL1TxSize: 0, MaxL1TxSize: 128_000, BatcherKey: dp.Secrets.Batcher, - }, rollupSeqCl, miner.EthClient(), seqEngine.EthClient()) + }, rollupSeqCl, miner.EthClient(), seqEngine.EthClient(), seqEngine.EngineClient(t, sd.RollupCfg)) proposer := NewL2Proposer(t, log, &ProposerCfg{ OutputOracleAddr: sd.DeploymentsL1.L2OutputOracleProxy, diff --git a/op-e2e/actions/l2_sequencer_test.go b/op-e2e/actions/l2_sequencer_test.go index 17dc2a15f47e0..654787cd8268a 100644 --- a/op-e2e/actions/l2_sequencer_test.go +++ b/op-e2e/actions/l2_sequencer_test.go @@ -21,7 +21,7 @@ func setupSequencerTest(t Testing, sd *e2eutils.SetupData, log log.Logger) (*L1M miner := NewL1Miner(t, log, sd.L1Cfg) - l1F, err := sources.NewL1Client(miner.RPCClient(), log, nil, sources.L1ClientDefaultConfig(sd.RollupCfg, false, sources.RPCKindBasic)) + l1F, err := sources.NewL1Client(miner.RPCClient(), log, nil, sources.L1ClientDefaultConfig(sd.RollupCfg, false, sources.RPCKindStandard)) require.NoError(t, err) engine := NewL2Engine(t, log, sd.L2Cfg, sd.RollupCfg.Genesis.L1, jwtPath) l2Cl, err := sources.NewEngineClient(engine.RPCClient(), log, nil, sources.EngineClientDefaultConfig(sd.RollupCfg)) diff --git a/op-e2e/actions/l2_verifier.go b/op-e2e/actions/l2_verifier.go index 1340210d197ee..6419a68ce669a 100644 --- a/op-e2e/actions/l2_verifier.go +++ b/op-e2e/actions/l2_verifier.go @@ -135,6 +135,10 @@ func (s *L2Verifier) L2Safe() eth.L2BlockRef { return s.derivation.SafeL2Head() } +func (s *L2Verifier) L2PendingSafe() eth.L2BlockRef { + return s.derivation.PendingSafeL2Head() +} + func (s *L2Verifier) L2Unsafe() eth.L2BlockRef { return s.derivation.UnsafeL2Head() } @@ -153,6 +157,7 @@ func (s *L2Verifier) SyncStatus() *eth.SyncStatus { UnsafeL2: s.L2Unsafe(), SafeL2: s.L2Safe(), FinalizedL2: s.L2Finalized(), + PendingSafeL2: s.L2PendingSafe(), UnsafeL2SyncTarget: s.derivation.UnsafeL2SyncTarget(), EngineSyncTarget: s.EngineSyncTarget(), } diff --git a/op-e2e/actions/reorg_test.go b/op-e2e/actions/reorg_test.go index 8330e22b44a0e..df88568356e4c 100644 --- a/op-e2e/actions/reorg_test.go +++ b/op-e2e/actions/reorg_test.go @@ -7,6 +7,7 @@ import ( "testing" "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/common/hexutil" "github.com/ethereum/go-ethereum/core/types" "github.com/ethereum/go-ethereum/eth/ethconfig" "github.com/ethereum/go-ethereum/log" @@ -21,8 +22,9 @@ import ( "github.com/ethereum-optimism/optimism/op-service/testlog" ) -func setupReorgTest(t Testing, config *e2eutils.TestParams) (*e2eutils.SetupData, *e2eutils.DeployParams, *L1Miner, *L2Sequencer, *L2Engine, *L2Verifier, *L2Engine, *L2Batcher) { +func setupReorgTest(t Testing, config *e2eutils.TestParams, spanBatchTimeOffset *hexutil.Uint64) (*e2eutils.SetupData, *e2eutils.DeployParams, *L1Miner, *L2Sequencer, *L2Engine, *L2Verifier, *L2Engine, *L2Batcher) { dp := e2eutils.MakeDeployParams(t, config) + dp.DeployConfig.L2GenesisSpanBatchTimeOffset = spanBatchTimeOffset sd := e2eutils.Setup(t, dp, defaultAlloc) log := testlog.Logger(t, log.LvlDebug) @@ -40,13 +42,42 @@ func setupReorgTestActors(t Testing, dp *e2eutils.DeployParams, sd *e2eutils.Set MinL1TxSize: 0, MaxL1TxSize: 128_000, BatcherKey: dp.Secrets.Batcher, - }, rollupSeqCl, miner.EthClient(), seqEngine.EthClient()) + }, rollupSeqCl, miner.EthClient(), seqEngine.EthClient(), seqEngine.EngineClient(t, sd.RollupCfg)) return sd, dp, miner, sequencer, seqEngine, verifier, verifEngine, batcher } -func TestReorgOrphanBlock(gt *testing.T) { +// TestReorgBatchType run each reorg-related test case in singular batch mode and span batch mode. +func TestReorgBatchType(t *testing.T) { + tests := []struct { + name string + f func(gt *testing.T, spanBatchTimeOffset *hexutil.Uint64) + }{ + {"ReorgOrphanBlock", ReorgOrphanBlock}, + {"ReorgFlipFlop", ReorgFlipFlop}, + {"DeepReorg", DeepReorg}, + {"RestartOpGeth", RestartOpGeth}, + {"ConflictingL2Blocks", ConflictingL2Blocks}, + {"SyncAfterReorg", SyncAfterReorg}, + } + for _, test := range tests { + test := test + t.Run(test.name+"_SingularBatch", func(t *testing.T) { + test.f(t, nil) + }) + } + + spanBatchTimeOffset := hexutil.Uint64(0) + for _, test := range tests { + test := test + t.Run(test.name+"_SpanBatch", func(t *testing.T) { + test.f(t, &spanBatchTimeOffset) + }) + } +} + +func ReorgOrphanBlock(gt *testing.T, spanBatchTimeOffset *hexutil.Uint64) { t := NewDefaultTesting(gt) - sd, _, miner, sequencer, _, verifier, verifierEng, batcher := setupReorgTest(t, defaultRollupTestParams) + sd, _, miner, sequencer, _, verifier, verifierEng, batcher := setupReorgTest(t, defaultRollupTestParams, spanBatchTimeOffset) verifEngClient := verifierEng.EngineClient(t, sd.RollupCfg) sequencer.ActL2PipelineFull(t) @@ -112,9 +143,9 @@ func TestReorgOrphanBlock(gt *testing.T) { require.Equal(t, verifier.L2Safe(), sequencer.L2Safe(), "verifier and sequencer see same safe L2 block, while only verifier dealt with the orphan and replay") } -func TestReorgFlipFlop(gt *testing.T) { +func ReorgFlipFlop(gt *testing.T, spanBatchTimeOffset *hexutil.Uint64) { t := NewDefaultTesting(gt) - sd, _, miner, sequencer, _, verifier, verifierEng, batcher := setupReorgTest(t, defaultRollupTestParams) + sd, _, miner, sequencer, _, verifier, verifierEng, batcher := setupReorgTest(t, defaultRollupTestParams, spanBatchTimeOffset) minerCl := miner.L1Client(t, sd.RollupCfg) verifEngClient := verifierEng.EngineClient(t, sd.RollupCfg) checkVerifEngine := func() { @@ -189,8 +220,16 @@ func TestReorgFlipFlop(gt *testing.T) { verifier.ActL2PipelineFull(t) require.Equal(t, sd.RollupCfg.Genesis.L1, verifier.L2Safe().L1Origin, "expected to be back at genesis origin after losing A0 and A1") - require.NotZero(t, verifier.L2Safe().Number, "still preserving old L2 blocks that did not reference reorged L1 chain (assuming more than one L2 block per L1 block)") - require.Equal(t, verifier.L2Safe(), verifier.L2Unsafe(), "head is at safe block after L1 reorg") + if sd.RollupCfg.SpanBatchTime == nil { + // before span batch hard fork + require.NotZero(t, verifier.L2Safe().Number, "still preserving old L2 blocks that did not reference reorged L1 chain (assuming more than one L2 block per L1 block)") + require.Equal(t, verifier.L2Safe(), verifier.L2Unsafe(), "head is at safe block after L1 reorg") + } else { + // after span batch hard fork + require.Zero(t, verifier.L2Safe().Number, "safe head is at genesis block because span batch referenced reorged L1 chain is not accepted") + require.Equal(t, verifier.L2Unsafe().ID(), sequencer.L2Unsafe().ParentID(), "head is at the highest unsafe block that references canonical L1 chain(genesis block)") + batcher.l2BufferedBlock = eth.L2BlockRef{} // must reset batcher to resubmit blocks included in the last batch + } checkVerifEngine() // and sync the sequencer, then build some new L2 blocks, up to and including with L1 origin B2 @@ -210,6 +249,7 @@ func TestReorgFlipFlop(gt *testing.T) { verifier.ActL1HeadSignal(t) verifier.ActL2PipelineFull(t) require.Equal(t, verifier.L2Safe().L1Origin, blockB2.ID(), "B2 is the L1 origin of verifier now") + require.Equal(t, verifier.L2Unsafe(), sequencer.L2Unsafe(), "verifier unsafe head is reorged along sequencer") checkVerifEngine() // Flop back to chain A! @@ -324,7 +364,7 @@ func TestReorgFlipFlop(gt *testing.T) { // Verifier // - Unsafe head is 62 // - Safe head is 42 -func TestDeepReorg(gt *testing.T) { +func DeepReorg(gt *testing.T, spanBatchTimeOffset *hexutil.Uint64) { t := NewDefaultTesting(gt) // Create actor and verification engine client @@ -333,7 +373,7 @@ func TestDeepReorg(gt *testing.T) { SequencerWindowSize: 20, ChannelTimeout: 120, L1BlockTime: 4, - }) + }, spanBatchTimeOffset) minerCl := miner.L1Client(t, sd.RollupCfg) l2Client := seqEngine.EthClient() verifEngClient := verifierEng.EngineClient(t, sd.RollupCfg) @@ -557,9 +597,9 @@ type rpcWrapper struct { client.RPC } -// TestRestartOpGeth tests that the sequencer can restart its execution engine without rollup-node restart, +// RestartOpGeth tests that the sequencer can restart its execution engine without rollup-node restart, // including recovering the finalized/safe state of L2 chain without reorging. -func TestRestartOpGeth(gt *testing.T) { +func RestartOpGeth(gt *testing.T, spanBatchTimeOffset *hexutil.Uint64) { t := NewDefaultTesting(gt) dbPath := path.Join(t.TempDir(), "testdb") dbOption := func(_ *ethconfig.Config, nodeCfg *node.Config) error { @@ -567,12 +607,13 @@ func TestRestartOpGeth(gt *testing.T) { return nil } dp := e2eutils.MakeDeployParams(t, defaultRollupTestParams) + dp.DeployConfig.L2GenesisSpanBatchTimeOffset = spanBatchTimeOffset sd := e2eutils.Setup(t, dp, defaultAlloc) log := testlog.Logger(t, log.LvlDebug) jwtPath := e2eutils.WriteDefaultJWT(t) // L1 miner := NewL1Miner(t, log, sd.L1Cfg) - l1F, err := sources.NewL1Client(miner.RPCClient(), log, nil, sources.L1ClientDefaultConfig(sd.RollupCfg, false, sources.RPCKindBasic)) + l1F, err := sources.NewL1Client(miner.RPCClient(), log, nil, sources.L1ClientDefaultConfig(sd.RollupCfg, false, sources.RPCKindStandard)) require.NoError(t, err) // Sequencer seqEng := NewL2Engine(t, log, sd.L2Cfg, sd.RollupCfg.Genesis.L1, jwtPath, dbOption) @@ -585,7 +626,7 @@ func TestRestartOpGeth(gt *testing.T) { MinL1TxSize: 0, MaxL1TxSize: 128_000, BatcherKey: dp.Secrets.Batcher, - }, sequencer.RollupClient(), miner.EthClient(), seqEng.EthClient()) + }, sequencer.RollupClient(), miner.EthClient(), seqEng.EthClient(), seqEng.EngineClient(t, sd.RollupCfg)) // start sequencer.ActL2PipelineFull(t) @@ -651,12 +692,13 @@ func TestRestartOpGeth(gt *testing.T) { require.Equal(t, statusBeforeRestart.SafeL2, sequencer.L2Safe(), "expecting the safe block to catch up to what it was before shutdown after syncing from L1, and not be stuck at the finalized block") } -// TestConflictingL2Blocks tests that a second copy of the sequencer stack cannot introduce an alternative +// ConflictingL2Blocks tests that a second copy of the sequencer stack cannot introduce an alternative // L2 block (compared to something already secured by the first sequencer): // the alt block is not synced by the verifier, in unsafe and safe sync modes. -func TestConflictingL2Blocks(gt *testing.T) { +func ConflictingL2Blocks(gt *testing.T, spanBatchTimeOffset *hexutil.Uint64) { t := NewDefaultTesting(gt) dp := e2eutils.MakeDeployParams(t, defaultRollupTestParams) + dp.DeployConfig.L2GenesisSpanBatchTimeOffset = spanBatchTimeOffset sd := e2eutils.Setup(t, dp, defaultAlloc) log := testlog.Logger(t, log.LvlDebug) @@ -667,14 +709,14 @@ func TestConflictingL2Blocks(gt *testing.T) { altSeqEng := NewL2Engine(t, log, sd.L2Cfg, sd.RollupCfg.Genesis.L1, jwtPath) altSeqEngCl, err := sources.NewEngineClient(altSeqEng.RPCClient(), log, nil, sources.EngineClientDefaultConfig(sd.RollupCfg)) require.NoError(t, err) - l1F, err := sources.NewL1Client(miner.RPCClient(), log, nil, sources.L1ClientDefaultConfig(sd.RollupCfg, false, sources.RPCKindBasic)) + l1F, err := sources.NewL1Client(miner.RPCClient(), log, nil, sources.L1ClientDefaultConfig(sd.RollupCfg, false, sources.RPCKindStandard)) require.NoError(t, err) altSequencer := NewL2Sequencer(t, log, l1F, altSeqEngCl, sd.RollupCfg, 0) altBatcher := NewL2Batcher(log, sd.RollupCfg, &BatcherCfg{ MinL1TxSize: 0, MaxL1TxSize: 128_000, BatcherKey: dp.Secrets.Batcher, - }, altSequencer.RollupClient(), miner.EthClient(), altSeqEng.EthClient()) + }, altSequencer.RollupClient(), miner.EthClient(), altSeqEng.EthClient(), altSeqEng.EngineClient(t, sd.RollupCfg)) // And set up user Alice, using the alternative sequencer endpoint l2Cl := altSeqEng.EthClient() @@ -762,3 +804,108 @@ func TestConflictingL2Blocks(gt *testing.T) { require.Equal(t, verifier.L2Unsafe(), altSequencer.L2Unsafe(), "alt-sequencer gets back in harmony with verifier by reorging out its conflicting data") require.Equal(t, sequencer.L2Unsafe(), altSequencer.L2Unsafe(), "and gets back in harmony with original sequencer") } + +func SyncAfterReorg(gt *testing.T, spanBatchTimeOffset *hexutil.Uint64) { + t := NewDefaultTesting(gt) + testingParams := e2eutils.TestParams{ + MaxSequencerDrift: 60, + SequencerWindowSize: 4, + ChannelTimeout: 2, + L1BlockTime: 12, + } + sd, dp, miner, sequencer, seqEngine, verifier, _, batcher := setupReorgTest(t, &testingParams, spanBatchTimeOffset) + l2Client := seqEngine.EthClient() + log := testlog.Logger(t, log.LvlDebug) + addresses := e2eutils.CollectAddresses(sd, dp) + l2UserEnv := &BasicUserEnv[*L2Bindings]{ + EthCl: l2Client, + Signer: types.LatestSigner(sd.L2Cfg.Config), + AddressCorpora: addresses, + Bindings: NewL2Bindings(t, l2Client, seqEngine.GethClient()), + } + alice := NewCrossLayerUser(log, dp.Secrets.Alice, rand.New(rand.NewSource(0xa57b))) + alice.L2.SetUserEnv(l2UserEnv) + + sequencer.ActL2PipelineFull(t) + verifier.ActL2PipelineFull(t) + + // build empty L1 block: A0 + miner.ActL1SetFeeRecipient(common.Address{'A', 0}) + miner.ActEmptyBlock(t) + sequencer.ActL1HeadSignal(t) + for sequencer.derivation.UnsafeL2Head().L1Origin.Number < sequencer.l1State.L1Head().Number { + // build L2 blocks until the L1 origin is the current L1 head(A0) + sequencer.ActL2PipelineFull(t) + sequencer.ActL2StartBlock(t) + if sequencer.derivation.UnsafeL2Head().Number == 11 { + // include a user tx at L2 block #12 to make a state transition + alice.L2.ActResetTxOpts(t) + alice.L2.ActSetTxToAddr(&dp.Addresses.Bob)(t) + alice.L2.ActMakeTx(t) + // Include the tx in the block we're making + seqEngine.ActL2IncludeTx(alice.Address())(t) + } + sequencer.ActL2EndBlock(t) + } + // submit all new L2 blocks: #1 ~ #12 + batcher.ActSubmitAll(t) + + // build an L1 block included batch TX: A1 + miner.ActL1SetFeeRecipient(common.Address{'A', 1}) + miner.ActL1StartBlock(12)(t) + miner.ActL1IncludeTx(sd.RollupCfg.Genesis.SystemConfig.BatcherAddr)(t) + miner.ActL1EndBlock(t) + + for i := 2; i < 6; i++ { + // build L2 blocks until the L1 origin is the current L1 head + sequencer.ActL1HeadSignal(t) + sequencer.ActBuildToL1Head(t) + // submt all new L2 blocks + batcher.ActSubmitAll(t) + + // build an L1 block included batch TX: A2 ~ A5 + miner.ActL1SetFeeRecipient(common.Address{'A', byte(i)}) + miner.ActL1StartBlock(12)(t) + miner.ActL1IncludeTx(sd.RollupCfg.Genesis.SystemConfig.BatcherAddr)(t) + miner.ActL1EndBlock(t) + } + + sequencer.ActL1HeadSignal(t) + sequencer.ActL2PipelineFull(t) + // capture current L2 safe head + submittedSafeHead := sequencer.L2Safe().ID() + + // build L2 blocks until the L1 origin is the current L1 head(A5) + sequencer.ActBuildToL1Head(t) + batcher.ActSubmitAll(t) + + // build an L1 block included batch TX: A6 + miner.ActL1SetFeeRecipient(common.Address{'A', 6}) + miner.ActL1StartBlock(12)(t) + miner.ActL1IncludeTx(sd.RollupCfg.Genesis.SystemConfig.BatcherAddr)(t) + miner.ActL1EndBlock(t) + + sequencer.ActL1HeadSignal(t) + sequencer.ActL2PipelineFull(t) + verifier.ActL1HeadSignal(t) + verifier.ActL2PipelineFull(t) + + // reorg L1 + miner.ActL1RewindToParent(t) // undo A6 + miner.ActL1SetFeeRecipient(common.Address{'B', 6}) // build B6 + miner.ActEmptyBlock(t) + miner.ActL1SetFeeRecipient(common.Address{'B', 7}) // build B7 + miner.ActEmptyBlock(t) + + // sequencer and verifier detect L1 reorg + // derivation pipeline is reset + // safe head may be reset to block #11 + sequencer.ActL1HeadSignal(t) + sequencer.ActL2PipelineFull(t) + verifier.ActL1HeadSignal(t) + verifier.ActL2PipelineFull(t) + + // sequencer and verifier must derive all submitted batches and reach to the captured block + require.Equal(t, sequencer.L2Safe().ID(), submittedSafeHead) + require.Equal(t, verifier.L2Safe().ID(), submittedSafeHead) +} diff --git a/op-e2e/actions/span_batch_test.go b/op-e2e/actions/span_batch_test.go new file mode 100644 index 0000000000000..65b20cf04306b --- /dev/null +++ b/op-e2e/actions/span_batch_test.go @@ -0,0 +1,365 @@ +package actions + +import ( + "crypto/ecdsa" + crand "crypto/rand" + "fmt" + "math/big" + "math/rand" + "testing" + + "github.com/ethereum-optimism/optimism/op-e2e/e2eutils" + "github.com/ethereum-optimism/optimism/op-node/rollup/sync" + "github.com/ethereum-optimism/optimism/op-service/testlog" + "github.com/ethereum/go-ethereum" + "github.com/ethereum/go-ethereum/accounts" + "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/common/hexutil" + "github.com/ethereum/go-ethereum/core" + "github.com/ethereum/go-ethereum/core/types" + "github.com/ethereum/go-ethereum/crypto" + "github.com/ethereum/go-ethereum/log" + "github.com/ethereum/go-ethereum/params" + "github.com/stretchr/testify/require" +) + +// TestDropSpanBatchBeforeHardfork tests behavior of op-node before SpanBatch hardfork. +// op-node must drop SpanBatch before SpanBatch hardfork. +func TestDropSpanBatchBeforeHardfork(gt *testing.T) { + t := NewDefaultTesting(gt) + p := &e2eutils.TestParams{ + MaxSequencerDrift: 20, // larger than L1 block time we simulate in this test (12) + SequencerWindowSize: 24, + ChannelTimeout: 20, + L1BlockTime: 12, + } + dp := e2eutils.MakeDeployParams(t, p) + // do not activate SpanBatch hardfork for verifier + dp.DeployConfig.L2GenesisSpanBatchTimeOffset = nil + sd := e2eutils.Setup(t, dp, defaultAlloc) + log := testlog.Logger(t, log.LvlError) + miner, seqEngine, sequencer := setupSequencerTest(t, sd, log) + verifEngine, verifier := setupVerifier(t, sd, log, miner.L1Client(t, sd.RollupCfg), &sync.Config{}) + + rollupSeqCl := sequencer.RollupClient() + dp2 := e2eutils.MakeDeployParams(t, p) + minTs := hexutil.Uint64(0) + // activate SpanBatch hardfork for batcher. so batcher will submit SpanBatches to L1. + dp2.DeployConfig.L2GenesisSpanBatchTimeOffset = &minTs + sd2 := e2eutils.Setup(t, dp2, defaultAlloc) + batcher := NewL2Batcher(log, sd2.RollupCfg, &BatcherCfg{ + MinL1TxSize: 0, + MaxL1TxSize: 128_000, + BatcherKey: dp.Secrets.Batcher, + }, rollupSeqCl, miner.EthClient(), seqEngine.EthClient(), seqEngine.EngineClient(t, sd.RollupCfg)) + + // Alice makes a L2 tx + cl := seqEngine.EthClient() + n, err := cl.PendingNonceAt(t.Ctx(), dp.Addresses.Alice) + require.NoError(t, err) + signer := types.LatestSigner(sd.L2Cfg.Config) + tx := types.MustSignNewTx(dp.Secrets.Alice, signer, &types.DynamicFeeTx{ + ChainID: sd.L2Cfg.Config.ChainID, + Nonce: n, + GasTipCap: big.NewInt(2 * params.GWei), + GasFeeCap: new(big.Int).Add(miner.l1Chain.CurrentBlock().BaseFee, big.NewInt(2*params.GWei)), + Gas: params.TxGas, + To: &dp.Addresses.Bob, + Value: e2eutils.Ether(2), + }) + require.NoError(gt, cl.SendTransaction(t.Ctx(), tx)) + + sequencer.ActL2PipelineFull(t) + verifier.ActL2PipelineFull(t) + + // Make L2 block + sequencer.ActL2StartBlock(t) + seqEngine.ActL2IncludeTx(dp.Addresses.Alice)(t) + sequencer.ActL2EndBlock(t) + + // batch submit to L1. batcher should submit span batches. + batcher.ActL2BatchBuffer(t) + batcher.ActL2ChannelClose(t) + batcher.ActL2BatchSubmit(t) + + // confirm batch on L1 + miner.ActL1StartBlock(12)(t) + miner.ActL1IncludeTx(dp.Addresses.Batcher)(t) + miner.ActL1EndBlock(t) + bl := miner.l1Chain.CurrentBlock() + log.Info("bl", "txs", len(miner.l1Chain.GetBlockByHash(bl.Hash()).Transactions())) + + // Now make enough L1 blocks that the verifier will have to derive a L2 block + // It will also eagerly derive the block from the batcher + for i := uint64(0); i < sd.RollupCfg.SeqWindowSize; i++ { + miner.ActL1StartBlock(12)(t) + miner.ActL1EndBlock(t) + } + + // try to sync verifier from L1 batch. but verifier should drop every span batch. + verifier.ActL1HeadSignal(t) + verifier.ActL2PipelineFull(t) + require.Equal(t, uint64(1), verifier.SyncStatus().SafeL2.L1Origin.Number) + + verifCl := verifEngine.EthClient() + for i := int64(1); i < int64(verifier.L2Safe().Number); i++ { + block, _ := verifCl.BlockByNumber(t.Ctx(), big.NewInt(i)) + require.NoError(t, err) + // because verifier drops every span batch, it should generate empty blocks. + // so every block has only L1 attribute deposit transaction. + require.Equal(t, block.Transactions().Len(), 1) + } + // check that the tx from alice is not included in verifier's chain + _, _, err = verifCl.TransactionByHash(t.Ctx(), tx.Hash()) + require.ErrorIs(t, err, ethereum.NotFound) +} + +// TestAcceptSingularBatchAfterHardfork tests behavior of op-node after SpanBatch hardfork. +// op-node must accept SingularBatch after SpanBatch hardfork. +func TestAcceptSingularBatchAfterHardfork(gt *testing.T) { + t := NewDefaultTesting(gt) + p := &e2eutils.TestParams{ + MaxSequencerDrift: 20, // larger than L1 block time we simulate in this test (12) + SequencerWindowSize: 24, + ChannelTimeout: 20, + L1BlockTime: 12, + } + minTs := hexutil.Uint64(0) + dp := e2eutils.MakeDeployParams(t, p) + + // activate SpanBatch hardfork for verifier. + dp.DeployConfig.L2GenesisSpanBatchTimeOffset = &minTs + sd := e2eutils.Setup(t, dp, defaultAlloc) + log := testlog.Logger(t, log.LvlError) + miner, seqEngine, sequencer := setupSequencerTest(t, sd, log) + verifEngine, verifier := setupVerifier(t, sd, log, miner.L1Client(t, sd.RollupCfg), &sync.Config{}) + + rollupSeqCl := sequencer.RollupClient() + dp2 := e2eutils.MakeDeployParams(t, p) + + // not activate SpanBatch hardfork for batcher + dp2.DeployConfig.L2GenesisSpanBatchTimeOffset = nil + sd2 := e2eutils.Setup(t, dp2, defaultAlloc) + batcher := NewL2Batcher(log, sd2.RollupCfg, &BatcherCfg{ + MinL1TxSize: 0, + MaxL1TxSize: 128_000, + BatcherKey: dp.Secrets.Batcher, + }, rollupSeqCl, miner.EthClient(), seqEngine.EthClient(), seqEngine.EngineClient(t, sd.RollupCfg)) + + // Alice makes a L2 tx + cl := seqEngine.EthClient() + n, err := cl.PendingNonceAt(t.Ctx(), dp.Addresses.Alice) + require.NoError(t, err) + signer := types.LatestSigner(sd.L2Cfg.Config) + tx := types.MustSignNewTx(dp.Secrets.Alice, signer, &types.DynamicFeeTx{ + ChainID: sd.L2Cfg.Config.ChainID, + Nonce: n, + GasTipCap: big.NewInt(2 * params.GWei), + GasFeeCap: new(big.Int).Add(miner.l1Chain.CurrentBlock().BaseFee, big.NewInt(2*params.GWei)), + Gas: params.TxGas, + To: &dp.Addresses.Bob, + Value: e2eutils.Ether(2), + }) + require.NoError(gt, cl.SendTransaction(t.Ctx(), tx)) + + sequencer.ActL2PipelineFull(t) + verifier.ActL2PipelineFull(t) + + // Make L2 block + sequencer.ActL2StartBlock(t) + seqEngine.ActL2IncludeTx(dp.Addresses.Alice)(t) + sequencer.ActL2EndBlock(t) + + // batch submit to L1. batcher should submit singular batches. + batcher.ActL2BatchBuffer(t) + batcher.ActL2ChannelClose(t) + batcher.ActL2BatchSubmit(t) + + // confirm batch on L1 + miner.ActL1StartBlock(12)(t) + miner.ActL1IncludeTx(dp.Addresses.Batcher)(t) + miner.ActL1EndBlock(t) + bl := miner.l1Chain.CurrentBlock() + log.Info("bl", "txs", len(miner.l1Chain.GetBlockByHash(bl.Hash()).Transactions())) + + // Now make enough L1 blocks that the verifier will have to derive a L2 block + // It will also eagerly derive the block from the batcher + for i := uint64(0); i < sd.RollupCfg.SeqWindowSize; i++ { + miner.ActL1StartBlock(12)(t) + miner.ActL1EndBlock(t) + } + + // sync verifier from L1 batch in otherwise empty sequence window + verifier.ActL1HeadSignal(t) + verifier.ActL2PipelineFull(t) + require.Equal(t, uint64(1), verifier.SyncStatus().SafeL2.L1Origin.Number) + + // check that the tx from alice made it into the L2 chain + verifCl := verifEngine.EthClient() + vTx, isPending, err := verifCl.TransactionByHash(t.Ctx(), tx.Hash()) + require.NoError(t, err) + require.False(t, isPending) + require.NotNil(t, vTx) +} + +// TestSpanBatchEmptyChain tests derivation of empty chain using SpanBatch. +func TestSpanBatchEmptyChain(gt *testing.T) { + t := NewDefaultTesting(gt) + p := &e2eutils.TestParams{ + MaxSequencerDrift: 20, + SequencerWindowSize: 24, + ChannelTimeout: 20, + L1BlockTime: 12, + } + dp := e2eutils.MakeDeployParams(t, p) + minTs := hexutil.Uint64(0) + // Activate SpanBatch hardfork + dp.DeployConfig.L2GenesisSpanBatchTimeOffset = &minTs + sd := e2eutils.Setup(t, dp, defaultAlloc) + log := testlog.Logger(t, log.LvlError) + miner, seqEngine, sequencer := setupSequencerTest(t, sd, log) + _, verifier := setupVerifier(t, sd, log, miner.L1Client(t, sd.RollupCfg), &sync.Config{}) + + rollupSeqCl := sequencer.RollupClient() + batcher := NewL2Batcher(log, sd.RollupCfg, &BatcherCfg{ + MinL1TxSize: 0, + MaxL1TxSize: 128_000, + BatcherKey: dp.Secrets.Batcher, + }, rollupSeqCl, miner.EthClient(), seqEngine.EthClient(), seqEngine.EngineClient(t, sd.RollupCfg)) + + sequencer.ActL2PipelineFull(t) + verifier.ActL2PipelineFull(t) + + miner.ActEmptyBlock(t) + // Make 1200 empty L2 blocks (L1BlockTime / L2BlockTime * 100) + for i := 0; i < 100; i++ { + sequencer.ActL1HeadSignal(t) + sequencer.ActBuildToL1Head(t) + + if i%10 == 9 { + // batch submit to L1 + batcher.ActSubmitAll(t) + + // confirm batch on L1 + miner.ActL1StartBlock(12)(t) + miner.ActL1IncludeTx(dp.Addresses.Batcher)(t) + miner.ActL1EndBlock(t) + } else { + miner.ActEmptyBlock(t) + } + } + sequencer.ActL1HeadSignal(t) + sequencer.ActL2PipelineFull(t) + + verifier.ActL1HeadSignal(t) + verifier.ActL2PipelineFull(t) + + require.Equal(t, sequencer.L2Unsafe(), sequencer.L2Safe()) + require.Equal(t, verifier.L2Unsafe(), verifier.L2Safe()) + require.Equal(t, sequencer.L2Safe(), verifier.L2Safe()) +} + +// TestSpanBatchLowThroughputChain tests derivation of low-throughput chain using SpanBatch. +func TestSpanBatchLowThroughputChain(gt *testing.T) { + t := NewDefaultTesting(gt) + p := &e2eutils.TestParams{ + MaxSequencerDrift: 20, + SequencerWindowSize: 24, + ChannelTimeout: 20, + L1BlockTime: 12, + } + dp := e2eutils.MakeDeployParams(t, p) + minTs := hexutil.Uint64(0) + // Activate SpanBatch hardfork + dp.DeployConfig.L2GenesisSpanBatchTimeOffset = &minTs + sd := e2eutils.Setup(t, dp, defaultAlloc) + log := testlog.Logger(t, log.LvlError) + miner, seqEngine, sequencer := setupSequencerTest(t, sd, log) + _, verifier := setupVerifier(t, sd, log, miner.L1Client(t, sd.RollupCfg), &sync.Config{}) + + rollupSeqCl := sequencer.RollupClient() + batcher := NewL2Batcher(log, sd.RollupCfg, &BatcherCfg{ + MinL1TxSize: 0, + MaxL1TxSize: 128_000, + BatcherKey: dp.Secrets.Batcher, + }, rollupSeqCl, miner.EthClient(), seqEngine.EthClient(), seqEngine.EngineClient(t, sd.RollupCfg)) + cl := seqEngine.EthClient() + + const numTestUsers = 5 + var privKeys [numTestUsers]*ecdsa.PrivateKey + var addrs [numTestUsers]common.Address + for i := 0; i < numTestUsers; i++ { + // Create a new test account + privateKey, err := dp.Secrets.Wallet.PrivateKey(accounts.Account{ + URL: accounts.URL{ + Path: fmt.Sprintf("m/44'/60'/0'/0/%d", 10+i), + }, + }) + privKeys[i] = privateKey + addr := crypto.PubkeyToAddress(privateKey.PublicKey) + require.NoError(t, err) + addrs[i] = addr + } + + sequencer.ActL2PipelineFull(t) + verifier.ActL2PipelineFull(t) + + miner.ActEmptyBlock(t) + totalTxCount := 0 + // Make 600 L2 blocks (L1BlockTime / L2BlockTime * 50) including 1~3 txs + for i := 0; i < 50; i++ { + sequencer.ActL1HeadSignal(t) + for sequencer.derivation.UnsafeL2Head().L1Origin.Number < sequencer.l1State.L1Head().Number { + sequencer.ActL2PipelineFull(t) + sequencer.ActL2StartBlock(t) + // fill the block with random number of L2 txs + for j := 0; j < rand.Intn(3); j++ { + userIdx := totalTxCount % numTestUsers + signer := types.LatestSigner(sd.L2Cfg.Config) + data := make([]byte, rand.Intn(100)) + _, err := crand.Read(data[:]) // fill with random bytes + require.NoError(t, err) + gas, err := core.IntrinsicGas(data, nil, false, true, true, false) + require.NoError(t, err) + baseFee := seqEngine.l2Chain.CurrentBlock().BaseFee + nonce, err := cl.PendingNonceAt(t.Ctx(), addrs[userIdx]) + require.NoError(t, err) + tx := types.MustSignNewTx(privKeys[userIdx], signer, &types.DynamicFeeTx{ + ChainID: sd.L2Cfg.Config.ChainID, + Nonce: nonce, + GasTipCap: big.NewInt(2 * params.GWei), + GasFeeCap: new(big.Int).Add(new(big.Int).Mul(baseFee, big.NewInt(2)), big.NewInt(2*params.GWei)), + Gas: gas, + To: &dp.Addresses.Bob, + Value: big.NewInt(0), + Data: data, + }) + require.NoError(gt, cl.SendTransaction(t.Ctx(), tx)) + seqEngine.ActL2IncludeTx(addrs[userIdx])(t) + totalTxCount += 1 + } + sequencer.ActL2EndBlock(t) + } + + if i%10 == 9 { + // batch submit to L1 + batcher.ActSubmitAll(t) + + // confirm batch on L1 + miner.ActL1StartBlock(12)(t) + miner.ActL1IncludeTx(dp.Addresses.Batcher)(t) + miner.ActL1EndBlock(t) + } else { + miner.ActEmptyBlock(t) + } + } + sequencer.ActL1HeadSignal(t) + sequencer.ActL2PipelineFull(t) + + verifier.ActL1HeadSignal(t) + verifier.ActL2PipelineFull(t) + + require.Equal(t, sequencer.L2Unsafe(), sequencer.L2Safe()) + require.Equal(t, verifier.L2Unsafe(), verifier.L2Safe()) + require.Equal(t, sequencer.L2Safe(), verifier.L2Safe()) +} diff --git a/op-e2e/actions/sync_test.go b/op-e2e/actions/sync_test.go index 07321859579fb..387daf343dc88 100644 --- a/op-e2e/actions/sync_test.go +++ b/op-e2e/actions/sync_test.go @@ -2,21 +2,56 @@ package actions import ( "errors" + "math/big" "math/rand" "testing" + "github.com/ethereum-optimism/optimism/op-batcher/compressor" "github.com/ethereum-optimism/optimism/op-e2e/e2eutils" + "github.com/ethereum-optimism/optimism/op-node/rollup/derive" "github.com/ethereum-optimism/optimism/op-node/rollup/sync" "github.com/ethereum-optimism/optimism/op-service/eth" "github.com/ethereum-optimism/optimism/op-service/sources" "github.com/ethereum-optimism/optimism/op-service/testlog" + "github.com/ethereum-optimism/optimism/op-service/testutils" + + "github.com/ethereum/go-ethereum/common/hexutil" + "github.com/ethereum/go-ethereum/core" + "github.com/ethereum/go-ethereum/core/types" "github.com/ethereum/go-ethereum/log" + "github.com/ethereum/go-ethereum/params" "github.com/stretchr/testify/require" ) -func TestDerivationWithFlakyL1RPC(gt *testing.T) { +// TestSyncBatchType run each sync test case in singular batch mode and span batch mode. +func TestSyncBatchType(t *testing.T) { + tests := []struct { + name string + f func(gt *testing.T, spanBatchTimeOffset *hexutil.Uint64) + }{ + {"DerivationWithFlakyL1RPC", DerivationWithFlakyL1RPC}, + {"FinalizeWhileSyncing", FinalizeWhileSyncing}, + } + for _, test := range tests { + test := test + t.Run(test.name+"_SingularBatch", func(t *testing.T) { + test.f(t, nil) + }) + } + + spanBatchTimeOffset := hexutil.Uint64(0) + for _, test := range tests { + test := test + t.Run(test.name+"_SpanBatch", func(t *testing.T) { + test.f(t, &spanBatchTimeOffset) + }) + } +} + +func DerivationWithFlakyL1RPC(gt *testing.T, spanBatchTimeOffset *hexutil.Uint64) { t := NewDefaultTesting(gt) dp := e2eutils.MakeDeployParams(t, defaultRollupTestParams) + dp.DeployConfig.L2GenesisSpanBatchTimeOffset = spanBatchTimeOffset sd := e2eutils.Setup(t, dp, defaultAlloc) log := testlog.Logger(t, log.LvlError) // mute all the temporary derivation errors that we forcefully create _, _, miner, sequencer, _, verifier, _, batcher := setupReorgTestActors(t, dp, sd, log) @@ -53,9 +88,10 @@ func TestDerivationWithFlakyL1RPC(gt *testing.T) { require.Equal(t, sequencer.L2Unsafe(), verifier.L2Safe(), "verifier is synced") } -func TestFinalizeWhileSyncing(gt *testing.T) { +func FinalizeWhileSyncing(gt *testing.T, spanBatchTimeOffset *hexutil.Uint64) { t := NewDefaultTesting(gt) dp := e2eutils.MakeDeployParams(t, defaultRollupTestParams) + dp.DeployConfig.L2GenesisSpanBatchTimeOffset = spanBatchTimeOffset sd := e2eutils.Setup(t, dp, defaultAlloc) log := testlog.Logger(t, log.LvlError) // mute all the temporary derivation errors that we forcefully create _, _, miner, sequencer, _, verifier, _, batcher := setupReorgTestActors(t, dp, sd, log) @@ -166,3 +202,232 @@ func TestEngineP2PSync(gt *testing.T) { require.Equal(t, sequencer.L2Unsafe().Hash, verifier.EngineSyncTarget().Hash) } } + +func TestInvalidPayloadInSpanBatch(gt *testing.T) { + t := NewDefaultTesting(gt) + dp := e2eutils.MakeDeployParams(t, defaultRollupTestParams) + minTs := hexutil.Uint64(0) + // Activate SpanBatch hardfork + dp.DeployConfig.L2GenesisSpanBatchTimeOffset = &minTs + dp.DeployConfig.L2BlockTime = 2 + sd := e2eutils.Setup(t, dp, defaultAlloc) + log := testlog.Logger(t, log.LvlInfo) + _, _, miner, sequencer, seqEng, verifier, _, batcher := setupReorgTestActors(t, dp, sd, log) + l2Cl := seqEng.EthClient() + rng := rand.New(rand.NewSource(1234)) + signer := types.LatestSigner(sd.L2Cfg.Config) + + sequencer.ActL2PipelineFull(t) + verifier.ActL2PipelineFull(t) + + c, e := compressor.NewRatioCompressor(compressor.Config{ + TargetFrameSize: 128_000, + TargetNumFrames: 1, + ApproxComprRatio: 1, + }) + require.NoError(t, e) + spanBatchBuilder := derive.NewSpanBatchBuilder(sd.RollupCfg.Genesis.L2Time, sd.RollupCfg.L2ChainID) + // Create new span batch channel + channelOut, err := derive.NewChannelOut(derive.SpanBatchType, c, spanBatchBuilder) + require.NoError(t, err) + + // Create block A1 ~ A12 for L1 block #0 ~ #2 + miner.ActEmptyBlock(t) + miner.ActEmptyBlock(t) + sequencer.ActL1HeadSignal(t) + sequencer.ActBuildToL1HeadUnsafe(t) + + for i := uint64(1); i <= sequencer.L2Unsafe().Number; i++ { + block, err := l2Cl.BlockByNumber(t.Ctx(), new(big.Int).SetUint64(i)) + require.NoError(t, err) + if i == 8 { + // Make block A8 as an invalid block + invalidTx := testutils.RandomTx(rng, big.NewInt(100), signer) + block = block.WithBody([]*types.Transaction{block.Transactions()[0], invalidTx}, []*types.Header{}) + } + // Add A1 ~ A12 into the channel + _, err = channelOut.AddBlock(block) + require.NoError(t, err) + } + + // Submit span batch(A1, ..., A7, invalid A8, A9, ..., A12) + batcher.l2ChannelOut = channelOut + batcher.ActL2ChannelClose(t) + batcher.ActL2BatchSubmit(t) + + miner.ActL1StartBlock(12)(t) + miner.ActL1IncludeTx(dp.Addresses.Batcher)(t) + miner.ActL1EndBlock(t) + miner.ActL1SafeNext(t) + miner.ActL1FinalizeNext(t) + + // After the verifier processed the span batch, only unsafe head should be advanced to A7. + // Safe head is not updated because the span batch is not fully processed. + verifier.ActL1HeadSignal(t) + verifier.ActL2PipelineFull(t) + require.Equal(t, verifier.L2Unsafe().Number, uint64(7)) + require.Equal(t, verifier.L2Safe().Number, uint64(0)) + + // Create new span batch channel + c, e = compressor.NewRatioCompressor(compressor.Config{ + TargetFrameSize: 128_000, + TargetNumFrames: 1, + ApproxComprRatio: 1, + }) + require.NoError(t, e) + spanBatchBuilder = derive.NewSpanBatchBuilder(sd.RollupCfg.Genesis.L2Time, sd.RollupCfg.L2ChainID) + channelOut, err = derive.NewChannelOut(derive.SpanBatchType, c, spanBatchBuilder) + require.NoError(t, err) + + for i := uint64(1); i <= sequencer.L2Unsafe().Number; i++ { + block, err := l2Cl.BlockByNumber(t.Ctx(), new(big.Int).SetUint64(i)) + require.NoError(t, err) + if i == 1 { + // Create valid TX + aliceNonce, err := seqEng.EthClient().PendingNonceAt(t.Ctx(), dp.Addresses.Alice) + require.NoError(t, err) + data := make([]byte, rand.Intn(100)) + gas, err := core.IntrinsicGas(data, nil, false, true, true, false) + require.NoError(t, err) + baseFee := seqEng.l2Chain.CurrentBlock().BaseFee + tx := types.MustSignNewTx(dp.Secrets.Alice, signer, &types.DynamicFeeTx{ + ChainID: sd.L2Cfg.Config.ChainID, + Nonce: aliceNonce, + GasTipCap: big.NewInt(2 * params.GWei), + GasFeeCap: new(big.Int).Add(new(big.Int).Mul(baseFee, big.NewInt(2)), big.NewInt(2*params.GWei)), + Gas: gas, + To: &dp.Addresses.Bob, + Value: big.NewInt(0), + Data: data, + }) + // Create valid new block B1 at the same height as A1 + block = block.WithBody([]*types.Transaction{block.Transactions()[0], tx}, []*types.Header{}) + } + // Add B1, A2 ~ A12 into the channel + _, err = channelOut.AddBlock(block) + require.NoError(t, err) + } + // Submit span batch(B1, A2, ... A12) + batcher.l2ChannelOut = channelOut + batcher.ActL2ChannelClose(t) + batcher.ActL2BatchSubmit(t) + + miner.ActL1StartBlock(12)(t) + miner.ActL1IncludeTx(dp.Addresses.Batcher)(t) + miner.ActL1EndBlock(t) + miner.ActL1SafeNext(t) + miner.ActL1FinalizeNext(t) + + verifier.ActL1HeadSignal(t) + verifier.ActL2PipelineFull(t) + + // verifier should advance its unsafe and safe head to the height of A12. + require.Equal(t, verifier.L2Unsafe().Number, uint64(12)) + require.Equal(t, verifier.L2Safe().Number, uint64(12)) +} + +func TestSpanBatchAtomicity_Consolidation(gt *testing.T) { + t := NewDefaultTesting(gt) + dp := e2eutils.MakeDeployParams(t, defaultRollupTestParams) + minTs := hexutil.Uint64(0) + // Activate SpanBatch hardfork + dp.DeployConfig.L2GenesisSpanBatchTimeOffset = &minTs + dp.DeployConfig.L2BlockTime = 2 + sd := e2eutils.Setup(t, dp, defaultAlloc) + log := testlog.Logger(t, log.LvlInfo) + _, _, miner, sequencer, seqEng, verifier, _, batcher := setupReorgTestActors(t, dp, sd, log) + seqEngCl, err := sources.NewEngineClient(seqEng.RPCClient(), log, nil, sources.EngineClientDefaultConfig(sd.RollupCfg)) + require.NoError(t, err) + + targetHeadNumber := uint64(6) // L1 block time / L2 block time + + sequencer.ActL2PipelineFull(t) + verifier.ActL2PipelineFull(t) + + // Create 6 blocks + miner.ActEmptyBlock(t) + sequencer.ActL1HeadSignal(t) + sequencer.ActBuildToL1HeadUnsafe(t) + require.Equal(t, sequencer.L2Unsafe().Number, targetHeadNumber) + + // Gossip unsafe blocks to the verifier + for i := uint64(1); i <= sequencer.L2Unsafe().Number; i++ { + seqHead, err := seqEngCl.PayloadByNumber(t.Ctx(), i) + require.NoError(t, err) + verifier.ActL2UnsafeGossipReceive(seqHead)(t) + } + verifier.ActL2PipelineFull(t) + + // Check if the verifier's unsafe sync is done + require.Equal(t, sequencer.L2Unsafe().Hash, verifier.L2Unsafe().Hash) + + // Build and submit a span batch with 6 blocks + batcher.ActSubmitAll(t) + miner.ActL1StartBlock(12)(t) + miner.ActL1IncludeTx(dp.Addresses.Batcher)(t) + miner.ActL1EndBlock(t) + + // Start verifier safe sync + verifier.ActL1HeadSignal(t) + verifier.l2PipelineIdle = false + for !verifier.l2PipelineIdle { + verifier.ActL2PipelineStep(t) + if verifier.L2PendingSafe().Number < targetHeadNumber { + // If the span batch is not fully processed, the safe head must not advance. + require.Equal(t, verifier.L2Safe().Number, uint64(0)) + } else { + // Once the span batch is fully processed, the safe head must advance to the end of span batch. + require.Equal(t, verifier.L2Safe().Number, targetHeadNumber) + require.Equal(t, verifier.L2Safe(), verifier.L2PendingSafe()) + } + // The unsafe head must not be changed + require.Equal(t, verifier.L2Unsafe(), sequencer.L2Unsafe()) + } +} + +func TestSpanBatchAtomicity_ForceAdvance(gt *testing.T) { + t := NewDefaultTesting(gt) + dp := e2eutils.MakeDeployParams(t, defaultRollupTestParams) + minTs := hexutil.Uint64(0) + // Activate SpanBatch hardfork + dp.DeployConfig.L2GenesisSpanBatchTimeOffset = &minTs + dp.DeployConfig.L2BlockTime = 2 + sd := e2eutils.Setup(t, dp, defaultAlloc) + log := testlog.Logger(t, log.LvlInfo) + _, _, miner, sequencer, _, verifier, _, batcher := setupReorgTestActors(t, dp, sd, log) + + targetHeadNumber := uint64(6) // L1 block time / L2 block time + + sequencer.ActL2PipelineFull(t) + verifier.ActL2PipelineFull(t) + require.Equal(t, verifier.L2Unsafe().Number, uint64(0)) + + // Create 6 blocks + miner.ActEmptyBlock(t) + sequencer.ActL1HeadSignal(t) + sequencer.ActBuildToL1HeadUnsafe(t) + require.Equal(t, sequencer.L2Unsafe().Number, targetHeadNumber) + + // Build and submit a span batch with 6 blocks + batcher.ActSubmitAll(t) + miner.ActL1StartBlock(12)(t) + miner.ActL1IncludeTx(dp.Addresses.Batcher)(t) + miner.ActL1EndBlock(t) + + // Start verifier safe sync + verifier.ActL1HeadSignal(t) + verifier.l2PipelineIdle = false + for !verifier.l2PipelineIdle { + verifier.ActL2PipelineStep(t) + if verifier.L2PendingSafe().Number < targetHeadNumber { + // If the span batch is not fully processed, the safe head must not advance. + require.Equal(t, verifier.L2Safe().Number, uint64(0)) + } else { + // Once the span batch is fully processed, the safe head must advance to the end of span batch. + require.Equal(t, verifier.L2Safe().Number, targetHeadNumber) + require.Equal(t, verifier.L2Safe(), verifier.L2PendingSafe()) + } + // The unsafe head and the pending safe head must be the same + require.Equal(t, verifier.L2Unsafe(), verifier.L2PendingSafe()) + } +} diff --git a/op-e2e/actions/system_config_test.go b/op-e2e/actions/system_config_test.go index 4d4563c90e1b9..6d0e24bf6c2fa 100644 --- a/op-e2e/actions/system_config_test.go +++ b/op-e2e/actions/system_config_test.go @@ -7,6 +7,7 @@ import ( "github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/common/hexutil" "github.com/ethereum/go-ethereum/core/types" "github.com/ethereum/go-ethereum/log" "github.com/stretchr/testify/require" @@ -19,13 +20,40 @@ import ( "github.com/ethereum-optimism/optimism/op-service/testlog" ) -// TestBatcherKeyRotation tests that batcher A can operate, then be replaced with batcher B, then ignore old batcher A, +// TestSystemConfigBatchType run each system config-related test case in singular batch mode and span batch mode. +func TestSystemConfigBatchType(t *testing.T) { + tests := []struct { + name string + f func(gt *testing.T, spanBatchTimeOffset *hexutil.Uint64) + }{ + {"BatcherKeyRotation", BatcherKeyRotation}, + {"GPOParamsChange", GPOParamsChange}, + {"GasLimitChange", GasLimitChange}, + } + for _, test := range tests { + test := test + t.Run(test.name+"_SingularBatch", func(t *testing.T) { + test.f(t, nil) + }) + } + + spanBatchTimeOffset := hexutil.Uint64(0) + for _, test := range tests { + test := test + t.Run(test.name+"_SpanBatch", func(t *testing.T) { + test.f(t, &spanBatchTimeOffset) + }) + } +} + +// BatcherKeyRotation tests that batcher A can operate, then be replaced with batcher B, then ignore old batcher A, // and that the change to batcher B is reverted properly upon reorg of L1. -func TestBatcherKeyRotation(gt *testing.T) { +func BatcherKeyRotation(gt *testing.T, spanBatchTimeOffset *hexutil.Uint64) { t := NewDefaultTesting(gt) dp := e2eutils.MakeDeployParams(t, defaultRollupTestParams) dp.DeployConfig.L2BlockTime = 2 + dp.DeployConfig.L2GenesisSpanBatchTimeOffset = spanBatchTimeOffset sd := e2eutils.Setup(t, dp, defaultAlloc) log := testlog.Logger(t, log.LvlDebug) miner, seqEngine, sequencer := setupSequencerTest(t, sd, log) @@ -39,14 +67,14 @@ func TestBatcherKeyRotation(gt *testing.T) { MinL1TxSize: 0, MaxL1TxSize: 128_000, BatcherKey: dp.Secrets.Batcher, - }, rollupSeqCl, miner.EthClient(), seqEngine.EthClient()) + }, rollupSeqCl, miner.EthClient(), seqEngine.EthClient(), seqEngine.EngineClient(t, sd.RollupCfg)) // a batcher with a new key batcherB := NewL2Batcher(log, sd.RollupCfg, &BatcherCfg{ MinL1TxSize: 0, MaxL1TxSize: 128_000, BatcherKey: dp.Secrets.Bob, - }, rollupSeqCl, miner.EthClient(), seqEngine.EthClient()) + }, rollupSeqCl, miner.EthClient(), seqEngine.EthClient(), seqEngine.EngineClient(t, sd.RollupCfg)) sequencer.ActL2PipelineFull(t) verifier.ActL2PipelineFull(t) @@ -80,7 +108,7 @@ func TestBatcherKeyRotation(gt *testing.T) { require.Equal(t, dp.Addresses.SysCfgOwner, owner, "system config owner mismatch") // Change the batch sender key to Bob! - tx, err := sysCfgContract.SetBatcherHash(sysCfgOwner, dp.Addresses.Bob.Hash()) + tx, err := sysCfgContract.SetBatcherHash(sysCfgOwner, eth.AddressAsLeftPaddedHash(dp.Addresses.Bob)) require.NoError(t, err) t.Logf("batcher changes in L1 tx %s", tx.Hash()) miner.ActL1StartBlock(12)(t) @@ -198,11 +226,12 @@ func TestBatcherKeyRotation(gt *testing.T) { require.Equal(t, sequencer.L2Unsafe(), verifier.L2Unsafe(), "verifier synced") } -// TestGPOParamsChange tests that the GPO params can be updated to adjust fees of L2 transactions, +// GPOParamsChange tests that the GPO params can be updated to adjust fees of L2 transactions, // and that the L1 data fees to the L2 transaction are applied correctly before, during and after the GPO update in L2. -func TestGPOParamsChange(gt *testing.T) { +func GPOParamsChange(gt *testing.T, spanBatchTimeOffset *hexutil.Uint64) { t := NewDefaultTesting(gt) dp := e2eutils.MakeDeployParams(t, defaultRollupTestParams) + dp.DeployConfig.L2GenesisSpanBatchTimeOffset = spanBatchTimeOffset sd := e2eutils.Setup(t, dp, defaultAlloc) log := testlog.Logger(t, log.LvlDebug) miner, seqEngine, sequencer := setupSequencerTest(t, sd, log) @@ -210,7 +239,7 @@ func TestGPOParamsChange(gt *testing.T) { MinL1TxSize: 0, MaxL1TxSize: 128_000, BatcherKey: dp.Secrets.Batcher, - }, sequencer.RollupClient(), miner.EthClient(), seqEngine.EthClient()) + }, sequencer.RollupClient(), miner.EthClient(), seqEngine.EthClient(), seqEngine.EngineClient(t, sd.RollupCfg)) alice := NewBasicUser[any](log, dp.Secrets.Alice, rand.New(rand.NewSource(1234))) alice.SetUserEnv(&BasicUserEnv[any]{ @@ -326,12 +355,13 @@ func TestGPOParamsChange(gt *testing.T) { require.Equal(t, "2.3", receipt.FeeScalar.String(), "2_300_000 divided by 6 decimals = float(2.3)") } -// TestGasLimitChange tests that the gas limit can be configured to L1, +// GasLimitChange tests that the gas limit can be configured to L1, // and that the L2 changes the gas limit instantly at the exact block that adopts the L1 origin with // the gas limit change event. And checks if a verifier node can reproduce the same gas limit change. -func TestGasLimitChange(gt *testing.T) { +func GasLimitChange(gt *testing.T, spanBatchTimeOffset *hexutil.Uint64) { t := NewDefaultTesting(gt) dp := e2eutils.MakeDeployParams(t, defaultRollupTestParams) + dp.DeployConfig.L2GenesisSpanBatchTimeOffset = spanBatchTimeOffset sd := e2eutils.Setup(t, dp, defaultAlloc) log := testlog.Logger(t, log.LvlDebug) miner, seqEngine, sequencer := setupSequencerTest(t, sd, log) @@ -339,7 +369,7 @@ func TestGasLimitChange(gt *testing.T) { MinL1TxSize: 0, MaxL1TxSize: 128_000, BatcherKey: dp.Secrets.Batcher, - }, sequencer.RollupClient(), miner.EthClient(), seqEngine.EthClient()) + }, sequencer.RollupClient(), miner.EthClient(), seqEngine.EthClient(), seqEngine.EngineClient(t, sd.RollupCfg)) sequencer.ActL2PipelineFull(t) miner.ActEmptyBlock(t) diff --git a/op-e2e/actions/tx_helper.go b/op-e2e/actions/tx_helper.go new file mode 100644 index 0000000000000..e63c1a2248223 --- /dev/null +++ b/op-e2e/actions/tx_helper.go @@ -0,0 +1,49 @@ +package actions + +import ( + "context" + "math/big" + "time" + + "github.com/ethereum-optimism/optimism/op-e2e/e2eutils/wait" + "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/core/types" + "github.com/stretchr/testify/require" +) + +// firstValidTx finds the first transaction that is valid for inclusion from the specified address. +// It uses a waiter and filtering of already included transactions to avoid race conditions with the async +// updates to the transaction pool. +func firstValidTx( + t Testing, + from common.Address, + pendingIndices func(common.Address) uint64, + contentFrom func(common.Address) ([]*types.Transaction, []*types.Transaction), + nonceAt func(context.Context, common.Address, *big.Int) (uint64, error), +) *types.Transaction { + var i uint64 + var txs []*types.Transaction + var q []*types.Transaction + // Wait for the tx to be in the pending tx queue + ctx, cancel := context.WithTimeout(context.Background(), 30*time.Second) + defer cancel() + err := wait.For(ctx, time.Second, func() (bool, error) { + i = pendingIndices(from) + txs, q = contentFrom(from) + // Remove any transactions that have already been included in the head block + // The tx pool only prunes included transactions async so they may still be in the list + nonce, err := nonceAt(ctx, from, nil) + if err != nil { + return false, err + } + for len(txs) > 0 && txs[0].Nonce() < nonce { + t.Logf("Removing already included transaction from list of length %v", len(txs)) + txs = txs[1:] + } + return uint64(len(txs)) > i, nil + }) + require.NoError(t, err, + "no pending txs from %s, and have %d unprocessable queued txs from this account: %w", from, len(q), err) + + return txs[i] +} diff --git a/op-e2e/actions/user_test.go b/op-e2e/actions/user_test.go index c63918cdaec1a..34171696f72a7 100644 --- a/op-e2e/actions/user_test.go +++ b/op-e2e/actions/user_test.go @@ -13,10 +13,12 @@ import ( "github.com/ethereum-optimism/optimism/op-service/testlog" ) -type regolithScheduledTest struct { - name string - regolithTime *hexutil.Uint64 - activateRegolith bool +type hardforkScheduledTest struct { + name string + regolithTime *hexutil.Uint64 + spanBatchTime *hexutil.Uint64 + activateRegolith bool + activateSpanBatch bool } // TestCrossLayerUser tests that common actions of the CrossLayerUser actor work in various regolith configurations: @@ -31,11 +33,18 @@ func TestCrossLayerUser(t *testing.T) { zeroTime := hexutil.Uint64(0) futureTime := hexutil.Uint64(20) farFutureTime := hexutil.Uint64(2000) - tests := []regolithScheduledTest{ - {name: "NoRegolith", regolithTime: nil, activateRegolith: false}, - {name: "NotYetRegolith", regolithTime: &farFutureTime, activateRegolith: false}, - {name: "RegolithAtGenesis", regolithTime: &zeroTime, activateRegolith: true}, - {name: "RegolithAfterGenesis", regolithTime: &futureTime, activateRegolith: true}, + tests := []hardforkScheduledTest{ + {name: "NoRegolith", regolithTime: nil, activateRegolith: false, spanBatchTime: nil, activateSpanBatch: false}, + {name: "NotYetRegolith", regolithTime: &farFutureTime, activateRegolith: false, spanBatchTime: nil, activateSpanBatch: false}, + {name: "RegolithAtGenesis", regolithTime: &zeroTime, activateRegolith: true, spanBatchTime: nil, activateSpanBatch: false}, + {name: "RegolithAfterGenesis", regolithTime: &futureTime, activateRegolith: true, spanBatchTime: nil, activateSpanBatch: false}, + {name: "NoSpanBatch", regolithTime: &zeroTime, activateRegolith: true, spanBatchTime: nil, activateSpanBatch: false}, + {name: "NotYetSpanBatch", regolithTime: &zeroTime, activateRegolith: true, + spanBatchTime: &farFutureTime, activateSpanBatch: false}, + {name: "SpanBatchAtGenesis", regolithTime: &zeroTime, activateRegolith: true, + spanBatchTime: &zeroTime, activateSpanBatch: true}, + {name: "SpanBatchAfterGenesis", regolithTime: &zeroTime, activateRegolith: true, + spanBatchTime: &futureTime, activateSpanBatch: true}, } for _, test := range tests { test := test // Use a fixed reference as the tests run in parallel @@ -45,10 +54,11 @@ func TestCrossLayerUser(t *testing.T) { } } -func runCrossLayerUserTest(gt *testing.T, test regolithScheduledTest) { +func runCrossLayerUserTest(gt *testing.T, test hardforkScheduledTest) { t := NewDefaultTesting(gt) dp := e2eutils.MakeDeployParams(t, defaultRollupTestParams) dp.DeployConfig.L2GenesisRegolithTimeOffset = test.regolithTime + dp.DeployConfig.L2GenesisSpanBatchTimeOffset = test.spanBatchTime sd := e2eutils.Setup(t, dp, defaultAlloc) log := testlog.Logger(t, log.LvlDebug) @@ -60,7 +70,7 @@ func runCrossLayerUserTest(gt *testing.T, test regolithScheduledTest) { MinL1TxSize: 0, MaxL1TxSize: 128_000, BatcherKey: dp.Secrets.Batcher, - }, seq.RollupClient(), miner.EthClient(), seqEngine.EthClient()) + }, seq.RollupClient(), miner.EthClient(), seqEngine.EthClient(), seqEngine.EngineClient(t, sd.RollupCfg)) proposer := NewL2Proposer(t, log, &ProposerCfg{ OutputOracleAddr: sd.DeploymentsL1.L2OutputOracleProxy, ProposerKey: dp.Secrets.Proposer, diff --git a/op-e2e/e2eutils/challenger/helper.go b/op-e2e/e2eutils/challenger/helper.go index 6b32324ace680..fd5bb9a77e511 100644 --- a/op-e2e/e2eutils/challenger/helper.go +++ b/op-e2e/e2eutils/challenger/helper.go @@ -42,9 +42,6 @@ func WithFactoryAddress(addr common.Address) Option { func WithGameAddress(addr common.Address) Option { return func(c *config.Config) { - if c.GameAllowlist == nil { - c.GameAllowlist = make([]common.Address, 0) - } c.GameAllowlist = append(c.GameAllowlist, addr) } } @@ -63,7 +60,7 @@ func WithAgreeProposedOutput(agree bool) Option { func WithAlphabet(alphabet string) Option { return func(c *config.Config) { - c.TraceType = config.TraceTypeAlphabet + c.TraceTypes = append(c.TraceTypes, config.TraceTypeAlphabet) c.AlphabetTrace = alphabet } } @@ -82,7 +79,7 @@ func WithCannon( ) Option { return func(c *config.Config) { require := require.New(t) - c.TraceType = config.TraceTypeCannon + c.TraceTypes = append(c.TraceTypes, config.TraceTypeCannon) c.CannonL2 = l2Endpoint c.CannonBin = "../cannon/bin/cannon" c.CannonServer = "../op-program/bin/op-program" @@ -126,7 +123,7 @@ func NewChallenger(t *testing.T, ctx context.Context, l1Endpoint string, name st func NewChallengerConfig(t *testing.T, l1Endpoint string, options ...Option) *config.Config { // Use the NewConfig method to ensure we pick up any defaults that are set. - cfg := config.NewConfig(common.Address{}, l1Endpoint, config.TraceTypeAlphabet, true, t.TempDir()) + cfg := config.NewConfig(common.Address{}, l1Endpoint, true, t.TempDir()) cfg.TxMgrConfig.NumConfirmations = 1 cfg.TxMgrConfig.ReceiptQueryInterval = 1 * time.Second if cfg.MaxConcurrency > 4 { diff --git a/op-e2e/e2eutils/disputegame/alphabet_helper.go b/op-e2e/e2eutils/disputegame/alphabet_helper.go index a03d1aaac1856..8c179034e1ada 100644 --- a/op-e2e/e2eutils/disputegame/alphabet_helper.go +++ b/op-e2e/e2eutils/disputegame/alphabet_helper.go @@ -3,11 +3,8 @@ package disputegame import ( "context" - "github.com/ethereum-optimism/optimism/op-challenger/config" "github.com/ethereum-optimism/optimism/op-challenger/game/fault/trace/alphabet" "github.com/ethereum-optimism/optimism/op-e2e/e2eutils/challenger" - - "github.com/ethereum/go-ethereum/common" ) type AlphabetGameHelper struct { @@ -17,15 +14,12 @@ type AlphabetGameHelper struct { func (g *AlphabetGameHelper) StartChallenger(ctx context.Context, l1Endpoint string, name string, options ...challenger.Option) *challenger.Helper { opts := []challenger.Option{ - func(c *config.Config) { - c.GameFactoryAddress = g.factoryAddr - c.GameAllowlist = []common.Address{g.addr} - c.TraceType = config.TraceTypeAlphabet - // By default the challenger agrees with the root claim (thus disagrees with the proposed output) - // This can be overridden by passing in options - c.AlphabetTrace = g.claimedAlphabet - c.AgreeWithProposedOutput = false - }, + challenger.WithFactoryAddress(g.factoryAddr), + challenger.WithGameAddress(g.addr), + // By default the challenger agrees with the root claim (thus disagrees with the proposed output) + // This can be overridden by passing in options + challenger.WithAlphabet(g.claimedAlphabet), + challenger.WithAgreeProposedOutput(false), } opts = append(opts, options...) c := challenger.NewChallenger(g.t, ctx, l1Endpoint, name, opts...) diff --git a/op-e2e/e2eutils/disputegame/cannon_helper.go b/op-e2e/e2eutils/disputegame/cannon_helper.go index 8f633acec30a1..a9bbd16ec991a 100644 --- a/op-e2e/e2eutils/disputegame/cannon_helper.go +++ b/op-e2e/e2eutils/disputegame/cannon_helper.go @@ -4,13 +4,15 @@ import ( "context" "path/filepath" + "github.com/ethereum-optimism/optimism/op-challenger/game/fault/contracts" "github.com/ethereum-optimism/optimism/op-challenger/game/fault/trace/cannon" "github.com/ethereum-optimism/optimism/op-challenger/metrics" "github.com/ethereum-optimism/optimism/op-e2e/e2eutils/challenger" "github.com/ethereum-optimism/optimism/op-node/rollup" + "github.com/ethereum-optimism/optimism/op-service/sources/batching" "github.com/ethereum-optimism/optimism/op-service/testlog" - "github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/core" + "github.com/ethereum/go-ethereum/ethclient" "github.com/ethereum/go-ethereum/log" ) @@ -32,7 +34,7 @@ func (g *CannonGameHelper) StartChallenger(ctx context.Context, rollupCfg *rollu return c } -func (g *CannonGameHelper) CreateHonestActor(ctx context.Context, rollupCfg *rollup.Config, l2Genesis *core.Genesis, l1Client bind.ContractCaller, l1Endpoint string, l2Endpoint string, options ...challenger.Option) *HonestHelper { +func (g *CannonGameHelper) CreateHonestActor(ctx context.Context, rollupCfg *rollup.Config, l2Genesis *core.Genesis, l1Client *ethclient.Client, l1Endpoint string, l2Endpoint string, options ...challenger.Option) *HonestHelper { opts := []challenger.Option{ challenger.WithCannon(g.t, rollupCfg, l2Genesis, l2Endpoint), challenger.WithFactoryAddress(g.factoryAddr), @@ -42,7 +44,9 @@ func (g *CannonGameHelper) CreateHonestActor(ctx context.Context, rollupCfg *rol cfg := challenger.NewChallengerConfig(g.t, l1Endpoint, opts...) logger := testlog.Logger(g.t, log.LvlInfo).New("role", "CorrectTrace") maxDepth := g.MaxDepth(ctx) - provider, err := cannon.NewTraceProvider(ctx, logger, metrics.NoopMetrics, cfg, l1Client, filepath.Join(cfg.Datadir, "honest"), g.addr, uint64(maxDepth)) + gameContract, err := contracts.NewFaultDisputeGameContract(g.addr, batching.NewMultiCaller(l1Client.Client(), batching.DefaultBatchSize)) + g.require.NoError(err, "Create game contract bindings") + provider, err := cannon.NewTraceProvider(ctx, logger, metrics.NoopMetrics, cfg, gameContract, filepath.Join(cfg.Datadir, "honest"), uint64(maxDepth)) g.require.NoError(err, "create cannon trace provider") return &HonestHelper{ diff --git a/op-e2e/e2eutils/disputegame/dishonest_helper.go b/op-e2e/e2eutils/disputegame/dishonest_helper.go index fde8b817843eb..6b6f1912c18e5 100644 --- a/op-e2e/e2eutils/disputegame/dishonest_helper.go +++ b/op-e2e/e2eutils/disputegame/dishonest_helper.go @@ -3,6 +3,7 @@ package disputegame import ( "context" "errors" + "time" "github.com/ethereum-optimism/optimism/op-challenger/game/fault/types" "github.com/ethereum/go-ethereum/common" @@ -96,7 +97,9 @@ func (d *DishonestHelper) ExhaustDishonestClaims(ctx context.Context) { var numClaimsSeen int64 for { - newCount, err := d.WaitForNewClaim(ctx, numClaimsSeen) + // Use a short timeout since we don't know the challenger will respond, + // and this is only designed for the alphabet game where the response should be fast. + newCount, err := d.waitForNewClaim(ctx, numClaimsSeen, 30*time.Second) if errors.Is(err, context.DeadlineExceeded) { // we assume that the honest challenger has stopped responding // There's nothing to respond to. diff --git a/op-e2e/e2eutils/disputegame/game_helper.go b/op-e2e/e2eutils/disputegame/game_helper.go index 14279aa00f833..5e8a1fcb1a009 100644 --- a/op-e2e/e2eutils/disputegame/game_helper.go +++ b/op-e2e/e2eutils/disputegame/game_helper.go @@ -8,7 +8,6 @@ import ( "time" "github.com/ethereum-optimism/optimism/op-bindings/bindings" - "github.com/ethereum-optimism/optimism/op-challenger/game/fault" "github.com/ethereum-optimism/optimism/op-challenger/game/fault/types" "github.com/ethereum-optimism/optimism/op-e2e/e2eutils/wait" "github.com/ethereum/go-ethereum/accounts/abi/bind" @@ -18,6 +17,8 @@ import ( "github.com/stretchr/testify/require" ) +const defaultTimeout = 5 * time.Minute + type FaultGameHelper struct { t *testing.T require *require.Assertions @@ -42,7 +43,7 @@ func (g *FaultGameHelper) GameDuration(ctx context.Context) time.Duration { // This does not check that the number of claims is exactly the specified count to avoid intermittent failures // where a challenger posts an additional claim before this method sees the number of claims it was waiting for. func (g *FaultGameHelper) WaitForClaimCount(ctx context.Context, count int64) { - ctx, cancel := context.WithTimeout(ctx, 2*time.Minute) + ctx, cancel := context.WithTimeout(ctx, defaultTimeout) defer cancel() err := wait.For(ctx, time.Second, func() (bool, error) { actual, err := g.game.ClaimDataLen(&bind.CallOpts{Context: ctx}) @@ -70,7 +71,7 @@ func (g *FaultGameHelper) MaxDepth(ctx context.Context) int64 { } func (g *FaultGameHelper) waitForClaim(ctx context.Context, errorMsg string, predicate func(claim ContractClaim) bool) { - timedCtx, cancel := context.WithTimeout(ctx, 2*time.Minute) + timedCtx, cancel := context.WithTimeout(ctx, defaultTimeout) defer cancel() err := wait.For(timedCtx, time.Second, func() (bool, error) { count, err := g.game.ClaimDataLen(&bind.CallOpts{Context: timedCtx}) @@ -95,7 +96,7 @@ func (g *FaultGameHelper) waitForClaim(ctx context.Context, errorMsg string, pre } func (g *FaultGameHelper) waitForNoClaim(ctx context.Context, errorMsg string, predicate func(claim ContractClaim) bool) { - timedCtx, cancel := context.WithTimeout(ctx, 3*time.Minute) + timedCtx, cancel := context.WithTimeout(ctx, defaultTimeout) defer cancel() err := wait.For(timedCtx, time.Second, func() (bool, error) { count, err := g.game.ClaimDataLen(&bind.CallOpts{Context: timedCtx}) @@ -193,7 +194,7 @@ func (g *FaultGameHelper) Status(ctx context.Context) Status { func (g *FaultGameHelper) WaitForGameStatus(ctx context.Context, expected Status) { g.t.Logf("Waiting for game %v to have status %v", g.addr, expected) - timedCtx, cancel := context.WithTimeout(ctx, time.Minute) + timedCtx, cancel := context.WithTimeout(ctx, defaultTimeout) defer cancel() err := wait.For(timedCtx, time.Second, func() (bool, error) { ctx, cancel := context.WithTimeout(timedCtx, 30*time.Second) @@ -302,7 +303,10 @@ func (g *FaultGameHelper) ChallengeRootClaim(ctx context.Context, performMove Mo } func (g *FaultGameHelper) WaitForNewClaim(ctx context.Context, checkPoint int64) (int64, error) { - timedCtx, cancel := context.WithTimeout(ctx, 2*time.Minute) + return g.waitForNewClaim(ctx, checkPoint, defaultTimeout) +} +func (g *FaultGameHelper) waitForNewClaim(ctx context.Context, checkPoint int64, timeout time.Duration) (int64, error) { + timedCtx, cancel := context.WithTimeout(ctx, timeout) defer cancel() var newClaimLen int64 err := wait.For(timedCtx, time.Second, func() (bool, error) { @@ -351,25 +355,6 @@ func (g *FaultGameHelper) ResolveClaim(ctx context.Context, claimIdx int64) { g.require.NoError(err, "ResolveClaim transaction was not OK") } -// ResolveAllClaims resolves all subgames -// This function does not resolve the game. That's the responsibility of challengers -func (g *FaultGameHelper) ResolveAllClaims(ctx context.Context) { - loader := fault.NewLoader(g.game) - claims, err := loader.FetchClaims(ctx) - g.require.NoError(err, "Failed to fetch claims") - subgames := make(map[int]bool) - for i := len(claims) - 1; i > 0; i-- { - subgames[claims[i].ParentContractIndex] = true - // Subgames containing only one node are implicitly resolved - // i.e. uncountered and claims at MAX_DEPTH - if !subgames[i] { - continue - } - g.ResolveClaim(ctx, int64(i)) - } - g.ResolveClaim(ctx, 0) -} - func (g *FaultGameHelper) gameData(ctx context.Context) string { opts := &bind.CallOpts{Context: ctx} maxDepth := int(g.MaxDepth(ctx)) diff --git a/op-e2e/e2eutils/geth/fakepos.go b/op-e2e/e2eutils/geth/fakepos.go index 081a5b838d570..51ec48eb15d6a 100644 --- a/op-e2e/e2eutils/geth/fakepos.go +++ b/op-e2e/e2eutils/geth/fakepos.go @@ -1,9 +1,9 @@ package geth import ( + "math/rand" "time" - "github.com/ethereum-optimism/optimism/op-service/clock" "github.com/ethereum/go-ethereum" "github.com/ethereum/go-ethereum/beacon/engine" "github.com/ethereum/go-ethereum/common" @@ -12,6 +12,9 @@ import ( "github.com/ethereum/go-ethereum/eth/catalyst" "github.com/ethereum/go-ethereum/event" "github.com/ethereum/go-ethereum/log" + + "github.com/ethereum-optimism/optimism/op-service/clock" + "github.com/ethereum-optimism/optimism/op-service/testutils" ) // fakePoS is a testing-only utility to attach to Geth, @@ -22,6 +25,8 @@ type fakePoS struct { log log.Logger blockTime uint64 + withdrawalsIndex uint64 + finalizedDistance uint64 safeDistance uint64 @@ -33,6 +38,7 @@ func (f *fakePoS) Start() error { if advancing, ok := f.clock.(*clock.AdvancingClock); ok { advancing.Start() } + withdrawalsRNG := rand.New(rand.NewSource(450368975843)) // avoid generating the same address as any test f.sub = event.NewSubscription(func(quit <-chan struct{}) error { // poll every half a second: enough to catch up with any block time when ticks are missed t := f.clock.NewTicker(time.Second / 2) @@ -64,6 +70,17 @@ func (f *fakePoS) Start() error { // We're a long way behind, let's skip some blocks... newBlockTime = uint64(f.clock.Now().Unix()) } + // create some random withdrawals + withdrawals := make([]*types.Withdrawal, withdrawalsRNG.Intn(4)) + for i := 0; i < len(withdrawals); i++ { + withdrawals[i] = &types.Withdrawal{ + Index: f.withdrawalsIndex + uint64(i), + Validator: withdrawalsRNG.Uint64() % 100_000_000, // 100 million fake validators + Address: testutils.RandomAddress(withdrawalsRNG), + // in gwei, consensus-layer quirk. withdraw non-zero value up to 50 ETH + Amount: uint64(withdrawalsRNG.Intn(50_000_000_000) + 1), + } + } res, err := f.engineAPI.ForkchoiceUpdatedV2(engine.ForkchoiceStateV1{ HeadBlockHash: head.Hash(), SafeBlockHash: safe.Hash(), @@ -72,7 +89,7 @@ func (f *fakePoS) Start() error { Timestamp: newBlockTime, Random: common.Hash{}, SuggestedFeeRecipient: head.Coinbase, - Withdrawals: make([]*types.Withdrawal, 0), + Withdrawals: withdrawals, }) if err != nil { f.log.Error("failed to start building L1 block", "err", err) @@ -109,6 +126,10 @@ func (f *fakePoS) Start() error { f.log.Error("failed to make built L1 block canonical", "err", err) continue } + // Increment global withdrawals index in the CL. + // The EL doesn't really care about the value, + // but it's nice to mock something consistent with the CL specs. + f.withdrawalsIndex += uint64(len(withdrawals)) case <-quit: return nil } diff --git a/op-e2e/e2eutils/setup.go b/op-e2e/e2eutils/setup.go index b097f0cb9c8b9..050cde7983fc5 100644 --- a/op-e2e/e2eutils/setup.go +++ b/op-e2e/e2eutils/setup.go @@ -58,7 +58,7 @@ func MakeDeployParams(t require.TestingT, tp *TestParams) *DeployParams { deployConfig.ChannelTimeout = tp.ChannelTimeout deployConfig.L1BlockTime = tp.L1BlockTime deployConfig.L2GenesisRegolithTimeOffset = nil - deployConfig.L2GenesisSpanBatchTimeOffset = SpanBatchTimeOffset() + deployConfig.L2GenesisCanyonTimeOffset = CanyonTimeOffset() require.NoError(t, deployConfig.Check()) require.Equal(t, addresses.Batcher, deployConfig.BatchSenderAddress) @@ -157,6 +157,7 @@ func Setup(t require.TestingT, deployParams *DeployParams, alloc *AllocParams) * DepositContractAddress: deployConf.OptimismPortalProxy, L1SystemConfigAddress: deployConf.SystemConfigProxy, RegolithTime: deployConf.RegolithTime(uint64(deployConf.L1GenesisBlockTimestamp)), + CanyonTime: deployConf.CanyonTime(uint64(deployConf.L1GenesisBlockTimestamp)), SpanBatchTime: deployConf.SpanBatchTime(uint64(deployConf.L1GenesisBlockTimestamp)), } @@ -184,8 +185,8 @@ func SystemConfigFromDeployConfig(deployConfig *genesis.DeployConfig) eth.System } } -func SpanBatchTimeOffset() *hexutil.Uint64 { - if os.Getenv("OP_E2E_USE_SPAN_BATCH") == "true" { +func CanyonTimeOffset() *hexutil.Uint64 { + if os.Getenv("OP_E2E_USE_CANYON") == "true" { offset := hexutil.Uint64(0) return &offset } diff --git a/op-e2e/e2eutils/wait/blocks.go b/op-e2e/e2eutils/wait/blocks.go index dd6ef178cd413..066b16df6884e 100644 --- a/op-e2e/e2eutils/wait/blocks.go +++ b/op-e2e/e2eutils/wait/blocks.go @@ -6,6 +6,8 @@ import ( "math/big" "time" + "github.com/ethereum-optimism/optimism/op-service/eth" + "github.com/ethereum-optimism/optimism/op-service/sources" "github.com/ethereum/go-ethereum/core/types" ) @@ -57,3 +59,12 @@ func ForNextBlock(ctx context.Context, client BlockCaller) error { } return ForBlock(ctx, client, current+1) } + +func ForProcessingFullBatch(ctx context.Context, rollupCl *sources.RollupClient) error { + _, err := AndGet(ctx, time.Second, func() (*eth.SyncStatus, error) { + return rollupCl.SyncStatus(ctx) + }, func(syncStatus *eth.SyncStatus) bool { + return syncStatus.PendingSafeL2 == syncStatus.SafeL2 + }) + return err +} diff --git a/op-e2e/external.go b/op-e2e/external.go index aaeaa4448184e..0efdf4deb600e 100644 --- a/op-e2e/external.go +++ b/op-e2e/external.go @@ -2,6 +2,7 @@ package op_e2e import ( "encoding/json" + "errors" "math/big" "os" "os/exec" @@ -51,6 +52,11 @@ func (eec *ExternalEthClient) Close() error { select { case <-time.After(5 * time.Second): eec.Session.Kill() + select { + case <-time.After(30 * time.Second): + return errors.New("external client failed to terminate") + case <-eec.Session.Exited: + } case <-eec.Session.Exited: } return nil diff --git a/op-e2e/faultproof_test.go b/op-e2e/faultproof_test.go index 8ed8a13fff997..7857fbbee0f7e 100644 --- a/op-e2e/faultproof_test.go +++ b/op-e2e/faultproof_test.go @@ -2,9 +2,12 @@ package op_e2e import ( "context" + "math/big" "testing" "time" + "github.com/ethereum-optimism/optimism/op-challenger/game/fault/trace/alphabet" + "github.com/ethereum-optimism/optimism/op-challenger/game/fault/types" "github.com/ethereum-optimism/optimism/op-e2e/e2eutils/challenger" "github.com/ethereum-optimism/optimism/op-e2e/e2eutils/disputegame" l2oo2 "github.com/ethereum-optimism/optimism/op-e2e/e2eutils/l2oo" @@ -15,7 +18,7 @@ import ( ) func TestMultipleCannonGames(t *testing.T) { - InitParallel(t) + InitParallel(t, UsesCannon, UseExecutor(0)) ctx := context.Background() sys, l1Client := startFaultDisputeSystem(t) @@ -74,8 +77,43 @@ func TestMultipleCannonGames(t *testing.T) { challenger.WaitForGameDataDeletion(ctx, game1, game2) } +func TestMultipleGameTypes(t *testing.T) { + InitParallel(t, UsesCannon, UseExecutor(0)) + + ctx := context.Background() + sys, l1Client := startFaultDisputeSystem(t) + t.Cleanup(sys.Close) + + gameFactory := disputegame.NewFactoryHelper(t, ctx, sys.cfg.L1Deployments, l1Client) + // Start a challenger with both cannon and alphabet support + gameFactory.StartChallenger(ctx, sys.NodeEndpoint("l1"), "TowerDefense", + challenger.WithCannon(t, sys.RollupConfig, sys.L2GenesisCfg, sys.NodeEndpoint("sequencer")), + challenger.WithAlphabet(disputegame.CorrectAlphabet), + challenger.WithPrivKey(sys.cfg.Secrets.Alice), + challenger.WithAgreeProposedOutput(true), + ) + + game1 := gameFactory.StartCannonGame(ctx, common.Hash{0x01, 0xaa}) + game2 := gameFactory.StartAlphabetGame(ctx, "xyzabc") + + // Wait for the challenger to respond to both games + game1.WaitForClaimCount(ctx, 2) + game2.WaitForClaimCount(ctx, 2) + game1Response := game1.GetClaimValue(ctx, 1) + game2Response := game2.GetClaimValue(ctx, 1) + // The alphabet game always posts the same traces, so if they're different they can't both be from the alphabet. + require.NotEqual(t, game1Response, game2Response, "should have posted different claims") + // Now check they aren't both just from different cannon games by confirming the alphabet value. + correctAlphabet := alphabet.NewTraceProvider(disputegame.CorrectAlphabet, uint64(game2.MaxDepth(ctx))) + expectedClaim, err := correctAlphabet.Get(ctx, types.NewPositionFromGIndex(big.NewInt(1)).Attack()) + require.NoError(t, err) + require.Equal(t, expectedClaim, game2Response) + // We don't confirm the cannon value because generating the correct claim is expensive + // Just being different is enough to confirm the challenger isn't just playing two alphabet games incorrectly +} + func TestChallengerCompleteDisputeGame(t *testing.T) { - InitParallel(t) + InitParallel(t, UseExecutor(1)) tests := []struct { name string @@ -144,7 +182,7 @@ func TestChallengerCompleteDisputeGame(t *testing.T) { for _, test := range tests { test := test t.Run(test.name, func(t *testing.T) { - InitParallel(t) + InitParallel(t, UseExecutor(1)) ctx := context.Background() sys, l1Client := startFaultDisputeSystem(t) @@ -181,7 +219,7 @@ func TestChallengerCompleteDisputeGame(t *testing.T) { } func TestChallengerCompleteExhaustiveDisputeGame(t *testing.T) { - InitParallel(t) + InitParallel(t, UseExecutor(1)) testCase := func(t *testing.T, isRootCorrect bool) { ctx := context.Background() @@ -229,17 +267,17 @@ func TestChallengerCompleteExhaustiveDisputeGame(t *testing.T) { } t.Run("RootCorrect", func(t *testing.T) { - InitParallel(t) + InitParallel(t, UseExecutor(1)) testCase(t, true) }) t.Run("RootIncorrect", func(t *testing.T) { - InitParallel(t) + InitParallel(t, UseExecutor(1)) testCase(t, false) }) } func TestCannonDisputeGame(t *testing.T) { - InitParallel(t) + InitParallel(t, UsesCannon, UseExecutor(1)) tests := []struct { name string @@ -252,7 +290,7 @@ func TestCannonDisputeGame(t *testing.T) { for _, test := range tests { test := test t.Run(test.name, func(t *testing.T) { - InitParallel(t) + InitParallel(t, UseExecutor(1)) ctx := context.Background() sys, l1Client := startFaultDisputeSystem(t) @@ -290,7 +328,7 @@ func TestCannonDisputeGame(t *testing.T) { } func TestCannonDefendStep(t *testing.T) { - InitParallel(t) + InitParallel(t, UsesCannon, UseExecutor(1)) ctx := context.Background() sys, l1Client := startFaultDisputeSystem(t) @@ -332,7 +370,7 @@ func TestCannonDefendStep(t *testing.T) { } func TestCannonProposedOutputRootInvalid(t *testing.T) { - InitParallel(t) + InitParallel(t, UsesCannon, UseExecutor(0)) // honestStepsFail attempts to perform both an attack and defend step using the correct trace. honestStepsFail := func(ctx context.Context, game *disputegame.CannonGameHelper, correctTrace *disputegame.HonestHelper, parentClaimIdx int64) { // Attack step should fail @@ -383,7 +421,7 @@ func TestCannonProposedOutputRootInvalid(t *testing.T) { for _, test := range tests { test := test t.Run(test.name, func(t *testing.T) { - InitParallel(t) + InitParallel(t, UseExecutor(0)) ctx := context.Background() sys, l1Client, game, correctTrace := setupDisputeGameForInvalidOutputRoot(t, test.outputRoot) @@ -410,7 +448,7 @@ func TestCannonProposedOutputRootInvalid(t *testing.T) { } func TestCannonPoisonedPostState(t *testing.T) { - InitParallel(t) + InitParallel(t, UsesCannon, UseExecutor(0)) ctx := context.Background() sys, l1Client := startFaultDisputeSystem(t) @@ -520,8 +558,7 @@ func setupDisputeGameForInvalidOutputRoot(t *testing.T, outputRoot common.Hash) } func TestCannonChallengeWithCorrectRoot(t *testing.T) { - InitParallel(t) - + InitParallel(t, UsesCannon, UseExecutor(0)) ctx := context.Background() sys, l1Client := startFaultDisputeSystem(t) t.Cleanup(sys.Close) diff --git a/op-e2e/helper.go b/op-e2e/helper.go index 04f5a4c0feac6..3c8d411b12925 100644 --- a/op-e2e/helper.go +++ b/op-e2e/helper.go @@ -2,14 +2,70 @@ package op_e2e import ( "os" + "strconv" "testing" ) var enableParallelTesting bool = os.Getenv("OP_E2E_DISABLE_PARALLEL") != "true" -func InitParallel(t *testing.T) { +type testopts struct { + executor uint64 +} + +func InitParallel(t *testing.T, args ...func(t *testing.T, opts *testopts)) { t.Helper() if enableParallelTesting { t.Parallel() } + + opts := &testopts{} + for _, arg := range args { + arg(t, opts) + } + checkExecutor(t, opts.executor) +} + +func UsesCannon(t *testing.T, opts *testopts) { + if os.Getenv("OP_E2E_CANNON_ENABLED") == "false" { + t.Skip("Skipping cannon test") + } +} + +// UseExecutor allows manually splitting tests between circleci executors +// +// Tests default to run on the first executor but can be moved to the second with: +// InitParallel(t, UseExecutor(1)) +// Any tests assigned to an executor greater than the number available automatically use the last executor. +// Executor indexes start from 0 +func UseExecutor(assignedIdx uint64) func(t *testing.T, opts *testopts) { + return func(t *testing.T, opts *testopts) { + opts.executor = assignedIdx + } +} + +func checkExecutor(t *testing.T, assignedIdx uint64) { + envTotal := os.Getenv("CIRCLE_NODE_TOTAL") + envIdx := os.Getenv("CIRCLE_NODE_INDEX") + if envTotal == "" || envIdx == "" { + // Not using test splitting, so ignore assigned executor + t.Logf("Running test. Test splitting not in use.") + return + } + total, err := strconv.ParseUint(envTotal, 10, 0) + if err != nil { + t.Fatalf("Could not parse CIRCLE_NODE_TOTAL env var %v: %v", envTotal, err) + } + idx, err := strconv.ParseUint(envIdx, 10, 0) + if err != nil { + t.Fatalf("Could not parse CIRCLE_NODE_INDEX env var %v: %v", envIdx, err) + } + if assignedIdx >= total && idx == total-1 { + t.Logf("Running test. Current executor (%v) is the last executor and assigned executor (%v) >= total executors (%v).", idx, assignedIdx, total) + return + } + if idx == assignedIdx { + t.Logf("Running test. Assigned executor (%v) matches current executor (%v) of total (%v)", assignedIdx, idx, total) + return + } + t.Skipf("Skipping test. Assigned executor %v, current executor %v of total %v", assignedIdx, idx, total) } diff --git a/op-e2e/op_geth.go b/op-e2e/op_geth.go index f9c3058eb3a88..6b7eef31b48b8 100644 --- a/op-e2e/op_geth.go +++ b/op-e2e/op_geth.go @@ -102,10 +102,10 @@ func NewOpGeth(t *testing.T, ctx context.Context, cfg *SystemConfig) (*OpGeth, e ) require.Nil(t, err) - l2Client, err := ethclient.Dial(node.HTTPEndpoint()) + l2Client, err := ethclient.Dial(selectEndpoint(node)) require.Nil(t, err) - genesisPayload, err := eth.BlockAsPayload(l2GenesisBlock) + genesisPayload, err := eth.BlockAsPayload(l2GenesisBlock, cfg.DeployConfig.CanyonTime(l2GenesisBlock.Time())) require.Nil(t, err) return &OpGeth{ @@ -209,11 +209,18 @@ func (d *OpGeth) CreatePayloadAttributes(txs ...*types.Transaction) (*eth.Payloa } txBytes = append(txBytes, bin) } + + var withdrawals *types.Withdrawals + if d.L2ChainConfig.IsCanyon(uint64(timestamp)) { + withdrawals = &types.Withdrawals{} + } + attrs := eth.PayloadAttributes{ Timestamp: timestamp, Transactions: txBytes, NoTxPool: true, GasLimit: (*eth.Uint64Quantity)(&d.SystemConfig.GasLimit), + Withdrawals: withdrawals, } return &attrs, nil } diff --git a/op-e2e/op_geth_test.go b/op-e2e/op_geth_test.go index ef931d284aaed..230e99914ee05 100644 --- a/op-e2e/op_geth_test.go +++ b/op-e2e/op_geth_test.go @@ -2,12 +2,13 @@ package op_e2e import ( "context" + "fmt" "math/big" "testing" "time" - "github.com/stretchr/testify/require" - + "github.com/ethereum-optimism/optimism/op-node/rollup/derive" + "github.com/ethereum-optimism/optimism/op-service/eth" "github.com/ethereum/go-ethereum" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common/hexutil" @@ -16,9 +17,8 @@ import ( "github.com/ethereum/go-ethereum/core/vm" "github.com/ethereum/go-ethereum/crypto" "github.com/ethereum/go-ethereum/params" - - "github.com/ethereum-optimism/optimism/op-node/rollup/derive" - "github.com/ethereum-optimism/optimism/op-service/eth" + "github.com/stretchr/testify/assert" + "github.com/stretchr/testify/require" ) // TestMissingGasLimit tests that op-geth cannot build a block without gas limit while optimism is active in the chain config. @@ -719,3 +719,145 @@ func TestRegolith(t *testing.T) { }) } } + +func TestPreCanyon(t *testing.T) { + InitParallel(t) + futureTimestamp := hexutil.Uint64(4) + + tests := []struct { + name string + canyonTime *hexutil.Uint64 + }{ + {name: "CanyonNotScheduled"}, + {name: "CanyonNotYetActive", canyonTime: &futureTimestamp}, + } + for _, test := range tests { + test := test + + t.Run(fmt.Sprintf("ReturnsNilWithdrawals_%s", test.name), func(t *testing.T) { + InitParallel(t) + cfg := DefaultSystemConfig(t) + cfg.DeployConfig.L2GenesisCanyonTimeOffset = test.canyonTime + + ctx, cancel := context.WithTimeout(context.Background(), 60*time.Second) + defer cancel() + + opGeth, err := NewOpGeth(t, ctx, &cfg) + require.NoError(t, err) + defer opGeth.Close() + + b, err := opGeth.AddL2Block(ctx) + require.NoError(t, err) + assert.Nil(t, b.Withdrawals, "should not have withdrawals") + + l1Block, err := opGeth.L2Client.BlockByNumber(ctx, nil) + require.Nil(t, err) + assert.Equal(t, types.Withdrawals(nil), l1Block.Withdrawals()) + }) + + t.Run(fmt.Sprintf("RejectPushZeroTx_%s", test.name), func(t *testing.T) { + InitParallel(t) + cfg := DefaultSystemConfig(t) + cfg.DeployConfig.L2GenesisCanyonTimeOffset = test.canyonTime + + ctx, cancel := context.WithTimeout(context.Background(), 60*time.Second) + defer cancel() + + opGeth, err := NewOpGeth(t, ctx, &cfg) + require.NoError(t, err) + defer opGeth.Close() + + pushZeroContractCreateTxn := types.NewTx(&types.DepositTx{ + From: cfg.Secrets.Addresses().Alice, + Value: big.NewInt(params.Ether), + Gas: 1000001, + Data: []byte{ + byte(vm.PUSH0), + }, + IsSystemTransaction: false, + }) + + _, err = opGeth.AddL2Block(ctx, pushZeroContractCreateTxn) + require.NoError(t, err) + + receipt, err := opGeth.L2Client.TransactionReceipt(ctx, pushZeroContractCreateTxn.Hash()) + require.NoError(t, err) + assert.Equal(t, types.ReceiptStatusFailed, receipt.Status) + }) + } + +} + +func TestCanyon(t *testing.T) { + InitParallel(t) + + tests := []struct { + name string + canyonTime hexutil.Uint64 + activeCanyon func(ctx context.Context, opGeth *OpGeth) + }{ + {name: "ActivateAtGenesis", canyonTime: 0, activeCanyon: func(ctx context.Context, opGeth *OpGeth) {}}, + {name: "ActivateAfterGenesis", canyonTime: 2, activeCanyon: func(ctx context.Context, opGeth *OpGeth) { + // Adding this block advances us to the fork time. + _, err := opGeth.AddL2Block(ctx) + require.NoError(t, err) + }}, + } + for _, test := range tests { + test := test + t.Run(fmt.Sprintf("ReturnsEmptyWithdrawals_%s", test.name), func(t *testing.T) { + InitParallel(t) + cfg := DefaultSystemConfig(t) + s := hexutil.Uint64(0) + cfg.DeployConfig.L2GenesisRegolithTimeOffset = &s + cfg.DeployConfig.L2GenesisCanyonTimeOffset = &test.canyonTime + + ctx, cancel := context.WithTimeout(context.Background(), 60*time.Second) + defer cancel() + + opGeth, err := NewOpGeth(t, ctx, &cfg) + require.NoError(t, err) + defer opGeth.Close() + + test.activeCanyon(ctx, opGeth) + + b, err := opGeth.AddL2Block(ctx) + require.NoError(t, err) + assert.Equal(t, *b.Withdrawals, types.Withdrawals{}) + + l1Block, err := opGeth.L2Client.BlockByNumber(ctx, nil) + require.Nil(t, err) + assert.Equal(t, l1Block.Withdrawals(), types.Withdrawals{}) + }) + + t.Run(fmt.Sprintf("AcceptsPushZeroTxn_%s", test.name), func(t *testing.T) { + InitParallel(t) + cfg := DefaultSystemConfig(t) + cfg.DeployConfig.L2GenesisCanyonTimeOffset = &test.canyonTime + + ctx, cancel := context.WithTimeout(context.Background(), 60*time.Second) + defer cancel() + + opGeth, err := NewOpGeth(t, ctx, &cfg) + require.NoError(t, err) + defer opGeth.Close() + + pushZeroContractCreateTxn := types.NewTx(&types.DepositTx{ + From: cfg.Secrets.Addresses().Alice, + Value: big.NewInt(params.Ether), + Gas: 1000001, + Data: []byte{ + byte(vm.PUSH0), + }, + IsSystemTransaction: false, + }) + + _, err = opGeth.AddL2Block(ctx, pushZeroContractCreateTxn) + require.NoError(t, err) + + receipt, err := opGeth.L2Client.TransactionReceipt(ctx, pushZeroContractCreateTxn.Hash()) + require.NoError(t, err) + assert.Equal(t, types.ReceiptStatusSuccessful, receipt.Status) + }) + } +} diff --git a/op-e2e/setup.go b/op-e2e/setup.go index 0dd1239099704..0acd3c67b77ff 100644 --- a/op-e2e/setup.go +++ b/op-e2e/setup.go @@ -4,6 +4,7 @@ import ( "context" "crypto/ecdsa" "crypto/rand" + "errors" "fmt" "math/big" "net" @@ -37,7 +38,6 @@ import ( bss "github.com/ethereum-optimism/optimism/op-batcher/batcher" "github.com/ethereum-optimism/optimism/op-batcher/compressor" - batchermetrics "github.com/ethereum-optimism/optimism/op-batcher/metrics" "github.com/ethereum-optimism/optimism/op-bindings/predeploys" "github.com/ethereum-optimism/optimism/op-chain-ops/genesis" "github.com/ethereum-optimism/optimism/op-e2e/config" @@ -49,6 +49,7 @@ import ( "github.com/ethereum-optimism/optimism/op-node/p2p" "github.com/ethereum-optimism/optimism/op-node/p2p/store" "github.com/ethereum-optimism/optimism/op-node/rollup" + "github.com/ethereum-optimism/optimism/op-node/rollup/derive" "github.com/ethereum-optimism/optimism/op-node/rollup/driver" proposermetrics "github.com/ethereum-optimism/optimism/op-proposer/metrics" l2os "github.com/ethereum-optimism/optimism/op-proposer/proposer" @@ -71,6 +72,7 @@ func newTxMgrConfig(l1Addr string, privKey *ecdsa.PrivateKey) txmgr.CLIConfig { PrivateKey: hexPriv(privKey), NumConfirmations: 1, SafeAbortNonceTooLowCount: 3, + FeeLimitMultiplier: 5, ResubmissionTimeout: 3 * time.Second, ReceiptQueryInterval: 50 * time.Millisecond, NetworkTimeout: 2 * time.Second, @@ -85,7 +87,7 @@ func DefaultSystemConfig(t *testing.T) SystemConfig { require.NoError(t, err) deployConfig := config.DeployConfig.Copy() deployConfig.L1GenesisBlockTimestamp = hexutil.Uint64(time.Now().Unix()) - deployConfig.L2GenesisSpanBatchTimeOffset = e2eutils.SpanBatchTimeOffset() + deployConfig.L2GenesisCanyonTimeOffset = e2eutils.CanyonTimeOffset() require.NoError(t, deployConfig.Check(), "Deploy config is invalid, do you need to run make devnet-allocs?") l1Deployments := config.L1Deployments.Copy() require.NoError(t, l1Deployments.Check()) @@ -200,6 +202,9 @@ type SystemConfig struct { // Target L1 tx size for the batcher transactions BatcherTargetL1TxSizeBytes uint64 + // Max L1 tx size for the batcher transactions + BatcherMaxL1TxSizeBytes uint64 + // SupportL1TimeTravel determines if the L1 node supports quickly skipping forward in time SupportL1TimeTravel bool } @@ -252,7 +257,7 @@ type System struct { RawClients map[string]*rpc.Client RollupNodes map[string]*rollupNode.OpNode L2OutputSubmitter *l2os.L2OutputSubmitter - BatchSubmitter *bss.BatchSubmitter + BatchSubmitter *bss.BatcherService Mocknet mocknet.Mocknet // TimeTravelClock is nil unless SystemConfig.SupportL1TimeTravel was set to true @@ -268,18 +273,16 @@ func (sys *System) NodeEndpoint(name string) string { } func (sys *System) Close() { + postCtx, postCancel := context.WithCancel(context.Background()) + postCancel() // immediate shutdown, no allowance for idling + if sys.L2OutputSubmitter != nil { sys.L2OutputSubmitter.Stop() } if sys.BatchSubmitter != nil { - ctx, cancel := context.WithTimeout(context.Background(), 10*time.Second) - defer cancel() - sys.BatchSubmitter.StopIfRunning(ctx) + _ = sys.BatchSubmitter.Kill() } - postCtx, postCancel := context.WithCancel(context.Background()) - postCancel() // immediate shutdown, no allowance for idling - for _, node := range sys.RollupNodes { _ = node.Stop(postCtx) } @@ -424,6 +427,7 @@ func (cfg SystemConfig) Start(t *testing.T, _opts ...SystemConfigOption) (*Syste DepositContractAddress: cfg.DeployConfig.OptimismPortalProxy, L1SystemConfigAddress: cfg.DeployConfig.SystemConfigProxy, RegolithTime: cfg.DeployConfig.RegolithTime(uint64(cfg.DeployConfig.L1GenesisBlockTimestamp)), + CanyonTime: cfg.DeployConfig.CanyonTime(uint64(cfg.DeployConfig.L1GenesisBlockTimestamp)), SpanBatchTime: cfg.DeployConfig.SpanBatchTime(uint64(cfg.DeployConfig.L1GenesisBlockTimestamp)), ProtocolVersionsAddress: cfg.L1Deployments.ProtocolVersionsProxy, } @@ -678,14 +682,21 @@ func (cfg SystemConfig) Start(t *testing.T, _opts ...SystemConfigOption) (*Syste return nil, fmt.Errorf("unable to start l2 output submitter: %w", err) } - // Batch Submitter - sys.BatchSubmitter, err = bss.NewBatchSubmitterFromCLIConfig(bss.CLIConfig{ + var batchType uint = derive.SingularBatchType + if cfg.DeployConfig.L2GenesisSpanBatchTimeOffset != nil && *cfg.DeployConfig.L2GenesisSpanBatchTimeOffset == hexutil.Uint64(0) { + batchType = derive.SpanBatchType + } + batcherMaxL1TxSizeBytes := cfg.BatcherMaxL1TxSizeBytes + if batcherMaxL1TxSizeBytes == 0 { + batcherMaxL1TxSizeBytes = 240_000 + } + batcherCLIConfig := &bss.CLIConfig{ L1EthRpc: sys.EthInstances["l1"].WSEndpoint(), L2EthRpc: sys.EthInstances["sequencer"].WSEndpoint(), RollupRpc: sys.RollupNodes["sequencer"].HTTPEndpoint(), MaxPendingTransactions: 0, MaxChannelDuration: 1, - MaxL1TxSize: 240_000, + MaxL1TxSize: batcherMaxL1TxSizeBytes, CompressorConfig: compressor.CLIConfig{ TargetL1TxSizeBytes: cfg.BatcherTargetL1TxSizeBytes, TargetNumFrames: 1, @@ -698,17 +709,18 @@ func (cfg SystemConfig) Start(t *testing.T, _opts ...SystemConfigOption) (*Syste Level: log.LvlInfo, Format: oplog.FormatText, }, - }, sys.cfg.Loggers["batcher"], batchermetrics.NoopMetrics) + Stopped: sys.cfg.DisableBatcher, // Batch submitter may be enabled later + BatchType: batchType, + } + // Batch Submitter + batcher, err := bss.BatcherServiceFromCLIConfig(context.Background(), "0.0.1", batcherCLIConfig, sys.cfg.Loggers["batcher"]) if err != nil { return nil, fmt.Errorf("failed to setup batch submitter: %w", err) } - - // Batcher may be enabled later - if !sys.cfg.DisableBatcher { - if err := sys.BatchSubmitter.Start(); err != nil { - return nil, fmt.Errorf("unable to start batch submitter: %w", err) - } + if err := batcher.Start(context.Background()); err != nil { + return nil, errors.Join(fmt.Errorf("failed to start batch submitter: %w", err), batcher.Stop(context.Background())) } + sys.BatchSubmitter = batcher return sys, nil } @@ -758,9 +770,12 @@ func (sys *System) newMockNetPeer() (host.Host, error) { return sys.Mocknet.AddPeerWithPeerstore(p, eps) } +func UseHTTP() bool { + return os.Getenv("OP_E2E_USE_HTTP") == "true" +} + func selectEndpoint(node EthInstance) string { - useHTTP := os.Getenv("OP_E2E_USE_HTTP") == "true" - if useHTTP { + if UseHTTP() { log.Info("using HTTP client") return node.HTTPEndpoint() } @@ -772,7 +787,7 @@ func configureL1(rollupNodeCfg *rollupNode.Config, l1Node EthInstance) { rollupNodeCfg.L1 = &rollupNode.L1EndpointConfig{ L1NodeAddr: l1EndpointConfig, L1TrustRPC: false, - L1RPCKind: sources.RPCKindBasic, + L1RPCKind: sources.RPCKindStandard, RateLimit: 0, BatchSize: 20, HttpPollInterval: time.Millisecond * 100, @@ -785,9 +800,8 @@ type WSOrHTTPEndpoint interface { } func configureL2(rollupNodeCfg *rollupNode.Config, l2Node WSOrHTTPEndpoint, jwtSecret [32]byte) { - useHTTP := os.Getenv("OP_E2E_USE_HTTP") == "true" l2EndpointConfig := l2Node.WSAuthEndpoint() - if useHTTP { + if UseHTTP() { l2EndpointConfig = l2Node.HTTPAuthEndpoint() } diff --git a/op-e2e/system_fpp_test.go b/op-e2e/system_fpp_test.go index 307ede8d0bfbf..5c4d3376c0400 100644 --- a/op-e2e/system_fpp_test.go +++ b/op-e2e/system_fpp_test.go @@ -15,25 +15,42 @@ import ( "github.com/ethereum-optimism/optimism/op-service/testlog" "github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/common/hexutil" "github.com/ethereum/go-ethereum/log" "github.com/ethereum/go-ethereum/rpc" "github.com/stretchr/testify/require" ) func TestVerifyL2OutputRoot(t *testing.T) { - testVerifyL2OutputRoot(t, false) + testVerifyL2OutputRoot(t, false, false) +} + +func TestVerifyL2OutputRootSpanBatch(t *testing.T) { + testVerifyL2OutputRoot(t, false, true) } func TestVerifyL2OutputRootDetached(t *testing.T) { - testVerifyL2OutputRoot(t, true) + testVerifyL2OutputRoot(t, true, false) +} + +func TestVerifyL2OutputRootDetachedSpanBatch(t *testing.T) { + testVerifyL2OutputRoot(t, true, true) } func TestVerifyL2OutputRootEmptyBlock(t *testing.T) { - testVerifyL2OutputRootEmptyBlock(t, false) + testVerifyL2OutputRootEmptyBlock(t, false, false) +} + +func TestVerifyL2OutputRootEmptyBlockSpanBatch(t *testing.T) { + testVerifyL2OutputRootEmptyBlock(t, false, true) } func TestVerifyL2OutputRootEmptyBlockDetached(t *testing.T) { - testVerifyL2OutputRootEmptyBlock(t, true) + testVerifyL2OutputRootEmptyBlock(t, true, false) +} + +func TestVerifyL2OutputRootEmptyBlockDetachedSpanBatch(t *testing.T) { + testVerifyL2OutputRootEmptyBlock(t, true, true) } // TestVerifyL2OutputRootEmptyBlock asserts that the program can verify the output root of an empty block @@ -46,7 +63,7 @@ func TestVerifyL2OutputRootEmptyBlockDetached(t *testing.T) { // - reboot the batch submitter // - update the state root via a tx // - run program -func testVerifyL2OutputRootEmptyBlock(t *testing.T, detached bool) { +func testVerifyL2OutputRootEmptyBlock(t *testing.T, detached bool, spanBatchActivated bool) { InitParallel(t) ctx := context.Background() @@ -56,6 +73,13 @@ func testVerifyL2OutputRootEmptyBlock(t *testing.T, detached bool) { // Use a small sequencer window size to avoid test timeout while waiting for empty blocks // But not too small to ensure that our claim and subsequent state change is published cfg.DeployConfig.SequencerWindowSize = 16 + if spanBatchActivated { + // Activate span batch hard fork + minTs := hexutil.Uint64(0) + cfg.DeployConfig.L2GenesisSpanBatchTimeOffset = &minTs + } else { + cfg.DeployConfig.L2GenesisSpanBatchTimeOffset = nil + } sys, err := cfg.Start(t) require.Nil(t, err, "Error starting up system") @@ -93,7 +117,7 @@ func testVerifyL2OutputRootEmptyBlock(t *testing.T, detached bool) { l2OutputRoot := agreedL2Output.OutputRoot t.Log("=====Stopping batch submitter=====") - err = sys.BatchSubmitter.Stop(ctx) + err = sys.BatchSubmitter.Driver().StopBatchSubmitting(ctx) require.NoError(t, err, "could not stop batch submitter") // Wait for the sequencer to catch up with the current L1 head so we know all submitted batches are processed @@ -121,7 +145,7 @@ func testVerifyL2OutputRootEmptyBlock(t *testing.T, detached bool) { l2Claim := l2Output.OutputRoot t.Log("=====Restarting batch submitter=====") - err = sys.BatchSubmitter.Start() + err = sys.BatchSubmitter.Driver().StartBatchSubmitting() require.NoError(t, err, "could not start batch submitter") t.Log("Add a transaction to the next batch after sequence of empty blocks") @@ -147,13 +171,20 @@ func testVerifyL2OutputRootEmptyBlock(t *testing.T, detached bool) { }) } -func testVerifyL2OutputRoot(t *testing.T, detached bool) { +func testVerifyL2OutputRoot(t *testing.T, detached bool, spanBatchActivated bool) { InitParallel(t) ctx := context.Background() cfg := DefaultSystemConfig(t) // We don't need a verifier - just the sequencer is enough delete(cfg.Nodes, "verifier") + if spanBatchActivated { + // Activate span batch hard fork + minTs := hexutil.Uint64(0) + cfg.DeployConfig.L2GenesisSpanBatchTimeOffset = &minTs + } else { + cfg.DeployConfig.L2GenesisSpanBatchTimeOffset = nil + } sys, err := cfg.Start(t) require.Nil(t, err, "Error starting up system") @@ -258,7 +289,7 @@ func testFaultProofProgramScenario(t *testing.T, ctx context.Context, sys *Syste t.Log("Shutting down network") // Shutdown the nodes from the actual chain. Should now be able to run using only the pre-fetched data. - sys.BatchSubmitter.StopIfRunning(context.Background()) + require.NoError(t, sys.BatchSubmitter.Kill()) sys.L2OutputSubmitter.Stop() sys.L2OutputSubmitter = nil for _, node := range sys.EthInstances { diff --git a/op-e2e/system_test.go b/op-e2e/system_test.go index 5e943102888df..7c850b9d9d5f3 100644 --- a/op-e2e/system_test.go +++ b/op-e2e/system_test.go @@ -45,6 +45,31 @@ import ( "github.com/ethereum-optimism/optimism/op-service/testlog" ) +// TestSystemBatchType run each system e2e test case in singular batch mode and span batch mode. +// If the test case tests batch submission and advancing safe head, it should be tested in both singular and span batch mode. +func TestSystemBatchType(t *testing.T) { + tests := []struct { + name string + f func(gt *testing.T, spanBatchTimeOffset *hexutil.Uint64) + }{ + {"StopStartBatcher", StopStartBatcher}, + } + for _, test := range tests { + test := test + t.Run(test.name+"_SingularBatch", func(t *testing.T) { + test.f(t, nil) + }) + } + + spanBatchTimeOffset := hexutil.Uint64(0) + for _, test := range tests { + test := test + t.Run(test.name+"_SpanBatch", func(t *testing.T) { + test.f(t, &spanBatchTimeOffset) + }) + } +} + func TestMain(m *testing.M) { if config.ExternalL2Shim != "" { fmt.Println("Running tests with external L2 process adapter at ", config.ExternalL2Shim) @@ -491,7 +516,7 @@ func TestSystemMockP2P(t *testing.T) { verifierPeerID := sys.RollupNodes["verifier"].P2P().Host().ID() check := func() bool { - sequencerBlocksTopicPeers := sys.RollupNodes["sequencer"].P2P().GossipOut().BlocksTopicPeers() + sequencerBlocksTopicPeers := sys.RollupNodes["sequencer"].P2P().GossipOut().AllBlockTopicsPeers() return slices.Contains[[]peer.ID](sequencerBlocksTopicPeers, verifierPeerID) } @@ -592,6 +617,10 @@ func TestSystemRPCAltSync(t *testing.T) { opts.VerifyOnClients(l2Verif) }) + // Sometimes we get duplicate blocks on the sequencer which makes this test flaky + published = slices.Compact(published) + received = slices.Compact(received) + // Verify that the tx was received via RPC sync (P2P is disabled) require.Contains(t, received, eth.BlockID{Hash: receiptSeq.BlockHash, Number: receiptSeq.BlockNumber.Uint64()}.String()) @@ -1218,10 +1247,11 @@ func TestFees(t *testing.T) { require.Equal(t, balanceDiff, totalFee, "balances should add up") } -func TestStopStartBatcher(t *testing.T) { +func StopStartBatcher(t *testing.T, spanBatchTimeOffset *hexutil.Uint64) { InitParallel(t) cfg := DefaultSystemConfig(t) + cfg.DeployConfig.L2GenesisSpanBatchTimeOffset = spanBatchTimeOffset sys, err := cfg.Start(t) require.Nil(t, err, "Error starting up system") defer sys.Close() @@ -1255,6 +1285,7 @@ func TestStopStartBatcher(t *testing.T) { safeBlockInclusionDuration := time.Duration(6*cfg.DeployConfig.L1BlockTime) * time.Second _, err = geth.WaitForBlock(receipt.BlockNumber, l2Verif, safeBlockInclusionDuration) require.Nil(t, err, "Waiting for block on verifier") + require.NoError(t, wait.ForProcessingFullBatch(context.Background(), rollupClient)) // ensure the safe chain advances newSeqStatus, err := rollupClient.SyncStatus(context.Background()) @@ -1262,7 +1293,7 @@ func TestStopStartBatcher(t *testing.T) { require.Greater(t, newSeqStatus.SafeL2.Number, seqStatus.SafeL2.Number, "Safe chain did not advance") // stop the batch submission - err = sys.BatchSubmitter.Stop(context.Background()) + err = sys.BatchSubmitter.Driver().StopBatchSubmitting(context.Background()) require.Nil(t, err) // wait for any old safe blocks being submitted / derived @@ -1282,7 +1313,7 @@ func TestStopStartBatcher(t *testing.T) { require.Equal(t, newSeqStatus.SafeL2.Number, seqStatus.SafeL2.Number, "Safe chain advanced while batcher was stopped") // start the batch submission - err = sys.BatchSubmitter.Start() + err = sys.BatchSubmitter.Driver().StartBatchSubmitting() require.Nil(t, err) time.Sleep(safeBlockInclusionDuration) @@ -1292,6 +1323,7 @@ func TestStopStartBatcher(t *testing.T) { // wait until the block the tx was first included in shows up in the safe chain on the verifier _, err = geth.WaitForBlock(receipt.BlockNumber, l2Verif, safeBlockInclusionDuration) require.Nil(t, err, "Waiting for block on verifier") + require.NoError(t, wait.ForProcessingFullBatch(context.Background(), rollupClient)) // ensure that the safe chain advances after restarting the batcher newSeqStatus, err = rollupClient.SyncStatus(context.Background()) @@ -1321,7 +1353,7 @@ func TestBatcherMultiTx(t *testing.T) { require.Nil(t, err) // start batch submission - err = sys.BatchSubmitter.Start() + err = sys.BatchSubmitter.Driver().StartBatchSubmitting() require.Nil(t, err) totalTxCount := 0 @@ -1549,3 +1581,14 @@ func TestRequiredProtocolVersionChangeAndHalt(t *testing.T) { require.NoError(t, err) t.Log("verified that op-geth closed!") } + +func TestIncorrectBatcherConfiguration(t *testing.T) { + InitParallel(t) + + cfg := DefaultSystemConfig(t) + // make the batcher configuration invalid + cfg.BatcherMaxL1TxSizeBytes = 1 + + _, err := cfg.Start(t) + require.Error(t, err, "Expected error on invalid batcher configuration") +} diff --git a/op-heartbeat/Dockerfile b/op-heartbeat/Dockerfile index f1347f0a4ce36..2e3996cde666c 100644 --- a/op-heartbeat/Dockerfile +++ b/op-heartbeat/Dockerfile @@ -1,22 +1,9 @@ -FROM golang:1.21.1-alpine3.18 as builder - -RUN apk add --no-cache make gcc musl-dev linux-headers git jq bash - -# build op-heartbeat with local monorepo go modules -COPY ./op-heartbeat /app/op-heartbeat -COPY ./op-node /app/op-node -COPY ./op-service /app/op-service -COPY ./go.mod /app/go.mod -COPY ./go.sum /app/go.sum - -COPY ./.git /app/.git - -WORKDIR /app/op-heartbeat - -RUN make op-heartbeat +ARG OP_STACK_GO_BUILDER=us-docker.pkg.dev/oplabs-tools-artifacts/images/op-stack-go:latest +FROM $OP_STACK_GO_BUILDER as builder +# See "make golang-docker" and /ops/docker/op-stack-go FROM alpine:3.18 -COPY --from=builder /app/op-heartbeat/bin/op-heartbeat /usr/local/bin +COPY --from=builder /usr/local/bin/op-heartbeat /usr/local/bin/op-heartbeat CMD ["op-heartbeat"] diff --git a/op-heartbeat/Dockerfile.dockerignore b/op-heartbeat/Dockerfile.dockerignore new file mode 100644 index 0000000000000..4f26140750a08 --- /dev/null +++ b/op-heartbeat/Dockerfile.dockerignore @@ -0,0 +1,2 @@ +# ignore everything but the dockerfile, the op-stack-go base image performs the build +* diff --git a/op-heartbeat/Makefile b/op-heartbeat/Makefile index 7f1530dc17ac4..03daf6b05bec9 100644 --- a/op-heartbeat/Makefile +++ b/op-heartbeat/Makefile @@ -1,5 +1,5 @@ -GITCOMMIT := $(shell git rev-parse HEAD) -GITDATE := $(shell git show -s --format='%ct') +GITCOMMIT ?= $(shell git rev-parse HEAD) +GITDATE ?= $(shell git show -s --format='%ct') VERSION := v0.0.0 LDFLAGSSTRING +=-X main.GitCommit=$(GITCOMMIT) @@ -16,9 +16,6 @@ clean: test: go test -v ./... -lint: - golangci-lint run -E goimports,sqlclosecheck,bodyclose,asciicheck,misspell,errorlint --timeout 5m -e "errors.As" -e "errors.Is" ./... - .PHONY: \ clean \ op-heartbeat \ diff --git a/op-heartbeat/cmd/main.go b/op-heartbeat/cmd/main.go index 46ee115f5c5bf..2e324661e8f74 100644 --- a/op-heartbeat/cmd/main.go +++ b/op-heartbeat/cmd/main.go @@ -1,11 +1,11 @@ package main import ( - "fmt" "os" heartbeat "github.com/ethereum-optimism/optimism/op-heartbeat" "github.com/ethereum-optimism/optimism/op-heartbeat/flags" + opservice "github.com/ethereum-optimism/optimism/op-service" oplog "github.com/ethereum-optimism/optimism/op-service/log" "github.com/ethereum/go-ethereum/log" "github.com/urfave/cli/v2" @@ -22,7 +22,7 @@ func main() { app := cli.NewApp() app.Flags = flags.Flags - app.Version = fmt.Sprintf("%s-%s-%s", Version, GitCommit, GitDate) + app.Version = opservice.FormatVersion(Version, GitCommit, GitDate, "") app.Name = "op-heartbeat" app.Usage = "Heartbeat recorder" app.Description = "Service that records opt-in heartbeats from op nodes" diff --git a/op-node/.gitignore b/op-node/.gitignore index ba077a4031add..cf23cfa08d5bd 100644 --- a/op-node/.gitignore +++ b/op-node/.gitignore @@ -1 +1,6 @@ bin + +# config files +genesis.json +jwt.txt +rollup.json diff --git a/op-node/Dockerfile b/op-node/Dockerfile index c719585d5dabf..0cd7f16d9c1dd 100644 --- a/op-node/Dockerfile +++ b/op-node/Dockerfile @@ -1,31 +1,9 @@ -FROM --platform=$BUILDPLATFORM golang:1.21.1-alpine3.18 as builder - -ARG VERSION=v0.0.0 - -RUN apk add --no-cache make gcc musl-dev linux-headers git jq bash - -COPY ./go.mod /app/go.mod -COPY ./go.sum /app/go.sum - -WORKDIR /app - -RUN go mod download - -# build op-node with the shared go.mod & go.sum files -COPY ./op-node /app/op-node -COPY ./op-chain-ops /app/op-chain-ops -COPY ./op-service /app/op-service -COPY ./op-bindings /app/op-bindings -COPY ./.git /app/.git - -WORKDIR /app/op-node - -ARG TARGETOS TARGETARCH - -RUN make op-node VERSION="$VERSION" GOOS=$TARGETOS GOARCH=$TARGETARCH +ARG OP_STACK_GO_BUILDER=us-docker.pkg.dev/oplabs-tools-artifacts/images/op-stack-go:latest +FROM $OP_STACK_GO_BUILDER as builder +# See "make golang-docker" and /ops/docker/op-stack-go FROM alpine:3.18 -COPY --from=builder /app/op-node/bin/op-node /usr/local/bin +COPY --from=builder /usr/local/bin/op-node /usr/local/bin/op-node CMD ["op-node"] diff --git a/op-node/Dockerfile.dockerignore b/op-node/Dockerfile.dockerignore new file mode 100644 index 0000000000000..4f26140750a08 --- /dev/null +++ b/op-node/Dockerfile.dockerignore @@ -0,0 +1,2 @@ +# ignore everything but the dockerfile, the op-stack-go base image performs the build +* diff --git a/op-node/Makefile b/op-node/Makefile index 9ce9a6a9919d9..ea2b2544acfaa 100644 --- a/op-node/Makefile +++ b/op-node/Makefile @@ -1,5 +1,5 @@ -GITCOMMIT := $(shell git rev-parse HEAD) -GITDATE := $(shell git show -s --format='%ct') +GITCOMMIT ?= $(shell git rev-parse HEAD) +GITDATE ?= $(shell git show -s --format='%ct') VERSION := v0.0.0 LDFLAGSSTRING +=-X main.GitCommit=$(GITCOMMIT) @@ -17,9 +17,6 @@ clean: test: go test -v ./... -lint: - golangci-lint run -E goimports,sqlclosecheck,bodyclose,asciicheck,misspell,errorlint --timeout 5m -e "errors.As" -e "errors.Is" ./... - fuzz: go test -run NOTAREALTEST -v -fuzztime 10s -fuzz FuzzL1InfoRoundTrip ./rollup/derive go test -run NOTAREALTEST -v -fuzztime 10s -fuzz FuzzL1InfoAgainstContract ./rollup/derive diff --git a/op-node/chaincfg/chains.go b/op-node/chaincfg/chains.go index e864c93a94da9..34ded749fad0d 100644 --- a/op-node/chaincfg/chains.go +++ b/op-node/chaincfg/chains.go @@ -33,14 +33,7 @@ var L2ChainIDToNetworkDisplayName = func() map[string]string { }() // AvailableNetworks returns the selection of network configurations that is available by default. -// Other configurations that are part of the superchain-registry can be used with the --beta.network flag. func AvailableNetworks() []string { - return []string{"op-mainnet", "op-goerli", "op-sepolia"} -} - -// BetaAvailableNetworks returns all available network configurations in the superchain-registry. -// This set of configurations is experimental, and may change at any time. -func BetaAvailableNetworks() []string { var networks []string for _, cfg := range superchain.OPChains { networks = append(networks, cfg.Chain+"-"+cfg.Superchain) @@ -48,20 +41,6 @@ func BetaAvailableNetworks() []string { return networks } -func IsAvailableNetwork(name string, beta bool) bool { - name = handleLegacyName(name) - available := AvailableNetworks() - if beta { - available = BetaAvailableNetworks() - } - for _, v := range available { - if v == name { - return true - } - } - return false -} - func handleLegacyName(name string) string { switch name { case "goerli": @@ -91,7 +70,7 @@ func ChainByName(name string) *superchain.ChainConfig { func GetRollupConfig(name string) (*rollup.Config, error) { chainCfg := ChainByName(name) if chainCfg == nil { - return nil, fmt.Errorf("invalid network %s", name) + return nil, fmt.Errorf("invalid network: %q", name) } rollupCfg, err := rollup.LoadOPStackRollupConfig(chainCfg.ChainID) if err != nil { diff --git a/op-node/chaincfg/chains_test.go b/op-node/chaincfg/chains_test.go index 78ec73f732fe1..98dbfa9ee1e38 100644 --- a/op-node/chaincfg/chains_test.go +++ b/op-node/chaincfg/chains_test.go @@ -27,12 +27,10 @@ func TestGetRollupConfig(t *testing.T) { } for name, expectedCfg := range configsByName { - require.True(t, IsAvailableNetwork(name, false)) - gotCfg, err := GetRollupConfig(name) require.NoError(t, err) - require.Equal(t, expectedCfg, *gotCfg, "rollup-configs from superchain-registry must match") + require.Equalf(t, expectedCfg, *gotCfg, "rollup-configs from superchain-registry must match for %v", name) } } @@ -54,16 +52,17 @@ var mainnetCfg = rollup.Config{ GasLimit: 30_000_000, }, }, - BlockTime: 2, - MaxSequencerDrift: 600, - SeqWindowSize: 3600, - ChannelTimeout: 300, - L1ChainID: big.NewInt(1), - L2ChainID: big.NewInt(10), - BatchInboxAddress: common.HexToAddress("0xff00000000000000000000000000000000000010"), - DepositContractAddress: common.HexToAddress("0xbEb5Fc579115071764c7423A4f12eDde41f106Ed"), - L1SystemConfigAddress: common.HexToAddress("0x229047fed2591dbec1eF1118d64F7aF3dB9EB290"), - RegolithTime: u64Ptr(0), + BlockTime: 2, + MaxSequencerDrift: 600, + SeqWindowSize: 3600, + ChannelTimeout: 300, + L1ChainID: big.NewInt(1), + L2ChainID: big.NewInt(10), + BatchInboxAddress: common.HexToAddress("0xff00000000000000000000000000000000000010"), + DepositContractAddress: common.HexToAddress("0xbEb5Fc579115071764c7423A4f12eDde41f106Ed"), + L1SystemConfigAddress: common.HexToAddress("0x229047fed2591dbec1eF1118d64F7aF3dB9EB290"), + RegolithTime: u64Ptr(0), + ProtocolVersionsAddress: common.HexToAddress("0x8062AbC286f5e7D9428a0Ccb9AbD71e50d93b935"), } var goerliCfg = rollup.Config{ @@ -94,6 +93,7 @@ var goerliCfg = rollup.Config{ DepositContractAddress: common.HexToAddress("0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383"), L1SystemConfigAddress: common.HexToAddress("0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60"), RegolithTime: u64Ptr(1679079600), + CanyonTime: u64Ptr(1699981200), ProtocolVersionsAddress: common.HexToAddress("0x0C24F5098774aA366827D667494e9F889f7cFc08"), } @@ -115,16 +115,18 @@ var sepoliaCfg = rollup.Config{ GasLimit: 30000000, }, }, - BlockTime: 2, - MaxSequencerDrift: 600, - SeqWindowSize: 3600, - ChannelTimeout: 300, - L1ChainID: big.NewInt(11155111), - L2ChainID: big.NewInt(11155420), - BatchInboxAddress: common.HexToAddress("0xff00000000000000000000000000000011155420"), - DepositContractAddress: common.HexToAddress("0x16fc5058f25648194471939df75cf27a2fdc48bc"), - L1SystemConfigAddress: common.HexToAddress("0x034edd2a225f7f429a63e0f1d2084b9e0a93b538"), - RegolithTime: u64Ptr(0), + BlockTime: 2, + MaxSequencerDrift: 600, + SeqWindowSize: 3600, + ChannelTimeout: 300, + L1ChainID: big.NewInt(11155111), + L2ChainID: big.NewInt(11155420), + BatchInboxAddress: common.HexToAddress("0xff00000000000000000000000000000011155420"), + DepositContractAddress: common.HexToAddress("0x16fc5058f25648194471939df75cf27a2fdc48bc"), + L1SystemConfigAddress: common.HexToAddress("0x034edd2a225f7f429a63e0f1d2084b9e0a93b538"), + RegolithTime: u64Ptr(0), + CanyonTime: u64Ptr(1699981200), + ProtocolVersionsAddress: common.HexToAddress("0x79ADD5713B383DAa0a138d3C4780C7A1804a8090"), } func u64Ptr(v uint64) *uint64 { diff --git a/op-node/cmd/batch_decoder/reassemble/reassemble.go b/op-node/cmd/batch_decoder/reassemble/reassemble.go index 18ebba79f15e9..adab7a9cdc8d7 100644 --- a/op-node/cmd/batch_decoder/reassemble/reassemble.go +++ b/op-node/cmd/batch_decoder/reassemble/reassemble.go @@ -19,12 +19,12 @@ import ( ) type ChannelWithMetadata struct { - ID derive.ChannelID `json:"id"` - IsReady bool `json:"is_ready"` - InvalidFrames bool `json:"invalid_frames"` - InvalidBatches bool `json:"invalid_batches"` - Frames []FrameWithMetadata `json:"frames"` - Batches []derive.SingularBatch `json:"batches"` + ID derive.ChannelID `json:"id"` + IsReady bool `json:"is_ready"` + InvalidFrames bool `json:"invalid_frames"` + InvalidBatches bool `json:"invalid_batches"` + Frames []FrameWithMetadata `json:"frames"` + Batches []derive.BatchData `json:"batches"` } type FrameWithMetadata struct { @@ -104,17 +104,17 @@ func processFrames(cfg *rollup.Config, id derive.ChannelID, frames []FrameWithMe } } - var batches []derive.SingularBatch + var batches []derive.BatchData invalidBatches := false if ch.IsReady() { - br, err := derive.BatchReader(cfg, ch.Reader(), eth.L1BlockRef{}) + br, err := derive.BatchReader(ch.Reader()) if err == nil { for batch, err := br(); err != io.EOF; batch, err = br() { if err != nil { fmt.Printf("Error reading batch for channel %v. Err: %v\n", id.String(), err) invalidBatches = true } else { - batches = append(batches, batch.Batch.SingularBatch) + batches = append(batches, *batch) } } } else { diff --git a/op-node/cmd/genesis/cmd.go b/op-node/cmd/genesis/cmd.go index f5e8ebd872b3f..2bbb8e70567fe 100644 --- a/op-node/cmd/genesis/cmd.go +++ b/op-node/cmd/genesis/cmd.go @@ -28,7 +28,7 @@ var Subcommands = cli.Commands{ Flags: []cli.Flag{ &cli.StringFlag{ Name: "deploy-config", - Usage: "Path to hardhat deploy config file", + Usage: "Path to deploy config file", Required: true, }, &cli.StringFlag{ @@ -91,18 +91,26 @@ var Subcommands = cli.Commands{ { Name: "l2", Usage: "Generates an L2 genesis file and rollup config suitable for a deployed network", + Description: "Generating the L2 genesis depends on knowledge of L1 contract addresses for the bridge to be secure. " + + "A deploy config and either a deployment directory or an L1 deployments file are used to create the L2 genesis. " + + "The deploy directory and L1 deployments file are generated by the L1 contract deployments.", Flags: []cli.Flag{ &cli.StringFlag{ Name: "l1-rpc", Usage: "L1 RPC URL", }, &cli.StringFlag{ - Name: "deploy-config", - Usage: "Path to deploy config file", + Name: "deploy-config", + Usage: "Path to deploy config file", + Required: true, }, &cli.StringFlag{ Name: "deployment-dir", - Usage: "Path to network deployment directory", + Usage: "Path to network deployment directory. Cannot be used with --l1-deployments", + }, + &cli.StringFlag{ + Name: "l1-deployments", + Usage: "Path to L1 deployments JSON file. Cannot be used with --deployment-dir", }, &cli.StringFlag{ Name: "outfile.l2", @@ -122,20 +130,36 @@ var Subcommands = cli.Commands{ } deployDir := ctx.String("deployment-dir") - if deployDir == "" { - return errors.New("Must specify --deployment-dir") + l1Deployments := ctx.String("l1-deployments") + + if deployDir != "" && l1Deployments != "" { + return errors.New("cannot specify both --deployment-dir and --l1-deployments") + } + if deployDir == "" && l1Deployments == "" { + return errors.New("must specify either --deployment-dir or --l1-deployments") } - log.Info("Deployment directory", "path", deployDir) - depPath, network := filepath.Split(deployDir) - hh, err := hardhat.New(network, nil, []string{depPath}) - if err != nil { - return err + if deployDir != "" { + log.Info("Deployment directory", "path", deployDir) + depPath, network := filepath.Split(deployDir) + hh, err := hardhat.New(network, nil, []string{depPath}) + if err != nil { + return err + } + + // Read the appropriate deployment addresses from disk + if err := config.GetDeployedAddresses(hh); err != nil { + return err + } } - // Read the appropriate deployment addresses from disk - if err := config.GetDeployedAddresses(hh); err != nil { - return err + if l1Deployments != "" { + log.Info("L1 deployments", "path", l1Deployments) + deployments, err := genesis.NewL1Deployments(l1Deployments) + if err != nil { + return err + } + config.SetDeployments(deployments) } client, err := ethclient.Dial(ctx.String("l1-rpc")) diff --git a/op-node/cmd/main.go b/op-node/cmd/main.go index adee4fd232328..ee21f1cd22b77 100644 --- a/op-node/cmd/main.go +++ b/op-node/cmd/main.go @@ -12,6 +12,7 @@ import ( opnode "github.com/ethereum-optimism/optimism/op-node" "github.com/ethereum-optimism/optimism/op-node/chaincfg" "github.com/ethereum-optimism/optimism/op-node/cmd/genesis" + "github.com/ethereum-optimism/optimism/op-node/cmd/networks" "github.com/ethereum-optimism/optimism/op-node/cmd/p2p" "github.com/ethereum-optimism/optimism/op-node/flags" "github.com/ethereum-optimism/optimism/op-node/metrics" @@ -21,6 +22,7 @@ import ( "github.com/ethereum-optimism/optimism/op-service/cliapp" oplog "github.com/ethereum-optimism/optimism/op-service/log" "github.com/ethereum-optimism/optimism/op-service/metrics/doc" + "github.com/ethereum-optimism/optimism/op-service/opio" ) var ( @@ -29,19 +31,7 @@ var ( ) // VersionWithMeta holds the textual version string including the metadata. -var VersionWithMeta = func() string { - v := version.Version - if GitCommit != "" { - v += "-" + GitCommit[:8] - } - if GitDate != "" { - v += "-" + GitDate - } - if version.Meta != "" { - v += "-" + version.Meta - } - return v -}() +var VersionWithMeta = opservice.FormatVersion(version.Version, GitCommit, GitDate, version.Meta) func main() { // Set up logger with a default INFO level in case we fail to parse flags, @@ -68,9 +58,14 @@ func main() { Name: "doc", Subcommands: doc.NewSubcommands(metrics.NewMetrics("default")), }, + { + Name: "networks", + Subcommands: networks.Subcommands, + }, } - err := app.Run(os.Args) + ctx := opio.WithInterruptBlocker(context.Background()) + err := app.RunContext(ctx, os.Args) if err != nil { log.Crit("Application failed", "message", err) } diff --git a/op-node/cmd/networks/cmd.go b/op-node/cmd/networks/cmd.go new file mode 100644 index 0000000000000..a55ecc09cd4a9 --- /dev/null +++ b/op-node/cmd/networks/cmd.go @@ -0,0 +1,43 @@ +package networks + +import ( + "encoding/json" + "errors" + "fmt" + + opnode "github.com/ethereum-optimism/optimism/op-node" + "github.com/ethereum-optimism/optimism/op-node/flags" + oplog "github.com/ethereum-optimism/optimism/op-service/log" + "github.com/urfave/cli/v2" +) + +var Subcommands = []*cli.Command{ + { + Name: "dump-rollup-config", + Usage: "Dumps network configs", + Flags: []cli.Flag{ + flags.Network, + }, + Action: func(ctx *cli.Context) error { + logCfg := oplog.ReadCLIConfig(ctx) + logger := oplog.NewLogger(oplog.AppOut(ctx), logCfg) + + network := ctx.String(flags.Network.Name) + if network == "" { + return errors.New("must specify a network name") + } + + rCfg, err := opnode.NewRollupConfig(logger, ctx) + if err != nil { + return err + } + + out, err := json.MarshalIndent(rCfg, "", " ") + if err != nil { + return err + } + fmt.Println(string(out)) + return nil + }, + }, +} diff --git a/op-node/flags/flags.go b/op-node/flags/flags.go index e73c196b1eb3a..f5aa45d2d06de 100644 --- a/op-node/flags/flags.go +++ b/op-node/flags/flags.go @@ -78,10 +78,17 @@ var ( openum.EnumString(sources.RPCProviderKinds), EnvVars: prefixEnvVars("L1_RPC_KIND"), Value: func() *sources.RPCProviderKind { - out := sources.RPCKindBasic + out := sources.RPCKindStandard return &out }(), } + L1RethDBPath = &cli.StringFlag{ + Name: "l1.rethdb", + Usage: "The L1 RethDB path, used to fetch receipts for L1 blocks. Only applicable when using the `reth_db` RPC kind with `l1.rpckind`.", + EnvVars: prefixEnvVars("L1_RETHDB"), + Required: false, + Hidden: true, + } L1RPCRateLimit = &cli.Float64Flag{ Name: "l1.rpc-rate-limit", Usage: "Optional self-imposed global rate-limit on L1 RPC requests, specified in requests / second. Disabled if set to 0.", @@ -237,11 +244,10 @@ var ( Value: false, } BetaExtraNetworks = &cli.BoolFlag{ - Name: "beta.extra-networks", - Usage: fmt.Sprintf("Beta feature: enable selection of a predefined-network from the superchain-registry. "+ - "The superchain-registry is experimental, and the availability of configurations may change."+ - "Available networks: %s", strings.Join(chaincfg.BetaAvailableNetworks(), ", ")), + Name: "beta.extra-networks", + Usage: "Legacy flag, ignored, all superchain-registry networks are enabled by default.", EnvVars: prefixEnvVars("BETA_EXTRA_NETWORKS"), + Hidden: true, // hidden, this is deprecated, the flag is not used anymore. } RollupHalt = &cli.StringFlag{ Name: "rollup.halt", @@ -254,9 +260,10 @@ var ( EnvVars: prefixEnvVars("ROLLUP_LOAD_PROTOCOL_VERSIONS"), } CanyonOverrideFlag = &cli.Uint64Flag{ - Name: "override.canyon", - Usage: "Manually specify the Canyon fork timestamp, overriding the bundled setting", - Hidden: true, + Name: "override.canyon", + Usage: "Manually specify the Canyon fork timestamp, overriding the bundled setting", + EnvVars: prefixEnvVars("OVERRIDE_CANYON"), + Hidden: false, } ) @@ -303,6 +310,7 @@ var optionalFlags = []cli.Flag{ RollupHalt, RollupLoadProtocolVersions, CanyonOverrideFlag, + L1RethDBPath, } // Flags contains the list of configuration options available to the binary. diff --git a/op-node/flags/p2p_flags.go b/op-node/flags/p2p_flags.go index 4f680eae7e8dc..34577d831f5b3 100644 --- a/op-node/flags/p2p_flags.go +++ b/op-node/flags/p2p_flags.go @@ -189,8 +189,9 @@ func P2PFlags(envPrefix string) []cli.Flag { EnvVars: p2pEnv(envPrefix, "BOOTNODES"), }, &cli.StringFlag{ - Name: StaticPeersName, - Usage: "Comma-separated multiaddr-format peer list. Static connections to make and maintain, these peers will be regarded as trusted.", + Name: StaticPeersName, + Usage: "Comma-separated multiaddr-format peer list. Static connections to make and maintain, these peers will be regarded as trusted. " + + "Addresses of the local peer are ignored. Duplicate/Alternative addresses for the same peer all apply, but only a single connection per peer is maintained.", Required: false, Value: "", EnvVars: p2pEnv(envPrefix, "STATIC"), diff --git a/op-node/metrics/metrics.go b/op-node/metrics/metrics.go index a5faba121d53f..b0fc76b1c69d5 100644 --- a/op-node/metrics/metrics.go +++ b/op-node/metrics/metrics.go @@ -604,7 +604,9 @@ func (m *Metrics) ReportProtocolVersions(local, engine, recommended, required pa m.ProtocolVersions.WithLabelValues(local.String(), engine.String(), recommended.String(), required.String()).Set(1) } -type noopMetricer struct{} +type noopMetricer struct { + metrics.NoopRPCMetrics +} var NoopMetrics Metricer = new(noopMetricer) @@ -614,17 +616,6 @@ func (n *noopMetricer) RecordInfo(version string) { func (n *noopMetricer) RecordUp() { } -func (n *noopMetricer) RecordRPCServerRequest(method string) func() { - return func() {} -} - -func (n *noopMetricer) RecordRPCClientRequest(method string) func(err error) { - return func(err error) {} -} - -func (n *noopMetricer) RecordRPCClientResponse(method string, err error) { -} - func (n *noopMetricer) SetDerivationIdle(status bool) { } diff --git a/op-node/node/config.go b/op-node/node/config.go index 6f15e7d710f96..cb970d5ebfd36 100644 --- a/op-node/node/config.go +++ b/op-node/node/config.go @@ -60,6 +60,9 @@ type Config struct { // Cancel to request a premature shutdown of the node itself, e.g. when halting. This may be nil. Cancel context.CancelCauseFunc + + // [OPTIONAL] The reth DB path to read receipts from + RethDBPath string } type RPCConfig struct { diff --git a/op-node/node/node.go b/op-node/node/node.go index 280324b82109d..c2bcedb0b8937 100644 --- a/op-node/node/node.go +++ b/op-node/node/node.go @@ -156,6 +156,9 @@ func (n *OpNode) initL1(ctx context.Context, cfg *Config) error { return fmt.Errorf("failed to get L1 RPC client: %w", err) } + // Set the RethDB path in the EthClientConfig, if there is one configured. + rpcCfg.EthClientConfig.RethDBPath = cfg.RethDBPath + n.l1Source, err = sources.NewL1Client( client.NewInstrumentedRPC(l1Node, n.metrics), n.log, n.metrics.L1SourceCache, rpcCfg) if err != nil { @@ -510,6 +513,7 @@ func (n *OpNode) OnUnsafeL2Payload(ctx context.Context, from peer.ID, payload *e // Pass on the event to the L2 Engine ctx, cancel := context.WithTimeout(ctx, time.Second*30) defer cancel() + if err := n.l2Driver.OnUnsafeL2Payload(ctx, payload); err != nil { n.log.Warn("failed to notify engine driver of new L2 payload", "err", err, "id", payload.ID()) } diff --git a/op-node/node/server_test.go b/op-node/node/server_test.go index eda1c8252750f..d63879f00a52e 100644 --- a/op-node/node/server_test.go +++ b/op-node/node/server_test.go @@ -161,6 +161,7 @@ func randomSyncStatus(rng *rand.Rand) *eth.SyncStatus { UnsafeL2: testutils.RandomL2BlockRef(rng), SafeL2: testutils.RandomL2BlockRef(rng), FinalizedL2: testutils.RandomL2BlockRef(rng), + PendingSafeL2: testutils.RandomL2BlockRef(rng), UnsafeL2SyncTarget: testutils.RandomL2BlockRef(rng), EngineSyncTarget: testutils.RandomL2BlockRef(rng), } diff --git a/op-node/p2p/cli/load_signer.go b/op-node/p2p/cli/load_signer.go index e8abfd9f87a11..7416fa76397a6 100644 --- a/op-node/p2p/cli/load_signer.go +++ b/op-node/p2p/cli/load_signer.go @@ -2,6 +2,7 @@ package cli import ( "fmt" + "strings" "github.com/ethereum/go-ethereum/crypto" "github.com/urfave/cli/v2" @@ -19,7 +20,7 @@ func LoadSignerSetup(ctx *cli.Context) (p2p.SignerSetup, error) { if key != "" { // Mnemonics are bad because they leak *all* keys when they leak. // Unencrypted keys from file are bad because they are easy to leak (and we are not checking file permissions). - priv, err := crypto.HexToECDSA(key) + priv, err := crypto.HexToECDSA(strings.TrimPrefix(key, "0x")) if err != nil { return nil, fmt.Errorf("failed to read batch submitter key: %w", err) } diff --git a/op-node/p2p/gossip.go b/op-node/p2p/gossip.go index 85577f32c96e9..36951a76767da 100644 --- a/op-node/p2p/gossip.go +++ b/op-node/p2p/gossip.go @@ -70,10 +70,14 @@ func blocksTopicV1(cfg *rollup.Config) string { return fmt.Sprintf("/optimism/%s/0/blocks", cfg.L2ChainID.String()) } +func blocksTopicV2(cfg *rollup.Config) string { + return fmt.Sprintf("/optimism/%s/1/blocks", cfg.L2ChainID.String()) +} + // BuildSubscriptionFilter builds a simple subscription filter, // to help protect against peers spamming useless subscriptions. func BuildSubscriptionFilter(cfg *rollup.Config) pubsub.SubscriptionFilter { - return pubsub.NewAllowlistSubscriptionFilter(blocksTopicV1(cfg)) // add more topics here in the future, if any. + return pubsub.NewAllowlistSubscriptionFilter(blocksTopicV1(cfg), blocksTopicV2(cfg)) // add more topics here in the future, if any. } var msgBufPool = sync.Pool{New: func() any { @@ -239,7 +243,7 @@ func (sb *seenBlocks) markSeen(h common.Hash) { sb.blockHashes = append(sb.blockHashes, h) } -func BuildBlocksValidator(log log.Logger, cfg *rollup.Config, runCfg GossipRuntimeConfig) pubsub.ValidatorEx { +func BuildBlocksValidator(log log.Logger, cfg *rollup.Config, runCfg GossipRuntimeConfig, blockVersion eth.BlockVersion) pubsub.ValidatorEx { // Seen block hashes per block height // uint64 -> *seenBlocks @@ -284,7 +288,7 @@ func BuildBlocksValidator(log log.Logger, cfg *rollup.Config, runCfg GossipRunti // [REJECT] if the block encoding is not valid var payload eth.ExecutionPayload - if err := payload.UnmarshalSSZ(uint32(len(payloadBytes)), bytes.NewReader(payloadBytes)); err != nil { + if err := payload.UnmarshalSSZ(blockVersion, uint32(len(payloadBytes)), bytes.NewReader(payloadBytes)); err != nil { log.Warn("invalid payload", "err", err, "peer", id) return pubsub.ValidationReject } @@ -310,6 +314,24 @@ func BuildBlocksValidator(log log.Logger, cfg *rollup.Config, runCfg GossipRunti return pubsub.ValidationReject } + // [REJECT] if a V1 Block has withdrawals + if blockVersion == eth.BlockV1 && payload.Withdrawals != nil { + log.Warn("payload is on v1 topic, but has withdrawals", "bad_hash", payload.BlockHash.String()) + return pubsub.ValidationReject + } + + // [REJECT] if a V2 Block does not have withdrawals + if blockVersion == eth.BlockV2 && payload.Withdrawals == nil { + log.Warn("payload is on v2 topic, but does not have withdrawals", "bad_hash", payload.BlockHash.String()) + return pubsub.ValidationReject + } + + // [REJECT] if a V2 Block has non-empty withdrawals + if blockVersion == eth.BlockV2 && len(*payload.Withdrawals) != 0 { + log.Warn("payload is on v2 topic, but has non-empty withdrawals", "bad_hash", payload.BlockHash.String(), "withdrawal_count", len(*payload.Withdrawals)) + return pubsub.ValidationReject + } + seen, ok := blockHeightLRU.Get(uint64(payload.BlockNumber)) if !ok { seen = new(seenBlocks) @@ -370,7 +392,9 @@ type GossipIn interface { } type GossipTopicInfo interface { - BlocksTopicPeers() []peer.ID + AllBlockTopicsPeers() []peer.ID + BlocksTopicV1Peers() []peer.ID + BlocksTopicV2Peers() []peer.ID } type GossipOut interface { @@ -379,6 +403,21 @@ type GossipOut interface { Close() error } +type blockTopic struct { + // blocks topic, main handle on block gossip + topic *pubsub.Topic + // block events handler, to be cancelled before closing the blocks topic. + events *pubsub.TopicEventHandler + // block subscriptions, to be cancelled before closing blocks topic. + sub *pubsub.Subscription +} + +func (bt *blockTopic) Close() error { + bt.events.Cancel() + bt.sub.Cancel() + return bt.topic.Close() +} + type publisher struct { log log.Logger cfg *rollup.Config @@ -388,20 +427,39 @@ type publisher struct { // thus we have to stop it ourselves this way. p2pCancel context.CancelFunc - // blocks topic, main handle on block gossip - blocksTopic *pubsub.Topic - // block events handler, to be cancelled before closing the blocks topic. - blocksEvents *pubsub.TopicEventHandler - // block subscriptions, to be cancelled before closing blocks topic. - blocksSub *pubsub.Subscription + blocksV1 *blockTopic + blocksV2 *blockTopic runCfg GossipRuntimeConfig } var _ GossipOut = (*publisher)(nil) -func (p *publisher) BlocksTopicPeers() []peer.ID { - return p.blocksTopic.ListPeers() +func combinePeers(allPeers ...[]peer.ID) []peer.ID { + var seen = make(map[peer.ID]bool) + var res []peer.ID + for _, peers := range allPeers { + for _, p := range peers { + if _, ok := seen[p]; ok { + continue + } + res = append(res, p) + seen[p] = true + } + } + return res +} + +func (p *publisher) AllBlockTopicsPeers() []peer.ID { + return combinePeers(p.BlocksTopicV1Peers(), p.BlocksTopicV2Peers()) +} + +func (p *publisher) BlocksTopicV1Peers() []peer.ID { + return p.blocksV1.topic.ListPeers() +} + +func (p *publisher) BlocksTopicV2Peers() []peer.ID { + return p.blocksV2.topic.ListPeers() } func (p *publisher) PublishL2Payload(ctx context.Context, payload *eth.ExecutionPayload, signer Signer) error { @@ -428,55 +486,84 @@ func (p *publisher) PublishL2Payload(ctx context.Context, payload *eth.Execution // This also copies the data, freeing up the original buffer to go back into the pool out := snappy.Encode(nil, data) - return p.blocksTopic.Publish(ctx, out) + if p.cfg.IsCanyon(uint64(payload.Timestamp)) { + return p.blocksV2.topic.Publish(ctx, out) + } else { + return p.blocksV1.topic.Publish(ctx, out) + } } func (p *publisher) Close() error { p.p2pCancel() - p.blocksEvents.Cancel() - p.blocksSub.Cancel() - return p.blocksTopic.Close() + e1 := p.blocksV1.Close() + e2 := p.blocksV2.Close() + return errors.Join(e1, e2) } func JoinGossip(self peer.ID, ps *pubsub.PubSub, log log.Logger, cfg *rollup.Config, runCfg GossipRuntimeConfig, gossipIn GossipIn) (GossipOut, error) { - val := guardGossipValidator(log, logValidationResult(self, "validated block", log, BuildBlocksValidator(log, cfg, runCfg))) - blocksTopicName := blocksTopicV1(cfg) - err := ps.RegisterTopicValidator(blocksTopicName, - val, + p2pCtx, p2pCancel := context.WithCancel(context.Background()) + + v1Logger := log.New("topic", "blocksV1") + blocksV1Validator := guardGossipValidator(log, logValidationResult(self, "validated blockv1", v1Logger, BuildBlocksValidator(v1Logger, cfg, runCfg, eth.BlockV1))) + blocksV1, err := newBlockTopic(p2pCtx, blocksTopicV1(cfg), ps, v1Logger, gossipIn, blocksV1Validator) + if err != nil { + p2pCancel() + return nil, fmt.Errorf("failed to setup blocks v1 p2p: %w", err) + } + + v2Logger := log.New("topic", "blocksV2") + blocksV2Validator := guardGossipValidator(log, logValidationResult(self, "validated blockv2", v2Logger, BuildBlocksValidator(v2Logger, cfg, runCfg, eth.BlockV2))) + blocksV2, err := newBlockTopic(p2pCtx, blocksTopicV2(cfg), ps, v2Logger, gossipIn, blocksV2Validator) + if err != nil { + p2pCancel() + return nil, fmt.Errorf("failed to setup blocks v2 p2p: %w", err) + } + + return &publisher{ + log: log, + cfg: cfg, + p2pCancel: p2pCancel, + blocksV1: blocksV1, + blocksV2: blocksV2, + runCfg: runCfg, + }, nil +} + +func newBlockTopic(ctx context.Context, topicId string, ps *pubsub.PubSub, log log.Logger, gossipIn GossipIn, validator pubsub.ValidatorEx) (*blockTopic, error) { + err := ps.RegisterTopicValidator(topicId, + validator, pubsub.WithValidatorTimeout(3*time.Second), pubsub.WithValidatorConcurrency(4)) + if err != nil { - return nil, fmt.Errorf("failed to register blocks gossip topic: %w", err) + return nil, fmt.Errorf("failed to register gossip topic: %w", err) } - blocksTopic, err := ps.Join(blocksTopicName) + + blocksTopic, err := ps.Join(topicId) if err != nil { - return nil, fmt.Errorf("failed to join blocks gossip topic: %w", err) + return nil, fmt.Errorf("failed to join gossip topic: %w", err) } + blocksTopicEvents, err := blocksTopic.EventHandler() if err != nil { return nil, fmt.Errorf("failed to create blocks gossip topic handler: %w", err) } - p2pCtx, p2pCancel := context.WithCancel(context.Background()) - go LogTopicEvents(p2pCtx, log.New("topic", "blocks"), blocksTopicEvents) + + go LogTopicEvents(ctx, log, blocksTopicEvents) subscription, err := blocksTopic.Subscribe() if err != nil { - p2pCancel() err = errors.Join(err, blocksTopic.Close()) return nil, fmt.Errorf("failed to subscribe to blocks gossip topic: %w", err) } subscriber := MakeSubscriber(log, BlocksHandler(gossipIn.OnUnsafeL2Payload)) - go subscriber(p2pCtx, subscription) + go subscriber(ctx, subscription) - return &publisher{ - log: log, - cfg: cfg, - blocksTopic: blocksTopic, - blocksEvents: blocksTopicEvents, - blocksSub: subscription, - p2pCancel: p2pCancel, - runCfg: runCfg, + return &blockTopic{ + topic: blocksTopic, + events: blocksTopicEvents, + sub: subscription, }, nil } diff --git a/op-node/p2p/gossip_test.go b/op-node/p2p/gossip_test.go index d7f6efd2824f9..0f47787d84abc 100644 --- a/op-node/p2p/gossip_test.go +++ b/op-node/p2p/gossip_test.go @@ -1,18 +1,28 @@ package p2p import ( + "bytes" "context" + "fmt" "math/big" "testing" + "time" "github.com/ethereum-optimism/optimism/op-e2e/e2eutils" "github.com/ethereum-optimism/optimism/op-node/rollup" + "github.com/golang/snappy" + + // "github.com/ethereum-optimism/optimism/op-service/eth" + "github.com/ethereum-optimism/optimism/op-service/eth" "github.com/ethereum-optimism/optimism/op-service/testutils" "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/common/hexutil" + "github.com/ethereum/go-ethereum/core/types" "github.com/ethereum/go-ethereum/crypto" "github.com/ethereum/go-ethereum/log" pubsub "github.com/libp2p/go-libp2p-pubsub" + pubsub_pb "github.com/libp2p/go-libp2p-pubsub/pb" "github.com/libp2p/go-libp2p/core/peer" "github.com/stretchr/testify/require" @@ -40,6 +50,11 @@ func TestGuardGossipValidator(t *testing.T) { require.Equal(t, pubsub.ValidationIgnore, val(context.Background(), "bob", nil)) } +func TestCombinePeers(t *testing.T) { + res := combinePeers([]peer.ID{"foo", "bar"}, []peer.ID{"bar", "baz"}) + require.Equal(t, []peer.ID{"foo", "bar", "baz"}, res) +} + func TestVerifyBlockSignature(t *testing.T) { logger := testlog.Logger(t, log.LvlCrit) cfg := &rollup.Config{ @@ -84,3 +99,65 @@ func TestVerifyBlockSignature(t *testing.T) { require.Equal(t, pubsub.ValidationIgnore, result) }) } + +func createSignedP2Payload(payload *eth.ExecutionPayload, signer Signer, l2ChainID *big.Int) ([]byte, error) { + var buf bytes.Buffer + buf.Write(make([]byte, 65)) + if _, err := payload.MarshalSSZ(&buf); err != nil { + return nil, fmt.Errorf("failed to encoded execution payload to publish: %w", err) + } + data := buf.Bytes() + payloadData := data[65:] + sig, err := signer.Sign(context.TODO(), SigningDomainBlocksV1, l2ChainID, payloadData) + if err != nil { + return nil, fmt.Errorf("failed to sign execution payload with signer: %w", err) + } + copy(data[:65], sig[:]) + + // compress the full message + // This also copies the data, freeing up the original buffer to go back into the pool + return snappy.Encode(nil, data), nil +} + +// TestBlockValidator does some very basic tests of the p2p block validation logic +func TestBlockValidator(t *testing.T) { + // Params Set 1: Create the validation function + cfg := &rollup.Config{ + L2ChainID: big.NewInt(100), + } + secrets, err := e2eutils.DefaultMnemonicConfig.Secrets() + require.NoError(t, err) + runCfg := &testutils.MockRuntimeConfig{P2PSeqAddress: crypto.PubkeyToAddress(secrets.SequencerP2P.PublicKey)} + signer := &PreparedSigner{Signer: NewLocalSigner(secrets.SequencerP2P)} + + // valFnV1 := BuildBlocksValidator(testlog.Logger(t, log.LvlCrit), rollupCfg, runCfg, eth.BlockV1) + valFnV2 := BuildBlocksValidator(testlog.Logger(t, log.LvlCrit), cfg, runCfg, eth.BlockV2) + + // Params Set 2: Call the validation function + peerID := peer.ID("foo") + + // Valid Case + payload := eth.ExecutionPayload{ + Timestamp: hexutil.Uint64(time.Now().Unix()), + Withdrawals: &types.Withdrawals{}, + } + payload.BlockHash, _ = payload.CheckBlockHash() // hack to generate the block hash easily. + data, err := createSignedP2Payload(&payload, signer, cfg.L2ChainID) + require.NoError(t, err) + message := &pubsub.Message{Message: &pubsub_pb.Message{Data: data}} + res := valFnV2(context.TODO(), peerID, message) + require.Equal(t, res, pubsub.ValidationAccept) + + // Invalid because non-empty withdrawals when Canyon is active + payload = eth.ExecutionPayload{ + Timestamp: hexutil.Uint64(time.Now().Unix()), + Withdrawals: &types.Withdrawals{&types.Withdrawal{Index: 1, Validator: 1}}, + } + payload.BlockHash, _ = payload.CheckBlockHash() + data, err = createSignedP2Payload(&payload, signer, cfg.L2ChainID) + require.NoError(t, err) + message = &pubsub.Message{Message: &pubsub_pb.Message{Data: data}} + res = valFnV2(context.TODO(), peerID, message) + require.Equal(t, res, pubsub.ValidationReject) + +} diff --git a/op-node/p2p/host.go b/op-node/p2p/host.go index 5396bed05d9cc..6011617f5c780 100644 --- a/op-node/p2p/host.go +++ b/op-node/p2p/host.go @@ -229,13 +229,17 @@ func (conf *Config) Host(log log.Logger, reporter metrics.Reporter, metrics Host return nil, err } - staticPeers := make([]*peer.AddrInfo, len(conf.StaticPeers)) - for i, peerAddr := range conf.StaticPeers { + staticPeers := make([]*peer.AddrInfo, 0, len(conf.StaticPeers)) + for _, peerAddr := range conf.StaticPeers { addr, err := peer.AddrInfoFromP2pAddr(peerAddr) if err != nil { return nil, fmt.Errorf("bad peer address: %w", err) } - staticPeers[i] = addr + if addr.ID == h.ID() { + log.Info("Static-peer list contains address of local peer, ignoring the address.", "peer_id", addr.ID, "addrs", addr.Addrs) + continue + } + staticPeers = append(staticPeers, addr) } out := &extraHost{ diff --git a/op-node/p2p/host_test.go b/op-node/p2p/host_test.go index 1a44c25664b0e..66454c70fe234 100644 --- a/op-node/p2p/host_test.go +++ b/op-node/p2p/host_test.go @@ -15,6 +15,7 @@ import ( "github.com/libp2p/go-libp2p/core/network" "github.com/libp2p/go-libp2p/core/peer" mocknet "github.com/libp2p/go-libp2p/p2p/net/mock" + ma "github.com/multiformats/go-multiaddr" "github.com/stretchr/testify/require" "golang.org/x/exp/slices" @@ -139,6 +140,13 @@ func TestP2PFull(t *testing.T) { confB.StaticPeers, err = peer.AddrInfoToP2pAddrs(&peer.AddrInfo{ID: hostA.ID(), Addrs: hostA.Addrs()}) require.NoError(t, err) + // Add address of host B itself, it shouldn't connect or cause issues. + idB, err := peer.IDFromPublicKey(confB.Priv.GetPublic()) + require.NoError(t, err) + altAddrB, err := ma.NewMultiaddr("/ip4/127.0.0.1/tcp/12345/p2p/" + idB.String()) + require.NoError(t, err) + confB.StaticPeers = append(confB.StaticPeers, altAddrB) + logB := testlog.Logger(t, log.LvlError).New("host", "B") nodeB, err := NewNodeP2P(context.Background(), &rollup.Config{}, logB, &confB, &mockGossipIn{}, nil, runCfgB, metrics.NoopMetrics) @@ -146,6 +154,9 @@ func TestP2PFull(t *testing.T) { defer nodeB.Close() hostB := nodeB.Host() + require.True(t, nodeB.IsStatic(hostA.ID()), "node A must be static peer of node B") + require.False(t, nodeB.IsStatic(hostB.ID()), "node B must not be static peer of node B itself") + select { case <-time.After(time.Second): t.Fatal("failed to connect new host") diff --git a/op-node/p2p/node.go b/op-node/p2p/node.go index 2d8665e9159d7..9c4d3f4da082b 100644 --- a/op-node/p2p/node.go +++ b/op-node/p2p/node.go @@ -112,7 +112,10 @@ func (n *NodeP2P) init(resourcesCtx context.Context, rollupCfg *rollup.Config, l n.syncCl.AddPeer(conn.RemotePeer()) }, DisconnectedF: func(nw network.Network, conn network.Conn) { - n.syncCl.RemovePeer(conn.RemotePeer()) + // only when no connection is available, we can remove the peer + if nw.Connectedness(conn.RemotePeer()) == network.NotConnected { + n.syncCl.RemovePeer(conn.RemotePeer()) + } }, }) n.syncCl.Start() @@ -139,7 +142,7 @@ func (n *NodeP2P) init(resourcesCtx context.Context, rollupCfg *rollup.Config, l if err != nil { return fmt.Errorf("failed to join blocks gossip topic: %w", err) } - log.Info("started p2p host", "addrs", n.host.Addrs(), "peerID", n.host.ID().Pretty()) + log.Info("started p2p host", "addrs", n.host.Addrs(), "peerID", n.host.ID().String()) tcpPort, err := FindActiveTCPPort(n.host) if err != nil { diff --git a/op-node/p2p/rpc_server.go b/op-node/p2p/rpc_server.go index 677877b4a8497..e86952ebd56d7 100644 --- a/op-node/p2p/rpc_server.go +++ b/op-node/p2p/rpc_server.go @@ -194,7 +194,7 @@ func (s *APIBackend) Peers(ctx context.Context, connected bool) (*PeerDump, erro dump.TotalConnected += 1 } } - for _, id := range s.node.GossipOut().BlocksTopicPeers() { + for _, id := range s.node.GossipOut().AllBlockTopicsPeers() { if p, ok := dump.Peers[id.String()]; ok { p.GossipBlocks = true } @@ -208,11 +208,12 @@ func (s *APIBackend) Peers(ctx context.Context, connected bool) (*PeerDump, erro } type PeerStats struct { - Connected uint `json:"connected"` - Table uint `json:"table"` - BlocksTopic uint `json:"blocksTopic"` - Banned uint `json:"banned"` - Known uint `json:"known"` + Connected uint `json:"connected"` + Table uint `json:"table"` + BlocksTopic uint `json:"blocksTopic"` + BlocksTopicV2 uint `json:"blocksTopicV2"` + Banned uint `json:"banned"` + Known uint `json:"known"` } func (s *APIBackend) PeerStats(_ context.Context) (*PeerStats, error) { @@ -223,11 +224,12 @@ func (s *APIBackend) PeerStats(_ context.Context) (*PeerStats, error) { pstore := h.Peerstore() stats := &PeerStats{ - Connected: uint(len(nw.Peers())), - Table: 0, - BlocksTopic: uint(len(s.node.GossipOut().BlocksTopicPeers())), - Banned: 0, - Known: uint(len(pstore.Peers())), + Connected: uint(len(nw.Peers())), + Table: 0, + BlocksTopic: uint(len(s.node.GossipOut().BlocksTopicV1Peers())), + BlocksTopicV2: uint(len(s.node.GossipOut().BlocksTopicV2Peers())), + Banned: 0, + Known: uint(len(pstore.Peers())), } if gater := s.node.ConnectionGater(); gater != nil { stats.Banned = uint(len(gater.ListBlockedPeers())) diff --git a/op-node/p2p/store/scorebook.go b/op-node/p2p/store/scorebook.go index 81def53685fcc..68043ef8a9e16 100644 --- a/op-node/p2p/store/scorebook.go +++ b/op-node/p2p/store/scorebook.go @@ -2,6 +2,7 @@ package store import ( "context" + "sync/atomic" "time" "github.com/ethereum-optimism/optimism/op-service/clock" @@ -17,17 +18,18 @@ const ( var scoresBase = ds.NewKey("/peers/scores") +// LastUpdate requires atomic update operations. Use the helper functions SetLastUpdated and LastUpdated to modify and access this field. type scoreRecord struct { - PeerScores PeerScores `json:"peerScores"` LastUpdate int64 `json:"lastUpdate"` // unix timestamp in seconds + PeerScores PeerScores `json:"peerScores"` } func (s *scoreRecord) SetLastUpdated(t time.Time) { - s.LastUpdate = t.Unix() + atomic.StoreInt64(&s.LastUpdate, t.Unix()) } func (s *scoreRecord) LastUpdated() time.Time { - return time.Unix(s.LastUpdate, 0) + return time.Unix(atomic.LoadInt64(&s.LastUpdate), 0) } func (s *scoreRecord) MarshalBinary() (data []byte, err error) { diff --git a/op-node/p2p/sync.go b/op-node/p2p/sync.go index f4000b667869c..0225dd4f1bfc3 100644 --- a/op-node/p2p/sync.go +++ b/op-node/p2p/sync.go @@ -571,7 +571,7 @@ func (r requestResultErr) ResultCode() byte { return byte(r) } -func (s *SyncClient) doRequest(ctx context.Context, id peer.ID, n uint64) error { +func (s *SyncClient) doRequest(ctx context.Context, id peer.ID, expectedBlockNum uint64) error { // open stream to peer reqCtx, reqCancel := context.WithTimeout(ctx, streamTimeout) str, err := s.newStreamFn(reqCtx, id, s.payloadByNumber) @@ -582,8 +582,8 @@ func (s *SyncClient) doRequest(ctx context.Context, id peer.ID, n uint64) error defer str.Close() // set write timeout (if available) _ = str.SetWriteDeadline(time.Now().Add(clientWriteRequestTimeout)) - if err := binary.Write(str, binary.LittleEndian, n); err != nil { - return fmt.Errorf("failed to write request (%d): %w", n, err) + if err := binary.Write(str, binary.LittleEndian, expectedBlockNum); err != nil { + return fmt.Errorf("failed to write request (%d): %w", expectedBlockNum, err) } if err := str.CloseWrite(); err != nil { return fmt.Errorf("failed to close writer side while making request: %w", err) @@ -620,14 +620,22 @@ func (s *SyncClient) doRequest(ctx context.Context, id peer.ID, n uint64) error if err != nil { return fmt.Errorf("failed to read response: %w", err) } + + expectedBlockTime := s.cfg.TimestampForBlock(expectedBlockNum) + + blockVersion := eth.BlockV1 + if s.cfg.IsCanyon(expectedBlockTime) { + blockVersion = eth.BlockV2 + } var res eth.ExecutionPayload - if err := res.UnmarshalSSZ(uint32(len(data)), bytes.NewReader(data)); err != nil { + if err := res.UnmarshalSSZ(blockVersion, uint32(len(data)), bytes.NewReader(data)); err != nil { return fmt.Errorf("failed to decode response: %w", err) } + if err := str.CloseRead(); err != nil { return fmt.Errorf("failed to close reading side") } - if err := verifyBlock(&res, n); err != nil { + if err := verifyBlock(&res, expectedBlockNum); err != nil { return fmt.Errorf("received execution payload is invalid: %w", err) } select { diff --git a/op-node/p2p/sync_test.go b/op-node/p2p/sync_test.go index e90c5f4f590b2..4144629e41cb5 100644 --- a/op-node/p2p/sync_test.go +++ b/op-node/p2p/sync_test.go @@ -288,3 +288,57 @@ func TestMultiPeerSync(t *testing.T) { require.Equal(t, exp.BlockHash, p.BlockHash, "expecting the correct payload") } } + +func TestNetworkNotifyAddPeerAndRemovePeer(t *testing.T) { + t.Parallel() + log := testlog.Logger(t, log.LvlDebug) + + cfg, _ := setupSyncTestData(25) + + confA := TestingConfig(t) + confB := TestingConfig(t) + hostA, err := confA.Host(log.New("host", "A"), nil, metrics.NoopMetrics) + require.NoError(t, err, "failed to launch host A") + defer hostA.Close() + hostB, err := confB.Host(log.New("host", "B"), nil, metrics.NoopMetrics) + require.NoError(t, err, "failed to launch host B") + defer hostB.Close() + + syncCl := NewSyncClient(log, cfg, hostA.NewStream, func(ctx context.Context, from peer.ID, payload *eth.ExecutionPayload) error { + return nil + }, metrics.NoopMetrics, &NoopApplicationScorer{}) + + waitChan := make(chan struct{}, 1) + hostA.Network().Notify(&network.NotifyBundle{ + ConnectedF: func(nw network.Network, conn network.Conn) { + syncCl.AddPeer(conn.RemotePeer()) + waitChan <- struct{}{} + }, + DisconnectedF: func(nw network.Network, conn network.Conn) { + // only when no connection is available, we can remove the peer + if nw.Connectedness(conn.RemotePeer()) == network.NotConnected { + syncCl.RemovePeer(conn.RemotePeer()) + } + waitChan <- struct{}{} + }, + }) + syncCl.Start() + + err = hostA.Connect(context.Background(), peer.AddrInfo{ID: hostB.ID(), Addrs: hostB.Addrs()}) + require.NoError(t, err, "failed to connect to peer B from peer A") + require.Equal(t, hostA.Network().Connectedness(hostB.ID()), network.Connected) + + //wait for async add process done + <-waitChan + _, ok := syncCl.peers[hostB.ID()] + require.True(t, ok, "peerB should exist in syncClient") + + err = hostA.Network().ClosePeer(hostB.ID()) + require.NoError(t, err, "close peer fail") + + //wait for async removing process done + <-waitChan + _, peerBExist3 := syncCl.peers[hostB.ID()] + require.True(t, !peerBExist3, "peerB should not exist in syncClient") + +} diff --git a/op-node/rollup/derive/attributes.go b/op-node/rollup/derive/attributes.go index 0cc7c63494b46..b65f680952f3f 100644 --- a/op-node/rollup/derive/attributes.go +++ b/op-node/rollup/derive/attributes.go @@ -109,6 +109,11 @@ func (ba *FetchingAttributesBuilder) PreparePayloadAttributes(ctx context.Contex txs = append(txs, l1InfoTx) txs = append(txs, depositTxs...) + var withdrawals *types.Withdrawals + if ba.cfg.IsCanyon(nextL2Time) { + withdrawals = &types.Withdrawals{} + } + return ð.PayloadAttributes{ Timestamp: hexutil.Uint64(nextL2Time), PrevRandao: eth.Bytes32(l1Info.MixDigest()), @@ -116,5 +121,6 @@ func (ba *FetchingAttributesBuilder) PreparePayloadAttributes(ctx context.Contex Transactions: txs, NoTxPool: true, GasLimit: (*eth.Uint64Quantity)(&sysConfig.GasLimit), + Withdrawals: withdrawals, }, nil } diff --git a/op-node/rollup/derive/attributes_queue.go b/op-node/rollup/derive/attributes_queue.go index 016c39d696b87..e923695a6cdf8 100644 --- a/op-node/rollup/derive/attributes_queue.go +++ b/op-node/rollup/derive/attributes_queue.go @@ -28,11 +28,12 @@ type AttributesBuilder interface { } type AttributesQueue struct { - log log.Logger - config *rollup.Config - builder AttributesBuilder - prev *BatchQueue - batch *BatchData + log log.Logger + config *rollup.Config + builder AttributesBuilder + prev *BatchQueue + batch *SingularBatch + isLastInSpan bool } func NewAttributesQueue(log log.Logger, cfg *rollup.Config, builder AttributesBuilder, prev *BatchQueue) *AttributesQueue { @@ -48,30 +49,33 @@ func (aq *AttributesQueue) Origin() eth.L1BlockRef { return aq.prev.Origin() } -func (aq *AttributesQueue) NextAttributes(ctx context.Context, l2SafeHead eth.L2BlockRef) (*eth.PayloadAttributes, error) { +func (aq *AttributesQueue) NextAttributes(ctx context.Context, parent eth.L2BlockRef) (*AttributesWithParent, error) { // Get a batch if we need it if aq.batch == nil { - batch, err := aq.prev.NextBatch(ctx, l2SafeHead) + batch, isLastInSpan, err := aq.prev.NextBatch(ctx, parent) if err != nil { return nil, err } aq.batch = batch + aq.isLastInSpan = isLastInSpan } // Actually generate the next attributes - if attrs, err := aq.createNextAttributes(ctx, aq.batch, l2SafeHead); err != nil { + if attrs, err := aq.createNextAttributes(ctx, aq.batch, parent); err != nil { return nil, err } else { // Clear out the local state once we will succeed + attr := AttributesWithParent{attrs, parent, aq.isLastInSpan} aq.batch = nil - return attrs, nil + aq.isLastInSpan = false + return &attr, nil } } // createNextAttributes transforms a batch into a payload attributes. This sets `NoTxPool` and appends the batched transactions // to the attributes transaction list -func (aq *AttributesQueue) createNextAttributes(ctx context.Context, batch *BatchData, l2SafeHead eth.L2BlockRef) (*eth.PayloadAttributes, error) { +func (aq *AttributesQueue) createNextAttributes(ctx context.Context, batch *SingularBatch, l2SafeHead eth.L2BlockRef) (*eth.PayloadAttributes, error) { // sanity check parent hash if batch.ParentHash != l2SafeHead.Hash { return nil, NewResetError(fmt.Errorf("valid batch has bad parent hash %s, expected %s", batch.ParentHash, l2SafeHead.Hash)) @@ -99,5 +103,6 @@ func (aq *AttributesQueue) createNextAttributes(ctx context.Context, batch *Batc func (aq *AttributesQueue) Reset(ctx context.Context, _ eth.L1BlockRef, _ eth.SystemConfig) error { aq.batch = nil + aq.isLastInSpan = false // overwritten later, but set for consistency return io.EOF } diff --git a/op-node/rollup/derive/attributes_queue_test.go b/op-node/rollup/derive/attributes_queue_test.go index fef240c576bcc..c5b2cde5eca6c 100644 --- a/op-node/rollup/derive/attributes_queue_test.go +++ b/op-node/rollup/derive/attributes_queue_test.go @@ -42,13 +42,13 @@ func TestAttributesQueue(t *testing.T) { safeHead.L1Origin = l1Info.ID() safeHead.Time = l1Info.InfoTime - batch := NewSingularBatchData(SingularBatch{ + batch := SingularBatch{ ParentHash: safeHead.Hash, EpochNum: rollup.Epoch(l1Info.InfoNum), EpochHash: l1Info.InfoHash, Timestamp: safeHead.Time + cfg.BlockTime, Transactions: []eth.Data{eth.Data("foobar"), eth.Data("example")}, - }) + } parentL1Cfg := eth.SystemConfig{ BatcherAddr: common.Address{42}, @@ -80,7 +80,7 @@ func TestAttributesQueue(t *testing.T) { aq := NewAttributesQueue(testlog.Logger(t, log.LvlError), cfg, attrBuilder, nil) - actual, err := aq.createNextAttributes(context.Background(), batch, safeHead) + actual, err := aq.createNextAttributes(context.Background(), &batch, safeHead) require.NoError(t, err) require.Equal(t, attrs, *actual) diff --git a/op-node/rollup/derive/batch.go b/op-node/rollup/derive/batch.go index 88b50bed641d6..9f3563e790803 100644 --- a/op-node/rollup/derive/batch.go +++ b/op-node/rollup/derive/batch.go @@ -25,9 +25,9 @@ var encodeBufferPool = sync.Pool{ const ( // SingularBatchType is the first version of Batch format, representing a single L2 block. - SingularBatchType = iota + SingularBatchType = 0 // SpanBatchType is the Batch version used after SpanBatch hard fork, representing a span of L2 blocks. - SpanBatchType + SpanBatchType = 1 ) // Batch contains information to build one or multiple L2 blocks. @@ -39,12 +39,20 @@ type Batch interface { LogContext(log.Logger) log.Logger } -// BatchData is a composition type that contains raw data of each batch version. -// It has encoding & decoding methods to implement typed encoding. +// BatchData is used to represent the typed encoding & decoding. +// and wraps around a single interface InnerBatchData. +// Further fields such as cache can be added in the future, without embedding each type of InnerBatchData. +// Similar design with op-geth's types.Transaction struct. type BatchData struct { - BatchType int - SingularBatch - RawSpanBatch + inner InnerBatchData +} + +// InnerBatchData is the underlying data of a BatchData. +// This is implemented by SingularBatch and RawSpanBatch. +type InnerBatchData interface { + GetBatchType() int + encode(w io.Writer) error + decode(r *bytes.Reader) error } // EncodeRLP implements rlp.Encoder @@ -58,6 +66,10 @@ func (b *BatchData) EncodeRLP(w io.Writer) error { return rlp.Encode(w, buf.Bytes()) } +func (bd *BatchData) GetBatchType() uint8 { + return uint8(bd.inner.GetBatchType()) +} + // MarshalBinary returns the canonical encoding of the batch. func (b *BatchData) MarshalBinary() ([]byte, error) { var buf bytes.Buffer @@ -67,16 +79,10 @@ func (b *BatchData) MarshalBinary() ([]byte, error) { // encodeTyped encodes batch type and payload for each batch type. func (b *BatchData) encodeTyped(buf *bytes.Buffer) error { - switch b.BatchType { - case SingularBatchType: - buf.WriteByte(SingularBatchType) - return rlp.Encode(buf, &b.SingularBatch) - case SpanBatchType: - buf.WriteByte(SpanBatchType) - return b.RawSpanBatch.encode(buf) - default: - return fmt.Errorf("unrecognized batch type: %d", b.BatchType) + if err := buf.WriteByte(b.GetBatchType()); err != nil { + return err } + return b.inner.encode(buf) } // DecodeRLP implements rlp.Decoder @@ -99,35 +105,28 @@ func (b *BatchData) UnmarshalBinary(data []byte) error { return b.decodeTyped(data) } -// decodeTyped decodes batch type and payload for each batch type. +// decodeTyped decodes a typed batchData func (b *BatchData) decodeTyped(data []byte) error { if len(data) == 0 { - return fmt.Errorf("batch too short") + return errors.New("batch too short") } + var inner InnerBatchData switch data[0] { case SingularBatchType: - b.BatchType = SingularBatchType - return rlp.DecodeBytes(data[1:], &b.SingularBatch) + inner = new(SingularBatch) case SpanBatchType: - b.BatchType = int(data[0]) - return b.RawSpanBatch.decodeBytes(data[1:]) + inner = new(RawSpanBatch) default: return fmt.Errorf("unrecognized batch type: %d", data[0]) } -} - -// NewSingularBatchData creates new BatchData with SingularBatch -func NewSingularBatchData(singularBatch SingularBatch) *BatchData { - return &BatchData{ - BatchType: SingularBatchType, - SingularBatch: singularBatch, + if err := inner.decode(bytes.NewReader(data[1:])); err != nil { + return err } + b.inner = inner + return nil } -// NewSpanBatchData creates new BatchData with SpanBatch -func NewSpanBatchData(spanBatch RawSpanBatch) *BatchData { - return &BatchData{ - BatchType: SpanBatchType, - RawSpanBatch: spanBatch, - } +// NewBatchData creates a new BatchData +func NewBatchData(inner InnerBatchData) *BatchData { + return &BatchData{inner: inner} } diff --git a/op-node/rollup/derive/batch_queue.go b/op-node/rollup/derive/batch_queue.go index 5f57299879cbb..8e9dca29473db 100644 --- a/op-node/rollup/derive/batch_queue.go +++ b/op-node/rollup/derive/batch_queue.go @@ -29,7 +29,12 @@ import ( type NextBatchProvider interface { Origin() eth.L1BlockRef - NextBatch(ctx context.Context) (*BatchData, error) + NextBatch(ctx context.Context) (Batch, error) +} + +type SafeBlockFetcher interface { + L2BlockRefByNumber(context.Context, uint64) (eth.L2BlockRef, error) + PayloadByNumber(context.Context, uint64) (*eth.ExecutionPayload, error) } // BatchQueue contains a set of batches for every L1 block. @@ -40,18 +45,30 @@ type BatchQueue struct { prev NextBatchProvider origin eth.L1BlockRef + // l1Blocks contains consecutive eth.L1BlockRef sorted by time. + // Every L1 origin of unsafe L2 blocks must be eventually included in l1Blocks. + // Batch queue's job is to ensure below two rules: + // If every L2 block corresponding to single L1 block becomes safe, it will be popped from l1Blocks. + // If new L2 block's L1 origin is not included in l1Blocks, fetch and push to l1Blocks. + // length of l1Blocks never exceeds SequencerWindowSize l1Blocks []eth.L1BlockRef - // batches in order of when we've first seen them, grouped by L2 timestamp - batches map[uint64][]*BatchWithL1InclusionBlock + // batches in order of when we've first seen them + batches []*BatchWithL1InclusionBlock + + // nextSpan is cached SingularBatches derived from SpanBatch + nextSpan []*SingularBatch + + l2 SafeBlockFetcher } // NewBatchQueue creates a BatchQueue, which should be Reset(origin) before use. -func NewBatchQueue(log log.Logger, cfg *rollup.Config, prev NextBatchProvider) *BatchQueue { +func NewBatchQueue(log log.Logger, cfg *rollup.Config, prev NextBatchProvider, l2 SafeBlockFetcher) *BatchQueue { return &BatchQueue{ log: log, config: cfg, prev: prev, + l2: l2, } } @@ -59,12 +76,56 @@ func (bq *BatchQueue) Origin() eth.L1BlockRef { return bq.prev.Origin() } -func (bq *BatchQueue) NextBatch(ctx context.Context, safeL2Head eth.L2BlockRef) (*BatchData, error) { +// popNextBatch pops the next batch from the current queued up span-batch nextSpan. +// The queue must be non-empty, or the function will panic. +func (bq *BatchQueue) popNextBatch(parent eth.L2BlockRef) *SingularBatch { + if len(bq.nextSpan) == 0 { + panic("popping non-existent span-batch, invalid state") + } + nextBatch := bq.nextSpan[0] + bq.nextSpan = bq.nextSpan[1:] + // Must set ParentHash before return. we can use parent because the parentCheck is verified in CheckBatch(). + nextBatch.ParentHash = parent.Hash + return nextBatch +} + +// NextBatch return next valid batch upon the given safe head. +// It also returns the boolean that indicates if the batch is the last block in the batch. +func (bq *BatchQueue) NextBatch(ctx context.Context, parent eth.L2BlockRef) (*SingularBatch, bool, error) { + if len(bq.nextSpan) > 0 { + // There are cached singular batches derived from the span batch. + // Check if the next cached batch matches the given parent block. + if bq.nextSpan[0].Timestamp == parent.Time+bq.config.BlockTime { + // Pop first one and return. + nextBatch := bq.popNextBatch(parent) + // len(bq.nextSpan) == 0 means it's the last batch of the span. + return nextBatch, len(bq.nextSpan) == 0, nil + } else { + // Given parent block does not match the next batch. It means the previously returned batch is invalid. + // Drop cached batches and find another batch. + bq.nextSpan = bq.nextSpan[:0] + } + } + + // If the epoch is advanced, update bq.l1Blocks + // Advancing epoch must be done after the pipeline successfully apply the entire span batch to the chain. + // Because the span batch can be reverted during processing the batch, then we must preserve existing l1Blocks + // to verify the epochs of the next candidate batch. + if len(bq.l1Blocks) > 0 && parent.L1Origin.Number > bq.l1Blocks[0].Number { + for i, l1Block := range bq.l1Blocks { + if parent.L1Origin.Number == l1Block.Number { + bq.l1Blocks = bq.l1Blocks[i:] + break + } + } + // If we can't find the origin of parent block, we have to advance bq.origin. + } + // Note: We use the origin that we will have to determine if it's behind. This is important // because it's the future origin that gets saved into the l1Blocks array. // We always update the origin of this stage if it is not the same so after the update code // runs, this is consistent. - originBehind := bq.prev.Origin().Number < safeL2Head.L1Origin.Number + originBehind := bq.prev.Origin().Number < parent.L1Origin.Number // Advance origin if needed // Note: The entire pipeline has the same origin @@ -87,133 +148,149 @@ func (bq *BatchQueue) NextBatch(ctx context.Context, safeL2Head eth.L2BlockRef) if batch, err := bq.prev.NextBatch(ctx); err == io.EOF { outOfData = true } else if err != nil { - return nil, err + return nil, false, err } else if !originBehind { - bq.AddBatch(batch, safeL2Head) + bq.AddBatch(ctx, batch, parent) } // Skip adding data unless we are up to date with the origin, but do fully // empty the previous stages if originBehind { if outOfData { - return nil, io.EOF + return nil, false, io.EOF } else { - return nil, NotEnoughData + return nil, false, NotEnoughData } } // Finally attempt to derive more batches - batch, err := bq.deriveNextBatch(ctx, outOfData, safeL2Head) + batch, err := bq.deriveNextBatch(ctx, outOfData, parent) if err == io.EOF && outOfData { - return nil, io.EOF + return nil, false, io.EOF } else if err == io.EOF { - return nil, NotEnoughData + return nil, false, NotEnoughData } else if err != nil { - return nil, err + return nil, false, err + } + + var nextBatch *SingularBatch + switch batch.GetBatchType() { + case SingularBatchType: + singularBatch, ok := batch.(*SingularBatch) + if !ok { + return nil, false, NewCriticalError(errors.New("failed type assertion to SingularBatch")) + } + nextBatch = singularBatch + case SpanBatchType: + spanBatch, ok := batch.(*SpanBatch) + if !ok { + return nil, false, NewCriticalError(errors.New("failed type assertion to SpanBatch")) + } + // If next batch is SpanBatch, convert it to SingularBatches. + singularBatches, err := spanBatch.GetSingularBatches(bq.l1Blocks, parent) + if err != nil { + return nil, false, NewCriticalError(err) + } + bq.nextSpan = singularBatches + // span-batches are non-empty, so the below pop is safe. + nextBatch = bq.popNextBatch(parent) + default: + return nil, false, NewCriticalError(fmt.Errorf("unrecognized batch type: %d", batch.GetBatchType())) } - return batch, nil + + // If the nextBatch is derived from the span batch, len(bq.nextSpan) == 0 means it's the last batch of the span. + // For singular batches, len(bq.nextSpan) == 0 is always true. + return nextBatch, len(bq.nextSpan) == 0, nil } func (bq *BatchQueue) Reset(ctx context.Context, base eth.L1BlockRef, _ eth.SystemConfig) error { // Copy over the Origin from the next stage // It is set in the engine queue (two stages away) such that the L2 Safe Head origin is the progress bq.origin = base - bq.batches = make(map[uint64][]*BatchWithL1InclusionBlock) + bq.batches = []*BatchWithL1InclusionBlock{} // Include the new origin as an origin to build on // Note: This is only for the initialization case. During normal resets we will later // throw out this block. bq.l1Blocks = bq.l1Blocks[:0] bq.l1Blocks = append(bq.l1Blocks, base) + bq.nextSpan = bq.nextSpan[:0] return io.EOF } -func (bq *BatchQueue) AddBatch(batch *BatchData, l2SafeHead eth.L2BlockRef) { +func (bq *BatchQueue) AddBatch(ctx context.Context, batch Batch, parent eth.L2BlockRef) { if len(bq.l1Blocks) == 0 { - panic(fmt.Errorf("cannot add batch with timestamp %d, no origin was prepared", batch.Timestamp)) + panic(fmt.Errorf("cannot add batch with timestamp %d, no origin was prepared", batch.GetTimestamp())) } data := BatchWithL1InclusionBlock{ L1InclusionBlock: bq.origin, Batch: batch, } - validity := CheckBatch(bq.config, bq.log, bq.l1Blocks, l2SafeHead, &data) + validity := CheckBatch(ctx, bq.config, bq.log, bq.l1Blocks, parent, &data, bq.l2) if validity == BatchDrop { return // if we do drop the batch, CheckBatch will log the drop reason with WARN level. } - bq.log.Debug("Adding batch", "batch_timestamp", batch.Timestamp, "parent_hash", batch.ParentHash, "batch_epoch", batch.Epoch(), "txs", len(batch.Transactions)) - bq.batches[batch.Timestamp] = append(bq.batches[batch.Timestamp], &data) + batch.LogContext(bq.log).Debug("Adding batch") + bq.batches = append(bq.batches, &data) } // deriveNextBatch derives the next batch to apply on top of the current L2 safe head, // following the validity rules imposed on consecutive batches, // based on currently available buffered batch and L1 origin information. // If no batch can be derived yet, then (nil, io.EOF) is returned. -func (bq *BatchQueue) deriveNextBatch(ctx context.Context, outOfData bool, l2SafeHead eth.L2BlockRef) (*BatchData, error) { +func (bq *BatchQueue) deriveNextBatch(ctx context.Context, outOfData bool, parent eth.L2BlockRef) (Batch, error) { if len(bq.l1Blocks) == 0 { return nil, NewCriticalError(errors.New("cannot derive next batch, no origin was prepared")) } epoch := bq.l1Blocks[0] - bq.log.Trace("Deriving the next batch", "epoch", epoch, "l2SafeHead", l2SafeHead, "outOfData", outOfData) + bq.log.Trace("Deriving the next batch", "epoch", epoch, "parent", parent, "outOfData", outOfData) // Note: epoch origin can now be one block ahead of the L2 Safe Head // This is in the case where we auto generate all batches in an epoch & advance the epoch // but don't advance the L2 Safe Head's epoch - if l2SafeHead.L1Origin != epoch.ID() && l2SafeHead.L1Origin.Number != epoch.Number-1 { - return nil, NewResetError(fmt.Errorf("buffered L1 chain epoch %s in batch queue does not match safe head origin %s", epoch, l2SafeHead.L1Origin)) + if parent.L1Origin != epoch.ID() && parent.L1Origin.Number != epoch.Number-1 { + return nil, NewResetError(fmt.Errorf("buffered L1 chain epoch %s in batch queue does not match safe head origin %s", epoch, parent.L1Origin)) } // Find the first-seen batch that matches all validity conditions. // We may not have sufficient information to proceed filtering, and then we stop. // There may be none: in that case we force-create an empty batch - nextTimestamp := l2SafeHead.Time + bq.config.BlockTime + nextTimestamp := parent.Time + bq.config.BlockTime var nextBatch *BatchWithL1InclusionBlock // Go over all batches, in order of inclusion, and find the first batch we can accept. // We filter in-place by only remembering the batches that may be processed in the future, or those we are undecided on. var remaining []*BatchWithL1InclusionBlock - candidates := bq.batches[nextTimestamp] batchLoop: - for i, batch := range candidates { - validity := CheckBatch(bq.config, bq.log.New("batch_index", i), bq.l1Blocks, l2SafeHead, batch) + for i, batch := range bq.batches { + validity := CheckBatch(ctx, bq.config, bq.log.New("batch_index", i), bq.l1Blocks, parent, batch, bq.l2) switch validity { case BatchFuture: - return nil, NewCriticalError(fmt.Errorf("found batch with timestamp %d marked as future batch, but expected timestamp %d", batch.Batch.Timestamp, nextTimestamp)) + remaining = append(remaining, batch) + continue case BatchDrop: - bq.log.Warn("dropping batch", - "batch_timestamp", batch.Batch.Timestamp, - "parent_hash", batch.Batch.ParentHash, - "batch_epoch", batch.Batch.Epoch(), - "txs", len(batch.Batch.Transactions), - "l2_safe_head", l2SafeHead.ID(), - "l2_safe_head_time", l2SafeHead.Time, + batch.Batch.LogContext(bq.log).Warn("Dropping batch", + "parent", parent.ID(), + "parent_time", parent.Time, ) continue case BatchAccept: nextBatch = batch // don't keep the current batch in the remaining items since we are processing it now, // but retain every batch we didn't get to yet. - remaining = append(remaining, candidates[i+1:]...) + remaining = append(remaining, bq.batches[i+1:]...) break batchLoop case BatchUndecided: - remaining = append(remaining, batch) - bq.batches[nextTimestamp] = remaining + remaining = append(remaining, bq.batches[i:]...) + bq.batches = remaining return nil, io.EOF default: return nil, NewCriticalError(fmt.Errorf("unknown batch validity type: %d", validity)) } } - // clean up if we remove the final batch for this timestamp - if len(remaining) == 0 { - delete(bq.batches, nextTimestamp) - } else { - bq.batches[nextTimestamp] = remaining - } + bq.batches = remaining if nextBatch != nil { - // advance epoch if necessary - if nextBatch.Batch.EpochNum == rollup.Epoch(epoch.Number)+1 { - bq.l1Blocks = bq.l1Blocks[1:] - } - bq.log.Info("Found next batch", "epoch", epoch, "batch_epoch", nextBatch.Batch.EpochNum, "batch_timestamp", nextBatch.Batch.Timestamp) + nextBatch.Batch.LogContext(bq.log).Info("Found next batch") return nextBatch.Batch, nil } @@ -221,7 +298,7 @@ batchLoop: // i.e. if the sequence window expired, we create empty batches for the current epoch expiryEpoch := epoch.Number + bq.config.SeqWindowSize forceEmptyBatches := (expiryEpoch == bq.origin.Number && outOfData) || expiryEpoch < bq.origin.Number - firstOfEpoch := epoch.Number == l2SafeHead.L1Origin.Number+1 + firstOfEpoch := epoch.Number == parent.L1Origin.Number+1 bq.log.Trace("Potentially generating an empty batch", "expiryEpoch", expiryEpoch, "forceEmptyBatches", forceEmptyBatches, "nextTimestamp", nextTimestamp, @@ -243,15 +320,13 @@ batchLoop: // batch to ensure that we at least have one batch per epoch. if nextTimestamp < nextEpoch.Time || firstOfEpoch { bq.log.Info("Generating next batch", "epoch", epoch, "timestamp", nextTimestamp) - return NewSingularBatchData( - SingularBatch{ - ParentHash: l2SafeHead.Hash, - EpochNum: rollup.Epoch(epoch.Number), - EpochHash: epoch.Hash, - Timestamp: nextTimestamp, - Transactions: nil, - }, - ), nil + return &SingularBatch{ + ParentHash: parent.Hash, + EpochNum: rollup.Epoch(epoch.Number), + EpochHash: epoch.Hash, + Timestamp: nextTimestamp, + Transactions: nil, + }, nil } // At this point we have auto generated every batch for the current epoch diff --git a/op-node/rollup/derive/batch_queue_test.go b/op-node/rollup/derive/batch_queue_test.go index 8bad5f22a6a63..fbd9ae1e86dc9 100644 --- a/op-node/rollup/derive/batch_queue_test.go +++ b/op-node/rollup/derive/batch_queue_test.go @@ -3,12 +3,15 @@ package derive import ( "context" "encoding/binary" + "errors" "io" + "math/big" "math/rand" "testing" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common/hexutil" + "github.com/ethereum/go-ethereum/core/types" "github.com/ethereum/go-ethereum/log" "github.com/stretchr/testify/require" @@ -20,7 +23,7 @@ import ( type fakeBatchQueueInput struct { i int - batches []*BatchData + batches []Batch errors []error origin eth.L1BlockRef } @@ -29,7 +32,7 @@ func (f *fakeBatchQueueInput) Origin() eth.L1BlockRef { return f.origin } -func (f *fakeBatchQueueInput) NextBatch(ctx context.Context) (*BatchData, error) { +func (f *fakeBatchQueueInput) NextBatch(ctx context.Context) (Batch, error) { if f.i >= len(f.batches) { return nil, io.EOF } @@ -45,16 +48,74 @@ func mockHash(time uint64, layer uint8) common.Hash { return hash } -func b(timestamp uint64, epoch eth.L1BlockRef) *BatchData { +func b(chainId *big.Int, timestamp uint64, epoch eth.L1BlockRef) *SingularBatch { rng := rand.New(rand.NewSource(int64(timestamp))) - data := testutils.RandomData(rng, 20) - return NewSingularBatchData(SingularBatch{ + signer := types.NewLondonSigner(chainId) + tx := testutils.RandomTx(rng, new(big.Int).SetUint64(rng.Uint64()), signer) + txData, _ := tx.MarshalBinary() + return &SingularBatch{ ParentHash: mockHash(timestamp-2, 2), Timestamp: timestamp, EpochNum: rollup.Epoch(epoch.Number), EpochHash: epoch.Hash, - Transactions: []hexutil.Bytes{data}, - }) + Transactions: []hexutil.Bytes{txData}, + } +} + +func buildSpanBatches(t *testing.T, parent *eth.L2BlockRef, singularBatches []*SingularBatch, blockCounts []int, chainId *big.Int) []Batch { + var spanBatches []Batch + idx := 0 + for _, count := range blockCounts { + span := NewSpanBatch(singularBatches[idx : idx+count]) + spanBatches = append(spanBatches, span) + idx += count + } + return spanBatches +} + +func getSpanBatchTime(batchType int) *uint64 { + minTs := uint64(0) + if batchType == SpanBatchType { + return &minTs + } + return nil +} + +func l1InfoDepositTx(t *testing.T, l1BlockNum uint64) hexutil.Bytes { + l1Info := L1BlockInfo{ + Number: l1BlockNum, + BaseFee: big.NewInt(0), + } + infoData, err := l1Info.MarshalBinary() + require.NoError(t, err) + depositTx := &types.DepositTx{ + Data: infoData, + } + txData, err := types.NewTx(depositTx).MarshalBinary() + require.NoError(t, err) + return txData +} + +func singularBatchToPayload(t *testing.T, batch *SingularBatch, blockNumber uint64) eth.ExecutionPayload { + txs := []hexutil.Bytes{l1InfoDepositTx(t, uint64(batch.EpochNum))} + txs = append(txs, batch.Transactions...) + return eth.ExecutionPayload{ + BlockHash: mockHash(batch.Timestamp, 2), + ParentHash: batch.ParentHash, + BlockNumber: hexutil.Uint64(blockNumber), + Timestamp: hexutil.Uint64(batch.Timestamp), + Transactions: txs, + } +} + +func singularBatchToBlockRef(t *testing.T, batch *SingularBatch, blockNumber uint64) eth.L2BlockRef { + return eth.L2BlockRef{ + Hash: mockHash(batch.Timestamp, 2), + Number: blockNumber, + ParentHash: batch.ParentHash, + Time: batch.Timestamp, + L1Origin: eth.BlockID{Hash: batch.EpochHash, Number: uint64(batch.EpochNum)}, + } } func L1Chain(l1Times []uint64) []eth.L1BlockRef { @@ -73,10 +134,37 @@ func L1Chain(l1Times []uint64) []eth.L1BlockRef { return out } -// TestBatchQueueNewOrigin tests that the batch queue properly saves the new origin +func TestBatchQueue(t *testing.T) { + tests := []struct { + name string + f func(t *testing.T, batchType int) + }{ + {"BatchQueueNewOrigin", BatchQueueNewOrigin}, + {"BatchQueueEager", BatchQueueEager}, + {"BatchQueueInvalidInternalAdvance", BatchQueueInvalidInternalAdvance}, + {"BatchQueueMissing", BatchQueueMissing}, + {"BatchQueueAdvancedEpoch", BatchQueueAdvancedEpoch}, + {"BatchQueueShuffle", BatchQueueShuffle}, + } + for _, test := range tests { + test := test + t.Run(test.name+"_SingularBatch", func(t *testing.T) { + test.f(t, SingularBatchType) + }) + } + + for _, test := range tests { + test := test + t.Run(test.name+"_SpanBatch", func(t *testing.T) { + test.f(t, SpanBatchType) + }) + } +} + +// BatchQueueNewOrigin tests that the batch queue properly saves the new origin // when the safehead's origin is ahead of the pipeline's origin (as is after a reset). // This issue was fixed in https://github.com/ethereum-optimism/optimism/pull/3694 -func TestBatchQueueNewOrigin(t *testing.T) { +func BatchQueueNewOrigin(t *testing.T, batchType int) { log := testlog.Logger(t, log.LvlCrit) l1 := L1Chain([]uint64{10, 15, 20, 25}) safeHead := eth.L2BlockRef{ @@ -94,21 +182,22 @@ func TestBatchQueueNewOrigin(t *testing.T) { BlockTime: 2, MaxSequencerDrift: 600, SeqWindowSize: 2, + SpanBatchTime: getSpanBatchTime(batchType), } input := &fakeBatchQueueInput{ - batches: []*BatchData{nil}, + batches: []Batch{nil}, errors: []error{io.EOF}, origin: l1[0], } - bq := NewBatchQueue(log, cfg, input) + bq := NewBatchQueue(log, cfg, input, nil) _ = bq.Reset(context.Background(), l1[0], eth.SystemConfig{}) require.Equal(t, []eth.L1BlockRef{l1[0]}, bq.l1Blocks) // Prev Origin: 0; Safehead Origin: 2; Internal Origin: 0 // Should return no data but keep the same origin - data, err := bq.NextBatch(context.Background(), safeHead) + data, _, err := bq.NextBatch(context.Background(), safeHead) require.Nil(t, data) require.Equal(t, io.EOF, err) require.Equal(t, []eth.L1BlockRef{l1[0]}, bq.l1Blocks) @@ -117,7 +206,7 @@ func TestBatchQueueNewOrigin(t *testing.T) { // Prev Origin: 1; Safehead Origin: 2; Internal Origin: 0 // Should wipe l1blocks + advance internal origin input.origin = l1[1] - data, err = bq.NextBatch(context.Background(), safeHead) + data, _, err = bq.NextBatch(context.Background(), safeHead) require.Nil(t, data) require.Equal(t, io.EOF, err) require.Empty(t, bq.l1Blocks) @@ -126,18 +215,19 @@ func TestBatchQueueNewOrigin(t *testing.T) { // Prev Origin: 2; Safehead Origin: 2; Internal Origin: 1 // Should add to l1Blocks + advance internal origin input.origin = l1[2] - data, err = bq.NextBatch(context.Background(), safeHead) + data, _, err = bq.NextBatch(context.Background(), safeHead) require.Nil(t, data) require.Equal(t, io.EOF, err) require.Equal(t, []eth.L1BlockRef{l1[2]}, bq.l1Blocks) require.Equal(t, l1[2], bq.origin) } -// TestBatchQueueEager adds a bunch of contiguous batches and asserts that +// BatchQueueEager adds a bunch of contiguous batches and asserts that // enough calls to `NextBatch` return all of those batches. -func TestBatchQueueEager(t *testing.T) { +func BatchQueueEager(t *testing.T, batchType int) { log := testlog.Logger(t, log.LvlCrit) l1 := L1Chain([]uint64{10, 20, 30}) + chainId := big.NewInt(1234) safeHead := eth.L2BlockRef{ Hash: mockHash(10, 2), Number: 0, @@ -153,41 +243,69 @@ func TestBatchQueueEager(t *testing.T) { BlockTime: 2, MaxSequencerDrift: 600, SeqWindowSize: 30, + SpanBatchTime: getSpanBatchTime(batchType), + L2ChainID: chainId, } - batches := []*BatchData{b(12, l1[0]), b(14, l1[0]), b(16, l1[0]), b(18, l1[0]), b(20, l1[0]), b(22, l1[0]), b(24, l1[1]), nil} - errors := []error{nil, nil, nil, nil, nil, nil, nil, io.EOF} + // expected output of BatchQueue.NextBatch() + expectedOutputBatches := []*SingularBatch{ + b(cfg.L2ChainID, 12, l1[0]), + b(cfg.L2ChainID, 14, l1[0]), + b(cfg.L2ChainID, 16, l1[0]), + b(cfg.L2ChainID, 18, l1[0]), + b(cfg.L2ChainID, 20, l1[0]), + b(cfg.L2ChainID, 22, l1[0]), + nil, + } + // expected error of BatchQueue.NextBatch() + expectedOutputErrors := []error{nil, nil, nil, nil, nil, nil, io.EOF} + // errors will be returned by fakeBatchQueueInput.NextBatch() + inputErrors := expectedOutputErrors + // batches will be returned by fakeBatchQueueInput + var inputBatches []Batch + if batchType == SpanBatchType { + spanBlockCounts := []int{1, 2, 3} + inputErrors = []error{nil, nil, nil, io.EOF} + inputBatches = buildSpanBatches(t, &safeHead, expectedOutputBatches, spanBlockCounts, chainId) + inputBatches = append(inputBatches, nil) + } else { + for _, singularBatch := range expectedOutputBatches { + inputBatches = append(inputBatches, singularBatch) + } + } input := &fakeBatchQueueInput{ - batches: batches, - errors: errors, + batches: inputBatches, + errors: inputErrors, origin: l1[0], } - bq := NewBatchQueue(log, cfg, input) + bq := NewBatchQueue(log, cfg, input, nil) _ = bq.Reset(context.Background(), l1[0], eth.SystemConfig{}) // Advance the origin input.origin = l1[1] - for i := 0; i < len(batches); i++ { - b, e := bq.NextBatch(context.Background(), safeHead) - require.ErrorIs(t, e, errors[i]) - require.Equal(t, batches[i], b) - - if b != nil { + for i := 0; i < len(expectedOutputBatches); i++ { + b, _, e := bq.NextBatch(context.Background(), safeHead) + require.ErrorIs(t, e, expectedOutputErrors[i]) + if b == nil { + require.Nil(t, expectedOutputBatches[i]) + } else { + require.Equal(t, expectedOutputBatches[i], b) safeHead.Number += 1 - safeHead.Time += 2 + safeHead.Time += cfg.BlockTime safeHead.Hash = mockHash(b.Timestamp, 2) safeHead.L1Origin = b.Epoch() } } } -// TestBatchQueueInvalidInternalAdvance asserts that we do not miss an epoch when generating batches. +// BatchQueueInvalidInternalAdvance asserts that we do not miss an epoch when generating batches. // This is a regression test for CLI-3378. -func TestBatchQueueInvalidInternalAdvance(t *testing.T) { +func BatchQueueInvalidInternalAdvance(t *testing.T, batchType int) { log := testlog.Logger(t, log.LvlTrace) l1 := L1Chain([]uint64{10, 15, 20, 25, 30}) + chainId := big.NewInt(1234) safeHead := eth.L2BlockRef{ Hash: mockHash(10, 2), Number: 0, @@ -203,27 +321,54 @@ func TestBatchQueueInvalidInternalAdvance(t *testing.T) { BlockTime: 2, MaxSequencerDrift: 600, SeqWindowSize: 2, + SpanBatchTime: getSpanBatchTime(batchType), + L2ChainID: chainId, } - batches := []*BatchData{b(12, l1[0]), b(14, l1[0]), b(16, l1[0]), b(18, l1[0]), b(20, l1[0]), b(22, l1[0]), nil} - errors := []error{nil, nil, nil, nil, nil, nil, io.EOF} + // expected output of BatchQueue.NextBatch() + expectedOutputBatches := []*SingularBatch{ + b(cfg.L2ChainID, 12, l1[0]), + b(cfg.L2ChainID, 14, l1[0]), + b(cfg.L2ChainID, 16, l1[0]), + b(cfg.L2ChainID, 18, l1[0]), + b(cfg.L2ChainID, 20, l1[0]), + b(cfg.L2ChainID, 22, l1[0]), + nil, + } + // expected error of BatchQueue.NextBatch() + expectedOutputErrors := []error{nil, nil, nil, nil, nil, nil, io.EOF} + // errors will be returned by fakeBatchQueueInput.NextBatch() + inputErrors := expectedOutputErrors + // batches will be returned by fakeBatchQueueInput + var inputBatches []Batch + if batchType == SpanBatchType { + spanBlockCounts := []int{1, 2, 3} + inputErrors = []error{nil, nil, nil, io.EOF} + inputBatches = buildSpanBatches(t, &safeHead, expectedOutputBatches, spanBlockCounts, chainId) + inputBatches = append(inputBatches, nil) + } else { + for _, singularBatch := range expectedOutputBatches { + inputBatches = append(inputBatches, singularBatch) + } + } input := &fakeBatchQueueInput{ - batches: batches, - errors: errors, + batches: inputBatches, + errors: inputErrors, origin: l1[0], } - bq := NewBatchQueue(log, cfg, input) + bq := NewBatchQueue(log, cfg, input, nil) _ = bq.Reset(context.Background(), l1[0], eth.SystemConfig{}) // Load continuous batches for epoch 0 - for i := 0; i < len(batches); i++ { - b, e := bq.NextBatch(context.Background(), safeHead) - require.ErrorIs(t, e, errors[i]) - require.Equal(t, batches[i], b) - - if b != nil { + for i := 0; i < len(expectedOutputBatches); i++ { + b, _, e := bq.NextBatch(context.Background(), safeHead) + require.ErrorIs(t, e, expectedOutputErrors[i]) + if b == nil { + require.Nil(t, expectedOutputBatches[i]) + } else { + require.Equal(t, expectedOutputBatches[i], b) safeHead.Number += 1 safeHead.Time += 2 safeHead.Hash = mockHash(b.Timestamp, 2) @@ -233,20 +378,20 @@ func TestBatchQueueInvalidInternalAdvance(t *testing.T) { // Advance to origin 1. No forced batches yet. input.origin = l1[1] - b, e := bq.NextBatch(context.Background(), safeHead) + b, _, e := bq.NextBatch(context.Background(), safeHead) require.ErrorIs(t, e, io.EOF) require.Nil(t, b) // Advance to origin 2. No forced batches yet because we are still on epoch 0 // & have batches for epoch 0. input.origin = l1[2] - b, e = bq.NextBatch(context.Background(), safeHead) + b, _, e = bq.NextBatch(context.Background(), safeHead) require.ErrorIs(t, e, io.EOF) require.Nil(t, b) // Advance to origin 3. Should generate one empty batch. input.origin = l1[3] - b, e = bq.NextBatch(context.Background(), safeHead) + b, _, e = bq.NextBatch(context.Background(), safeHead) require.Nil(t, e) require.NotNil(t, b) require.Equal(t, safeHead.Time+2, b.Timestamp) @@ -255,13 +400,13 @@ func TestBatchQueueInvalidInternalAdvance(t *testing.T) { safeHead.Time += 2 safeHead.Hash = mockHash(b.Timestamp, 2) safeHead.L1Origin = b.Epoch() - b, e = bq.NextBatch(context.Background(), safeHead) + b, _, e = bq.NextBatch(context.Background(), safeHead) require.ErrorIs(t, e, io.EOF) require.Nil(t, b) // Advance to origin 4. Should generate one empty batch. input.origin = l1[4] - b, e = bq.NextBatch(context.Background(), safeHead) + b, _, e = bq.NextBatch(context.Background(), safeHead) require.Nil(t, e) require.NotNil(t, b) require.Equal(t, rollup.Epoch(2), b.EpochNum) @@ -270,15 +415,16 @@ func TestBatchQueueInvalidInternalAdvance(t *testing.T) { safeHead.Time += 2 safeHead.Hash = mockHash(b.Timestamp, 2) safeHead.L1Origin = b.Epoch() - b, e = bq.NextBatch(context.Background(), safeHead) + b, _, e = bq.NextBatch(context.Background(), safeHead) require.ErrorIs(t, e, io.EOF) require.Nil(t, b) } -func TestBatchQueueMissing(t *testing.T) { +func BatchQueueMissing(t *testing.T, batchType int) { log := testlog.Logger(t, log.LvlCrit) l1 := L1Chain([]uint64{10, 15, 20, 25}) + chainId := big.NewInt(1234) safeHead := eth.L2BlockRef{ Hash: mockHash(10, 2), Number: 0, @@ -294,33 +440,52 @@ func TestBatchQueueMissing(t *testing.T) { BlockTime: 2, MaxSequencerDrift: 600, SeqWindowSize: 2, + SpanBatchTime: getSpanBatchTime(batchType), + L2ChainID: chainId, } - // The batches at 18 and 20 are skipped to stop 22 from being eagerly processed. + // The inputBatches at 18 and 20 are skipped to stop 22 from being eagerly processed. // This test checks that batch timestamp 12 & 14 are created, 16 is used, and 18 is advancing the epoch. - // Due to the large sequencer time drift 16 is perfectly valid to have epoch 0 as origin. - batches := []*BatchData{b(16, l1[0]), b(22, l1[1])} - errors := []error{nil, nil} + // Due to the large sequencer time drift 16 is perfectly valid to have epoch 0 as origin.a + + // expected output of BatchQueue.NextBatch() + expectedOutputBatches := []*SingularBatch{ + b(cfg.L2ChainID, 16, l1[0]), + b(cfg.L2ChainID, 22, l1[1]), + } + // errors will be returned by fakeBatchQueueInput.NextBatch() + inputErrors := []error{nil, nil} + // batches will be returned by fakeBatchQueueInput + var inputBatches []Batch + if batchType == SpanBatchType { + spanBlockCounts := []int{1, 1} + inputErrors = []error{nil, nil, nil, io.EOF} + inputBatches = buildSpanBatches(t, &safeHead, expectedOutputBatches, spanBlockCounts, chainId) + } else { + for _, singularBatch := range expectedOutputBatches { + inputBatches = append(inputBatches, singularBatch) + } + } input := &fakeBatchQueueInput{ - batches: batches, - errors: errors, + batches: inputBatches, + errors: inputErrors, origin: l1[0], } - bq := NewBatchQueue(log, cfg, input) + bq := NewBatchQueue(log, cfg, input, nil) _ = bq.Reset(context.Background(), l1[0], eth.SystemConfig{}) - for i := 0; i < len(batches); i++ { - b, e := bq.NextBatch(context.Background(), safeHead) + for i := 0; i < len(expectedOutputBatches); i++ { + b, _, e := bq.NextBatch(context.Background(), safeHead) require.ErrorIs(t, e, NotEnoughData) require.Nil(t, b) } - // advance origin. Underlying stage still has no more batches + // advance origin. Underlying stage still has no more inputBatches // This is not enough to auto advance yet input.origin = l1[1] - b, e := bq.NextBatch(context.Background(), safeHead) + b, _, e := bq.NextBatch(context.Background(), safeHead) require.ErrorIs(t, e, io.EOF) require.Nil(t, b) @@ -328,29 +493,29 @@ func TestBatchQueueMissing(t *testing.T) { input.origin = l1[2] // Check for a generated batch at t = 12 - b, e = bq.NextBatch(context.Background(), safeHead) + b, _, e = bq.NextBatch(context.Background(), safeHead) require.Nil(t, e) require.Equal(t, b.Timestamp, uint64(12)) - require.Empty(t, b.SingularBatch.Transactions) + require.Empty(t, b.Transactions) require.Equal(t, rollup.Epoch(0), b.EpochNum) safeHead.Number += 1 safeHead.Time += 2 safeHead.Hash = mockHash(b.Timestamp, 2) // Check for generated batch at t = 14 - b, e = bq.NextBatch(context.Background(), safeHead) + b, _, e = bq.NextBatch(context.Background(), safeHead) require.Nil(t, e) require.Equal(t, b.Timestamp, uint64(14)) - require.Empty(t, b.SingularBatch.Transactions) + require.Empty(t, b.Transactions) require.Equal(t, rollup.Epoch(0), b.EpochNum) safeHead.Number += 1 safeHead.Time += 2 safeHead.Hash = mockHash(b.Timestamp, 2) // Check for the inputted batch at t = 16 - b, e = bq.NextBatch(context.Background(), safeHead) + b, _, e = bq.NextBatch(context.Background(), safeHead) require.Nil(t, e) - require.Equal(t, b, batches[0]) + require.Equal(t, b, expectedOutputBatches[0]) require.Equal(t, rollup.Epoch(0), b.EpochNum) safeHead.Number += 1 safeHead.Time += 2 @@ -362,11 +527,488 @@ func TestBatchQueueMissing(t *testing.T) { // Check for the generated batch at t = 18. This batch advances the epoch // Note: We need one io.EOF returned from the bq that advances the internal L1 Blocks view // before the batch will be auto generated - _, e = bq.NextBatch(context.Background(), safeHead) + _, _, e = bq.NextBatch(context.Background(), safeHead) require.Equal(t, e, io.EOF) - b, e = bq.NextBatch(context.Background(), safeHead) + b, _, e = bq.NextBatch(context.Background(), safeHead) require.Nil(t, e) require.Equal(t, b.Timestamp, uint64(18)) - require.Empty(t, b.SingularBatch.Transactions) + require.Empty(t, b.Transactions) require.Equal(t, rollup.Epoch(1), b.EpochNum) } + +// BatchQueueAdvancedEpoch tests that batch queue derives consecutive valid batches with advancing epochs. +// Batch queue's l1blocks list should be updated along epochs. +func BatchQueueAdvancedEpoch(t *testing.T, batchType int) { + log := testlog.Logger(t, log.LvlCrit) + l1 := L1Chain([]uint64{0, 6, 12, 18, 24}) // L1 block time: 6s + chainId := big.NewInt(1234) + safeHead := eth.L2BlockRef{ + Hash: mockHash(4, 2), + Number: 0, + ParentHash: common.Hash{}, + Time: 4, + L1Origin: l1[0].ID(), + SequenceNumber: 0, + } + cfg := &rollup.Config{ + Genesis: rollup.Genesis{ + L2Time: 10, + }, + BlockTime: 2, + MaxSequencerDrift: 600, + SeqWindowSize: 30, + SpanBatchTime: getSpanBatchTime(batchType), + L2ChainID: chainId, + } + + // expected output of BatchQueue.NextBatch() + expectedOutputBatches := []*SingularBatch{ + // 3 L2 blocks per L1 block + b(cfg.L2ChainID, 6, l1[1]), + b(cfg.L2ChainID, 8, l1[1]), + b(cfg.L2ChainID, 10, l1[1]), + b(cfg.L2ChainID, 12, l1[2]), + b(cfg.L2ChainID, 14, l1[2]), + b(cfg.L2ChainID, 16, l1[2]), + b(cfg.L2ChainID, 18, l1[3]), + b(cfg.L2ChainID, 20, l1[3]), + b(cfg.L2ChainID, 22, l1[3]), + nil, + } + // expected error of BatchQueue.NextBatch() + expectedOutputErrors := []error{nil, nil, nil, nil, nil, nil, nil, nil, nil, io.EOF} + // errors will be returned by fakeBatchQueueInput.NextBatch() + inputErrors := expectedOutputErrors + // batches will be returned by fakeBatchQueueInput + var inputBatches []Batch + if batchType == SpanBatchType { + spanBlockCounts := []int{2, 2, 2, 3} + inputErrors = []error{nil, nil, nil, nil, io.EOF} + inputBatches = buildSpanBatches(t, &safeHead, expectedOutputBatches, spanBlockCounts, chainId) + inputBatches = append(inputBatches, nil) + } else { + for _, singularBatch := range expectedOutputBatches { + inputBatches = append(inputBatches, singularBatch) + } + } + + // ChannelInReader origin number + inputOriginNumber := 2 + input := &fakeBatchQueueInput{ + batches: inputBatches, + errors: inputErrors, + origin: l1[inputOriginNumber], + } + + bq := NewBatchQueue(log, cfg, input, nil) + _ = bq.Reset(context.Background(), l1[1], eth.SystemConfig{}) + + for i := 0; i < len(expectedOutputBatches); i++ { + expectedOutput := expectedOutputBatches[i] + if expectedOutput != nil && uint64(expectedOutput.EpochNum) == l1[inputOriginNumber].Number { + // Advance ChannelInReader origin if needed + inputOriginNumber += 1 + input.origin = l1[inputOriginNumber] + } + b, _, e := bq.NextBatch(context.Background(), safeHead) + require.ErrorIs(t, e, expectedOutputErrors[i]) + if b == nil { + require.Nil(t, expectedOutput) + } else { + require.Equal(t, expectedOutput, b) + safeHead.Number += 1 + safeHead.Time += cfg.BlockTime + safeHead.Hash = mockHash(b.Timestamp, 2) + safeHead.L1Origin = b.Epoch() + } + } +} + +// BatchQueueShuffle tests batch queue can reorder shuffled valid batches +func BatchQueueShuffle(t *testing.T, batchType int) { + log := testlog.Logger(t, log.LvlCrit) + l1 := L1Chain([]uint64{0, 6, 12, 18, 24}) // L1 block time: 6s + chainId := big.NewInt(1234) + safeHead := eth.L2BlockRef{ + Hash: mockHash(4, 2), + Number: 0, + ParentHash: common.Hash{}, + Time: 4, + L1Origin: l1[0].ID(), + SequenceNumber: 0, + } + cfg := &rollup.Config{ + Genesis: rollup.Genesis{ + L2Time: 10, + }, + BlockTime: 2, + MaxSequencerDrift: 600, + SeqWindowSize: 30, + SpanBatchTime: getSpanBatchTime(batchType), + L2ChainID: chainId, + } + + // expected output of BatchQueue.NextBatch() + expectedOutputBatches := []*SingularBatch{ + // 3 L2 blocks per L1 block + b(cfg.L2ChainID, 6, l1[1]), + b(cfg.L2ChainID, 8, l1[1]), + b(cfg.L2ChainID, 10, l1[1]), + b(cfg.L2ChainID, 12, l1[2]), + b(cfg.L2ChainID, 14, l1[2]), + b(cfg.L2ChainID, 16, l1[2]), + b(cfg.L2ChainID, 18, l1[3]), + b(cfg.L2ChainID, 20, l1[3]), + b(cfg.L2ChainID, 22, l1[3]), + } + // expected error of BatchQueue.NextBatch() + expectedOutputErrors := []error{nil, nil, nil, nil, nil, nil, nil, nil, nil, io.EOF} + // errors will be returned by fakeBatchQueueInput.NextBatch() + inputErrors := expectedOutputErrors + // batches will be returned by fakeBatchQueueInput + var inputBatches []Batch + if batchType == SpanBatchType { + spanBlockCounts := []int{2, 2, 2, 3} + inputErrors = []error{nil, nil, nil, nil, io.EOF} + inputBatches = buildSpanBatches(t, &safeHead, expectedOutputBatches, spanBlockCounts, chainId) + } else { + for _, singularBatch := range expectedOutputBatches { + inputBatches = append(inputBatches, singularBatch) + } + } + + // Shuffle the order of input batches + rand.Shuffle(len(inputBatches), func(i, j int) { + inputBatches[i], inputBatches[j] = inputBatches[j], inputBatches[i] + }) + inputBatches = append(inputBatches, nil) + + // ChannelInReader origin number + inputOriginNumber := 2 + input := &fakeBatchQueueInput{ + batches: inputBatches, + errors: inputErrors, + origin: l1[inputOriginNumber], + } + + bq := NewBatchQueue(log, cfg, input, nil) + _ = bq.Reset(context.Background(), l1[1], eth.SystemConfig{}) + + for i := 0; i < len(expectedOutputBatches); i++ { + expectedOutput := expectedOutputBatches[i] + if expectedOutput != nil && uint64(expectedOutput.EpochNum) == l1[inputOriginNumber].Number { + // Advance ChannelInReader origin if needed + inputOriginNumber += 1 + input.origin = l1[inputOriginNumber] + } + var b *SingularBatch + var e error + for j := 0; j < len(expectedOutputBatches); j++ { + // Multiple NextBatch() executions may be required because the order of input is shuffled + b, _, e = bq.NextBatch(context.Background(), safeHead) + if !errors.Is(e, NotEnoughData) { + break + } + } + require.ErrorIs(t, e, expectedOutputErrors[i]) + if b == nil { + require.Nil(t, expectedOutput) + } else { + require.Equal(t, expectedOutput, b) + safeHead.Number += 1 + safeHead.Time += cfg.BlockTime + safeHead.Hash = mockHash(b.Timestamp, 2) + safeHead.L1Origin = b.Epoch() + } + } +} + +func TestBatchQueueOverlappingSpanBatch(t *testing.T) { + log := testlog.Logger(t, log.LvlCrit) + l1 := L1Chain([]uint64{10, 20, 30}) + chainId := big.NewInt(1234) + safeHead := eth.L2BlockRef{ + Hash: mockHash(10, 2), + Number: 0, + ParentHash: common.Hash{}, + Time: 10, + L1Origin: l1[0].ID(), + SequenceNumber: 0, + } + cfg := &rollup.Config{ + Genesis: rollup.Genesis{ + L2Time: 10, + }, + BlockTime: 2, + MaxSequencerDrift: 600, + SeqWindowSize: 30, + SpanBatchTime: getSpanBatchTime(SpanBatchType), + L2ChainID: chainId, + } + + // expected output of BatchQueue.NextBatch() + expectedOutputBatches := []*SingularBatch{ + b(cfg.L2ChainID, 12, l1[0]), + b(cfg.L2ChainID, 14, l1[0]), + b(cfg.L2ChainID, 16, l1[0]), + b(cfg.L2ChainID, 18, l1[0]), + b(cfg.L2ChainID, 20, l1[0]), + b(cfg.L2ChainID, 22, l1[0]), + nil, + } + // expected error of BatchQueue.NextBatch() + expectedOutputErrors := []error{nil, nil, nil, nil, nil, nil, io.EOF} + // errors will be returned by fakeBatchQueueInput.NextBatch() + inputErrors := []error{nil, nil, nil, nil, io.EOF} + + // batches will be returned by fakeBatchQueueInput + var inputBatches []Batch + batchSize := 3 + for i := 0; i < len(expectedOutputBatches)-batchSize; i++ { + inputBatches = append(inputBatches, NewSpanBatch(expectedOutputBatches[i:i+batchSize])) + } + inputBatches = append(inputBatches, nil) + // inputBatches: + // [ + // [12, 14, 16], // No overlap + // [14, 16, 18], // overlapped blocks: 14, 16 + // [16, 18, 20], // overlapped blocks: 16, 18 + // [18, 20, 22], // overlapped blocks: 18, 20 + // ] + + input := &fakeBatchQueueInput{ + batches: inputBatches, + errors: inputErrors, + origin: l1[0], + } + + l2Client := testutils.MockL2Client{} + var nilErr error + for i, batch := range expectedOutputBatches { + if batch != nil { + blockRef := singularBatchToBlockRef(t, batch, uint64(i+1)) + payload := singularBatchToPayload(t, batch, uint64(i+1)) + if i < 3 { + // In CheckBatch(), "L2BlockRefByNumber" is called when fetching the parent block of overlapped span batch + // so blocks at 12, 14, 16 should be called. + // CheckBatch() is called twice for a batch - before pushing to the queue, after popping from the queue + l2Client.Mock.On("L2BlockRefByNumber", uint64(i+1)).Times(2).Return(blockRef, &nilErr) + } + if i == 1 || i == 4 { + // In CheckBatch(), "PayloadByNumber" is called when fetching the overlapped blocks. + // blocks at 14, 20 are included in overlapped blocks once. + // CheckBatch() is called twice for a batch - before adding to the queue, after getting from the queue + l2Client.Mock.On("PayloadByNumber", uint64(i+1)).Times(2).Return(&payload, &nilErr) + } else if i == 2 || i == 3 { + // blocks at 16, 18 are included in overlapped blocks twice. + l2Client.Mock.On("PayloadByNumber", uint64(i+1)).Times(4).Return(&payload, &nilErr) + } + } + } + + bq := NewBatchQueue(log, cfg, input, &l2Client) + _ = bq.Reset(context.Background(), l1[0], eth.SystemConfig{}) + // Advance the origin + input.origin = l1[1] + + for i := 0; i < len(expectedOutputBatches); i++ { + b, _, e := bq.NextBatch(context.Background(), safeHead) + require.ErrorIs(t, e, expectedOutputErrors[i]) + if b == nil { + require.Nil(t, expectedOutputBatches[i]) + } else { + require.Equal(t, expectedOutputBatches[i], b) + safeHead.Number += 1 + safeHead.Time += cfg.BlockTime + safeHead.Hash = mockHash(b.Timestamp, 2) + safeHead.L1Origin = b.Epoch() + } + } + + l2Client.Mock.AssertExpectations(t) +} + +func TestBatchQueueComplex(t *testing.T) { + log := testlog.Logger(t, log.LvlCrit) + l1 := L1Chain([]uint64{0, 6, 12, 18, 24}) // L1 block time: 6s + chainId := big.NewInt(1234) + safeHead := eth.L2BlockRef{ + Hash: mockHash(4, 2), + Number: 0, + ParentHash: common.Hash{}, + Time: 4, + L1Origin: l1[0].ID(), + SequenceNumber: 0, + } + cfg := &rollup.Config{ + Genesis: rollup.Genesis{ + L2Time: 10, + }, + BlockTime: 2, + MaxSequencerDrift: 600, + SeqWindowSize: 30, + SpanBatchTime: getSpanBatchTime(SpanBatchType), + L2ChainID: chainId, + } + + // expected output of BatchQueue.NextBatch() + expectedOutputBatches := []*SingularBatch{ + // 3 L2 blocks per L1 block + b(cfg.L2ChainID, 6, l1[1]), + b(cfg.L2ChainID, 8, l1[1]), + b(cfg.L2ChainID, 10, l1[1]), + b(cfg.L2ChainID, 12, l1[2]), + b(cfg.L2ChainID, 14, l1[2]), + b(cfg.L2ChainID, 16, l1[2]), + b(cfg.L2ChainID, 18, l1[3]), + b(cfg.L2ChainID, 20, l1[3]), + b(cfg.L2ChainID, 22, l1[3]), + } + // expected error of BatchQueue.NextBatch() + expectedOutputErrors := []error{nil, nil, nil, nil, nil, nil, nil, nil, nil, io.EOF} + // errors will be returned by fakeBatchQueueInput.NextBatch() + inputErrors := []error{nil, nil, nil, nil, nil, nil, io.EOF} + // batches will be returned by fakeBatchQueueInput + inputBatches := []Batch{ + NewSpanBatch(expectedOutputBatches[0:2]), // [6, 8] - no overlap + expectedOutputBatches[2], // [10] - no overlap + NewSpanBatch(expectedOutputBatches[1:4]), // [8, 10, 12] - overlapped blocks: 8 or 8, 10 + expectedOutputBatches[4], // [14] - no overlap + NewSpanBatch(expectedOutputBatches[4:6]), // [14, 16] - overlapped blocks: nothing or 14 + NewSpanBatch(expectedOutputBatches[6:9]), // [18, 20, 22] - no overlap + } + + // Shuffle the order of input batches + rand.Shuffle(len(inputBatches), func(i, j int) { + inputBatches[i], inputBatches[j] = inputBatches[j], inputBatches[i] + }) + + inputBatches = append(inputBatches, nil) + + // ChannelInReader origin number + inputOriginNumber := 2 + input := &fakeBatchQueueInput{ + batches: inputBatches, + errors: inputErrors, + origin: l1[inputOriginNumber], + } + + l2Client := testutils.MockL2Client{} + var nilErr error + for i, batch := range expectedOutputBatches { + if batch != nil { + blockRef := singularBatchToBlockRef(t, batch, uint64(i+1)) + payload := singularBatchToPayload(t, batch, uint64(i+1)) + if i == 0 || i == 3 { + // In CheckBatch(), "L2BlockRefByNumber" is called when fetching the parent block of overlapped span batch + // so blocks at 6, 8 could be called, depends on the order of batches + l2Client.Mock.On("L2BlockRefByNumber", uint64(i+1)).Return(blockRef, &nilErr).Maybe() + } + if i == 1 || i == 2 || i == 4 { + // In CheckBatch(), "PayloadByNumber" is called when fetching the overlapped blocks. + // so blocks at 14, 20 could be called, depends on the order of batches + l2Client.Mock.On("PayloadByNumber", uint64(i+1)).Return(&payload, &nilErr).Maybe() + } + } + } + + bq := NewBatchQueue(log, cfg, input, &l2Client) + _ = bq.Reset(context.Background(), l1[1], eth.SystemConfig{}) + + for i := 0; i < len(expectedOutputBatches); i++ { + expectedOutput := expectedOutputBatches[i] + if expectedOutput != nil && uint64(expectedOutput.EpochNum) == l1[inputOriginNumber].Number { + // Advance ChannelInReader origin if needed + inputOriginNumber += 1 + input.origin = l1[inputOriginNumber] + } + var b *SingularBatch + var e error + for j := 0; j < len(expectedOutputBatches); j++ { + // Multiple NextBatch() executions may be required because the order of input is shuffled + b, _, e = bq.NextBatch(context.Background(), safeHead) + if !errors.Is(e, NotEnoughData) { + break + } + } + require.ErrorIs(t, e, expectedOutputErrors[i]) + if b == nil { + require.Nil(t, expectedOutput) + } else { + require.Equal(t, expectedOutput, b) + safeHead.Number += 1 + safeHead.Time += cfg.BlockTime + safeHead.Hash = mockHash(b.Timestamp, 2) + safeHead.L1Origin = b.Epoch() + } + } + + l2Client.Mock.AssertExpectations(t) +} + +func TestBatchQueueResetSpan(t *testing.T) { + log := testlog.Logger(t, log.LvlCrit) + chainId := big.NewInt(1234) + l1 := L1Chain([]uint64{0, 4, 8}) + safeHead := eth.L2BlockRef{ + Hash: mockHash(0, 2), + Number: 0, + ParentHash: common.Hash{}, + Time: 0, + L1Origin: l1[0].ID(), + SequenceNumber: 0, + } + cfg := &rollup.Config{ + Genesis: rollup.Genesis{ + L2Time: 10, + }, + BlockTime: 2, + MaxSequencerDrift: 600, + SeqWindowSize: 30, + SpanBatchTime: getSpanBatchTime(SpanBatchType), + L2ChainID: chainId, + } + + singularBatches := []*SingularBatch{ + b(cfg.L2ChainID, 2, l1[0]), + b(cfg.L2ChainID, 4, l1[1]), + b(cfg.L2ChainID, 6, l1[1]), + b(cfg.L2ChainID, 8, l1[2]), + } + + input := &fakeBatchQueueInput{ + batches: []Batch{NewSpanBatch(singularBatches)}, + errors: []error{nil}, + origin: l1[2], + } + l2Client := testutils.MockL2Client{} + bq := NewBatchQueue(log, cfg, input, &l2Client) + bq.l1Blocks = l1 // Set enough l1 blocks to derive span batch + + // This NextBatch() will derive the span batch, return the first singular batch and save rest of batches in span. + nextBatch, _, err := bq.NextBatch(context.Background(), safeHead) + require.NoError(t, err) + require.Equal(t, nextBatch, singularBatches[0]) + require.Equal(t, len(bq.nextSpan), len(singularBatches)-1) + // batch queue's epoch should not be advanced until the entire span batch is returned + require.Equal(t, bq.l1Blocks[0], l1[0]) + + // This NextBatch() will return the second singular batch. + safeHead.Number += 1 + safeHead.Time += cfg.BlockTime + safeHead.Hash = mockHash(nextBatch.Timestamp, 2) + safeHead.L1Origin = nextBatch.Epoch() + nextBatch, _, err = bq.NextBatch(context.Background(), safeHead) + require.NoError(t, err) + require.Equal(t, nextBatch, singularBatches[1]) + require.Equal(t, len(bq.nextSpan), len(singularBatches)-2) + // batch queue's epoch should not be advanced until the entire span batch is returned + require.Equal(t, bq.l1Blocks[0], l1[0]) + + // Call NextBatch() with stale safeHead. It means the second batch failed to be processed. + // Batch queue should drop the entire span batch. + nextBatch, _, err = bq.NextBatch(context.Background(), safeHead) + require.Nil(t, nextBatch) + require.ErrorIs(t, err, io.EOF) + require.Equal(t, len(bq.nextSpan), 0) +} diff --git a/op-node/rollup/derive/batch_test.go b/op-node/rollup/derive/batch_test.go index b7646e7528d7d..a5d438ebfec04 100644 --- a/op-node/rollup/derive/batch_test.go +++ b/op-node/rollup/derive/batch_test.go @@ -6,15 +6,16 @@ import ( "math/rand" "testing" - "github.com/ethereum-optimism/optimism/op-node/rollup" - "github.com/ethereum-optimism/optimism/op-service/eth" - "github.com/ethereum-optimism/optimism/op-service/testutils" - "github.com/stretchr/testify/assert" + "github.com/stretchr/testify/require" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common/hexutil" "github.com/ethereum/go-ethereum/core/types" "github.com/ethereum/go-ethereum/rlp" + + "github.com/ethereum-optimism/optimism/op-node/rollup" + "github.com/ethereum-optimism/optimism/op-service/eth" + "github.com/ethereum-optimism/optimism/op-service/testutils" ) func RandomRawSpanBatch(rng *rand.Rand, chainId *big.Int) *RawSpanBatch { @@ -52,8 +53,8 @@ func RandomRawSpanBatch(rng *rand.Rand, chainId *big.Int) *RawSpanBatch { spanBatchPrefix: spanBatchPrefix{ relTimestamp: uint64(rng.Uint32()), l1OriginNum: rng.Uint64(), - parentCheck: testutils.RandomData(rng, 20), - l1OriginCheck: testutils.RandomData(rng, 20), + parentCheck: [20]byte(testutils.RandomData(rng, 20)), + l1OriginCheck: [20]byte(testutils.RandomData(rng, 20)), }, spanBatchPayload: spanBatchPayload{ blockCount: blockCount, @@ -141,40 +142,42 @@ func TestBatchRoundTrip(t *testing.T) { chainID := new(big.Int).SetUint64(rng.Uint64()) batches := []*BatchData{ - { - SingularBatch: SingularBatch{ + NewBatchData( + &SingularBatch{ ParentHash: common.Hash{}, EpochNum: 0, Timestamp: 0, Transactions: []hexutil.Bytes{}, }, - }, - { - SingularBatch: SingularBatch{ + ), + NewBatchData( + &SingularBatch{ ParentHash: common.Hash{31: 0x42}, EpochNum: 1, Timestamp: 1647026951, Transactions: []hexutil.Bytes{[]byte{0, 0, 0}, []byte{0x76, 0xfd, 0x7c}}, }, - }, - NewSingularBatchData(*RandomSingularBatch(rng, 5, chainID)), - NewSingularBatchData(*RandomSingularBatch(rng, 7, chainID)), - NewSpanBatchData(*RandomRawSpanBatch(rng, chainID)), - NewSpanBatchData(*RandomRawSpanBatch(rng, chainID)), - NewSpanBatchData(*RandomRawSpanBatch(rng, chainID)), + ), + NewBatchData(RandomSingularBatch(rng, 5, chainID)), + NewBatchData(RandomSingularBatch(rng, 7, chainID)), + NewBatchData(RandomRawSpanBatch(rng, chainID)), + NewBatchData(RandomRawSpanBatch(rng, chainID)), + NewBatchData(RandomRawSpanBatch(rng, chainID)), } for i, batch := range batches { enc, err := batch.MarshalBinary() - assert.NoError(t, err) + require.NoError(t, err) var dec BatchData err = dec.UnmarshalBinary(enc) - assert.NoError(t, err) - if dec.BatchType == SpanBatchType { - _, err := dec.RawSpanBatch.derive(blockTime, genesisTimestamp, chainID) - assert.NoError(t, err) + require.NoError(t, err) + if dec.GetBatchType() == SpanBatchType { + rawSpanBatch, ok := dec.inner.(*RawSpanBatch) + require.True(t, ok) + _, err := rawSpanBatch.derive(blockTime, genesisTimestamp, chainID) + require.NoError(t, err) } - assert.Equal(t, batch, &dec, "Batch not equal test case %v", i) + require.Equal(t, batch, &dec, "Batch not equal test case %v", i) } } @@ -185,43 +188,45 @@ func TestBatchRoundTripRLP(t *testing.T) { chainID := new(big.Int).SetUint64(rng.Uint64()) batches := []*BatchData{ - { - SingularBatch: SingularBatch{ + NewBatchData( + &SingularBatch{ ParentHash: common.Hash{}, EpochNum: 0, Timestamp: 0, Transactions: []hexutil.Bytes{}, }, - }, - { - SingularBatch: SingularBatch{ + ), + NewBatchData( + &SingularBatch{ ParentHash: common.Hash{31: 0x42}, EpochNum: 1, Timestamp: 1647026951, Transactions: []hexutil.Bytes{[]byte{0, 0, 0}, []byte{0x76, 0xfd, 0x7c}}, }, - }, - NewSingularBatchData(*RandomSingularBatch(rng, 5, chainID)), - NewSingularBatchData(*RandomSingularBatch(rng, 7, chainID)), - NewSpanBatchData(*RandomRawSpanBatch(rng, chainID)), - NewSpanBatchData(*RandomRawSpanBatch(rng, chainID)), - NewSpanBatchData(*RandomRawSpanBatch(rng, chainID)), + ), + NewBatchData(RandomSingularBatch(rng, 5, chainID)), + NewBatchData(RandomSingularBatch(rng, 7, chainID)), + NewBatchData(RandomRawSpanBatch(rng, chainID)), + NewBatchData(RandomRawSpanBatch(rng, chainID)), + NewBatchData(RandomRawSpanBatch(rng, chainID)), } for i, batch := range batches { var buf bytes.Buffer err := batch.EncodeRLP(&buf) - assert.NoError(t, err) + require.NoError(t, err) result := buf.Bytes() var dec BatchData r := bytes.NewReader(result) s := rlp.NewStream(r, 0) err = dec.DecodeRLP(s) - assert.NoError(t, err) - if dec.BatchType == SpanBatchType { - _, err := dec.RawSpanBatch.derive(blockTime, genesisTimestamp, chainID) - assert.NoError(t, err) + require.NoError(t, err) + if dec.GetBatchType() == SpanBatchType { + rawSpanBatch, ok := dec.inner.(*RawSpanBatch) + require.True(t, ok) + _, err := rawSpanBatch.derive(blockTime, genesisTimestamp, chainID) + require.NoError(t, err) } - assert.Equal(t, batch, &dec, "Batch not equal test case %v", i) + require.Equal(t, batch, &dec, "Batch not equal test case %v", i) } } diff --git a/op-node/rollup/derive/batch_tob_test.go b/op-node/rollup/derive/batch_tob_test.go index 6955fdcf5a42d..5b62b4b5bb6f5 100644 --- a/op-node/rollup/derive/batch_tob_test.go +++ b/op-node/rollup/derive/batch_tob_test.go @@ -17,13 +17,13 @@ func FuzzBatchRoundTrip(f *testing.F) { typeProvider := fuzz.NewFromGoFuzz(fuzzedData).NilChance(0).MaxDepth(10000).NumElements(0, 0x100).AllowUnexportedFields(true) fuzzerutils.AddFuzzerFunctions(typeProvider) + var singularBatch SingularBatch + typeProvider.Fuzz(&singularBatch) + // Create our batch data from fuzzed data var batchData BatchData - typeProvider.Fuzz(&batchData) - // force batchdata to only contain singular batch - batchData.BatchType = SingularBatchType - batchData.RawSpanBatch = RawSpanBatch{} + batchData.inner = &singularBatch // Encode our batch data enc, err := batchData.MarshalBinary() diff --git a/op-node/rollup/derive/batches.go b/op-node/rollup/derive/batches.go index 7790e471d9dd4..9cba08686f4cc 100644 --- a/op-node/rollup/derive/batches.go +++ b/op-node/rollup/derive/batches.go @@ -1,6 +1,9 @@ package derive import ( + "bytes" + "context" + "github.com/ethereum-optimism/optimism/op-node/rollup" "github.com/ethereum-optimism/optimism/op-service/eth" "github.com/ethereum/go-ethereum/core/types" @@ -9,7 +12,7 @@ import ( type BatchWithL1InclusionBlock struct { L1InclusionBlock eth.L1BlockRef - Batch *BatchData + Batch Batch } type BatchValidity uint8 @@ -28,14 +31,33 @@ const ( // CheckBatch checks if the given batch can be applied on top of the given l2SafeHead, given the contextual L1 blocks the batch was included in. // The first entry of the l1Blocks should match the origin of the l2SafeHead. One or more consecutive l1Blocks should be provided. // In case of only a single L1 block, the decision whether a batch is valid may have to stay undecided. -func CheckBatch(cfg *rollup.Config, log log.Logger, l1Blocks []eth.L1BlockRef, l2SafeHead eth.L2BlockRef, batch *BatchWithL1InclusionBlock) BatchValidity { +func CheckBatch(ctx context.Context, cfg *rollup.Config, log log.Logger, l1Blocks []eth.L1BlockRef, + l2SafeHead eth.L2BlockRef, batch *BatchWithL1InclusionBlock, l2Fetcher SafeBlockFetcher) BatchValidity { + switch batch.Batch.GetBatchType() { + case SingularBatchType: + singularBatch, ok := batch.Batch.(*SingularBatch) + if !ok { + log.Error("failed type assertion to SingularBatch") + return BatchDrop + } + return checkSingularBatch(cfg, log, l1Blocks, l2SafeHead, singularBatch, batch.L1InclusionBlock) + case SpanBatchType: + spanBatch, ok := batch.Batch.(*SpanBatch) + if !ok { + log.Error("failed type assertion to SpanBatch") + return BatchDrop + } + return checkSpanBatch(ctx, cfg, log, l1Blocks, l2SafeHead, spanBatch, batch.L1InclusionBlock, l2Fetcher) + default: + log.Warn("Unrecognized batch type: %d", batch.Batch.GetBatchType()) + return BatchDrop + } +} + +// checkSingularBatch implements SingularBatch validation rule. +func checkSingularBatch(cfg *rollup.Config, log log.Logger, l1Blocks []eth.L1BlockRef, l2SafeHead eth.L2BlockRef, batch *SingularBatch, l1InclusionBlock eth.L1BlockRef) BatchValidity { // add details to the log - log = log.New( - "batch_timestamp", batch.Batch.Timestamp, - "parent_hash", batch.Batch.ParentHash, - "batch_epoch", batch.Batch.Epoch(), - "txs", len(batch.Batch.Transactions), - ) + log = batch.LogContext(log) // sanity check we have consistent inputs if len(l1Blocks) == 0 { @@ -45,36 +67,36 @@ func CheckBatch(cfg *rollup.Config, log log.Logger, l1Blocks []eth.L1BlockRef, l epoch := l1Blocks[0] nextTimestamp := l2SafeHead.Time + cfg.BlockTime - if batch.Batch.Timestamp > nextTimestamp { + if batch.Timestamp > nextTimestamp { log.Trace("received out-of-order batch for future processing after next batch", "next_timestamp", nextTimestamp) return BatchFuture } - if batch.Batch.Timestamp < nextTimestamp { + if batch.Timestamp < nextTimestamp { log.Warn("dropping batch with old timestamp", "min_timestamp", nextTimestamp) return BatchDrop } // dependent on above timestamp check. If the timestamp is correct, then it must build on top of the safe head. - if batch.Batch.ParentHash != l2SafeHead.Hash { + if batch.ParentHash != l2SafeHead.Hash { log.Warn("ignoring batch with mismatching parent hash", "current_safe_head", l2SafeHead.Hash) return BatchDrop } // Filter out batches that were included too late. - if uint64(batch.Batch.EpochNum)+cfg.SeqWindowSize < batch.L1InclusionBlock.Number { + if uint64(batch.EpochNum)+cfg.SeqWindowSize < l1InclusionBlock.Number { log.Warn("batch was included too late, sequence window expired") return BatchDrop } // Check the L1 origin of the batch batchOrigin := epoch - if uint64(batch.Batch.EpochNum) < epoch.Number { + if uint64(batch.EpochNum) < epoch.Number { log.Warn("dropped batch, epoch is too old", "minimum", epoch.ID()) // batch epoch too old return BatchDrop - } else if uint64(batch.Batch.EpochNum) == epoch.Number { + } else if uint64(batch.EpochNum) == epoch.Number { // Batch is sticking to the current epoch, continue. - } else if uint64(batch.Batch.EpochNum) == epoch.Number+1 { + } else if uint64(batch.EpochNum) == epoch.Number+1 { // With only 1 l1Block we cannot look at the next L1 Origin. // Note: This means that we are unable to determine validity of a batch // without more information. In this case we should bail out until we have @@ -90,19 +112,19 @@ func CheckBatch(cfg *rollup.Config, log log.Logger, l1Blocks []eth.L1BlockRef, l return BatchDrop } - if batch.Batch.EpochHash != batchOrigin.Hash { + if batch.EpochHash != batchOrigin.Hash { log.Warn("batch is for different L1 chain, epoch hash does not match", "expected", batchOrigin.ID()) return BatchDrop } - if batch.Batch.Timestamp < batchOrigin.Time { - log.Warn("batch timestamp is less than L1 origin timestamp", "l2_timestamp", batch.Batch.Timestamp, "l1_timestamp", batchOrigin.Time, "origin", batchOrigin.ID()) + if batch.Timestamp < batchOrigin.Time { + log.Warn("batch timestamp is less than L1 origin timestamp", "l2_timestamp", batch.Timestamp, "l1_timestamp", batchOrigin.Time, "origin", batchOrigin.ID()) return BatchDrop } // Check if we ran out of sequencer time drift - if max := batchOrigin.Time + cfg.MaxSequencerDrift; batch.Batch.Timestamp > max { - if len(batch.Batch.Transactions) == 0 { + if max := batchOrigin.Time + cfg.MaxSequencerDrift; batch.Timestamp > max { + if len(batch.Transactions) == 0 { // If the sequencer is co-operating by producing an empty batch, // then allow the batch if it was the right thing to do to maintain the L2 time >= L1 time invariant. // We only check batches that do not advance the epoch, to ensure epoch advancement regardless of time drift is allowed. @@ -112,7 +134,7 @@ func CheckBatch(cfg *rollup.Config, log log.Logger, l1Blocks []eth.L1BlockRef, l return BatchUndecided } nextOrigin := l1Blocks[1] - if batch.Batch.Timestamp >= nextOrigin.Time { // check if the next L1 origin could have been adopted + if batch.Timestamp >= nextOrigin.Time { // check if the next L1 origin could have been adopted log.Info("batch exceeded sequencer time drift without adopting next origin, and next L1 origin would have been valid") return BatchDrop } else { @@ -128,7 +150,7 @@ func CheckBatch(cfg *rollup.Config, log log.Logger, l1Blocks []eth.L1BlockRef, l } // We can do this check earlier, but it's a more intensive one, so we do this last. - for i, txBytes := range batch.Batch.Transactions { + for i, txBytes := range batch.Transactions { if len(txBytes) == 0 { log.Warn("transaction data must not be empty, but found empty tx", "tx_index", i) return BatchDrop @@ -141,3 +163,217 @@ func CheckBatch(cfg *rollup.Config, log log.Logger, l1Blocks []eth.L1BlockRef, l return BatchAccept } + +// checkSpanBatch implements SpanBatch validation rule. +func checkSpanBatch(ctx context.Context, cfg *rollup.Config, log log.Logger, l1Blocks []eth.L1BlockRef, l2SafeHead eth.L2BlockRef, + batch *SpanBatch, l1InclusionBlock eth.L1BlockRef, l2Fetcher SafeBlockFetcher) BatchValidity { + // add details to the log + log = batch.LogContext(log) + + // sanity check we have consistent inputs + if len(l1Blocks) == 0 { + log.Warn("missing L1 block input, cannot proceed with batch checking") + return BatchUndecided + } + epoch := l1Blocks[0] + + startEpochNum := uint64(batch.GetStartEpochNum()) + batchOrigin := epoch + if startEpochNum == batchOrigin.Number+1 { + if len(l1Blocks) < 2 { + log.Info("eager batch wants to advance epoch, but could not without more L1 blocks", "current_epoch", epoch.ID()) + return BatchUndecided + } + batchOrigin = l1Blocks[1] + } + if !cfg.IsSpanBatch(batchOrigin.Time) { + log.Warn("received SpanBatch with L1 origin before SpanBatch hard fork") + return BatchDrop + } + + nextTimestamp := l2SafeHead.Time + cfg.BlockTime + + if batch.GetTimestamp() > nextTimestamp { + log.Trace("received out-of-order batch for future processing after next batch", "next_timestamp", nextTimestamp) + return BatchFuture + } + if batch.GetBlockTimestamp(batch.GetBlockCount()-1) < nextTimestamp { + log.Warn("span batch has no new blocks after safe head") + return BatchDrop + } + + // finding parent block of the span batch. + // if the span batch does not overlap the current safe chain, parentBLock should be l2SafeHead. + parentNum := l2SafeHead.Number + parentBlock := l2SafeHead + if batch.GetTimestamp() < nextTimestamp { + if batch.GetTimestamp() > l2SafeHead.Time { + // batch timestamp cannot be between safe head and next timestamp + log.Warn("batch has misaligned timestamp, block time is too short") + return BatchDrop + } + if (l2SafeHead.Time-batch.GetTimestamp())%cfg.BlockTime != 0 { + log.Warn("batch has misaligned timestamp, not overlapped exactly") + return BatchDrop + } + parentNum = l2SafeHead.Number - (l2SafeHead.Time-batch.GetTimestamp())/cfg.BlockTime - 1 + var err error + parentBlock, err = l2Fetcher.L2BlockRefByNumber(ctx, parentNum) + if err != nil { + log.Warn("failed to fetch L2 block", "number", parentNum, "err", err) + // unable to validate the batch for now. retry later. + return BatchUndecided + } + } + if !batch.CheckParentHash(parentBlock.Hash) { + log.Warn("ignoring batch with mismatching parent hash", "parent_block", parentBlock.Hash) + return BatchDrop + } + + // Filter out batches that were included too late. + if startEpochNum+cfg.SeqWindowSize < l1InclusionBlock.Number { + log.Warn("batch was included too late, sequence window expired") + return BatchDrop + } + + // Check the L1 origin of the batch + if startEpochNum > parentBlock.L1Origin.Number+1 { + log.Warn("batch is for future epoch too far ahead, while it has the next timestamp, so it must be invalid", "current_epoch", epoch.ID()) + return BatchDrop + } + + endEpochNum := batch.GetBlockEpochNum(batch.GetBlockCount() - 1) + originChecked := false + // l1Blocks is supplied from batch queue and its length is limited to SequencerWindowSize. + for _, l1Block := range l1Blocks { + if l1Block.Number == endEpochNum { + if !batch.CheckOriginHash(l1Block.Hash) { + log.Warn("batch is for different L1 chain, epoch hash does not match", "expected", l1Block.Hash) + return BatchDrop + } + originChecked = true + break + } + } + if !originChecked { + log.Info("need more l1 blocks to check entire origins of span batch") + return BatchUndecided + } + + if startEpochNum < parentBlock.L1Origin.Number { + log.Warn("dropped batch, epoch is too old", "minimum", parentBlock.ID()) + return BatchDrop + } + + originIdx := 0 + originAdvanced := false + if startEpochNum == parentBlock.L1Origin.Number+1 { + originAdvanced = true + } + + for i := 0; i < batch.GetBlockCount(); i++ { + if batch.GetBlockTimestamp(i) <= l2SafeHead.Time { + continue + } + var l1Origin eth.L1BlockRef + for j := originIdx; j < len(l1Blocks); j++ { + if batch.GetBlockEpochNum(i) == l1Blocks[j].Number { + l1Origin = l1Blocks[j] + originIdx = j + break + } + + } + if i > 0 { + originAdvanced = false + if batch.GetBlockEpochNum(i) > batch.GetBlockEpochNum(i-1) { + originAdvanced = true + } + } + blockTimestamp := batch.GetBlockTimestamp(i) + if blockTimestamp < l1Origin.Time { + log.Warn("block timestamp is less than L1 origin timestamp", "l2_timestamp", blockTimestamp, "l1_timestamp", l1Origin.Time, "origin", l1Origin.ID()) + return BatchDrop + } + + // Check if we ran out of sequencer time drift + if max := l1Origin.Time + cfg.MaxSequencerDrift; blockTimestamp > max { + if len(batch.GetBlockTransactions(i)) == 0 { + // If the sequencer is co-operating by producing an empty batch, + // then allow the batch if it was the right thing to do to maintain the L2 time >= L1 time invariant. + // We only check batches that do not advance the epoch, to ensure epoch advancement regardless of time drift is allowed. + if !originAdvanced { + if originIdx+1 >= len(l1Blocks) { + log.Info("without the next L1 origin we cannot determine yet if this empty batch that exceeds the time drift is still valid") + return BatchUndecided + } + if blockTimestamp >= l1Blocks[originIdx+1].Time { // check if the next L1 origin could have been adopted + log.Info("batch exceeded sequencer time drift without adopting next origin, and next L1 origin would have been valid") + return BatchDrop + } else { + log.Info("continuing with empty batch before late L1 block to preserve L2 time invariant") + } + } + } else { + // If the sequencer is ignoring the time drift rule, then drop the batch and force an empty batch instead, + // as the sequencer is not allowed to include anything past this point without moving to the next epoch. + log.Warn("batch exceeded sequencer time drift, sequencer must adopt new L1 origin to include transactions again", "max_time", max) + return BatchDrop + } + } + + for i, txBytes := range batch.GetBlockTransactions(i) { + if len(txBytes) == 0 { + log.Warn("transaction data must not be empty, but found empty tx", "tx_index", i) + return BatchDrop + } + if txBytes[0] == types.DepositTxType { + log.Warn("sequencers may not embed any deposits into batch data, but found tx that has one", "tx_index", i) + return BatchDrop + } + } + } + + // Check overlapped blocks + if batch.GetTimestamp() < nextTimestamp { + for i := uint64(0); i < l2SafeHead.Number-parentNum; i++ { + safeBlockNum := parentNum + i + 1 + safeBlockPayload, err := l2Fetcher.PayloadByNumber(ctx, safeBlockNum) + if err != nil { + log.Warn("failed to fetch L2 block payload", "number", parentNum, "err", err) + // unable to validate the batch for now. retry later. + return BatchUndecided + } + safeBlockTxs := safeBlockPayload.Transactions + batchTxs := batch.GetBlockTransactions(int(i)) + // execution payload has deposit TXs, but batch does not. + depositCount := 0 + for _, tx := range safeBlockTxs { + if tx[0] == types.DepositTxType { + depositCount++ + } + } + if len(safeBlockTxs)-depositCount != len(batchTxs) { + log.Warn("overlapped block's tx count does not match", "safeBlockTxs", len(safeBlockTxs), "batchTxs", len(batchTxs)) + return BatchDrop + } + for j := 0; j < len(batchTxs); j++ { + if !bytes.Equal(safeBlockTxs[j+depositCount], batchTxs[j]) { + log.Warn("overlapped block's transaction does not match") + return BatchDrop + } + } + safeBlockRef, err := PayloadToBlockRef(safeBlockPayload, &cfg.Genesis) + if err != nil { + log.Error("failed to extract L2BlockRef from execution payload", "hash", safeBlockPayload.BlockHash, "err", err) + return BatchDrop + } + if safeBlockRef.L1Origin.Number != batch.GetBlockEpochNum(int(i)) { + log.Warn("overlapped block's L1 origin number does not match") + return BatchDrop + } + } + } + + return BatchAccept +} diff --git a/op-node/rollup/derive/batches_test.go b/op-node/rollup/derive/batches_test.go index cabcb6e4e1473..b122a61e0e799 100644 --- a/op-node/rollup/derive/batches_test.go +++ b/op-node/rollup/derive/batches_test.go @@ -1,7 +1,12 @@ package derive import ( + "bytes" + "context" + "errors" + "math/big" "math/rand" + "strings" "testing" "github.com/stretchr/testify/require" @@ -17,18 +22,31 @@ import ( ) type ValidBatchTestCase struct { - Name string - L1Blocks []eth.L1BlockRef - L2SafeHead eth.L2BlockRef - Batch BatchWithL1InclusionBlock - Expected BatchValidity + Name string + L1Blocks []eth.L1BlockRef + L2SafeHead eth.L2BlockRef + Batch BatchWithL1InclusionBlock + Expected BatchValidity + ExpectedLog string // log message that must be included + NotExpectedLog string // log message that must not be included + SpanBatchTime *uint64 +} + +type TestLogHandler struct { + handler log.Handler + logs *bytes.Buffer +} + +func (th *TestLogHandler) Log(r *log.Record) error { + th.logs.WriteString(r.Msg + "\n") + return th.handler.Log(r) } var HashA = common.Hash{0x0a} var HashB = common.Hash{0x0b} func TestValidBatch(t *testing.T) { - conf := rollup.Config{ + defaultConf := rollup.Config{ Genesis: rollup.Genesis{ L2Time: 31, // a genesis time that itself does not align to make it more interesting }, @@ -36,9 +54,17 @@ func TestValidBatch(t *testing.T) { SeqWindowSize: 4, MaxSequencerDrift: 6, // other config fields are ignored and can be left empty. + SpanBatchTime: nil, } rng := rand.New(rand.NewSource(1234)) + + minTs := uint64(0) + chainId := new(big.Int).SetUint64(rng.Uint64()) + signer := types.NewLondonSigner(chainId) + randTx := testutils.RandomTx(rng, new(big.Int).SetUint64(rng.Uint64()), signer) + randTxData, _ := randTx.MarshalBinary() + l1A := testutils.RandomBlockRef(rng) l1B := eth.L1BlockRef{ Hash: testutils.RandomHash(rng), @@ -84,7 +110,7 @@ func TestValidBatch(t *testing.T) { Hash: testutils.RandomHash(rng), Number: l2A0.Number + 1, ParentHash: l2A0.Hash, - Time: l2A0.Time + conf.BlockTime, + Time: l2A0.Time + defaultConf.BlockTime, L1Origin: l1A.ID(), SequenceNumber: 1, } @@ -93,7 +119,7 @@ func TestValidBatch(t *testing.T) { Hash: testutils.RandomHash(rng), Number: l2A1.Number + 1, ParentHash: l2A1.Hash, - Time: l2A1.Time + conf.BlockTime, + Time: l2A1.Time + defaultConf.BlockTime, L1Origin: l1A.ID(), SequenceNumber: 2, } @@ -102,7 +128,7 @@ func TestValidBatch(t *testing.T) { Hash: testutils.RandomHash(rng), Number: l2A2.Number + 1, ParentHash: l2A2.Hash, - Time: l2A2.Time + conf.BlockTime, + Time: l2A2.Time + defaultConf.BlockTime, L1Origin: l1A.ID(), SequenceNumber: 3, } @@ -111,11 +137,29 @@ func TestValidBatch(t *testing.T) { Hash: testutils.RandomHash(rng), Number: l2A3.Number + 1, ParentHash: l2A3.Hash, - Time: l2A3.Time + conf.BlockTime, // 8 seconds larger than l1A0, 1 larger than origin + Time: l2A3.Time + defaultConf.BlockTime, // 8 seconds larger than l1A0, 1 larger than origin L1Origin: l1B.ID(), SequenceNumber: 0, } + l2B1 := eth.L2BlockRef{ + Hash: testutils.RandomHash(rng), + Number: l2B0.Number + 1, + ParentHash: l2B0.Hash, + Time: l2B0.Time + defaultConf.BlockTime, + L1Origin: l1B.ID(), + SequenceNumber: 1, + } + + l2B2 := eth.L2BlockRef{ + Hash: testutils.RandomHash(rng), + Number: l2B1.Number + 1, + ParentHash: l2B1.Hash, + Time: l2B1.Time + defaultConf.BlockTime, + L1Origin: l1B.ID(), + SequenceNumber: 2, + } + l1X := eth.L1BlockRef{ Hash: testutils.RandomHash(rng), Number: 42, @@ -138,7 +182,7 @@ func TestValidBatch(t *testing.T) { Hash: testutils.RandomHash(rng), Number: 1000, ParentHash: testutils.RandomHash(rng), - Time: 10_000 + 12 + 6 - 1, // add one block, and you get ahead of next l1 block by more than the drift + Time: 10_000 + 24 + 6 - 1, // add one block, and you get ahead of next l1 block by more than the drift L1Origin: l1X.ID(), SequenceNumber: 0, } @@ -146,16 +190,24 @@ func TestValidBatch(t *testing.T) { Hash: testutils.RandomHash(rng), Number: l2X0.Number + 1, ParentHash: l2X0.Hash, - Time: l2X0.Time + conf.BlockTime, // exceeds sequencer time drift, forced to be empty block + Time: l2X0.Time + defaultConf.BlockTime, // exceeds sequencer time drift, forced to be empty block L1Origin: l1Y.ID(), SequenceNumber: 0, } + l2Z0 := eth.L2BlockRef{ + Hash: testutils.RandomHash(rng), + Number: l2Y0.Number + 1, + ParentHash: l2Y0.Hash, + Time: l2Y0.Time + defaultConf.BlockTime, // exceeds sequencer time drift, forced to be empty block + L1Origin: l1Z.ID(), + SequenceNumber: 0, + } l2A4 := eth.L2BlockRef{ Hash: testutils.RandomHash(rng), Number: l2A3.Number + 1, ParentHash: l2A3.Hash, - Time: l2A3.Time + conf.BlockTime, // 4*2 = 8, higher than seq time drift + Time: l2A3.Time + defaultConf.BlockTime, // 4*2 = 8, higher than seq time drift L1Origin: l1A.ID(), SequenceNumber: 4, } @@ -167,20 +219,20 @@ func TestValidBatch(t *testing.T) { Time: l2A4.Time + 1, // too late for l2A4 to adopt yet } - testCases := []ValidBatchTestCase{ + singularBatchTestCases := []ValidBatchTestCase{ { Name: "missing L1 info", L1Blocks: []eth.L1BlockRef{}, L2SafeHead: l2A0, Batch: BatchWithL1InclusionBlock{ L1InclusionBlock: l1B, - Batch: NewSingularBatchData(SingularBatch{ + Batch: &SingularBatch{ ParentHash: l2A1.ParentHash, EpochNum: rollup.Epoch(l2A1.L1Origin.Number), EpochHash: l2A1.L1Origin.Hash, Timestamp: l2A1.Time, Transactions: nil, - }), + }, }, Expected: BatchUndecided, }, @@ -190,13 +242,13 @@ func TestValidBatch(t *testing.T) { L2SafeHead: l2A0, Batch: BatchWithL1InclusionBlock{ L1InclusionBlock: l1B, - Batch: NewSingularBatchData(SingularBatch{ + Batch: &SingularBatch{ ParentHash: l2A1.ParentHash, EpochNum: rollup.Epoch(l2A1.L1Origin.Number), EpochHash: l2A1.L1Origin.Hash, Timestamp: l2A1.Time + 1, // 1 too high Transactions: nil, - }), + }, }, Expected: BatchFuture, }, @@ -206,13 +258,13 @@ func TestValidBatch(t *testing.T) { L2SafeHead: l2A0, Batch: BatchWithL1InclusionBlock{ L1InclusionBlock: l1B, - Batch: NewSingularBatchData(SingularBatch{ + Batch: &SingularBatch{ ParentHash: l2A1.ParentHash, EpochNum: rollup.Epoch(l2A1.L1Origin.Number), EpochHash: l2A1.L1Origin.Hash, Timestamp: l2A0.Time, // repeating the same time Transactions: nil, - }), + }, }, Expected: BatchDrop, }, @@ -222,13 +274,13 @@ func TestValidBatch(t *testing.T) { L2SafeHead: l2A0, Batch: BatchWithL1InclusionBlock{ L1InclusionBlock: l1B, - Batch: NewSingularBatchData(SingularBatch{ + Batch: &SingularBatch{ ParentHash: l2A1.ParentHash, EpochNum: rollup.Epoch(l2A1.L1Origin.Number), EpochHash: l2A1.L1Origin.Hash, Timestamp: l2A1.Time - 1, // block time is 2, so this is 1 too low Transactions: nil, - }), + }, }, Expected: BatchDrop, }, @@ -238,13 +290,13 @@ func TestValidBatch(t *testing.T) { L2SafeHead: l2A0, Batch: BatchWithL1InclusionBlock{ L1InclusionBlock: l1B, - Batch: NewSingularBatchData(SingularBatch{ + Batch: &SingularBatch{ ParentHash: testutils.RandomHash(rng), EpochNum: rollup.Epoch(l2A1.L1Origin.Number), EpochHash: l2A1.L1Origin.Hash, Timestamp: l2A1.Time, Transactions: nil, - }), + }, }, Expected: BatchDrop, }, @@ -254,13 +306,13 @@ func TestValidBatch(t *testing.T) { L2SafeHead: l2A0, Batch: BatchWithL1InclusionBlock{ L1InclusionBlock: l1F, // included in 5th block after epoch of batch, while seq window is 4 - Batch: NewSingularBatchData(SingularBatch{ + Batch: &SingularBatch{ ParentHash: l2A1.ParentHash, EpochNum: rollup.Epoch(l2A1.L1Origin.Number), EpochHash: l2A1.L1Origin.Hash, Timestamp: l2A1.Time, Transactions: nil, - }), + }, }, Expected: BatchDrop, }, @@ -270,13 +322,13 @@ func TestValidBatch(t *testing.T) { L2SafeHead: l2B0, // we already moved on to B Batch: BatchWithL1InclusionBlock{ L1InclusionBlock: l1C, - Batch: NewSingularBatchData(SingularBatch{ + Batch: &SingularBatch{ ParentHash: l2B0.Hash, // build on top of safe head to continue EpochNum: rollup.Epoch(l2A3.L1Origin.Number), // epoch A is no longer valid EpochHash: l2A3.L1Origin.Hash, - Timestamp: l2B0.Time + conf.BlockTime, // pass the timestamp check to get too epoch check + Timestamp: l2B0.Time + defaultConf.BlockTime, // pass the timestamp check to get too epoch check Transactions: nil, - }), + }, }, Expected: BatchDrop, }, @@ -286,13 +338,13 @@ func TestValidBatch(t *testing.T) { L2SafeHead: l2A3, Batch: BatchWithL1InclusionBlock{ L1InclusionBlock: l1C, - Batch: NewSingularBatchData(SingularBatch{ + Batch: &SingularBatch{ ParentHash: l2B0.ParentHash, EpochNum: rollup.Epoch(l2B0.L1Origin.Number), EpochHash: l2B0.L1Origin.Hash, Timestamp: l2B0.Time, Transactions: nil, - }), + }, }, Expected: BatchUndecided, }, @@ -302,13 +354,13 @@ func TestValidBatch(t *testing.T) { L2SafeHead: l2A3, Batch: BatchWithL1InclusionBlock{ L1InclusionBlock: l1D, - Batch: NewSingularBatchData(SingularBatch{ + Batch: &SingularBatch{ ParentHash: l2B0.ParentHash, EpochNum: rollup.Epoch(l1C.Number), // invalid, we need to adopt epoch B before C EpochHash: l1C.Hash, Timestamp: l2B0.Time, Transactions: nil, - }), + }, }, Expected: BatchDrop, }, @@ -318,13 +370,13 @@ func TestValidBatch(t *testing.T) { L2SafeHead: l2A3, Batch: BatchWithL1InclusionBlock{ L1InclusionBlock: l1C, - Batch: NewSingularBatchData(SingularBatch{ + Batch: &SingularBatch{ ParentHash: l2B0.ParentHash, EpochNum: rollup.Epoch(l2B0.L1Origin.Number), EpochHash: l1A.Hash, // invalid, epoch hash should be l1B Timestamp: l2B0.Time, Transactions: nil, - }), + }, }, Expected: BatchDrop, }, @@ -334,13 +386,13 @@ func TestValidBatch(t *testing.T) { L2SafeHead: l2A3, Batch: BatchWithL1InclusionBlock{ L1InclusionBlock: l1B, - Batch: NewSingularBatchData(SingularBatch{ // we build l2A4, which has a timestamp of 2*4 = 8 higher than l2A0 + Batch: &SingularBatch{ // we build l2A4, which has a timestamp of 2*4 = 8 higher than l2A0 ParentHash: l2A4.ParentHash, EpochNum: rollup.Epoch(l2A4.L1Origin.Number), EpochHash: l2A4.L1Origin.Hash, Timestamp: l2A4.Time, Transactions: []hexutil.Bytes{[]byte("sequencer should not include this tx")}, - }), + }, }, Expected: BatchDrop, }, @@ -350,13 +402,13 @@ func TestValidBatch(t *testing.T) { L2SafeHead: l2X0, Batch: BatchWithL1InclusionBlock{ L1InclusionBlock: l1Z, - Batch: NewSingularBatchData(SingularBatch{ + Batch: &SingularBatch{ ParentHash: l2Y0.ParentHash, EpochNum: rollup.Epoch(l2Y0.L1Origin.Number), EpochHash: l2Y0.L1Origin.Hash, Timestamp: l2Y0.Time, // valid, but more than 6 ahead of l1Y.Time Transactions: []hexutil.Bytes{[]byte("sequencer should not include this tx")}, - }), + }, }, Expected: BatchDrop, }, @@ -366,13 +418,13 @@ func TestValidBatch(t *testing.T) { L2SafeHead: l2A3, Batch: BatchWithL1InclusionBlock{ L1InclusionBlock: l1BLate, - Batch: NewSingularBatchData(SingularBatch{ // l2A4 time < l1BLate time, so we cannot adopt origin B yet + Batch: &SingularBatch{ // l2A4 time < l1BLate time, so we cannot adopt origin B yet ParentHash: l2A4.ParentHash, EpochNum: rollup.Epoch(l2A4.L1Origin.Number), EpochHash: l2A4.L1Origin.Hash, Timestamp: l2A4.Time, Transactions: nil, - }), + }, }, Expected: BatchAccept, // accepted because empty & preserving L2 time invariant }, @@ -382,13 +434,13 @@ func TestValidBatch(t *testing.T) { L2SafeHead: l2X0, Batch: BatchWithL1InclusionBlock{ L1InclusionBlock: l1Z, - Batch: NewSingularBatchData(SingularBatch{ + Batch: &SingularBatch{ ParentHash: l2Y0.ParentHash, EpochNum: rollup.Epoch(l2Y0.L1Origin.Number), EpochHash: l2Y0.L1Origin.Hash, Timestamp: l2Y0.Time, // valid, but more than 6 ahead of l1Y.Time Transactions: nil, - }), + }, }, Expected: BatchAccept, // accepted because empty & still advancing epoch }, @@ -398,13 +450,13 @@ func TestValidBatch(t *testing.T) { L2SafeHead: l2A3, Batch: BatchWithL1InclusionBlock{ L1InclusionBlock: l1B, - Batch: NewSingularBatchData(SingularBatch{ // we build l2A4, which has a timestamp of 2*4 = 8 higher than l2A0 + Batch: &SingularBatch{ // we build l2A4, which has a timestamp of 2*4 = 8 higher than l2A0 ParentHash: l2A4.ParentHash, EpochNum: rollup.Epoch(l2A4.L1Origin.Number), EpochHash: l2A4.L1Origin.Hash, Timestamp: l2A4.Time, Transactions: nil, - }), + }, }, Expected: BatchUndecided, // we have to wait till the next epoch is in sight to check the time }, @@ -414,13 +466,13 @@ func TestValidBatch(t *testing.T) { L2SafeHead: l2A3, Batch: BatchWithL1InclusionBlock{ L1InclusionBlock: l1C, - Batch: NewSingularBatchData(SingularBatch{ // we build l2A4, which has a timestamp of 2*4 = 8 higher than l2A0 + Batch: &SingularBatch{ // we build l2A4, which has a timestamp of 2*4 = 8 higher than l2A0 ParentHash: l2A4.ParentHash, EpochNum: rollup.Epoch(l2A4.L1Origin.Number), EpochHash: l2A4.L1Origin.Hash, Timestamp: l2A4.Time, Transactions: nil, - }), + }, }, Expected: BatchDrop, // dropped because it could have advanced the epoch to B }, @@ -430,7 +482,7 @@ func TestValidBatch(t *testing.T) { L2SafeHead: l2A0, Batch: BatchWithL1InclusionBlock{ L1InclusionBlock: l1B, - Batch: NewSingularBatchData(SingularBatch{ + Batch: &SingularBatch{ ParentHash: l2A1.ParentHash, EpochNum: rollup.Epoch(l2A1.L1Origin.Number), EpochHash: l2A1.L1Origin.Hash, @@ -438,7 +490,7 @@ func TestValidBatch(t *testing.T) { Transactions: []hexutil.Bytes{ []byte{}, // empty tx data }, - }), + }, }, Expected: BatchDrop, }, @@ -448,7 +500,7 @@ func TestValidBatch(t *testing.T) { L2SafeHead: l2A0, Batch: BatchWithL1InclusionBlock{ L1InclusionBlock: l1B, - Batch: NewSingularBatchData(SingularBatch{ + Batch: &SingularBatch{ ParentHash: l2A1.ParentHash, EpochNum: rollup.Epoch(l2A1.L1Origin.Number), EpochHash: l2A1.L1Origin.Hash, @@ -456,7 +508,7 @@ func TestValidBatch(t *testing.T) { Transactions: []hexutil.Bytes{ []byte{types.DepositTxType, 0}, // piece of data alike to a deposit }, - }), + }, }, Expected: BatchDrop, }, @@ -466,7 +518,7 @@ func TestValidBatch(t *testing.T) { L2SafeHead: l2A0, Batch: BatchWithL1InclusionBlock{ L1InclusionBlock: l1B, - Batch: NewSingularBatchData(SingularBatch{ + Batch: &SingularBatch{ ParentHash: l2A1.ParentHash, EpochNum: rollup.Epoch(l2A1.L1Origin.Number), EpochHash: l2A1.L1Origin.Hash, @@ -475,7 +527,7 @@ func TestValidBatch(t *testing.T) { []byte{0x02, 0x42, 0x13, 0x37}, []byte{0x02, 0xde, 0xad, 0xbe, 0xef}, }, - }), + }, }, Expected: BatchAccept, }, @@ -485,7 +537,7 @@ func TestValidBatch(t *testing.T) { L2SafeHead: l2A3, Batch: BatchWithL1InclusionBlock{ L1InclusionBlock: l1C, - Batch: NewSingularBatchData(SingularBatch{ + Batch: &SingularBatch{ ParentHash: l2B0.ParentHash, EpochNum: rollup.Epoch(l2B0.L1Origin.Number), EpochHash: l2B0.L1Origin.Hash, @@ -494,7 +546,7 @@ func TestValidBatch(t *testing.T) { []byte{0x02, 0x42, 0x13, 0x37}, []byte{0x02, 0xde, 0xad, 0xbe, 0xef}, }, - }), + }, }, Expected: BatchAccept, }, @@ -504,25 +556,1107 @@ func TestValidBatch(t *testing.T) { L2SafeHead: l2A2, Batch: BatchWithL1InclusionBlock{ L1InclusionBlock: l1B, - Batch: NewSingularBatchData(SingularBatch{ // we build l2B0', which starts a new epoch too early + Batch: &SingularBatch{ // we build l2B0', which starts a new epoch too early ParentHash: l2A2.Hash, EpochNum: rollup.Epoch(l2B0.L1Origin.Number), EpochHash: l2B0.L1Origin.Hash, - Timestamp: l2A2.Time + conf.BlockTime, + Timestamp: l2A2.Time + defaultConf.BlockTime, Transactions: nil, - }), + }, }, Expected: BatchDrop, }, } + spanBatchTestCases := []ValidBatchTestCase{ + { + Name: "missing L1 info", + L1Blocks: []eth.L1BlockRef{}, + L2SafeHead: l2A0, + Batch: BatchWithL1InclusionBlock{ + L1InclusionBlock: l1B, + Batch: NewSpanBatch([]*SingularBatch{ + { + ParentHash: l2A1.ParentHash, + EpochNum: rollup.Epoch(l2A1.L1Origin.Number), + EpochHash: l2A1.L1Origin.Hash, + Timestamp: l2A1.Time, + Transactions: nil, + }, + }), + }, + Expected: BatchUndecided, + ExpectedLog: "missing L1 block input, cannot proceed with batch checking", + SpanBatchTime: &minTs, + }, + { + Name: "future timestamp", + L1Blocks: []eth.L1BlockRef{l1A, l1B, l1C}, + L2SafeHead: l2A0, + Batch: BatchWithL1InclusionBlock{ + L1InclusionBlock: l1B, + Batch: NewSpanBatch([]*SingularBatch{ + { + ParentHash: l2A1.ParentHash, + EpochNum: rollup.Epoch(l2A1.L1Origin.Number), + EpochHash: l2A1.L1Origin.Hash, + Timestamp: l2A1.Time + 1, // 1 too high + Transactions: nil, + }, + }), + }, + Expected: BatchFuture, + ExpectedLog: "received out-of-order batch for future processing after next batch", + SpanBatchTime: &minTs, + }, + { + Name: "misaligned timestamp", + L1Blocks: []eth.L1BlockRef{l1A, l1B, l1C}, + L2SafeHead: l2A0, + Batch: BatchWithL1InclusionBlock{ + L1InclusionBlock: l1B, + Batch: NewSpanBatch([]*SingularBatch{ + { + ParentHash: l2A1.ParentHash, + EpochNum: rollup.Epoch(l2A1.L1Origin.Number), + EpochHash: l2A1.L1Origin.Hash, + Timestamp: l2A1.Time - 1, // block time is 2, so this is 1 too low + Transactions: nil, + }, + }), + }, + Expected: BatchDrop, + ExpectedLog: "span batch has no new blocks after safe head", + SpanBatchTime: &minTs, + }, + { + Name: "invalid parent block hash", + L1Blocks: []eth.L1BlockRef{l1A, l1B, l1C}, + L2SafeHead: l2A0, + Batch: BatchWithL1InclusionBlock{ + L1InclusionBlock: l1B, + Batch: NewSpanBatch([]*SingularBatch{ + { + ParentHash: testutils.RandomHash(rng), + EpochNum: rollup.Epoch(l2A1.L1Origin.Number), + EpochHash: l2A1.L1Origin.Hash, + Timestamp: l2A1.Time, + Transactions: nil, + }, + }), + }, + Expected: BatchDrop, + ExpectedLog: "ignoring batch with mismatching parent hash", + SpanBatchTime: &minTs, + }, + { + Name: "sequence window expired", + L1Blocks: []eth.L1BlockRef{l1A, l1B, l1C, l1D, l1E, l1F}, + L2SafeHead: l2A0, + Batch: BatchWithL1InclusionBlock{ + L1InclusionBlock: l1F, + Batch: NewSpanBatch([]*SingularBatch{ + { + ParentHash: l2A1.ParentHash, + EpochNum: rollup.Epoch(l2A1.L1Origin.Number), + EpochHash: l2A1.L1Origin.Hash, + Timestamp: l2A1.Time, + Transactions: nil, + }, + }), + }, + Expected: BatchDrop, + ExpectedLog: "batch was included too late, sequence window expired", + SpanBatchTime: &minTs, + }, + { + Name: "epoch too old, but good parent hash and timestamp", // repeat of now outdated l2A3 data + L1Blocks: []eth.L1BlockRef{l1B, l1C, l1D}, + L2SafeHead: l2B0, // we already moved on to B + Batch: BatchWithL1InclusionBlock{ + L1InclusionBlock: l1C, + Batch: NewSpanBatch([]*SingularBatch{ + { + ParentHash: l2B0.Hash, // build on top of safe head to continue + EpochNum: rollup.Epoch(l2A3.L1Origin.Number), // epoch A is no longer valid + EpochHash: l2A3.L1Origin.Hash, + Timestamp: l2B0.Time + defaultConf.BlockTime, // pass the timestamp check to get too epoch check + Transactions: nil, + }, + { + EpochNum: rollup.Epoch(l1B.Number), + EpochHash: l1B.Hash, // pass the l1 origin check + Timestamp: l2B0.Time + defaultConf.BlockTime*2, + Transactions: nil, + }, + }), + }, + Expected: BatchDrop, + ExpectedLog: "dropped batch, epoch is too old", + SpanBatchTime: &minTs, + }, + { + Name: "insufficient L1 info for eager derivation", + L1Blocks: []eth.L1BlockRef{l1A}, // don't know about l1B yet + L2SafeHead: l2A3, + Batch: BatchWithL1InclusionBlock{ + L1InclusionBlock: l1C, + Batch: NewSpanBatch([]*SingularBatch{ + { + ParentHash: l2B0.ParentHash, + EpochNum: rollup.Epoch(l2B0.L1Origin.Number), + EpochHash: l2B0.L1Origin.Hash, + Timestamp: l2B0.Time, + Transactions: nil, + }, + }), + }, + Expected: BatchUndecided, + ExpectedLog: "eager batch wants to advance epoch, but could not without more L1 blocks", + SpanBatchTime: &minTs, + }, + { + Name: "insufficient L1 info for eager derivation - long span", + L1Blocks: []eth.L1BlockRef{l1A}, // don't know about l1B yet + L2SafeHead: l2A2, + Batch: BatchWithL1InclusionBlock{ + L1InclusionBlock: l1C, + Batch: NewSpanBatch([]*SingularBatch{ + { + ParentHash: l2A3.ParentHash, + EpochNum: rollup.Epoch(l2A3.L1Origin.Number), + EpochHash: l2A3.L1Origin.Hash, + Timestamp: l2A3.Time, + Transactions: nil, + }, + { + ParentHash: l2B0.ParentHash, + EpochNum: rollup.Epoch(l2B0.L1Origin.Number), + EpochHash: l2B0.L1Origin.Hash, + Timestamp: l2B0.Time, + Transactions: nil, + }, + }), + }, + Expected: BatchUndecided, + ExpectedLog: "need more l1 blocks to check entire origins of span batch", + SpanBatchTime: &minTs, + }, + { + Name: "epoch too new", + L1Blocks: []eth.L1BlockRef{l1A, l1B, l1C, l1D}, + L2SafeHead: l2A3, + Batch: BatchWithL1InclusionBlock{ + L1InclusionBlock: l1D, + Batch: NewSpanBatch([]*SingularBatch{ + { + ParentHash: l2B0.ParentHash, + EpochNum: rollup.Epoch(l1C.Number), // invalid, we need to adopt epoch B before C + EpochHash: l1C.Hash, + Timestamp: l2B0.Time, + Transactions: nil, + }, + }), + }, + Expected: BatchDrop, + ExpectedLog: "batch is for future epoch too far ahead, while it has the next timestamp, so it must be invalid", + SpanBatchTime: &minTs, + }, + { + Name: "epoch hash wrong", + L1Blocks: []eth.L1BlockRef{l1A, l1B}, + L2SafeHead: l2A3, + Batch: BatchWithL1InclusionBlock{ + L1InclusionBlock: l1C, + Batch: NewSpanBatch([]*SingularBatch{ + { + ParentHash: l2B0.ParentHash, + EpochNum: rollup.Epoch(l2B0.L1Origin.Number), + EpochHash: l1A.Hash, // invalid, epoch hash should be l1B + Timestamp: l2B0.Time, + Transactions: nil, + }, + }), + }, + Expected: BatchDrop, + ExpectedLog: "batch is for different L1 chain, epoch hash does not match", + SpanBatchTime: &minTs, + }, + { + Name: "epoch hash wrong - long span", + L1Blocks: []eth.L1BlockRef{l1A, l1B}, + L2SafeHead: l2A2, + Batch: BatchWithL1InclusionBlock{ + L1InclusionBlock: l1C, + Batch: NewSpanBatch([]*SingularBatch{ + { // valid batch + ParentHash: l2A3.ParentHash, + EpochNum: rollup.Epoch(l2A3.L1Origin.Number), + EpochHash: l1A.Hash, + Timestamp: l2A3.Time, + Transactions: nil, + }, + { + ParentHash: l2B0.ParentHash, + EpochNum: rollup.Epoch(l2B0.L1Origin.Number), + EpochHash: l1A.Hash, // invalid, epoch hash should be l1B + Timestamp: l2B0.Time, + Transactions: nil, + }, + }), + }, + Expected: BatchDrop, + ExpectedLog: "batch is for different L1 chain, epoch hash does not match", + SpanBatchTime: &minTs, + }, + { + Name: "sequencer time drift on same epoch with non-empty txs", + L1Blocks: []eth.L1BlockRef{l1A, l1B}, + L2SafeHead: l2A3, + Batch: BatchWithL1InclusionBlock{ + L1InclusionBlock: l1B, + Batch: NewSpanBatch([]*SingularBatch{ + { // we build l2A4, which has a timestamp of 2*4 = 8 higher than l2A0 + ParentHash: l2A4.ParentHash, + EpochNum: rollup.Epoch(l2A4.L1Origin.Number), + EpochHash: l2A4.L1Origin.Hash, + Timestamp: l2A4.Time, + Transactions: []hexutil.Bytes{randTxData}, + }, + }), + }, + Expected: BatchDrop, + ExpectedLog: "batch exceeded sequencer time drift, sequencer must adopt new L1 origin to include transactions again", + SpanBatchTime: &minTs, + }, + { + Name: "sequencer time drift on same epoch with non-empty txs - long span", + L1Blocks: []eth.L1BlockRef{l1A, l1B}, + L2SafeHead: l2A2, + Batch: BatchWithL1InclusionBlock{ + L1InclusionBlock: l1B, + Batch: NewSpanBatch([]*SingularBatch{ + { // valid batch + ParentHash: l2A3.ParentHash, + EpochNum: rollup.Epoch(l2A3.L1Origin.Number), + EpochHash: l2A3.L1Origin.Hash, + Timestamp: l2A3.Time, + Transactions: []hexutil.Bytes{randTxData}, + }, + { // we build l2A4, which has a timestamp of 2*4 = 8 higher than l2A0 + ParentHash: l2A4.ParentHash, + EpochNum: rollup.Epoch(l2A4.L1Origin.Number), + EpochHash: l2A4.L1Origin.Hash, + Timestamp: l2A4.Time, + Transactions: []hexutil.Bytes{randTxData}, + }, + }), + }, + Expected: BatchDrop, + ExpectedLog: "batch exceeded sequencer time drift, sequencer must adopt new L1 origin to include transactions again", + SpanBatchTime: &minTs, + }, + { + Name: "sequencer time drift on changing epoch with non-empty txs", + L1Blocks: []eth.L1BlockRef{l1X, l1Y, l1Z}, + L2SafeHead: l2X0, + Batch: BatchWithL1InclusionBlock{ + L1InclusionBlock: l1Z, + Batch: NewSpanBatch([]*SingularBatch{ + { + ParentHash: l2Y0.ParentHash, + EpochNum: rollup.Epoch(l2Y0.L1Origin.Number), + EpochHash: l2Y0.L1Origin.Hash, + Timestamp: l2Y0.Time, // valid, but more than 6 ahead of l1Y.Time + Transactions: []hexutil.Bytes{randTxData}, + }, + }), + }, + Expected: BatchDrop, + ExpectedLog: "batch exceeded sequencer time drift, sequencer must adopt new L1 origin to include transactions again", + SpanBatchTime: &minTs, + }, + { + Name: "sequencer time drift on same epoch with empty txs and late next epoch", + L1Blocks: []eth.L1BlockRef{l1A, l1BLate}, + L2SafeHead: l2A3, + Batch: BatchWithL1InclusionBlock{ + L1InclusionBlock: l1BLate, + Batch: NewSpanBatch([]*SingularBatch{ + { // l2A4 time < l1BLate time, so we cannot adopt origin B yet + ParentHash: l2A4.ParentHash, + EpochNum: rollup.Epoch(l2A4.L1Origin.Number), + EpochHash: l2A4.L1Origin.Hash, + Timestamp: l2A4.Time, + Transactions: nil, + }, + }), + }, + Expected: BatchAccept, // accepted because empty & preserving L2 time invariant + SpanBatchTime: &minTs, + }, + { + Name: "sequencer time drift on changing epoch with empty txs", + L1Blocks: []eth.L1BlockRef{l1X, l1Y, l1Z}, + L2SafeHead: l2X0, + Batch: BatchWithL1InclusionBlock{ + L1InclusionBlock: l1Z, + Batch: NewSpanBatch([]*SingularBatch{ + { + ParentHash: l2Y0.ParentHash, + EpochNum: rollup.Epoch(l2Y0.L1Origin.Number), + EpochHash: l2Y0.L1Origin.Hash, + Timestamp: l2Y0.Time, // valid, but more than 6 ahead of l1Y.Time + Transactions: nil, + }, + { + ParentHash: l2Z0.ParentHash, + EpochNum: rollup.Epoch(l2Z0.L1Origin.Number), + EpochHash: l2Z0.L1Origin.Hash, + Timestamp: l2Z0.Time, // valid, but more than 6 ahead of l1Y.Time + Transactions: nil, + }, + }), + }, + Expected: BatchAccept, // accepted because empty & still advancing epoch + SpanBatchTime: &minTs, + NotExpectedLog: "continuing with empty batch before late L1 block to preserve L2 time invariant", + }, + { + Name: "sequencer time drift on same epoch with empty txs and no next epoch in sight yet", + L1Blocks: []eth.L1BlockRef{l1A}, + L2SafeHead: l2A3, + Batch: BatchWithL1InclusionBlock{ + L1InclusionBlock: l1B, + Batch: NewSpanBatch([]*SingularBatch{ + { // we build l2A4, which has a timestamp of 2*4 = 8 higher than l2A0 + ParentHash: l2A4.ParentHash, + EpochNum: rollup.Epoch(l2A4.L1Origin.Number), + EpochHash: l2A4.L1Origin.Hash, + Timestamp: l2A4.Time, + Transactions: nil, + }, + }), + }, + Expected: BatchUndecided, // we have to wait till the next epoch is in sight to check the time + ExpectedLog: "without the next L1 origin we cannot determine yet if this empty batch that exceeds the time drift is still valid", + SpanBatchTime: &minTs, + }, + { + Name: "sequencer time drift on same epoch with empty txs and no next epoch in sight yet - long span", + L1Blocks: []eth.L1BlockRef{l1A}, + L2SafeHead: l2A2, + Batch: BatchWithL1InclusionBlock{ + L1InclusionBlock: l1B, + Batch: NewSpanBatch([]*SingularBatch{ + { // valid batch + ParentHash: l2A3.ParentHash, + EpochNum: rollup.Epoch(l2A3.L1Origin.Number), + EpochHash: l2A3.L1Origin.Hash, + Timestamp: l2A3.Time, + Transactions: nil, + }, + { // we build l2A4, which has a timestamp of 2*4 = 8 higher than l2A0 + ParentHash: l2A4.ParentHash, + EpochNum: rollup.Epoch(l2A4.L1Origin.Number), + EpochHash: l2A4.L1Origin.Hash, + Timestamp: l2A4.Time, + Transactions: nil, + }, + }), + }, + Expected: BatchUndecided, // we have to wait till the next epoch is in sight to check the time + ExpectedLog: "without the next L1 origin we cannot determine yet if this empty batch that exceeds the time drift is still valid", + SpanBatchTime: &minTs, + }, + { + Name: "sequencer time drift on same epoch with empty txs and but in-sight epoch that invalidates it", + L1Blocks: []eth.L1BlockRef{l1A, l1B, l1C}, + L2SafeHead: l2A3, + Batch: BatchWithL1InclusionBlock{ + L1InclusionBlock: l1C, + Batch: NewSpanBatch([]*SingularBatch{ + { // we build l2A4, which has a timestamp of 2*4 = 8 higher than l2A0 + ParentHash: l2A4.ParentHash, + EpochNum: rollup.Epoch(l2A4.L1Origin.Number), + EpochHash: l2A4.L1Origin.Hash, + Timestamp: l2A4.Time, + Transactions: nil, + }, + }), + }, + Expected: BatchDrop, // dropped because it could have advanced the epoch to B + ExpectedLog: "batch exceeded sequencer time drift without adopting next origin, and next L1 origin would have been valid", + SpanBatchTime: &minTs, + }, + { + Name: "sequencer time drift on same epoch with empty txs and but in-sight epoch that invalidates it - long span", + L1Blocks: []eth.L1BlockRef{l1A, l1B, l1C}, + L2SafeHead: l2A2, + Batch: BatchWithL1InclusionBlock{ + L1InclusionBlock: l1C, + Batch: NewSpanBatch([]*SingularBatch{ + { // valid batch + ParentHash: l2A3.ParentHash, + EpochNum: rollup.Epoch(l2A3.L1Origin.Number), + EpochHash: l2A3.L1Origin.Hash, + Timestamp: l2A3.Time, + Transactions: nil, + }, + { // we build l2A4, which has a timestamp of 2*4 = 8 higher than l2A0 + ParentHash: l2A4.ParentHash, + EpochNum: rollup.Epoch(l2A4.L1Origin.Number), + EpochHash: l2A4.L1Origin.Hash, + Timestamp: l2A4.Time, + Transactions: nil, + }, + }), + }, + Expected: BatchDrop, // dropped because it could have advanced the epoch to B + ExpectedLog: "batch exceeded sequencer time drift without adopting next origin, and next L1 origin would have been valid", + SpanBatchTime: &minTs, + }, + { + Name: "empty tx included", + L1Blocks: []eth.L1BlockRef{l1A, l1B}, + L2SafeHead: l2A0, + Batch: BatchWithL1InclusionBlock{ + L1InclusionBlock: l1B, + Batch: NewSpanBatch([]*SingularBatch{ + { + ParentHash: l2A1.ParentHash, + EpochNum: rollup.Epoch(l2A1.L1Origin.Number), + EpochHash: l2A1.L1Origin.Hash, + Timestamp: l2A1.Time, + Transactions: []hexutil.Bytes{ + []byte{}, // empty tx data + }, + }, + }), + }, + Expected: BatchDrop, + ExpectedLog: "transaction data must not be empty, but found empty tx", + SpanBatchTime: &minTs, + }, + { + Name: "deposit tx included", + L1Blocks: []eth.L1BlockRef{l1A, l1B}, + L2SafeHead: l2A0, + Batch: BatchWithL1InclusionBlock{ + L1InclusionBlock: l1B, + Batch: NewSpanBatch([]*SingularBatch{ + { + ParentHash: l2A1.ParentHash, + EpochNum: rollup.Epoch(l2A1.L1Origin.Number), + EpochHash: l2A1.L1Origin.Hash, + Timestamp: l2A1.Time, + Transactions: []hexutil.Bytes{ + []byte{types.DepositTxType, 0}, // piece of data alike to a deposit + }, + }, + }), + }, + Expected: BatchDrop, + ExpectedLog: "sequencers may not embed any deposits into batch data, but found tx that has one", + SpanBatchTime: &minTs, + }, + { + Name: "valid batch same epoch", + L1Blocks: []eth.L1BlockRef{l1A, l1B}, + L2SafeHead: l2A0, + Batch: BatchWithL1InclusionBlock{ + L1InclusionBlock: l1B, + Batch: NewSpanBatch([]*SingularBatch{ + { + ParentHash: l2A1.ParentHash, + EpochNum: rollup.Epoch(l2A1.L1Origin.Number), + EpochHash: l2A1.L1Origin.Hash, + Timestamp: l2A1.Time, + Transactions: []hexutil.Bytes{randTxData}, + }, + }), + }, + Expected: BatchAccept, + SpanBatchTime: &minTs, + }, + { + Name: "valid batch changing epoch", + L1Blocks: []eth.L1BlockRef{l1A, l1B, l1C}, + L2SafeHead: l2A3, + Batch: BatchWithL1InclusionBlock{ + L1InclusionBlock: l1C, + Batch: NewSpanBatch([]*SingularBatch{ + { + ParentHash: l2B0.ParentHash, + EpochNum: rollup.Epoch(l2B0.L1Origin.Number), + EpochHash: l2B0.L1Origin.Hash, + Timestamp: l2B0.Time, + Transactions: []hexutil.Bytes{randTxData}, + }, + }), + }, + Expected: BatchAccept, + SpanBatchTime: &minTs, + }, + { + Name: "batch with L2 time before L1 time", + L1Blocks: []eth.L1BlockRef{l1A, l1B, l1C}, + L2SafeHead: l2A2, + Batch: BatchWithL1InclusionBlock{ + L1InclusionBlock: l1B, + Batch: NewSpanBatch([]*SingularBatch{ + { // we build l2B0, which starts a new epoch too early + ParentHash: l2A2.Hash, + EpochNum: rollup.Epoch(l2B0.L1Origin.Number), + EpochHash: l2B0.L1Origin.Hash, + Timestamp: l2A2.Time + defaultConf.BlockTime, + Transactions: nil, + }, + }), + }, + Expected: BatchDrop, + ExpectedLog: "block timestamp is less than L1 origin timestamp", + SpanBatchTime: &minTs, + }, + { + Name: "batch with L2 time before L1 time - long span", + L1Blocks: []eth.L1BlockRef{l1A, l1B, l1C}, + L2SafeHead: l2A1, + Batch: BatchWithL1InclusionBlock{ + L1InclusionBlock: l1B, + Batch: NewSpanBatch([]*SingularBatch{ + { // valid batch + ParentHash: l2A1.Hash, + EpochNum: rollup.Epoch(l2A2.L1Origin.Number), + EpochHash: l2A2.L1Origin.Hash, + Timestamp: l2A2.Time, + Transactions: nil, + }, + { // we build l2B0, which starts a new epoch too early + ParentHash: l2A2.Hash, + EpochNum: rollup.Epoch(l2B0.L1Origin.Number), + EpochHash: l2B0.L1Origin.Hash, + Timestamp: l2A2.Time + defaultConf.BlockTime, + Transactions: nil, + }, + }), + }, + Expected: BatchDrop, + ExpectedLog: "block timestamp is less than L1 origin timestamp", + SpanBatchTime: &minTs, + }, + { + Name: "valid overlapping batch", + L1Blocks: []eth.L1BlockRef{l1A, l1B}, + L2SafeHead: l2A2, + Batch: BatchWithL1InclusionBlock{ + L1InclusionBlock: l1B, + Batch: NewSpanBatch([]*SingularBatch{ + { + ParentHash: l2A1.Hash, + EpochNum: rollup.Epoch(l2A2.L1Origin.Number), + EpochHash: l2A2.L1Origin.Hash, + Timestamp: l2A2.Time, + Transactions: nil, + }, + { + ParentHash: l2A2.Hash, + EpochNum: rollup.Epoch(l2A3.L1Origin.Number), + EpochHash: l2A3.L1Origin.Hash, + Timestamp: l2A3.Time, + Transactions: nil, + }, + }), + }, + Expected: BatchAccept, + SpanBatchTime: &minTs, + }, + { + Name: "longer overlapping batch", + L1Blocks: []eth.L1BlockRef{l1A, l1B}, + L2SafeHead: l2A2, + Batch: BatchWithL1InclusionBlock{ + L1InclusionBlock: l1B, + Batch: NewSpanBatch([]*SingularBatch{ + { + ParentHash: l2A0.Hash, + EpochNum: rollup.Epoch(l2A1.L1Origin.Number), + EpochHash: l2A1.L1Origin.Hash, + Timestamp: l2A1.Time, + Transactions: nil, + }, + { + ParentHash: l2A1.Hash, + EpochNum: rollup.Epoch(l2A2.L1Origin.Number), + EpochHash: l2A2.L1Origin.Hash, + Timestamp: l2A2.Time, + Transactions: nil, + }, + { + ParentHash: l2A2.Hash, + EpochNum: rollup.Epoch(l2A3.L1Origin.Number), + EpochHash: l2A3.L1Origin.Hash, + Timestamp: l2A3.Time, + Transactions: nil, + }, + }), + }, + Expected: BatchAccept, + SpanBatchTime: &minTs, + }, + { + Name: "fully overlapping batch", + L1Blocks: []eth.L1BlockRef{l1A, l1B}, + L2SafeHead: l2A2, + Batch: BatchWithL1InclusionBlock{ + L1InclusionBlock: l1B, + Batch: NewSpanBatch([]*SingularBatch{ + { + ParentHash: l2A0.Hash, + EpochNum: rollup.Epoch(l2A1.L1Origin.Number), + EpochHash: l2A1.L1Origin.Hash, + Timestamp: l2A1.Time, + Transactions: nil, + }, + { + ParentHash: l2A1.Hash, + EpochNum: rollup.Epoch(l2A2.L1Origin.Number), + EpochHash: l2A2.L1Origin.Hash, + Timestamp: l2A2.Time, + Transactions: nil, + }, + }), + }, + Expected: BatchDrop, + ExpectedLog: "span batch has no new blocks after safe head", + SpanBatchTime: &minTs, + }, + { + Name: "overlapping batch with invalid parent hash", + L1Blocks: []eth.L1BlockRef{l1A, l1B}, + L2SafeHead: l2A2, + Batch: BatchWithL1InclusionBlock{ + L1InclusionBlock: l1B, + Batch: NewSpanBatch([]*SingularBatch{ + { + ParentHash: l2A0.Hash, + EpochNum: rollup.Epoch(l2A2.L1Origin.Number), + EpochHash: l2A2.L1Origin.Hash, + Timestamp: l2A2.Time, + Transactions: nil, + }, + { + ParentHash: l2A2.Hash, + EpochNum: rollup.Epoch(l2A3.L1Origin.Number), + EpochHash: l2A3.L1Origin.Hash, + Timestamp: l2A3.Time, + Transactions: nil, + }, + }), + }, + Expected: BatchDrop, + ExpectedLog: "ignoring batch with mismatching parent hash", + SpanBatchTime: &minTs, + }, + { + Name: "overlapping batch with invalid origin number", + L1Blocks: []eth.L1BlockRef{l1A, l1B}, + L2SafeHead: l2A2, + Batch: BatchWithL1InclusionBlock{ + L1InclusionBlock: l1B, + Batch: NewSpanBatch([]*SingularBatch{ + { + ParentHash: l2A1.Hash, + EpochNum: rollup.Epoch(l2A2.L1Origin.Number) + 1, + EpochHash: l2A2.L1Origin.Hash, + Timestamp: l2A2.Time, + Transactions: nil, + }, + { + ParentHash: l2A2.Hash, + EpochNum: rollup.Epoch(l2A3.L1Origin.Number), + EpochHash: l2A3.L1Origin.Hash, + Timestamp: l2A3.Time, + Transactions: nil, + }, + }), + }, + Expected: BatchDrop, + ExpectedLog: "overlapped block's L1 origin number does not match", + SpanBatchTime: &minTs, + }, + { + Name: "overlapping batch with invalid tx", + L1Blocks: []eth.L1BlockRef{l1A, l1B}, + L2SafeHead: l2A2, + Batch: BatchWithL1InclusionBlock{ + L1InclusionBlock: l1B, + Batch: NewSpanBatch([]*SingularBatch{ + { + ParentHash: l2A1.Hash, + EpochNum: rollup.Epoch(l2A2.L1Origin.Number), + EpochHash: l2A2.L1Origin.Hash, + Timestamp: l2A2.Time, + Transactions: []hexutil.Bytes{randTxData}, + }, + { + ParentHash: l2A2.Hash, + EpochNum: rollup.Epoch(l2A3.L1Origin.Number), + EpochHash: l2A3.L1Origin.Hash, + Timestamp: l2A3.Time, + Transactions: nil, + }, + }), + }, + Expected: BatchDrop, + ExpectedLog: "overlapped block's tx count does not match", + SpanBatchTime: &minTs, + }, + { + Name: "overlapping batch l2 fetcher error", + L1Blocks: []eth.L1BlockRef{l1A, l1B}, + L2SafeHead: l2A1, + Batch: BatchWithL1InclusionBlock{ + L1InclusionBlock: l1B, + Batch: NewSpanBatch([]*SingularBatch{ + { + ParentHash: l2A0.ParentHash, + EpochNum: rollup.Epoch(l2A0.L1Origin.Number), + EpochHash: l2A0.L1Origin.Hash, + Timestamp: l2A0.Time, + Transactions: nil, + }, + { + ParentHash: l2A0.Hash, + EpochNum: rollup.Epoch(l2A1.L1Origin.Number), + EpochHash: l2A1.L1Origin.Hash, + Timestamp: l2A1.Time, + Transactions: nil, + }, + { + ParentHash: l2A1.Hash, + EpochNum: rollup.Epoch(l2A2.L1Origin.Number), + EpochHash: l2A2.L1Origin.Hash, + Timestamp: l2A2.Time, + Transactions: nil, + }, + }), + }, + Expected: BatchUndecided, + ExpectedLog: "failed to fetch L2 block", + SpanBatchTime: &minTs, + }, + { + Name: "short block time", + L1Blocks: []eth.L1BlockRef{l1A, l1B}, + L2SafeHead: l2A0, + Batch: BatchWithL1InclusionBlock{ + L1InclusionBlock: l1B, + Batch: NewSpanBatch([]*SingularBatch{ + { + ParentHash: l2A0.Hash, + EpochNum: rollup.Epoch(l2A1.L1Origin.Number), + EpochHash: l2A1.L1Origin.Hash, + Timestamp: l2A0.Time + 1, + Transactions: nil, + }, + { + ParentHash: l2A1.Hash, + EpochNum: rollup.Epoch(l2A2.L1Origin.Number), + EpochHash: l2A2.L1Origin.Hash, + Timestamp: l2A1.Time + 1, + Transactions: nil, + }, + }), + }, + Expected: BatchDrop, + ExpectedLog: "batch has misaligned timestamp, block time is too short", + SpanBatchTime: &minTs, + }, + { + Name: "misaligned batch", + L1Blocks: []eth.L1BlockRef{l1A, l1B}, + L2SafeHead: l2A0, + Batch: BatchWithL1InclusionBlock{ + L1InclusionBlock: l1B, + Batch: NewSpanBatch([]*SingularBatch{ + { + ParentHash: l2A0.Hash, + EpochNum: rollup.Epoch(l2A1.L1Origin.Number), + EpochHash: l2A1.L1Origin.Hash, + Timestamp: l2A0.Time - 1, + Transactions: nil, + }, + { + ParentHash: l2A1.Hash, + EpochNum: rollup.Epoch(l2A2.L1Origin.Number), + EpochHash: l2A2.L1Origin.Hash, + Timestamp: l2A1.Time, + Transactions: nil, + }, + }), + }, + Expected: BatchDrop, + ExpectedLog: "batch has misaligned timestamp, not overlapped exactly", + SpanBatchTime: &minTs, + }, + { + Name: "failed to fetch overlapping block payload", + L1Blocks: []eth.L1BlockRef{l1A, l1B}, + L2SafeHead: l2A3, + Batch: BatchWithL1InclusionBlock{ + L1InclusionBlock: l1B, + Batch: NewSpanBatch([]*SingularBatch{ + { + ParentHash: l2A2.Hash, + EpochNum: rollup.Epoch(l2A3.L1Origin.Number), + EpochHash: l2A3.L1Origin.Hash, + Timestamp: l2A3.Time, + Transactions: nil, + }, + { + ParentHash: l2A3.Hash, + EpochNum: rollup.Epoch(l2B0.L1Origin.Number), + EpochHash: l2B0.L1Origin.Hash, + Timestamp: l2B0.Time, + Transactions: nil, + }, + }), + }, + Expected: BatchUndecided, + ExpectedLog: "failed to fetch L2 block payload", + SpanBatchTime: &minTs, + }, + { + Name: "singular batch before hard fork", + L1Blocks: []eth.L1BlockRef{l1A, l1B}, + L2SafeHead: l2A0, + Batch: BatchWithL1InclusionBlock{ + L1InclusionBlock: l1B, + Batch: &SingularBatch{ + ParentHash: l2A1.ParentHash, + EpochNum: rollup.Epoch(l2A1.L1Origin.Number), + EpochHash: l2A1.L1Origin.Hash, + Timestamp: l2A1.Time, + Transactions: []hexutil.Bytes{randTxData}, + }, + }, + SpanBatchTime: &l1B.Time, + Expected: BatchAccept, + }, + { + Name: "span batch before hard fork", + L1Blocks: []eth.L1BlockRef{l1A, l1B}, + L2SafeHead: l2A0, + Batch: BatchWithL1InclusionBlock{ + L1InclusionBlock: l1B, + Batch: NewSpanBatch([]*SingularBatch{ + { + ParentHash: l2A1.ParentHash, + EpochNum: rollup.Epoch(l2A1.L1Origin.Number), + EpochHash: l2A1.L1Origin.Hash, + Timestamp: l2A1.Time, + Transactions: []hexutil.Bytes{randTxData}, + }, + }), + }, + SpanBatchTime: &l1B.Time, + Expected: BatchDrop, + ExpectedLog: "received SpanBatch with L1 origin before SpanBatch hard fork", + }, + { + Name: "singular batch after hard fork", + L1Blocks: []eth.L1BlockRef{l1A, l1B}, + L2SafeHead: l2A0, + Batch: BatchWithL1InclusionBlock{ + L1InclusionBlock: l1B, + Batch: &SingularBatch{ + ParentHash: l2A1.ParentHash, + EpochNum: rollup.Epoch(l2A1.L1Origin.Number), + EpochHash: l2A1.L1Origin.Hash, + Timestamp: l2A1.Time, + Transactions: []hexutil.Bytes{randTxData}, + }, + }, + SpanBatchTime: &l1A.Time, + Expected: BatchAccept, + }, + { + Name: "span batch after hard fork", + L1Blocks: []eth.L1BlockRef{l1A, l1B}, + L2SafeHead: l2A0, + Batch: BatchWithL1InclusionBlock{ + L1InclusionBlock: l1B, + Batch: NewSpanBatch([]*SingularBatch{ + { + ParentHash: l2A1.ParentHash, + EpochNum: rollup.Epoch(l2A1.L1Origin.Number), + EpochHash: l2A1.L1Origin.Hash, + Timestamp: l2A1.Time, + Transactions: []hexutil.Bytes{randTxData}, + }, + }), + }, + SpanBatchTime: &l1A.Time, + Expected: BatchAccept, + }, + } // Log level can be increased for debugging purposes logger := testlog.Logger(t, log.LvlError) - for _, testCase := range testCases { - t.Run(testCase.Name, func(t *testing.T) { - validity := CheckBatch(&conf, logger, testCase.L1Blocks, testCase.L2SafeHead, &testCase.Batch) - require.Equal(t, testCase.Expected, validity, "batch check must return expected validity level") + // Create a test log handler to check expected logs + var logBuf bytes.Buffer + handler := TestLogHandler{handler: logger.GetHandler(), logs: &logBuf} + logger.SetHandler(&handler) + + l2Client := testutils.MockL2Client{} + var nilErr error + tempErr := errors.New("temp error") + // will return an error for block #99 (parent of l2A0) + l2Client.Mock.On("L2BlockRefByNumber", l2A0.Number-1).Return(eth.L2BlockRef{}, &tempErr) + // will return an error for l2A3 + l2Client.Mock.On("PayloadByNumber", l2A3.Number).Return(ð.ExecutionPayload{}, &tempErr) + + // make payloads for L2 blocks and set as expected return value of MockL2Client + for _, l2Block := range []eth.L2BlockRef{l2A0, l2A1, l2A2, l2B0} { + l2Client.ExpectL2BlockRefByNumber(l2Block.Number, l2Block, nil) + txData := l1InfoDepositTx(t, l2Block.L1Origin.Number) + payload := eth.ExecutionPayload{ + ParentHash: l2Block.ParentHash, + BlockNumber: hexutil.Uint64(l2Block.Number), + Timestamp: hexutil.Uint64(l2Block.Time), + BlockHash: l2Block.Hash, + Transactions: []hexutil.Bytes{txData}, + } + l2Client.Mock.On("L2BlockRefByNumber", l2Block.Number).Return(l2Block, &nilErr) + l2Client.Mock.On("PayloadByNumber", l2Block.Number).Return(&payload, &nilErr) + } + + runTestCase := func(t *testing.T, testCase ValidBatchTestCase) { + ctx := context.Background() + rcfg := defaultConf + if testCase.SpanBatchTime != nil { + rcfg.SpanBatchTime = testCase.SpanBatchTime + } + validity := CheckBatch(ctx, &rcfg, logger, testCase.L1Blocks, testCase.L2SafeHead, &testCase.Batch, &l2Client) + require.Equal(t, testCase.Expected, validity, "batch check must return expected validity level") + if testCase.ExpectedLog != "" { + // Check if ExpectedLog is contained in the log buffer + if !strings.Contains(logBuf.String(), testCase.ExpectedLog) { + t.Errorf("Expected log message was not found in the buffer: %s", testCase.ExpectedLog) + } + } + if testCase.NotExpectedLog != "" { + // Check if NotExpectedLog is contained in the log buffer + if strings.Contains(logBuf.String(), testCase.NotExpectedLog) { + t.Errorf("Not expected log message was found in the buffer: %s", testCase.NotExpectedLog) + } + } + logBuf.Reset() + } + + // Run singular batch test cases + for _, testCase := range singularBatchTestCases { + t.Run("singular_"+testCase.Name, func(t *testing.T) { + runTestCase(t, testCase) + }) + } + + // Run span batch test cases + for _, testCase := range spanBatchTestCases { + t.Run("span_"+testCase.Name, func(t *testing.T) { + runTestCase(t, testCase) }) } + + // ====== Test different TX for overlapping batches ====== + l2Client.ExpectL2BlockRefByNumber(l2B1.Number, l2B1, nil) + txData := l1InfoDepositTx(t, l2B1.L1Origin.Number) + randTx = testutils.RandomTx(rng, new(big.Int).SetUint64(rng.Uint64()), signer) + randTxData, _ = randTx.MarshalBinary() + payload := eth.ExecutionPayload{ + ParentHash: l2B0.Hash, + BlockNumber: hexutil.Uint64(l2B1.Number), + Timestamp: hexutil.Uint64(l2B1.Time), + BlockHash: l2B1.Hash, + Transactions: []hexutil.Bytes{txData, randTxData}, + } + l2Client.Mock.On("PayloadByNumber", l2B1.Number).Return(&payload, &nilErr).Once() + + randTx = testutils.RandomTx(rng, new(big.Int).SetUint64(rng.Uint64()), signer) + randTxData, _ = randTx.MarshalBinary() + differentTxtestCase := ValidBatchTestCase{ + Name: "different_tx_overlapping_batch", + L1Blocks: []eth.L1BlockRef{l1B}, + L2SafeHead: l2B1, + Batch: BatchWithL1InclusionBlock{ + L1InclusionBlock: l1B, + Batch: NewSpanBatch([]*SingularBatch{ + { + ParentHash: l2B0.Hash, + EpochNum: rollup.Epoch(l2B1.L1Origin.Number), + EpochHash: l2B1.L1Origin.Hash, + Timestamp: l2B1.Time, + Transactions: []hexutil.Bytes{randTxData}, // Random generated TX that does not match overlapping block + }, + { + ParentHash: l2B1.Hash, + EpochNum: rollup.Epoch(l2B2.L1Origin.Number), + EpochHash: l2B2.L1Origin.Hash, + Timestamp: l2B2.Time, + Transactions: nil, + }, + }), + }, + Expected: BatchDrop, + ExpectedLog: "overlapped block's transaction does not match", + SpanBatchTime: &minTs, + } + + t.Run(differentTxtestCase.Name, func(t *testing.T) { + runTestCase(t, differentTxtestCase) + }) + + // ====== Test invalid TX for overlapping batches ====== + payload = eth.ExecutionPayload{ + ParentHash: l2B0.Hash, + BlockNumber: hexutil.Uint64(l2B1.Number), + Timestamp: hexutil.Uint64(l2B1.Time), + BlockHash: l2B1.Hash, + // First TX is not a deposit TX. it will make error when extracting L2BlockRef from the payload + Transactions: []hexutil.Bytes{randTxData}, + } + l2Client.Mock.On("PayloadByNumber", l2B1.Number).Return(&payload, &nilErr).Once() + + invalidTxTestCase := ValidBatchTestCase{ + Name: "invalid_tx_overlapping_batch", + L1Blocks: []eth.L1BlockRef{l1B}, + L2SafeHead: l2B1, + Batch: BatchWithL1InclusionBlock{ + L1InclusionBlock: l1B, + Batch: NewSpanBatch([]*SingularBatch{ + { + ParentHash: l2B0.Hash, + EpochNum: rollup.Epoch(l2B1.L1Origin.Number), + EpochHash: l2B1.L1Origin.Hash, + Timestamp: l2B1.Time, + Transactions: []hexutil.Bytes{randTxData}, + }, + { + ParentHash: l2B1.Hash, + EpochNum: rollup.Epoch(l2B2.L1Origin.Number), + EpochHash: l2B2.L1Origin.Hash, + Timestamp: l2B2.Time, + Transactions: nil, + }, + }), + }, + Expected: BatchDrop, + ExpectedLog: "failed to extract L2BlockRef from execution payload", + SpanBatchTime: &minTs, + } + + t.Run(invalidTxTestCase.Name, func(t *testing.T) { + runTestCase(t, invalidTxTestCase) + }) } diff --git a/op-node/rollup/derive/channel.go b/op-node/rollup/derive/channel.go index 1d9a85cc9027e..7bd67f1849951 100644 --- a/op-node/rollup/derive/channel.go +++ b/op-node/rollup/derive/channel.go @@ -6,8 +6,6 @@ import ( "fmt" "io" - "github.com/ethereum-optimism/optimism/op-node/rollup" - "github.com/ethereum-optimism/optimism/op-service/eth" "github.com/ethereum/go-ethereum/rlp" ) @@ -146,7 +144,9 @@ func (ch *Channel) Reader() io.Reader { // BatchReader provides a function that iteratively consumes batches from the reader. // The L1Inclusion block is also provided at creation time. -func BatchReader(cfg *rollup.Config, r io.Reader, l1InclusionBlock eth.L1BlockRef) (func() (BatchWithL1InclusionBlock, error), error) { +// Warning: the batch reader can read every batch-type. +// The caller of the batch-reader should filter the results. +func BatchReader(r io.Reader) (func() (*BatchData, error), error) { // Setup decompressor stage + RLP reader zr, err := zlib.NewReader(r) if err != nil { @@ -154,17 +154,11 @@ func BatchReader(cfg *rollup.Config, r io.Reader, l1InclusionBlock eth.L1BlockRe } rlpReader := rlp.NewStream(zr, MaxRLPBytesPerChannel) // Read each batch iteratively - return func() (BatchWithL1InclusionBlock, error) { - ret := BatchWithL1InclusionBlock{ - L1InclusionBlock: l1InclusionBlock, - } - err := rlpReader.Decode(&ret.Batch) - if err != nil { - return ret, err - } - if ret.Batch.BatchType == SpanBatchType && !cfg.IsSpanBatch(ret.L1InclusionBlock.Time) { - return ret, fmt.Errorf("cannot accept span-batch in L1 block with time %d", ret.L1InclusionBlock.Time) + return func() (*BatchData, error) { + var batchData BatchData + if err = rlpReader.Decode(&batchData); err != nil { + return nil, err } - return ret, nil + return &batchData, nil }, nil } diff --git a/op-node/rollup/derive/channel_bank.go b/op-node/rollup/derive/channel_bank.go index edd1aae9e8789..64a7660ba5ea9 100644 --- a/op-node/rollup/derive/channel_bank.go +++ b/op-node/rollup/derive/channel_bank.go @@ -6,6 +6,7 @@ import ( "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/log" + "golang.org/x/exp/slices" "github.com/ethereum-optimism/optimism/op-node/rollup" "github.com/ethereum-optimism/optimism/op-service/eth" @@ -116,9 +117,12 @@ func (cb *ChannelBank) IngestFrame(f Frame) { // Read the raw data of the first channel, if it's timed-out or closed. // Read returns io.EOF if there is nothing new to read. func (cb *ChannelBank) Read() (data []byte, err error) { + // Common Code pre/post canyon. Return io.EOF if no channels if len(cb.channelQueue) == 0 { return nil, io.EOF } + // Return nil,nil on the first channel if it is timed out. There may be more timed out + // channels at the head of the queue and we want to remove them all. first := cb.channelQueue[0] ch := cb.channels[first] timedOut := ch.OpenBlockNumber()+cb.cfg.ChannelTimeout < cb.Origin().Number @@ -127,23 +131,41 @@ func (cb *ChannelBank) Read() (data []byte, err error) { cb.metrics.RecordChannelTimedOut() delete(cb.channels, first) cb.channelQueue = cb.channelQueue[1:] - // There is a new head channel if there is a channel after we have removed the first channel - if len(cb.channelQueue) > 0 { - cb.metrics.RecordHeadChannelOpened() - } return nil, nil // multiple different channels may all be timed out } - if !ch.IsReady() { - return nil, io.EOF + + // At the point we have removed all timed out channels from the front of the channelQueue. + // Pre-Canyon we simply check the first index. + // Post-Canyon we read the entire channelQueue for the first ready channel. If no channel is + // available, we return `nil, io.EOF`. + // Canyon is activated when the first L1 block whose time >= CanyonTime, not on the L2 timestamp. + if !cb.cfg.IsCanyon(cb.Origin().Time) { + return cb.tryReadChannelAtIndex(0) } - cb.log.Info("Reading channel", "channel", first, "frames", len(ch.inputs)) - delete(cb.channels, first) - cb.channelQueue = cb.channelQueue[1:] - // There is a new head channel if there is a channel after we have removed the first channel - if len(cb.channelQueue) > 0 { - cb.metrics.RecordHeadChannelOpened() + for i := 0; i < len(cb.channelQueue); i++ { + if data, err := cb.tryReadChannelAtIndex(i); err == nil { + return data, nil + } } + return nil, io.EOF +} + +// tryReadChannelAtIndex attempts to read the channel at the specified index. If the channel is +// not ready (or timed out), it will return io.EOF. +// If the channel read was successful, it will remove the channel from the channelQueue. +func (cb *ChannelBank) tryReadChannelAtIndex(i int) (data []byte, err error) { + chanID := cb.channelQueue[i] + ch := cb.channels[chanID] + timedOut := ch.OpenBlockNumber()+cb.cfg.ChannelTimeout < cb.Origin().Number + if timedOut || !ch.IsReady() { + return nil, io.EOF + } + cb.log.Info("Reading channel", "channel", chanID, "frames", len(ch.inputs)) + + delete(cb.channels, chanID) + cb.channelQueue = slices.Delete(cb.channelQueue, i, i+1) + cb.metrics.RecordHeadChannelOpened() r := ch.Reader() // Suppress error here. io.ReadAll does return nil instead of io.EOF though. data, _ = io.ReadAll(r) diff --git a/op-node/rollup/derive/channel_bank_test.go b/op-node/rollup/derive/channel_bank_test.go index 8e90fe172f4ea..495ce4426bb83 100644 --- a/op-node/rollup/derive/channel_bank_test.go +++ b/op-node/rollup/derive/channel_bank_test.go @@ -130,10 +130,10 @@ func TestChannelBankSimple(t *testing.T) { require.Equal(t, io.EOF, err) } -// TestChannelBankInterleaved ensure that the channel bank can handle frames from multiple channels +// TestChannelBankInterleavedPreCanyon ensure that the channel bank can handle frames from multiple channels // that arrive out of order. Per the specs, the first channel to arrive (not the first to be completed) -// is returned first. -func TestChannelBankInterleaved(t *testing.T) { +// is returned first prior to the Canyon network upgrade +func TestChannelBankInterleavedPreCanyon(t *testing.T) { rng := rand.New(rand.NewSource(1234)) a := testutils.RandomBlockRef(rng) @@ -144,7 +144,7 @@ func TestChannelBankInterleaved(t *testing.T) { input.AddFrames("a:1:second") input.AddFrame(Frame{}, io.EOF) - cfg := &rollup.Config{ChannelTimeout: 10} + cfg := &rollup.Config{ChannelTimeout: 10, CanyonTime: nil} cb := NewChannelBank(testlog.Logger(t, log.LvlCrit), cfg, input, nil, metrics.NoopMetrics) @@ -194,6 +194,71 @@ func TestChannelBankInterleaved(t *testing.T) { require.Equal(t, io.EOF, err) } +// TestChannelBankInterleaved ensure that the channel bank can handle frames from multiple channels +// that arrive out of order. Per the specs (post Canyon), the first channel to be complete should be +// returned +func TestChannelBankInterleaved(t *testing.T) { + rng := rand.New(rand.NewSource(1234)) + a := testutils.RandomBlockRef(rng) + + input := &fakeChannelBankInput{origin: a} + input.AddFrames("a:0:first", "b:2:trois!") + input.AddFrames("b:1:deux", "a:2:third!") + input.AddFrames("b:0:premiere") + input.AddFrames("a:1:second") + input.AddFrame(Frame{}, io.EOF) + + ct := uint64(0) + cfg := &rollup.Config{ChannelTimeout: 10, CanyonTime: &ct} + + cb := NewChannelBank(testlog.Logger(t, log.LvlCrit), cfg, input, nil, metrics.NoopMetrics) + + // Load a:0 + out, err := cb.NextData(context.Background()) + require.ErrorIs(t, err, NotEnoughData) + require.Equal(t, []byte(nil), out) + + // Load b:2 + out, err = cb.NextData(context.Background()) + require.ErrorIs(t, err, NotEnoughData) + require.Equal(t, []byte(nil), out) + + // Load b:1 + out, err = cb.NextData(context.Background()) + require.ErrorIs(t, err, NotEnoughData) + require.Equal(t, []byte(nil), out) + + // Load a:2 + out, err = cb.NextData(context.Background()) + require.ErrorIs(t, err, NotEnoughData) + require.Equal(t, []byte(nil), out) + + // Load b:0 & Channel b is complete. Channel a was opened first but isn't ready + out, err = cb.NextData(context.Background()) + require.ErrorIs(t, err, NotEnoughData) + require.Equal(t, []byte(nil), out) + + // Pull out the channel b because it's ready first. + out, err = cb.NextData(context.Background()) + require.Nil(t, err) + require.Equal(t, "premieredeuxtrois", string(out)) + + // Load a:1 + out, err = cb.NextData(context.Background()) + require.ErrorIs(t, err, NotEnoughData) + require.Equal(t, []byte(nil), out) + + // Pull out the channel a + out, err = cb.NextData(context.Background()) + require.Nil(t, err) + require.Equal(t, "firstsecondthird", string(out)) + + // No more data + out, err = cb.NextData(context.Background()) + require.Nil(t, out) + require.Equal(t, io.EOF, err) +} + func TestChannelBankDuplicates(t *testing.T) { rng := rand.New(rand.NewSource(1234)) a := testutils.RandomBlockRef(rng) diff --git a/op-node/rollup/derive/channel_in_reader.go b/op-node/rollup/derive/channel_in_reader.go index 7487326d99bf9..374b676ccf0ee 100644 --- a/op-node/rollup/derive/channel_in_reader.go +++ b/op-node/rollup/derive/channel_in_reader.go @@ -3,12 +3,13 @@ package derive import ( "bytes" "context" + "errors" + "fmt" "io" - "github.com/ethereum-optimism/optimism/op-node/rollup" - "github.com/ethereum/go-ethereum/log" + "github.com/ethereum-optimism/optimism/op-node/rollup" "github.com/ethereum-optimism/optimism/op-service/eth" ) @@ -21,7 +22,7 @@ type ChannelInReader struct { cfg *rollup.Config - nextBatchFn func() (BatchWithL1InclusionBlock, error) + nextBatchFn func() (*BatchData, error) prev *ChannelBank @@ -46,7 +47,7 @@ func (cr *ChannelInReader) Origin() eth.L1BlockRef { // TODO: Take full channel for better logging func (cr *ChannelInReader) WriteChannel(data []byte) error { - if f, err := BatchReader(cr.cfg, bytes.NewBuffer(data), cr.Origin()); err == nil { + if f, err := BatchReader(bytes.NewBuffer(data)); err == nil { cr.nextBatchFn = f cr.metrics.RecordChannelInputBytes(len(data)) return nil @@ -65,7 +66,7 @@ func (cr *ChannelInReader) NextChannel() { // NextBatch pulls out the next batch from the channel if it has it. // It returns io.EOF when it cannot make any more progress. // It will return a temporary error if it needs to be called again to advance some internal state. -func (cr *ChannelInReader) NextBatch(ctx context.Context) (*BatchData, error) { +func (cr *ChannelInReader) NextBatch(ctx context.Context) (Batch, error) { if cr.nextBatchFn == nil { if data, err := cr.prev.NextData(ctx); err == io.EOF { return nil, io.EOF @@ -80,7 +81,7 @@ func (cr *ChannelInReader) NextBatch(ctx context.Context) (*BatchData, error) { // TODO: can batch be non nil while err == io.EOF // This depends on the behavior of rlp.Stream - batch, err := cr.nextBatchFn() + batchData, err := cr.nextBatchFn() if err == io.EOF { cr.NextChannel() return nil, NotEnoughData @@ -89,7 +90,34 @@ func (cr *ChannelInReader) NextBatch(ctx context.Context) (*BatchData, error) { cr.NextChannel() return nil, NotEnoughData } - return batch.Batch, nil + switch batchData.GetBatchType() { + case SingularBatchType: + singularBatch, ok := batchData.inner.(*SingularBatch) + if !ok { + return nil, NewCriticalError(errors.New("failed type assertion to SingularBatch")) + } + return singularBatch, nil + case SpanBatchType: + if origin := cr.Origin(); !cr.cfg.IsSpanBatch(origin.Time) { + // Check hard fork activation with the L1 inclusion block time instead of the L1 origin block time. + // Therefore, even if the batch passed this rule, it can be dropped in the batch queue. + // This is just for early dropping invalid batches as soon as possible. + return nil, NewTemporaryError(fmt.Errorf("cannot accept span batch in L1 block %s at time %d", origin, origin.Time)) + } + rawSpanBatch, ok := batchData.inner.(*RawSpanBatch) + if !ok { + return nil, NewCriticalError(errors.New("failed type assertion to SpanBatch")) + } + // If the batch type is Span batch, derive block inputs from RawSpanBatch. + spanBatch, err := rawSpanBatch.derive(cr.cfg.BlockTime, cr.cfg.Genesis.L2Time, cr.cfg.L2ChainID) + if err != nil { + return nil, err + } + return spanBatch, nil + default: + // error is bubbled up to user, but pipeline can skip the batch and continue after. + return nil, NewTemporaryError(fmt.Errorf("unrecognized batch type: %d", batchData.GetBatchType())) + } } func (cr *ChannelInReader) Reset(ctx context.Context, _ eth.L1BlockRef, _ eth.SystemConfig) error { diff --git a/op-node/rollup/derive/channel_out.go b/op-node/rollup/derive/channel_out.go index 63e7cc38bc62d..e932b9524ba7c 100644 --- a/op-node/rollup/derive/channel_out.go +++ b/op-node/rollup/derive/channel_out.go @@ -48,7 +48,31 @@ type Compressor interface { FullErr() error } -type ChannelOut struct { +type ChannelOut interface { + ID() ChannelID + Reset() error + AddBlock(*types.Block) (uint64, error) + AddSingularBatch(*SingularBatch, uint64) (uint64, error) + InputBytes() int + ReadyBytes() int + Flush() error + FullErr() error + Close() error + OutputFrame(*bytes.Buffer, uint64) (uint16, error) +} + +func NewChannelOut(batchType uint, compress Compressor, spanBatchBuilder *SpanBatchBuilder) (ChannelOut, error) { + switch batchType { + case SingularBatchType: + return NewSingularChannelOut(compress) + case SpanBatchType: + return NewSpanChannelOut(compress, spanBatchBuilder) + default: + return nil, fmt.Errorf("unrecognized batch type: %d", batchType) + } +} + +type SingularChannelOut struct { id ChannelID // Frame ID of the next frame to emit. Increment after emitting frame uint64 @@ -61,13 +85,13 @@ type ChannelOut struct { closed bool } -func (co *ChannelOut) ID() ChannelID { +func (co *SingularChannelOut) ID() ChannelID { return co.id } -func NewChannelOut(compress Compressor) (*ChannelOut, error) { - c := &ChannelOut{ - id: ChannelID{}, // TODO: use GUID here instead of fully random data +func NewSingularChannelOut(compress Compressor) (*SingularChannelOut, error) { + c := &SingularChannelOut{ + id: ChannelID{}, frame: 0, rlpLength: 0, compress: compress, @@ -80,8 +104,7 @@ func NewChannelOut(compress Compressor) (*ChannelOut, error) { return c, nil } -// TODO: reuse ChannelOut for performance -func (co *ChannelOut) Reset() error { +func (co *SingularChannelOut) Reset() error { co.frame = 0 co.rlpLength = 0 co.compress.Reset() @@ -94,27 +117,27 @@ func (co *ChannelOut) Reset() error { // and an error if there is a problem adding the block. The only sentinel error // that it returns is ErrTooManyRLPBytes. If this error is returned, the channel // should be closed and a new one should be made. -func (co *ChannelOut) AddBlock(block *types.Block) (uint64, error) { +func (co *SingularChannelOut) AddBlock(block *types.Block) (uint64, error) { if co.closed { return 0, errors.New("already closed") } - batch, _, err := BlockToBatch(block) + batch, l1Info, err := BlockToSingularBatch(block) if err != nil { return 0, err } - return co.AddBatch(batch) + return co.AddSingularBatch(batch, l1Info.SequenceNumber) } -// AddBatch adds a batch to the channel. It returns the RLP encoded byte size +// AddSingularBatch adds a batch to the channel. It returns the RLP encoded byte size // and an error if there is a problem adding the batch. The only sentinel error // that it returns is ErrTooManyRLPBytes. If this error is returned, the channel // should be closed and a new one should be made. // -// AddBatch should be used together with BlockToBatch if you need to access the +// AddSingularBatch should be used together with BlockToBatch if you need to access the // BatchData before adding a block to the channel. It isn't possible to access // the batch data with AddBlock. -func (co *ChannelOut) AddBatch(batch *BatchData) (uint64, error) { +func (co *SingularChannelOut) AddSingularBatch(batch *SingularBatch, _ uint64) (uint64, error) { if co.closed { return 0, errors.New("already closed") } @@ -122,7 +145,7 @@ func (co *ChannelOut) AddBatch(batch *BatchData) (uint64, error) { // We encode to a temporary buffer to determine the encoded length to // ensure that the total size of all RLP elements is less than or equal to MAX_RLP_BYTES_PER_CHANNEL var buf bytes.Buffer - if err := rlp.Encode(&buf, batch); err != nil { + if err := rlp.Encode(&buf, NewBatchData(batch)); err != nil { return 0, err } if co.rlpLength+buf.Len() > MaxRLPBytesPerChannel { @@ -137,28 +160,28 @@ func (co *ChannelOut) AddBatch(batch *BatchData) (uint64, error) { } // InputBytes returns the total amount of RLP-encoded input bytes. -func (co *ChannelOut) InputBytes() int { +func (co *SingularChannelOut) InputBytes() int { return co.rlpLength } // ReadyBytes returns the number of bytes that the channel out can immediately output into a frame. // Use `Flush` or `Close` to move data from the compression buffer into the ready buffer if more bytes // are needed. Add blocks may add to the ready buffer, but it is not guaranteed due to the compression stage. -func (co *ChannelOut) ReadyBytes() int { +func (co *SingularChannelOut) ReadyBytes() int { return co.compress.Len() } // Flush flushes the internal compression stage to the ready buffer. It enables pulling a larger & more // complete frame. It reduces the compression efficiency. -func (co *ChannelOut) Flush() error { +func (co *SingularChannelOut) Flush() error { return co.compress.Flush() } -func (co *ChannelOut) FullErr() error { +func (co *SingularChannelOut) FullErr() error { return co.compress.FullErr() } -func (co *ChannelOut) Close() error { +func (co *SingularChannelOut) Close() error { if co.closed { return errors.New("already closed") } @@ -173,28 +196,13 @@ func (co *ChannelOut) Close() error { // Returns io.EOF when the channel is closed & there are no more frames. // Returns nil if there is still more buffered data. // Returns an error if it ran into an error during processing. -func (co *ChannelOut) OutputFrame(w *bytes.Buffer, maxSize uint64) (uint16, error) { - f := Frame{ - ID: co.id, - FrameNumber: uint16(co.frame), - } - +func (co *SingularChannelOut) OutputFrame(w *bytes.Buffer, maxSize uint64) (uint16, error) { // Check that the maxSize is large enough for the frame overhead size. if maxSize < FrameV0OverHeadSize { return 0, ErrMaxFrameSizeTooSmall } - // Copy data from the local buffer into the frame data buffer - maxDataSize := maxSize - FrameV0OverHeadSize - if maxDataSize > uint64(co.compress.Len()) { - maxDataSize = uint64(co.compress.Len()) - // If we are closed & will not spill past the current frame - // mark it is the final frame of the channel. - if co.closed { - f.IsLast = true - } - } - f.Data = make([]byte, maxDataSize) + f := createEmptyFrame(co.id, co.frame, co.ReadyBytes(), co.closed, maxSize) if _, err := io.ReadFull(co.compress, f.Data); err != nil { return 0, err @@ -213,8 +221,8 @@ func (co *ChannelOut) OutputFrame(w *bytes.Buffer, maxSize uint64) (uint16, erro } } -// BlockToBatch transforms a block into a batch object that can easily be RLP encoded. -func BlockToBatch(block *types.Block) (*BatchData, L1BlockInfo, error) { +// BlockToSingularBatch transforms a block into a batch object that can easily be RLP encoded. +func BlockToSingularBatch(block *types.Block) (*SingularBatch, L1BlockInfo, error) { opaqueTxs := make([]hexutil.Bytes, 0, len(block.Transactions())) for i, tx := range block.Transactions() { if tx.Type() == types.DepositTxType { @@ -238,15 +246,13 @@ func BlockToBatch(block *types.Block) (*BatchData, L1BlockInfo, error) { return nil, l1Info, fmt.Errorf("could not parse the L1 Info deposit: %w", err) } - return NewSingularBatchData( - SingularBatch{ - ParentHash: block.ParentHash(), - EpochNum: rollup.Epoch(l1Info.Number), - EpochHash: l1Info.BlockHash, - Timestamp: block.Time(), - Transactions: opaqueTxs, - }, - ), l1Info, nil + return &SingularBatch{ + ParentHash: block.ParentHash(), + EpochNum: rollup.Epoch(l1Info.Number), + EpochHash: l1Info.BlockHash, + Timestamp: block.Time(), + Transactions: opaqueTxs, + }, l1Info, nil } // ForceCloseTxData generates the transaction data for a transaction which will force close @@ -303,3 +309,24 @@ func ForceCloseTxData(frames []Frame) ([]byte, error) { return out.Bytes(), nil } + +// createEmptyFrame creates new empty Frame with given information. Frame data must be copied from ChannelOut. +func createEmptyFrame(id ChannelID, frame uint64, readyBytes int, closed bool, maxSize uint64) *Frame { + f := Frame{ + ID: id, + FrameNumber: uint16(frame), + } + + // Copy data from the local buffer into the frame data buffer + maxDataSize := maxSize - FrameV0OverHeadSize + if maxDataSize > uint64(readyBytes) { + maxDataSize = uint64(readyBytes) + // If we are closed & will not spill past the current frame + // mark it is the final frame of the channel. + if closed { + f.IsLast = true + } + } + f.Data = make([]byte, maxDataSize) + return &f +} diff --git a/op-node/rollup/derive/channel_out_test.go b/op-node/rollup/derive/channel_out_test.go index 73f07d762884b..0eef4a241c1b0 100644 --- a/op-node/rollup/derive/channel_out_test.go +++ b/op-node/rollup/derive/channel_out_test.go @@ -29,7 +29,7 @@ func (s *nonCompressor) FullErr() error { } func TestChannelOutAddBlock(t *testing.T) { - cout, err := NewChannelOut(&nonCompressor{}) + cout, err := NewChannelOut(SingularBatchType, &nonCompressor{}, nil) require.NoError(t, err) t.Run("returns err if first tx is not an l1info tx", func(t *testing.T) { @@ -50,7 +50,7 @@ func TestChannelOutAddBlock(t *testing.T) { // max size that is below the fixed frame size overhead of 23, will return // an error. func TestOutputFrameSmallMaxSize(t *testing.T) { - cout, err := NewChannelOut(&nonCompressor{}) + cout, err := NewChannelOut(SingularBatchType, &nonCompressor{}, nil) require.NoError(t, err) // Call OutputFrame with the range of small max size values that err @@ -97,42 +97,42 @@ func TestForceCloseTxData(t *testing.T) { output: "", }, { - frames: []Frame{Frame{FrameNumber: 0, IsLast: false}, Frame{ID: id, FrameNumber: 1, IsLast: true}}, + frames: []Frame{{FrameNumber: 0, IsLast: false}, {ID: id, FrameNumber: 1, IsLast: true}}, errors: true, output: "", }, { - frames: []Frame{Frame{ID: id, FrameNumber: 0, IsLast: false}}, + frames: []Frame{{ID: id, FrameNumber: 0, IsLast: false}}, errors: false, output: "00deadbeefdeadbeefdeadbeefdeadbeef00000000000001", }, { - frames: []Frame{Frame{ID: id, FrameNumber: 0, IsLast: true}}, + frames: []Frame{{ID: id, FrameNumber: 0, IsLast: true}}, errors: false, output: "00", }, { - frames: []Frame{Frame{ID: id, FrameNumber: 1, IsLast: false}}, + frames: []Frame{{ID: id, FrameNumber: 1, IsLast: false}}, errors: false, output: "00deadbeefdeadbeefdeadbeefdeadbeef00000000000001", }, { - frames: []Frame{Frame{ID: id, FrameNumber: 1, IsLast: true}}, + frames: []Frame{{ID: id, FrameNumber: 1, IsLast: true}}, errors: false, output: "00deadbeefdeadbeefdeadbeefdeadbeef00000000000000", }, { - frames: []Frame{Frame{ID: id, FrameNumber: 2, IsLast: true}}, + frames: []Frame{{ID: id, FrameNumber: 2, IsLast: true}}, errors: false, output: "00deadbeefdeadbeefdeadbeefdeadbeef00000000000000deadbeefdeadbeefdeadbeefdeadbeef00010000000000", }, { - frames: []Frame{Frame{ID: id, FrameNumber: 1, IsLast: false}, Frame{ID: id, FrameNumber: 3, IsLast: true}}, + frames: []Frame{{ID: id, FrameNumber: 1, IsLast: false}, {ID: id, FrameNumber: 3, IsLast: true}}, errors: false, output: "00deadbeefdeadbeefdeadbeefdeadbeef00000000000000deadbeefdeadbeefdeadbeefdeadbeef00020000000000", }, { - frames: []Frame{Frame{ID: id, FrameNumber: 1, IsLast: false}, Frame{ID: id, FrameNumber: 3, IsLast: true}, Frame{ID: id, FrameNumber: 5, IsLast: true}}, + frames: []Frame{{ID: id, FrameNumber: 1, IsLast: false}, {ID: id, FrameNumber: 3, IsLast: true}, {ID: id, FrameNumber: 5, IsLast: true}}, errors: false, output: "00deadbeefdeadbeefdeadbeefdeadbeef00000000000000deadbeefdeadbeefdeadbeefdeadbeef00020000000000", }, @@ -152,6 +152,6 @@ func TestForceCloseTxData(t *testing.T) { func TestBlockToBatchValidity(t *testing.T) { block := new(types.Block) - _, _, err := BlockToBatch(block) + _, _, err := BlockToSingularBatch(block) require.ErrorContains(t, err, "has no transactions") } diff --git a/op-node/rollup/derive/deposit_log.go b/op-node/rollup/derive/deposit_log.go index 3215d0452fbb4..74fde28c59882 100644 --- a/op-node/rollup/derive/deposit_log.go +++ b/op-node/rollup/derive/deposit_log.go @@ -10,6 +10,8 @@ import ( "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/core/types" "github.com/ethereum/go-ethereum/crypto" + + "github.com/ethereum-optimism/optimism/op-service/eth" ) var ( @@ -143,11 +145,11 @@ func unmarshalDepositVersion0(dep *types.DepositTx, to common.Address, opaqueDat func MarshalDepositLogEvent(depositContractAddr common.Address, deposit *types.DepositTx) (*types.Log, error) { toBytes := common.Hash{} if deposit.To != nil { - toBytes = deposit.To.Hash() + toBytes = eth.AddressAsLeftPaddedHash(*deposit.To) } topics := []common.Hash{ DepositEventABIHash, - deposit.From.Hash(), + eth.AddressAsLeftPaddedHash(deposit.From), toBytes, DepositEventVersion0, } diff --git a/op-node/rollup/derive/engine_consolidate.go b/op-node/rollup/derive/engine_consolidate.go index 03940058c91f4..ecac3684e194c 100644 --- a/op-node/rollup/derive/engine_consolidate.go +++ b/op-node/rollup/derive/engine_consolidate.go @@ -41,6 +41,37 @@ func AttributesMatchBlock(attrs *eth.PayloadAttributes, parentHash common.Hash, if *attrs.GasLimit != block.GasLimit { return fmt.Errorf("gas limit does not match. expected %d. got: %d", *attrs.GasLimit, block.GasLimit) } + if withdrawalErr := checkWithdrawalsMatch(attrs.Withdrawals, block.Withdrawals); withdrawalErr != nil { + return withdrawalErr + } + return nil +} + +func checkWithdrawalsMatch(attrWithdrawals *types.Withdrawals, blockWithdrawals *types.Withdrawals) error { + if attrWithdrawals == nil && blockWithdrawals == nil { + return nil + } + + if attrWithdrawals == nil && blockWithdrawals != nil { + return fmt.Errorf("expected withdrawals in block to be nil, actual %v", *blockWithdrawals) + } + + if attrWithdrawals != nil && blockWithdrawals == nil { + return fmt.Errorf("expected withdrawals in block to be non-nil %v, actual nil", *attrWithdrawals) + } + + if len(*attrWithdrawals) != len(*blockWithdrawals) { + return fmt.Errorf("expected withdrawals in block to be %d, actual %d", len(*attrWithdrawals), len(*blockWithdrawals)) + } + + for idx, expected := range *attrWithdrawals { + actual := (*blockWithdrawals)[idx] + + if *expected != *actual { + return fmt.Errorf("expected withdrawal %d to be %v, actual %v", idx, expected, actual) + } + } + return nil } diff --git a/op-node/rollup/derive/engine_consolidate_test.go b/op-node/rollup/derive/engine_consolidate_test.go new file mode 100644 index 0000000000000..9b54d89ea6044 --- /dev/null +++ b/op-node/rollup/derive/engine_consolidate_test.go @@ -0,0 +1,70 @@ +package derive + +import ( + "testing" + + "github.com/stretchr/testify/require" + + "github.com/ethereum/go-ethereum/core/types" +) + +func TestWithdrawalsMatch(t *testing.T) { + tests := []struct { + attrs *types.Withdrawals + block *types.Withdrawals + shouldMatch bool + }{ + { + attrs: nil, + block: nil, + shouldMatch: true, + }, + { + attrs: &types.Withdrawals{}, + block: nil, + shouldMatch: false, + }, + { + attrs: nil, + block: &types.Withdrawals{}, + shouldMatch: false, + }, + { + attrs: &types.Withdrawals{}, + block: &types.Withdrawals{}, + shouldMatch: true, + }, + { + attrs: &types.Withdrawals{ + { + Index: 1, + }, + }, + block: &types.Withdrawals{}, + shouldMatch: false, + }, + { + attrs: &types.Withdrawals{ + { + Index: 1, + }, + }, + block: &types.Withdrawals{ + { + Index: 2, + }, + }, + shouldMatch: false, + }, + } + + for _, test := range tests { + err := checkWithdrawalsMatch(test.attrs, test.block) + + if test.shouldMatch { + require.NoError(t, err) + } else { + require.Error(t, err) + } + } +} diff --git a/op-node/rollup/derive/engine_queue.go b/op-node/rollup/derive/engine_queue.go index f99a6fdeb04e4..8073849aa7c31 100644 --- a/op-node/rollup/derive/engine_queue.go +++ b/op-node/rollup/derive/engine_queue.go @@ -17,14 +17,15 @@ import ( "github.com/ethereum-optimism/optimism/op-service/eth" ) -type attributesWithParent struct { - attributes *eth.PayloadAttributes - parent eth.L2BlockRef +type AttributesWithParent struct { + attributes *eth.PayloadAttributes + parent eth.L2BlockRef + isLastInSpan bool } type NextAttributesProvider interface { Origin() eth.L1BlockRef - NextAttributes(context.Context, eth.L2BlockRef) (*eth.PayloadAttributes, error) + NextAttributes(context.Context, eth.L2BlockRef) (*AttributesWithParent, error) } type Engine interface { @@ -35,6 +36,7 @@ type Engine interface { PayloadByNumber(context.Context, uint64) (*eth.ExecutionPayload, error) L2BlockRefByLabel(ctx context.Context, label eth.BlockLabel) (eth.L2BlockRef, error) L2BlockRefByHash(ctx context.Context, l2Hash common.Hash) (eth.L2BlockRef, error) + L2BlockRefByNumber(ctx context.Context, num uint64) (eth.L2BlockRef, error) SystemConfigL2Fetcher } @@ -102,6 +104,10 @@ type EngineQueue struct { safeHead eth.L2BlockRef unsafeHead eth.L2BlockRef + // L2 block processed from the batch, but not consolidated to the safe block yet. + // Consolidation will be pending until the entire batch is processed successfully, to guarantee the span batch atomicity. + pendingSafeHead eth.L2BlockRef + // Target L2 block the engine is currently syncing to. // If the engine p2p sync is enabled, it can be different with unsafeHead. Otherwise, it must be same with unsafeHead. engineSyncTarget eth.L2BlockRef @@ -123,7 +129,7 @@ type EngineQueue struct { triedFinalizeAt eth.L1BlockRef // The queued-up attributes - safeAttributes *attributesWithParent + safeAttributes *AttributesWithParent unsafePayloads *PayloadsQueue // queue of unsafe payloads, ordered by ascending block number, may have gaps and duplicates // Tracks which L2 blocks where last derived from which L1 block. At most finalityLookback large. @@ -182,6 +188,7 @@ func (eq *EngineQueue) AddUnsafePayload(payload *eth.ExecutionPayload) { eq.log.Warn("cannot add nil unsafe payload") return } + if err := eq.unsafePayloads.Push(payload); err != nil { eq.log.Warn("Could not add unsafe payload", "id", payload.ID(), "timestamp", uint64(payload.Timestamp), "err", err) return @@ -233,6 +240,10 @@ func (eq *EngineQueue) SafeL2Head() eth.L2BlockRef { return eq.safeHead } +func (eq *EngineQueue) PendingSafeL2Head() eth.L2BlockRef { + return eq.pendingSafeHead +} + func (eq *EngineQueue) EngineSyncTarget() eth.L2BlockRef { return eq.engineSyncTarget } @@ -273,16 +284,14 @@ func (eq *EngineQueue) Step(ctx context.Context) error { if err := eq.tryFinalizePastL2Blocks(ctx); err != nil { return err } - if next, err := eq.prev.NextAttributes(ctx, eq.safeHead); err == io.EOF { + if next, err := eq.prev.NextAttributes(ctx, eq.pendingSafeHead); err == io.EOF { outOfData = true } else if err != nil { return err } else { - eq.safeAttributes = &attributesWithParent{ - attributes: next, - parent: eq.safeHead, - } - eq.log.Debug("Adding next safe attributes", "safe_head", eq.safeHead, "next", next) + eq.safeAttributes = next + eq.log.Debug("Adding next safe attributes", "safe_head", eq.safeHead, + "pending_safe_head", eq.pendingSafeHead, "next", next) return NotEnoughData } @@ -409,6 +418,7 @@ func (eq *EngineQueue) logSyncProgress(reason string) { "reason", reason, "l2_finalized", eq.finalized, "l2_safe", eq.safeHead, + "l2_safe_pending", eq.pendingSafeHead, "l2_unsafe", eq.unsafeHead, "l2_engineSyncTarget", eq.engineSyncTarget, "l2_time", eq.unsafeHead.Time, @@ -550,29 +560,30 @@ func (eq *EngineQueue) tryNextSafeAttributes(ctx context.Context) error { return nil } // validate the safe attributes before processing them. The engine may have completed processing them through other means. - if eq.safeHead != eq.safeAttributes.parent { - // Previously the attribute's parent was the safe head. If the safe head advances so safe head's parent is the same as the + if eq.pendingSafeHead != eq.safeAttributes.parent { + // Previously the attribute's parent was the pending safe head. If the pending safe head advances so pending safe head's parent is the same as the // attribute's parent then we need to cancel the attributes. - if eq.safeHead.ParentHash == eq.safeAttributes.parent.Hash { + if eq.pendingSafeHead.ParentHash == eq.safeAttributes.parent.Hash { eq.log.Warn("queued safe attributes are stale, safehead progressed", - "safe_head", eq.safeHead, "safe_head_parent", eq.safeHead.ParentID(), "attributes_parent", eq.safeAttributes.parent) + "pending_safe_head", eq.pendingSafeHead, "pending_safe_head_parent", eq.pendingSafeHead.ParentID(), + "attributes_parent", eq.safeAttributes.parent) eq.safeAttributes = nil return nil } // If something other than a simple advance occurred, perform a full reset - return NewResetError(fmt.Errorf("safe head changed to %s with parent %s, conflicting with queued safe attributes on top of %s", - eq.safeHead, eq.safeHead.ParentID(), eq.safeAttributes.parent)) + return NewResetError(fmt.Errorf("pending safe head changed to %s with parent %s, conflicting with queued safe attributes on top of %s", + eq.pendingSafeHead, eq.pendingSafeHead.ParentID(), eq.safeAttributes.parent)) } - if eq.safeHead.Number < eq.unsafeHead.Number { + if eq.pendingSafeHead.Number < eq.unsafeHead.Number { return eq.consolidateNextSafeAttributes(ctx) - } else if eq.safeHead.Number == eq.unsafeHead.Number { + } else if eq.pendingSafeHead.Number == eq.unsafeHead.Number { return eq.forceNextSafeAttributes(ctx) } else { - // For some reason the unsafe head is behind the safe head. Log it, and correct it. - eq.log.Error("invalid sync state, unsafe head is behind safe head", "unsafe", eq.unsafeHead, "safe", eq.safeHead) - eq.unsafeHead = eq.safeHead - eq.engineSyncTarget = eq.safeHead + // For some reason the unsafe head is behind the pending safe head. Log it, and correct it. + eq.log.Error("invalid sync state, unsafe head is behind pending safe head", "unsafe", eq.unsafeHead, "pending_safe", eq.pendingSafeHead) + eq.unsafeHead = eq.pendingSafeHead + eq.engineSyncTarget = eq.pendingSafeHead eq.metrics.RecordL2Ref("l2_unsafe", eq.unsafeHead) eq.metrics.RecordL2Ref("l2_engineSyncTarget", eq.unsafeHead) return nil @@ -586,7 +597,7 @@ func (eq *EngineQueue) consolidateNextSafeAttributes(ctx context.Context) error ctx, cancel := context.WithTimeout(ctx, time.Second*10) defer cancel() - payload, err := eq.engine.PayloadByNumber(ctx, eq.safeHead.Number+1) + payload, err := eq.engine.PayloadByNumber(ctx, eq.pendingSafeHead.Number+1) if err != nil { if errors.Is(err, ethereum.NotFound) { // engine may have restarted, or inconsistent safe head. We need to reset @@ -594,8 +605,8 @@ func (eq *EngineQueue) consolidateNextSafeAttributes(ctx context.Context) error } return NewTemporaryError(fmt.Errorf("failed to get existing unsafe payload to compare against derived attributes from L1: %w", err)) } - if err := AttributesMatchBlock(eq.safeAttributes.attributes, eq.safeHead.Hash, payload, eq.log); err != nil { - eq.log.Warn("L2 reorg: existing unsafe block does not match derived attributes from L1", "err", err, "unsafe", eq.unsafeHead, "safe", eq.safeHead) + if err := AttributesMatchBlock(eq.safeAttributes.attributes, eq.pendingSafeHead.Hash, payload, eq.log); err != nil { + eq.log.Warn("L2 reorg: existing unsafe block does not match derived attributes from L1", "err", err, "unsafe", eq.unsafeHead, "pending_safe", eq.pendingSafeHead, "safe", eq.safeHead) // geth cannot wind back a chain without reorging to a new, previously non-canonical, block return eq.forceNextSafeAttributes(ctx) } @@ -603,12 +614,15 @@ func (eq *EngineQueue) consolidateNextSafeAttributes(ctx context.Context) error if err != nil { return NewResetError(fmt.Errorf("failed to decode L2 block ref from payload: %w", err)) } - eq.safeHead = ref - eq.needForkchoiceUpdate = true - eq.metrics.RecordL2Ref("l2_safe", ref) + eq.pendingSafeHead = ref + if eq.safeAttributes.isLastInSpan { + eq.safeHead = ref + eq.needForkchoiceUpdate = true + eq.metrics.RecordL2Ref("l2_safe", ref) + eq.postProcessSafeL2() + } // unsafe head stays the same, we did not reorg the chain. eq.safeAttributes = nil - eq.postProcessSafeL2() eq.logSyncProgress("reconciled with L1") return nil @@ -620,7 +634,7 @@ func (eq *EngineQueue) forceNextSafeAttributes(ctx context.Context) error { return nil } attrs := eq.safeAttributes.attributes - errType, err := eq.StartPayload(ctx, eq.safeHead, attrs, true) + errType, err := eq.StartPayload(ctx, eq.pendingSafeHead, attrs, true) if err == nil { _, errType, err = eq.ConfirmPayload(ctx) } @@ -646,11 +660,13 @@ func (eq *EngineQueue) forceNextSafeAttributes(ctx context.Context) error { // block is somehow invalid, there is nothing we can do to recover & we should exit. // TODO: Can this be triggered by an empty batch with invalid data (like parent hash or gas limit?) if len(attrs.Transactions) == depositCount { - eq.log.Error("deposit only block was invalid", "parent", eq.safeHead, "err", err) + eq.log.Error("deposit only block was invalid", "parent", eq.safeAttributes.parent, "err", err) return NewCriticalError(fmt.Errorf("failed to process block with only deposit transactions: %w", err)) } // drop the payload without inserting it eq.safeAttributes = nil + // Revert the pending safe head to the safe head. + eq.pendingSafeHead = eq.safeHead // suppress the error b/c we want to retry with the next batch from the batch queue // If there is no valid batch the node will eventually force a deposit only block. If // the deposit only block fails, this will return the critical error above. @@ -701,7 +717,9 @@ func (eq *EngineQueue) ConfirmPayload(ctx context.Context) (out *eth.ExecutionPa SafeBlockHash: eq.safeHead.Hash, FinalizedBlockHash: eq.finalized.Hash, } - payload, errTyp, err := ConfirmPayload(ctx, eq.log, eq.engine, fc, eq.buildingID, eq.buildingSafe) + // Update the safe head if the payload is built with the last attributes in the batch. + updateSafe := eq.buildingSafe && eq.safeAttributes != nil && eq.safeAttributes.isLastInSpan + payload, errTyp, err := ConfirmPayload(ctx, eq.log, eq.engine, fc, eq.buildingID, updateSafe) if err != nil { return nil, errTyp, fmt.Errorf("failed to complete building on top of L2 chain %s, id: %s, error (%d): %w", eq.buildingOnto, eq.buildingID, errTyp, err) } @@ -716,9 +734,12 @@ func (eq *EngineQueue) ConfirmPayload(ctx context.Context) (out *eth.ExecutionPa eq.metrics.RecordL2Ref("l2_engineSyncTarget", ref) if eq.buildingSafe { - eq.safeHead = ref - eq.postProcessSafeL2() - eq.metrics.RecordL2Ref("l2_safe", ref) + eq.pendingSafeHead = ref + if updateSafe { + eq.safeHead = ref + eq.postProcessSafeL2() + eq.metrics.RecordL2Ref("l2_safe", ref) + } } eq.resetBuildingState() return payload, BlockInsertOK, nil @@ -796,6 +817,7 @@ func (eq *EngineQueue) Reset(ctx context.Context, _ eth.L1BlockRef, _ eth.System eq.unsafeHead = unsafe eq.engineSyncTarget = unsafe eq.safeHead = safe + eq.pendingSafeHead = safe eq.safeAttributes = nil eq.finalized = finalized eq.resetBuildingState() diff --git a/op-node/rollup/derive/engine_queue_test.go b/op-node/rollup/derive/engine_queue_test.go index 654b4fe23c25e..e9fbd91b77680 100644 --- a/op-node/rollup/derive/engine_queue_test.go +++ b/op-node/rollup/derive/engine_queue_test.go @@ -23,19 +23,20 @@ import ( ) type fakeAttributesQueue struct { - origin eth.L1BlockRef - attrs *eth.PayloadAttributes + origin eth.L1BlockRef + attrs *eth.PayloadAttributes + islastInSpan bool } func (f *fakeAttributesQueue) Origin() eth.L1BlockRef { return f.origin } -func (f *fakeAttributesQueue) NextAttributes(_ context.Context, _ eth.L2BlockRef) (*eth.PayloadAttributes, error) { +func (f *fakeAttributesQueue) NextAttributes(_ context.Context, safeHead eth.L2BlockRef) (*AttributesWithParent, error) { if f.attrs == nil { return nil, io.EOF } - return f.attrs, nil + return &AttributesWithParent{f.attrs, safeHead, f.islastInSpan}, nil } var _ NextAttributesProvider = (*fakeAttributesQueue)(nil) @@ -909,7 +910,7 @@ func TestBlockBuildingRace(t *testing.T) { GasLimit: &gasLimit, } - prev := &fakeAttributesQueue{origin: refA, attrs: attrs} + prev := &fakeAttributesQueue{origin: refA, attrs: attrs, islastInSpan: true} eq := NewEngineQueue(logger, cfg, eng, metrics, prev, l1F, &sync.Config{}) require.ErrorIs(t, eq.Reset(context.Background(), eth.L1BlockRef{}, eth.SystemConfig{}), io.EOF) @@ -1078,7 +1079,7 @@ func TestResetLoop(t *testing.T) { l1F.ExpectL1BlockRefByHash(refA.Hash, refA, nil) l1F.ExpectL1BlockRefByHash(refA.Hash, refA, nil) - prev := &fakeAttributesQueue{origin: refA, attrs: attrs} + prev := &fakeAttributesQueue{origin: refA, attrs: attrs, islastInSpan: true} eq := NewEngineQueue(logger, cfg, eng, metrics.NoopMetrics, prev, l1F, &sync.Config{}) eq.unsafeHead = refA2 diff --git a/op-node/rollup/derive/fuzz_parsers_test.go b/op-node/rollup/derive/fuzz_parsers_test.go index 054e34fe75a9b..6e0e9ebe51b6b 100644 --- a/op-node/rollup/derive/fuzz_parsers_test.go +++ b/op-node/rollup/derive/fuzz_parsers_test.go @@ -97,7 +97,7 @@ func FuzzL1InfoAgainstContract(f *testing.F) { BytesToBigInt(baseFee), common.BytesToHash(hash), seqNumber, - common.BytesToAddress(batcherHash).Hash(), + eth.AddressAsLeftPaddedHash(common.BytesToAddress(batcherHash)), common.BytesToHash(l1FeeOverhead).Big(), common.BytesToHash(l1FeeScalar).Big(), ) diff --git a/op-node/rollup/derive/l1_traversal.go b/op-node/rollup/derive/l1_traversal.go index 99c8d4475400b..5c854613e4ba1 100644 --- a/op-node/rollup/derive/l1_traversal.go +++ b/op-node/rollup/derive/l1_traversal.go @@ -73,7 +73,7 @@ func (l1t *L1Traversal) AdvanceL1Block(ctx context.Context) error { // Parse L1 receipts of the given block and update the L1 system configuration _, receipts, err := l1t.l1Blocks.FetchReceipts(ctx, nextL1Origin.Hash) if err != nil { - return NewTemporaryError(fmt.Errorf("failed to fetch receipts of L1 block %s for L1 sysCfg update: %w", origin, err)) + return NewTemporaryError(fmt.Errorf("failed to fetch receipts of L1 block %s (parent: %s) for L1 sysCfg update: %w", nextL1Origin, origin, err)) } if err := UpdateSystemConfigWithL1Receipts(&l1t.sysCfg, receipts, l1t.cfg); err != nil { // the sysCfg changes should always be formatted correctly. diff --git a/op-node/rollup/derive/params.go b/op-node/rollup/derive/params.go index 469899c3aae5f..bba78cc2dfee1 100644 --- a/op-node/rollup/derive/params.go +++ b/op-node/rollup/derive/params.go @@ -19,10 +19,10 @@ func frameSize(frame Frame) uint64 { const DerivationVersion0 = 0 -// MaxSpanBatchFieldSize is the maximum amount of bytes that will be read from -// a span batch to decode span batch field. This value cannot be larger than +// MaxSpanBatchSize is the maximum amount of bytes that will be needed +// to decode every span batch field. This value cannot be larger than // MaxRLPBytesPerChannel because single batch cannot be larger than channel size. -const MaxSpanBatchFieldSize = 10_000_000 +const MaxSpanBatchSize = MaxRLPBytesPerChannel // MaxChannelBankSize is the amount of memory space, in number of bytes, // till the bank is pruned by removing channels, diff --git a/op-node/rollup/derive/pipeline.go b/op-node/rollup/derive/pipeline.go index 7b017515b7630..643dc312cce9d 100644 --- a/op-node/rollup/derive/pipeline.go +++ b/op-node/rollup/derive/pipeline.go @@ -51,6 +51,7 @@ type EngineQueueStage interface { Finalized() eth.L2BlockRef UnsafeL2Head() eth.L2BlockRef SafeL2Head() eth.L2BlockRef + PendingSafeL2Head() eth.L2BlockRef EngineSyncTarget() eth.L2BlockRef Origin() eth.L1BlockRef SystemConfig() eth.SystemConfig @@ -90,7 +91,7 @@ func NewDerivationPipeline(log log.Logger, cfg *rollup.Config, l1Fetcher L1Fetch frameQueue := NewFrameQueue(log, l1Src) bank := NewChannelBank(log, cfg, frameQueue, l1Fetcher, metrics) chInReader := NewChannelInReader(cfg, log, bank, metrics) - batchQueue := NewBatchQueue(log, cfg, chInReader) + batchQueue := NewBatchQueue(log, cfg, chInReader, engine) attrBuilder := NewFetchingAttributesBuilder(cfg, l1Fetcher, engine) attributesQueue := NewAttributesQueue(log, cfg, attrBuilder, batchQueue) @@ -148,6 +149,10 @@ func (dp *DerivationPipeline) SafeL2Head() eth.L2BlockRef { return dp.eng.SafeL2Head() } +func (dp *DerivationPipeline) PendingSafeL2Head() eth.L2BlockRef { + return dp.eng.PendingSafeL2Head() +} + // UnsafeL2Head returns the head of the L2 chain that we are deriving for, this may be past what we derived from L1 func (dp *DerivationPipeline) UnsafeL2Head() eth.L2BlockRef { return dp.eng.UnsafeL2Head() diff --git a/op-node/rollup/derive/singular_batch.go b/op-node/rollup/derive/singular_batch.go index 3d37325cd35dd..6354dc46ee535 100644 --- a/op-node/rollup/derive/singular_batch.go +++ b/op-node/rollup/derive/singular_batch.go @@ -1,11 +1,15 @@ package derive import ( + "bytes" + "io" + "github.com/ethereum-optimism/optimism/op-node/rollup" "github.com/ethereum-optimism/optimism/op-service/eth" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common/hexutil" "github.com/ethereum/go-ethereum/log" + "github.com/ethereum/go-ethereum/rlp" ) // Batch format @@ -51,3 +55,13 @@ func (b *SingularBatch) LogContext(log log.Logger) log.Logger { func (b *SingularBatch) Epoch() eth.BlockID { return eth.BlockID{Hash: b.EpochHash, Number: uint64(b.EpochNum)} } + +// encode writes the byte encoding of SingularBatch to Writer stream +func (b *SingularBatch) encode(w io.Writer) error { + return rlp.Encode(w, b) +} + +// decode reads the byte encoding of SingularBatch from Reader stream +func (b *SingularBatch) decode(r *bytes.Reader) error { + return rlp.Decode(r, b) +} diff --git a/op-node/rollup/derive/singular_batch_test.go b/op-node/rollup/derive/singular_batch_test.go index bd8d2a562d6fe..d6922c86d6676 100644 --- a/op-node/rollup/derive/singular_batch_test.go +++ b/op-node/rollup/derive/singular_batch_test.go @@ -5,7 +5,7 @@ import ( "math/rand" "testing" - "github.com/stretchr/testify/assert" + "github.com/stretchr/testify/require" ) func TestSingularBatchForBatchInterface(t *testing.T) { @@ -15,7 +15,7 @@ func TestSingularBatchForBatchInterface(t *testing.T) { singularBatch := RandomSingularBatch(rng, txCount, chainID) - assert.Equal(t, SingularBatchType, singularBatch.GetBatchType()) - assert.Equal(t, singularBatch.Timestamp, singularBatch.GetTimestamp()) - assert.Equal(t, singularBatch.EpochNum, singularBatch.GetEpochNum()) + require.Equal(t, SingularBatchType, singularBatch.GetBatchType()) + require.Equal(t, singularBatch.Timestamp, singularBatch.GetTimestamp()) + require.Equal(t, singularBatch.EpochNum, singularBatch.GetEpochNum()) } diff --git a/op-node/rollup/derive/span_batch.go b/op-node/rollup/derive/span_batch.go index 81baf158bfee1..e71dd05a5b18e 100644 --- a/op-node/rollup/derive/span_batch.go +++ b/op-node/rollup/derive/span_batch.go @@ -9,12 +9,14 @@ import ( "math/big" "sort" - "github.com/ethereum-optimism/optimism/op-node/rollup" - "github.com/ethereum-optimism/optimism/op-service/eth" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common/hexutil" + "github.com/ethereum/go-ethereum/common/math" "github.com/ethereum/go-ethereum/log" "github.com/ethereum/go-ethereum/rlp" + + "github.com/ethereum-optimism/optimism/op-node/rollup" + "github.com/ethereum-optimism/optimism/op-service/eth" ) // Batch format @@ -25,13 +27,15 @@ import ( // payload := block_count ++ origin_bits ++ block_tx_counts ++ txs // txs := contract_creation_bits ++ y_parity_bits ++ tx_sigs ++ tx_tos ++ tx_datas ++ tx_nonces ++ tx_gases -var ErrTooBigSpanBatchFieldSize = errors.New("batch would cause field bytes to go over limit") +var ErrTooBigSpanBatchSize = errors.New("span batch size limit reached") + +var ErrEmptySpanBatch = errors.New("span-batch must not be empty") type spanBatchPrefix struct { - relTimestamp uint64 // Relative timestamp of the first block - l1OriginNum uint64 // L1 origin number - parentCheck []byte // First 20 bytes of the first block's parent hash - l1OriginCheck []byte // First 20 bytes of the last block's L1 origin hash + relTimestamp uint64 // Relative timestamp of the first block + l1OriginNum uint64 // L1 origin number + parentCheck [20]byte // First 20 bytes of the first block's parent hash + l1OriginCheck [20]byte // First 20 bytes of the last block's L1 origin hash } type spanBatchPayload struct { @@ -47,6 +51,11 @@ type RawSpanBatch struct { spanBatchPayload } +// GetBatchType returns its batch type (batch_version) +func (b *RawSpanBatch) GetBatchType() int { + return SpanBatchType +} + // decodeOriginBits parses data into bp.originBits // originBits is bitlist right-padded to a multiple of 8 bits func (bp *spanBatchPayload) decodeOriginBits(r *bytes.Reader) error { @@ -55,8 +64,8 @@ func (bp *spanBatchPayload) decodeOriginBits(r *bytes.Reader) error { originBitBufferLen++ } // avoid out of memory before allocation - if originBitBufferLen > MaxSpanBatchFieldSize { - return ErrTooBigSpanBatchFieldSize + if originBitBufferLen > MaxSpanBatchSize { + return ErrTooBigSpanBatchSize } originBitBuffer := make([]byte, originBitBufferLen) _, err := io.ReadFull(r, originBitBuffer) @@ -101,8 +110,7 @@ func (bp *spanBatchPrefix) decodeL1OriginNum(r *bytes.Reader) error { // decodeParentCheck parses data into bp.parentCheck func (bp *spanBatchPrefix) decodeParentCheck(r *bytes.Reader) error { - bp.parentCheck = make([]byte, 20) - _, err := io.ReadFull(r, bp.parentCheck) + _, err := io.ReadFull(r, bp.parentCheck[:]) if err != nil { return fmt.Errorf("failed to read parent check: %w", err) } @@ -111,8 +119,7 @@ func (bp *spanBatchPrefix) decodeParentCheck(r *bytes.Reader) error { // decodeL1OriginCheck parses data into bp.decodeL1OriginCheck func (bp *spanBatchPrefix) decodeL1OriginCheck(r *bytes.Reader) error { - bp.l1OriginCheck = make([]byte, 20) - _, err := io.ReadFull(r, bp.l1OriginCheck) + _, err := io.ReadFull(r, bp.l1OriginCheck[:]) if err != nil { return fmt.Errorf("failed to read l1 origin check: %w", err) } @@ -139,10 +146,17 @@ func (bp *spanBatchPrefix) decodePrefix(r *bytes.Reader) error { // decodeBlockCount parses data into bp.blockCount func (bp *spanBatchPayload) decodeBlockCount(r *bytes.Reader) error { blockCount, err := binary.ReadUvarint(r) - bp.blockCount = blockCount if err != nil { return fmt.Errorf("failed to read block count: %w", err) } + // number of L2 block in span batch cannot be greater than MaxSpanBatchSize + if blockCount > MaxSpanBatchSize { + return ErrTooBigSpanBatchSize + } + if blockCount == 0 { + return ErrEmptySpanBatch + } + bp.blockCount = blockCount return nil } @@ -155,6 +169,11 @@ func (bp *spanBatchPayload) decodeBlockTxCounts(r *bytes.Reader) error { if err != nil { return fmt.Errorf("failed to read block tx count: %w", err) } + // number of txs in single L2 block cannot be greater than MaxSpanBatchSize + // every tx will take at least single byte + if blockTxCount > MaxSpanBatchSize { + return ErrTooBigSpanBatchSize + } blockTxCounts = append(blockTxCounts, blockTxCount) } bp.blockTxCounts = blockTxCounts @@ -171,7 +190,15 @@ func (bp *spanBatchPayload) decodeTxs(r *bytes.Reader) error { } totalBlockTxCount := uint64(0) for i := 0; i < len(bp.blockTxCounts); i++ { - totalBlockTxCount += bp.blockTxCounts[i] + total, overflow := math.SafeAdd(totalBlockTxCount, bp.blockTxCounts[i]) + if overflow { + return ErrTooBigSpanBatchSize + } + totalBlockTxCount = total + } + // total number of txs in span batch cannot be greater than MaxSpanBatchSize + if totalBlockTxCount > MaxSpanBatchSize { + return ErrTooBigSpanBatchSize } bp.txs.totalBlockTxCount = totalBlockTxCount if err := bp.txs.decode(r); err != nil { @@ -197,9 +224,11 @@ func (bp *spanBatchPayload) decodePayload(r *bytes.Reader) error { return nil } -// decodeBytes parses data into b from data -func (b *RawSpanBatch) decodeBytes(data []byte) error { - r := bytes.NewReader(data) +// decode reads the byte encoding of SpanBatch from Reader stream +func (b *RawSpanBatch) decode(r *bytes.Reader) error { + if r.Len() > MaxSpanBatchSize { + return ErrTooBigSpanBatchSize + } if err := b.decodePrefix(r); err != nil { return err } @@ -231,7 +260,7 @@ func (bp *spanBatchPrefix) encodeL1OriginNum(w io.Writer) error { // encodeParentCheck encodes bp.parentCheck func (bp *spanBatchPrefix) encodeParentCheck(w io.Writer) error { - if _, err := w.Write(bp.parentCheck); err != nil { + if _, err := w.Write(bp.parentCheck[:]); err != nil { return fmt.Errorf("cannot write parent check: %w", err) } return nil @@ -239,7 +268,7 @@ func (bp *spanBatchPrefix) encodeParentCheck(w io.Writer) error { // encodeL1OriginCheck encodes bp.l1OriginCheck func (bp *spanBatchPrefix) encodeL1OriginCheck(w io.Writer) error { - if _, err := w.Write(bp.l1OriginCheck); err != nil { + if _, err := w.Write(bp.l1OriginCheck[:]); err != nil { return fmt.Errorf("cannot write l1 origin check: %w", err) } return nil @@ -348,20 +377,12 @@ func (b *RawSpanBatch) encode(w io.Writer) error { return nil } -// encodeBytes returns the byte encoding of SpanBatch -func (b *RawSpanBatch) encodeBytes() ([]byte, error) { - buf := encodeBufferPool.Get().(*bytes.Buffer) - defer encodeBufferPool.Put(buf) - buf.Reset() - if err := b.encode(buf); err != nil { - return []byte{}, err - } - return buf.Bytes(), nil -} - // derive converts RawSpanBatch into SpanBatch, which has a list of spanBatchElement. // We need chain config constants to derive values for making payload attributes. func (b *RawSpanBatch) derive(blockTime, genesisTimestamp uint64, chainID *big.Int) (*SpanBatch, error) { + if b.blockCount == 0 { + return nil, ErrEmptySpanBatch + } blockOriginNums := make([]uint64, b.blockCount) l1OriginBlockNumber := b.l1OriginNum for i := int(b.blockCount) - 1; i >= 0; i-- { @@ -416,8 +437,8 @@ func singularBatchToElement(singularBatch *SingularBatch) *spanBatchElement { // SpanBatch is an implementation of Batch interface, // containing the input to build a span of L2 blocks in derived form (spanBatchElement) type SpanBatch struct { - parentCheck []byte // First 20 bytes of the first block's parent hash - l1OriginCheck []byte // First 20 bytes of the last block's L1 origin hash + parentCheck [20]byte // First 20 bytes of the first block's parent hash + l1OriginCheck [20]byte // First 20 bytes of the last block's L1 origin hash batches []*spanBatchElement // List of block input in derived form } @@ -438,8 +459,8 @@ func (b *SpanBatch) LogContext(log log.Logger) log.Logger { } return log.New( "batch_timestamp", b.batches[0].Timestamp, - "parent_check", hexutil.Encode(b.parentCheck), - "origin_check", hexutil.Encode(b.l1OriginCheck), + "parent_check", hexutil.Encode(b.parentCheck[:]), + "origin_check", hexutil.Encode(b.l1OriginCheck[:]), "start_epoch_number", b.GetStartEpochNum(), "end_epoch_number", b.GetBlockEpochNum(len(b.batches)-1), "block_count", len(b.batches), @@ -453,12 +474,12 @@ func (b *SpanBatch) GetStartEpochNum() rollup.Epoch { // CheckOriginHash checks if the l1OriginCheck matches the first 20 bytes of given hash, probably L1 block hash from the current canonical L1 chain. func (b *SpanBatch) CheckOriginHash(hash common.Hash) bool { - return bytes.Equal(b.l1OriginCheck, hash.Bytes()[:20]) + return bytes.Equal(b.l1OriginCheck[:], hash.Bytes()[:20]) } // CheckParentHash checks if the parentCheck matches the first 20 bytes of given hash, probably the current L2 safe head. func (b *SpanBatch) CheckParentHash(hash common.Hash) bool { - return bytes.Equal(b.parentCheck, hash.Bytes()[:20]) + return bytes.Equal(b.parentCheck[:], hash.Bytes()[:20]) } // GetBlockEpochNum returns the epoch number(L1 origin block number) of the block at the given index in the span. @@ -485,10 +506,10 @@ func (b *SpanBatch) GetBlockCount() int { // updates l1OriginCheck or parentCheck if needed. func (b *SpanBatch) AppendSingularBatch(singularBatch *SingularBatch) { if len(b.batches) == 0 { - b.parentCheck = singularBatch.ParentHash.Bytes()[:20] + copy(b.parentCheck[:], singularBatch.ParentHash.Bytes()[:20]) } b.batches = append(b.batches, singularBatchToElement(singularBatch)) - b.l1OriginCheck = singularBatch.EpochHash.Bytes()[:20] + copy(b.l1OriginCheck[:], singularBatch.EpochHash.Bytes()[:20]) } // ToRawSpanBatch merges SingularBatch List and initialize single RawSpanBatch @@ -506,10 +527,8 @@ func (b *SpanBatch) ToRawSpanBatch(originChangedBit uint, genesisTimestamp uint6 span_end := b.batches[len(b.batches)-1] raw.relTimestamp = span_start.Timestamp - genesisTimestamp raw.l1OriginNum = uint64(span_end.EpochNum) - raw.parentCheck = make([]byte, 20) - copy(raw.parentCheck, b.parentCheck) - raw.l1OriginCheck = make([]byte, 20) - copy(raw.l1OriginCheck, b.l1OriginCheck) + raw.parentCheck = b.parentCheck + raw.l1OriginCheck = b.l1OriginCheck // spanBatchPayload raw.blockCount = uint64(len(b.batches)) raw.originBits = new(big.Int) @@ -573,47 +592,47 @@ func (b *SpanBatch) GetSingularBatches(l1Origins []eth.L1BlockRef, l2SafeHead et // NewSpanBatch converts given singularBatches into spanBatchElements, and creates a new SpanBatch. func NewSpanBatch(singularBatches []*SingularBatch) *SpanBatch { + spanBatch := &SpanBatch{} if len(singularBatches) == 0 { - return &SpanBatch{} - } - spanBatch := SpanBatch{ - parentCheck: singularBatches[0].ParentHash.Bytes()[:20], - l1OriginCheck: singularBatches[len(singularBatches)-1].EpochHash.Bytes()[:20], + return spanBatch } + copy(spanBatch.parentCheck[:], singularBatches[0].ParentHash.Bytes()[:20]) + copy(spanBatch.l1OriginCheck[:], singularBatches[len(singularBatches)-1].EpochHash.Bytes()[:20]) for _, singularBatch := range singularBatches { spanBatch.batches = append(spanBatch.batches, singularBatchToElement(singularBatch)) } - return &spanBatch + return spanBatch } // SpanBatchBuilder is a utility type to build a SpanBatch by adding a SingularBatch one by one. // makes easier to stack SingularBatches and convert to RawSpanBatch for encoding. type SpanBatchBuilder struct { - parentEpoch uint64 genesisTimestamp uint64 chainID *big.Int spanBatch *SpanBatch + originChangedBit uint } -func NewSpanBatchBuilder(parentEpoch uint64, genesisTimestamp uint64, chainID *big.Int) *SpanBatchBuilder { +func NewSpanBatchBuilder(genesisTimestamp uint64, chainID *big.Int) *SpanBatchBuilder { return &SpanBatchBuilder{ - parentEpoch: parentEpoch, genesisTimestamp: genesisTimestamp, chainID: chainID, spanBatch: &SpanBatch{}, } } -func (b *SpanBatchBuilder) AppendSingularBatch(singularBatch *SingularBatch) { +func (b *SpanBatchBuilder) AppendSingularBatch(singularBatch *SingularBatch, seqNum uint64) { + if b.GetBlockCount() == 0 { + b.originChangedBit = 0 + if seqNum == 0 { + b.originChangedBit = 1 + } + } b.spanBatch.AppendSingularBatch(singularBatch) } func (b *SpanBatchBuilder) GetRawSpanBatch() (*RawSpanBatch, error) { - originChangedBit := 0 - if uint64(b.spanBatch.GetStartEpochNum()) != b.parentEpoch { - originChangedBit = 1 - } - raw, err := b.spanBatch.ToRawSpanBatch(uint(originChangedBit), b.genesisTimestamp, b.chainID) + raw, err := b.spanBatch.ToRawSpanBatch(b.originChangedBit, b.genesisTimestamp, b.chainID) if err != nil { return nil, err } @@ -652,13 +671,13 @@ func ReadTxData(r *bytes.Reader) ([]byte, int, error) { } } // avoid out of memory before allocation - s := rlp.NewStream(r, MaxSpanBatchFieldSize) + s := rlp.NewStream(r, MaxSpanBatchSize) var txPayload []byte kind, _, err := s.Kind() switch { case err != nil: if errors.Is(err, rlp.ErrValueTooLarge) { - return nil, 0, ErrTooBigSpanBatchFieldSize + return nil, 0, ErrTooBigSpanBatchSize } return nil, 0, fmt.Errorf("failed to read tx RLP prefix: %w", err) case kind == rlp.List: diff --git a/op-node/rollup/derive/span_batch_test.go b/op-node/rollup/derive/span_batch_test.go index 3348b358a1cf1..eaa03a8a53d7e 100644 --- a/op-node/rollup/derive/span_batch_test.go +++ b/op-node/rollup/derive/span_batch_test.go @@ -2,16 +2,20 @@ package derive import ( "bytes" + "math" "math/big" "math/rand" "testing" - "github.com/ethereum-optimism/optimism/op-node/rollup" - "github.com/ethereum-optimism/optimism/op-service/testutils" + "github.com/stretchr/testify/assert" + "github.com/stretchr/testify/require" + "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/core/types" "github.com/ethereum/go-ethereum/rlp" - "github.com/stretchr/testify/assert" + + "github.com/ethereum-optimism/optimism/op-node/rollup" + "github.com/ethereum-optimism/optimism/op-service/testutils" ) func TestSpanBatchForBatchInterface(t *testing.T) { @@ -26,11 +30,44 @@ func TestSpanBatchForBatchInterface(t *testing.T) { spanBatch := NewSpanBatch(singularBatches) // check interface method implementations except logging - assert.Equal(t, SpanBatchType, spanBatch.GetBatchType()) - assert.Equal(t, singularBatches[0].Timestamp, spanBatch.GetTimestamp()) - assert.Equal(t, singularBatches[0].EpochNum, spanBatch.GetStartEpochNum()) - assert.True(t, spanBatch.CheckOriginHash(singularBatches[blockCount-1].EpochHash)) - assert.True(t, spanBatch.CheckParentHash(singularBatches[0].ParentHash)) + require.Equal(t, SpanBatchType, spanBatch.GetBatchType()) + require.Equal(t, singularBatches[0].Timestamp, spanBatch.GetTimestamp()) + require.Equal(t, singularBatches[0].EpochNum, spanBatch.GetStartEpochNum()) + require.True(t, spanBatch.CheckOriginHash(singularBatches[blockCount-1].EpochHash)) + require.True(t, spanBatch.CheckParentHash(singularBatches[0].ParentHash)) +} + +func TestEmptySpanBatch(t *testing.T) { + rng := rand.New(rand.NewSource(0x77556691)) + chainID := big.NewInt(rng.Int63n(1000)) + spanTxs, err := newSpanBatchTxs(nil, chainID) + require.NoError(t, err) + + rawSpanBatch := RawSpanBatch{ + spanBatchPrefix: spanBatchPrefix{ + relTimestamp: uint64(rng.Uint32()), + l1OriginNum: rng.Uint64(), + parentCheck: *(*[20]byte)(testutils.RandomData(rng, 20)), + l1OriginCheck: *(*[20]byte)(testutils.RandomData(rng, 20)), + }, + spanBatchPayload: spanBatchPayload{ + blockCount: 0, + originBits: big.NewInt(0), + blockTxCounts: []uint64{}, + txs: spanTxs, + }, + } + + var buf bytes.Buffer + err = rawSpanBatch.encodeBlockCount(&buf) + assert.NoError(t, err) + + result := buf.Bytes() + r := bytes.NewReader(result) + var sb RawSpanBatch + + err = sb.decodeBlockCount(r) + require.ErrorIs(t, err, ErrEmptySpanBatch) } func TestSpanBatchOriginBits(t *testing.T) { @@ -43,23 +80,23 @@ func TestSpanBatchOriginBits(t *testing.T) { var buf bytes.Buffer err := rawSpanBatch.encodeOriginBits(&buf) - assert.NoError(t, err) + require.NoError(t, err) // originBit field is fixed length: single bit originBitBufferLen := blockCount / 8 if blockCount%8 != 0 { originBitBufferLen++ } - assert.Equal(t, buf.Len(), int(originBitBufferLen)) + require.Equal(t, buf.Len(), int(originBitBufferLen)) result := buf.Bytes() var sb RawSpanBatch sb.blockCount = blockCount r := bytes.NewReader(result) err = sb.decodeOriginBits(r) - assert.NoError(t, err) + require.NoError(t, err) - assert.Equal(t, rawSpanBatch.originBits, sb.originBits) + require.Equal(t, rawSpanBatch.originBits, sb.originBits) } func TestSpanBatchPrefix(t *testing.T) { @@ -72,15 +109,15 @@ func TestSpanBatchPrefix(t *testing.T) { var buf bytes.Buffer err := rawSpanBatch.encodePrefix(&buf) - assert.NoError(t, err) + require.NoError(t, err) result := buf.Bytes() r := bytes.NewReader(result) var sb RawSpanBatch err = sb.decodePrefix(r) - assert.NoError(t, err) + require.NoError(t, err) - assert.Equal(t, rawSpanBatch, &sb) + require.Equal(t, rawSpanBatch, &sb) } func TestSpanBatchRelTimestamp(t *testing.T) { @@ -91,15 +128,15 @@ func TestSpanBatchRelTimestamp(t *testing.T) { var buf bytes.Buffer err := rawSpanBatch.encodeRelTimestamp(&buf) - assert.NoError(t, err) + require.NoError(t, err) result := buf.Bytes() r := bytes.NewReader(result) var sb RawSpanBatch err = sb.decodeRelTimestamp(r) - assert.NoError(t, err) + require.NoError(t, err) - assert.Equal(t, rawSpanBatch.relTimestamp, sb.relTimestamp) + require.Equal(t, rawSpanBatch.relTimestamp, sb.relTimestamp) } func TestSpanBatchL1OriginNum(t *testing.T) { @@ -110,15 +147,15 @@ func TestSpanBatchL1OriginNum(t *testing.T) { var buf bytes.Buffer err := rawSpanBatch.encodeL1OriginNum(&buf) - assert.NoError(t, err) + require.NoError(t, err) result := buf.Bytes() r := bytes.NewReader(result) var sb RawSpanBatch err = sb.decodeL1OriginNum(r) - assert.NoError(t, err) + require.NoError(t, err) - assert.Equal(t, rawSpanBatch.l1OriginNum, sb.l1OriginNum) + require.Equal(t, rawSpanBatch.l1OriginNum, sb.l1OriginNum) } func TestSpanBatchParentCheck(t *testing.T) { @@ -129,18 +166,18 @@ func TestSpanBatchParentCheck(t *testing.T) { var buf bytes.Buffer err := rawSpanBatch.encodeParentCheck(&buf) - assert.NoError(t, err) + require.NoError(t, err) // parent check field is fixed length: 20 bytes - assert.Equal(t, buf.Len(), 20) + require.Equal(t, buf.Len(), 20) result := buf.Bytes() r := bytes.NewReader(result) var sb RawSpanBatch err = sb.decodeParentCheck(r) - assert.NoError(t, err) + require.NoError(t, err) - assert.Equal(t, rawSpanBatch.parentCheck, sb.parentCheck) + require.Equal(t, rawSpanBatch.parentCheck, sb.parentCheck) } func TestSpanBatchL1OriginCheck(t *testing.T) { @@ -151,18 +188,18 @@ func TestSpanBatchL1OriginCheck(t *testing.T) { var buf bytes.Buffer err := rawSpanBatch.encodeL1OriginCheck(&buf) - assert.NoError(t, err) + require.NoError(t, err) // l1 origin check field is fixed length: 20 bytes - assert.Equal(t, buf.Len(), 20) + require.Equal(t, buf.Len(), 20) result := buf.Bytes() r := bytes.NewReader(result) var sb RawSpanBatch err = sb.decodeL1OriginCheck(r) - assert.NoError(t, err) + require.NoError(t, err) - assert.Equal(t, rawSpanBatch.l1OriginCheck, sb.l1OriginCheck) + require.Equal(t, rawSpanBatch.l1OriginCheck, sb.l1OriginCheck) } func TestSpanBatchPayload(t *testing.T) { @@ -173,18 +210,18 @@ func TestSpanBatchPayload(t *testing.T) { var buf bytes.Buffer err := rawSpanBatch.encodePayload(&buf) - assert.NoError(t, err) + require.NoError(t, err) result := buf.Bytes() r := bytes.NewReader(result) var sb RawSpanBatch err = sb.decodePayload(r) - assert.NoError(t, err) + require.NoError(t, err) sb.txs.recoverV(chainID) - assert.Equal(t, rawSpanBatch.spanBatchPayload, sb.spanBatchPayload) + require.Equal(t, rawSpanBatch.spanBatchPayload, sb.spanBatchPayload) } func TestSpanBatchBlockCount(t *testing.T) { @@ -195,16 +232,16 @@ func TestSpanBatchBlockCount(t *testing.T) { var buf bytes.Buffer err := rawSpanBatch.encodeBlockCount(&buf) - assert.NoError(t, err) + require.NoError(t, err) result := buf.Bytes() r := bytes.NewReader(result) var sb RawSpanBatch err = sb.decodeBlockCount(r) - assert.NoError(t, err) + require.NoError(t, err) - assert.Equal(t, rawSpanBatch.blockCount, sb.blockCount) + require.Equal(t, rawSpanBatch.blockCount, sb.blockCount) } func TestSpanBatchBlockTxCounts(t *testing.T) { @@ -215,7 +252,7 @@ func TestSpanBatchBlockTxCounts(t *testing.T) { var buf bytes.Buffer err := rawSpanBatch.encodeBlockTxCounts(&buf) - assert.NoError(t, err) + require.NoError(t, err) result := buf.Bytes() r := bytes.NewReader(result) @@ -223,9 +260,9 @@ func TestSpanBatchBlockTxCounts(t *testing.T) { sb.blockCount = rawSpanBatch.blockCount err = sb.decodeBlockTxCounts(r) - assert.NoError(t, err) + require.NoError(t, err) - assert.Equal(t, rawSpanBatch.blockTxCounts, sb.blockTxCounts) + require.Equal(t, rawSpanBatch.blockTxCounts, sb.blockTxCounts) } func TestSpanBatchTxs(t *testing.T) { @@ -236,7 +273,7 @@ func TestSpanBatchTxs(t *testing.T) { var buf bytes.Buffer err := rawSpanBatch.encodeTxs(&buf) - assert.NoError(t, err) + require.NoError(t, err) result := buf.Bytes() r := bytes.NewReader(result) @@ -244,11 +281,11 @@ func TestSpanBatchTxs(t *testing.T) { sb.blockTxCounts = rawSpanBatch.blockTxCounts err = sb.decodeTxs(r) - assert.NoError(t, err) + require.NoError(t, err) sb.txs.recoverV(chainID) - assert.Equal(t, rawSpanBatch.txs, sb.txs) + require.Equal(t, rawSpanBatch.txs, sb.txs) } func TestSpanBatchRoundTrip(t *testing.T) { @@ -257,16 +294,17 @@ func TestSpanBatchRoundTrip(t *testing.T) { rawSpanBatch := RandomRawSpanBatch(rng, chainID) - result, err := rawSpanBatch.encodeBytes() - assert.NoError(t, err) + var result bytes.Buffer + err := rawSpanBatch.encode(&result) + require.NoError(t, err) var sb RawSpanBatch - err = sb.decodeBytes(result) - assert.NoError(t, err) + err = sb.decode(bytes.NewReader(result.Bytes())) + require.NoError(t, err) sb.txs.recoverV(chainID) - assert.Equal(t, rawSpanBatch, &sb) + require.Equal(t, rawSpanBatch, &sb) } func TestSpanBatchDerive(t *testing.T) { @@ -284,24 +322,24 @@ func TestSpanBatchDerive(t *testing.T) { spanBatch := NewSpanBatch(singularBatches) originChangedBit := uint(originChangedBit) rawSpanBatch, err := spanBatch.ToRawSpanBatch(originChangedBit, genesisTimeStamp, chainID) - assert.NoError(t, err) + require.NoError(t, err) spanBatchDerived, err := rawSpanBatch.derive(l2BlockTime, genesisTimeStamp, chainID) - assert.NoError(t, err) + require.NoError(t, err) blockCount := len(singularBatches) - assert.Equal(t, safeL2Head.Hash.Bytes()[:20], spanBatchDerived.parentCheck) - assert.Equal(t, singularBatches[blockCount-1].Epoch().Hash.Bytes()[:20], spanBatchDerived.l1OriginCheck) - assert.Equal(t, len(singularBatches), int(rawSpanBatch.blockCount)) + require.Equal(t, safeL2Head.Hash.Bytes()[:20], spanBatchDerived.parentCheck[:]) + require.Equal(t, singularBatches[blockCount-1].Epoch().Hash.Bytes()[:20], spanBatchDerived.l1OriginCheck[:]) + require.Equal(t, len(singularBatches), int(rawSpanBatch.blockCount)) for i := 1; i < len(singularBatches); i++ { - assert.Equal(t, spanBatchDerived.batches[i].Timestamp, spanBatchDerived.batches[i-1].Timestamp+l2BlockTime) + require.Equal(t, spanBatchDerived.batches[i].Timestamp, spanBatchDerived.batches[i-1].Timestamp+l2BlockTime) } for i := 0; i < len(singularBatches); i++ { - assert.Equal(t, singularBatches[i].EpochNum, spanBatchDerived.batches[i].EpochNum) - assert.Equal(t, singularBatches[i].Timestamp, spanBatchDerived.batches[i].Timestamp) - assert.Equal(t, singularBatches[i].Transactions, spanBatchDerived.batches[i].Transactions) + require.Equal(t, singularBatches[i].EpochNum, spanBatchDerived.batches[i].EpochNum) + require.Equal(t, singularBatches[i].Timestamp, spanBatchDerived.batches[i].Timestamp) + require.Equal(t, singularBatches[i].Transactions, spanBatchDerived.batches[i].Transactions) } } } @@ -322,7 +360,7 @@ func TestSpanBatchAppend(t *testing.T) { // initialize with two singular batches spanBatch2 := NewSpanBatch(singularBatches[:L]) - assert.Equal(t, spanBatch, spanBatch2) + require.Equal(t, spanBatch, spanBatch2) } func TestSpanBatchMerge(t *testing.T) { @@ -338,32 +376,32 @@ func TestSpanBatchMerge(t *testing.T) { spanBatch := NewSpanBatch(singularBatches) originChangedBit := uint(originChangedBit) rawSpanBatch, err := spanBatch.ToRawSpanBatch(originChangedBit, genesisTimeStamp, chainID) - assert.NoError(t, err) + require.NoError(t, err) // check span batch prefix - assert.Equal(t, rawSpanBatch.relTimestamp, singularBatches[0].Timestamp-genesisTimeStamp, "invalid relative timestamp") - assert.Equal(t, rollup.Epoch(rawSpanBatch.l1OriginNum), singularBatches[blockCount-1].EpochNum) - assert.Equal(t, rawSpanBatch.parentCheck, singularBatches[0].ParentHash.Bytes()[:20], "invalid parent check") - assert.Equal(t, rawSpanBatch.l1OriginCheck, singularBatches[blockCount-1].EpochHash.Bytes()[:20], "invalid l1 origin check") + require.Equal(t, rawSpanBatch.relTimestamp, singularBatches[0].Timestamp-genesisTimeStamp, "invalid relative timestamp") + require.Equal(t, rollup.Epoch(rawSpanBatch.l1OriginNum), singularBatches[blockCount-1].EpochNum) + require.Equal(t, rawSpanBatch.parentCheck[:], singularBatches[0].ParentHash.Bytes()[:20], "invalid parent check") + require.Equal(t, rawSpanBatch.l1OriginCheck[:], singularBatches[blockCount-1].EpochHash.Bytes()[:20], "invalid l1 origin check") // check span batch payload - assert.Equal(t, int(rawSpanBatch.blockCount), len(singularBatches)) - assert.Equal(t, rawSpanBatch.originBits.Bit(0), originChangedBit) + require.Equal(t, int(rawSpanBatch.blockCount), len(singularBatches)) + require.Equal(t, rawSpanBatch.originBits.Bit(0), originChangedBit) for i := 1; i < blockCount; i++ { if rawSpanBatch.originBits.Bit(i) == 1 { - assert.Equal(t, singularBatches[i].EpochNum, singularBatches[i-1].EpochNum+1) + require.Equal(t, singularBatches[i].EpochNum, singularBatches[i-1].EpochNum+1) } else { - assert.Equal(t, singularBatches[i].EpochNum, singularBatches[i-1].EpochNum) + require.Equal(t, singularBatches[i].EpochNum, singularBatches[i-1].EpochNum) } } for i := 0; i < len(singularBatches); i++ { txCount := len(singularBatches[i].Transactions) - assert.Equal(t, txCount, int(rawSpanBatch.blockTxCounts[i])) + require.Equal(t, txCount, int(rawSpanBatch.blockTxCounts[i])) } // check invariants endEpochNum := rawSpanBatch.l1OriginNum - assert.Equal(t, endEpochNum, uint64(singularBatches[blockCount-1].EpochNum)) + require.Equal(t, endEpochNum, uint64(singularBatches[blockCount-1].EpochNum)) // we do not check txs field because it has to be derived to be compared } @@ -383,12 +421,12 @@ func TestSpanBatchToSingularBatch(t *testing.T) { spanBatch := NewSpanBatch(singularBatches) originChangedBit := uint(originChangedBit) rawSpanBatch, err := spanBatch.ToRawSpanBatch(originChangedBit, genesisTimeStamp, chainID) - assert.NoError(t, err) + require.NoError(t, err) l1Origins := mockL1Origin(rng, rawSpanBatch, singularBatches) singularBatches2, err := spanBatch.GetSingularBatches(l1Origins, safeL2Head) - assert.NoError(t, err) + require.NoError(t, err) // GetSingularBatches does not fill in parent hash of singular batches // empty out parent hash for comparison @@ -397,52 +435,54 @@ func TestSpanBatchToSingularBatch(t *testing.T) { } // check parent hash is empty for i := 0; i < len(singularBatches2); i++ { - assert.Equal(t, singularBatches2[i].ParentHash, common.Hash{}) + require.Equal(t, singularBatches2[i].ParentHash, common.Hash{}) } - assert.Equal(t, singularBatches, singularBatches2) + require.Equal(t, singularBatches, singularBatches2) } } func TestSpanBatchReadTxData(t *testing.T) { - rng := rand.New(rand.NewSource(0x109550)) - chainID := new(big.Int).SetUint64(rng.Uint64()) - - txCount := 64 - - signer := types.NewLondonSigner(chainID) - var rawTxs [][]byte - var txs []*types.Transaction - m := make(map[byte]int) - for i := 0; i < txCount; i++ { - tx := testutils.RandomTx(rng, new(big.Int).SetUint64(rng.Uint64()), signer) - m[tx.Type()] += 1 - rawTx, err := tx.MarshalBinary() - assert.NoError(t, err) - rawTxs = append(rawTxs, rawTx) - txs = append(txs, tx) + cases := []spanBatchTxTest{ + {"legacy tx", 32, testutils.RandomLegacyTx}, + {"access list tx", 32, testutils.RandomAccessListTx}, + {"dynamic fee tx", 32, testutils.RandomDynamicFeeTx}, } - for i := 0; i < txCount; i++ { - r := bytes.NewReader(rawTxs[i]) - _, txType, err := ReadTxData(r) - assert.NoError(t, err) - assert.Equal(t, int(txs[i].Type()), txType) + for i, testCase := range cases { + t.Run(testCase.name, func(t *testing.T) { + rng := rand.New(rand.NewSource(int64(0x109550 + i))) + chainID := new(big.Int).SetUint64(rng.Uint64()) + signer := types.NewLondonSigner(chainID) + + var rawTxs [][]byte + var txs []*types.Transaction + for txIdx := 0; txIdx < testCase.trials; txIdx++ { + tx := testCase.mkTx(rng, signer) + rawTx, err := tx.MarshalBinary() + require.NoError(t, err) + rawTxs = append(rawTxs, rawTx) + txs = append(txs, tx) + } + + for txIdx := 0; txIdx < testCase.trials; txIdx++ { + r := bytes.NewReader(rawTxs[i]) + _, txType, err := ReadTxData(r) + require.NoError(t, err) + assert.Equal(t, int(txs[i].Type()), txType) + } + }) } - // make sure every tx type is tested - assert.Positive(t, m[types.LegacyTxType]) - assert.Positive(t, m[types.AccessListTxType]) - assert.Positive(t, m[types.DynamicFeeTxType]) } func TestSpanBatchReadTxDataInvalid(t *testing.T) { dummy, err := rlp.EncodeToBytes("dummy") - assert.NoError(t, err) + require.NoError(t, err) // test non list rlp decoding r := bytes.NewReader(dummy) _, _, err = ReadTxData(r) - assert.ErrorContains(t, err, "tx RLP prefix type must be list") + require.ErrorContains(t, err, "tx RLP prefix type must be list") } func TestSpanBatchBuilder(t *testing.T) { @@ -457,34 +497,34 @@ func TestSpanBatchBuilder(t *testing.T) { } genesisTimeStamp := 1 + singularBatches[0].Timestamp - 128 - parentEpoch := uint64(singularBatches[0].EpochNum) + var seqNum uint64 = 1 if originChangedBit == 1 { - parentEpoch -= 1 + seqNum = 0 } - spanBatchBuilder := NewSpanBatchBuilder(parentEpoch, genesisTimeStamp, chainID) + spanBatchBuilder := NewSpanBatchBuilder(genesisTimeStamp, chainID) - assert.Equal(t, 0, spanBatchBuilder.GetBlockCount()) + require.Equal(t, 0, spanBatchBuilder.GetBlockCount()) for i := 0; i < len(singularBatches); i++ { - spanBatchBuilder.AppendSingularBatch(singularBatches[i]) - assert.Equal(t, i+1, spanBatchBuilder.GetBlockCount()) - assert.Equal(t, singularBatches[0].ParentHash.Bytes()[:20], spanBatchBuilder.spanBatch.parentCheck) - assert.Equal(t, singularBatches[i].EpochHash.Bytes()[:20], spanBatchBuilder.spanBatch.l1OriginCheck) + spanBatchBuilder.AppendSingularBatch(singularBatches[i], seqNum) + require.Equal(t, i+1, spanBatchBuilder.GetBlockCount()) + require.Equal(t, singularBatches[0].ParentHash.Bytes()[:20], spanBatchBuilder.spanBatch.parentCheck[:]) + require.Equal(t, singularBatches[i].EpochHash.Bytes()[:20], spanBatchBuilder.spanBatch.l1OriginCheck[:]) } rawSpanBatch, err := spanBatchBuilder.GetRawSpanBatch() - assert.NoError(t, err) + require.NoError(t, err) // compare with rawSpanBatch not using spanBatchBuilder spanBatch := NewSpanBatch(singularBatches) originChangedBit := uint(originChangedBit) rawSpanBatch2, err := spanBatch.ToRawSpanBatch(originChangedBit, genesisTimeStamp, chainID) - assert.NoError(t, err) + require.NoError(t, err) - assert.Equal(t, rawSpanBatch2, rawSpanBatch) + require.Equal(t, rawSpanBatch2, rawSpanBatch) spanBatchBuilder.Reset() - assert.Equal(t, 0, spanBatchBuilder.GetBlockCount()) + require.Equal(t, 0, spanBatchBuilder.GetBlockCount()) } } @@ -492,23 +532,82 @@ func TestSpanBatchMaxTxData(t *testing.T) { rng := rand.New(rand.NewSource(0x177288)) invalidTx := types.NewTx(&types.DynamicFeeTx{ - Data: testutils.RandomData(rng, MaxSpanBatchFieldSize+1), + Data: testutils.RandomData(rng, MaxSpanBatchSize+1), }) txEncoded, err := invalidTx.MarshalBinary() - assert.NoError(t, err) + require.NoError(t, err) r := bytes.NewReader(txEncoded) _, _, err = ReadTxData(r) - assert.ErrorIs(t, err, ErrTooBigSpanBatchFieldSize) + require.ErrorIs(t, err, ErrTooBigSpanBatchSize) } func TestSpanBatchMaxOriginBitsLength(t *testing.T) { var sb RawSpanBatch - sb.blockCount = 0xFFFFFFFFFFFFFFFF + sb.blockCount = math.MaxUint64 r := bytes.NewReader([]byte{}) err := sb.decodeOriginBits(r) - assert.ErrorIs(t, err, ErrTooBigSpanBatchFieldSize) + require.ErrorIs(t, err, ErrTooBigSpanBatchSize) +} + +func TestSpanBatchMaxBlockCount(t *testing.T) { + rng := rand.New(rand.NewSource(0x77556691)) + chainID := big.NewInt(rng.Int63n(1000)) + + rawSpanBatch := RandomRawSpanBatch(rng, chainID) + rawSpanBatch.blockCount = math.MaxUint64 + + var buf bytes.Buffer + err := rawSpanBatch.encodeBlockCount(&buf) + require.NoError(t, err) + + result := buf.Bytes() + r := bytes.NewReader(result) + var sb RawSpanBatch + err = sb.decodeBlockCount(r) + require.ErrorIs(t, err, ErrTooBigSpanBatchSize) +} + +func TestSpanBatchMaxBlockTxCount(t *testing.T) { + rng := rand.New(rand.NewSource(0x77556692)) + chainID := big.NewInt(rng.Int63n(1000)) + + rawSpanBatch := RandomRawSpanBatch(rng, chainID) + rawSpanBatch.blockTxCounts[0] = math.MaxUint64 + + var buf bytes.Buffer + err := rawSpanBatch.encodeBlockTxCounts(&buf) + require.NoError(t, err) + + result := buf.Bytes() + r := bytes.NewReader(result) + var sb RawSpanBatch + sb.blockCount = rawSpanBatch.blockCount + err = sb.decodeBlockTxCounts(r) + require.ErrorIs(t, err, ErrTooBigSpanBatchSize) +} + +func TestSpanBatchTotalBlockTxCountNotOverflow(t *testing.T) { + rng := rand.New(rand.NewSource(0x77556693)) + chainID := big.NewInt(rng.Int63n(1000)) + + rawSpanBatch := RandomRawSpanBatch(rng, chainID) + rawSpanBatch.blockTxCounts[0] = MaxSpanBatchSize - 1 + rawSpanBatch.blockTxCounts[1] = MaxSpanBatchSize - 1 + // we are sure that totalBlockTxCount will overflow on uint64 + + var buf bytes.Buffer + err := rawSpanBatch.encodeBlockTxCounts(&buf) + require.NoError(t, err) + + result := buf.Bytes() + r := bytes.NewReader(result) + var sb RawSpanBatch + sb.blockTxCounts = rawSpanBatch.blockTxCounts + err = sb.decodeTxs(r) + + require.ErrorIs(t, err, ErrTooBigSpanBatchSize) } diff --git a/op-node/rollup/derive/span_batch_tx.go b/op-node/rollup/derive/span_batch_tx.go index c35a95fbc3a67..12628097a3f5f 100644 --- a/op-node/rollup/derive/span_batch_tx.go +++ b/op-node/rollup/derive/span_batch_tx.go @@ -4,7 +4,6 @@ import ( "bytes" "errors" "fmt" - "io" "math/big" "github.com/ethereum/go-ethereum/common" @@ -70,21 +69,6 @@ func (tx *spanBatchTx) MarshalBinary() ([]byte, error) { return buf.Bytes(), err } -// EncodeRLP implements rlp.Encoder -func (tx *spanBatchTx) EncodeRLP(w io.Writer) error { - if tx.Type() == types.LegacyTxType { - return rlp.Encode(w, tx.inner) - } - // It's an EIP-2718 typed TX envelope. - buf := encodeBufferPool.Get().(*bytes.Buffer) - defer encodeBufferPool.Put(buf) - buf.Reset() - if err := tx.encodeTyped(buf); err != nil { - return err - } - return rlp.Encode(w, buf.Bytes()) -} - // setDecoded sets the inner transaction after decoding. func (tx *spanBatchTx) setDecoded(inner spanBatchTxData, size uint64) { tx.inner = inner @@ -115,36 +99,6 @@ func (tx *spanBatchTx) decodeTyped(b []byte) (spanBatchTxData, error) { } } -// DecodeRLP implements rlp.Decoder -func (tx *spanBatchTx) DecodeRLP(s *rlp.Stream) error { - kind, size, err := s.Kind() - switch { - case err != nil: - return err - case kind == rlp.List: - // It's a legacy transaction. - var inner spanBatchLegacyTxData - err = s.Decode(&inner) - if err != nil { - return fmt.Errorf("failed to decode spanBatchLegacyTxData: %w", err) - } - tx.setDecoded(&inner, rlp.ListSize(size)) - return nil - default: - // It's an EIP-2718 typed TX envelope. - var b []byte - if b, err = s.Bytes(); err != nil { - return err - } - inner, err := tx.decodeTyped(b) - if err != nil { - return err - } - tx.setDecoded(inner, uint64(len(b))) - return nil - } -} - // UnmarshalBinary decodes the canonical encoding of transactions. // It supports legacy RLP transactions and EIP2718 typed transactions. func (tx *spanBatchTx) UnmarshalBinary(b []byte) error { diff --git a/op-node/rollup/derive/span_batch_tx_test.go b/op-node/rollup/derive/span_batch_tx_test.go index d995e9fb015a1..dd50cb6bbbfab 100644 --- a/op-node/rollup/derive/span_batch_tx_test.go +++ b/op-node/rollup/derive/span_batch_tx_test.go @@ -1,103 +1,87 @@ package derive import ( - "bytes" "math/big" "math/rand" "testing" "github.com/ethereum-optimism/optimism/op-service/testutils" "github.com/ethereum/go-ethereum/core/types" - "github.com/ethereum/go-ethereum/rlp" "github.com/stretchr/testify/assert" + "github.com/stretchr/testify/require" ) +type spanBatchTxTest struct { + name string + trials int + mkTx func(rng *rand.Rand, signer types.Signer) *types.Transaction +} + func TestSpanBatchTxConvert(t *testing.T) { - rng := rand.New(rand.NewSource(0x1331)) - chainID := big.NewInt(rng.Int63n(1000)) - signer := types.NewLondonSigner(chainID) - - m := make(map[byte]int) - for i := 0; i < 32; i++ { - tx := testutils.RandomTx(rng, new(big.Int).SetUint64(rng.Uint64()), signer) - m[tx.Type()] += 1 - v, r, s := tx.RawSignatureValues() - sbtx, err := newSpanBatchTx(*tx) - assert.NoError(t, err) - - tx2, err := sbtx.convertToFullTx(tx.Nonce(), tx.Gas(), tx.To(), chainID, v, r, s) - assert.NoError(t, err) - - // compare after marshal because we only need inner field of transaction - txEncoded, err := tx.MarshalBinary() - assert.NoError(t, err) - tx2Encoded, err := tx2.MarshalBinary() - assert.NoError(t, err) - - assert.Equal(t, txEncoded, tx2Encoded) + cases := []spanBatchTxTest{ + {"legacy tx", 32, testutils.RandomLegacyTx}, + {"access list tx", 32, testutils.RandomAccessListTx}, + {"dynamic fee tx", 32, testutils.RandomDynamicFeeTx}, } - // make sure every tx type is tested - assert.Positive(t, m[types.LegacyTxType]) - assert.Positive(t, m[types.AccessListTxType]) - assert.Positive(t, m[types.DynamicFeeTxType]) -} -func TestSpanBatchTxRoundTrip(t *testing.T) { - rng := rand.New(rand.NewSource(0x1332)) - chainID := big.NewInt(rng.Int63n(1000)) - signer := types.NewLondonSigner(chainID) + for i, testCase := range cases { + t.Run(testCase.name, func(t *testing.T) { + rng := rand.New(rand.NewSource(int64(0x1331 + i))) + chainID := big.NewInt(rng.Int63n(1000)) + signer := types.NewLondonSigner(chainID) - m := make(map[byte]int) - for i := 0; i < 32; i++ { - tx := testutils.RandomTx(rng, new(big.Int).SetUint64(rng.Uint64()), signer) - m[tx.Type()] += 1 - sbtx, err := newSpanBatchTx(*tx) - assert.NoError(t, err) + for txIdx := 0; txIdx < testCase.trials; txIdx++ { + tx := testCase.mkTx(rng, signer) - sbtxEncoded, err := sbtx.MarshalBinary() - assert.NoError(t, err) + v, r, s := tx.RawSignatureValues() + sbtx, err := newSpanBatchTx(*tx) + require.NoError(t, err) - var sbtx2 spanBatchTx - err = sbtx2.UnmarshalBinary(sbtxEncoded) - assert.NoError(t, err) + tx2, err := sbtx.convertToFullTx(tx.Nonce(), tx.Gas(), tx.To(), chainID, v, r, s) + require.NoError(t, err) - assert.Equal(t, sbtx, &sbtx2) + // compare after marshal because we only need inner field of transaction + txEncoded, err := tx.MarshalBinary() + require.NoError(t, err) + tx2Encoded, err := tx2.MarshalBinary() + require.NoError(t, err) + + assert.Equal(t, txEncoded, tx2Encoded) + } + }) } - // make sure every tx type is tested - assert.Positive(t, m[types.LegacyTxType]) - assert.Positive(t, m[types.AccessListTxType]) - assert.Positive(t, m[types.DynamicFeeTxType]) } -func TestSpanBatchTxRoundTripRLP(t *testing.T) { - rng := rand.New(rand.NewSource(0x1333)) - chainID := big.NewInt(rng.Int63n(1000)) - signer := types.NewLondonSigner(chainID) - - m := make(map[byte]int) - for i := 0; i < 32; i++ { - tx := testutils.RandomTx(rng, new(big.Int).SetUint64(rng.Uint64()), signer) - m[tx.Type()] += 1 - sbtx, err := newSpanBatchTx(*tx) - assert.NoError(t, err) - - var buf bytes.Buffer - err = sbtx.EncodeRLP(&buf) - assert.NoError(t, err) - - result := buf.Bytes() - var sbtx2 spanBatchTx - r := bytes.NewReader(result) - rlpReader := rlp.NewStream(r, 0) - err = sbtx2.DecodeRLP(rlpReader) - assert.NoError(t, err) - - assert.Equal(t, sbtx, &sbtx2) +func TestSpanBatchTxRoundTrip(t *testing.T) { + cases := []spanBatchTxTest{ + {"legacy tx", 32, testutils.RandomLegacyTx}, + {"access list tx", 32, testutils.RandomAccessListTx}, + {"dynamic fee tx", 32, testutils.RandomDynamicFeeTx}, + } + + for i, testCase := range cases { + t.Run(testCase.name, func(t *testing.T) { + rng := rand.New(rand.NewSource(int64(0x1332 + i))) + chainID := big.NewInt(rng.Int63n(1000)) + signer := types.NewLondonSigner(chainID) + + for txIdx := 0; txIdx < testCase.trials; txIdx++ { + tx := testCase.mkTx(rng, signer) + + sbtx, err := newSpanBatchTx(*tx) + require.NoError(t, err) + + sbtxEncoded, err := sbtx.MarshalBinary() + require.NoError(t, err) + + var sbtx2 spanBatchTx + err = sbtx2.UnmarshalBinary(sbtxEncoded) + require.NoError(t, err) + + assert.Equal(t, sbtx, &sbtx2) + } + }) } - // make sure every tx type is tested - assert.Positive(t, m[types.LegacyTxType]) - assert.Positive(t, m[types.AccessListTxType]) - assert.Positive(t, m[types.DynamicFeeTxType]) } type spanBatchDummyTxData struct{} @@ -107,44 +91,44 @@ func TestSpanBatchTxInvalidTxType(t *testing.T) { // span batch never contain deposit tx depositTx := types.NewTx(&types.DepositTx{}) _, err := newSpanBatchTx(*depositTx) - assert.ErrorContains(t, err, "invalid tx type") + require.ErrorContains(t, err, "invalid tx type") var sbtx spanBatchTx sbtx.inner = &spanBatchDummyTxData{} _, err = sbtx.convertToFullTx(0, 0, nil, nil, nil, nil, nil) - assert.ErrorContains(t, err, "invalid tx type") + require.ErrorContains(t, err, "invalid tx type") } func TestSpanBatchTxDecodeInvalid(t *testing.T) { var sbtx spanBatchTx _, err := sbtx.decodeTyped([]byte{}) - assert.EqualError(t, err, "typed transaction too short") + require.EqualError(t, err, "typed transaction too short") tx := types.NewTx(&types.LegacyTx{}) txEncoded, err := tx.MarshalBinary() - assert.NoError(t, err) + require.NoError(t, err) // legacy tx is not typed tx _, err = sbtx.decodeTyped(txEncoded) - assert.EqualError(t, err, types.ErrTxTypeNotSupported.Error()) + require.EqualError(t, err, types.ErrTxTypeNotSupported.Error()) tx2 := types.NewTx(&types.AccessListTx{}) tx2Encoded, err := tx2.MarshalBinary() - assert.NoError(t, err) + require.NoError(t, err) tx2Encoded[0] = types.DynamicFeeTxType _, err = sbtx.decodeTyped(tx2Encoded) - assert.ErrorContains(t, err, "failed to decode spanBatchDynamicFeeTxData") + require.ErrorContains(t, err, "failed to decode spanBatchDynamicFeeTxData") tx3 := types.NewTx(&types.DynamicFeeTx{}) tx3Encoded, err := tx3.MarshalBinary() - assert.NoError(t, err) + require.NoError(t, err) tx3Encoded[0] = types.AccessListTxType _, err = sbtx.decodeTyped(tx3Encoded) - assert.ErrorContains(t, err, "failed to decode spanBatchAccessListTxData") + require.ErrorContains(t, err, "failed to decode spanBatchAccessListTxData") invalidLegacyTxDecoded := []byte{0xFF, 0xFF} err = sbtx.UnmarshalBinary(invalidLegacyTxDecoded) - assert.ErrorContains(t, err, "failed to decode spanBatchLegacyTxData") + require.ErrorContains(t, err, "failed to decode spanBatchLegacyTxData") } diff --git a/op-node/rollup/derive/span_batch_txs.go b/op-node/rollup/derive/span_batch_txs.go index 17dd13262346b..4f2fe19b58edf 100644 --- a/op-node/rollup/derive/span_batch_txs.go +++ b/op-node/rollup/derive/span_batch_txs.go @@ -67,8 +67,8 @@ func (btx *spanBatchTxs) decodeContractCreationBits(r *bytes.Reader) error { contractCreationBitBufferLen++ } // avoid out of memory before allocation - if contractCreationBitBufferLen > MaxSpanBatchFieldSize { - return ErrTooBigSpanBatchFieldSize + if contractCreationBitBufferLen > MaxSpanBatchSize { + return ErrTooBigSpanBatchSize } contractCreationBitBuffer := make([]byte, contractCreationBitBufferLen) _, err := io.ReadFull(r, contractCreationBitBuffer) @@ -190,8 +190,8 @@ func (btx *spanBatchTxs) decodeYParityBits(r *bytes.Reader) error { yParityBitBufferLen++ } // avoid out of memory before allocation - if yParityBitBufferLen > MaxSpanBatchFieldSize { - return ErrTooBigSpanBatchFieldSize + if yParityBitBufferLen > MaxSpanBatchSize { + return ErrTooBigSpanBatchSize } yParityBitBuffer := make([]byte, yParityBitBufferLen) _, err := io.ReadFull(r, yParityBitBuffer) diff --git a/op-node/rollup/derive/span_batch_txs_test.go b/op-node/rollup/derive/span_batch_txs_test.go index f393c8df70f49..1fda8b5ffbf33 100644 --- a/op-node/rollup/derive/span_batch_txs_test.go +++ b/op-node/rollup/derive/span_batch_txs_test.go @@ -6,10 +6,12 @@ import ( "math/rand" "testing" - "github.com/ethereum-optimism/optimism/op-service/testutils" - "github.com/ethereum/go-ethereum/core/types" "github.com/holiman/uint256" - "github.com/stretchr/testify/assert" + "github.com/stretchr/testify/require" + + "github.com/ethereum/go-ethereum/core/types" + + "github.com/ethereum-optimism/optimism/op-service/testutils" ) func TestSpanBatchTxsContractCreationBits(t *testing.T) { @@ -26,23 +28,23 @@ func TestSpanBatchTxsContractCreationBits(t *testing.T) { var buf bytes.Buffer err := sbt.encodeContractCreationBits(&buf) - assert.NoError(t, err) + require.NoError(t, err) // contractCreationBit field is fixed length: single bit contractCreationBitBufferLen := totalBlockTxCount / 8 if totalBlockTxCount%8 != 0 { contractCreationBitBufferLen++ } - assert.Equal(t, buf.Len(), int(contractCreationBitBufferLen)) + require.Equal(t, buf.Len(), int(contractCreationBitBufferLen)) result := buf.Bytes() sbt.contractCreationBits = nil r := bytes.NewReader(result) err = sbt.decodeContractCreationBits(r) - assert.NoError(t, err) + require.NoError(t, err) - assert.Equal(t, contractCreationBits, sbt.contractCreationBits) + require.Equal(t, contractCreationBits, sbt.contractCreationBits) } func TestSpanBatchTxsContractCreationCount(t *testing.T) { @@ -61,16 +63,16 @@ func TestSpanBatchTxsContractCreationCount(t *testing.T) { var buf bytes.Buffer err := sbt.encodeContractCreationBits(&buf) - assert.NoError(t, err) + require.NoError(t, err) result := buf.Bytes() sbt.contractCreationBits = nil r := bytes.NewReader(result) err = sbt.decodeContractCreationBits(r) - assert.NoError(t, err) + require.NoError(t, err) - assert.Equal(t, contractCreationCount, sbt.contractCreationCount()) + require.Equal(t, contractCreationCount, sbt.contractCreationCount()) } func TestSpanBatchTxsYParityBits(t *testing.T) { @@ -87,23 +89,23 @@ func TestSpanBatchTxsYParityBits(t *testing.T) { var buf bytes.Buffer err := sbt.encodeYParityBits(&buf) - assert.NoError(t, err) + require.NoError(t, err) // yParityBit field is fixed length: single bit yParityBitBufferLen := totalBlockTxCount / 8 if totalBlockTxCount%8 != 0 { yParityBitBufferLen++ } - assert.Equal(t, buf.Len(), int(yParityBitBufferLen)) + require.Equal(t, buf.Len(), int(yParityBitBufferLen)) result := buf.Bytes() sbt.yParityBits = nil r := bytes.NewReader(result) err = sbt.decodeYParityBits(r) - assert.NoError(t, err) + require.NoError(t, err) - assert.Equal(t, yParityBits, sbt.yParityBits) + require.Equal(t, yParityBits, sbt.yParityBits) } func TestSpanBatchTxsTxSigs(t *testing.T) { @@ -120,22 +122,22 @@ func TestSpanBatchTxsTxSigs(t *testing.T) { var buf bytes.Buffer err := sbt.encodeTxSigsRS(&buf) - assert.NoError(t, err) + require.NoError(t, err) // txSig field is fixed length: 32 byte + 32 byte = 64 byte - assert.Equal(t, buf.Len(), 64*int(totalBlockTxCount)) + require.Equal(t, buf.Len(), 64*int(totalBlockTxCount)) result := buf.Bytes() sbt.txSigs = nil r := bytes.NewReader(result) err = sbt.decodeTxSigsRS(r) - assert.NoError(t, err) + require.NoError(t, err) // v field is not set for i := 0; i < int(totalBlockTxCount); i++ { - assert.Equal(t, txSigs[i].r, sbt.txSigs[i].r) - assert.Equal(t, txSigs[i].s, sbt.txSigs[i].s) + require.Equal(t, txSigs[i].r, sbt.txSigs[i].r) + require.Equal(t, txSigs[i].s, sbt.txSigs[i].s) } } @@ -153,16 +155,16 @@ func TestSpanBatchTxsTxNonces(t *testing.T) { var buf bytes.Buffer err := sbt.encodeTxNonces(&buf) - assert.NoError(t, err) + require.NoError(t, err) result := buf.Bytes() sbt.txNonces = nil r := bytes.NewReader(result) err = sbt.decodeTxNonces(r) - assert.NoError(t, err) + require.NoError(t, err) - assert.Equal(t, txNonces, sbt.txNonces) + require.Equal(t, txNonces, sbt.txNonces) } func TestSpanBatchTxsTxGases(t *testing.T) { @@ -179,16 +181,16 @@ func TestSpanBatchTxsTxGases(t *testing.T) { var buf bytes.Buffer err := sbt.encodeTxGases(&buf) - assert.NoError(t, err) + require.NoError(t, err) result := buf.Bytes() sbt.txGases = nil r := bytes.NewReader(result) err = sbt.decodeTxGases(r) - assert.NoError(t, err) + require.NoError(t, err) - assert.Equal(t, txGases, sbt.txGases) + require.Equal(t, txGases, sbt.txGases) } func TestSpanBatchTxsTxTos(t *testing.T) { @@ -208,19 +210,19 @@ func TestSpanBatchTxsTxTos(t *testing.T) { var buf bytes.Buffer err := sbt.encodeTxTos(&buf) - assert.NoError(t, err) + require.NoError(t, err) // to field is fixed length: 20 bytes - assert.Equal(t, buf.Len(), 20*len(txTos)) + require.Equal(t, buf.Len(), 20*len(txTos)) result := buf.Bytes() sbt.txTos = nil r := bytes.NewReader(result) err = sbt.decodeTxTos(r) - assert.NoError(t, err) + require.NoError(t, err) - assert.Equal(t, txTos, sbt.txTos) + require.Equal(t, txTos, sbt.txTos) } func TestSpanBatchTxsTxDatas(t *testing.T) { @@ -239,7 +241,7 @@ func TestSpanBatchTxsTxDatas(t *testing.T) { var buf bytes.Buffer err := sbt.encodeTxDatas(&buf) - assert.NoError(t, err) + require.NoError(t, err) result := buf.Bytes() sbt.txDatas = nil @@ -247,10 +249,10 @@ func TestSpanBatchTxsTxDatas(t *testing.T) { r := bytes.NewReader(result) err = sbt.decodeTxDatas(r) - assert.NoError(t, err) + require.NoError(t, err) - assert.Equal(t, txDatas, sbt.txDatas) - assert.Equal(t, txTypes, sbt.txTypes) + require.Equal(t, txDatas, sbt.txDatas) + require.Equal(t, txTypes, sbt.txTypes) } func TestSpanBatchTxsRecoverV(t *testing.T) { @@ -290,7 +292,7 @@ func TestSpanBatchTxsRecoverV(t *testing.T) { recoveredVs = append(recoveredVs, txSig.v) } - assert.Equal(t, originalVs, recoveredVs, "recovered v mismatch") + require.Equal(t, originalVs, recoveredVs, "recovered v mismatch") } func TestSpanBatchTxsRoundTrip(t *testing.T) { @@ -304,7 +306,7 @@ func TestSpanBatchTxsRoundTrip(t *testing.T) { var buf bytes.Buffer err := sbt.encode(&buf) - assert.NoError(t, err) + require.NoError(t, err) result := buf.Bytes() r := bytes.NewReader(result) @@ -312,10 +314,10 @@ func TestSpanBatchTxsRoundTrip(t *testing.T) { var sbt2 spanBatchTxs sbt2.totalBlockTxCount = totalBlockTxCount err = sbt2.decode(r) - assert.NoError(t, err) + require.NoError(t, err) sbt2.recoverV(chainID) - assert.Equal(t, sbt, &sbt2) + require.Equal(t, sbt, &sbt2) } } @@ -330,16 +332,16 @@ func TestSpanBatchTxsRoundTripFullTxs(t *testing.T) { for i := 0; i < int(totalblockTxCounts); i++ { tx := testutils.RandomTx(rng, new(big.Int).SetUint64(rng.Uint64()), signer) rawTx, err := tx.MarshalBinary() - assert.NoError(t, err) + require.NoError(t, err) txs = append(txs, rawTx) } sbt, err := newSpanBatchTxs(txs, chainID) - assert.NoError(t, err) + require.NoError(t, err) txs2, err := sbt.fullTxs(chainID) - assert.NoError(t, err) + require.NoError(t, err) - assert.Equal(t, txs, txs2) + require.Equal(t, txs, txs2) } } @@ -372,17 +374,17 @@ func TestSpanBatchTxsFullTxNotEnoughTxTos(t *testing.T) { for i := 0; i < int(totalblockTxCounts); i++ { tx := testutils.RandomTx(rng, new(big.Int).SetUint64(rng.Uint64()), signer) rawTx, err := tx.MarshalBinary() - assert.NoError(t, err) + require.NoError(t, err) txs = append(txs, rawTx) } sbt, err := newSpanBatchTxs(txs, chainID) - assert.NoError(t, err) + require.NoError(t, err) // drop single to field sbt.txTos = sbt.txTos[:len(sbt.txTos)-2] _, err = sbt.fullTxs(chainID) - assert.EqualError(t, err, "tx to not enough") + require.EqualError(t, err, "tx to not enough") } func TestSpanBatchTxsMaxContractCreationBitsLength(t *testing.T) { @@ -391,7 +393,7 @@ func TestSpanBatchTxsMaxContractCreationBitsLength(t *testing.T) { r := bytes.NewReader([]byte{}) err := sbt.decodeContractCreationBits(r) - assert.ErrorIs(t, err, ErrTooBigSpanBatchFieldSize) + require.ErrorIs(t, err, ErrTooBigSpanBatchSize) } func TestSpanBatchTxsMaxYParityBitsLength(t *testing.T) { @@ -400,5 +402,5 @@ func TestSpanBatchTxsMaxYParityBitsLength(t *testing.T) { r := bytes.NewReader([]byte{}) err := sb.decodeOriginBits(r) - assert.ErrorIs(t, err, ErrTooBigSpanBatchFieldSize) + require.ErrorIs(t, err, ErrTooBigSpanBatchSize) } diff --git a/op-node/rollup/derive/span_channel_out.go b/op-node/rollup/derive/span_channel_out.go new file mode 100644 index 0000000000000..a272dfaf52257 --- /dev/null +++ b/op-node/rollup/derive/span_channel_out.go @@ -0,0 +1,228 @@ +package derive + +import ( + "bytes" + "crypto/rand" + "errors" + "fmt" + "io" + + "github.com/ethereum/go-ethereum/core/types" + "github.com/ethereum/go-ethereum/rlp" +) + +type SpanChannelOut struct { + id ChannelID + // Frame ID of the next frame to emit. Increment after emitting + frame uint64 + // rlpLength is the uncompressed size of the channel. Must be less than MAX_RLP_BYTES_PER_CHANNEL + rlpLength int + + // Compressor stage. Write input data to it + compress Compressor + // closed indicates if the channel is closed + closed bool + // spanBatchBuilder contains information requires to build SpanBatch + spanBatchBuilder *SpanBatchBuilder + // reader contains compressed data for making output frames + reader *bytes.Buffer +} + +func (co *SpanChannelOut) ID() ChannelID { + return co.id +} + +func NewSpanChannelOut(compress Compressor, spanBatchBuilder *SpanBatchBuilder) (*SpanChannelOut, error) { + c := &SpanChannelOut{ + id: ChannelID{}, + frame: 0, + rlpLength: 0, + compress: compress, + spanBatchBuilder: spanBatchBuilder, + reader: &bytes.Buffer{}, + } + _, err := rand.Read(c.id[:]) + if err != nil { + return nil, err + } + + return c, nil +} + +func (co *SpanChannelOut) Reset() error { + co.frame = 0 + co.rlpLength = 0 + co.compress.Reset() + co.reader.Reset() + co.closed = false + co.spanBatchBuilder.Reset() + _, err := rand.Read(co.id[:]) + return err +} + +// AddBlock adds a block to the channel. It returns the RLP encoded byte size +// and an error if there is a problem adding the block. The only sentinel error +// that it returns is ErrTooManyRLPBytes. If this error is returned, the channel +// should be closed and a new one should be made. +func (co *SpanChannelOut) AddBlock(block *types.Block) (uint64, error) { + if co.closed { + return 0, errors.New("already closed") + } + + batch, l1Info, err := BlockToSingularBatch(block) + if err != nil { + return 0, err + } + return co.AddSingularBatch(batch, l1Info.SequenceNumber) +} + +// AddSingularBatch adds a batch to the channel. It returns the RLP encoded byte size +// and an error if there is a problem adding the batch. The only sentinel error +// that it returns is ErrTooManyRLPBytes. If this error is returned, the channel +// should be closed and a new one should be made. +// +// AddSingularBatch should be used together with BlockToSingularBatch if you need to access the +// BatchData before adding a block to the channel. It isn't possible to access +// the batch data with AddBlock. +// +// SingularBatch is appended to the channel's SpanBatch. +// A channel can have only one SpanBatch. And compressed results should not be accessible until the channel is closed, since the prefix and payload can be changed. +// So it resets channel contents and rewrites the entire SpanBatch each time, and compressed results are copied to reader after the channel is closed. +// It makes we can only get frames once the channel is full or closed, in the case of SpanBatch. +func (co *SpanChannelOut) AddSingularBatch(batch *SingularBatch, seqNum uint64) (uint64, error) { + if co.closed { + return 0, errors.New("already closed") + } + if co.FullErr() != nil { + // channel is already full + return 0, co.FullErr() + } + var buf bytes.Buffer + // Append Singular batch to its span batch builder + co.spanBatchBuilder.AppendSingularBatch(batch, seqNum) + // Convert Span batch to RawSpanBatch + rawSpanBatch, err := co.spanBatchBuilder.GetRawSpanBatch() + if err != nil { + return 0, fmt.Errorf("failed to convert SpanBatch into RawSpanBatch: %w", err) + } + // Encode RawSpanBatch into bytes + if err = rlp.Encode(&buf, NewBatchData(rawSpanBatch)); err != nil { + return 0, fmt.Errorf("failed to encode RawSpanBatch into bytes: %w", err) + } + // Ensure that the total size of all RLP elements is less than or equal to MAX_RLP_BYTES_PER_CHANNEL + if buf.Len() > MaxRLPBytesPerChannel { + return 0, fmt.Errorf("could not take %d bytes as replacement of channel of %d bytes, max is %d. err: %w", + buf.Len(), co.rlpLength, MaxRLPBytesPerChannel, ErrTooManyRLPBytes) + } + co.rlpLength = buf.Len() + + if co.spanBatchBuilder.GetBlockCount() > 1 { + // Flush compressed data into reader to preserve current result. + // If the channel is full after this block is appended, we should use preserved data. + if err := co.compress.Flush(); err != nil { + return 0, fmt.Errorf("failed to flush compressor: %w", err) + } + _, err = io.Copy(co.reader, co.compress) + if err != nil { + // Must reset reader to avoid partial output + co.reader.Reset() + return 0, fmt.Errorf("failed to copy compressed data to reader: %w", err) + } + } + + // Reset compressor to rewrite the entire span batch + co.compress.Reset() + // Avoid using io.Copy here, because we need all or nothing + written, err := co.compress.Write(buf.Bytes()) + if co.compress.FullErr() != nil { + err = co.compress.FullErr() + if co.spanBatchBuilder.GetBlockCount() == 1 { + // Do not return CompressorFullErr for the first block in the batch + // In this case, reader must be empty. then the contents of compressor will be copied to reader when the channel is closed. + err = nil + } + // If there are more than one blocks in the channel, reader should have data that preserves previous compression result before adding this block. + // So, as a result, this block is not added to the channel and the channel will be closed. + return uint64(written), err + } + + // If compressor is not full yet, reader must be reset to avoid submitting invalid frames + co.reader.Reset() + return uint64(written), err +} + +// InputBytes returns the total amount of RLP-encoded input bytes. +func (co *SpanChannelOut) InputBytes() int { + return co.rlpLength +} + +// ReadyBytes returns the number of bytes that the channel out can immediately output into a frame. +// Use `Flush` or `Close` to move data from the compression buffer into the ready buffer if more bytes +// are needed. Add blocks may add to the ready buffer, but it is not guaranteed due to the compression stage. +func (co *SpanChannelOut) ReadyBytes() int { + return co.reader.Len() +} + +// Flush flushes the internal compression stage to the ready buffer. It enables pulling a larger & more +// complete frame. It reduces the compression efficiency. +func (co *SpanChannelOut) Flush() error { + if err := co.compress.Flush(); err != nil { + return err + } + if co.closed && co.ReadyBytes() == 0 && co.compress.Len() > 0 { + _, err := io.Copy(co.reader, co.compress) + if err != nil { + // Must reset reader to avoid partial output + co.reader.Reset() + return fmt.Errorf("failed to flush compressed data to reader: %w", err) + } + } + return nil +} + +func (co *SpanChannelOut) FullErr() error { + return co.compress.FullErr() +} + +func (co *SpanChannelOut) Close() error { + if co.closed { + return errors.New("already closed") + } + co.closed = true + if err := co.Flush(); err != nil { + return err + } + return co.compress.Close() +} + +// OutputFrame writes a frame to w with a given max size and returns the frame +// number. +// Use `ReadyBytes`, `Flush`, and `Close` to modify the ready buffer. +// Returns an error if the `maxSize` < FrameV0OverHeadSize. +// Returns io.EOF when the channel is closed & there are no more frames. +// Returns nil if there is still more buffered data. +// Returns an error if it ran into an error during processing. +func (co *SpanChannelOut) OutputFrame(w *bytes.Buffer, maxSize uint64) (uint16, error) { + // Check that the maxSize is large enough for the frame overhead size. + if maxSize < FrameV0OverHeadSize { + return 0, ErrMaxFrameSizeTooSmall + } + + f := createEmptyFrame(co.id, co.frame, co.ReadyBytes(), co.closed, maxSize) + + if _, err := io.ReadFull(co.reader, f.Data); err != nil { + return 0, err + } + + if err := f.MarshalBinary(w); err != nil { + return 0, err + } + + co.frame += 1 + fn := f.FrameNumber + if f.IsLast { + return fn, io.EOF + } else { + return fn, nil + } +} diff --git a/op-node/rollup/derive/test/random.go b/op-node/rollup/derive/test/random.go index 83ab5835808f9..5724fd023f317 100644 --- a/op-node/rollup/derive/test/random.go +++ b/op-node/rollup/derive/test/random.go @@ -1,6 +1,7 @@ package test import ( + "math/big" "math/rand" "github.com/ethereum-optimism/optimism/op-node/rollup/derive" @@ -21,3 +22,13 @@ func RandomL2Block(rng *rand.Rand, txCount int) (*types.Block, []*types.Receipt) } return testutils.RandomBlockPrependTxs(rng, txCount, types.NewTx(l1InfoTx)) } + +func RandomL2BlockWithChainId(rng *rand.Rand, txCount int, chainId *big.Int) *types.Block { + signer := types.NewLondonSigner(chainId) + block, _ := RandomL2Block(rng, 0) + txs := []*types.Transaction{block.Transactions()[0]} // L1 info deposit TX + for i := 0; i < txCount; i++ { + txs = append(txs, testutils.RandomTx(rng, big.NewInt(int64(rng.Uint32())), signer)) + } + return block.WithBody(txs, nil) +} diff --git a/op-node/rollup/driver/driver.go b/op-node/rollup/driver/driver.go index c41fea100a121..1db8d5dff87ed 100644 --- a/op-node/rollup/driver/driver.go +++ b/op-node/rollup/driver/driver.go @@ -60,6 +60,7 @@ type DerivationPipeline interface { Finalized() eth.L2BlockRef SafeL2Head() eth.L2BlockRef UnsafeL2Head() eth.L2BlockRef + PendingSafeL2Head() eth.L2BlockRef Origin() eth.L1BlockRef EngineReady() bool EngineSyncTarget() eth.L2BlockRef diff --git a/op-node/rollup/driver/state.go b/op-node/rollup/driver/state.go index 87d8ca8ec521b..6236c763f4f4c 100644 --- a/op-node/rollup/driver/state.go +++ b/op-node/rollup/driver/state.go @@ -481,6 +481,7 @@ func (s *Driver) syncStatus() *eth.SyncStatus { UnsafeL2: s.derivation.UnsafeL2Head(), SafeL2: s.derivation.SafeL2Head(), FinalizedL2: s.derivation.Finalized(), + PendingSafeL2: s.derivation.PendingSafeL2Head(), UnsafeL2SyncTarget: s.derivation.UnsafeL2SyncTarget(), EngineSyncTarget: s.derivation.EngineSyncTarget(), } diff --git a/op-node/rollup/superchain.go b/op-node/rollup/superchain.go index 2235a0051e86d..fe0e0ee460a3a 100644 --- a/op-node/rollup/superchain.go +++ b/op-node/rollup/superchain.go @@ -12,7 +12,7 @@ import ( "github.com/ethereum-optimism/superchain-registry/superchain" ) -var OPStackSupport = params.ProtocolVersionV0{Build: [8]byte{}, Major: 3, Minor: 1, Patch: 0, PreRelease: 1}.Encode() +var OPStackSupport = params.ProtocolVersionV0{Build: [8]byte{}, Major: 4, Minor: 0, Patch: 0, PreRelease: 1}.Encode() const ( opMainnet = 10 @@ -98,6 +98,7 @@ func LoadOPStackRollupConfig(chainID uint64) (*Config, error) { L1ChainID: new(big.Int).SetUint64(superChain.Config.L1.ChainID), L2ChainID: new(big.Int).SetUint64(chConfig.ChainID), RegolithTime: ®olithTime, + CanyonTime: superChain.Config.CanyonTime, BatchInboxAddress: common.Address(chConfig.BatchInboxAddr), DepositContractAddress: depositContractAddress, L1SystemConfigAddress: common.Address(chConfig.SystemConfigAddr), @@ -109,5 +110,9 @@ func LoadOPStackRollupConfig(chainID uint64) (*Config, error) { cfg.ChannelTimeout = 120 cfg.MaxSequencerDrift = 1200 } + if chainID == pgnSepolia { + cfg.MaxSequencerDrift = 1000 + cfg.SeqWindowSize = 7200 + } return cfg, nil } diff --git a/op-node/rollup/types.go b/op-node/rollup/types.go index 055f53069f4ec..abf3cdfcf71c9 100644 --- a/op-node/rollup/types.go +++ b/op-node/rollup/types.go @@ -125,6 +125,10 @@ func (cfg *Config) ValidateL2Config(ctx context.Context, client L2Client) error return nil } +func (cfg *Config) TimestampForBlock(blockNumber uint64) uint64 { + return cfg.Genesis.L2Time + ((blockNumber - cfg.Genesis.L2.Number) * cfg.BlockTime) +} + func (cfg *Config) TargetBlockNumber(timestamp uint64) (num uint64, err error) { // subtract genesis time from timestamp to get the time elapsed since genesis, and then divide that // difference by the block time to get the expected L2 block number at the current time. If the diff --git a/op-node/rollup/types_test.go b/op-node/rollup/types_test.go index c51903b4ef71f..d4c4e8bc2357a 100644 --- a/op-node/rollup/types_test.go +++ b/op-node/rollup/types_test.go @@ -396,3 +396,54 @@ func TestConfig_Check(t *testing.T) { }) } } + +func TestTimestampForBlock(t *testing.T) { + config := randConfig() + + tests := []struct { + name string + genesisTime uint64 + genesisBlock uint64 + blockTime uint64 + blockNum uint64 + expectedBlockTime uint64 + }{ + { + name: "FirstBlock", + genesisTime: 100, + genesisBlock: 0, + blockTime: 2, + blockNum: 0, + expectedBlockTime: 100, + }, + { + name: "SecondBlock", + genesisTime: 100, + genesisBlock: 0, + blockTime: 2, + blockNum: 1, + expectedBlockTime: 102, + }, + { + name: "NBlock", + genesisTime: 100, + genesisBlock: 0, + blockTime: 2, + blockNum: 25, + expectedBlockTime: 150, + }, + } + + for _, test := range tests { + test := test + t.Run(fmt.Sprintf("TestTimestampForBlock_%s", test.name), func(t *testing.T) { + config.Genesis.L2Time = test.genesisTime + config.Genesis.L2.Number = test.genesisBlock + config.BlockTime = test.blockTime + + timestamp := config.TimestampForBlock(test.blockNum) + assert.Equal(t, timestamp, test.expectedBlockTime) + }) + } + +} diff --git a/op-node/service.go b/op-node/service.go index a243cba253900..64c564cc517b0 100644 --- a/op-node/service.go +++ b/op-node/service.go @@ -104,6 +104,7 @@ func NewConfig(ctx *cli.Context, log log.Logger) (*node.Config, error) { ConfigPersistence: configPersistence, Sync: *syncConfig, RollupHalt: haltOption, + RethDBPath: ctx.String(flags.L1RethDBPath.Name), } if err := cfg.LoadPersisted(log); err != nil { @@ -187,6 +188,9 @@ func NewDriverConfig(ctx *cli.Context) *driver.Config { func NewRollupConfig(log log.Logger, ctx *cli.Context) (*rollup.Config, error) { network := ctx.String(flags.Network.Name) rollupConfigPath := ctx.String(flags.RollupConfig.Name) + if ctx.Bool(flags.BetaExtraNetworks.Name) { + log.Warn("The beta.extra-networks flag is deprecated and can be omitted safely.") + } if network != "" { if rollupConfigPath != "" { log.Error(`Cannot configure network and rollup-config at the same time. @@ -194,10 +198,6 @@ Startup will proceed to use the network-parameter and ignore the rollup config. Conflicting configuration is deprecated, and will stop the op-node from starting in the future. `, "network", network, "rollup_config", rollupConfigPath) } - // check that the network is available - if !chaincfg.IsAvailableNetwork(network, ctx.Bool(flags.BetaExtraNetworks.Name)) { - return nil, fmt.Errorf("unavailable network: %q", network) - } config, err := chaincfg.GetRollupConfig(network) if err != nil { return nil, err diff --git a/op-preimage/filepoller_test.go b/op-preimage/filepoller_test.go index 2a2018fc72511..e42c5de1cbdcc 100644 --- a/op-preimage/filepoller_test.go +++ b/op-preimage/filepoller_test.go @@ -15,9 +15,9 @@ func TestFilePoller_Read(t *testing.T) { chanAPoller := NewFilePoller(ctx, chanA, time.Millisecond*100) go func() { - chanB.Write([]byte("hello")) + _, _ = chanB.Write([]byte("hello")) time.Sleep(time.Second * 1) - chanB.Write([]byte("world")) + _, _ = chanB.Write([]byte("world")) }() var buf [10]byte n, err := chanAPoller.Read(buf[:]) @@ -34,9 +34,9 @@ func TestFilePoller_Write(t *testing.T) { bufch := make(chan []byte, 1) go func() { var buf [10]byte - chanB.Read(buf[:5]) + _, _ = chanB.Read(buf[:5]) time.Sleep(time.Second * 1) - chanB.Read(buf[5:]) + _, _ = chanB.Read(buf[5:]) bufch <- buf[:] close(bufch) }() @@ -59,7 +59,7 @@ func TestFilePoller_ReadCancel(t *testing.T) { chanAPoller := NewFilePoller(ctx, chanA, time.Millisecond*100) go func() { - chanB.Write([]byte("hello")) + _, _ = chanB.Write([]byte("hello")) cancel() }() var buf [10]byte @@ -76,7 +76,7 @@ func TestFilePoller_WriteCancel(t *testing.T) { go func() { var buf [5]byte - chanB.Read(buf[:]) + _, _ = chanB.Read(buf[:]) cancel() }() // use a large buffer to overflow the kernel buffer provided to pipe(2) so the write actually blocks diff --git a/op-program/Dockerfile b/op-program/Dockerfile index b3e57bf287bea..91688b51607d7 100644 --- a/op-program/Dockerfile +++ b/op-program/Dockerfile @@ -1,33 +1,9 @@ -FROM --platform=$BUILDPLATFORM golang:1.21.1-alpine3.18 as builder - -ARG VERSION=v0.0.0 - -RUN apk add --no-cache make gcc musl-dev linux-headers git jq bash - -COPY ./go.mod /app/go.mod -COPY ./go.sum /app/go.sum - -WORKDIR /app - -RUN go mod download - -# build op-program with the shared go.mod & go.sum files -COPY ./op-program /app/op-program -COPY ./op-preimage /app/op-preimage -COPY ./op-node /app/op-node -COPY ./op-chain-ops /app/op-chain-ops -COPY ./op-service /app/op-service -COPY ./op-bindings /app/op-bindings -COPY ./.git /app/.git - -WORKDIR /app/op-program - -ARG TARGETOS TARGETARCH - -RUN make op-program VERSION="$VERSION" GOOS=$TARGETOS GOARCH=$TARGETARCH +ARG OP_STACK_GO_BUILDER=us-docker.pkg.dev/oplabs-tools-artifacts/images/op-stack-go:latest +FROM $OP_STACK_GO_BUILDER as builder +# See "make golang-docker" and /ops/docker/op-stack-go FROM alpine:3.18 -COPY --from=builder /app/op-program/bin/op-program /usr/local/bin +COPY --from=builder /usr/local/bin/op-program /usr/local/bin/op-program CMD ["op-program"] diff --git a/op-program/Dockerfile.dockerignore b/op-program/Dockerfile.dockerignore new file mode 100644 index 0000000000000..4f26140750a08 --- /dev/null +++ b/op-program/Dockerfile.dockerignore @@ -0,0 +1,2 @@ +# ignore everything but the dockerfile, the op-stack-go base image performs the build +* diff --git a/op-program/Makefile b/op-program/Makefile index cf300fc7ab42a..aa4de3f3a16a6 100644 --- a/op-program/Makefile +++ b/op-program/Makefile @@ -1,5 +1,5 @@ -GITCOMMIT := $(shell git rev-parse HEAD) -GITDATE := $(shell git show -s --format='%ct') +GITCOMMIT ?= $(shell git rev-parse HEAD) +GITDATE ?= $(shell git show -s --format='%ct') VERSION := v0.0.0 LDFLAGSSTRING +=-X main.GitCommit=$(GITCOMMIT) @@ -8,6 +8,8 @@ LDFLAGSSTRING +=-X github.com/ethereum-optimism/optimism/op-program/version.Vers LDFLAGSSTRING +=-X github.com/ethereum-optimism/optimism/op-program/version.Meta=$(VERSION_META) LDFLAGS := -ldflags "$(LDFLAGSSTRING)" +COMPAT_DIR := temp/compat + op-program: \ op-program-host \ op-program-client \ @@ -25,16 +27,26 @@ op-program-client-mips: # result is mips32, big endian, R3000 clean: - rm -rf bin + rm -rf bin "$(COMPAT_DIR)" test: go test -v ./... -lint: - golangci-lint run -E goimports,sqlclosecheck,bodyclose,asciicheck,misspell,errorlint --timeout 5m -e "errors.As" -e "errors.Is" ./... - verify-goerli: op-program-host op-program-client - env GO111MODULE=on go run ./verify/cmd/goerli.go $$L1URL $$L2URL + env GO111MODULE=on go run ./verify/cmd/goerli.go --l1 $$L1URL --l2 $$L2URL + +capture-goerli-verify: op-program-host op-program-client + rm -rf "$(COMPAT_DIR)/goerli" "$(COMPAT_DIR)/goerli.tar.bz" + env GO111MODULE=on go run ./verify/cmd/goerli.go --l1 $$L1URL --l2 $$L2URL --datadir "$(COMPAT_DIR)/goerli" + tar jcf "$(COMPAT_DIR)/goerli.tar.bz" -C "$(COMPAT_DIR)" goerli + +capture-chain-test-data: capture-goerli-verify + +run-goerli-verify: op-program-host op-program-client + mkdir -p "$(COMPAT_DIR)" + curl -L -o "$(COMPAT_DIR)/goerli.tar.bz" https://github.com/ethereum-optimism/chain-test-data/releases/download/2023-10-11/goerli.tar.bz + tar jxf "$(COMPAT_DIR)/goerli.tar.bz" -C "$(COMPAT_DIR)" + ./bin/op-program `cat "$(COMPAT_DIR)/goerli/args.txt"` .PHONY: \ op-program \ diff --git a/op-program/client/driver/driver.go b/op-program/client/driver/driver.go index 95a3df751f326..5487d8f19fd57 100644 --- a/op-program/client/driver/driver.go +++ b/op-program/client/driver/driver.go @@ -25,13 +25,13 @@ type Derivation interface { type L2Source interface { derive.Engine - L2OutputRoot() (eth.Bytes32, error) + L2OutputRoot(uint64) (eth.Bytes32, error) } type Driver struct { logger log.Logger pipeline Derivation - l2OutputRoot func() (eth.Bytes32, error) + l2OutputRoot func(uint64) (eth.Bytes32, error) targetBlockNum uint64 } @@ -77,8 +77,8 @@ func (d *Driver) SafeHead() eth.L2BlockRef { return d.pipeline.SafeL2Head() } -func (d *Driver) ValidateClaim(claimedOutputRoot eth.Bytes32) error { - outputRoot, err := d.l2OutputRoot() +func (d *Driver) ValidateClaim(l2ClaimBlockNum uint64, claimedOutputRoot eth.Bytes32) error { + outputRoot, err := d.l2OutputRoot(l2ClaimBlockNum) if err != nil { return fmt.Errorf("calculate L2 output root: %w", err) } diff --git a/op-program/client/driver/driver_test.go b/op-program/client/driver/driver_test.go index cc24c696cf846..3262ab7ed9861 100644 --- a/op-program/client/driver/driver_test.go +++ b/op-program/client/driver/driver_test.go @@ -73,29 +73,29 @@ func TestValidateClaim(t *testing.T) { t.Run("Valid", func(t *testing.T) { driver := createDriver(t, io.EOF) expected := eth.Bytes32{0x11} - driver.l2OutputRoot = func() (eth.Bytes32, error) { + driver.l2OutputRoot = func(_ uint64) (eth.Bytes32, error) { return expected, nil } - err := driver.ValidateClaim(expected) + err := driver.ValidateClaim(uint64(0), expected) require.NoError(t, err) }) t.Run("Invalid", func(t *testing.T) { driver := createDriver(t, io.EOF) - driver.l2OutputRoot = func() (eth.Bytes32, error) { + driver.l2OutputRoot = func(_ uint64) (eth.Bytes32, error) { return eth.Bytes32{0x22}, nil } - err := driver.ValidateClaim(eth.Bytes32{0x11}) + err := driver.ValidateClaim(uint64(0), eth.Bytes32{0x11}) require.ErrorIs(t, err, ErrClaimNotValid) }) t.Run("Error", func(t *testing.T) { driver := createDriver(t, io.EOF) expectedErr := errors.New("boom") - driver.l2OutputRoot = func() (eth.Bytes32, error) { + driver.l2OutputRoot = func(_ uint64) (eth.Bytes32, error) { return eth.Bytes32{}, expectedErr } - err := driver.ValidateClaim(eth.Bytes32{0x11}) + err := driver.ValidateClaim(uint64(0), eth.Bytes32{0x11}) require.ErrorIs(t, err, expectedErr) }) } diff --git a/op-program/client/l2/engine.go b/op-program/client/l2/engine.go index 76523416369dc..2bc808e4a78ad 100644 --- a/op-program/client/l2/engine.go +++ b/op-program/client/l2/engine.go @@ -34,8 +34,11 @@ func NewOracleEngine(rollupCfg *rollup.Config, logger log.Logger, backend engine } } -func (o *OracleEngine) L2OutputRoot() (eth.Bytes32, error) { - outBlock := o.backend.CurrentHeader() +func (o *OracleEngine) L2OutputRoot(l2ClaimBlockNum uint64) (eth.Bytes32, error) { + outBlock := o.backend.GetHeaderByNumber(l2ClaimBlockNum) + if outBlock == nil { + return eth.Bytes32{}, fmt.Errorf("failed to get L2 block at %d", l2ClaimBlockNum) + } stateDB, err := o.backend.StateAt(outBlock.Root) if err != nil { return eth.Bytes32{}, fmt.Errorf("failed to open L2 state db at block %s: %w", outBlock.Hash(), err) @@ -48,15 +51,19 @@ func (o *OracleEngine) L2OutputRoot() (eth.Bytes32, error) { } func (o *OracleEngine) GetPayload(ctx context.Context, payloadId eth.PayloadID) (*eth.ExecutionPayload, error) { - return o.api.GetPayloadV1(ctx, payloadId) + res, err := o.api.GetPayloadV2(ctx, payloadId) + if err != nil { + return nil, err + } + return res.ExecutionPayload, nil } func (o *OracleEngine) ForkchoiceUpdate(ctx context.Context, state *eth.ForkchoiceState, attr *eth.PayloadAttributes) (*eth.ForkchoiceUpdatedResult, error) { - return o.api.ForkchoiceUpdatedV1(ctx, state, attr) + return o.api.ForkchoiceUpdatedV2(ctx, state, attr) } func (o *OracleEngine) NewPayload(ctx context.Context, payload *eth.ExecutionPayload) (*eth.PayloadStatusV1, error) { - return o.api.NewPayloadV1(ctx, payload) + return o.api.NewPayloadV2(ctx, payload) } func (o *OracleEngine) PayloadByHash(ctx context.Context, hash common.Hash) (*eth.ExecutionPayload, error) { @@ -64,7 +71,7 @@ func (o *OracleEngine) PayloadByHash(ctx context.Context, hash common.Hash) (*et if block == nil { return nil, ErrNotFound } - return eth.BlockAsPayload(block) + return eth.BlockAsPayload(block, o.rollupCfg.CanyonTime) } func (o *OracleEngine) PayloadByNumber(ctx context.Context, n uint64) (*eth.ExecutionPayload, error) { @@ -105,6 +112,14 @@ func (o *OracleEngine) L2BlockRefByHash(ctx context.Context, l2Hash common.Hash) return derive.L2BlockToBlockRef(block, &o.rollupCfg.Genesis) } +func (o *OracleEngine) L2BlockRefByNumber(ctx context.Context, n uint64) (eth.L2BlockRef, error) { + hash := o.backend.GetCanonicalHash(n) + if hash == (common.Hash{}) { + return eth.L2BlockRef{}, ErrNotFound + } + return o.L2BlockRefByHash(ctx, hash) +} + func (o *OracleEngine) SystemConfigByL2Hash(ctx context.Context, hash common.Hash) (eth.SystemConfig, error) { payload, err := o.PayloadByHash(ctx, hash) if err != nil { diff --git a/op-program/client/l2/engine_test.go b/op-program/client/l2/engine_test.go index 899f64dd2a427..cfee68e6dac7a 100644 --- a/op-program/client/l2/engine_test.go +++ b/op-program/client/l2/engine_test.go @@ -29,7 +29,7 @@ func TestPayloadByHash(t *testing.T) { block := stub.head payload, err := engine.PayloadByHash(ctx, block.Hash()) require.NoError(t, err) - expected, err := eth.BlockAsPayload(block) + expected, err := eth.BlockAsPayload(block, engine.rollupCfg.CanyonTime) require.NoError(t, err) require.Equal(t, expected, payload) }) @@ -51,7 +51,7 @@ func TestPayloadByNumber(t *testing.T) { block := stub.head payload, err := engine.PayloadByNumber(ctx, block.NumberU64()) require.NoError(t, err) - expected, err := eth.BlockAsPayload(block) + expected, err := eth.BlockAsPayload(block, engine.rollupCfg.CanyonTime) require.NoError(t, err) require.Equal(t, expected, payload) }) @@ -124,7 +124,7 @@ func TestSystemConfigByL2Hash(t *testing.T) { engine, stub := createOracleEngine(t) t.Run("KnownBlock", func(t *testing.T) { - payload, err := eth.BlockAsPayload(stub.safe) + payload, err := eth.BlockAsPayload(stub.safe, engine.rollupCfg.CanyonTime) require.NoError(t, err) expected, err := derive.PayloadToSystemConfig(payload, engine.rollupCfg) require.NoError(t, err) diff --git a/op-program/client/l2/engineapi/block_processor.go b/op-program/client/l2/engineapi/block_processor.go index 22c6e1441401e..c6966e0d94c2f 100644 --- a/op-program/client/l2/engineapi/block_processor.go +++ b/op-program/client/l2/engineapi/block_processor.go @@ -68,7 +68,7 @@ func NewBlockProcessorFromHeader(provider BlockDataProvider, h *types.Header) (* return nil, fmt.Errorf("get parent state: %w", err) } header.Number = new(big.Int).Add(parentHeader.Number, common.Big1) - header.BaseFee = eip1559.CalcBaseFee(provider.Config(), parentHeader) + header.BaseFee = eip1559.CalcBaseFee(provider.Config(), parentHeader, header.Time) header.GasUsed = 0 gasPool := new(core.GasPool).AddGas(header.GasLimit) return &BlockProcessor{ diff --git a/op-program/client/l2/engineapi/l2_engine_api.go b/op-program/client/l2/engineapi/l2_engine_api.go index 31039fea68336..1863e948464fb 100644 --- a/op-program/client/l2/engineapi/l2_engine_api.go +++ b/op-program/client/l2/engineapi/l2_engine_api.go @@ -264,7 +264,7 @@ func (ea *L2EngineAPI) getPayload(ctx context.Context, payloadId eth.PayloadID) ea.log.Error("failed to finish block building", "err", err) return nil, engine.UnknownPayload } - return eth.BlockAsPayload(bl) + return eth.BlockAsPayload(bl, ea.config().CanyonTime) } func (ea *L2EngineAPI) forkchoiceUpdated(ctx context.Context, state *eth.ForkchoiceState, attr *eth.PayloadAttributes) (*eth.ForkchoiceUpdatedResult, error) { @@ -350,6 +350,25 @@ func (ea *L2EngineAPI) forkchoiceUpdated(ctx context.Context, state *eth.Forkcho return valid(nil), nil } +func toGethWithdrawals(payload *eth.ExecutionPayload) []*types.Withdrawal { + if payload.Withdrawals == nil { + return nil + } + + result := make([]*types.Withdrawal, 0, len(*payload.Withdrawals)) + + for _, w := range *payload.Withdrawals { + result = append(result, &types.Withdrawal{ + Index: w.Index, + Validator: w.Validator, + Address: w.Address, + Amount: w.Amount, + }) + } + + return result +} + func (ea *L2EngineAPI) newPayload(ctx context.Context, payload *eth.ExecutionPayload) (*eth.PayloadStatusV1, error) { ea.log.Trace("L2Engine API request received", "method", "ExecutePayload", "number", payload.BlockNumber, "hash", payload.BlockHash) txs := make([][]byte, len(payload.Transactions)) @@ -371,6 +390,7 @@ func (ea *L2EngineAPI) newPayload(ctx context.Context, payload *eth.ExecutionPay BaseFeePerGas: payload.BaseFeePerGas.ToBig(), BlockHash: payload.BlockHash, Transactions: txs, + Withdrawals: toGethWithdrawals(payload), }, nil, nil) if err != nil { log.Debug("Invalid NewPayload params", "params", payload, "error", err) diff --git a/op-program/client/l2/engineapi/test/l2_engine_api_tests.go b/op-program/client/l2/engineapi/test/l2_engine_api_tests.go index e0ed96e273dca..2bdc784886e47 100644 --- a/op-program/client/l2/engineapi/test/l2_engine_api_tests.go +++ b/op-program/client/l2/engineapi/test/l2_engine_api_tests.go @@ -55,17 +55,25 @@ func RunEngineAPITests(t *testing.T, createBackend func(t *testing.T) engineapi. txRlp, err := tx.MarshalBinary() api.assert.NoError(err) - result, err := api.engine.ForkchoiceUpdatedV1(api.ctx, ð.ForkchoiceState{ + nextBlockTime := eth.Uint64Quantity(genesis.Time + 1) + + var w *types.Withdrawals + if api.backend.Config().IsCanyon(uint64(nextBlockTime)) { + w = &types.Withdrawals{} + } + + result, err := api.engine.ForkchoiceUpdatedV2(api.ctx, ð.ForkchoiceState{ HeadBlockHash: genesis.Hash(), SafeBlockHash: genesis.Hash(), FinalizedBlockHash: genesis.Hash(), }, ð.PayloadAttributes{ - Timestamp: eth.Uint64Quantity(genesis.Time + 1), + Timestamp: nextBlockTime, PrevRandao: eth.Bytes32(genesis.MixDigest), SuggestedFeeRecipient: feeRecipient, Transactions: []eth.Data{txRlp}, NoTxPool: true, GasLimit: &gasLimit, + Withdrawals: w, }) api.assert.Error(err) api.assert.Equal(eth.ExecutionInvalid, result.PayloadStatus.Status) @@ -103,9 +111,16 @@ func RunEngineAPITests(t *testing.T, createBackend func(t *testing.T) engineapi. t.Run("RejectInvalidBlockHash", func(t *testing.T) { api := newTestHelper(t, createBackend) + var w *types.Withdrawals + if api.backend.Config().IsCanyon(uint64(0)) { + w = &types.Withdrawals{} + } + // Invalid because BlockHash won't be correct (among many other reasons) - block := ð.ExecutionPayload{} - r, err := api.engine.NewPayloadV1(api.ctx, block) + block := ð.ExecutionPayload{ + Withdrawals: w, + } + r, err := api.engine.NewPayloadV2(api.ctx, block) api.assert.NoError(err) api.assert.Equal(eth.ExecutionInvalidBlockHash, r.Status) }) @@ -122,7 +137,7 @@ func RunEngineAPITests(t *testing.T, createBackend func(t *testing.T) engineapi. newBlock.StateRoot = eth.Bytes32(genesis.TxHash) updateBlockHash(newBlock) - r, err := api.engine.NewPayloadV1(api.ctx, newBlock) + r, err := api.engine.NewPayloadV2(api.ctx, newBlock) api.assert.NoError(err) api.assert.Equal(eth.ExecutionInvalid, r.Status) }) @@ -139,7 +154,7 @@ func RunEngineAPITests(t *testing.T, createBackend func(t *testing.T) engineapi. newBlock.Timestamp = eth.Uint64Quantity(genesis.Time) updateBlockHash(newBlock) - r, err := api.engine.NewPayloadV1(api.ctx, newBlock) + r, err := api.engine.NewPayloadV2(api.ctx, newBlock) api.assert.NoError(err) api.assert.Equal(eth.ExecutionInvalid, r.Status) }) @@ -156,7 +171,7 @@ func RunEngineAPITests(t *testing.T, createBackend func(t *testing.T) engineapi. newBlock.Timestamp = eth.Uint64Quantity(genesis.Time - 1) updateBlockHash(newBlock) - r, err := api.engine.NewPayloadV1(api.ctx, newBlock) + r, err := api.engine.NewPayloadV2(api.ctx, newBlock) api.assert.NoError(err) api.assert.Equal(eth.ExecutionInvalid, r.Status) }) @@ -165,7 +180,7 @@ func RunEngineAPITests(t *testing.T, createBackend func(t *testing.T) engineapi. api := newTestHelper(t, createBackend) genesis := api.backend.CurrentHeader() - result, err := api.engine.ForkchoiceUpdatedV1(api.ctx, ð.ForkchoiceState{ + result, err := api.engine.ForkchoiceUpdatedV2(api.ctx, ð.ForkchoiceState{ HeadBlockHash: genesis.Hash(), SafeBlockHash: genesis.Hash(), FinalizedBlockHash: genesis.Hash(), @@ -185,7 +200,7 @@ func RunEngineAPITests(t *testing.T, createBackend func(t *testing.T) engineapi. api := newTestHelper(t, createBackend) genesis := api.backend.CurrentHeader() - result, err := api.engine.ForkchoiceUpdatedV1(api.ctx, ð.ForkchoiceState{ + result, err := api.engine.ForkchoiceUpdatedV2(api.ctx, ð.ForkchoiceState{ HeadBlockHash: genesis.Hash(), SafeBlockHash: genesis.Hash(), FinalizedBlockHash: genesis.Hash(), @@ -207,7 +222,7 @@ func RunEngineAPITests(t *testing.T, createBackend func(t *testing.T) engineapi. gasLimit := eth.Uint64Quantity(params.MaxGasLimit + 1) - result, err := api.engine.ForkchoiceUpdatedV1(api.ctx, ð.ForkchoiceState{ + result, err := api.engine.ForkchoiceUpdatedV2(api.ctx, ð.ForkchoiceState{ HeadBlockHash: genesis.Hash(), SafeBlockHash: genesis.Hash(), FinalizedBlockHash: genesis.Hash(), @@ -246,7 +261,7 @@ func RunEngineAPITests(t *testing.T, createBackend func(t *testing.T) engineapi. chainB1 := api.addBlockWithParent(genesis, eth.Uint64Quantity(genesis.Time+3)) - result, err := api.engine.ForkchoiceUpdatedV1(api.ctx, ð.ForkchoiceState{ + result, err := api.engine.ForkchoiceUpdatedV2(api.ctx, ð.ForkchoiceState{ HeadBlockHash: chainA3.BlockHash, SafeBlockHash: chainB1.BlockHash, FinalizedBlockHash: chainA2.BlockHash, @@ -266,7 +281,7 @@ func RunEngineAPITests(t *testing.T, createBackend func(t *testing.T) engineapi. chainB1 := api.addBlockWithParent(genesis, eth.Uint64Quantity(genesis.Time+3)) - result, err := api.engine.ForkchoiceUpdatedV1(api.ctx, ð.ForkchoiceState{ + result, err := api.engine.ForkchoiceUpdatedV2(api.ctx, ð.ForkchoiceState{ HeadBlockHash: chainA3.BlockHash, SafeBlockHash: chainA2.BlockHash, FinalizedBlockHash: chainB1.BlockHash, @@ -349,7 +364,7 @@ func (h *testHelper) addBlockWithParent(head *types.Header, timestamp eth.Uint64 func (h *testHelper) forkChoiceUpdated(head common.Hash, safe common.Hash, finalized common.Hash) { h.Log("forkChoiceUpdated", "head", head, "safe", safe, "finalized", finalized) - result, err := h.engine.ForkchoiceUpdatedV1(h.ctx, ð.ForkchoiceState{ + result, err := h.engine.ForkchoiceUpdatedV2(h.ctx, ð.ForkchoiceState{ HeadBlockHash: head, SafeBlockHash: safe, FinalizedBlockHash: finalized, @@ -368,7 +383,14 @@ func (h *testHelper) startBlockBuilding(head *types.Header, newBlockTimestamp et h.assert.NoError(err, "Failed to marshall tx %v", tx) txData = append(txData, rlp) } - result, err := h.engine.ForkchoiceUpdatedV1(h.ctx, ð.ForkchoiceState{ + + canyonTime := h.backend.Config().CanyonTime + var w *types.Withdrawals + if canyonTime != nil && *canyonTime <= uint64(newBlockTimestamp) { + w = &types.Withdrawals{} + } + + result, err := h.engine.ForkchoiceUpdatedV2(h.ctx, ð.ForkchoiceState{ HeadBlockHash: head.Hash(), SafeBlockHash: head.Hash(), FinalizedBlockHash: head.Hash(), @@ -379,6 +401,7 @@ func (h *testHelper) startBlockBuilding(head *types.Header, newBlockTimestamp et Transactions: txData, NoTxPool: true, GasLimit: &gasLimit, + Withdrawals: w, }) h.assert.NoError(err) h.assert.Equal(eth.ExecutionValid, result.PayloadStatus.Status) @@ -389,15 +412,16 @@ func (h *testHelper) startBlockBuilding(head *types.Header, newBlockTimestamp et func (h *testHelper) getPayload(id *eth.PayloadID) *eth.ExecutionPayload { h.Log("getPayload", "id", id) - block, err := h.engine.GetPayloadV1(h.ctx, *id) + envelope, err := h.engine.GetPayloadV2(h.ctx, *id) h.assert.NoError(err) - h.assert.NotNil(block) - return block + h.assert.NotNil(envelope) + h.assert.NotNil(envelope.ExecutionPayload) + return envelope.ExecutionPayload } func (h *testHelper) newPayload(block *eth.ExecutionPayload) { h.Log("newPayload", "hash", block.BlockHash) - r, err := h.engine.NewPayloadV1(h.ctx, block) + r, err := h.engine.NewPayloadV2(h.ctx, block) h.assert.NoError(err) h.assert.Equal(eth.ExecutionValid, r.Status) h.assert.Nil(r.ValidationError) diff --git a/op-program/client/mpt/trie.go b/op-program/client/mpt/trie.go index 814b2df47b38a..7f957cd630c2f 100644 --- a/op-program/client/mpt/trie.go +++ b/op-program/client/mpt/trie.go @@ -116,7 +116,7 @@ func (n noResetHasher) Reset() {} func WriteTrie(values []hexutil.Bytes) (common.Hash, []hexutil.Bytes) { var out []hexutil.Bytes st := noResetHasher{trie.NewStackTrie( - func(owner common.Hash, path []byte, hash common.Hash, blob []byte) { + func(path []byte, hash common.Hash, blob []byte) { out = append(out, common.CopyBytes(blob)) // the stack hasher may mutate the blob bytes, so copy them. })} root := types.DeriveSha(rawList(values), st) diff --git a/op-program/client/program.go b/op-program/client/program.go index 7d037a7b6ebef..b43950bfb871e 100644 --- a/op-program/client/program.go +++ b/op-program/client/program.go @@ -79,7 +79,7 @@ func runDerivation(logger log.Logger, cfg *rollup.Config, l2Cfg *params.ChainCon return err } } - return d.ValidateClaim(eth.Bytes32(l2Claim)) + return d.ValidateClaim(l2ClaimBlockNum, eth.Bytes32(l2Claim)) } func CreateHinterChannel() oppio.FileChannel { diff --git a/op-program/host/cmd/main.go b/op-program/host/cmd/main.go index cf4022c09e749..19d0f188730b8 100644 --- a/op-program/host/cmd/main.go +++ b/op-program/host/cmd/main.go @@ -7,6 +7,7 @@ import ( "github.com/ethereum-optimism/optimism/op-program/host/config" "github.com/ethereum-optimism/optimism/op-program/host/flags" "github.com/ethereum-optimism/optimism/op-program/host/version" + opservice "github.com/ethereum-optimism/optimism/op-service" oplog "github.com/ethereum-optimism/optimism/op-service/log" "github.com/ethereum/go-ethereum/log" "github.com/urfave/cli/v2" @@ -18,19 +19,7 @@ var ( ) // VersionWithMeta holds the textual version string including the metadata. -var VersionWithMeta = func() string { - v := version.Version - if GitCommit != "" { - v += "-" + GitCommit[:8] - } - if GitDate != "" { - v += "-" + GitDate - } - if version.Meta != "" { - v += "-" + version.Meta - } - return v -}() +var VersionWithMeta = opservice.FormatVersion(version.Version, GitCommit, GitDate, version.Meta) func main() { args := os.Args diff --git a/op-program/host/cmd/main_test.go b/op-program/host/cmd/main_test.go index e852ed53c6e9d..081136af117be 100644 --- a/op-program/host/cmd/main_test.go +++ b/op-program/host/cmd/main_test.go @@ -75,7 +75,7 @@ func TestDefaultCLIOptionsMatchDefaultConfig(t *testing.T) { func TestNetwork(t *testing.T) { t.Run("Unknown", func(t *testing.T) { - verifyArgsInvalid(t, "unavailable network: \"bar\"", replaceRequiredArg("--network", "bar")) + verifyArgsInvalid(t, "invalid network: \"bar\"", replaceRequiredArg("--network", "bar")) }) t.Run("Required", func(t *testing.T) { @@ -210,7 +210,7 @@ func TestL1TrustRPC(t *testing.T) { func TestL1RPCKind(t *testing.T) { t.Run("DefaultBasic", func(t *testing.T) { cfg := configForArgs(t, addRequiredArgs()) - require.Equal(t, sources.RPCKindBasic, cfg.L1RPCKind) + require.Equal(t, sources.RPCKindStandard, cfg.L1RPCKind) }) for _, kind := range sources.RPCProviderKinds { t.Run(kind.String(), func(t *testing.T) { diff --git a/op-program/host/config/config.go b/op-program/host/config/config.go index c6f0f02fc6f3a..84d7c2e329082 100644 --- a/op-program/host/config/config.go +++ b/op-program/host/config/config.go @@ -130,7 +130,7 @@ func NewConfig( L2OutputRoot: l2OutputRoot, L2Claim: l2Claim, L2ClaimBlockNumber: l2ClaimBlockNum, - L1RPCKind: sources.RPCKindBasic, + L1RPCKind: sources.RPCKindStandard, IsCustomChainConfig: isCustomConfig, } } diff --git a/op-program/host/flags/flags.go b/op-program/host/flags/flags.go index 3d767db70d584..a4340be84cffc 100644 --- a/op-program/host/flags/flags.go +++ b/op-program/host/flags/flags.go @@ -86,7 +86,7 @@ var ( openum.EnumString(sources.RPCProviderKinds), EnvVars: prefixEnvVars("L1_RPC_KIND"), Value: func() *sources.RPCProviderKind { - out := sources.RPCKindBasic + out := sources.RPCKindStandard return &out }(), } diff --git a/op-program/verify/cmd/goerli.go b/op-program/verify/cmd/goerli.go index 84b1b7b652330..88e1fbf0b0a4c 100644 --- a/op-program/verify/cmd/goerli.go +++ b/op-program/verify/cmd/goerli.go @@ -2,10 +2,13 @@ package main import ( "context" + "flag" "fmt" "math/big" "os" "os/exec" + "path/filepath" + "strings" "time" "github.com/ethereum-optimism/optimism/op-bindings/bindings" @@ -15,28 +18,32 @@ import ( "github.com/ethereum/go-ethereum/rpc" ) -const agreedBlockTrailingDistance = 100 - func main() { - if len(os.Args) < 3 { - _, _ = fmt.Fprintln(os.Stderr, "Must specify L1 RPC URL and L2 RPC URL as arguments") + var l1RpcUrl string + var l1RpcKind string + var l2RpcUrl string + var dataDir string + flag.StringVar(&l1RpcUrl, "l1", "", "L1 RPC URL to use") + flag.StringVar(&l1RpcKind, "l1-rpckind", "alchemy", "L1 RPC kind") + flag.StringVar(&l2RpcUrl, "l2", "", "L2 RPC URL to use") + flag.StringVar(&dataDir, "datadir", "", + "Directory to use for storing pre-images. If not set a temporary directory will be used.") + flag.Parse() + + if l1RpcUrl == "" || l2RpcUrl == "" { + _, _ = fmt.Fprintln(os.Stderr, "Must specify --l1 and --l2 RPC URLs") os.Exit(2) } - l1RpcUrl := os.Args[1] - l2RpcUrl := os.Args[2] - l1RpcKind := "alchemy" - if len(os.Args) > 3 { - l1RpcKind = os.Args[3] - } + goerliOutputAddress := common.HexToAddress("0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0") - err := Run(l1RpcUrl, l1RpcKind, l2RpcUrl, goerliOutputAddress) + err := Run(l1RpcUrl, l1RpcKind, l2RpcUrl, goerliOutputAddress, dataDir) if err != nil { _, _ = fmt.Fprintf(os.Stderr, "Failed: %v\n", err.Error()) os.Exit(1) } } -func Run(l1RpcUrl string, l1RpcKind string, l2RpcUrl string, l2OracleAddr common.Address) error { +func Run(l1RpcUrl string, l1RpcKind string, l2RpcUrl string, l2OracleAddr common.Address, dataDir string) error { ctx := context.Background() l1RpcClient, err := rpc.Dial(l1RpcUrl) if err != nil { @@ -55,14 +62,7 @@ func Run(l1RpcUrl string, l1RpcKind string, l2RpcUrl string, l2OracleAddr common return fmt.Errorf("create output oracle bindings: %w", err) } - // Find L2 finalized head. This is far enough back that we know it's submitted to L1 and won't be re-orged - l2FinalizedHead, err := l2Client.BlockByNumber(ctx, big.NewInt(int64(rpc.FinalizedBlockNumber))) - if err != nil { - return fmt.Errorf("get l2 safe head: %w", err) - } - fmt.Printf("Found L2 finalized head number: %v hash: %v\n", l2FinalizedHead.NumberU64(), l2FinalizedHead.Hash()) - - // Find L1 finalized block. Can't be re-orged and must contain all batches for the L2 finalized block + // Find L1 finalized block. Can't be re-orged. l1BlockNum := big.NewInt(int64(rpc.FinalizedBlockNumber)) l1HeadBlock, err := l1Client.BlockByNumber(ctx, l1BlockNum) if err != nil { @@ -70,89 +70,68 @@ func Run(l1RpcUrl string, l1RpcKind string, l2RpcUrl string, l2OracleAddr common } fmt.Printf("Found l1 head block number: %v hash: %v\n", l1HeadBlock.NumberU64(), l1HeadBlock.Hash()) - // Get the most published L2 output from before the finalized block - callOpts := &bind.CallOpts{Context: ctx} - outputIndex, err := outputOracle.GetL2OutputIndexAfter(callOpts, l2FinalizedHead.Number()) + l1CallOpts := &bind.CallOpts{Context: ctx, BlockNumber: l1BlockNum} + + // Find the latest output root published in this finalized block + latestOutputIndex, err := outputOracle.LatestOutputIndex(l1CallOpts) if err != nil { - fmt.Println("Failed to get output index after finalized block. Checking latest output", "finalized", l2FinalizedHead.Number(), "err", err) - outputIndex, err = outputOracle.LatestOutputIndex(callOpts) - if err != nil { - return fmt.Errorf("get latest output index: %w", err) - } - } else { - outputIndex = outputIndex.Sub(outputIndex, big.NewInt(1)) + return fmt.Errorf("fetch latest output index: %w", err) } - output, err := outputOracle.GetL2Output(callOpts, outputIndex) + output, err := outputOracle.GetL2Output(l1CallOpts, latestOutputIndex) if err != nil { - return fmt.Errorf("retrieve latest output: %w", err) - } - // Check we wound up with an output prior to the finalized block - if output.L2BlockNumber.Uint64() > l2FinalizedHead.NumberU64() { - return fmt.Errorf("selected output is after finalized head output block: %v, finalized block: %v", output.L2BlockNumber.Uint64(), l2FinalizedHead.NumberU64()) + return fmt.Errorf("fetch l2 output %v: %w", latestOutputIndex, err) } - l1Head := l1HeadBlock.Hash() - l2Claim := common.Hash(output.OutputRoot) - l2BlockNumber := output.L2BlockNumber - - // Use an agreed starting L2 block some distance before the block the output claim is from - agreedBlockNumber := uint64(0) - if l2BlockNumber.Uint64() > agreedBlockTrailingDistance { - agreedBlockNumber = l2BlockNumber.Uint64() - agreedBlockTrailingDistance - } - l2AgreedBlock, err := l2Client.BlockByNumber(ctx, big.NewInt(int64(agreedBlockNumber))) + // Use the previous output as the agreed starting point + agreedOutput, err := outputOracle.GetL2Output(l1CallOpts, new(big.Int).Sub(latestOutputIndex, common.Big1)) if err != nil { - return fmt.Errorf("retrieve agreed l2 block: %w", err) - } - agreedOutputIndex, err := outputOracle.GetL2OutputIndexAfter(callOpts, l2AgreedBlock.Number()) - if err != nil { - return fmt.Errorf("failed to output index after agreed block") - } - // Find an output that differs from what is being claimed - var agreedOutput bindings.TypesOutputProposal - for { - agreedOutput, err = outputOracle.GetL2Output(callOpts, agreedOutputIndex) - if err != nil { - return fmt.Errorf("retrieve agreed output: %w", err) - } - if agreedOutput.OutputRoot != output.OutputRoot { - break - } - fmt.Printf("Output at %v equals output at finalized block. Continuing search...\n", agreedOutput.L2BlockNumber) - agreedOutputIndex.Sub(agreedOutputIndex, big.NewInt(1)) - if agreedOutputIndex.Int64() < 0 { - return fmt.Errorf("failed to find an output different from finalized block output") - } + return fmt.Errorf("fetch l2 output before %v: %w", latestOutputIndex, err) } l2BlockAtOutput, err := l2Client.BlockByNumber(ctx, agreedOutput.L2BlockNumber) if err != nil { return fmt.Errorf("retrieve agreed block: %w", err) } + l2Head := l2BlockAtOutput.Hash() + l2BlockNumber := output.L2BlockNumber + l2Claim := common.Hash(output.OutputRoot) + l1Head := l1HeadBlock.Hash() - temp, err := os.MkdirTemp("", "oracledata") - if err != nil { - return fmt.Errorf("create temp dir: %w", err) - } - defer func() { - err := os.RemoveAll(temp) + if dataDir == "" { + dataDir, err = os.MkdirTemp("", "oracledata") if err != nil { - fmt.Println("Failed to remove temp dir:" + err.Error()) + return fmt.Errorf("create temp dir: %w", err) + } + defer func() { + err := os.RemoveAll(dataDir) + if err != nil { + fmt.Println("Failed to remove temp dir:" + err.Error()) + } + }() + } else { + if err := os.MkdirAll(dataDir, 0755); err != nil { + fmt.Printf("Could not create data directory %v: %v", dataDir, err) + os.Exit(1) } - }() - fmt.Printf("Using temp dir: %s\n", temp) + } + fmt.Printf("Using dir: %s\n", dataDir) args := []string{ "--log.level", "DEBUG", "--network", "goerli", "--exec", "./bin/op-program-client", - "--datadir", temp, + "--datadir", dataDir, "--l1.head", l1Head.Hex(), "--l2.head", l2Head.Hex(), "--l2.outputroot", common.Bytes2Hex(agreedOutput.OutputRoot[:]), "--l2.claim", l2Claim.Hex(), "--l2.blocknumber", l2BlockNumber.String(), } - fmt.Printf("Configuration: %s\n", args) + argsStr := strings.Join(args, " ") + if err := os.WriteFile(filepath.Join(dataDir, "args.txt"), []byte(argsStr), 0644); err != nil { + fmt.Printf("Could not write args: %v", err) + os.Exit(1) + } + fmt.Printf("Configuration: %s\n", argsStr) fmt.Println("Running in online mode") err = runFaultProofProgram(ctx, append(args, "--l1", l1RpcUrl, "--l2", l2RpcUrl, "--l1.rpckind", l1RpcKind)) if err != nil { diff --git a/op-proposer/Dockerfile b/op-proposer/Dockerfile index ae335221733da..8eb4b7cc0ebb0 100644 --- a/op-proposer/Dockerfile +++ b/op-proposer/Dockerfile @@ -1,31 +1,9 @@ -FROM --platform=$BUILDPLATFORM golang:1.21.1-alpine3.18 as builder - -ARG VERSION=v0.0.0 - -RUN apk add --no-cache make gcc musl-dev linux-headers git jq bash - -COPY ./go.mod /app/go.mod -COPY ./go.sum /app/go.sum - -WORKDIR /app - -RUN go mod download - -# build op-proposer with the shared go.mod & go.sum files -COPY ./op-proposer /app/op-proposer -COPY ./op-bindings /app/op-bindings -COPY ./op-node /app/op-node -COPY ./op-service /app/op-service -COPY ./.git /app/.git - -WORKDIR /app/op-proposer - -ARG TARGETOS TARGETARCH - -RUN make op-proposer VERSION="$VERSION" GOOS=$TARGETOS GOARCH=$TARGETARCH +ARG OP_STACK_GO_BUILDER=us-docker.pkg.dev/oplabs-tools-artifacts/images/op-stack-go:latest +FROM $OP_STACK_GO_BUILDER as builder +# See "make golang-docker" and /ops/docker/op-stack-go FROM alpine:3.18 -COPY --from=builder /app/op-proposer/bin/op-proposer /usr/local/bin +COPY --from=builder /usr/local/bin/op-proposer /usr/local/bin/op-proposer CMD ["op-proposer"] diff --git a/op-proposer/Dockerfile.dockerignore b/op-proposer/Dockerfile.dockerignore new file mode 100644 index 0000000000000..4f26140750a08 --- /dev/null +++ b/op-proposer/Dockerfile.dockerignore @@ -0,0 +1,2 @@ +# ignore everything but the dockerfile, the op-stack-go base image performs the build +* diff --git a/op-proposer/Makefile b/op-proposer/Makefile index 5b78e22d003fd..1b2db9f305152 100644 --- a/op-proposer/Makefile +++ b/op-proposer/Makefile @@ -1,5 +1,5 @@ -GITCOMMIT := $(shell git rev-parse HEAD) -GITDATE := $(shell git show -s --format='%ct') +GITCOMMIT ?= $(shell git rev-parse HEAD) +GITDATE ?= $(shell git show -s --format='%ct') VERSION := v0.0.0 LDFLAGSSTRING +=-X main.GitCommit=$(GITCOMMIT) @@ -16,9 +16,6 @@ clean: test: go test -v ./... -lint: - golangci-lint run -E goimports,sqlclosecheck,bodyclose,asciicheck,misspell,errorlint --timeout 5m -e "errors.As" -e "errors.Is" ./... - .PHONY: \ clean \ op-proposer \ diff --git a/op-proposer/cmd/main.go b/op-proposer/cmd/main.go index 2bd822d5038b4..10d6ad5e8d3ae 100644 --- a/op-proposer/cmd/main.go +++ b/op-proposer/cmd/main.go @@ -1,9 +1,9 @@ package main import ( - "fmt" "os" + opservice "github.com/ethereum-optimism/optimism/op-service" "github.com/urfave/cli/v2" "github.com/ethereum-optimism/optimism/op-proposer/flags" @@ -26,7 +26,7 @@ func main() { app := cli.NewApp() app.Flags = cliapp.ProtectFlags(flags.Flags) - app.Version = fmt.Sprintf("%s-%s-%s", Version, GitCommit, GitDate) + app.Version = opservice.FormatVersion(Version, GitCommit, GitDate, "") app.Name = "op-proposer" app.Usage = "L2Output Submitter" app.Description = "Service for generating and submitting L2 Output checkpoints to the L2OutputOracle contract" diff --git a/op-proposer/metrics/metrics.go b/op-proposer/metrics/metrics.go index bbb326ca4fe56..110e47ef34dab 100644 --- a/op-proposer/metrics/metrics.go +++ b/op-proposer/metrics/metrics.go @@ -84,7 +84,12 @@ func (m *Metrics) Start(host string, port int) (*httputil.HTTPServer, error) { func (m *Metrics) StartBalanceMetrics(ctx context.Context, l log.Logger, client *ethclient.Client, account common.Address) { - opmetrics.LaunchBalanceMetrics(ctx, l, m.registry, m.ns, client, account) + // TODO(7684): util was refactored to close, but ctx is still being used by caller for shutdown + balanceMetric := opmetrics.LaunchBalanceMetrics(l, m.registry, m.ns, client, account) + go func() { + <-ctx.Done() + _ = balanceMetric.Close() + }() } // RecordInfo sets a pseudo-metric that contains versioning and diff --git a/op-proposer/proposer/l2_output_submitter.go b/op-proposer/proposer/l2_output_submitter.go index b704c083d8ed8..255d3e9306e15 100644 --- a/op-proposer/proposer/l2_output_submitter.go +++ b/op-proposer/proposer/l2_output_submitter.go @@ -172,12 +172,12 @@ func NewL2OutputSubmitterConfigFromCLIConfig(cfg CLIConfig, l log.Logger, m metr } // Connect to L1 and L2 providers. Perform these last since they are the most expensive. - l1Client, err := dial.DialEthClientWithTimeout(dial.DefaultDialTimeout, l, cfg.L1EthRpc) + l1Client, err := dial.DialEthClientWithTimeout(context.Background(), dial.DefaultDialTimeout, l, cfg.L1EthRpc) if err != nil { return nil, err } - rollupClient, err := dial.DialRollupClientWithTimeout(dial.DefaultDialTimeout, l, cfg.RollupRpc) + rollupClient, err := dial.DialRollupClientWithTimeout(context.Background(), dial.DefaultDialTimeout, l, cfg.RollupRpc) if err != nil { return nil, err } diff --git a/op-service/Makefile b/op-service/Makefile index 7d3645466d1f2..a83804af8bbcf 100644 --- a/op-service/Makefile +++ b/op-service/Makefile @@ -1,9 +1,6 @@ test: go test -v ./... -lint: - golangci-lint run -E goimports,sqlclosecheck,bodyclose,asciicheck,misspell,errorlint --timeout 5m -e "errors.As" -e "errors.Is" ./... - generate-mocks: go generate ./... @@ -15,5 +12,6 @@ generate-mocks: fuzz: go test -run NOTAREALTEST -v -fuzztime 10s -fuzz FuzzExecutionPayloadUnmarshal ./eth - go test -run NOTAREALTEST -v -fuzztime 10s -fuzz FuzzExecutionPayloadMarshalUnmarshal ./eth + go test -run NOTAREALTEST -v -fuzztime 10s -fuzz FuzzExecutionPayloadMarshalUnmarshalV1 ./eth + go test -run NOTAREALTEST -v -fuzztime 10s -fuzz FuzzExecutionPayloadMarshalUnmarshalV2 ./eth go test -run NOTAREALTEST -v -fuzztime 10s -fuzz FuzzOBP01 ./eth diff --git a/op-service/cliapp/lifecycle.go b/op-service/cliapp/lifecycle.go index 3afce92898dca..2154c025645d3 100644 --- a/op-service/cliapp/lifecycle.go +++ b/op-service/cliapp/lifecycle.go @@ -4,7 +4,6 @@ import ( "context" "errors" "fmt" - "os" "github.com/urfave/cli/v2" @@ -30,21 +29,22 @@ type Lifecycle interface { // a shutdown when the Stop context is not expired. type LifecycleAction func(ctx *cli.Context, close context.CancelCauseFunc) (Lifecycle, error) +var interruptErr = errors.New("interrupt signal") + // LifecycleCmd turns a LifecycleAction into an CLI action, // by instrumenting it with CLI context and signal based termination. +// The signals are caught with the opio.BlockFn attached to the context, if any. +// If no block function is provided, it adds default interrupt handling. // The app may continue to run post-processing until fully shutting down. // The user can force an early shut-down during post-processing by sending a second interruption signal. func LifecycleCmd(fn LifecycleAction) cli.ActionFunc { - return lifecycleCmd(fn, opio.BlockOnInterruptsContext) -} - -type waitSignalFn func(ctx context.Context, signals ...os.Signal) - -var interruptErr = errors.New("interrupt signal") - -func lifecycleCmd(fn LifecycleAction, blockOnInterrupt waitSignalFn) cli.ActionFunc { return func(ctx *cli.Context) error { hostCtx := ctx.Context + blockOnInterrupt := opio.BlockerFromContext(hostCtx) + if blockOnInterrupt == nil { // add default interrupt blocker to context if none is set. + hostCtx = opio.WithInterruptBlocker(hostCtx) + blockOnInterrupt = opio.BlockerFromContext(hostCtx) + } appCtx, appCancel := context.WithCancelCause(hostCtx) ctx.Context = appCtx diff --git a/op-service/cliapp/lifecycle_test.go b/op-service/cliapp/lifecycle_test.go index 8cb65ee00d408..1a4002729bb51 100644 --- a/op-service/cliapp/lifecycle_test.go +++ b/op-service/cliapp/lifecycle_test.go @@ -3,12 +3,13 @@ package cliapp import ( "context" "errors" - "os" "testing" "time" "github.com/stretchr/testify/require" "github.com/urfave/cli/v2" + + "github.com/ethereum-optimism/optimism/op-service/opio" ) type fakeLifecycle struct { @@ -77,19 +78,19 @@ func TestLifecycleCmd(t *testing.T) { return app, nil } - // puppeteer a system signal waiter with a test signal channel - fakeSignalWaiter := func(ctx context.Context, signals ...os.Signal) { - select { - case <-ctx.Done(): - case <-signalCh: - } - } - // turn our mock app and system signal into a lifecycle-managed command - actionFn := lifecycleCmd(mockAppFn, fakeSignalWaiter) + actionFn := LifecycleCmd(mockAppFn) // try to shut the test down after being locked more than a minute ctx, cancel := context.WithTimeout(context.Background(), time.Minute) + + // puppeteer system signal interrupts by hooking up the test signal channel as "blocker" for the app to use. + ctx = opio.WithBlocker(ctx, func(ctx context.Context) { + select { + case <-ctx.Done(): + case <-signalCh: + } + }) t.Cleanup(cancel) // create a fake CLI context to run our command with diff --git a/op-service/clock/loop.go b/op-service/clock/loop.go new file mode 100644 index 0000000000000..d5a9aa8a49480 --- /dev/null +++ b/op-service/clock/loop.go @@ -0,0 +1,64 @@ +package clock + +import ( + "context" + "sync" + "time" +) + +// LoopFn is a simple ticker-loop with io.Closer support. +// Note that ticks adapt; slow function calls may result in lost ticks. +type LoopFn struct { + ctx context.Context + cancel context.CancelFunc + + ticker Ticker + fn func(ctx context.Context) + onClose func() error + + wg sync.WaitGroup +} + +// Close cancels the context of the ongoing function call, waits for the call to complete, and cancels further calls. +// Close is safe to call again or concurrently. The onClose callback will be called for each Close call. +func (lf *LoopFn) Close() error { + lf.cancel() // stop any ongoing function call, and close the main loop + lf.wg.Wait() // wait for completion + if lf.onClose != nil { + return lf.onClose() // optional: user can specify function to close resources with + } + return nil +} + +func (lf *LoopFn) work() { + defer lf.wg.Done() + defer lf.ticker.Stop() // clean up the timer + for { + select { + case <-lf.ctx.Done(): + return + case <-lf.ticker.Ch(): + ctx, cancel := context.WithCancel(lf.ctx) + func() { + defer cancel() + lf.fn(ctx) + }() + } + } +} + +// NewLoopFn creates a periodic function call, which can be closed, +// with an optional onClose callback to clean up resources. +func NewLoopFn(clock Clock, fn func(ctx context.Context), onClose func() error, interval time.Duration) *LoopFn { + ctx, cancel := context.WithCancel(context.Background()) + lf := &LoopFn{ + ctx: ctx, + cancel: cancel, + fn: fn, + ticker: clock.NewTicker(interval), + onClose: onClose, + } + lf.wg.Add(1) + go lf.work() + return lf +} diff --git a/op-service/clock/loop_test.go b/op-service/clock/loop_test.go new file mode 100644 index 0000000000000..6eab6af19cb47 --- /dev/null +++ b/op-service/clock/loop_test.go @@ -0,0 +1,32 @@ +package clock + +import ( + "context" + "errors" + "testing" + "time" + + "github.com/stretchr/testify/require" +) + +func TestLoopFn(t *testing.T) { + cl := NewDeterministicClock(time.Now()) + calls := make(chan struct{}, 10) + testErr := errors.New("test close error") + loopFn := NewLoopFn(cl, func(ctx context.Context) { + calls <- struct{}{} + }, func() error { + close(calls) + return testErr + }, time.Second*10) + cl.AdvanceTime(time.Second * 15) + <-calls + cl.AdvanceTime(time.Second * 10) + <-calls + select { + case <-calls: + t.Fatal("more calls than expected") + default: + } + require.ErrorIs(t, loopFn.Close(), testErr) +} diff --git a/op-service/dial/dial.go b/op-service/dial/dial.go index cab8b8466b304..11410197b7d30 100644 --- a/op-service/dial/dial.go +++ b/op-service/dial/dial.go @@ -21,8 +21,8 @@ const defaultRetryTime = 2 * time.Second // DialEthClientWithTimeout attempts to dial the L1 provider using the provided // URL. If the dial doesn't complete within defaultDialTimeout seconds, this // method will return an error. -func DialEthClientWithTimeout(timeout time.Duration, log log.Logger, url string) (*ethclient.Client, error) { - ctx, cancel := context.WithTimeout(context.Background(), timeout) +func DialEthClientWithTimeout(ctx context.Context, timeout time.Duration, log log.Logger, url string) (*ethclient.Client, error) { + ctx, cancel := context.WithTimeout(ctx, timeout) defer cancel() c, err := dialRPCClientWithBackoff(ctx, log, url) @@ -35,8 +35,8 @@ func DialEthClientWithTimeout(timeout time.Duration, log log.Logger, url string) // DialRollupClientWithTimeout attempts to dial the RPC provider using the provided URL. // If the dial doesn't complete within timeout seconds, this method will return an error. -func DialRollupClientWithTimeout(timeout time.Duration, log log.Logger, url string) (*sources.RollupClient, error) { - ctx, cancel := context.WithTimeout(context.Background(), timeout) +func DialRollupClientWithTimeout(ctx context.Context, timeout time.Duration, log log.Logger, url string) (*sources.RollupClient, error) { + ctx, cancel := context.WithTimeout(ctx, timeout) defer cancel() rpcCl, err := dialRPCClientWithBackoff(ctx, log, url) diff --git a/op-service/eth/address.go b/op-service/eth/address.go new file mode 100644 index 0000000000000..77d29b011ba45 --- /dev/null +++ b/op-service/eth/address.go @@ -0,0 +1,12 @@ +package eth + +import "github.com/ethereum/go-ethereum/common" + +// AddressAsLeftPaddedHash converts an address to a hash by left-padding it with zeros. +// No hashing is performed. +// This was previously known as Address.Hash(), +// but removed from go-ethereum in PR 28228, because the naming was not clear. +func AddressAsLeftPaddedHash(addr common.Address) (out common.Hash) { + copy(out[32-20:], addr[:]) + return +} diff --git a/op-service/eth/block_info.go b/op-service/eth/block_info.go index 0b8d69189be8e..15dff04a55297 100644 --- a/op-service/eth/block_info.go +++ b/op-service/eth/block_info.go @@ -20,6 +20,7 @@ type BlockInfo interface { BaseFee() *big.Int ReceiptHash() common.Hash GasUsed() uint64 + GasLimit() uint64 // HeaderRLP returns the RLP of the block header as per consensus rules // Returns an error if the header RLP could not be written @@ -100,6 +101,10 @@ func (h headerBlockInfo) GasUsed() uint64 { return h.Header.GasUsed } +func (h headerBlockInfo) GasLimit() uint64 { + return h.Header.GasLimit +} + func (h headerBlockInfo) HeaderRLP() ([]byte, error) { return rlp.EncodeToBytes(h.Header) } diff --git a/op-service/eth/ssz.go b/op-service/eth/ssz.go index 4a483221f55dc..80d5041f3be7c 100644 --- a/op-service/eth/ssz.go +++ b/op-service/eth/ssz.go @@ -7,6 +7,15 @@ import ( "io" "math" "sync" + + "github.com/ethereum/go-ethereum/core/types" +) + +type BlockVersion int + +const ( // iota is reset to 0 + BlockV1 BlockVersion = iota + BlockV2 = iota ) // ExecutionPayload is the only SSZ type we have to marshal/unmarshal, @@ -14,11 +23,21 @@ import ( // This is more efficient than RLP, and matches the L1 consensus-layer encoding of ExecutionPayload. // All fields (4s are offsets to dynamic data) -const executionPayloadFixedPart = 32 + 20 + 32 + 32 + 256 + 32 + 8 + 8 + 8 + 8 + 4 + 32 + 32 + 4 +const blockV1FixedPart = 32 + 20 + 32 + 32 + 256 + 32 + 8 + 8 + 8 + 8 + 4 + 32 + 32 + 4 + +// V1 + Withdrawals offset +const blockV2FixedPart = blockV1FixedPart + 4 + +const withdrawalSize = 8 + 8 + 20 + 8 // MAX_TRANSACTIONS_PER_PAYLOAD in consensus spec +// https://github.com/ethereum/consensus-specs/blob/ef434e87165e9a4c82a99f54ffd4974ae113f732/specs/bellatrix/beacon-chain.md#execution const maxTransactionsPerPayload = 1 << 20 +// MAX_WITHDRAWALS_PER_PAYLOAD in consensus spec +// https://github.com/ethereum/consensus-specs/blob/dev/specs/capella/beacon-chain.md#execution +const maxWithdrawalsPerPayload = 1 << 4 + // ErrExtraDataTooLarge occurs when the ExecutionPayload's ExtraData field // is too large to be properly represented in SSZ. var ErrExtraDataTooLarge = errors.New("extra data too large") @@ -31,16 +50,44 @@ var payloadBufPool = sync.Pool{New: func() any { }} var ErrBadTransactionOffset = errors.New("transactions offset is smaller than extra data offset, aborting") +var ErrBadWithdrawalsOffset = errors.New("withdrawals offset is smaller than transaction offset, aborting") + +func executionPayloadFixedPart(version BlockVersion) uint32 { + if version == BlockV2 { + return blockV2FixedPart + } else { + return blockV1FixedPart + } +} + +func (payload *ExecutionPayload) inferVersion() BlockVersion { + if payload.Withdrawals != nil { + return BlockV2 + } else { + return BlockV1 + } +} func (payload *ExecutionPayload) SizeSSZ() (full uint32) { - full = executionPayloadFixedPart + uint32(len(payload.ExtraData)) + return executionPayloadFixedPart(payload.inferVersion()) + uint32(len(payload.ExtraData)) + payload.transactionSize() + payload.withdrawalSize() +} + +func (payload *ExecutionPayload) withdrawalSize() uint32 { + if payload.Withdrawals == nil { + return 0 + } + + return uint32(len(*payload.Withdrawals) * withdrawalSize) +} + +func (payload *ExecutionPayload) transactionSize() uint32 { // One offset to each transaction - full += uint32(len(payload.Transactions)) * 4 + result := uint32(len(payload.Transactions)) * 4 // Each transaction for _, tx := range payload.Transactions { - full += uint32(len(tx)) + result += uint32(len(tx)) } - return full + return result } // marshalBytes32LE returns the value of z as a 32-byte little-endian array. @@ -62,9 +109,13 @@ func unmarshalBytes32LE(in []byte, z *Uint256Quantity) { // MarshalSSZ encodes the ExecutionPayload as SSZ type func (payload *ExecutionPayload) MarshalSSZ(w io.Writer) (n int, err error) { + fixedSize := executionPayloadFixedPart(payload.inferVersion()) + transactionSize := payload.transactionSize() + // Cast to uint32 to enable 32-bit MIPS support where math.MaxUint32-executionPayloadFixedPart is too big for int // In that case, len(payload.ExtraData) can't be longer than an int so this is always false anyway. - if uint32(len(payload.ExtraData)) > math.MaxUint32-uint32(executionPayloadFixedPart) { + extraDataSize := uint32(len(payload.ExtraData)) + if extraDataSize > math.MaxUint32-fixedSize { return 0, ErrExtraDataTooLarge } @@ -100,26 +151,58 @@ func (payload *ExecutionPayload) MarshalSSZ(w io.Writer) (n int, err error) { binary.LittleEndian.PutUint64(buf[offset:offset+8], uint64(payload.Timestamp)) offset += 8 // offset to ExtraData - binary.LittleEndian.PutUint32(buf[offset:offset+4], executionPayloadFixedPart) + binary.LittleEndian.PutUint32(buf[offset:offset+4], fixedSize) offset += 4 marshalBytes32LE(buf[offset:offset+32], &payload.BaseFeePerGas) offset += 32 copy(buf[offset:offset+32], payload.BlockHash[:]) offset += 32 // offset to Transactions - binary.LittleEndian.PutUint32(buf[offset:offset+4], executionPayloadFixedPart+uint32(len(payload.ExtraData))) + binary.LittleEndian.PutUint32(buf[offset:offset+4], fixedSize+extraDataSize) offset += 4 - if offset != executionPayloadFixedPart { - panic("fixed part size is inconsistent") + + if payload.Withdrawals == nil && offset != fixedSize { + panic("transactions - fixed part size is inconsistent") } + + if payload.Withdrawals != nil { + binary.LittleEndian.PutUint32(buf[offset:offset+4], fixedSize+extraDataSize+transactionSize) + offset += 4 + + if offset != fixedSize { + panic("withdrawals - fixed part size is inconsistent") + } + } + // dynamic value 1: ExtraData - copy(buf[offset:offset+uint32(len(payload.ExtraData))], payload.ExtraData[:]) - offset += uint32(len(payload.ExtraData)) + copy(buf[offset:offset+extraDataSize], payload.ExtraData[:]) + offset += extraDataSize // dynamic value 2: Transactions - marshalTransactions(buf[offset:], payload.Transactions) + marshalTransactions(buf[offset:offset+transactionSize], payload.Transactions) + offset += transactionSize + // dyanmic value 3: Withdrawals + if payload.Withdrawals != nil { + marshalWithdrawals(buf[offset:], *payload.Withdrawals) + } + return w.Write(buf) } +func marshalWithdrawals(out []byte, withdrawals types.Withdrawals) { + offset := uint32(0) + + for _, withdrawal := range withdrawals { + binary.LittleEndian.PutUint64(out[offset:offset+8], withdrawal.Index) + offset += 8 + binary.LittleEndian.PutUint64(out[offset:offset+8], withdrawal.Validator) + offset += 8 + copy(out[offset:offset+20], withdrawal.Address[:]) + offset += 20 + binary.LittleEndian.PutUint64(out[offset:offset+8], withdrawal.Amount) + offset += 8 + } +} + func marshalTransactions(out []byte, txs []Data) { offset := uint32(0) txOffset := uint32(len(txs)) * 4 @@ -133,8 +216,10 @@ func marshalTransactions(out []byte, txs []Data) { } // UnmarshalSSZ decodes the ExecutionPayload as SSZ type -func (payload *ExecutionPayload) UnmarshalSSZ(scope uint32, r io.Reader) error { - if scope < executionPayloadFixedPart { +func (payload *ExecutionPayload) UnmarshalSSZ(version BlockVersion, scope uint32, r io.Reader) error { + fixedSize := executionPayloadFixedPart(version) + + if scope < fixedSize { return fmt.Errorf("scope too small to decode execution payload: %d", scope) } @@ -171,36 +256,99 @@ func (payload *ExecutionPayload) UnmarshalSSZ(scope uint32, r io.Reader) error { payload.Timestamp = Uint64Quantity(binary.LittleEndian.Uint64(buf[offset : offset+8])) offset += 8 extraDataOffset := binary.LittleEndian.Uint32(buf[offset : offset+4]) - if extraDataOffset != executionPayloadFixedPart { - return fmt.Errorf("unexpected extra data offset: %d <> %d", extraDataOffset, executionPayloadFixedPart) + if extraDataOffset != fixedSize { + return fmt.Errorf("unexpected extra data offset: %d <> %d", extraDataOffset, fixedSize) } offset += 4 unmarshalBytes32LE(buf[offset:offset+32], &payload.BaseFeePerGas) offset += 32 copy(payload.BlockHash[:], buf[offset:offset+32]) offset += 32 + transactionsOffset := binary.LittleEndian.Uint32(buf[offset : offset+4]) if transactionsOffset < extraDataOffset { return ErrBadTransactionOffset } offset += 4 - if offset != executionPayloadFixedPart { + if version == BlockV1 && offset != fixedSize { panic("fixed part size is inconsistent") } + + withdrawalsOffset := scope + if version == BlockV2 { + withdrawalsOffset = binary.LittleEndian.Uint32(buf[offset : offset+4]) + // No offset increment, due to this being the last field + + if withdrawalsOffset < transactionsOffset { + return ErrBadWithdrawalsOffset + } + } + if transactionsOffset > extraDataOffset+32 || transactionsOffset > scope { return fmt.Errorf("extra-data is too large: %d", transactionsOffset-extraDataOffset) } + extraDataSize := transactionsOffset - extraDataOffset payload.ExtraData = make(BytesMax32, extraDataSize) copy(payload.ExtraData, buf[extraDataOffset:transactionsOffset]) - txs, err := unmarshalTransactions(buf[transactionsOffset:]) + + txs, err := unmarshalTransactions(buf[transactionsOffset:withdrawalsOffset]) if err != nil { return fmt.Errorf("failed to unmarshal transactions list: %w", err) } payload.Transactions = txs + + if version == BlockV2 { + if withdrawalsOffset > scope { + return fmt.Errorf("withdrawals offset is too large: %d", withdrawalsOffset) + } + + withdrawals, err := unmarshalWithdrawals(buf[withdrawalsOffset:]) + if err != nil { + return fmt.Errorf("failed to unmarshal withdrawals list: %w", err) + } + payload.Withdrawals = &withdrawals + } + return nil } +func unmarshalWithdrawals(in []byte) (types.Withdrawals, error) { + result := types.Withdrawals{} // empty list by default, intentionally non-nil + + if len(in)%withdrawalSize != 0 { + return nil, errors.New("invalid withdrawals data") + } + + withdrawalCount := len(in) / withdrawalSize + + if withdrawalCount > maxWithdrawalsPerPayload { + return nil, fmt.Errorf("too many withdrawals: %d > %d", withdrawalCount, maxWithdrawalsPerPayload) + } + + offset := 0 + + for i := 0; i < withdrawalCount; i++ { + withdrawal := &types.Withdrawal{} + + withdrawal.Index = binary.LittleEndian.Uint64(in[offset : offset+8]) + offset += 8 + + withdrawal.Validator = binary.LittleEndian.Uint64(in[offset : offset+8]) + offset += 8 + + copy(withdrawal.Address[:], in[offset:offset+20]) + offset += 20 + + withdrawal.Amount = binary.LittleEndian.Uint64(in[offset : offset+8]) + offset += 8 + + result = append(result, withdrawal) + } + + return result, nil +} + func unmarshalTransactions(in []byte) (txs []Data, err error) { scope := uint32(len(in)) if scope == 0 { // empty txs list diff --git a/op-service/eth/ssz_test.go b/op-service/eth/ssz_test.go index 3d0dcdbb864c9..79a4c02888390 100644 --- a/op-service/eth/ssz_test.go +++ b/op-service/eth/ssz_test.go @@ -3,29 +3,43 @@ package eth import ( "bytes" "encoding/binary" + "fmt" "math" "testing" "github.com/google/go-cmp/cmp" + "github.com/holiman/uint256" "github.com/stretchr/testify/require" "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/core/types" ) // FuzzExecutionPayloadUnmarshal checks that our SSZ decoding never panics func FuzzExecutionPayloadUnmarshal(f *testing.F) { f.Fuzz(func(t *testing.T, data []byte) { - var payload ExecutionPayload - err := payload.UnmarshalSSZ(uint32(len(data)), bytes.NewReader(data)) - if err != nil { - // not every input is a valid ExecutionPayload, that's ok. Should just not panic. - return + { + var payload ExecutionPayload + err := payload.UnmarshalSSZ(BlockV1, uint32(len(data)), bytes.NewReader(data)) + if err != nil { + // not every input is a valid ExecutionPayload, that's ok. Should just not panic. + return + } + } + + { + var payload ExecutionPayload + err := payload.UnmarshalSSZ(BlockV2, uint32(len(data)), bytes.NewReader(data)) + if err != nil { + // not every input is a valid ExecutionPayload, that's ok. Should just not panic. + return + } } }) } // FuzzExecutionPayloadMarshalUnmarshal checks that our SSZ encoding>decoding round trips properly -func FuzzExecutionPayloadMarshalUnmarshal(f *testing.F) { +func FuzzExecutionPayloadMarshalUnmarshalV1(f *testing.F) { f.Fuzz(func(t *testing.T, data []byte, a, b, c, d uint64, extraData []byte, txs uint16, txsData []byte) { if len(data) < 32+20+32+32+256+32+32+32 { return @@ -72,7 +86,77 @@ func FuzzExecutionPayloadMarshalUnmarshal(f *testing.F) { t.Fatalf("failed to marshal ExecutionPayload: %v", err) } var roundTripped ExecutionPayload - err := roundTripped.UnmarshalSSZ(uint32(len(buf.Bytes())), bytes.NewReader(buf.Bytes())) + err := roundTripped.UnmarshalSSZ(BlockV1, uint32(len(buf.Bytes())), bytes.NewReader(buf.Bytes())) + if err != nil { + t.Fatalf("failed to decode previously marshalled payload: %v", err) + } + if diff := cmp.Diff(payload, roundTripped); diff != "" { + t.Fatalf("The data did not round trip correctly:\n%s", diff) + } + }) +} + +func FuzzExecutionPayloadMarshalUnmarshalV2(f *testing.F) { + f.Fuzz(func(t *testing.T, data []byte, a, b, c, d uint64, extraData []byte, txs uint16, txsData []byte, wCount uint16) { + if len(data) < 32+20+32+32+256+32+32+32 { + return + } + var payload ExecutionPayload + payload.ParentHash = *(*common.Hash)(data[:32]) + data = data[32:] + payload.FeeRecipient = *(*common.Address)(data[:20]) + data = data[20:] + payload.StateRoot = *(*Bytes32)(data[:32]) + data = data[32:] + payload.ReceiptsRoot = *(*Bytes32)(data[:32]) + data = data[32:] + payload.LogsBloom = *(*Bytes256)(data[:256]) + data = data[256:] + payload.PrevRandao = *(*Bytes32)(data[:32]) + data = data[32:] + payload.BlockNumber = Uint64Quantity(a) + payload.GasLimit = Uint64Quantity(a) + payload.GasUsed = Uint64Quantity(a) + payload.Timestamp = Uint64Quantity(a) + if len(extraData) > 32 { + extraData = extraData[:32] + } + payload.ExtraData = extraData + payload.BaseFeePerGas.SetBytes(data[:32]) + payload.BlockHash = *(*common.Hash)(data[:32]) + payload.Transactions = make([]Data, txs) + for i := 0; i < int(txs); i++ { + if len(txsData) < 2 { + payload.Transactions[i] = make(Data, 0) + continue + } + txSize := binary.LittleEndian.Uint16(txsData[:2]) + txsData = txsData[2:] + if int(txSize) > len(txsData) { + txSize = uint16(len(txsData)) + } + payload.Transactions[i] = txsData[:txSize] + txsData = txsData[txSize:] + } + + wCount = wCount % maxWithdrawalsPerPayload + withdrawals := make(types.Withdrawals, wCount) + for i := 0; i < int(wCount); i++ { + withdrawals[i] = &types.Withdrawal{ + Index: a, + Validator: b, + Address: common.BytesToAddress(data[:20]), + Amount: c, + } + } + payload.Withdrawals = &withdrawals + + var buf bytes.Buffer + if _, err := payload.MarshalSSZ(&buf); err != nil { + t.Fatalf("failed to marshal ExecutionPayload: %v", err) + } + var roundTripped ExecutionPayload + err := roundTripped.UnmarshalSSZ(BlockV2, uint32(len(buf.Bytes())), bytes.NewReader(buf.Bytes())) if err != nil { t.Fatalf("failed to decode previously marshalled payload: %v", err) } @@ -99,7 +183,7 @@ func FuzzOBP01(f *testing.F) { binary.LittleEndian.PutUint32(clone[504:508], txOffset) var unmarshalled ExecutionPayload - err = unmarshalled.UnmarshalSSZ(uint32(len(clone)), bytes.NewReader(clone)) + err = unmarshalled.UnmarshalSSZ(BlockV1, uint32(len(clone)), bytes.NewReader(clone)) if err == nil { t.Fatalf("expected a failure, but didn't get one") } @@ -122,7 +206,7 @@ func TestOPB01(t *testing.T) { copy(data[504:508], make([]byte, 4)) var unmarshalled ExecutionPayload - err = unmarshalled.UnmarshalSSZ(uint32(len(data)), bytes.NewReader(data)) + err = unmarshalled.UnmarshalSSZ(BlockV1, uint32(len(data)), bytes.NewReader(data)) require.Equal(t, ErrBadTransactionOffset, err) } @@ -130,20 +214,126 @@ func TestOPB01(t *testing.T) { // properly returns an error when the ExtraData field // cannot be represented in the outputted SSZ. func TestOPB04(t *testing.T) { + data := make([]byte, math.MaxUint32) + + var buf bytes.Buffer // First, test the maximum len - which in this case is the max uint32 // minus the execution payload fixed part. payload := &ExecutionPayload{ - ExtraData: make([]byte, math.MaxUint32-executionPayloadFixedPart), + ExtraData: data[:math.MaxUint32-executionPayloadFixedPart(BlockV1)], + Withdrawals: nil, } - var buf bytes.Buffer + _, err := payload.MarshalSSZ(&buf) require.NoError(t, err) buf.Reset() - payload = &ExecutionPayload{ - ExtraData: make([]byte, math.MaxUint32-executionPayloadFixedPart+1), + tests := []struct { + version BlockVersion + withdrawals *types.Withdrawals + }{ + {BlockV1, nil}, + {BlockV2, &types.Withdrawals{}}, + } + + for _, test := range tests { + payload := &ExecutionPayload{ + ExtraData: data[:math.MaxUint32-executionPayloadFixedPart(test.version)+1], + Withdrawals: test.withdrawals, + } + _, err := payload.MarshalSSZ(&buf) + require.Error(t, err) + require.Equal(t, ErrExtraDataTooLarge, err) + } + +} + +func createPayloadWithWithdrawals(w *types.Withdrawals) *ExecutionPayload { + return &ExecutionPayload{ + ParentHash: common.HexToHash("0x123"), + FeeRecipient: common.HexToAddress("0x456"), + StateRoot: Bytes32(common.HexToHash("0x789")), + ReceiptsRoot: Bytes32(common.HexToHash("0xabc")), + LogsBloom: Bytes256{byte(13), byte(14), byte(15)}, + PrevRandao: Bytes32(common.HexToHash("0x111")), + BlockNumber: Uint64Quantity(222), + GasLimit: Uint64Quantity(333), + GasUsed: Uint64Quantity(444), + Timestamp: Uint64Quantity(555), + ExtraData: common.Hex2Bytes("0x666"), + BaseFeePerGas: *uint256.NewInt(777), + BlockHash: common.HexToHash("0x888"), + Withdrawals: w, + Transactions: []Data{common.Hex2Bytes("0x999")}, + } +} + +func TestMarshalUnmarshalWithdrawals(t *testing.T) { + emptyWithdrawal := &types.Withdrawals{} + withdrawals := &types.Withdrawals{ + { + Index: 987, + Validator: 654, + Address: common.HexToAddress("0x898"), + Amount: 321, + }, + } + maxWithdrawals := make(types.Withdrawals, maxWithdrawalsPerPayload) + for i := 0; i < maxWithdrawalsPerPayload; i++ { + maxWithdrawals[i] = &types.Withdrawal{ + Index: 987, + Validator: 654, + Address: common.HexToAddress("0x898"), + Amount: 321, + } + } + tooManyWithdrawals := make(types.Withdrawals, maxWithdrawalsPerPayload+1) + for i := 0; i < maxWithdrawalsPerPayload+1; i++ { + tooManyWithdrawals[i] = &types.Withdrawal{ + Index: 987, + Validator: 654, + Address: common.HexToAddress("0x898"), + Amount: 321, + } + } + + tests := []struct { + name string + version BlockVersion + hasError bool + withdrawals *types.Withdrawals + }{ + {"ZeroWithdrawalsSucceeds", BlockV2, false, emptyWithdrawal}, + {"ZeroWithdrawalsFailsToDeserialize", BlockV1, true, emptyWithdrawal}, + {"WithdrawalsSucceeds", BlockV2, false, withdrawals}, + {"WithdrawalsFailsToDeserialize", BlockV1, true, withdrawals}, + {"MaxWithdrawalsSucceeds", BlockV2, false, &maxWithdrawals}, + {"TooManyWithdrawalsErrors", BlockV2, true, &tooManyWithdrawals}, + } + + for _, test := range tests { + test := test + + t.Run(fmt.Sprintf("TestWithdrawalUnmarshalMarshal_%s", test.name), func(t *testing.T) { + input := createPayloadWithWithdrawals(test.withdrawals) + + var buf bytes.Buffer + _, err := input.MarshalSSZ(&buf) + require.NoError(t, err) + data := buf.Bytes() + + output := &ExecutionPayload{} + err = output.UnmarshalSSZ(test.version, uint32(len(data)), bytes.NewReader(data)) + + if test.hasError { + require.Error(t, err) + } else { + require.NoError(t, err) + require.Equal(t, input, output) + if test.withdrawals != nil { + require.Equal(t, len(*test.withdrawals), len(*output.Withdrawals)) + } + } + }) } - _, err = payload.MarshalSSZ(&buf) - require.Error(t, err) - require.Equal(t, ErrExtraDataTooLarge, err) } diff --git a/op-service/eth/sync_status.go b/op-service/eth/sync_status.go index 74ac24c12cc07..2217fa9439e37 100644 --- a/op-service/eth/sync_status.go +++ b/op-service/eth/sync_status.go @@ -32,6 +32,8 @@ type SyncStatus struct { // FinalizedL2 points to the L2 block that was derived fully from // finalized L1 information, thus irreversible. FinalizedL2 L2BlockRef `json:"finalized_l2"` + // PendingSafeL2 points to the L2 block processed from the batch, but not consolidated to the safe block yet. + PendingSafeL2 L2BlockRef `json:"pending_safe_l2"` // UnsafeL2SyncTarget points to the first unprocessed unsafe L2 block. // It may be zeroed if there is no targeted block. UnsafeL2SyncTarget L2BlockRef `json:"queued_unsafe_l2"` diff --git a/op-service/eth/types.go b/op-service/eth/types.go index 1b3cc2147e8f5..f3bdf8be9df4c 100644 --- a/op-service/eth/types.go +++ b/op-service/eth/types.go @@ -6,13 +6,12 @@ import ( "math/big" "reflect" - "github.com/holiman/uint256" - "github.com/ethereum/go-ethereum/beacon/engine" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common/hexutil" "github.com/ethereum/go-ethereum/core/types" "github.com/ethereum/go-ethereum/trie" + "github.com/holiman/uint256" ) type ErrorCode int @@ -143,7 +142,8 @@ type ExecutionPayload struct { ExtraData BytesMax32 `json:"extraData"` BaseFeePerGas Uint256Quantity `json:"baseFeePerGas"` BlockHash common.Hash `json:"blockHash"` - Withdrawals *[]Withdrawal `json:"withdrawals,omitempty"` + // nil if not present, pre-shanghai + Withdrawals *types.Withdrawals `json:"withdrawals,omitempty"` // Array of transaction objects, each object is a byte list (DATA) representing // TransactionType || TransactionPayload or LegacyTransaction as defined in EIP-2718 Transactions []Data `json:"transactions"` @@ -168,6 +168,10 @@ func (s rawTransactions) EncodeIndex(i int, w *bytes.Buffer) { w.Write(s[i]) } +func (payload *ExecutionPayload) CanyonBlock() bool { + return payload.Withdrawals != nil +} + // CheckBlockHash recomputes the block hash and returns if the embedded block hash matches. func (payload *ExecutionPayload) CheckBlockHash() (actual common.Hash, ok bool) { hasher := trie.NewStackTrie(nil) @@ -191,11 +195,17 @@ func (payload *ExecutionPayload) CheckBlockHash() (actual common.Hash, ok bool) Nonce: types.BlockNonce{}, // zeroed, proof-of-work legacy BaseFee: payload.BaseFeePerGas.ToBig(), } + + if payload.CanyonBlock() { + withdrawalHash := types.DeriveSha(*payload.Withdrawals, hasher) + header.WithdrawalsHash = &withdrawalHash + } + blockHash := header.Hash() return blockHash, blockHash == payload.BlockHash } -func BlockAsPayload(bl *types.Block) (*ExecutionPayload, error) { +func BlockAsPayload(bl *types.Block, canyonForkTime *uint64) (*ExecutionPayload, error) { baseFee, overflow := uint256.FromBig(bl.BaseFee()) if overflow { return nil, fmt.Errorf("invalid base fee in block: %s", bl.BaseFee()) @@ -208,7 +218,8 @@ func BlockAsPayload(bl *types.Block) (*ExecutionPayload, error) { } opaqueTxs[i] = otx } - return &ExecutionPayload{ + + payload := &ExecutionPayload{ ParentHash: bl.ParentHash(), FeeRecipient: bl.Coinbase(), StateRoot: Bytes32(bl.Root()), @@ -220,10 +231,16 @@ func BlockAsPayload(bl *types.Block) (*ExecutionPayload, error) { GasUsed: Uint64Quantity(bl.GasUsed()), Timestamp: Uint64Quantity(bl.Time()), ExtraData: bl.Extra(), - BaseFeePerGas: Uint256Quantity(*baseFee), + BaseFeePerGas: *baseFee, BlockHash: bl.Hash(), Transactions: opaqueTxs, - }, nil + } + + if canyonForkTime != nil && uint64(payload.Timestamp) >= *canyonForkTime { + payload.Withdrawals = &types.Withdrawals{} + } + + return payload, nil } type PayloadAttributes struct { @@ -234,7 +251,7 @@ type PayloadAttributes struct { // suggested value for the coinbase field of the new payload SuggestedFeeRecipient common.Address `json:"suggestedFeeRecipient"` // Withdrawals to include into the block -- should be nil or empty depending on Shanghai enablement - Withdrawals *[]Withdrawal `json:"withdrawals,omitempty"` + Withdrawals *types.Withdrawals `json:"withdrawals,omitempty"` // Transactions to force into the block (always at the start of the transactions list). Transactions []Data `json:"transactions,omitempty"` // NoTxPool to disable adding any transactions from the transaction-pool. @@ -300,11 +317,3 @@ type SystemConfig struct { GasLimit uint64 `json:"gasLimit"` // More fields can be added for future SystemConfig versions. } - -// Withdrawal represents a validator withdrawal from the consensus layer. -type Withdrawal struct { - Index uint64 `json:"index"` // monotonically increasing identifier issued by consensus layer - Validator uint64 `json:"validatorIndex"` // index of validator associated with withdrawal - Address common.Address `json:"address"` // target address for withdrawn ether - Amount uint64 `json:"amount"` // value of withdrawal in Gwei -} diff --git a/op-service/metrics/balance.go b/op-service/metrics/balance.go index de9066846c5e2..8da012813268e 100644 --- a/op-service/metrics/balance.go +++ b/op-service/metrics/balance.go @@ -5,12 +5,15 @@ import ( "math/big" "time" + "github.com/prometheus/client_golang/prometheus" + "github.com/prometheus/client_golang/prometheus/promauto" + "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/ethclient" "github.com/ethereum/go-ethereum/log" "github.com/ethereum/go-ethereum/params" - "github.com/prometheus/client_golang/prometheus" - "github.com/prometheus/client_golang/prometheus/promauto" + + "github.com/ethereum-optimism/optimism/op-service/clock" ) // weiToEther divides the wei value by 10^18 to get a number in ether as a float64 @@ -22,38 +25,27 @@ func weiToEther(wei *big.Int) float64 { return f } -// LaunchBalanceMetrics fires off a go rountine that queries the balance of the supplied account & periodically records it -// to the balance metric of the namespace. The balance of the account is recorded in Ether (not Wei). +// LaunchBalanceMetrics starts a periodic query of the balance of the supplied account and records it +// to the "balance" metric of the namespace. The balance of the account is recorded in Ether (not Wei). // Cancel the supplied context to shut down the go routine -func LaunchBalanceMetrics(ctx context.Context, log log.Logger, r *prometheus.Registry, ns string, client *ethclient.Client, account common.Address) { - go func() { - balanceGuage := promauto.With(r).NewGauge(prometheus.GaugeOpts{ - Namespace: ns, - Name: "balance", - Help: "balance (in ether) of account " + account.String(), - }) - - ticker := time.NewTicker(10 * time.Second) - defer ticker.Stop() - - for { - select { - case <-ticker.C: - ctx, cancel := context.WithTimeout(ctx, 1*time.Minute) - bigBal, err := client.BalanceAt(ctx, account, nil) - if err != nil { - log.Warn("failed to get balance of account", "err", err, "address", account) - cancel() - continue - } - bal := weiToEther(bigBal) - balanceGuage.Set(bal) - cancel() - case <-ctx.Done(): - log.Info("balance metrics shutting down") - return - } +func LaunchBalanceMetrics(log log.Logger, r *prometheus.Registry, ns string, client *ethclient.Client, account common.Address) *clock.LoopFn { + balanceGuage := promauto.With(r).NewGauge(prometheus.GaugeOpts{ + Namespace: ns, + Name: "balance", + Help: "balance (in ether) of account " + account.String(), + }) + return clock.NewLoopFn(clock.SystemClock, func(ctx context.Context) { + ctx, cancel := context.WithTimeout(ctx, 1*time.Minute) + defer cancel() + bigBal, err := client.BalanceAt(ctx, account, nil) + if err != nil { + log.Warn("failed to get balance of account", "err", err, "address", account) + return } - - }() + bal := weiToEther(bigBal) + balanceGuage.Set(bal) + }, func() error { + log.Info("balance metrics shutting down") + return nil + }, 10*time.Second) } diff --git a/op-service/metrics/http.go b/op-service/metrics/http.go index f9102ac44f903..8640fe02a6f20 100644 --- a/op-service/metrics/http.go +++ b/op-service/metrics/http.go @@ -44,21 +44,41 @@ func (n *noopHTTPRecorder) RecordHTTPRequest(*HTTPParams) {} func (n *noopHTTPRecorder) RecordHTTPResponse(*HTTPParams) {} type PromHTTPRecorder struct { - HTTPRequestDuration *prometheus.HistogramVec + // HTTPRequestDuration is the old metric for request latency + // it was created with too tight buckets: [.005, .01, .025, .05, .1, .25, .5, 1, 2.5, 5, 10] + // in order to preserve backward compatibility we are keeping this metric for now + // and it will be removed when services opt in to HTTPRequestLatency + // Deprecated: HTTPRequestDuration is deprecated + HTTPRequestDuration *prometheus.HistogramVec + + // HTTPRequestLatency measures request execution latency in *seconds* + // buckets are: [.025, .05, .1, .25, .5, 1, 2.5, 5, 10, 25, 50] + HTTPRequestLatency *prometheus.HistogramVec + HTTPResponseSize *prometheus.HistogramVec HTTPInflightRequests *prometheus.GaugeVec HTTPRequests *prometheus.CounterVec HTTPResponses *prometheus.CounterVec } +var LatencyBuckets = []float64{.025, .05, .1, .25, .5, 1, 2.5, 5, 10, 25, 50, 100} + func NewPromHTTPRecorder(r *prometheus.Registry, ns string) HTTPRecorder { return &PromHTTPRecorder{ + // TODO(INF-509): remove this in the future when services opted in to HTTPRequestLatency HTTPRequestDuration: promauto.With(r).NewHistogramVec(prometheus.HistogramOpts{ Namespace: ns, Name: "http_request_duration_ms", Help: "Tracks HTTP request durations, in ms", Buckets: prometheus.DefBuckets, }, httpLabels), + HTTPRequestLatency: promauto.With(r).NewHistogramVec(prometheus.HistogramOpts{ + Namespace: ns, + Name: "http_request_latency_seconds", + Help: "Tracks HTTP request execution latency, in seconds", + Buckets: LatencyBuckets, + }, httpLabels), + HTTPResponseSize: promauto.With(r).NewHistogramVec(prometheus.HistogramOpts{ Namespace: ns, Name: "http_response_size", @@ -84,8 +104,12 @@ func NewPromHTTPRecorder(r *prometheus.Registry, ns string) HTTPRecorder { } func (p *PromHTTPRecorder) RecordHTTPRequestDuration(params *HTTPParams, dur time.Duration) { + // TODO(INF-509): remove this in the future when services opted in to new metric p.HTTPRequestDuration.WithLabelValues(params.Method, strconv.Itoa(params.StatusCode)). Observe(float64(dur.Milliseconds())) + + p.HTTPRequestLatency.WithLabelValues(params.Method, strconv.Itoa(params.StatusCode)). + Observe(dur.Seconds()) } func (p *PromHTTPRecorder) RecordHTTPResponseSize(params *HTTPParams, size int) { diff --git a/op-service/metrics/registry.go b/op-service/metrics/registry.go index 882bcbe4ae356..9ba44707c5867 100644 --- a/op-service/metrics/registry.go +++ b/op-service/metrics/registry.go @@ -11,3 +11,7 @@ func NewRegistry() *prometheus.Registry { registry.MustRegister(collectors.NewGoCollector()) return registry } + +type RegistryMetricer interface { + Registry() *prometheus.Registry +} diff --git a/op-service/metrics/rpc_metrics.go b/op-service/metrics/rpc_metrics.go index a9f0d105798e2..b6bda30c80075 100644 --- a/op-service/metrics/rpc_metrics.go +++ b/op-service/metrics/rpc_metrics.go @@ -125,3 +125,17 @@ func (m *RPCMetrics) RecordRPCClientResponse(method string, err error) { } m.RPCClientResponsesTotal.WithLabelValues(method, errStr).Inc() } + +type NoopRPCMetrics struct{} + +func (n *NoopRPCMetrics) RecordRPCServerRequest(method string) func() { + return func() {} +} + +func (n *NoopRPCMetrics) RecordRPCClientRequest(method string) func(err error) { + return func(err error) {} +} +func (n *NoopRPCMetrics) RecordRPCClientResponse(method string, err error) { +} + +var _ RPCMetricer = (*NoopRPCMetrics)(nil) diff --git a/op-service/opio/interrupts.go b/op-service/opio/interrupts.go index 1b886c6d90018..cd1b8485791d3 100644 --- a/op-service/opio/interrupts.go +++ b/op-service/opio/interrupts.go @@ -41,3 +41,74 @@ func BlockOnInterruptsContext(ctx context.Context, signals ...os.Signal) { signal.Stop(interruptChannel) } } + +type interruptContextKeyType struct{} + +var blockerContextKey = interruptContextKeyType{} + +type interruptCatcher struct { + incoming chan os.Signal +} + +// Block blocks until either an interrupt signal is received, or the context is cancelled. +// No error is returned on interrupt. +func (c *interruptCatcher) Block(ctx context.Context) { + select { + case <-c.incoming: + case <-ctx.Done(): + } +} + +// WithInterruptBlocker attaches an interrupt handler to the context, +// which continues to receive signals after every block. +// This helps functions block on individual consecutive interrupts. +func WithInterruptBlocker(ctx context.Context) context.Context { + if ctx.Value(blockerContextKey) != nil { // already has an interrupt handler + return ctx + } + catcher := &interruptCatcher{ + incoming: make(chan os.Signal, 10), + } + signal.Notify(catcher.incoming, DefaultInterruptSignals...) + + return context.WithValue(ctx, blockerContextKey, BlockFn(catcher.Block)) +} + +// WithBlocker overrides the interrupt blocker value, +// e.g. to insert a block-function for testing CLI shutdown without actual process signals. +func WithBlocker(ctx context.Context, fn BlockFn) context.Context { + return context.WithValue(ctx, blockerContextKey, fn) +} + +// BlockFn simply blocks until the implementation of the blocker interrupts it, or till the given context is cancelled. +type BlockFn func(ctx context.Context) + +// BlockerFromContext returns a BlockFn that blocks on interrupts when called. +func BlockerFromContext(ctx context.Context) BlockFn { + v := ctx.Value(blockerContextKey) + if v == nil { + return nil + } + return v.(BlockFn) +} + +// CancelOnInterrupt cancels the given context on interrupt. +// If a BlockFn is attached to the context, this is used as interrupt-blocking. +// If not, then the context blocks on a manually handled interrupt signal. +func CancelOnInterrupt(ctx context.Context) context.Context { + inner, cancel := context.WithCancel(ctx) + + blockOnInterrupt := BlockerFromContext(ctx) + if blockOnInterrupt == nil { + blockOnInterrupt = func(ctx context.Context) { + BlockOnInterruptsContext(ctx) // default signals + } + } + + go func() { + blockOnInterrupt(ctx) + cancel() + }() + + return inner +} diff --git a/op-service/rethdb-reader/.gitignore b/op-service/rethdb-reader/.gitignore new file mode 100644 index 0000000000000..96359724ffbcd --- /dev/null +++ b/op-service/rethdb-reader/.gitignore @@ -0,0 +1,5 @@ +# Target +target/ + +# Bindings +rdb.h diff --git a/op-service/rethdb-reader/Cargo.lock b/op-service/rethdb-reader/Cargo.lock new file mode 100644 index 0000000000000..14622c0a8c03a --- /dev/null +++ b/op-service/rethdb-reader/Cargo.lock @@ -0,0 +1,7452 @@ +# This file is automatically @generated by Cargo. +# It is not intended for manual editing. +version = 3 + +[[package]] +name = "addr2line" +version = "0.21.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8a30b2e23b9e17a9f90641c7ab1549cd9b44f296d3ccbf309d2863cfe398a0cb" +dependencies = [ + "gimli", +] + +[[package]] +name = "adler" +version = "1.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f26201604c87b1e01bd3d98f8d5d9a8fcbb815e8cedb41ffccbeb4bf593a35fe" + +[[package]] +name = "aead" +version = "0.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0b613b8e1e3cf911a086f53f03bf286f52fd7a7258e4fa606f0ef220d39d8877" +dependencies = [ + "generic-array", +] + +[[package]] +name = "aes" +version = "0.7.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9e8b47f52ea9bae42228d07ec09eb676433d7c4ed1ebdf0f1d1c29ed446f1ab8" +dependencies = [ + "cfg-if", + "cipher 0.3.0", + "cpufeatures", + "ctr 0.8.0", + "opaque-debug", +] + +[[package]] +name = "aes" +version = "0.8.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ac1f845298e95f983ff1944b728ae08b8cebab80d684f0a832ed0fc74dfa27e2" +dependencies = [ + "cfg-if", + "cipher 0.4.4", + "cpufeatures", +] + +[[package]] +name = "aes-gcm" +version = "0.9.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bc3be92e19a7ef47457b8e6f90707e12b6ac5d20c6f3866584fa3be0787d839f" +dependencies = [ + "aead", + "aes 0.7.5", + "cipher 0.3.0", + "ctr 0.7.0", + "ghash", + "subtle", +] + +[[package]] +name = "ahash" +version = "0.8.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "91429305e9f0a25f6205c5b8e0d2db09e0708a7a6df0f42212bb56c32c8ac97a" +dependencies = [ + "cfg-if", + "getrandom 0.2.10", + "once_cell", + "version_check", + "zerocopy", +] + +[[package]] +name = "aho-corasick" +version = "0.7.20" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cc936419f96fa211c1b9166887b38e5e40b19958e5b895be7c1f93adec7071ac" +dependencies = [ + "memchr", +] + +[[package]] +name = "aho-corasick" +version = "1.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b2969dcb958b36655471fc61f7e416fa76033bdd4bfed0678d8fee1e2d07a1f0" +dependencies = [ + "memchr", +] + +[[package]] +name = "alloc-no-stdlib" +version = "2.0.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cc7bb162ec39d46ab1ca8c77bf72e890535becd1751bb45f64c597edb4c8c6b3" + +[[package]] +name = "alloc-stdlib" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "94fb8275041c72129eb51b7d0322c29b8387a0386127718b096429201a5d6ece" +dependencies = [ + "alloc-no-stdlib", +] + +[[package]] +name = "allocator-api2" +version = "0.2.16" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0942ffc6dcaadf03badf6e6a2d0228460359d5e34b57ccdc720b7382dfbd5ec5" + +[[package]] +name = "alloy-dyn-abi" +version = "0.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e4e0daba57ddaba12dc9b21f608b843251f3de017f94a431dca4e7f4f72e5ba9" +dependencies = [ + "alloy-json-abi", + "alloy-primitives", + "alloy-sol-type-parser", + "alloy-sol-types", + "const-hex", + "derive_more", + "itoa", + "serde", + "serde_json", +] + +[[package]] +name = "alloy-json-abi" +version = "0.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "63c9319ad8b2b623c6a3ac15899f8ffb71479224762dbaedc385c16efbb6cfe3" +dependencies = [ + "alloy-primitives", + "alloy-sol-type-parser", + "serde", + "serde_json", +] + +[[package]] +name = "alloy-primitives" +version = "0.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a0628ec0ba5b98b3370bb6be17b12f23bfce8ee4ad83823325a20546d9b03b78" +dependencies = [ + "alloy-rlp", + "arbitrary", + "bytes", + "cfg-if", + "const-hex", + "derive_arbitrary", + "derive_more", + "getrandom 0.2.10", + "hex-literal", + "itoa", + "proptest", + "proptest-derive", + "rand 0.8.5", + "ruint", + "serde", + "tiny-keccak", +] + +[[package]] +name = "alloy-rlp" +version = "0.3.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cc0fac0fc16baf1f63f78b47c3d24718f3619b0714076f6a02957d808d52cbef" +dependencies = [ + "alloy-rlp-derive", + "arrayvec", + "bytes", + "smol_str", +] + +[[package]] +name = "alloy-rlp-derive" +version = "0.3.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c0391754c09fab4eae3404d19d0d297aa1c670c1775ab51d8a5312afeca23157" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.38", +] + +[[package]] +name = "alloy-sol-macro" +version = "0.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8a98ad1696a2e17f010ae8e43e9f2a1e930ed176a8e3ff77acfeff6dfb07b42c" +dependencies = [ + "const-hex", + "dunce", + "heck", + "proc-macro-error", + "proc-macro2", + "quote", + "syn 2.0.38", + "syn-solidity", + "tiny-keccak", +] + +[[package]] +name = "alloy-sol-type-parser" +version = "0.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "81c61ccc29e7c58bf16a2f780898852348183f58b127bde03ced6d07ad544787" +dependencies = [ + "winnow", +] + +[[package]] +name = "alloy-sol-types" +version = "0.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "98d7107bed88e8f09f0ddcc3335622d87bfb6821f3e0c7473329fb1cfad5e015" +dependencies = [ + "alloy-primitives", + "alloy-sol-macro", + "const-hex", + "serde", +] + +[[package]] +name = "android-tzdata" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e999941b234f3131b00bc13c22d06e8c5ff726d1b6318ac7eb276997bbb4fef0" + +[[package]] +name = "android_system_properties" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "819e7219dbd41043ac279b19830f2efc897156490d7fd6ea916720117ee66311" +dependencies = [ + "libc", +] + +[[package]] +name = "anstream" +version = "0.6.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2ab91ebe16eb252986481c5b62f6098f3b698a45e34b5b98200cf20dd2484a44" +dependencies = [ + "anstyle", + "anstyle-parse", + "anstyle-query", + "anstyle-wincon", + "colorchoice", + "utf8parse", +] + +[[package]] +name = "anstyle" +version = "1.0.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7079075b41f533b8c61d2a4d073c4676e1f8b249ff94a393b0595db304e0dd87" + +[[package]] +name = "anstyle-parse" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "317b9a89c1868f5ea6ff1d9539a69f45dffc21ce321ac1fd1160dfa48c8e2140" +dependencies = [ + "utf8parse", +] + +[[package]] +name = "anstyle-query" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5ca11d4be1bab0c8bc8734a9aa7bf4ee8316d462a08c6ac5052f888fef5b494b" +dependencies = [ + "windows-sys 0.48.0", +] + +[[package]] +name = "anstyle-wincon" +version = "3.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f0699d10d2f4d628a98ee7b57b289abbc98ff3bad977cb3152709d4bf2330628" +dependencies = [ + "anstyle", + "windows-sys 0.48.0", +] + +[[package]] +name = "anyhow" +version = "1.0.75" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a4668cab20f66d8d020e1fbc0ebe47217433c1b6c8f2040faf858554e394ace6" + +[[package]] +name = "aquamarine" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "df752953c49ce90719c7bf1fc587bc8227aed04732ea0c0f85e5397d7fdbd1a1" +dependencies = [ + "include_dir", + "itertools 0.10.5", + "proc-macro-error", + "proc-macro2", + "quote", + "syn 1.0.109", +] + +[[package]] +name = "arbitrary" +version = "1.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a2e1373abdaa212b704512ec2bd8b26bd0b7d5c3f70117411a5d9a451383c859" +dependencies = [ + "derive_arbitrary", +] + +[[package]] +name = "ark-ff" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6b3235cc41ee7a12aaaf2c575a2ad7b46713a8a50bda2fc3b003a04845c05dd6" +dependencies = [ + "ark-ff-asm 0.3.0", + "ark-ff-macros 0.3.0", + "ark-serialize 0.3.0", + "ark-std 0.3.0", + "derivative", + "num-bigint", + "num-traits", + "paste", + "rustc_version 0.3.3", + "zeroize", +] + +[[package]] +name = "ark-ff" +version = "0.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ec847af850f44ad29048935519032c33da8aa03340876d351dfab5660d2966ba" +dependencies = [ + "ark-ff-asm 0.4.2", + "ark-ff-macros 0.4.2", + "ark-serialize 0.4.2", + "ark-std 0.4.0", + "derivative", + "digest 0.10.7", + "itertools 0.10.5", + "num-bigint", + "num-traits", + "paste", + "rustc_version 0.4.0", + "zeroize", +] + +[[package]] +name = "ark-ff-asm" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "db02d390bf6643fb404d3d22d31aee1c4bc4459600aef9113833d17e786c6e44" +dependencies = [ + "quote", + "syn 1.0.109", +] + +[[package]] +name = "ark-ff-asm" +version = "0.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3ed4aa4fe255d0bc6d79373f7e31d2ea147bcf486cba1be5ba7ea85abdb92348" +dependencies = [ + "quote", + "syn 1.0.109", +] + +[[package]] +name = "ark-ff-macros" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "db2fd794a08ccb318058009eefdf15bcaaaaf6f8161eb3345f907222bac38b20" +dependencies = [ + "num-bigint", + "num-traits", + "quote", + "syn 1.0.109", +] + +[[package]] +name = "ark-ff-macros" +version = "0.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7abe79b0e4288889c4574159ab790824d0033b9fdcb2a112a3182fac2e514565" +dependencies = [ + "num-bigint", + "num-traits", + "proc-macro2", + "quote", + "syn 1.0.109", +] + +[[package]] +name = "ark-serialize" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1d6c2b318ee6e10f8c2853e73a83adc0ccb88995aa978d8a3408d492ab2ee671" +dependencies = [ + "ark-std 0.3.0", + "digest 0.9.0", +] + +[[package]] +name = "ark-serialize" +version = "0.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "adb7b85a02b83d2f22f89bd5cac66c9c89474240cb6207cb1efc16d098e822a5" +dependencies = [ + "ark-std 0.4.0", + "digest 0.10.7", + "num-bigint", +] + +[[package]] +name = "ark-std" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1df2c09229cbc5a028b1d70e00fdb2acee28b1055dfb5ca73eea49c5a25c4e7c" +dependencies = [ + "num-traits", + "rand 0.8.5", +] + +[[package]] +name = "ark-std" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "94893f1e0c6eeab764ade8dc4c0db24caf4fe7cbbaafc0eba0a9030f447b5185" +dependencies = [ + "num-traits", + "rand 0.8.5", +] + +[[package]] +name = "arrayvec" +version = "0.7.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" + +[[package]] +name = "async-compression" +version = "0.4.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f658e2baef915ba0f26f1f7c42bfb8e12f532a01f449a090ded75ae7a07e9ba2" +dependencies = [ + "brotli", + "flate2", + "futures-core", + "memchr", + "pin-project-lite", + "tokio", + "zstd 0.13.0", + "zstd-safe 7.0.0", +] + +[[package]] +name = "async-lock" +version = "2.8.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "287272293e9d8c41773cec55e365490fe034813a2f172f502d6ddcf75b2f582b" +dependencies = [ + "event-listener", +] + +[[package]] +name = "async-trait" +version = "0.1.74" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a66537f1bb974b254c98ed142ff995236e81b9d0fe4db0575f46612cb15eb0f9" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.38", +] + +[[package]] +name = "atomic-polyfill" +version = "0.1.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e3ff7eb3f316534d83a8a2c3d1674ace8a5a71198eba31e2e2b597833f699b28" +dependencies = [ + "critical-section", +] + +[[package]] +name = "atomic-polyfill" +version = "1.0.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8cf2bce30dfe09ef0bfaef228b9d414faaf7e563035494d7fe092dba54b300f4" +dependencies = [ + "critical-section", +] + +[[package]] +name = "attohttpc" +version = "0.16.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fdb8867f378f33f78a811a8eb9bf108ad99430d7aad43315dd9319c827ef6247" +dependencies = [ + "http", + "log", + "url", + "wildmatch", +] + +[[package]] +name = "aurora-engine-modexp" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bfacad86e9e138fca0670949eb8ed4ffdf73a55bded8887efe0863cd1a3a6f70" +dependencies = [ + "hex", + "num", +] + +[[package]] +name = "auto_impl" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fee3da8ef1276b0bee5dd1c7258010d8fffd31801447323115a25560e1327b89" +dependencies = [ + "proc-macro-error", + "proc-macro2", + "quote", + "syn 1.0.109", +] + +[[package]] +name = "autocfg" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" + +[[package]] +name = "backon" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0c1a6197b2120bb2185a267f6515038558b019e92b832bb0320e96d66268dcf9" +dependencies = [ + "fastrand 1.9.0", + "futures-core", + "pin-project", + "tokio", +] + +[[package]] +name = "backtrace" +version = "0.3.69" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2089b7e3f35b9dd2d0ed921ead4f6d318c27680d4a5bd167b3ee120edb105837" +dependencies = [ + "addr2line", + "cc", + "cfg-if", + "libc", + "miniz_oxide", + "object", + "rustc-demangle", +] + +[[package]] +name = "base16ct" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4c7f02d4ea65f2c1853089ffd8d2787bdbc63de2f0d29dedbcf8ccdfa0ccd4cf" + +[[package]] +name = "base64" +version = "0.13.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9e1b586273c5702936fe7b7d6896644d8be71e6314cfe09d3167c95f712589e8" + +[[package]] +name = "base64" +version = "0.21.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "35636a1494ede3b646cc98f74f8e62c773a38a659ebc777a2cf26b9b74171df9" + +[[package]] +name = "base64ct" +version = "1.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8c3c1a368f70d6cf7302d78f8f7093da241fb8e8807c05cc9e51a125895a6d5b" + +[[package]] +name = "beef" +version = "0.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3a8241f3ebb85c056b509d4327ad0358fbbba6ffb340bf388f26350aeda225b1" +dependencies = [ + "serde", +] + +[[package]] +name = "bincode" +version = "1.3.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b1f45e9417d87227c7a56d22e471c6206462cba514c7590c09aff4cf6d1ddcad" +dependencies = [ + "serde", +] + +[[package]] +name = "bindgen" +version = "0.64.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c4243e6031260db77ede97ad86c27e501d646a27ab57b59a574f725d98ab1fb4" +dependencies = [ + "bitflags 1.3.2", + "cexpr", + "clang-sys", + "lazy_static", + "lazycell", + "peeking_take_while", + "proc-macro2", + "quote", + "regex", + "rustc-hash", + "shlex", + "syn 1.0.109", +] + +[[package]] +name = "bindgen" +version = "0.66.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f2b84e06fc203107bfbad243f4aba2af864eb7db3b1cf46ea0a023b0b433d2a7" +dependencies = [ + "bitflags 2.4.1", + "cexpr", + "clang-sys", + "lazy_static", + "lazycell", + "log", + "peeking_take_while", + "prettyplease", + "proc-macro2", + "quote", + "regex", + "rustc-hash", + "shlex", + "syn 2.0.38", + "which", +] + +[[package]] +name = "bindgen" +version = "0.68.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "726e4313eb6ec35d2730258ad4e15b547ee75d6afaa1361a922e78e59b7d8078" +dependencies = [ + "bitflags 2.4.1", + "cexpr", + "clang-sys", + "lazy_static", + "lazycell", + "peeking_take_while", + "proc-macro2", + "quote", + "regex", + "rustc-hash", + "shlex", + "syn 2.0.38", +] + +[[package]] +name = "binout" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "288c7b1c00556959bb7dc822d8adad4a30edd0d3a1fcc6839515792b8f300e5f" + +[[package]] +name = "bit-set" +version = "0.5.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0700ddab506f33b20a03b13996eccd309a48e5ff77d0d95926aa0210fb4e95f1" +dependencies = [ + "bit-vec", +] + +[[package]] +name = "bit-vec" +version = "0.6.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "349f9b6a179ed607305526ca489b34ad0a41aed5f7980fa90eb03160b69598fb" + +[[package]] +name = "bitflags" +version = "1.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" + +[[package]] +name = "bitflags" +version = "2.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "327762f6e5a765692301e5bb513e0d9fef63be86bbc14528052b1cd3e6f03e07" +dependencies = [ + "arbitrary", + "serde", +] + +[[package]] +name = "bitm" +version = "0.2.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7becd9fb525c1c507eb025ec37129a0d9320aee17c841085a48101f4f18c0d27" +dependencies = [ + "dyn_size_of", +] + +[[package]] +name = "bitvec" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1bc2832c24239b0141d5674bb9174f9d68a8b5b3f2753311927c172ca46f7e9c" +dependencies = [ + "funty", + "radium", + "serde", + "tap", + "wyz", +] + +[[package]] +name = "block-buffer" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4152116fd6e9dadb291ae18fc1ec3575ed6d84c29642d97890f4b4a3417297e4" +dependencies = [ + "generic-array", +] + +[[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 = "block-padding" +version = "0.3.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a8894febbff9f758034a5b8e12d87918f56dfc64a8e1fe757d65e29041538d93" +dependencies = [ + "generic-array", +] + +[[package]] +name = "blst" +version = "0.3.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c94087b935a822949d3291a9989ad2b2051ea141eda0fd4e478a75f6aa3e604b" +dependencies = [ + "cc", + "glob", + "threadpool", + "zeroize", +] + +[[package]] +name = "boa_ast" +version = "0.17.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "73498e9b2f0aa7db74977afa4d594657611e90587abf0dd564c0b55b4a130163" +dependencies = [ + "bitflags 2.4.1", + "boa_interner", + "boa_macros", + "indexmap 2.0.2", + "num-bigint", + "rustc-hash", +] + +[[package]] +name = "boa_engine" +version = "0.17.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "16377479d5d6d33896e7acdd1cc698d04a8f72004025bbbddf47558cd29146a6" +dependencies = [ + "bitflags 2.4.1", + "boa_ast", + "boa_gc", + "boa_icu_provider", + "boa_interner", + "boa_macros", + "boa_parser", + "boa_profiler", + "chrono", + "dashmap", + "fast-float", + "icu_normalizer", + "indexmap 2.0.2", + "itertools 0.11.0", + "num-bigint", + "num-integer", + "num-traits", + "num_enum 0.6.1", + "once_cell", + "pollster", + "rand 0.8.5", + "regress", + "rustc-hash", + "ryu-js", + "serde", + "serde_json", + "sptr", + "static_assertions", + "tap", + "thin-vec", + "thiserror", +] + +[[package]] +name = "boa_gc" +version = "0.17.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c97b44beaef9d4452342d117d94607fdfa8d474280f1ba0fd97853834e3a49b2" +dependencies = [ + "boa_macros", + "boa_profiler", + "thin-vec", +] + +[[package]] +name = "boa_icu_provider" +version = "0.17.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b30e52e34e451dd0bfc2c654a9a43ed34b0073dbd4ae3394b40313edda8627aa" +dependencies = [ + "icu_collections", + "icu_normalizer", + "icu_properties", + "icu_provider", + "icu_provider_adapters", + "icu_provider_blob", + "once_cell", +] + +[[package]] +name = "boa_interner" +version = "0.17.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f3e5afa991908cfbe79bd3109b824e473a1dc5f74f31fab91bb44c9e245daa77" +dependencies = [ + "boa_gc", + "boa_macros", + "hashbrown 0.14.2", + "indexmap 2.0.2", + "once_cell", + "phf", + "rustc-hash", + "static_assertions", +] + +[[package]] +name = "boa_macros" +version = "0.17.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "005fa0c5bd20805466dda55eb34cd709bb31a2592bb26927b47714eeed6914d8" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.38", + "synstructure", +] + +[[package]] +name = "boa_parser" +version = "0.17.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9e09afb035377a9044443b598187a7d34cd13164617182a4d7c348522ee3f052" +dependencies = [ + "bitflags 2.4.1", + "boa_ast", + "boa_icu_provider", + "boa_interner", + "boa_macros", + "boa_profiler", + "fast-float", + "icu_locid", + "icu_properties", + "icu_provider", + "icu_provider_macros", + "num-bigint", + "num-traits", + "once_cell", + "regress", + "rustc-hash", + "tinystr", +] + +[[package]] +name = "boa_profiler" +version = "0.17.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3190f92dfe48224adc92881c620f08ccf37ff62b91a094bb357fe53bd5e84647" + +[[package]] +name = "boyer-moore-magiclen" +version = "0.2.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "116d76fee857b03ecdd95d5f9555e46aa0cd34e5bb348a520e9445d151182a7e" +dependencies = [ + "debug-helper", +] + +[[package]] +name = "brotli" +version = "3.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "516074a47ef4bce09577a3b379392300159ce5b1ba2e501ff1c819950066100f" +dependencies = [ + "alloc-no-stdlib", + "alloc-stdlib", + "brotli-decompressor", +] + +[[package]] +name = "brotli-decompressor" +version = "2.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "da74e2b81409b1b743f8f0c62cc6254afefb8b8e50bbfe3735550f7aeefa3448" +dependencies = [ + "alloc-no-stdlib", + "alloc-stdlib", +] + +[[package]] +name = "bumpalo" +version = "3.14.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7f30e7476521f6f8af1a1c4c0b8cc94f0bee37d91763d0ca2665f299b6cd8aec" + +[[package]] +name = "byte-slice-cast" +version = "1.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c3ac9f8b63eca6fd385229b3675f6cc0dc5c8a5c8a54a59d4f52ffd670d87b0c" + +[[package]] +name = "byteorder" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b" + +[[package]] +name = "bytes" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a2bd12c1caf447e69cd4528f47f94d203fd2582878ecb9e9465484c4148a8223" +dependencies = [ + "serde", +] + +[[package]] +name = "c-kzg" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ac926d808fb72fe09ebf471a091d6d72918876ccf0b4989766093d2d0d24a0ef" +dependencies = [ + "bindgen 0.66.1", + "blst", + "cc", + "glob", + "hex", + "libc", + "serde", +] + +[[package]] +name = "cassowary" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "df8670b8c7b9dae1793364eafadf7239c40d669904660c5960d74cfd80b46a53" + +[[package]] +name = "cc" +version = "1.0.83" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f1174fb0b6ec23863f8b971027804a42614e347eafb0a95bf0b12cdae21fc4d0" +dependencies = [ + "jobserver", + "libc", +] + +[[package]] +name = "cexpr" +version = "0.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6fac387a98bb7c37292057cffc56d62ecb629900026402633ae9160df93a8766" +dependencies = [ + "nom", +] + +[[package]] +name = "cfg-if" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" + +[[package]] +name = "chrono" +version = "0.4.31" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7f2c685bad3eb3d45a01354cedb7d5faa66194d1d58ba6e267a8de788f79db38" +dependencies = [ + "android-tzdata", + "iana-time-zone", + "js-sys", + "num-traits", + "serde", + "wasm-bindgen", + "windows-targets 0.48.5", +] + +[[package]] +name = "cipher" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7ee52072ec15386f770805afd189a01c8841be8696bed250fa2f13c4c0d6dfb7" +dependencies = [ + "generic-array", +] + +[[package]] +name = "cipher" +version = "0.4.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "773f3b9af64447d2ce9850330c473515014aa235e6a783b02db81ff39e4a3dad" +dependencies = [ + "crypto-common", + "inout", +] + +[[package]] +name = "clang-sys" +version = "1.6.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c688fc74432808e3eb684cae8830a86be1d66a2bd58e1f248ed0960a590baf6f" +dependencies = [ + "glob", + "libc", + "libloading", +] + +[[package]] +name = "clap" +version = "4.4.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ac495e00dcec98c83465d5ad66c5c4fabd652fd6686e7c6269b117e729a6f17b" +dependencies = [ + "clap_builder", + "clap_derive", +] + +[[package]] +name = "clap_builder" +version = "4.4.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c77ed9a32a62e6ca27175d00d29d05ca32e396ea1eb5fb01d8256b669cec7663" +dependencies = [ + "anstream", + "anstyle", + "clap_lex", + "strsim 0.10.0", +] + +[[package]] +name = "clap_derive" +version = "4.4.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf9804afaaf59a91e75b022a30fb7229a7901f60c755489cc61c9b423b836442" +dependencies = [ + "heck", + "proc-macro2", + "quote", + "syn 2.0.38", +] + +[[package]] +name = "clap_lex" +version = "0.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "702fc72eb24e5a1e48ce58027a675bc24edd52096d5397d4aea7c6dd9eca0bd1" + +[[package]] +name = "cobs" +version = "0.2.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "67ba02a97a2bd10f4b59b25c7973101c79642302776489e030cd13cdab09ed15" + +[[package]] +name = "codecs-derive" +version = "0.1.0-alpha.10" +source = "git+https://github.com/paradigmxyz/reth.git#fc4fc936807870b07acb91e1d50c3920b55ff055" +dependencies = [ + "convert_case 0.6.0", + "parity-scale-codec", + "proc-macro2", + "quote", + "serde", + "syn 2.0.38", +] + +[[package]] +name = "colorchoice" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "acbf1af155f9b9ef647e42cdc158db4b64a1b61f743629225fde6f3e0be2a7c7" + +[[package]] +name = "comfy-table" +version = "7.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7c64043d6c7b7a4c58e39e7efccfdea7b93d885a795d0c054a69dbbf4dd52686" +dependencies = [ + "crossterm 0.27.0", + "strum", + "strum_macros", + "unicode-width", +] + +[[package]] +name = "confy" +version = "0.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e37668cb35145dcfaa1931a5f37fde375eeae8068b4c0d2f289da28a270b2d2c" +dependencies = [ + "directories", + "serde", + "thiserror", + "toml 0.5.11", +] + +[[package]] +name = "const-hex" +version = "1.9.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c37be52ef5e3b394db27a2341010685ad5103c72ac15ce2e9420a7e8f93f342c" +dependencies = [ + "cfg-if", + "cpufeatures", + "hex", + "serde", +] + +[[package]] +name = "const-oid" +version = "0.9.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "28c122c3980598d243d63d9a704629a2d748d101f278052ff068be5a4423ab6f" + +[[package]] +name = "const-str" +version = "0.5.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "aca749d3d3f5b87a0d6100509879f9cf486ab510803a4a4e1001da1ff61c2bd6" + +[[package]] +name = "convert_case" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6245d59a3e82a7fc217c5828a6692dbc6dfb63a0c8c90495621f7b9d79704a0e" + +[[package]] +name = "convert_case" +version = "0.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ec182b0ca2f35d8fc196cf3404988fd8b8c739a4d270ff118a398feb0cbec1ca" +dependencies = [ + "unicode-segmentation", +] + +[[package]] +name = "core-foundation" +version = "0.9.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "194a7a9e6de53fa55116934067c844d9d749312f75c6f6d0980e8c252f8c2146" +dependencies = [ + "core-foundation-sys", + "libc", +] + +[[package]] +name = "core-foundation-sys" +version = "0.8.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e496a50fda8aacccc86d7529e2c1e0892dbd0f898a6b5645b5561b89c3210efa" + +[[package]] +name = "cpufeatures" +version = "0.2.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ce420fe07aecd3e67c5f910618fe65e94158f6dcc0adf44e00d69ce2bdfe0fd0" +dependencies = [ + "libc", +] + +[[package]] +name = "crc" +version = "3.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "86ec7a15cbe22e59248fc7eadb1907dab5ba09372595da4d73dd805ed4417dfe" +dependencies = [ + "crc-catalog", +] + +[[package]] +name = "crc-catalog" +version = "2.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9cace84e55f07e7301bae1c519df89cdad8cc3cd868413d3fdbdeca9ff3db484" + +[[package]] +name = "crc32fast" +version = "1.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b540bd8bc810d3885c6ea91e2018302f68baba2129ab3e88f32389ee9370880d" +dependencies = [ + "cfg-if", +] + +[[package]] +name = "critical-section" +version = "1.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7059fff8937831a9ae6f0fe4d658ffabf58f2ca96aa9dec1c889f936f705f216" + +[[package]] +name = "crossbeam-channel" +version = "0.5.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a33c2bf77f2df06183c3aa30d1e96c0695a313d4f9c453cc3762a6db39f99200" +dependencies = [ + "cfg-if", + "crossbeam-utils", +] + +[[package]] +name = "crossbeam-deque" +version = "0.8.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ce6fd6f855243022dcecf8702fef0c297d4338e226845fe067f6341ad9fa0cef" +dependencies = [ + "cfg-if", + "crossbeam-epoch", + "crossbeam-utils", +] + +[[package]] +name = "crossbeam-epoch" +version = "0.9.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ae211234986c545741a7dc064309f67ee1e5ad243d0e48335adc0484d960bcc7" +dependencies = [ + "autocfg", + "cfg-if", + "crossbeam-utils", + "memoffset", + "scopeguard", +] + +[[package]] +name = "crossbeam-utils" +version = "0.8.16" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5a22b2d63d4d1dc0b7f1b6b2747dd0088008a9be28b6ddf0b1e7d335e3037294" +dependencies = [ + "cfg-if", +] + +[[package]] +name = "crossterm" +version = "0.25.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e64e6c0fbe2c17357405f7c758c1ef960fce08bdfb2c03d88d2a18d7e09c4b67" +dependencies = [ + "bitflags 1.3.2", + "crossterm_winapi", + "libc", + "mio", + "parking_lot 0.12.1", + "signal-hook", + "signal-hook-mio", + "winapi", +] + +[[package]] +name = "crossterm" +version = "0.27.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f476fe445d41c9e991fd07515a6f463074b782242ccf4a5b7b1d1012e70824df" +dependencies = [ + "bitflags 2.4.1", + "crossterm_winapi", + "libc", + "mio", + "parking_lot 0.12.1", + "signal-hook", + "signal-hook-mio", + "winapi", +] + +[[package]] +name = "crossterm_winapi" +version = "0.9.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "acdd7c62a3665c7f6830a51635d9ac9b23ed385797f70a83bb8bafe9c572ab2b" +dependencies = [ + "winapi", +] + +[[package]] +name = "crunchy" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7a81dae078cea95a014a339291cec439d2f232ebe854a9d672b796c6afafa9b7" + +[[package]] +name = "crypto-bigint" +version = "0.5.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "740fe28e594155f10cfc383984cbefd529d7396050557148f79cb0f621204124" +dependencies = [ + "generic-array", + "rand_core 0.6.4", + "subtle", + "zeroize", +] + +[[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 = "ctr" +version = "0.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a232f92a03f37dd7d7dd2adc67166c77e9cd88de5b019b9a9eecfaeaf7bfd481" +dependencies = [ + "cipher 0.3.0", +] + +[[package]] +name = "ctr" +version = "0.8.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "049bb91fb4aaf0e3c7efa6cd5ef877dbbbd15b39dad06d9948de4ec8a75761ea" +dependencies = [ + "cipher 0.3.0", +] + +[[package]] +name = "ctr" +version = "0.9.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0369ee1ad671834580515889b80f2ea915f23b8be8d0daa4bbaf2ac5c7590835" +dependencies = [ + "cipher 0.4.4", +] + +[[package]] +name = "cuckoofilter" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b810a8449931679f64cd7eef1bbd0fa315801b6d5d9cdc1ace2804d6529eee18" +dependencies = [ + "byteorder", + "fnv", + "rand 0.7.3", + "serde", + "serde_bytes", + "serde_derive", +] + +[[package]] +name = "curve25519-dalek" +version = "4.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e89b8c6a2e4b1f45971ad09761aafb85514a84744b67a95e32c3cc1352d1f65c" +dependencies = [ + "cfg-if", + "cpufeatures", + "curve25519-dalek-derive", + "digest 0.10.7", + "fiat-crypto", + "platforms", + "rustc_version 0.4.0", + "subtle", + "zeroize", +] + +[[package]] +name = "curve25519-dalek-derive" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "83fdaf97f4804dcebfa5862639bc9ce4121e82140bec2a987ac5140294865b5b" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.38", +] + +[[package]] +name = "darling" +version = "0.10.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0d706e75d87e35569db781a9b5e2416cff1236a47ed380831f959382ccd5f858" +dependencies = [ + "darling_core 0.10.2", + "darling_macro 0.10.2", +] + +[[package]] +name = "darling" +version = "0.20.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0209d94da627ab5605dcccf08bb18afa5009cfbef48d8a8b7d7bdbc79be25c5e" +dependencies = [ + "darling_core 0.20.3", + "darling_macro 0.20.3", +] + +[[package]] +name = "darling_core" +version = "0.10.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f0c960ae2da4de88a91b2d920c2a7233b400bc33cb28453a2987822d8392519b" +dependencies = [ + "fnv", + "ident_case", + "proc-macro2", + "quote", + "strsim 0.9.3", + "syn 1.0.109", +] + +[[package]] +name = "darling_core" +version = "0.20.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "177e3443818124b357d8e76f53be906d60937f0d3a90773a664fa63fa253e621" +dependencies = [ + "fnv", + "ident_case", + "proc-macro2", + "quote", + "strsim 0.10.0", + "syn 2.0.38", +] + +[[package]] +name = "darling_macro" +version = "0.10.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d9b5a2f4ac4969822c62224815d069952656cadc7084fdca9751e6d959189b72" +dependencies = [ + "darling_core 0.10.2", + "quote", + "syn 1.0.109", +] + +[[package]] +name = "darling_macro" +version = "0.20.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "836a9bbc7ad63342d6d6e7b815ccab164bc77a2d95d84bc3117a8c0d5c98e2d5" +dependencies = [ + "darling_core 0.20.3", + "quote", + "syn 2.0.38", +] + +[[package]] +name = "dashmap" +version = "5.5.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "978747c1d849a7d2ee5e8adc0159961c48fb7e5db2f06af6723b80123bb53856" +dependencies = [ + "cfg-if", + "hashbrown 0.14.2", + "lock_api", + "once_cell", + "parking_lot_core 0.9.9", +] + +[[package]] +name = "data-encoding" +version = "2.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c2e66c9d817f1720209181c316d28635c050fa304f9c79e47a520882661b7308" + +[[package]] +name = "debug-helper" +version = "0.3.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f578e8e2c440e7297e008bb5486a3a8a194775224bbc23729b0dbdfaeebf162e" + +[[package]] +name = "delay_map" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e4355c25cbf99edcb6b4a0e906f6bdc6956eda149e84455bea49696429b2f8e8" +dependencies = [ + "futures", + "tokio-util", +] + +[[package]] +name = "der" +version = "0.7.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fffa369a668c8af7dbf8b5e56c9f744fbd399949ed171606040001947de40b1c" +dependencies = [ + "const-oid", + "zeroize", +] + +[[package]] +name = "deranged" +version = "0.3.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0f32d04922c60427da6f9fef14d042d9edddef64cb9d4ce0d64d0685fbeb1fd3" +dependencies = [ + "powerfmt", + "serde", +] + +[[package]] +name = "derivative" +version = "2.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fcc3dd5e9e9c0b295d6e1e4d811fb6f157d5ffd784b8d202fc62eac8035a770b" +dependencies = [ + "proc-macro2", + "quote", + "syn 1.0.109", +] + +[[package]] +name = "derive_arbitrary" +version = "1.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "53e0efad4403bfc52dc201159c4b842a246a14b98c64b55dfd0f2d89729dfeb8" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.38", +] + +[[package]] +name = "derive_builder" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a2658621297f2cf68762a6f7dc0bb7e1ff2cfd6583daef8ee0fed6f7ec468ec0" +dependencies = [ + "darling 0.10.2", + "derive_builder_core", + "proc-macro2", + "quote", + "syn 1.0.109", +] + +[[package]] +name = "derive_builder_core" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2791ea3e372c8495c0bc2033991d76b512cd799d07491fbd6890124db9458bef" +dependencies = [ + "darling 0.10.2", + "proc-macro2", + "quote", + "syn 1.0.109", +] + +[[package]] +name = "derive_more" +version = "0.99.17" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4fb810d30a7c1953f91334de7244731fc3f3c10d7fe163338a35b9f640960321" +dependencies = [ + "convert_case 0.4.0", + "proc-macro2", + "quote", + "rustc_version 0.4.0", + "syn 1.0.109", +] + +[[package]] +name = "diff" +version = "0.1.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "56254986775e3233ffa9c4d7d3faaf6d36a2c09d30b20687e9f88bc8bafc16c8" + +[[package]] +name = "digest" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d3dd60d1080a57a05ab032377049e0591415d2b31afd7028356dbf3cc6dcb066" +dependencies = [ + "generic-array", +] + +[[package]] +name = "digest" +version = "0.10.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9ed9a281f7bc9b7576e61468ba615a66a5c8cfdff42420a70aa82701a3b1e292" +dependencies = [ + "block-buffer 0.10.4", + "const-oid", + "crypto-common", + "subtle", +] + +[[package]] +name = "directories" +version = "4.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f51c5d4ddabd36886dd3e1438cb358cdcb0d7c499cb99cb4ac2e38e18b5cb210" +dependencies = [ + "dirs-sys 0.3.7", +] + +[[package]] +name = "dirs" +version = "5.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "44c45a9d03d6676652bcb5e724c7e988de1acad23a711b5217ab9cbecbec2225" +dependencies = [ + "dirs-sys 0.4.1", +] + +[[package]] +name = "dirs-next" +version = "2.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b98cf8ebf19c3d1b223e151f99a4f9f0690dca41414773390fc824184ac833e1" +dependencies = [ + "cfg-if", + "dirs-sys-next", +] + +[[package]] +name = "dirs-sys" +version = "0.3.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1b1d1d91c932ef41c0f2663aa8b0ca0342d444d842c06914aa0a7e352d0bada6" +dependencies = [ + "libc", + "redox_users", + "winapi", +] + +[[package]] +name = "dirs-sys" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "520f05a5cbd335fae5a99ff7a6ab8627577660ee5cfd6a94a6a929b52ff0321c" +dependencies = [ + "libc", + "option-ext", + "redox_users", + "windows-sys 0.48.0", +] + +[[package]] +name = "dirs-sys-next" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4ebda144c4fe02d1f7ea1a7d9641b6fc6b580adcfa024ae48797ecdeb6825b4d" +dependencies = [ + "libc", + "redox_users", + "winapi", +] + +[[package]] +name = "discv5" +version = "0.3.1" +source = "git+https://github.com/sigp/discv5?rev=f289bbd4c57d499bb1bdb393af3c249600a1c662#f289bbd4c57d499bb1bdb393af3c249600a1c662" +dependencies = [ + "aes 0.7.5", + "aes-gcm", + "arrayvec", + "delay_map", + "enr", + "fnv", + "futures", + "hashlink", + "hex", + "hkdf", + "lazy_static", + "lru 0.12.0", + "more-asserts", + "parking_lot 0.11.2", + "rand 0.8.5", + "rlp", + "smallvec", + "socket2 0.4.10", + "tokio", + "tracing", + "tracing-subscriber", + "uint", + "zeroize", +] + +[[package]] +name = "displaydoc" +version = "0.2.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "487585f4d0c6655fe74905e2504d8ad6908e4db67f744eb140876906c2f3175d" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.38", +] + +[[package]] +name = "dns-lookup" +version = "1.0.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "53ecafc952c4528d9b51a458d1a8904b81783feff9fde08ab6ed2545ff396872" +dependencies = [ + "cfg-if", + "libc", + "socket2 0.4.10", + "winapi", +] + +[[package]] +name = "dunce" +version = "1.0.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "56ce8c6da7551ec6c462cbaf3bfbc75131ebbfa1c944aeaa9dab51ca1c5f0c3b" + +[[package]] +name = "dyn-clone" +version = "1.0.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "23d2f3407d9a573d666de4b5bdf10569d73ca9478087346697dcbae6244bfbcd" + +[[package]] +name = "dyn_size_of" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6c8adcce29eef18ae1369bbd268fd56bf98144e80281315e9d4a82e34df001c7" + +[[package]] +name = "ecdsa" +version = "0.16.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a4b1e0c257a9e9f25f90ff76d7a68360ed497ee519c8e428d1825ef0000799d4" +dependencies = [ + "der", + "digest 0.10.7", + "elliptic-curve", + "rfc6979", + "signature", + "spki", +] + +[[package]] +name = "ed25519" +version = "2.2.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "115531babc129696a58c64a4fef0a8bf9e9698629fb97e9e40767d235cfbcd53" +dependencies = [ + "pkcs8", + "signature", +] + +[[package]] +name = "ed25519-dalek" +version = "2.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7277392b266383ef8396db7fdeb1e77b6c52fed775f5df15bb24f35b72156980" +dependencies = [ + "curve25519-dalek", + "ed25519", + "rand_core 0.6.4", + "serde", + "sha2", + "zeroize", +] + +[[package]] +name = "educe" +version = "0.4.23" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0f0042ff8246a363dbe77d2ceedb073339e85a804b9a47636c6e016a9a32c05f" +dependencies = [ + "enum-ordinalize", + "proc-macro2", + "quote", + "syn 1.0.109", +] + +[[package]] +name = "either" +version = "1.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a26ae43d7bcc3b814de94796a5e736d4029efb0ee900c12e2d54c993ad1a1e07" + +[[package]] +name = "elliptic-curve" +version = "0.13.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d97ca172ae9dc9f9b779a6e3a65d308f2af74e5b8c921299075bdb4a0370e914" +dependencies = [ + "base16ct", + "crypto-bigint", + "digest 0.10.7", + "ff", + "generic-array", + "group", + "pkcs8", + "rand_core 0.6.4", + "sec1", + "subtle", + "zeroize", +] + +[[package]] +name = "embedded-io" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ef1a6892d9eef45c8fa6b9e0086428a2cca8491aca8f787c534a3d6d0bcb3ced" + +[[package]] +name = "endian-type" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c34f04666d835ff5d62e058c3995147c06f42fe86ff053337632bca83e42702d" + +[[package]] +name = "enr" +version = "0.9.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fe81b5c06ecfdbc71dd845216f225f53b62a10cb8a16c946836a3467f701d05b" +dependencies = [ + "base64 0.21.5", + "bytes", + "ed25519-dalek", + "hex", + "k256", + "log", + "rand 0.8.5", + "rlp", + "secp256k1 0.27.0", + "serde", + "sha3", + "zeroize", +] + +[[package]] +name = "enum-as-inner" +version = "0.3.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "570d109b813e904becc80d8d5da38376818a143348413f7149f1340fe04754d4" +dependencies = [ + "heck", + "proc-macro2", + "quote", + "syn 1.0.109", +] + +[[package]] +name = "enum-as-inner" +version = "0.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5ffccbb6966c05b32ef8fbac435df276c4ae4d3dc55a8cd0eb9745e6c12f546a" +dependencies = [ + "heck", + "proc-macro2", + "quote", + "syn 2.0.38", +] + +[[package]] +name = "enum-ordinalize" +version = "3.1.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1bf1fa3f06bbff1ea5b1a9c7b14aa992a39657db60a2759457328d7e058f49ee" +dependencies = [ + "num-bigint", + "num-traits", + "proc-macro2", + "quote", + "syn 2.0.38", +] + +[[package]] +name = "enumn" +version = "0.1.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c2ad8cef1d801a4686bfd8919f0b30eac4c8e48968c437a6405ded4fb5272d2b" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.38", +] + +[[package]] +name = "equivalent" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" + +[[package]] +name = "errno" +version = "0.2.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f639046355ee4f37944e44f60642c6f3a7efa3cf6b78c78a0d989a8ce6c396a1" +dependencies = [ + "errno-dragonfly", + "libc", + "winapi", +] + +[[package]] +name = "errno" +version = "0.3.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ac3e13f66a2f95e32a39eaa81f6b95d42878ca0e1db0c7543723dfe12557e860" +dependencies = [ + "libc", + "windows-sys 0.48.0", +] + +[[package]] +name = "errno-dragonfly" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "aa68f1b12764fab894d2755d2518754e71b4fd80ecfb822714a1206c2aab39bf" +dependencies = [ + "cc", + "libc", +] + +[[package]] +name = "event-listener" +version = "2.5.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0206175f82b8d6bf6652ff7d71a1e27fd2e4efde587fd368662814d6ec1d9ce0" + +[[package]] +name = "eyre" +version = "0.6.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4c2b6b5a29c02cdc822728b7d7b8ae1bab3e3b05d44522770ddd49722eeac7eb" +dependencies = [ + "indenter", + "once_cell", +] + +[[package]] +name = "fast-float" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "95765f67b4b18863968b4a1bd5bb576f732b29a4a28c7cd84c09fa3e2875f33c" + +[[package]] +name = "fastrand" +version = "1.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e51093e27b0797c359783294ca4f0a911c270184cb10f85783b118614a1501be" +dependencies = [ + "instant", +] + +[[package]] +name = "fastrand" +version = "2.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "25cbce373ec4653f1a01a31e8a5e5ec0c622dc27ff9c4e6606eefef5cbbed4a5" + +[[package]] +name = "fastrlp" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "139834ddba373bbdd213dffe02c8d110508dcf1726c2be27e8d1f7d7e1856418" +dependencies = [ + "arrayvec", + "auto_impl", + "bytes", +] + +[[package]] +name = "fdlimit" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2c4c9e43643f5a3be4ca5b67d26b98031ff9db6806c3440ae32e02e3ceac3f1b" +dependencies = [ + "libc", +] + +[[package]] +name = "ff" +version = "0.13.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ded41244b729663b1e574f1b4fb731469f69f79c17667b5d776b16cda0479449" +dependencies = [ + "rand_core 0.6.4", + "subtle", +] + +[[package]] +name = "fiat-crypto" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d0870c84016d4b481be5c9f323c24f65e31e901ae618f0e80f4308fb00de1d2d" + +[[package]] +name = "fixed-hash" +version = "0.8.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "835c052cb0c08c1acf6ffd71c022172e18723949c8282f2b9f27efbc51e64534" +dependencies = [ + "byteorder", + "rand 0.8.5", + "rustc-hex", + "static_assertions", +] + +[[package]] +name = "flate2" +version = "1.0.28" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "46303f565772937ffe1d394a4fac6f411c6013172fadde9dcdb1e147a086940e" +dependencies = [ + "crc32fast", + "miniz_oxide", +] + +[[package]] +name = "fnv" +version = "1.0.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1" + +[[package]] +name = "form_urlencoded" +version = "1.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a62bc1cf6f830c2ec14a513a9fb124d0a213a629668a4186f329db21fe045652" +dependencies = [ + "percent-encoding", +] + +[[package]] +name = "funty" +version = "2.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e6d5a32815ae3f33302d95fdcb2ce17862f8c65363dcfd29360480ba1001fc9c" + +[[package]] +name = "futures" +version = "0.3.29" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "da0290714b38af9b4a7b094b8a37086d1b4e61f2df9122c3cad2577669145335" +dependencies = [ + "futures-channel", + "futures-core", + "futures-executor", + "futures-io", + "futures-sink", + "futures-task", + "futures-util", +] + +[[package]] +name = "futures-channel" +version = "0.3.29" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ff4dd66668b557604244583e3e1e1eada8c5c2e96a6d0d6653ede395b78bbacb" +dependencies = [ + "futures-core", + "futures-sink", +] + +[[package]] +name = "futures-core" +version = "0.3.29" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "eb1d22c66e66d9d72e1758f0bd7d4fd0bee04cad842ee34587d68c07e45d088c" + +[[package]] +name = "futures-executor" +version = "0.3.29" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0f4fb8693db0cf099eadcca0efe2a5a22e4550f98ed16aba6c48700da29597bc" +dependencies = [ + "futures-core", + "futures-task", + "futures-util", +] + +[[package]] +name = "futures-io" +version = "0.3.29" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8bf34a163b5c4c52d0478a4d757da8fb65cabef42ba90515efee0f6f9fa45aaa" + +[[package]] +name = "futures-macro" +version = "0.3.29" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "53b153fd91e4b0147f4aced87be237c98248656bb01050b96bf3ee89220a8ddb" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.38", +] + +[[package]] +name = "futures-sink" +version = "0.3.29" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e36d3378ee38c2a36ad710c5d30c2911d752cb941c00c72dbabfb786a7970817" + +[[package]] +name = "futures-task" +version = "0.3.29" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "efd193069b0ddadc69c46389b740bbccdd97203899b48d09c5f7969591d6bae2" + +[[package]] +name = "futures-timer" +version = "3.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e64b03909df88034c26dc1547e8970b91f98bdb65165d6a4e9110d94263dbb2c" +dependencies = [ + "gloo-timers", + "send_wrapper", +] + +[[package]] +name = "futures-util" +version = "0.3.29" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a19526d624e703a3179b3d322efec918b6246ea0fa51d41124525f00f1cc8104" +dependencies = [ + "futures-channel", + "futures-core", + "futures-io", + "futures-macro", + "futures-sink", + "futures-task", + "memchr", + "pin-project-lite", + "pin-utils", + "slab", +] + +[[package]] +name = "generic-array" +version = "0.14.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "85649ca51fd72272d7821adaf274ad91c288277713d9c18820d8499a7ff69e9a" +dependencies = [ + "typenum", + "version_check", + "zeroize", +] + +[[package]] +name = "getrandom" +version = "0.1.16" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8fc3cb4d91f53b50155bdcfd23f6a4c39ae1969c2ae85982b135750cccaf5fce" +dependencies = [ + "cfg-if", + "libc", + "wasi 0.9.0+wasi-snapshot-preview1", +] + +[[package]] +name = "getrandom" +version = "0.2.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "be4136b2a15dd319360be1c07d9933517ccf0be8f16bf62a3bee4f0d618df427" +dependencies = [ + "cfg-if", + "libc", + "wasi 0.11.0+wasi-snapshot-preview1", +] + +[[package]] +name = "ghash" +version = "0.4.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1583cc1656d7839fd3732b80cf4f38850336cdb9b8ded1cd399ca62958de3c99" +dependencies = [ + "opaque-debug", + "polyval", +] + +[[package]] +name = "gimli" +version = "0.28.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6fb8d784f27acf97159b40fc4db5ecd8aa23b9ad5ef69cdd136d3bc80665f0c0" + +[[package]] +name = "glob" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d2fabcfbdc87f4758337ca535fb41a6d701b65693ce38287d856d1674551ec9b" + +[[package]] +name = "gloo-net" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8ac9e8288ae2c632fa9f8657ac70bfe38a1530f345282d7ba66a1f70b72b7dc4" +dependencies = [ + "futures-channel", + "futures-core", + "futures-sink", + "gloo-utils", + "http", + "js-sys", + "pin-project", + "serde", + "serde_json", + "thiserror", + "wasm-bindgen", + "wasm-bindgen-futures", + "web-sys", +] + +[[package]] +name = "gloo-timers" +version = "0.2.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9b995a66bb87bebce9a0f4a95aed01daca4872c050bfcb21653361c03bc35e5c" +dependencies = [ + "futures-channel", + "futures-core", + "js-sys", + "wasm-bindgen", +] + +[[package]] +name = "gloo-utils" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0b5555354113b18c547c1d3a98fbf7fb32a9ff4f6fa112ce823a21641a0ba3aa" +dependencies = [ + "js-sys", + "serde", + "serde_json", + "wasm-bindgen", + "web-sys", +] + +[[package]] +name = "group" +version = "0.13.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f0f9ef7462f7c099f518d754361858f86d8a07af53ba9af0fe635bbccb151a63" +dependencies = [ + "ff", + "rand_core 0.6.4", + "subtle", +] + +[[package]] +name = "h2" +version = "0.3.21" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "91fc23aa11be92976ef4729127f1a74adf36d8436f7816b185d18df956790833" +dependencies = [ + "bytes", + "fnv", + "futures-core", + "futures-sink", + "futures-util", + "http", + "indexmap 1.9.3", + "slab", + "tokio", + "tokio-util", + "tracing", +] + +[[package]] +name = "hash32" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b0c35f58762feb77d74ebe43bdbc3210f09be9fe6742234d573bacc26ed92b67" +dependencies = [ + "byteorder", +] + +[[package]] +name = "hashbrown" +version = "0.12.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8a9ee70c43aaf417c914396645a0fa852624801b24ebb7ae78fe8272889ac888" + +[[package]] +name = "hashbrown" +version = "0.13.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "43a3c133739dddd0d2990f9a4bdf8eb4b21ef50e4851ca85ab661199821d510e" +dependencies = [ + "ahash", +] + +[[package]] +name = "hashbrown" +version = "0.14.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f93e7192158dbcda357bdec5fb5788eebf8bbac027f3f33e719d29135ae84156" +dependencies = [ + "ahash", + "allocator-api2", + "serde", +] + +[[package]] +name = "hashlink" +version = "0.8.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e8094feaf31ff591f651a2664fb9cfd92bba7a60ce3197265e9482ebe753c8f7" +dependencies = [ + "hashbrown 0.14.2", +] + +[[package]] +name = "hdrhistogram" +version = "7.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7f19b9f54f7c7f55e31401bb647626ce0cf0f67b0004982ce815b3ee72a02aa8" +dependencies = [ + "byteorder", + "num-traits", +] + +[[package]] +name = "heapless" +version = "0.7.16" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "db04bc24a18b9ea980628ecf00e6c0264f3c1426dac36c00cb49b6fbad8b0743" +dependencies = [ + "atomic-polyfill 0.1.11", + "hash32", + "rustc_version 0.4.0", + "serde", + "spin 0.9.8", + "stable_deref_trait", +] + +[[package]] +name = "heck" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "95505c38b4572b2d910cecb0281560f54b440a19336cbbcb27bf6ce6adc6f5a8" + +[[package]] +name = "hermit-abi" +version = "0.3.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d77f7ec81a6d05a3abb01ab6eb7590f6083d08449fe5a1c8b1e620283546ccb7" + +[[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 = "hkdf" +version = "0.12.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "791a029f6b9fc27657f6f188ec6e5e43f6911f6f878e0dc5501396e09809d437" +dependencies = [ + "hmac", +] + +[[package]] +name = "hmac" +version = "0.12.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6c49c37c09c17a53d937dfbb742eb3a961d65a994e6bcdcf37e7399d0cc8ab5e" +dependencies = [ + "digest 0.10.7", +] + +[[package]] +name = "home" +version = "0.5.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5444c27eef6923071f7ebcc33e3444508466a76f7a2b93da00ed6e19f30c1ddb" +dependencies = [ + "windows-sys 0.48.0", +] + +[[package]] +name = "hostname" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3c731c3e10504cc8ed35cfe2f1db4c9274c3d35fa486e3b31df46f068ef3e867" +dependencies = [ + "libc", + "match_cfg", + "winapi", +] + +[[package]] +name = "http" +version = "0.2.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bd6effc99afb63425aff9b05836f029929e345a6148a14b7ecd5ab67af944482" +dependencies = [ + "bytes", + "fnv", + "itoa", +] + +[[package]] +name = "http-body" +version = "0.4.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d5f38f16d184e36f2408a55281cd658ecbd3ca05cce6d6510a176eca393e26d1" +dependencies = [ + "bytes", + "http", + "pin-project-lite", +] + +[[package]] +name = "http-range-header" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "add0ab9360ddbd88cfeb3bd9574a1d85cfdfa14db10b3e21d3700dbc4328758f" + +[[package]] +name = "httparse" +version = "1.8.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d897f394bad6a705d5f4104762e116a75639e470d80901eed05a860a95cb1904" + +[[package]] +name = "httpdate" +version = "1.0.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "df3b46402a9d5adb4c86a0cf463f42e19994e3ee891101b1841f30a545cb49a9" + +[[package]] +name = "human_bytes" +version = "0.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "91f255a4535024abf7640cb288260811fc14794f62b063652ed349f9a6c2348e" + +[[package]] +name = "humantime" +version = "2.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9a3a5bfb195931eeb336b2a7b4d761daec841b97f947d34394601737a7bba5e4" + +[[package]] +name = "humantime-serde" +version = "1.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "57a3db5ea5923d99402c94e9feb261dc5ee9b4efa158b0315f788cf549cc200c" +dependencies = [ + "humantime", + "serde", +] + +[[package]] +name = "hyper" +version = "0.14.27" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ffb1cfd654a8219eaef89881fdb3bb3b1cdc5fa75ded05d6933b2b382e395468" +dependencies = [ + "bytes", + "futures-channel", + "futures-core", + "futures-util", + "h2", + "http", + "http-body", + "httparse", + "httpdate", + "itoa", + "pin-project-lite", + "socket2 0.4.10", + "tokio", + "tower-service", + "tracing", + "want", +] + +[[package]] +name = "hyper-rustls" +version = "0.24.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ec3efd23720e2049821a693cbc7e65ea87c72f1c58ff2f9522ff332b1491e590" +dependencies = [ + "futures-util", + "http", + "hyper", + "log", + "rustls", + "rustls-native-certs", + "tokio", + "tokio-rustls", +] + +[[package]] +name = "hyper-system-resolver" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6eea26c5d0b6ab9d72219f65000af310f042a740926f7b2fa3553e774036e2e7" +dependencies = [ + "derive_builder", + "dns-lookup", + "hyper", + "tokio", + "tower-service", + "tracing", +] + +[[package]] +name = "iana-time-zone" +version = "0.1.58" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8326b86b6cff230b97d0d312a6c40a60726df3332e721f72a1b035f451663b20" +dependencies = [ + "android_system_properties", + "core-foundation-sys", + "iana-time-zone-haiku", + "js-sys", + "wasm-bindgen", + "windows-core", +] + +[[package]] +name = "iana-time-zone-haiku" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f31827a206f56af32e590ba56d5d2d085f558508192593743f16b2306495269f" +dependencies = [ + "cc", +] + +[[package]] +name = "icu_collections" +version = "1.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ef8302d8dfd6044d3ddb3f807a5ef3d7bbca9a574959c6d6e4dc39aa7012d0d5" +dependencies = [ + "displaydoc", + "serde", + "yoke", + "zerofrom", + "zerovec", +] + +[[package]] +name = "icu_locid" +version = "1.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3003f85dccfc0e238ff567693248c59153a46f4e6125ba4020b973cef4d1d335" +dependencies = [ + "displaydoc", + "litemap", + "serde", + "tinystr", + "writeable", + "zerovec", +] + +[[package]] +name = "icu_normalizer" +version = "1.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "652869735c9fb9f5a64ba180ee16f2c848390469c116deef517ecc53f4343598" +dependencies = [ + "displaydoc", + "icu_collections", + "icu_properties", + "icu_provider", + "serde", + "smallvec", + "utf16_iter", + "utf8_iter", + "write16", + "zerovec", +] + +[[package]] +name = "icu_properties" +version = "1.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ce0e1aa26851f16c9e04412a5911c86b7f8768dac8f8d4c5f1c568a7e5d7a434" +dependencies = [ + "displaydoc", + "icu_collections", + "icu_provider", + "serde", + "tinystr", + "zerovec", +] + +[[package]] +name = "icu_provider" +version = "1.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8dc312a7b6148f7dfe098047ae2494d12d4034f48ade58d4f353000db376e305" +dependencies = [ + "displaydoc", + "icu_locid", + "icu_provider_macros", + "postcard", + "serde", + "stable_deref_trait", + "writeable", + "yoke", + "zerofrom", + "zerovec", +] + +[[package]] +name = "icu_provider_adapters" +version = "1.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f4ae1e2bd0c41728b77e7c46e9afdec5e2127d1eedacc684724667d50c126bd3" +dependencies = [ + "icu_locid", + "icu_provider", + "serde", + "tinystr", + "yoke", + "zerovec", +] + +[[package]] +name = "icu_provider_blob" +version = "1.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fd364c9a01f791a4bc04a74cf2a1d01d9f6926a40fd5ae1c28004e1e70d8338b" +dependencies = [ + "icu_provider", + "postcard", + "serde", + "writeable", + "yoke", + "zerovec", +] + +[[package]] +name = "icu_provider_macros" +version = "1.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dd8b728b9421e93eff1d9f8681101b78fa745e0748c95c655c83f337044a7e10" +dependencies = [ + "proc-macro2", + "quote", + "syn 1.0.109", +] + +[[package]] +name = "ident_case" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b9e0384b61958566e926dc50660321d12159025e767c18e043daf26b70104c39" + +[[package]] +name = "idna" +version = "0.2.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "418a0a6fab821475f634efe3ccc45c013f742efe03d853e8d3355d5cb850ecf8" +dependencies = [ + "matches", + "unicode-bidi", + "unicode-normalization", +] + +[[package]] +name = "idna" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7d20d6b07bfbc108882d88ed8e37d39636dcc260e15e30c45e6ba089610b917c" +dependencies = [ + "unicode-bidi", + "unicode-normalization", +] + +[[package]] +name = "igd" +version = "0.12.0" +source = "git+https://github.com/stevefan1999-personal/rust-igd?rev=c2d1f83eb1612a462962453cb0703bc93258b173#c2d1f83eb1612a462962453cb0703bc93258b173" +dependencies = [ + "attohttpc", + "bytes", + "futures", + "http", + "hyper", + "log", + "rand 0.8.5", + "tokio", + "url", + "xmltree", +] + +[[package]] +name = "impl-codec" +version = "0.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ba6a270039626615617f3f36d15fc827041df3b78c439da2cadfa47455a77f2f" +dependencies = [ + "parity-scale-codec", +] + +[[package]] +name = "impl-trait-for-tuples" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "11d7a9f6330b71fea57921c9b61c47ee6e84f72d394754eff6163ae67e7395eb" +dependencies = [ + "proc-macro2", + "quote", + "syn 1.0.109", +] + +[[package]] +name = "include_dir" +version = "0.7.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "18762faeff7122e89e0857b02f7ce6fcc0d101d5e9ad2ad7846cc01d61b7f19e" +dependencies = [ + "include_dir_macros", +] + +[[package]] +name = "include_dir_macros" +version = "0.7.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b139284b5cf57ecfa712bcc66950bb635b31aff41c188e8a4cfc758eca374a3f" +dependencies = [ + "proc-macro2", + "quote", +] + +[[package]] +name = "indenter" +version = "0.3.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ce23b50ad8242c51a442f3ff322d56b02f08852c77e4c0b4d3fd684abc89c683" + +[[package]] +name = "indexmap" +version = "1.9.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bd070e393353796e801d209ad339e89596eb4c8d430d18ede6a1cced8fafbd99" +dependencies = [ + "autocfg", + "hashbrown 0.12.3", + "serde", +] + +[[package]] +name = "indexmap" +version = "2.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8adf3ddd720272c6ea8bf59463c04e0f93d0bbf7c5439b691bca2987e0270897" +dependencies = [ + "equivalent", + "hashbrown 0.14.2", + "serde", +] + +[[package]] +name = "inout" +version = "0.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a0c10553d664a4d0bcff9f4215d0aac67a639cc68ef660840afe309b807bc9f5" +dependencies = [ + "block-padding", + "generic-array", +] + +[[package]] +name = "instant" +version = "0.1.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7a5bbe824c507c5da5956355e86a746d82e0e1464f65d862cc5e71da70e94b2c" +dependencies = [ + "cfg-if", +] + +[[package]] +name = "io-lifetimes" +version = "1.0.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "eae7b9aee968036d54dce06cebaefd919e4472e753296daccd6d344e3e2df0c2" +dependencies = [ + "hermit-abi", + "libc", + "windows-sys 0.48.0", +] + +[[package]] +name = "ipconfig" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b58db92f96b720de98181bbbe63c831e87005ab460c1bf306eb2622b4707997f" +dependencies = [ + "socket2 0.5.5", + "widestring", + "windows-sys 0.48.0", + "winreg", +] + +[[package]] +name = "ipnet" +version = "2.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8f518f335dce6725a761382244631d86cf0ccb2863413590b31338feb467f9c3" + +[[package]] +name = "iri-string" +version = "0.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "21859b667d66a4c1dacd9df0863b3efb65785474255face87f5bca39dd8407c0" +dependencies = [ + "memchr", + "serde", +] + +[[package]] +name = "itertools" +version = "0.10.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b0fd2260e829bddf4cb6ea802289de2f86d6a7a690192fbe91b3f46e0f2c8473" +dependencies = [ + "either", +] + +[[package]] +name = "itertools" +version = "0.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b1c173a5686ce8bfa551b3563d0c2170bf24ca44da99c7ca4bfdab5418c3fe57" +dependencies = [ + "either", +] + +[[package]] +name = "itoa" +version = "1.0.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "af150ab688ff2122fcef229be89cb50dd66af9e01a4ff320cc137eecc9bacc38" + +[[package]] +name = "jemalloc-ctl" +version = "0.5.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7cffc705424a344c054e135d12ee591402f4539245e8bbd64e6c9eaa9458b63c" +dependencies = [ + "jemalloc-sys", + "libc", + "paste", +] + +[[package]] +name = "jemalloc-sys" +version = "0.5.4+5.3.0-patched" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ac6c1946e1cea1788cbfde01c993b52a10e2da07f4bac608228d1bed20bfebf2" +dependencies = [ + "cc", + "libc", +] + +[[package]] +name = "jemallocator" +version = "0.5.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a0de374a9f8e63150e6f5e8a60cc14c668226d7a347d8aee1a45766e3c4dd3bc" +dependencies = [ + "jemalloc-sys", + "libc", +] + +[[package]] +name = "jobserver" +version = "0.1.27" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8c37f63953c4c63420ed5fd3d6d398c719489b9f872b9fa683262f8edd363c7d" +dependencies = [ + "libc", +] + +[[package]] +name = "js-sys" +version = "0.3.64" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c5f195fe497f702db0f318b07fdd68edb16955aed830df8363d837542f8f935a" +dependencies = [ + "wasm-bindgen", +] + +[[package]] +name = "jsonrpsee" +version = "0.20.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "affdc52f7596ccb2d7645231fc6163bb314630c989b64998f3699a28b4d5d4dc" +dependencies = [ + "jsonrpsee-client-transport", + "jsonrpsee-core", + "jsonrpsee-http-client", + "jsonrpsee-proc-macros", + "jsonrpsee-server", + "jsonrpsee-types", + "jsonrpsee-wasm-client", + "jsonrpsee-ws-client", + "tokio", + "tracing", +] + +[[package]] +name = "jsonrpsee-client-transport" +version = "0.20.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b5b005c793122d03217da09af68ba9383363caa950b90d3436106df8cabce935" +dependencies = [ + "futures-channel", + "futures-util", + "gloo-net", + "http", + "jsonrpsee-core", + "pin-project", + "rustls-native-certs", + "soketto", + "thiserror", + "tokio", + "tokio-rustls", + "tokio-util", + "tracing", + "url", + "webpki-roots", +] + +[[package]] +name = "jsonrpsee-core" +version = "0.20.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "da2327ba8df2fdbd5e897e2b5ed25ce7f299d345b9736b6828814c3dbd1fd47b" +dependencies = [ + "anyhow", + "async-lock", + "async-trait", + "beef", + "futures-timer", + "futures-util", + "hyper", + "jsonrpsee-types", + "parking_lot 0.12.1", + "rand 0.8.5", + "rustc-hash", + "serde", + "serde_json", + "soketto", + "thiserror", + "tokio", + "tracing", + "wasm-bindgen-futures", +] + +[[package]] +name = "jsonrpsee-http-client" +version = "0.20.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5f80c17f62c7653ce767e3d7288b793dfec920f97067ceb189ebdd3570f2bc20" +dependencies = [ + "async-trait", + "hyper", + "hyper-rustls", + "jsonrpsee-core", + "jsonrpsee-types", + "serde", + "serde_json", + "thiserror", + "tokio", + "tower", + "tracing", + "url", +] + +[[package]] +name = "jsonrpsee-proc-macros" +version = "0.20.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "29110019693a4fa2dbda04876499d098fa16d70eba06b1e6e2b3f1b251419515" +dependencies = [ + "heck", + "proc-macro-crate", + "proc-macro2", + "quote", + "syn 1.0.109", +] + +[[package]] +name = "jsonrpsee-server" +version = "0.20.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "82c39a00449c9ef3f50b84fc00fc4acba20ef8f559f07902244abf4c15c5ab9c" +dependencies = [ + "futures-util", + "http", + "hyper", + "jsonrpsee-core", + "jsonrpsee-types", + "route-recognizer", + "serde", + "serde_json", + "soketto", + "thiserror", + "tokio", + "tokio-stream", + "tokio-util", + "tower", + "tracing", +] + +[[package]] +name = "jsonrpsee-types" +version = "0.20.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5be0be325642e850ed0bdff426674d2e66b2b7117c9be23a7caef68a2902b7d9" +dependencies = [ + "anyhow", + "beef", + "serde", + "serde_json", + "thiserror", + "tracing", +] + +[[package]] +name = "jsonrpsee-wasm-client" +version = "0.20.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7c7cbb3447cf14fd4d2f407c3cc96e6c9634d5440aa1fbed868a31f3c02b27f0" +dependencies = [ + "jsonrpsee-client-transport", + "jsonrpsee-core", + "jsonrpsee-types", +] + +[[package]] +name = "jsonrpsee-ws-client" +version = "0.20.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bca9cb3933ccae417eb6b08c3448eb1cb46e39834e5b503e395e5e5bd08546c0" +dependencies = [ + "http", + "jsonrpsee-client-transport", + "jsonrpsee-core", + "jsonrpsee-types", + "url", +] + +[[package]] +name = "jsonwebtoken" +version = "8.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6971da4d9c3aa03c3d8f3ff0f4155b534aad021292003895a469716b2a230378" +dependencies = [ + "base64 0.21.5", + "pem", + "ring 0.16.20", + "serde", + "serde_json", + "simple_asn1", +] + +[[package]] +name = "k256" +version = "0.13.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cadb76004ed8e97623117f3df85b17aaa6626ab0b0831e6573f104df16cd1bcc" +dependencies = [ + "cfg-if", + "ecdsa", + "elliptic-curve", + "once_cell", + "sha2", + "signature", +] + +[[package]] +name = "keccak" +version = "0.1.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8f6d5ed8676d904364de097082f4e7d240b571b67989ced0240f08b7f966f940" +dependencies = [ + "cpufeatures", +] + +[[package]] +name = "lazy_static" +version = "1.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e2abad23fbc42b3700f2f279844dc832adb2b2eb069b2df918f455c4e18cc646" +dependencies = [ + "spin 0.5.2", +] + +[[package]] +name = "lazycell" +version = "1.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "830d08ce1d1d941e6b30645f1a0eb5643013d835ce3779a5fc208261dbe10f55" + +[[package]] +name = "libc" +version = "0.2.149" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a08173bc88b7955d1b3145aa561539096c421ac8debde8cbc3612ec635fee29b" + +[[package]] +name = "libloading" +version = "0.7.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b67380fd3b2fbe7527a606e18729d21c6f3951633d0500574c4dc22d2d638b9f" +dependencies = [ + "cfg-if", + "winapi", +] + +[[package]] +name = "libm" +version = "0.2.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4ec2a862134d2a7d32d7983ddcdd1c4923530833c9f2ea1a44fc5fa473989058" + +[[package]] +name = "libproc" +version = "0.13.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8b18cbf29f8ff3542ba22bdce9ac610fcb75d74bb4e2b306b2a2762242025b4f" +dependencies = [ + "bindgen 0.64.0", + "errno 0.2.8", + "libc", +] + +[[package]] +name = "linked-hash-map" +version = "0.5.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0717cef1bc8b636c6e1c1bbdefc09e6322da8a9321966e8928ef80d20f7f770f" + +[[package]] +name = "linked_hash_set" +version = "0.1.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "47186c6da4d81ca383c7c47c1bfc80f4b95f4720514d860a5407aaf4233f9588" +dependencies = [ + "linked-hash-map", +] + +[[package]] +name = "linux-raw-sys" +version = "0.1.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f051f77a7c8e6957c0696eac88f26b0117e54f52d3fc682ab19397a8812846a4" + +[[package]] +name = "linux-raw-sys" +version = "0.4.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "da2479e8c062e40bf0066ffa0bc823de0a9368974af99c9f6df941d2c231e03f" + +[[package]] +name = "litemap" +version = "0.7.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "77a1a2647d5b7134127971a6de0d533c49de2159167e7f259c427195f87168a1" + +[[package]] +name = "lock_api" +version = "0.4.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3c168f8615b12bc01f9c17e2eb0cc07dcae1940121185446edc3744920e8ef45" +dependencies = [ + "autocfg", + "scopeguard", +] + +[[package]] +name = "log" +version = "0.4.20" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b5e6163cb8c49088c2c36f57875e58ccd8c87c7427f7fbd50ea6710b2f3f2e8f" + +[[package]] +name = "lru" +version = "0.11.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a4a83fb7698b3643a0e34f9ae6f2e8f0178c0fd42f8b59d493aa271ff3a5bf21" +dependencies = [ + "hashbrown 0.14.2", +] + +[[package]] +name = "lru" +version = "0.12.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1efa59af2ddfad1854ae27d75009d538d0998b4b2fd47083e743ac1a10e46c60" +dependencies = [ + "hashbrown 0.14.2", +] + +[[package]] +name = "lru-cache" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "31e24f1ad8321ca0e8a1e0ac13f23cb668e6f5466c2c57319f6a5cf1cc8e3b1c" +dependencies = [ + "linked-hash-map", +] + +[[package]] +name = "lz4_flex" +version = "0.11.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3ea9b256699eda7b0387ffbc776dd625e28bde3918446381781245b7a50349d8" + +[[package]] +name = "mach2" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6d0d1830bcd151a6fc4aea1369af235b36c1528fe976b8ff678683c9995eade8" +dependencies = [ + "libc", +] + +[[package]] +name = "match_cfg" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ffbee8634e0d45d258acb448e7eaab3fce7a0a467395d4d9f228e3c1f01fb2e4" + +[[package]] +name = "matchers" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8263075bb86c5a1b1427b5ae862e8889656f126e9f77c484496e8b47cf5c5558" +dependencies = [ + "regex-automata 0.1.10", +] + +[[package]] +name = "matches" +version = "0.1.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2532096657941c2fea9c289d370a250971c689d4f143798ff67113ec042024a5" + +[[package]] +name = "memchr" +version = "2.6.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f665ee40bc4a3c5590afb1e9677db74a508659dfd71e126420da8274909a0167" + +[[package]] +name = "memmap2" +version = "0.7.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f49388d20533534cd19360ad3d6a7dadc885944aa802ba3995040c5ec11288c6" +dependencies = [ + "libc", +] + +[[package]] +name = "memoffset" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5a634b1c61a95585bd15607c6ab0c4e5b226e695ff2800ba0cdccddf208c406c" +dependencies = [ + "autocfg", +] + +[[package]] +name = "metrics" +version = "0.21.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fde3af1a009ed76a778cb84fdef9e7dbbdf5775ae3e4cc1f434a6a307f6f76c5" +dependencies = [ + "ahash", + "metrics-macros", + "portable-atomic", +] + +[[package]] +name = "metrics-exporter-prometheus" +version = "0.12.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8a4964177ddfdab1e3a2b37aec7cf320e14169abb0ed73999f558136409178d5" +dependencies = [ + "base64 0.21.5", + "hyper", + "indexmap 1.9.3", + "ipnet", + "metrics", + "metrics-util", + "quanta", + "thiserror", + "tokio", + "tracing", +] + +[[package]] +name = "metrics-macros" +version = "0.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ddece26afd34c31585c74a4db0630c376df271c285d682d1e55012197830b6df" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.38", +] + +[[package]] +name = "metrics-process" +version = "1.0.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1c93f6ad342d3f7bc14724147e2dbc6eb6fdbe5a832ace16ea23b73618e8cc17" +dependencies = [ + "libproc", + "mach2", + "metrics", + "once_cell", + "procfs", + "rlimit", + "windows", +] + +[[package]] +name = "metrics-util" +version = "0.15.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "111cb375987443c3de8d503580b536f77dc8416d32db62d9456db5d93bd7ac47" +dependencies = [ + "aho-corasick 0.7.20", + "crossbeam-epoch", + "crossbeam-utils", + "hashbrown 0.13.2", + "indexmap 1.9.3", + "metrics", + "num_cpus", + "ordered-float", + "quanta", + "radix_trie", + "sketches-ddsketch", +] + +[[package]] +name = "mime" +version = "0.3.17" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6877bb514081ee2a7ff5ef9de3281f14a4dd4bceac4c09388074a6b5df8a139a" + +[[package]] +name = "mime_guess" +version = "2.0.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4192263c238a5f0d0c6bfd21f336a313a4ce1c450542449ca191bb657b4642ef" +dependencies = [ + "mime", + "unicase", +] + +[[package]] +name = "minimal-lexical" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "68354c5c6bd36d73ff3feceb05efa59b6acb7626617f4962be322a825e61f79a" + +[[package]] +name = "miniz_oxide" +version = "0.7.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e7810e0be55b428ada41041c41f32c9f1a42817901b4ccf45fa3d4b6561e74c7" +dependencies = [ + "adler", +] + +[[package]] +name = "mio" +version = "0.8.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3dce281c5e46beae905d4de1870d8b1509a9142b62eedf18b443b011ca8343d0" +dependencies = [ + "libc", + "log", + "wasi 0.11.0+wasi-snapshot-preview1", + "windows-sys 0.48.0", +] + +[[package]] +name = "modular-bitfield" +version = "0.11.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a53d79ba8304ac1c4f9eb3b9d281f21f7be9d4626f72ce7df4ad8fbde4f38a74" +dependencies = [ + "modular-bitfield-impl", + "static_assertions", +] + +[[package]] +name = "modular-bitfield-impl" +version = "0.11.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5a7d5f7076603ebc68de2dc6a650ec331a062a13abaa346975be747bbfa4b789" +dependencies = [ + "proc-macro2", + "quote", + "syn 1.0.109", +] + +[[package]] +name = "more-asserts" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1fafa6961cabd9c63bcd77a45d7e3b7f3b552b70417831fb0f56db717e72407e" + +[[package]] +name = "nibble_vec" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "77a5d83df9f36fe23f0c3648c6bbb8b0298bb5f1939c8f2704431371f4b84d43" +dependencies = [ + "smallvec", +] + +[[package]] +name = "nom" +version = "7.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d273983c5a657a70a3e8f2a01329822f3b8c8172b73826411a55751e404a0a4a" +dependencies = [ + "memchr", + "minimal-lexical", +] + +[[package]] +name = "nu-ansi-term" +version = "0.46.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "77a8165726e8236064dbb45459242600304b42a5ea24ee2948e18e023bf7ba84" +dependencies = [ + "overload", + "winapi", +] + +[[package]] +name = "num" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b05180d69e3da0e530ba2a1dae5110317e49e3b7f3d41be227dc5f92e49ee7af" +dependencies = [ + "num-bigint", + "num-complex", + "num-integer", + "num-iter", + "num-rational", + "num-traits", +] + +[[package]] +name = "num-bigint" +version = "0.4.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "608e7659b5c3d7cba262d894801b9ec9d00de989e8a82bd4bef91d08da45cdc0" +dependencies = [ + "autocfg", + "num-integer", + "num-traits", + "serde", +] + +[[package]] +name = "num-complex" +version = "0.4.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1ba157ca0885411de85d6ca030ba7e2a83a28636056c7c699b07c8b6f7383214" +dependencies = [ + "num-traits", +] + +[[package]] +name = "num-integer" +version = "0.1.45" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "225d3389fb3509a24c93f5c29eb6bde2586b98d9f016636dff58d7c6f7569cd9" +dependencies = [ + "autocfg", + "num-traits", +] + +[[package]] +name = "num-iter" +version = "0.1.43" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7d03e6c028c5dc5cac6e2dec0efda81fc887605bb3d884578bb6d6bf7514e252" +dependencies = [ + "autocfg", + "num-integer", + "num-traits", +] + +[[package]] +name = "num-rational" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0638a1c9d0a3c0914158145bc76cff373a75a627e6ecbfb71cbe6f453a5a19b0" +dependencies = [ + "autocfg", + "num-bigint", + "num-integer", + "num-traits", +] + +[[package]] +name = "num-traits" +version = "0.2.17" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "39e3200413f237f41ab11ad6d161bc7239c84dcb631773ccd7de3dfe4b5c267c" +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 = "num_enum" +version = "0.6.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7a015b430d3c108a207fd776d2e2196aaf8b1cf8cf93253e3a097ff3085076a1" +dependencies = [ + "num_enum_derive 0.6.1", +] + +[[package]] +name = "num_enum" +version = "0.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "70bf6736f74634d299d00086f02986875b3c2d924781a6a2cb6c201e73da0ceb" +dependencies = [ + "num_enum_derive 0.7.0", +] + +[[package]] +name = "num_enum_derive" +version = "0.6.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "96667db765a921f7b295ffee8b60472b686a51d4f21c2ee4ffdb94c7013b65a6" +dependencies = [ + "proc-macro-crate", + "proc-macro2", + "quote", + "syn 2.0.38", +] + +[[package]] +name = "num_enum_derive" +version = "0.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "56ea360eafe1022f7cc56cd7b869ed57330fb2453d0c7831d99b74c65d2f5597" +dependencies = [ + "proc-macro-crate", + "proc-macro2", + "quote", + "syn 2.0.38", +] + +[[package]] +name = "num_threads" +version = "0.1.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2819ce041d2ee131036f4fc9d6ae7ae125a3a40e97ba64d04fe799ad9dabbb44" +dependencies = [ + "libc", +] + +[[package]] +name = "object" +version = "0.32.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9cf5f9dd3933bd50a9e1f149ec995f39ae2c496d31fd772c1fd45ebc27e902b0" +dependencies = [ + "memchr", +] + +[[package]] +name = "once_cell" +version = "1.18.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dd8b5dd2ae5ed71462c540258bedcb51965123ad7e7ccf4b9a8cafaa4a63576d" +dependencies = [ + "atomic-polyfill 1.0.3", + "critical-section", +] + +[[package]] +name = "opaque-debug" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "624a8340c38c1b80fd549087862da4ba43e08858af025b236e509b6649fc13d5" + +[[package]] +name = "openssl-probe" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ff011a302c396a5197692431fc1948019154afc178baf7d8e37367442a4601cf" + +[[package]] +name = "option-ext" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "04744f49eae99ab78e0d5c0b603ab218f515ea8cfe5a456d7629ad883a3b6e7d" + +[[package]] +name = "ordered-float" +version = "3.9.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f1e1c390732d15f1d48471625cd92d154e66db2c56645e29a9cd26f4699f72dc" +dependencies = [ + "num-traits", +] + +[[package]] +name = "overload" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b15813163c1d831bf4a13c3610c05c0d03b39feb07f7e09fa234dac9b15aaf39" + +[[package]] +name = "page_size" +version = "0.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "30d5b2194ed13191c1999ae0704b7839fb18384fa22e49b57eeaa97d79ce40da" +dependencies = [ + "libc", + "winapi", +] + +[[package]] +name = "parity-scale-codec" +version = "3.6.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0dec8a8073036902368c2cdc0387e85ff9a37054d7e7c98e592145e0c92cd4fb" +dependencies = [ + "arrayvec", + "bitvec", + "byte-slice-cast", + "bytes", + "impl-trait-for-tuples", + "parity-scale-codec-derive", + "serde", +] + +[[package]] +name = "parity-scale-codec-derive" +version = "3.6.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "312270ee71e1cd70289dacf597cab7b207aa107d2f28191c2ae45b2ece18a260" +dependencies = [ + "proc-macro-crate", + "proc-macro2", + "quote", + "syn 1.0.109", +] + +[[package]] +name = "parity-tokio-ipc" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9981e32fb75e004cc148f5fb70342f393830e0a4aa62e3cc93b50976218d42b6" +dependencies = [ + "futures", + "libc", + "log", + "rand 0.7.3", + "tokio", + "winapi", +] + +[[package]] +name = "parking_lot" +version = "0.11.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7d17b78036a60663b797adeaee46f5c9dfebb86948d1255007a1d6be0271ff99" +dependencies = [ + "instant", + "lock_api", + "parking_lot_core 0.8.6", +] + +[[package]] +name = "parking_lot" +version = "0.12.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3742b2c103b9f06bc9fff0a37ff4912935851bee6d36f3c02bcc755bcfec228f" +dependencies = [ + "lock_api", + "parking_lot_core 0.9.9", +] + +[[package]] +name = "parking_lot_core" +version = "0.8.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "60a2cfe6f0ad2bfc16aefa463b497d5c7a5ecd44a23efa72aa342d90177356dc" +dependencies = [ + "cfg-if", + "instant", + "libc", + "redox_syscall 0.2.16", + "smallvec", + "winapi", +] + +[[package]] +name = "parking_lot_core" +version = "0.9.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4c42a9226546d68acdd9c0a280d17ce19bfe27a46bf68784e4066115788d008e" +dependencies = [ + "cfg-if", + "libc", + "redox_syscall 0.4.1", + "smallvec", + "windows-targets 0.48.5", +] + +[[package]] +name = "paste" +version = "1.0.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "de3145af08024dea9fa9914f381a17b8fc6034dfb00f3a84013f7ff43f29ed4c" + +[[package]] +name = "peeking_take_while" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "19b17cddbe7ec3f8bc800887bab5e717348c95ea2ca0b1bf0837fb964dc67099" + +[[package]] +name = "pem" +version = "1.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a8835c273a76a90455d7344889b0964598e3316e2a79ede8e36f16bdcf2228b8" +dependencies = [ + "base64 0.13.1", +] + +[[package]] +name = "percent-encoding" +version = "2.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9b2a4787296e9989611394c33f193f676704af1686e70b8f8033ab5ba9a35a94" + +[[package]] +name = "pest" +version = "2.7.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ae9cee2a55a544be8b89dc6848072af97a20f2422603c10865be2a42b580fff5" +dependencies = [ + "memchr", + "thiserror", + "ucd-trie", +] + +[[package]] +name = "ph" +version = "0.8.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "88c6e62e083483e2812a9d2a6eff6b97871302ef4166b5182c6da30624b7e991" +dependencies = [ + "binout", + "bitm", + "dyn_size_of", + "rayon", + "wyhash", +] + +[[package]] +name = "phf" +version = "0.11.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ade2d8b8f33c7333b51bcf0428d37e217e9f32192ae4772156f65063b8ce03dc" +dependencies = [ + "phf_macros", + "phf_shared", +] + +[[package]] +name = "phf_generator" +version = "0.11.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "48e4cc64c2ad9ebe670cb8fd69dd50ae301650392e81c05f9bfcb2d5bdbc24b0" +dependencies = [ + "phf_shared", + "rand 0.8.5", +] + +[[package]] +name = "phf_macros" +version = "0.11.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3444646e286606587e49f3bcf1679b8cef1dc2c5ecc29ddacaffc305180d464b" +dependencies = [ + "phf_generator", + "phf_shared", + "proc-macro2", + "quote", + "syn 2.0.38", +] + +[[package]] +name = "phf_shared" +version = "0.11.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "90fcb95eef784c2ac79119d1dd819e162b5da872ce6f3c3abe1e8ca1c082f72b" +dependencies = [ + "siphasher", +] + +[[package]] +name = "pin-project" +version = "1.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fda4ed1c6c173e3fc7a83629421152e01d7b1f9b7f65fb301e490e8cfc656422" +dependencies = [ + "pin-project-internal", +] + +[[package]] +name = "pin-project-internal" +version = "1.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4359fd9c9171ec6e8c62926d6faaf553a8dc3f64e1507e76da7911b4f6a04405" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.38", +] + +[[package]] +name = "pin-project-lite" +version = "0.2.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8afb450f006bf6385ca15ef45d71d2288452bc3683ce2e2cacc0d18e4be60b58" + +[[package]] +name = "pin-utils" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184" + +[[package]] +name = "pkcs8" +version = "0.10.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f950b2377845cebe5cf8b5165cb3cc1a5e0fa5cfa3e1f7f55707d8fd82e0a7b7" +dependencies = [ + "der", + "spki", +] + +[[package]] +name = "pkg-config" +version = "0.3.27" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "26072860ba924cbfa98ea39c8c19b4dd6a4a25423dbdf219c1eca91aa0cf6964" + +[[package]] +name = "platforms" +version = "3.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4503fa043bf02cee09a9582e9554b4c6403b2ef55e4612e96561d294419429f8" + +[[package]] +name = "pollster" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "22686f4785f02a4fcc856d3b3bb19bf6c8160d103f7a99cc258bddd0251dc7f2" + +[[package]] +name = "polyval" +version = "0.5.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8419d2b623c7c0896ff2d5d96e2cb4ede590fed28fcc34934f4c33c036e620a1" +dependencies = [ + "cfg-if", + "cpufeatures", + "opaque-debug", + "universal-hash", +] + +[[package]] +name = "portable-atomic" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b559898e0b4931ed2d3b959ab0c2da4d99cc644c4b0b1a35b4d344027f474023" + +[[package]] +name = "postcard" +version = "1.0.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a55c51ee6c0db07e68448e336cf8ea4131a620edefebf9893e759b2d793420f8" +dependencies = [ + "cobs", + "embedded-io", + "heapless", + "serde", +] + +[[package]] +name = "powerfmt" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "439ee305def115ba05938db6eb1644ff94165c5ab5e9420d1c1bcedbba909391" + +[[package]] +name = "ppv-lite86" +version = "0.2.17" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5b40af805b3121feab8a3c29f04d8ad262fa8e0561883e7653e024ae4479e6de" + +[[package]] +name = "pretty_assertions" +version = "1.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "af7cee1a6c8a5b9208b3cb1061f10c0cb689087b3d8ce85fb9d2dd7a29b6ba66" +dependencies = [ + "diff", + "yansi", +] + +[[package]] +name = "prettyplease" +version = "0.2.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ae005bd773ab59b4725093fd7df83fd7892f7d8eafb48dbd7de6e024e4215f9d" +dependencies = [ + "proc-macro2", + "syn 2.0.38", +] + +[[package]] +name = "primitive-types" +version = "0.12.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0b34d9fd68ae0b74a41b21c03c2f62847aa0ffea044eee893b4c140b37e244e2" +dependencies = [ + "fixed-hash", + "impl-codec", + "uint", +] + +[[package]] +name = "proc-macro-crate" +version = "1.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7f4c021e1093a56626774e81216a4ce732a735e5bad4868a03f3ed65ca0c3919" +dependencies = [ + "once_cell", + "toml_edit 0.19.15", +] + +[[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.69" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "134c189feb4956b20f6f547d2cf727d4c0fe06722b20a0eec87ed445a97f92da" +dependencies = [ + "unicode-ident", +] + +[[package]] +name = "procfs" +version = "0.15.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "943ca7f9f29bab5844ecd8fdb3992c5969b6622bb9609b9502fef9b4310e3f1f" +dependencies = [ + "bitflags 1.3.2", + "byteorder", + "hex", + "lazy_static", + "rustix 0.36.16", +] + +[[package]] +name = "proptest" +version = "1.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7c003ac8c77cb07bb74f5f198bce836a689bcd5a42574612bf14d17bfd08c20e" +dependencies = [ + "bit-set", + "bit-vec", + "bitflags 2.4.1", + "lazy_static", + "num-traits", + "rand 0.8.5", + "rand_chacha 0.3.1", + "rand_xorshift", + "regex-syntax 0.7.5", + "rusty-fork", + "tempfile", + "unarray", +] + +[[package]] +name = "proptest-derive" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9cf16337405ca084e9c78985114633b6827711d22b9e6ef6c6c0d665eb3f0b6e" +dependencies = [ + "proc-macro2", + "quote", + "syn 1.0.109", +] + +[[package]] +name = "public-ip" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7b4c40db5262d93298c363a299f8bc1b3a956a78eecddba3bc0e58b76e2f419a" +dependencies = [ + "dns-lookup", + "futures-core", + "futures-util", + "http", + "hyper", + "hyper-system-resolver", + "pin-project-lite", + "thiserror", + "tokio", + "tracing", + "tracing-futures", + "trust-dns-client", + "trust-dns-proto 0.20.4", +] + +[[package]] +name = "quanta" +version = "0.11.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a17e662a7a8291a865152364c20c7abc5e60486ab2001e8ec10b24862de0b9ab" +dependencies = [ + "crossbeam-utils", + "libc", + "mach2", + "once_cell", + "raw-cpuid", + "wasi 0.11.0+wasi-snapshot-preview1", + "web-sys", + "winapi", +] + +[[package]] +name = "quick-error" +version = "1.2.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a1d01941d82fa2ab50be1e79e6714289dd7cde78eba4c074bc5a4374f650dfe0" + +[[package]] +name = "quote" +version = "1.0.33" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5267fca4496028628a95160fc423a33e8b2e6af8a5302579e322e4b520293cae" +dependencies = [ + "proc-macro2", +] + +[[package]] +name = "radium" +version = "0.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dc33ff2d4973d518d823d61aa239014831e521c75da58e3df4840d3f47749d09" + +[[package]] +name = "radix_trie" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c069c179fcdc6a2fe24d8d18305cf085fdbd4f922c041943e203685d6a1c58fd" +dependencies = [ + "endian-type", + "nibble_vec", +] + +[[package]] +name = "rand" +version = "0.7.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6a6b1679d49b24bbfe0c803429aa1874472f50d9b363131f0e89fc356b544d03" +dependencies = [ + "getrandom 0.1.16", + "libc", + "rand_chacha 0.2.2", + "rand_core 0.5.1", + "rand_hc", +] + +[[package]] +name = "rand" +version = "0.8.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "34af8d1a0e25924bc5b7c43c079c942339d8f0a8b57c39049bef581b46327404" +dependencies = [ + "libc", + "rand_chacha 0.3.1", + "rand_core 0.6.4", +] + +[[package]] +name = "rand_chacha" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f4c8ed856279c9737206bf725bf36935d8666ead7aa69b52be55af369d193402" +dependencies = [ + "ppv-lite86", + "rand_core 0.5.1", +] + +[[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 0.6.4", +] + +[[package]] +name = "rand_core" +version = "0.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "90bde5296fc891b0cef12a6d03ddccc162ce7b2aff54160af9338f8d40df6d19" +dependencies = [ + "getrandom 0.1.16", +] + +[[package]] +name = "rand_core" +version = "0.6.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c" +dependencies = [ + "getrandom 0.2.10", +] + +[[package]] +name = "rand_hc" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ca3129af7b92a17112d59ad498c6f81eaf463253766b90396d39ea7a39d6613c" +dependencies = [ + "rand_core 0.5.1", +] + +[[package]] +name = "rand_xorshift" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d25bf25ec5ae4a3f1b92f929810509a2f53d7dca2f50b794ff57e3face536c8f" +dependencies = [ + "rand_core 0.6.4", +] + +[[package]] +name = "raw-cpuid" +version = "10.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6c297679cb867470fa8c9f67dbba74a78d78e3e98d7cf2b08d6d71540f797332" +dependencies = [ + "bitflags 1.3.2", +] + +[[package]] +name = "rayon" +version = "1.8.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9c27db03db7734835b3f53954b534c91069375ce6ccaa2e065441e07d9b6cdb1" +dependencies = [ + "either", + "rayon-core", +] + +[[package]] +name = "rayon-core" +version = "1.12.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5ce3fb6ad83f861aac485e76e1985cd109d9a3713802152be56c3b1f0e0658ed" +dependencies = [ + "crossbeam-deque", + "crossbeam-utils", +] + +[[package]] +name = "redox_syscall" +version = "0.2.16" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fb5a58c1855b4b6819d59012155603f0b22ad30cad752600aadfcb695265519a" +dependencies = [ + "bitflags 1.3.2", +] + +[[package]] +name = "redox_syscall" +version = "0.3.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "567664f262709473930a4bf9e51bf2ebf3348f2e748ccc50dea20646858f8f29" +dependencies = [ + "bitflags 1.3.2", +] + +[[package]] +name = "redox_syscall" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4722d768eff46b75989dd134e5c353f0d6296e5aaa3132e776cbdb56be7731aa" +dependencies = [ + "bitflags 1.3.2", +] + +[[package]] +name = "redox_users" +version = "0.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b033d837a7cf162d7993aded9304e30a83213c648b6e389db233191f891e5c2b" +dependencies = [ + "getrandom 0.2.10", + "redox_syscall 0.2.16", + "thiserror", +] + +[[package]] +name = "regex" +version = "1.10.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "380b951a9c5e80ddfd6136919eef32310721aa4aacd4889a8d39124b026ab343" +dependencies = [ + "aho-corasick 1.1.2", + "memchr", + "regex-automata 0.4.3", + "regex-syntax 0.8.2", +] + +[[package]] +name = "regex-automata" +version = "0.1.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6c230d73fb8d8c1b9c0b3135c5142a8acee3a0558fb8db5cf1cb65f8d7862132" +dependencies = [ + "regex-syntax 0.6.29", +] + +[[package]] +name = "regex-automata" +version = "0.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5f804c7828047e88b2d32e2d7fe5a105da8ee3264f01902f796c8e067dc2483f" +dependencies = [ + "aho-corasick 1.1.2", + "memchr", + "regex-syntax 0.8.2", +] + +[[package]] +name = "regex-syntax" +version = "0.6.29" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f162c6dd7b008981e4d40210aca20b4bd0f9b60ca9271061b07f78537722f2e1" + +[[package]] +name = "regex-syntax" +version = "0.7.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dbb5fb1acd8a1a18b3dd5be62d25485eb770e05afb408a9627d14d451bae12da" + +[[package]] +name = "regex-syntax" +version = "0.8.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c08c74e62047bb2de4ff487b251e4a92e24f48745648451635cec7d591162d9f" + +[[package]] +name = "regress" +version = "0.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "82a9ecfa0cb04d0b04dddb99b8ccf4f66bc8dfd23df694b398570bd8ae3a50fb" +dependencies = [ + "hashbrown 0.13.2", + "memchr", +] + +[[package]] +name = "resolv-conf" +version = "0.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "52e44394d2086d010551b14b53b1f24e31647570cd1deb0379e2c21b329aba00" +dependencies = [ + "hostname", + "quick-error", +] + +[[package]] +name = "reth" +version = "0.1.0-alpha.10" +source = "git+https://github.com/paradigmxyz/reth.git#fc4fc936807870b07acb91e1d50c3920b55ff055" +dependencies = [ + "alloy-rlp", + "aquamarine", + "backon", + "boyer-moore-magiclen", + "clap", + "comfy-table", + "confy", + "const-str", + "crossterm 0.27.0", + "dirs-next", + "eyre", + "fdlimit", + "futures", + "human_bytes", + "humantime", + "hyper", + "itertools 0.11.0", + "jemalloc-ctl", + "jemallocator", + "metrics", + "metrics-exporter-prometheus", + "metrics-process", + "metrics-util", + "pin-project", + "pretty_assertions", + "proptest", + "rand 0.8.5", + "reth-auto-seal-consensus", + "reth-basic-payload-builder", + "reth-beacon-consensus", + "reth-blockchain-tree", + "reth-config", + "reth-consensus-common", + "reth-db", + "reth-discv4", + "reth-downloaders", + "reth-interfaces", + "reth-metrics", + "reth-net-nat", + "reth-network", + "reth-network-api", + "reth-nippy-jar", + "reth-payload-builder", + "reth-primitives", + "reth-provider", + "reth-prune", + "reth-revm", + "reth-revm-inspectors", + "reth-rpc", + "reth-rpc-api", + "reth-rpc-builder", + "reth-rpc-engine-api", + "reth-rpc-types", + "reth-rpc-types-compat", + "reth-snapshot", + "reth-stages", + "reth-tasks", + "reth-tracing", + "reth-transaction-pool", + "reth-trie", + "secp256k1 0.27.0", + "serde", + "serde_json", + "shellexpand", + "tempfile", + "thiserror", + "tokio", + "toml 0.8.5", + "tracing", + "tui", + "vergen", +] + +[[package]] +name = "reth-auto-seal-consensus" +version = "0.1.0-alpha.10" +source = "git+https://github.com/paradigmxyz/reth.git#fc4fc936807870b07acb91e1d50c3920b55ff055" +dependencies = [ + "futures-util", + "reth-beacon-consensus", + "reth-interfaces", + "reth-primitives", + "reth-provider", + "reth-revm", + "reth-stages", + "reth-transaction-pool", + "tokio", + "tokio-stream", + "tracing", +] + +[[package]] +name = "reth-basic-payload-builder" +version = "0.1.0-alpha.10" +source = "git+https://github.com/paradigmxyz/reth.git#fc4fc936807870b07acb91e1d50c3920b55ff055" +dependencies = [ + "alloy-rlp", + "futures-core", + "futures-util", + "metrics", + "reth-interfaces", + "reth-metrics", + "reth-payload-builder", + "reth-primitives", + "reth-provider", + "reth-revm", + "reth-tasks", + "reth-transaction-pool", + "revm", + "tokio", + "tracing", +] + +[[package]] +name = "reth-beacon-consensus" +version = "0.1.0-alpha.10" +source = "git+https://github.com/paradigmxyz/reth.git#fc4fc936807870b07acb91e1d50c3920b55ff055" +dependencies = [ + "futures", + "metrics", + "reth-consensus-common", + "reth-db", + "reth-interfaces", + "reth-metrics", + "reth-payload-builder", + "reth-primitives", + "reth-provider", + "reth-prune", + "reth-rpc-types", + "reth-rpc-types-compat", + "reth-snapshot", + "reth-stages", + "reth-tasks", + "reth-tokio-util", + "schnellru", + "thiserror", + "tokio", + "tokio-stream", + "tracing", +] + +[[package]] +name = "reth-blockchain-tree" +version = "0.1.0-alpha.10" +source = "git+https://github.com/paradigmxyz/reth.git#fc4fc936807870b07acb91e1d50c3920b55ff055" +dependencies = [ + "aquamarine", + "linked_hash_set", + "lru 0.11.1", + "metrics", + "parking_lot 0.12.1", + "reth-db", + "reth-interfaces", + "reth-metrics", + "reth-primitives", + "reth-provider", + "reth-stages", + "tokio", + "tracing", +] + +[[package]] +name = "reth-codecs" +version = "0.1.0-alpha.10" +source = "git+https://github.com/paradigmxyz/reth.git#fc4fc936807870b07acb91e1d50c3920b55ff055" +dependencies = [ + "arbitrary", + "bytes", + "codecs-derive", + "proptest", + "proptest-derive", + "revm-primitives", +] + +[[package]] +name = "reth-config" +version = "0.1.0-alpha.10" +source = "git+https://github.com/paradigmxyz/reth.git#fc4fc936807870b07acb91e1d50c3920b55ff055" +dependencies = [ + "confy", + "reth-discv4", + "reth-downloaders", + "reth-net-nat", + "reth-network", + "reth-primitives", + "reth-stages", + "secp256k1 0.27.0", + "serde", + "serde_json", + "tempfile", +] + +[[package]] +name = "reth-consensus-common" +version = "0.1.0-alpha.10" +source = "git+https://github.com/paradigmxyz/reth.git#fc4fc936807870b07acb91e1d50c3920b55ff055" +dependencies = [ + "reth-interfaces", + "reth-primitives", + "reth-provider", +] + +[[package]] +name = "reth-db" +version = "0.1.0-alpha.10" +source = "git+https://github.com/paradigmxyz/reth.git#fc4fc936807870b07acb91e1d50c3920b55ff055" +dependencies = [ + "arbitrary", + "bytes", + "derive_more", + "eyre", + "futures", + "heapless", + "itertools 0.11.0", + "metrics", + "modular-bitfield", + "page_size", + "parity-scale-codec", + "parking_lot 0.12.1", + "paste", + "postcard", + "proptest", + "proptest-derive", + "rand 0.8.5", + "rayon", + "reth-codecs", + "reth-interfaces", + "reth-libmdbx", + "reth-metrics", + "reth-nippy-jar", + "reth-primitives", + "reth-tracing", + "serde", + "tempfile", + "thiserror", + "tokio-stream", + "vergen", +] + +[[package]] +name = "reth-discv4" +version = "0.1.0-alpha.10" +source = "git+https://github.com/paradigmxyz/reth.git#fc4fc936807870b07acb91e1d50c3920b55ff055" +dependencies = [ + "alloy-rlp", + "discv5", + "enr", + "generic-array", + "parking_lot 0.12.1", + "reth-net-common", + "reth-net-nat", + "reth-primitives", + "rlp", + "secp256k1 0.27.0", + "serde", + "thiserror", + "tokio", + "tokio-stream", + "tracing", +] + +[[package]] +name = "reth-dns-discovery" +version = "0.1.0-alpha.10" +source = "git+https://github.com/paradigmxyz/reth.git#fc4fc936807870b07acb91e1d50c3920b55ff055" +dependencies = [ + "alloy-rlp", + "async-trait", + "data-encoding", + "enr", + "linked_hash_set", + "parking_lot 0.12.1", + "reth-net-common", + "reth-primitives", + "schnellru", + "secp256k1 0.27.0", + "serde", + "serde_with", + "thiserror", + "tokio", + "tokio-stream", + "tracing", + "trust-dns-resolver", +] + +[[package]] +name = "reth-downloaders" +version = "0.1.0-alpha.10" +source = "git+https://github.com/paradigmxyz/reth.git#fc4fc936807870b07acb91e1d50c3920b55ff055" +dependencies = [ + "alloy-rlp", + "futures", + "futures-util", + "itertools 0.11.0", + "metrics", + "pin-project", + "rayon", + "reth-db", + "reth-interfaces", + "reth-metrics", + "reth-primitives", + "reth-tasks", + "tempfile", + "thiserror", + "tokio", + "tokio-stream", + "tokio-util", + "tracing", +] + +[[package]] +name = "reth-ecies" +version = "0.1.0-alpha.10" +source = "git+https://github.com/paradigmxyz/reth.git#fc4fc936807870b07acb91e1d50c3920b55ff055" +dependencies = [ + "aes 0.8.3", + "alloy-rlp", + "block-padding", + "byteorder", + "cipher 0.4.4", + "ctr 0.9.2", + "digest 0.10.7", + "educe", + "futures", + "generic-array", + "hmac", + "pin-project", + "rand 0.8.5", + "reth-net-common", + "reth-primitives", + "secp256k1 0.27.0", + "sha2", + "sha3", + "thiserror", + "tokio", + "tokio-stream", + "tokio-util", + "tracing", + "typenum", +] + +[[package]] +name = "reth-eth-wire" +version = "0.1.0-alpha.10" +source = "git+https://github.com/paradigmxyz/reth.git#fc4fc936807870b07acb91e1d50c3920b55ff055" +dependencies = [ + "alloy-rlp", + "async-trait", + "bytes", + "futures", + "metrics", + "pin-project", + "reth-codecs", + "reth-discv4", + "reth-ecies", + "reth-metrics", + "reth-primitives", + "serde", + "snap", + "thiserror", + "tokio", + "tokio-stream", + "tokio-util", + "tracing", +] + +[[package]] +name = "reth-interfaces" +version = "0.1.0-alpha.10" +source = "git+https://github.com/paradigmxyz/reth.git#fc4fc936807870b07acb91e1d50c3920b55ff055" +dependencies = [ + "async-trait", + "auto_impl", + "clap", + "futures", + "modular-bitfield", + "parity-scale-codec", + "parking_lot 0.12.1", + "rand 0.8.5", + "reth-codecs", + "reth-eth-wire", + "reth-network-api", + "reth-nippy-jar", + "reth-primitives", + "reth-rpc-types", + "revm-primitives", + "secp256k1 0.27.0", + "thiserror", + "tokio", + "tokio-stream", + "tracing", +] + +[[package]] +name = "reth-ipc" +version = "0.1.0-alpha.10" +source = "git+https://github.com/paradigmxyz/reth.git#fc4fc936807870b07acb91e1d50c3920b55ff055" +dependencies = [ + "async-trait", + "bytes", + "futures", + "jsonrpsee", + "parity-tokio-ipc", + "pin-project", + "serde_json", + "thiserror", + "tokio", + "tokio-stream", + "tokio-util", + "tower", + "tracing", +] + +[[package]] +name = "reth-libmdbx" +version = "0.1.0-alpha.10" +source = "git+https://github.com/paradigmxyz/reth.git#fc4fc936807870b07acb91e1d50c3920b55ff055" +dependencies = [ + "bitflags 2.4.1", + "byteorder", + "derive_more", + "indexmap 2.0.2", + "libc", + "parking_lot 0.12.1", + "reth-mdbx-sys", + "thiserror", +] + +[[package]] +name = "reth-mdbx-sys" +version = "0.1.0-alpha.10" +source = "git+https://github.com/paradigmxyz/reth.git#fc4fc936807870b07acb91e1d50c3920b55ff055" +dependencies = [ + "bindgen 0.68.1", + "cc", + "libc", +] + +[[package]] +name = "reth-metrics" +version = "0.1.0-alpha.10" +source = "git+https://github.com/paradigmxyz/reth.git#fc4fc936807870b07acb91e1d50c3920b55ff055" +dependencies = [ + "futures", + "metrics", + "reth-metrics-derive", + "tokio", + "tokio-util", +] + +[[package]] +name = "reth-metrics-derive" +version = "0.1.0-alpha.10" +source = "git+https://github.com/paradigmxyz/reth.git#fc4fc936807870b07acb91e1d50c3920b55ff055" +dependencies = [ + "once_cell", + "proc-macro2", + "quote", + "regex", + "syn 2.0.38", +] + +[[package]] +name = "reth-net-common" +version = "0.1.0-alpha.10" +source = "git+https://github.com/paradigmxyz/reth.git#fc4fc936807870b07acb91e1d50c3920b55ff055" +dependencies = [ + "pin-project", + "reth-primitives", + "tokio", +] + +[[package]] +name = "reth-net-nat" +version = "0.1.0-alpha.10" +source = "git+https://github.com/paradigmxyz/reth.git#fc4fc936807870b07acb91e1d50c3920b55ff055" +dependencies = [ + "igd", + "pin-project-lite", + "public-ip", + "serde_with", + "thiserror", + "tokio", + "tracing", +] + +[[package]] +name = "reth-network" +version = "0.1.0-alpha.10" +source = "git+https://github.com/paradigmxyz/reth.git#fc4fc936807870b07acb91e1d50c3920b55ff055" +dependencies = [ + "alloy-rlp", + "aquamarine", + "async-trait", + "auto_impl", + "enr", + "fnv", + "futures", + "humantime-serde", + "linked-hash-map", + "linked_hash_set", + "metrics", + "parking_lot 0.12.1", + "pin-project", + "rand 0.8.5", + "reth-discv4", + "reth-dns-discovery", + "reth-ecies", + "reth-eth-wire", + "reth-interfaces", + "reth-metrics", + "reth-net-common", + "reth-network-api", + "reth-primitives", + "reth-provider", + "reth-rpc-types", + "reth-tasks", + "reth-tokio-util", + "reth-transaction-pool", + "secp256k1 0.27.0", + "serde", + "serde_json", + "thiserror", + "tokio", + "tokio-stream", + "tokio-util", + "tracing", +] + +[[package]] +name = "reth-network-api" +version = "0.1.0-alpha.10" +source = "git+https://github.com/paradigmxyz/reth.git#fc4fc936807870b07acb91e1d50c3920b55ff055" +dependencies = [ + "async-trait", + "reth-discv4", + "reth-eth-wire", + "reth-primitives", + "reth-rpc-types", + "serde", + "thiserror", + "tokio", +] + +[[package]] +name = "reth-nippy-jar" +version = "0.1.0-alpha.10" +source = "git+https://github.com/paradigmxyz/reth.git#fc4fc936807870b07acb91e1d50c3920b55ff055" +dependencies = [ + "anyhow", + "bincode", + "bytes", + "cuckoofilter", + "hex", + "lz4_flex", + "memmap2", + "ph", + "serde", + "sucds 0.8.1", + "tempfile", + "thiserror", + "tracing", + "tracing-appender", + "zstd 0.12.4", +] + +[[package]] +name = "reth-payload-builder" +version = "0.1.0-alpha.10" +source = "git+https://github.com/paradigmxyz/reth.git#fc4fc936807870b07acb91e1d50c3920b55ff055" +dependencies = [ + "alloy-rlp", + "futures-util", + "metrics", + "reth-interfaces", + "reth-metrics", + "reth-primitives", + "reth-rpc-types", + "reth-rpc-types-compat", + "reth-transaction-pool", + "revm-primitives", + "sha2", + "thiserror", + "tokio", + "tokio-stream", + "tracing", +] + +[[package]] +name = "reth-primitives" +version = "0.1.0-alpha.10" +source = "git+https://github.com/paradigmxyz/reth.git#fc4fc936807870b07acb91e1d50c3920b55ff055" +dependencies = [ + "alloy-primitives", + "alloy-rlp", + "alloy-sol-types", + "arbitrary", + "byteorder", + "bytes", + "c-kzg", + "clap", + "crc", + "derive_more", + "itertools 0.11.0", + "modular-bitfield", + "num_enum 0.7.0", + "once_cell", + "proptest", + "proptest-derive", + "rayon", + "reth-codecs", + "revm", + "revm-primitives", + "secp256k1 0.27.0", + "serde", + "serde_json", + "serde_with", + "sha2", + "strum", + "sucds 0.6.0", + "tempfile", + "thiserror", + "tracing", + "url", + "zstd 0.12.4", +] + +[[package]] +name = "reth-provider" +version = "0.1.0-alpha.10" +source = "git+https://github.com/paradigmxyz/reth.git#fc4fc936807870b07acb91e1d50c3920b55ff055" +dependencies = [ + "alloy-rlp", + "auto_impl", + "itertools 0.11.0", + "parking_lot 0.12.1", + "pin-project", + "rayon", + "reth-db", + "reth-interfaces", + "reth-nippy-jar", + "reth-primitives", + "reth-trie", + "revm", + "tokio", + "tokio-stream", + "tracing", +] + +[[package]] +name = "reth-prune" +version = "0.1.0-alpha.10" +source = "git+https://github.com/paradigmxyz/reth.git#fc4fc936807870b07acb91e1d50c3920b55ff055" +dependencies = [ + "itertools 0.11.0", + "metrics", + "rayon", + "reth-db", + "reth-interfaces", + "reth-metrics", + "reth-primitives", + "reth-provider", + "reth-snapshot", + "reth-tokio-util", + "thiserror", + "tokio", + "tokio-stream", + "tracing", +] + +[[package]] +name = "reth-revm" +version = "0.1.0-alpha.10" +source = "git+https://github.com/paradigmxyz/reth.git#fc4fc936807870b07acb91e1d50c3920b55ff055" +dependencies = [ + "reth-consensus-common", + "reth-interfaces", + "reth-primitives", + "reth-provider", + "reth-revm-inspectors", + "revm", + "tracing", +] + +[[package]] +name = "reth-revm-inspectors" +version = "0.1.0-alpha.10" +source = "git+https://github.com/paradigmxyz/reth.git#fc4fc936807870b07acb91e1d50c3920b55ff055" +dependencies = [ + "alloy-sol-types", + "boa_engine", + "boa_gc", + "reth-primitives", + "reth-rpc-types", + "revm", + "serde", + "serde_json", + "thiserror", + "tokio", +] + +[[package]] +name = "reth-rpc" +version = "0.1.0-alpha.10" +source = "git+https://github.com/paradigmxyz/reth.git#fc4fc936807870b07acb91e1d50c3920b55ff055" +dependencies = [ + "alloy-dyn-abi", + "alloy-primitives", + "alloy-rlp", + "alloy-sol-types", + "async-trait", + "bytes", + "derive_more", + "futures", + "http", + "http-body", + "hyper", + "jsonrpsee", + "jsonwebtoken", + "lazy_static", + "metrics", + "pin-project", + "rand 0.8.5", + "rayon", + "reth-consensus-common", + "reth-interfaces", + "reth-metrics", + "reth-network-api", + "reth-primitives", + "reth-provider", + "reth-revm", + "reth-rpc-api", + "reth-rpc-engine-api", + "reth-rpc-types", + "reth-rpc-types-compat", + "reth-tasks", + "reth-transaction-pool", + "revm", + "revm-primitives", + "schnellru", + "secp256k1 0.27.0", + "serde", + "serde_json", + "thiserror", + "tokio", + "tokio-stream", + "tokio-util", + "tower", + "tracing", + "tracing-futures", +] + +[[package]] +name = "reth-rpc-api" +version = "0.1.0-alpha.10" +source = "git+https://github.com/paradigmxyz/reth.git#fc4fc936807870b07acb91e1d50c3920b55ff055" +dependencies = [ + "jsonrpsee", + "reth-primitives", + "reth-rpc-types", + "serde_json", +] + +[[package]] +name = "reth-rpc-builder" +version = "0.1.0-alpha.10" +source = "git+https://github.com/paradigmxyz/reth.git#fc4fc936807870b07acb91e1d50c3920b55ff055" +dependencies = [ + "hyper", + "jsonrpsee", + "metrics", + "reth-interfaces", + "reth-ipc", + "reth-metrics", + "reth-network-api", + "reth-primitives", + "reth-provider", + "reth-rpc", + "reth-rpc-api", + "reth-rpc-engine-api", + "reth-rpc-types", + "reth-rpc-types-compat", + "reth-tasks", + "reth-transaction-pool", + "serde", + "strum", + "thiserror", + "tower", + "tower-http", + "tracing", +] + +[[package]] +name = "reth-rpc-engine-api" +version = "0.1.0-alpha.10" +source = "git+https://github.com/paradigmxyz/reth.git#fc4fc936807870b07acb91e1d50c3920b55ff055" +dependencies = [ + "async-trait", + "jsonrpsee-core", + "jsonrpsee-types", + "metrics", + "reth-beacon-consensus", + "reth-interfaces", + "reth-metrics", + "reth-payload-builder", + "reth-primitives", + "reth-provider", + "reth-rpc-api", + "reth-rpc-types", + "reth-rpc-types-compat", + "reth-tasks", + "serde", + "thiserror", + "tokio", + "tracing", +] + +[[package]] +name = "reth-rpc-types" +version = "0.1.0-alpha.10" +source = "git+https://github.com/paradigmxyz/reth.git#fc4fc936807870b07acb91e1d50c3920b55ff055" +dependencies = [ + "alloy-primitives", + "alloy-rlp", + "itertools 0.11.0", + "jsonrpsee-types", + "reth-primitives", + "serde", + "serde_json", + "serde_with", + "thiserror", +] + +[[package]] +name = "reth-rpc-types-compat" +version = "0.1.0-alpha.10" +source = "git+https://github.com/paradigmxyz/reth.git#fc4fc936807870b07acb91e1d50c3920b55ff055" +dependencies = [ + "alloy-rlp", + "reth-primitives", + "reth-rpc-types", +] + +[[package]] +name = "reth-snapshot" +version = "0.1.0-alpha.10" +source = "git+https://github.com/paradigmxyz/reth.git#fc4fc936807870b07acb91e1d50c3920b55ff055" +dependencies = [ + "clap", + "reth-db", + "reth-interfaces", + "reth-nippy-jar", + "reth-primitives", + "reth-provider", + "thiserror", + "tokio", + "tracing", +] + +[[package]] +name = "reth-stages" +version = "0.1.0-alpha.10" +source = "git+https://github.com/paradigmxyz/reth.git#fc4fc936807870b07acb91e1d50c3920b55ff055" +dependencies = [ + "aquamarine", + "async-trait", + "futures-util", + "itertools 0.11.0", + "metrics", + "num-traits", + "pin-project", + "rayon", + "reth-codecs", + "reth-db", + "reth-interfaces", + "reth-metrics", + "reth-primitives", + "reth-provider", + "reth-tokio-util", + "reth-trie", + "revm", + "serde", + "thiserror", + "tokio", + "tokio-stream", + "tracing", +] + +[[package]] +name = "reth-tasks" +version = "0.1.0-alpha.10" +source = "git+https://github.com/paradigmxyz/reth.git#fc4fc936807870b07acb91e1d50c3920b55ff055" +dependencies = [ + "dyn-clone", + "futures-util", + "metrics", + "reth-metrics", + "thiserror", + "tokio", + "tracing", + "tracing-futures", +] + +[[package]] +name = "reth-tokio-util" +version = "0.1.0-alpha.10" +source = "git+https://github.com/paradigmxyz/reth.git#fc4fc936807870b07acb91e1d50c3920b55ff055" +dependencies = [ + "tokio", + "tokio-stream", +] + +[[package]] +name = "reth-tracing" +version = "0.1.0-alpha.10" +source = "git+https://github.com/paradigmxyz/reth.git#fc4fc936807870b07acb91e1d50c3920b55ff055" +dependencies = [ + "rolling-file", + "tracing", + "tracing-appender", + "tracing-journald", + "tracing-subscriber", +] + +[[package]] +name = "reth-transaction-pool" +version = "0.1.0-alpha.10" +source = "git+https://github.com/paradigmxyz/reth.git#fc4fc936807870b07acb91e1d50c3920b55ff055" +dependencies = [ + "alloy-rlp", + "aquamarine", + "async-trait", + "auto_impl", + "bitflags 2.4.1", + "fnv", + "futures-util", + "metrics", + "parking_lot 0.12.1", + "paste", + "rand 0.8.5", + "reth-interfaces", + "reth-metrics", + "reth-primitives", + "reth-provider", + "reth-tasks", + "revm", + "serde", + "thiserror", + "tokio", + "tokio-stream", + "tracing", +] + +[[package]] +name = "reth-trie" +version = "0.1.0-alpha.10" +source = "git+https://github.com/paradigmxyz/reth.git#fc4fc936807870b07acb91e1d50c3920b55ff055" +dependencies = [ + "alloy-rlp", + "auto_impl", + "derive_more", + "reth-db", + "reth-interfaces", + "reth-primitives", + "thiserror", + "tokio", + "tracing", +] + +[[package]] +name = "rethdb-reader" +version = "0.1.0" +dependencies = [ + "anyhow", + "reth", + "serde", + "serde_json", +] + +[[package]] +name = "revm" +version = "3.5.0" +source = "git+https://github.com/bluealloy/revm?rev=0d78d1eb304a2ce41ddac8f03206f5a316af247b#0d78d1eb304a2ce41ddac8f03206f5a316af247b" +dependencies = [ + "auto_impl", + "revm-interpreter", + "revm-precompile", +] + +[[package]] +name = "revm-interpreter" +version = "1.3.0" +source = "git+https://github.com/bluealloy/revm?rev=0d78d1eb304a2ce41ddac8f03206f5a316af247b#0d78d1eb304a2ce41ddac8f03206f5a316af247b" +dependencies = [ + "revm-primitives", +] + +[[package]] +name = "revm-precompile" +version = "2.2.0" +source = "git+https://github.com/bluealloy/revm?rev=0d78d1eb304a2ce41ddac8f03206f5a316af247b#0d78d1eb304a2ce41ddac8f03206f5a316af247b" +dependencies = [ + "aurora-engine-modexp", + "c-kzg", + "k256", + "once_cell", + "revm-primitives", + "ripemd", + "secp256k1 0.28.0", + "sha2", + "substrate-bn", +] + +[[package]] +name = "revm-primitives" +version = "1.3.0" +source = "git+https://github.com/bluealloy/revm?rev=0d78d1eb304a2ce41ddac8f03206f5a316af247b#0d78d1eb304a2ce41ddac8f03206f5a316af247b" +dependencies = [ + "alloy-primitives", + "alloy-rlp", + "auto_impl", + "bitflags 2.4.1", + "bitvec", + "c-kzg", + "derive_more", + "enumn", + "hashbrown 0.14.2", + "hex", + "once_cell", + "serde", +] + +[[package]] +name = "rfc6979" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f8dd2a808d456c4a54e300a23e9f5a67e122c3024119acbfd73e3bf664491cb2" +dependencies = [ + "hmac", + "subtle", +] + +[[package]] +name = "ring" +version = "0.16.20" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3053cf52e236a3ed746dfc745aa9cacf1b791d846bdaf412f60a8d7d6e17c8fc" +dependencies = [ + "cc", + "libc", + "once_cell", + "spin 0.5.2", + "untrusted 0.7.1", + "web-sys", + "winapi", +] + +[[package]] +name = "ring" +version = "0.17.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fb0205304757e5d899b9c2e448b867ffd03ae7f988002e47cd24954391394d0b" +dependencies = [ + "cc", + "getrandom 0.2.10", + "libc", + "spin 0.9.8", + "untrusted 0.9.0", + "windows-sys 0.48.0", +] + +[[package]] +name = "ripemd" +version = "0.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bd124222d17ad93a644ed9d011a40f4fb64aa54275c08cc216524a9ea82fb09f" +dependencies = [ + "digest 0.10.7", +] + +[[package]] +name = "rlimit" +version = "0.10.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3560f70f30a0f16d11d01ed078a07740fe6b489667abc7c7b029155d9f21c3d8" +dependencies = [ + "libc", +] + +[[package]] +name = "rlp" +version = "0.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bb919243f34364b6bd2fc10ef797edbfa75f33c252e7998527479c6d6b47e1ec" +dependencies = [ + "bytes", + "rustc-hex", +] + +[[package]] +name = "rolling-file" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8395b4f860856b740f20a296ea2cd4d823e81a2658cf05ef61be22916026a906" +dependencies = [ + "chrono", +] + +[[package]] +name = "route-recognizer" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "afab94fb28594581f62d981211a9a4d53cc8130bbcbbb89a0440d9b8e81a7746" + +[[package]] +name = "ruint" +version = "1.10.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "95294d6e3a6192f3aabf91c38f56505a625aa495533442744185a36d75a790c4" +dependencies = [ + "alloy-rlp", + "arbitrary", + "ark-ff 0.3.0", + "ark-ff 0.4.2", + "bytes", + "fastrlp", + "num-bigint", + "parity-scale-codec", + "primitive-types", + "proptest", + "rand 0.8.5", + "rlp", + "ruint-macro", + "serde", + "valuable", + "zeroize", +] + +[[package]] +name = "ruint-macro" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e666a5496a0b2186dbcd0ff6106e29e093c15591bde62c20d3842007c6978a09" + +[[package]] +name = "rustc-demangle" +version = "0.1.23" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d626bb9dae77e28219937af045c257c28bfd3f69333c512553507f5f9798cb76" + +[[package]] +name = "rustc-hash" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "08d43f7aa6b08d49f382cde6a7982047c3426db949b1424bc4b7ec9ae12c6ce2" + +[[package]] +name = "rustc-hex" +version = "2.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3e75f6a532d0fd9f7f13144f392b6ad56a32696bfcd9c78f797f16bbb6f072d6" + +[[package]] +name = "rustc_version" +version = "0.3.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f0dfe2087c51c460008730de8b57e6a320782fbfb312e1f4d520e6c6fae155ee" +dependencies = [ + "semver 0.11.0", +] + +[[package]] +name = "rustc_version" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bfa0f585226d2e68097d4f95d113b15b83a82e819ab25717ec0590d9584ef366" +dependencies = [ + "semver 1.0.20", +] + +[[package]] +name = "rustix" +version = "0.36.16" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6da3636faa25820d8648e0e31c5d519bbb01f72fdf57131f0f5f7da5fed36eab" +dependencies = [ + "bitflags 1.3.2", + "errno 0.3.5", + "io-lifetimes", + "libc", + "linux-raw-sys 0.1.4", + "windows-sys 0.45.0", +] + +[[package]] +name = "rustix" +version = "0.38.20" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "67ce50cb2e16c2903e30d1cbccfd8387a74b9d4c938b6a4c5ec6cc7556f7a8a0" +dependencies = [ + "bitflags 2.4.1", + "errno 0.3.5", + "libc", + "linux-raw-sys 0.4.10", + "windows-sys 0.48.0", +] + +[[package]] +name = "rustls" +version = "0.21.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "446e14c5cda4f3f30fe71863c34ec70f5ac79d6087097ad0bb433e1be5edf04c" +dependencies = [ + "log", + "ring 0.17.5", + "rustls-webpki", + "sct", +] + +[[package]] +name = "rustls-native-certs" +version = "0.6.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a9aace74cb666635c918e9c12bc0d348266037aa8eb599b5cba565709a8dff00" +dependencies = [ + "openssl-probe", + "rustls-pemfile", + "schannel", + "security-framework", +] + +[[package]] +name = "rustls-pemfile" +version = "1.0.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2d3987094b1d07b653b7dfdc3f70ce9a1da9c51ac18c1b06b662e4f9a0e9f4b2" +dependencies = [ + "base64 0.21.5", +] + +[[package]] +name = "rustls-webpki" +version = "0.101.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8b6275d1ee7a1cd780b64aca7726599a1dbc893b1e64144529e55c3c2f745765" +dependencies = [ + "ring 0.17.5", + "untrusted 0.9.0", +] + +[[package]] +name = "rustversion" +version = "1.0.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7ffc183a10b4478d04cbbbfc96d0873219d962dd5accaff2ffbd4ceb7df837f4" + +[[package]] +name = "rusty-fork" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cb3dcc6e454c328bb824492db107ab7c0ae8fcffe4ad210136ef014458c1bc4f" +dependencies = [ + "fnv", + "quick-error", + "tempfile", + "wait-timeout", +] + +[[package]] +name = "ryu" +version = "1.0.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1ad4cc8da4ef723ed60bced201181d83791ad433213d8c24efffda1eec85d741" + +[[package]] +name = "ryu-js" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6518fc26bced4d53678a22d6e423e9d8716377def84545fe328236e3af070e7f" + +[[package]] +name = "schannel" +version = "0.1.22" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0c3733bf4cf7ea0880754e19cb5a462007c4a8c1914bff372ccc95b464f1df88" +dependencies = [ + "windows-sys 0.48.0", +] + +[[package]] +name = "schnellru" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "772575a524feeb803e5b0fcbc6dd9f367e579488197c94c6e4023aad2305774d" +dependencies = [ + "ahash", + "cfg-if", + "hashbrown 0.13.2", +] + +[[package]] +name = "scopeguard" +version = "1.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "94143f37725109f92c262ed2cf5e59bce7498c01bcc1502d7b9afe439a4e9f49" + +[[package]] +name = "sct" +version = "0.7.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "da046153aa2352493d6cb7da4b6e5c0c057d8a1d0a9aa8560baffdd945acd414" +dependencies = [ + "ring 0.17.5", + "untrusted 0.9.0", +] + +[[package]] +name = "sec1" +version = "0.7.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d3e97a565f76233a6003f9f5c54be1d9c5bdfa3eccfb189469f11ec4901c47dc" +dependencies = [ + "base16ct", + "der", + "generic-array", + "pkcs8", + "subtle", + "zeroize", +] + +[[package]] +name = "secp256k1" +version = "0.27.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "25996b82292a7a57ed3508f052cfff8640d38d32018784acd714758b43da9c8f" +dependencies = [ + "rand 0.8.5", + "secp256k1-sys 0.8.1", + "serde", +] + +[[package]] +name = "secp256k1" +version = "0.28.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2acea373acb8c21ecb5a23741452acd2593ed44ee3d343e72baaa143bc89d0d5" +dependencies = [ + "secp256k1-sys 0.9.0", +] + +[[package]] +name = "secp256k1-sys" +version = "0.8.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "70a129b9e9efbfb223753b9163c4ab3b13cff7fd9c7f010fbac25ab4099fa07e" +dependencies = [ + "cc", +] + +[[package]] +name = "secp256k1-sys" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "09e67c467c38fd24bd5499dc9a18183b31575c12ee549197e3e20d57aa4fe3b7" +dependencies = [ + "cc", +] + +[[package]] +name = "security-framework" +version = "2.9.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "05b64fb303737d99b81884b2c63433e9ae28abebe5eb5045dcdd175dc2ecf4de" +dependencies = [ + "bitflags 1.3.2", + "core-foundation", + "core-foundation-sys", + "libc", + "security-framework-sys", +] + +[[package]] +name = "security-framework-sys" +version = "2.9.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e932934257d3b408ed8f30db49d85ea163bfe74961f017f405b025af298f0c7a" +dependencies = [ + "core-foundation-sys", + "libc", +] + +[[package]] +name = "semver" +version = "0.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f301af10236f6df4160f7c3f04eec6dbc70ace82d23326abad5edee88801c6b6" +dependencies = [ + "semver-parser", +] + +[[package]] +name = "semver" +version = "1.0.20" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "836fa6a3e1e547f9a2c4040802ec865b5d85f4014efe00555d7090a3dcaa1090" + +[[package]] +name = "semver-parser" +version = "0.10.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "00b0bef5b7f9e0df16536d3961cfb6e84331c065b4066afb39768d0e319411f7" +dependencies = [ + "pest", +] + +[[package]] +name = "send_wrapper" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f638d531eccd6e23b980caf34876660d38e265409d8e99b397ab71eb3612fad0" + +[[package]] +name = "serde" +version = "1.0.190" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "91d3c334ca1ee894a2c6f6ad698fe8c435b76d504b13d436f0685d648d6d96f7" +dependencies = [ + "serde_derive", +] + +[[package]] +name = "serde_bytes" +version = "0.11.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ab33ec92f677585af6d88c65593ae2375adde54efdbf16d597f2cbc7a6d368ff" +dependencies = [ + "serde", +] + +[[package]] +name = "serde_derive" +version = "1.0.190" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "67c5609f394e5c2bd7fc51efda478004ea80ef42fee983d5c67a65e34f32c0e3" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.38", +] + +[[package]] +name = "serde_json" +version = "1.0.107" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6b420ce6e3d8bd882e9b243c6eed35dbc9a6110c9769e74b584e0d68d1f20c65" +dependencies = [ + "itoa", + "ryu", + "serde", +] + +[[package]] +name = "serde_spanned" +version = "0.6.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "12022b835073e5b11e90a14f86838ceb1c8fb0325b72416845c487ac0fa95e80" +dependencies = [ + "serde", +] + +[[package]] +name = "serde_with" +version = "3.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "64cd236ccc1b7a29e7e2739f27c0b2dd199804abc4290e32f59f3b68d6405c23" +dependencies = [ + "base64 0.21.5", + "chrono", + "hex", + "indexmap 1.9.3", + "indexmap 2.0.2", + "serde", + "serde_json", + "serde_with_macros", + "time", +] + +[[package]] +name = "serde_with_macros" +version = "3.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "93634eb5f75a2323b16de4748022ac4297f9e76b6dced2be287a099f41b5e788" +dependencies = [ + "darling 0.20.3", + "proc-macro2", + "quote", + "syn 2.0.38", +] + +[[package]] +name = "sha-1" +version = "0.9.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "99cd6713db3cf16b6c84e06321e049a9b9f699826e16096d23bbcc44d15d51a6" +dependencies = [ + "block-buffer 0.9.0", + "cfg-if", + "cpufeatures", + "digest 0.9.0", + "opaque-debug", +] + +[[package]] +name = "sha2" +version = "0.10.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "793db75ad2bcafc3ffa7c68b215fee268f537982cd901d132f89c6343f3a3dc8" +dependencies = [ + "cfg-if", + "cpufeatures", + "digest 0.10.7", +] + +[[package]] +name = "sha3" +version = "0.10.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "75872d278a8f37ef87fa0ddbda7802605cb18344497949862c0d4dcb291eba60" +dependencies = [ + "digest 0.10.7", + "keccak", +] + +[[package]] +name = "sharded-slab" +version = "0.1.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f40ca3c46823713e0d4209592e8d6e826aa57e928f09752619fc696c499637f6" +dependencies = [ + "lazy_static", +] + +[[package]] +name = "shellexpand" +version = "3.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "da03fa3b94cc19e3ebfc88c4229c49d8f08cdbd1228870a45f0ffdf84988e14b" +dependencies = [ + "dirs", +] + +[[package]] +name = "shlex" +version = "1.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a7cee0529a6d40f580e7a5e6c495c8fbfe21b7b52795ed4bb5e62cdf92bc6380" + +[[package]] +name = "signal-hook" +version = "0.3.17" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8621587d4798caf8eb44879d42e56b9a93ea5dcd315a6487c357130095b62801" +dependencies = [ + "libc", + "signal-hook-registry", +] + +[[package]] +name = "signal-hook-mio" +version = "0.2.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "29ad2e15f37ec9a6cc544097b78a1ec90001e9f71b81338ca39f430adaca99af" +dependencies = [ + "libc", + "mio", + "signal-hook", +] + +[[package]] +name = "signal-hook-registry" +version = "1.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d8229b473baa5980ac72ef434c4415e70c4b5e71b423043adb4ba059f89c99a1" +dependencies = [ + "libc", +] + +[[package]] +name = "signature" +version = "2.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5e1788eed21689f9cf370582dfc467ef36ed9c707f073528ddafa8d83e3b8500" +dependencies = [ + "digest 0.10.7", + "rand_core 0.6.4", +] + +[[package]] +name = "simple_asn1" +version = "0.6.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "adc4e5204eb1910f40f9cfa375f6f05b68c3abac4b6fd879c8ff5e7ae8a0a085" +dependencies = [ + "num-bigint", + "num-traits", + "thiserror", + "time", +] + +[[package]] +name = "siphasher" +version = "0.3.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "38b58827f4464d87d377d175e90bf58eb00fd8716ff0a62f80356b5e61555d0d" + +[[package]] +name = "sketches-ddsketch" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "68a406c1882ed7f29cd5e248c9848a80e7cb6ae0fea82346d2746f2f941c07e1" + +[[package]] +name = "slab" +version = "0.4.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8f92a496fb766b417c996b9c5e57daf2f7ad3b0bebe1ccfca4856390e3d3bb67" +dependencies = [ + "autocfg", +] + +[[package]] +name = "smallvec" +version = "1.11.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "942b4a808e05215192e39f4ab80813e599068285906cc91aa64f923db842bd5a" + +[[package]] +name = "smol_str" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "74212e6bbe9a4352329b2f68ba3130c15a3f26fe88ff22dbdc6cdd58fa85e99c" +dependencies = [ + "serde", +] + +[[package]] +name = "snap" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5e9f0ab6ef7eb7353d9119c170a436d1bf248eea575ac42d19d12f4e34130831" + +[[package]] +name = "socket2" +version = "0.4.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9f7916fc008ca5542385b89a3d3ce689953c143e9304a9bf8beec1de48994c0d" +dependencies = [ + "libc", + "winapi", +] + +[[package]] +name = "socket2" +version = "0.5.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7b5fac59a5cb5dd637972e5fca70daf0523c9067fcdc4842f053dae04a18f8e9" +dependencies = [ + "libc", + "windows-sys 0.48.0", +] + +[[package]] +name = "soketto" +version = "0.7.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "41d1c5305e39e09653383c2c7244f2f78b3bcae37cf50c64cb4789c9f5096ec2" +dependencies = [ + "base64 0.13.1", + "bytes", + "futures", + "http", + "httparse", + "log", + "rand 0.8.5", + "sha-1", +] + +[[package]] +name = "spin" +version = "0.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6e63cff320ae2c57904679ba7cb63280a3dc4613885beafb148ee7bf9aa9042d" + +[[package]] +name = "spin" +version = "0.9.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6980e8d7511241f8acf4aebddbb1ff938df5eebe98691418c4468d0b72a96a67" +dependencies = [ + "lock_api", +] + +[[package]] +name = "spki" +version = "0.7.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9d1e996ef02c474957d681f1b05213dfb0abab947b446a62d37770b23500184a" +dependencies = [ + "base64ct", + "der", +] + +[[package]] +name = "sptr" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3b9b39299b249ad65f3b7e96443bad61c02ca5cd3589f46cb6d610a0fd6c0d6a" + +[[package]] +name = "stable_deref_trait" +version = "1.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a8f112729512f8e442d81f95a8a7ddf2b7c6b8a1a6f509a95864142b30cab2d3" + +[[package]] +name = "static_assertions" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a2eb9349b6444b326872e140eb1cf5e7c522154d69e7a0ffb0fb81c06b37543f" + +[[package]] +name = "strsim" +version = "0.9.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6446ced80d6c486436db5c078dde11a9f73d42b57fb273121e160b84f63d894c" + +[[package]] +name = "strsim" +version = "0.10.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "73473c0e59e6d5812c5dfe2a064a6444949f089e20eec9a2e5506596494e4623" + +[[package]] +name = "strum" +version = "0.25.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "290d54ea6f91c969195bdbcd7442c8c2a2ba87da8bf60a7ee86a235d4bc1e125" +dependencies = [ + "strum_macros", +] + +[[package]] +name = "strum_macros" +version = "0.25.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "23dc1fa9ac9c169a78ba62f0b841814b7abae11bdd047b9c58f893439e309ea0" +dependencies = [ + "heck", + "proc-macro2", + "quote", + "rustversion", + "syn 2.0.38", +] + +[[package]] +name = "substrate-bn" +version = "0.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "72b5bbfa79abbae15dd642ea8176a21a635ff3c00059961d1ea27ad04e5b441c" +dependencies = [ + "byteorder", + "crunchy", + "lazy_static", + "rand 0.8.5", + "rustc-hex", +] + +[[package]] +name = "subtle" +version = "2.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "81cdd64d312baedb58e21336b31bc043b77e01cc99033ce76ef539f78e965ebc" + +[[package]] +name = "sucds" +version = "0.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "64accd20141dfbef67ad83c51d588146cff7810616e1bda35a975be369059533" +dependencies = [ + "anyhow", +] + +[[package]] +name = "sucds" +version = "0.8.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d53d46182afe6ed822a94c54a532dc0d59691a8f49226bdc4596529ca864cdd6" +dependencies = [ + "anyhow", + "num-traits", +] + +[[package]] +name = "syn" +version = "1.0.109" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "72b64191b275b66ffe2469e8af2c1cfe3bafa67b529ead792a6d0160888b4237" +dependencies = [ + "proc-macro2", + "quote", + "unicode-ident", +] + +[[package]] +name = "syn" +version = "2.0.38" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e96b79aaa137db8f61e26363a0c9b47d8b4ec75da28b7d1d614c2303e232408b" +dependencies = [ + "proc-macro2", + "quote", + "unicode-ident", +] + +[[package]] +name = "syn-solidity" +version = "0.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "86b837ef12ab88835251726eb12237655e61ec8dc8a280085d1961cdc3dfd047" +dependencies = [ + "paste", + "proc-macro2", + "quote", + "syn 2.0.38", +] + +[[package]] +name = "synstructure" +version = "0.13.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "285ba80e733fac80aa4270fbcdf83772a79b80aa35c97075320abfee4a915b06" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.38", + "unicode-xid", +] + +[[package]] +name = "tap" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "55937e1799185b12863d447f42597ed69d9928686b8d88a1df17376a097d8369" + +[[package]] +name = "tempfile" +version = "3.8.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cb94d2f3cc536af71caac6b6fcebf65860b347e7ce0cc9ebe8f70d3e521054ef" +dependencies = [ + "cfg-if", + "fastrand 2.0.1", + "redox_syscall 0.3.5", + "rustix 0.38.20", + "windows-sys 0.48.0", +] + +[[package]] +name = "thin-vec" +version = "0.2.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "aac81b6fd6beb5884b0cf3321b8117e6e5d47ecb6fc89f414cfdcca8b2fe2dd8" + +[[package]] +name = "thiserror" +version = "1.0.50" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f9a7210f5c9a7156bb50aa36aed4c95afb51df0df00713949448cf9e97d382d2" +dependencies = [ + "thiserror-impl", +] + +[[package]] +name = "thiserror-impl" +version = "1.0.50" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "266b2e40bc00e5a6c09c3584011e08b06f123c00362c92b975ba9843aaaa14b8" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.38", +] + +[[package]] +name = "thread_local" +version = "1.1.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3fdd6f064ccff2d6567adcb3873ca630700f00b5ad3f060c25b5dcfd9a4ce152" +dependencies = [ + "cfg-if", + "once_cell", +] + +[[package]] +name = "threadpool" +version = "1.8.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d050e60b33d41c19108b32cea32164033a9013fe3b46cbd4457559bfbf77afaa" +dependencies = [ + "num_cpus", +] + +[[package]] +name = "time" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c4a34ab300f2dee6e562c10a046fc05e358b29f9bf92277f30c3c8d82275f6f5" +dependencies = [ + "deranged", + "itoa", + "libc", + "num_threads", + "powerfmt", + "serde", + "time-core", + "time-macros", +] + +[[package]] +name = "time-core" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ef927ca75afb808a4d64dd374f00a2adf8d0fcff8e7b184af886c3c87ec4a3f3" + +[[package]] +name = "time-macros" +version = "0.2.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4ad70d68dba9e1f8aceda7aa6711965dfec1cac869f311a51bd08b3a2ccbce20" +dependencies = [ + "time-core", +] + +[[package]] +name = "tiny-keccak" +version = "2.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2c9d3793400a45f954c52e73d068316d76b6f4e36977e3fcebb13a2721e80237" +dependencies = [ + "crunchy", +] + +[[package]] +name = "tinystr" +version = "0.7.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8faa444297615a4e020acb64146b0603c9c395c03a97c17fd9028816d3b4d63e" +dependencies = [ + "displaydoc", + "serde", + "zerovec", +] + +[[package]] +name = "tinyvec" +version = "1.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "87cc5ceb3875bb20c2890005a4e226a4651264a5c75edb2421b52861a0a0cb50" +dependencies = [ + "tinyvec_macros", +] + +[[package]] +name = "tinyvec_macros" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" + +[[package]] +name = "tokio" +version = "1.33.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4f38200e3ef7995e5ef13baec2f432a6da0aa9ac495b2c0e8f3b7eec2c92d653" +dependencies = [ + "backtrace", + "bytes", + "libc", + "mio", + "num_cpus", + "parking_lot 0.12.1", + "pin-project-lite", + "signal-hook-registry", + "socket2 0.5.5", + "tokio-macros", + "windows-sys 0.48.0", +] + +[[package]] +name = "tokio-macros" +version = "2.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "630bdcf245f78637c13ec01ffae6187cca34625e8c63150d424b59e55af2675e" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.38", +] + +[[package]] +name = "tokio-rustls" +version = "0.24.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c28327cf380ac148141087fbfb9de9d7bd4e84ab5d2c28fbc911d753de8a7081" +dependencies = [ + "rustls", + "tokio", +] + +[[package]] +name = "tokio-stream" +version = "0.1.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "397c988d37662c7dda6d2208364a706264bf3d6138b11d436cbac0ad38832842" +dependencies = [ + "futures-core", + "pin-project-lite", + "tokio", + "tokio-util", +] + +[[package]] +name = "tokio-util" +version = "0.7.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5419f34732d9eb6ee4c3578b7989078579b7f039cbbb9ca2c4da015749371e15" +dependencies = [ + "bytes", + "futures-core", + "futures-io", + "futures-sink", + "pin-project-lite", + "slab", + "tokio", + "tracing", +] + +[[package]] +name = "toml" +version = "0.5.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f4f7f0dd8d50a853a531c426359045b1998f04219d88799810762cd4ad314234" +dependencies = [ + "serde", +] + +[[package]] +name = "toml" +version = "0.8.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3efaf127c78d5339cc547cce4e4d973bd5e4f56e949a06d091c082ebeef2f800" +dependencies = [ + "serde", + "serde_spanned", + "toml_datetime", + "toml_edit 0.20.5", +] + +[[package]] +name = "toml_datetime" +version = "0.6.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3550f4e9685620ac18a50ed434eb3aec30db8ba93b0287467bca5826ea25baf1" +dependencies = [ + "serde", +] + +[[package]] +name = "toml_edit" +version = "0.19.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1b5bb770da30e5cbfde35a2d7b9b8a2c4b8ef89548a7a6aeab5c9a576e3e7421" +dependencies = [ + "indexmap 2.0.2", + "toml_datetime", + "winnow", +] + +[[package]] +name = "toml_edit" +version = "0.20.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "782bf6c2ddf761c1e7855405e8975472acf76f7f36d0d4328bd3b7a2fae12a85" +dependencies = [ + "indexmap 2.0.2", + "serde", + "serde_spanned", + "toml_datetime", + "winnow", +] + +[[package]] +name = "tower" +version = "0.4.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b8fa9be0de6cf49e536ce1851f987bd21a43b771b09473c3549a6c853db37c1c" +dependencies = [ + "futures-core", + "futures-util", + "hdrhistogram", + "indexmap 1.9.3", + "pin-project", + "pin-project-lite", + "rand 0.8.5", + "slab", + "tokio", + "tokio-util", + "tower-layer", + "tower-service", + "tracing", +] + +[[package]] +name = "tower-http" +version = "0.4.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "61c5bb1d698276a2443e5ecfabc1008bf15a36c12e6a7176e7bf089ea9131140" +dependencies = [ + "async-compression", + "base64 0.21.5", + "bitflags 2.4.1", + "bytes", + "futures-core", + "futures-util", + "http", + "http-body", + "http-range-header", + "httpdate", + "iri-string", + "mime", + "mime_guess", + "percent-encoding", + "pin-project-lite", + "tokio", + "tokio-util", + "tower", + "tower-layer", + "tower-service", + "tracing", + "uuid", +] + +[[package]] +name = "tower-layer" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c20c8dbed6283a09604c3e69b4b7eeb54e298b8a600d4d5ecb5ad39de609f1d0" + +[[package]] +name = "tower-service" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b6bc1c9ce2b5135ac7f93c72918fc37feb872bdc6a5533a8b85eb4b86bfdae52" + +[[package]] +name = "tracing" +version = "0.1.40" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c3523ab5a71916ccf420eebdf5521fcef02141234bbc0b8a49f2fdc4544364ef" +dependencies = [ + "log", + "pin-project-lite", + "tracing-attributes", + "tracing-core", +] + +[[package]] +name = "tracing-appender" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "09d48f71a791638519505cefafe162606f706c25592e4bde4d97600c0195312e" +dependencies = [ + "crossbeam-channel", + "time", + "tracing-subscriber", +] + +[[package]] +name = "tracing-attributes" +version = "0.1.27" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "34704c8d6ebcbc939824180af020566b01a7c01f80641264eba0999f6c2b6be7" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.38", +] + +[[package]] +name = "tracing-core" +version = "0.1.32" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c06d3da6113f116aaee68e4d601191614c9053067f9ab7f6edbcb161237daa54" +dependencies = [ + "once_cell", + "valuable", +] + +[[package]] +name = "tracing-futures" +version = "0.2.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "97d095ae15e245a057c8e8451bab9b3ee1e1f68e9ba2b4fbc18d0ac5237835f2" +dependencies = [ + "futures", + "futures-task", + "pin-project", + "tracing", +] + +[[package]] +name = "tracing-journald" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ba316a74e8fc3c3896a850dba2375928a9fa171b085ecddfc7c054d39970f3fd" +dependencies = [ + "libc", + "tracing-core", + "tracing-subscriber", +] + +[[package]] +name = "tracing-log" +version = "0.1.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f751112709b4e791d8ce53e32c4ed2d353565a795ce84da2285393f41557bdf2" +dependencies = [ + "log", + "once_cell", + "tracing-core", +] + +[[package]] +name = "tracing-subscriber" +version = "0.3.17" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "30a651bc37f915e81f087d86e62a18eec5f79550c7faff886f7090b4ea757c77" +dependencies = [ + "matchers", + "nu-ansi-term", + "once_cell", + "regex", + "sharded-slab", + "smallvec", + "thread_local", + "tracing", + "tracing-core", + "tracing-log", +] + +[[package]] +name = "trust-dns-client" +version = "0.20.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5b4ef9b9bde0559b78a4abb00339143750085f05e5a453efb7b8bef1061f09dc" +dependencies = [ + "cfg-if", + "data-encoding", + "futures-channel", + "futures-util", + "lazy_static", + "log", + "radix_trie", + "rand 0.8.5", + "thiserror", + "time", + "tokio", + "trust-dns-proto 0.20.4", +] + +[[package]] +name = "trust-dns-proto" +version = "0.20.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ca94d4e9feb6a181c690c4040d7a24ef34018d8313ac5044a61d21222ae24e31" +dependencies = [ + "async-trait", + "cfg-if", + "data-encoding", + "enum-as-inner 0.3.4", + "futures-channel", + "futures-io", + "futures-util", + "idna 0.2.3", + "ipnet", + "lazy_static", + "log", + "rand 0.8.5", + "smallvec", + "thiserror", + "tinyvec", + "tokio", + "url", +] + +[[package]] +name = "trust-dns-proto" +version = "0.23.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3119112651c157f4488931a01e586aa459736e9d6046d3bd9105ffb69352d374" +dependencies = [ + "async-trait", + "cfg-if", + "data-encoding", + "enum-as-inner 0.6.0", + "futures-channel", + "futures-io", + "futures-util", + "idna 0.4.0", + "ipnet", + "once_cell", + "rand 0.8.5", + "smallvec", + "thiserror", + "tinyvec", + "tokio", + "tracing", + "url", +] + +[[package]] +name = "trust-dns-resolver" +version = "0.23.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "10a3e6c3aff1718b3c73e395d1f35202ba2ffa847c6a62eea0db8fb4cfe30be6" +dependencies = [ + "cfg-if", + "futures-util", + "ipconfig", + "lru-cache", + "once_cell", + "parking_lot 0.12.1", + "rand 0.8.5", + "resolv-conf", + "smallvec", + "thiserror", + "tokio", + "tracing", + "trust-dns-proto 0.23.2", +] + +[[package]] +name = "try-lock" +version = "0.2.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3528ecfd12c466c6f163363caf2d02a71161dd5e1cc6ae7b34207ea2d42d81ed" + +[[package]] +name = "tui" +version = "0.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ccdd26cbd674007e649a272da4475fb666d3aa0ad0531da7136db6fab0e5bad1" +dependencies = [ + "bitflags 1.3.2", + "cassowary", + "crossterm 0.25.0", + "unicode-segmentation", + "unicode-width", +] + +[[package]] +name = "typenum" +version = "1.17.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "42ff0bf0c66b8238c6f3b578df37d0b7848e55df8577b3f74f92a69acceeb825" + +[[package]] +name = "ucd-trie" +version = "0.1.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ed646292ffc8188ef8ea4d1e0e0150fb15a5c2e12ad9b8fc191ae7a8a7f3c4b9" + +[[package]] +name = "uint" +version = "0.9.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "76f64bba2c53b04fcab63c01a7d7427eadc821e3bc48c34dc9ba29c501164b52" +dependencies = [ + "byteorder", + "crunchy", + "hex", + "static_assertions", +] + +[[package]] +name = "unarray" +version = "0.1.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "eaea85b334db583fe3274d12b4cd1880032beab409c0d774be044d4480ab9a94" + +[[package]] +name = "unicase" +version = "2.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f7d2d4dafb69621809a81864c9c1b864479e1235c0dd4e199924b9742439ed89" +dependencies = [ + "version_check", +] + +[[package]] +name = "unicode-bidi" +version = "0.3.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "92888ba5573ff080736b3648696b70cafad7d250551175acbaa4e0385b3e1460" + +[[package]] +name = "unicode-ident" +version = "1.0.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" + +[[package]] +name = "unicode-normalization" +version = "0.1.22" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5c5713f0fc4b5db668a2ac63cdb7bb4469d8c9fed047b1d0292cc7b0ce2ba921" +dependencies = [ + "tinyvec", +] + +[[package]] +name = "unicode-segmentation" +version = "1.10.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1dd624098567895118886609431a7c3b8f516e41d30e0643f03d94592a147e36" + +[[package]] +name = "unicode-width" +version = "0.1.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e51733f11c9c4f72aa0c160008246859e340b00807569a0da0e7a1079b27ba85" + +[[package]] +name = "unicode-xid" +version = "0.2.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f962df74c8c05a667b5ee8bcf162993134c104e96440b663c8daa176dc772d8c" + +[[package]] +name = "universal-hash" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8326b2c654932e3e4f9196e69d08fdf7cfd718e1dc6f66b347e6024a0c961402" +dependencies = [ + "generic-array", + "subtle", +] + +[[package]] +name = "untrusted" +version = "0.7.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a156c684c91ea7d62626509bce3cb4e1d9ed5c4d978f7b4352658f96a4c26b4a" + +[[package]] +name = "untrusted" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8ecb6da28b8a351d773b68d5825ac39017e680750f980f3a1a85cd8dd28a47c1" + +[[package]] +name = "url" +version = "2.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "143b538f18257fac9cad154828a57c6bf5157e1aa604d4816b5995bf6de87ae5" +dependencies = [ + "form_urlencoded", + "idna 0.4.0", + "percent-encoding", +] + +[[package]] +name = "utf16_iter" +version = "1.0.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "52df8b7fb78e7910d776fccf2e42ceaf3604d55e8e7eb2dbd183cb1441d8a692" + +[[package]] +name = "utf8_iter" +version = "1.0.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "64a8922555b9500e3d865caed19330172cd67cbf82203f1a3311d8c305cc9f33" + +[[package]] +name = "utf8parse" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "711b9620af191e0cdc7468a8d14e709c3dcdb115b36f838e601583af800a370a" + +[[package]] +name = "uuid" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "88ad59a7560b41a70d191093a945f0b87bc1deeda46fb237479708a1d6b6cdfc" +dependencies = [ + "getrandom 0.2.10", +] + +[[package]] +name = "valuable" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "830b7e5d4d90034032940e4ace0d9a9a057e7a45cd94e6c007832e39edb82f6d" + +[[package]] +name = "vergen" +version = "8.2.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "85e7dc29b3c54a2ea67ef4f953d5ec0c4085035c0ae2d325be1c0d2144bd9f16" +dependencies = [ + "anyhow", + "rustversion", + "time", +] + +[[package]] +name = "version_check" +version = "0.9.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483f" + +[[package]] +name = "wait-timeout" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9f200f5b12eb75f8c1ed65abd4b2db8a6e1b138a20de009dacee265a2498f3f6" +dependencies = [ + "libc", +] + +[[package]] +name = "want" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bfa7760aed19e106de2c7c0b581b509f2f25d3dacaf737cb82ac61bc6d760b0e" +dependencies = [ + "try-lock", +] + +[[package]] +name = "wasi" +version = "0.9.0+wasi-snapshot-preview1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cccddf32554fecc6acb585f82a32a72e28b48f8c4c1883ddfeeeaa96f7d8e519" + +[[package]] +name = "wasi" +version = "0.11.0+wasi-snapshot-preview1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" + +[[package]] +name = "wasm-bindgen" +version = "0.2.87" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7706a72ab36d8cb1f80ffbf0e071533974a60d0a308d01a5d0375bf60499a342" +dependencies = [ + "cfg-if", + "wasm-bindgen-macro", +] + +[[package]] +name = "wasm-bindgen-backend" +version = "0.2.87" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5ef2b6d3c510e9625e5fe6f509ab07d66a760f0885d858736483c32ed7809abd" +dependencies = [ + "bumpalo", + "log", + "once_cell", + "proc-macro2", + "quote", + "syn 2.0.38", + "wasm-bindgen-shared", +] + +[[package]] +name = "wasm-bindgen-futures" +version = "0.4.37" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c02dbc21516f9f1f04f187958890d7e6026df8d16540b7ad9492bc34a67cea03" +dependencies = [ + "cfg-if", + "js-sys", + "wasm-bindgen", + "web-sys", +] + +[[package]] +name = "wasm-bindgen-macro" +version = "0.2.87" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dee495e55982a3bd48105a7b947fd2a9b4a8ae3010041b9e0faab3f9cd028f1d" +dependencies = [ + "quote", + "wasm-bindgen-macro-support", +] + +[[package]] +name = "wasm-bindgen-macro-support" +version = "0.2.87" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "54681b18a46765f095758388f2d0cf16eb8d4169b639ab575a8f5693af210c7b" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.38", + "wasm-bindgen-backend", + "wasm-bindgen-shared", +] + +[[package]] +name = "wasm-bindgen-shared" +version = "0.2.87" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ca6ad05a4870b2bf5fe995117d3728437bd27d7cd5f06f13c17443ef369775a1" + +[[package]] +name = "web-sys" +version = "0.3.64" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9b85cbef8c220a6abc02aefd892dfc0fc23afb1c6a426316ec33253a3877249b" +dependencies = [ + "js-sys", + "wasm-bindgen", +] + +[[package]] +name = "webpki-roots" +version = "0.25.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "14247bb57be4f377dfb94c72830b8ce8fc6beac03cf4bf7b9732eadd414123fc" + +[[package]] +name = "which" +version = "4.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "87ba24419a2078cd2b0f2ede2691b6c66d8e47836da3b6db8265ebad47afbfc7" +dependencies = [ + "either", + "home", + "once_cell", + "rustix 0.38.20", +] + +[[package]] +name = "widestring" +version = "1.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "653f141f39ec16bba3c5abe400a0c60da7468261cc2cbf36805022876bc721a8" + +[[package]] +name = "wildmatch" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7f44b95f62d34113cf558c93511ac93027e03e9c29a60dd0fd70e6e025c7270a" + +[[package]] +name = "winapi" +version = "0.3.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5c839a674fcd7a98952e593242ea400abe93992746761e38641405d28b00f419" +dependencies = [ + "winapi-i686-pc-windows-gnu", + "winapi-x86_64-pc-windows-gnu", +] + +[[package]] +name = "winapi-i686-pc-windows-gnu" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ac3b87c63620426dd9b991e5ce0329eff545bccbbb34f3be09ff6fb6ab51b7b6" + +[[package]] +name = "winapi-x86_64-pc-windows-gnu" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f" + +[[package]] +name = "windows" +version = "0.51.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ca229916c5ee38c2f2bc1e9d8f04df975b4bd93f9955dc69fabb5d91270045c9" +dependencies = [ + "windows-core", + "windows-targets 0.48.5", +] + +[[package]] +name = "windows-core" +version = "0.51.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f1f8cf84f35d2db49a46868f947758c7a1138116f7fac3bc844f43ade1292e64" +dependencies = [ + "windows-targets 0.48.5", +] + +[[package]] +name = "windows-sys" +version = "0.45.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "75283be5efb2831d37ea142365f009c02ec203cd29a3ebecbc093d52315b66d0" +dependencies = [ + "windows-targets 0.42.2", +] + +[[package]] +name = "windows-sys" +version = "0.48.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "677d2418bec65e3338edb076e806bc1ec15693c5d0104683f2efe857f61056a9" +dependencies = [ + "windows-targets 0.48.5", +] + +[[package]] +name = "windows-targets" +version = "0.42.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8e5180c00cd44c9b1c88adb3693291f1cd93605ded80c250a75d472756b4d071" +dependencies = [ + "windows_aarch64_gnullvm 0.42.2", + "windows_aarch64_msvc 0.42.2", + "windows_i686_gnu 0.42.2", + "windows_i686_msvc 0.42.2", + "windows_x86_64_gnu 0.42.2", + "windows_x86_64_gnullvm 0.42.2", + "windows_x86_64_msvc 0.42.2", +] + +[[package]] +name = "windows-targets" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9a2fa6e2155d7247be68c096456083145c183cbbbc2764150dda45a87197940c" +dependencies = [ + "windows_aarch64_gnullvm 0.48.5", + "windows_aarch64_msvc 0.48.5", + "windows_i686_gnu 0.48.5", + "windows_i686_msvc 0.48.5", + "windows_x86_64_gnu 0.48.5", + "windows_x86_64_gnullvm 0.48.5", + "windows_x86_64_msvc 0.48.5", +] + +[[package]] +name = "windows_aarch64_gnullvm" +version = "0.42.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "597a5118570b68bc08d8d59125332c54f1ba9d9adeedeef5b99b02ba2b0698f8" + +[[package]] +name = "windows_aarch64_gnullvm" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2b38e32f0abccf9987a4e3079dfb67dcd799fb61361e53e2882c3cbaf0d905d8" + +[[package]] +name = "windows_aarch64_msvc" +version = "0.42.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e08e8864a60f06ef0d0ff4ba04124db8b0fb3be5776a5cd47641e942e58c4d43" + +[[package]] +name = "windows_aarch64_msvc" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dc35310971f3b2dbbf3f0690a219f40e2d9afcf64f9ab7cc1be722937c26b4bc" + +[[package]] +name = "windows_i686_gnu" +version = "0.42.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c61d927d8da41da96a81f029489353e68739737d3beca43145c8afec9a31a84f" + +[[package]] +name = "windows_i686_gnu" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a75915e7def60c94dcef72200b9a8e58e5091744960da64ec734a6c6e9b3743e" + +[[package]] +name = "windows_i686_msvc" +version = "0.42.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "44d840b6ec649f480a41c8d80f9c65108b92d89345dd94027bfe06ac444d1060" + +[[package]] +name = "windows_i686_msvc" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8f55c233f70c4b27f66c523580f78f1004e8b5a8b659e05a4eb49d4166cca406" + +[[package]] +name = "windows_x86_64_gnu" +version = "0.42.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8de912b8b8feb55c064867cf047dda097f92d51efad5b491dfb98f6bbb70cb36" + +[[package]] +name = "windows_x86_64_gnu" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "53d40abd2583d23e4718fddf1ebec84dbff8381c07cae67ff7768bbf19c6718e" + +[[package]] +name = "windows_x86_64_gnullvm" +version = "0.42.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "26d41b46a36d453748aedef1486d5c7a85db22e56aff34643984ea85514e94a3" + +[[package]] +name = "windows_x86_64_gnullvm" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0b7b52767868a23d5bab768e390dc5f5c55825b6d30b86c844ff2dc7414044cc" + +[[package]] +name = "windows_x86_64_msvc" +version = "0.42.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9aec5da331524158c6d1a4ac0ab1541149c0b9505fde06423b02f5ef0106b9f0" + +[[package]] +name = "windows_x86_64_msvc" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ed94fce61571a4006852b7389a063ab983c02eb1bb37b47f8272ce92d06d9538" + +[[package]] +name = "winnow" +version = "0.5.17" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a3b801d0e0a6726477cc207f60162da452f3a95adb368399bef20a946e06f65c" +dependencies = [ + "memchr", +] + +[[package]] +name = "winreg" +version = "0.50.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "524e57b2c537c0f9b1e69f1965311ec12182b4122e45035b1508cd24d2adadb1" +dependencies = [ + "cfg-if", + "windows-sys 0.48.0", +] + +[[package]] +name = "write16" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d1890f4022759daae28ed4fe62859b1236caebfc61ede2f63ed4e695f3f6d936" + +[[package]] +name = "writeable" +version = "0.5.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c0af0c3d13faebf8dda0b5256fa7096a2d5ccb662f7b9f54a40fe201077ab1c2" + +[[package]] +name = "wyhash" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "baf6e163c25e3fac820b4b453185ea2dea3b6a3e0a721d4d23d75bd33734c295" +dependencies = [ + "rand_core 0.6.4", +] + +[[package]] +name = "wyz" +version = "0.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "05f360fc0b24296329c78fda852a1e9ae82de9cf7b27dae4b7f62f118f77b9ed" +dependencies = [ + "tap", +] + +[[package]] +name = "xml-rs" +version = "0.8.19" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0fcb9cbac069e033553e8bb871be2fbdffcab578eb25bd0f7c508cedc6dcd75a" + +[[package]] +name = "xmltree" +version = "0.10.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d7d8a75eaf6557bb84a65ace8609883db44a29951042ada9b393151532e41fcb" +dependencies = [ + "xml-rs", +] + +[[package]] +name = "yansi" +version = "0.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "09041cd90cf85f7f8b2df60c646f853b7f535ce68f85244eb6731cf89fa498ec" + +[[package]] +name = "yoke" +version = "0.7.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "61e38c508604d6bbbd292dadb3c02559aa7fff6b654a078a36217cad871636e4" +dependencies = [ + "serde", + "stable_deref_trait", + "yoke-derive", + "zerofrom", +] + +[[package]] +name = "yoke-derive" +version = "0.7.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d5e19fb6ed40002bab5403ffa37e53e0e56f914a4450c8765f533018db1db35f" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.38", + "synstructure", +] + +[[package]] +name = "zerocopy" +version = "0.7.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "81ba595b9f2772fbee2312de30eeb80ec773b4cb2f1e8098db024afadda6c06f" +dependencies = [ + "zerocopy-derive", +] + +[[package]] +name = "zerocopy-derive" +version = "0.7.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "772666c41fb6dceaf520b564b962d738a8e1a83b41bd48945f50837aed78bb1d" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.38", +] + +[[package]] +name = "zerofrom" +version = "0.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "655b0814c5c0b19ade497851070c640773304939a6c0fd5f5fb43da0696d05b7" +dependencies = [ + "zerofrom-derive", +] + +[[package]] +name = "zerofrom-derive" +version = "0.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e6a647510471d372f2e6c2e6b7219e44d8c574d24fdc11c610a61455782f18c3" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.38", + "synstructure", +] + +[[package]] +name = "zeroize" +version = "1.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2a0956f1ba7c7909bfb66c2e9e4124ab6f6482560f6628b5aaeba39207c9aad9" +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.38", +] + +[[package]] +name = "zerovec" +version = "0.9.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "591691014119b87047ead4dcf3e6adfbf73cb7c38ab6980d4f18a32138f35d46" +dependencies = [ + "serde", + "yoke", + "zerofrom", + "zerovec-derive", +] + +[[package]] +name = "zerovec-derive" +version = "0.9.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7a4a1638a1934450809c2266a70362bfc96cd90550c073f5b8a55014d1010157" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.38", +] + +[[package]] +name = "zstd" +version = "0.12.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1a27595e173641171fc74a1232b7b1c7a7cb6e18222c11e9dfb9888fa424c53c" +dependencies = [ + "zstd-safe 6.0.6", +] + +[[package]] +name = "zstd" +version = "0.13.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bffb3309596d527cfcba7dfc6ed6052f1d39dfbd7c867aa2e865e4a449c10110" +dependencies = [ + "zstd-safe 7.0.0", +] + +[[package]] +name = "zstd-safe" +version = "6.0.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ee98ffd0b48ee95e6c5168188e44a54550b1564d9d530ee21d5f0eaed1069581" +dependencies = [ + "libc", + "zstd-sys", +] + +[[package]] +name = "zstd-safe" +version = "7.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "43747c7422e2924c11144d5229878b98180ef8b06cca4ab5af37afc8a8d8ea3e" +dependencies = [ + "zstd-sys", +] + +[[package]] +name = "zstd-sys" +version = "2.0.9+zstd.1.5.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9e16efa8a874a0481a574084d34cc26fdb3b99627480f785888deb6386506656" +dependencies = [ + "cc", + "pkg-config", +] diff --git a/op-service/rethdb-reader/Cargo.toml b/op-service/rethdb-reader/Cargo.toml new file mode 100644 index 0000000000000..c73662970ad10 --- /dev/null +++ b/op-service/rethdb-reader/Cargo.toml @@ -0,0 +1,15 @@ +[package] +name = "rethdb-reader" +description = "A simple library for reading data through Reth's DB abstractions." +version = "0.1.0" +edition = "2021" + +[lib] +name = "rethdbreader" +crate-type = ["cdylib"] + +[dependencies] +reth = { git = "https://github.com/paradigmxyz/reth.git" } +serde = "1.0.190" +serde_json = "1.0.107" +anyhow = "1.0.75" diff --git a/op-service/rethdb-reader/README.md b/op-service/rethdb-reader/README.md new file mode 100644 index 0000000000000..2ef313ef413e7 --- /dev/null +++ b/op-service/rethdb-reader/README.md @@ -0,0 +1,83 @@ +# `rethdb-reader` + +A dylib to be accessed via FFI in `op-service`'s `sources` package for reading information +directly from the `reth` database. + +## Developing + +**Building** + +To build the dylib, you must first have the [Rust Toolchain][rust-toolchain] installed. + +```sh +cargo build --release +``` + +**Docs** + +Documentation is available via rustdoc. + +```sh +cargo doc --open +``` + +**Linting** + +```sh +cargo +nightly fmt -- && cargo +nightly clippy --all --all-features -- -D warnings +``` + +**Generating the C header** + +To generate the C header, first install `cbindgen` via `cargo install cbindgen --force`. Then, run the generation script: + +```sh +./headgen.sh +``` + +### C Header + +The C header below is generated by `cbindgen`, and it is the interface that consumers of the dylib use to call its exported +functions. Currently, the only exported functions pertain to reading fully hydrated block receipts from the database. + +```c +#include +#include +#include +#include + +/** + * A [ReceiptsResult] is a wrapper around a JSON string containing serialized [TransactionReceipt]s + * as well as an error status that is compatible with FFI. + * + * # Safety + * - When the `error` field is false, the `data` pointer is guaranteed to be valid. + * - When the `error` field is true, the `data` pointer is guaranteed to be null. + */ +typedef struct ReceiptsResult { + uint32_t *data; + uintptr_t data_len; + bool error; +} ReceiptsResult; + +/** + * Read the receipts for a blockhash from the RETH database directly. + * + * # Safety + * - All possible nil pointer dereferences are checked, and the function will return a + * failing [ReceiptsResult] if any are found. + */ +struct ReceiptsResult rdb_read_receipts(const uint8_t *block_hash, + uintptr_t block_hash_len, + const char *db_path); + +/** + * Free a string that was allocated in Rust and passed to C. + * + * # Safety + * - All possible nil pointer dereferences are checked. + */ +void rdb_free_string(char *string); +``` + +[rust-toolchain]: https://rustup.rs/ diff --git a/op-service/rethdb-reader/headgen.sh b/op-service/rethdb-reader/headgen.sh new file mode 100755 index 0000000000000..e7f7daf676d4c --- /dev/null +++ b/op-service/rethdb-reader/headgen.sh @@ -0,0 +1,16 @@ +#!/bin/bash + +set -e + +# Generate rdb.h +cbindgen --crate rethdb-reader --output rdb.h -l C + +# Process README.md to replace the content within the specified code block +awk ' + BEGIN { in_code_block=0; } + /^```c/ { in_code_block=1; print; next; } + /^```/ && in_code_block { in_code_block=0; while ((getline line < "rdb.h") > 0) print line; } + !in_code_block { print; } +' README.md > README.tmp && mv README.tmp README.md + +echo "Generated C header successfully" diff --git a/op-service/rethdb-reader/src/lib.rs b/op-service/rethdb-reader/src/lib.rs new file mode 100644 index 0000000000000..20aabb1f13913 --- /dev/null +++ b/op-service/rethdb-reader/src/lib.rs @@ -0,0 +1,33 @@ +#![doc = include_str!("../README.md")] + +use receipts::{read_receipts_inner, ReceiptsResult}; +use std::os::raw::c_char; + +mod receipts; + +/// Read the receipts for a blockhash from the RETH database directly. +/// +/// # Safety +/// - All possible nil pointer dereferences are checked, and the function will return a +/// failing [ReceiptsResult] if any are found. +#[no_mangle] +pub unsafe extern "C" fn rdb_read_receipts( + block_hash: *const u8, + block_hash_len: usize, + db_path: *const c_char, +) -> ReceiptsResult { + read_receipts_inner(block_hash, block_hash_len, db_path).unwrap_or(ReceiptsResult::fail()) +} + +/// Free a string that was allocated in Rust and passed to C. +/// +/// # Safety +/// - All possible nil pointer dereferences are checked. +#[no_mangle] +pub unsafe extern "C" fn rdb_free_string(string: *mut c_char) { + // Convert the raw pointer back to a CString and let it go out of scope, + // which will deallocate the memory. + if !string.is_null() { + let _ = std::ffi::CString::from_raw(string); + } +} diff --git a/op-service/rethdb-reader/src/receipts.rs b/op-service/rethdb-reader/src/receipts.rs new file mode 100644 index 0000000000000..3f17daff74bd6 --- /dev/null +++ b/op-service/rethdb-reader/src/receipts.rs @@ -0,0 +1,211 @@ +//! This module contains the logic for reading a block's fully hydrated receipts directly from the +//! [reth] database. + +use anyhow::{anyhow, Result}; +use reth::{ + blockchain_tree::noop::NoopBlockchainTree, + primitives::{ + BlockHashOrNumber, Receipt, TransactionKind, TransactionMeta, TransactionSigned, MAINNET, + U128, U256, U64, + }, + providers::{providers::BlockchainProvider, BlockReader, ProviderFactory, ReceiptProvider}, + rpc::types::{Log, TransactionReceipt}, + utils::db::open_db_read_only, +}; +use std::{ffi::c_char, path::Path}; + +/// A [ReceiptsResult] is a wrapper around a JSON string containing serialized [TransactionReceipt]s +/// as well as an error status that is compatible with FFI. +/// +/// # Safety +/// - When the `error` field is false, the `data` pointer is guaranteed to be valid. +/// - When the `error` field is true, the `data` pointer is guaranteed to be null. +#[repr(C)] +pub struct ReceiptsResult { + data: *mut char, + data_len: usize, + error: bool, +} + +impl ReceiptsResult { + /// Constructs a successful [ReceiptsResult] from a JSON string. + pub fn success(data: *mut char, data_len: usize) -> Self { + Self { + data, + data_len, + error: false, + } + } + + /// Constructs a failing [ReceiptsResult] with a null pointer to the data. + pub fn fail() -> Self { + Self { + data: std::ptr::null_mut(), + data_len: 0, + error: true, + } + } +} + +/// Read the receipts for a blockhash from the RETH database directly. +/// +/// # Safety +/// - All possible nil pointer dereferences are checked, and the function will return a +/// failing [ReceiptsResult] if any are found. +#[inline(always)] +pub(crate) unsafe fn read_receipts_inner( + block_hash: *const u8, + block_hash_len: usize, + db_path: *const c_char, +) -> Result { + // Convert the raw pointer and length back to a Rust slice + let block_hash: [u8; 32] = { + if block_hash.is_null() { + anyhow::bail!("block_hash pointer is null"); + } + std::slice::from_raw_parts(block_hash, block_hash_len) + } + .try_into()?; + + // Convert the *const c_char to a Rust &str + let db_path_str = { + if db_path.is_null() { + anyhow::bail!("db path pointer is null"); + } + std::ffi::CStr::from_ptr(db_path) + } + .to_str()?; + + let db = open_db_read_only(Path::new(db_path_str), None).map_err(|e| anyhow!(e))?; + let factory = ProviderFactory::new(db, MAINNET.clone()); + + // Create a read-only BlockChainProvider + let provider = BlockchainProvider::new(factory, NoopBlockchainTree::default())?; + + // Fetch the block and the receipts within it + let block = provider + .block_by_hash(block_hash.into())? + .ok_or(anyhow!("Failed to fetch block"))?; + let receipts = provider + .receipts_by_block(BlockHashOrNumber::Hash(block_hash.into()))? + .ok_or(anyhow!("Failed to fetch block receipts"))?; + + let block_number = block.number; + let base_fee = block.base_fee_per_gas; + let block_hash = block.hash_slow(); + let receipts = block + .body + .into_iter() + .zip(receipts.clone()) + .enumerate() + .map(|(idx, (tx, receipt))| { + let meta = TransactionMeta { + tx_hash: tx.hash, + index: idx as u64, + block_hash, + block_number, + base_fee, + excess_blob_gas: None, + }; + build_transaction_receipt_with_block_receipts(tx, meta, receipt, &receipts) + }) + .collect::>>() + .ok_or(anyhow!("Failed to build receipts"))?; + + // Convert the receipts to JSON for transport + let mut receipts_json = serde_json::to_string(&receipts)?; + + // Create a ReceiptsResult with a pointer to the json-ified receipts + let res = ReceiptsResult::success(receipts_json.as_mut_ptr() as *mut char, receipts_json.len()); + + // Forget the `receipts_json` string so that its memory isn't freed by the + // borrow checker at the end of this scope + std::mem::forget(receipts_json); // Prevent Rust from freeing the memory + + Ok(res) +} + +/// Builds a hydrated [TransactionReceipt] from information in the passed transaction, +/// receipt, and block receipts. +/// +/// Returns [None] if the transaction's sender could not be recovered from the signature. +#[inline(always)] +fn build_transaction_receipt_with_block_receipts( + tx: TransactionSigned, + meta: TransactionMeta, + receipt: Receipt, + all_receipts: &[Receipt], +) -> Option { + let transaction = tx.clone().into_ecrecovered()?; + + // get the previous transaction cumulative gas used + let gas_used = if meta.index == 0 { + receipt.cumulative_gas_used + } else { + let prev_tx_idx = (meta.index - 1) as usize; + all_receipts + .get(prev_tx_idx) + .map(|prev_receipt| receipt.cumulative_gas_used - prev_receipt.cumulative_gas_used) + .unwrap_or_default() + }; + + let mut res_receipt = TransactionReceipt { + transaction_hash: Some(meta.tx_hash), + transaction_index: U64::from(meta.index), + block_hash: Some(meta.block_hash), + block_number: Some(U256::from(meta.block_number)), + from: transaction.signer(), + to: None, + cumulative_gas_used: U256::from(receipt.cumulative_gas_used), + gas_used: Some(U256::from(gas_used)), + contract_address: None, + logs: Vec::with_capacity(receipt.logs.len()), + effective_gas_price: U128::from(transaction.effective_gas_price(meta.base_fee)), + transaction_type: tx.transaction.tx_type().into(), + // TODO pre-byzantium receipts have a post-transaction state root + state_root: None, + logs_bloom: receipt.bloom_slow(), + status_code: if receipt.success { + Some(U64::from(1)) + } else { + Some(U64::from(0)) + }, + + // EIP-4844 fields + blob_gas_price: None, + blob_gas_used: None, + }; + + match tx.transaction.kind() { + TransactionKind::Create => { + res_receipt.contract_address = + Some(transaction.signer().create(tx.transaction.nonce())); + } + TransactionKind::Call(addr) => { + res_receipt.to = Some(*addr); + } + } + + // get number of logs in the block + let mut num_logs = 0; + for prev_receipt in all_receipts.iter().take(meta.index as usize) { + num_logs += prev_receipt.logs.len(); + } + + for (tx_log_idx, log) in receipt.logs.into_iter().enumerate() { + let rpclog = Log { + address: log.address, + topics: log.topics, + data: log.data, + block_hash: Some(meta.block_hash), + block_number: Some(U256::from(meta.block_number)), + transaction_hash: Some(meta.tx_hash), + transaction_index: Some(U256::from(meta.index)), + log_index: Some(U256::from(num_logs + tx_log_idx)), + removed: false, + }; + res_receipt.logs.push(rpclog); + } + + Some(res_receipt) +} diff --git a/op-service/retry/strategies.go b/op-service/retry/strategies.go index 76681dc306c6f..95157182886f8 100644 --- a/op-service/retry/strategies.go +++ b/op-service/retry/strategies.go @@ -14,7 +14,7 @@ type Strategy interface { } // ExponentialStrategy performs exponential backoff. The exponential backoff -// function is min(e.Min + (2^attempt * 1000) + randBetween(0, e.MaxJitter), e.Max) +// function is min(e.Min + (2^attempt * second), e.Max) + randBetween(0, e.MaxJitter) type ExponentialStrategy struct { // Min is the minimum amount of time to wait between attempts. Min time.Duration @@ -23,27 +23,34 @@ type ExponentialStrategy struct { Max time.Duration // MaxJitter is the maximum amount of random jitter to insert between attempts. + // Jitter is added on top of the maximum, if the maximum is reached. MaxJitter time.Duration } func (e *ExponentialStrategy) Duration(attempt int) time.Duration { - var jitter time.Duration + var jitter time.Duration // non-negative jitter if e.MaxJitter > 0 { jitter = time.Duration(rand.Int63n(e.MaxJitter.Nanoseconds())) } - dur := e.Min + time.Duration(int(math.Pow(2, float64(attempt))*1000))*time.Millisecond - dur += jitter - if dur > e.Max { - return e.Max + if attempt < 0 { + return e.Min + jitter + } + durFloat := float64(e.Min) + durFloat += math.Pow(2, float64(attempt)) * float64(time.Second) + dur := time.Duration(durFloat) + if durFloat > float64(e.Max) { + dur = e.Max } + dur += jitter return dur } func Exponential() Strategy { return &ExponentialStrategy{ - Max: time.Duration(10000 * time.Millisecond), - MaxJitter: time.Duration(250 * time.Millisecond), + Min: 0, + Max: 10 * time.Second, + MaxJitter: 250 * time.Millisecond, } } diff --git a/op-service/retry/strategies_test.go b/op-service/retry/strategies_test.go index aeeee5113fcf2..c18d19ce88363 100644 --- a/op-service/retry/strategies_test.go +++ b/op-service/retry/strategies_test.go @@ -1,6 +1,7 @@ package retry import ( + "math" "testing" "time" @@ -9,13 +10,17 @@ import ( func TestExponential(t *testing.T) { strategy := &ExponentialStrategy{ - Min: 3000 * time.Millisecond, - Max: 10000 * time.Millisecond, + Min: 3 * time.Second, + Max: 10 * time.Second, MaxJitter: 0, } + require.Equal(t, 3*time.Second, strategy.Duration(-1)) durations := []time.Duration{4, 5, 7, 10, 10} for i, dur := range durations { - require.Equal(t, dur*time.Second, strategy.Duration(i)) + require.Equal(t, dur*time.Second, strategy.Duration(i), "attempt %d", i) } + require.Equal(t, 10*time.Second, strategy.Duration(100)) + require.Equal(t, 10*time.Second, strategy.Duration(16000)) + require.Equal(t, 10*time.Second, strategy.Duration(math.MaxInt)) } diff --git a/op-service/sources/batching.go b/op-service/sources/batching/batching.go similarity index 99% rename from op-service/sources/batching.go rename to op-service/sources/batching/batching.go index 958185ac32bba..0cf88f7027046 100644 --- a/op-service/sources/batching.go +++ b/op-service/sources/batching/batching.go @@ -1,4 +1,4 @@ -package sources +package batching import ( "context" diff --git a/op-service/sources/batching_test.go b/op-service/sources/batching/batching_test.go similarity index 99% rename from op-service/sources/batching_test.go rename to op-service/sources/batching/batching_test.go index 4d79e3e1f4e65..c2880dd0c92bf 100644 --- a/op-service/sources/batching_test.go +++ b/op-service/sources/batching/batching_test.go @@ -1,4 +1,4 @@ -package sources +package batching import ( "context" diff --git a/op-service/sources/batching/call.go b/op-service/sources/batching/call.go new file mode 100644 index 0000000000000..690cf630af08d --- /dev/null +++ b/op-service/sources/batching/call.go @@ -0,0 +1,135 @@ +package batching + +import ( + "fmt" + "math/big" + + "github.com/ethereum-optimism/optimism/op-service/txmgr" + "github.com/ethereum/go-ethereum" + "github.com/ethereum/go-ethereum/accounts/abi" + "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/common/hexutil" +) + +type BoundContract struct { + abi *abi.ABI + addr common.Address +} + +func NewBoundContract(abi *abi.ABI, addr common.Address) *BoundContract { + return &BoundContract{ + abi: abi, + addr: addr, + } +} + +func (b *BoundContract) Call(method string, args ...interface{}) *ContractCall { + return NewContractCall(b.abi, b.addr, method, args...) +} + +type ContractCall struct { + Abi *abi.ABI + Addr common.Address + Method string + Args []interface{} +} + +func NewContractCall(abi *abi.ABI, addr common.Address, method string, args ...interface{}) *ContractCall { + return &ContractCall{ + Abi: abi, + Addr: addr, + Method: method, + Args: args, + } +} + +func (c *ContractCall) Pack() ([]byte, error) { + return c.Abi.Pack(c.Method, c.Args...) +} + +func (c *ContractCall) ToCallArgs() (interface{}, error) { + data, err := c.Pack() + if err != nil { + return nil, fmt.Errorf("failed to pack arguments: %w", err) + } + msg := ethereum.CallMsg{ + To: &c.Addr, + Data: data, + } + return toCallArg(msg), nil +} + +func (c *ContractCall) Unpack(hex hexutil.Bytes) (*CallResult, error) { + out, err := c.Abi.Unpack(c.Method, hex) + if err != nil { + return nil, fmt.Errorf("failed to unpack data: %w", err) + } + return &CallResult{out: out}, nil +} + +func toCallArg(msg ethereum.CallMsg) interface{} { + arg := map[string]interface{}{ + "from": msg.From, + "to": msg.To, + } + if len(msg.Data) > 0 { + arg["input"] = hexutil.Bytes(msg.Data) + } + if msg.Value != nil { + arg["value"] = (*hexutil.Big)(msg.Value) + } + if msg.Gas != 0 { + arg["gas"] = hexutil.Uint64(msg.Gas) + } + if msg.GasPrice != nil { + arg["gasPrice"] = (*hexutil.Big)(msg.GasPrice) + } + return arg +} + +func (c *ContractCall) ToTxCandidate() (txmgr.TxCandidate, error) { + data, err := c.Pack() + if err != nil { + return txmgr.TxCandidate{}, fmt.Errorf("failed to pack arguments: %w", err) + } + return txmgr.TxCandidate{ + TxData: data, + To: &c.Addr, + }, nil +} + +type CallResult struct { + out []interface{} +} + +func (c *CallResult) GetUint8(i int) uint8 { + return *abi.ConvertType(c.out[i], new(uint8)).(*uint8) +} + +func (c *CallResult) GetUint32(i int) uint32 { + return *abi.ConvertType(c.out[i], new(uint32)).(*uint32) +} + +func (c *CallResult) GetUint64(i int) uint64 { + return *abi.ConvertType(c.out[i], new(uint64)).(*uint64) +} + +func (c *CallResult) GetBool(i int) bool { + return *abi.ConvertType(c.out[i], new(bool)).(*bool) +} + +func (c *CallResult) GetHash(i int) common.Hash { + return *abi.ConvertType(c.out[i], new([32]byte)).(*[32]byte) +} + +func (c *CallResult) GetAddress(i int) common.Address { + return *abi.ConvertType(c.out[i], new([20]byte)).(*[20]byte) +} + +func (c *CallResult) GetBigInt(i int) *big.Int { + return *abi.ConvertType(c.out[i], new(*big.Int)).(**big.Int) +} + +func (c *CallResult) GetStruct(i int, target interface{}) { + abi.ConvertType(c.out[i], target) +} diff --git a/op-service/sources/batching/call_test.go b/op-service/sources/batching/call_test.go new file mode 100644 index 0000000000000..1349e314df53d --- /dev/null +++ b/op-service/sources/batching/call_test.go @@ -0,0 +1,186 @@ +package batching + +import ( + "math/big" + "testing" + + "github.com/ethereum-optimism/optimism/op-bindings/bindings" + "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/common/hexutil" + "github.com/stretchr/testify/require" +) + +func TestContractCall_ToCallArgs(t *testing.T) { + addr := common.Address{0xbd} + testAbi, err := bindings.ERC20MetaData.GetAbi() + require.NoError(t, err) + call := NewContractCall(testAbi, addr, "approve", common.Address{0xcc}, big.NewInt(1234444)) + args, err := call.ToCallArgs() + require.NoError(t, err) + argMap, ok := args.(map[string]interface{}) + require.True(t, ok) + require.Equal(t, argMap["from"], common.Address{}) + require.Equal(t, argMap["to"], &addr) + expectedData, err := call.Pack() + require.NoError(t, err) + require.Equal(t, argMap["input"], hexutil.Bytes(expectedData)) + + require.NotContains(t, argMap, "value") + require.NotContains(t, argMap, "gas") + require.NotContains(t, argMap, "gasPrice") +} + +func TestContractCall_ToTxCandidate(t *testing.T) { + addr := common.Address{0xbd} + testAbi, err := bindings.ERC20MetaData.GetAbi() + require.NoError(t, err) + call := NewContractCall(testAbi, addr, "approve", common.Address{0xcc}, big.NewInt(1234444)) + candidate, err := call.ToTxCandidate() + require.NoError(t, err) + require.Equal(t, candidate.To, &addr) + expectedData, err := call.Pack() + require.NoError(t, err) + require.Equal(t, candidate.TxData, expectedData) + + require.Nil(t, candidate.Value) + require.Zero(t, candidate.GasLimit) +} + +func TestContractCall_Pack(t *testing.T) { + addr := common.Address{0xbd} + testAbi, err := bindings.ERC20MetaData.GetAbi() + require.NoError(t, err) + sender := common.Address{0xcc} + amount := big.NewInt(1234444) + call := NewContractCall(testAbi, addr, "approve", sender, amount) + actual, err := call.Pack() + require.NoError(t, err) + + expected, err := testAbi.Pack("approve", sender, amount) + require.NoError(t, err) + require.Equal(t, actual, expected) +} + +func TestContractCall_PackInvalid(t *testing.T) { + addr := common.Address{0xbd} + testAbi, err := bindings.ERC20MetaData.GetAbi() + require.NoError(t, err) + // Second arg should be a *big.Int so packing should fail + call := NewContractCall(testAbi, addr, "approve", common.Address{0xcc}, uint32(123)) + _, err = call.Pack() + require.Error(t, err) +} + +func TestContractCall_Unpack(t *testing.T) { + addr := common.Address{0xbd} + testAbi, err := bindings.ERC20MetaData.GetAbi() + require.NoError(t, err) + call := NewContractCall(testAbi, addr, "balanceOf", common.Address{0xcc}) + outputs := testAbi.Methods["balanceOf"].Outputs + expected := big.NewInt(1234) + packed, err := outputs.Pack(expected) + require.NoError(t, err) + + unpacked, err := call.Unpack(packed) + require.NoError(t, err) + require.Equal(t, unpacked.GetBigInt(0), expected) +} + +func TestContractCall_UnpackInvalid(t *testing.T) { + addr := common.Address{0xbd} + testAbi, err := bindings.ERC20MetaData.GetAbi() + require.NoError(t, err) + call := NewContractCall(testAbi, addr, "balanceOf", common.Address{0xcc}) + + // Input data is the wrong format and won't unpack successfully + inputPacked, err := call.Pack() + require.NoError(t, err) + + _, err = call.Unpack(inputPacked) + require.Error(t, err) +} + +func TestCallResult_GetValues(t *testing.T) { + tests := []struct { + name string + getter func(result *CallResult, i int) interface{} + expected interface{} + }{ + { + name: "GetUint8", + getter: func(result *CallResult, i int) interface{} { + return result.GetUint8(i) + }, + expected: uint8(12), + }, + { + name: "GetUint32", + getter: func(result *CallResult, i int) interface{} { + return result.GetUint32(i) + }, + expected: uint32(12346), + }, + { + name: "GetUint64", + getter: func(result *CallResult, i int) interface{} { + return result.GetUint64(i) + }, + expected: uint64(12346), + }, + { + name: "GetBool", + getter: func(result *CallResult, i int) interface{} { + return result.GetBool(i) + }, + expected: true, + }, + { + name: "GetAddress", + getter: func(result *CallResult, i int) interface{} { + return result.GetAddress(i) + }, + expected: ([20]byte)(common.Address{0xaa, 0xbb, 0xcc}), + }, + { + name: "GetHash", + getter: func(result *CallResult, i int) interface{} { + return result.GetHash(i) + }, + expected: ([32]byte)(common.Hash{0xaa, 0xbb, 0xcc}), + }, + { + name: "GetBigInt", + getter: func(result *CallResult, i int) interface{} { + return result.GetBigInt(i) + }, + expected: big.NewInt(2398423), + }, + { + name: "GetStruct", + getter: func(result *CallResult, i int) interface{} { + out := struct { + a *big.Int + b common.Hash + }{} + result.GetStruct(i, &out) + return out + }, + expected: struct { + a *big.Int + b common.Hash + }{ + a: big.NewInt(6), + b: common.Hash{0xee}, + }, + }, + } + + for _, test := range tests { + test := test + t.Run(test.name, func(t *testing.T) { + callResult := &CallResult{[]interface{}{nil, 0, "abc", test.expected, "xyz", 3, nil}} + actual := test.getter(callResult, 3) + require.EqualValues(t, test.expected, actual) + }) + } +} diff --git a/op-service/sources/batching/multicall.go b/op-service/sources/batching/multicall.go new file mode 100644 index 0000000000000..79322da1f9b76 --- /dev/null +++ b/op-service/sources/batching/multicall.go @@ -0,0 +1,111 @@ +package batching + +import ( + "context" + "fmt" + "io" + + "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/common/hexutil" + "github.com/ethereum/go-ethereum/rpc" +) + +var DefaultBatchSize = 100 + +type EthRpc interface { + CallContext(ctx context.Context, out interface{}, method string, args ...interface{}) error + BatchCallContext(ctx context.Context, b []rpc.BatchElem) error +} + +type MultiCaller struct { + rpc EthRpc + batchSize int +} + +func NewMultiCaller(rpc EthRpc, batchSize int) *MultiCaller { + return &MultiCaller{ + rpc: rpc, + batchSize: batchSize, + } +} + +func (m *MultiCaller) SingleCall(ctx context.Context, block Block, call *ContractCall) (*CallResult, error) { + results, err := m.Call(ctx, block, call) + if err != nil { + return nil, err + } + return results[0], nil +} + +func (m *MultiCaller) Call(ctx context.Context, block Block, calls ...*ContractCall) ([]*CallResult, error) { + keys := make([]interface{}, len(calls)) + for i := 0; i < len(calls); i++ { + args, err := calls[i].ToCallArgs() + if err != nil { + return nil, err + } + keys[i] = args + } + fetcher := NewIterativeBatchCall[interface{}, *hexutil.Bytes]( + keys, + func(args interface{}) (*hexutil.Bytes, rpc.BatchElem) { + out := new(hexutil.Bytes) + return out, rpc.BatchElem{ + Method: "eth_call", + Args: []interface{}{args, block.value}, + Result: &out, + } + }, + m.rpc.BatchCallContext, + m.rpc.CallContext, + m.batchSize) + for { + if err := fetcher.Fetch(ctx); err == io.EOF { + break + } else if err != nil { + return nil, fmt.Errorf("failed to fetch claims: %w", err) + } + } + results, err := fetcher.Result() + if err != nil { + return nil, fmt.Errorf("failed to get batch call results: %w", err) + } + + callResults := make([]*CallResult, len(results)) + for i, result := range results { + call := calls[i] + out, err := call.Unpack(*result) + if err != nil { + return nil, fmt.Errorf("failed to unpack result: %w", err) + } + callResults[i] = out + } + return callResults, nil +} + +// Block represents the block ref value in RPC calls. +// It can be either a label (e.g. latest), a block number or block hash. +type Block struct { + value any +} + +func (b Block) ArgValue() any { + return b.value +} + +var ( + BlockPending = Block{"pending"} + BlockLatest = Block{"latest"} + BlockSafe = Block{"safe"} + BlockFinalized = Block{"finalized"} +) + +// BlockByNumber references a canonical block by number. +func BlockByNumber(blockNum uint64) Block { + return Block{rpc.BlockNumber(blockNum)} +} + +// BlockByHash references a block by hash. Canonical or non-canonical blocks may be referenced. +func BlockByHash(hash common.Hash) Block { + return Block{rpc.BlockNumberOrHashWithHash(hash, false)} +} diff --git a/op-service/sources/batching/test/stubs.go b/op-service/sources/batching/test/stubs.go new file mode 100644 index 0000000000000..1554e1653e60b --- /dev/null +++ b/op-service/sources/batching/test/stubs.go @@ -0,0 +1,126 @@ +package test + +import ( + "context" + "encoding/json" + "errors" + "fmt" + "testing" + + "github.com/ethereum-optimism/optimism/op-service/sources/batching" + "github.com/ethereum-optimism/optimism/op-service/txmgr" + "github.com/ethereum/go-ethereum/accounts/abi" + "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/common/hexutil" + "github.com/ethereum/go-ethereum/rpc" + "github.com/stretchr/testify/assert" + "github.com/stretchr/testify/require" + "golang.org/x/exp/slices" +) + +type expectedCall struct { + block batching.Block + args []interface{} + packedArgs []byte + outputs []interface{} +} + +func (e *expectedCall) String() string { + return fmt.Sprintf("{block: %v, args: %v, outputs: %v}", e.block, e.args, e.outputs) +} + +type AbiBasedRpc struct { + t *testing.T + abi *abi.ABI + addr common.Address + + expectedCalls map[string][]*expectedCall +} + +func NewAbiBasedRpc(t *testing.T, contractAbi *abi.ABI, addr common.Address) *AbiBasedRpc { + return &AbiBasedRpc{ + t: t, + abi: contractAbi, + addr: addr, + expectedCalls: make(map[string][]*expectedCall), + } +} + +func (l *AbiBasedRpc) SetResponse(method string, block batching.Block, expected []interface{}, output []interface{}) { + if expected == nil { + expected = []interface{}{} + } + if output == nil { + output = []interface{}{} + } + abiMethod, ok := l.abi.Methods[method] + require.Truef(l.t, ok, "No method: %v", method) + packedArgs, err := abiMethod.Inputs.Pack(expected...) + require.NoErrorf(l.t, err, "Invalid expected arguments for method %v: %v", method, expected) + l.expectedCalls[method] = append(l.expectedCalls[method], &expectedCall{ + block: block, + args: expected, + packedArgs: packedArgs, + outputs: output, + }) +} + +func (l *AbiBasedRpc) BatchCallContext(ctx context.Context, b []rpc.BatchElem) error { + var errs []error + for _, elem := range b { + elem.Error = l.CallContext(ctx, elem.Result, elem.Method, elem.Args...) + errs = append(errs, elem.Error) + } + return errors.Join(errs...) +} + +func (l *AbiBasedRpc) VerifyTxCandidate(candidate txmgr.TxCandidate) { + require.EqualValues(l.t, &l.addr, candidate.To, "Incorrect To address") + l.findExpectedCall(candidate.TxData, batching.BlockLatest.ArgValue()) +} + +func (l *AbiBasedRpc) CallContext(_ context.Context, out interface{}, method string, args ...interface{}) error { + require.Equal(l.t, "eth_call", method) + require.Len(l.t, args, 2) + actualBlockRef := args[1] + callOpts, ok := args[0].(map[string]any) + require.True(l.t, ok) + require.Equal(l.t, &l.addr, callOpts["to"]) + data, ok := callOpts["input"].(hexutil.Bytes) + require.True(l.t, ok) + + call, abiMethod := l.findExpectedCall(data, actualBlockRef) + + output, err := abiMethod.Outputs.Pack(call.outputs...) + require.NoErrorf(l.t, err, "Invalid outputs for method %v: %v", abiMethod.Name, call.outputs) + + // I admit I do not understand Go reflection. + // So leverage json.Unmarshal to set the out value correctly. + j, err := json.Marshal(hexutil.Bytes(output)) + require.NoError(l.t, err) + require.NoError(l.t, json.Unmarshal(j, out)) + return nil +} + +func (l *AbiBasedRpc) findExpectedCall(data []byte, actualBlockRef interface{}) (*expectedCall, *abi.Method) { + + abiMethod, err := l.abi.MethodById(data[0:4]) + require.NoError(l.t, err) + + argData := data[4:] + args, err := abiMethod.Inputs.Unpack(argData) + require.NoError(l.t, err) + require.Len(l.t, args, len(abiMethod.Inputs)) + + expectedCalls, ok := l.expectedCalls[abiMethod.Name] + require.Truef(l.t, ok, "Unexpected call to %v", abiMethod.Name) + var call *expectedCall + for _, candidate := range expectedCalls { + if slices.Equal(candidate.packedArgs, argData) && assert.ObjectsAreEqualValues(candidate.block.ArgValue(), actualBlockRef) { + call = candidate + break + } + } + require.NotNilf(l.t, call, "No expected calls to %v at block %v with arguments: %v\nExpected calls: %v", abiMethod.Name, actualBlockRef, args, expectedCalls) + return call, abiMethod +} diff --git a/op-service/sources/batching/types.go b/op-service/sources/batching/types.go new file mode 100644 index 0000000000000..4bd0cc2048d6d --- /dev/null +++ b/op-service/sources/batching/types.go @@ -0,0 +1,11 @@ +package batching + +import ( + "context" + + "github.com/ethereum/go-ethereum/rpc" +) + +type BatchCallContextFn func(ctx context.Context, b []rpc.BatchElem) error + +type CallContextFn func(ctx context.Context, result any, method string, args ...any) error diff --git a/op-service/sources/debug_client.go b/op-service/sources/debug_client.go index db5a782281f12..e9bb2ca579a78 100644 --- a/op-service/sources/debug_client.go +++ b/op-service/sources/debug_client.go @@ -4,16 +4,17 @@ import ( "context" "fmt" + "github.com/ethereum-optimism/optimism/op-service/sources/batching" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common/hexutil" "github.com/ethereum/go-ethereum/core/rawdb" ) type DebugClient struct { - callContext CallContextFn + callContext batching.CallContextFn } -func NewDebugClient(callContext CallContextFn) *DebugClient { +func NewDebugClient(callContext batching.CallContextFn) *DebugClient { return &DebugClient{callContext} } diff --git a/op-service/sources/engine_client.go b/op-service/sources/engine_client.go index 4f54d324ce89e..f7abc5d8d077e 100644 --- a/op-service/sources/engine_client.go +++ b/op-service/sources/engine_client.go @@ -51,20 +51,21 @@ func NewEngineClient(client client.RPC, log log.Logger, metrics caching.Metrics, // 2. `error` as eth.InputError: the forkchoice state or attributes are not valid. // 3. Other types of `error`: temporary RPC errors, like timeouts. func (s *EngineClient) ForkchoiceUpdate(ctx context.Context, fc *eth.ForkchoiceState, attributes *eth.PayloadAttributes) (*eth.ForkchoiceUpdatedResult, error) { - e := s.log.New("state", fc, "attr", attributes) - e.Trace("Sharing forkchoice-updated signal") + llog := s.log.New("state", fc) // local logger + tlog := llog.New("attr", attributes) // trace logger + tlog.Trace("Sharing forkchoice-updated signal") fcCtx, cancel := context.WithTimeout(ctx, time.Second*5) defer cancel() var result eth.ForkchoiceUpdatedResult err := s.client.CallContext(fcCtx, &result, "engine_forkchoiceUpdatedV2", fc, attributes) if err == nil { - e.Trace("Shared forkchoice-updated signal") + tlog.Trace("Shared forkchoice-updated signal") if attributes != nil { // block building is optional, we only get a payload ID if we are building a block - e.Trace("Received payload id", "payloadId", result.PayloadID) + tlog.Trace("Received payload id", "payloadId", result.PayloadID) } return &result, nil } else { - e.Warn("Failed to share forkchoice-updated signal", "err", err) + llog.Warn("Failed to share forkchoice-updated signal", "err", err) if rpcErr, ok := err.(rpc.Error); ok { code := eth.ErrorCode(rpcErr.ErrorCode()) switch code { diff --git a/op-service/sources/eth_client.go b/op-service/sources/eth_client.go index 553615857908c..7a54a5838f857 100644 --- a/op-service/sources/eth_client.go +++ b/op-service/sources/eth_client.go @@ -62,6 +62,9 @@ type EthClientConfig struct { // till we re-attempt the user-preferred methods. // If this is 0 then the client does not fall back to less optimal but available methods. MethodResetDuration time.Duration + + // [OPTIONAL] The reth DB path to fetch receipts from + RethDBPath string } func (c *EthClientConfig) Check() error { @@ -132,6 +135,9 @@ type EthClient struct { // methodResetDuration defines how long we take till we reset lastMethodsReset methodResetDuration time.Duration + + // [OPTIONAL] The reth DB path to fetch receipts from + rethDbPath string } func (s *EthClient) PickReceiptsMethod(txCount uint64) ReceiptsFetchingMethod { @@ -179,6 +185,7 @@ func NewEthClient(client client.RPC, log log.Logger, metrics caching.Metrics, co availableReceiptMethods: AvailableReceiptsFetchingMethods(config.RPCProviderKind), lastMethodsReset: time.Now(), methodResetDuration: config.MethodResetDuration, + rethDbPath: config.RethDBPath, }, nil } @@ -357,7 +364,7 @@ func (s *EthClient) FetchReceipts(ctx context.Context, blockHash common.Hash) (e job = v } else { txHashes := eth.TransactionsToHashes(txs) - job = NewReceiptsFetchingJob(s, s.client, s.maxBatchSize, eth.ToBlockID(info), info.ReceiptHash(), txHashes) + job = NewReceiptsFetchingJob(s, s.client, s.maxBatchSize, eth.ToBlockID(info), info.ReceiptHash(), txHashes, s.rethDbPath) s.receiptsCache.Add(blockHash, job) } receipts, err := job.Fetch(ctx) diff --git a/op-service/sources/eth_client_test.go b/op-service/sources/eth_client_test.go index 145f87696be3a..11447f8a2e518 100644 --- a/op-service/sources/eth_client_test.go +++ b/op-service/sources/eth_client_test.go @@ -52,7 +52,7 @@ var testEthClientConfig = &EthClientConfig{ MaxConcurrentRequests: 10, TrustRPC: false, MustBePostMerge: false, - RPCProviderKind: RPCKindBasic, + RPCProviderKind: RPCKindStandard, } func randHash() (out common.Hash) { @@ -133,7 +133,7 @@ func TestEthClient_InfoByNumber(t *testing.T) { "eth_getBlockByNumber", []any{n.String(), false}).Run(func(args mock.Arguments) { *args[1].(**rpcHeader) = rhdr }).Return([]error{nil}) - s, err := NewL1Client(m, nil, nil, L1ClientDefaultConfig(&rollup.Config{SeqWindowSize: 10}, true, RPCKindBasic)) + s, err := NewL1Client(m, nil, nil, L1ClientDefaultConfig(&rollup.Config{SeqWindowSize: 10}, true, RPCKindStandard)) require.NoError(t, err) info, err := s.InfoByNumber(ctx, uint64(n)) require.NoError(t, err) @@ -152,7 +152,7 @@ func TestEthClient_WrongInfoByNumber(t *testing.T) { "eth_getBlockByNumber", []any{n.String(), false}).Run(func(args mock.Arguments) { *args[1].(**rpcHeader) = &rhdr2 }).Return([]error{nil}) - s, err := NewL1Client(m, nil, nil, L1ClientDefaultConfig(&rollup.Config{SeqWindowSize: 10}, true, RPCKindBasic)) + s, err := NewL1Client(m, nil, nil, L1ClientDefaultConfig(&rollup.Config{SeqWindowSize: 10}, true, RPCKindStandard)) require.NoError(t, err) _, err = s.InfoByNumber(ctx, uint64(n)) require.Error(t, err, "cannot accept the wrong block") @@ -171,7 +171,7 @@ func TestEthClient_WrongInfoByHash(t *testing.T) { "eth_getBlockByHash", []any{k, false}).Run(func(args mock.Arguments) { *args[1].(**rpcHeader) = &rhdr2 }).Return([]error{nil}) - s, err := NewL1Client(m, nil, nil, L1ClientDefaultConfig(&rollup.Config{SeqWindowSize: 10}, true, RPCKindBasic)) + s, err := NewL1Client(m, nil, nil, L1ClientDefaultConfig(&rollup.Config{SeqWindowSize: 10}, true, RPCKindStandard)) require.NoError(t, err) _, err = s.InfoByHash(ctx, k) require.Error(t, err, "cannot accept the wrong block") diff --git a/op-service/sources/l2_client.go b/op-service/sources/l2_client.go index e6e714d71acfe..5d108d3ca338d 100644 --- a/op-service/sources/l2_client.go +++ b/op-service/sources/l2_client.go @@ -51,7 +51,7 @@ func L2ClientDefaultConfig(config *rollup.Config, trustRPC bool) *L2ClientConfig MaxConcurrentRequests: 10, TrustRPC: trustRPC, MustBePostMerge: true, - RPCProviderKind: RPCKindBasic, + RPCProviderKind: RPCKindStandard, MethodResetDuration: time.Minute, }, // Not bounded by span, to cover find-sync-start range fully for speedy recovery after errors. diff --git a/op-service/sources/receipts.go b/op-service/sources/receipts.go index 771d35b5fbdf5..fb40689ce6bf6 100644 --- a/op-service/sources/receipts.go +++ b/op-service/sources/receipts.go @@ -6,6 +6,7 @@ import ( "io" "sync" + "github.com/ethereum-optimism/optimism/op-service/sources/batching" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common/hexutil" "github.com/ethereum/go-ethereum/core/types" @@ -121,8 +122,10 @@ const ( RPCKindNethermind RPCProviderKind = "nethermind" RPCKindDebugGeth RPCProviderKind = "debug_geth" RPCKindErigon RPCProviderKind = "erigon" - RPCKindBasic RPCProviderKind = "basic" // try only the standard most basic receipt fetching - RPCKindAny RPCProviderKind = "any" // try any method available + RPCKindBasic RPCProviderKind = "basic" // try only the standard most basic receipt fetching + RPCKindAny RPCProviderKind = "any" // try any method available + RPCKindStandard RPCProviderKind = "standard" // try standard methods, including newer optimized standard RPC methods + RPCKindRethDB RPCProviderKind = "reth_db" // read data directly from reth's database ) var RPCProviderKinds = []RPCProviderKind{ @@ -135,8 +138,14 @@ var RPCProviderKinds = []RPCProviderKind{ RPCKindErigon, RPCKindBasic, RPCKindAny, + RPCKindStandard, } +// Copy of RPCProviderKinds with RethDB added to all RethDB to be used but to hide it from the flags +var validRPCProviderKinds = func() []RPCProviderKind { + return append(RPCProviderKinds, RPCKindRethDB) +}() + func (kind RPCProviderKind) String() string { return string(kind) } @@ -155,7 +164,7 @@ func (kind *RPCProviderKind) Clone() any { } func ValidRPCProviderKind(value RPCProviderKind) bool { - for _, k := range RPCProviderKinds { + for _, k := range validRPCProviderKinds { if k == value { return true } @@ -235,11 +244,14 @@ const ( // - Alchemy: https://docs.alchemy.com/reference/eth-getblockreceipts // - Nethermind: https://docs.nethermind.io/nethermind/ethereum-client/json-rpc/parity#parity_getblockreceipts ParityGetBlockReceipts - // EthGetBlockReceipts is a non-standard receipt fetching method in the eth namespace, + // EthGetBlockReceipts is a previously non-standard receipt fetching method in the eth namespace, // supported by some RPC platforms. + // This since has been standardized in https://github.com/ethereum/execution-apis/pull/438 and adopted in Geth: + // https://github.com/ethereum/go-ethereum/pull/27702 // Available in: // - Alchemy: 500 CU total (and deprecated) // - QuickNode: 59 credits total (does not seem to work with block hash arg, inaccurate docs) + // - Standard, incl. Geth, Besu and Reth, and Nethermind has a PR in review. // Method: eth_getBlockReceipts // Params: // - QuickNode: string, "quantity or tag", docs say incl. block hash, but API does not actually accept it. @@ -263,6 +275,18 @@ const ( // See: // https://github.com/ledgerwatch/erigon/blob/287a3d1d6c90fc6a7a088b5ae320f93600d5a167/cmd/rpcdaemon/commands/erigon_receipts.go#LL391C24-L391C51 ErigonGetBlockReceiptsByBlockHash + // RethGetBlockReceiptsMDBX is a Reth-specific receipt fetching method. It reads the data directly from reth's database, using their + // generic DB abstractions, rather than requesting it from the RPC provider. + // Available in: + // - Reth + // Method: n/a - does not use RPC. + // Params: + // - Reth: string, hex-encoded block hash + // Returns: + // - Reth: string, json-ified receipts + // See: + // - reth's DB crate documentation: https://github.com/paradigmxyz/reth/blob/main/docs/crates/db.md + RethGetBlockReceipts // Other: // - 250 credits, not supported, strictly worse than other options. In quicknode price-table. @@ -292,10 +316,14 @@ func AvailableReceiptsFetchingMethods(kind RPCProviderKind) ReceiptsFetchingMeth case RPCKindBasic: return EthGetTransactionReceiptBatch case RPCKindAny: - // if it's any kind of RPC provider, then try all methods + // if it's any kind of RPC provider, then try all methods (except for RethGetBlockReceipts) return AlchemyGetTransactionReceipts | EthGetBlockReceipts | DebugGetRawReceipts | ErigonGetBlockReceiptsByBlockHash | ParityGetBlockReceipts | EthGetTransactionReceiptBatch + case RPCKindStandard: + return EthGetBlockReceipts | EthGetTransactionReceiptBatch + case RPCKindRethDB: + return RethGetBlockReceipts default: return EthGetTransactionReceiptBatch } @@ -306,7 +334,9 @@ func AvailableReceiptsFetchingMethods(kind RPCProviderKind) ReceiptsFetchingMeth func PickBestReceiptsFetchingMethod(kind RPCProviderKind, available ReceiptsFetchingMethod, txCount uint64) ReceiptsFetchingMethod { // If we have optimized methods available, it makes sense to use them, but only if the cost is // lower than fetching transactions one by one with the standard receipts RPC method. - if kind == RPCKindAlchemy { + if kind == RPCKindRethDB { + return RethGetBlockReceipts + } else if kind == RPCKindAlchemy { if available&AlchemyGetTransactionReceipts != 0 && txCount > 250/15 { return AlchemyGetTransactionReceipts } @@ -362,13 +392,16 @@ type receiptsFetchingJob struct { receiptHash common.Hash txHashes []common.Hash - fetcher *IterativeBatchCall[common.Hash, *types.Receipt] + fetcher *batching.IterativeBatchCall[common.Hash, *types.Receipt] + + // [OPTIONAL] RethDB path to fetch receipts from + rethDbPath string result types.Receipts } func NewReceiptsFetchingJob(requester ReceiptsRequester, client rpcClient, maxBatchSize int, block eth.BlockID, - receiptHash common.Hash, txHashes []common.Hash) *receiptsFetchingJob { + receiptHash common.Hash, txHashes []common.Hash, rethDb string) *receiptsFetchingJob { return &receiptsFetchingJob{ requester: requester, client: client, @@ -376,6 +409,7 @@ func NewReceiptsFetchingJob(requester ReceiptsRequester, client rpcClient, maxBa block: block, receiptHash: receiptHash, txHashes: txHashes, + rethDbPath: rethDb, } } @@ -391,7 +425,7 @@ type ReceiptsRequester interface { func (job *receiptsFetchingJob) runFetcher(ctx context.Context) error { if job.fetcher == nil { // start new work - job.fetcher = NewIterativeBatchCall[common.Hash, *types.Receipt]( + job.fetcher = batching.NewIterativeBatchCall[common.Hash, *types.Receipt]( job.txHashes, makeReceiptRequest, job.client.BatchCallContext, @@ -453,6 +487,15 @@ func (job *receiptsFetchingJob) runAltMethod(ctx context.Context, m ReceiptsFetc err = job.client.CallContext(ctx, &result, "eth_getBlockReceipts", job.block.Hash) case ErigonGetBlockReceiptsByBlockHash: err = job.client.CallContext(ctx, &result, "erigon_getBlockReceiptsByBlockHash", job.block.Hash) + case RethGetBlockReceipts: + if job.rethDbPath == "" { + return fmt.Errorf("reth_db path not set") + } + res, err := FetchRethReceipts(job.rethDbPath, &job.block.Hash) + if err != nil { + return err + } + result = res default: err = fmt.Errorf("unknown receipt fetching method: %d", uint64(m)) } diff --git a/op-service/sources/receipts_test.go b/op-service/sources/receipts_test.go index 5ee635e868c3d..12c450199fcd0 100644 --- a/op-service/sources/receipts_test.go +++ b/op-service/sources/receipts_test.go @@ -4,6 +4,7 @@ import ( "context" "encoding/json" "fmt" + "math/big" "math/rand" "testing" "time" @@ -17,6 +18,7 @@ import ( "github.com/ethereum/go-ethereum/core/types" "github.com/ethereum/go-ethereum/log" "github.com/ethereum/go-ethereum/rpc" + "github.com/ethereum/go-ethereum/trie" "github.com/stretchr/testify/mock" "github.com/stretchr/testify/require" ) @@ -305,6 +307,16 @@ func TestEthClient_FetchReceipts(t *testing.T) { providerKind: RPCKindBasic, setup: fallbackCase(4, EthGetTransactionReceiptBatch), }, + { + name: "standard", + providerKind: RPCKindStandard, + setup: fallbackCase(4, EthGetBlockReceipts), + }, + { + name: "standard fallback", + providerKind: RPCKindStandard, + setup: fallbackCase(4, EthGetBlockReceipts, EthGetTransactionReceiptBatch), + }, { name: "any discovers alchemy", providerKind: RPCKindAny, @@ -328,3 +340,233 @@ func TestEthClient_FetchReceipts(t *testing.T) { t.Run(tc.name, tc.Run) } } + +func TestVerifyReceipts(t *testing.T) { + validData := func() (eth.BlockID, common.Hash, []common.Hash, []*types.Receipt) { + block := eth.BlockID{ + Hash: common.HexToHash("0x40fb7cc5fbc1ec594230a60648a442412116d50ae43d517ea458d8ea4e60bd1b"), + Number: 9998910, + } + txHashes := []common.Hash{ + common.HexToHash("0x61e4872004a80843fcbede236527bf24707f4e8f44a2704ed9c4fb91c87b0f29"), + common.HexToHash("0x0ae25ad9ff01fd74fa1b0c11f12fbb623a3f0553a0eed465a6dbf0962898c3b6"), + common.HexToHash("0x2de33b18143039dcdf88cb62c3f3dd8f3f5d9f29807edfd3b0507246c55f9cb8"), + common.HexToHash("0xb6a381d3c31df47da82ac807c3000ae4adf55e981715f56d13a27b220de20198"), + } + receipts := []*types.Receipt{ + { + Type: 2, + Status: 0, + CumulativeGasUsed: 0x3035b, + Bloom: types.BytesToBloom(common.Hex2Bytes("0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000")), + Logs: nil, + TxHash: txHashes[0], + GasUsed: 0x3035b, + EffectiveGasPrice: big.NewInt(0x12a05f20a), + BlockHash: block.Hash, + BlockNumber: new(big.Int).SetUint64(block.Number), + TransactionIndex: 0, + }, + { + Type: 2, + Status: 1, + CumulativeGasUsed: 0xa9ae4, + Bloom: types.BytesToBloom(common.Hex2Bytes("0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000")), + Logs: nil, + TxHash: txHashes[1], + GasUsed: 0x79789, + EffectiveGasPrice: big.NewInt(0xb2d05e0a), + BlockHash: block.Hash, + BlockNumber: new(big.Int).SetUint64(block.Number), + TransactionIndex: 1, + }, + { + Type: 0, + Status: 1, + CumulativeGasUsed: 0x101f09, + Bloom: types.BytesToBloom(common.Hex2Bytes("0x00000000000000000000000000000200000400000000000000000000000000800000000000040000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002002000000000000000000000000000000000000000000000000000000000000000000000000000000000000200000000000800000000000000000000000000000000000000000000000000000400000000000000020000000000000000000000000002000000000000000000000000000000000000000000")), + Logs: []*types.Log{ + { + Address: common.HexToAddress("0x759c5e44a9e4be8b7e9bd25a790ceb662c924c45"), + Topics: []common.Hash{ + common.HexToHash("0x33830f93f4b524630176cdcbc04070b30ada13c6ad27081289131b77f178ff89"), + common.HexToHash("0x0000000000000000000000000000000000000000000000000000000000426a80"), + common.HexToHash("0x000000000000000000000000a6275ee214f80a532c3abee0a4cbbc2d1dc22a72"), + }, + Data: common.Hex2Bytes("0x00000000000000000000000000000000000000000000000000000000000005dc"), + BlockNumber: block.Number, + TxHash: txHashes[2], + TxIndex: 2, + BlockHash: block.Hash, + Index: 0, + Removed: false, + }, + }, + TxHash: txHashes[2], + GasUsed: 0x58425, + EffectiveGasPrice: big.NewInt(0xb2d05e00), + BlockHash: block.Hash, + BlockNumber: new(big.Int).SetUint64(block.Number), + TransactionIndex: 2, + }, + { + Type: 0, + Status: 1, + CumulativeGasUsed: 0x1227ab, + Bloom: types.BytesToBloom(common.Hex2Bytes("0x00000000000000000000000000000200000400000000000000000000000000800000000000040000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002002000000000000000000000000000000000000000000000000000000000000000000000000000000000000200000000000800000000000000000000000000000000000000000000000000000400000000000000020000000000000000000000000002000000000000000000000000000000000000000000")), + Logs: []*types.Log{ + { + Address: common.HexToAddress("0x759c5e44a9e4be8b7e9bd25a790ceb662c924c45"), + Topics: []common.Hash{ + common.HexToHash("0x33830f93f4b524630176cdcbc04070b30ada13c6ad27081289131b77f178ff89"), + common.HexToHash("0x0000000000000000000000000000000000000000000000000000000000426a80"), + common.HexToHash("0x000000000000000000000000a6275ee214f80a532c3abee0a4cbbc2d1dc22a72"), + }, + Data: common.Hex2Bytes("0x00000000000000000000000000000000000000000000000000000000000005dc"), + BlockNumber: block.Number, + TxHash: txHashes[3], + TxIndex: 3, + BlockHash: block.Hash, + Index: 1, + Removed: false, + }, + }, + TxHash: txHashes[3], + GasUsed: 0x208a2, + EffectiveGasPrice: big.NewInt(0x59682f0a), + BlockHash: block.Hash, + BlockNumber: new(big.Int).SetUint64(block.Number), + TransactionIndex: 3, + }, + } + receiptsHash := types.DeriveSha(types.Receipts(receipts), trie.NewStackTrie(nil)) + return block, receiptsHash, txHashes, receipts + } + + t.Run("Valid", func(t *testing.T) { + block, receiptHash, txHashes, receipts := validData() + err := validateReceipts(block, receiptHash, txHashes, receipts) + require.NoError(t, err) + }) + + t.Run("NotEnoughReceipts", func(t *testing.T) { + block, receiptHash, txHashes, receipts := validData() + err := validateReceipts(block, receiptHash, txHashes, receipts[1:]) + require.ErrorContains(t, err, fmt.Sprintf("got %d receipts but expected %d", len(receipts)-1, len(receipts))) + }) + + t.Run("TooManyReceipts", func(t *testing.T) { + block, receiptHash, txHashes, receipts := validData() + err := validateReceipts(block, receiptHash, txHashes, append(receipts, receipts[0])) + require.ErrorContains(t, err, fmt.Sprintf("got %d receipts but expected %d", len(receipts)+1, len(receipts))) + }) + + t.Run("NoTxButNotEmptyTrieRoot", func(t *testing.T) { + block, receiptHash, _, _ := validData() + err := validateReceipts(block, receiptHash, nil, nil) + require.ErrorContains(t, err, "no transactions, but got non-empty receipt trie root") + }) + + t.Run("NoTxWithEmptyTrieRoot", func(t *testing.T) { + block, _, _, _ := validData() + err := validateReceipts(block, types.EmptyRootHash, nil, nil) + require.NoError(t, err) + }) + + t.Run("IncorrectReceiptRoot", func(t *testing.T) { + block, _, txHashes, receipts := validData() + err := validateReceipts(block, common.Hash{0x35}, txHashes, receipts) + require.ErrorContains(t, err, "failed to fetch list of receipts: expected receipt root") + }) + + t.Run("NilReceipt", func(t *testing.T) { + block, receiptHash, txHashes, receipts := validData() + receipts[0] = nil + err := validateReceipts(block, receiptHash, txHashes, receipts) + require.ErrorContains(t, err, "returns nil on retrieval") + }) + + t.Run("IncorrectTxIndex", func(t *testing.T) { + block, receiptHash, txHashes, receipts := validData() + receipts[0].TransactionIndex = 2 + err := validateReceipts(block, receiptHash, txHashes, receipts) + require.ErrorContains(t, err, "has unexpected tx index") + }) + + t.Run("Missing block number", func(t *testing.T) { + block, receiptHash, txHashes, receipts := validData() + receipts[0].BlockNumber = nil + err := validateReceipts(block, receiptHash, txHashes, receipts) + require.ErrorContains(t, err, "has unexpected nil block number") + }) + + t.Run("IncorrectBlockNumber", func(t *testing.T) { + block, receiptHash, txHashes, receipts := validData() + receipts[0].BlockNumber = big.NewInt(1234) + err := validateReceipts(block, receiptHash, txHashes, receipts) + require.ErrorContains(t, err, "has unexpected block number") + }) + + t.Run("IncorrectBlockHash", func(t *testing.T) { + block, receiptHash, txHashes, receipts := validData() + receipts[0].BlockHash = common.Hash{0x48} + err := validateReceipts(block, receiptHash, txHashes, receipts) + require.ErrorContains(t, err, "has unexpected block hash") + }) + + t.Run("IncorrectCumulativeUsed", func(t *testing.T) { + block, receiptHash, txHashes, receipts := validData() + receipts[1].CumulativeGasUsed = receipts[0].CumulativeGasUsed + err := validateReceipts(block, receiptHash, txHashes, receipts) + require.ErrorContains(t, err, "has invalid gas used metadata") + }) + + t.Run("IncorrectLogIndex", func(t *testing.T) { + block, receiptHash, txHashes, receipts := validData() + receipts[2].Logs[0].Index = 4 + err := validateReceipts(block, receiptHash, txHashes, receipts) + require.ErrorContains(t, err, "has unexpected log index") + }) + + t.Run("LogIndexNotBlockBased", func(t *testing.T) { + block, receiptHash, txHashes, receipts := validData() + receipts[3].Logs[0].Index = 0 + err := validateReceipts(block, receiptHash, txHashes, receipts) + require.ErrorContains(t, err, "has unexpected log index") + }) + + t.Run("IncorrectLogTxIndex", func(t *testing.T) { + block, receiptHash, txHashes, receipts := validData() + receipts[2].Logs[0].TxIndex = 1 + err := validateReceipts(block, receiptHash, txHashes, receipts) + require.ErrorContains(t, err, "has unexpected tx index") + }) + + t.Run("IncorrectLogBlockHash", func(t *testing.T) { + block, receiptHash, txHashes, receipts := validData() + receipts[2].Logs[0].BlockHash = common.Hash{0x64} + err := validateReceipts(block, receiptHash, txHashes, receipts) + require.ErrorContains(t, err, "has unexpected block hash") + }) + + t.Run("IncorrectLogBlockNumber", func(t *testing.T) { + block, receiptHash, txHashes, receipts := validData() + receipts[2].Logs[0].BlockNumber = 4727923 + err := validateReceipts(block, receiptHash, txHashes, receipts) + require.ErrorContains(t, err, "has unexpected block number") + }) + + t.Run("IncorrectLogTxHash", func(t *testing.T) { + block, receiptHash, txHashes, receipts := validData() + receipts[2].Logs[0].TxHash = common.Hash{0x87} + err := validateReceipts(block, receiptHash, txHashes, receipts) + require.ErrorContains(t, err, "has unexpected tx hash") + }) + + t.Run("Removed", func(t *testing.T) { + block, receiptHash, txHashes, receipts := validData() + receipts[2].Logs[0].Removed = true + err := validateReceipts(block, receiptHash, txHashes, receipts) + require.ErrorContains(t, err, "must never be removed due to reorg") + }) +} diff --git a/op-service/sources/reth_db.go b/op-service/sources/reth_db.go new file mode 100644 index 0000000000000..2579b95f3f870 --- /dev/null +++ b/op-service/sources/reth_db.go @@ -0,0 +1,65 @@ +//go:build rethdb + +package sources + +import ( + "encoding/json" + "fmt" + + "unsafe" + + "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/core/types" +) + +/* +#cgo LDFLAGS: -L../rethdb-reader/target/release -lrethdbreader +#include +#include +#include + +typedef struct { + char* data; + size_t data_len; + bool error; +} ReceiptsResult; + +extern ReceiptsResult rdb_read_receipts(const uint8_t* block_hash, size_t block_hash_len, const char* db_path); +extern void rdb_free_string(char* string); +*/ +import "C" + +// FetchRethReceipts fetches the receipts for the given block hash directly from the Reth Database +// and populates the given results slice pointer with the receipts that were found. +func FetchRethReceipts(dbPath string, blockHash *common.Hash) (types.Receipts, error) { + if blockHash == nil { + return nil, fmt.Errorf("Must provide a block hash to fetch receipts for.") + } + + // Convert the block hash to a C byte array and defer its deallocation + cBlockHash := C.CBytes(blockHash[:]) + defer C.free(cBlockHash) + + // Convert the db path to a C string and defer its deallocation + cDbPath := C.CString(dbPath) + defer C.free(unsafe.Pointer(cDbPath)) + + // Call the C function to fetch the receipts from the Reth Database + receiptsResult := C.rdb_read_receipts((*C.uint8_t)(cBlockHash), C.size_t(len(blockHash)), cDbPath) + + if receiptsResult.error { + return nil, fmt.Errorf("Error fetching receipts from Reth Database.") + } + + // Free the memory allocated by the C code + defer C.rdb_free_string(receiptsResult.data) + + // Convert the returned JSON string to Go string and parse it + receiptsJSON := C.GoStringN(receiptsResult.data, C.int(receiptsResult.data_len)) + var receipts types.Receipts + if err := json.Unmarshal([]byte(receiptsJSON), &receipts); err != nil { + return nil, err + } + + return receipts, nil +} diff --git a/op-service/sources/reth_db_stub.go b/op-service/sources/reth_db_stub.go new file mode 100644 index 0000000000000..be685a1d5a9c0 --- /dev/null +++ b/op-service/sources/reth_db_stub.go @@ -0,0 +1,13 @@ +//go:build !rethdb + +package sources + +import ( + "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/core/types" +) + +// FetchRethReceipts stub; Not available without `rethdb` build tag. +func FetchRethReceipts(dbPath string, blockHash *common.Hash) (types.Receipts, error) { + panic("unimplemented! Did you forget to enable the `rethdb` build tag?") +} diff --git a/op-service/sources/rollupclient.go b/op-service/sources/rollupclient.go index 3e8bdfc02febb..863305d6a101a 100644 --- a/op-service/sources/rollupclient.go +++ b/op-service/sources/rollupclient.go @@ -63,3 +63,7 @@ func (r *RollupClient) SequencerActive(ctx context.Context) (bool, error) { func (r *RollupClient) SetLogLevel(ctx context.Context, lvl log.Lvl) error { return r.rpc.CallContext(ctx, nil, "admin_setLogLevel", lvl.String()) } + +func (r *RollupClient) Close() { + r.rpc.Close() +} diff --git a/op-service/sources/testdata/data/blocks/post-shanghai-bad-receipts-hash_data.json b/op-service/sources/testdata/data/blocks/post-shanghai-bad-receipts-hash_data.json new file mode 100644 index 0000000000000..11c81ca24590f --- /dev/null +++ b/op-service/sources/testdata/data/blocks/post-shanghai-bad-receipts-hash_data.json @@ -0,0 +1 @@ +{"baseFeePerGas":"0x3fb7c357","difficulty":"0x0","extraData":"0x","gasLimit":"0x1c9c380","gasUsed":"0x18f759","hash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","logsBloom":"0x020010404000001a0000021000000080001100410000100001000010040200980220400000008806200200000100000000000000000000008000000400042000000050000040000112080808800002044000040004042008800480002000000000000002020020000042002400000820000080040000000010200010020010100101212050000008000000008000001010200c80000112010000438040020400000000202400000000002002a0210402000622010000000001700144000040000000002204000000c000410105024010000808000000002004002000000261000000822200200800881000000012500400400000000000000040010000800000","miner":"0x000095e79eac4d76aab57cb2c1f091d553b36ca0","mixHash":"0x5b53dc49cbab268ef9950b1d81b5e36a1b2f1b97aee1b7ff6e4db0e06c29a8b0","nonce":"0x0000000000000000","number":"0x84161e","parentHash":"0x72d92c1498e05952988d4e79a695928a6bcbd37239f8a1734051263b4d3504b8","receiptsRoot":"0xaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa","sha3Uncles":"0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347","size":"0x2a51","stateRoot":"0xc56738518b2c7854a640ae25996d2211c9ef0dd2e4dd9e59e9d9cacef39622da","timestamp":"0x64110a5c","totalDifficulty":"0xa4a470","transactions":[{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x1b7aa44088a0ea95bdc65fef6e5071e946bf7d8f","gas":"0x5208","gasPrice":"0x4159f01735","hash":"0x1e8f148a9aea7d8d16ea6e9446723b8f262e8bcd89c7c961d52046ebd43b4598","input":"0x","nonce":"0x279ad","to":"0xa21765a03dd41e2783696d314f235f4d520f6cac","transactionIndex":"0x0","value":"0x3782dace9d90000","type":"0x0","chainId":"0x5","v":"0x2e","r":"0xf9eca8b74ccaec5f4a83e981baeb8602f38d0271179c592b4a18f3866316a367","s":"0x350a9d26718d1fa9dc4f268f9c0e18fb96dbc037816ca8fc20f33f1a76f9f501"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x4d9a852e6aecd3a6e87fece2ca109780e45e6f2d","gas":"0x160ab","gasPrice":"0xd4babc57","maxFeePerGas":"0x11407d03e","maxPriorityFeePerGas":"0x9502f900","hash":"0xab5c870f4c367012bd763172afbfbe68fbf35336a66ae41aff3f2c9dbf4ea3f8","input":"0x60566037600b82828239805160001a607314602a57634e487b7160e01b600052600060045260246000fd5b30600052607381538281f3fe73000000000000000000000000000000000000000030146080604052600080fdfea26469706673582212200c479c99d58d7fbee5ee3aef5001431073a3d465bdfa46cf747a7c0b9289607864736f6c634300080d0033","nonce":"0xafd","to":null,"transactionIndex":"0x1","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x48f6acf4ac4371eb96ffca8cdef5b7704ea8c68a631d1c02927036d4ce92567e","s":"0x1f12261ddde63fd3da2ed9ea1bcbb4b0f25af898248c805a9d4b0a6e42caf9c8","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xce297b30e56bf2f6142c4048fbae1cb8a756fefd","gas":"0x557300","gasPrice":"0xd4babc57","maxFeePerGas":"0xfabdd183","maxPriorityFeePerGas":"0x9502f900","hash":"0xa81fd92b2d0f0bbd3cc355f869cca3243c98c5e2641db9ecf3eeabb3b13bff6a","input":"0x7bbaf1ea0000000000000000000000000000000000000000000000000000000000000005000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000000","nonce":"0xad92","to":"0x4c0ce02c1219ce5d2afffba97e484272a4637b49","transactionIndex":"0x2","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xd11b842a5f7b0e020470e764b443fafc4044327bca8dbb37131425359abace2","s":"0x1009867573946fb0a4a35339a6eaaece4d0a168b2346539076e6319e9a466b1","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x47a916d0b694c95bc0c09953c1a6e22c8867be32","gas":"0x5208","gasPrice":"0x991ff257","maxFeePerGas":"0xb2fea055","maxPriorityFeePerGas":"0x59682f00","hash":"0xa92c7b720c08c83f1a0ed7e4c163200e30a3a8c03fcc5a51e685ea20cd0cb577","input":"0x","nonce":"0x2","to":"0xf955dfe99bbfd06a8be208274cd654ecfb66a45e","transactionIndex":"0x3","value":"0x11c37937e08000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xeecd431225215c3ddc2e13cf16fa29f9a2ab1afbaa02988f3ceac27416edf0f5","s":"0x6494062330a9d509f7c778cb45cbcc9932e5f9b4ec94a1ec315f579f8d973b7b","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x672d214fe4db218defae698085a3ccefc773dfa9","gas":"0xf4f6","gasPrice":"0x991ff257","maxFeePerGas":"0xb2fea055","maxPriorityFeePerGas":"0x59682f00","hash":"0x6921b429ad2ec1e97d3457049ad2e893b5a0349beba47ca1c74a9540af75347a","input":"0xa1ddc546000000000000000000000000000000000000000000000000000000000000118f","nonce":"0x8e","to":"0xdef65f8e2f62bde60cd86ad3b4ad7fa6741cf175","transactionIndex":"0x4","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x4732ad21401b509bebb947a8566127fba1e245eb5a262ddc522d6867ab80567e","s":"0x2153013617fefdb06db0a7316d8883056441d33c2abf5ed6291fa0e3cc5c3a2f","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x0b12f7f996579fe7d9302d2574910121c214ee15","gas":"0x56a8","gasPrice":"0x991ff257","maxFeePerGas":"0xb2fea055","maxPriorityFeePerGas":"0x59682f00","hash":"0xf776b2da0b835dde05d0d8b76fd19385d61e7055036cf637f804b36dc94f2384","input":"0x71ec5c05aa669c4922569c1d33f7a81aaa21813800000000000000000000000013a0c5930c028511dc02665e7285134b6d11a5f40000000000000000000000000b12f7f996579fe7d9302d2574910121c214ee150000000000000000000000000000000000000000000000000000000000000000","nonce":"0xe","to":"0x7c125c1d515b8945841b3d5144a060115c58725f","transactionIndex":"0x5","value":"0x2386f26fc10000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xc4505d4c46ef9a0103178e5ef4fbc857114ae5c4686b68b74d07c3ee3a86e575","s":"0x74db34fd675bea7d2ee74f14fd8709cb88c7d22c2267d12f2c671b5ebc180bd5","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xd36aac0c9676e984d72823fb662ce94d3ab5e551","gas":"0xff212","gasPrice":"0x991ff257","maxFeePerGas":"0xd86d063e","maxPriorityFeePerGas":"0x59682f00","hash":"0x9a08d899cd14ebb930ed59fa774afdb88a22615b3a931e930931ea54d26dc0bc","input":"0x49160658babdf216946a22b96c966ceeba750f14807726306ebeed500a2621a7481df010000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000c0000000000000000000000000000000000000000000000000000000000000012000000000000000000000000000000000000000000000000000000000000000084d6f6f6e6265616d000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002a3078434133633746363939643335333137316438434643364236334431433764333841333233373238300000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0b616f73c8d00641109f0000054f967b8a135e44e233da070ea88c5e4a53bacac0000000000000000000000000000000000000000000000000000000000000002000000000000000000000000c6a3a17399d88e5dfd2de4fa41dcccade6a2d2170000000000000000000000008676147503f761e44b85df01811edd52be01b56c000000000000000000000000000000000000000000000000d02ab486cedc00000000000000000000000000000000000000000000000000000de0b6b3a7640000","nonce":"0x7121","to":"0x2d276bd64fe8643a1d76b2e9530c753423e972c1","transactionIndex":"0x6","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xce452361d331baf2ac86947a1b3b454b3e842923e1f39139b33a572845dd5d7c","s":"0x388126881782af5a146ce8409f1e3a2c9a4cadcfe9a2c1d27258af6e4eb5cec1","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xb83a48ee322989a0a4f838cb207abc28ec021b73","gas":"0x326ff","gasPrice":"0x991ff257","maxFeePerGas":"0x5c3362b9c","maxPriorityFeePerGas":"0x59682f00","hash":"0x0fe0d97e25d5eb11a33a3e8278584c3780941fc2675bdf8fc547cee3d1fd3b17","input":"0xa4110dbe190e65a7fe0ad5acd305c6446a02cb39de30f382000fe67927434063bf4c4b2ca86b3ee6d039dc7a0268f9e1c39266c3f12a752a7eb72f0895dedf62291fd292","nonce":"0x12e","to":"0x96e6192eeaf7bb308f79fb5017a9085754b9e12a","transactionIndex":"0x7","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x46819bb540fa459a5a0cbf041a0286507d597fc8958a6af8b9ce193f00005238","s":"0x31495c58bf4b74925f870c59635912681bee947b1cb4b08cc19f22421b1a10ab","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xb83a48ee322989a0a4f838cb207abc28ec021b73","gas":"0x3270b","gasPrice":"0x991ff257","maxFeePerGas":"0x5c3362b9c","maxPriorityFeePerGas":"0x59682f00","hash":"0xef47a60f57f177a683c723c658137efab66d311e1c5abbc4d74f653535144d03","input":"0xa4110dbe18eba3e815ec7fcb03a8eea0487209c3253024d1dc4f36f775a43fdd3e409b74c0a5c88e54f39b88db6f185a41431b204120d3e66c9b08b86f5e8382623327e5","nonce":"0x12f","to":"0x96e6192eeaf7bb308f79fb5017a9085754b9e12a","transactionIndex":"0x8","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x4d7e11fe3914763a2735493a62b71ae0028e75a750a8b06407996cf478e273c8","s":"0x60c18fdf948721f96fdc2efbf694910122e82191c7a40a5caab247c06ab7f3cf","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x7712a1f96b3f37c3dd88a22d4f7a7977b937fe62","gas":"0x1ff06","gasPrice":"0x991ff257","maxFeePerGas":"0xcf662006","maxPriorityFeePerGas":"0x59682f00","hash":"0xe23a5b35faae5335adc5aca38c5d633b00438b798c2053104b8df48406c9b141","input":"0x3ff9751b0000000000000000000000000000000000000000000000000000000000000034000000000000000000000000000000000000000000000000000000000000003500000000000000000000000000000000000000000000000000000000000000a000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000160000000000000000000000000000000000000000000000000000000000000002e516d566e75374a51566f445271536748427a72615970374879373848774a744c4669366e5546436f775447647a70000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002e516d5439716b3343525962464457704446596541763854384831676e6f6e67774b6868354a36384e4c6b4c6972360000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000041c9f31b989aaa745aecc563139f89c8ab3ab492e725d1e0305b7d602fcbf9293c463f0d2e4f5fb0c9efb54eb2cde9af10ebc9c3676f2334007291ffa8efb40adb1c00000000000000000000000000000000000000000000000000000000000000","nonce":"0x16","to":"0xc3b87ea584cb9cb5a4523e2bed16a34bf7746317","transactionIndex":"0x9","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xcc693a9544394653e1f393f02635e2c1f78b5e6c26c4d00a867bcf4adc2bc09e","s":"0x23f4b71b773c19f77cf251b2aeea03f2696bddd847d1f6d75acd2fbea6a543e4","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x12bbafcfa06423d87bed591a64c1a1f34791e90a","gas":"0x1b2e020","gasPrice":"0x8f0d3617","maxFeePerGas":"0x1cb3abd5a","maxPriorityFeePerGas":"0x4f5572c0","hash":"0xd8cea4ba619b317bc05d58534af73beec6c2548b31b24d4dc61c9bbd29cfa17a","input":"0x","nonce":"0x4d","to":"0x12bbafcfa06423d87bed591a64c1a1f34791e90a","transactionIndex":"0xa","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x8dae28608985d6ab47cbe122ee88972e38664cede30978f41944f347bad86e5c","s":"0x17c2898b39b7e3b874dc78e7df3fcff68f4d715385c632aad4bdf6e62505651c","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x6999c36394dd5d3d3295af63a4736ad6bd279448","gas":"0x14d94","gasPrice":"0x7b528d57","maxFeePerGas":"0x7df743e0","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x79a4b9d90b02c768baaad305f266281213cc75062cbe99a13222cc0c4b509498","input":"0x6a7612020000000000000000000000009008d19f58aabd9ed0d60971565aa8510560ab4100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000140000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000022000000000000000000000000000000000000000000000000000000000000000a4ec6cb13f00000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000003826d8d7371becafc0afedc3fe85b699b87f4357d55ec39ce83c510ed7d70ff514dce8236351f4627ccec6a7d9a67bc6fc2ec17ca76411113c00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000410000000000000000000000006999c36394dd5d3d3295af63a4736ad6bd27944800000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000","nonce":"0x13","to":"0xdce8236351f4627ccec6a7d9a67bc6fc2ec17ca7","transactionIndex":"0xb","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x669487011643510f7512ec15b07d74efb853ba4ad9fe9c7e9850ccf24e3d4c53","s":"0x2191f9ee81087e1df833e69d6129ec330ed4c99be2031060834e22c589fcf79b","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x08ebc052e6353b4d8392113f0f2c5decd691ddcd","gas":"0x1b2e020","gasPrice":"0x7b528d57","maxFeePerGas":"0xf6e4d9c4","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x6790a3bbddbeb21fcb736a59b3775755051c3a6344d8390cf8ca27f2e8a814f0","input":"0x6871ee40","nonce":"0x4","to":"0xb21b333c40354393f18de57f2d0a0fc21f270482","transactionIndex":"0xc","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xa7a58ab858e5dd87b9a74d550e5716ac40ddefd1c21d5baa51e542f4f941d73e","s":"0x1fd0cb1563df0368bd332717d7c8210187cd1ac2ff44f61f5242fc02eaa0c2fe","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x08ebc052e6353b4d8392113f0f2c5decd691ddcd","gas":"0x12c36","gasPrice":"0x7b528d57","maxFeePerGas":"0xe596c292","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x87ec7ace5442db252b5751ffddd38dcb04b088d36b6b0e526ff25607a4293c81","input":"0xcb40cbfd","nonce":"0x5","to":"0xb21b333c40354393f18de57f2d0a0fc21f270482","transactionIndex":"0xd","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x8e4bd40195bdfaa868af97dbf22e0b74295d95564a8381bc9bcfe1af3cde2cdb","s":"0x62057dc87c8b2b197d12c648233aab4134b7c2a2f65db89a49728564f3d0864d","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x08ebc052e6353b4d8392113f0f2c5decd691ddcd","gas":"0x12c36","gasPrice":"0x7b528d57","maxFeePerGas":"0xe596c292","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x40cb487ecffda94f97ce7fc0f7163f2f024235df2c8291169edc80dac063e6d0","input":"0xcb40cbfd","nonce":"0x6","to":"0xb21b333c40354393f18de57f2d0a0fc21f270482","transactionIndex":"0xe","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x993c4386ffc2bd63a48dd31cf5f65aa355cba3c063b08778b328d748937098e5","s":"0x203b1faf595628dd78e760bcc1740065625abb6cf00b1b17224e10fa6b424e43","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xafc7682751d3654f34958e3fb660971bf5918367","gas":"0x1b2e020","gasPrice":"0x7b528d57","maxFeePerGas":"0xefb40664","maxPriorityFeePerGas":"0x3b9aca00","hash":"0xb76bb3d88c9b30d927c45ccfcf8d5b0054411ac8501ad588822a7d04690cccf6","input":"0x40c10f19000000000000000000000000afc7682751d3654f34958e3fb660971bf59183670000000000000000000000000000000000000000000000008ac7230489e80000","nonce":"0x20","to":"0x84ced17d95f3ec7230baf4a369f1e624ae60090d","transactionIndex":"0xf","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x78e9d29c606f6a61a1428ed7326df05210d802c3061f3b469847cc461eb48025","s":"0x517afe5a21175f186233ae7a6c090cd33e028a77e5854e98eb2fa4c9284430e7","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x12bbafcfa06423d87bed591a64c1a1f34791e90a","gas":"0xcafe","gasPrice":"0x7b528d57","maxFeePerGas":"0x16ba45bce","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x798ebe823209869347c08bd81e04fbf60e9bdfe44b1cc923215182d0cf3d4edb","input":"0x40c10f1900000000000000000000000012bbafcfa06423d87bed591a64c1a1f34791e90a0000000000000000000000000000000000000000000000000000000000000032","nonce":"0x4e","to":"0xd25d682189afa7ed0c2811195b3f3d07616927bc","transactionIndex":"0x10","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xbe2aa95f4c32188c9ecbae97286ab983f7cc5a7017d46c404f8eb80b55e2dc13","s":"0x55d8968f509f51633f49260178941fd5a3db999e1995206348d7a3f05152b3d5","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x12bbafcfa06423d87bed591a64c1a1f34791e90a","gas":"0xcafe","gasPrice":"0x7b528d57","maxFeePerGas":"0xc6132c0c","maxPriorityFeePerGas":"0x3b9aca00","hash":"0xbe68a7e02725f799a65ebb069ccc83a014ac7c40e4119bf7c220a2f6ddfee295","input":"0x40c10f1900000000000000000000000012bbafcfa06423d87bed591a64c1a1f34791e90a0000000000000000000000000000000000000000000000000000000000000064","nonce":"0x4f","to":"0xd25d682189afa7ed0c2811195b3f3d07616927bc","transactionIndex":"0x11","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x1750ed45d0d2d048a61dcc3ff3e7ad0cbd395b77698c4f2eeb6baaea4c966d96","s":"0xe646e3a87b6dc50439468bcfd24cbf12a6f95b2762f1527c97a7d1b7f03530e","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xd0c0338baac9ce09c1d1caab88b4360507061e37","gas":"0x1b2e020","gasPrice":"0x7b528d57","maxFeePerGas":"0x1918167aa","maxPriorityFeePerGas":"0x3b9aca00","hash":"0xc90c3a72efe81331727fcce4b5bd4906066da314ca9a0b44023a6b09ea7e8114","input":"0x4e71d92d","nonce":"0xe7","to":"0x0137d796936e199b917b93118eb4e002508a48bd","transactionIndex":"0x12","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x22222ce8fe753082c8e5dc7478fa7b87db9c8d0fb070ebc88ab015db13fd6bb","s":"0x6dceadecf6f6a3ddc433a547dba6d5fcdfb7d006ce09eeae1c06c1828ef9fff9","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x8bd834cc1dd17d1a2f7eb6140c3dd5ab51d0f338","gas":"0x1b2e020","gasPrice":"0x7b528d57","maxFeePerGas":"0x1a4019792","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x619a6cbd43cde074d314c19623bd66d9fb1e13c158d7138775236f798dc1245e","input":"0x1da1db5e00000000000000000000000000000000000000000000000000001b5ec4ff740d","nonce":"0x10","to":"0xbad0009f7a8e796e3f975dc1d6ab3e3c237b857c","transactionIndex":"0x13","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x733c496e8c84f78d113bc8b5ad6d04a133bb10bbcecf0db93d97eeedfa3d984a","s":"0x6627c16aa7dea27db44c0f0641c30ffd544b9b9b1c299dc60611e1e01c714ee8","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x8bd834cc1dd17d1a2f7eb6140c3dd5ab51d0f338","gas":"0x11df0","gasPrice":"0x7b528d57","maxFeePerGas":"0x1d3fbccb8","maxPriorityFeePerGas":"0x3b9aca00","hash":"0xca5a56cd77b9e5b0e79020cc6346edf205bc11e901984d805125f28c2e6686e6","input":"0xd7c01032000000000000000000000000356f24c0f3187a6dcb949e4a60aa0a74a8a0327e0000000000000000000000000f8bacfae87aee49a2eec86df0c6b958ec3fd4fd0000000000000000000000000f8bacfae87aee49a2eec86df0c6b958ec3fd4fd","nonce":"0x11","to":"0xbad0009f7a8e796e3f975dc1d6ab3e3c237b857c","transactionIndex":"0x14","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x4aa872c1a7da70126917604193717575b91407f82449bca956d4089b90cd902","s":"0x4b5f788c68024f8958f66e8c768a8e0f65ef297c4ffd420a715258b0a55cb0a0","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x9bedd66b05712a1add7d1fec899b8641b3ecc863","gas":"0x1b2e020","gasPrice":"0x7b528d57","maxFeePerGas":"0x1e706c8d2","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x999c9ddeed67c6ef6fbf02a6e977a6c1b68e18d24814e51643c7157b87a43e0a","input":"0xa8b78ed0","nonce":"0x3","to":"0xf6c2afb18b85175e5ffb28f20f007c047ce28592","transactionIndex":"0x15","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xf1ca074104ee0b6a67223afd797654b8f21060453f7662dd7be79de938c396da","s":"0x4c9a4e56f0ad21e2dd8d1116c7a3e41ea2c6126853772f7897bd959e81e2e28a","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x9bedd66b05712a1add7d1fec899b8641b3ecc863","gas":"0x2dc6c0","gasPrice":"0xd4babc57","maxFeePerGas":"0x21c13e710","maxPriorityFeePerGas":"0x9502f900","hash":"0x47c8f5d0b3778e4c34eba7fcc356fa04a5afd954ccf484728e72c002764dd3c4","input":"0xf688bcfb0000000000000000000000000000000000000000000000000000000005f5e100","nonce":"0x4","to":"0xf6c2afb18b85175e5ffb28f20f007c047ce28592","transactionIndex":"0x16","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x970982425d18b9949141bbabb5c5230fa168626ce210a97f3856d64700fc0eeb","s":"0x6fa6d0aea6ae48783d80c1e51cda47e11c28b90a5497579b93d7f242d786f67e","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x4b596cebd02c35aa99878eb9ecb24d6f5ca5f865","gas":"0x5208","gasPrice":"0x68c88f79","maxFeePerGas":"0x68c88f79","maxPriorityFeePerGas":"0x68c88f79","hash":"0x396797ae0ebcdb72ff1f96fd08b6128f78acc7417353f142f1a5facd425a33e6","input":"0x","nonce":"0x1","to":"0x375980b8e1a417620ba9b18e5a9e0b17dccbac9d","transactionIndex":"0x17","value":"0x1c9a406c58878","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xcb2a7b106097b2f2a61d3a048054a5175c386b1dcdd5b6fcd7849dcac7c32a66","s":"0x10aef76e98276c47470f04a599b81c260ace9d2f6adc95755c6d22d859e805a2","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x6f4aa3bc9732372daa288beb9b2516374ace5786","gas":"0x1b2e020","gasPrice":"0x61010bda","maxFeePerGas":"0x61010bda","maxPriorityFeePerGas":"0x61010bda","hash":"0x454aa43d6546a6f62246826c16b7a49c6c704238c18802ef0d659922f23a573c","input":"0xe99a3f8000000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000480000000000000000000000000000000000000000000000000000000000000050000000000000000000000000000000000000000000000000000000000000008a000000000000000000000000058ce7eb44ae575fb3b3974861c1138dad3c5aee40000000000000000000000000000000000000000000000000000000000000120000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001e06defd69964a6ce467b87c64627a7a2be4be139b504757c625eb6114ec166557d000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000641a269023d235ef0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002a000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000002b05699353b600008ae85d840000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000020000000000000000000000000b4fbf271143f4fbf7b91a5ded31805e42b2208d600000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000001f63c28250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000020000000000000000000000000def65f8e2f62bde60cd86ad3b4ad7fa6741cf17500000000000000000000000000000000000000000000000000000000000001400000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000020000000000000000000000006e512435020ac228a15543236b1f46656f98136300000000000000000000000000000000000000000000000000000000000000fa000000000000000000000000d6ffd79b52a587a0a9941a61f4e6cb0d386d5458000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000413e24433da3efc4c3cc305339a7b77a1b31abb4e4d4967e97e42aed1dd0bf98936f43035f40bc80f6f6e3a9cfb43524a1171ee7f21e9ac2fa586d33a31f10619d1c000000000000000000000000000000000000000000000000000000000000000000000000000000000000006f4aa3bc9732372daa288beb9b2516374ace5786000000000000000000000000000000000000000000000000000000000000012000000000000000000000000058ce7eb44ae575fb3b3974861c1138dad3c5aee400000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000641a269023d235ef0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002c00000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000173ad21460000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000040000000000000000000000000def65f8e2f62bde60cd86ad3b4ad7fa6741cf1750000000000000000000000000000000000000000000000000000000000000ba200000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000002b05699353b600008ae85d840000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000020000000000000000000000000b4fbf271143f4fbf7b91a5ded31805e42b2208d600000000000000000000000000000000000000000000000000000000000000c00000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000def65f8e2f62bde60cd86ad3b4ad7fa6741cf175ffffffff09616c6c64617461","nonce":"0x82","to":"0x02afbd43cad367fcb71305a2dfb9a3928218f0c1","transactionIndex":"0x18","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xc7ac308b1ae238cb2aa4b030ca79baffb7b498e1b10df0c3354b3cc19cfabac9","s":"0x2358b1093b9aab5fae0cf751766b0bb2e3d8cd2b18ca627e1e12520990a8ed6d","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x6ece61d29b90642941c41240da924690da145696","gas":"0x4399c","gasPrice":"0x506794e0","hash":"0x317ecb5bd19caa42a69f836d41556ebb0e0e00e1c6cd2dee230e6e6192612527","input":"0x46f83b5000000000000000000000000000000000000000000000000000000000000000654666803decc59e7d0a5d3efa3c3653c05645ef4342738445e20a3b43e0b4aa8b000000000000000000000000000000000000000000000000000000000000000f4666803decc59e7d0a5d3efa3c3653c05645ef4342738445e20a3b43e0b4aa8b","nonce":"0x2cc4","to":"0xa6bf2be6c60175601bf88217c75dd4b14abb5fbb","transactionIndex":"0x19","value":"0x0","type":"0x0","chainId":"0x5","v":"0x2d","r":"0x37aeab0db6d550e6cba2c04c9cb10a2af0fec0b11f6e04b85e1ea0b8b9defeae","s":"0x4f32f4ef74872e1385c25e69bf21ee049545a4d423e939eaff29677450efe9eb"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xc4a5c059840a146b81c77bf79f1398f2b3d28ca7","gas":"0x432ec","gasPrice":"0x45db0a51","hash":"0xc879285db5ef0a6bce98021584d16f134c1dc0aed8cc988802c4f72ba6877ff6","input":"0x9f8420b300000000000000000000000000000000000000000000000000470de4df8200000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x1a7","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x1a","value":"0x470efc4514e000","type":"0x0","chainId":"0x5","v":"0x2d","r":"0x237e3a541c5ab490843cdc20d0fcb7416bff8da471f6a11ae1b32d2bab119141","s":"0x3c8417d7a60bd5b0bcae4975dbb4aaee54a4b4d588226481be400843bfe2b64e"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x6f4aa3bc9732372daa288beb9b2516374ace5786","gas":"0xffff","gasPrice":"0x44e9acbc","maxFeePerGas":"0x44e9acbc","maxPriorityFeePerGas":"0x44e9acbc","hash":"0xecaa2d6f597608307e5084854854ba6dc1e69395e2abea14f2c6a2fa1d6faf9a","input":"0xe2864fe300000000000000000000000000000000000000000000000000000000000000200000000000000000000000006f4aa3bc9732372daa288beb9b2516374ace57860000000000000000000000000000000000000000000000000000000000000120000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002004a8312e37fcecd450e6684009a2b54bc64f66afbe5217c7b2f63b03cd9980a9e00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000064893e8223d235ef0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002a00000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000173ad21460000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000040000000000000000000000000def65f8e2f62bde60cd86ad3b4ad7fa6741cf175000000000000000000000000000000000000000000000000000000000000085000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000de0b6b3a7640000aaaebeba000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001400000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000020000000000000000000000006e512435020ac228a15543236b1f46656f98136300000000000000000000000000000000000000000000000000000000000000fa000000000000000000000000d6ffd79b52a587a0a9941a61f4e6cb0d386d54580000000000000000000000000000000000000000000000000000000000000000","nonce":"0x83","to":"0x02afbd43cad367fcb71305a2dfb9a3928218f0c1","transactionIndex":"0x1b","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xa18772e4b9e1493ebfd5ae6219cc9ca060b71e83788fb614ab02b03fb36eaf1b","s":"0x482c7e50fde29bb4130fd6e723176e0e9913430ebb9260667d7fb55f5408d9c5","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xdb33365a8730de2f7574ff1189fb9d337bf4c36d","gas":"0x61a80","gasPrice":"0x433653c8","maxFeePerGas":"0x828367af","maxPriorityFeePerGas":"0x37e9071","hash":"0x4dd69b69a568ff30ae439e2ded72fbd7f2e7aaa345836703663f155c749c5eed","input":"0x7f34c0ddc6e984f46ab7c13b7a53643096e79c39103dc74550204d5bd1b5206ef5a2f49689071bb6a332212df26aa57cd4d1e3c0894187a9fc5e5d686cbedba5b187470f000000000000000000000000000000000000000000000000000000000000000e000000000000000000000000e8c44c30e8e52c38ac7bd232e7b7f0c7463a535100000000000000000000000000000000000000000000000000000000000000a0000000000000000000000000000000000000000000000000000000000000002e516d5044645856613738437a6b7856325a364e52777a67685a785872736e75397261616a695a7555423569465a62000000000000000000000000000000000000","nonce":"0x2b57","to":"0xb8ad54644e2371cbb7940b9fa0936f399ba7495f","transactionIndex":"0x1c","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xa1fb0e5662b54ceb3dc1623ebfb200668433cb27252d553669bcd136387394f3","s":"0x27c2f8e19f69a52a0960f05d8b21f11c313dd3e86a7139b5783a18353c407415","yParity":"0x0"}],"transactionsRoot":"0x4a87d0cf5990b1c5bac631583e5965c2ba943858bebb2e07f74d0b697f73821a","uncles":[],"withdrawals":[{"index":"0x1170","validatorIndex":"0x38c2c","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x66edfd65"},{"index":"0x1171","validatorIndex":"0x38c2d","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6cd228e4"},{"index":"0x1172","validatorIndex":"0x38c2e","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x77f3431b"},{"index":"0x1173","validatorIndex":"0x38c2f","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6b61f268"},{"index":"0x1174","validatorIndex":"0x38c30","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6e10bb21"},{"index":"0x1175","validatorIndex":"0x38c31","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6eb115a5"},{"index":"0x1176","validatorIndex":"0x38c32","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x7caead1d"},{"index":"0x1177","validatorIndex":"0x38c33","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x772c0ddf"},{"index":"0x1178","validatorIndex":"0x38c34","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x75930a95"},{"index":"0x1179","validatorIndex":"0x38c35","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x76a4db09"},{"index":"0x117a","validatorIndex":"0x38c36","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x7e692b27"},{"index":"0x117b","validatorIndex":"0x38c37","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x72038ae6"},{"index":"0x117c","validatorIndex":"0x38c38","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6ccce352"},{"index":"0x117d","validatorIndex":"0x38c39","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x79ef6898"},{"index":"0x117e","validatorIndex":"0x38c3a","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6d58977d"},{"index":"0x117f","validatorIndex":"0x38c3b","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x76f7d208"}],"withdrawalsRoot":"0xbe712c930a0665264b025ced87cc7839eef95a3cbc26dadc93e9e185a350ad28"} diff --git a/op-service/sources/testdata/data/blocks/post-shanghai-bad-receipts-hash_metadata.json b/op-service/sources/testdata/data/blocks/post-shanghai-bad-receipts-hash_metadata.json new file mode 100644 index 0000000000000..62535fdc0388d --- /dev/null +++ b/op-service/sources/testdata/data/blocks/post-shanghai-bad-receipts-hash_metadata.json @@ -0,0 +1 @@ +{"name":"post-shanghai-bad-receipts-hash","fail":true, "reason":"failed to verify block hash"} diff --git a/op-service/sources/testdata/data/blocks/post-shanghai-bad-transactions-hash_data.json b/op-service/sources/testdata/data/blocks/post-shanghai-bad-transactions-hash_data.json new file mode 100644 index 0000000000000..f82f515d96dd3 --- /dev/null +++ b/op-service/sources/testdata/data/blocks/post-shanghai-bad-transactions-hash_data.json @@ -0,0 +1 @@ +{"baseFeePerGas":"0x3fb7c357","difficulty":"0x0","extraData":"0x","gasLimit":"0x1c9c380","gasUsed":"0x18f759","hash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","logsBloom":"0x020010404000001a0000021000000080001100410000100001000010040200980220400000008806200200000100000000000000000000008000000400042000000050000040000112080808800002044000040004042008800480002000000000000002020020000042002400000820000080040000000010200010020010100101212050000008000000008000001010200c80000112010000438040020400000000202400000000002002a0210402000622010000000001700144000040000000002204000000c000410105024010000808000000002004002000000261000000822200200800881000000012500400400000000000000040010000800000","miner":"0x000095e79eac4d76aab57cb2c1f091d553b36ca0","mixHash":"0x5b53dc49cbab268ef9950b1d81b5e36a1b2f1b97aee1b7ff6e4db0e06c29a8b0","nonce":"0x0000000000000000","number":"0x84161e","parentHash":"0x72d92c1498e05952988d4e79a695928a6bcbd37239f8a1734051263b4d3504b8","receiptsRoot":"0xaff90ae18dcc35924a4bddb68d403b8b7812c10c3ea2a114f34105c87d75bcdb","sha3Uncles":"0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347","size":"0x2a51","stateRoot":"0xc56738518b2c7854a640ae25996d2211c9ef0dd2e4dd9e59e9d9cacef39622da","timestamp":"0x64110a5c","totalDifficulty":"0xa4a470","transactions":[{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x1b7aa44088a0ea95bdc65fef6e5071e946bf7d8f","gas":"0x5208","gasPrice":"0x4159f01735","hash":"0x1e8f148a9aea7d8d16ea6e9446723b8f262e8bcd89c7c961d52046ebd43b4598","input":"0x","nonce":"0x279ad","to":"0xa21765a03dd41e2783696d314f235f4d520f6cac","transactionIndex":"0x0","value":"0x3782dace9d90000","type":"0x0","chainId":"0x5","v":"0x2e","r":"0xf9eca8b74ccaec5f4a83e981baeb8602f38d0271179c592b4a18f3866316a367","s":"0x350a9d26718d1fa9dc4f268f9c0e18fb96dbc037816ca8fc20f33f1a76f9f501"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x4d9a852e6aecd3a6e87fece2ca109780e45e6f2d","gas":"0x160ab","gasPrice":"0xd4babc57","maxFeePerGas":"0x11407d03e","maxPriorityFeePerGas":"0x9502f900","hash":"0xab5c870f4c367012bd763172afbfbe68fbf35336a66ae41aff3f2c9dbf4ea3f8","input":"0x60566037600b82828239805160001a607314602a57634e487b7160e01b600052600060045260246000fd5b30600052607381538281f3fe73000000000000000000000000000000000000000030146080604052600080fdfea26469706673582212200c479c99d58d7fbee5ee3aef5001431073a3d465bdfa46cf747a7c0b9289607864736f6c634300080d0033","nonce":"0xafd","to":null,"transactionIndex":"0x1","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x48f6acf4ac4371eb96ffca8cdef5b7704ea8c68a631d1c02927036d4ce92567e","s":"0x1f12261ddde63fd3da2ed9ea1bcbb4b0f25af898248c805a9d4b0a6e42caf9c8","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xce297b30e56bf2f6142c4048fbae1cb8a756fefd","gas":"0x557300","gasPrice":"0xd4babc57","maxFeePerGas":"0xfabdd183","maxPriorityFeePerGas":"0x9502f900","hash":"0xa81fd92b2d0f0bbd3cc355f869cca3243c98c5e2641db9ecf3eeabb3b13bff6a","input":"0x7bbaf1ea0000000000000000000000000000000000000000000000000000000000000005000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000000","nonce":"0xad92","to":"0x4c0ce02c1219ce5d2afffba97e484272a4637b49","transactionIndex":"0x2","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xd11b842a5f7b0e020470e764b443fafc4044327bca8dbb37131425359abace2","s":"0x1009867573946fb0a4a35339a6eaaece4d0a168b2346539076e6319e9a466b1","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x47a916d0b694c95bc0c09953c1a6e22c8867be32","gas":"0x5208","gasPrice":"0x991ff257","maxFeePerGas":"0xb2fea055","maxPriorityFeePerGas":"0x59682f00","hash":"0xa92c7b720c08c83f1a0ed7e4c163200e30a3a8c03fcc5a51e685ea20cd0cb577","input":"0x","nonce":"0x2","to":"0xf955dfe99bbfd06a8be208274cd654ecfb66a45e","transactionIndex":"0x3","value":"0x11c37937e08000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xeecd431225215c3ddc2e13cf16fa29f9a2ab1afbaa02988f3ceac27416edf0f5","s":"0x6494062330a9d509f7c778cb45cbcc9932e5f9b4ec94a1ec315f579f8d973b7b","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x672d214fe4db218defae698085a3ccefc773dfa9","gas":"0xf4f6","gasPrice":"0x991ff257","maxFeePerGas":"0xb2fea055","maxPriorityFeePerGas":"0x59682f00","hash":"0x6921b429ad2ec1e97d3457049ad2e893b5a0349beba47ca1c74a9540af75347a","input":"0xa1ddc546000000000000000000000000000000000000000000000000000000000000118f","nonce":"0x8e","to":"0xdef65f8e2f62bde60cd86ad3b4ad7fa6741cf175","transactionIndex":"0x4","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x4732ad21401b509bebb947a8566127fba1e245eb5a262ddc522d6867ab80567e","s":"0x2153013617fefdb06db0a7316d8883056441d33c2abf5ed6291fa0e3cc5c3a2f","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x0b12f7f996579fe7d9302d2574910121c214ee15","gas":"0x56a8","gasPrice":"0x991ff257","maxFeePerGas":"0xb2fea055","maxPriorityFeePerGas":"0x59682f00","hash":"0xf776b2da0b835dde05d0d8b76fd19385d61e7055036cf637f804b36dc94f2384","input":"0x71ec5c05aa669c4922569c1d33f7a81aaa21813800000000000000000000000013a0c5930c028511dc02665e7285134b6d11a5f40000000000000000000000000b12f7f996579fe7d9302d2574910121c214ee150000000000000000000000000000000000000000000000000000000000000000","nonce":"0xe","to":"0x7c125c1d515b8945841b3d5144a060115c58725f","transactionIndex":"0x5","value":"0x2386f26fc10000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xc4505d4c46ef9a0103178e5ef4fbc857114ae5c4686b68b74d07c3ee3a86e575","s":"0x74db34fd675bea7d2ee74f14fd8709cb88c7d22c2267d12f2c671b5ebc180bd5","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xd36aac0c9676e984d72823fb662ce94d3ab5e551","gas":"0xff212","gasPrice":"0x991ff257","maxFeePerGas":"0xd86d063e","maxPriorityFeePerGas":"0x59682f00","hash":"0x9a08d899cd14ebb930ed59fa774afdb88a22615b3a931e930931ea54d26dc0bc","input":"0x49160658babdf216946a22b96c966ceeba750f14807726306ebeed500a2621a7481df010000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000c0000000000000000000000000000000000000000000000000000000000000012000000000000000000000000000000000000000000000000000000000000000084d6f6f6e6265616d000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002a3078434133633746363939643335333137316438434643364236334431433764333841333233373238300000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0b616f73c8d00641109f0000054f967b8a135e44e233da070ea88c5e4a53bacac0000000000000000000000000000000000000000000000000000000000000002000000000000000000000000c6a3a17399d88e5dfd2de4fa41dcccade6a2d2170000000000000000000000008676147503f761e44b85df01811edd52be01b56c000000000000000000000000000000000000000000000000d02ab486cedc00000000000000000000000000000000000000000000000000000de0b6b3a7640000","nonce":"0x7121","to":"0x2d276bd64fe8643a1d76b2e9530c753423e972c1","transactionIndex":"0x6","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xce452361d331baf2ac86947a1b3b454b3e842923e1f39139b33a572845dd5d7c","s":"0x388126881782af5a146ce8409f1e3a2c9a4cadcfe9a2c1d27258af6e4eb5cec1","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xb83a48ee322989a0a4f838cb207abc28ec021b73","gas":"0x326ff","gasPrice":"0x991ff257","maxFeePerGas":"0x5c3362b9c","maxPriorityFeePerGas":"0x59682f00","hash":"0x0fe0d97e25d5eb11a33a3e8278584c3780941fc2675bdf8fc547cee3d1fd3b17","input":"0xa4110dbe190e65a7fe0ad5acd305c6446a02cb39de30f382000fe67927434063bf4c4b2ca86b3ee6d039dc7a0268f9e1c39266c3f12a752a7eb72f0895dedf62291fd292","nonce":"0x12e","to":"0x96e6192eeaf7bb308f79fb5017a9085754b9e12a","transactionIndex":"0x7","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x46819bb540fa459a5a0cbf041a0286507d597fc8958a6af8b9ce193f00005238","s":"0x31495c58bf4b74925f870c59635912681bee947b1cb4b08cc19f22421b1a10ab","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xb83a48ee322989a0a4f838cb207abc28ec021b73","gas":"0x3270b","gasPrice":"0x991ff257","maxFeePerGas":"0x5c3362b9c","maxPriorityFeePerGas":"0x59682f00","hash":"0xef47a60f57f177a683c723c658137efab66d311e1c5abbc4d74f653535144d03","input":"0xa4110dbe18eba3e815ec7fcb03a8eea0487209c3253024d1dc4f36f775a43fdd3e409b74c0a5c88e54f39b88db6f185a41431b204120d3e66c9b08b86f5e8382623327e5","nonce":"0x12f","to":"0x96e6192eeaf7bb308f79fb5017a9085754b9e12a","transactionIndex":"0x8","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x4d7e11fe3914763a2735493a62b71ae0028e75a750a8b06407996cf478e273c8","s":"0x60c18fdf948721f96fdc2efbf694910122e82191c7a40a5caab247c06ab7f3cf","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x7712a1f96b3f37c3dd88a22d4f7a7977b937fe62","gas":"0x1ff06","gasPrice":"0x991ff257","maxFeePerGas":"0xcf662006","maxPriorityFeePerGas":"0x59682f00","hash":"0xe23a5b35faae5335adc5aca38c5d633b00438b798c2053104b8df48406c9b141","input":"0x3ff9751b0000000000000000000000000000000000000000000000000000000000000034000000000000000000000000000000000000000000000000000000000000003500000000000000000000000000000000000000000000000000000000000000a000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000160000000000000000000000000000000000000000000000000000000000000002e516d566e75374a51566f445271536748427a72615970374879373848774a744c4669366e5546436f775447647a70000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002e516d5439716b3343525962464457704446596541763854384831676e6f6e67774b6868354a36384e4c6b4c6972360000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000041c9f31b989aaa745aecc563139f89c8ab3ab492e725d1e0305b7d602fcbf9293c463f0d2e4f5fb0c9efb54eb2cde9af10ebc9c3676f2334007291ffa8efb40adb1c00000000000000000000000000000000000000000000000000000000000000","nonce":"0x16","to":"0xc3b87ea584cb9cb5a4523e2bed16a34bf7746317","transactionIndex":"0x9","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xcc693a9544394653e1f393f02635e2c1f78b5e6c26c4d00a867bcf4adc2bc09e","s":"0x23f4b71b773c19f77cf251b2aeea03f2696bddd847d1f6d75acd2fbea6a543e4","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x12bbafcfa06423d87bed591a64c1a1f34791e90a","gas":"0x1b2e020","gasPrice":"0x8f0d3617","maxFeePerGas":"0x1cb3abd5a","maxPriorityFeePerGas":"0x4f5572c0","hash":"0xd8cea4ba619b317bc05d58534af73beec6c2548b31b24d4dc61c9bbd29cfa17a","input":"0x","nonce":"0x4d","to":"0x12bbafcfa06423d87bed591a64c1a1f34791e90a","transactionIndex":"0xa","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x8dae28608985d6ab47cbe122ee88972e38664cede30978f41944f347bad86e5c","s":"0x17c2898b39b7e3b874dc78e7df3fcff68f4d715385c632aad4bdf6e62505651c","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x6999c36394dd5d3d3295af63a4736ad6bd279448","gas":"0x14d94","gasPrice":"0x7b528d57","maxFeePerGas":"0x7df743e0","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x79a4b9d90b02c768baaad305f266281213cc75062cbe99a13222cc0c4b509498","input":"0x6a7612020000000000000000000000009008d19f58aabd9ed0d60971565aa8510560ab4100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000140000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000022000000000000000000000000000000000000000000000000000000000000000a4ec6cb13f00000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000003826d8d7371becafc0afedc3fe85b699b87f4357d55ec39ce83c510ed7d70ff514dce8236351f4627ccec6a7d9a67bc6fc2ec17ca76411113c00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000410000000000000000000000006999c36394dd5d3d3295af63a4736ad6bd27944800000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000","nonce":"0x13","to":"0xdce8236351f4627ccec6a7d9a67bc6fc2ec17ca7","transactionIndex":"0xb","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x669487011643510f7512ec15b07d74efb853ba4ad9fe9c7e9850ccf24e3d4c53","s":"0x2191f9ee81087e1df833e69d6129ec330ed4c99be2031060834e22c589fcf79b","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x08ebc052e6353b4d8392113f0f2c5decd691ddcd","gas":"0x1b2e020","gasPrice":"0x7b528d57","maxFeePerGas":"0xf6e4d9c4","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x6790a3bbddbeb21fcb736a59b3775755051c3a6344d8390cf8ca27f2e8a814f0","input":"0x6871ee40","nonce":"0x4","to":"0xb21b333c40354393f18de57f2d0a0fc21f270482","transactionIndex":"0xc","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xa7a58ab858e5dd87b9a74d550e5716ac40ddefd1c21d5baa51e542f4f941d73e","s":"0x1fd0cb1563df0368bd332717d7c8210187cd1ac2ff44f61f5242fc02eaa0c2fe","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x08ebc052e6353b4d8392113f0f2c5decd691ddcd","gas":"0x12c36","gasPrice":"0x7b528d57","maxFeePerGas":"0xe596c292","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x87ec7ace5442db252b5751ffddd38dcb04b088d36b6b0e526ff25607a4293c81","input":"0xcb40cbfd","nonce":"0x5","to":"0xb21b333c40354393f18de57f2d0a0fc21f270482","transactionIndex":"0xd","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x8e4bd40195bdfaa868af97dbf22e0b74295d95564a8381bc9bcfe1af3cde2cdb","s":"0x62057dc87c8b2b197d12c648233aab4134b7c2a2f65db89a49728564f3d0864d","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x08ebc052e6353b4d8392113f0f2c5decd691ddcd","gas":"0x12c36","gasPrice":"0x7b528d57","maxFeePerGas":"0xe596c292","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x40cb487ecffda94f97ce7fc0f7163f2f024235df2c8291169edc80dac063e6d0","input":"0xcb40cbfd","nonce":"0x6","to":"0xb21b333c40354393f18de57f2d0a0fc21f270482","transactionIndex":"0xe","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x993c4386ffc2bd63a48dd31cf5f65aa355cba3c063b08778b328d748937098e5","s":"0x203b1faf595628dd78e760bcc1740065625abb6cf00b1b17224e10fa6b424e43","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xafc7682751d3654f34958e3fb660971bf5918367","gas":"0x1b2e020","gasPrice":"0x7b528d57","maxFeePerGas":"0xefb40664","maxPriorityFeePerGas":"0x3b9aca00","hash":"0xb76bb3d88c9b30d927c45ccfcf8d5b0054411ac8501ad588822a7d04690cccf6","input":"0x40c10f19000000000000000000000000afc7682751d3654f34958e3fb660971bf59183670000000000000000000000000000000000000000000000008ac7230489e80000","nonce":"0x20","to":"0x84ced17d95f3ec7230baf4a369f1e624ae60090d","transactionIndex":"0xf","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x78e9d29c606f6a61a1428ed7326df05210d802c3061f3b469847cc461eb48025","s":"0x517afe5a21175f186233ae7a6c090cd33e028a77e5854e98eb2fa4c9284430e7","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x12bbafcfa06423d87bed591a64c1a1f34791e90a","gas":"0xcafe","gasPrice":"0x7b528d57","maxFeePerGas":"0x16ba45bce","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x798ebe823209869347c08bd81e04fbf60e9bdfe44b1cc923215182d0cf3d4edb","input":"0x40c10f1900000000000000000000000012bbafcfa06423d87bed591a64c1a1f34791e90a0000000000000000000000000000000000000000000000000000000000000032","nonce":"0x4e","to":"0xd25d682189afa7ed0c2811195b3f3d07616927bc","transactionIndex":"0x10","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xbe2aa95f4c32188c9ecbae97286ab983f7cc5a7017d46c404f8eb80b55e2dc13","s":"0x55d8968f509f51633f49260178941fd5a3db999e1995206348d7a3f05152b3d5","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x12bbafcfa06423d87bed591a64c1a1f34791e90a","gas":"0xcafe","gasPrice":"0x7b528d57","maxFeePerGas":"0xc6132c0c","maxPriorityFeePerGas":"0x3b9aca00","hash":"0xbe68a7e02725f799a65ebb069ccc83a014ac7c40e4119bf7c220a2f6ddfee295","input":"0x40c10f1900000000000000000000000012bbafcfa06423d87bed591a64c1a1f34791e90a0000000000000000000000000000000000000000000000000000000000000064","nonce":"0x4f","to":"0xd25d682189afa7ed0c2811195b3f3d07616927bc","transactionIndex":"0x11","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x1750ed45d0d2d048a61dcc3ff3e7ad0cbd395b77698c4f2eeb6baaea4c966d96","s":"0xe646e3a87b6dc50439468bcfd24cbf12a6f95b2762f1527c97a7d1b7f03530e","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xd0c0338baac9ce09c1d1caab88b4360507061e37","gas":"0x1b2e020","gasPrice":"0x7b528d57","maxFeePerGas":"0x1918167aa","maxPriorityFeePerGas":"0x3b9aca00","hash":"0xc90c3a72efe81331727fcce4b5bd4906066da314ca9a0b44023a6b09ea7e8114","input":"0x4e71d92d","nonce":"0xe7","to":"0x0137d796936e199b917b93118eb4e002508a48bd","transactionIndex":"0x12","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x22222ce8fe753082c8e5dc7478fa7b87db9c8d0fb070ebc88ab015db13fd6bb","s":"0x6dceadecf6f6a3ddc433a547dba6d5fcdfb7d006ce09eeae1c06c1828ef9fff9","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x8bd834cc1dd17d1a2f7eb6140c3dd5ab51d0f338","gas":"0x1b2e020","gasPrice":"0x7b528d57","maxFeePerGas":"0x1a4019792","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x619a6cbd43cde074d314c19623bd66d9fb1e13c158d7138775236f798dc1245e","input":"0x1da1db5e00000000000000000000000000000000000000000000000000001b5ec4ff740d","nonce":"0x10","to":"0xbad0009f7a8e796e3f975dc1d6ab3e3c237b857c","transactionIndex":"0x13","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x733c496e8c84f78d113bc8b5ad6d04a133bb10bbcecf0db93d97eeedfa3d984a","s":"0x6627c16aa7dea27db44c0f0641c30ffd544b9b9b1c299dc60611e1e01c714ee8","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x8bd834cc1dd17d1a2f7eb6140c3dd5ab51d0f338","gas":"0x11df0","gasPrice":"0x7b528d57","maxFeePerGas":"0x1d3fbccb8","maxPriorityFeePerGas":"0x3b9aca00","hash":"0xca5a56cd77b9e5b0e79020cc6346edf205bc11e901984d805125f28c2e6686e6","input":"0xd7c01032000000000000000000000000356f24c0f3187a6dcb949e4a60aa0a74a8a0327e0000000000000000000000000f8bacfae87aee49a2eec86df0c6b958ec3fd4fd0000000000000000000000000f8bacfae87aee49a2eec86df0c6b958ec3fd4fd","nonce":"0x11","to":"0xbad0009f7a8e796e3f975dc1d6ab3e3c237b857c","transactionIndex":"0x14","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x4aa872c1a7da70126917604193717575b91407f82449bca956d4089b90cd902","s":"0x4b5f788c68024f8958f66e8c768a8e0f65ef297c4ffd420a715258b0a55cb0a0","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x9bedd66b05712a1add7d1fec899b8641b3ecc863","gas":"0x1b2e020","gasPrice":"0x7b528d57","maxFeePerGas":"0x1e706c8d2","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x999c9ddeed67c6ef6fbf02a6e977a6c1b68e18d24814e51643c7157b87a43e0a","input":"0xa8b78ed0","nonce":"0x3","to":"0xf6c2afb18b85175e5ffb28f20f007c047ce28592","transactionIndex":"0x15","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xf1ca074104ee0b6a67223afd797654b8f21060453f7662dd7be79de938c396da","s":"0x4c9a4e56f0ad21e2dd8d1116c7a3e41ea2c6126853772f7897bd959e81e2e28a","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x9bedd66b05712a1add7d1fec899b8641b3ecc863","gas":"0x2dc6c0","gasPrice":"0xd4babc57","maxFeePerGas":"0x21c13e710","maxPriorityFeePerGas":"0x9502f900","hash":"0x47c8f5d0b3778e4c34eba7fcc356fa04a5afd954ccf484728e72c002764dd3c4","input":"0xf688bcfb0000000000000000000000000000000000000000000000000000000005f5e100","nonce":"0x4","to":"0xf6c2afb18b85175e5ffb28f20f007c047ce28592","transactionIndex":"0x16","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x970982425d18b9949141bbabb5c5230fa168626ce210a97f3856d64700fc0eeb","s":"0x6fa6d0aea6ae48783d80c1e51cda47e11c28b90a5497579b93d7f242d786f67e","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x4b596cebd02c35aa99878eb9ecb24d6f5ca5f865","gas":"0x5208","gasPrice":"0x68c88f79","maxFeePerGas":"0x68c88f79","maxPriorityFeePerGas":"0x68c88f79","hash":"0x396797ae0ebcdb72ff1f96fd08b6128f78acc7417353f142f1a5facd425a33e6","input":"0x","nonce":"0x1","to":"0x375980b8e1a417620ba9b18e5a9e0b17dccbac9d","transactionIndex":"0x17","value":"0x1c9a406c58878","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xcb2a7b106097b2f2a61d3a048054a5175c386b1dcdd5b6fcd7849dcac7c32a66","s":"0x10aef76e98276c47470f04a599b81c260ace9d2f6adc95755c6d22d859e805a2","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x6f4aa3bc9732372daa288beb9b2516374ace5786","gas":"0x1b2e020","gasPrice":"0x61010bda","maxFeePerGas":"0x61010bda","maxPriorityFeePerGas":"0x61010bda","hash":"0x454aa43d6546a6f62246826c16b7a49c6c704238c18802ef0d659922f23a573c","input":"0xe99a3f8000000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000480000000000000000000000000000000000000000000000000000000000000050000000000000000000000000000000000000000000000000000000000000008a000000000000000000000000058ce7eb44ae575fb3b3974861c1138dad3c5aee40000000000000000000000000000000000000000000000000000000000000120000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001e06defd69964a6ce467b87c64627a7a2be4be139b504757c625eb6114ec166557d000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000641a269023d235ef0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002a000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000002b05699353b600008ae85d840000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000020000000000000000000000000b4fbf271143f4fbf7b91a5ded31805e42b2208d600000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000001f63c28250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000020000000000000000000000000def65f8e2f62bde60cd86ad3b4ad7fa6741cf17500000000000000000000000000000000000000000000000000000000000001400000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000020000000000000000000000006e512435020ac228a15543236b1f46656f98136300000000000000000000000000000000000000000000000000000000000000fa000000000000000000000000d6ffd79b52a587a0a9941a61f4e6cb0d386d5458000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000413e24433da3efc4c3cc305339a7b77a1b31abb4e4d4967e97e42aed1dd0bf98936f43035f40bc80f6f6e3a9cfb43524a1171ee7f21e9ac2fa586d33a31f10619d1c000000000000000000000000000000000000000000000000000000000000000000000000000000000000006f4aa3bc9732372daa288beb9b2516374ace5786000000000000000000000000000000000000000000000000000000000000012000000000000000000000000058ce7eb44ae575fb3b3974861c1138dad3c5aee400000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000641a269023d235ef0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002c00000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000173ad21460000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000040000000000000000000000000def65f8e2f62bde60cd86ad3b4ad7fa6741cf1750000000000000000000000000000000000000000000000000000000000000ba200000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000002b05699353b600008ae85d840000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000020000000000000000000000000b4fbf271143f4fbf7b91a5ded31805e42b2208d600000000000000000000000000000000000000000000000000000000000000c00000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000def65f8e2f62bde60cd86ad3b4ad7fa6741cf175ffffffff09616c6c64617461","nonce":"0x82","to":"0x02afbd43cad367fcb71305a2dfb9a3928218f0c1","transactionIndex":"0x18","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xc7ac308b1ae238cb2aa4b030ca79baffb7b498e1b10df0c3354b3cc19cfabac9","s":"0x2358b1093b9aab5fae0cf751766b0bb2e3d8cd2b18ca627e1e12520990a8ed6d","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x6ece61d29b90642941c41240da924690da145696","gas":"0x4399c","gasPrice":"0x506794e0","hash":"0x317ecb5bd19caa42a69f836d41556ebb0e0e00e1c6cd2dee230e6e6192612527","input":"0x46f83b5000000000000000000000000000000000000000000000000000000000000000654666803decc59e7d0a5d3efa3c3653c05645ef4342738445e20a3b43e0b4aa8b000000000000000000000000000000000000000000000000000000000000000f4666803decc59e7d0a5d3efa3c3653c05645ef4342738445e20a3b43e0b4aa8b","nonce":"0x2cc4","to":"0xa6bf2be6c60175601bf88217c75dd4b14abb5fbb","transactionIndex":"0x19","value":"0x0","type":"0x0","chainId":"0x5","v":"0x2d","r":"0x37aeab0db6d550e6cba2c04c9cb10a2af0fec0b11f6e04b85e1ea0b8b9defeae","s":"0x4f32f4ef74872e1385c25e69bf21ee049545a4d423e939eaff29677450efe9eb"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xc4a5c059840a146b81c77bf79f1398f2b3d28ca7","gas":"0x432ec","gasPrice":"0x45db0a51","hash":"0xc879285db5ef0a6bce98021584d16f134c1dc0aed8cc988802c4f72ba6877ff6","input":"0x9f8420b300000000000000000000000000000000000000000000000000470de4df8200000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x1a7","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x1a","value":"0x470efc4514e000","type":"0x0","chainId":"0x5","v":"0x2d","r":"0x237e3a541c5ab490843cdc20d0fcb7416bff8da471f6a11ae1b32d2bab119141","s":"0x3c8417d7a60bd5b0bcae4975dbb4aaee54a4b4d588226481be400843bfe2b64e"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x6f4aa3bc9732372daa288beb9b2516374ace5786","gas":"0xffff","gasPrice":"0x44e9acbc","maxFeePerGas":"0x44e9acbc","maxPriorityFeePerGas":"0x44e9acbc","hash":"0xecaa2d6f597608307e5084854854ba6dc1e69395e2abea14f2c6a2fa1d6faf9a","input":"0xe2864fe300000000000000000000000000000000000000000000000000000000000000200000000000000000000000006f4aa3bc9732372daa288beb9b2516374ace57860000000000000000000000000000000000000000000000000000000000000120000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002004a8312e37fcecd450e6684009a2b54bc64f66afbe5217c7b2f63b03cd9980a9e00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000064893e8223d235ef0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002a00000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000173ad21460000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000040000000000000000000000000def65f8e2f62bde60cd86ad3b4ad7fa6741cf175000000000000000000000000000000000000000000000000000000000000085000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000de0b6b3a7640000aaaebeba000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001400000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000020000000000000000000000006e512435020ac228a15543236b1f46656f98136300000000000000000000000000000000000000000000000000000000000000fa000000000000000000000000d6ffd79b52a587a0a9941a61f4e6cb0d386d54580000000000000000000000000000000000000000000000000000000000000000","nonce":"0x83","to":"0x02afbd43cad367fcb71305a2dfb9a3928218f0c1","transactionIndex":"0x1b","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xa18772e4b9e1493ebfd5ae6219cc9ca060b71e83788fb614ab02b03fb36eaf1b","s":"0x482c7e50fde29bb4130fd6e723176e0e9913430ebb9260667d7fb55f5408d9c5","yParity":"0x1"}],"transactionsRoot":"0x038aa965036f8a4fc4825a83ae35ec6135b936ad429b47bd14961d744e2fc2ac","uncles":[],"withdrawals":[{"index":"0x1170","validatorIndex":"0x38c2c","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x66edfd65"},{"index":"0x1171","validatorIndex":"0x38c2d","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6cd228e4"},{"index":"0x1172","validatorIndex":"0x38c2e","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x77f3431b"},{"index":"0x1173","validatorIndex":"0x38c2f","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6b61f268"},{"index":"0x1174","validatorIndex":"0x38c30","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6e10bb21"},{"index":"0x1175","validatorIndex":"0x38c31","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6eb115a5"},{"index":"0x1176","validatorIndex":"0x38c32","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x7caead1d"},{"index":"0x1177","validatorIndex":"0x38c33","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x772c0ddf"},{"index":"0x1178","validatorIndex":"0x38c34","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x75930a95"},{"index":"0x1179","validatorIndex":"0x38c35","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x76a4db09"},{"index":"0x117a","validatorIndex":"0x38c36","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x7e692b27"},{"index":"0x117b","validatorIndex":"0x38c37","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x72038ae6"},{"index":"0x117c","validatorIndex":"0x38c38","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6ccce352"},{"index":"0x117d","validatorIndex":"0x38c39","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x79ef6898"},{"index":"0x117e","validatorIndex":"0x38c3a","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6d58977d"},{"index":"0x117f","validatorIndex":"0x38c3b","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x76f7d208"}],"withdrawalsRoot":"0xbe712c930a0665264b025ced87cc7839eef95a3cbc26dadc93e9e185a350ad28"} diff --git a/op-service/sources/testdata/data/blocks/post-shanghai-bad-transactions-hash_metadata.json b/op-service/sources/testdata/data/blocks/post-shanghai-bad-transactions-hash_metadata.json new file mode 100644 index 0000000000000..33f6dc140e878 --- /dev/null +++ b/op-service/sources/testdata/data/blocks/post-shanghai-bad-transactions-hash_metadata.json @@ -0,0 +1 @@ +{"name":"post-shanghai-bad-transactions-hash","fail":true, "reason":"failed to verify block hash"} diff --git a/op-service/sources/testdata/data/blocks/post-shanghai-bad-transactions-nil_data.json b/op-service/sources/testdata/data/blocks/post-shanghai-bad-transactions-nil_data.json new file mode 100644 index 0000000000000..9c030f27cec1b --- /dev/null +++ b/op-service/sources/testdata/data/blocks/post-shanghai-bad-transactions-nil_data.json @@ -0,0 +1 @@ +{"baseFeePerGas":"0x3fb7c357","difficulty":"0x0","extraData":"0x","gasLimit":"0x1c9c380","gasUsed":"0x18f759","hash":"0x0afe3cbfbf24c0b097b50864b8aaf9f819cf56d4b2b6a67b1edff20bc2a66ad2","logsBloom":"0x020010404000001a0000021000000080001100410000100001000010040200980220400000008806200200000100000000000000000000008000000400042000000050000040000112080808800002044000040004042008800480002000000000000002020020000042002400000820000080040000000010200010020010100101212050000008000000008000001010200c80000112010000438040020400000000202400000000002002a0210402000622010000000001700144000040000000002204000000c000410105024010000808000000002004002000000261000000822200200800881000000012500400400000000000000040010000800000","miner":"0x000095e79eac4d76aab57cb2c1f091d553b36ca0","mixHash":"0x5b53dc49cbab268ef9950b1d81b5e36a1b2f1b97aee1b7ff6e4db0e06c29a8b0","nonce":"0x0000000000000000","number":"0x84161e","parentHash":"0x72d92c1498e05952988d4e79a695928a6bcbd37239f8a1734051263b4d3504b8","receiptsRoot":"0xaff90ae18dcc35924a4bddb68d403b8b7812c10c3ea2a114f34105c87d75bcdb","sha3Uncles":"0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347","size":"0x2a51","stateRoot":"0xc56738518b2c7854a640ae25996d2211c9ef0dd2e4dd9e59e9d9cacef39622da","timestamp":"0x64110a5c","totalDifficulty":"0xa4a470","transactions":[null,{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x4d9a852e6aecd3a6e87fece2ca109780e45e6f2d","gas":"0x160ab","gasPrice":"0xd4babc57","maxFeePerGas":"0x11407d03e","maxPriorityFeePerGas":"0x9502f900","hash":"0xab5c870f4c367012bd763172afbfbe68fbf35336a66ae41aff3f2c9dbf4ea3f8","input":"0x60566037600b82828239805160001a607314602a57634e487b7160e01b600052600060045260246000fd5b30600052607381538281f3fe73000000000000000000000000000000000000000030146080604052600080fdfea26469706673582212200c479c99d58d7fbee5ee3aef5001431073a3d465bdfa46cf747a7c0b9289607864736f6c634300080d0033","nonce":"0xafd","to":null,"transactionIndex":"0x1","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x48f6acf4ac4371eb96ffca8cdef5b7704ea8c68a631d1c02927036d4ce92567e","s":"0x1f12261ddde63fd3da2ed9ea1bcbb4b0f25af898248c805a9d4b0a6e42caf9c8","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xce297b30e56bf2f6142c4048fbae1cb8a756fefd","gas":"0x557300","gasPrice":"0xd4babc57","maxFeePerGas":"0xfabdd183","maxPriorityFeePerGas":"0x9502f900","hash":"0xa81fd92b2d0f0bbd3cc355f869cca3243c98c5e2641db9ecf3eeabb3b13bff6a","input":"0x7bbaf1ea0000000000000000000000000000000000000000000000000000000000000005000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000000","nonce":"0xad92","to":"0x4c0ce02c1219ce5d2afffba97e484272a4637b49","transactionIndex":"0x2","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xd11b842a5f7b0e020470e764b443fafc4044327bca8dbb37131425359abace2","s":"0x1009867573946fb0a4a35339a6eaaece4d0a168b2346539076e6319e9a466b1","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x47a916d0b694c95bc0c09953c1a6e22c8867be32","gas":"0x5208","gasPrice":"0x991ff257","maxFeePerGas":"0xb2fea055","maxPriorityFeePerGas":"0x59682f00","hash":"0xa92c7b720c08c83f1a0ed7e4c163200e30a3a8c03fcc5a51e685ea20cd0cb577","input":"0x","nonce":"0x2","to":"0xf955dfe99bbfd06a8be208274cd654ecfb66a45e","transactionIndex":"0x3","value":"0x11c37937e08000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xeecd431225215c3ddc2e13cf16fa29f9a2ab1afbaa02988f3ceac27416edf0f5","s":"0x6494062330a9d509f7c778cb45cbcc9932e5f9b4ec94a1ec315f579f8d973b7b","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x672d214fe4db218defae698085a3ccefc773dfa9","gas":"0xf4f6","gasPrice":"0x991ff257","maxFeePerGas":"0xb2fea055","maxPriorityFeePerGas":"0x59682f00","hash":"0x6921b429ad2ec1e97d3457049ad2e893b5a0349beba47ca1c74a9540af75347a","input":"0xa1ddc546000000000000000000000000000000000000000000000000000000000000118f","nonce":"0x8e","to":"0xdef65f8e2f62bde60cd86ad3b4ad7fa6741cf175","transactionIndex":"0x4","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x4732ad21401b509bebb947a8566127fba1e245eb5a262ddc522d6867ab80567e","s":"0x2153013617fefdb06db0a7316d8883056441d33c2abf5ed6291fa0e3cc5c3a2f","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x0b12f7f996579fe7d9302d2574910121c214ee15","gas":"0x56a8","gasPrice":"0x991ff257","maxFeePerGas":"0xb2fea055","maxPriorityFeePerGas":"0x59682f00","hash":"0xf776b2da0b835dde05d0d8b76fd19385d61e7055036cf637f804b36dc94f2384","input":"0x71ec5c05aa669c4922569c1d33f7a81aaa21813800000000000000000000000013a0c5930c028511dc02665e7285134b6d11a5f40000000000000000000000000b12f7f996579fe7d9302d2574910121c214ee150000000000000000000000000000000000000000000000000000000000000000","nonce":"0xe","to":"0x7c125c1d515b8945841b3d5144a060115c58725f","transactionIndex":"0x5","value":"0x2386f26fc10000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xc4505d4c46ef9a0103178e5ef4fbc857114ae5c4686b68b74d07c3ee3a86e575","s":"0x74db34fd675bea7d2ee74f14fd8709cb88c7d22c2267d12f2c671b5ebc180bd5","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xd36aac0c9676e984d72823fb662ce94d3ab5e551","gas":"0xff212","gasPrice":"0x991ff257","maxFeePerGas":"0xd86d063e","maxPriorityFeePerGas":"0x59682f00","hash":"0x9a08d899cd14ebb930ed59fa774afdb88a22615b3a931e930931ea54d26dc0bc","input":"0x49160658babdf216946a22b96c966ceeba750f14807726306ebeed500a2621a7481df010000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000c0000000000000000000000000000000000000000000000000000000000000012000000000000000000000000000000000000000000000000000000000000000084d6f6f6e6265616d000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002a3078434133633746363939643335333137316438434643364236334431433764333841333233373238300000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0b616f73c8d00641109f0000054f967b8a135e44e233da070ea88c5e4a53bacac0000000000000000000000000000000000000000000000000000000000000002000000000000000000000000c6a3a17399d88e5dfd2de4fa41dcccade6a2d2170000000000000000000000008676147503f761e44b85df01811edd52be01b56c000000000000000000000000000000000000000000000000d02ab486cedc00000000000000000000000000000000000000000000000000000de0b6b3a7640000","nonce":"0x7121","to":"0x2d276bd64fe8643a1d76b2e9530c753423e972c1","transactionIndex":"0x6","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xce452361d331baf2ac86947a1b3b454b3e842923e1f39139b33a572845dd5d7c","s":"0x388126881782af5a146ce8409f1e3a2c9a4cadcfe9a2c1d27258af6e4eb5cec1","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xb83a48ee322989a0a4f838cb207abc28ec021b73","gas":"0x326ff","gasPrice":"0x991ff257","maxFeePerGas":"0x5c3362b9c","maxPriorityFeePerGas":"0x59682f00","hash":"0x0fe0d97e25d5eb11a33a3e8278584c3780941fc2675bdf8fc547cee3d1fd3b17","input":"0xa4110dbe190e65a7fe0ad5acd305c6446a02cb39de30f382000fe67927434063bf4c4b2ca86b3ee6d039dc7a0268f9e1c39266c3f12a752a7eb72f0895dedf62291fd292","nonce":"0x12e","to":"0x96e6192eeaf7bb308f79fb5017a9085754b9e12a","transactionIndex":"0x7","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x46819bb540fa459a5a0cbf041a0286507d597fc8958a6af8b9ce193f00005238","s":"0x31495c58bf4b74925f870c59635912681bee947b1cb4b08cc19f22421b1a10ab","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xb83a48ee322989a0a4f838cb207abc28ec021b73","gas":"0x3270b","gasPrice":"0x991ff257","maxFeePerGas":"0x5c3362b9c","maxPriorityFeePerGas":"0x59682f00","hash":"0xef47a60f57f177a683c723c658137efab66d311e1c5abbc4d74f653535144d03","input":"0xa4110dbe18eba3e815ec7fcb03a8eea0487209c3253024d1dc4f36f775a43fdd3e409b74c0a5c88e54f39b88db6f185a41431b204120d3e66c9b08b86f5e8382623327e5","nonce":"0x12f","to":"0x96e6192eeaf7bb308f79fb5017a9085754b9e12a","transactionIndex":"0x8","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x4d7e11fe3914763a2735493a62b71ae0028e75a750a8b06407996cf478e273c8","s":"0x60c18fdf948721f96fdc2efbf694910122e82191c7a40a5caab247c06ab7f3cf","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x7712a1f96b3f37c3dd88a22d4f7a7977b937fe62","gas":"0x1ff06","gasPrice":"0x991ff257","maxFeePerGas":"0xcf662006","maxPriorityFeePerGas":"0x59682f00","hash":"0xe23a5b35faae5335adc5aca38c5d633b00438b798c2053104b8df48406c9b141","input":"0x3ff9751b0000000000000000000000000000000000000000000000000000000000000034000000000000000000000000000000000000000000000000000000000000003500000000000000000000000000000000000000000000000000000000000000a000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000160000000000000000000000000000000000000000000000000000000000000002e516d566e75374a51566f445271536748427a72615970374879373848774a744c4669366e5546436f775447647a70000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002e516d5439716b3343525962464457704446596541763854384831676e6f6e67774b6868354a36384e4c6b4c6972360000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000041c9f31b989aaa745aecc563139f89c8ab3ab492e725d1e0305b7d602fcbf9293c463f0d2e4f5fb0c9efb54eb2cde9af10ebc9c3676f2334007291ffa8efb40adb1c00000000000000000000000000000000000000000000000000000000000000","nonce":"0x16","to":"0xc3b87ea584cb9cb5a4523e2bed16a34bf7746317","transactionIndex":"0x9","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xcc693a9544394653e1f393f02635e2c1f78b5e6c26c4d00a867bcf4adc2bc09e","s":"0x23f4b71b773c19f77cf251b2aeea03f2696bddd847d1f6d75acd2fbea6a543e4","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x12bbafcfa06423d87bed591a64c1a1f34791e90a","gas":"0x1b2e020","gasPrice":"0x8f0d3617","maxFeePerGas":"0x1cb3abd5a","maxPriorityFeePerGas":"0x4f5572c0","hash":"0xd8cea4ba619b317bc05d58534af73beec6c2548b31b24d4dc61c9bbd29cfa17a","input":"0x","nonce":"0x4d","to":"0x12bbafcfa06423d87bed591a64c1a1f34791e90a","transactionIndex":"0xa","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x8dae28608985d6ab47cbe122ee88972e38664cede30978f41944f347bad86e5c","s":"0x17c2898b39b7e3b874dc78e7df3fcff68f4d715385c632aad4bdf6e62505651c","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x6999c36394dd5d3d3295af63a4736ad6bd279448","gas":"0x14d94","gasPrice":"0x7b528d57","maxFeePerGas":"0x7df743e0","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x79a4b9d90b02c768baaad305f266281213cc75062cbe99a13222cc0c4b509498","input":"0x6a7612020000000000000000000000009008d19f58aabd9ed0d60971565aa8510560ab4100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000140000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000022000000000000000000000000000000000000000000000000000000000000000a4ec6cb13f00000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000003826d8d7371becafc0afedc3fe85b699b87f4357d55ec39ce83c510ed7d70ff514dce8236351f4627ccec6a7d9a67bc6fc2ec17ca76411113c00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000410000000000000000000000006999c36394dd5d3d3295af63a4736ad6bd27944800000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000","nonce":"0x13","to":"0xdce8236351f4627ccec6a7d9a67bc6fc2ec17ca7","transactionIndex":"0xb","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x669487011643510f7512ec15b07d74efb853ba4ad9fe9c7e9850ccf24e3d4c53","s":"0x2191f9ee81087e1df833e69d6129ec330ed4c99be2031060834e22c589fcf79b","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x08ebc052e6353b4d8392113f0f2c5decd691ddcd","gas":"0x1b2e020","gasPrice":"0x7b528d57","maxFeePerGas":"0xf6e4d9c4","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x6790a3bbddbeb21fcb736a59b3775755051c3a6344d8390cf8ca27f2e8a814f0","input":"0x6871ee40","nonce":"0x4","to":"0xb21b333c40354393f18de57f2d0a0fc21f270482","transactionIndex":"0xc","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xa7a58ab858e5dd87b9a74d550e5716ac40ddefd1c21d5baa51e542f4f941d73e","s":"0x1fd0cb1563df0368bd332717d7c8210187cd1ac2ff44f61f5242fc02eaa0c2fe","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x08ebc052e6353b4d8392113f0f2c5decd691ddcd","gas":"0x12c36","gasPrice":"0x7b528d57","maxFeePerGas":"0xe596c292","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x87ec7ace5442db252b5751ffddd38dcb04b088d36b6b0e526ff25607a4293c81","input":"0xcb40cbfd","nonce":"0x5","to":"0xb21b333c40354393f18de57f2d0a0fc21f270482","transactionIndex":"0xd","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x8e4bd40195bdfaa868af97dbf22e0b74295d95564a8381bc9bcfe1af3cde2cdb","s":"0x62057dc87c8b2b197d12c648233aab4134b7c2a2f65db89a49728564f3d0864d","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x08ebc052e6353b4d8392113f0f2c5decd691ddcd","gas":"0x12c36","gasPrice":"0x7b528d57","maxFeePerGas":"0xe596c292","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x40cb487ecffda94f97ce7fc0f7163f2f024235df2c8291169edc80dac063e6d0","input":"0xcb40cbfd","nonce":"0x6","to":"0xb21b333c40354393f18de57f2d0a0fc21f270482","transactionIndex":"0xe","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x993c4386ffc2bd63a48dd31cf5f65aa355cba3c063b08778b328d748937098e5","s":"0x203b1faf595628dd78e760bcc1740065625abb6cf00b1b17224e10fa6b424e43","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xafc7682751d3654f34958e3fb660971bf5918367","gas":"0x1b2e020","gasPrice":"0x7b528d57","maxFeePerGas":"0xefb40664","maxPriorityFeePerGas":"0x3b9aca00","hash":"0xb76bb3d88c9b30d927c45ccfcf8d5b0054411ac8501ad588822a7d04690cccf6","input":"0x40c10f19000000000000000000000000afc7682751d3654f34958e3fb660971bf59183670000000000000000000000000000000000000000000000008ac7230489e80000","nonce":"0x20","to":"0x84ced17d95f3ec7230baf4a369f1e624ae60090d","transactionIndex":"0xf","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x78e9d29c606f6a61a1428ed7326df05210d802c3061f3b469847cc461eb48025","s":"0x517afe5a21175f186233ae7a6c090cd33e028a77e5854e98eb2fa4c9284430e7","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x12bbafcfa06423d87bed591a64c1a1f34791e90a","gas":"0xcafe","gasPrice":"0x7b528d57","maxFeePerGas":"0x16ba45bce","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x798ebe823209869347c08bd81e04fbf60e9bdfe44b1cc923215182d0cf3d4edb","input":"0x40c10f1900000000000000000000000012bbafcfa06423d87bed591a64c1a1f34791e90a0000000000000000000000000000000000000000000000000000000000000032","nonce":"0x4e","to":"0xd25d682189afa7ed0c2811195b3f3d07616927bc","transactionIndex":"0x10","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xbe2aa95f4c32188c9ecbae97286ab983f7cc5a7017d46c404f8eb80b55e2dc13","s":"0x55d8968f509f51633f49260178941fd5a3db999e1995206348d7a3f05152b3d5","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x12bbafcfa06423d87bed591a64c1a1f34791e90a","gas":"0xcafe","gasPrice":"0x7b528d57","maxFeePerGas":"0xc6132c0c","maxPriorityFeePerGas":"0x3b9aca00","hash":"0xbe68a7e02725f799a65ebb069ccc83a014ac7c40e4119bf7c220a2f6ddfee295","input":"0x40c10f1900000000000000000000000012bbafcfa06423d87bed591a64c1a1f34791e90a0000000000000000000000000000000000000000000000000000000000000064","nonce":"0x4f","to":"0xd25d682189afa7ed0c2811195b3f3d07616927bc","transactionIndex":"0x11","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x1750ed45d0d2d048a61dcc3ff3e7ad0cbd395b77698c4f2eeb6baaea4c966d96","s":"0xe646e3a87b6dc50439468bcfd24cbf12a6f95b2762f1527c97a7d1b7f03530e","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xd0c0338baac9ce09c1d1caab88b4360507061e37","gas":"0x1b2e020","gasPrice":"0x7b528d57","maxFeePerGas":"0x1918167aa","maxPriorityFeePerGas":"0x3b9aca00","hash":"0xc90c3a72efe81331727fcce4b5bd4906066da314ca9a0b44023a6b09ea7e8114","input":"0x4e71d92d","nonce":"0xe7","to":"0x0137d796936e199b917b93118eb4e002508a48bd","transactionIndex":"0x12","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x22222ce8fe753082c8e5dc7478fa7b87db9c8d0fb070ebc88ab015db13fd6bb","s":"0x6dceadecf6f6a3ddc433a547dba6d5fcdfb7d006ce09eeae1c06c1828ef9fff9","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x8bd834cc1dd17d1a2f7eb6140c3dd5ab51d0f338","gas":"0x1b2e020","gasPrice":"0x7b528d57","maxFeePerGas":"0x1a4019792","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x619a6cbd43cde074d314c19623bd66d9fb1e13c158d7138775236f798dc1245e","input":"0x1da1db5e00000000000000000000000000000000000000000000000000001b5ec4ff740d","nonce":"0x10","to":"0xbad0009f7a8e796e3f975dc1d6ab3e3c237b857c","transactionIndex":"0x13","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x733c496e8c84f78d113bc8b5ad6d04a133bb10bbcecf0db93d97eeedfa3d984a","s":"0x6627c16aa7dea27db44c0f0641c30ffd544b9b9b1c299dc60611e1e01c714ee8","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x8bd834cc1dd17d1a2f7eb6140c3dd5ab51d0f338","gas":"0x11df0","gasPrice":"0x7b528d57","maxFeePerGas":"0x1d3fbccb8","maxPriorityFeePerGas":"0x3b9aca00","hash":"0xca5a56cd77b9e5b0e79020cc6346edf205bc11e901984d805125f28c2e6686e6","input":"0xd7c01032000000000000000000000000356f24c0f3187a6dcb949e4a60aa0a74a8a0327e0000000000000000000000000f8bacfae87aee49a2eec86df0c6b958ec3fd4fd0000000000000000000000000f8bacfae87aee49a2eec86df0c6b958ec3fd4fd","nonce":"0x11","to":"0xbad0009f7a8e796e3f975dc1d6ab3e3c237b857c","transactionIndex":"0x14","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x4aa872c1a7da70126917604193717575b91407f82449bca956d4089b90cd902","s":"0x4b5f788c68024f8958f66e8c768a8e0f65ef297c4ffd420a715258b0a55cb0a0","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x9bedd66b05712a1add7d1fec899b8641b3ecc863","gas":"0x1b2e020","gasPrice":"0x7b528d57","maxFeePerGas":"0x1e706c8d2","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x999c9ddeed67c6ef6fbf02a6e977a6c1b68e18d24814e51643c7157b87a43e0a","input":"0xa8b78ed0","nonce":"0x3","to":"0xf6c2afb18b85175e5ffb28f20f007c047ce28592","transactionIndex":"0x15","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xf1ca074104ee0b6a67223afd797654b8f21060453f7662dd7be79de938c396da","s":"0x4c9a4e56f0ad21e2dd8d1116c7a3e41ea2c6126853772f7897bd959e81e2e28a","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x9bedd66b05712a1add7d1fec899b8641b3ecc863","gas":"0x2dc6c0","gasPrice":"0xd4babc57","maxFeePerGas":"0x21c13e710","maxPriorityFeePerGas":"0x9502f900","hash":"0x47c8f5d0b3778e4c34eba7fcc356fa04a5afd954ccf484728e72c002764dd3c4","input":"0xf688bcfb0000000000000000000000000000000000000000000000000000000005f5e100","nonce":"0x4","to":"0xf6c2afb18b85175e5ffb28f20f007c047ce28592","transactionIndex":"0x16","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x970982425d18b9949141bbabb5c5230fa168626ce210a97f3856d64700fc0eeb","s":"0x6fa6d0aea6ae48783d80c1e51cda47e11c28b90a5497579b93d7f242d786f67e","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x4b596cebd02c35aa99878eb9ecb24d6f5ca5f865","gas":"0x5208","gasPrice":"0x68c88f79","maxFeePerGas":"0x68c88f79","maxPriorityFeePerGas":"0x68c88f79","hash":"0x396797ae0ebcdb72ff1f96fd08b6128f78acc7417353f142f1a5facd425a33e6","input":"0x","nonce":"0x1","to":"0x375980b8e1a417620ba9b18e5a9e0b17dccbac9d","transactionIndex":"0x17","value":"0x1c9a406c58878","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xcb2a7b106097b2f2a61d3a048054a5175c386b1dcdd5b6fcd7849dcac7c32a66","s":"0x10aef76e98276c47470f04a599b81c260ace9d2f6adc95755c6d22d859e805a2","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x6f4aa3bc9732372daa288beb9b2516374ace5786","gas":"0x1b2e020","gasPrice":"0x61010bda","maxFeePerGas":"0x61010bda","maxPriorityFeePerGas":"0x61010bda","hash":"0x454aa43d6546a6f62246826c16b7a49c6c704238c18802ef0d659922f23a573c","input":"0xe99a3f8000000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000480000000000000000000000000000000000000000000000000000000000000050000000000000000000000000000000000000000000000000000000000000008a000000000000000000000000058ce7eb44ae575fb3b3974861c1138dad3c5aee40000000000000000000000000000000000000000000000000000000000000120000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001e06defd69964a6ce467b87c64627a7a2be4be139b504757c625eb6114ec166557d000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000641a269023d235ef0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002a000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000002b05699353b600008ae85d840000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000020000000000000000000000000b4fbf271143f4fbf7b91a5ded31805e42b2208d600000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000001f63c28250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000020000000000000000000000000def65f8e2f62bde60cd86ad3b4ad7fa6741cf17500000000000000000000000000000000000000000000000000000000000001400000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000020000000000000000000000006e512435020ac228a15543236b1f46656f98136300000000000000000000000000000000000000000000000000000000000000fa000000000000000000000000d6ffd79b52a587a0a9941a61f4e6cb0d386d5458000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000413e24433da3efc4c3cc305339a7b77a1b31abb4e4d4967e97e42aed1dd0bf98936f43035f40bc80f6f6e3a9cfb43524a1171ee7f21e9ac2fa586d33a31f10619d1c000000000000000000000000000000000000000000000000000000000000000000000000000000000000006f4aa3bc9732372daa288beb9b2516374ace5786000000000000000000000000000000000000000000000000000000000000012000000000000000000000000058ce7eb44ae575fb3b3974861c1138dad3c5aee400000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000641a269023d235ef0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002c00000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000173ad21460000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000040000000000000000000000000def65f8e2f62bde60cd86ad3b4ad7fa6741cf1750000000000000000000000000000000000000000000000000000000000000ba200000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000002b05699353b600008ae85d840000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000020000000000000000000000000b4fbf271143f4fbf7b91a5ded31805e42b2208d600000000000000000000000000000000000000000000000000000000000000c00000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000def65f8e2f62bde60cd86ad3b4ad7fa6741cf175ffffffff09616c6c64617461","nonce":"0x82","to":"0x02afbd43cad367fcb71305a2dfb9a3928218f0c1","transactionIndex":"0x18","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xc7ac308b1ae238cb2aa4b030ca79baffb7b498e1b10df0c3354b3cc19cfabac9","s":"0x2358b1093b9aab5fae0cf751766b0bb2e3d8cd2b18ca627e1e12520990a8ed6d","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x6ece61d29b90642941c41240da924690da145696","gas":"0x4399c","gasPrice":"0x506794e0","hash":"0x317ecb5bd19caa42a69f836d41556ebb0e0e00e1c6cd2dee230e6e6192612527","input":"0x46f83b5000000000000000000000000000000000000000000000000000000000000000654666803decc59e7d0a5d3efa3c3653c05645ef4342738445e20a3b43e0b4aa8b000000000000000000000000000000000000000000000000000000000000000f4666803decc59e7d0a5d3efa3c3653c05645ef4342738445e20a3b43e0b4aa8b","nonce":"0x2cc4","to":"0xa6bf2be6c60175601bf88217c75dd4b14abb5fbb","transactionIndex":"0x19","value":"0x0","type":"0x0","chainId":"0x5","v":"0x2d","r":"0x37aeab0db6d550e6cba2c04c9cb10a2af0fec0b11f6e04b85e1ea0b8b9defeae","s":"0x4f32f4ef74872e1385c25e69bf21ee049545a4d423e939eaff29677450efe9eb"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xc4a5c059840a146b81c77bf79f1398f2b3d28ca7","gas":"0x432ec","gasPrice":"0x45db0a51","hash":"0xc879285db5ef0a6bce98021584d16f134c1dc0aed8cc988802c4f72ba6877ff6","input":"0x9f8420b300000000000000000000000000000000000000000000000000470de4df8200000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x1a7","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x1a","value":"0x470efc4514e000","type":"0x0","chainId":"0x5","v":"0x2d","r":"0x237e3a541c5ab490843cdc20d0fcb7416bff8da471f6a11ae1b32d2bab119141","s":"0x3c8417d7a60bd5b0bcae4975dbb4aaee54a4b4d588226481be400843bfe2b64e"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x6f4aa3bc9732372daa288beb9b2516374ace5786","gas":"0xffff","gasPrice":"0x44e9acbc","maxFeePerGas":"0x44e9acbc","maxPriorityFeePerGas":"0x44e9acbc","hash":"0xecaa2d6f597608307e5084854854ba6dc1e69395e2abea14f2c6a2fa1d6faf9a","input":"0xe2864fe300000000000000000000000000000000000000000000000000000000000000200000000000000000000000006f4aa3bc9732372daa288beb9b2516374ace57860000000000000000000000000000000000000000000000000000000000000120000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002004a8312e37fcecd450e6684009a2b54bc64f66afbe5217c7b2f63b03cd9980a9e00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000064893e8223d235ef0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002a00000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000173ad21460000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000040000000000000000000000000def65f8e2f62bde60cd86ad3b4ad7fa6741cf175000000000000000000000000000000000000000000000000000000000000085000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000de0b6b3a7640000aaaebeba000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001400000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000020000000000000000000000006e512435020ac228a15543236b1f46656f98136300000000000000000000000000000000000000000000000000000000000000fa000000000000000000000000d6ffd79b52a587a0a9941a61f4e6cb0d386d54580000000000000000000000000000000000000000000000000000000000000000","nonce":"0x83","to":"0x02afbd43cad367fcb71305a2dfb9a3928218f0c1","transactionIndex":"0x1b","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xa18772e4b9e1493ebfd5ae6219cc9ca060b71e83788fb614ab02b03fb36eaf1b","s":"0x482c7e50fde29bb4130fd6e723176e0e9913430ebb9260667d7fb55f5408d9c5","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xdb33365a8730de2f7574ff1189fb9d337bf4c36d","gas":"0x61a80","gasPrice":"0x433653c8","maxFeePerGas":"0x828367af","maxPriorityFeePerGas":"0x37e9071","hash":"0x4dd69b69a568ff30ae439e2ded72fbd7f2e7aaa345836703663f155c749c5eed","input":"0x7f34c0ddc6e984f46ab7c13b7a53643096e79c39103dc74550204d5bd1b5206ef5a2f49689071bb6a332212df26aa57cd4d1e3c0894187a9fc5e5d686cbedba5b187470f000000000000000000000000000000000000000000000000000000000000000e000000000000000000000000e8c44c30e8e52c38ac7bd232e7b7f0c7463a535100000000000000000000000000000000000000000000000000000000000000a0000000000000000000000000000000000000000000000000000000000000002e516d5044645856613738437a6b7856325a364e52777a67685a785872736e75397261616a695a7555423569465a62000000000000000000000000000000000000","nonce":"0x2b57","to":"0xb8ad54644e2371cbb7940b9fa0936f399ba7495f","transactionIndex":"0x1c","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xa1fb0e5662b54ceb3dc1623ebfb200668433cb27252d553669bcd136387394f3","s":"0x27c2f8e19f69a52a0960f05d8b21f11c313dd3e86a7139b5783a18353c407415","yParity":"0x0"}],"transactionsRoot":"0xaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa","uncles":[],"withdrawals":[{"index":"0x1170","validatorIndex":"0x38c2c","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x66edfd65"},{"index":"0x1171","validatorIndex":"0x38c2d","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6cd228e4"},{"index":"0x1172","validatorIndex":"0x38c2e","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x77f3431b"},{"index":"0x1173","validatorIndex":"0x38c2f","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6b61f268"},{"index":"0x1174","validatorIndex":"0x38c30","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6e10bb21"},{"index":"0x1175","validatorIndex":"0x38c31","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6eb115a5"},{"index":"0x1176","validatorIndex":"0x38c32","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x7caead1d"},{"index":"0x1177","validatorIndex":"0x38c33","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x772c0ddf"},{"index":"0x1178","validatorIndex":"0x38c34","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x75930a95"},{"index":"0x1179","validatorIndex":"0x38c35","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x76a4db09"},{"index":"0x117a","validatorIndex":"0x38c36","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x7e692b27"},{"index":"0x117b","validatorIndex":"0x38c37","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x72038ae6"},{"index":"0x117c","validatorIndex":"0x38c38","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6ccce352"},{"index":"0x117d","validatorIndex":"0x38c39","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x79ef6898"},{"index":"0x117e","validatorIndex":"0x38c3a","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6d58977d"},{"index":"0x117f","validatorIndex":"0x38c3b","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x76f7d208"}],"withdrawalsRoot":"0xbe712c930a0665264b025ced87cc7839eef95a3cbc26dadc93e9e185a350ad28"} diff --git a/op-service/sources/testdata/data/blocks/post-shanghai-bad-transactions-nil_metadata.json b/op-service/sources/testdata/data/blocks/post-shanghai-bad-transactions-nil_metadata.json new file mode 100644 index 0000000000000..9fc85fff5071c --- /dev/null +++ b/op-service/sources/testdata/data/blocks/post-shanghai-bad-transactions-nil_metadata.json @@ -0,0 +1 @@ +{"name":"post-shanghai-bad-transactions-nil","fail":true, "reason": "block tx 0 is nil"} diff --git a/op-service/sources/testdata/data/blocks/post-shanghai-bad-transactions_data.json b/op-service/sources/testdata/data/blocks/post-shanghai-bad-transactions_data.json new file mode 100644 index 0000000000000..1c7594777a15c --- /dev/null +++ b/op-service/sources/testdata/data/blocks/post-shanghai-bad-transactions_data.json @@ -0,0 +1 @@ +{"baseFeePerGas":"0x3fb7c357","difficulty":"0x0","extraData":"0x","gasLimit":"0x1c9c380","gasUsed":"0x18f759","hash":"0x0afe3cbfbf24c0b097b50864b8aaf9f819cf56d4b2b6a67b1edff20bc2a66ad2","logsBloom":"0x020010404000001a0000021000000080001100410000100001000010040200980220400000008806200200000100000000000000000000008000000400042000000050000040000112080808800002044000040004042008800480002000000000000002020020000042002400000820000080040000000010200010020010100101212050000008000000008000001010200c80000112010000438040020400000000202400000000002002a0210402000622010000000001700144000040000000002204000000c000410105024010000808000000002004002000000261000000822200200800881000000012500400400000000000000040010000800000","miner":"0x000095e79eac4d76aab57cb2c1f091d553b36ca0","mixHash":"0x5b53dc49cbab268ef9950b1d81b5e36a1b2f1b97aee1b7ff6e4db0e06c29a8b0","nonce":"0x0000000000000000","number":"0x84161e","parentHash":"0x72d92c1498e05952988d4e79a695928a6bcbd37239f8a1734051263b4d3504b8","receiptsRoot":"0xaff90ae18dcc35924a4bddb68d403b8b7812c10c3ea2a114f34105c87d75bcdb","sha3Uncles":"0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347","size":"0x2a51","stateRoot":"0xc56738518b2c7854a640ae25996d2211c9ef0dd2e4dd9e59e9d9cacef39622da","timestamp":"0x64110a5c","totalDifficulty":"0xa4a470","transactions":[{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x1b7aa44088a0ea95bdc65fef6e5071e946bf7d8f","gas":"0x5208","gasPrice":"0x4159f01735","hash":"0x1e8f148a9aea7d8d16ea6e9446723b8f262e8bcd89c7c961d52046ebd43b4598","input":"0x","nonce":"0x279ad","to":"0xa21765a03dd41e2783696d314f235f4d520f6cac","transactionIndex":"0x0","value":"0x3782dace9d90000","type":"0x0","chainId":"0x5","v":"0x2e","r":"0xf9eca8b74ccaec5f4a83e981baeb8602f38d0271179c592b4a18f3866316a367","s":"0x350a9d26718d1fa9dc4f268f9c0e18fb96dbc037816ca8fc20f33f1a76f9f501"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x4d9a852e6aecd3a6e87fece2ca109780e45e6f2d","gas":"0x160ab","gasPrice":"0xd4babc57","maxFeePerGas":"0x11407d03e","maxPriorityFeePerGas":"0x9502f900","hash":"0xab5c870f4c367012bd763172afbfbe68fbf35336a66ae41aff3f2c9dbf4ea3f8","input":"0x60566037600b82828239805160001a607314602a57634e487b7160e01b600052600060045260246000fd5b30600052607381538281f3fe73000000000000000000000000000000000000000030146080604052600080fdfea26469706673582212200c479c99d58d7fbee5ee3aef5001431073a3d465bdfa46cf747a7c0b9289607864736f6c634300080d0033","nonce":"0xafd","to":null,"transactionIndex":"0x1","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x48f6acf4ac4371eb96ffca8cdef5b7704ea8c68a631d1c02927036d4ce92567e","s":"0x1f12261ddde63fd3da2ed9ea1bcbb4b0f25af898248c805a9d4b0a6e42caf9c8","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xce297b30e56bf2f6142c4048fbae1cb8a756fefd","gas":"0x557300","gasPrice":"0xd4babc57","maxFeePerGas":"0xfabdd183","maxPriorityFeePerGas":"0x9502f900","hash":"0xa81fd92b2d0f0bbd3cc355f869cca3243c98c5e2641db9ecf3eeabb3b13bff6a","input":"0x7bbaf1ea0000000000000000000000000000000000000000000000000000000000000005000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000000","nonce":"0xad92","to":"0x4c0ce02c1219ce5d2afffba97e484272a4637b49","transactionIndex":"0x2","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xd11b842a5f7b0e020470e764b443fafc4044327bca8dbb37131425359abace2","s":"0x1009867573946fb0a4a35339a6eaaece4d0a168b2346539076e6319e9a466b1","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x47a916d0b694c95bc0c09953c1a6e22c8867be32","gas":"0x5208","gasPrice":"0x991ff257","maxFeePerGas":"0xb2fea055","maxPriorityFeePerGas":"0x59682f00","hash":"0xa92c7b720c08c83f1a0ed7e4c163200e30a3a8c03fcc5a51e685ea20cd0cb577","input":"0x","nonce":"0x2","to":"0xf955dfe99bbfd06a8be208274cd654ecfb66a45e","transactionIndex":"0x3","value":"0x11c37937e08000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xeecd431225215c3ddc2e13cf16fa29f9a2ab1afbaa02988f3ceac27416edf0f5","s":"0x6494062330a9d509f7c778cb45cbcc9932e5f9b4ec94a1ec315f579f8d973b7b","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x672d214fe4db218defae698085a3ccefc773dfa9","gas":"0xf4f6","gasPrice":"0x991ff257","maxFeePerGas":"0xb2fea055","maxPriorityFeePerGas":"0x59682f00","hash":"0x6921b429ad2ec1e97d3457049ad2e893b5a0349beba47ca1c74a9540af75347a","input":"0xa1ddc546000000000000000000000000000000000000000000000000000000000000118f","nonce":"0x8e","to":"0xdef65f8e2f62bde60cd86ad3b4ad7fa6741cf175","transactionIndex":"0x4","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x4732ad21401b509bebb947a8566127fba1e245eb5a262ddc522d6867ab80567e","s":"0x2153013617fefdb06db0a7316d8883056441d33c2abf5ed6291fa0e3cc5c3a2f","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x0b12f7f996579fe7d9302d2574910121c214ee15","gas":"0x56a8","gasPrice":"0x991ff257","maxFeePerGas":"0xb2fea055","maxPriorityFeePerGas":"0x59682f00","hash":"0xf776b2da0b835dde05d0d8b76fd19385d61e7055036cf637f804b36dc94f2384","input":"0x71ec5c05aa669c4922569c1d33f7a81aaa21813800000000000000000000000013a0c5930c028511dc02665e7285134b6d11a5f40000000000000000000000000b12f7f996579fe7d9302d2574910121c214ee150000000000000000000000000000000000000000000000000000000000000000","nonce":"0xe","to":"0x7c125c1d515b8945841b3d5144a060115c58725f","transactionIndex":"0x5","value":"0x2386f26fc10000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xc4505d4c46ef9a0103178e5ef4fbc857114ae5c4686b68b74d07c3ee3a86e575","s":"0x74db34fd675bea7d2ee74f14fd8709cb88c7d22c2267d12f2c671b5ebc180bd5","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xd36aac0c9676e984d72823fb662ce94d3ab5e551","gas":"0xff212","gasPrice":"0x991ff257","maxFeePerGas":"0xd86d063e","maxPriorityFeePerGas":"0x59682f00","hash":"0x9a08d899cd14ebb930ed59fa774afdb88a22615b3a931e930931ea54d26dc0bc","input":"0x49160658babdf216946a22b96c966ceeba750f14807726306ebeed500a2621a7481df010000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000c0000000000000000000000000000000000000000000000000000000000000012000000000000000000000000000000000000000000000000000000000000000084d6f6f6e6265616d000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002a3078434133633746363939643335333137316438434643364236334431433764333841333233373238300000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0b616f73c8d00641109f0000054f967b8a135e44e233da070ea88c5e4a53bacac0000000000000000000000000000000000000000000000000000000000000002000000000000000000000000c6a3a17399d88e5dfd2de4fa41dcccade6a2d2170000000000000000000000008676147503f761e44b85df01811edd52be01b56c000000000000000000000000000000000000000000000000d02ab486cedc00000000000000000000000000000000000000000000000000000de0b6b3a7640000","nonce":"0x7121","to":"0x2d276bd64fe8643a1d76b2e9530c753423e972c1","transactionIndex":"0x6","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xce452361d331baf2ac86947a1b3b454b3e842923e1f39139b33a572845dd5d7c","s":"0x388126881782af5a146ce8409f1e3a2c9a4cadcfe9a2c1d27258af6e4eb5cec1","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xb83a48ee322989a0a4f838cb207abc28ec021b73","gas":"0x326ff","gasPrice":"0x991ff257","maxFeePerGas":"0x5c3362b9c","maxPriorityFeePerGas":"0x59682f00","hash":"0x0fe0d97e25d5eb11a33a3e8278584c3780941fc2675bdf8fc547cee3d1fd3b17","input":"0xa4110dbe190e65a7fe0ad5acd305c6446a02cb39de30f382000fe67927434063bf4c4b2ca86b3ee6d039dc7a0268f9e1c39266c3f12a752a7eb72f0895dedf62291fd292","nonce":"0x12e","to":"0x96e6192eeaf7bb308f79fb5017a9085754b9e12a","transactionIndex":"0x7","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x46819bb540fa459a5a0cbf041a0286507d597fc8958a6af8b9ce193f00005238","s":"0x31495c58bf4b74925f870c59635912681bee947b1cb4b08cc19f22421b1a10ab","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xb83a48ee322989a0a4f838cb207abc28ec021b73","gas":"0x3270b","gasPrice":"0x991ff257","maxFeePerGas":"0x5c3362b9c","maxPriorityFeePerGas":"0x59682f00","hash":"0xef47a60f57f177a683c723c658137efab66d311e1c5abbc4d74f653535144d03","input":"0xa4110dbe18eba3e815ec7fcb03a8eea0487209c3253024d1dc4f36f775a43fdd3e409b74c0a5c88e54f39b88db6f185a41431b204120d3e66c9b08b86f5e8382623327e5","nonce":"0x12f","to":"0x96e6192eeaf7bb308f79fb5017a9085754b9e12a","transactionIndex":"0x8","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x4d7e11fe3914763a2735493a62b71ae0028e75a750a8b06407996cf478e273c8","s":"0x60c18fdf948721f96fdc2efbf694910122e82191c7a40a5caab247c06ab7f3cf","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x7712a1f96b3f37c3dd88a22d4f7a7977b937fe62","gas":"0x1ff06","gasPrice":"0x991ff257","maxFeePerGas":"0xcf662006","maxPriorityFeePerGas":"0x59682f00","hash":"0xe23a5b35faae5335adc5aca38c5d633b00438b798c2053104b8df48406c9b141","input":"0x3ff9751b0000000000000000000000000000000000000000000000000000000000000034000000000000000000000000000000000000000000000000000000000000003500000000000000000000000000000000000000000000000000000000000000a000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000160000000000000000000000000000000000000000000000000000000000000002e516d566e75374a51566f445271536748427a72615970374879373848774a744c4669366e5546436f775447647a70000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002e516d5439716b3343525962464457704446596541763854384831676e6f6e67774b6868354a36384e4c6b4c6972360000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000041c9f31b989aaa745aecc563139f89c8ab3ab492e725d1e0305b7d602fcbf9293c463f0d2e4f5fb0c9efb54eb2cde9af10ebc9c3676f2334007291ffa8efb40adb1c00000000000000000000000000000000000000000000000000000000000000","nonce":"0x16","to":"0xc3b87ea584cb9cb5a4523e2bed16a34bf7746317","transactionIndex":"0x9","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xcc693a9544394653e1f393f02635e2c1f78b5e6c26c4d00a867bcf4adc2bc09e","s":"0x23f4b71b773c19f77cf251b2aeea03f2696bddd847d1f6d75acd2fbea6a543e4","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x12bbafcfa06423d87bed591a64c1a1f34791e90a","gas":"0x1b2e020","gasPrice":"0x8f0d3617","maxFeePerGas":"0x1cb3abd5a","maxPriorityFeePerGas":"0x4f5572c0","hash":"0xd8cea4ba619b317bc05d58534af73beec6c2548b31b24d4dc61c9bbd29cfa17a","input":"0x","nonce":"0x4d","to":"0x12bbafcfa06423d87bed591a64c1a1f34791e90a","transactionIndex":"0xa","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x8dae28608985d6ab47cbe122ee88972e38664cede30978f41944f347bad86e5c","s":"0x17c2898b39b7e3b874dc78e7df3fcff68f4d715385c632aad4bdf6e62505651c","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x6999c36394dd5d3d3295af63a4736ad6bd279448","gas":"0x14d94","gasPrice":"0x7b528d57","maxFeePerGas":"0x7df743e0","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x79a4b9d90b02c768baaad305f266281213cc75062cbe99a13222cc0c4b509498","input":"0x6a7612020000000000000000000000009008d19f58aabd9ed0d60971565aa8510560ab4100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000140000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000022000000000000000000000000000000000000000000000000000000000000000a4ec6cb13f00000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000003826d8d7371becafc0afedc3fe85b699b87f4357d55ec39ce83c510ed7d70ff514dce8236351f4627ccec6a7d9a67bc6fc2ec17ca76411113c00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000410000000000000000000000006999c36394dd5d3d3295af63a4736ad6bd27944800000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000","nonce":"0x13","to":"0xdce8236351f4627ccec6a7d9a67bc6fc2ec17ca7","transactionIndex":"0xb","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x669487011643510f7512ec15b07d74efb853ba4ad9fe9c7e9850ccf24e3d4c53","s":"0x2191f9ee81087e1df833e69d6129ec330ed4c99be2031060834e22c589fcf79b","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x08ebc052e6353b4d8392113f0f2c5decd691ddcd","gas":"0x1b2e020","gasPrice":"0x7b528d57","maxFeePerGas":"0xf6e4d9c4","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x6790a3bbddbeb21fcb736a59b3775755051c3a6344d8390cf8ca27f2e8a814f0","input":"0x6871ee40","nonce":"0x4","to":"0xb21b333c40354393f18de57f2d0a0fc21f270482","transactionIndex":"0xc","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xa7a58ab858e5dd87b9a74d550e5716ac40ddefd1c21d5baa51e542f4f941d73e","s":"0x1fd0cb1563df0368bd332717d7c8210187cd1ac2ff44f61f5242fc02eaa0c2fe","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x08ebc052e6353b4d8392113f0f2c5decd691ddcd","gas":"0x12c36","gasPrice":"0x7b528d57","maxFeePerGas":"0xe596c292","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x87ec7ace5442db252b5751ffddd38dcb04b088d36b6b0e526ff25607a4293c81","input":"0xcb40cbfd","nonce":"0x5","to":"0xb21b333c40354393f18de57f2d0a0fc21f270482","transactionIndex":"0xd","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x8e4bd40195bdfaa868af97dbf22e0b74295d95564a8381bc9bcfe1af3cde2cdb","s":"0x62057dc87c8b2b197d12c648233aab4134b7c2a2f65db89a49728564f3d0864d","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x08ebc052e6353b4d8392113f0f2c5decd691ddcd","gas":"0x12c36","gasPrice":"0x7b528d57","maxFeePerGas":"0xe596c292","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x40cb487ecffda94f97ce7fc0f7163f2f024235df2c8291169edc80dac063e6d0","input":"0xcb40cbfd","nonce":"0x6","to":"0xb21b333c40354393f18de57f2d0a0fc21f270482","transactionIndex":"0xe","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x993c4386ffc2bd63a48dd31cf5f65aa355cba3c063b08778b328d748937098e5","s":"0x203b1faf595628dd78e760bcc1740065625abb6cf00b1b17224e10fa6b424e43","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xafc7682751d3654f34958e3fb660971bf5918367","gas":"0x1b2e020","gasPrice":"0x7b528d57","maxFeePerGas":"0xefb40664","maxPriorityFeePerGas":"0x3b9aca00","hash":"0xb76bb3d88c9b30d927c45ccfcf8d5b0054411ac8501ad588822a7d04690cccf6","input":"0x40c10f19000000000000000000000000afc7682751d3654f34958e3fb660971bf59183670000000000000000000000000000000000000000000000008ac7230489e80000","nonce":"0x20","to":"0x84ced17d95f3ec7230baf4a369f1e624ae60090d","transactionIndex":"0xf","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x78e9d29c606f6a61a1428ed7326df05210d802c3061f3b469847cc461eb48025","s":"0x517afe5a21175f186233ae7a6c090cd33e028a77e5854e98eb2fa4c9284430e7","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x12bbafcfa06423d87bed591a64c1a1f34791e90a","gas":"0xcafe","gasPrice":"0x7b528d57","maxFeePerGas":"0x16ba45bce","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x798ebe823209869347c08bd81e04fbf60e9bdfe44b1cc923215182d0cf3d4edb","input":"0x40c10f1900000000000000000000000012bbafcfa06423d87bed591a64c1a1f34791e90a0000000000000000000000000000000000000000000000000000000000000032","nonce":"0x4e","to":"0xd25d682189afa7ed0c2811195b3f3d07616927bc","transactionIndex":"0x10","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xbe2aa95f4c32188c9ecbae97286ab983f7cc5a7017d46c404f8eb80b55e2dc13","s":"0x55d8968f509f51633f49260178941fd5a3db999e1995206348d7a3f05152b3d5","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x12bbafcfa06423d87bed591a64c1a1f34791e90a","gas":"0xcafe","gasPrice":"0x7b528d57","maxFeePerGas":"0xc6132c0c","maxPriorityFeePerGas":"0x3b9aca00","hash":"0xbe68a7e02725f799a65ebb069ccc83a014ac7c40e4119bf7c220a2f6ddfee295","input":"0x40c10f1900000000000000000000000012bbafcfa06423d87bed591a64c1a1f34791e90a0000000000000000000000000000000000000000000000000000000000000064","nonce":"0x4f","to":"0xd25d682189afa7ed0c2811195b3f3d07616927bc","transactionIndex":"0x11","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x1750ed45d0d2d048a61dcc3ff3e7ad0cbd395b77698c4f2eeb6baaea4c966d96","s":"0xe646e3a87b6dc50439468bcfd24cbf12a6f95b2762f1527c97a7d1b7f03530e","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xd0c0338baac9ce09c1d1caab88b4360507061e37","gas":"0x1b2e020","gasPrice":"0x7b528d57","maxFeePerGas":"0x1918167aa","maxPriorityFeePerGas":"0x3b9aca00","hash":"0xc90c3a72efe81331727fcce4b5bd4906066da314ca9a0b44023a6b09ea7e8114","input":"0x4e71d92d","nonce":"0xe7","to":"0x0137d796936e199b917b93118eb4e002508a48bd","transactionIndex":"0x12","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x22222ce8fe753082c8e5dc7478fa7b87db9c8d0fb070ebc88ab015db13fd6bb","s":"0x6dceadecf6f6a3ddc433a547dba6d5fcdfb7d006ce09eeae1c06c1828ef9fff9","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x8bd834cc1dd17d1a2f7eb6140c3dd5ab51d0f338","gas":"0x1b2e020","gasPrice":"0x7b528d57","maxFeePerGas":"0x1a4019792","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x619a6cbd43cde074d314c19623bd66d9fb1e13c158d7138775236f798dc1245e","input":"0x1da1db5e00000000000000000000000000000000000000000000000000001b5ec4ff740d","nonce":"0x10","to":"0xbad0009f7a8e796e3f975dc1d6ab3e3c237b857c","transactionIndex":"0x13","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x733c496e8c84f78d113bc8b5ad6d04a133bb10bbcecf0db93d97eeedfa3d984a","s":"0x6627c16aa7dea27db44c0f0641c30ffd544b9b9b1c299dc60611e1e01c714ee8","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x8bd834cc1dd17d1a2f7eb6140c3dd5ab51d0f338","gas":"0x11df0","gasPrice":"0x7b528d57","maxFeePerGas":"0x1d3fbccb8","maxPriorityFeePerGas":"0x3b9aca00","hash":"0xca5a56cd77b9e5b0e79020cc6346edf205bc11e901984d805125f28c2e6686e6","input":"0xd7c01032000000000000000000000000356f24c0f3187a6dcb949e4a60aa0a74a8a0327e0000000000000000000000000f8bacfae87aee49a2eec86df0c6b958ec3fd4fd0000000000000000000000000f8bacfae87aee49a2eec86df0c6b958ec3fd4fd","nonce":"0x11","to":"0xbad0009f7a8e796e3f975dc1d6ab3e3c237b857c","transactionIndex":"0x14","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x4aa872c1a7da70126917604193717575b91407f82449bca956d4089b90cd902","s":"0x4b5f788c68024f8958f66e8c768a8e0f65ef297c4ffd420a715258b0a55cb0a0","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x9bedd66b05712a1add7d1fec899b8641b3ecc863","gas":"0x1b2e020","gasPrice":"0x7b528d57","maxFeePerGas":"0x1e706c8d2","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x999c9ddeed67c6ef6fbf02a6e977a6c1b68e18d24814e51643c7157b87a43e0a","input":"0xa8b78ed0","nonce":"0x3","to":"0xf6c2afb18b85175e5ffb28f20f007c047ce28592","transactionIndex":"0x15","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xf1ca074104ee0b6a67223afd797654b8f21060453f7662dd7be79de938c396da","s":"0x4c9a4e56f0ad21e2dd8d1116c7a3e41ea2c6126853772f7897bd959e81e2e28a","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x9bedd66b05712a1add7d1fec899b8641b3ecc863","gas":"0x2dc6c0","gasPrice":"0xd4babc57","maxFeePerGas":"0x21c13e710","maxPriorityFeePerGas":"0x9502f900","hash":"0x47c8f5d0b3778e4c34eba7fcc356fa04a5afd954ccf484728e72c002764dd3c4","input":"0xf688bcfb0000000000000000000000000000000000000000000000000000000005f5e100","nonce":"0x4","to":"0xf6c2afb18b85175e5ffb28f20f007c047ce28592","transactionIndex":"0x16","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x970982425d18b9949141bbabb5c5230fa168626ce210a97f3856d64700fc0eeb","s":"0x6fa6d0aea6ae48783d80c1e51cda47e11c28b90a5497579b93d7f242d786f67e","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x4b596cebd02c35aa99878eb9ecb24d6f5ca5f865","gas":"0x5208","gasPrice":"0x68c88f79","maxFeePerGas":"0x68c88f79","maxPriorityFeePerGas":"0x68c88f79","hash":"0x396797ae0ebcdb72ff1f96fd08b6128f78acc7417353f142f1a5facd425a33e6","input":"0x","nonce":"0x1","to":"0x375980b8e1a417620ba9b18e5a9e0b17dccbac9d","transactionIndex":"0x17","value":"0x1c9a406c58878","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xcb2a7b106097b2f2a61d3a048054a5175c386b1dcdd5b6fcd7849dcac7c32a66","s":"0x10aef76e98276c47470f04a599b81c260ace9d2f6adc95755c6d22d859e805a2","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x6f4aa3bc9732372daa288beb9b2516374ace5786","gas":"0x1b2e020","gasPrice":"0x61010bda","maxFeePerGas":"0x61010bda","maxPriorityFeePerGas":"0x61010bda","hash":"0x454aa43d6546a6f62246826c16b7a49c6c704238c18802ef0d659922f23a573c","input":"0xe99a3f8000000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000480000000000000000000000000000000000000000000000000000000000000050000000000000000000000000000000000000000000000000000000000000008a000000000000000000000000058ce7eb44ae575fb3b3974861c1138dad3c5aee40000000000000000000000000000000000000000000000000000000000000120000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001e06defd69964a6ce467b87c64627a7a2be4be139b504757c625eb6114ec166557d000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000641a269023d235ef0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002a000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000002b05699353b600008ae85d840000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000020000000000000000000000000b4fbf271143f4fbf7b91a5ded31805e42b2208d600000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000001f63c28250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000020000000000000000000000000def65f8e2f62bde60cd86ad3b4ad7fa6741cf17500000000000000000000000000000000000000000000000000000000000001400000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000020000000000000000000000006e512435020ac228a15543236b1f46656f98136300000000000000000000000000000000000000000000000000000000000000fa000000000000000000000000d6ffd79b52a587a0a9941a61f4e6cb0d386d5458000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000413e24433da3efc4c3cc305339a7b77a1b31abb4e4d4967e97e42aed1dd0bf98936f43035f40bc80f6f6e3a9cfb43524a1171ee7f21e9ac2fa586d33a31f10619d1c000000000000000000000000000000000000000000000000000000000000000000000000000000000000006f4aa3bc9732372daa288beb9b2516374ace5786000000000000000000000000000000000000000000000000000000000000012000000000000000000000000058ce7eb44ae575fb3b3974861c1138dad3c5aee400000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000641a269023d235ef0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002c00000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000173ad21460000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000040000000000000000000000000def65f8e2f62bde60cd86ad3b4ad7fa6741cf1750000000000000000000000000000000000000000000000000000000000000ba200000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000002b05699353b600008ae85d840000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000020000000000000000000000000b4fbf271143f4fbf7b91a5ded31805e42b2208d600000000000000000000000000000000000000000000000000000000000000c00000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000def65f8e2f62bde60cd86ad3b4ad7fa6741cf175ffffffff09616c6c64617461","nonce":"0x82","to":"0x02afbd43cad367fcb71305a2dfb9a3928218f0c1","transactionIndex":"0x18","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xc7ac308b1ae238cb2aa4b030ca79baffb7b498e1b10df0c3354b3cc19cfabac9","s":"0x2358b1093b9aab5fae0cf751766b0bb2e3d8cd2b18ca627e1e12520990a8ed6d","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x6ece61d29b90642941c41240da924690da145696","gas":"0x4399c","gasPrice":"0x506794e0","hash":"0x317ecb5bd19caa42a69f836d41556ebb0e0e00e1c6cd2dee230e6e6192612527","input":"0x46f83b5000000000000000000000000000000000000000000000000000000000000000654666803decc59e7d0a5d3efa3c3653c05645ef4342738445e20a3b43e0b4aa8b000000000000000000000000000000000000000000000000000000000000000f4666803decc59e7d0a5d3efa3c3653c05645ef4342738445e20a3b43e0b4aa8b","nonce":"0x2cc4","to":"0xa6bf2be6c60175601bf88217c75dd4b14abb5fbb","transactionIndex":"0x19","value":"0x0","type":"0x0","chainId":"0x5","v":"0x2d","r":"0x37aeab0db6d550e6cba2c04c9cb10a2af0fec0b11f6e04b85e1ea0b8b9defeae","s":"0x4f32f4ef74872e1385c25e69bf21ee049545a4d423e939eaff29677450efe9eb"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xc4a5c059840a146b81c77bf79f1398f2b3d28ca7","gas":"0x432ec","gasPrice":"0x45db0a51","hash":"0xc879285db5ef0a6bce98021584d16f134c1dc0aed8cc988802c4f72ba6877ff6","input":"0x9f8420b300000000000000000000000000000000000000000000000000470de4df8200000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x1a7","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x1a","value":"0x470efc4514e000","type":"0x0","chainId":"0x5","v":"0x2d","r":"0x237e3a541c5ab490843cdc20d0fcb7416bff8da471f6a11ae1b32d2bab119141","s":"0x3c8417d7a60bd5b0bcae4975dbb4aaee54a4b4d588226481be400843bfe2b64e"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x6f4aa3bc9732372daa288beb9b2516374ace5786","gas":"0xffff","gasPrice":"0x44e9acbc","maxFeePerGas":"0x44e9acbc","maxPriorityFeePerGas":"0x44e9acbc","hash":"0xecaa2d6f597608307e5084854854ba6dc1e69395e2abea14f2c6a2fa1d6faf9a","input":"0xe2864fe300000000000000000000000000000000000000000000000000000000000000200000000000000000000000006f4aa3bc9732372daa288beb9b2516374ace57860000000000000000000000000000000000000000000000000000000000000120000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002004a8312e37fcecd450e6684009a2b54bc64f66afbe5217c7b2f63b03cd9980a9e00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000064893e8223d235ef0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002a00000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000173ad21460000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000040000000000000000000000000def65f8e2f62bde60cd86ad3b4ad7fa6741cf175000000000000000000000000000000000000000000000000000000000000085000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000de0b6b3a7640000aaaebeba000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001400000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000020000000000000000000000006e512435020ac228a15543236b1f46656f98136300000000000000000000000000000000000000000000000000000000000000fa000000000000000000000000d6ffd79b52a587a0a9941a61f4e6cb0d386d54580000000000000000000000000000000000000000000000000000000000000000","nonce":"0x83","to":"0x02afbd43cad367fcb71305a2dfb9a3928218f0c1","transactionIndex":"0x1b","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xa18772e4b9e1493ebfd5ae6219cc9ca060b71e83788fb614ab02b03fb36eaf1b","s":"0x482c7e50fde29bb4130fd6e723176e0e9913430ebb9260667d7fb55f5408d9c5","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xdb33365a8730de2f7574ff1189fb9d337bf4c36d","gas":"0x61a80","gasPrice":"0x433653c8","maxFeePerGas":"0x828367af","maxPriorityFeePerGas":"0x37e9071","hash":"0x4dd69b69a568ff30ae439e2ded72fbd7f2e7aaa345836703663f155c749c5eed","input":"0x7f34c0ddc6e984f46ab7c13b7a53643096e79c39103dc74550204d5bd1b5206ef5a2f49689071bb6a332212df26aa57cd4d1e3c0894187a9fc5e5d686cbedba5b187470f000000000000000000000000000000000000000000000000000000000000000e000000000000000000000000e8c44c30e8e52c38ac7bd232e7b7f0c7463a535100000000000000000000000000000000000000000000000000000000000000a0000000000000000000000000000000000000000000000000000000000000002e516d5044645856613738437a6b7856325a364e52777a67685a785872736e75397261616a695a7555423569465a62000000000000000000000000000000000000","nonce":"0x2b57","to":"0xb8ad54644e2371cbb7940b9fa0936f399ba7495f","transactionIndex":"0x1c","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xa1fb0e5662b54ceb3dc1623ebfb200668433cb27252d553669bcd136387394f3","s":"0x27c2f8e19f69a52a0960f05d8b21f11c313dd3e86a7139b5783a18353c407415","yParity":"0x0"}],"transactionsRoot":"0xaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa","uncles":[],"withdrawals":[{"index":"0x1170","validatorIndex":"0x38c2c","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x66edfd65"},{"index":"0x1171","validatorIndex":"0x38c2d","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6cd228e4"},{"index":"0x1172","validatorIndex":"0x38c2e","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x77f3431b"},{"index":"0x1173","validatorIndex":"0x38c2f","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6b61f268"},{"index":"0x1174","validatorIndex":"0x38c30","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6e10bb21"},{"index":"0x1175","validatorIndex":"0x38c31","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6eb115a5"},{"index":"0x1176","validatorIndex":"0x38c32","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x7caead1d"},{"index":"0x1177","validatorIndex":"0x38c33","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x772c0ddf"},{"index":"0x1178","validatorIndex":"0x38c34","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x75930a95"},{"index":"0x1179","validatorIndex":"0x38c35","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x76a4db09"},{"index":"0x117a","validatorIndex":"0x38c36","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x7e692b27"},{"index":"0x117b","validatorIndex":"0x38c37","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x72038ae6"},{"index":"0x117c","validatorIndex":"0x38c38","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6ccce352"},{"index":"0x117d","validatorIndex":"0x38c39","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x79ef6898"},{"index":"0x117e","validatorIndex":"0x38c3a","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6d58977d"},{"index":"0x117f","validatorIndex":"0x38c3b","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x76f7d208"}],"withdrawalsRoot":"0xbe712c930a0665264b025ced87cc7839eef95a3cbc26dadc93e9e185a350ad28"} diff --git a/op-service/sources/testdata/data/blocks/post-shanghai-bad-transactions_metadata.json b/op-service/sources/testdata/data/blocks/post-shanghai-bad-transactions_metadata.json new file mode 100644 index 0000000000000..0a9f8871b5542 --- /dev/null +++ b/op-service/sources/testdata/data/blocks/post-shanghai-bad-transactions_metadata.json @@ -0,0 +1 @@ +{"name":"post-shanghai-bad-transactions","fail":true, "reason": "failed to verify transactions list"} diff --git a/op-service/sources/testdata/data/blocks/post-shanghai-bad-withdrawals-hash_data.json b/op-service/sources/testdata/data/blocks/post-shanghai-bad-withdrawals-hash_data.json new file mode 100644 index 0000000000000..07d959023dbc1 --- /dev/null +++ b/op-service/sources/testdata/data/blocks/post-shanghai-bad-withdrawals-hash_data.json @@ -0,0 +1 @@ +{"baseFeePerGas":"0x3fb7c357","difficulty":"0x0","extraData":"0x","gasLimit":"0x1c9c380","gasUsed":"0x18f759","hash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","logsBloom":"0x020010404000001a0000021000000080001100410000100001000010040200980220400000008806200200000100000000000000000000008000000400042000000050000040000112080808800002044000040004042008800480002000000000000002020020000042002400000820000080040000000010200010020010100101212050000008000000008000001010200c80000112010000438040020400000000202400000000002002a0210402000622010000000001700144000040000000002204000000c000410105024010000808000000002004002000000261000000822200200800881000000012500400400000000000000040010000800000","miner":"0x000095e79eac4d76aab57cb2c1f091d553b36ca0","mixHash":"0x5b53dc49cbab268ef9950b1d81b5e36a1b2f1b97aee1b7ff6e4db0e06c29a8b0","nonce":"0x0000000000000000","number":"0x84161e","parentHash":"0x72d92c1498e05952988d4e79a695928a6bcbd37239f8a1734051263b4d3504b8","receiptsRoot":"0xaff90ae18dcc35924a4bddb68d403b8b7812c10c3ea2a114f34105c87d75bcdb","sha3Uncles":"0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347","size":"0x2a51","stateRoot":"0xc56738518b2c7854a640ae25996d2211c9ef0dd2e4dd9e59e9d9cacef39622da","timestamp":"0x64110a5c","totalDifficulty":"0xa4a470","transactions":[{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x1b7aa44088a0ea95bdc65fef6e5071e946bf7d8f","gas":"0x5208","gasPrice":"0x4159f01735","hash":"0x1e8f148a9aea7d8d16ea6e9446723b8f262e8bcd89c7c961d52046ebd43b4598","input":"0x","nonce":"0x279ad","to":"0xa21765a03dd41e2783696d314f235f4d520f6cac","transactionIndex":"0x0","value":"0x3782dace9d90000","type":"0x0","chainId":"0x5","v":"0x2e","r":"0xf9eca8b74ccaec5f4a83e981baeb8602f38d0271179c592b4a18f3866316a367","s":"0x350a9d26718d1fa9dc4f268f9c0e18fb96dbc037816ca8fc20f33f1a76f9f501"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x4d9a852e6aecd3a6e87fece2ca109780e45e6f2d","gas":"0x160ab","gasPrice":"0xd4babc57","maxFeePerGas":"0x11407d03e","maxPriorityFeePerGas":"0x9502f900","hash":"0xab5c870f4c367012bd763172afbfbe68fbf35336a66ae41aff3f2c9dbf4ea3f8","input":"0x60566037600b82828239805160001a607314602a57634e487b7160e01b600052600060045260246000fd5b30600052607381538281f3fe73000000000000000000000000000000000000000030146080604052600080fdfea26469706673582212200c479c99d58d7fbee5ee3aef5001431073a3d465bdfa46cf747a7c0b9289607864736f6c634300080d0033","nonce":"0xafd","to":null,"transactionIndex":"0x1","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x48f6acf4ac4371eb96ffca8cdef5b7704ea8c68a631d1c02927036d4ce92567e","s":"0x1f12261ddde63fd3da2ed9ea1bcbb4b0f25af898248c805a9d4b0a6e42caf9c8","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xce297b30e56bf2f6142c4048fbae1cb8a756fefd","gas":"0x557300","gasPrice":"0xd4babc57","maxFeePerGas":"0xfabdd183","maxPriorityFeePerGas":"0x9502f900","hash":"0xa81fd92b2d0f0bbd3cc355f869cca3243c98c5e2641db9ecf3eeabb3b13bff6a","input":"0x7bbaf1ea0000000000000000000000000000000000000000000000000000000000000005000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000000","nonce":"0xad92","to":"0x4c0ce02c1219ce5d2afffba97e484272a4637b49","transactionIndex":"0x2","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xd11b842a5f7b0e020470e764b443fafc4044327bca8dbb37131425359abace2","s":"0x1009867573946fb0a4a35339a6eaaece4d0a168b2346539076e6319e9a466b1","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x47a916d0b694c95bc0c09953c1a6e22c8867be32","gas":"0x5208","gasPrice":"0x991ff257","maxFeePerGas":"0xb2fea055","maxPriorityFeePerGas":"0x59682f00","hash":"0xa92c7b720c08c83f1a0ed7e4c163200e30a3a8c03fcc5a51e685ea20cd0cb577","input":"0x","nonce":"0x2","to":"0xf955dfe99bbfd06a8be208274cd654ecfb66a45e","transactionIndex":"0x3","value":"0x11c37937e08000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xeecd431225215c3ddc2e13cf16fa29f9a2ab1afbaa02988f3ceac27416edf0f5","s":"0x6494062330a9d509f7c778cb45cbcc9932e5f9b4ec94a1ec315f579f8d973b7b","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x672d214fe4db218defae698085a3ccefc773dfa9","gas":"0xf4f6","gasPrice":"0x991ff257","maxFeePerGas":"0xb2fea055","maxPriorityFeePerGas":"0x59682f00","hash":"0x6921b429ad2ec1e97d3457049ad2e893b5a0349beba47ca1c74a9540af75347a","input":"0xa1ddc546000000000000000000000000000000000000000000000000000000000000118f","nonce":"0x8e","to":"0xdef65f8e2f62bde60cd86ad3b4ad7fa6741cf175","transactionIndex":"0x4","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x4732ad21401b509bebb947a8566127fba1e245eb5a262ddc522d6867ab80567e","s":"0x2153013617fefdb06db0a7316d8883056441d33c2abf5ed6291fa0e3cc5c3a2f","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x0b12f7f996579fe7d9302d2574910121c214ee15","gas":"0x56a8","gasPrice":"0x991ff257","maxFeePerGas":"0xb2fea055","maxPriorityFeePerGas":"0x59682f00","hash":"0xf776b2da0b835dde05d0d8b76fd19385d61e7055036cf637f804b36dc94f2384","input":"0x71ec5c05aa669c4922569c1d33f7a81aaa21813800000000000000000000000013a0c5930c028511dc02665e7285134b6d11a5f40000000000000000000000000b12f7f996579fe7d9302d2574910121c214ee150000000000000000000000000000000000000000000000000000000000000000","nonce":"0xe","to":"0x7c125c1d515b8945841b3d5144a060115c58725f","transactionIndex":"0x5","value":"0x2386f26fc10000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xc4505d4c46ef9a0103178e5ef4fbc857114ae5c4686b68b74d07c3ee3a86e575","s":"0x74db34fd675bea7d2ee74f14fd8709cb88c7d22c2267d12f2c671b5ebc180bd5","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xd36aac0c9676e984d72823fb662ce94d3ab5e551","gas":"0xff212","gasPrice":"0x991ff257","maxFeePerGas":"0xd86d063e","maxPriorityFeePerGas":"0x59682f00","hash":"0x9a08d899cd14ebb930ed59fa774afdb88a22615b3a931e930931ea54d26dc0bc","input":"0x49160658babdf216946a22b96c966ceeba750f14807726306ebeed500a2621a7481df010000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000c0000000000000000000000000000000000000000000000000000000000000012000000000000000000000000000000000000000000000000000000000000000084d6f6f6e6265616d000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002a3078434133633746363939643335333137316438434643364236334431433764333841333233373238300000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0b616f73c8d00641109f0000054f967b8a135e44e233da070ea88c5e4a53bacac0000000000000000000000000000000000000000000000000000000000000002000000000000000000000000c6a3a17399d88e5dfd2de4fa41dcccade6a2d2170000000000000000000000008676147503f761e44b85df01811edd52be01b56c000000000000000000000000000000000000000000000000d02ab486cedc00000000000000000000000000000000000000000000000000000de0b6b3a7640000","nonce":"0x7121","to":"0x2d276bd64fe8643a1d76b2e9530c753423e972c1","transactionIndex":"0x6","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xce452361d331baf2ac86947a1b3b454b3e842923e1f39139b33a572845dd5d7c","s":"0x388126881782af5a146ce8409f1e3a2c9a4cadcfe9a2c1d27258af6e4eb5cec1","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xb83a48ee322989a0a4f838cb207abc28ec021b73","gas":"0x326ff","gasPrice":"0x991ff257","maxFeePerGas":"0x5c3362b9c","maxPriorityFeePerGas":"0x59682f00","hash":"0x0fe0d97e25d5eb11a33a3e8278584c3780941fc2675bdf8fc547cee3d1fd3b17","input":"0xa4110dbe190e65a7fe0ad5acd305c6446a02cb39de30f382000fe67927434063bf4c4b2ca86b3ee6d039dc7a0268f9e1c39266c3f12a752a7eb72f0895dedf62291fd292","nonce":"0x12e","to":"0x96e6192eeaf7bb308f79fb5017a9085754b9e12a","transactionIndex":"0x7","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x46819bb540fa459a5a0cbf041a0286507d597fc8958a6af8b9ce193f00005238","s":"0x31495c58bf4b74925f870c59635912681bee947b1cb4b08cc19f22421b1a10ab","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xb83a48ee322989a0a4f838cb207abc28ec021b73","gas":"0x3270b","gasPrice":"0x991ff257","maxFeePerGas":"0x5c3362b9c","maxPriorityFeePerGas":"0x59682f00","hash":"0xef47a60f57f177a683c723c658137efab66d311e1c5abbc4d74f653535144d03","input":"0xa4110dbe18eba3e815ec7fcb03a8eea0487209c3253024d1dc4f36f775a43fdd3e409b74c0a5c88e54f39b88db6f185a41431b204120d3e66c9b08b86f5e8382623327e5","nonce":"0x12f","to":"0x96e6192eeaf7bb308f79fb5017a9085754b9e12a","transactionIndex":"0x8","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x4d7e11fe3914763a2735493a62b71ae0028e75a750a8b06407996cf478e273c8","s":"0x60c18fdf948721f96fdc2efbf694910122e82191c7a40a5caab247c06ab7f3cf","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x7712a1f96b3f37c3dd88a22d4f7a7977b937fe62","gas":"0x1ff06","gasPrice":"0x991ff257","maxFeePerGas":"0xcf662006","maxPriorityFeePerGas":"0x59682f00","hash":"0xe23a5b35faae5335adc5aca38c5d633b00438b798c2053104b8df48406c9b141","input":"0x3ff9751b0000000000000000000000000000000000000000000000000000000000000034000000000000000000000000000000000000000000000000000000000000003500000000000000000000000000000000000000000000000000000000000000a000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000160000000000000000000000000000000000000000000000000000000000000002e516d566e75374a51566f445271536748427a72615970374879373848774a744c4669366e5546436f775447647a70000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002e516d5439716b3343525962464457704446596541763854384831676e6f6e67774b6868354a36384e4c6b4c6972360000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000041c9f31b989aaa745aecc563139f89c8ab3ab492e725d1e0305b7d602fcbf9293c463f0d2e4f5fb0c9efb54eb2cde9af10ebc9c3676f2334007291ffa8efb40adb1c00000000000000000000000000000000000000000000000000000000000000","nonce":"0x16","to":"0xc3b87ea584cb9cb5a4523e2bed16a34bf7746317","transactionIndex":"0x9","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xcc693a9544394653e1f393f02635e2c1f78b5e6c26c4d00a867bcf4adc2bc09e","s":"0x23f4b71b773c19f77cf251b2aeea03f2696bddd847d1f6d75acd2fbea6a543e4","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x12bbafcfa06423d87bed591a64c1a1f34791e90a","gas":"0x1b2e020","gasPrice":"0x8f0d3617","maxFeePerGas":"0x1cb3abd5a","maxPriorityFeePerGas":"0x4f5572c0","hash":"0xd8cea4ba619b317bc05d58534af73beec6c2548b31b24d4dc61c9bbd29cfa17a","input":"0x","nonce":"0x4d","to":"0x12bbafcfa06423d87bed591a64c1a1f34791e90a","transactionIndex":"0xa","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x8dae28608985d6ab47cbe122ee88972e38664cede30978f41944f347bad86e5c","s":"0x17c2898b39b7e3b874dc78e7df3fcff68f4d715385c632aad4bdf6e62505651c","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x6999c36394dd5d3d3295af63a4736ad6bd279448","gas":"0x14d94","gasPrice":"0x7b528d57","maxFeePerGas":"0x7df743e0","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x79a4b9d90b02c768baaad305f266281213cc75062cbe99a13222cc0c4b509498","input":"0x6a7612020000000000000000000000009008d19f58aabd9ed0d60971565aa8510560ab4100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000140000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000022000000000000000000000000000000000000000000000000000000000000000a4ec6cb13f00000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000003826d8d7371becafc0afedc3fe85b699b87f4357d55ec39ce83c510ed7d70ff514dce8236351f4627ccec6a7d9a67bc6fc2ec17ca76411113c00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000410000000000000000000000006999c36394dd5d3d3295af63a4736ad6bd27944800000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000","nonce":"0x13","to":"0xdce8236351f4627ccec6a7d9a67bc6fc2ec17ca7","transactionIndex":"0xb","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x669487011643510f7512ec15b07d74efb853ba4ad9fe9c7e9850ccf24e3d4c53","s":"0x2191f9ee81087e1df833e69d6129ec330ed4c99be2031060834e22c589fcf79b","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x08ebc052e6353b4d8392113f0f2c5decd691ddcd","gas":"0x1b2e020","gasPrice":"0x7b528d57","maxFeePerGas":"0xf6e4d9c4","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x6790a3bbddbeb21fcb736a59b3775755051c3a6344d8390cf8ca27f2e8a814f0","input":"0x6871ee40","nonce":"0x4","to":"0xb21b333c40354393f18de57f2d0a0fc21f270482","transactionIndex":"0xc","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xa7a58ab858e5dd87b9a74d550e5716ac40ddefd1c21d5baa51e542f4f941d73e","s":"0x1fd0cb1563df0368bd332717d7c8210187cd1ac2ff44f61f5242fc02eaa0c2fe","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x08ebc052e6353b4d8392113f0f2c5decd691ddcd","gas":"0x12c36","gasPrice":"0x7b528d57","maxFeePerGas":"0xe596c292","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x87ec7ace5442db252b5751ffddd38dcb04b088d36b6b0e526ff25607a4293c81","input":"0xcb40cbfd","nonce":"0x5","to":"0xb21b333c40354393f18de57f2d0a0fc21f270482","transactionIndex":"0xd","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x8e4bd40195bdfaa868af97dbf22e0b74295d95564a8381bc9bcfe1af3cde2cdb","s":"0x62057dc87c8b2b197d12c648233aab4134b7c2a2f65db89a49728564f3d0864d","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x08ebc052e6353b4d8392113f0f2c5decd691ddcd","gas":"0x12c36","gasPrice":"0x7b528d57","maxFeePerGas":"0xe596c292","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x40cb487ecffda94f97ce7fc0f7163f2f024235df2c8291169edc80dac063e6d0","input":"0xcb40cbfd","nonce":"0x6","to":"0xb21b333c40354393f18de57f2d0a0fc21f270482","transactionIndex":"0xe","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x993c4386ffc2bd63a48dd31cf5f65aa355cba3c063b08778b328d748937098e5","s":"0x203b1faf595628dd78e760bcc1740065625abb6cf00b1b17224e10fa6b424e43","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xafc7682751d3654f34958e3fb660971bf5918367","gas":"0x1b2e020","gasPrice":"0x7b528d57","maxFeePerGas":"0xefb40664","maxPriorityFeePerGas":"0x3b9aca00","hash":"0xb76bb3d88c9b30d927c45ccfcf8d5b0054411ac8501ad588822a7d04690cccf6","input":"0x40c10f19000000000000000000000000afc7682751d3654f34958e3fb660971bf59183670000000000000000000000000000000000000000000000008ac7230489e80000","nonce":"0x20","to":"0x84ced17d95f3ec7230baf4a369f1e624ae60090d","transactionIndex":"0xf","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x78e9d29c606f6a61a1428ed7326df05210d802c3061f3b469847cc461eb48025","s":"0x517afe5a21175f186233ae7a6c090cd33e028a77e5854e98eb2fa4c9284430e7","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x12bbafcfa06423d87bed591a64c1a1f34791e90a","gas":"0xcafe","gasPrice":"0x7b528d57","maxFeePerGas":"0x16ba45bce","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x798ebe823209869347c08bd81e04fbf60e9bdfe44b1cc923215182d0cf3d4edb","input":"0x40c10f1900000000000000000000000012bbafcfa06423d87bed591a64c1a1f34791e90a0000000000000000000000000000000000000000000000000000000000000032","nonce":"0x4e","to":"0xd25d682189afa7ed0c2811195b3f3d07616927bc","transactionIndex":"0x10","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xbe2aa95f4c32188c9ecbae97286ab983f7cc5a7017d46c404f8eb80b55e2dc13","s":"0x55d8968f509f51633f49260178941fd5a3db999e1995206348d7a3f05152b3d5","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x12bbafcfa06423d87bed591a64c1a1f34791e90a","gas":"0xcafe","gasPrice":"0x7b528d57","maxFeePerGas":"0xc6132c0c","maxPriorityFeePerGas":"0x3b9aca00","hash":"0xbe68a7e02725f799a65ebb069ccc83a014ac7c40e4119bf7c220a2f6ddfee295","input":"0x40c10f1900000000000000000000000012bbafcfa06423d87bed591a64c1a1f34791e90a0000000000000000000000000000000000000000000000000000000000000064","nonce":"0x4f","to":"0xd25d682189afa7ed0c2811195b3f3d07616927bc","transactionIndex":"0x11","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x1750ed45d0d2d048a61dcc3ff3e7ad0cbd395b77698c4f2eeb6baaea4c966d96","s":"0xe646e3a87b6dc50439468bcfd24cbf12a6f95b2762f1527c97a7d1b7f03530e","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xd0c0338baac9ce09c1d1caab88b4360507061e37","gas":"0x1b2e020","gasPrice":"0x7b528d57","maxFeePerGas":"0x1918167aa","maxPriorityFeePerGas":"0x3b9aca00","hash":"0xc90c3a72efe81331727fcce4b5bd4906066da314ca9a0b44023a6b09ea7e8114","input":"0x4e71d92d","nonce":"0xe7","to":"0x0137d796936e199b917b93118eb4e002508a48bd","transactionIndex":"0x12","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x22222ce8fe753082c8e5dc7478fa7b87db9c8d0fb070ebc88ab015db13fd6bb","s":"0x6dceadecf6f6a3ddc433a547dba6d5fcdfb7d006ce09eeae1c06c1828ef9fff9","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x8bd834cc1dd17d1a2f7eb6140c3dd5ab51d0f338","gas":"0x1b2e020","gasPrice":"0x7b528d57","maxFeePerGas":"0x1a4019792","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x619a6cbd43cde074d314c19623bd66d9fb1e13c158d7138775236f798dc1245e","input":"0x1da1db5e00000000000000000000000000000000000000000000000000001b5ec4ff740d","nonce":"0x10","to":"0xbad0009f7a8e796e3f975dc1d6ab3e3c237b857c","transactionIndex":"0x13","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x733c496e8c84f78d113bc8b5ad6d04a133bb10bbcecf0db93d97eeedfa3d984a","s":"0x6627c16aa7dea27db44c0f0641c30ffd544b9b9b1c299dc60611e1e01c714ee8","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x8bd834cc1dd17d1a2f7eb6140c3dd5ab51d0f338","gas":"0x11df0","gasPrice":"0x7b528d57","maxFeePerGas":"0x1d3fbccb8","maxPriorityFeePerGas":"0x3b9aca00","hash":"0xca5a56cd77b9e5b0e79020cc6346edf205bc11e901984d805125f28c2e6686e6","input":"0xd7c01032000000000000000000000000356f24c0f3187a6dcb949e4a60aa0a74a8a0327e0000000000000000000000000f8bacfae87aee49a2eec86df0c6b958ec3fd4fd0000000000000000000000000f8bacfae87aee49a2eec86df0c6b958ec3fd4fd","nonce":"0x11","to":"0xbad0009f7a8e796e3f975dc1d6ab3e3c237b857c","transactionIndex":"0x14","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x4aa872c1a7da70126917604193717575b91407f82449bca956d4089b90cd902","s":"0x4b5f788c68024f8958f66e8c768a8e0f65ef297c4ffd420a715258b0a55cb0a0","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x9bedd66b05712a1add7d1fec899b8641b3ecc863","gas":"0x1b2e020","gasPrice":"0x7b528d57","maxFeePerGas":"0x1e706c8d2","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x999c9ddeed67c6ef6fbf02a6e977a6c1b68e18d24814e51643c7157b87a43e0a","input":"0xa8b78ed0","nonce":"0x3","to":"0xf6c2afb18b85175e5ffb28f20f007c047ce28592","transactionIndex":"0x15","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xf1ca074104ee0b6a67223afd797654b8f21060453f7662dd7be79de938c396da","s":"0x4c9a4e56f0ad21e2dd8d1116c7a3e41ea2c6126853772f7897bd959e81e2e28a","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x9bedd66b05712a1add7d1fec899b8641b3ecc863","gas":"0x2dc6c0","gasPrice":"0xd4babc57","maxFeePerGas":"0x21c13e710","maxPriorityFeePerGas":"0x9502f900","hash":"0x47c8f5d0b3778e4c34eba7fcc356fa04a5afd954ccf484728e72c002764dd3c4","input":"0xf688bcfb0000000000000000000000000000000000000000000000000000000005f5e100","nonce":"0x4","to":"0xf6c2afb18b85175e5ffb28f20f007c047ce28592","transactionIndex":"0x16","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x970982425d18b9949141bbabb5c5230fa168626ce210a97f3856d64700fc0eeb","s":"0x6fa6d0aea6ae48783d80c1e51cda47e11c28b90a5497579b93d7f242d786f67e","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x4b596cebd02c35aa99878eb9ecb24d6f5ca5f865","gas":"0x5208","gasPrice":"0x68c88f79","maxFeePerGas":"0x68c88f79","maxPriorityFeePerGas":"0x68c88f79","hash":"0x396797ae0ebcdb72ff1f96fd08b6128f78acc7417353f142f1a5facd425a33e6","input":"0x","nonce":"0x1","to":"0x375980b8e1a417620ba9b18e5a9e0b17dccbac9d","transactionIndex":"0x17","value":"0x1c9a406c58878","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xcb2a7b106097b2f2a61d3a048054a5175c386b1dcdd5b6fcd7849dcac7c32a66","s":"0x10aef76e98276c47470f04a599b81c260ace9d2f6adc95755c6d22d859e805a2","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x6f4aa3bc9732372daa288beb9b2516374ace5786","gas":"0x1b2e020","gasPrice":"0x61010bda","maxFeePerGas":"0x61010bda","maxPriorityFeePerGas":"0x61010bda","hash":"0x454aa43d6546a6f62246826c16b7a49c6c704238c18802ef0d659922f23a573c","input":"0xe99a3f8000000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000480000000000000000000000000000000000000000000000000000000000000050000000000000000000000000000000000000000000000000000000000000008a000000000000000000000000058ce7eb44ae575fb3b3974861c1138dad3c5aee40000000000000000000000000000000000000000000000000000000000000120000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001e06defd69964a6ce467b87c64627a7a2be4be139b504757c625eb6114ec166557d000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000641a269023d235ef0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002a000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000002b05699353b600008ae85d840000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000020000000000000000000000000b4fbf271143f4fbf7b91a5ded31805e42b2208d600000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000001f63c28250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000020000000000000000000000000def65f8e2f62bde60cd86ad3b4ad7fa6741cf17500000000000000000000000000000000000000000000000000000000000001400000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000020000000000000000000000006e512435020ac228a15543236b1f46656f98136300000000000000000000000000000000000000000000000000000000000000fa000000000000000000000000d6ffd79b52a587a0a9941a61f4e6cb0d386d5458000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000413e24433da3efc4c3cc305339a7b77a1b31abb4e4d4967e97e42aed1dd0bf98936f43035f40bc80f6f6e3a9cfb43524a1171ee7f21e9ac2fa586d33a31f10619d1c000000000000000000000000000000000000000000000000000000000000000000000000000000000000006f4aa3bc9732372daa288beb9b2516374ace5786000000000000000000000000000000000000000000000000000000000000012000000000000000000000000058ce7eb44ae575fb3b3974861c1138dad3c5aee400000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000641a269023d235ef0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002c00000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000173ad21460000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000040000000000000000000000000def65f8e2f62bde60cd86ad3b4ad7fa6741cf1750000000000000000000000000000000000000000000000000000000000000ba200000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000002b05699353b600008ae85d840000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000020000000000000000000000000b4fbf271143f4fbf7b91a5ded31805e42b2208d600000000000000000000000000000000000000000000000000000000000000c00000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000def65f8e2f62bde60cd86ad3b4ad7fa6741cf175ffffffff09616c6c64617461","nonce":"0x82","to":"0x02afbd43cad367fcb71305a2dfb9a3928218f0c1","transactionIndex":"0x18","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xc7ac308b1ae238cb2aa4b030ca79baffb7b498e1b10df0c3354b3cc19cfabac9","s":"0x2358b1093b9aab5fae0cf751766b0bb2e3d8cd2b18ca627e1e12520990a8ed6d","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x6ece61d29b90642941c41240da924690da145696","gas":"0x4399c","gasPrice":"0x506794e0","hash":"0x317ecb5bd19caa42a69f836d41556ebb0e0e00e1c6cd2dee230e6e6192612527","input":"0x46f83b5000000000000000000000000000000000000000000000000000000000000000654666803decc59e7d0a5d3efa3c3653c05645ef4342738445e20a3b43e0b4aa8b000000000000000000000000000000000000000000000000000000000000000f4666803decc59e7d0a5d3efa3c3653c05645ef4342738445e20a3b43e0b4aa8b","nonce":"0x2cc4","to":"0xa6bf2be6c60175601bf88217c75dd4b14abb5fbb","transactionIndex":"0x19","value":"0x0","type":"0x0","chainId":"0x5","v":"0x2d","r":"0x37aeab0db6d550e6cba2c04c9cb10a2af0fec0b11f6e04b85e1ea0b8b9defeae","s":"0x4f32f4ef74872e1385c25e69bf21ee049545a4d423e939eaff29677450efe9eb"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xc4a5c059840a146b81c77bf79f1398f2b3d28ca7","gas":"0x432ec","gasPrice":"0x45db0a51","hash":"0xc879285db5ef0a6bce98021584d16f134c1dc0aed8cc988802c4f72ba6877ff6","input":"0x9f8420b300000000000000000000000000000000000000000000000000470de4df8200000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x1a7","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x1a","value":"0x470efc4514e000","type":"0x0","chainId":"0x5","v":"0x2d","r":"0x237e3a541c5ab490843cdc20d0fcb7416bff8da471f6a11ae1b32d2bab119141","s":"0x3c8417d7a60bd5b0bcae4975dbb4aaee54a4b4d588226481be400843bfe2b64e"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x6f4aa3bc9732372daa288beb9b2516374ace5786","gas":"0xffff","gasPrice":"0x44e9acbc","maxFeePerGas":"0x44e9acbc","maxPriorityFeePerGas":"0x44e9acbc","hash":"0xecaa2d6f597608307e5084854854ba6dc1e69395e2abea14f2c6a2fa1d6faf9a","input":"0xe2864fe300000000000000000000000000000000000000000000000000000000000000200000000000000000000000006f4aa3bc9732372daa288beb9b2516374ace57860000000000000000000000000000000000000000000000000000000000000120000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002004a8312e37fcecd450e6684009a2b54bc64f66afbe5217c7b2f63b03cd9980a9e00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000064893e8223d235ef0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002a00000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000173ad21460000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000040000000000000000000000000def65f8e2f62bde60cd86ad3b4ad7fa6741cf175000000000000000000000000000000000000000000000000000000000000085000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000de0b6b3a7640000aaaebeba000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001400000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000020000000000000000000000006e512435020ac228a15543236b1f46656f98136300000000000000000000000000000000000000000000000000000000000000fa000000000000000000000000d6ffd79b52a587a0a9941a61f4e6cb0d386d54580000000000000000000000000000000000000000000000000000000000000000","nonce":"0x83","to":"0x02afbd43cad367fcb71305a2dfb9a3928218f0c1","transactionIndex":"0x1b","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xa18772e4b9e1493ebfd5ae6219cc9ca060b71e83788fb614ab02b03fb36eaf1b","s":"0x482c7e50fde29bb4130fd6e723176e0e9913430ebb9260667d7fb55f5408d9c5","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xdb33365a8730de2f7574ff1189fb9d337bf4c36d","gas":"0x61a80","gasPrice":"0x433653c8","maxFeePerGas":"0x828367af","maxPriorityFeePerGas":"0x37e9071","hash":"0x4dd69b69a568ff30ae439e2ded72fbd7f2e7aaa345836703663f155c749c5eed","input":"0x7f34c0ddc6e984f46ab7c13b7a53643096e79c39103dc74550204d5bd1b5206ef5a2f49689071bb6a332212df26aa57cd4d1e3c0894187a9fc5e5d686cbedba5b187470f000000000000000000000000000000000000000000000000000000000000000e000000000000000000000000e8c44c30e8e52c38ac7bd232e7b7f0c7463a535100000000000000000000000000000000000000000000000000000000000000a0000000000000000000000000000000000000000000000000000000000000002e516d5044645856613738437a6b7856325a364e52777a67685a785872736e75397261616a695a7555423569465a62000000000000000000000000000000000000","nonce":"0x2b57","to":"0xb8ad54644e2371cbb7940b9fa0936f399ba7495f","transactionIndex":"0x1c","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xa1fb0e5662b54ceb3dc1623ebfb200668433cb27252d553669bcd136387394f3","s":"0x27c2f8e19f69a52a0960f05d8b21f11c313dd3e86a7139b5783a18353c407415","yParity":"0x0"}],"transactionsRoot":"0x4a87d0cf5990b1c5bac631583e5965c2ba943858bebb2e07f74d0b697f73821a","uncles":[],"withdrawals":[{"index":"0x1171","validatorIndex":"0x38c2d","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6cd228e4"},{"index":"0x1172","validatorIndex":"0x38c2e","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x77f3431b"},{"index":"0x1173","validatorIndex":"0x38c2f","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6b61f268"},{"index":"0x1174","validatorIndex":"0x38c30","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6e10bb21"},{"index":"0x1175","validatorIndex":"0x38c31","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6eb115a5"},{"index":"0x1176","validatorIndex":"0x38c32","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x7caead1d"},{"index":"0x1177","validatorIndex":"0x38c33","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x772c0ddf"},{"index":"0x1178","validatorIndex":"0x38c34","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x75930a95"},{"index":"0x1179","validatorIndex":"0x38c35","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x76a4db09"},{"index":"0x117a","validatorIndex":"0x38c36","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x7e692b27"},{"index":"0x117b","validatorIndex":"0x38c37","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x72038ae6"},{"index":"0x117c","validatorIndex":"0x38c38","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6ccce352"},{"index":"0x117d","validatorIndex":"0x38c39","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x79ef6898"},{"index":"0x117e","validatorIndex":"0x38c3a","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6d58977d"},{"index":"0x117f","validatorIndex":"0x38c3b","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x76f7d208"}],"withdrawalsRoot":"0x6fd5c0b3074ad20176493616ef2e1ca79172f09ff7695e63a5ca2fd7b66cbe55"} diff --git a/op-service/sources/testdata/data/blocks/post-shanghai-bad-withdrawals-hash_metadata.json b/op-service/sources/testdata/data/blocks/post-shanghai-bad-withdrawals-hash_metadata.json new file mode 100644 index 0000000000000..afffda99a930f --- /dev/null +++ b/op-service/sources/testdata/data/blocks/post-shanghai-bad-withdrawals-hash_metadata.json @@ -0,0 +1 @@ +{"name":"post-shanghai-bad-withdrawals-hash","fail":true, "reason":"failed to verify block hash"} diff --git a/op-service/sources/testdata/data/blocks/post-shanghai-bad-withdrawals-nil_data.json b/op-service/sources/testdata/data/blocks/post-shanghai-bad-withdrawals-nil_data.json new file mode 100644 index 0000000000000..6891f9916845c --- /dev/null +++ b/op-service/sources/testdata/data/blocks/post-shanghai-bad-withdrawals-nil_data.json @@ -0,0 +1 @@ +{"baseFeePerGas":"0x3fb7c357","difficulty":"0x0","extraData":"0x","gasLimit":"0x1c9c380","gasUsed":"0x18f759","hash":"0x808eada47015f4a265801a708c720cc5d7c7e051fdd7cd1e042777866b379a73","logsBloom":"0x020010404000001a0000021000000080001100410000100001000010040200980220400000008806200200000100000000000000000000008000000400042000000050000040000112080808800002044000040004042008800480002000000000000002020020000042002400000820000080040000000010200010020010100101212050000008000000008000001010200c80000112010000438040020400000000202400000000002002a0210402000622010000000001700144000040000000002204000000c000410105024010000808000000002004002000000261000000822200200800881000000012500400400000000000000040010000800000","miner":"0x000095e79eac4d76aab57cb2c1f091d553b36ca0","mixHash":"0x5b53dc49cbab268ef9950b1d81b5e36a1b2f1b97aee1b7ff6e4db0e06c29a8b0","nonce":"0x0000000000000000","number":"0x84161e","parentHash":"0x72d92c1498e05952988d4e79a695928a6bcbd37239f8a1734051263b4d3504b8","receiptsRoot":"0xaff90ae18dcc35924a4bddb68d403b8b7812c10c3ea2a114f34105c87d75bcdb","sha3Uncles":"0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347","size":"0x2a51","stateRoot":"0xc56738518b2c7854a640ae25996d2211c9ef0dd2e4dd9e59e9d9cacef39622da","timestamp":"0x64110a5c","totalDifficulty":"0xa4a470","transactions":[{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x1b7aa44088a0ea95bdc65fef6e5071e946bf7d8f","gas":"0x5208","gasPrice":"0x4159f01735","hash":"0x1e8f148a9aea7d8d16ea6e9446723b8f262e8bcd89c7c961d52046ebd43b4598","input":"0x","nonce":"0x279ad","to":"0xa21765a03dd41e2783696d314f235f4d520f6cac","transactionIndex":"0x0","value":"0x3782dace9d90000","type":"0x0","chainId":"0x5","v":"0x2e","r":"0xf9eca8b74ccaec5f4a83e981baeb8602f38d0271179c592b4a18f3866316a367","s":"0x350a9d26718d1fa9dc4f268f9c0e18fb96dbc037816ca8fc20f33f1a76f9f501"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x4d9a852e6aecd3a6e87fece2ca109780e45e6f2d","gas":"0x160ab","gasPrice":"0xd4babc57","maxFeePerGas":"0x11407d03e","maxPriorityFeePerGas":"0x9502f900","hash":"0xab5c870f4c367012bd763172afbfbe68fbf35336a66ae41aff3f2c9dbf4ea3f8","input":"0x60566037600b82828239805160001a607314602a57634e487b7160e01b600052600060045260246000fd5b30600052607381538281f3fe73000000000000000000000000000000000000000030146080604052600080fdfea26469706673582212200c479c99d58d7fbee5ee3aef5001431073a3d465bdfa46cf747a7c0b9289607864736f6c634300080d0033","nonce":"0xafd","to":null,"transactionIndex":"0x1","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x48f6acf4ac4371eb96ffca8cdef5b7704ea8c68a631d1c02927036d4ce92567e","s":"0x1f12261ddde63fd3da2ed9ea1bcbb4b0f25af898248c805a9d4b0a6e42caf9c8","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xce297b30e56bf2f6142c4048fbae1cb8a756fefd","gas":"0x557300","gasPrice":"0xd4babc57","maxFeePerGas":"0xfabdd183","maxPriorityFeePerGas":"0x9502f900","hash":"0xa81fd92b2d0f0bbd3cc355f869cca3243c98c5e2641db9ecf3eeabb3b13bff6a","input":"0x7bbaf1ea0000000000000000000000000000000000000000000000000000000000000005000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000000","nonce":"0xad92","to":"0x4c0ce02c1219ce5d2afffba97e484272a4637b49","transactionIndex":"0x2","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xd11b842a5f7b0e020470e764b443fafc4044327bca8dbb37131425359abace2","s":"0x1009867573946fb0a4a35339a6eaaece4d0a168b2346539076e6319e9a466b1","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x47a916d0b694c95bc0c09953c1a6e22c8867be32","gas":"0x5208","gasPrice":"0x991ff257","maxFeePerGas":"0xb2fea055","maxPriorityFeePerGas":"0x59682f00","hash":"0xa92c7b720c08c83f1a0ed7e4c163200e30a3a8c03fcc5a51e685ea20cd0cb577","input":"0x","nonce":"0x2","to":"0xf955dfe99bbfd06a8be208274cd654ecfb66a45e","transactionIndex":"0x3","value":"0x11c37937e08000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xeecd431225215c3ddc2e13cf16fa29f9a2ab1afbaa02988f3ceac27416edf0f5","s":"0x6494062330a9d509f7c778cb45cbcc9932e5f9b4ec94a1ec315f579f8d973b7b","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x672d214fe4db218defae698085a3ccefc773dfa9","gas":"0xf4f6","gasPrice":"0x991ff257","maxFeePerGas":"0xb2fea055","maxPriorityFeePerGas":"0x59682f00","hash":"0x6921b429ad2ec1e97d3457049ad2e893b5a0349beba47ca1c74a9540af75347a","input":"0xa1ddc546000000000000000000000000000000000000000000000000000000000000118f","nonce":"0x8e","to":"0xdef65f8e2f62bde60cd86ad3b4ad7fa6741cf175","transactionIndex":"0x4","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x4732ad21401b509bebb947a8566127fba1e245eb5a262ddc522d6867ab80567e","s":"0x2153013617fefdb06db0a7316d8883056441d33c2abf5ed6291fa0e3cc5c3a2f","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x0b12f7f996579fe7d9302d2574910121c214ee15","gas":"0x56a8","gasPrice":"0x991ff257","maxFeePerGas":"0xb2fea055","maxPriorityFeePerGas":"0x59682f00","hash":"0xf776b2da0b835dde05d0d8b76fd19385d61e7055036cf637f804b36dc94f2384","input":"0x71ec5c05aa669c4922569c1d33f7a81aaa21813800000000000000000000000013a0c5930c028511dc02665e7285134b6d11a5f40000000000000000000000000b12f7f996579fe7d9302d2574910121c214ee150000000000000000000000000000000000000000000000000000000000000000","nonce":"0xe","to":"0x7c125c1d515b8945841b3d5144a060115c58725f","transactionIndex":"0x5","value":"0x2386f26fc10000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xc4505d4c46ef9a0103178e5ef4fbc857114ae5c4686b68b74d07c3ee3a86e575","s":"0x74db34fd675bea7d2ee74f14fd8709cb88c7d22c2267d12f2c671b5ebc180bd5","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xd36aac0c9676e984d72823fb662ce94d3ab5e551","gas":"0xff212","gasPrice":"0x991ff257","maxFeePerGas":"0xd86d063e","maxPriorityFeePerGas":"0x59682f00","hash":"0x9a08d899cd14ebb930ed59fa774afdb88a22615b3a931e930931ea54d26dc0bc","input":"0x49160658babdf216946a22b96c966ceeba750f14807726306ebeed500a2621a7481df010000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000c0000000000000000000000000000000000000000000000000000000000000012000000000000000000000000000000000000000000000000000000000000000084d6f6f6e6265616d000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002a3078434133633746363939643335333137316438434643364236334431433764333841333233373238300000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0b616f73c8d00641109f0000054f967b8a135e44e233da070ea88c5e4a53bacac0000000000000000000000000000000000000000000000000000000000000002000000000000000000000000c6a3a17399d88e5dfd2de4fa41dcccade6a2d2170000000000000000000000008676147503f761e44b85df01811edd52be01b56c000000000000000000000000000000000000000000000000d02ab486cedc00000000000000000000000000000000000000000000000000000de0b6b3a7640000","nonce":"0x7121","to":"0x2d276bd64fe8643a1d76b2e9530c753423e972c1","transactionIndex":"0x6","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xce452361d331baf2ac86947a1b3b454b3e842923e1f39139b33a572845dd5d7c","s":"0x388126881782af5a146ce8409f1e3a2c9a4cadcfe9a2c1d27258af6e4eb5cec1","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xb83a48ee322989a0a4f838cb207abc28ec021b73","gas":"0x326ff","gasPrice":"0x991ff257","maxFeePerGas":"0x5c3362b9c","maxPriorityFeePerGas":"0x59682f00","hash":"0x0fe0d97e25d5eb11a33a3e8278584c3780941fc2675bdf8fc547cee3d1fd3b17","input":"0xa4110dbe190e65a7fe0ad5acd305c6446a02cb39de30f382000fe67927434063bf4c4b2ca86b3ee6d039dc7a0268f9e1c39266c3f12a752a7eb72f0895dedf62291fd292","nonce":"0x12e","to":"0x96e6192eeaf7bb308f79fb5017a9085754b9e12a","transactionIndex":"0x7","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x46819bb540fa459a5a0cbf041a0286507d597fc8958a6af8b9ce193f00005238","s":"0x31495c58bf4b74925f870c59635912681bee947b1cb4b08cc19f22421b1a10ab","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xb83a48ee322989a0a4f838cb207abc28ec021b73","gas":"0x3270b","gasPrice":"0x991ff257","maxFeePerGas":"0x5c3362b9c","maxPriorityFeePerGas":"0x59682f00","hash":"0xef47a60f57f177a683c723c658137efab66d311e1c5abbc4d74f653535144d03","input":"0xa4110dbe18eba3e815ec7fcb03a8eea0487209c3253024d1dc4f36f775a43fdd3e409b74c0a5c88e54f39b88db6f185a41431b204120d3e66c9b08b86f5e8382623327e5","nonce":"0x12f","to":"0x96e6192eeaf7bb308f79fb5017a9085754b9e12a","transactionIndex":"0x8","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x4d7e11fe3914763a2735493a62b71ae0028e75a750a8b06407996cf478e273c8","s":"0x60c18fdf948721f96fdc2efbf694910122e82191c7a40a5caab247c06ab7f3cf","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x7712a1f96b3f37c3dd88a22d4f7a7977b937fe62","gas":"0x1ff06","gasPrice":"0x991ff257","maxFeePerGas":"0xcf662006","maxPriorityFeePerGas":"0x59682f00","hash":"0xe23a5b35faae5335adc5aca38c5d633b00438b798c2053104b8df48406c9b141","input":"0x3ff9751b0000000000000000000000000000000000000000000000000000000000000034000000000000000000000000000000000000000000000000000000000000003500000000000000000000000000000000000000000000000000000000000000a000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000160000000000000000000000000000000000000000000000000000000000000002e516d566e75374a51566f445271536748427a72615970374879373848774a744c4669366e5546436f775447647a70000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002e516d5439716b3343525962464457704446596541763854384831676e6f6e67774b6868354a36384e4c6b4c6972360000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000041c9f31b989aaa745aecc563139f89c8ab3ab492e725d1e0305b7d602fcbf9293c463f0d2e4f5fb0c9efb54eb2cde9af10ebc9c3676f2334007291ffa8efb40adb1c00000000000000000000000000000000000000000000000000000000000000","nonce":"0x16","to":"0xc3b87ea584cb9cb5a4523e2bed16a34bf7746317","transactionIndex":"0x9","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xcc693a9544394653e1f393f02635e2c1f78b5e6c26c4d00a867bcf4adc2bc09e","s":"0x23f4b71b773c19f77cf251b2aeea03f2696bddd847d1f6d75acd2fbea6a543e4","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x12bbafcfa06423d87bed591a64c1a1f34791e90a","gas":"0x1b2e020","gasPrice":"0x8f0d3617","maxFeePerGas":"0x1cb3abd5a","maxPriorityFeePerGas":"0x4f5572c0","hash":"0xd8cea4ba619b317bc05d58534af73beec6c2548b31b24d4dc61c9bbd29cfa17a","input":"0x","nonce":"0x4d","to":"0x12bbafcfa06423d87bed591a64c1a1f34791e90a","transactionIndex":"0xa","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x8dae28608985d6ab47cbe122ee88972e38664cede30978f41944f347bad86e5c","s":"0x17c2898b39b7e3b874dc78e7df3fcff68f4d715385c632aad4bdf6e62505651c","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x6999c36394dd5d3d3295af63a4736ad6bd279448","gas":"0x14d94","gasPrice":"0x7b528d57","maxFeePerGas":"0x7df743e0","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x79a4b9d90b02c768baaad305f266281213cc75062cbe99a13222cc0c4b509498","input":"0x6a7612020000000000000000000000009008d19f58aabd9ed0d60971565aa8510560ab4100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000140000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000022000000000000000000000000000000000000000000000000000000000000000a4ec6cb13f00000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000003826d8d7371becafc0afedc3fe85b699b87f4357d55ec39ce83c510ed7d70ff514dce8236351f4627ccec6a7d9a67bc6fc2ec17ca76411113c00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000410000000000000000000000006999c36394dd5d3d3295af63a4736ad6bd27944800000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000","nonce":"0x13","to":"0xdce8236351f4627ccec6a7d9a67bc6fc2ec17ca7","transactionIndex":"0xb","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x669487011643510f7512ec15b07d74efb853ba4ad9fe9c7e9850ccf24e3d4c53","s":"0x2191f9ee81087e1df833e69d6129ec330ed4c99be2031060834e22c589fcf79b","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x08ebc052e6353b4d8392113f0f2c5decd691ddcd","gas":"0x1b2e020","gasPrice":"0x7b528d57","maxFeePerGas":"0xf6e4d9c4","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x6790a3bbddbeb21fcb736a59b3775755051c3a6344d8390cf8ca27f2e8a814f0","input":"0x6871ee40","nonce":"0x4","to":"0xb21b333c40354393f18de57f2d0a0fc21f270482","transactionIndex":"0xc","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xa7a58ab858e5dd87b9a74d550e5716ac40ddefd1c21d5baa51e542f4f941d73e","s":"0x1fd0cb1563df0368bd332717d7c8210187cd1ac2ff44f61f5242fc02eaa0c2fe","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x08ebc052e6353b4d8392113f0f2c5decd691ddcd","gas":"0x12c36","gasPrice":"0x7b528d57","maxFeePerGas":"0xe596c292","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x87ec7ace5442db252b5751ffddd38dcb04b088d36b6b0e526ff25607a4293c81","input":"0xcb40cbfd","nonce":"0x5","to":"0xb21b333c40354393f18de57f2d0a0fc21f270482","transactionIndex":"0xd","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x8e4bd40195bdfaa868af97dbf22e0b74295d95564a8381bc9bcfe1af3cde2cdb","s":"0x62057dc87c8b2b197d12c648233aab4134b7c2a2f65db89a49728564f3d0864d","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x08ebc052e6353b4d8392113f0f2c5decd691ddcd","gas":"0x12c36","gasPrice":"0x7b528d57","maxFeePerGas":"0xe596c292","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x40cb487ecffda94f97ce7fc0f7163f2f024235df2c8291169edc80dac063e6d0","input":"0xcb40cbfd","nonce":"0x6","to":"0xb21b333c40354393f18de57f2d0a0fc21f270482","transactionIndex":"0xe","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x993c4386ffc2bd63a48dd31cf5f65aa355cba3c063b08778b328d748937098e5","s":"0x203b1faf595628dd78e760bcc1740065625abb6cf00b1b17224e10fa6b424e43","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xafc7682751d3654f34958e3fb660971bf5918367","gas":"0x1b2e020","gasPrice":"0x7b528d57","maxFeePerGas":"0xefb40664","maxPriorityFeePerGas":"0x3b9aca00","hash":"0xb76bb3d88c9b30d927c45ccfcf8d5b0054411ac8501ad588822a7d04690cccf6","input":"0x40c10f19000000000000000000000000afc7682751d3654f34958e3fb660971bf59183670000000000000000000000000000000000000000000000008ac7230489e80000","nonce":"0x20","to":"0x84ced17d95f3ec7230baf4a369f1e624ae60090d","transactionIndex":"0xf","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x78e9d29c606f6a61a1428ed7326df05210d802c3061f3b469847cc461eb48025","s":"0x517afe5a21175f186233ae7a6c090cd33e028a77e5854e98eb2fa4c9284430e7","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x12bbafcfa06423d87bed591a64c1a1f34791e90a","gas":"0xcafe","gasPrice":"0x7b528d57","maxFeePerGas":"0x16ba45bce","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x798ebe823209869347c08bd81e04fbf60e9bdfe44b1cc923215182d0cf3d4edb","input":"0x40c10f1900000000000000000000000012bbafcfa06423d87bed591a64c1a1f34791e90a0000000000000000000000000000000000000000000000000000000000000032","nonce":"0x4e","to":"0xd25d682189afa7ed0c2811195b3f3d07616927bc","transactionIndex":"0x10","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xbe2aa95f4c32188c9ecbae97286ab983f7cc5a7017d46c404f8eb80b55e2dc13","s":"0x55d8968f509f51633f49260178941fd5a3db999e1995206348d7a3f05152b3d5","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x12bbafcfa06423d87bed591a64c1a1f34791e90a","gas":"0xcafe","gasPrice":"0x7b528d57","maxFeePerGas":"0xc6132c0c","maxPriorityFeePerGas":"0x3b9aca00","hash":"0xbe68a7e02725f799a65ebb069ccc83a014ac7c40e4119bf7c220a2f6ddfee295","input":"0x40c10f1900000000000000000000000012bbafcfa06423d87bed591a64c1a1f34791e90a0000000000000000000000000000000000000000000000000000000000000064","nonce":"0x4f","to":"0xd25d682189afa7ed0c2811195b3f3d07616927bc","transactionIndex":"0x11","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x1750ed45d0d2d048a61dcc3ff3e7ad0cbd395b77698c4f2eeb6baaea4c966d96","s":"0xe646e3a87b6dc50439468bcfd24cbf12a6f95b2762f1527c97a7d1b7f03530e","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xd0c0338baac9ce09c1d1caab88b4360507061e37","gas":"0x1b2e020","gasPrice":"0x7b528d57","maxFeePerGas":"0x1918167aa","maxPriorityFeePerGas":"0x3b9aca00","hash":"0xc90c3a72efe81331727fcce4b5bd4906066da314ca9a0b44023a6b09ea7e8114","input":"0x4e71d92d","nonce":"0xe7","to":"0x0137d796936e199b917b93118eb4e002508a48bd","transactionIndex":"0x12","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x22222ce8fe753082c8e5dc7478fa7b87db9c8d0fb070ebc88ab015db13fd6bb","s":"0x6dceadecf6f6a3ddc433a547dba6d5fcdfb7d006ce09eeae1c06c1828ef9fff9","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x8bd834cc1dd17d1a2f7eb6140c3dd5ab51d0f338","gas":"0x1b2e020","gasPrice":"0x7b528d57","maxFeePerGas":"0x1a4019792","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x619a6cbd43cde074d314c19623bd66d9fb1e13c158d7138775236f798dc1245e","input":"0x1da1db5e00000000000000000000000000000000000000000000000000001b5ec4ff740d","nonce":"0x10","to":"0xbad0009f7a8e796e3f975dc1d6ab3e3c237b857c","transactionIndex":"0x13","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x733c496e8c84f78d113bc8b5ad6d04a133bb10bbcecf0db93d97eeedfa3d984a","s":"0x6627c16aa7dea27db44c0f0641c30ffd544b9b9b1c299dc60611e1e01c714ee8","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x8bd834cc1dd17d1a2f7eb6140c3dd5ab51d0f338","gas":"0x11df0","gasPrice":"0x7b528d57","maxFeePerGas":"0x1d3fbccb8","maxPriorityFeePerGas":"0x3b9aca00","hash":"0xca5a56cd77b9e5b0e79020cc6346edf205bc11e901984d805125f28c2e6686e6","input":"0xd7c01032000000000000000000000000356f24c0f3187a6dcb949e4a60aa0a74a8a0327e0000000000000000000000000f8bacfae87aee49a2eec86df0c6b958ec3fd4fd0000000000000000000000000f8bacfae87aee49a2eec86df0c6b958ec3fd4fd","nonce":"0x11","to":"0xbad0009f7a8e796e3f975dc1d6ab3e3c237b857c","transactionIndex":"0x14","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x4aa872c1a7da70126917604193717575b91407f82449bca956d4089b90cd902","s":"0x4b5f788c68024f8958f66e8c768a8e0f65ef297c4ffd420a715258b0a55cb0a0","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x9bedd66b05712a1add7d1fec899b8641b3ecc863","gas":"0x1b2e020","gasPrice":"0x7b528d57","maxFeePerGas":"0x1e706c8d2","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x999c9ddeed67c6ef6fbf02a6e977a6c1b68e18d24814e51643c7157b87a43e0a","input":"0xa8b78ed0","nonce":"0x3","to":"0xf6c2afb18b85175e5ffb28f20f007c047ce28592","transactionIndex":"0x15","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xf1ca074104ee0b6a67223afd797654b8f21060453f7662dd7be79de938c396da","s":"0x4c9a4e56f0ad21e2dd8d1116c7a3e41ea2c6126853772f7897bd959e81e2e28a","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x9bedd66b05712a1add7d1fec899b8641b3ecc863","gas":"0x2dc6c0","gasPrice":"0xd4babc57","maxFeePerGas":"0x21c13e710","maxPriorityFeePerGas":"0x9502f900","hash":"0x47c8f5d0b3778e4c34eba7fcc356fa04a5afd954ccf484728e72c002764dd3c4","input":"0xf688bcfb0000000000000000000000000000000000000000000000000000000005f5e100","nonce":"0x4","to":"0xf6c2afb18b85175e5ffb28f20f007c047ce28592","transactionIndex":"0x16","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x970982425d18b9949141bbabb5c5230fa168626ce210a97f3856d64700fc0eeb","s":"0x6fa6d0aea6ae48783d80c1e51cda47e11c28b90a5497579b93d7f242d786f67e","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x4b596cebd02c35aa99878eb9ecb24d6f5ca5f865","gas":"0x5208","gasPrice":"0x68c88f79","maxFeePerGas":"0x68c88f79","maxPriorityFeePerGas":"0x68c88f79","hash":"0x396797ae0ebcdb72ff1f96fd08b6128f78acc7417353f142f1a5facd425a33e6","input":"0x","nonce":"0x1","to":"0x375980b8e1a417620ba9b18e5a9e0b17dccbac9d","transactionIndex":"0x17","value":"0x1c9a406c58878","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xcb2a7b106097b2f2a61d3a048054a5175c386b1dcdd5b6fcd7849dcac7c32a66","s":"0x10aef76e98276c47470f04a599b81c260ace9d2f6adc95755c6d22d859e805a2","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x6f4aa3bc9732372daa288beb9b2516374ace5786","gas":"0x1b2e020","gasPrice":"0x61010bda","maxFeePerGas":"0x61010bda","maxPriorityFeePerGas":"0x61010bda","hash":"0x454aa43d6546a6f62246826c16b7a49c6c704238c18802ef0d659922f23a573c","input":"0xe99a3f8000000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000480000000000000000000000000000000000000000000000000000000000000050000000000000000000000000000000000000000000000000000000000000008a000000000000000000000000058ce7eb44ae575fb3b3974861c1138dad3c5aee40000000000000000000000000000000000000000000000000000000000000120000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001e06defd69964a6ce467b87c64627a7a2be4be139b504757c625eb6114ec166557d000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000641a269023d235ef0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002a000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000002b05699353b600008ae85d840000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000020000000000000000000000000b4fbf271143f4fbf7b91a5ded31805e42b2208d600000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000001f63c28250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000020000000000000000000000000def65f8e2f62bde60cd86ad3b4ad7fa6741cf17500000000000000000000000000000000000000000000000000000000000001400000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000020000000000000000000000006e512435020ac228a15543236b1f46656f98136300000000000000000000000000000000000000000000000000000000000000fa000000000000000000000000d6ffd79b52a587a0a9941a61f4e6cb0d386d5458000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000413e24433da3efc4c3cc305339a7b77a1b31abb4e4d4967e97e42aed1dd0bf98936f43035f40bc80f6f6e3a9cfb43524a1171ee7f21e9ac2fa586d33a31f10619d1c000000000000000000000000000000000000000000000000000000000000000000000000000000000000006f4aa3bc9732372daa288beb9b2516374ace5786000000000000000000000000000000000000000000000000000000000000012000000000000000000000000058ce7eb44ae575fb3b3974861c1138dad3c5aee400000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000641a269023d235ef0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002c00000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000173ad21460000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000040000000000000000000000000def65f8e2f62bde60cd86ad3b4ad7fa6741cf1750000000000000000000000000000000000000000000000000000000000000ba200000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000002b05699353b600008ae85d840000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000020000000000000000000000000b4fbf271143f4fbf7b91a5ded31805e42b2208d600000000000000000000000000000000000000000000000000000000000000c00000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000def65f8e2f62bde60cd86ad3b4ad7fa6741cf175ffffffff09616c6c64617461","nonce":"0x82","to":"0x02afbd43cad367fcb71305a2dfb9a3928218f0c1","transactionIndex":"0x18","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xc7ac308b1ae238cb2aa4b030ca79baffb7b498e1b10df0c3354b3cc19cfabac9","s":"0x2358b1093b9aab5fae0cf751766b0bb2e3d8cd2b18ca627e1e12520990a8ed6d","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x6ece61d29b90642941c41240da924690da145696","gas":"0x4399c","gasPrice":"0x506794e0","hash":"0x317ecb5bd19caa42a69f836d41556ebb0e0e00e1c6cd2dee230e6e6192612527","input":"0x46f83b5000000000000000000000000000000000000000000000000000000000000000654666803decc59e7d0a5d3efa3c3653c05645ef4342738445e20a3b43e0b4aa8b000000000000000000000000000000000000000000000000000000000000000f4666803decc59e7d0a5d3efa3c3653c05645ef4342738445e20a3b43e0b4aa8b","nonce":"0x2cc4","to":"0xa6bf2be6c60175601bf88217c75dd4b14abb5fbb","transactionIndex":"0x19","value":"0x0","type":"0x0","chainId":"0x5","v":"0x2d","r":"0x37aeab0db6d550e6cba2c04c9cb10a2af0fec0b11f6e04b85e1ea0b8b9defeae","s":"0x4f32f4ef74872e1385c25e69bf21ee049545a4d423e939eaff29677450efe9eb"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xc4a5c059840a146b81c77bf79f1398f2b3d28ca7","gas":"0x432ec","gasPrice":"0x45db0a51","hash":"0xc879285db5ef0a6bce98021584d16f134c1dc0aed8cc988802c4f72ba6877ff6","input":"0x9f8420b300000000000000000000000000000000000000000000000000470de4df8200000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x1a7","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x1a","value":"0x470efc4514e000","type":"0x0","chainId":"0x5","v":"0x2d","r":"0x237e3a541c5ab490843cdc20d0fcb7416bff8da471f6a11ae1b32d2bab119141","s":"0x3c8417d7a60bd5b0bcae4975dbb4aaee54a4b4d588226481be400843bfe2b64e"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x6f4aa3bc9732372daa288beb9b2516374ace5786","gas":"0xffff","gasPrice":"0x44e9acbc","maxFeePerGas":"0x44e9acbc","maxPriorityFeePerGas":"0x44e9acbc","hash":"0xecaa2d6f597608307e5084854854ba6dc1e69395e2abea14f2c6a2fa1d6faf9a","input":"0xe2864fe300000000000000000000000000000000000000000000000000000000000000200000000000000000000000006f4aa3bc9732372daa288beb9b2516374ace57860000000000000000000000000000000000000000000000000000000000000120000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002004a8312e37fcecd450e6684009a2b54bc64f66afbe5217c7b2f63b03cd9980a9e00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000064893e8223d235ef0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002a00000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000173ad21460000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000040000000000000000000000000def65f8e2f62bde60cd86ad3b4ad7fa6741cf175000000000000000000000000000000000000000000000000000000000000085000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000de0b6b3a7640000aaaebeba000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001400000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000020000000000000000000000006e512435020ac228a15543236b1f46656f98136300000000000000000000000000000000000000000000000000000000000000fa000000000000000000000000d6ffd79b52a587a0a9941a61f4e6cb0d386d54580000000000000000000000000000000000000000000000000000000000000000","nonce":"0x83","to":"0x02afbd43cad367fcb71305a2dfb9a3928218f0c1","transactionIndex":"0x1b","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xa18772e4b9e1493ebfd5ae6219cc9ca060b71e83788fb614ab02b03fb36eaf1b","s":"0x482c7e50fde29bb4130fd6e723176e0e9913430ebb9260667d7fb55f5408d9c5","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xdb33365a8730de2f7574ff1189fb9d337bf4c36d","gas":"0x61a80","gasPrice":"0x433653c8","maxFeePerGas":"0x828367af","maxPriorityFeePerGas":"0x37e9071","hash":"0x4dd69b69a568ff30ae439e2ded72fbd7f2e7aaa345836703663f155c749c5eed","input":"0x7f34c0ddc6e984f46ab7c13b7a53643096e79c39103dc74550204d5bd1b5206ef5a2f49689071bb6a332212df26aa57cd4d1e3c0894187a9fc5e5d686cbedba5b187470f000000000000000000000000000000000000000000000000000000000000000e000000000000000000000000e8c44c30e8e52c38ac7bd232e7b7f0c7463a535100000000000000000000000000000000000000000000000000000000000000a0000000000000000000000000000000000000000000000000000000000000002e516d5044645856613738437a6b7856325a364e52777a67685a785872736e75397261616a695a7555423569465a62000000000000000000000000000000000000","nonce":"0x2b57","to":"0xb8ad54644e2371cbb7940b9fa0936f399ba7495f","transactionIndex":"0x1c","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xa1fb0e5662b54ceb3dc1623ebfb200668433cb27252d553669bcd136387394f3","s":"0x27c2f8e19f69a52a0960f05d8b21f11c313dd3e86a7139b5783a18353c407415","yParity":"0x0"}],"transactionsRoot":"0x4a87d0cf5990b1c5bac631583e5965c2ba943858bebb2e07f74d0b697f73821a","uncles":[],"withdrawals":[null,{"index":"0x1171","validatorIndex":"0x38c2d","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6cd228e4"},{"index":"0x1172","validatorIndex":"0x38c2e","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x77f3431b"},{"index":"0x1173","validatorIndex":"0x38c2f","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6b61f268"},{"index":"0x1174","validatorIndex":"0x38c30","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6e10bb21"},{"index":"0x1175","validatorIndex":"0x38c31","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6eb115a5"},{"index":"0x1176","validatorIndex":"0x38c32","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x7caead1d"},{"index":"0x1177","validatorIndex":"0x38c33","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x772c0ddf"},{"index":"0x1178","validatorIndex":"0x38c34","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x75930a95"},{"index":"0x1179","validatorIndex":"0x38c35","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x76a4db09"},{"index":"0x117a","validatorIndex":"0x38c36","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x7e692b27"},{"index":"0x117b","validatorIndex":"0x38c37","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x72038ae6"},{"index":"0x117c","validatorIndex":"0x38c38","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6ccce352"},{"index":"0x117d","validatorIndex":"0x38c39","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x79ef6898"},{"index":"0x117e","validatorIndex":"0x38c3a","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6d58977d"},{"index":"0x117f","validatorIndex":"0x38c3b","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x76f7d208"}],"withdrawalsRoot":"0xaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"} diff --git a/op-service/sources/testdata/data/blocks/post-shanghai-bad-withdrawals-nil_metadata.json b/op-service/sources/testdata/data/blocks/post-shanghai-bad-withdrawals-nil_metadata.json new file mode 100644 index 0000000000000..284a5aa42de4b --- /dev/null +++ b/op-service/sources/testdata/data/blocks/post-shanghai-bad-withdrawals-nil_metadata.json @@ -0,0 +1 @@ +{"name":"post-shanghai-bad-withdrawals-nil","fail":true, "reason": "block withdrawal 0 is null"} diff --git a/op-service/sources/testdata/data/blocks/post-shanghai-bad-withdrawals_data.json b/op-service/sources/testdata/data/blocks/post-shanghai-bad-withdrawals_data.json new file mode 100644 index 0000000000000..6c5747e36701f --- /dev/null +++ b/op-service/sources/testdata/data/blocks/post-shanghai-bad-withdrawals_data.json @@ -0,0 +1 @@ +{"baseFeePerGas":"0x3fb7c357","difficulty":"0x0","extraData":"0x","gasLimit":"0x1c9c380","gasUsed":"0x18f759","hash":"0x808eada47015f4a265801a708c720cc5d7c7e051fdd7cd1e042777866b379a73","logsBloom":"0x020010404000001a0000021000000080001100410000100001000010040200980220400000008806200200000100000000000000000000008000000400042000000050000040000112080808800002044000040004042008800480002000000000000002020020000042002400000820000080040000000010200010020010100101212050000008000000008000001010200c80000112010000438040020400000000202400000000002002a0210402000622010000000001700144000040000000002204000000c000410105024010000808000000002004002000000261000000822200200800881000000012500400400000000000000040010000800000","miner":"0x000095e79eac4d76aab57cb2c1f091d553b36ca0","mixHash":"0x5b53dc49cbab268ef9950b1d81b5e36a1b2f1b97aee1b7ff6e4db0e06c29a8b0","nonce":"0x0000000000000000","number":"0x84161e","parentHash":"0x72d92c1498e05952988d4e79a695928a6bcbd37239f8a1734051263b4d3504b8","receiptsRoot":"0xaff90ae18dcc35924a4bddb68d403b8b7812c10c3ea2a114f34105c87d75bcdb","sha3Uncles":"0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347","size":"0x2a51","stateRoot":"0xc56738518b2c7854a640ae25996d2211c9ef0dd2e4dd9e59e9d9cacef39622da","timestamp":"0x64110a5c","totalDifficulty":"0xa4a470","transactions":[{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x1b7aa44088a0ea95bdc65fef6e5071e946bf7d8f","gas":"0x5208","gasPrice":"0x4159f01735","hash":"0x1e8f148a9aea7d8d16ea6e9446723b8f262e8bcd89c7c961d52046ebd43b4598","input":"0x","nonce":"0x279ad","to":"0xa21765a03dd41e2783696d314f235f4d520f6cac","transactionIndex":"0x0","value":"0x3782dace9d90000","type":"0x0","chainId":"0x5","v":"0x2e","r":"0xf9eca8b74ccaec5f4a83e981baeb8602f38d0271179c592b4a18f3866316a367","s":"0x350a9d26718d1fa9dc4f268f9c0e18fb96dbc037816ca8fc20f33f1a76f9f501"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x4d9a852e6aecd3a6e87fece2ca109780e45e6f2d","gas":"0x160ab","gasPrice":"0xd4babc57","maxFeePerGas":"0x11407d03e","maxPriorityFeePerGas":"0x9502f900","hash":"0xab5c870f4c367012bd763172afbfbe68fbf35336a66ae41aff3f2c9dbf4ea3f8","input":"0x60566037600b82828239805160001a607314602a57634e487b7160e01b600052600060045260246000fd5b30600052607381538281f3fe73000000000000000000000000000000000000000030146080604052600080fdfea26469706673582212200c479c99d58d7fbee5ee3aef5001431073a3d465bdfa46cf747a7c0b9289607864736f6c634300080d0033","nonce":"0xafd","to":null,"transactionIndex":"0x1","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x48f6acf4ac4371eb96ffca8cdef5b7704ea8c68a631d1c02927036d4ce92567e","s":"0x1f12261ddde63fd3da2ed9ea1bcbb4b0f25af898248c805a9d4b0a6e42caf9c8","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xce297b30e56bf2f6142c4048fbae1cb8a756fefd","gas":"0x557300","gasPrice":"0xd4babc57","maxFeePerGas":"0xfabdd183","maxPriorityFeePerGas":"0x9502f900","hash":"0xa81fd92b2d0f0bbd3cc355f869cca3243c98c5e2641db9ecf3eeabb3b13bff6a","input":"0x7bbaf1ea0000000000000000000000000000000000000000000000000000000000000005000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000000","nonce":"0xad92","to":"0x4c0ce02c1219ce5d2afffba97e484272a4637b49","transactionIndex":"0x2","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xd11b842a5f7b0e020470e764b443fafc4044327bca8dbb37131425359abace2","s":"0x1009867573946fb0a4a35339a6eaaece4d0a168b2346539076e6319e9a466b1","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x47a916d0b694c95bc0c09953c1a6e22c8867be32","gas":"0x5208","gasPrice":"0x991ff257","maxFeePerGas":"0xb2fea055","maxPriorityFeePerGas":"0x59682f00","hash":"0xa92c7b720c08c83f1a0ed7e4c163200e30a3a8c03fcc5a51e685ea20cd0cb577","input":"0x","nonce":"0x2","to":"0xf955dfe99bbfd06a8be208274cd654ecfb66a45e","transactionIndex":"0x3","value":"0x11c37937e08000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xeecd431225215c3ddc2e13cf16fa29f9a2ab1afbaa02988f3ceac27416edf0f5","s":"0x6494062330a9d509f7c778cb45cbcc9932e5f9b4ec94a1ec315f579f8d973b7b","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x672d214fe4db218defae698085a3ccefc773dfa9","gas":"0xf4f6","gasPrice":"0x991ff257","maxFeePerGas":"0xb2fea055","maxPriorityFeePerGas":"0x59682f00","hash":"0x6921b429ad2ec1e97d3457049ad2e893b5a0349beba47ca1c74a9540af75347a","input":"0xa1ddc546000000000000000000000000000000000000000000000000000000000000118f","nonce":"0x8e","to":"0xdef65f8e2f62bde60cd86ad3b4ad7fa6741cf175","transactionIndex":"0x4","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x4732ad21401b509bebb947a8566127fba1e245eb5a262ddc522d6867ab80567e","s":"0x2153013617fefdb06db0a7316d8883056441d33c2abf5ed6291fa0e3cc5c3a2f","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x0b12f7f996579fe7d9302d2574910121c214ee15","gas":"0x56a8","gasPrice":"0x991ff257","maxFeePerGas":"0xb2fea055","maxPriorityFeePerGas":"0x59682f00","hash":"0xf776b2da0b835dde05d0d8b76fd19385d61e7055036cf637f804b36dc94f2384","input":"0x71ec5c05aa669c4922569c1d33f7a81aaa21813800000000000000000000000013a0c5930c028511dc02665e7285134b6d11a5f40000000000000000000000000b12f7f996579fe7d9302d2574910121c214ee150000000000000000000000000000000000000000000000000000000000000000","nonce":"0xe","to":"0x7c125c1d515b8945841b3d5144a060115c58725f","transactionIndex":"0x5","value":"0x2386f26fc10000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xc4505d4c46ef9a0103178e5ef4fbc857114ae5c4686b68b74d07c3ee3a86e575","s":"0x74db34fd675bea7d2ee74f14fd8709cb88c7d22c2267d12f2c671b5ebc180bd5","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xd36aac0c9676e984d72823fb662ce94d3ab5e551","gas":"0xff212","gasPrice":"0x991ff257","maxFeePerGas":"0xd86d063e","maxPriorityFeePerGas":"0x59682f00","hash":"0x9a08d899cd14ebb930ed59fa774afdb88a22615b3a931e930931ea54d26dc0bc","input":"0x49160658babdf216946a22b96c966ceeba750f14807726306ebeed500a2621a7481df010000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000c0000000000000000000000000000000000000000000000000000000000000012000000000000000000000000000000000000000000000000000000000000000084d6f6f6e6265616d000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002a3078434133633746363939643335333137316438434643364236334431433764333841333233373238300000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0b616f73c8d00641109f0000054f967b8a135e44e233da070ea88c5e4a53bacac0000000000000000000000000000000000000000000000000000000000000002000000000000000000000000c6a3a17399d88e5dfd2de4fa41dcccade6a2d2170000000000000000000000008676147503f761e44b85df01811edd52be01b56c000000000000000000000000000000000000000000000000d02ab486cedc00000000000000000000000000000000000000000000000000000de0b6b3a7640000","nonce":"0x7121","to":"0x2d276bd64fe8643a1d76b2e9530c753423e972c1","transactionIndex":"0x6","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xce452361d331baf2ac86947a1b3b454b3e842923e1f39139b33a572845dd5d7c","s":"0x388126881782af5a146ce8409f1e3a2c9a4cadcfe9a2c1d27258af6e4eb5cec1","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xb83a48ee322989a0a4f838cb207abc28ec021b73","gas":"0x326ff","gasPrice":"0x991ff257","maxFeePerGas":"0x5c3362b9c","maxPriorityFeePerGas":"0x59682f00","hash":"0x0fe0d97e25d5eb11a33a3e8278584c3780941fc2675bdf8fc547cee3d1fd3b17","input":"0xa4110dbe190e65a7fe0ad5acd305c6446a02cb39de30f382000fe67927434063bf4c4b2ca86b3ee6d039dc7a0268f9e1c39266c3f12a752a7eb72f0895dedf62291fd292","nonce":"0x12e","to":"0x96e6192eeaf7bb308f79fb5017a9085754b9e12a","transactionIndex":"0x7","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x46819bb540fa459a5a0cbf041a0286507d597fc8958a6af8b9ce193f00005238","s":"0x31495c58bf4b74925f870c59635912681bee947b1cb4b08cc19f22421b1a10ab","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xb83a48ee322989a0a4f838cb207abc28ec021b73","gas":"0x3270b","gasPrice":"0x991ff257","maxFeePerGas":"0x5c3362b9c","maxPriorityFeePerGas":"0x59682f00","hash":"0xef47a60f57f177a683c723c658137efab66d311e1c5abbc4d74f653535144d03","input":"0xa4110dbe18eba3e815ec7fcb03a8eea0487209c3253024d1dc4f36f775a43fdd3e409b74c0a5c88e54f39b88db6f185a41431b204120d3e66c9b08b86f5e8382623327e5","nonce":"0x12f","to":"0x96e6192eeaf7bb308f79fb5017a9085754b9e12a","transactionIndex":"0x8","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x4d7e11fe3914763a2735493a62b71ae0028e75a750a8b06407996cf478e273c8","s":"0x60c18fdf948721f96fdc2efbf694910122e82191c7a40a5caab247c06ab7f3cf","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x7712a1f96b3f37c3dd88a22d4f7a7977b937fe62","gas":"0x1ff06","gasPrice":"0x991ff257","maxFeePerGas":"0xcf662006","maxPriorityFeePerGas":"0x59682f00","hash":"0xe23a5b35faae5335adc5aca38c5d633b00438b798c2053104b8df48406c9b141","input":"0x3ff9751b0000000000000000000000000000000000000000000000000000000000000034000000000000000000000000000000000000000000000000000000000000003500000000000000000000000000000000000000000000000000000000000000a000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000160000000000000000000000000000000000000000000000000000000000000002e516d566e75374a51566f445271536748427a72615970374879373848774a744c4669366e5546436f775447647a70000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002e516d5439716b3343525962464457704446596541763854384831676e6f6e67774b6868354a36384e4c6b4c6972360000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000041c9f31b989aaa745aecc563139f89c8ab3ab492e725d1e0305b7d602fcbf9293c463f0d2e4f5fb0c9efb54eb2cde9af10ebc9c3676f2334007291ffa8efb40adb1c00000000000000000000000000000000000000000000000000000000000000","nonce":"0x16","to":"0xc3b87ea584cb9cb5a4523e2bed16a34bf7746317","transactionIndex":"0x9","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xcc693a9544394653e1f393f02635e2c1f78b5e6c26c4d00a867bcf4adc2bc09e","s":"0x23f4b71b773c19f77cf251b2aeea03f2696bddd847d1f6d75acd2fbea6a543e4","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x12bbafcfa06423d87bed591a64c1a1f34791e90a","gas":"0x1b2e020","gasPrice":"0x8f0d3617","maxFeePerGas":"0x1cb3abd5a","maxPriorityFeePerGas":"0x4f5572c0","hash":"0xd8cea4ba619b317bc05d58534af73beec6c2548b31b24d4dc61c9bbd29cfa17a","input":"0x","nonce":"0x4d","to":"0x12bbafcfa06423d87bed591a64c1a1f34791e90a","transactionIndex":"0xa","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x8dae28608985d6ab47cbe122ee88972e38664cede30978f41944f347bad86e5c","s":"0x17c2898b39b7e3b874dc78e7df3fcff68f4d715385c632aad4bdf6e62505651c","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x6999c36394dd5d3d3295af63a4736ad6bd279448","gas":"0x14d94","gasPrice":"0x7b528d57","maxFeePerGas":"0x7df743e0","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x79a4b9d90b02c768baaad305f266281213cc75062cbe99a13222cc0c4b509498","input":"0x6a7612020000000000000000000000009008d19f58aabd9ed0d60971565aa8510560ab4100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000140000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000022000000000000000000000000000000000000000000000000000000000000000a4ec6cb13f00000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000003826d8d7371becafc0afedc3fe85b699b87f4357d55ec39ce83c510ed7d70ff514dce8236351f4627ccec6a7d9a67bc6fc2ec17ca76411113c00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000410000000000000000000000006999c36394dd5d3d3295af63a4736ad6bd27944800000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000","nonce":"0x13","to":"0xdce8236351f4627ccec6a7d9a67bc6fc2ec17ca7","transactionIndex":"0xb","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x669487011643510f7512ec15b07d74efb853ba4ad9fe9c7e9850ccf24e3d4c53","s":"0x2191f9ee81087e1df833e69d6129ec330ed4c99be2031060834e22c589fcf79b","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x08ebc052e6353b4d8392113f0f2c5decd691ddcd","gas":"0x1b2e020","gasPrice":"0x7b528d57","maxFeePerGas":"0xf6e4d9c4","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x6790a3bbddbeb21fcb736a59b3775755051c3a6344d8390cf8ca27f2e8a814f0","input":"0x6871ee40","nonce":"0x4","to":"0xb21b333c40354393f18de57f2d0a0fc21f270482","transactionIndex":"0xc","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xa7a58ab858e5dd87b9a74d550e5716ac40ddefd1c21d5baa51e542f4f941d73e","s":"0x1fd0cb1563df0368bd332717d7c8210187cd1ac2ff44f61f5242fc02eaa0c2fe","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x08ebc052e6353b4d8392113f0f2c5decd691ddcd","gas":"0x12c36","gasPrice":"0x7b528d57","maxFeePerGas":"0xe596c292","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x87ec7ace5442db252b5751ffddd38dcb04b088d36b6b0e526ff25607a4293c81","input":"0xcb40cbfd","nonce":"0x5","to":"0xb21b333c40354393f18de57f2d0a0fc21f270482","transactionIndex":"0xd","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x8e4bd40195bdfaa868af97dbf22e0b74295d95564a8381bc9bcfe1af3cde2cdb","s":"0x62057dc87c8b2b197d12c648233aab4134b7c2a2f65db89a49728564f3d0864d","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x08ebc052e6353b4d8392113f0f2c5decd691ddcd","gas":"0x12c36","gasPrice":"0x7b528d57","maxFeePerGas":"0xe596c292","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x40cb487ecffda94f97ce7fc0f7163f2f024235df2c8291169edc80dac063e6d0","input":"0xcb40cbfd","nonce":"0x6","to":"0xb21b333c40354393f18de57f2d0a0fc21f270482","transactionIndex":"0xe","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x993c4386ffc2bd63a48dd31cf5f65aa355cba3c063b08778b328d748937098e5","s":"0x203b1faf595628dd78e760bcc1740065625abb6cf00b1b17224e10fa6b424e43","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xafc7682751d3654f34958e3fb660971bf5918367","gas":"0x1b2e020","gasPrice":"0x7b528d57","maxFeePerGas":"0xefb40664","maxPriorityFeePerGas":"0x3b9aca00","hash":"0xb76bb3d88c9b30d927c45ccfcf8d5b0054411ac8501ad588822a7d04690cccf6","input":"0x40c10f19000000000000000000000000afc7682751d3654f34958e3fb660971bf59183670000000000000000000000000000000000000000000000008ac7230489e80000","nonce":"0x20","to":"0x84ced17d95f3ec7230baf4a369f1e624ae60090d","transactionIndex":"0xf","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x78e9d29c606f6a61a1428ed7326df05210d802c3061f3b469847cc461eb48025","s":"0x517afe5a21175f186233ae7a6c090cd33e028a77e5854e98eb2fa4c9284430e7","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x12bbafcfa06423d87bed591a64c1a1f34791e90a","gas":"0xcafe","gasPrice":"0x7b528d57","maxFeePerGas":"0x16ba45bce","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x798ebe823209869347c08bd81e04fbf60e9bdfe44b1cc923215182d0cf3d4edb","input":"0x40c10f1900000000000000000000000012bbafcfa06423d87bed591a64c1a1f34791e90a0000000000000000000000000000000000000000000000000000000000000032","nonce":"0x4e","to":"0xd25d682189afa7ed0c2811195b3f3d07616927bc","transactionIndex":"0x10","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xbe2aa95f4c32188c9ecbae97286ab983f7cc5a7017d46c404f8eb80b55e2dc13","s":"0x55d8968f509f51633f49260178941fd5a3db999e1995206348d7a3f05152b3d5","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x12bbafcfa06423d87bed591a64c1a1f34791e90a","gas":"0xcafe","gasPrice":"0x7b528d57","maxFeePerGas":"0xc6132c0c","maxPriorityFeePerGas":"0x3b9aca00","hash":"0xbe68a7e02725f799a65ebb069ccc83a014ac7c40e4119bf7c220a2f6ddfee295","input":"0x40c10f1900000000000000000000000012bbafcfa06423d87bed591a64c1a1f34791e90a0000000000000000000000000000000000000000000000000000000000000064","nonce":"0x4f","to":"0xd25d682189afa7ed0c2811195b3f3d07616927bc","transactionIndex":"0x11","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x1750ed45d0d2d048a61dcc3ff3e7ad0cbd395b77698c4f2eeb6baaea4c966d96","s":"0xe646e3a87b6dc50439468bcfd24cbf12a6f95b2762f1527c97a7d1b7f03530e","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xd0c0338baac9ce09c1d1caab88b4360507061e37","gas":"0x1b2e020","gasPrice":"0x7b528d57","maxFeePerGas":"0x1918167aa","maxPriorityFeePerGas":"0x3b9aca00","hash":"0xc90c3a72efe81331727fcce4b5bd4906066da314ca9a0b44023a6b09ea7e8114","input":"0x4e71d92d","nonce":"0xe7","to":"0x0137d796936e199b917b93118eb4e002508a48bd","transactionIndex":"0x12","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x22222ce8fe753082c8e5dc7478fa7b87db9c8d0fb070ebc88ab015db13fd6bb","s":"0x6dceadecf6f6a3ddc433a547dba6d5fcdfb7d006ce09eeae1c06c1828ef9fff9","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x8bd834cc1dd17d1a2f7eb6140c3dd5ab51d0f338","gas":"0x1b2e020","gasPrice":"0x7b528d57","maxFeePerGas":"0x1a4019792","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x619a6cbd43cde074d314c19623bd66d9fb1e13c158d7138775236f798dc1245e","input":"0x1da1db5e00000000000000000000000000000000000000000000000000001b5ec4ff740d","nonce":"0x10","to":"0xbad0009f7a8e796e3f975dc1d6ab3e3c237b857c","transactionIndex":"0x13","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x733c496e8c84f78d113bc8b5ad6d04a133bb10bbcecf0db93d97eeedfa3d984a","s":"0x6627c16aa7dea27db44c0f0641c30ffd544b9b9b1c299dc60611e1e01c714ee8","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x8bd834cc1dd17d1a2f7eb6140c3dd5ab51d0f338","gas":"0x11df0","gasPrice":"0x7b528d57","maxFeePerGas":"0x1d3fbccb8","maxPriorityFeePerGas":"0x3b9aca00","hash":"0xca5a56cd77b9e5b0e79020cc6346edf205bc11e901984d805125f28c2e6686e6","input":"0xd7c01032000000000000000000000000356f24c0f3187a6dcb949e4a60aa0a74a8a0327e0000000000000000000000000f8bacfae87aee49a2eec86df0c6b958ec3fd4fd0000000000000000000000000f8bacfae87aee49a2eec86df0c6b958ec3fd4fd","nonce":"0x11","to":"0xbad0009f7a8e796e3f975dc1d6ab3e3c237b857c","transactionIndex":"0x14","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x4aa872c1a7da70126917604193717575b91407f82449bca956d4089b90cd902","s":"0x4b5f788c68024f8958f66e8c768a8e0f65ef297c4ffd420a715258b0a55cb0a0","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x9bedd66b05712a1add7d1fec899b8641b3ecc863","gas":"0x1b2e020","gasPrice":"0x7b528d57","maxFeePerGas":"0x1e706c8d2","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x999c9ddeed67c6ef6fbf02a6e977a6c1b68e18d24814e51643c7157b87a43e0a","input":"0xa8b78ed0","nonce":"0x3","to":"0xf6c2afb18b85175e5ffb28f20f007c047ce28592","transactionIndex":"0x15","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xf1ca074104ee0b6a67223afd797654b8f21060453f7662dd7be79de938c396da","s":"0x4c9a4e56f0ad21e2dd8d1116c7a3e41ea2c6126853772f7897bd959e81e2e28a","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x9bedd66b05712a1add7d1fec899b8641b3ecc863","gas":"0x2dc6c0","gasPrice":"0xd4babc57","maxFeePerGas":"0x21c13e710","maxPriorityFeePerGas":"0x9502f900","hash":"0x47c8f5d0b3778e4c34eba7fcc356fa04a5afd954ccf484728e72c002764dd3c4","input":"0xf688bcfb0000000000000000000000000000000000000000000000000000000005f5e100","nonce":"0x4","to":"0xf6c2afb18b85175e5ffb28f20f007c047ce28592","transactionIndex":"0x16","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x970982425d18b9949141bbabb5c5230fa168626ce210a97f3856d64700fc0eeb","s":"0x6fa6d0aea6ae48783d80c1e51cda47e11c28b90a5497579b93d7f242d786f67e","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x4b596cebd02c35aa99878eb9ecb24d6f5ca5f865","gas":"0x5208","gasPrice":"0x68c88f79","maxFeePerGas":"0x68c88f79","maxPriorityFeePerGas":"0x68c88f79","hash":"0x396797ae0ebcdb72ff1f96fd08b6128f78acc7417353f142f1a5facd425a33e6","input":"0x","nonce":"0x1","to":"0x375980b8e1a417620ba9b18e5a9e0b17dccbac9d","transactionIndex":"0x17","value":"0x1c9a406c58878","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xcb2a7b106097b2f2a61d3a048054a5175c386b1dcdd5b6fcd7849dcac7c32a66","s":"0x10aef76e98276c47470f04a599b81c260ace9d2f6adc95755c6d22d859e805a2","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x6f4aa3bc9732372daa288beb9b2516374ace5786","gas":"0x1b2e020","gasPrice":"0x61010bda","maxFeePerGas":"0x61010bda","maxPriorityFeePerGas":"0x61010bda","hash":"0x454aa43d6546a6f62246826c16b7a49c6c704238c18802ef0d659922f23a573c","input":"0xe99a3f8000000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000480000000000000000000000000000000000000000000000000000000000000050000000000000000000000000000000000000000000000000000000000000008a000000000000000000000000058ce7eb44ae575fb3b3974861c1138dad3c5aee40000000000000000000000000000000000000000000000000000000000000120000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001e06defd69964a6ce467b87c64627a7a2be4be139b504757c625eb6114ec166557d000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000641a269023d235ef0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002a000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000002b05699353b600008ae85d840000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000020000000000000000000000000b4fbf271143f4fbf7b91a5ded31805e42b2208d600000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000001f63c28250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000020000000000000000000000000def65f8e2f62bde60cd86ad3b4ad7fa6741cf17500000000000000000000000000000000000000000000000000000000000001400000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000020000000000000000000000006e512435020ac228a15543236b1f46656f98136300000000000000000000000000000000000000000000000000000000000000fa000000000000000000000000d6ffd79b52a587a0a9941a61f4e6cb0d386d5458000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000413e24433da3efc4c3cc305339a7b77a1b31abb4e4d4967e97e42aed1dd0bf98936f43035f40bc80f6f6e3a9cfb43524a1171ee7f21e9ac2fa586d33a31f10619d1c000000000000000000000000000000000000000000000000000000000000000000000000000000000000006f4aa3bc9732372daa288beb9b2516374ace5786000000000000000000000000000000000000000000000000000000000000012000000000000000000000000058ce7eb44ae575fb3b3974861c1138dad3c5aee400000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000641a269023d235ef0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002c00000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000173ad21460000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000040000000000000000000000000def65f8e2f62bde60cd86ad3b4ad7fa6741cf1750000000000000000000000000000000000000000000000000000000000000ba200000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000002b05699353b600008ae85d840000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000020000000000000000000000000b4fbf271143f4fbf7b91a5ded31805e42b2208d600000000000000000000000000000000000000000000000000000000000000c00000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000def65f8e2f62bde60cd86ad3b4ad7fa6741cf175ffffffff09616c6c64617461","nonce":"0x82","to":"0x02afbd43cad367fcb71305a2dfb9a3928218f0c1","transactionIndex":"0x18","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xc7ac308b1ae238cb2aa4b030ca79baffb7b498e1b10df0c3354b3cc19cfabac9","s":"0x2358b1093b9aab5fae0cf751766b0bb2e3d8cd2b18ca627e1e12520990a8ed6d","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x6ece61d29b90642941c41240da924690da145696","gas":"0x4399c","gasPrice":"0x506794e0","hash":"0x317ecb5bd19caa42a69f836d41556ebb0e0e00e1c6cd2dee230e6e6192612527","input":"0x46f83b5000000000000000000000000000000000000000000000000000000000000000654666803decc59e7d0a5d3efa3c3653c05645ef4342738445e20a3b43e0b4aa8b000000000000000000000000000000000000000000000000000000000000000f4666803decc59e7d0a5d3efa3c3653c05645ef4342738445e20a3b43e0b4aa8b","nonce":"0x2cc4","to":"0xa6bf2be6c60175601bf88217c75dd4b14abb5fbb","transactionIndex":"0x19","value":"0x0","type":"0x0","chainId":"0x5","v":"0x2d","r":"0x37aeab0db6d550e6cba2c04c9cb10a2af0fec0b11f6e04b85e1ea0b8b9defeae","s":"0x4f32f4ef74872e1385c25e69bf21ee049545a4d423e939eaff29677450efe9eb"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xc4a5c059840a146b81c77bf79f1398f2b3d28ca7","gas":"0x432ec","gasPrice":"0x45db0a51","hash":"0xc879285db5ef0a6bce98021584d16f134c1dc0aed8cc988802c4f72ba6877ff6","input":"0x9f8420b300000000000000000000000000000000000000000000000000470de4df8200000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x1a7","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x1a","value":"0x470efc4514e000","type":"0x0","chainId":"0x5","v":"0x2d","r":"0x237e3a541c5ab490843cdc20d0fcb7416bff8da471f6a11ae1b32d2bab119141","s":"0x3c8417d7a60bd5b0bcae4975dbb4aaee54a4b4d588226481be400843bfe2b64e"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x6f4aa3bc9732372daa288beb9b2516374ace5786","gas":"0xffff","gasPrice":"0x44e9acbc","maxFeePerGas":"0x44e9acbc","maxPriorityFeePerGas":"0x44e9acbc","hash":"0xecaa2d6f597608307e5084854854ba6dc1e69395e2abea14f2c6a2fa1d6faf9a","input":"0xe2864fe300000000000000000000000000000000000000000000000000000000000000200000000000000000000000006f4aa3bc9732372daa288beb9b2516374ace57860000000000000000000000000000000000000000000000000000000000000120000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002004a8312e37fcecd450e6684009a2b54bc64f66afbe5217c7b2f63b03cd9980a9e00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000064893e8223d235ef0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002a00000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000173ad21460000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000040000000000000000000000000def65f8e2f62bde60cd86ad3b4ad7fa6741cf175000000000000000000000000000000000000000000000000000000000000085000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000de0b6b3a7640000aaaebeba000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001400000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000020000000000000000000000006e512435020ac228a15543236b1f46656f98136300000000000000000000000000000000000000000000000000000000000000fa000000000000000000000000d6ffd79b52a587a0a9941a61f4e6cb0d386d54580000000000000000000000000000000000000000000000000000000000000000","nonce":"0x83","to":"0x02afbd43cad367fcb71305a2dfb9a3928218f0c1","transactionIndex":"0x1b","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xa18772e4b9e1493ebfd5ae6219cc9ca060b71e83788fb614ab02b03fb36eaf1b","s":"0x482c7e50fde29bb4130fd6e723176e0e9913430ebb9260667d7fb55f5408d9c5","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xdb33365a8730de2f7574ff1189fb9d337bf4c36d","gas":"0x61a80","gasPrice":"0x433653c8","maxFeePerGas":"0x828367af","maxPriorityFeePerGas":"0x37e9071","hash":"0x4dd69b69a568ff30ae439e2ded72fbd7f2e7aaa345836703663f155c749c5eed","input":"0x7f34c0ddc6e984f46ab7c13b7a53643096e79c39103dc74550204d5bd1b5206ef5a2f49689071bb6a332212df26aa57cd4d1e3c0894187a9fc5e5d686cbedba5b187470f000000000000000000000000000000000000000000000000000000000000000e000000000000000000000000e8c44c30e8e52c38ac7bd232e7b7f0c7463a535100000000000000000000000000000000000000000000000000000000000000a0000000000000000000000000000000000000000000000000000000000000002e516d5044645856613738437a6b7856325a364e52777a67685a785872736e75397261616a695a7555423569465a62000000000000000000000000000000000000","nonce":"0x2b57","to":"0xb8ad54644e2371cbb7940b9fa0936f399ba7495f","transactionIndex":"0x1c","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xa1fb0e5662b54ceb3dc1623ebfb200668433cb27252d553669bcd136387394f3","s":"0x27c2f8e19f69a52a0960f05d8b21f11c313dd3e86a7139b5783a18353c407415","yParity":"0x0"}],"transactionsRoot":"0x4a87d0cf5990b1c5bac631583e5965c2ba943858bebb2e07f74d0b697f73821a","uncles":[],"withdrawals":[{"index":"0x1170","validatorIndex":"0x38c2c","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x66edfd65"},{"index":"0x1171","validatorIndex":"0x38c2d","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6cd228e4"},{"index":"0x1172","validatorIndex":"0x38c2e","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x77f3431b"},{"index":"0x1173","validatorIndex":"0x38c2f","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6b61f268"},{"index":"0x1174","validatorIndex":"0x38c30","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6e10bb21"},{"index":"0x1175","validatorIndex":"0x38c31","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6eb115a5"},{"index":"0x1176","validatorIndex":"0x38c32","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x7caead1d"},{"index":"0x1177","validatorIndex":"0x38c33","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x772c0ddf"},{"index":"0x1178","validatorIndex":"0x38c34","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x75930a95"},{"index":"0x1179","validatorIndex":"0x38c35","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x76a4db09"},{"index":"0x117a","validatorIndex":"0x38c36","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x7e692b27"},{"index":"0x117b","validatorIndex":"0x38c37","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x72038ae6"},{"index":"0x117c","validatorIndex":"0x38c38","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6ccce352"},{"index":"0x117d","validatorIndex":"0x38c39","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x79ef6898"},{"index":"0x117e","validatorIndex":"0x38c3a","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6d58977d"},{"index":"0x117f","validatorIndex":"0x38c3b","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x76f7d208"}],"withdrawalsRoot":"0xaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"} diff --git a/op-service/sources/testdata/data/blocks/post-shanghai-bad-withdrawals_metadata.json b/op-service/sources/testdata/data/blocks/post-shanghai-bad-withdrawals_metadata.json new file mode 100644 index 0000000000000..8dc2a01f6faea --- /dev/null +++ b/op-service/sources/testdata/data/blocks/post-shanghai-bad-withdrawals_metadata.json @@ -0,0 +1 @@ +{"name":"post-shanghai-bad-withdrawals","fail":true,"reason": "failed to verify withdrawals list"} diff --git a/op-service/sources/testdata/data/blocks/post-shanghai-success_data.json b/op-service/sources/testdata/data/blocks/post-shanghai-success_data.json new file mode 100644 index 0000000000000..fea85638547f0 --- /dev/null +++ b/op-service/sources/testdata/data/blocks/post-shanghai-success_data.json @@ -0,0 +1 @@ +{"baseFeePerGas":"0x3fb7c357","difficulty":"0x0","extraData":"0x","gasLimit":"0x1c9c380","gasUsed":"0x18f759","hash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","logsBloom":"0x020010404000001a0000021000000080001100410000100001000010040200980220400000008806200200000100000000000000000000008000000400042000000050000040000112080808800002044000040004042008800480002000000000000002020020000042002400000820000080040000000010200010020010100101212050000008000000008000001010200c80000112010000438040020400000000202400000000002002a0210402000622010000000001700144000040000000002204000000c000410105024010000808000000002004002000000261000000822200200800881000000012500400400000000000000040010000800000","miner":"0x000095e79eac4d76aab57cb2c1f091d553b36ca0","mixHash":"0x5b53dc49cbab268ef9950b1d81b5e36a1b2f1b97aee1b7ff6e4db0e06c29a8b0","nonce":"0x0000000000000000","number":"0x84161e","parentHash":"0x72d92c1498e05952988d4e79a695928a6bcbd37239f8a1734051263b4d3504b8","receiptsRoot":"0xaff90ae18dcc35924a4bddb68d403b8b7812c10c3ea2a114f34105c87d75bcdb","sha3Uncles":"0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347","size":"0x2a51","stateRoot":"0xc56738518b2c7854a640ae25996d2211c9ef0dd2e4dd9e59e9d9cacef39622da","timestamp":"0x64110a5c","totalDifficulty":"0xa4a470","transactions":[{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x1b7aa44088a0ea95bdc65fef6e5071e946bf7d8f","gas":"0x5208","gasPrice":"0x4159f01735","hash":"0x1e8f148a9aea7d8d16ea6e9446723b8f262e8bcd89c7c961d52046ebd43b4598","input":"0x","nonce":"0x279ad","to":"0xa21765a03dd41e2783696d314f235f4d520f6cac","transactionIndex":"0x0","value":"0x3782dace9d90000","type":"0x0","chainId":"0x5","v":"0x2e","r":"0xf9eca8b74ccaec5f4a83e981baeb8602f38d0271179c592b4a18f3866316a367","s":"0x350a9d26718d1fa9dc4f268f9c0e18fb96dbc037816ca8fc20f33f1a76f9f501"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x4d9a852e6aecd3a6e87fece2ca109780e45e6f2d","gas":"0x160ab","gasPrice":"0xd4babc57","maxFeePerGas":"0x11407d03e","maxPriorityFeePerGas":"0x9502f900","hash":"0xab5c870f4c367012bd763172afbfbe68fbf35336a66ae41aff3f2c9dbf4ea3f8","input":"0x60566037600b82828239805160001a607314602a57634e487b7160e01b600052600060045260246000fd5b30600052607381538281f3fe73000000000000000000000000000000000000000030146080604052600080fdfea26469706673582212200c479c99d58d7fbee5ee3aef5001431073a3d465bdfa46cf747a7c0b9289607864736f6c634300080d0033","nonce":"0xafd","to":null,"transactionIndex":"0x1","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x48f6acf4ac4371eb96ffca8cdef5b7704ea8c68a631d1c02927036d4ce92567e","s":"0x1f12261ddde63fd3da2ed9ea1bcbb4b0f25af898248c805a9d4b0a6e42caf9c8","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xce297b30e56bf2f6142c4048fbae1cb8a756fefd","gas":"0x557300","gasPrice":"0xd4babc57","maxFeePerGas":"0xfabdd183","maxPriorityFeePerGas":"0x9502f900","hash":"0xa81fd92b2d0f0bbd3cc355f869cca3243c98c5e2641db9ecf3eeabb3b13bff6a","input":"0x7bbaf1ea0000000000000000000000000000000000000000000000000000000000000005000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000000","nonce":"0xad92","to":"0x4c0ce02c1219ce5d2afffba97e484272a4637b49","transactionIndex":"0x2","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xd11b842a5f7b0e020470e764b443fafc4044327bca8dbb37131425359abace2","s":"0x1009867573946fb0a4a35339a6eaaece4d0a168b2346539076e6319e9a466b1","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x47a916d0b694c95bc0c09953c1a6e22c8867be32","gas":"0x5208","gasPrice":"0x991ff257","maxFeePerGas":"0xb2fea055","maxPriorityFeePerGas":"0x59682f00","hash":"0xa92c7b720c08c83f1a0ed7e4c163200e30a3a8c03fcc5a51e685ea20cd0cb577","input":"0x","nonce":"0x2","to":"0xf955dfe99bbfd06a8be208274cd654ecfb66a45e","transactionIndex":"0x3","value":"0x11c37937e08000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xeecd431225215c3ddc2e13cf16fa29f9a2ab1afbaa02988f3ceac27416edf0f5","s":"0x6494062330a9d509f7c778cb45cbcc9932e5f9b4ec94a1ec315f579f8d973b7b","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x672d214fe4db218defae698085a3ccefc773dfa9","gas":"0xf4f6","gasPrice":"0x991ff257","maxFeePerGas":"0xb2fea055","maxPriorityFeePerGas":"0x59682f00","hash":"0x6921b429ad2ec1e97d3457049ad2e893b5a0349beba47ca1c74a9540af75347a","input":"0xa1ddc546000000000000000000000000000000000000000000000000000000000000118f","nonce":"0x8e","to":"0xdef65f8e2f62bde60cd86ad3b4ad7fa6741cf175","transactionIndex":"0x4","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x4732ad21401b509bebb947a8566127fba1e245eb5a262ddc522d6867ab80567e","s":"0x2153013617fefdb06db0a7316d8883056441d33c2abf5ed6291fa0e3cc5c3a2f","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x0b12f7f996579fe7d9302d2574910121c214ee15","gas":"0x56a8","gasPrice":"0x991ff257","maxFeePerGas":"0xb2fea055","maxPriorityFeePerGas":"0x59682f00","hash":"0xf776b2da0b835dde05d0d8b76fd19385d61e7055036cf637f804b36dc94f2384","input":"0x71ec5c05aa669c4922569c1d33f7a81aaa21813800000000000000000000000013a0c5930c028511dc02665e7285134b6d11a5f40000000000000000000000000b12f7f996579fe7d9302d2574910121c214ee150000000000000000000000000000000000000000000000000000000000000000","nonce":"0xe","to":"0x7c125c1d515b8945841b3d5144a060115c58725f","transactionIndex":"0x5","value":"0x2386f26fc10000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xc4505d4c46ef9a0103178e5ef4fbc857114ae5c4686b68b74d07c3ee3a86e575","s":"0x74db34fd675bea7d2ee74f14fd8709cb88c7d22c2267d12f2c671b5ebc180bd5","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xd36aac0c9676e984d72823fb662ce94d3ab5e551","gas":"0xff212","gasPrice":"0x991ff257","maxFeePerGas":"0xd86d063e","maxPriorityFeePerGas":"0x59682f00","hash":"0x9a08d899cd14ebb930ed59fa774afdb88a22615b3a931e930931ea54d26dc0bc","input":"0x49160658babdf216946a22b96c966ceeba750f14807726306ebeed500a2621a7481df010000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000c0000000000000000000000000000000000000000000000000000000000000012000000000000000000000000000000000000000000000000000000000000000084d6f6f6e6265616d000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002a3078434133633746363939643335333137316438434643364236334431433764333841333233373238300000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0b616f73c8d00641109f0000054f967b8a135e44e233da070ea88c5e4a53bacac0000000000000000000000000000000000000000000000000000000000000002000000000000000000000000c6a3a17399d88e5dfd2de4fa41dcccade6a2d2170000000000000000000000008676147503f761e44b85df01811edd52be01b56c000000000000000000000000000000000000000000000000d02ab486cedc00000000000000000000000000000000000000000000000000000de0b6b3a7640000","nonce":"0x7121","to":"0x2d276bd64fe8643a1d76b2e9530c753423e972c1","transactionIndex":"0x6","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xce452361d331baf2ac86947a1b3b454b3e842923e1f39139b33a572845dd5d7c","s":"0x388126881782af5a146ce8409f1e3a2c9a4cadcfe9a2c1d27258af6e4eb5cec1","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xb83a48ee322989a0a4f838cb207abc28ec021b73","gas":"0x326ff","gasPrice":"0x991ff257","maxFeePerGas":"0x5c3362b9c","maxPriorityFeePerGas":"0x59682f00","hash":"0x0fe0d97e25d5eb11a33a3e8278584c3780941fc2675bdf8fc547cee3d1fd3b17","input":"0xa4110dbe190e65a7fe0ad5acd305c6446a02cb39de30f382000fe67927434063bf4c4b2ca86b3ee6d039dc7a0268f9e1c39266c3f12a752a7eb72f0895dedf62291fd292","nonce":"0x12e","to":"0x96e6192eeaf7bb308f79fb5017a9085754b9e12a","transactionIndex":"0x7","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x46819bb540fa459a5a0cbf041a0286507d597fc8958a6af8b9ce193f00005238","s":"0x31495c58bf4b74925f870c59635912681bee947b1cb4b08cc19f22421b1a10ab","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xb83a48ee322989a0a4f838cb207abc28ec021b73","gas":"0x3270b","gasPrice":"0x991ff257","maxFeePerGas":"0x5c3362b9c","maxPriorityFeePerGas":"0x59682f00","hash":"0xef47a60f57f177a683c723c658137efab66d311e1c5abbc4d74f653535144d03","input":"0xa4110dbe18eba3e815ec7fcb03a8eea0487209c3253024d1dc4f36f775a43fdd3e409b74c0a5c88e54f39b88db6f185a41431b204120d3e66c9b08b86f5e8382623327e5","nonce":"0x12f","to":"0x96e6192eeaf7bb308f79fb5017a9085754b9e12a","transactionIndex":"0x8","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x4d7e11fe3914763a2735493a62b71ae0028e75a750a8b06407996cf478e273c8","s":"0x60c18fdf948721f96fdc2efbf694910122e82191c7a40a5caab247c06ab7f3cf","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x7712a1f96b3f37c3dd88a22d4f7a7977b937fe62","gas":"0x1ff06","gasPrice":"0x991ff257","maxFeePerGas":"0xcf662006","maxPriorityFeePerGas":"0x59682f00","hash":"0xe23a5b35faae5335adc5aca38c5d633b00438b798c2053104b8df48406c9b141","input":"0x3ff9751b0000000000000000000000000000000000000000000000000000000000000034000000000000000000000000000000000000000000000000000000000000003500000000000000000000000000000000000000000000000000000000000000a000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000160000000000000000000000000000000000000000000000000000000000000002e516d566e75374a51566f445271536748427a72615970374879373848774a744c4669366e5546436f775447647a70000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002e516d5439716b3343525962464457704446596541763854384831676e6f6e67774b6868354a36384e4c6b4c6972360000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000041c9f31b989aaa745aecc563139f89c8ab3ab492e725d1e0305b7d602fcbf9293c463f0d2e4f5fb0c9efb54eb2cde9af10ebc9c3676f2334007291ffa8efb40adb1c00000000000000000000000000000000000000000000000000000000000000","nonce":"0x16","to":"0xc3b87ea584cb9cb5a4523e2bed16a34bf7746317","transactionIndex":"0x9","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xcc693a9544394653e1f393f02635e2c1f78b5e6c26c4d00a867bcf4adc2bc09e","s":"0x23f4b71b773c19f77cf251b2aeea03f2696bddd847d1f6d75acd2fbea6a543e4","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x12bbafcfa06423d87bed591a64c1a1f34791e90a","gas":"0x1b2e020","gasPrice":"0x8f0d3617","maxFeePerGas":"0x1cb3abd5a","maxPriorityFeePerGas":"0x4f5572c0","hash":"0xd8cea4ba619b317bc05d58534af73beec6c2548b31b24d4dc61c9bbd29cfa17a","input":"0x","nonce":"0x4d","to":"0x12bbafcfa06423d87bed591a64c1a1f34791e90a","transactionIndex":"0xa","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x8dae28608985d6ab47cbe122ee88972e38664cede30978f41944f347bad86e5c","s":"0x17c2898b39b7e3b874dc78e7df3fcff68f4d715385c632aad4bdf6e62505651c","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x6999c36394dd5d3d3295af63a4736ad6bd279448","gas":"0x14d94","gasPrice":"0x7b528d57","maxFeePerGas":"0x7df743e0","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x79a4b9d90b02c768baaad305f266281213cc75062cbe99a13222cc0c4b509498","input":"0x6a7612020000000000000000000000009008d19f58aabd9ed0d60971565aa8510560ab4100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000140000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000022000000000000000000000000000000000000000000000000000000000000000a4ec6cb13f00000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000003826d8d7371becafc0afedc3fe85b699b87f4357d55ec39ce83c510ed7d70ff514dce8236351f4627ccec6a7d9a67bc6fc2ec17ca76411113c00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000410000000000000000000000006999c36394dd5d3d3295af63a4736ad6bd27944800000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000","nonce":"0x13","to":"0xdce8236351f4627ccec6a7d9a67bc6fc2ec17ca7","transactionIndex":"0xb","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x669487011643510f7512ec15b07d74efb853ba4ad9fe9c7e9850ccf24e3d4c53","s":"0x2191f9ee81087e1df833e69d6129ec330ed4c99be2031060834e22c589fcf79b","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x08ebc052e6353b4d8392113f0f2c5decd691ddcd","gas":"0x1b2e020","gasPrice":"0x7b528d57","maxFeePerGas":"0xf6e4d9c4","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x6790a3bbddbeb21fcb736a59b3775755051c3a6344d8390cf8ca27f2e8a814f0","input":"0x6871ee40","nonce":"0x4","to":"0xb21b333c40354393f18de57f2d0a0fc21f270482","transactionIndex":"0xc","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xa7a58ab858e5dd87b9a74d550e5716ac40ddefd1c21d5baa51e542f4f941d73e","s":"0x1fd0cb1563df0368bd332717d7c8210187cd1ac2ff44f61f5242fc02eaa0c2fe","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x08ebc052e6353b4d8392113f0f2c5decd691ddcd","gas":"0x12c36","gasPrice":"0x7b528d57","maxFeePerGas":"0xe596c292","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x87ec7ace5442db252b5751ffddd38dcb04b088d36b6b0e526ff25607a4293c81","input":"0xcb40cbfd","nonce":"0x5","to":"0xb21b333c40354393f18de57f2d0a0fc21f270482","transactionIndex":"0xd","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x8e4bd40195bdfaa868af97dbf22e0b74295d95564a8381bc9bcfe1af3cde2cdb","s":"0x62057dc87c8b2b197d12c648233aab4134b7c2a2f65db89a49728564f3d0864d","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x08ebc052e6353b4d8392113f0f2c5decd691ddcd","gas":"0x12c36","gasPrice":"0x7b528d57","maxFeePerGas":"0xe596c292","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x40cb487ecffda94f97ce7fc0f7163f2f024235df2c8291169edc80dac063e6d0","input":"0xcb40cbfd","nonce":"0x6","to":"0xb21b333c40354393f18de57f2d0a0fc21f270482","transactionIndex":"0xe","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x993c4386ffc2bd63a48dd31cf5f65aa355cba3c063b08778b328d748937098e5","s":"0x203b1faf595628dd78e760bcc1740065625abb6cf00b1b17224e10fa6b424e43","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xafc7682751d3654f34958e3fb660971bf5918367","gas":"0x1b2e020","gasPrice":"0x7b528d57","maxFeePerGas":"0xefb40664","maxPriorityFeePerGas":"0x3b9aca00","hash":"0xb76bb3d88c9b30d927c45ccfcf8d5b0054411ac8501ad588822a7d04690cccf6","input":"0x40c10f19000000000000000000000000afc7682751d3654f34958e3fb660971bf59183670000000000000000000000000000000000000000000000008ac7230489e80000","nonce":"0x20","to":"0x84ced17d95f3ec7230baf4a369f1e624ae60090d","transactionIndex":"0xf","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x78e9d29c606f6a61a1428ed7326df05210d802c3061f3b469847cc461eb48025","s":"0x517afe5a21175f186233ae7a6c090cd33e028a77e5854e98eb2fa4c9284430e7","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x12bbafcfa06423d87bed591a64c1a1f34791e90a","gas":"0xcafe","gasPrice":"0x7b528d57","maxFeePerGas":"0x16ba45bce","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x798ebe823209869347c08bd81e04fbf60e9bdfe44b1cc923215182d0cf3d4edb","input":"0x40c10f1900000000000000000000000012bbafcfa06423d87bed591a64c1a1f34791e90a0000000000000000000000000000000000000000000000000000000000000032","nonce":"0x4e","to":"0xd25d682189afa7ed0c2811195b3f3d07616927bc","transactionIndex":"0x10","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xbe2aa95f4c32188c9ecbae97286ab983f7cc5a7017d46c404f8eb80b55e2dc13","s":"0x55d8968f509f51633f49260178941fd5a3db999e1995206348d7a3f05152b3d5","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x12bbafcfa06423d87bed591a64c1a1f34791e90a","gas":"0xcafe","gasPrice":"0x7b528d57","maxFeePerGas":"0xc6132c0c","maxPriorityFeePerGas":"0x3b9aca00","hash":"0xbe68a7e02725f799a65ebb069ccc83a014ac7c40e4119bf7c220a2f6ddfee295","input":"0x40c10f1900000000000000000000000012bbafcfa06423d87bed591a64c1a1f34791e90a0000000000000000000000000000000000000000000000000000000000000064","nonce":"0x4f","to":"0xd25d682189afa7ed0c2811195b3f3d07616927bc","transactionIndex":"0x11","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x1750ed45d0d2d048a61dcc3ff3e7ad0cbd395b77698c4f2eeb6baaea4c966d96","s":"0xe646e3a87b6dc50439468bcfd24cbf12a6f95b2762f1527c97a7d1b7f03530e","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xd0c0338baac9ce09c1d1caab88b4360507061e37","gas":"0x1b2e020","gasPrice":"0x7b528d57","maxFeePerGas":"0x1918167aa","maxPriorityFeePerGas":"0x3b9aca00","hash":"0xc90c3a72efe81331727fcce4b5bd4906066da314ca9a0b44023a6b09ea7e8114","input":"0x4e71d92d","nonce":"0xe7","to":"0x0137d796936e199b917b93118eb4e002508a48bd","transactionIndex":"0x12","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x22222ce8fe753082c8e5dc7478fa7b87db9c8d0fb070ebc88ab015db13fd6bb","s":"0x6dceadecf6f6a3ddc433a547dba6d5fcdfb7d006ce09eeae1c06c1828ef9fff9","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x8bd834cc1dd17d1a2f7eb6140c3dd5ab51d0f338","gas":"0x1b2e020","gasPrice":"0x7b528d57","maxFeePerGas":"0x1a4019792","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x619a6cbd43cde074d314c19623bd66d9fb1e13c158d7138775236f798dc1245e","input":"0x1da1db5e00000000000000000000000000000000000000000000000000001b5ec4ff740d","nonce":"0x10","to":"0xbad0009f7a8e796e3f975dc1d6ab3e3c237b857c","transactionIndex":"0x13","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x733c496e8c84f78d113bc8b5ad6d04a133bb10bbcecf0db93d97eeedfa3d984a","s":"0x6627c16aa7dea27db44c0f0641c30ffd544b9b9b1c299dc60611e1e01c714ee8","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x8bd834cc1dd17d1a2f7eb6140c3dd5ab51d0f338","gas":"0x11df0","gasPrice":"0x7b528d57","maxFeePerGas":"0x1d3fbccb8","maxPriorityFeePerGas":"0x3b9aca00","hash":"0xca5a56cd77b9e5b0e79020cc6346edf205bc11e901984d805125f28c2e6686e6","input":"0xd7c01032000000000000000000000000356f24c0f3187a6dcb949e4a60aa0a74a8a0327e0000000000000000000000000f8bacfae87aee49a2eec86df0c6b958ec3fd4fd0000000000000000000000000f8bacfae87aee49a2eec86df0c6b958ec3fd4fd","nonce":"0x11","to":"0xbad0009f7a8e796e3f975dc1d6ab3e3c237b857c","transactionIndex":"0x14","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x4aa872c1a7da70126917604193717575b91407f82449bca956d4089b90cd902","s":"0x4b5f788c68024f8958f66e8c768a8e0f65ef297c4ffd420a715258b0a55cb0a0","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x9bedd66b05712a1add7d1fec899b8641b3ecc863","gas":"0x1b2e020","gasPrice":"0x7b528d57","maxFeePerGas":"0x1e706c8d2","maxPriorityFeePerGas":"0x3b9aca00","hash":"0x999c9ddeed67c6ef6fbf02a6e977a6c1b68e18d24814e51643c7157b87a43e0a","input":"0xa8b78ed0","nonce":"0x3","to":"0xf6c2afb18b85175e5ffb28f20f007c047ce28592","transactionIndex":"0x15","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xf1ca074104ee0b6a67223afd797654b8f21060453f7662dd7be79de938c396da","s":"0x4c9a4e56f0ad21e2dd8d1116c7a3e41ea2c6126853772f7897bd959e81e2e28a","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x9bedd66b05712a1add7d1fec899b8641b3ecc863","gas":"0x2dc6c0","gasPrice":"0xd4babc57","maxFeePerGas":"0x21c13e710","maxPriorityFeePerGas":"0x9502f900","hash":"0x47c8f5d0b3778e4c34eba7fcc356fa04a5afd954ccf484728e72c002764dd3c4","input":"0xf688bcfb0000000000000000000000000000000000000000000000000000000005f5e100","nonce":"0x4","to":"0xf6c2afb18b85175e5ffb28f20f007c047ce28592","transactionIndex":"0x16","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x970982425d18b9949141bbabb5c5230fa168626ce210a97f3856d64700fc0eeb","s":"0x6fa6d0aea6ae48783d80c1e51cda47e11c28b90a5497579b93d7f242d786f67e","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x4b596cebd02c35aa99878eb9ecb24d6f5ca5f865","gas":"0x5208","gasPrice":"0x68c88f79","maxFeePerGas":"0x68c88f79","maxPriorityFeePerGas":"0x68c88f79","hash":"0x396797ae0ebcdb72ff1f96fd08b6128f78acc7417353f142f1a5facd425a33e6","input":"0x","nonce":"0x1","to":"0x375980b8e1a417620ba9b18e5a9e0b17dccbac9d","transactionIndex":"0x17","value":"0x1c9a406c58878","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xcb2a7b106097b2f2a61d3a048054a5175c386b1dcdd5b6fcd7849dcac7c32a66","s":"0x10aef76e98276c47470f04a599b81c260ace9d2f6adc95755c6d22d859e805a2","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x6f4aa3bc9732372daa288beb9b2516374ace5786","gas":"0x1b2e020","gasPrice":"0x61010bda","maxFeePerGas":"0x61010bda","maxPriorityFeePerGas":"0x61010bda","hash":"0x454aa43d6546a6f62246826c16b7a49c6c704238c18802ef0d659922f23a573c","input":"0xe99a3f8000000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000480000000000000000000000000000000000000000000000000000000000000050000000000000000000000000000000000000000000000000000000000000008a000000000000000000000000058ce7eb44ae575fb3b3974861c1138dad3c5aee40000000000000000000000000000000000000000000000000000000000000120000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001e06defd69964a6ce467b87c64627a7a2be4be139b504757c625eb6114ec166557d000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000641a269023d235ef0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002a000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000002b05699353b600008ae85d840000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000020000000000000000000000000b4fbf271143f4fbf7b91a5ded31805e42b2208d600000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000001f63c28250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000020000000000000000000000000def65f8e2f62bde60cd86ad3b4ad7fa6741cf17500000000000000000000000000000000000000000000000000000000000001400000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000020000000000000000000000006e512435020ac228a15543236b1f46656f98136300000000000000000000000000000000000000000000000000000000000000fa000000000000000000000000d6ffd79b52a587a0a9941a61f4e6cb0d386d5458000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000413e24433da3efc4c3cc305339a7b77a1b31abb4e4d4967e97e42aed1dd0bf98936f43035f40bc80f6f6e3a9cfb43524a1171ee7f21e9ac2fa586d33a31f10619d1c000000000000000000000000000000000000000000000000000000000000000000000000000000000000006f4aa3bc9732372daa288beb9b2516374ace5786000000000000000000000000000000000000000000000000000000000000012000000000000000000000000058ce7eb44ae575fb3b3974861c1138dad3c5aee400000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000641a269023d235ef0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002c00000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000173ad21460000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000040000000000000000000000000def65f8e2f62bde60cd86ad3b4ad7fa6741cf1750000000000000000000000000000000000000000000000000000000000000ba200000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000002b05699353b600008ae85d840000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000020000000000000000000000000b4fbf271143f4fbf7b91a5ded31805e42b2208d600000000000000000000000000000000000000000000000000000000000000c00000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000def65f8e2f62bde60cd86ad3b4ad7fa6741cf175ffffffff09616c6c64617461","nonce":"0x82","to":"0x02afbd43cad367fcb71305a2dfb9a3928218f0c1","transactionIndex":"0x18","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xc7ac308b1ae238cb2aa4b030ca79baffb7b498e1b10df0c3354b3cc19cfabac9","s":"0x2358b1093b9aab5fae0cf751766b0bb2e3d8cd2b18ca627e1e12520990a8ed6d","yParity":"0x0"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x6ece61d29b90642941c41240da924690da145696","gas":"0x4399c","gasPrice":"0x506794e0","hash":"0x317ecb5bd19caa42a69f836d41556ebb0e0e00e1c6cd2dee230e6e6192612527","input":"0x46f83b5000000000000000000000000000000000000000000000000000000000000000654666803decc59e7d0a5d3efa3c3653c05645ef4342738445e20a3b43e0b4aa8b000000000000000000000000000000000000000000000000000000000000000f4666803decc59e7d0a5d3efa3c3653c05645ef4342738445e20a3b43e0b4aa8b","nonce":"0x2cc4","to":"0xa6bf2be6c60175601bf88217c75dd4b14abb5fbb","transactionIndex":"0x19","value":"0x0","type":"0x0","chainId":"0x5","v":"0x2d","r":"0x37aeab0db6d550e6cba2c04c9cb10a2af0fec0b11f6e04b85e1ea0b8b9defeae","s":"0x4f32f4ef74872e1385c25e69bf21ee049545a4d423e939eaff29677450efe9eb"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xc4a5c059840a146b81c77bf79f1398f2b3d28ca7","gas":"0x432ec","gasPrice":"0x45db0a51","hash":"0xc879285db5ef0a6bce98021584d16f134c1dc0aed8cc988802c4f72ba6877ff6","input":"0x9f8420b300000000000000000000000000000000000000000000000000470de4df8200000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x1a7","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x1a","value":"0x470efc4514e000","type":"0x0","chainId":"0x5","v":"0x2d","r":"0x237e3a541c5ab490843cdc20d0fcb7416bff8da471f6a11ae1b32d2bab119141","s":"0x3c8417d7a60bd5b0bcae4975dbb4aaee54a4b4d588226481be400843bfe2b64e"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0x6f4aa3bc9732372daa288beb9b2516374ace5786","gas":"0xffff","gasPrice":"0x44e9acbc","maxFeePerGas":"0x44e9acbc","maxPriorityFeePerGas":"0x44e9acbc","hash":"0xecaa2d6f597608307e5084854854ba6dc1e69395e2abea14f2c6a2fa1d6faf9a","input":"0xe2864fe300000000000000000000000000000000000000000000000000000000000000200000000000000000000000006f4aa3bc9732372daa288beb9b2516374ace57860000000000000000000000000000000000000000000000000000000000000120000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002004a8312e37fcecd450e6684009a2b54bc64f66afbe5217c7b2f63b03cd9980a9e00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000064893e8223d235ef0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002a00000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000173ad21460000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000040000000000000000000000000def65f8e2f62bde60cd86ad3b4ad7fa6741cf175000000000000000000000000000000000000000000000000000000000000085000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000de0b6b3a7640000aaaebeba000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001400000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000020000000000000000000000006e512435020ac228a15543236b1f46656f98136300000000000000000000000000000000000000000000000000000000000000fa000000000000000000000000d6ffd79b52a587a0a9941a61f4e6cb0d386d54580000000000000000000000000000000000000000000000000000000000000000","nonce":"0x83","to":"0x02afbd43cad367fcb71305a2dfb9a3928218f0c1","transactionIndex":"0x1b","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xa18772e4b9e1493ebfd5ae6219cc9ca060b71e83788fb614ab02b03fb36eaf1b","s":"0x482c7e50fde29bb4130fd6e723176e0e9913430ebb9260667d7fb55f5408d9c5","yParity":"0x1"},{"blockHash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","blockNumber":"0x84161e","from":"0xdb33365a8730de2f7574ff1189fb9d337bf4c36d","gas":"0x61a80","gasPrice":"0x433653c8","maxFeePerGas":"0x828367af","maxPriorityFeePerGas":"0x37e9071","hash":"0x4dd69b69a568ff30ae439e2ded72fbd7f2e7aaa345836703663f155c749c5eed","input":"0x7f34c0ddc6e984f46ab7c13b7a53643096e79c39103dc74550204d5bd1b5206ef5a2f49689071bb6a332212df26aa57cd4d1e3c0894187a9fc5e5d686cbedba5b187470f000000000000000000000000000000000000000000000000000000000000000e000000000000000000000000e8c44c30e8e52c38ac7bd232e7b7f0c7463a535100000000000000000000000000000000000000000000000000000000000000a0000000000000000000000000000000000000000000000000000000000000002e516d5044645856613738437a6b7856325a364e52777a67685a785872736e75397261616a695a7555423569465a62000000000000000000000000000000000000","nonce":"0x2b57","to":"0xb8ad54644e2371cbb7940b9fa0936f399ba7495f","transactionIndex":"0x1c","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xa1fb0e5662b54ceb3dc1623ebfb200668433cb27252d553669bcd136387394f3","s":"0x27c2f8e19f69a52a0960f05d8b21f11c313dd3e86a7139b5783a18353c407415","yParity":"0x0"}],"transactionsRoot":"0x4a87d0cf5990b1c5bac631583e5965c2ba943858bebb2e07f74d0b697f73821a","uncles":[],"withdrawals":[{"index":"0x1170","validatorIndex":"0x38c2c","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x66edfd65"},{"index":"0x1171","validatorIndex":"0x38c2d","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6cd228e4"},{"index":"0x1172","validatorIndex":"0x38c2e","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x77f3431b"},{"index":"0x1173","validatorIndex":"0x38c2f","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6b61f268"},{"index":"0x1174","validatorIndex":"0x38c30","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6e10bb21"},{"index":"0x1175","validatorIndex":"0x38c31","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6eb115a5"},{"index":"0x1176","validatorIndex":"0x38c32","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x7caead1d"},{"index":"0x1177","validatorIndex":"0x38c33","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x772c0ddf"},{"index":"0x1178","validatorIndex":"0x38c34","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x75930a95"},{"index":"0x1179","validatorIndex":"0x38c35","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x76a4db09"},{"index":"0x117a","validatorIndex":"0x38c36","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x7e692b27"},{"index":"0x117b","validatorIndex":"0x38c37","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x72038ae6"},{"index":"0x117c","validatorIndex":"0x38c38","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6ccce352"},{"index":"0x117d","validatorIndex":"0x38c39","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x79ef6898"},{"index":"0x117e","validatorIndex":"0x38c3a","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6d58977d"},{"index":"0x117f","validatorIndex":"0x38c3b","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x76f7d208"}],"withdrawalsRoot":"0xbe712c930a0665264b025ced87cc7839eef95a3cbc26dadc93e9e185a350ad28"} diff --git a/op-service/sources/testdata/data/blocks/post-shanghai-success_metadata.json b/op-service/sources/testdata/data/blocks/post-shanghai-success_metadata.json new file mode 100644 index 0000000000000..d6179c6587c35 --- /dev/null +++ b/op-service/sources/testdata/data/blocks/post-shanghai-success_metadata.json @@ -0,0 +1 @@ +{"name":"post-shanghai-success"} diff --git a/op-service/sources/testdata/data/blocks/pre-shanghai-bad-receipts-hash_data.json b/op-service/sources/testdata/data/blocks/pre-shanghai-bad-receipts-hash_data.json new file mode 100644 index 0000000000000..1d11d4b8465c0 --- /dev/null +++ b/op-service/sources/testdata/data/blocks/pre-shanghai-bad-receipts-hash_data.json @@ -0,0 +1 @@ +{"baseFeePerGas":"0x7ccf990f8","difficulty":"0x0","extraData":"0xd883010b02846765746888676f312e32302e31856c696e7578","gasLimit":"0x1c9c380","gasUsed":"0xa79638","hash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","logsBloom":"0xb034000008010014411408c080a0018440087220211154100005a1388807241142a2504080034a00111212a47f05008520200000280202a12800538cc06488486a0141989c7800c0c848011f02249661800e08449145b040a252d18082c009000641004052c80102000804ac10901c24032000980010438a01e50a90a0d8008c138c21204040000b20425000833041028000148124c2012d0aa8d1d0548301808228002015184090000224021040d68220100210220480420308455c382a40020130dc42502986080600000115034c0401c81828490410308005610048026b822e10b4228071ba00bdd20140621b2000c02012300808084181ac308200000011","miner":"0x0000000000000000000000000000000000000000","mixHash":"0x31f0c0305fc07a93b1a33da339c79aadbe8d9811c78d2b514cd18d64e1328f25","nonce":"0x0000000000000000","number":"0x840249","parentHash":"0x2303b55af4add799b19275a491b150c1a03075395f87a7856a4e3327595ed7df","receiptsRoot":"0xaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa","sha3Uncles":"0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347","size":"0xea6d","stateRoot":"0xd12bf4cf3941cf48be329a939b13d3403d326841c69cdcc9a9c13ab2f227e904","timestamp":"0x640fdeb0","totalDifficulty":"0xa4a470","transactions":[{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x1b7aa44088a0ea95bdc65fef6e5071e946bf7d8f","gas":"0x5208","gasPrice":"0x174876e800","hash":"0x39c666d9b5cec429accad7b0f94f789ca2ebeb5294b8b129c1b76f552daf57d3","input":"0x","nonce":"0x26bd1","to":"0x68643ada5885f14e7c15c13bee06168eff0f7c36","transactionIndex":"0x0","value":"0xb1a2bc2ec50000","type":"0x0","chainId":"0x5","v":"0x2e","r":"0x26e648625520c256d87d8e15769e8c4290d2a7e27147594815da42070870825b","s":"0x7db34c91603e51494b59b020597e7118433d50ed548bc7efad8880cbe7820ca"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x030b1cddf635e9e71ad70b8668e235e8ec3c67c4","gas":"0xf618","gasPrice":"0x1701ca2b9d","hash":"0x2ca7289ab3738d17e0f5093bd96c97c06c9a2ea4c22fc84a6a7fbfda93ce55ee","input":"0x","nonce":"0x456d","to":"0x89416096a0a1acad3436a357478c5c548e4d382b","transactionIndex":"0x1","value":"0x16345785d8a0000","type":"0x0","chainId":"0x5","v":"0x2e","r":"0x5aa6ad410ea42dbff3781de67b4815a376cd459206595fa6655c966a7709e5cb","s":"0x82f620f8dbc356dc38ef346d1e152656a1d318becbcc41884f61e85972355c0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x9c67435ce8a33ad23f377ddf08260ffc56417f21","gas":"0xf618","gasPrice":"0x1701ca2b9d","hash":"0xb0085de1476530de3efc6928c4683e7c40f8fac18875f74cbcc47df159de17d9","input":"0x","nonce":"0x446c","to":"0x471f3a988a77472e971112e7ff2ce65996b6c8cd","transactionIndex":"0x2","value":"0x2c68af0bb140000","type":"0x0","chainId":"0x5","v":"0x2d","r":"0x75425f21a6e66e6feaee79455c897656c4a94b6189c4c033facab1b67812fc3f","s":"0x7014f4b9f760165c7757f9d6dccea349b3d00b0a9c2f845af8010140842f826"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x168f6dec26cbbb3749654e0e3cc4fc29314fdf6c","gas":"0xf618","gasPrice":"0x1701ca2b9d","hash":"0xe01c8631c86ded63af95b8dbc0c8aac5d31254c14d6ecb4cc51d98259d838e52","input":"0x","nonce":"0x403c","to":"0xf2119a49a3ae35453c1c2704da248d08977084f1","transactionIndex":"0x3","value":"0x16345785d8a0000","type":"0x0","chainId":"0x5","v":"0x2e","r":"0x56bba57ee69c09dbbd5167d0fee07d5803130fea7c278f4d8b7bc54b34be8ff9","s":"0x7eea69c0de47b6b808ea1bdd9ecf5d25f4f2743e867b1f838db59c456026d7e6"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xc9af69904b4ba7f0fb69ab1a8719bd8950265e73","gas":"0xf618","gasPrice":"0x1701ca2b9d","hash":"0x69414a126a6f07ab5e31ad2f9069fb986b7c490e096898473873e41ece6af783","input":"0x","nonce":"0x44c20","to":"0x6adc3f5394e00cd067d1fad5a33756791e303c25","transactionIndex":"0x4","value":"0x16345785d8a0000","type":"0x0","chainId":"0x5","v":"0x2e","r":"0xdc9a52b87755cd07143bf032d57258d0d6c36500b38a574a9a5addc1293343da","s":"0x581e6fd051d0c72d64303c1f90edecfef46580f84f24dba930cde910923f7c21"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x92964e63cd52450e6e09a266e0c226e524754563","gas":"0x2625a0","gasPrice":"0xf5686c7be","hash":"0xa2fef1133ee726533c7f190f246fede123e3706a03933c1febc92618f90d2804","input":"0xa9059cbb00000000000000000000000011f7db5a824eaa5737c935ad09a925dd707f092b0000000000000000000000000000000000000000000000008ac7230489e80000","nonce":"0x2636","to":"0xbc071c64ed8f536011c78e847755680740d6b73c","transactionIndex":"0x5","value":"0x0","type":"0x0","chainId":"0x5","v":"0x2d","r":"0x422c5026584cd8fb8a1fe66e6edc7a020bc513cc3114083fb35f9846cd9a9792","s":"0x7fcd4e48ac5b53d881531a5651e587188157ed88d85c51533f7c6eda94c67ff7"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xdec1bc71bf91431d60ef2742f412dcd1c5a204b8","gas":"0x7a120","gasPrice":"0xb80e515ce","hash":"0x6585ec5c4c2bbf1f683f90f58e18f3b38d875e94457fe4cbb7bc5bf6581f83af","input":"0x67a5cd060000000000000000000000006343e96c99e2725e845ba04f90e03d853cc9bb2d","nonce":"0x6a5a4","to":"0xf5de760f2e916647fd766b4ad9e85ff943ce3a2b","transactionIndex":"0x6","value":"0x0","type":"0x0","chainId":"0x5","v":"0x2d","r":"0xcb7b32949ac0dedd3151d06d85ec4e99483c8ea706f12a009d97b055975241eb","s":"0x69f0009bce12e24408f9a3d5ad5a8578e2b23efb09002f7b86b3425cf8748889"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xdb954dd5d224004b26cfbb089312e0542e5d1c31","gas":"0xd5ef","gasPrice":"0x9fc748df1","maxFeePerGas":"0x116482c049","maxPriorityFeePerGas":"0x22f7afcf9","hash":"0x1db276b864fbf01dcf8cededf8d597553ecb0eb9438edfaf2f5bd0cc93297c66","input":"0xa3e35f36000000000000000000000000f18f2320e4779f21d6882d83f9133e582dfaa9b6","nonce":"0x570","to":"0x11672c0bbff498c72bc2200f42461c0414855042","transactionIndex":"0x7","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xf23a1fb0d17cdbc2831a2cb0b779795e12533e34425a3abbc4b7e7bde262b92d","s":"0xd4a2c8189378696065b7fc5d13e9cf6595d96047a31a4fcb812c2e677d22a26","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xe84d601e5d945031129a83e5602be0cc7f182cf3","gas":"0x249f0","gasPrice":"0x9502f9000","hash":"0xcbe7ed31654af4e191ca53445b82de040ae2cd92459a3f951bdcce423d780f08","input":"0xa9059cbb000000000000000000000000355f96e3261cc8237d2d36fd81cc9b9cdcbfc5ea0000000000000000000000000000000000000000000000000de0b6b3a7640000","nonce":"0x4f1f0","to":"0x499d11e0b6eac7c0593d8fb292dcbbf815fb29ae","transactionIndex":"0x8","value":"0x0","type":"0x0","chainId":"0x5","v":"0x2e","r":"0xadf7dce5f34d482bb19ff0c85f43be7008cb838043f9abb5fc08421245ac4228","s":"0x5d2c0f0b9d2e68bb8da6084e4971d57bd76bf0cd9d893c9c985962812d2df026"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xea0193f88a0d9c36e83e6fb6d382212b6373faba","gas":"0x43238","gasPrice":"0x933ea77d8","hash":"0x808ba5211f03cc78a732ff0f9383c6355e63c83ae8c6035ced2ba6f7c331dc63","input":"0x9f8420b300000000000000000000000000000000000000000000000000470de4df8200000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x0","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x9","value":"0x470e9f23394000","type":"0x0","chainId":"0x5","v":"0x2e","r":"0x9536f87e8c3433ea23ef7211c0c32689551906dfdf31bcc73b89fcf18fe86a92","s":"0x3e94bfe3b4ba32a6ce71ee6e0ff9f26dfc2b0d61b5c0fe049469e3c4b88ac227"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x1f9ab300b380313e6a2208e44c01a0602538385d","gas":"0x32b38","gasPrice":"0x87fc9eef8","maxFeePerGas":"0x2e90edd000","maxPriorityFeePerGas":"0xb2d05e00","hash":"0xdd66f1f26672849ef54c420210f479c9f0c46924d8e9f7b210981ffe8d3fac82","input":"0x32db5470000000000000000000000000000000000000000000000000000000000084021000000000000000000000000000000000000000000000085b0af981975a40fc5a00000000000000000000000000000000000000000000053ae1f470262f3b01c4000000000000000000000000000000000000000000000813bca9f8389ffd193f","nonce":"0x5699","to":"0x28cea7b0f3916c1dba667d3d58ec4836ad843c49","transactionIndex":"0xa","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xbe8eddd463a3518a4c94b5922c0f2fb26a32c8afcd819f7deaf4f0416757ad13","s":"0x3e234182acd5261dfba3cf4f125d1a8377fc707b3b1900b565d1a6b8987b398c","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x1d990a2cf61b46f37582dd31a7b242e989e1a1ee","gas":"0x493e0","gasPrice":"0x86f96eddb","hash":"0x254abb2f8cdcffe9ef62ab924312a1e4142578db87e4f7c199fd35991e92f014","input":"0x9f8420b3000000000000000000000000000000000000000000000000002386f26fc100000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x0","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0xb","value":"0x2387acb3784000","type":"0x0","chainId":"0x5","v":"0x2e","r":"0xbfe9b99fd2e9bbd2d65bb4cc17da88130d8f6b569a26afa642ed1cc8efd2e2ef","s":"0x7003dd3962eec2369bc5abe5e3d5b73a9086a3219643b1741f3a9832369448fa"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x1124bbb196fd7b61947f6f03b7d7cebde8340b6f","gas":"0x493e0","gasPrice":"0x86f96eddb","hash":"0xa7b7c654e7073b8043b680b7ffc95d3f2099abaa0b0578d6f954a2a7c99404e1","input":"0x9f8420b3000000000000000000000000000000000000000000000000002386f26fc100000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x0","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0xc","value":"0x2387acb3784000","type":"0x0","chainId":"0x5","v":"0x2e","r":"0xe8dae9efa8fa73a3aebdaa75ba12acf56712b1f99fc128ab802a7610d014547b","s":"0x2ef347ea90a0db21b035637342bfc916c9962d3ec610a4e99cfaf555a2606fe2"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xdedf52a88fe47f6a11d629badd0096d201aef86a","gas":"0x493e0","gasPrice":"0x86f96eddb","hash":"0x7ccdfa698c8acf47ab9316ed078eb40819ff575bcf612c6f59f29e7726df3f96","input":"0x9f8420b3000000000000000000000000000000000000000000000000000003a3529440000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x1","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0xd","value":"0x45d964b8000","type":"0x0","chainId":"0x5","v":"0x2d","r":"0xfc4e092094abc7fed9cf11eea8ad6ec3a760d13b9c603b5570c2143e48090f2f","s":"0x31a0a6016ab51ed6375891bf532d9031bf91c1d0e01df63cf7e46076aeee83a3"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xe1db1fd154b344ce7dfcb53a65279559b298f0df","gas":"0x493e0","gasPrice":"0x86f96eddb","hash":"0xa0b035ef315824a6f6a6565fa8de27042ade3af9cf0583a36dea83d6e01bf2a8","input":"0x9f8420b3000000000000000000000000000000000000000000000000002386f26fc100000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x0","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0xe","value":"0x2387acb3784000","type":"0x0","chainId":"0x5","v":"0x2d","r":"0x79c316492bfa36fa4de2dca02ffac77f6c1772714e153aad8c947ce848d4106f","s":"0x4fe3e083943ca8f974cb0752a2ffb70e4d6c8b615e16ece7e19b2c464be66929"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xd4c3777e1821f6fb532957104e1317a9d3f881ec","gas":"0x493e0","gasPrice":"0x86f96eddb","hash":"0x1ebad7f3e8cb3543d4963686a94d99f61839f666831eab9c9c1b4711de11d3d9","input":"0x9f8420b3000000000000000000000000000000000000000000000000000003a3529440000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x1","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0xf","value":"0x45d964b8000","type":"0x0","chainId":"0x5","v":"0x2d","r":"0x5c1f544ca92b28a014129a9d04f8e895dc8a6987ddc1717c26b0619bb9bac420","s":"0x47574643bd92a0f129f9c5ce3caebe7943cfd828d67fb0e5bdc1eb2ca202822a"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x127418955b15f5ff2fa232431a798b53fd006c82","gas":"0x493e0","gasPrice":"0x86f96eddb","hash":"0x501750278e91d8b5be1ccf60e793d4bbcd9b3bb3ccc518d3634a71caeac65f48","input":"0x9f8420b3000000000000000000000000000000000000000000000000000003a3529440000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x1","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x10","value":"0x45d964b8000","type":"0x0","chainId":"0x5","v":"0x2d","r":"0xcfc9894bf716ba707521f0969082afb688b7d47cc21f1423b239c40867128f47","s":"0x5d9b9c66d8437d0a37768fb9c3241ef64b7e795d0d908196e1f707215ac1f56"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xc2ac1bdcb3dd77864b99eb2cafef2ed36c1487c3","gas":"0x493e0","gasPrice":"0x86f96eddb","hash":"0xd80ff8af29ae163d5811ba511e60b3a87a279f677bb3872a0f1aa6d0a226e880","input":"0x9f8420b3000000000000000000000000000000000000000000000000002386f26fc100000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x0","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x11","value":"0x2387acb3784000","type":"0x0","chainId":"0x5","v":"0x2e","r":"0x8bd7220d176d18cfbc824063448cf864c494fcf0958dec82126f26d3fc6c0b6e","s":"0x2f4de3d2fc3be6d2812ee10aee16a995af5affcfec27f9953ae609886d2b563e"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x11a5ad000f8494233df5bd2f2573fe20bad744ab","gas":"0x493e0","gasPrice":"0x86f96eddb","hash":"0x096acab3b3fe47b149d375782d1eb00b9fef7904076d60c54b3c197b04e6bf82","input":"0x9f8420b3000000000000000000000000000000000000000000000000000003a3529440000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x1","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x12","value":"0x45d964b8000","type":"0x0","chainId":"0x5","v":"0x2d","r":"0x43726c3165958e94d80cb6992121f55df2904a1de4356e0a6ff3d8bfd03c0928","s":"0x6244361e31daccbb5c7e9f3f7d01004080d2efa314d614fdc2aad4c1b7d71613"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x90f8b290ec2929cce086826e971cad3857c6dbb5","gas":"0x50f46","gasPrice":"0x861fc89f8","maxFeePerGas":"0xe22924cba","maxPriorityFeePerGas":"0x9502f900","hash":"0xbe9d1738af74a22400591a9a808fb01a25ab41e2e56f202dd7251eb113e8ceeb","input":"0x6ab150710000000000000000000000000000000000000000000000001bc16d674ec800000000000000000000000000000000000000000000000000000de0b6b3a7640000","nonce":"0xe4","to":"0x2e84c9894f628fd209f48b06d10b46c8cada4c10","transactionIndex":"0x13","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x412c7bfb0236a4317da40645ee4e60f19185e7d0cd2cc9bc88f7629de505b939","s":"0x4f6bd485d10fa134926ec3e3a83e212f3c5d903ba52da87f07794a2ba0a5c1eb","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x7915ec065b644568155c4772a286addad3864c1b","gas":"0xb71b00","gasPrice":"0x861fc89f8","maxFeePerGas":"0x1176592e000","maxPriorityFeePerGas":"0x9502f900","hash":"0x0834c720e55cccd97aaf4f8fb0cb66afb9881fb6a762c0f70473ec53f98a712e","input":"0xedce8b4d6a1fb55588eadfd3a0c3350435a31d31e7c236125eafcc2a892d50711d9a4939a4282888c956c070cd83400fd47ab83bd5287244053b8228711b07386dccacbd000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000001a0000000000000000000000000000000000000000000000000000000000000082000000000000000000000000000000000000000000000000000000000000008a0000000000000000000000000000000000000000000000000000000000000092000888ad4975d4079d80bc6da5ded57746f889644719ec160efc2e4a96ad645df10b1683afcd7ce41ba6c06528761f821cbc6e806ef4b71c189603ec218b12a1f1478883498e67b97ae4babef6996acc582db1377d8755374602e00b8148025ac2d2f52e78d7484919cef14bf96e5b7a3f7f8cf09989551888f2c697052ce2bdb02a9296b20016c78683a9ca137037e57c8ff25198146f9d4cdb5a25ab9c95a03038f22f83c8604ca7c035ef756d2963c3657eea4ffb18ef967752d8cff15a16124a1d92a1cda613624c98e3078742803da1417b78bb264b7bb2197515cb4facc2ea395c6241664dbd953d0034900a86eb94897bf89aae775a1d73e6fd034785400000000000000000000000000000000000000000000000000000000000009a0000000000000000000000000000000000000000000000000000000000000000300000000000000000000000000000000000000000000000000000000000000600000000000000000000000000000000000000000000000000000000000000260000000000000000000000000000000000000000000000000000000000000046000000000000000000000000000000000000000000000000000000000000001d802f901d482e7041b846de27f7b846de27f8383026c28946aa397cab00a2a40025dbf839a83f16d5ec7c1eb841dcd6500b901a45ae401dc00000000000000000000000000000000000000000000000000000000640fdf5900000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000e404e45aaf0000000000000000000000002c1b868d6596a18e32e61b901e4060c872647b6c000000000000000000000000964ff70695da981027c81020b1c58d833d49a64000000000000000000000000000000000000000000000000000000000000027100000000000000000000000009a1a41127726f74560a57990fb928120eed6f55e000000000000000000000000000000000000000000000000000000001dcd6500000000000000000000000000000002d4766adcf72ef2d996edfadc866be12c28000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0000000000000000000000000000000000000000000000000000000000000000000000000000001d802f901d482e7041c846a969541846a96954983026c28946aa397cab00a2a40025dbf839a83f16d5ec7c1eb841dcd6500b901a45ae401dc00000000000000000000000000000000000000000000000000000000640fdf5a00000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000e404e45aaf0000000000000000000000002c1b868d6596a18e32e61b901e4060c872647b6c000000000000000000000000964ff70695da981027c81020b1c58d833d49a64000000000000000000000000000000000000000000000000000000000000027100000000000000000000000009a1a41127726f74560a57990fb928120eed6f55e000000000000000000000000000000000000000000000000000000001dcd6500000000000000000000000000000002d4766adcf72ef2d996edfadc866be12c28000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0000000000000000000000000000000000000000000000000000000000000000000000000000001db02f901d782e70480846a969541846a9695498302e100946aa397cab00a2a40025dbf839a83f16d5ec7c1eb870aa87bee538000b901a45ae401dc00000000000000000000000000000000000000000000000000000000640fdf8d00000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000e404e45aaf0000000000000000000000002c1b868d6596a18e32e61b901e4060c872647b6c000000000000000000000000964ff70695da981027c81020b1c58d833d49a6400000000000000000000000000000000000000000000000000000000000000bb800000000000000000000000048f2c17f8885e135c8689626d5841d0b94013556000000000000000000000000000000000000000000000000000aa87bee5380000000000000000000000000017a8db2711fe83b10bbfabb6a8b86c3e26ca154ef000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c000000000000000000000000000000000000000000000000000000000000000000000000003000000000000000000000000000000000000000000000000000000000000001b000000000000000000000000000000000000000000000000000000000000001b000000000000000000000000000000000000000000000000000000000000001c0000000000000000000000000000000000000000000000000000000000000003760f4e19e59be10b323fe1b42e42de2754c5da54ff316cef74ef09dbc0144bbf73e609a8d21a38f393bae9a3de6bebbf362608d907d941c8166f44d8ee2c6686b5dbbd6681f5467219d9bb530db013b7c067db659c03efe935caeb7bab36699d00000000000000000000000000000000000000000000000000000000000000032d2d7436bd45b5e81824945ff3dda846e270c81e72929841f4b14f56e02eef39477f9c162a2759c8d7c7e1feefdd064f6aefb4360d483f70671f36fc11ccc6db6c53f74e3019c12d859545ad75b51998b2238887dc0be3c78522c8356150526a0000000000000000000000000000000000000000000000000000000000000000","nonce":"0x48f08","to":"0xe87d317eb8dcc9afe24d9f63d6c760e52bc18a40","transactionIndex":"0x14","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x54159a63b8ce19097cb8afeaffc84cfb5257f9709dcb0f0a258befa0b924b13","s":"0x17f5ef5aeceb6f082a8a0f8fa28e55d453c52e5f86d48dfb4d4f039aad7fa493","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x52db522edf50fc32b8fc0f77d51140031da11da3","gas":"0x201568","gasPrice":"0x861fc89f8","maxFeePerGas":"0xe22924cba","maxPriorityFeePerGas":"0x9502f900","hash":"0x51a0c33c9b37245b416575bdd2751c0d8a5d8bead49585ac427bfc873d4016af","input":"0x96d3f83c0000000000000000000000008cd194f4ced354a14960f76f49305feb8510f73f00000000000000000000000000000000000000000000000000000000000000e000000000000000000000000000000000000000000000000000000000641024ef0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001b3fd330d479974ad52e18b8767d9f18cf9ff024fa749b1066a803b237570cb73e2868e821124c8128505d883124711ae7fdca0339f4f5cd5dadd8eb6956eb4af500000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000003","nonce":"0x2d9","to":"0x29c1442d7e3b6ed179ceb55fe996e1f4384880da","transactionIndex":"0x15","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xac84f403fa0347be3246ad695f8f6a780332357d49dfa67388fae3e051e5566c","s":"0xac2e148c1045af0ebdb334f20743af7d5499558af5eea43393159ce26a3fb1b","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x3aea5f857b75a946d5f5b329bdcf4db46aec5d2c","gas":"0x50f46","gasPrice":"0x861fc89f8","maxFeePerGas":"0xe22924cba","maxPriorityFeePerGas":"0x9502f900","hash":"0x531c25d51ccda59aa9ea82e85c99be9dd4e285af9b8973cbab9ac4a38e26e55a","input":"0x6ab150710000000000000000000000000000000000000000000000000de0b6b3a76400000000000000000000000000000000000000000000000000000de0b6b3a7640000","nonce":"0x1d","to":"0x6c23a4586cc791d2be6767532e12264992aef74a","transactionIndex":"0x16","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x81abc4fdf3b57fdf3a951fb293853fdd86aadce8f319576ac78c60caac186c43","s":"0x452742335bd1f63fd623d5e6cf91f6339361f863dba1a57fc3c1da8292e82c77","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x7915ec065b644568155c4772a286addad3864c1b","gas":"0xb71b00","gasPrice":"0x861fc89f8","maxFeePerGas":"0x1176592e000","maxPriorityFeePerGas":"0x9502f900","hash":"0x93ac6c08d21cb1b61ff59e5e2d6fa3f9ad54008b0a66c669199050bef219f6e3","input":"0xedce8b4da4282888c956c070cd83400fd47ab83bd5287244053b8228711b07386dccacbdb54cb66757631f9f22e2faf7da0eecc43474ab1a1af21aec22dcf949e2579241000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000001a00000000000000000000000000000000000000000000000000000000000000860000000000000000000000000000000000000000000000000000000000000092000000000000000000000000000000000000000000000000000000000000009e011cb7bbabfab668b42b5582cec8d60f326ae14ad55f8d675060dd111dee6c88d0937435261929ba3a881bea107593a10e13c917a0ef5ae4e8bde40de2d1da4ba25ab3a239ba53eb4e260d23b98a7db944f644f40ab75992a89fad40e8d692ad62f8671604db415b54238c5522f6c4e6b25785bffa696d173659309b95a2fae8700d4b9c14382973ea34a3cd8b8428594908dcad2d5d7a01056b8e49a8c25087f12f9e9fec1f4b5fdc57509dba6839100e28016b2e3fec4928bbe11d3789b6cab280c17bebfa5a0e06aea22764e1a18d2d11316bdf81028e65755582586ebdf571cbd0ef59800ba3405539187dfc03eac1dba0cf590e2131a56ef7f260aa38f940000000000000000000000000000000000000000000000000000000000000aa0000000000000000000000000000000000000000000000000000000000000000500000000000000000000000000000000000000000000000000000000000000a000000000000000000000000000000000000000000000000000000000000001a00000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000032000000000000000000000000000000000000000000000000000000000000005c000000000000000000000000000000000000000000000000000000000000000da02f8d782e704820101846a969541846a96954982dc1994a59477f7742ba7d51bb1e487a8540ab339d6801d87470de4df820000b8a4220b5b82000000000000000000000000f6213f16f3db9b50c684b2da37ff080895ae4a02000000000000000000000000000000000000000000000000002386f26fc100000000000000000000000000000000000000000000000000000000000064376b6900000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000000c0000000000000000000000000000000000000000000000000000000000000000000000000003202f082e70411846de27f7b846de27f8382520894b6605a717a2447edac46b1cdafe35e3e91130c8d87038d7ea4c6800080c0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000f202f8ef82e7040d846de27f7b846de27f838303335f947191061d5d4c60f598214cc6913502184baddf1880b8c44d49e87d00000000000000000000000000000000000000000000000000000000000000600000000000000000000000000000000000000000000000000160f9854c9f595e000000000000000000000000000000000000000000000000000000006417d4b8000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000b1a2bc2ec5000000000000000000000000000000000000000000000000000000b2f4f1df2e372ec00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000027502f9027182e7048197846a969541846a96954983029eb1946aa397cab00a2a40025dbf839a83f16d5ec7c1eb80b902445ae401dc00000000000000000000000000000000000000000000000000000000640fdf0b000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000016000000000000000000000000000000000000000000000000000000000000000e404e45aaf000000000000000000000000964ff70695da981027c81020b1c58d833d49a6400000000000000000000000002c1b868d6596a18e32e61b901e4060c872647b6c00000000000000000000000000000000000000000000000000000000000001f400000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000c097ce7bc90715b34b9f10000000000000000000000000000000000000000000000000000000000000000000000614000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000004449404b7c0000000000000000000000000000000000000000000000000000000000000614000000000000000000000000694b3f194e94c80b2d7a0e986e1440f204f0503f00000000000000000000000000000000000000000000000000000000c0000000000000000000000000000000000000000000000000000000000000000000000000000000000000b902f8b682e70427846a969541846a969549830dbba094964ff70695da981027c81020b1c58d833d49a640872aa1efb94e0000b884437471fd0000000000000000000000004e44260732136caeffc7d076e17b2a3554b9ce2a000000000000000000000000000000000000000000000000002aa1efb94e00000000000000000000000000000000000000000000000000000000000064376b6600000000000000000000000000000000000000000000000000000000000dbba0c0000000000000000000000000000000000000000000000000000000000000000000000000000005000000000000000000000000000000000000000000000000000000000000001b000000000000000000000000000000000000000000000000000000000000001b000000000000000000000000000000000000000000000000000000000000001b000000000000000000000000000000000000000000000000000000000000001b000000000000000000000000000000000000000000000000000000000000001b0000000000000000000000000000000000000000000000000000000000000005b0efccaa7c845eddd4fb98211c7a58a37abdf06b264fade6cbff8a73ed22fccc602337b33a81e2cc4127be9d913fb3aec24194e14a61515a26429a00cfb86196aa3c2e6983f1a05dec045f0e63db7bd8619cd2a770ed1f7f470eb7c297e8e19d61277fb276ed8a63fd666b4a5ab02347065a3c16539f4ccccbed8fa39f2a7dc6606fc04c49f3d69463ba1c86c6ddcef8b9f06b9741dc2ebae9f5f1c0523b320b00000000000000000000000000000000000000000000000000000000000000050668b9ca5e5b17e2e79f9f5a7d9ea27e4e7f0302e878584fef3c2304c70c1ef53da311342341f89df488646b97a83994a3d07cc622ffde98598548c5326b7ccc0cf77d5d6fca6cf3f5b5b41a266fa2aaf697fd976dddc710fca834c96d2dfd725eec5980733db3c4e8f779f9fde3a598b2860d819419c961012825f0e160ee7b220989005b6ac5c48734db18158c2d85c8499bea1972c9f875c2d2aeafccb33700000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000014000000000000000000000000000000000000000000000000000000000000000e0000000000000000000000000f6213f16f3db9b50c684b2da37ff080895ae4a02000000000000000000000000f6213f16f3db9b50c684b2da37ff080895ae4a02000000000000000000000000000000000000000000000000002386f26fc10000000000000000000000000000000000000000000000000000002386f26fc100000000000000000000000000000000000000000000000000000000000064376b6900000000000000000000000000000000000000000000000000000000000000c000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000140000000000000000000000000964ff70695da981027c81020b1c58d833d49a64000000000000000000000000073fee82ba7f6b98d27bcdc2befc1d3f6597fb02d000000000000000000000000000000000000000000000000002aa1efb94e000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000064376b6600000000000000000000000000000000000000000000000000000000000000c00000000000000000000000000000000000000000000000000000000000000044a1c058fa0000000000000000000000004e44260732136caeffc7d076e17b2a3554b9ce2a00000000000000000000000000000000000000000000000000000000000dbba000000000000000000000000000000000000000000000000000000000","nonce":"0x48f09","to":"0xe87d317eb8dcc9afe24d9f63d6c760e52bc18a40","transactionIndex":"0x17","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xb5f185933d49064643686594f44a2584b1d57ba6a91f2a45d1a122892488f209","s":"0x7bb4af7ea30290b36fa7c266ee2387eff9e3ee0cd79b48aed27f5bfaaf34114c","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x4281ecf07378ee595c564a59048801330f3084ee","gas":"0xea60","gasPrice":"0x861fc89f8","maxFeePerGas":"0xfd18eeafe","maxPriorityFeePerGas":"0x9502f900","hash":"0x3792db6dd6285f409e4281951e9f78dad16c4a78072ff1c909dfadea5658d857","input":"0xa9059cbb0000000000000000000000000cc351a97c2fafde4cfa8a00c4fd79881cf13b53000000000000000000000000000000000000000000000001158e460913d00000","nonce":"0x77ffb2","to":"0x326c977e6efc84e512bb9c30f76e30c160ed06fb","transactionIndex":"0x18","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xef4173dd45060791cfb6dfc3cdc8a9b417ff6a4b3ba57759ea91fd875b01a522","s":"0x4de926b5099c7d60cc24add3c2eecd8e9550c1fe7f878430eccb887a2ff932ff","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x53e2c2479833ca17f946aeb16dcc49f5e2194701","gas":"0x431eb","gasPrice":"0x8442f24f8","maxFeePerGas":"0xd6aac8818","maxPriorityFeePerGas":"0x77359400","hash":"0xd2d51764c01e8c0a43fbe362704388df5bacf7e5e620c3864e242530ffb3e828","input":"0x9f8420b300000000000000000000000000000000000000000000000000470de4df8200000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x2","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x19","value":"0x470e9f23394000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x155352758fb04a6c0816c3dd9ca16bd6c66c37e2e19f2aa5d969225e3cb7f118","s":"0x6a4a1237db75dac4322fe12aee8b94edf7083ea661d6e93334c667d2d5c2c101","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x535619cf2bd2e84e567bda1a6164f195cb2bba21","gas":"0x55730","gasPrice":"0x83152e5b0","hash":"0x516b0227d9e64eb6e0de6862764d40f5376b5f12fec878436fea3479b4c36bb8","input":"0xa9059cbb00000000000000000000000030509945d2b329cc253a8bb2e2c54bdbb08b1070000000000000000000000000000000000000000000000010ce1d3d8cb3180000","nonce":"0x2176","to":"0x1173069b0e472a64ce2b6203fec8fb25a05b75c2","transactionIndex":"0x1a","value":"0x0","type":"0x0","chainId":"0x5","v":"0x2e","r":"0x289ee9948b80fc623b8c5d85c7df6fd25786fcc118163042b77a00560f53c3fb","s":"0x5b0a79e30d05370b27664b2a10cf964e110387bd62098561b6ea6a9dcc4634a"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x339d413ccefd986b1b3647a9cfa9cbbe70a30749","gas":"0x180ac","gasPrice":"0x83152e5af","hash":"0x81b0abc78b82840adb666775b182a9e292f663b64bcd35004c04436ed3c8281c","input":"0x711746e200000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000009a00000000000000000000000000000000000000000000000000000002540be40100000000000000000000000000000000000000000000000000000006d3c514bd0000000000000000000000000000000000000000000000000000000000000010","nonce":"0x2689","to":"0x7cbd185f21bef4d87310d0171ad5f740bc240e26","transactionIndex":"0x1b","value":"0x0","type":"0x0","chainId":"0x5","v":"0x2d","r":"0x1f70a3d0933aab069a55fb2b16a259d21ea5fb3255e2032c5ff194a600ed2ab1","s":"0x3ac2142fc9f2009d68b08855eb5bc85e889e15d043c33bfc516f28ea38715485"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x339d413ccefd986b1b3647a9cfa9cbbe70a30749","gas":"0x180ac","gasPrice":"0x933ea77d8","hash":"0xd0287570d431d2baea96ecc81cb890e7f4f06ab5df02f9b4067768abca19acb5","input":"0x711746e200000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000006500000000000000000000000000000000000000000000000000003a09994473bc00000000000000000000000000000000000000000000000000000005672af7e00000000000000000000000000000000000000000000000000000000000000010","nonce":"0x268a","to":"0x7cbd185f21bef4d87310d0171ad5f740bc240e26","transactionIndex":"0x1c","value":"0x0","type":"0x0","chainId":"0x5","v":"0x2e","r":"0x73a68e10ef9726d47ff314cd16d1846a0876d2b63a65014909140de7e45aa8b3","s":"0x580de27e4626139fbad4129a249c7ac2b22e1062659293e5fc3a244fd74907c"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xb5b9345e21f34b6cfa538f49e2b14ad4c3db3f7e","gas":"0x431e0","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x76ddab2674369f34946c5fa2f05e2aa8566d86235b83e808e9b27bc106e04ac7","input":"0x9f8420b3000000000000000000000000000000000000000000000000016345785d8a00000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x38","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x1d","value":"0x1634632a1414000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x4314a4757076c92ca696f14cbe037bcc0178f8b10749418d4535195e90b2cdc9","s":"0x15ee917bc3e27928196ad987b61e3fd35ac92a4200b139d355b30502bff7fceb","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xac2fde165d9f13a223f58b9ac1dde51b63feff2b","gas":"0x5208","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x34a5c74011a2c8a00103bc91bfbfd94aa99cd569be69066e4bf64d188fe8714e","input":"0x","nonce":"0x38","to":"0x7155eba8ef327ac3b36fe59b5e00ab85f735f4f4","transactionIndex":"0x1e","value":"0x1c9f78d2893e40000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x52178c5dce512607a6242f501f78bc894917a482e99a3368caea6bca94c6dd69","s":"0x728be90654231b65f790eba478ccab574e2468fc4e031b712efa88af31fc6592","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x1ddedd674bfacb6587e0c68cee8f2f7d8a71e9d7","gas":"0x1d4c0","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x7b9730ead1b9f59b206d0ddea87be9383ba3fc7b496c7863b0cb847889b86617","input":"0x607019b9000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000041971588d95d4d664ac84a45e59fc81871b7051d679376d86cef6b9e1453c762dc33a84a125774319ee47f2a8b8d588da6c8ff7ad84fd9eed22fa124b1a5c5ed4d1b00000000000000000000000000000000000000000000000000000000000000","nonce":"0x1","to":"0xe1e6aef7642b6609e6c54884d1bda4a3cb152461","transactionIndex":"0x1f","value":"0x4380663abb8000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xc0d3e609b2e9f844d300a7784aa9e7cb956415d025cb573a73848f49e4be69e5","s":"0x6ce01527c00c1a93341a541824aed7a1c895f5a0d998f4415cf6d88171c5ad3e","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xf6df8ead0bdabfba61d9b2457d5a5ccec67fb7f3","gas":"0xc836","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x77166ee0409ba86bd26e7c03ad1a927abaf5af8a8a37149e725cd37512091dd6","input":"0x67a5cd06000000000000000000000000fa8449189744799ad2ace7e0ebac8bb7575eff47","nonce":"0xbd","to":"0xccb0f4cf5d3f97f4a55bb5f5ca321c3ed033f244","transactionIndex":"0x20","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x5649e1ff58fa9b6ee27a7316904df02db1ba1c471a2f3409f370a31c6b3d5ec4","s":"0x386b766277e267f8796ba6e92af71a752335bbe45cb3385b9cdcab9ef6c53e41","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xf37cbbc2dad42e8826898d45933afd3a04937e71","gas":"0x112c1","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x3c2b6c2ae505c5c36d5f316c1fcb5f54f7346ed35ae35c93462991ded7968a68","input":"0x095ea7b300000000000000000000000071bcefe9e9fbad3f12f2e6c14ea0cae7f0c91e7900000000000000000000000000000000000000000000000000000004912e6bef","nonce":"0x9","to":"0xb5d86e1f237d52f1f19793d3265e9340394f75b8","transactionIndex":"0x21","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x3ee4d5bfc575fa4b241b4d23e6f099eba5f1e6a20b8cea663c63db6400d01506","s":"0x21481ea7a3e7ad758f2e149829f70f43d67b3cc0d44112cd3744e290a06dd985","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x52b6255b7810d97de8f751737547d1792dff4fe0","gas":"0xece2","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0xf99a792837e13827b5e0a8915fb59c760babc95d242feca99a5594e64ff6b6e2","input":"0x095ea7b3000000000000000000000000c92470d7ffa21473611ab6c6e2fcfb8637c8f330ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff","nonce":"0x51","to":"0x07865c6e87b9f70255377e024ace6630c1eaa37f","transactionIndex":"0x22","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x5237f7449c0df409c1a4d6cb09005a9224860aa74737debd961e2a24668d1022","s":"0x17e5e842e3f5ffb5a16eca0ec2a92e5b52d43bf9856f97e2083b2e951499b970","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x3c70503d83c5a681aab503d724f47fe810ae8205","gas":"0x17eb2","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x522313f5d923f048ae5bd0b5595c1f4fc883bc0b3cf3cb0939d3fcf8b08c829c","input":"0x94d008ef0000000000000000000000003c70503d83c5a681aab503d724f47fe810ae82050000000000000000000000000000000000000000000000000000000316195298000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000","nonce":"0x5","to":"0xb5d86e1f237d52f1f19793d3265e9340394f75b8","transactionIndex":"0x23","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x6741309799fccf0f1359bd710291ec1bb66eed23522d6ed60c5924264d4d283e","s":"0x69c43182ee8a650b0042cdb2352781b23eb1de72f1c3a8903a1a33360e7d9732","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x4da9a48963c158a88bf6d4845a6a1890d20e55ad","gas":"0x431eb","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x471ceb0e85af594aa56deca54cb8198567b2afd8406722ea530077aaa6b641b3","input":"0x9f8420b3000000000000000000000000000000000000000000000000001dd7c1681d00000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x0","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x24","value":"0x1dd87babd44000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xf977ce19da80b7e155ee2d8b7656e5c89004851407bd5370785befe2c89d82f6","s":"0x1d76177407e73d8b73b0909158825ee375a25fa7c18b04884f4be77bb60795a8","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xe40a2cd9efde08fb7664bcdbbdd877c52c4bd228","gas":"0xf4f6","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x3e9dca502e9039ae0c6d642f62e9562ff00010c6bfbb8234a6135712ba70dfda","input":"0xa1ddc5460000000000000000000000000000000000000000000000000000000000000738","nonce":"0xa","to":"0xdef65f8e2f62bde60cd86ad3b4ad7fa6741cf175","transactionIndex":"0x25","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x34df85658956c9eb71549db3a73abca70dd01b8e91284afcd372c1212a36605d","s":"0x5036e2984bb2edbb5fd647bba873f1f5c5ee4845e539c9b0bc70d3d12a4bd93f","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x17299065e99b12b0c8cad06638624cff8d507334","gas":"0x5208","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0xc95cac67267f4accb9b5950316ac64772f7d082bed6b712c09cf2da0bdc237b7","input":"0x","nonce":"0x7","to":"0x02647cbb1714fa9a5747ec5be6333e06d806e85a","transactionIndex":"0x26","value":"0x71afd498d0000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x82ee5cafbd010cdf7a4604df728d1b8713a5bd26a708f5c92f6b6a55864c9576","s":"0x2b9a70d812123b2ddce1108c4101ddce182f6c83fc8aa0a139ba597aa178b270","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x9aef7b879787baf0c2dfe888e67a7edb7a233209","gas":"0x431eb","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0xfca28fdbd13fc16daf7aec7d4a2ad2c6b5f0b2a7b0fb1d9167c09b5e115ff26e","input":"0x9f8420b3000000000000000000000000000000000000000000000000002386f26fc100000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x2","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x27","value":"0x2387acb3784000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x7e5f1a27ea5e652ec8705f80365f1703d2fd50c1de7c22ee0181d556dd2fcc38","s":"0xb22fb8b31dbfff8ad0457ba4b659fb0d7031cd86f08fc3cb78d81c97248034e","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x06006a25e0fe65f0eeaad1f4813940b68db782a7","gas":"0x17ea3","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0xc73124ca798b2f7a5df2ea4d568efab2f41b135130ea5cc41d4bcb4b5c57d5bd","input":"0x94d008ef00000000000000000000000006006a25e0fe65f0eeaad1f4813940b68db782a700000000000000000000000000000000000000000000000000000002726bc7f1000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000","nonce":"0x6","to":"0xb5d86e1f237d52f1f19793d3265e9340394f75b8","transactionIndex":"0x28","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xabe4fc843d3a1628a464884c13c21bd21ae9a0a5738d9ae2761ec7cb24b059d0","s":"0x68408d8096e542b2c06cbbecb9494a3778c3ab644e69dde1fac078079c4bcad4","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x2501bf5c8ddf04a60fdd47a95d53d99b315604e2","gas":"0x5208","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x29abb76b5e7a5ce137bf9c22474d386eb58d249f43178d2b2e15c16dfdc5ca80","input":"0x","nonce":"0xa","to":"0x901a4e04f1513443c6efc6ce4e913d1b960ecd20","transactionIndex":"0x29","value":"0x1a3385ff37f0000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x1a1789d5b19950f45383cb1909cff9128dc2b332e2ea7ba42cfca5806376e3cb","s":"0x617a5a4339503a9c9d08705d98e7a202ed7ede1d1192fd7d98b648c8c102716c","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x507832c92ade971b9a2880427353c6ce6d0ffe53","gas":"0x61a80","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x03e5ab25a58bd44fb9dd0c698b323eab8b8363479dfcbcbb16d0a0bd983880ae","input":"0x85ff842c00000000000000000000000000000000000000000000000000000000000000c0000000000000000000000000000080383847bd75f91c168269aa74004877592f00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000006100000000000000000000000000000000000000000000000000000000000557300000000000000000000000000000000000000000000000000000000000000014507832c92ade971b9a2880427353c6ce6d0ffe53000000000000000000000000","nonce":"0x1e7","to":"0x805fe47d1fe7d86496753bb4b36206953c1ae660","transactionIndex":"0x2a","value":"0x214e8348c4f0000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xf707322f65ba56c95ced5654efafcf9bfd60a2dd80e74bded3190673cda55d8e","s":"0x46412ec3d2137fcef30f53cc4644769f4da126128979920ed4e209acb1c8ebc9","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xd44c850ce9103d6b2398d4ed9bbce321f3b769c7","gas":"0x1e0cf","gasPrice":"0x82661bff8","maxFeePerGas":"0xde6f782ba","maxPriorityFeePerGas":"0x59682f00","hash":"0x3c8ee80ddea7fa2d2b75e44563c10c10756f598e8ad252a49c5d3e8a5c8e6cbf","input":"0xeb672419000000000000000000000000d44c850ce9103d6b2398d4ed9bbce321f3b769c7000000000000000000000000000000000000000000000000002e2f6e5e14800000000000000000000000000000000000000000000000000000000000000000e0000000000000000000000000000000000000000000000000000000000098968000000000000000000000000000000000000000000000000000000000000003200000000000000000000000000000000000000000000000000000000000000100000000000000000000000000d44c850ce9103d6b2398d4ed9bbce321f3b769c700000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000","nonce":"0x9","to":"0x1908e2bf4a88f91e4ef0dc72f02b8ea36bea2319","transactionIndex":"0x2b","value":"0x2e2f6e5e148000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x327a6fbcaa2ac3cfb0ce64b47f6e61de4d18297f1305f23c6bfd42d88e8d068","s":"0x6b3a9b5252ced14b2e2f2833ad7cc62c46fbd0785d57f2747473af3fff7d46b8","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x78aa9046272fec8d51a402681d7c37481db01c6f","gas":"0x431e0","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0xaffa73b68bc7ab0c3f5e28377f5ca0a5df33c0a485f64dc094b7f6ae23353203","input":"0x9f8420b3000000000000000000000000000000000000000000000000016345785d8a00000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x36","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x2c","value":"0x1634632a1414000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x925370b51dda3e1d1bc6b86580fda3b40875157ea594a9a14174436c726ad46c","s":"0x516c88bf3cb2f46ca81572140b41e5db2d74c4a736ee7d572b508415c438f779","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x56784e51c2ce28dbe9aa68342638d1e95ea4324b","gas":"0xb72e","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0xc66c9c66fbc8fe97fcc16506cde7a58689af1004a18c6171cfe763bcd94f50b2","input":"0x095ea7b3000000000000000000000000805fe47d1fe7d86496753bb4b36206953c1ae66000000000000000000000000000000000000000000000000029a2241af62c0000","nonce":"0x9","to":"0xcc7bb2d219a0fc08033e130629c2b854b7ba9195","transactionIndex":"0x2d","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x407c855bed0fb088e886c3721ee9abee4761221d110512ac29b8fb143c4b34d4","s":"0x1e47aa957d9ebdb564dfa41b72022d525383ffd825a307fbfa9ca13a59994dcc","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x805e39acf2f170251c48a35df16411cfb2f761e3","gas":"0x56a8","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x80fec96707519172b53790610d5800cd09a4243aca9bacfa956c56337d06f820","input":"0x71ec5c05aa669c4922569c1d33f7a81aaa21813800000000000000000000000013a0c5930c028511dc02665e7285134b6d11a5f4000000000000000000000000805e39acf2f170251c48a35df16411cfb2f761e30000000000000000000000000000000000000000000000000000000000000000","nonce":"0xc","to":"0x7c125c1d515b8945841b3d5144a060115c58725f","transactionIndex":"0x2e","value":"0xb1a2bc2ec50000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x8fcf376106af19aac48ecb840ea51df90a5e3ba557eeaad41cd3c8a90785d416","s":"0x4a9e9021ddb5f839bf7f54b54ad52c57b21b6ed285773eea022e3ccae69d1b99","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x4199614bf74f6b3ef47a812d976dd1f57a8f082c","gas":"0x431eb","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x61b33bfcf11214906dcdce7d7ed83ad82f38184c03ded07f7782059d02eeedea","input":"0x9f8420b3000000000000000000000000000000000000000000000000002386f26fc100000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x6","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x2f","value":"0x2387acb3784000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x3d295f5fa2dbec04793f07adec57e29c03376c628a0256ee297fb3070a1e3364","s":"0x6f115dd4505bd320bd7460a47bab0c20e6bcb4b3f17c6d0e00e3ff1d936ed2af","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xf6df8ead0bdabfba61d9b2457d5a5ccec67fb7f3","gas":"0xc7c7","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x5d4138d4e28a8327e506cb012346b1b38b65f615a2b991d35cf5d4de244b3e6d","input":"0x67a5cd060000000000000000000000001f1f156e0317167c11aa412e3d1435ea29dc3cce","nonce":"0xbe","to":"0xccb0f4cf5d3f97f4a55bb5f5ca321c3ed033f244","transactionIndex":"0x30","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x47bfb48eb89a8b110749d34d171db36a8ad21c8d7cc78c7489e72f21cd86ba14","s":"0xa525976583b19b3d2c2dd6b34324cf55b1a61595cb53e3c58acaf203f8709e6","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x9eda8333e09828571db26576a566668f79f98946","gas":"0x50df20","gasPrice":"0x82661bff8","maxFeePerGas":"0xc8d5e2427","maxPriorityFeePerGas":"0x59682f00","hash":"0x875a142b6dfcf10ffb71a7afe0ce4672c047fc7e162ba0383390516d6334d45d","input":"0xb1dc65a400011a04d404e571ead64b2f08cfae623a0d96b9beb326c20e322001cbbd34470000000000000000000000000000000000000000000000000000000000bd780a7d2e00ee03a29f787096cae99da52d07803c76c13473654239118e2cf0491bcb00000000000000000000000000000000000000000000000000000000000000e000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000480000001000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003000000000000000000000000000000000000000000000000000000000077359400000000000000000000000000000000000000000000000000000e50bb6420faa6000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000e0000000000000000000000000000000000000000000000000000000000000000217f0aee859cd78a5cdf79c68c8de4342658d52ccc6420181b5fcb7c657c5fdfa5ca2c8f2dd7e6e5799d44d6818e6dd8fee19b2530bed2045e0c665041f053fe70000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000001200000000000000000000000000000000000000000000000000000000000840235df8360bffc902a68675311f5eaa79ea2c25e2cc394bff0a43d5d608e98c97de200000000000000000000000000000000000000000000000000000000000000600000000000000000000000000000000000000000000000000000000000000060000000000000000000000000000000000000000000000000000000000000002a00000000000000000000000000000000000000000000000000000000000004b000000000000000000000000000000000000000000000000000000000000493e00000000000000000000000000000000000000000000000000000000000840235df8360bffc902a68675311f5eaa79ea2c25e2cc394bff0a43d5d608e98c97de200000000000000000000000000000000000000000000000000000000000000600000000000000000000000000000000000000000000000000000000000000060000000000000000000000000000000000000000000000000000000000000003f00000000000000000000000000000000000000000000000000000000000007080000000000000000000000000000000000000000000000000000000000061a800000000000000000000000000000000000000000000000000000000000000003312d88cdb7cfd5fc5458d9a424da374cd818847f87fc4fb6eae2c3b97e541a6b81e108e55daf857b71514fb7213db7ba15bd6adc12253afc3c5e949144c13696faabe22d1b7ace91532134a5cc65bed9afdd897d6f84ad1b0b6da463bda8fde5000000000000000000000000000000000000000000000000000000000000000352c2a75f88112864819de485c392c349f718fc257934181c4d8ac8eb3a9b1fdd3b7bfb96496290f2b41fcd20fc8d29bd8e29be38550775dc97d21b17c2d679ad05f519787eb2c92a9a897c9f02f15316865cfeb4bcc2c0ba5ac2dc4aaab5c0c9","nonce":"0x3705a","to":"0x233a95ccebf3c9f934482c637c08b4015cdd6ddd","transactionIndex":"0x31","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x7e9247209bede2c21548c6e4f26e41d2636a2490e09ad062f9235e978094073d","s":"0x288d820793b48e55777e794f1694b1605d74dc8726fff438b481125f219eaec","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x6df2b54f23ed4e95235c6e21ada2cfff5a2615a6","gas":"0x5208","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x79b6df832bfbd04085d0b005a6e3ad8f00fc8717eed59280aa8107268b71e7e0","input":"0x","nonce":"0x17f","to":"0x6143d939b2d117f4b998d8d88a56eb0e0a1e9c31","transactionIndex":"0x32","value":"0x186cc6acd4b0000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xcb641be908976bc0a035b0b31a96039da9e63e829e0a24a092ecfbce7724b9c7","s":"0x4034e7dc4001cf9f62a2e5dc4390229655b85e9aac5a5b263278e9d2cb43abb2","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x3f5ceedd435b6143eba2254811a39fc3423f18dd","gas":"0x186a0","gasPrice":"0x82661bff8","maxFeePerGas":"0xaa246a58c","maxPriorityFeePerGas":"0x59682f00","hash":"0xcb2fb25d268f65dc9312e89bd3c328c9847a3c9da282026793c54a745f825ab5","input":"0xe9e05c420000000000000000000000003f5ceedd435b6143eba2254811a39fc3423f18dd000000000000000000000000000000000000000000000000001c6bf52634000000000000000000000000000000000000000000000000000000000000000186a0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000a00000000000000000000000000000000000000000000000000000000000000000","nonce":"0x0","to":"0xe93c8cd0d409341205a592f8c4ac1a5fe5585cfa","transactionIndex":"0x33","value":"0x1c6bf526340000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xa48a4ece6fbe881e342a4eda767c82097c3bd47dc70c09ef6a4e7f90c0f8e843","s":"0x66c92f16907488d115f5088ed8ff4d71c966232458479245bf6dae45358c0429","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xdb4f0eeb7c89b00118cc74de8c9ed55d65c2b933","gas":"0xb72e","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0xe483d4a36ad19fd5eacb7f6d9ad3ce080ad70ac673273e710f6e3d5acbc6559c","input":"0x095ea7b3000000000000000000000000805fe47d1fe7d86496753bb4b36206953c1ae66000000000000000000000000000000000000000000000000029a2241af62c0000","nonce":"0x120","to":"0xcc7bb2d219a0fc08033e130629c2b854b7ba9195","transactionIndex":"0x34","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x6d73169394cb6a9bceb2dcb16aacd261705096f50f30ffe146a09659e25dae48","s":"0x496a1cccf01ad2ae7094b8da2ce50c0a990baba6300625c48ca12c5f20005a64","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x9ac253db14a434cbe7653a99c5039648fa4f7353","gas":"0xb4f8","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x0564242c37d5013b671ef4864394cc0f3924c589f8aad64118223a9af2f164f6","input":"0x095ea7b300000000000000000000000028ac7dbbf9ed6ece39a902e76780fba60f1b2e3b000000000000000000000000000000000000000c9f2c9cd04674edea40000000","nonce":"0x4a","to":"0x0dece1605795461158538302b5f0936afe78c4db","transactionIndex":"0x35","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x15684c9697dcc8d89abe562c4315bfb959938fe7644c00615d9e147a4e496ff6","s":"0x7c58abea24e1fa8caeb73a70219b0d63007785c39694fe5ed2a5a342c99292a6","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x22496eece162f52d185c07524d452b9506e9fe12","gas":"0x186a0","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x48db358e80b278c3a46c2a166339797060a40f33984a5d974992cd9722139d5d","input":"0xe9e05c4200000000000000000000000022496eece162f52d185c07524d452b9506e9fe12000000000000000000000000000000000000000000000000001c6bf52634000000000000000000000000000000000000000000000000000000000000000186a0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000a00000000000000000000000000000000000000000000000000000000000000000","nonce":"0x0","to":"0xe93c8cd0d409341205a592f8c4ac1a5fe5585cfa","transactionIndex":"0x36","value":"0x1c6bf526340000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xa50e6ea1eff21fd33d69f8c74b90c28303b92ebc4a77c71b65c4c8bf3e92ac8c","s":"0x29af3bce2365578b76dc528917b44e96e4fe2e7a8f948eff3e379721f35664d8","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x9ce3f4210dc06889ad5267ef0ce3ded4bd96dc50","gas":"0x249f0","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x69d7758db91fae31fa35ecbed4d40897c5087f45dc796cd796b8ceead21f972e","input":"0x47e7ef2400000000000000000000000089f01bc9865324583380d8d7ed08b8046bffd7fd0000000000000000000000000000000000000000000000000de0b6b3a7640000","nonce":"0x1c","to":"0x6cf3df5d00e842aab1eb504bcf01ebf81646f7b7","transactionIndex":"0x37","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xeefc19e8dca874308c84712c3e48c032a25971a0f7dff16dc47633ba7a4f5b96","s":"0xc0994cf21d29cb0c5f1e666538b58d6dff3b9ba2aa7545337da732c4b5938cc","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xbd1c4e36842c06e53b378eca310cd2dc79a78cbe","gas":"0x35965","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x2951478916ecd27a8e808d08f85be4bf2c0b0e0546f21f4e309145dd96eb8df1","input":"0xab7d7969102507275d685f3f55d10ee45f7b9fa39c29a8a604a7a971c05eee739e63938500000000000000000000000000000000000000000000000000000000641cfd18","nonce":"0x252","to":"0x96e6192eeaf7bb308f79fb5017a9085754b9e12a","transactionIndex":"0x38","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x87fcffa38e0c84cf80fb37ac1e538faeca21462b0a9ec25af0ca0517af22789a","s":"0x72cffece99e79edb7425a9d660590fbc395cdd0db8fd4848074c85f814b3cf63","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x5dbcb3e489fbef1656dbbd7bc4848ed0e520a089","gas":"0x7a120","gasPrice":"0x82661bff8","maxFeePerGas":"0xc8d5e2427","maxPriorityFeePerGas":"0x59682f00","hash":"0xaca9028cb5d55bbf71b7bff9884a9a3b0b38a575ffc8f8807ce345cf8bd298ef","input":"0xc9807539000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000001a00000000000000000000000000000000000000000000000000000000000000200010100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001000000000000000000000000a7a9d91e687decaa6b045797c2e002d70001b48f03020003010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000600000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000002361273ef6f000000000000000000000000000000000000000000000000000002368a4faa14000000000000000000000000000000000000000000000000000002368a4faa1400000000000000000000000000000000000000000000000000000237b9042149000000000000000000000000000000000000000000000000000000000000000288e1b54f6e54124deb78bdb67cbfd0bf63612da12868fc281afc34bb26200a1771f9e00fce297da11cf49427becf350d0bd20a2277439fbb2e8db0fbb5e3d34700000000000000000000000000000000000000000000000000000000000000027d16a90ad0e1f8d924255e6380764fa7c7d46427c8e8ea19f5ba6a9d595297a340f141f74e705d0fe851d7564eba89fcde574deb5975d9126867cd927a0d92cc","nonce":"0x11d38","to":"0xbe57bac491de9a260abb6ba2c9ad4c5d2eaea09a","transactionIndex":"0x39","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x1eba7bf95bf63d02b74d20554af050eedd78ecfbe1a42ec70badb36ccfae4bfd","s":"0x4d7f8d0ac2be28e59374453f24ae6506a81707cc57f0d1c6877b49b3949a9a79","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x3079be9d8622173f02618ba2b793f00795d4f320","gas":"0xf848e","gasPrice":"0x7d9f6fbd8","maxFeePerGas":"0xd9a8cbe9a","maxPriorityFeePerGas":"0xcfd6ae0","hash":"0xc7f625a19ee41a1750eac9428b4394a9a2476b8ea2d31b4c2f9f5b4fcb86cae3","input":"0x2169f79f000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000fdce50000000000000000000000000000000000000000000000000000000000003f2000000000000000000000000000000000000000000000000000000000000001f579a43ce4f3e38c6a948f1ef3bf7954c2059b087b18fdb22c7b69d61727a5d2aa16090b4d1f3281bce660a31d3e2789eeb360192a54e3ac3513c5c8f67b7346fda957c92c1a2981bc68a47d0282e78df2fb63822f06f410e1ffbee7eb83c425122be9be94d817e2e42099632fb9eb5ce7c414cf6ce48e4ed2e64e46e1558ca809742159e841e3de803a8cdc628f7877bfa6d75af4b4ebb185e6d0670ce83332478137fec243a38c0a80d067c955cbe13103294dadfc8c356d0e7996cb62fb2c683e6dd5ad58be934f57375920142990074f8a161ad2390a1e6bea9fc3a58dc3f7e002e9952a68bff229437d3fb4cc1cd8097032b22c884868253d8f2f69c75ada0fbe1dd57145610ae5f451b47645718aca7432d8cd3193d0b96417df6638fd47062a1cb1f63636236fb72195e5a46d1b37f493b8380315e5bb1a6fe67cc6546d62f2c73aad5699e6ffa0d49ce653bcefa173fe0de7b4328aad75f74d15f4f570a1839514550d576e21b8d16c8355b770442f0740e6e5e77ab450ee1fadff8daeeb25a91585192fcd3cdd64dcb6a35e41ff47e854337ebd0923ce280cdacff2ced48eac96bc9f910391a44cfec243a8660ff80c10ff844ea22411953e0387f87d2c2ae81055fc8e87d59e04cd7a923d6aa5204b3eaaf5b842b5fd656e9fda16c59e90c64ef51124fb32f8e63442b1f79d3ba3c0cd5fb90895103719629857d5999b44aad2d69380f48dd824795a89dce14bb82600701ad8fa9bbb36fe93a97d75da26ffcb1a8828918e0293680ecb12e1b772fd98637a7a83cffbca1a994fc889ed0c0b20d447ff727b9f5dcb9a83e1aae9a3518dfe1d7ddab1da48310eaa7ab293d85dd9ca811bfdfee990459fa044c9a9fa6460e5ff7612e42021f16854d790710684663bb6a10ba475fa602b02519f03eb544fe486d9cdde47ab7d4027bfb8f29d778b3a7cc35a9f78dbb05943062efe3b388f1a8c496682a0215265b99fed0363a1061556a40e0539a6656b6cf8967c8fb3092a7fc9b56af124c8f1bd0abbb9af753884b22b333410d47d80c083c9fee52dda8907be0c87c5496f1fe9ac4bf4dd4f06d6ac0ac0cde22138b67bf782e8e9b5c991d58a2a828b4c68620e6d3d26abf8d41005a00866cb4095518b2711636f2fac3b5e26403ef96f5b1765519787ed74c6802b445de029d7bc696aeef5a2e605376aeda4f495c29af66e357c6e1232d7a2c3f22c0bae0c62372d6b2690e503804e2ad314c38a4ffc080d36213458f606075d32dc0a365087616e94a972bf76d7e5eb4a53292fd0d7570cb6fbb4540b3c5ee6deee0f257fe8703d5d8d0180d09754bd9a05894e77318b8c8fb6b4a56999bfc6c405c09d9ce7fe424812db5bf778d7d8634b2f44ad6d00f18615e4c3695d9c5965ba51991508405187275840a3f27cb3101a9742c49edf42dea79ae5418ada42dfe2042f931af15a205e64196b04ef53492a450423c2b63dc849ef72a166fac5f36b25c72d9cb4a2507d5ad15094a979b4ac4ff8eb4c90f448a81fc6dbfcf6a228675ab3308bca37bda8eda22b61ec7e596f2448ee6b7cb6eef589f43f28fc5444d1da3f82ddbe574b774719a3a7869e897e642735517832959ea9cb9164eb2f7665bca1d2e44e1093acc7088271f2be20459c383f5762303b553af1ccfb3371e4eef1f102ce70d62620c5164972facbfbe03b5018265ed62c4c3cc49522166913517e2f2718edb591047a72e818f07c645a18aed87c0384d180dc0bb7fe63bd335b1c09e58571b92e2267ffa5712a33e4a92231d9da7b005730f6d6559ee685edad9a9031c4708c8642c297287af3a3e637d9b5ac6b23218977cf4d30231a79063987f98313a2bc0ca4a73a97e441a45b58cdd8731fc269255b415a9d2ef2bb8a311587f39f6dc82f537cf86a68af19a68c409910f4dbebdfa66445361877a3bf551480d115d8768e8650e9979472a64802da3625cdbddee8f02678a3cc6400824d91b3c7d4c9274b74fb11a9538f1990fc314d35564a0cb0b384590e15cb93db1de1a837b9319828b3fd6b76f1d2bca4ac765f9ec4366905f2dca69a4c8c194cf0a5d821c58bd291e8dd4ddd829a873d093042c1b8e1bb2bb1a95e150c0a0d5c3369c4a791dfcfbc3e631da3d1e704214c3cf8318901f9c58465be78a870a040f34c567c27eb077db2d1ff825a127a038eb14c2890ff9a8a1dc8d6360a91fd788fec97599a318ab03f69bd50a5ece92d96c49413b517579ececf71371b6b1d902b1dbbf40c728c64fadf368582cc4b3c51712c8d6441c0c61802943624e93f9de9eedde87056c21ecf66b3a6977af0261ef48b4c6191ca7ea70d6acc5af910ebf247e2a4429c506c6a41f865175a9bfc81dbb69e59ec2c47370fcee9169b8749c852e7a1275c1278aa3f88bc16d311e58aa9a579ed7bed62f12b4c4dfe9c493cf33f979f667eda043c2aaaf863a747b208f3aa2ccc34f07b12d89bfd75b696a82c493e7eedcdc41eb01321ecfdcb691d14996c3ed7487b5f831436bb7c25876c4149cb6222dbee9e1a05771a8abfd0fd530266476e1bf69d9a15e99c901243585f56a77ef0e6c684a4d49417133ebb91f896176ec3a8f0b966eaffce96f129d18960fdbf5917f8aa0926d52c57192f99e55959369e57ce85ae84ad944e40652f6a81ab8da1dbe81a827366b8b8d2ffb9c7b93087f7a356a16d0022ee8ae891060e29ff11f9f17b01f39b8024baefc8b928a6816309a5c3fc92ed6007499353b5f1bc5700d5fe67f3e34ef3654712b9c67c231f30dff485213b94c20afaa91540560df80ba9ff1cc0f6ea75bf1dac0566551050873c112478f3fce6af162397161e1b41e1ca295f327a4f0ccf4d15fbe58e20a23698bdc25c751d020df371cd1fc59fa51dbf7ad619d208d7084c5752984b5fd0e3a7978f2c11e6b26531fe03c0cb85519483d668bf1dc4dce24509b00aa6e146adb49f31c2c937a2d3a08f1cc0b73cd66f2cb926f0453cf78618e39cbfccd6e6a3b4909d6874872eefed0e395ac2582d8c1d0483007fa6ed7b735323fe8fa1c4be83c725c6b743f63cbd0d6017f1145634b0b905552a2a237561b37c415146d0555a276b4b45d515ed7dab942f9bf40a26d5366032f23fc5fad8b98a1625a841c8cc97dfe0e2074a363a951946df16d1261ef6b2da7f5789dada153448b076637f9d2e04f4390e9dd32fd5e9ab3f5939807bb451bd19d962403da9dd118f1cfa91731973bc721e5ae4a687bb2270e3e76966dd2156e95796d4bfa6b4c10caaee46e1d8f8495f901cfc241c6f9a690349eb0752adb220996ebb95ed26ef376dbb9eea201906a6a3eb346c64eba3c9e4d1b3088baa0ed868cdaf063a4c2434b9d1bbbd69f44ef659262fad9535988ce729aadafcfc6c3ff741dbf8b784b3465fb05f6d5daec91e915f89117e01c9b0c99d7b7cb78e44f5c28de0d3b782de981be058ffa1294072c4e5a66d2d81641d1c07a9a04012f9f1ad15028709fba761a659becf01963de0cc42b0e16bc5432cffa00722a84628373198dbbe75f209115c4e30e60297c2d737996dd9aac330f4a3e82609dd33460438026ae287c172af8aeed0d6c71b1f9470d60588ebd365f20d596999d97c7a6f265890c719dfe43ae1ee5bba122d9d4cfc96b399f610a90606add4f0d25b903c7ddf6eb7bfdc3b9f926243108f591678b0e92a48d52b1dbcdf30ef8af74cfe34d48d0e02d0f99af2adb090c489d4214f3562d3f6a6e9b83b54bb6cfe6c1961ecd2eb2b7eda63601c835c5dc696b32bc495bda9b6567984f83e79a9d4ee88b140dc78cdb64a2ba8761a827cdc8d2b27e690c22402178ade602f2e9092a1b07d56d142bd24d665d7b10bc7646eb6d6823d5622f1fb08f2e48b8deda6cde324d6508fc428e3bf1a9ed608c196786db4e8d6b7271a07e4f73d9ef76244e3e10aa13fd9b82ce2ce72af2df7faaecaf95d885e64bcae16f9b59ab8e0f21a2f459d00a290b0dc57e10bf21ce06a029224ae15cb86bb1cf060ddccb1f6ae82d767eb077fa4ab0f37d02a4bede5d3f8ee3972a6a3a438a3cd92ffd6c1fb11cf2c68c2c6d1efff62b9f769e302f6c5eec96b0c05a942321ef8b9cf0ff2bb80073a8fe138bac5bd8e93f3b27e7ec7a78512059fa37b0b6939f3b1311cb6ea154909e9d316567e013df315e8f02a80e17feb8f3248cc3f11d1253ef3156d7f12d1f6d7a382d6b6ac6abd38fdb5d954e13ce005ce16bd5625a5df01883409f4ab938a59a75b7a816af6a2447b2c65ea55c0ec4e4f23fde145a26ef0b13b740b352809c10b54bfdf30592a8b0d507cb8210391d66d6f68d06f3a4663756697d472adb6ba78976b423ad9ccb3a3bead9de51e324fb77609729c78664f4d37c7c748ad9fad95af355be4f00a76cd5cc2c0b6170fdf3efaa2571bc8fc2d0d24682fec5e034460de55cd0426b8ad448551032e1f6ade6d96682bc38a92c296e5bdbf42fcf106d14c5e8a4acbfc0cc1f0bd6877c4469be8b204ffd5d7c0ee85e7b3265011ad5e4896f9f8a69997e321a797549cd3c1cbb0301ff30c3a136068ba37b2176e556b574a542db90250eca38f3b0e418e352b5728206d6d531ea253d781d771ad974b476a045ff14718d9a1820fb469e981c7b71ae8fe423b0a04278bcfc967ca602254de37751127fe3716456df3fae50ed508e529c2181d63479b6464bfcde6629e8179f8d5fa5b61003edfc2f129affa58608d6145de98ca8f1c0b3b9b5ae996a7fbc6326a9ac2880206fbeb1c99d0448cd1ac5f275b84e4be03258f9fd0d3f44a692513957fa083a462086787315e38aec8c09b96cca034cc6294359fe00285c607d41fb4e3bf25760ed1ef0802bcc40b2fce2cfe1c64f7c34b21d0bb1f5210360079ca8638ab42943b0ab8277f1cfb1e529073d2068a36a4d8ae8179c32bf66ca335d698f76db1cfe5236e6427e01804464c1ed4facf18ae09148c5a0cc9ebcf6fb6c7d03ec6782b7595816245ac2d1fdb3184ea49800d5d0f1dd880ff99d6016549d63ba2a44ab96f0db0d0cbd5fd4f67af1f1da0b1023883d4b2e7cb23cf85c617c180a771267fe63c70f19eee28fdc50c57d73b2718f8001383135b859f4c2fa3b9a12d095beba8857df13e921d9dcda5b87e1fce6038fc2f92282c717305157b6fca5ca2c23cb7307a093512f985628e75326e0bca2c4dc5ed44bed8e0cbce1238f4023089a81bf62b04a31539de9c8a0c867b791c18a34abcc721c0e90a1604e8d2855e78673367ce463307f6036850b81e0aadc9f81d8c9ad6e3b81d7850d4a46bd6772e651e03581a7a55568c9d63c1b1e8ca947174d68afcae6401b75dc7397be3c0dd76ad1827424f9ea9de8ac99803641535dae3eb57ee1eb1e2c193bf66addd488da55055bcf93172b1966364db4412e44bde64c50f7692a38d1536683af14fa057569cc7ef11f614a58995ade1b12f979005a53bee0769847deceab4f58f3d062767f7ac0511a04fea349e7688ab26425cfc369127325ab7fd24d73c4a8b23f099892b3bf52f35f0d775ba753098611ce35c56873a7455737a42672747bcfa99da8c8d0f06d8754d2babe3eb303cb06ce69e4046541ce63b6c28ded5a6fbf729200060132e9b01d8646b512356c92d8a642de0f62d169b195cc2e7ea2efebe550b1cddb5df7668a0d1f94a2f5cdf7897e46cb03b958ad906393c7d252b58493ce6c7d813c8fdfd5ef577a9e778c64d48c21b130c4f6a57985b8122f3cb69de015081cd3e247de65643f9d863fac6935cffb2ca23083d4fca9b8707679d9d4c3cb34d05d092334b1740ccf4b2aeae724902ad4fb4bceaa642b3ffdd5b564d7bfb725fae91f5c7ab9583abc2d80afd2272b14ec6fafbc51e35bebecce63bd95fa3f39e4e689034c47628345c4d8e30a73c36d87d289b6ec715a2769efacf39c9f19eefdb311b9800377c5c61aadeac78dba6946da4e7914415eced875b66f10b96ec98f64e58320bff09e8ac4f5969608171dbd4ab5883548a289b52d55aa82da62ba3d9fa59734d8f810bc1a40a0e3b2e116873116fdd8bad95471f16a14054fe247637febb6081d00e7ded3019ec03f76ebef5401a27f380fbe8a55bb4a0014f61276d9aa5626a34e7fe5a129a75ff130ccfd78cfbde65416882ce9ae9da57a3a04c67d22d3a12e811b2578fce5f6a64a09a86782bc15e5872e546dcca46bd9ccce5b787d17c70d6b075bf4c789ca184dedad3485a0526a61d280dcecd984fcb7ec663f8f491e91253675877987433e11b9cfcb5940a1357b55fcc5f977fc898f72e8199ed5d8d2554d54a55d6b4b3726e7fd7093996e271e218533f3b31257aa989f5efbdb12dce02d18a5188ec32c3c1c91845a17011ffede3f060f19d59b6565a352e90c5ca30eb252c6fb0cc845833e553f0bbe1822b5d6b26eb817608799b5b77c2cce27beb151060261f34ea73db94bb2fee11864aff76da5b10b17aba6634ae655dd396fd7e7155013fe3c6f840ab1ba9b25489c67f6bd5967a62134b238c325986c87aa005396c54af6357ca88baf5a03e353c8b0175386157d9221833585921d581f1fd3f5d9932b24d41895a5c35be91b35643e7091a7585ede900853aebc260b1fbe8b72d527390ddf46472f7c8d5844355ffc0b731dd5e584e13d65f2347131ba8a5161a6749458c1899b60cf9f9f8810889fc23b5d0fe2c843fb5675cfac6dc8ec8125d1c582186eac82d5e0b3f6df2a83eb2fc23c4c3f873267deb5ea86dcf1e3c5bb39df23f06560609b9fbd89511281fc7d69fb19764c41168a539b44f0603a52577c266fd601c0cc849b067746b4da78d280385ef80a3a553dabe4b137c50152f4e1de456d43e015e26f7d76e612b7be29b9f8e15c6a73653f5f7dc28aa245e64f076130bad58bbbd3b024c97e267a96365f019846d965c037116c74ef18415ed5500f12a1816997895f3bbe7b0fa1eb12a565255a64d5eceb2272027e45ecb0a1a8b5dc99128c002058c569076371703e1f10368c6cfb830ae8bc688eb143da7a1780dbe29cc4c83743b25d570f5d8609df46c807edbbc96358cde9ed0d9b8936271b3ade28001a6bfa6ff7ffeb4e6a6687e803b5e8f67b82e6dff215ee4f2caee571b8febeeff368a89539d145842526fef110174ba3a2d9f1b4a348dd25dd964efcf88847d3eef1c18fde81ce84b80cca8588bc1fbf9c9f34059808d3eef3fc2cef7636f7a76c533933b79a9dd2ae2791d1ab5e1e715837a766d9df1947d5986c21808eac758461596870b744a6a2862f7f5bff0c7a3460875b3b326e45fcec1cdad1cb4b99085748d69a62320f7e6c53c061a55ae20368a4e6cfc126cf2c0b410af545f169fcc741cfcec4947f577a1bfad47b5080ecb41760b5056a9bd10a10ca43677de0e06bf36b0d2bf7ca605b9217240871ed1ce43bbd07a7e77d1901dde15e173ca344ee8078ff115e954a2fa660bd4af61ac32256fa7d62af17a4f95adbdcd09b933fa47828d91a6b710a5c67195797bc789647db90107fb527b8ccbc1200bac302dc47a366d170314f5fd7b60535130d76832ab7a06ebcd83d064c1a1c5a7386b0945d39f8ddfc3503415ea22514a0ebd0ad74e3ece5508d83355cba944b12b669d6355a6143921533190eaeda0337a1b89ff9db0cae62a239025bef078137362db71a9eaa6d0a26fcda7e80a9b8fa4a1799819f0489b899cba4048c999fda79e0bb046d7e765d9abb445279efd13d47fde8b731a944af92da8d8965bc4e90d9da8ba0a9c385357e16788cfb663573d9d34810c754e86e3293a868461b241d7872911e676e73136557db1261573962221589850fa5ce049d2356e6630a142427a2cb2efecfed09445edd112323f0071f63f6a42035a9248efe155aae056db25b8004204d530d27027c34eb6937a5a05bd2096eeb1fa266a0325cbc7ac03270b751013b53429aa2d8da2de8c12e7d4996b5f1dd365e270285d2f3a65bdeea9346d960ecf015215a88f465a66417d12d95be2c0bb3d8e15163e0dc66028a30f1f5506558ef534ab28cf6dc2b7d12f49b0e319995efbde71978ef7121df58bbd16be908298b0abb6197bec22c598413283e7893f0fa7398369b83d30b29560ad09a0a24e029d0c22a7cc6fe53d84a7b2104681df35cf4c3ffd90b14cacb2ebbb673ddbbba291feae96498b30d024398676107d3efdce47353a544c9d885cd5cae19588a4b9e29c700c539bbcc119926e3d1adcbf4e8fa3dfb0d5c2686a3fb4ae7b4b278fd94db5efcad7f280488702d9f7675aafd248960806df3e8f95325298968a8e7bf54cd2797decb5bbea7bd3cbe34081c0b65ca9a4d0d08d86ff39f97751471e09f25b486dddfb2975edd51ec77d949862dd4a658ec974b8a5a381ca5b7314b677c4491e07b43a5a9964d95e1a29fc1d87cbf1a64296f4cbd8128ab13dcb60dfa8593a575140f5a9fa6a3708052b3bbed4b129aea88e66b72e583f1fc285ed6f835df0d4751c5d5f004ee0c65203ba9fbd8ff70fc255e497748f24c476d18c94089bcab8ae3f933563c6682e5452da8f760943c7efa631b2980e6589ad4ee83c88fe0b2ed9900571c3df6bac839df1a6d9d281a5ff627d41ada13b867735aa7377386182b1b113f237c14b6d806079d2f7c234a7cb585e12a5b16f7064fccff99386d58f91d9c235eef730660a02ad37dcfb0352b1da76d739ba7bd4982cbb8be48494acab84451bb39bc59521c9873ec9f53cedb527332c47afd919c94d777e603b405e8563248c9ca72f3b2fb52f08a876778d18e7d179f6437b64f79ca01f6be06d7b115b8d3c3320c2dc0ac59c860aca8c92407ca2239998613f44945bbe2c6a0ef0890ceb27467d1ab805ec960e6e58e49678a0841823632f62c58f540f19e82bf719e12bdc63db5363fc0749877539865a05786106b58dcf50bbdd015893b043b21bc1f24ef9eee5f2487d986db13c143d3366260ade522ab824fe82218daafe5e42c50ef740cb9ac570a13cb55fc30c9017228f2c60680f75ca89affdd376ce70ca5223078a47da0aab9bd18333c14aa021e6c088609d7a2460744006f149b648116152e7c814a5730bedeb6ebb59fe395e6b15d379909f197c4703dff34f8915b26a36e30088cb227fc1df108560fce419f462181e468b5d94251fe1373e0dd004fad02d690f8f28bd972e85ec49485cfcdba717db66e6a343044a2453ceb6403fa0795485f8014225d283da4c3aa6fcbbbdd6b04c30c96fce04579578882a44fe7b781285daa11ee71239c1b69791b8fe45868fe6e85341b7ba4292d6da1ae079875b33d7aa2becb02327a17bf2d09f6a42e9681df41890f17de5cf4752880660a35dab912d10480f20f92589d52ef4780ec28920d11de0de06bf63d61829a3d0894f9a32f911ac79041ef51fbcdf3f5b03f6a0b16f0b9e47444b82efa7c012e3bb9324c8649053433306d0640ae953737336cebe9b854186f9dbfda861fd7eedd76fc24634acb9cb925302d0bfd3751b7b6bab36ebe2ea80cb7c5359a505689ed5642118ce93cd783c80a2cf050f57d5acb62853367ac606fc1b8a01abb7b29e49fdb190e2b586e249639889bcf5ad23161f278086f244d0db0f9ff520e6858b68f5bfa0f5ca700096277ddfbcd14a4cf4358c0f042b1eb34bca6353a1383f5d310176262ba45512ea4f172f321efe971c391fa9e9876a250ab653fd6d5a8b046028018ae043da256b78eb26d86e6e89873476ae24dad26ec1d39da44ffdcd93d8c5c1fe0796bd46dbe9b01be0aeae841662c10ea28cbfbef76f0197cee86dd4c7dae3ba46d5c2884ae977c456681d5d9859d854a3e0708bc35fd8415c22ef4cb889bf0e66da72ebc635b71f5df04db801c76564d2fbd946ac17e27fbf995994ad26c3d577ac86b3b19f855d87bf3f0f7c3fd574b89901732dfacf2e13960975176f7418893b31747d96bd981e9b1463590bd35b51b7a2eacf1a7733f76a7d4b02fa2afc5925f5483f82cb529682f785c21cb951d5678a7d09f99c0e2bd98948b79456e4e0b5d9de80943f1df0c639ab8acd6c99a6297cc5a53a829561a6615c6c44b24a30a75174aac207a35fc429e1a415b0813857ed85ab49db6e523cdf9b122c2442a4fc2b4fc21685c9c4a5de8f36c0b405e34ddee91832cc6567d458ab76b4650020d270a65a562e75e06a3d8f1313b4d1d4d29d597bae9eee653bf8e31b82f9cad2d0848ed5daff73d99472c7e71d2f1be60bca4ee9d315196c096cd8260192597c8ce3cefa9cb6f129dcfbcbd65b5b0e19df5a1e81bdd423a2e26d11ca4f7aee99104530c1c8e3b1150669f16acf415559a38cb27eb6d637c78b1c90ddb5eef14ab9b2ff14ddababd7a349b7f6f5b6caa3a28c45835c9beaf8f836848f579598ae80ff9af739cdd800c5a3d7675c780ad66b2c449824d8ccf55a7669fb720604eeab427a0308122c3039ef9be6df46e34b719aca7a001b884e3f7b1d1579176aa4d365a25b6f3d420190e3cd9babefd8382b6bb12b4c38b981b08b5a139cd46e9382c01f361abdac7fb16b87e2c61f3241191028c770c3e3be939c8825c63bc4e523b389d1ee28189b5a2c11ccbe0aa7d3c2b47443028c89f3d4bc1bcac39eb61d91e75e0d372b9f27c8dc622a86bc0cc0a9c9dafa5e2bc67834a75805f3bf1571fbc5528e4c69f3e64ed27c1f2d93f43215ea0d4213bf2809391b8b9201f36ee2a275dc7c44d0d83de3b82490b65d2b399a7348133c4df7ef40e6dcc114d040f65de00a70cc0c9fe615c6fa90a2fad6dbcb39370af043345ebd9d8af094c831f341fa5f7658c2c1ea062948fef5015696eddd181d87dea49ac8bbcc2c7a1ea01ba1d04239153ca401bdc27aa87093a78b2020109d7cbdd39f279a7d67b14a5822fae28854323a2620033a5fcf9817a0d45eca7e2d120a113fd5ccd9fc0011e89398767f7f6b7d01d5a670b4fcb9c5648991817a62edf43d6964de204541a8b5573d7cc10bacaa1bb835f87d12985ad5fc6ac4834ce76c76e5dc34cc322c4220d9d65ca77051e7c1d4edcfb4595db16c641fa445401c72a24e36567631ea02e4875b7f9ac2ddb4712b79d1468c7ed2384ad5d90ea0825f817e42413de33eb30861ac92e19b1aada118beaddb179399008137f28a8f3df1509ab12d6f6ce7872521f5cfe4738722fdb410b3824f139ccf8ea63817d154b1e497a70e6f55b75e4decb73d10ddb0c57d7e0f74b3f4fb41ee57c2da1e4399c2577f28b7e911db08e877c366f231114cc9553c7f3cda2b75895fb60ce9eef4e0c25d253f689dff5e4f9cdc744c301b6f13e9fa9e30bdba8abc203c05879ff01bf8c3a3aa742ea5fffabbd6d165e50bc412bf5e18c60bbdd4fdb276f3bbfef246cfe36612ad61fcbd4498c18321a1ee12e6dee902c737999f9c6b3919f52125cc77e237a788640f262ab76d5c9db9ceb2d988c261dca63455658293b10842ee0b30cc1f928215e0308cf258ee39ba666b16319d0e21df8b9ed91be2e2feb9e117682cdc9edbc20b0b3b9ddaa93ec7a2d8f752ebaae57b7d74037c5cd64cb04746a38c0ea3ba3241319360e585c257fb593c123a653e6e0420fc540bcc0f072de6ae1a31b57dd5acf0b8607e04d21b727c93623e5227202a7c6432b308f74266dd1e1447a2d637a5259fdcd1d8729f341a7dc383b4c8a6ae0e78c34a55793043d2dddbbca1d161c300a8a7cb760298541c90a1c5a890b5257369b8fea0b4d14dc0848e644953cfd5196494e4c1b422f8e188314f2fa903fe93393193e9b76bb71c0caddba43d8586d72657a2d717e4b2c3a0e8bc33a6f8d89b871244eb04e4ecee26f9b71ae7d5c44f828083b0c1920d37cb5d7db86be3b18ef16653863762939cd1ab5c5e0cd1c495ebd0a3037725470d526bf12d21c2fbf4946ec224619c79906e8c87f0699be8a3621ae718aa232e26e43bf7cace7918ce34577a5e27261a4a6bdbbb8ac21a8a40b0c9682a0e0a37b7fc43306820b0db5fb5bbeed529102187fc3e5019185588d1ca6222a5e2b60faa2a93857bd7224e1e1c3c86128fd16993aaacaa34d8679e194ac0da6bf617144a2b1e844e7f6f8884df05ce1624ef1fe5d0895265bef2de61d637a74f78f6e3402923c9363656b7b91131dfc8f8f7360d14e01a25869f0f15a9355c07bba82e4969f5643519611d99ee9566138e4610712d55f22ad36c7acdc9e32b4e1e9b1ee9bd14ca122db05938840b8f47a5fd25a26072e2055494eb4ba916473e973c1efcef8dd7f0f04711b7e968d59d144fc04b9c6d8f951ab973441a6086ab6ab896f4d282793fb14c74322c7ff1c4c1c6d0544b7457635a6fe2632644344b1fabe12633b2f7d8fcb6e0929a05aeb2749fbc99671283c47c0eabe152fb6215bbc6e03d61b1ae955838a8b7b3bfa883a04f5156982ba433dcb21311fe9027a5b2e133cce16ac15786d2d44b5e4979cf2a8667d2976ea386eef4c85bcebc39b9d2dd216e8b4f7c68b7e0a5d7ff570770a20cc605e66470d995ef96f1e0acf6136716cd8a26b3b725db3ff48364f19cb2c640600d00d0d728d8fdac7b8a205ba8109318eb5519ee03848e79a1c33898555b298aa62d6da66188506638918b46926a99ebfccb649cd6bea1eb87fa6c1999a70937f51c4a2d485c6aa2bb5f98b1c8ae558e82287b9f34ad70954f8dbf3a9736604c43bc3062f8707fe88483b0865bd6df65f7e085593d5046554ee465a10ddb0c0b651e2b1031d56f5130e100e4544809a093026b88277e4e1f1e3aa40997871ced6e6eca44f183ee09ca679e4fb0796af62cec931c553ea788e75fd37ced477f9a58e54410c513fa79a4b5552b049fffd7d261d90a16f253a0782ec75219d1f7492ac2a242fc04c0216e6c804f8fd8f761a70eb747e1545313706136b085fc72dff1714ced89ba14a65a34168dc0e997ea8718ff304a962cbe8c7df8b759d76eb0f18155e49822d21d91dc8913c323a824da271f8c57d44a27be3f04991e2a47e5c8da2f0d71610be89dd4459b9a9f5cd4bb5ebf730a72617613667984d9a0e0ccf81c803e46425899b2fffe9158f9e3d7c36c2c42938d9433f764ed1f6d9c7d69e9ebf854db44c398c00b2612cdf19927de8bf45df70a5d4307e3a628a88a09a79d4e03742f89363d891b241383887b4447d0cf3e0eebe4a9143cd6873abfe2993b1f4d1b3b3a18aae4db4465385500ebef246adf17f1d9196f78749dba2b12deecc5c957e022f5b9dfcc3536bfd306a1a70e50f7bab1db22e98c8705328fedf3686938eccea04e7db4abfbdd939d56c0c357612ee3536356c0f5bbf1d428fb31c7b06a75c5b4fd5b020e6d9894b50eaf1df723131712344888adb5a0b4c07d23f6e853c88b51fcd56beefa721557256bd9978caca155db7f9c325f9564479c39b589431ee7d5da402e79ee6e04061c62c1f369176f6b35174b65a978ae3a4e8a25032d987dbaa5ca048734cc1da5f875f72db399df6e6a300db183e96ade56ecae019c4559c8f7c94899178c98e5071aece48a3e9f5a795159b2dfd0a1aa784b263ae5d352a890b7c2c6887d76f0364e2028d4f9046408e76efd6b5092590d39ec343facb16ccfc0000bfe7bebca2575b1f02c8a0aaaf5fb0bb13ac3246e245ace99f2186160a12792fabc0b390cb4c32f87c46f741c8fc940c4aa7843d650f90d422504bf97dd4825e533f646c6b77c4f004b7036b5480b587a913f05bb8ee470f0ab148727835b1659d8c046fd24276c95d30158424914e75d9b01fe52b34d5f76b2a1c98bc5236945fb46724e02851d46aca237fbf047f3055d6331dccab91c0bc20be2260086552fa7c958840843a3c38acfb24f9dcb506ee3cfc67f3125954d9090c1fcd629d1c3fc557b7d6ab33b9369ebc8b5b43f9e23673f688ffe50e6c3dfb12ac58aac60590991c9ce68502873fbdea04455459f6ee721570a87f87ae03a9f97f6e457ce1447358d8e3453632618701d62885ec4f8dd201e26405499dd7f317a8d2456940348827a08950d548b5c0b24cf494eb76dd0a51e3f5c6fda9f8f6545e3a6d1009775d78720f9b20ddded15c162f226873162a5076bc0cfc151e655e29d100b7a0d32c9c783375d1c6af0f39b51d927442386cc2c26337cbe5f4a34bfbb65b544b50b4947f72d839e6255a95fc859d6f1e34bb63dbfae1469be613472f22cbc703468d8552b9c691c829bdaf0d2e7e4093e940398f9ab8837baad8d9e4c710e4584685df01ea15ed9ed95ba9f6420e5766363e86ab8dfd1626eb1c7d2dba91d360821da99977be4642488972ec61fce7d754dd45a4d7fd9fc3498a6b7e0b7235c7843dfe8980bbd3a52c8868c1832f62d9e25a40986d061d7ca9d8fe29c7f234e3448fa315d749a09cf29556060307b970e5e080e90dcdbec4ecab1a7868cc5bad1037c07e17f961f3cb5641405f3d3c1439596a243f83b4f8576019712320ccc40581bf02a0788e3ad9cf4c44113d47f587e96061c61c06be84f6e35711d105f0c46b31f036356f6abd329c4e1e74f7d97ae6e4e0879be998a85257b6de6277d9c18980208e83d9bf266c9909a26f3e19941e728fe4ab0866d103644fd86b203029271361ea97fa93079ff227861aceb55e68d7454d1dc25aa8a7c780590a04756c840d13dfbde1d52d7df47d4146ed8d530907fcb13f6071e5c18acfd0a694938bca6cb081b7dbef2a646aaf55d4da9f3d42996a90655cb48144a4dd2789d75692530dc02a2635c26d428f2c6b66779bd9facebcd73274ebf333b8de26609bedad5739e73ed68798cf9882ebcb12902bed483bd905b92b3df495e708a0914a96840761da66379d85105f29e14e47a3e5273cc23ef5053077ecc513363379d2e6cb3aed80098589032cab7c20eeaaeb7bdae7e3a1c7a704cda4568138ce1ed94e944eb4ea72120ec91117338d0c86116db36f3807a70bcd98de03cc46ae9dd0c5fd3b26d78fed5a8b53c0c8f9566f921175fd193ec521c9914be68f2864715a572cd6b25948fb8dfbd75f4315967d5a6a707f1ceb81b98972e615d3e81b08ad5ef1838af673af9b6d63dccc226eda6d0b6fc1fd104f62b80662ff157999d7508f625fa2408b6f9ab4deb410ebef73750dca3e63d5045300d9b52845afc42f064bd78ce574ba9b4fce22aa3158bd058772ac2eadbf9fc77bfdf85dc745b529e8baf248a0bc1963f8fad78471116b9ac11679a326e92d87e03e316c90d15d2f9e3921e0bb6ab4b7ce91f12e7cdcd9dd141b8ef160e5db1faa47525a77a038558abd98757ac5f6313afb4f4c84b2c768e456f6de4a78b5b25f90926352fbfe83037f81b31251249fe52860f3cfa7ae1b20c73acb015821840dde2ff2de0470450b11aed7c1f84d4020147f8b9aeed4a37909bbb63508e533f939f23c2f5952ba6734745c51b837b72a398a4eb8dd6b4ee7648ecb55799cee7b6385ecb0b2e36b9518439ba550b257230885b83f72312e53afce7e7670b26342e4eb0a6286c0693c54abceaed1811418a9a289b4b09b65e84b3149cada8114e830c0403884ffb74c515bac074e4a981c61447ac99368dbe9cab8830911ba9cbb64633f444716f401aa17f599174581538918e88cd255765142a49412841deb528f44a64acb372498bd66f979d9189fa0f0e70e305015dcd3c9aea085cb0f1d79a63e92eb39b2dd2fb1b9ee9aec0213f3a4a848f3450e4a6d902f5435e234588ce4a7d2c9dbf60de27227ff02ee4ca19314d72674fb06c00ac7e5d15cd05fb35e973f0974a4718ea9b0d35bb4064a6280b654a15a7188c5d5a5998ba1f031a3baecdf7b608169c0ede84d91c9a5f73b0176e5ab2958169ccc6022e0c43481bb8e6217ddb1bd9ba8e8446aebed6afd163dbb6873d81afcb74b034085afec0d626b02fb10839bdf2279acec3d8f3f7c47fcc3ddc8cf1f08de8c8e120d9c06648acbd1ba6824ff74419776b73b05d797a0bc43d77eb75029112380ff4e87e543863ae29065e40c1b2b1b2d62a409a299ee5868036835627dacf4f9f7c84fd2f6707d823eebca0e8ceb2bd258038b137aaf43e0e937be762be5d3a6545e439a45090d397c8d4a068286836780536ad99cb138cbdc6fe5e9db3bd405ae6eb86084be3a49c8af88682dd52a5fa8f7fdad76cc0b452b3c37b27dc3cf66c57a4ae59a3687950ad3f1fdab3002fb2281365348cfcd9306583eb79a9555e8750dc95260a1b277c566babda92cf2b3ef177854fcc3dbac88da1536eb3c6d6fa3e336ed3a7a6da006901c845619fa00596af8e54bc1980aec4aa97bc98266c248bc038013020fdd128db0b9425e8f7e3165f5b9190fbf2dae5e317485d9d103695cd209d5d247ac7e1122bee4538b5b74790277ecfd2051e43a34b7c5440d1198a1875a0501eb3f519ac2f17553c5e99a9c83412200a519251d4d4ed1c84baecf7d8cfbfe4a7e50d789cc034a21043fc13fc3150314bd7a7801bf9c31aa00b7cbd9d0fa4ef0636504f0dab63316d9b9a1f4703b3be23170549fa3a29ec02f418d687589f77939fe068e41abce460fe118b04fd418f28edba4fe70d8fd24b38078a5c47ea236d73610ea116666a49acec52fbd810bb99af1dc5bfc4eaa634dbf2178151acc453f93567f015f2a25002eebc1f778da195b7e9cf683db1a85da98a99d98614f2c25b2237d4393f5799d06cd36254d3f22a53df5133cb1f43836991d3f7529cd260df88bc47e4172ab045b66e081940dff797b28c632898140425c3f81a60236b82522c0da7f0e0ec7a8ccdc73cee175d3b4543293135c31c0e0c926c7506920cea1d0a1eed64ede7572b8c77ade1d95bce10dfa69fab7fb5ba64055800593465dd4c26717e37a66089f550202a0530157e5274f3d3fdae187444f5ed641c608643eee1b361d78c9ed8070a85150c80368a84b14c9dba5b20a9059f1a05a60de938ab914a093b2e741e891c02f638c73c730e60ef8cb5d9e5031fdaf6918750f192ea7a76e035eb05d7556ad64a77109c5e13bb3ac7627d99165567dfbcfb7fdc7bd847ee7dedd7864353f8fdb7a9939867d9a5ff4d9ec9727fd432d8abb43628519cdb6fa49ce49064a421a89bc924cf6286fdec8bea6b5a7b8eb606f584d44c7194d5424f98576dc4b5ce7dccf65509727ed52f8d7210095252403023473af96eb5892cd3881f2e1f4dedd4c9b0755b70776aedead14e2606bbc1ea3c300984ebf27ca69f36beb03c0fe3c13d9df79791d828d52260103be72b832ba235bf1165250b608e2cbda0c9c8d3c96534802534080b2a4ddd5be4f269f37c4cde9d43dbb42fef8d507cce8b8e2eed799c72a2fb836f4160b5e5729192f088ab8557d51b58940065ceb4b48fec1873cc4b178166d15d441f45625f45af62c1d13863feaa8afc320bb36af0d151165c122a47d4306d075b344974835363818009d86c81e90345cf4b7d81786c40318a371fbedcfc325cf0e853fdfe6e91e99c07dc9430c04e6069b9e2efeed0eccfb161ca85d96298ae6dd67c395b78668d5818f567f2039111a7a0c52a21d84ef72dedbabe83f811184a95976b1a90dba5aca60d0313c546ea97d7b2e40b34ae88ccf4f45e28f05f16732d7a0d62dfd86e40a51de7f2b9b66ed780476cebeca547c8eb71ac20a245b1bf7445e64bce260b8871ead95f708974c3a93dcc4ee979975daa399055108854c1c3fe5a07046d13169c084b2e4e81821ff73d5d20e7556f40fa152226a6da48d5f86cfcf1a5520451c3c1e534db654b1a58adea167ffeea90023cc2b0b01710323177059e1c610154cb234d5ea165dcaebdc2fd9d9b66413b8a6848ea11a673f207ad76bd3ab5399dc0ed58a3ac0ac9d3c53781c36415d54b452a4a78e1eaa7046d062e3105541fec8819439da85ce53aa683aaed543704aa8210b26c1e6c8f1d1814595e3bce2d98a36089bd722110bcefd651937892ffd36dbc34f1284eb32c49a1c134ad460c19e01b3f3f2d40f664d90020ae8c546bba9ccf5500171ad07a55f9fd299d7518f00c0017f6c25d4aa01615fc7eec160ac2cc1ecd38bb0324e54cb466c3df4d56508f5239e1b392a50a8c20946a6db9220088d77c494406296921e3ac9997c34f15fc5c39f2529eb2bf6b41b0415e90cc9d7e8a83256cc59b4607be49eb76a7dc07c1ce3d0512888705c9ea145079085273f2236d5bb151dbe7d1bda2ed607fe51847ba09ea6431dcae727ec1ef0a201b8df9e148885e1308425d5c7fde473e90b4382de8bf5e215c3be357f8a2356348bab00a2b629dee017ecbd76d7ebd45fe4df2884e34ecbb86ea371fca29496fd05327c3b985a069a24a32380ac9e4b131ff48d58b1c528b941dc6290cbb41ab4aad2a55e5e03a63813c2113c0740029529eca008d906dcda1094571f5d2cd31ed79e9bca8e815e206b3ff3a7b4b82b0d30775e0b77260a42b1ccd0a58a91f0378df95cfc7f8dcabcabd2d7ae3b603e9061c1e126d00fde94b4b625e953b6b781da167c71a6a7ce0792e7de070863deaff94d74a7ab9dd2e3d39519a6c5c864036f7bcd4663fecd163d78a72a74d2838b6949eb7ba85dacb2eecbff1af2792047b036f77d488e5256ea16252257bdbdc1ca3d18d01c5de00ae8ce7d1c4cf103b2bd7a31dd52fa92d945da38eb9070d6f11aa9cb8bfaebe133cdd7a72f94f0fa067da0481dcc86e6eabe115cdfd8fe2e2c63c3cb3c0f75a4655eacfd337ddc82f770442d18ef9cf3993a9d1830217f50917153de7576917c533247a6725a0cb7447ebb0cf7516e19781a8ea8d1854349db9d3bc4e4931a1fa4fc075186dfc37ac10db1d3feb6298c1fabc8d897e1c806e38981c3fe7f252371b0e92efc61b2e787279f4a8138e7c6527ffc4092de912378ae692e9941d0b6d14354dd25900912f9a907dd970db649dd965c959e60f4d174ab0aeb7bc016735e8b847e231bdd240042aca16731926f537fe388b6496967b750a94cf514c9296805607b5f44451bc622486ff62e7af5c0d243503ff31d1c753d9fa3adecc8f555445298aa10a877250455c43d412719aade5a202076fdf080589a28cbeace5a63de77d188c1fb486d888528c5142f92e54f005239285cc4f8695c05ed32fddf0b0072bbf7642a1daff7246055cf35e077acb567b78c73094e583b9bac3ccea986305eb4322bcb923b93187bb3061fc00ee0b3d10702d7890c4eaf4e5f3da2143282dea0b12c3f043818914ae3ea98cb1322d73878b5d9920e87e6e00ae831a3b76484e0f69d35eb15b053c545464811f9c381337a80a603ca91ddebab47b72d6c80db4cf0646c579a136326be69bae46cb6ecbe23ae355cf7181981d8f7b8e16b3303aade349f44c005602c34878690d91fb7b4bbbaa75a91528fab18c3c8c1380c0c26a98dae3a2e441527e8c7e7df331a506eeaa2d299757e8b0cbba97a91f64e36e5a24cc83b00fa14b8a41e6fcbafab7eaa905c04c30755c551b2f0f1a24fb422bbd76090e212efa160103344200e83545a119cd7d2f53e8e5e6d89b1c75f12a44ddce7b9e9bb4710e30c853ac8d024be6f5b3d162941e2767c61a7f7ac5265d08a680b87f07bdb4d4e2037b99a6eeabef33b7ca6e7e6f4428f6814e294b7c08783525e1f632fc2a43dc057264bed23898edcc35493222a92dbe28da74c07c49fd725670ded86494fbce9476d3a594f4d96ccc3302a9e861933dcf46d03b7648bbe7bca88d9791b5a62694b34a9ee0d6c9d5600f0758e7e0a2721cadd048bf59d84bcd7ab33a5ffa8c1a237dbdf3481f03e6368b0c1a86ddf01b962520372bbb8e330a70cc684e84e1a438fc571ad9bfd297288135934aa4f1310849bc9c1658006eb1639d4b8ad2f858fdec1d5a4aa89259e591e2cc2948ff126caffa24bf41bf71b408da6b5107e1d65fcf37697d307ef3a3ce742e5d117e7bd4d095dfe8598213e0925bc9c8da414b09fd21451ad8f3531a756f15269614ea1ed728d3d37820c6e90578aa43f8f4cddeb9ce97b345840899a016591690a810c5773572f34b68d1f2f1538dd7c541508c990621d54dc2653bb4a7e9a1c637515538840f836d38333de92ff70997478fa7e4eb0b447ef04a96b2376d3e7319b49f8eb0b9c656bbaeb8a000104f3407e33c23030ee9d5d92a2aa7ff76f419ea3b1c9a8953b30a92759a8d0fd37b50e66c8f664792da1448f8d12d60e169382da435c038f10be62dd1c0430f18eb30af8c14512d3311a28d4252fd4b4dcc04b5da190a22c6eda7ad837e470b9d8ca3254f89a3e613ddc74c1865b5386efc7a8811e95163fc4c2a61b738bab3ce75e9450dfc38a52a59b89746cbb216cafa6faa0236db5b86747e7d9d3b6515bb19aee0a85bd4c2bfd76c1916e04db2e0d0382efd97d2ce79eb9370087b19faf4f269e7fdf64f6c30eabdef01c5a4f347dea6e28c48a55643ca36881ac5b283a9f85a56b203c3076e592779f91d3a00344a29eefcda31e2c66e38c6386367a5b43dfcb3978c891feda33c7907d7e4a501376e1786b9cc2ae1e0a60b9c0c979a0c1c96b9c126f647c3bb21abca0d4498c08a4544fc46ad1a33b17b105db91390689ecdbe0b9e6b5cc1d65a52a51d7d3a714c850c14c9329410c9efdbbd55cbc43e8568b01957d664de2a82c04caaf9e55ae5a34c533bc4da5c2a715409a900c7dbda950463131367613ddb0ae44c73625fc8f293e4002d5b704645c08098ead5a0fde1980d8addf0af0efa1288d569fa62d6b3f6227d1b4d628d1142f5eab4f7f1302bc97809b1b022e5976b32da3537a192938b8716307aac1972cc5b97019f4b7a9e5e650d0569ef4e7d12f8b123b1ff1d95d3d713a18dce009364a07d01b3b62a1f3ffe29130bee4f3b275dd27fd6860423629b181194a10ac44077eb2323e931cfdf64504a94a1e7683110ee8a21e67396d09b85237a51d824966527f9e3681ba9fa6db51e571d7d6a1d04d0f9bbd9d1036316a67ce225705018d1f0a9b9817b0d01dc092beb4e1290a7f12b22cc32697a75e17b9a93ff817a721ed0c696643353b80478a8d41e92b0dde35d7f2918f310e829305711683fc8c2119f0759e4bdca673ec93f4f0837aaab4c925925504fab72f35bc494a4d8bca2b2ee392af02422b2f80f174519fc83a06f99290cc7f1812a32511dc9fce9499947c92cc12c241923e62e98824b85ff3ea4979bd4362f87b7a89204598f51629ba1bc6d42354cb13c093d00c7da85b2523fee61b85573aa7d4a3145d518689ffcae21ff6470a8210cc6302bcce2459244e6f9173e1d9447726942749fb6bb13bd0d3479ac5f1e6d70e104990f2c9311046798f906aa215c002ae0b918af3db1bc591a937d5f485489a132fe9098bb77387906ae54d92d368ded939a069d0866279e0f7cd815062dc25c664c168ae4a11b9f1fedcaff8e3c37b6f7b075e737354074381a135291383a35047b1dcc7cf3b815c1b7ac187a4dcbf64fa5ef83c4fa2c0b4f5b7e024af32ab5d72e4e86a92acf858ff0aaf0fb8fc64fa12d0733c6fc530ad739df51038fceaa88e6e47fd80a357f501dc4ba5de4b6c0c573534a84e5aac913bdfd30e548c8009f06e7281d4b91b968852033af7b9e79b644b1532b9324b9788ab6ed930236c5bb2de248231f3046f490131ac34586b43a3c8e0a73cc756a816c79f3f10f12c23501947b29617fdc2a45c7f361d27966f73b1b3a1f50cb0052dcee33ce739cf2da8fbf9b7e5734c5a7fb8eea9f5a598ec6c207735409ca3401894f634fc787fbae311d4bdc8c99e8986f306883d7185a18e71b5166cb9b84cdaa3cb03231ac3053beb31ff3d87838e53ef698f9921a0ebe69c9b1526ba5940bdf21fd745f6f2653adc2d3c36340a6dd7c9ada045dfee2349e26a62b437e0c8f4fae2c7eb9eb577c20886d8a8fdbd02d245c1a1478f52e339e8ddd71fbc6d2cd1668a44e2c82b311720996b8da7111658a04f4b756d84418ef3e99713cb73d87bb4a14f69d5ef4a8b8cd6d0008164fa0a802c0679b26e155d801b40a2c77453dbdaa5a582d7c9d967e8a5706358c68c6da6c3e6746f0648401f896f1674797b0e14b354c27ea94fb12ad6d8494ecb0eca0eb5795b1920c618b429b4e95979174fd21685ead022e7ca4f87958c8a101b8b3a5e0a9d64393395b12dfdbe7e7503b62db0fa8813c4eaf1ffe5f190de55e83fc3a01b10a647d77cc49b07a258cc4e65d489451f849f6aeea5bde2aedd8e184cb9c778a3676dcf87d2bcbc19647bff28953c5d06fa73b860a16785238f9765c0fa958757b4791272cd8d1fae302b8dc47282b782d5c4c5ae75a9c02a3e911a79547df96d2c2306a2e347e83a8d8a126e6a3a21cc46e476a706af9c42a97b3f8fbcc0de5cdfb59bd6cecba11bbb93ec1bac6422b61277eccecb8b28b3d97f0051b89997c8c22a9f517d9fee5e16606614fda11940cf388c04daa1b302d3b0590a9bd0692d6139b77546d71454054197adf346bb94b4f2e85e502e3cd919bb43e8b424339e2af0e7070b035271783b1d7d48ecb6e63f3597d08a9d0677a44c29948d9cf9570e7fab1ab0d8262bb963d62e895c9bc8ea999f6f8770ed5ebf75a39dc0fe2eff88d75ae19690e0f0d52090f18bbfbe39697042cfb5293692f1e66d76aad38bd919b634ee20000000000000000000000000000000000000000000000000000000000000041187a86f715ea1475c76d354d556242c15f6b8f7c441cd862cc7c89d89a58bca02ac74c422eb01833db93e4b067e507da65080f93cf1815f4cf1dc0d53a2802230100000000000000000000000000000000000000000000000000000000000000","nonce":"0x190ed","to":"0x91a5d806ba73d0aa4bfa9b318126dde60582e92a","transactionIndex":"0x3a","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x1f02737dec59ce5f29b7e11309a33cea7b370eddefa1a8007ed3fadfd1c6b23b","s":"0x106ff6938ec0a46da92e74768b54926633945ab503e2f2dcb69469b544907586","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x2d679b567db6187c0c8323fa982cfb88b74dbcc7","gas":"0x5c90c","gasPrice":"0x7d9f6fbd8","maxFeePerGas":"0xf49895cde","maxPriorityFeePerGas":"0xcfd6ae0","hash":"0x45499074aa521ac4151138f0aad969bcc2dfc1648d22ff8c42e51c74cb77414d","input":"0x003851f8368551cdf133121c7cf32ee5690000000057b378dadc7d07581359f7f74c422f52a4d750946601a4898820282002a14608e24ce8d2412c889246951210c5eea0206041c4025828362c2828a8a860418a28208a224185ef99505d5d85ddfdbfefbb9ffb3cd964ee997b4ff99d73cf2ddc5b063a034cd01e114eddde75618857bf21dae562932ea35bbe70493443b0d3bda8e6161bdf9a2e6e1a1d63845cef77f151ab3e17f6819ec2bc7388893dbbbf49e9f0c76d8f4e3a6d5cb9c46eff41ba97c0b3794c105b1a891908a7812b16b0d1d7780802e8c7621a188764369f6bba1bb0c95c54c4e3ecad237716b875175c0e27d3cb133dee5692910d9eb1ceb4679f65e7247f51ad58b4609f4c41fb91c48acf7b7d2a8532654b741723ce4f70eb38a521e9948c62bb5d73328e2aa5e7174426f5da2a4b1c6ef04eb66b2d4d1a48f0a20cd3d8b6bff8794b3975124f8d8149ff9c0b714da5e23b8ff418940c5dadad787c4298fc8486c94c44d45593bb8dcf6cbea18578904b0c99dd61f2b7653a1562b2cfdc3dc96fb15db01fd11710145c7d6b0957b60eb6fe886a047920fc64a496565e715ce7ac34a51a8fb632f62680c9de88bce189d008e29a23679115012cd789ae2fdf6cf5f4dac0cc4aa2e092b846d3d3b36974cc62244625394645ce73c1eaeec885e6dedb131a1d420a57f945698a9e7c57befcea025554af9a4cf6a432908061828ea86605e8ae7ef301f4c388060625fc5cded2d60f4bcdd4270b2cd05a133fe45e31ff72c0fb8465065d16678ff60a4f2ebf901d2403345bd6c4459c6c6b97bc038b3cbf9f0ffcbd7fe06fca91bff93e504946e2051d05e23e28dcf2d35dd2d1c2b16da8fffcf65ec0b789efb1afec71cf481e5b4476b7df95109b64e2c1950beb3cf3ec9a671ecbebbca59aade6ca79f06328bb06669266f9fe9a6673c50f5aced1aabd49947341ec338b82d9ae31d9fff59a0511ed938e016432f9c5a001a7d5d34b54a7d9a2419456e3bd0eaa860ff52e69806188aec7e559a70415ccb6653c885fa17efcfccdb680026e43c9ad0bd5b379d4da2127d429e74dcb29f3e45b3ead08e1e85c2be6505fac13244c6e528ea261329310d9b80b16bb7b562d9477dd95f6415de5bddec30bbcfab9cb9bbf88e71eb47c16df81087fa93c4b39b5e0e1cbad17cb1bbae73eca0e2c75f73e12e89371e79a4d42babb71e9da013fdf5ff1c20a45ac00a02bf1ee09b0efb1254f4862526e5abc8cafc311bb27abd9af1464ed617acf4c1647dc8765d530e4b40fed95768dcfb24a0782f32fa6cb29e165a5745f2b44a8875a96812b99a095edaf5afb1144335625ebac2a489d9133676bffed7d161671de594b27973fdebe55eef99d65ca83e607ce6ed86d32efc36bcb4bffeb2062a99371c93d2eea8a0f47519e0b40ef21ee8d9de5e8d8da61657072561ab1cf9a4b1d51da9926a2d934cb9be7a548af7a5835758b5164f249ef0f0b53051779089dab29284dc10c24a1ee298ff1faf3aee4072cfd4ca19520b23941a4852bf56dfdf0eb075ff435f87aa51ebedab52cc3ebcb4db9e133e57c2aeb10a836d1f5484807f73a9d411e059283bb45fc028cc8f919abb8ad2b008ff7a95ca576c0c04aa4f243f10d2fcbc425ce014f5fa6793335650b99beb722faab1bae677d9939a02d3de5e0ae5d5906ba024cd019c11f0d51c89e73b8cb3609f7faf3d127f969f3beddda1a756fef93ba1a4d33e4c3992957a9c304394b7760063250a5519ae83b304c00fdf0a21e2acdec12482b724df3ac5ea472c065a9e2b7c8de28454d72ced29d817ebf3126b6928c2cd7cabbf0cee395489744896faea55699fc7ec581ad49b782e1bb83bcf535468b91703bcda0c48fef1e919dbbf30aa45b162c92f0e01496643bab3d9020b8e471695769f04020557e8d0fd5812bf346deaabcc118c92dfa146a1b5fa6aaf5db5e6fd704d073d9c6d549004066b97db487f857716ddbe6cc6332f7ddba3ce2df47f0f25911e833adf8f345677a96c7223a3efc77a3f7a5d24e543525591d1fe4afde76a4a3fa883efb81fb9e324c5727a5d2e7c04013a249366aa8f8242373f9c0aa55a7366d364b0bb89ca1da127046eea1de1d39b917fa53d6acde40da381a71d342e3fdbb19254d7df86704eb979ebcb905762ad78a852bc948b97aba45e99ea4fd7e0340ba70097b4884abc81c20e99276eadce78b6b5f075620424b9a83af6457cf29d9fa52b6df6bb7054711e789cbfdfd1bccf3081ed96225866598328089398b84ac237a46aeb513780c62f5ba256d9de6392fb333debe7b2ebf00571be5b6dfb5298b68c0c4f8a281db7b5a819b91297d29e586e6e78dd685f9810e830dad91e79459de4f2cc484ed9cb3a49eebe9b51975dbedfa1699e3c2fb9cd6a7e9ecde33677fd57e07847bdfb9bef75f07bb9f55f73c695a97ac188df3280a5e92f0a4f1c4adaf8f53bbab4682a9dff482e9cfb43db9dcfcda1a466cbfae58cb09a97d8336c88b124bf1cfff8a603a78299b6e6a9ffec57be9c75d73fa3a86049c56f127d5f3a6645bec138e6f9ee98510eef2dfcaba7f894ce575889ed3c89b3c1caaa37f0901d49f7ef9d46c955095899a76feb44cab15d918d6f9e924e77ef594b9af6e7a2bcbd2190758bcdc73a2cb5f7e25e9afd87f893b653e7d81b294fd6e0bfca1f5565a21f725312a2108c950f275a4c0a698ebabc567bc1d0e7b1d74b027f1dd7187cb584fccf0206d997519a61060628e2255ba437bdffb3cba91b64c87899fb19b5790ebbe92b0d55d2b0eeceed76d6e91aa53c6ae2113e33e299d531c4fe70c696050e654c13387f0f5a9006691089779741473c7c7dacc4503fe93cbf7565bbbc4f715dade96b451a21f1e36920bdd10f42f48946f8ac56ab3afafd84800b2a9fb6d643cb17cde43a619d7ceaa915e6f5d209ce489a8b47bab1eeb9a93792c6dc3b7676dbacfbf3e3cf43e2d68c79522b62530e423f3ac341333908eea556442afd4a7035384916fe5ea257e3af6655cd75ed06f3498afbed542b0ad0491373609b66dc14b70fb96868a8962a2d7ee4d16ceebdbf334a8758b9721bc879a8ff8bf9f2fbcc6f63a9718a35d8b5df1d6a38bf1c6123b43566a079d88b94f3870ea1b9ad8d94d2db14bf12db3ba58dee361949713c756937de91dffcef9fabe2f9714589d51e3a72c7c896ce9b1fde893f5ea895975986ed8766eb7c7598bf7371fdab658e7bad069a9b52f9e9761ae014c4c15c25b1f98e3e0dc1d831cbaddb6f4d3a993f2257d61f345b3cec990f79d3edeb2f5ea94016bc4c4448c8f9815e81b7433017a719d074003d7307e3d627653f5cae3753642527b0a49b76bae643e4f0cb4fe00bc7b71202d6b1ed7329f6ec4ae64ae463ba7cae1375d3ae4b36741ed88e3dbfc48efbabebde8c1eedd487fb8a9f42b66808936bb6692353b37642efd113c62f14a711f42aa00a0947ef974dbf1c9455e3c1ef175af9cbd8bb729f5a7069685775d8ba8fc3552e37e8765680a58eed27db682227eb6f9f12e9378bed42d4292a77ca86c2eb79f2d289b557e5be66535a2f7bef852cfa2dea5d97c52fee7124916123d91d6d6911564a5c2be40110b99de71e9d9a6203de69a6f7b57e54fa4af76b82daad4021a3fdf1ed0cb5f2118646dbd38f2ff5c7a107967eff06986db9e2bb8996f3dd20b7905cb8f091bfa1f9ab52307226009181925c4cf729b64c39add884cc606b5cd0ffd92167e5871ca3b85b0eda19eecd1f3876fb98ea4b0ba1df9cb8b5e5a87dc74399170e34ec1a2b29df609aa1f86f24fac697de3bdd5eec694516c5c59c6160a30d90211319e50ed9384a8c8e316331b2a64f65a2f2f72b3793163870b4fbec75e81af7d4353aed284c926575a821938c34a619bc75358126deef5ca9fe7b0a5e69b6a7c19935505c73df8f2c06ceb3c09fabd79df5e67c5f209579df95d20ad0491ca79df3ae257b8ac3e95aa302f84de6fc847c8cb147bbef136f355a240aebf1d19e1db26bab8ad4c6cc6d6e27c92d0cc8420e0f9e9cd2bab9e9ef2196e07f04997abc6c1054e015c72da67366699fc045c21974f9d6433740a3abc30b8fea46456ddc7c3adf8ff00b85cfd8e8b6ea2ead437ba951d6d5c6c73322d29be2a35e63081d752933b7938c212b1289d2775222261d18633dad1e73e5f323ff2e0ecf36784f52179e6bdc31c5c19616886a139ad0c632e47d0d32d1ba2ac6c0807fae7bd766ec53b94fab2d2ff22a93483fbb6445e72d409a398840f476eb72f1a0ae8143b70fd04676db9411782f83dee540fbe6aa82664c779605bf155030785e13d8f0bbf86951c62ecaa7e25881f491ef1ffec48fc67ecfe2b9247df77673fee6cb0f66f64fb982379d6deb13a79a3f893488596938b1bd7369f9b99832c4c3c23b04cd34cec0dc5236c4105ede9dcad1943c5813cd18525daa70fcbacda879ad6675aa6bdd5174f0b9e9b6c53e67f7771408aabf9fefe79e92c5e8a6638ae8f1e38b621647d0d51aad753ad3b5a5dffd869f18bcb9a8f73c76b452f45c2f8ef6bbc39c9a479bd1c66bb74f6e3f555db06f55a1566364ace5a637cabb4b6b5f422305086e8542d0ebfcdfff1d1e7ac9d2deab374165267cd49df53bcfaecc76a6139337e9fd029079ca503816826e13fb54ca2dd757e147bf8cb7d793ab299cb920dfd306ab4654bb7661cd83814994236d8b50cd984ccb5d210aa54dc73415c96b92d6079d19ad0da60496d2b64f3d687b8cb154565602ec004b311f96d330f172d255bc6f0c550afe9acd9927abfc7bf67c37ca527edf3f61625f6dd9d32ffe64cd0b10cc433411bc558b67cf11bc09f8f4d7f44bcdf6395fde7ea9f70c80cd66aed764d8dd0ce88679b5caed8fc9c2ee8e32d2ef5a8ed9efd1e418feb40aacf7f19f16c9a1b35357f8bf8049ea7fb91c7ba47d670ec211f547ddfac75bc552f487263f859af5dea16f91baf2104b6dac8af88eefba672312ee7fb9f96886ca51ead0fda9213f8aafb5bc4a7840f65a01cc004a510ee5ad1dcfb0fb650b747acbfff26a26f568544c0d24186f8ee4b169615fdec32de53b6d3f2813ba5b7076edaff3224797d524bba359d90f417140cb222acc5ea65d83c0e7bab279f4bd8b9f44e0e7c907865bb83d3ededf3f539ee85c3420f10ebfb0725fd91f3cd2f3cb28d9ea9911fe136e6acee0bb05a7f18bcd4b5caa9784b19f63dc0c47623730f54eb3f52b2610e9cac31bf560d29def6b778e3a6512fec915eff7cb1c18981292bc892893d581a311046dd9c132b6eb9fe354075e0caece17f573454c035ec85e973988dedccbb7041ce2801733da9f782c8d85491ddce93a943b1b647b41d02902ccebdc3c82b7901adb91cbad9d18b7915866a1d9098e1c43de52e70477048d02ab565547ad68c33c7138d30fb165f1e5e76a837bd74a4af58fbcf4e34203d0a1b56be539f2ddeb3706d3f25e663ed919a97ff8abe62a76be6bc6fa6e61aaf2c8ec01768c7eadc9bee7ceae30c31dcba975d6b558ea932e22a71a5c728d2dce05067b1d4a27dcfe0438fefcca5cb4a95efe83e63a7dc247570449dbed353e7efbad6ad8c981a2b47de139ff5bab370c969e154b9e4f07f813a9310a9c021f52b22829622dba52fc47814892fca57ded9158663b293356decac92b391c56d7ab26702767e30b9726aa51bb16b79ead28fb4e00b815b66ed75006e443a9e41bb5ead6975bd3f8326cbb4de758e7907ef62dfdbaddcb7b1fd85b3785ab27cc0128d4a8f0306ce3c92cfe0f708ffdb335bf69c55348e88597f711e5d35efb6e05bfb9d266f107bf8497e8ef403b791e1c3f23d6f83f7c7f2c7bdc63776dd4f3ab24178e30daebb616cec37cecfc9756e2809a6d131c648f88c6eaae019a9c3579c6287d7681f8b5a24bedd607ed629eae12f9e2bdf55ca28a01ebfa2b20cf30460621e22b49241d178f5884481f3cb5e062f2b5a1f90e4a66da24bcd9328d9501e5f7369ef94ab5cc9c42494d60edc51fa6d5ff843a8fd5d5ff89743ad44ca92594df4fd090a213696a51aa7c3845fb4d89b7c8ce12a9e57ea61d3651b8868e7d8af070f78ec48dfba75613df791126e81aefbbeed1911f5ee74eca37da5f0c478e8d9d4c6433984cb8ffef678888c982b7fdbd36c736ccbc9c74f65d3b6659d3f23ea63f6614974a4d62507951089c22d885256b29d96a7f196cdde15515ef5b95bed572ef4bd1b712467c7bd67f96b1674378d8f87a07fe35443630157d419d038c7fbb0486d5ff6dc908db1319271d24b7d8ec8b0cd7fa16d812828368871866b96fbd5fbc63f5db2e85991c937e1e7fe1dd93972d9013b5e56e69661f40026461bc9fde8a9a46f19da2be783f9f07695579e22609fe4b6252ef1ddbc0bbbbf687d9e316570db32c1563487f09b5e0ef117862d5301762222e99860629271f05b8d38d06658ead0e686113b9aa67ba89cb26bdd3e8fa4d64244cb955fef548f69f9c5059c0de748799e245be3b9cac822e2927319db667124ee46639bc3b462dbd6ba6f375e94842e4e5dfde5d409975afdb02d03b52c27f33f98f745c0d9ca2d2d3405f2babb8231fb446e87f1f97b776e3e7a862db3fc7a05512b633f75ab70bd7244aefa306fe9c5975202ef0d360dc8b725b06b961c6257d02b4d1c8867d3a1817257a7c80adf3e15ac7108cfcca555bde972db3b1bcf38bb19b35839f0fad1166f936c23877501f220ff81b93c06ad91f798214b63bbfc9e9cb6af0f41548c3772da35590ca55d22b6decc5d1d7b3149fb5e71e09a40fcd997da77eed62a8d84d9aee853c68fcbdd79b210ce34a9ac25093a57572d557d47cfeeac5beaf9eaa9e0bc29c3065f59c6190a303903918dd88b9b4c7624db2ee1b48de9cd4d0ca875095650d5c8b5d903717d33bc5b1635e52a1d989c72e3d397e29367db456ffe6afa124496a6f331d5243f40dd192b1a2e230badcf97acb3130f5e2af588fda4bac803875788d425867687a67dfbbb7da5fefd9443c7b565b79d3dd9e669e76d59a797b3ed7a1e3a580b98da60adba5c7c71d0acfd5bde9ab5ccb69fefbf6915976653797ef913ed65260a5c6286eb11e962d9358e3bfa3c8fef1526293c72e4bbba4522a7e07a5f6da6012775d5b1d487283eb5ff89e5b024e4b918e98ca203a0eac6bb26a5be64bb478ba936f1b410c298db9260f6969ef4023125bdbc7db8b725cf7e4b69e0c0bb1733f3a4ce5f6b2eb374713fbfd4f488c5d1be324c038689a943154e1568a3dca5823234ce6c5c26ed2da769d0b1a78bdb4fa9a71d59a2af1241315f462ec378dd24472efc8d17937fe3e4bf89a2987f3201db5ebf41726d27cf6c26b167556dfbbd0c00589c8fc1827fab8ddf45f95f76efec6f8d3ffcb2bc9754f9ebf26c935f967f74e5fe0d7f18c35eb6fe9b112b9767b418c56d9ef750f7725ad45de079a5d42b2569d5857cbdba2f426619e57273da74b5cf5af951e76b3dfc6843519c8e6ed6dc7b8290fdb0b1f7efeae73a579a7cb26abf03c7e7e8bdce598e578a5a6f1dd57f77ec99edba37793aef1fee973cb8ae75cee284055e15d62e19178d3707522ae7e3ee9ae5d00e9d4d82d21e79578288e3068737f317a7c865c4ce6f38eedfa4502deb116b7735b897b77f8d41b7cdb7fd07973e715eb9995a40986da462fa51b9e682506f2559526a6bffbe8b6f6ebcbe97568679806162eeb1602d386302d65aadbb374419f9dd1e08dcad0467c5f3e96934cdf94fc11a04ff3158473a8a7e3db77f79c292f017ed42a28ab2ff7d58f7ae65fcba3cb1ee97e5ef3feafe1ad6a4dfcd1061fa5d171d2f21debb4a99b5ec48d57adee17b492faac44efb1bed06b538a30302078e9e17bbb15b25d3ba8a4e9255b1ebb3905ab17ccebefd6591d9feea87e3660fe17e57bf9f60cf0992dab3aacb619b0902162a967eaa4709aa8b0c65aef4bbb2a56fe2695b51f950ea8b5544e6fc4d5d81b96fdccbd55df29cbae1ac667efbf62b51c39c6b2ac9c839cf8f85c7869fe8162a5f6a3925e16cea1e6cba00bffb4863d8c73c355ead66692428b3a88f939c136818237f256159881265b37aadff156ec96f73aaa3b7f8783f2bed00065a914715bb57d12b5f65a5ddda5ea31c67d9b9e6d2aab2c0a425ba857c471fd552097a343a660972b6d4cefe7e3671d5d34d5da54312451d414f00d3944635dad335e7f56b00b30ab4c3751ac81adfd8c33e950db63ff44c85b901983717a35575561570ef166c747d3abfb8a112440aeed6cc8f575a3d285f3a6c1c163bf745b4d79172d13da49263bb2415b00f520d118b3767240e1dd82f7666b352989c7a6fc8e7dde6c5ee6bcfd79e9ea9bf4ba342865886f90c30317d88903d4fc501a706f9b7070c15ef543ed850963cab079ef72e75090761717efdca575316d58589c9fdf9424ac0cf070ef2cc885b83e49f0c1c82e91a1a00b3ac246599bcc4db1ebdbbd70d956efd071652cc5e2d14f79a0f78614f7fb472185af9cabfd138b7705b9f9bf6725e29faa5804f8838a6e5f5ca00385808eb2ab34363ab50b2f2f9f39233eddd4e463d18d6352ada86a61dfeffc4424a22b2986f9791436fd96cc3ed2bdaa399b32dfad71bdd1e36cedf2f6996f6c2b6ebab2bb2ea4bf11b2295f77d0bdd9e91295cdd23ea548e8b8839e7dfec6bb74976a68232ca8be3b478f1bf6ce7868db922b5bad6f87ab1e162b27256ed71560a54aa622cdc91785046ee2dbbb4c8f220a9334b8aa9d6bbf73fe724f69fc8a0bec2236e0d39769befbf3128e88811c39d55dfccdefed9a8fdcdaac78c8df18882b467cff80e2ce569edc0fad9247625883cf6577f16f08d9efc2ce1f8c3976b73e789773f6c32b6d1baeded08ee286e68f046148b66e61ea93da5735c56a5c956b076d067db079b76bce5add735a078b5db7ce3328c04c0c488205ee15f6f3b81b559f9bc83df308fb6b974bce453e894adb0df2061d8b3c3cf62ef9491bf8a095e1fcfaab174aede7b64f4e32c0d84737f9d559b16bb8b3acccf662b81b5a01d5f8da95ea91483152a4c93feb61db3f5d2aa8791009f43820bce2c1076edf0d56a31311c6c40b4bd9bd65764de5cf8e886805e3c6d64d22ef09f9d03fd5df9ffeca41dc983f7d403e190d873607781e2d756177c31b750dea08658fba0dd215e28a501096dfbe83e5b51e068a650ebbca797ea4508fd1a570e3cc5bfa6d46fce6e35580e9581150013bc8004a93d12b222cd5dfffaa8ecc66fa9694daf5e333b4ceb24d584bd67573d34f50c9e3234dc9860d0785084ff75b32920b2539af3f26d5363e70b94bbc71615c564d61d5df3527885b8dae59373333db7ecad439655a79c12b0c39c0f552cbafd6ef742e2e682ea274bcd9a5a7a7de6de1f7a1ec5561a341040e5e75ec0da406ab741f458c3a11bf714f23f730c19ca32d78af3c52b6d79a2600b698e2c0ac8dc7548b658bc4bc3f975bf2ebfdb916e214be74fcdd8c60737bbd2e5bf68de1e444c28562b70515cc9bbce2cbf911b7ac2aa18a20b1dbbe556bb8e6788921c34285766b410601ae9221fe28ffb48169cac5e277cef909925dbec8f8e3b6fa884553a865f085fd7f9992b75ca1674672eea28d37f8f61ea77b3a6f29e4f9aca9bfde138995ca6cf80c89089830e59940400420408207f23e221137b32640242260e64084b718070600caca5ff4b6d531cfee25b1408cba09000202d9d4102b86a5c887832c4c67a923dfe048f2701c05512009492009007c2494338191722090085277d675b400280c724006c1c7b08f19000a003ad85d7cc85e8c9fee92540028001d6834cd63b2f27dee7d7752142c002069e81fe1fe2860086130306011e065bc4f04ffe8931f014940a25a138517e4a83911463d07efe36469ce18cfff95b627ff23866db0bce7d8e62ae2233cdefc8d7e57ca04b5ac564291e7e72f2d5198990002fc20bc8c41eb5413a9671188f6749213c2acecf2ba4fefc319604601c0990897d0cd7954dc8afcd07b1812400b3824102f84c5c88a3ad7f2392008c2f04d06824006b3ba662328481002ad589046036a326e023b91033f0780ac3194f860032fde7ccfc8986507431589f108063550b8ed6f527cafb331dc4347f703821dd7263afffe522bfaffa29477768e4bdf7bc9a2da6fac9cde693d2e97734c8c49e0460e7b1582e1c97f13009c0ae181531604c4454eb2400eb43633d0e8570d224802f4a7cb40c3ffa4102b0092c0a367f1605bff608c59fb148fb5333615b0924007b974a02d88227908c7d4602d8ee4dfc66f3fa2b1060332190003675daf775b319fea16e4fd6a7fd1fc948dff144fc4e7ab6bb103b04d0febabd4900db65b4c14f130db22f1eb701ab893e888304b0759000f69b3f23421542fe5b3c3831f0e90c96939100763b12c05e3f5637034f2601ec3e7408004900fbfbb1c782a22480fd2a810a0120854186408a1348a63a93d3f1780864601910e000e12000ad9b918efe8777a64220489d1ae9886a2100c2388d7a3c0960ef82b8480087f908c6f4c54799639592a96427061e4b0238b80910c0c093008e252e440a04d2d0e72480439605f7db2e448a134590047068114800872609e0e770211227387062e089a36aa0400038a1148afde8d7185bcbcd61bfeec71d205388cd015286806f5323571c274725a6b231f01048152393008e06021443154bc713211c559082caf70665bc93047024bb1089e3dca1b17b54867196211c244f03d9c67f53a9d20c7c46faa862b9681812c0e91433fc9b7f5412c0298a828d138aa38d7cdf81274bd2c5b6e3c9716274f10c3c1ebf3d63d45c14c6248ec6e1c479820470e69100ce6c3a09e0dcc8aa8ccafadc881af00f6f9000ce9b6843c9acaf2f49006723cac31917229dee440238155d885467fc68830c16d10009e0ec44bf71b153e8681be5a3be49a450509872cd2590002e0508402bea71214220054451c1c53b12e22079aa104a168d922da790008e5e566df6685dec2e440a08e1625915c1040a038f166d22015ca1b123c534904a02b878d0bac6704ba5ca4ce89a0470654380241de2c290002e8a0b51924c134bc74f2ebf88864fae5417623a9e0a613054f1b1b74900d7232a09e0707021fa8e9984c262b60f65f60309e058ed4244c986d19e88e302fa0a371f951a4b02b8b44660c0c043f2342108a48890006e730204d0454900f77c02351eb46749c3bd281695a0d08518e78c2701dcc7509548d2c54800b753dc883620804865e9927b2b819e08da539d21900aa6e3215c2c98898770230ae526b810e3682cb2032c3212c0bd07924f14a38e484773c6132110c22460c004d486a8ba581a9b929b084d72130a04ca8c43874c4dc7d31868d5b1a86a784c09e4383696967824092480478204709f7621a2e562e8433502998a49c713c9140cca35cfc25812c0dde242cc444560a2ffcf1c43349504f0b813209674bcf35d881412c013381a6258bf47d4ca134b8030ac2f0cb4c1eb28c6d2f1a334d0309dc54b2e5a9433ca0b0dc2f0a4e3e92ce0f154a025e5a325a36fe1211c4d100617d004c5205bba20c44b171413172501bc00814ae561e06923020ea2af32475f1d799304f00ad0e974082401dcefd09c8481a7d047f4c1ab462001bcaaa3e414547ee2b8f742c354b1496ecb8ba78eb8683acad16a1a09e0d5436b2301bcc9bf0d1ba81bf2ac40dd7b02e5bcd9932b2ca48dfcc8c053a91812c05b4e192ba452d9e82234517112c0db88b2fb684c31635551a90e108e0a8ed51db3ccc14c5bd31017e41fbc0eb72e04b7cecf1b17e51d1e8283bdbcc2bd23220008a0820ea34cf0a942f2a828cf47d8e0d3a592005e14e0ac0ac74327fa8342c142000d7420017ca8ddf92427452b12c01732491abee849d2800c3c996557be2c0209e0db39cafe9843f3e58f4a4a75c04f6a8d04f05d439ba39300befd2ec409b5f1354e6ea86d5243589447b4217e006d68f8bb86a6e452dae32e05ab5b934900ff32085808017d4363832818101c1b43b1e909c2a00d010274a1173264cf5084aa250403570864cf5dd2ca754230103dfa5504c62204b2670ee1f22311185b47207b16b0efbb2002b30104b2e7e3c7c9ad22309b2681ecd94cea361681d92002d9f3c3b757db4460360601066d5c8823958bc0583602d9330c2f714404c6ea10c89e9b6a7c192230d69840f64cc9bd4d1481b16e04b2e78ec6bda62230762381ec992514e6260263778e55b310bfdd5e08064509235f45600c1f81ec695225202902638c0864cfa53b03fd4460cc2a02d9d3b6e5ce561118b38e40f6741fee7c2602637208644f58dbf998088c6918ab91e3db33ac080c3a10c89edc1e79a74560309440f69410e36f168141546aa5d270f46b3981eca965d4e62b02833d04224b8330e806b31d6725dc30e89bce80a59ac6b3ef3e220c26416c643d2c0564c0606c3a0396dee74284d98d47e9b3d0279fbfa3cf87d9e1d1d2b3e90c5846e1bbd2c689daead15223b4b68051fab61f6beb87d9f78c9462b028fdb1c9a598d9e3b56114c6793b3c4abfe087da302e13f4f6e3f44f5c880011c6844f9405a12d5d47cb7a47ca5227ca12c7dee3601b6d67ef0f5262ca27e8cbd219b0ec4e947edd28fded1ff9ea99a0ef4c67c072722e44986b548b982f3fd48f951ba7c74a8ed3378ed063357ea43782b9712c49b0ab26de741c93845b67a48c04733b8dd61182d6eaf65d1d64987beb6869ca0f28c11e807904476a393fd1c2d9313df2288dbe59fd236f6f26e8dbc638e219e3e3f30fba62931aa767131da7bf3d42cfa6f223fd8a09fa65e3f43da3f4841ff8618b9aa08f44b510e94284794347e9e37fa43f3a419f3b660bdecfa82e2008c2929d60b60b0c58ae151d98cb83108e9cce8641873626f60c0a6b0e27239d41618d76a8286dc728ad28ccae432043f282303b3701060132cd890d4373488770603accaee342a482e9e3e303063a7c70604020c8807020992604b38b13a80c2c242f4605d347b299b11109cc6e05f32f43bb0c98dd85121b0bf3db8c6605e339f8f8e0860cb3af1f27a6c55263610131d42b52636363618143a3ef4d74d4c213ef158ebf578b36c25e199bc8d222cc7e2b9d01cb9bbb10ffd830ccde020b4ba0ffefa25261e19d233930cc01c2ec5f589551e1995dac71276b4c0973d8d3d1f16dc25f1f5bc2a26568ef958ea7c01c7e0498c33396e54430c75a172299884a35a61298232696e59074215198a36aea933630472903967f3369ca06adec4e5c1c0b820c3cccf1383e8e256c8c59ba65ef85ebd45b9c07963f6cb9dc5bf5aa14f7fe507a917f63827a45f2fb94c7f13f17c953e915dfb605898971494990897dbce7c82ccc0be991e63917efdc91b93d239d01e308683281b241c3522020deedbd285914e674272c8600b2f162b4af45610299d82f86e42521792a284605d1de168f429b938c56d1e9421481392ba7213e6709035648f85e7cce5bb058214b78ce96044d7a22ccd93c0609145e10401521c35cb204fc9f4da6fcc9d493085114e63222c05cfa09b404984b7bac521435309703fab13c217ef4a77d0295ce82301102514befc8c48f0dde34a73585230273ed274000cc750fad3697d5f9fd360d85b9ead219b0423e3ac81f1f2dfc23f32430b7ea8817716b43002c76da85887e5f4e85b94d584e441b71616e3c75d49df0539e86455d1b82d8c84e3077cad4231a77d97844e3e1188968dc4f7f88683c1cbf8b68dc9d3f8d68308fc488bc3c38587cd3a4f0c0b3800e714cf2701e2b02cc63ce320fcc633de6e063ba8779d68c062cf4d5206a1c2b58a1a319415198a7781a88e72960c08ab693100ff35450e3e2e8d8d1783739ac90619e87637192e7156572501d23d19cd65ca508cceb310d5e799d19b0e2f9c9bcf2fad168b078ede401120442c0df9a34fe7ba81eed1c788759669e6648c0c27cc1d3d0079f3703565a39591f7c1b282c274259e08ba5d16830bff6f4679061be5a02cc77990a8b3f42ebb9054ba8a3fddfdce9cf17c3fc9204989f8f365213bfc8684d73d00fc5b1a71a230d4d9e0dfee3bce1825f2e58fca91cfc17a7a14dfed30c58e9d977b17f9ac2ced0984673331419b072e8a4e6c8287263ff0e72ff06ec7fb144f227da8d4926be6c7bdbb58578cf2e6ce916397a5f3356a4f273b19a1c11c773a3fa4ad92c1a9a810a707f9f811e1e352f2ca048a78f06addf763f141158601f8182c63681d469a8582096012b374df60f81bd743a7d34b611c73ad069824a50681a2c087231e059c17f075482e4e934b78101cf06264b2cb80d8d0212c6a3fd4cecdf0a6e2c13084d477e212e063c3b631243acd92072dcdf442a049063ffa185c13f513cfd2fae0bd251d40b0dff01f5b0b0309d4e87256c5d4651070be3583de9cf5b81858d5963db3feb358533a76102e16d0c78f6d02413fc85303e937d3a0d7e65c02a6b278370a610048ca2706cb9179ea9349af0fe4b167be1990d7f34eaccd72362d98ee5a5d3d4aa08711a5a157160c02a5f276b55c4970a01937c9bfef77d5ba47b3a1cb53260d5d41f7c3bf6effaf60840b0a3b69c667c9e9a838a227fb4a5e8191a048c7be898468560d1e1696844b49f01ab0e4eb69118272ce138320e17b39a464d62260c58cde7fb81a8181c1b0b01202ce1c548678c0c9c59393f048064d48058586c2b0102c819f80c3c1e16cb4353733a0482548a13451016db4980c576c06a71dfafd4b2888919f80cc6d84ae0ff2fbb5c60f158880b96941df99ec6b203031f43d67cbd88ad71f33b47cb19b3676bfb3cbce51367988f5f7b2b6496ebbda4ecdbbe14141fe295dfe3239b9c8e1fc94047f37b0995bfb959019650a48d4cdf482e18c9d7258c200e58427f64c8873e449f59a1bd375f94cb77b9312cb106e282f9f527d6ed59ebf35858228ab5a6064b8ab39ed2d1a70c3c914c15148525eea2c37e89dd341a2cc99acea0c31247e269b064034a0b3a0989c212a504723a1e96b8c15adb8525ae8d4768221e968865cd7508914561897e029e064bf4c641602c2cf176746a60bc2611a2282c294480402a2cc9355a880e23596c51d06f63cb32209ae57f17b947e4935c3c6a2d322cb9928e625eb2df8528280a4b16fc9fef94a0d22560c98a7406acd6ea42a4d2c560c99a51354c8c31c9340870a08ed481aabb9b024b2d4547ee1314233b296029be118b482d9ed847014bc98d6a85e59852f309b0d4bc1f1c73d2168a1fb74ffcb078070144d6d85f2a8e40a682f6143ae830b29a0c4b05a0a5743ae83096efb2e6cb68e0c422252c554885a556ba1061a9524a2c2c4570216ec7c3523728b1102e0e84a5fcd0927b14582ac38548ff6eeaf5bb053e58aa9f4287a50e7fa7a96f631f3f758a492ba5b0f4022a2ccd35be38084b9b516069551722450496b61d5d3d632941978187a5210a2c6d38b1be47197f6b130596f619798bfec35b3b29b074e8c45b64c884168b151685a54f1360e962586ac885c862a52a961a07c2d2f62ce0423858fafec883f811238f454b8aa8e878bbef29b074d31f572361193ed662242cfd7aac5558467a84c33f52ea8d50ca084fe60f80207a1ccaa18c330196711ae750c6338e1a3fc2e176168732ebc61fa02c9bc032b1230fc659c667fc61751a96c9a5c032693f725239cac9be094e201c95ce62a38900cb3c9d60e30d9d1a3bd1c8d8f4b3cc109565bab18664675060993e96516425ff6814590d0a2ccb3e49e86fdf7fd020793a280ccbba106059675856cb8548a4ea32f093f771c0b2110458361c96d543d9c2d1c0743c0d02a9181a8896a51160d9545876910b71a29f238f28971c97804a255b4c80654f8d4b255b99404d0461591917e20e967265efb11ea0cacd642957b665e441fc88faa13850f73b7ee4b004580e034b635d8844584e60a43a13d43419787cc60e7cc60ec6f6eff42aa74380e5168c7320b77444aff693f40acb398d38c41fcc251732622e39eb9f005b2e9900cb6d9ba877cf1f802d776cfcc104b0ffce6e2b58eeebf79bad607901022c3f03963b3bbed36adadb5460793b2acb67d2f1b0bc1b8df575d21601583e9c00cb87c1f2a213cbf6accd0ccb03e1083f1bffe075863838282432781dce7ba3a7b7b757042e88b5992106dec82259190207ff9c11dcd8960758be01d2a0b16223cac4732a2cbf114d0ffe74bb038cc35260f9ea499b1dfe10b2a9149a3e3a7e6005665613383d5a2c8ce361455f9c192d960ee3a45d88306e256d34f432262d5e212ce3e302d1c61259c687719b50ec278cfe88834c68603c2b9ec0b8ed104403e3583f5006c92c068f50e871304e1d65316b271e3fbea2301e4c71d72930ee34cb6f71f726fbad3ddaf42b0a8cbbf46388c00d1360dcd038e414f85950c6354c82f20fd6f10f5e0f07fa7be1c2bdd7458607e3d68f5a2730f2977f363ac93a0ae190f2b87514b6506105b15f5b47219b022b784fb20eac707a1c630ae513181bdd1d022b3c24c00a0f7ec49821cecbdb33dc1b8ef0f6c2c18181211be0604f6f1cc93b3064c38814ac4d34539342d1009a352e85a219155668fab5148abe145851635c8a1ff4ba213c24d817b72e24c03b78d4b126daca81a427da3a498515837fb97d0756aca7c08a59136dd96d08864981de86b860ef0db8900dc1dee138ff8849bb8646a41fdd3b3415e995f4a0d9e31c29995261c527bf965ec99b022ba9fd417a431c1c1a1a1eb2de1be7131e12f4dd2ea6118e7ecdcff71cdd98842aa57a2aac14f81b8e3e5360a50b7fcad10fbbaa4638fa353fdf71a4ec06298e73a4ec4d8595867ecd9172220556b6f98123ffe088481f1f7f4f7fefe07513b0fd1e21cad721d989b6ee516165c6af11a2fc89022b97fdd0d6ba703838c2c73bfc07838c22e437069924fdac5593fc6396271556fefa6be967c553e059d67fced11f0d32c2d16f00f21d476f20a5098e3e51e159a9bfe668b624059ed5fce71cfda19f228d45c251f3fc9ea3d9d193bc68763c159e8dfb0d47c728f0ec909ff8b5271c1838e2d4c121eb587a6279f92484cc7e0de126daeaa3c2b38b7f8d1015710a3cfbe90fd24f61cb21ace204c98fb7a5b2860aabc8fda62d1a0556b1f8a12d12dac1fc101ac2bd23467d1198b22faab4430a131cbda7c22a49bfd6b4aa28055679fc738efe6877d4e2231c797a4f9923d58d93a2832a8d0aabcafc86a33c0aac1af0078e1c83e1d008bf10b45bf642adaf3939319b68ab15129b68eb1d15562dfcb53dd4665260d5477fda567048b0f746ff88756840f2f7fabe2d35fca448a446a4c26a52bf692b8602ab994db435bd4d9c5322179e9c9faabd1bcf1dd406c77307589d8700ab73c36a68ea4b45536456e23074c8cb3fd4276295a2300e42f2d627d33db73d2e215cb5582376872c7f78913f55a7ecc1de0bdb63dae58dbc2242023dcd002e6160412588987173ae8e5b27cf4f7aff45cd789beb623d3257a7d987e01bc744a564495bf45e22b622f60c4299f92c7e0176a0831accecffa49c527fab463d9dbd2e79fd368b79a54903090ba6f507d4f92ffd8e10198bcd14acf8bb6b396a37973eeab665fd31772387554c5dc6d1a3cd9ab752acde3d37601a2d8f84c0a57bf5380469a7af9f7b89c86fc9b58b0c192ccd59a7286c622ab7e6a09ebfcfc0f21b9b3e5992c29f71debfffdd611b7a13876d0ce800cb5f8a85c3ecda17e7473a29cbf408a595fcc70edbf8e7fe1e58eac4ce7beca97babdd2d73308addc04600589c8f0531d8ffd2611ba00cb2cbfe17f73d61b4b51de4257e51ae175e5774fc57e509aa949cdf1d8651a12f5e5f107db9d63d717763b87540f7056e97eaaaa13967a8d8769d756bdf3d9a79c6edee968c37a0cb9d3da27b9f6f5d5935bb5c2e7287cef5eaab83fb08363586bfab3f7cf0525012670ea652ccac4c26c6e5f055bb3b4c25ef973b1c3f53da9e2b0e58b27d7c224917afbe5690beb725cbefe09b6371a79c5e2846dcd8c6df41db79ffb169258898da3baa42ebdf0db917bb9a2cd5d077a0dfbba64e0cc3c844b7d8749d9fbf401859b196193df322d703cd96c48f85ae9d4b86b6bd791a95b369e9c0fb28a28b69ef9cf18301664deb608016bf37d71e0c959c557940e6cbb1a57cec4ade78b41244f25579b61edf6a6a6d76d63ca67d97294dbb708de30701fed8f564eb87678ad6442378d2936376699f3a9c382fec4c63ef70680783b006da4dd7f56e78e75ccc9c1758869d0f30b11ac871f35bd1999e87be191938dfd876f0b0ddd015419fd398c7b6a53efa56f77a4ee54ef96f873d9898e632cc130c13f370e4fca7ebe38703dcfdaf9f96f30ffe41ffcf4ecbc162c1bfd5c8df3b2da7c7eacbaf4fcbd1bff1ebd3706c9ffdb2fcd37a95df3958aae660c1e0aefb222e9d22e1bc5ca5ef177a540cd51faeec332c5ed1a85ea4f676ddba35fa37d9573ad7dc32ed345ac00ff770d739c8e4ea7fb4b8bdcf791934f0bb536731361eaffb234b29abd5df955fac2ab7b19c2556cfec5bbde106ffb621e058506ca45b489b4468bbef57be4367ed45d7dc3e15f56691f5a5f26d5767ae38793c31d3c2b4928c34dfe792edf7bf8bdd30e0ec5c34681054a83127ce17283930c7d007ab0e3db6463c664458e262a5afc7a45775d83bab757a2bef29e5fe68a69751abd84d0aff5c58862d0198d8d3c8e6dc35a56a2e72e27d43ecef9bb21796f6e2b4df735679c5ec55727cf075c0559d46c7982043f47bdb0566a489bd0aeb28a433fcae75303addac5c5f5fa06e5ede8cf3800ea11e0331b1ded33a8d1fa3504c6afed92132afd72203576cf6166c8adb6e9555bc252167be5bee7fe0f449a4f7d529f2d5f52fc436ef375ab75144e4e31ed1f6595107d3a2f2b744b57aec588688cdea71e0b0376ad0d0400849cb63edcaeba859e40b8f3e712be8b31f5f593d84e61d6ba79577545569633092dafa1b485b07773c3b9375b1b6559d9577845ea687b5c52a8add5ffef9eaf28550650455dd97f3a2a293b9ddd6d32f228ea722162dad9f940645b784ec5b70b92aa6bee240f74a64a1dda2f925bc1ffbb615fae4a2bc38fd3307da2cdc838481d78d8fcfbcbe92a9738570d113b83958cdd79122eab161d7994b455d089758583c367ad68b8e60da9b3de96e4a292b6bed77776e5ab0203aea2e9735b56de4a493a07ff6a4939f9d76ffaf38e9e4f5420d2d4d0d3fe7757250c93262c9cc5ebb0e19cf83afcf6a9c2fb6555bc15b82cc8a765d1cc57d4c0c4aea945dcea66c3953f5aa6258fd76a7ba0f518dc9ca6fa44bdb8181570865c52b2b719a4707e7cc674dd6d0d04be81c59dbfd5ecff1add6dafe8d36f724a7ecb7a4819de3b70d89fe95db86847a8af42ec6eddcd8eba9a2fffec54cd307a4b3d44a32d27da963f95a5b5dbfd21d5bd45e7da9d9472d7e5ec2bdc6cf4eb5b7bf490d799b84444bf2ae6e911e6a6a150a65cb977bef5505e1d2e6ca5f176e1754d1bcfbaa5db20c0c0298a03f32074e19ea482ef7d66953ace9d20a95d54830da146fabd5b3b6e1907069c9bc5d5396d48b094aa37ea1332dbf98c7b620a0b741aa7afdfd0a7f7cbbfb7d0fcc8037cb907b4e5e153a6a6cccd979e919d648759e5d9ba79a68c3870637e9baab6edcf96b3d9195cbe1abc78fe6c404d1d6cd33ad2c49a6ea362ff1c25dde7cb630fa9c5ec5ae67e339941cc6671a3994a7b4e422f752874c152e1fb354dd7a4422ffa34b2588cc30d4de56539ab1ccd43f4c90a344a9caa65fb238cfef4a71824c5d453bcf85b588f7cb8556a722dc9a3738489ceff802710eac0fb9be769ffe605a20efcaf5378343c7cedf7fa6e45780177eb2e3b367e58ea36def7431f9e7f6de9f41b821db53798693ff55f994f5ed3372fe7ef0f4cecefd0b47184ded50e8778a09af45ab62be7eb469616fdd71fe1b368590cad96452edfce66c5d9155d02b448291cd6598947f50b2e8f40bd2dba3f2dec75f0ead259e6aef693b659bc85e2d5986f10398182fa4467df656d292f543b948c846ae27ecadbd315629214e86e6af2d16087d583b77c99415e4c7c4888d7799a47fe181cd5e87cb35f15bd6ee7549da2c58a7d3fd7a79a397ff12eca73cb677973fec7a3b7f0db24cc3a2648656a80e589692641f722c090857e9ae52b5caacc5462eeb4dfa701375c78069b96368efe226e1c30098574ec2ee513bdbeb3cb72e9065def5073fa4be316e13c3c9ab0b7743cf5b6eecdc2d6c17b0d7f0915982baf909291bc4daeccab7f3f7522d021ecbb7765db43856a27b8fa47162a3e1a0c2a607e75a375d437971fe278e7d4f42b6fb9a78bec6da1b13b92e1eca6a2b709dcbe3a12f351454b72ed0d96c438af23564eb7d8900dd3df5ab0b6fb53d176e219c5eea6061aebcd0202e99c3cb4af1a4b16b19580d30c12bc88288e604bdeb98ddbe0c53c34b47d722c7ceaeb76d5eddb31c6f9cfea1dfb0e9f094a1b69609468e1f74a638f5dbcf4044e75afdfc17caedf39d06dbefcc34715ff1e933fd5c5535ad375641e3c23db1b52b9079e5865c8992c72ed5e50ce95ec67646a5ddae7d548995bcf45c0eebadfc98c4f393a4d0e84f118e3be9faf6ddcf102e52ced3f5764df2fa067eb5a75ea70d050ec4b477fd070ed12ae7a9bfbc5baa90c3345a79cb97e75a6c0fb27dd964aa579df6d8bb82e2f1a6e332a2a0f526a93455c131c93e40f644fe0937578ef50f4c254b1845a09ce02645ede2324c1dc0c4d4200ae6f194bd6da4ab7b376e5978a2f9ce85c08e6df8a84fabbdf44ccf2f9bcd85659fb225039998ad932e5ec44ce568ca1fd3ab85fb7456e70b06cf5a73f2746a90bfc99502d703772797fb24f069e57f4e00927b56fa155c9e9b207d6ca7fcff7a7a554946ba3ccf168928dce79fed5473a262d623e387af7dc959331e241d7fa57241d4d12d1309ad192c22c9ac320895f556313b223fac82975948d4bb676c6da3aa39cbe64b77e94eccc076d6881f8c9d04d729274306af0ac3bbaf34d6b45bfbbf56583f2f7b11ee8d6b258854b4be6e93c2a8a5ad585825b7babe46a46e5f6a99ca7d99e836c32f9a335e7a1d46562721da1b2e447f34dbd8e5989ccc56646af1f90ec5a64cbc546aa5c7eb3e9d323438e9fe33f9fc7611e2666ffd4b5bd602f319cb3b0f54b938575f1d006f495eeef572b0c699462292eeda2dce6baf9223d66df4b1d551106bc052eb5fea751dbeec7974b6a8d4375c19c80d304176c4eee8c74b995eaf8cd87949d9333d9e35f2eb29343d152268390d2f7971cb392568ca900e1e282d3d871938cd3aa5edc5c4296dd41281ccaa334ea52503fd77025cad78760824efcb55996f4d2e35e7f6c83bfdf7ee5b901faa04912b56add25970f83771c7900a3e678dad2762ec782282535b12cf5ca075de6ddb8f2c7c69fa7c26b8cbcd8862eb47ad3db78729b142988bb24266c7ed93359a9a3be78c5c8dc5f886e4add54c8f28ba5fde7c83cc10ebf03a1b156b5a74fc134fb631b7ed9a8d53d644e8c8d5582153396d3d09a940c0b0dcab5c3565267616774379fc12be84bbc794a40fc52ff4632e75333744a264670708cef5dc1b710d7ce32e8898a87eda8a0935ae6f280998c9c7b3cf6e43198727c0e45883449f6a0ba3056cdbc5bdec80b5ca5efdc282aa24fbfd166b0e3ce8ed64323992be4c99ff702687d0c8d5584ad3bf1a4bbd63bd5de5e75abb1ec9b977973614fb952fb6f4ff5de2fb5f8e4953b91a2b09094e91cc2e7838ff3c69d12b45be450bef6725c5455fdff1a5e2ababa8515f4e6323027a3f2c189c3b3baea14b48dafa74bb732678413c94db499023e2d3303975b7c3a4782ff1d72edafddd70f9d509bb66effe0e1b6d46da716ebdec6d94fb73fbffe7e33d88dc5493dc4f69e278efee965e5ab85b7ed329bbaf72314733535f6dfd6492fb4d6a0962dfa4372be41ac7c90277c255c53d350d408ac05320a7a37cf9ed5514c69e24e7c9eb3302d594bb5450eebfbe3e03fcdfaecfb003580cf8df99dec5e8453ff53cffabf27e05c6c35f94ebcbd4a925fcaa7ce3f69d06bf9b7e6513b85560bdd93a49353fb7494a6b1746e831c702c6a1d876e5b79ebcf147b419d7ec367bdc3e367859be6fb82af7f88e142eb9ec7589273adf9e2899afc53b58dcf1bbfa030d1c33d7c6f5a53b1fef3b3d3f4a78759d74dd9138de77b7cbf69bd9b8ef8879be38f49b6ce2f2b673164a12fc396a9f5235e44b186f6f37a8d56749e429bffb86af242309183933cb8a8b579d95e7151f78d86efe5e9ae78d85c8c5855497bbe5f03ead14c45cafa7e3a094a3fac1baccd5c7fa25edec1b3514cfcd5deee4c8b1fac2d20bcc54345f709956bef0b3cb9858f9c2be8470bb752598cb745a97ca9bed6fc181f4e5fbeeb93fbdd61c124d5d3927a41b5987e195589496714d78bd2397dda645ba552be9a488c88d38f5e379490afead1bcb30960013638ed4a79a75dc8aaa5829b541b9981ebf6c16ce3de4f66ccd859a42ca6e09a6ab3a64a6dccbac6382fde3a30acf298c2afed7c6cdc203d073e52fc9c5d1856d2ee485c7300a96aaafcb94d9b59243ea3b691e852b10310db7974d7bb34befaddd3fd79c229e6b2caccf99da7a2685bd2d64cecc1689443449089c5a9270a66ecfb7c5f854bad8fe1747973ed7fe665ceff9f298a3fab0ed5200c833492222726aaf13173ce1cee60c3e7275c9f6e72909bb0a4ef03759f4dc4c9ef3e6957786260a25bd694169454f0bffaefd5b949ff1efdb9c9d78b007a4b8e6b278c9feb0dd25e735247a63f91ea5f543c6516f37bff5bba5e4aa77f6cbeed715aa05414884220e5ed34bd3166b65cf6b1c50bfba982bb167dfeb3aa3eb360749f74e0af18edcd3736cf62646c62ee5d4cf2b7d9f9d3dd69037df85bfe2f53d05db7a24660dfcd09e7bca405a5f598639013031054834cd27d840ed65fbdce1ed29efe35d1d0d56b7a99b15dcb50c5d56e4561b95866640a688dc96eb7d31a6550a671cbf3dded3e16f5d737ffd16d17bfb9f25ee2bb2ebecd61d42abdcc8c41047ee54cc9db8539154b7fa1c3692ca79d0dba495d3337d0e8d0cdbfde14ec5e06a7e0f4697d190b05ca3f991ba47ad75067dbc2bb3de9e2bee7a2cde607d4216d9087f783317df7621578087cbcaf7a3586cf2d5c44f43c71d92e62a3b50931edd1cbfac80f2723c83f6a21e2afd79069db37467a0df6f80ca5f494616dfdede5c6953f16260752e9c45dfb55d2f89246bafba738ea543f91d2b73ec5b8467f683c7cdedbdd9db3747cd122d19d4513821c9ceddbb555066f3f58c82f9dbe78e4cfe87feb393ff06c5a11c65cd7389d5d66a7b8efbbc78710b8a14f8174cfe27222efc7e74bd1c98f3884467b638e3ce7be9aa1bb3bb8fad70b5a9ef2a983b33e50e22d51dea5bd5faad78de90fdc10e47a719853cf88557f248ee811ee73755bdecd319c3abfc5094a9652370b1b3dcf26c9c86f2de70430f8941051d67cea297596215379029e3350ac56bedc01de5e95fdff7bb7cfd2fced426223c5a417509f4dd15e77862ce6f0bb7a19d3da3607cd46367c8b2afd64bcc86eb3088de270a5620ffcc1981270f36e987e55fc8bbaa3ba810b7dc2a391ff6f2341fe41bef1c38a6d039fce93ae47fe5ca7932b2abd8f4e3f2968bd8bdc2724eab07f92f55fb9bd8149dacb64c322a3bc07ee6f900e26ad07265de1b33eea017b73825ece4dd42031b938e852df93420baa433509bc2bae38df0cfdc0ace5d5630fc499bf0799ec0f5708dfefdfb1f2cf55e57ed946c3fe3b2b269eee134552462561897338effa6dd1dac6b67e497b28fcccd356e4edf743bc55e208df3a51ccb40358009ce426abeacf7f6da35436c2567a30562fb44f8c4968ff3961cfaec9fad7ef6cdaaf076dc94f11a3dd058fa1033508f5a5770c2ba34506470aab81568ad891f72af987f39e07dc232832e8bb3477bfff60a43258844c62f4d6abc7041c820aa7ca8eb90fa4afb55a5060d73bcdfa67d01f1d22e895710f0a29dc40185561ba6733bc375f70c77cf3031d0d19cdedd7970e155c62ac7e1328e4b0093a30c79f2cc033b57c2ed6693ca296fa5a153cd3b8779a343797085bea4797d6050d8d929eb6a2b9323a0740366601daa2cb649aee0c09509983d9c117fad99eb46a096920e277bb673a08564bc28fe7353deacf9e44a32725ddba6fb2ae35dc2e2bcdb7ef657ec8f3a398b8a6fe67f6a305ce0ba93c195aa83ac53e4d7319e19b4ff63b8b017f6a60878bc2d7adecd4d34e6a9259564770c1e9cdeb46f74806ffdcf7cb029d5bbb653c2966d9f907d52407ae867cce13cb5ffc0b4ef5a3ac1cb77bd096753e04b524b4ccc815877aafbd61acf79f35e95cc8d18e0a120562619f47ba927b5aec327331478b81047932fcb2ccc17d9cab8ba8349ea7d8746ba3dfde9757bbf9be0f8d7deee71108b7de8ca57bb7585af469878f02da924cbb59cef3d4eee8cae3f24d430d3b5105996bf5de9442155f6e88b9365874f78e428a5ea55dd52b418548dbd1e71ace034f2dd364afdff91abf8feb93bcb7e76151f0788fd6fde59f69babf6def7d5fcb2fc833ef9d7bbb4dc7ebb8d727d3a533d66cbad63f39958639f2417d0698f032757575fcf5cfe85daa0af87d5708874bf6af5fb85079b7702b33c81dc5df197575665c7a8777677e3ee76b697fdaefe2dd9a9fee147bc1fdb575d7ec031d83ab4dcec6ca67db4fb01f3fd29ef2e8671399a9d5b32e38b2e8f884bcaeb9033253afeebe6846d4ffb76ffc5b194d3fbd3a50edfaa242338eb1505f72fc845db87e6ceadd83428bff2c88b6a695fafba9d05ed73f63c73388e2cad5f926960659fcb5917a0dfdafe285fd3ffc2a60fc9ee9a51f5a47cfd4739acf5f1b0ff89f5f144c4fb66d5dc01e5edade5f107dc43afcef9585ddd1961f36ace66a354f7878577536621a6974e35d816ac12d3098e1172ea911c7cb2d0acbea06cc6bae7372ecd3ea854d930b62e40caefaad6ac99d958f5b44d2023bed3e77c9fdf4deca768e323891fbe896337c64fb9ff224f5e176899b42e70f9c49fad0b6caaf165fcbd750180ad928cc80cf9c6e49c28b1e08ebc40e2eeb06d9ba9e4cca315356397a68e0cd675ab6907429891a8bab7f2c693e39ed677452b39795c783dddb08015724f29bba38efd464019d80430c146a48922e81e6cb6c87c83e860ca37bf4a27d3d6fe84fc790ff82b4fcc3159c6afdb39655d509960d27897eaf52fdc2b90adb9fdd0fcab0642f34fbfb8850815f7f21f0d292c3911f7a2e2ddbbc4c3e6f50a888bf63259cd0daf766f363f6a6d2dbe897670556fbacb894afdc646e2a0fc81072bd0b476d5b4d2da19ab92755615a4cec899b3b5fff63e0b8b38efaca52ca8575eccd6f45ba9480adb36c41f6bf964edaefe07ca225b0a45407089369d90ba03c1cb9eb23750ad5ff385d1631e98356740acf123d476fbc5b1c3590ada816ef53565986a8089b982043d894ba3088b75787ceedb967931f623b69caf77c155f8ead2e2fa6f8331b93e343a6629d2c8f398a1608d8d9f4dcf95a05012771cdd9fae4eaca7debeecb9f1fd92ea6721a879e94c4c64e9da01bfa0a94deab464608ded756266dee0caaef6edd735d0e1bdadae6063717be1e6ce050673027510d7fba73bb35d796c1a1fb1edb86bb0cb6837653342eb2f6fdf2390d6ac7ff97c0b1a780ca61778fec2f2cbd436e6a463d85f3ee7f0ac9634b8eee738ef86eac6971a430ca399da2d8e0e3912d9bb1d1005a3c53378b7b5f4377f7d12ca7f29e78a28a088b49e594c8d7b7420b7e52e44fc8b9bd17fba918a8cdc483ebc45c3ed3e59cba0d372e92a8147a106d5ff8fbb2f0f8772fdff9f194b832c85ecbb644b96905d681864295bb652b66c59b33396c328644bb678b2644d945d458821eb945df63142488591e57739ae3aaeeb774e679cbabed7399f3fe6afe79ae79ee7fdbaeff7fd7abddfaf7b1edb92ea14987071ea8c13ae760180e9cf04d615f5e48c0a3067222b9f4ca90b43032ccea3a43229571218527b78ab0ad7f3834958c44220f1fa091f2bb4b48e940f16848f4bf1f8620fdb67b3741620aa54e842cc98ffbf68b83f4edafd8018b26d41a01fbeca16b49b1d7f0f9ea4a1631fc813a937f452dd50577479dbfd963af4b542ed2903e1e09b6c6cf6db192f7866318e11ee628c2cd242cd55a415259f02081a0cee86df389283f93c5a5f0d7e00c281ef0357aa9a7a79247fb3f4411fbfc62da7abc87e72e87ee1b08b4c71f475610ea9462fbc6772180eacbdc77e5d7f6dd127cd3296529da988786d8cddbe6e96355d3d5a8ee83f51f4813d4d3b19e4dfc12c3daeb04eaec59eb8f462c2502e3d54e6c5a171a608394934a0bb22466f94d63d3c21debdc46370ddd1b53c37a0a1d4c88ac67ae3c5333462ea9b8896b97ddd223c4a9d4885c572b455285347e24a610d04b97089c99b533a10e03a873746c87d229afc9f89e81cba0c354191ae561356034037a1c489f0158ee8a745340200483ce9df7d9e8d70a0975883d1896fb55dafd259179b9e164c8c8c2f51862e03015e386fc679e32a7e7a018ff366ba48e262c226cdb6279467259342656d8873aa0950201c411330d299e5c01c1948155071a66004c910529d9849d95a363f9f365a77cc93f1550bdeb1ba8523b8f9070b99dac7423c607fc542b20d1bfa7f928510d58381cd6d53472f92b02cc97b56fdac19132a67fb8802e8275e87c355830b9b97d20d00e7e177b1728d2c27aac86cdee4918c8a0c9cf88dc67c715bfeb9879931f3e680c477c717fb411c5f66fef90bc2be304b87a3f04469d326d457b832f3631ff7c4582b8af6345de9c3802d9629c9fbf69015268922da35314f48e32dee9a5a68054ea9e5c28ed74ee79bbde5ef74b0e5ff6735a8835cffd72eff73e9758e85627e60a38e47e6120068788061eb6bb68de493538bde6225ae163e8047a05aea293e73519d2c860c2d6627484a8cf02bb25cb12ed5f418dd50d466cf2e2fb884dffbf75db4b95ae0561d9b74e57e18817cf2aefefeb238df9796c9d95a22797728ef14008209cc3223e7b33448df67642642ad385643903e51cdfab7c6a2cb863facca2ced922ca95fd1ec89006ab7ce9a57f4083569b3483c1ab8e63c56a71d04e39924b359ba669de2aae82c049c99469b64caf1e6b0adf2ea4d9aea1a4a170482c71539513d172291aba76dc9bf19922ff149130a278dbfbdcae75458de51c4a6203c9bf3ec8edf45736b939449d68b77f05eca917b8664b77f89e0f2dd843f2be5bfe06c37c7e7ce78b96d16c2888ab62d9b599468adaf465cba7611a0b32d6a7d4333c14b61de3f4bae014f78c0fde471ad8e3553db75f1f6ae681fdf6a702508077e0a7c66ab3c6278ab9e694518ed77e62502ab8a3dff86d324c4aef890476a8013cb32de018ac681adbee70ce87ea7096deb8f7346ec5dbeb77c0fb411911e9b44921462d96172c7da939a26af8a97192bc7982b9002fc5c370280c63e54fdb272c686ba0c99f0b62f5557367965c6fc8add35bb39d5efc3921c64d813204862166c896880e1716ca776bcff25f233a41b30bdcec80c8735c3931e35c071770b2abea98240b9a6a5b3b9d3d44ccfe966faf22548b424c2cb4f18762106bf0f4bba7f1bfcbb618bcc54f886de7d585c199b34fde2fdc4c68432457c0b56db58f1406447a3776a01e099106d21338488beb83c04cdc9b09c8531323fd112de6e17218321aba5da73f6fa981730f10d9a5c823e6313ae62759d5802d94e63b567b95eec225b57278582b57b434221cac0430da8a12fb0aaa8d889b1c716f82087d64eb2357f00053e788a0a826b938077718ba9af26a205e1888e00d051651e8139d4e455adcd12d9707ab3a31fc37cb050aa4eec6d18a7fc64e704deb78cc31136ee39b9380eeee4820f59d322636a7dd80eb378cc45b7a8587d2c8bfb97e7727c9c5c1180958e7bf66cb31c2832e6d92cbfeaea369350f6adcad2ce8bd0abf4592b95c061c0e76e3dc1722d98da4d869da7c7ef5629249566f45509ddeb410d21a7873529b0ef12deea3f28e1e7c3328349b0a7d30cb8238094cab4b35fdb481f893ce41145850919e25eeec40146812ad8d5ca693deda352a6aa794b5845a273b70b02edea4a2451fc3b67b00adf7bd4c4fb17b9701c9e5b8d3285fa8ad767f10ba9348773e41f50a73a8c0586d6230048340a639faec54a7a41354b76e3ed8c95c38c1b8d48a94b058dc290d8a5f348e0ba2c751b91b9c5c504e355c932f123d471500f849d183cd167ca4909d3ae706f8faf181f8caffc5971e17fe2805ad70295920b5a9d425263838bf70b46a9222cf7a61b51086dc6b593f6b3cd9c01c0b9eca50f4e2f9008b113cf6a74387448aa3f4ddea17f55e43a1c48434bdf777b6e9743481f8843008b1c9e9a4bfc3c748b5276ab41819fbb1eb64ffcfe5b8815cd1d578f267de0b5e7bdefeb694a003240bdb8f7e2ec08474d90eb95c4866ec08d596bc9d3a8fa7a029d92896c9d7205ec29347fdd9dd9939f81ede3ac2f895b350403c2412600cda3cfdba0415c57a268f97f0b94c3c42852703a600a8e0b1a093ced92e38f4bc73b2f26e020f17fc881e9fd72a0feafe480944ebcee4fca01e27a04c0c860ddfe7051bc7eb0a83d91c8d1adfb9dbff1e711afb420916c1a448168c857801663ebfd6640cdc2103ea137b53c3569c3d8290f49f778c7ee956ae23e9a77631718f70301036f1614747850728b2ccea69d31f7da90f2e649ffdf136172a4653f307ef37c7698048c667d1ab130a2d038e55cac055e5b966c0dafdc02f469b55cf2c4ce0979255defb21f7fcff3fe4d09ad01a8aae6e3c7cb3e8dbe92647b6beec6afd508d7aea6b5f9b5e80c8b8ebfb6a63a9fe19060533bfd9f58736ede03e59943dae5d4f5d2023b3bc4645f3ed569aa070c905a0f16d6c2f3357b01d618cae20eb22a3d78cfcc391345c93bc5341cd657f559adf99220d8b4e3d43e7b87425fe7cfa62fa0c12ca9156b8d0d98dbba63693e6942433225f4b7e23af4d2d9d3f09ee589fb0e851edbb7537d68feb9544df8825c8d58c2ea5d17eda9b7646f1972b912b4cd593d3daea4aa7fdd24171850060ec9717871e4d731a13fccd527f61535e6de66121077b25639db5434df9998eff74d13e47d72e531876f6bd159b2f913930ce6c1d5cd4b37d846a2ac6db891924a157d783f69d29e2630399826f8bbe4ff8f354109f9715213553d6355818a76497b47c63838ea5e780bf7a6acc0c8734c54f23d002a6496d48b75f832a1b166c472c2c331f30282ea665e66607afb910ee913fd65d5e065100ebc00385e3ff17c6653d5cf74b22d92fb26e1dbbbc76e64a8c06adadd027da92ba3ce7ae31da0141c38bdaa6bbd83f3e006a1bfa381ffb862acafb37151882a3a81d95db79a7fddf8dafb23d0f317ae425978529fd75241474e0214c14484665d32d0fec3332dd45c0587f3a1b26fc3535a9e5a3b5f6c77e10dc3ed42ee7c30c8ff0167c50f72494ff10537e788dcc75f4d89233b121ed0849324f42550e4197af1850a4a43f50038abce58ab3fdb97c36ed30123e501299fe6ebf2da57641bbd9b1dcb03099937aa4640eb830076c52e4344d96b9ef96ca6fb43274ce1cc74e33944eb0aa26068f0ac8b0f78136fc0d3d62377370a995f711432027846dafea4b6d8993d0379a682c943a9dee6f4c6a7fc49ced512f9ee8af75ccd148029733fcb51d39b14e82ee9b595c9de3ef74bf22a8e3708300c15fde8cd858d8fd584c6201ca10110620cb2dca07add2e1f089bf05473c54595d984131f2a80c8b71abffaf8b05b10efe74bc71142abc12238b050f0a189507b385a3a048c284ad097a4a0acbd6c12553ce855c37cc8189e5e7aa80a51d5e442079bfc1b18d97f6e1a9cf0ffe1657be0dd8fee6d91e55afe37e353fd0e04efac02fac9a94f4cad36da0659fcb6342bcbeed3324c371202b87a775843f50601db165de5649f4be414dc2f83bb798ffb7c8589bce20c73c435062f7e94af3b1ff42d6693ff86983dfa51675f8f6cfa87dff7b26608c02b66a237a8a21763730fbff1e4a07edfbdb3c16b9dea0a3fe7ce503094af258745da0090e5de0f61f54a56ada14cc96aaf06ecd59d079f9e66582c6e49ba37a8da1f4ef12d6653ff869845fc44cc88f9d93aedf088d92de0b4d2cc1d27ff88cc42bb64abecb0e8471e8f6a47f3087afafb7b1727ad32cd8d01f2d3495b1990cd378b4c02a26cbe16616acf95b86256a52763c96322ac75dce7aaecd66d39f02b77a22c6d0d3e838dbcb70dd36a1ea7c913a4385c6e34cb4737151de14bbcdb3bce02088ff0760d8b2d7bc35081bf853b16d7570ed2081ec58683bfa87d40bdd09775ac06278270e0388081bbbf3f5ee87295478fb88524da5eacd4e77e0955ef619a90d202c8d5c2bc28bc930b8003abfc210f30fbe4c1a3eebf92078a2f29197e4e1e10c8d58381a3626e23fdf14f1b261402da750767331a1ca2065f691dc73c5f3575ce545d4b02fc4ba7e706f5dc8695dcdedd0e7abff205414f5e1d298c72af3c26d2d1969fa2b29bf54d7f4dd6b7dbda2229b430599e9b12324445e545da2077348bdb569c4607e60760845acf00a7c6f1ecac116edeb5e2c910dfd4fb7e1b8ae9141a3b40d9329ad3cace2dbea01a920ec24152006e228e37d26766c7b91b5649635d7bc8a4d0f3062b264ca03b75cf08bb86efa3f106261307d1acfa0a595fc7f3ef89c2da7a6450cb7f527b29c7b632ddf7a0f71098e4f017687ee03607e585fc1f38125d241db744eeba6ee4396707dae590296a84d2d05b8e7ff22b1c4b22ce0eb39e05a4128e1bfa7e323d9673a572baa660bdfdf69965cbd8da159c981cff9df93922fa3dc1e5f26b05d711544c4b22cdc9e5b98756aa8c6a6b0dbea16941ff09c18584d2c4c66c57d20adc2aa917bcf4785bef50de2663c5cd2b0647e62bec3e138b02a61770236d5dce412e8564e853a3913df3dd102343bb1ad2b759d85287906d996a88300807110444eb4a9315a2e73e37f1075bf0713812703ebd328188437629b950da747e09c59f6767e3c0a37b18711e0c23cfd703fd3e335d12ddf7270e45d06b680a299e92fe1f28444500c69e4ed69878761ca577100512bed36e3630e59ddcab5eb53c245d2ef59cf82a20b3186f7a51aa8035f9f5b2b5a6522f6b475627ef73a9741706e15e969b719a6cdf7d215c07f285fcd9a4af070329c746938d422f67de7022d37f8498459f4f149ef50f71f92097c6547526895b1670999a96e9e36fe315d1379379894db6569ead7eb460763b52fa6d992fc2ef02e65b1bdf656c504bf6b4088f1ccb3c0a162b2bb465cc390cdd316fb821ee21b34c0fa1c27bca3cdcd7c667d85f51c5bf8dff0f26073e5ef870c7e0ba37b9a74ec9bd93e047493b472a050130456e64d4c360e34b77e55d8d000d4a61ddbe8b3af09a00356dea2f26d1e68a3c5fa508c68aeee4a189178edaebffbf000000ffff1ed9a0d101","nonce":"0x128cd","to":"0x8453100000000000000000000000000000000000","transactionIndex":"0x3b","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x41535904d7b20be8d733e03d95ec725d0c6ee4307d899cd00e0ca0de91533b13","s":"0x3f98c81207d078199bf74a600a77cfa389574646d63ff55ccfd194491faf7226","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xd3343d473f624c02045a01f4e7ab604bc56c4f42","gas":"0x156c0","gasPrice":"0x7d9f6fbd8","maxFeePerGas":"0xf49895cde","maxPriorityFeePerGas":"0xcfd6ae0","hash":"0x00b5b05c6d1a2eb8abe2c383da600516515e383fc8a29953bb6e6d167e9705b2","input":"0x9aaab64814636b3e36ce9c4227a5fb53273a04c3fdc94c8a00a4d6d5b6521571b94ec7ac00000000000000000000000000000000000000000000000000000000000028a416eb20a9e75d33ef7eeb4a0bad7413cea6c0b3a7f6ea249a93a428c0c36b52240000000000000000000000000000000000000000000000000000000000840244","nonce":"0x6c7","to":"0x1a8b038f5dff48f541e8cc658b9e186b9828a726","transactionIndex":"0x3c","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xfcd40d6ec6fa94f40f866c18457c22ebf5d8e3aaf2616c4c1cee5245ce8f042c","s":"0x45e5962efdda48e38f706cf8fb7c2f722d80da6e0a1d2589b6627627b44feb82","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x9aba7eeb134fa94dfe735205dda6ac6447d76f9b","gas":"0x3e64f","gasPrice":"0x7d9f6fbd8","maxFeePerGas":"0xf49895cde","maxPriorityFeePerGas":"0xcfd6ae0","hash":"0x6fc411f24c7b4b8d821b45de32b9edc5ac998d1ac748a98abe8e983c6f39fc19","input":"0x2e260ac30000000000000000000000000000000000000000000000000000000000000200a5c46e2dd70854a0fe8167b705eb7df71cc927469c345248c81b21a5ab2f5f19000000000000000000000000000000000000000000000000000000000000051d000000000000000000000000000000000000000000000000000000000000051e000000000000000000000000000000000000000000000000000000000084024700000000000000000000000000000000000000000000000000000001b3fd9f800000000000000000000000007ebc0d2451003f2d3bc5f6eafbb7e6bad81e250d0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000640fdea40000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002e43c000000000000000000000000000000000000000000000000000000000002e7d600000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000f6cb686532a3ece4a20f823e59cc386e1ba384d8504e902c932fa1497c4afdfb0b000000000008008402470000051e00000000000000082ffe82e7b18f0778493c989ecae1740325207ea29328999d5ae646723a4bb75a1305c8ca593670972f535ff8afda050351549ed800e9b98c805788acfe20e6ac076ae024efa64ac3ceb8f0a3cc9ce93d122f6faf8376c854da95567fb7576f762299ca2135608c7ac5a824257b50043526903fc8e01ad88006448a69a4afda4c01ad8a6ed1260582538f2311e902c1e7d5853a75b74482117f2cf920897c1b9428eaeb7e74a95d3d32db03931d157a48aaca9748bfebfecffc2d140caddc66b300000000000000000000","nonce":"0x108af","to":"0x7ebc0d2451003f2d3bc5f6eafbb7e6bad81e250d","transactionIndex":"0x3d","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x1b284cf86146fa2094c7c709cf9fcb8a177f4fde1d1c5ca112e41f82a5e973d2","s":"0x5618261c40d23e5beb7ac0bac77b16ead56e547f103f649462387c5acdf18ba5","yParity":"0x0"}],"transactionsRoot":"0x1ad3212eca045505cfc4cacf675b5fa2e7dc7b9f9cee88191464f97d1c9fbca4","uncles":[]} diff --git a/op-service/sources/testdata/data/blocks/pre-shanghai-bad-receipts-hash_metadata.json b/op-service/sources/testdata/data/blocks/pre-shanghai-bad-receipts-hash_metadata.json new file mode 100644 index 0000000000000..3e6f348b85f6e --- /dev/null +++ b/op-service/sources/testdata/data/blocks/pre-shanghai-bad-receipts-hash_metadata.json @@ -0,0 +1 @@ +{"name":"pre-shanghai-bad-receipts-hash","fail":true, "reason":"failed to verify block hash"} diff --git a/op-service/sources/testdata/data/blocks/pre-shanghai-bad-transactions-hash_data.json b/op-service/sources/testdata/data/blocks/pre-shanghai-bad-transactions-hash_data.json new file mode 100644 index 0000000000000..e1821ce46dc8f --- /dev/null +++ b/op-service/sources/testdata/data/blocks/pre-shanghai-bad-transactions-hash_data.json @@ -0,0 +1 @@ +{"baseFeePerGas":"0x7ccf990f8","difficulty":"0x0","extraData":"0xd883010b02846765746888676f312e32302e31856c696e7578","gasLimit":"0x1c9c380","gasUsed":"0xa79638","hash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","logsBloom":"0xb034000008010014411408c080a0018440087220211154100005a1388807241142a2504080034a00111212a47f05008520200000280202a12800538cc06488486a0141989c7800c0c848011f02249661800e08449145b040a252d18082c009000641004052c80102000804ac10901c24032000980010438a01e50a90a0d8008c138c21204040000b20425000833041028000148124c2012d0aa8d1d0548301808228002015184090000224021040d68220100210220480420308455c382a40020130dc42502986080600000115034c0401c81828490410308005610048026b822e10b4228071ba00bdd20140621b2000c02012300808084181ac308200000011","miner":"0x0000000000000000000000000000000000000000","mixHash":"0x31f0c0305fc07a93b1a33da339c79aadbe8d9811c78d2b514cd18d64e1328f25","nonce":"0x0000000000000000","number":"0x840249","parentHash":"0x2303b55af4add799b19275a491b150c1a03075395f87a7856a4e3327595ed7df","receiptsRoot":"0x99da71b17ae1929db912c3315ebe349d37f2bb600454616fdde0ee90d6dbc59e","sha3Uncles":"0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347","size":"0xea6d","stateRoot":"0xd12bf4cf3941cf48be329a939b13d3403d326841c69cdcc9a9c13ab2f227e904","timestamp":"0x640fdeb0","totalDifficulty":"0xa4a470","transactions":[{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x030b1cddf635e9e71ad70b8668e235e8ec3c67c4","gas":"0xf618","gasPrice":"0x1701ca2b9d","hash":"0x2ca7289ab3738d17e0f5093bd96c97c06c9a2ea4c22fc84a6a7fbfda93ce55ee","input":"0x","nonce":"0x456d","to":"0x89416096a0a1acad3436a357478c5c548e4d382b","transactionIndex":"0x1","value":"0x16345785d8a0000","type":"0x0","chainId":"0x5","v":"0x2e","r":"0x5aa6ad410ea42dbff3781de67b4815a376cd459206595fa6655c966a7709e5cb","s":"0x82f620f8dbc356dc38ef346d1e152656a1d318becbcc41884f61e85972355c0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x9c67435ce8a33ad23f377ddf08260ffc56417f21","gas":"0xf618","gasPrice":"0x1701ca2b9d","hash":"0xb0085de1476530de3efc6928c4683e7c40f8fac18875f74cbcc47df159de17d9","input":"0x","nonce":"0x446c","to":"0x471f3a988a77472e971112e7ff2ce65996b6c8cd","transactionIndex":"0x2","value":"0x2c68af0bb140000","type":"0x0","chainId":"0x5","v":"0x2d","r":"0x75425f21a6e66e6feaee79455c897656c4a94b6189c4c033facab1b67812fc3f","s":"0x7014f4b9f760165c7757f9d6dccea349b3d00b0a9c2f845af8010140842f826"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x168f6dec26cbbb3749654e0e3cc4fc29314fdf6c","gas":"0xf618","gasPrice":"0x1701ca2b9d","hash":"0xe01c8631c86ded63af95b8dbc0c8aac5d31254c14d6ecb4cc51d98259d838e52","input":"0x","nonce":"0x403c","to":"0xf2119a49a3ae35453c1c2704da248d08977084f1","transactionIndex":"0x3","value":"0x16345785d8a0000","type":"0x0","chainId":"0x5","v":"0x2e","r":"0x56bba57ee69c09dbbd5167d0fee07d5803130fea7c278f4d8b7bc54b34be8ff9","s":"0x7eea69c0de47b6b808ea1bdd9ecf5d25f4f2743e867b1f838db59c456026d7e6"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xc9af69904b4ba7f0fb69ab1a8719bd8950265e73","gas":"0xf618","gasPrice":"0x1701ca2b9d","hash":"0x69414a126a6f07ab5e31ad2f9069fb986b7c490e096898473873e41ece6af783","input":"0x","nonce":"0x44c20","to":"0x6adc3f5394e00cd067d1fad5a33756791e303c25","transactionIndex":"0x4","value":"0x16345785d8a0000","type":"0x0","chainId":"0x5","v":"0x2e","r":"0xdc9a52b87755cd07143bf032d57258d0d6c36500b38a574a9a5addc1293343da","s":"0x581e6fd051d0c72d64303c1f90edecfef46580f84f24dba930cde910923f7c21"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x92964e63cd52450e6e09a266e0c226e524754563","gas":"0x2625a0","gasPrice":"0xf5686c7be","hash":"0xa2fef1133ee726533c7f190f246fede123e3706a03933c1febc92618f90d2804","input":"0xa9059cbb00000000000000000000000011f7db5a824eaa5737c935ad09a925dd707f092b0000000000000000000000000000000000000000000000008ac7230489e80000","nonce":"0x2636","to":"0xbc071c64ed8f536011c78e847755680740d6b73c","transactionIndex":"0x5","value":"0x0","type":"0x0","chainId":"0x5","v":"0x2d","r":"0x422c5026584cd8fb8a1fe66e6edc7a020bc513cc3114083fb35f9846cd9a9792","s":"0x7fcd4e48ac5b53d881531a5651e587188157ed88d85c51533f7c6eda94c67ff7"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xdec1bc71bf91431d60ef2742f412dcd1c5a204b8","gas":"0x7a120","gasPrice":"0xb80e515ce","hash":"0x6585ec5c4c2bbf1f683f90f58e18f3b38d875e94457fe4cbb7bc5bf6581f83af","input":"0x67a5cd060000000000000000000000006343e96c99e2725e845ba04f90e03d853cc9bb2d","nonce":"0x6a5a4","to":"0xf5de760f2e916647fd766b4ad9e85ff943ce3a2b","transactionIndex":"0x6","value":"0x0","type":"0x0","chainId":"0x5","v":"0x2d","r":"0xcb7b32949ac0dedd3151d06d85ec4e99483c8ea706f12a009d97b055975241eb","s":"0x69f0009bce12e24408f9a3d5ad5a8578e2b23efb09002f7b86b3425cf8748889"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xdb954dd5d224004b26cfbb089312e0542e5d1c31","gas":"0xd5ef","gasPrice":"0x9fc748df1","maxFeePerGas":"0x116482c049","maxPriorityFeePerGas":"0x22f7afcf9","hash":"0x1db276b864fbf01dcf8cededf8d597553ecb0eb9438edfaf2f5bd0cc93297c66","input":"0xa3e35f36000000000000000000000000f18f2320e4779f21d6882d83f9133e582dfaa9b6","nonce":"0x570","to":"0x11672c0bbff498c72bc2200f42461c0414855042","transactionIndex":"0x7","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xf23a1fb0d17cdbc2831a2cb0b779795e12533e34425a3abbc4b7e7bde262b92d","s":"0xd4a2c8189378696065b7fc5d13e9cf6595d96047a31a4fcb812c2e677d22a26","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xe84d601e5d945031129a83e5602be0cc7f182cf3","gas":"0x249f0","gasPrice":"0x9502f9000","hash":"0xcbe7ed31654af4e191ca53445b82de040ae2cd92459a3f951bdcce423d780f08","input":"0xa9059cbb000000000000000000000000355f96e3261cc8237d2d36fd81cc9b9cdcbfc5ea0000000000000000000000000000000000000000000000000de0b6b3a7640000","nonce":"0x4f1f0","to":"0x499d11e0b6eac7c0593d8fb292dcbbf815fb29ae","transactionIndex":"0x8","value":"0x0","type":"0x0","chainId":"0x5","v":"0x2e","r":"0xadf7dce5f34d482bb19ff0c85f43be7008cb838043f9abb5fc08421245ac4228","s":"0x5d2c0f0b9d2e68bb8da6084e4971d57bd76bf0cd9d893c9c985962812d2df026"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xea0193f88a0d9c36e83e6fb6d382212b6373faba","gas":"0x43238","gasPrice":"0x933ea77d8","hash":"0x808ba5211f03cc78a732ff0f9383c6355e63c83ae8c6035ced2ba6f7c331dc63","input":"0x9f8420b300000000000000000000000000000000000000000000000000470de4df8200000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x0","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x9","value":"0x470e9f23394000","type":"0x0","chainId":"0x5","v":"0x2e","r":"0x9536f87e8c3433ea23ef7211c0c32689551906dfdf31bcc73b89fcf18fe86a92","s":"0x3e94bfe3b4ba32a6ce71ee6e0ff9f26dfc2b0d61b5c0fe049469e3c4b88ac227"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x1f9ab300b380313e6a2208e44c01a0602538385d","gas":"0x32b38","gasPrice":"0x87fc9eef8","maxFeePerGas":"0x2e90edd000","maxPriorityFeePerGas":"0xb2d05e00","hash":"0xdd66f1f26672849ef54c420210f479c9f0c46924d8e9f7b210981ffe8d3fac82","input":"0x32db5470000000000000000000000000000000000000000000000000000000000084021000000000000000000000000000000000000000000000085b0af981975a40fc5a00000000000000000000000000000000000000000000053ae1f470262f3b01c4000000000000000000000000000000000000000000000813bca9f8389ffd193f","nonce":"0x5699","to":"0x28cea7b0f3916c1dba667d3d58ec4836ad843c49","transactionIndex":"0xa","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xbe8eddd463a3518a4c94b5922c0f2fb26a32c8afcd819f7deaf4f0416757ad13","s":"0x3e234182acd5261dfba3cf4f125d1a8377fc707b3b1900b565d1a6b8987b398c","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x1d990a2cf61b46f37582dd31a7b242e989e1a1ee","gas":"0x493e0","gasPrice":"0x86f96eddb","hash":"0x254abb2f8cdcffe9ef62ab924312a1e4142578db87e4f7c199fd35991e92f014","input":"0x9f8420b3000000000000000000000000000000000000000000000000002386f26fc100000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x0","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0xb","value":"0x2387acb3784000","type":"0x0","chainId":"0x5","v":"0x2e","r":"0xbfe9b99fd2e9bbd2d65bb4cc17da88130d8f6b569a26afa642ed1cc8efd2e2ef","s":"0x7003dd3962eec2369bc5abe5e3d5b73a9086a3219643b1741f3a9832369448fa"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x1124bbb196fd7b61947f6f03b7d7cebde8340b6f","gas":"0x493e0","gasPrice":"0x86f96eddb","hash":"0xa7b7c654e7073b8043b680b7ffc95d3f2099abaa0b0578d6f954a2a7c99404e1","input":"0x9f8420b3000000000000000000000000000000000000000000000000002386f26fc100000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x0","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0xc","value":"0x2387acb3784000","type":"0x0","chainId":"0x5","v":"0x2e","r":"0xe8dae9efa8fa73a3aebdaa75ba12acf56712b1f99fc128ab802a7610d014547b","s":"0x2ef347ea90a0db21b035637342bfc916c9962d3ec610a4e99cfaf555a2606fe2"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xdedf52a88fe47f6a11d629badd0096d201aef86a","gas":"0x493e0","gasPrice":"0x86f96eddb","hash":"0x7ccdfa698c8acf47ab9316ed078eb40819ff575bcf612c6f59f29e7726df3f96","input":"0x9f8420b3000000000000000000000000000000000000000000000000000003a3529440000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x1","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0xd","value":"0x45d964b8000","type":"0x0","chainId":"0x5","v":"0x2d","r":"0xfc4e092094abc7fed9cf11eea8ad6ec3a760d13b9c603b5570c2143e48090f2f","s":"0x31a0a6016ab51ed6375891bf532d9031bf91c1d0e01df63cf7e46076aeee83a3"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xe1db1fd154b344ce7dfcb53a65279559b298f0df","gas":"0x493e0","gasPrice":"0x86f96eddb","hash":"0xa0b035ef315824a6f6a6565fa8de27042ade3af9cf0583a36dea83d6e01bf2a8","input":"0x9f8420b3000000000000000000000000000000000000000000000000002386f26fc100000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x0","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0xe","value":"0x2387acb3784000","type":"0x0","chainId":"0x5","v":"0x2d","r":"0x79c316492bfa36fa4de2dca02ffac77f6c1772714e153aad8c947ce848d4106f","s":"0x4fe3e083943ca8f974cb0752a2ffb70e4d6c8b615e16ece7e19b2c464be66929"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xd4c3777e1821f6fb532957104e1317a9d3f881ec","gas":"0x493e0","gasPrice":"0x86f96eddb","hash":"0x1ebad7f3e8cb3543d4963686a94d99f61839f666831eab9c9c1b4711de11d3d9","input":"0x9f8420b3000000000000000000000000000000000000000000000000000003a3529440000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x1","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0xf","value":"0x45d964b8000","type":"0x0","chainId":"0x5","v":"0x2d","r":"0x5c1f544ca92b28a014129a9d04f8e895dc8a6987ddc1717c26b0619bb9bac420","s":"0x47574643bd92a0f129f9c5ce3caebe7943cfd828d67fb0e5bdc1eb2ca202822a"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x127418955b15f5ff2fa232431a798b53fd006c82","gas":"0x493e0","gasPrice":"0x86f96eddb","hash":"0x501750278e91d8b5be1ccf60e793d4bbcd9b3bb3ccc518d3634a71caeac65f48","input":"0x9f8420b3000000000000000000000000000000000000000000000000000003a3529440000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x1","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x10","value":"0x45d964b8000","type":"0x0","chainId":"0x5","v":"0x2d","r":"0xcfc9894bf716ba707521f0969082afb688b7d47cc21f1423b239c40867128f47","s":"0x5d9b9c66d8437d0a37768fb9c3241ef64b7e795d0d908196e1f707215ac1f56"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xc2ac1bdcb3dd77864b99eb2cafef2ed36c1487c3","gas":"0x493e0","gasPrice":"0x86f96eddb","hash":"0xd80ff8af29ae163d5811ba511e60b3a87a279f677bb3872a0f1aa6d0a226e880","input":"0x9f8420b3000000000000000000000000000000000000000000000000002386f26fc100000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x0","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x11","value":"0x2387acb3784000","type":"0x0","chainId":"0x5","v":"0x2e","r":"0x8bd7220d176d18cfbc824063448cf864c494fcf0958dec82126f26d3fc6c0b6e","s":"0x2f4de3d2fc3be6d2812ee10aee16a995af5affcfec27f9953ae609886d2b563e"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x11a5ad000f8494233df5bd2f2573fe20bad744ab","gas":"0x493e0","gasPrice":"0x86f96eddb","hash":"0x096acab3b3fe47b149d375782d1eb00b9fef7904076d60c54b3c197b04e6bf82","input":"0x9f8420b3000000000000000000000000000000000000000000000000000003a3529440000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x1","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x12","value":"0x45d964b8000","type":"0x0","chainId":"0x5","v":"0x2d","r":"0x43726c3165958e94d80cb6992121f55df2904a1de4356e0a6ff3d8bfd03c0928","s":"0x6244361e31daccbb5c7e9f3f7d01004080d2efa314d614fdc2aad4c1b7d71613"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x90f8b290ec2929cce086826e971cad3857c6dbb5","gas":"0x50f46","gasPrice":"0x861fc89f8","maxFeePerGas":"0xe22924cba","maxPriorityFeePerGas":"0x9502f900","hash":"0xbe9d1738af74a22400591a9a808fb01a25ab41e2e56f202dd7251eb113e8ceeb","input":"0x6ab150710000000000000000000000000000000000000000000000001bc16d674ec800000000000000000000000000000000000000000000000000000de0b6b3a7640000","nonce":"0xe4","to":"0x2e84c9894f628fd209f48b06d10b46c8cada4c10","transactionIndex":"0x13","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x412c7bfb0236a4317da40645ee4e60f19185e7d0cd2cc9bc88f7629de505b939","s":"0x4f6bd485d10fa134926ec3e3a83e212f3c5d903ba52da87f07794a2ba0a5c1eb","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x7915ec065b644568155c4772a286addad3864c1b","gas":"0xb71b00","gasPrice":"0x861fc89f8","maxFeePerGas":"0x1176592e000","maxPriorityFeePerGas":"0x9502f900","hash":"0x0834c720e55cccd97aaf4f8fb0cb66afb9881fb6a762c0f70473ec53f98a712e","input":"0xedce8b4d6a1fb55588eadfd3a0c3350435a31d31e7c236125eafcc2a892d50711d9a4939a4282888c956c070cd83400fd47ab83bd5287244053b8228711b07386dccacbd000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000001a0000000000000000000000000000000000000000000000000000000000000082000000000000000000000000000000000000000000000000000000000000008a0000000000000000000000000000000000000000000000000000000000000092000888ad4975d4079d80bc6da5ded57746f889644719ec160efc2e4a96ad645df10b1683afcd7ce41ba6c06528761f821cbc6e806ef4b71c189603ec218b12a1f1478883498e67b97ae4babef6996acc582db1377d8755374602e00b8148025ac2d2f52e78d7484919cef14bf96e5b7a3f7f8cf09989551888f2c697052ce2bdb02a9296b20016c78683a9ca137037e57c8ff25198146f9d4cdb5a25ab9c95a03038f22f83c8604ca7c035ef756d2963c3657eea4ffb18ef967752d8cff15a16124a1d92a1cda613624c98e3078742803da1417b78bb264b7bb2197515cb4facc2ea395c6241664dbd953d0034900a86eb94897bf89aae775a1d73e6fd034785400000000000000000000000000000000000000000000000000000000000009a0000000000000000000000000000000000000000000000000000000000000000300000000000000000000000000000000000000000000000000000000000000600000000000000000000000000000000000000000000000000000000000000260000000000000000000000000000000000000000000000000000000000000046000000000000000000000000000000000000000000000000000000000000001d802f901d482e7041b846de27f7b846de27f8383026c28946aa397cab00a2a40025dbf839a83f16d5ec7c1eb841dcd6500b901a45ae401dc00000000000000000000000000000000000000000000000000000000640fdf5900000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000e404e45aaf0000000000000000000000002c1b868d6596a18e32e61b901e4060c872647b6c000000000000000000000000964ff70695da981027c81020b1c58d833d49a64000000000000000000000000000000000000000000000000000000000000027100000000000000000000000009a1a41127726f74560a57990fb928120eed6f55e000000000000000000000000000000000000000000000000000000001dcd6500000000000000000000000000000002d4766adcf72ef2d996edfadc866be12c28000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0000000000000000000000000000000000000000000000000000000000000000000000000000001d802f901d482e7041c846a969541846a96954983026c28946aa397cab00a2a40025dbf839a83f16d5ec7c1eb841dcd6500b901a45ae401dc00000000000000000000000000000000000000000000000000000000640fdf5a00000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000e404e45aaf0000000000000000000000002c1b868d6596a18e32e61b901e4060c872647b6c000000000000000000000000964ff70695da981027c81020b1c58d833d49a64000000000000000000000000000000000000000000000000000000000000027100000000000000000000000009a1a41127726f74560a57990fb928120eed6f55e000000000000000000000000000000000000000000000000000000001dcd6500000000000000000000000000000002d4766adcf72ef2d996edfadc866be12c28000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0000000000000000000000000000000000000000000000000000000000000000000000000000001db02f901d782e70480846a969541846a9695498302e100946aa397cab00a2a40025dbf839a83f16d5ec7c1eb870aa87bee538000b901a45ae401dc00000000000000000000000000000000000000000000000000000000640fdf8d00000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000e404e45aaf0000000000000000000000002c1b868d6596a18e32e61b901e4060c872647b6c000000000000000000000000964ff70695da981027c81020b1c58d833d49a6400000000000000000000000000000000000000000000000000000000000000bb800000000000000000000000048f2c17f8885e135c8689626d5841d0b94013556000000000000000000000000000000000000000000000000000aa87bee5380000000000000000000000000017a8db2711fe83b10bbfabb6a8b86c3e26ca154ef000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c000000000000000000000000000000000000000000000000000000000000000000000000003000000000000000000000000000000000000000000000000000000000000001b000000000000000000000000000000000000000000000000000000000000001b000000000000000000000000000000000000000000000000000000000000001c0000000000000000000000000000000000000000000000000000000000000003760f4e19e59be10b323fe1b42e42de2754c5da54ff316cef74ef09dbc0144bbf73e609a8d21a38f393bae9a3de6bebbf362608d907d941c8166f44d8ee2c6686b5dbbd6681f5467219d9bb530db013b7c067db659c03efe935caeb7bab36699d00000000000000000000000000000000000000000000000000000000000000032d2d7436bd45b5e81824945ff3dda846e270c81e72929841f4b14f56e02eef39477f9c162a2759c8d7c7e1feefdd064f6aefb4360d483f70671f36fc11ccc6db6c53f74e3019c12d859545ad75b51998b2238887dc0be3c78522c8356150526a0000000000000000000000000000000000000000000000000000000000000000","nonce":"0x48f08","to":"0xe87d317eb8dcc9afe24d9f63d6c760e52bc18a40","transactionIndex":"0x14","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x54159a63b8ce19097cb8afeaffc84cfb5257f9709dcb0f0a258befa0b924b13","s":"0x17f5ef5aeceb6f082a8a0f8fa28e55d453c52e5f86d48dfb4d4f039aad7fa493","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x52db522edf50fc32b8fc0f77d51140031da11da3","gas":"0x201568","gasPrice":"0x861fc89f8","maxFeePerGas":"0xe22924cba","maxPriorityFeePerGas":"0x9502f900","hash":"0x51a0c33c9b37245b416575bdd2751c0d8a5d8bead49585ac427bfc873d4016af","input":"0x96d3f83c0000000000000000000000008cd194f4ced354a14960f76f49305feb8510f73f00000000000000000000000000000000000000000000000000000000000000e000000000000000000000000000000000000000000000000000000000641024ef0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001b3fd330d479974ad52e18b8767d9f18cf9ff024fa749b1066a803b237570cb73e2868e821124c8128505d883124711ae7fdca0339f4f5cd5dadd8eb6956eb4af500000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000003","nonce":"0x2d9","to":"0x29c1442d7e3b6ed179ceb55fe996e1f4384880da","transactionIndex":"0x15","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xac84f403fa0347be3246ad695f8f6a780332357d49dfa67388fae3e051e5566c","s":"0xac2e148c1045af0ebdb334f20743af7d5499558af5eea43393159ce26a3fb1b","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x3aea5f857b75a946d5f5b329bdcf4db46aec5d2c","gas":"0x50f46","gasPrice":"0x861fc89f8","maxFeePerGas":"0xe22924cba","maxPriorityFeePerGas":"0x9502f900","hash":"0x531c25d51ccda59aa9ea82e85c99be9dd4e285af9b8973cbab9ac4a38e26e55a","input":"0x6ab150710000000000000000000000000000000000000000000000000de0b6b3a76400000000000000000000000000000000000000000000000000000de0b6b3a7640000","nonce":"0x1d","to":"0x6c23a4586cc791d2be6767532e12264992aef74a","transactionIndex":"0x16","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x81abc4fdf3b57fdf3a951fb293853fdd86aadce8f319576ac78c60caac186c43","s":"0x452742335bd1f63fd623d5e6cf91f6339361f863dba1a57fc3c1da8292e82c77","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x7915ec065b644568155c4772a286addad3864c1b","gas":"0xb71b00","gasPrice":"0x861fc89f8","maxFeePerGas":"0x1176592e000","maxPriorityFeePerGas":"0x9502f900","hash":"0x93ac6c08d21cb1b61ff59e5e2d6fa3f9ad54008b0a66c669199050bef219f6e3","input":"0xedce8b4da4282888c956c070cd83400fd47ab83bd5287244053b8228711b07386dccacbdb54cb66757631f9f22e2faf7da0eecc43474ab1a1af21aec22dcf949e2579241000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000001a00000000000000000000000000000000000000000000000000000000000000860000000000000000000000000000000000000000000000000000000000000092000000000000000000000000000000000000000000000000000000000000009e011cb7bbabfab668b42b5582cec8d60f326ae14ad55f8d675060dd111dee6c88d0937435261929ba3a881bea107593a10e13c917a0ef5ae4e8bde40de2d1da4ba25ab3a239ba53eb4e260d23b98a7db944f644f40ab75992a89fad40e8d692ad62f8671604db415b54238c5522f6c4e6b25785bffa696d173659309b95a2fae8700d4b9c14382973ea34a3cd8b8428594908dcad2d5d7a01056b8e49a8c25087f12f9e9fec1f4b5fdc57509dba6839100e28016b2e3fec4928bbe11d3789b6cab280c17bebfa5a0e06aea22764e1a18d2d11316bdf81028e65755582586ebdf571cbd0ef59800ba3405539187dfc03eac1dba0cf590e2131a56ef7f260aa38f940000000000000000000000000000000000000000000000000000000000000aa0000000000000000000000000000000000000000000000000000000000000000500000000000000000000000000000000000000000000000000000000000000a000000000000000000000000000000000000000000000000000000000000001a00000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000032000000000000000000000000000000000000000000000000000000000000005c000000000000000000000000000000000000000000000000000000000000000da02f8d782e704820101846a969541846a96954982dc1994a59477f7742ba7d51bb1e487a8540ab339d6801d87470de4df820000b8a4220b5b82000000000000000000000000f6213f16f3db9b50c684b2da37ff080895ae4a02000000000000000000000000000000000000000000000000002386f26fc100000000000000000000000000000000000000000000000000000000000064376b6900000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000000c0000000000000000000000000000000000000000000000000000000000000000000000000003202f082e70411846de27f7b846de27f8382520894b6605a717a2447edac46b1cdafe35e3e91130c8d87038d7ea4c6800080c0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000f202f8ef82e7040d846de27f7b846de27f838303335f947191061d5d4c60f598214cc6913502184baddf1880b8c44d49e87d00000000000000000000000000000000000000000000000000000000000000600000000000000000000000000000000000000000000000000160f9854c9f595e000000000000000000000000000000000000000000000000000000006417d4b8000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000b1a2bc2ec5000000000000000000000000000000000000000000000000000000b2f4f1df2e372ec00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000027502f9027182e7048197846a969541846a96954983029eb1946aa397cab00a2a40025dbf839a83f16d5ec7c1eb80b902445ae401dc00000000000000000000000000000000000000000000000000000000640fdf0b000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000016000000000000000000000000000000000000000000000000000000000000000e404e45aaf000000000000000000000000964ff70695da981027c81020b1c58d833d49a6400000000000000000000000002c1b868d6596a18e32e61b901e4060c872647b6c00000000000000000000000000000000000000000000000000000000000001f400000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000c097ce7bc90715b34b9f10000000000000000000000000000000000000000000000000000000000000000000000614000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000004449404b7c0000000000000000000000000000000000000000000000000000000000000614000000000000000000000000694b3f194e94c80b2d7a0e986e1440f204f0503f00000000000000000000000000000000000000000000000000000000c0000000000000000000000000000000000000000000000000000000000000000000000000000000000000b902f8b682e70427846a969541846a969549830dbba094964ff70695da981027c81020b1c58d833d49a640872aa1efb94e0000b884437471fd0000000000000000000000004e44260732136caeffc7d076e17b2a3554b9ce2a000000000000000000000000000000000000000000000000002aa1efb94e00000000000000000000000000000000000000000000000000000000000064376b6600000000000000000000000000000000000000000000000000000000000dbba0c0000000000000000000000000000000000000000000000000000000000000000000000000000005000000000000000000000000000000000000000000000000000000000000001b000000000000000000000000000000000000000000000000000000000000001b000000000000000000000000000000000000000000000000000000000000001b000000000000000000000000000000000000000000000000000000000000001b000000000000000000000000000000000000000000000000000000000000001b0000000000000000000000000000000000000000000000000000000000000005b0efccaa7c845eddd4fb98211c7a58a37abdf06b264fade6cbff8a73ed22fccc602337b33a81e2cc4127be9d913fb3aec24194e14a61515a26429a00cfb86196aa3c2e6983f1a05dec045f0e63db7bd8619cd2a770ed1f7f470eb7c297e8e19d61277fb276ed8a63fd666b4a5ab02347065a3c16539f4ccccbed8fa39f2a7dc6606fc04c49f3d69463ba1c86c6ddcef8b9f06b9741dc2ebae9f5f1c0523b320b00000000000000000000000000000000000000000000000000000000000000050668b9ca5e5b17e2e79f9f5a7d9ea27e4e7f0302e878584fef3c2304c70c1ef53da311342341f89df488646b97a83994a3d07cc622ffde98598548c5326b7ccc0cf77d5d6fca6cf3f5b5b41a266fa2aaf697fd976dddc710fca834c96d2dfd725eec5980733db3c4e8f779f9fde3a598b2860d819419c961012825f0e160ee7b220989005b6ac5c48734db18158c2d85c8499bea1972c9f875c2d2aeafccb33700000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000014000000000000000000000000000000000000000000000000000000000000000e0000000000000000000000000f6213f16f3db9b50c684b2da37ff080895ae4a02000000000000000000000000f6213f16f3db9b50c684b2da37ff080895ae4a02000000000000000000000000000000000000000000000000002386f26fc10000000000000000000000000000000000000000000000000000002386f26fc100000000000000000000000000000000000000000000000000000000000064376b6900000000000000000000000000000000000000000000000000000000000000c000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000140000000000000000000000000964ff70695da981027c81020b1c58d833d49a64000000000000000000000000073fee82ba7f6b98d27bcdc2befc1d3f6597fb02d000000000000000000000000000000000000000000000000002aa1efb94e000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000064376b6600000000000000000000000000000000000000000000000000000000000000c00000000000000000000000000000000000000000000000000000000000000044a1c058fa0000000000000000000000004e44260732136caeffc7d076e17b2a3554b9ce2a00000000000000000000000000000000000000000000000000000000000dbba000000000000000000000000000000000000000000000000000000000","nonce":"0x48f09","to":"0xe87d317eb8dcc9afe24d9f63d6c760e52bc18a40","transactionIndex":"0x17","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xb5f185933d49064643686594f44a2584b1d57ba6a91f2a45d1a122892488f209","s":"0x7bb4af7ea30290b36fa7c266ee2387eff9e3ee0cd79b48aed27f5bfaaf34114c","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x4281ecf07378ee595c564a59048801330f3084ee","gas":"0xea60","gasPrice":"0x861fc89f8","maxFeePerGas":"0xfd18eeafe","maxPriorityFeePerGas":"0x9502f900","hash":"0x3792db6dd6285f409e4281951e9f78dad16c4a78072ff1c909dfadea5658d857","input":"0xa9059cbb0000000000000000000000000cc351a97c2fafde4cfa8a00c4fd79881cf13b53000000000000000000000000000000000000000000000001158e460913d00000","nonce":"0x77ffb2","to":"0x326c977e6efc84e512bb9c30f76e30c160ed06fb","transactionIndex":"0x18","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xef4173dd45060791cfb6dfc3cdc8a9b417ff6a4b3ba57759ea91fd875b01a522","s":"0x4de926b5099c7d60cc24add3c2eecd8e9550c1fe7f878430eccb887a2ff932ff","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x53e2c2479833ca17f946aeb16dcc49f5e2194701","gas":"0x431eb","gasPrice":"0x8442f24f8","maxFeePerGas":"0xd6aac8818","maxPriorityFeePerGas":"0x77359400","hash":"0xd2d51764c01e8c0a43fbe362704388df5bacf7e5e620c3864e242530ffb3e828","input":"0x9f8420b300000000000000000000000000000000000000000000000000470de4df8200000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x2","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x19","value":"0x470e9f23394000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x155352758fb04a6c0816c3dd9ca16bd6c66c37e2e19f2aa5d969225e3cb7f118","s":"0x6a4a1237db75dac4322fe12aee8b94edf7083ea661d6e93334c667d2d5c2c101","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x535619cf2bd2e84e567bda1a6164f195cb2bba21","gas":"0x55730","gasPrice":"0x83152e5b0","hash":"0x516b0227d9e64eb6e0de6862764d40f5376b5f12fec878436fea3479b4c36bb8","input":"0xa9059cbb00000000000000000000000030509945d2b329cc253a8bb2e2c54bdbb08b1070000000000000000000000000000000000000000000000010ce1d3d8cb3180000","nonce":"0x2176","to":"0x1173069b0e472a64ce2b6203fec8fb25a05b75c2","transactionIndex":"0x1a","value":"0x0","type":"0x0","chainId":"0x5","v":"0x2e","r":"0x289ee9948b80fc623b8c5d85c7df6fd25786fcc118163042b77a00560f53c3fb","s":"0x5b0a79e30d05370b27664b2a10cf964e110387bd62098561b6ea6a9dcc4634a"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x339d413ccefd986b1b3647a9cfa9cbbe70a30749","gas":"0x180ac","gasPrice":"0x83152e5af","hash":"0x81b0abc78b82840adb666775b182a9e292f663b64bcd35004c04436ed3c8281c","input":"0x711746e200000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000009a00000000000000000000000000000000000000000000000000000002540be40100000000000000000000000000000000000000000000000000000006d3c514bd0000000000000000000000000000000000000000000000000000000000000010","nonce":"0x2689","to":"0x7cbd185f21bef4d87310d0171ad5f740bc240e26","transactionIndex":"0x1b","value":"0x0","type":"0x0","chainId":"0x5","v":"0x2d","r":"0x1f70a3d0933aab069a55fb2b16a259d21ea5fb3255e2032c5ff194a600ed2ab1","s":"0x3ac2142fc9f2009d68b08855eb5bc85e889e15d043c33bfc516f28ea38715485"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x339d413ccefd986b1b3647a9cfa9cbbe70a30749","gas":"0x180ac","gasPrice":"0x933ea77d8","hash":"0xd0287570d431d2baea96ecc81cb890e7f4f06ab5df02f9b4067768abca19acb5","input":"0x711746e200000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000006500000000000000000000000000000000000000000000000000003a09994473bc00000000000000000000000000000000000000000000000000000005672af7e00000000000000000000000000000000000000000000000000000000000000010","nonce":"0x268a","to":"0x7cbd185f21bef4d87310d0171ad5f740bc240e26","transactionIndex":"0x1c","value":"0x0","type":"0x0","chainId":"0x5","v":"0x2e","r":"0x73a68e10ef9726d47ff314cd16d1846a0876d2b63a65014909140de7e45aa8b3","s":"0x580de27e4626139fbad4129a249c7ac2b22e1062659293e5fc3a244fd74907c"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xb5b9345e21f34b6cfa538f49e2b14ad4c3db3f7e","gas":"0x431e0","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x76ddab2674369f34946c5fa2f05e2aa8566d86235b83e808e9b27bc106e04ac7","input":"0x9f8420b3000000000000000000000000000000000000000000000000016345785d8a00000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x38","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x1d","value":"0x1634632a1414000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x4314a4757076c92ca696f14cbe037bcc0178f8b10749418d4535195e90b2cdc9","s":"0x15ee917bc3e27928196ad987b61e3fd35ac92a4200b139d355b30502bff7fceb","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xac2fde165d9f13a223f58b9ac1dde51b63feff2b","gas":"0x5208","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x34a5c74011a2c8a00103bc91bfbfd94aa99cd569be69066e4bf64d188fe8714e","input":"0x","nonce":"0x38","to":"0x7155eba8ef327ac3b36fe59b5e00ab85f735f4f4","transactionIndex":"0x1e","value":"0x1c9f78d2893e40000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x52178c5dce512607a6242f501f78bc894917a482e99a3368caea6bca94c6dd69","s":"0x728be90654231b65f790eba478ccab574e2468fc4e031b712efa88af31fc6592","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x1ddedd674bfacb6587e0c68cee8f2f7d8a71e9d7","gas":"0x1d4c0","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x7b9730ead1b9f59b206d0ddea87be9383ba3fc7b496c7863b0cb847889b86617","input":"0x607019b9000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000041971588d95d4d664ac84a45e59fc81871b7051d679376d86cef6b9e1453c762dc33a84a125774319ee47f2a8b8d588da6c8ff7ad84fd9eed22fa124b1a5c5ed4d1b00000000000000000000000000000000000000000000000000000000000000","nonce":"0x1","to":"0xe1e6aef7642b6609e6c54884d1bda4a3cb152461","transactionIndex":"0x1f","value":"0x4380663abb8000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xc0d3e609b2e9f844d300a7784aa9e7cb956415d025cb573a73848f49e4be69e5","s":"0x6ce01527c00c1a93341a541824aed7a1c895f5a0d998f4415cf6d88171c5ad3e","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xf6df8ead0bdabfba61d9b2457d5a5ccec67fb7f3","gas":"0xc836","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x77166ee0409ba86bd26e7c03ad1a927abaf5af8a8a37149e725cd37512091dd6","input":"0x67a5cd06000000000000000000000000fa8449189744799ad2ace7e0ebac8bb7575eff47","nonce":"0xbd","to":"0xccb0f4cf5d3f97f4a55bb5f5ca321c3ed033f244","transactionIndex":"0x20","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x5649e1ff58fa9b6ee27a7316904df02db1ba1c471a2f3409f370a31c6b3d5ec4","s":"0x386b766277e267f8796ba6e92af71a752335bbe45cb3385b9cdcab9ef6c53e41","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xf37cbbc2dad42e8826898d45933afd3a04937e71","gas":"0x112c1","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x3c2b6c2ae505c5c36d5f316c1fcb5f54f7346ed35ae35c93462991ded7968a68","input":"0x095ea7b300000000000000000000000071bcefe9e9fbad3f12f2e6c14ea0cae7f0c91e7900000000000000000000000000000000000000000000000000000004912e6bef","nonce":"0x9","to":"0xb5d86e1f237d52f1f19793d3265e9340394f75b8","transactionIndex":"0x21","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x3ee4d5bfc575fa4b241b4d23e6f099eba5f1e6a20b8cea663c63db6400d01506","s":"0x21481ea7a3e7ad758f2e149829f70f43d67b3cc0d44112cd3744e290a06dd985","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x52b6255b7810d97de8f751737547d1792dff4fe0","gas":"0xece2","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0xf99a792837e13827b5e0a8915fb59c760babc95d242feca99a5594e64ff6b6e2","input":"0x095ea7b3000000000000000000000000c92470d7ffa21473611ab6c6e2fcfb8637c8f330ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff","nonce":"0x51","to":"0x07865c6e87b9f70255377e024ace6630c1eaa37f","transactionIndex":"0x22","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x5237f7449c0df409c1a4d6cb09005a9224860aa74737debd961e2a24668d1022","s":"0x17e5e842e3f5ffb5a16eca0ec2a92e5b52d43bf9856f97e2083b2e951499b970","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x3c70503d83c5a681aab503d724f47fe810ae8205","gas":"0x17eb2","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x522313f5d923f048ae5bd0b5595c1f4fc883bc0b3cf3cb0939d3fcf8b08c829c","input":"0x94d008ef0000000000000000000000003c70503d83c5a681aab503d724f47fe810ae82050000000000000000000000000000000000000000000000000000000316195298000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000","nonce":"0x5","to":"0xb5d86e1f237d52f1f19793d3265e9340394f75b8","transactionIndex":"0x23","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x6741309799fccf0f1359bd710291ec1bb66eed23522d6ed60c5924264d4d283e","s":"0x69c43182ee8a650b0042cdb2352781b23eb1de72f1c3a8903a1a33360e7d9732","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x4da9a48963c158a88bf6d4845a6a1890d20e55ad","gas":"0x431eb","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x471ceb0e85af594aa56deca54cb8198567b2afd8406722ea530077aaa6b641b3","input":"0x9f8420b3000000000000000000000000000000000000000000000000001dd7c1681d00000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x0","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x24","value":"0x1dd87babd44000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xf977ce19da80b7e155ee2d8b7656e5c89004851407bd5370785befe2c89d82f6","s":"0x1d76177407e73d8b73b0909158825ee375a25fa7c18b04884f4be77bb60795a8","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xe40a2cd9efde08fb7664bcdbbdd877c52c4bd228","gas":"0xf4f6","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x3e9dca502e9039ae0c6d642f62e9562ff00010c6bfbb8234a6135712ba70dfda","input":"0xa1ddc5460000000000000000000000000000000000000000000000000000000000000738","nonce":"0xa","to":"0xdef65f8e2f62bde60cd86ad3b4ad7fa6741cf175","transactionIndex":"0x25","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x34df85658956c9eb71549db3a73abca70dd01b8e91284afcd372c1212a36605d","s":"0x5036e2984bb2edbb5fd647bba873f1f5c5ee4845e539c9b0bc70d3d12a4bd93f","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x17299065e99b12b0c8cad06638624cff8d507334","gas":"0x5208","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0xc95cac67267f4accb9b5950316ac64772f7d082bed6b712c09cf2da0bdc237b7","input":"0x","nonce":"0x7","to":"0x02647cbb1714fa9a5747ec5be6333e06d806e85a","transactionIndex":"0x26","value":"0x71afd498d0000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x82ee5cafbd010cdf7a4604df728d1b8713a5bd26a708f5c92f6b6a55864c9576","s":"0x2b9a70d812123b2ddce1108c4101ddce182f6c83fc8aa0a139ba597aa178b270","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x9aef7b879787baf0c2dfe888e67a7edb7a233209","gas":"0x431eb","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0xfca28fdbd13fc16daf7aec7d4a2ad2c6b5f0b2a7b0fb1d9167c09b5e115ff26e","input":"0x9f8420b3000000000000000000000000000000000000000000000000002386f26fc100000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x2","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x27","value":"0x2387acb3784000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x7e5f1a27ea5e652ec8705f80365f1703d2fd50c1de7c22ee0181d556dd2fcc38","s":"0xb22fb8b31dbfff8ad0457ba4b659fb0d7031cd86f08fc3cb78d81c97248034e","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x06006a25e0fe65f0eeaad1f4813940b68db782a7","gas":"0x17ea3","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0xc73124ca798b2f7a5df2ea4d568efab2f41b135130ea5cc41d4bcb4b5c57d5bd","input":"0x94d008ef00000000000000000000000006006a25e0fe65f0eeaad1f4813940b68db782a700000000000000000000000000000000000000000000000000000002726bc7f1000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000","nonce":"0x6","to":"0xb5d86e1f237d52f1f19793d3265e9340394f75b8","transactionIndex":"0x28","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xabe4fc843d3a1628a464884c13c21bd21ae9a0a5738d9ae2761ec7cb24b059d0","s":"0x68408d8096e542b2c06cbbecb9494a3778c3ab644e69dde1fac078079c4bcad4","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x2501bf5c8ddf04a60fdd47a95d53d99b315604e2","gas":"0x5208","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x29abb76b5e7a5ce137bf9c22474d386eb58d249f43178d2b2e15c16dfdc5ca80","input":"0x","nonce":"0xa","to":"0x901a4e04f1513443c6efc6ce4e913d1b960ecd20","transactionIndex":"0x29","value":"0x1a3385ff37f0000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x1a1789d5b19950f45383cb1909cff9128dc2b332e2ea7ba42cfca5806376e3cb","s":"0x617a5a4339503a9c9d08705d98e7a202ed7ede1d1192fd7d98b648c8c102716c","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x507832c92ade971b9a2880427353c6ce6d0ffe53","gas":"0x61a80","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x03e5ab25a58bd44fb9dd0c698b323eab8b8363479dfcbcbb16d0a0bd983880ae","input":"0x85ff842c00000000000000000000000000000000000000000000000000000000000000c0000000000000000000000000000080383847bd75f91c168269aa74004877592f00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000006100000000000000000000000000000000000000000000000000000000000557300000000000000000000000000000000000000000000000000000000000000014507832c92ade971b9a2880427353c6ce6d0ffe53000000000000000000000000","nonce":"0x1e7","to":"0x805fe47d1fe7d86496753bb4b36206953c1ae660","transactionIndex":"0x2a","value":"0x214e8348c4f0000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xf707322f65ba56c95ced5654efafcf9bfd60a2dd80e74bded3190673cda55d8e","s":"0x46412ec3d2137fcef30f53cc4644769f4da126128979920ed4e209acb1c8ebc9","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xd44c850ce9103d6b2398d4ed9bbce321f3b769c7","gas":"0x1e0cf","gasPrice":"0x82661bff8","maxFeePerGas":"0xde6f782ba","maxPriorityFeePerGas":"0x59682f00","hash":"0x3c8ee80ddea7fa2d2b75e44563c10c10756f598e8ad252a49c5d3e8a5c8e6cbf","input":"0xeb672419000000000000000000000000d44c850ce9103d6b2398d4ed9bbce321f3b769c7000000000000000000000000000000000000000000000000002e2f6e5e14800000000000000000000000000000000000000000000000000000000000000000e0000000000000000000000000000000000000000000000000000000000098968000000000000000000000000000000000000000000000000000000000000003200000000000000000000000000000000000000000000000000000000000000100000000000000000000000000d44c850ce9103d6b2398d4ed9bbce321f3b769c700000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000","nonce":"0x9","to":"0x1908e2bf4a88f91e4ef0dc72f02b8ea36bea2319","transactionIndex":"0x2b","value":"0x2e2f6e5e148000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x327a6fbcaa2ac3cfb0ce64b47f6e61de4d18297f1305f23c6bfd42d88e8d068","s":"0x6b3a9b5252ced14b2e2f2833ad7cc62c46fbd0785d57f2747473af3fff7d46b8","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x78aa9046272fec8d51a402681d7c37481db01c6f","gas":"0x431e0","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0xaffa73b68bc7ab0c3f5e28377f5ca0a5df33c0a485f64dc094b7f6ae23353203","input":"0x9f8420b3000000000000000000000000000000000000000000000000016345785d8a00000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x36","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x2c","value":"0x1634632a1414000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x925370b51dda3e1d1bc6b86580fda3b40875157ea594a9a14174436c726ad46c","s":"0x516c88bf3cb2f46ca81572140b41e5db2d74c4a736ee7d572b508415c438f779","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x56784e51c2ce28dbe9aa68342638d1e95ea4324b","gas":"0xb72e","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0xc66c9c66fbc8fe97fcc16506cde7a58689af1004a18c6171cfe763bcd94f50b2","input":"0x095ea7b3000000000000000000000000805fe47d1fe7d86496753bb4b36206953c1ae66000000000000000000000000000000000000000000000000029a2241af62c0000","nonce":"0x9","to":"0xcc7bb2d219a0fc08033e130629c2b854b7ba9195","transactionIndex":"0x2d","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x407c855bed0fb088e886c3721ee9abee4761221d110512ac29b8fb143c4b34d4","s":"0x1e47aa957d9ebdb564dfa41b72022d525383ffd825a307fbfa9ca13a59994dcc","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x805e39acf2f170251c48a35df16411cfb2f761e3","gas":"0x56a8","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x80fec96707519172b53790610d5800cd09a4243aca9bacfa956c56337d06f820","input":"0x71ec5c05aa669c4922569c1d33f7a81aaa21813800000000000000000000000013a0c5930c028511dc02665e7285134b6d11a5f4000000000000000000000000805e39acf2f170251c48a35df16411cfb2f761e30000000000000000000000000000000000000000000000000000000000000000","nonce":"0xc","to":"0x7c125c1d515b8945841b3d5144a060115c58725f","transactionIndex":"0x2e","value":"0xb1a2bc2ec50000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x8fcf376106af19aac48ecb840ea51df90a5e3ba557eeaad41cd3c8a90785d416","s":"0x4a9e9021ddb5f839bf7f54b54ad52c57b21b6ed285773eea022e3ccae69d1b99","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x4199614bf74f6b3ef47a812d976dd1f57a8f082c","gas":"0x431eb","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x61b33bfcf11214906dcdce7d7ed83ad82f38184c03ded07f7782059d02eeedea","input":"0x9f8420b3000000000000000000000000000000000000000000000000002386f26fc100000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x6","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x2f","value":"0x2387acb3784000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x3d295f5fa2dbec04793f07adec57e29c03376c628a0256ee297fb3070a1e3364","s":"0x6f115dd4505bd320bd7460a47bab0c20e6bcb4b3f17c6d0e00e3ff1d936ed2af","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xf6df8ead0bdabfba61d9b2457d5a5ccec67fb7f3","gas":"0xc7c7","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x5d4138d4e28a8327e506cb012346b1b38b65f615a2b991d35cf5d4de244b3e6d","input":"0x67a5cd060000000000000000000000001f1f156e0317167c11aa412e3d1435ea29dc3cce","nonce":"0xbe","to":"0xccb0f4cf5d3f97f4a55bb5f5ca321c3ed033f244","transactionIndex":"0x30","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x47bfb48eb89a8b110749d34d171db36a8ad21c8d7cc78c7489e72f21cd86ba14","s":"0xa525976583b19b3d2c2dd6b34324cf55b1a61595cb53e3c58acaf203f8709e6","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x9eda8333e09828571db26576a566668f79f98946","gas":"0x50df20","gasPrice":"0x82661bff8","maxFeePerGas":"0xc8d5e2427","maxPriorityFeePerGas":"0x59682f00","hash":"0x875a142b6dfcf10ffb71a7afe0ce4672c047fc7e162ba0383390516d6334d45d","input":"0xb1dc65a400011a04d404e571ead64b2f08cfae623a0d96b9beb326c20e322001cbbd34470000000000000000000000000000000000000000000000000000000000bd780a7d2e00ee03a29f787096cae99da52d07803c76c13473654239118e2cf0491bcb00000000000000000000000000000000000000000000000000000000000000e000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000480000001000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003000000000000000000000000000000000000000000000000000000000077359400000000000000000000000000000000000000000000000000000e50bb6420faa6000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000e0000000000000000000000000000000000000000000000000000000000000000217f0aee859cd78a5cdf79c68c8de4342658d52ccc6420181b5fcb7c657c5fdfa5ca2c8f2dd7e6e5799d44d6818e6dd8fee19b2530bed2045e0c665041f053fe70000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000001200000000000000000000000000000000000000000000000000000000000840235df8360bffc902a68675311f5eaa79ea2c25e2cc394bff0a43d5d608e98c97de200000000000000000000000000000000000000000000000000000000000000600000000000000000000000000000000000000000000000000000000000000060000000000000000000000000000000000000000000000000000000000000002a00000000000000000000000000000000000000000000000000000000000004b000000000000000000000000000000000000000000000000000000000000493e00000000000000000000000000000000000000000000000000000000000840235df8360bffc902a68675311f5eaa79ea2c25e2cc394bff0a43d5d608e98c97de200000000000000000000000000000000000000000000000000000000000000600000000000000000000000000000000000000000000000000000000000000060000000000000000000000000000000000000000000000000000000000000003f00000000000000000000000000000000000000000000000000000000000007080000000000000000000000000000000000000000000000000000000000061a800000000000000000000000000000000000000000000000000000000000000003312d88cdb7cfd5fc5458d9a424da374cd818847f87fc4fb6eae2c3b97e541a6b81e108e55daf857b71514fb7213db7ba15bd6adc12253afc3c5e949144c13696faabe22d1b7ace91532134a5cc65bed9afdd897d6f84ad1b0b6da463bda8fde5000000000000000000000000000000000000000000000000000000000000000352c2a75f88112864819de485c392c349f718fc257934181c4d8ac8eb3a9b1fdd3b7bfb96496290f2b41fcd20fc8d29bd8e29be38550775dc97d21b17c2d679ad05f519787eb2c92a9a897c9f02f15316865cfeb4bcc2c0ba5ac2dc4aaab5c0c9","nonce":"0x3705a","to":"0x233a95ccebf3c9f934482c637c08b4015cdd6ddd","transactionIndex":"0x31","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x7e9247209bede2c21548c6e4f26e41d2636a2490e09ad062f9235e978094073d","s":"0x288d820793b48e55777e794f1694b1605d74dc8726fff438b481125f219eaec","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x6df2b54f23ed4e95235c6e21ada2cfff5a2615a6","gas":"0x5208","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x79b6df832bfbd04085d0b005a6e3ad8f00fc8717eed59280aa8107268b71e7e0","input":"0x","nonce":"0x17f","to":"0x6143d939b2d117f4b998d8d88a56eb0e0a1e9c31","transactionIndex":"0x32","value":"0x186cc6acd4b0000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xcb641be908976bc0a035b0b31a96039da9e63e829e0a24a092ecfbce7724b9c7","s":"0x4034e7dc4001cf9f62a2e5dc4390229655b85e9aac5a5b263278e9d2cb43abb2","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x3f5ceedd435b6143eba2254811a39fc3423f18dd","gas":"0x186a0","gasPrice":"0x82661bff8","maxFeePerGas":"0xaa246a58c","maxPriorityFeePerGas":"0x59682f00","hash":"0xcb2fb25d268f65dc9312e89bd3c328c9847a3c9da282026793c54a745f825ab5","input":"0xe9e05c420000000000000000000000003f5ceedd435b6143eba2254811a39fc3423f18dd000000000000000000000000000000000000000000000000001c6bf52634000000000000000000000000000000000000000000000000000000000000000186a0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000a00000000000000000000000000000000000000000000000000000000000000000","nonce":"0x0","to":"0xe93c8cd0d409341205a592f8c4ac1a5fe5585cfa","transactionIndex":"0x33","value":"0x1c6bf526340000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xa48a4ece6fbe881e342a4eda767c82097c3bd47dc70c09ef6a4e7f90c0f8e843","s":"0x66c92f16907488d115f5088ed8ff4d71c966232458479245bf6dae45358c0429","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xdb4f0eeb7c89b00118cc74de8c9ed55d65c2b933","gas":"0xb72e","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0xe483d4a36ad19fd5eacb7f6d9ad3ce080ad70ac673273e710f6e3d5acbc6559c","input":"0x095ea7b3000000000000000000000000805fe47d1fe7d86496753bb4b36206953c1ae66000000000000000000000000000000000000000000000000029a2241af62c0000","nonce":"0x120","to":"0xcc7bb2d219a0fc08033e130629c2b854b7ba9195","transactionIndex":"0x34","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x6d73169394cb6a9bceb2dcb16aacd261705096f50f30ffe146a09659e25dae48","s":"0x496a1cccf01ad2ae7094b8da2ce50c0a990baba6300625c48ca12c5f20005a64","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x9ac253db14a434cbe7653a99c5039648fa4f7353","gas":"0xb4f8","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x0564242c37d5013b671ef4864394cc0f3924c589f8aad64118223a9af2f164f6","input":"0x095ea7b300000000000000000000000028ac7dbbf9ed6ece39a902e76780fba60f1b2e3b000000000000000000000000000000000000000c9f2c9cd04674edea40000000","nonce":"0x4a","to":"0x0dece1605795461158538302b5f0936afe78c4db","transactionIndex":"0x35","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x15684c9697dcc8d89abe562c4315bfb959938fe7644c00615d9e147a4e496ff6","s":"0x7c58abea24e1fa8caeb73a70219b0d63007785c39694fe5ed2a5a342c99292a6","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x22496eece162f52d185c07524d452b9506e9fe12","gas":"0x186a0","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x48db358e80b278c3a46c2a166339797060a40f33984a5d974992cd9722139d5d","input":"0xe9e05c4200000000000000000000000022496eece162f52d185c07524d452b9506e9fe12000000000000000000000000000000000000000000000000001c6bf52634000000000000000000000000000000000000000000000000000000000000000186a0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000a00000000000000000000000000000000000000000000000000000000000000000","nonce":"0x0","to":"0xe93c8cd0d409341205a592f8c4ac1a5fe5585cfa","transactionIndex":"0x36","value":"0x1c6bf526340000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xa50e6ea1eff21fd33d69f8c74b90c28303b92ebc4a77c71b65c4c8bf3e92ac8c","s":"0x29af3bce2365578b76dc528917b44e96e4fe2e7a8f948eff3e379721f35664d8","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x9ce3f4210dc06889ad5267ef0ce3ded4bd96dc50","gas":"0x249f0","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x69d7758db91fae31fa35ecbed4d40897c5087f45dc796cd796b8ceead21f972e","input":"0x47e7ef2400000000000000000000000089f01bc9865324583380d8d7ed08b8046bffd7fd0000000000000000000000000000000000000000000000000de0b6b3a7640000","nonce":"0x1c","to":"0x6cf3df5d00e842aab1eb504bcf01ebf81646f7b7","transactionIndex":"0x37","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xeefc19e8dca874308c84712c3e48c032a25971a0f7dff16dc47633ba7a4f5b96","s":"0xc0994cf21d29cb0c5f1e666538b58d6dff3b9ba2aa7545337da732c4b5938cc","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xbd1c4e36842c06e53b378eca310cd2dc79a78cbe","gas":"0x35965","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x2951478916ecd27a8e808d08f85be4bf2c0b0e0546f21f4e309145dd96eb8df1","input":"0xab7d7969102507275d685f3f55d10ee45f7b9fa39c29a8a604a7a971c05eee739e63938500000000000000000000000000000000000000000000000000000000641cfd18","nonce":"0x252","to":"0x96e6192eeaf7bb308f79fb5017a9085754b9e12a","transactionIndex":"0x38","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x87fcffa38e0c84cf80fb37ac1e538faeca21462b0a9ec25af0ca0517af22789a","s":"0x72cffece99e79edb7425a9d660590fbc395cdd0db8fd4848074c85f814b3cf63","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x5dbcb3e489fbef1656dbbd7bc4848ed0e520a089","gas":"0x7a120","gasPrice":"0x82661bff8","maxFeePerGas":"0xc8d5e2427","maxPriorityFeePerGas":"0x59682f00","hash":"0xaca9028cb5d55bbf71b7bff9884a9a3b0b38a575ffc8f8807ce345cf8bd298ef","input":"0xc9807539000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000001a00000000000000000000000000000000000000000000000000000000000000200010100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001000000000000000000000000a7a9d91e687decaa6b045797c2e002d70001b48f03020003010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000600000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000002361273ef6f000000000000000000000000000000000000000000000000000002368a4faa14000000000000000000000000000000000000000000000000000002368a4faa1400000000000000000000000000000000000000000000000000000237b9042149000000000000000000000000000000000000000000000000000000000000000288e1b54f6e54124deb78bdb67cbfd0bf63612da12868fc281afc34bb26200a1771f9e00fce297da11cf49427becf350d0bd20a2277439fbb2e8db0fbb5e3d34700000000000000000000000000000000000000000000000000000000000000027d16a90ad0e1f8d924255e6380764fa7c7d46427c8e8ea19f5ba6a9d595297a340f141f74e705d0fe851d7564eba89fcde574deb5975d9126867cd927a0d92cc","nonce":"0x11d38","to":"0xbe57bac491de9a260abb6ba2c9ad4c5d2eaea09a","transactionIndex":"0x39","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x1eba7bf95bf63d02b74d20554af050eedd78ecfbe1a42ec70badb36ccfae4bfd","s":"0x4d7f8d0ac2be28e59374453f24ae6506a81707cc57f0d1c6877b49b3949a9a79","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x3079be9d8622173f02618ba2b793f00795d4f320","gas":"0xf848e","gasPrice":"0x7d9f6fbd8","maxFeePerGas":"0xd9a8cbe9a","maxPriorityFeePerGas":"0xcfd6ae0","hash":"0xc7f625a19ee41a1750eac9428b4394a9a2476b8ea2d31b4c2f9f5b4fcb86cae3","input":"0x2169f79f000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000fdce50000000000000000000000000000000000000000000000000000000000003f2000000000000000000000000000000000000000000000000000000000000001f579a43ce4f3e38c6a948f1ef3bf7954c2059b087b18fdb22c7b69d61727a5d2aa16090b4d1f3281bce660a31d3e2789eeb360192a54e3ac3513c5c8f67b7346fda957c92c1a2981bc68a47d0282e78df2fb63822f06f410e1ffbee7eb83c425122be9be94d817e2e42099632fb9eb5ce7c414cf6ce48e4ed2e64e46e1558ca809742159e841e3de803a8cdc628f7877bfa6d75af4b4ebb185e6d0670ce83332478137fec243a38c0a80d067c955cbe13103294dadfc8c356d0e7996cb62fb2c683e6dd5ad58be934f57375920142990074f8a161ad2390a1e6bea9fc3a58dc3f7e002e9952a68bff229437d3fb4cc1cd8097032b22c884868253d8f2f69c75ada0fbe1dd57145610ae5f451b47645718aca7432d8cd3193d0b96417df6638fd47062a1cb1f63636236fb72195e5a46d1b37f493b8380315e5bb1a6fe67cc6546d62f2c73aad5699e6ffa0d49ce653bcefa173fe0de7b4328aad75f74d15f4f570a1839514550d576e21b8d16c8355b770442f0740e6e5e77ab450ee1fadff8daeeb25a91585192fcd3cdd64dcb6a35e41ff47e854337ebd0923ce280cdacff2ced48eac96bc9f910391a44cfec243a8660ff80c10ff844ea22411953e0387f87d2c2ae81055fc8e87d59e04cd7a923d6aa5204b3eaaf5b842b5fd656e9fda16c59e90c64ef51124fb32f8e63442b1f79d3ba3c0cd5fb90895103719629857d5999b44aad2d69380f48dd824795a89dce14bb82600701ad8fa9bbb36fe93a97d75da26ffcb1a8828918e0293680ecb12e1b772fd98637a7a83cffbca1a994fc889ed0c0b20d447ff727b9f5dcb9a83e1aae9a3518dfe1d7ddab1da48310eaa7ab293d85dd9ca811bfdfee990459fa044c9a9fa6460e5ff7612e42021f16854d790710684663bb6a10ba475fa602b02519f03eb544fe486d9cdde47ab7d4027bfb8f29d778b3a7cc35a9f78dbb05943062efe3b388f1a8c496682a0215265b99fed0363a1061556a40e0539a6656b6cf8967c8fb3092a7fc9b56af124c8f1bd0abbb9af753884b22b333410d47d80c083c9fee52dda8907be0c87c5496f1fe9ac4bf4dd4f06d6ac0ac0cde22138b67bf782e8e9b5c991d58a2a828b4c68620e6d3d26abf8d41005a00866cb4095518b2711636f2fac3b5e26403ef96f5b1765519787ed74c6802b445de029d7bc696aeef5a2e605376aeda4f495c29af66e357c6e1232d7a2c3f22c0bae0c62372d6b2690e503804e2ad314c38a4ffc080d36213458f606075d32dc0a365087616e94a972bf76d7e5eb4a53292fd0d7570cb6fbb4540b3c5ee6deee0f257fe8703d5d8d0180d09754bd9a05894e77318b8c8fb6b4a56999bfc6c405c09d9ce7fe424812db5bf778d7d8634b2f44ad6d00f18615e4c3695d9c5965ba51991508405187275840a3f27cb3101a9742c49edf42dea79ae5418ada42dfe2042f931af15a205e64196b04ef53492a450423c2b63dc849ef72a166fac5f36b25c72d9cb4a2507d5ad15094a979b4ac4ff8eb4c90f448a81fc6dbfcf6a228675ab3308bca37bda8eda22b61ec7e596f2448ee6b7cb6eef589f43f28fc5444d1da3f82ddbe574b774719a3a7869e897e642735517832959ea9cb9164eb2f7665bca1d2e44e1093acc7088271f2be20459c383f5762303b553af1ccfb3371e4eef1f102ce70d62620c5164972facbfbe03b5018265ed62c4c3cc49522166913517e2f2718edb591047a72e818f07c645a18aed87c0384d180dc0bb7fe63bd335b1c09e58571b92e2267ffa5712a33e4a92231d9da7b005730f6d6559ee685edad9a9031c4708c8642c297287af3a3e637d9b5ac6b23218977cf4d30231a79063987f98313a2bc0ca4a73a97e441a45b58cdd8731fc269255b415a9d2ef2bb8a311587f39f6dc82f537cf86a68af19a68c409910f4dbebdfa66445361877a3bf551480d115d8768e8650e9979472a64802da3625cdbddee8f02678a3cc6400824d91b3c7d4c9274b74fb11a9538f1990fc314d35564a0cb0b384590e15cb93db1de1a837b9319828b3fd6b76f1d2bca4ac765f9ec4366905f2dca69a4c8c194cf0a5d821c58bd291e8dd4ddd829a873d093042c1b8e1bb2bb1a95e150c0a0d5c3369c4a791dfcfbc3e631da3d1e704214c3cf8318901f9c58465be78a870a040f34c567c27eb077db2d1ff825a127a038eb14c2890ff9a8a1dc8d6360a91fd788fec97599a318ab03f69bd50a5ece92d96c49413b517579ececf71371b6b1d902b1dbbf40c728c64fadf368582cc4b3c51712c8d6441c0c61802943624e93f9de9eedde87056c21ecf66b3a6977af0261ef48b4c6191ca7ea70d6acc5af910ebf247e2a4429c506c6a41f865175a9bfc81dbb69e59ec2c47370fcee9169b8749c852e7a1275c1278aa3f88bc16d311e58aa9a579ed7bed62f12b4c4dfe9c493cf33f979f667eda043c2aaaf863a747b208f3aa2ccc34f07b12d89bfd75b696a82c493e7eedcdc41eb01321ecfdcb691d14996c3ed7487b5f831436bb7c25876c4149cb6222dbee9e1a05771a8abfd0fd530266476e1bf69d9a15e99c901243585f56a77ef0e6c684a4d49417133ebb91f896176ec3a8f0b966eaffce96f129d18960fdbf5917f8aa0926d52c57192f99e55959369e57ce85ae84ad944e40652f6a81ab8da1dbe81a827366b8b8d2ffb9c7b93087f7a356a16d0022ee8ae891060e29ff11f9f17b01f39b8024baefc8b928a6816309a5c3fc92ed6007499353b5f1bc5700d5fe67f3e34ef3654712b9c67c231f30dff485213b94c20afaa91540560df80ba9ff1cc0f6ea75bf1dac0566551050873c112478f3fce6af162397161e1b41e1ca295f327a4f0ccf4d15fbe58e20a23698bdc25c751d020df371cd1fc59fa51dbf7ad619d208d7084c5752984b5fd0e3a7978f2c11e6b26531fe03c0cb85519483d668bf1dc4dce24509b00aa6e146adb49f31c2c937a2d3a08f1cc0b73cd66f2cb926f0453cf78618e39cbfccd6e6a3b4909d6874872eefed0e395ac2582d8c1d0483007fa6ed7b735323fe8fa1c4be83c725c6b743f63cbd0d6017f1145634b0b905552a2a237561b37c415146d0555a276b4b45d515ed7dab942f9bf40a26d5366032f23fc5fad8b98a1625a841c8cc97dfe0e2074a363a951946df16d1261ef6b2da7f5789dada153448b076637f9d2e04f4390e9dd32fd5e9ab3f5939807bb451bd19d962403da9dd118f1cfa91731973bc721e5ae4a687bb2270e3e76966dd2156e95796d4bfa6b4c10caaee46e1d8f8495f901cfc241c6f9a690349eb0752adb220996ebb95ed26ef376dbb9eea201906a6a3eb346c64eba3c9e4d1b3088baa0ed868cdaf063a4c2434b9d1bbbd69f44ef659262fad9535988ce729aadafcfc6c3ff741dbf8b784b3465fb05f6d5daec91e915f89117e01c9b0c99d7b7cb78e44f5c28de0d3b782de981be058ffa1294072c4e5a66d2d81641d1c07a9a04012f9f1ad15028709fba761a659becf01963de0cc42b0e16bc5432cffa00722a84628373198dbbe75f209115c4e30e60297c2d737996dd9aac330f4a3e82609dd33460438026ae287c172af8aeed0d6c71b1f9470d60588ebd365f20d596999d97c7a6f265890c719dfe43ae1ee5bba122d9d4cfc96b399f610a90606add4f0d25b903c7ddf6eb7bfdc3b9f926243108f591678b0e92a48d52b1dbcdf30ef8af74cfe34d48d0e02d0f99af2adb090c489d4214f3562d3f6a6e9b83b54bb6cfe6c1961ecd2eb2b7eda63601c835c5dc696b32bc495bda9b6567984f83e79a9d4ee88b140dc78cdb64a2ba8761a827cdc8d2b27e690c22402178ade602f2e9092a1b07d56d142bd24d665d7b10bc7646eb6d6823d5622f1fb08f2e48b8deda6cde324d6508fc428e3bf1a9ed608c196786db4e8d6b7271a07e4f73d9ef76244e3e10aa13fd9b82ce2ce72af2df7faaecaf95d885e64bcae16f9b59ab8e0f21a2f459d00a290b0dc57e10bf21ce06a029224ae15cb86bb1cf060ddccb1f6ae82d767eb077fa4ab0f37d02a4bede5d3f8ee3972a6a3a438a3cd92ffd6c1fb11cf2c68c2c6d1efff62b9f769e302f6c5eec96b0c05a942321ef8b9cf0ff2bb80073a8fe138bac5bd8e93f3b27e7ec7a78512059fa37b0b6939f3b1311cb6ea154909e9d316567e013df315e8f02a80e17feb8f3248cc3f11d1253ef3156d7f12d1f6d7a382d6b6ac6abd38fdb5d954e13ce005ce16bd5625a5df01883409f4ab938a59a75b7a816af6a2447b2c65ea55c0ec4e4f23fde145a26ef0b13b740b352809c10b54bfdf30592a8b0d507cb8210391d66d6f68d06f3a4663756697d472adb6ba78976b423ad9ccb3a3bead9de51e324fb77609729c78664f4d37c7c748ad9fad95af355be4f00a76cd5cc2c0b6170fdf3efaa2571bc8fc2d0d24682fec5e034460de55cd0426b8ad448551032e1f6ade6d96682bc38a92c296e5bdbf42fcf106d14c5e8a4acbfc0cc1f0bd6877c4469be8b204ffd5d7c0ee85e7b3265011ad5e4896f9f8a69997e321a797549cd3c1cbb0301ff30c3a136068ba37b2176e556b574a542db90250eca38f3b0e418e352b5728206d6d531ea253d781d771ad974b476a045ff14718d9a1820fb469e981c7b71ae8fe423b0a04278bcfc967ca602254de37751127fe3716456df3fae50ed508e529c2181d63479b6464bfcde6629e8179f8d5fa5b61003edfc2f129affa58608d6145de98ca8f1c0b3b9b5ae996a7fbc6326a9ac2880206fbeb1c99d0448cd1ac5f275b84e4be03258f9fd0d3f44a692513957fa083a462086787315e38aec8c09b96cca034cc6294359fe00285c607d41fb4e3bf25760ed1ef0802bcc40b2fce2cfe1c64f7c34b21d0bb1f5210360079ca8638ab42943b0ab8277f1cfb1e529073d2068a36a4d8ae8179c32bf66ca335d698f76db1cfe5236e6427e01804464c1ed4facf18ae09148c5a0cc9ebcf6fb6c7d03ec6782b7595816245ac2d1fdb3184ea49800d5d0f1dd880ff99d6016549d63ba2a44ab96f0db0d0cbd5fd4f67af1f1da0b1023883d4b2e7cb23cf85c617c180a771267fe63c70f19eee28fdc50c57d73b2718f8001383135b859f4c2fa3b9a12d095beba8857df13e921d9dcda5b87e1fce6038fc2f92282c717305157b6fca5ca2c23cb7307a093512f985628e75326e0bca2c4dc5ed44bed8e0cbce1238f4023089a81bf62b04a31539de9c8a0c867b791c18a34abcc721c0e90a1604e8d2855e78673367ce463307f6036850b81e0aadc9f81d8c9ad6e3b81d7850d4a46bd6772e651e03581a7a55568c9d63c1b1e8ca947174d68afcae6401b75dc7397be3c0dd76ad1827424f9ea9de8ac99803641535dae3eb57ee1eb1e2c193bf66addd488da55055bcf93172b1966364db4412e44bde64c50f7692a38d1536683af14fa057569cc7ef11f614a58995ade1b12f979005a53bee0769847deceab4f58f3d062767f7ac0511a04fea349e7688ab26425cfc369127325ab7fd24d73c4a8b23f099892b3bf52f35f0d775ba753098611ce35c56873a7455737a42672747bcfa99da8c8d0f06d8754d2babe3eb303cb06ce69e4046541ce63b6c28ded5a6fbf729200060132e9b01d8646b512356c92d8a642de0f62d169b195cc2e7ea2efebe550b1cddb5df7668a0d1f94a2f5cdf7897e46cb03b958ad906393c7d252b58493ce6c7d813c8fdfd5ef577a9e778c64d48c21b130c4f6a57985b8122f3cb69de015081cd3e247de65643f9d863fac6935cffb2ca23083d4fca9b8707679d9d4c3cb34d05d092334b1740ccf4b2aeae724902ad4fb4bceaa642b3ffdd5b564d7bfb725fae91f5c7ab9583abc2d80afd2272b14ec6fafbc51e35bebecce63bd95fa3f39e4e689034c47628345c4d8e30a73c36d87d289b6ec715a2769efacf39c9f19eefdb311b9800377c5c61aadeac78dba6946da4e7914415eced875b66f10b96ec98f64e58320bff09e8ac4f5969608171dbd4ab5883548a289b52d55aa82da62ba3d9fa59734d8f810bc1a40a0e3b2e116873116fdd8bad95471f16a14054fe247637febb6081d00e7ded3019ec03f76ebef5401a27f380fbe8a55bb4a0014f61276d9aa5626a34e7fe5a129a75ff130ccfd78cfbde65416882ce9ae9da57a3a04c67d22d3a12e811b2578fce5f6a64a09a86782bc15e5872e546dcca46bd9ccce5b787d17c70d6b075bf4c789ca184dedad3485a0526a61d280dcecd984fcb7ec663f8f491e91253675877987433e11b9cfcb5940a1357b55fcc5f977fc898f72e8199ed5d8d2554d54a55d6b4b3726e7fd7093996e271e218533f3b31257aa989f5efbdb12dce02d18a5188ec32c3c1c91845a17011ffede3f060f19d59b6565a352e90c5ca30eb252c6fb0cc845833e553f0bbe1822b5d6b26eb817608799b5b77c2cce27beb151060261f34ea73db94bb2fee11864aff76da5b10b17aba6634ae655dd396fd7e7155013fe3c6f840ab1ba9b25489c67f6bd5967a62134b238c325986c87aa005396c54af6357ca88baf5a03e353c8b0175386157d9221833585921d581f1fd3f5d9932b24d41895a5c35be91b35643e7091a7585ede900853aebc260b1fbe8b72d527390ddf46472f7c8d5844355ffc0b731dd5e584e13d65f2347131ba8a5161a6749458c1899b60cf9f9f8810889fc23b5d0fe2c843fb5675cfac6dc8ec8125d1c582186eac82d5e0b3f6df2a83eb2fc23c4c3f873267deb5ea86dcf1e3c5bb39df23f06560609b9fbd89511281fc7d69fb19764c41168a539b44f0603a52577c266fd601c0cc849b067746b4da78d280385ef80a3a553dabe4b137c50152f4e1de456d43e015e26f7d76e612b7be29b9f8e15c6a73653f5f7dc28aa245e64f076130bad58bbbd3b024c97e267a96365f019846d965c037116c74ef18415ed5500f12a1816997895f3bbe7b0fa1eb12a565255a64d5eceb2272027e45ecb0a1a8b5dc99128c002058c569076371703e1f10368c6cfb830ae8bc688eb143da7a1780dbe29cc4c83743b25d570f5d8609df46c807edbbc96358cde9ed0d9b8936271b3ade28001a6bfa6ff7ffeb4e6a6687e803b5e8f67b82e6dff215ee4f2caee571b8febeeff368a89539d145842526fef110174ba3a2d9f1b4a348dd25dd964efcf88847d3eef1c18fde81ce84b80cca8588bc1fbf9c9f34059808d3eef3fc2cef7636f7a76c533933b79a9dd2ae2791d1ab5e1e715837a766d9df1947d5986c21808eac758461596870b744a6a2862f7f5bff0c7a3460875b3b326e45fcec1cdad1cb4b99085748d69a62320f7e6c53c061a55ae20368a4e6cfc126cf2c0b410af545f169fcc741cfcec4947f577a1bfad47b5080ecb41760b5056a9bd10a10ca43677de0e06bf36b0d2bf7ca605b9217240871ed1ce43bbd07a7e77d1901dde15e173ca344ee8078ff115e954a2fa660bd4af61ac32256fa7d62af17a4f95adbdcd09b933fa47828d91a6b710a5c67195797bc789647db90107fb527b8ccbc1200bac302dc47a366d170314f5fd7b60535130d76832ab7a06ebcd83d064c1a1c5a7386b0945d39f8ddfc3503415ea22514a0ebd0ad74e3ece5508d83355cba944b12b669d6355a6143921533190eaeda0337a1b89ff9db0cae62a239025bef078137362db71a9eaa6d0a26fcda7e80a9b8fa4a1799819f0489b899cba4048c999fda79e0bb046d7e765d9abb445279efd13d47fde8b731a944af92da8d8965bc4e90d9da8ba0a9c385357e16788cfb663573d9d34810c754e86e3293a868461b241d7872911e676e73136557db1261573962221589850fa5ce049d2356e6630a142427a2cb2efecfed09445edd112323f0071f63f6a42035a9248efe155aae056db25b8004204d530d27027c34eb6937a5a05bd2096eeb1fa266a0325cbc7ac03270b751013b53429aa2d8da2de8c12e7d4996b5f1dd365e270285d2f3a65bdeea9346d960ecf015215a88f465a66417d12d95be2c0bb3d8e15163e0dc66028a30f1f5506558ef534ab28cf6dc2b7d12f49b0e319995efbde71978ef7121df58bbd16be908298b0abb6197bec22c598413283e7893f0fa7398369b83d30b29560ad09a0a24e029d0c22a7cc6fe53d84a7b2104681df35cf4c3ffd90b14cacb2ebbb673ddbbba291feae96498b30d024398676107d3efdce47353a544c9d885cd5cae19588a4b9e29c700c539bbcc119926e3d1adcbf4e8fa3dfb0d5c2686a3fb4ae7b4b278fd94db5efcad7f280488702d9f7675aafd248960806df3e8f95325298968a8e7bf54cd2797decb5bbea7bd3cbe34081c0b65ca9a4d0d08d86ff39f97751471e09f25b486dddfb2975edd51ec77d949862dd4a658ec974b8a5a381ca5b7314b677c4491e07b43a5a9964d95e1a29fc1d87cbf1a64296f4cbd8128ab13dcb60dfa8593a575140f5a9fa6a3708052b3bbed4b129aea88e66b72e583f1fc285ed6f835df0d4751c5d5f004ee0c65203ba9fbd8ff70fc255e497748f24c476d18c94089bcab8ae3f933563c6682e5452da8f760943c7efa631b2980e6589ad4ee83c88fe0b2ed9900571c3df6bac839df1a6d9d281a5ff627d41ada13b867735aa7377386182b1b113f237c14b6d806079d2f7c234a7cb585e12a5b16f7064fccff99386d58f91d9c235eef730660a02ad37dcfb0352b1da76d739ba7bd4982cbb8be48494acab84451bb39bc59521c9873ec9f53cedb527332c47afd919c94d777e603b405e8563248c9ca72f3b2fb52f08a876778d18e7d179f6437b64f79ca01f6be06d7b115b8d3c3320c2dc0ac59c860aca8c92407ca2239998613f44945bbe2c6a0ef0890ceb27467d1ab805ec960e6e58e49678a0841823632f62c58f540f19e82bf719e12bdc63db5363fc0749877539865a05786106b58dcf50bbdd015893b043b21bc1f24ef9eee5f2487d986db13c143d3366260ade522ab824fe82218daafe5e42c50ef740cb9ac570a13cb55fc30c9017228f2c60680f75ca89affdd376ce70ca5223078a47da0aab9bd18333c14aa021e6c088609d7a2460744006f149b648116152e7c814a5730bedeb6ebb59fe395e6b15d379909f197c4703dff34f8915b26a36e30088cb227fc1df108560fce419f462181e468b5d94251fe1373e0dd004fad02d690f8f28bd972e85ec49485cfcdba717db66e6a343044a2453ceb6403fa0795485f8014225d283da4c3aa6fcbbbdd6b04c30c96fce04579578882a44fe7b781285daa11ee71239c1b69791b8fe45868fe6e85341b7ba4292d6da1ae079875b33d7aa2becb02327a17bf2d09f6a42e9681df41890f17de5cf4752880660a35dab912d10480f20f92589d52ef4780ec28920d11de0de06bf63d61829a3d0894f9a32f911ac79041ef51fbcdf3f5b03f6a0b16f0b9e47444b82efa7c012e3bb9324c8649053433306d0640ae953737336cebe9b854186f9dbfda861fd7eedd76fc24634acb9cb925302d0bfd3751b7b6bab36ebe2ea80cb7c5359a505689ed5642118ce93cd783c80a2cf050f57d5acb62853367ac606fc1b8a01abb7b29e49fdb190e2b586e249639889bcf5ad23161f278086f244d0db0f9ff520e6858b68f5bfa0f5ca700096277ddfbcd14a4cf4358c0f042b1eb34bca6353a1383f5d310176262ba45512ea4f172f321efe971c391fa9e9876a250ab653fd6d5a8b046028018ae043da256b78eb26d86e6e89873476ae24dad26ec1d39da44ffdcd93d8c5c1fe0796bd46dbe9b01be0aeae841662c10ea28cbfbef76f0197cee86dd4c7dae3ba46d5c2884ae977c456681d5d9859d854a3e0708bc35fd8415c22ef4cb889bf0e66da72ebc635b71f5df04db801c76564d2fbd946ac17e27fbf995994ad26c3d577ac86b3b19f855d87bf3f0f7c3fd574b89901732dfacf2e13960975176f7418893b31747d96bd981e9b1463590bd35b51b7a2eacf1a7733f76a7d4b02fa2afc5925f5483f82cb529682f785c21cb951d5678a7d09f99c0e2bd98948b79456e4e0b5d9de80943f1df0c639ab8acd6c99a6297cc5a53a829561a6615c6c44b24a30a75174aac207a35fc429e1a415b0813857ed85ab49db6e523cdf9b122c2442a4fc2b4fc21685c9c4a5de8f36c0b405e34ddee91832cc6567d458ab76b4650020d270a65a562e75e06a3d8f1313b4d1d4d29d597bae9eee653bf8e31b82f9cad2d0848ed5daff73d99472c7e71d2f1be60bca4ee9d315196c096cd8260192597c8ce3cefa9cb6f129dcfbcbd65b5b0e19df5a1e81bdd423a2e26d11ca4f7aee99104530c1c8e3b1150669f16acf415559a38cb27eb6d637c78b1c90ddb5eef14ab9b2ff14ddababd7a349b7f6f5b6caa3a28c45835c9beaf8f836848f579598ae80ff9af739cdd800c5a3d7675c780ad66b2c449824d8ccf55a7669fb720604eeab427a0308122c3039ef9be6df46e34b719aca7a001b884e3f7b1d1579176aa4d365a25b6f3d420190e3cd9babefd8382b6bb12b4c38b981b08b5a139cd46e9382c01f361abdac7fb16b87e2c61f3241191028c770c3e3be939c8825c63bc4e523b389d1ee28189b5a2c11ccbe0aa7d3c2b47443028c89f3d4bc1bcac39eb61d91e75e0d372b9f27c8dc622a86bc0cc0a9c9dafa5e2bc67834a75805f3bf1571fbc5528e4c69f3e64ed27c1f2d93f43215ea0d4213bf2809391b8b9201f36ee2a275dc7c44d0d83de3b82490b65d2b399a7348133c4df7ef40e6dcc114d040f65de00a70cc0c9fe615c6fa90a2fad6dbcb39370af043345ebd9d8af094c831f341fa5f7658c2c1ea062948fef5015696eddd181d87dea49ac8bbcc2c7a1ea01ba1d04239153ca401bdc27aa87093a78b2020109d7cbdd39f279a7d67b14a5822fae28854323a2620033a5fcf9817a0d45eca7e2d120a113fd5ccd9fc0011e89398767f7f6b7d01d5a670b4fcb9c5648991817a62edf43d6964de204541a8b5573d7cc10bacaa1bb835f87d12985ad5fc6ac4834ce76c76e5dc34cc322c4220d9d65ca77051e7c1d4edcfb4595db16c641fa445401c72a24e36567631ea02e4875b7f9ac2ddb4712b79d1468c7ed2384ad5d90ea0825f817e42413de33eb30861ac92e19b1aada118beaddb179399008137f28a8f3df1509ab12d6f6ce7872521f5cfe4738722fdb410b3824f139ccf8ea63817d154b1e497a70e6f55b75e4decb73d10ddb0c57d7e0f74b3f4fb41ee57c2da1e4399c2577f28b7e911db08e877c366f231114cc9553c7f3cda2b75895fb60ce9eef4e0c25d253f689dff5e4f9cdc744c301b6f13e9fa9e30bdba8abc203c05879ff01bf8c3a3aa742ea5fffabbd6d165e50bc412bf5e18c60bbdd4fdb276f3bbfef246cfe36612ad61fcbd4498c18321a1ee12e6dee902c737999f9c6b3919f52125cc77e237a788640f262ab76d5c9db9ceb2d988c261dca63455658293b10842ee0b30cc1f928215e0308cf258ee39ba666b16319d0e21df8b9ed91be2e2feb9e117682cdc9edbc20b0b3b9ddaa93ec7a2d8f752ebaae57b7d74037c5cd64cb04746a38c0ea3ba3241319360e585c257fb593c123a653e6e0420fc540bcc0f072de6ae1a31b57dd5acf0b8607e04d21b727c93623e5227202a7c6432b308f74266dd1e1447a2d637a5259fdcd1d8729f341a7dc383b4c8a6ae0e78c34a55793043d2dddbbca1d161c300a8a7cb760298541c90a1c5a890b5257369b8fea0b4d14dc0848e644953cfd5196494e4c1b422f8e188314f2fa903fe93393193e9b76bb71c0caddba43d8586d72657a2d717e4b2c3a0e8bc33a6f8d89b871244eb04e4ecee26f9b71ae7d5c44f828083b0c1920d37cb5d7db86be3b18ef16653863762939cd1ab5c5e0cd1c495ebd0a3037725470d526bf12d21c2fbf4946ec224619c79906e8c87f0699be8a3621ae718aa232e26e43bf7cace7918ce34577a5e27261a4a6bdbbb8ac21a8a40b0c9682a0e0a37b7fc43306820b0db5fb5bbeed529102187fc3e5019185588d1ca6222a5e2b60faa2a93857bd7224e1e1c3c86128fd16993aaacaa34d8679e194ac0da6bf617144a2b1e844e7f6f8884df05ce1624ef1fe5d0895265bef2de61d637a74f78f6e3402923c9363656b7b91131dfc8f8f7360d14e01a25869f0f15a9355c07bba82e4969f5643519611d99ee9566138e4610712d55f22ad36c7acdc9e32b4e1e9b1ee9bd14ca122db05938840b8f47a5fd25a26072e2055494eb4ba916473e973c1efcef8dd7f0f04711b7e968d59d144fc04b9c6d8f951ab973441a6086ab6ab896f4d282793fb14c74322c7ff1c4c1c6d0544b7457635a6fe2632644344b1fabe12633b2f7d8fcb6e0929a05aeb2749fbc99671283c47c0eabe152fb6215bbc6e03d61b1ae955838a8b7b3bfa883a04f5156982ba433dcb21311fe9027a5b2e133cce16ac15786d2d44b5e4979cf2a8667d2976ea386eef4c85bcebc39b9d2dd216e8b4f7c68b7e0a5d7ff570770a20cc605e66470d995ef96f1e0acf6136716cd8a26b3b725db3ff48364f19cb2c640600d00d0d728d8fdac7b8a205ba8109318eb5519ee03848e79a1c33898555b298aa62d6da66188506638918b46926a99ebfccb649cd6bea1eb87fa6c1999a70937f51c4a2d485c6aa2bb5f98b1c8ae558e82287b9f34ad70954f8dbf3a9736604c43bc3062f8707fe88483b0865bd6df65f7e085593d5046554ee465a10ddb0c0b651e2b1031d56f5130e100e4544809a093026b88277e4e1f1e3aa40997871ced6e6eca44f183ee09ca679e4fb0796af62cec931c553ea788e75fd37ced477f9a58e54410c513fa79a4b5552b049fffd7d261d90a16f253a0782ec75219d1f7492ac2a242fc04c0216e6c804f8fd8f761a70eb747e1545313706136b085fc72dff1714ced89ba14a65a34168dc0e997ea8718ff304a962cbe8c7df8b759d76eb0f18155e49822d21d91dc8913c323a824da271f8c57d44a27be3f04991e2a47e5c8da2f0d71610be89dd4459b9a9f5cd4bb5ebf730a72617613667984d9a0e0ccf81c803e46425899b2fffe9158f9e3d7c36c2c42938d9433f764ed1f6d9c7d69e9ebf854db44c398c00b2612cdf19927de8bf45df70a5d4307e3a628a88a09a79d4e03742f89363d891b241383887b4447d0cf3e0eebe4a9143cd6873abfe2993b1f4d1b3b3a18aae4db4465385500ebef246adf17f1d9196f78749dba2b12deecc5c957e022f5b9dfcc3536bfd306a1a70e50f7bab1db22e98c8705328fedf3686938eccea04e7db4abfbdd939d56c0c357612ee3536356c0f5bbf1d428fb31c7b06a75c5b4fd5b020e6d9894b50eaf1df723131712344888adb5a0b4c07d23f6e853c88b51fcd56beefa721557256bd9978caca155db7f9c325f9564479c39b589431ee7d5da402e79ee6e04061c62c1f369176f6b35174b65a978ae3a4e8a25032d987dbaa5ca048734cc1da5f875f72db399df6e6a300db183e96ade56ecae019c4559c8f7c94899178c98e5071aece48a3e9f5a795159b2dfd0a1aa784b263ae5d352a890b7c2c6887d76f0364e2028d4f9046408e76efd6b5092590d39ec343facb16ccfc0000bfe7bebca2575b1f02c8a0aaaf5fb0bb13ac3246e245ace99f2186160a12792fabc0b390cb4c32f87c46f741c8fc940c4aa7843d650f90d422504bf97dd4825e533f646c6b77c4f004b7036b5480b587a913f05bb8ee470f0ab148727835b1659d8c046fd24276c95d30158424914e75d9b01fe52b34d5f76b2a1c98bc5236945fb46724e02851d46aca237fbf047f3055d6331dccab91c0bc20be2260086552fa7c958840843a3c38acfb24f9dcb506ee3cfc67f3125954d9090c1fcd629d1c3fc557b7d6ab33b9369ebc8b5b43f9e23673f688ffe50e6c3dfb12ac58aac60590991c9ce68502873fbdea04455459f6ee721570a87f87ae03a9f97f6e457ce1447358d8e3453632618701d62885ec4f8dd201e26405499dd7f317a8d2456940348827a08950d548b5c0b24cf494eb76dd0a51e3f5c6fda9f8f6545e3a6d1009775d78720f9b20ddded15c162f226873162a5076bc0cfc151e655e29d100b7a0d32c9c783375d1c6af0f39b51d927442386cc2c26337cbe5f4a34bfbb65b544b50b4947f72d839e6255a95fc859d6f1e34bb63dbfae1469be613472f22cbc703468d8552b9c691c829bdaf0d2e7e4093e940398f9ab8837baad8d9e4c710e4584685df01ea15ed9ed95ba9f6420e5766363e86ab8dfd1626eb1c7d2dba91d360821da99977be4642488972ec61fce7d754dd45a4d7fd9fc3498a6b7e0b7235c7843dfe8980bbd3a52c8868c1832f62d9e25a40986d061d7ca9d8fe29c7f234e3448fa315d749a09cf29556060307b970e5e080e90dcdbec4ecab1a7868cc5bad1037c07e17f961f3cb5641405f3d3c1439596a243f83b4f8576019712320ccc40581bf02a0788e3ad9cf4c44113d47f587e96061c61c06be84f6e35711d105f0c46b31f036356f6abd329c4e1e74f7d97ae6e4e0879be998a85257b6de6277d9c18980208e83d9bf266c9909a26f3e19941e728fe4ab0866d103644fd86b203029271361ea97fa93079ff227861aceb55e68d7454d1dc25aa8a7c780590a04756c840d13dfbde1d52d7df47d4146ed8d530907fcb13f6071e5c18acfd0a694938bca6cb081b7dbef2a646aaf55d4da9f3d42996a90655cb48144a4dd2789d75692530dc02a2635c26d428f2c6b66779bd9facebcd73274ebf333b8de26609bedad5739e73ed68798cf9882ebcb12902bed483bd905b92b3df495e708a0914a96840761da66379d85105f29e14e47a3e5273cc23ef5053077ecc513363379d2e6cb3aed80098589032cab7c20eeaaeb7bdae7e3a1c7a704cda4568138ce1ed94e944eb4ea72120ec91117338d0c86116db36f3807a70bcd98de03cc46ae9dd0c5fd3b26d78fed5a8b53c0c8f9566f921175fd193ec521c9914be68f2864715a572cd6b25948fb8dfbd75f4315967d5a6a707f1ceb81b98972e615d3e81b08ad5ef1838af673af9b6d63dccc226eda6d0b6fc1fd104f62b80662ff157999d7508f625fa2408b6f9ab4deb410ebef73750dca3e63d5045300d9b52845afc42f064bd78ce574ba9b4fce22aa3158bd058772ac2eadbf9fc77bfdf85dc745b529e8baf248a0bc1963f8fad78471116b9ac11679a326e92d87e03e316c90d15d2f9e3921e0bb6ab4b7ce91f12e7cdcd9dd141b8ef160e5db1faa47525a77a038558abd98757ac5f6313afb4f4c84b2c768e456f6de4a78b5b25f90926352fbfe83037f81b31251249fe52860f3cfa7ae1b20c73acb015821840dde2ff2de0470450b11aed7c1f84d4020147f8b9aeed4a37909bbb63508e533f939f23c2f5952ba6734745c51b837b72a398a4eb8dd6b4ee7648ecb55799cee7b6385ecb0b2e36b9518439ba550b257230885b83f72312e53afce7e7670b26342e4eb0a6286c0693c54abceaed1811418a9a289b4b09b65e84b3149cada8114e830c0403884ffb74c515bac074e4a981c61447ac99368dbe9cab8830911ba9cbb64633f444716f401aa17f599174581538918e88cd255765142a49412841deb528f44a64acb372498bd66f979d9189fa0f0e70e305015dcd3c9aea085cb0f1d79a63e92eb39b2dd2fb1b9ee9aec0213f3a4a848f3450e4a6d902f5435e234588ce4a7d2c9dbf60de27227ff02ee4ca19314d72674fb06c00ac7e5d15cd05fb35e973f0974a4718ea9b0d35bb4064a6280b654a15a7188c5d5a5998ba1f031a3baecdf7b608169c0ede84d91c9a5f73b0176e5ab2958169ccc6022e0c43481bb8e6217ddb1bd9ba8e8446aebed6afd163dbb6873d81afcb74b034085afec0d626b02fb10839bdf2279acec3d8f3f7c47fcc3ddc8cf1f08de8c8e120d9c06648acbd1ba6824ff74419776b73b05d797a0bc43d77eb75029112380ff4e87e543863ae29065e40c1b2b1b2d62a409a299ee5868036835627dacf4f9f7c84fd2f6707d823eebca0e8ceb2bd258038b137aaf43e0e937be762be5d3a6545e439a45090d397c8d4a068286836780536ad99cb138cbdc6fe5e9db3bd405ae6eb86084be3a49c8af88682dd52a5fa8f7fdad76cc0b452b3c37b27dc3cf66c57a4ae59a3687950ad3f1fdab3002fb2281365348cfcd9306583eb79a9555e8750dc95260a1b277c566babda92cf2b3ef177854fcc3dbac88da1536eb3c6d6fa3e336ed3a7a6da006901c845619fa00596af8e54bc1980aec4aa97bc98266c248bc038013020fdd128db0b9425e8f7e3165f5b9190fbf2dae5e317485d9d103695cd209d5d247ac7e1122bee4538b5b74790277ecfd2051e43a34b7c5440d1198a1875a0501eb3f519ac2f17553c5e99a9c83412200a519251d4d4ed1c84baecf7d8cfbfe4a7e50d789cc034a21043fc13fc3150314bd7a7801bf9c31aa00b7cbd9d0fa4ef0636504f0dab63316d9b9a1f4703b3be23170549fa3a29ec02f418d687589f77939fe068e41abce460fe118b04fd418f28edba4fe70d8fd24b38078a5c47ea236d73610ea116666a49acec52fbd810bb99af1dc5bfc4eaa634dbf2178151acc453f93567f015f2a25002eebc1f778da195b7e9cf683db1a85da98a99d98614f2c25b2237d4393f5799d06cd36254d3f22a53df5133cb1f43836991d3f7529cd260df88bc47e4172ab045b66e081940dff797b28c632898140425c3f81a60236b82522c0da7f0e0ec7a8ccdc73cee175d3b4543293135c31c0e0c926c7506920cea1d0a1eed64ede7572b8c77ade1d95bce10dfa69fab7fb5ba64055800593465dd4c26717e37a66089f550202a0530157e5274f3d3fdae187444f5ed641c608643eee1b361d78c9ed8070a85150c80368a84b14c9dba5b20a9059f1a05a60de938ab914a093b2e741e891c02f638c73c730e60ef8cb5d9e5031fdaf6918750f192ea7a76e035eb05d7556ad64a77109c5e13bb3ac7627d99165567dfbcfb7fdc7bd847ee7dedd7864353f8fdb7a9939867d9a5ff4d9ec9727fd432d8abb43628519cdb6fa49ce49064a421a89bc924cf6286fdec8bea6b5a7b8eb606f584d44c7194d5424f98576dc4b5ce7dccf65509727ed52f8d7210095252403023473af96eb5892cd3881f2e1f4dedd4c9b0755b70776aedead14e2606bbc1ea3c300984ebf27ca69f36beb03c0fe3c13d9df79791d828d52260103be72b832ba235bf1165250b608e2cbda0c9c8d3c96534802534080b2a4ddd5be4f269f37c4cde9d43dbb42fef8d507cce8b8e2eed799c72a2fb836f4160b5e5729192f088ab8557d51b58940065ceb4b48fec1873cc4b178166d15d441f45625f45af62c1d13863feaa8afc320bb36af0d151165c122a47d4306d075b344974835363818009d86c81e90345cf4b7d81786c40318a371fbedcfc325cf0e853fdfe6e91e99c07dc9430c04e6069b9e2efeed0eccfb161ca85d96298ae6dd67c395b78668d5818f567f2039111a7a0c52a21d84ef72dedbabe83f811184a95976b1a90dba5aca60d0313c546ea97d7b2e40b34ae88ccf4f45e28f05f16732d7a0d62dfd86e40a51de7f2b9b66ed780476cebeca547c8eb71ac20a245b1bf7445e64bce260b8871ead95f708974c3a93dcc4ee979975daa399055108854c1c3fe5a07046d13169c084b2e4e81821ff73d5d20e7556f40fa152226a6da48d5f86cfcf1a5520451c3c1e534db654b1a58adea167ffeea90023cc2b0b01710323177059e1c610154cb234d5ea165dcaebdc2fd9d9b66413b8a6848ea11a673f207ad76bd3ab5399dc0ed58a3ac0ac9d3c53781c36415d54b452a4a78e1eaa7046d062e3105541fec8819439da85ce53aa683aaed543704aa8210b26c1e6c8f1d1814595e3bce2d98a36089bd722110bcefd651937892ffd36dbc34f1284eb32c49a1c134ad460c19e01b3f3f2d40f664d90020ae8c546bba9ccf5500171ad07a55f9fd299d7518f00c0017f6c25d4aa01615fc7eec160ac2cc1ecd38bb0324e54cb466c3df4d56508f5239e1b392a50a8c20946a6db9220088d77c494406296921e3ac9997c34f15fc5c39f2529eb2bf6b41b0415e90cc9d7e8a83256cc59b4607be49eb76a7dc07c1ce3d0512888705c9ea145079085273f2236d5bb151dbe7d1bda2ed607fe51847ba09ea6431dcae727ec1ef0a201b8df9e148885e1308425d5c7fde473e90b4382de8bf5e215c3be357f8a2356348bab00a2b629dee017ecbd76d7ebd45fe4df2884e34ecbb86ea371fca29496fd05327c3b985a069a24a32380ac9e4b131ff48d58b1c528b941dc6290cbb41ab4aad2a55e5e03a63813c2113c0740029529eca008d906dcda1094571f5d2cd31ed79e9bca8e815e206b3ff3a7b4b82b0d30775e0b77260a42b1ccd0a58a91f0378df95cfc7f8dcabcabd2d7ae3b603e9061c1e126d00fde94b4b625e953b6b781da167c71a6a7ce0792e7de070863deaff94d74a7ab9dd2e3d39519a6c5c864036f7bcd4663fecd163d78a72a74d2838b6949eb7ba85dacb2eecbff1af2792047b036f77d488e5256ea16252257bdbdc1ca3d18d01c5de00ae8ce7d1c4cf103b2bd7a31dd52fa92d945da38eb9070d6f11aa9cb8bfaebe133cdd7a72f94f0fa067da0481dcc86e6eabe115cdfd8fe2e2c63c3cb3c0f75a4655eacfd337ddc82f770442d18ef9cf3993a9d1830217f50917153de7576917c533247a6725a0cb7447ebb0cf7516e19781a8ea8d1854349db9d3bc4e4931a1fa4fc075186dfc37ac10db1d3feb6298c1fabc8d897e1c806e38981c3fe7f252371b0e92efc61b2e787279f4a8138e7c6527ffc4092de912378ae692e9941d0b6d14354dd25900912f9a907dd970db649dd965c959e60f4d174ab0aeb7bc016735e8b847e231bdd240042aca16731926f537fe388b6496967b750a94cf514c9296805607b5f44451bc622486ff62e7af5c0d243503ff31d1c753d9fa3adecc8f555445298aa10a877250455c43d412719aade5a202076fdf080589a28cbeace5a63de77d188c1fb486d888528c5142f92e54f005239285cc4f8695c05ed32fddf0b0072bbf7642a1daff7246055cf35e077acb567b78c73094e583b9bac3ccea986305eb4322bcb923b93187bb3061fc00ee0b3d10702d7890c4eaf4e5f3da2143282dea0b12c3f043818914ae3ea98cb1322d73878b5d9920e87e6e00ae831a3b76484e0f69d35eb15b053c545464811f9c381337a80a603ca91ddebab47b72d6c80db4cf0646c579a136326be69bae46cb6ecbe23ae355cf7181981d8f7b8e16b3303aade349f44c005602c34878690d91fb7b4bbbaa75a91528fab18c3c8c1380c0c26a98dae3a2e441527e8c7e7df331a506eeaa2d299757e8b0cbba97a91f64e36e5a24cc83b00fa14b8a41e6fcbafab7eaa905c04c30755c551b2f0f1a24fb422bbd76090e212efa160103344200e83545a119cd7d2f53e8e5e6d89b1c75f12a44ddce7b9e9bb4710e30c853ac8d024be6f5b3d162941e2767c61a7f7ac5265d08a680b87f07bdb4d4e2037b99a6eeabef33b7ca6e7e6f4428f6814e294b7c08783525e1f632fc2a43dc057264bed23898edcc35493222a92dbe28da74c07c49fd725670ded86494fbce9476d3a594f4d96ccc3302a9e861933dcf46d03b7648bbe7bca88d9791b5a62694b34a9ee0d6c9d5600f0758e7e0a2721cadd048bf59d84bcd7ab33a5ffa8c1a237dbdf3481f03e6368b0c1a86ddf01b962520372bbb8e330a70cc684e84e1a438fc571ad9bfd297288135934aa4f1310849bc9c1658006eb1639d4b8ad2f858fdec1d5a4aa89259e591e2cc2948ff126caffa24bf41bf71b408da6b5107e1d65fcf37697d307ef3a3ce742e5d117e7bd4d095dfe8598213e0925bc9c8da414b09fd21451ad8f3531a756f15269614ea1ed728d3d37820c6e90578aa43f8f4cddeb9ce97b345840899a016591690a810c5773572f34b68d1f2f1538dd7c541508c990621d54dc2653bb4a7e9a1c637515538840f836d38333de92ff70997478fa7e4eb0b447ef04a96b2376d3e7319b49f8eb0b9c656bbaeb8a000104f3407e33c23030ee9d5d92a2aa7ff76f419ea3b1c9a8953b30a92759a8d0fd37b50e66c8f664792da1448f8d12d60e169382da435c038f10be62dd1c0430f18eb30af8c14512d3311a28d4252fd4b4dcc04b5da190a22c6eda7ad837e470b9d8ca3254f89a3e613ddc74c1865b5386efc7a8811e95163fc4c2a61b738bab3ce75e9450dfc38a52a59b89746cbb216cafa6faa0236db5b86747e7d9d3b6515bb19aee0a85bd4c2bfd76c1916e04db2e0d0382efd97d2ce79eb9370087b19faf4f269e7fdf64f6c30eabdef01c5a4f347dea6e28c48a55643ca36881ac5b283a9f85a56b203c3076e592779f91d3a00344a29eefcda31e2c66e38c6386367a5b43dfcb3978c891feda33c7907d7e4a501376e1786b9cc2ae1e0a60b9c0c979a0c1c96b9c126f647c3bb21abca0d4498c08a4544fc46ad1a33b17b105db91390689ecdbe0b9e6b5cc1d65a52a51d7d3a714c850c14c9329410c9efdbbd55cbc43e8568b01957d664de2a82c04caaf9e55ae5a34c533bc4da5c2a715409a900c7dbda950463131367613ddb0ae44c73625fc8f293e4002d5b704645c08098ead5a0fde1980d8addf0af0efa1288d569fa62d6b3f6227d1b4d628d1142f5eab4f7f1302bc97809b1b022e5976b32da3537a192938b8716307aac1972cc5b97019f4b7a9e5e650d0569ef4e7d12f8b123b1ff1d95d3d713a18dce009364a07d01b3b62a1f3ffe29130bee4f3b275dd27fd6860423629b181194a10ac44077eb2323e931cfdf64504a94a1e7683110ee8a21e67396d09b85237a51d824966527f9e3681ba9fa6db51e571d7d6a1d04d0f9bbd9d1036316a67ce225705018d1f0a9b9817b0d01dc092beb4e1290a7f12b22cc32697a75e17b9a93ff817a721ed0c696643353b80478a8d41e92b0dde35d7f2918f310e829305711683fc8c2119f0759e4bdca673ec93f4f0837aaab4c925925504fab72f35bc494a4d8bca2b2ee392af02422b2f80f174519fc83a06f99290cc7f1812a32511dc9fce9499947c92cc12c241923e62e98824b85ff3ea4979bd4362f87b7a89204598f51629ba1bc6d42354cb13c093d00c7da85b2523fee61b85573aa7d4a3145d518689ffcae21ff6470a8210cc6302bcce2459244e6f9173e1d9447726942749fb6bb13bd0d3479ac5f1e6d70e104990f2c9311046798f906aa215c002ae0b918af3db1bc591a937d5f485489a132fe9098bb77387906ae54d92d368ded939a069d0866279e0f7cd815062dc25c664c168ae4a11b9f1fedcaff8e3c37b6f7b075e737354074381a135291383a35047b1dcc7cf3b815c1b7ac187a4dcbf64fa5ef83c4fa2c0b4f5b7e024af32ab5d72e4e86a92acf858ff0aaf0fb8fc64fa12d0733c6fc530ad739df51038fceaa88e6e47fd80a357f501dc4ba5de4b6c0c573534a84e5aac913bdfd30e548c8009f06e7281d4b91b968852033af7b9e79b644b1532b9324b9788ab6ed930236c5bb2de248231f3046f490131ac34586b43a3c8e0a73cc756a816c79f3f10f12c23501947b29617fdc2a45c7f361d27966f73b1b3a1f50cb0052dcee33ce739cf2da8fbf9b7e5734c5a7fb8eea9f5a598ec6c207735409ca3401894f634fc787fbae311d4bdc8c99e8986f306883d7185a18e71b5166cb9b84cdaa3cb03231ac3053beb31ff3d87838e53ef698f9921a0ebe69c9b1526ba5940bdf21fd745f6f2653adc2d3c36340a6dd7c9ada045dfee2349e26a62b437e0c8f4fae2c7eb9eb577c20886d8a8fdbd02d245c1a1478f52e339e8ddd71fbc6d2cd1668a44e2c82b311720996b8da7111658a04f4b756d84418ef3e99713cb73d87bb4a14f69d5ef4a8b8cd6d0008164fa0a802c0679b26e155d801b40a2c77453dbdaa5a582d7c9d967e8a5706358c68c6da6c3e6746f0648401f896f1674797b0e14b354c27ea94fb12ad6d8494ecb0eca0eb5795b1920c618b429b4e95979174fd21685ead022e7ca4f87958c8a101b8b3a5e0a9d64393395b12dfdbe7e7503b62db0fa8813c4eaf1ffe5f190de55e83fc3a01b10a647d77cc49b07a258cc4e65d489451f849f6aeea5bde2aedd8e184cb9c778a3676dcf87d2bcbc19647bff28953c5d06fa73b860a16785238f9765c0fa958757b4791272cd8d1fae302b8dc47282b782d5c4c5ae75a9c02a3e911a79547df96d2c2306a2e347e83a8d8a126e6a3a21cc46e476a706af9c42a97b3f8fbcc0de5cdfb59bd6cecba11bbb93ec1bac6422b61277eccecb8b28b3d97f0051b89997c8c22a9f517d9fee5e16606614fda11940cf388c04daa1b302d3b0590a9bd0692d6139b77546d71454054197adf346bb94b4f2e85e502e3cd919bb43e8b424339e2af0e7070b035271783b1d7d48ecb6e63f3597d08a9d0677a44c29948d9cf9570e7fab1ab0d8262bb963d62e895c9bc8ea999f6f8770ed5ebf75a39dc0fe2eff88d75ae19690e0f0d52090f18bbfbe39697042cfb5293692f1e66d76aad38bd919b634ee20000000000000000000000000000000000000000000000000000000000000041187a86f715ea1475c76d354d556242c15f6b8f7c441cd862cc7c89d89a58bca02ac74c422eb01833db93e4b067e507da65080f93cf1815f4cf1dc0d53a2802230100000000000000000000000000000000000000000000000000000000000000","nonce":"0x190ed","to":"0x91a5d806ba73d0aa4bfa9b318126dde60582e92a","transactionIndex":"0x3a","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x1f02737dec59ce5f29b7e11309a33cea7b370eddefa1a8007ed3fadfd1c6b23b","s":"0x106ff6938ec0a46da92e74768b54926633945ab503e2f2dcb69469b544907586","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x2d679b567db6187c0c8323fa982cfb88b74dbcc7","gas":"0x5c90c","gasPrice":"0x7d9f6fbd8","maxFeePerGas":"0xf49895cde","maxPriorityFeePerGas":"0xcfd6ae0","hash":"0x45499074aa521ac4151138f0aad969bcc2dfc1648d22ff8c42e51c74cb77414d","input":"0x003851f8368551cdf133121c7cf32ee5690000000057b378dadc7d07581359f7f74c422f52a4d750946601a4898820282002a14608e24ce8d2412c889246951210c5eea0206041c4025828362c2828a8a860418a28208a224185ef99505d5d85ddfdbfefbb9ffb3cd964ee997b4ff99d73cf2ddc5b063a034cd01e114eddde75618857bf21dae562932ea35bbe70493443b0d3bda8e6161bdf9a2e6e1a1d63845cef77f151ab3e17f6819ec2bc7388893dbbbf49e9f0c76d8f4e3a6d5cb9c46eff41ba97c0b3794c105b1a891908a7812b16b0d1d7780802e8c7621a188764369f6bba1bb0c95c54c4e3ecad237716b875175c0e27d3cb133dee5692910d9eb1ceb4679f65e7247f51ad58b4609f4c41fb91c48acf7b7d2a8532654b741723ce4f70eb38a521e9948c62bb5d73328e2aa5e7174426f5da2a4b1c6ef04eb66b2d4d1a48f0a20cd3d8b6bff8794b3975124f8d8149ff9c0b714da5e23b8ff418940c5dadad787c4298fc8486c94c44d45593bb8dcf6cbea18578904b0c99dd61f2b7653a1562b2cfdc3dc96fb15db01fd11710145c7d6b0957b60eb6fe886a047920fc64a496565e715ce7ac34a51a8fb632f62680c9de88bce189d008e29a23679115012cd789ae2fdf6cf5f4dac0cc4aa2e092b846d3d3b36974cc62244625394645ce73c1eaeec885e6dedb131a1d420a57f945698a9e7c57befcea025554af9a4cf6a432908061828ea86605e8ae7ef301f4c388060625fc5cded2d60f4bcdd4270b2cd05a133fe45e31ff72c0fb8465065d16678ff60a4f2ebf901d2403345bd6c4459c6c6b97bc038b3cbf9f0ffcbd7fe06fca91bff93e504946e2051d05e23e28dcf2d35dd2d1c2b16da8fffcf65ec0b789efb1afec71cf481e5b4476b7df95109b64e2c1950beb3cf3ec9a671ecbebbca59aade6ca79f06328bb06669266f9fe9a6673c50f5aced1aabd49947341ec338b82d9ae31d9fff59a0511ed938e016432f9c5a001a7d5d34b54a7d9a2419456e3bd0eaa860ff52e69806188aec7e559a70415ccb6653c885fa17efcfccdb680026e43c9ad0bd5b379d4da2127d429e74dcb29f3e45b3ead08e1e85c2be6505fac13244c6e528ea261329310d9b80b16bb7b562d9477dd95f6415de5bddec30bbcfab9cb9bbf88e71eb47c16df81087fa93c4b39b5e0e1cbad17cb1bbae73eca0e2c75f73e12e89371e79a4d42babb71e9da013fdf5ff1c20a45ac00a02bf1ee09b0efb1254f4862526e5abc8cafc311bb27abd9af1464ed617acf4c1647dc8765d530e4b40fed95768dcfb24a0782f32fa6cb29e165a5745f2b44a8875a96812b99a095edaf5afb1144335625ebac2a489d9133676bffed7d161671de594b27973fdebe55eef99d65ca83e607ce6ed86d32efc36bcb4bffeb2062a99371c93d2eea8a0f47519e0b40ef21ee8d9de5e8d8da61657072561ab1cf9a4b1d51da9926a2d934cb9be7a548af7a5835758b5164f249ef0f0b53051779089dab29284dc10c24a1ee298ff1faf3aee4072cfd4ca19520b23941a4852bf56dfdf0eb075ff435f87aa51ebedab52cc3ebcb4db9e133e57c2aeb10a836d1f5484807f73a9d411e059283bb45fc028cc8f919abb8ad2b008ff7a95ca576c0c04aa4f243f10d2fcbc425ce014f5fa6793335650b99beb722faab1bae677d9939a02d3de5e0ae5d5906ba024cd019c11f0d51c89e73b8cb3609f7faf3d127f969f3beddda1a756fef93ba1a4d33e4c3992957a9c304394b7760063250a5519ae83b304c00fdf0a21e2acdec12482b724df3ac5ea472c065a9e2b7c8de28454d72ced29d817ebf3126b6928c2cd7cabbf0cee395489744896faea55699fc7ec581ad49b782e1bb83bcf535468b91703bcda0c48fef1e919dbbf30aa45b162c92f0e01496643bab3d9020b8e471695769f04020557e8d0fd5812bf346deaabcc118c92dfa146a1b5fa6aaf5db5e6fd704d073d9c6d549004066b97db487f857716ddbe6cc6332f7ddba3ce2df47f0f25911e833adf8f345677a96c7223a3efc77a3f7a5d24e543525591d1fe4afde76a4a3fa883efb81fb9e324c5727a5d2e7c04013a249366aa8f8242373f9c0aa55a7366d364b0bb89ca1da127046eea1de1d39b917fa53d6acde40da381a71d342e3fdbb19254d7df86704eb979ebcb905762ad78a852bc948b97aba45e99ea4fd7e0340ba70097b4884abc81c20e99276eadce78b6b5f075620424b9a83af6457cf29d9fa52b6df6bb7054711e789cbfdfd1bccf3081ed96225866598328089398b84ac237a46aeb513780c62f5ba256d9de6392fb333debe7b2ebf00571be5b6dfb5298b68c0c4f8a281db7b5a819b91297d29e586e6e78dd685f9810e830dad91e79459de4f2cc484ed9cb3a49eebe9b51975dbedfa1699e3c2fb9cd6a7e9ecde33677fd57e07847bdfb9bef75f07bb9f55f73c695a97ac188df3280a5e92f0a4f1c4adaf8f53bbab4682a9dff482e9cfb43db9dcfcda1a466cbfae58cb09a97d8336c88b124bf1cfff8a603a78299b6e6a9ffec57be9c75d73fa3a86049c56f127d5f3a6645bec138e6f9ee98510eef2dfcaba7f894ce575889ed3c89b3c1caaa37f0901d49f7ef9d46c955095899a76feb44cab15d918d6f9e924e77ef594b9af6e7a2bcbd2190758bcdc73a2cb5f7e25e9afd87f893b653e7d81b294fd6e0bfca1f5565a21f725312a2108c950f275a4c0a698ebabc567bc1d0e7b1d74b027f1dd7187cb584fccf0206d997519a61060628e2255ba437bdffb3cba91b64c87899fb19b5790ebbe92b0d55d2b0eeceed76d6e91aa53c6ae2113e33e299d531c4fe70c696050e654c13387f0f5a9006691089779741473c7c7dacc4503fe93cbf7565bbbc4f715dade96b451a21f1e36920bdd10f42f48946f8ac56ab3afafd84800b2a9fb6d643cb17cde43a619d7ceaa915e6f5d209ce489a8b47bab1eeb9a93792c6dc3b7676dbacfbf3e3cf43e2d68c79522b62530e423f3ac341333908eea556442afd4a7035384916fe5ea257e3af6655cd75ed06f3498afbed542b0ad0491373609b66dc14b70fb96868a8962a2d7ee4d16ceebdbf334a8758b9721bc879a8ff8bf9f2fbcc6f63a9718a35d8b5df1d6a38bf1c6123b43566a079d88b94f3870ea1b9ad8d94d2db14bf12db3ba58dee361949713c756937de91dffcef9fabe2f9714589d51e3a72c7c896ce9b1fde893f5ea895975986ed8766eb7c7598bf7371fdab658e7bad069a9b52f9e9761ae014c4c15c25b1f98e3e0dc1d831cbaddb6f4d3a993f2257d61f345b3cec990f79d3edeb2f5ea94016bc4c4448c8f9815e81b7433017a719d074003d7307e3d627653f5cae3753642527b0a49b76bae643e4f0cb4fe00bc7b71202d6b1ed7329f6ec4ae64ae463ba7cae1375d3ae4b36741ed88e3dbfc48efbabebde8c1eedd487fb8a9f42b66808936bb6692353b37642efd113c62f14a711f42aa00a0947ef974dbf1c9455e3c1ef175af9cbd8bb729f5a7069685775d8ba8fc3552e37e8765680a58eed27db682227eb6f9f12e9378bed42d4292a77ca86c2eb79f2d289b557e5be66535a2f7bef852cfa2dea5d97c52fee7124916123d91d6d6911564a5c2be40110b99de71e9d9a6203de69a6f7b57e54fa4af76b82daad4021a3fdf1ed0cb5f2118646dbd38f2ff5c7a107967eff06986db9e2bb8996f3dd20b7905cb8f091bfa1f9ab52307226009181925c4cf729b64c39add884cc606b5cd0ffd92167e5871ca3b85b0eda19eecd1f3876fb98ea4b0ba1df9cb8b5e5a87dc74399170e34ec1a2b29df609aa1f86f24fac697de3bdd5eec694516c5c59c6160a30d90211319e50ed9384a8c8e316331b2a64f65a2f2f72b3793163870b4fbec75e81af7d4353aed284c926575a821938c34a619bc75358126deef5ca9fe7b0a5e69b6a7c19935505c73df8f2c06ceb3c09fabd79df5e67c5f209579df95d20ad0491ca79df3ae257b8ac3e95aa302f84de6fc847c8cb147bbef136f355a240aebf1d19e1db26bab8ad4c6cc6d6e27c92d0cc8420e0f9e9cd2bab9e9ef2196e07f04997abc6c1054e015c72da67366699fc045c21974f9d6433740a3abc30b8fea46456ddc7c3adf8ff00b85cfd8e8b6ea2ead437ba951d6d5c6c73322d29be2a35e63081d752933b7938c212b1289d2775222261d18633dad1e73e5f323ff2e0ecf36784f52179e6bdc31c5c19616886a139ad0c632e47d0d32d1ba2ac6c0807fae7bd766ec53b94fab2d2ff22a93483fbb6445e72d409a398840f476eb72f1a0ae8143b70fd04676db9411782f83dee540fbe6aa82664c779605bf155030785e13d8f0bbf86951c62ecaa7e25881f491ef1ffec48fc67ecfe2b9247df77673fee6cb0f66f64fb982379d6deb13a79a3f893488596938b1bd7369f9b99832c4c3c23b04cd34cec0dc5236c4105ede9dcad1943c5813cd18525daa70fcbacda879ad6675aa6bdd5174f0b9e9b6c53e67f7771408aabf9fefe79e92c5e8a6638ae8f1e38b621647d0d51aad753ad3b5a5dffd869f18bcb9a8f73c76b452f45c2f8ef6bbc39c9a479bd1c66bb74f6e3f555db06f55a1566364ace5a637cabb4b6b5f422305086e8542d0ebfcdfff1d1e7ac9d2deab374165267cd49df53bcfaecc76a6139337e9fd029079ca503816826e13fb54ca2dd757e147bf8cb7d793ab299cb920dfd306ab4654bb7661cd83814994236d8b50cd984ccb5d210aa54dc73415c96b92d6079d19ad0da60496d2b64f3d687b8cb154565602ec004b311f96d330f172d255bc6f0c550afe9acd9927abfc7bf67c37ca527edf3f61625f6dd9d32ffe64cd0b10cc433411bc558b67cf11bc09f8f4d7f44bcdf6395fde7ea9f70c80cd66aed764d8dd0ce88679b5caed8fc9c2ee8e32d2ef5a8ed9efd1e418feb40aacf7f19f16c9a1b35357f8bf8049ea7fb91c7ba47d670ec211f547ddfac75bc552f487263f859af5dea16f91baf2104b6dac8af88eefba672312ee7fb9f96886ca51ead0fda9213f8aafb5bc4a7840f65a01cc004a510ee5ad1dcfb0fb650b747acbfff26a26f568544c0d24186f8ee4b169615fdec32de53b6d3f2813ba5b7076edaff3224797d524bba359d90f417140cb222acc5ea65d83c0e7bab279f4bd8b9f44e0e7c907865bb83d3ededf3f539ee85c3420f10ebfb0725fd91f3cd2f3cb28d9ea9911fe136e6acee0bb05a7f18bcd4b5caa9784b19f63dc0c47623730f54eb3f52b2610e9cac31bf560d29def6b778e3a6512fec915eff7cb1c18981292bc892893d581a311046dd9c132b6eb9fe354075e0caece17f573454c035ec85e973988dedccbb7041ce2801733da9f782c8d85491ddce93a943b1b647b41d02902ccebdc3c82b7901adb91cbad9d18b7915866a1d9098e1c43de52e70477048d02ab565547ad68c33c7138d30fb165f1e5e76a837bd74a4af58fbcf4e34203d0a1b56be539f2ddeb3706d3f25e663ed919a97ff8abe62a76be6bc6fa6e61aaf2c8ec01768c7eadc9bee7ceae30c31dcba975d6b558ea932e22a71a5c728d2dce05067b1d4a27dcfe0438fefcca5cb4a95efe83e63a7dc247570449dbed353e7efbad6ad8c981a2b47de139ff5bab370c969e154b9e4f07f813a9310a9c021f52b22829622dba52fc47814892fca57ded9158663b293356decac92b391c56d7ab26702767e30b9726aa51bb16b79ead28fb4e00b815b66ed75006e443a9e41bb5ead6975bd3f8326cbb4de758e7907ef62dfdbaddcb7b1fd85b3785ab27cc0128d4a8f0306ce3c92cfe0f708ffdb335bf69c55348e88597f711e5d35efb6e05bfb9d266f107bf8497e8ef403b791e1c3f23d6f83f7c7f2c7bdc63776dd4f3ab24178e30daebb616cec37cecfc9756e2809a6d131c648f88c6eaae019a9c3579c6287d7681f8b5a24bedd607ed629eae12f9e2bdf55ca28a01ebfa2b20cf30460621e22b49241d178f5884481f3cb5e062f2b5a1f90e4a66da24bcd9328d9501e5f7369ef94ab5cc9c42494d60edc51fa6d5ff843a8fd5d5ff89743ad44ca92594df4fd090a213696a51aa7c3845fb4d89b7c8ce12a9e57ea61d3651b8868e7d8af070f78ec48dfba75613df791126e81aefbbeed1911f5ee74eca37da5f0c478e8d9d4c6433984cb8ffef678888c982b7fdbd36c736ccbc9c74f65d3b6659d3f23ea63f6614974a4d62507951089c22d885256b29d96a7f196cdde15515ef5b95bed572ef4bd1b712467c7bd67f96b1674378d8f87a07fe35443630157d419d038c7fbb0486d5ff6dc908db1319271d24b7d8ec8b0cd7fa16d812828368871866b96fbd5fbc63f5db2e85991c937e1e7fe1dd93972d9013b5e56e69661f40026461bc9fde8a9a46f19da2be783f9f07695579e22609fe4b6252ef1ddbc0bbbbf687d9e316570db32c1563487f09b5e0ef117862d5301762222e99860629271f05b8d38d06658ead0e686113b9aa67ba89cb26bdd3e8fa4d64244cb955fef548f69f9c5059c0de748799e245be3b9cac822e2927319db667124ee46639bc3b462dbd6ba6f375e94842e4e5dfde5d409975afdb02d03b52c27f33f98f745c0d9ca2d2d3405f2babb8231fb446e87f1f97b776e3e7a862db3fc7a05512b633f75ab70bd7244aefa306fe9c5975202ef0d360dc8b725b06b961c6257d02b4d1c8867d3a1817257a7c80adf3e15ac7108cfcca555bde972db3b1bcf38bb19b35839f0fad1166f936c23877501f220ff81b93c06ad91f798214b63bbfc9e9cb6af0f41548c3772da35590ca55d22b6decc5d1d7b3149fb5e71e09a40fcd997da77eed62a8d84d9aee853c68fcbdd79b210ce34a9ac25093a57572d557d47cfeeac5beaf9eaa9e0bc29c3065f59c6190a303903918dd88b9b4c7624db2ee1b48de9cd4d0ca875095650d5c8b5d903717d33bc5b1635e52a1d989c72e3d397e29367db456ffe6afa124496a6f331d5243f40dd192b1a2e230badcf97acb3130f5e2af588fda4bac803875788d425867687a67dfbbb7da5fefd9443c7b565b79d3dd9e669e76d59a797b3ed7a1e3a580b98da60adba5c7c71d0acfd5bde9ab5ccb69fefbf6915976653797ef913ed65260a5c6286eb11e962d9358e3bfa3c8fef1526293c72e4bbba4522a7e07a5f6da6012775d5b1d487283eb5ff89e5b024e4b918e98ca203a0eac6bb26a5be64bb478ba936f1b410c298db9260f6969ef4023125bdbc7db8b725cf7e4b69e0c0bb1733f3a4ce5f6b2eb374713fbfd4f488c5d1be324c038689a943154e1568a3dca5823234ce6c5c26ed2da769d0b1a78bdb4fa9a71d59a2af1241315f462ec378dd24472efc8d17937fe3e4bf89a2987f3201db5ebf41726d27cf6c26b167556dfbbd0c00589c8fc1827fab8ddf45f95f76efec6f8d3ffcb2bc9754f9ebf26c935f967f74e5fe0d7f18c35eb6fe9b112b9767b418c56d9ef750f7725ad45de079a5d42b2569d5857cbdba2f426619e57273da74b5cf5af951e76b3dfc6843519c8e6ed6dc7b8290fdb0b1f7efeae73a579a7cb26abf03c7e7e8bdce598e578a5a6f1dd57f77ec99edba37793aef1fee973cb8ae75cee284055e15d62e19178d3707522ae7e3ee9ae5d00e9d4d82d21e79578288e3068737f317a7c865c4ce6f38eedfa4502deb116b7735b897b77f8d41b7cdb7fd07973e715eb9995a40986da462fa51b9e682506f2559526a6bffbe8b6f6ebcbe97568679806162eeb1602d386302d65aadbb374419f9dd1e08dcad0467c5f3e96934cdf94fc11a04ff3158473a8a7e3db77f79c292f017ed42a28ab2ff7d58f7ae65fcba3cb1ee97e5ef3feafe1ad6a4dfcd1061fa5d171d2f21debb4a99b5ec48d57adee17b492faac44efb1bed06b538a30302078e9e17bbb15b25d3ba8a4e9255b1ebb3905ab17ccebefd6591d9feea87e3660fe17e57bf9f60cf0992dab3aacb619b0902162a967eaa4709aa8b0c65aef4bbb2a56fe2695b51f950ea8b5544e6fc4d5d81b96fdccbd55df29cbae1ac667efbf62b51c39c6b2ac9c839cf8f85c7869fe8162a5f6a3925e16cea1e6cba00bffb4863d8c73c355ead66692428b3a88f939c136818237f256159881265b37aadff156ec96f73aaa3b7f8783f2bed00065a914715bb57d12b5f65a5ddda5ea31c67d9b9e6d2aab2c0a425ba857c471fd552097a343a660972b6d4cefe7e3671d5d34d5da54312451d414f00d3944635dad335e7f56b00b30ab4c3751ac81adfd8c33e950db63ff44c85b901983717a35575561570ef166c747d3abfb8a112440aeed6cc8f575a3d285f3a6c1c163bf745b4d79172d13da49263bb2415b00f520d118b3767240e1dd82f7666b352989c7a6fc8e7dde6c5ee6bcfd79e9ea9bf4ba342865886f90c30317d88903d4fc501a706f9b7070c15ef543ed850963cab079ef72e75090761717efdca575316d58589c9fdf9424ac0cf070ef2cc885b83e49f0c1c82e91a1a00b3ac246599bcc4db1ebdbbd70d956efd071652cc5e2d14f79a0f78614f7fb472185af9cabfd138b7705b9f9bf6725e29faa5804f8838a6e5f5ca00385808eb2ab34363ab50b2f2f9f39233eddd4e463d18d6352ada86a61dfeffc4424a22b2986f9791436fd96cc3ed2bdaa399b32dfad71bdd1e36cedf2f6996f6c2b6ebab2bb2ea4bf11b2295f77d0bdd9e91295cdd23ea548e8b8839e7dfec6bb74976a68232ca8be3b478f1bf6ce7868db922b5bad6f87ab1e162b27256ed71560a54aa622cdc91785046ee2dbbb4c8f220a9334b8aa9d6bbf73fe724f69fc8a0bec2236e0d39769befbf3128e88811c39d55dfccdefed9a8fdcdaac78c8df18882b467cff80e2ce569edc0fad9247625883cf6577f16f08d9efc2ce1f8c3976b73e789773f6c32b6d1baeded08ee286e68f046148b66e61ea93da5735c56a5c956b076d067db079b76bce5add735a078b5db7ce3328c04c0c488205ee15f6f3b81b559f9bc83df308fb6b974bce453e894adb0df2061d8b3c3cf62ef9491bf8a095e1fcfaab174aede7b64f4e32c0d84737f9d559b16bb8b3acccf662b81b5a01d5f8da95ea91483152a4c93feb61db3f5d2aa8791009f43820bce2c1076edf0d56a31311c6c40b4bd9bd65764de5cf8e886805e3c6d64d22ef09f9d03fd5df9ffeca41dc983f7d403e190d873607781e2d756177c31b750dea08658fba0dd215e28a501096dfbe83e5b51e068a650ebbca797ea4508fd1a570e3cc5bfa6d46fce6e35580e9581150013bc8004a93d12b222cd5dfffaa8ecc66fa9694daf5e333b4ceb24d584bd67573d34f50c9e3234dc9860d0785084ff75b32920b2539af3f26d5363e70b94bbc71615c564d61d5df3527885b8dae59373333db7ecad439655a79c12b0c39c0f552cbafd6ef742e2e682ea274bcd9a5a7a7de6de1f7a1ec5561a341040e5e75ec0da406ab741f458c3a11bf714f23f730c19ca32d78af3c52b6d79a2600b698e2c0ac8dc7548b658bc4bc3f975bf2ebfdb916e214be74fcdd8c60737bbd2e5bf68de1e444c28562b70515cc9bbce2cbf911b7ac2aa18a20b1dbbe556bb8e6788921c34285766b410601ae9221fe28ffb48169cac5e277cef909925dbec8f8e3b6fa884553a865f085fd7f9992b75ca1674672eea28d37f8f61ea77b3a6f29e4f9aca9bfde138995ca6cf80c89089830e59940400420408207f23e221137b32640242260e64084b718070600caca5ff4b6d531cfee25b1408cba09000202d9d4102b86a5c887832c4c67a923dfe048f2701c05512009492009007c2494338191722090085277d675b400280c724006c1c7b08f19000a003ad85d7cc85e8c9fee92540028001d6834cd63b2f27dee7d7752142c002069e81fe1fe2860086130306011e065bc4f04ffe8931f014940a25a138517e4a83911463d07efe36469ce18cfff95b627ff23866db0bce7d8e62ae2233cdefc8d7e57ca04b5ac564291e7e72f2d5198990002fc20bc8c41eb5413a9671188f6749213c2acecf2ba4fefc319604601c0990897d0cd7954dc8afcd07b1812400b3824102f84c5c88a3ad7f2392008c2f04d06824006b3ba662328481002ad589046036a326e023b91033f0780ac3194f860032fde7ccfc8986507431589f108063550b8ed6f527cafb331dc4347f703821dd7263afffe522bfaffa29477768e4bdf7bc9a2da6fac9cde693d2e97734c8c49e0460e7b1582e1c97f13009c0ae181531604c4454eb2400eb43633d0e8570d224802f4a7cb40c3ffa4102b0092c0a367f1605bff608c59fb148fb5333615b0924007b974a02d88227908c7d4602d8ee4dfc66f3fa2b1060332190003675daf775b319fea16e4fd6a7fd1fc948dff144fc4e7ab6bb103b04d0febabd4900db65b4c14f130db22f1eb701ab893e888304b0759000f69b3f23421542fe5b3c3831f0e90c96939100763b12c05e3f5637034f2601ec3e7408004900fbfbb1c782a22480fd2a810a0120854186408a1348a63a93d3f1780864601910e000e12000ad9b918efe8777a64220489d1ae9886a2100c2388d7a3c0960ef82b8480087f908c6f4c54799639592a96427061e4b0238b80910c0c093008e252e440a04d2d0e72480439605f7db2e448a134590047068114800872609e0e770211227387062e089a36aa0400038a1148afde8d7185bcbcd61bfeec71d205388cd015286806f5323571c274725a6b231f01048152393008e06021443154bc713211c559082caf70665bc93047024bb1089e3dca1b17b54867196211c244f03d9c67f53a9d20c7c46faa862b9681812c0e91433fc9b7f5412c0298a828d138aa38d7cdf81274bd2c5b6e3c9716274f10c3c1ebf3d63d45c14c6248ec6e1c479820470e69100ce6c3a09e0dcc8aa8ccafadc881af00f6f9000ce9b6843c9acaf2f49006723cac31917229dee440238155d885467fc68830c16d10009e0ec44bf71b153e8681be5a3be49a450509872cd2590002e0508402bea71214220054451c1c53b12e22079aa104a168d922da790008e5e566df6685dec2e440a08e1625915c1040a038f166d22015ca1b123c534904a02b878d0bac6704ba5ca4ce89a0470654380241de2c290002e8a0b51924c134bc74f2ebf88864fae5417623a9e0a613054f1b1b74900d7232a09e0707021fa8e9984c262b60f65f60309e058ed4244c986d19e88e302fa0a371f951a4b02b8b44660c0c043f2342108a48890006e730204d0454900f77c02351eb46749c3bd281695a0d08518e78c2701dcc7509548d2c54800b753dc883620804865e9927b2b819e08da539d21900aa6e3215c2c98898770230ae526b810e3682cb2032c3212c0bd07924f14a38e484773c6132110c22460c004d486a8ba581a9b929b084d72130a04ca8c43874c4dc7d31868d5b1a86a784c09e4383696967824092480478204709f7621a2e562e8433502998a49c713c9140cca35cfc25812c0dde242cc444560a2ffcf1c43349504f0b813209674bcf35d881412c013381a6258bf47d4ca134b8030ac2f0cb4c1eb28c6d2f1a334d0309dc54b2e5a9433ca0b0dc2f0a4e3e92ce0f154a025e5a325a36fe1211c4d100617d004c5205bba20c44b171413172501bc00814ae561e06923020ea2af32475f1d799304f00ad0e974082401dcefd09c8481a7d047f4c1ab462001bcaaa3e414547ee2b8f742c354b1496ecb8ba78eb8683acad16a1a09e0d5436b2301bcc9bf0d1ba81bf2ac40dd7b02e5bcd9932b2ca48dfcc8c053a91812c05b4e192ba452d9e82234517112c0db88b2fb684c31635551a90e108e0a8ed51db3ccc14c5bd31017e41fbc0eb72e04b7cecf1b17e51d1e8283bdbcc2bd23220008a0820ea34cf0a942f2a828cf47d8e0d3a592005e14e0ac0ac74327fa8342c142000d7420017ca8ddf92427452b12c01732491abee849d2800c3c996557be2c0209e0db39cafe9843f3e58f4a4a75c04f6a8d04f05d439ba39300befd2ec409b5f1354e6ea86d5243589447b4217e006d68f8bb86a6e452dae32e05ab5b934900ff32085808017d4363832818101c1b43b1e909c2a00d010274a1173264cf5084aa250403570864cf5dd2ca754230103dfa5504c62204b2670ee1f22311185b47207b16b0efbb2002b30104b2e7e3c7c9ad22309b2681ecd94cea361681d92002d9f3c3b757db4460360601066d5c8823958bc0583602d9330c2f714404c6ea10c89e9b6a7c192230d69840f64cc9bd4d1481b16e04b2e78ec6bda62230762381ec992514e6260263778e55b310bfdd5e08064509235f45600c1f81ec695225202902638c0864cfa53b03fd4460cc2a02d9d3b6e5ce561118b38e40f6741fee7c2602637208644f58dbf998088c6918ab91e3db33ac080c3a10c89edc1e79a74560309440f69410e36f168141546aa5d270f46b3981eca965d4e62b02833d04224b8330e806b31d6725dc30e89bce80a59ac6b3ef3e220c26416c643d2c0564c0606c3a0396dee74284d98d47e9b3d0279fbfa3cf87d9e1d1d2b3e90c5846e1bbd2c689daead15223b4b68051fab61f6beb87d9f78c9462b028fdb1c9a598d9e3b56114c6793b3c4abfe087da302e13f4f6e3f44f5c880011c6844f9405a12d5d47cb7a47ca5227ca12c7dee3601b6d67ef0f5262ca27e8cbd219b0ec4e947edd28fded1ff9ea99a0ef4c67c072722e44986b548b982f3fd48f951ba7c74a8ed3378ed063357ea43782b9712c49b0ab26de741c93845b67a48c04733b8dd61182d6eaf65d1d64987beb6869ca0f28c11e807904476a393fd1c2d9313df2288dbe59fd236f6f26e8dbc638e219e3e3f30fba62931aa767131da7bf3d42cfa6f223fd8a09fa65e3f43da3f4841ff8618b9aa08f44b510e94284794347e9e37fa43f3a419f3b660bdecfa82e2008c2929d60b60b0c58ae151d98cb83108e9cce8641873626f60c0a6b0e27239d41618d76a8286dc728ad28ccae432043f282303b3701060132cd890d4373488770603accaee342a482e9e3e303063a7c70604020c8807020992604b38b13a80c2c242f4605d347b299b11109cc6e05f32f43bb0c98dd85121b0bf3db8c6605e339f8f8e0860cb3af1f27a6c55263610131d42b52636363618143a3ef4d74d4c213ef158ebf578b36c25e199bc8d222cc7e2b9d01cb9bbb10ffd830ccde020b4ba0ffefa25261e19d233930cc01c2ec5f589551e1995dac71276b4c0973d8d3d1f16dc25f1f5bc2a26568ef958ea7c01c7e0498c33396e54430c75a172299884a35a61298232696e59074215198a36aea933630472903967f3369ca06adec4e5c1c0b820c3cccf1383e8e256c8c59ba65ef85ebd45b9c07963f6cb9dc5bf5aa14f7fe507a917f63827a45f2fb94c7f13f17c953e915dfb605898971494990897dbce7c82ccc0be991e63917efdc91b93d239d01e308683281b241c3522020deedbd285914e674272c8600b2f162b4af45610299d82f86e42521792a284605d1de168f429b938c56d1e9421481392ba7213e6709035648f85e7cce5bb058214b78ce96044d7a22ccd93c0609145e10401521c35cb204fc9f4da6fcc9d493085114e63222c05cfa09b404984b7bac521435309703fab13c217ef4a77d0295ce82301102514befc8c48f0dde34a73585230273ed274000cc750fad3697d5f9fd360d85b9ead219b0423e3ac81f1f2dfc23f32430b7ea8817716b43002c76da85887e5f4e85b94d584e441b71616e3c75d49df0539e86455d1b82d8c84e3077cad4231a77d97844e3e1188968dc4f7f88683c1cbf8b68dc9d3f8d68308fc488bc3c38587cd3a4f0c0b3800e714cf2701e2b02cc63ce320fcc633de6e063ba8779d68c062cf4d5206a1c2b58a1a319415198a7781a88e72960c08ab693100ff35450e3e2e8d8d1783739ac90619e87637192e7156572501d23d19cd65ca508cceb310d5e799d19b0e2f9c9bcf2fad168b078ede401120442c0df9a34fe7ba81eed1c788759669e6648c0c27cc1d3d0079f3703565a39591f7c1b282c274259e08ba5d16830bff6f4679061be5a02cc77990a8b3f42ebb9054ba8a3fddfdce9cf17c3fc9204989f8f365213bfc8684d73d00fc5b1a71a230d4d9e0dfee3bce1825f2e58fca91cfc17a7a14dfed30c58e9d977b17f9ac2ced0984673331419b072e8a4e6c8287263ff0e72ff06ec7fb144f227da8d4926be6c7bdbb58578cf2e6ce916397a5f3356a4f273b19a1c11c773a3fa4ad92c1a9a810a707f9f811e1e352f2ca048a78f06addf763f141158601f8182c63681d469a8582096012b374df60f81bd743a7d34b611c73ad069824a50681a2c087231e059c17f075482e4e934b78101cf06264b2cb80d8d0212c6a3fd4cecdf0a6e2c13084d477e212e063c3b631243acd92072dcdf442a049063ffa185c13f513cfd2fae0bd251d40b0dff01f5b0b0309d4e87256c5d4651070be3583de9cf5b81858d5963db3feb358533a76102e16d0c78f6d02413fc85303e937d3a0d7e65c02a6b278370a610048ca2706cb9179ea9349af0fe4b167be1990d7f34eaccd72362d98ee5a5d3d4aa08711a5a157160c02a5f276b55c4970a01937c9bfef77d5ba47b3a1cb53260d5d41f7c3bf6effaf60840b0a3b69c667c9e9a838a227fb4a5e8191a048c7be898468560d1e1696844b49f01ab0e4eb69118272ce138320e17b39a464d62260c58cde7fb81a8181c1b0b01202ce1c548678c0c9c59393f048064d48058586c2b0102c819f80c3c1e16cb4353733a0482548a13451016db4980c576c06a71dfafd4b2888919f80cc6d84ae0ff2fbb5c60f158880b96941df99ec6b203031f43d67cbd88ad71f33b47cb19b3676bfb3cbce51367988f5f7b2b6496ebbda4ecdbbe14141fe295dfe3239b9c8e1fc94047f37b0995bfb959019650a48d4cdf482e18c9d7258c200e58427f64c8873e449f59a1bd375f94cb77b9312cb106e282f9f527d6ed59ebf35858228ab5a6064b8ab39ed2d1a70c3c914c15148525eea2c37e89dd341a2cc99acea0c31247e269b064034a0b3a0989c212a504723a1e96b8c15adb8525ae8d4768221e968865cd7508914561897e029e064bf4c641602c2cf176746a60bc2611a2282c294480402a2cc9355a880e23596c51d06f63cb32209ae57f17b947e4935c3c6a2d322cb9928e625eb2df8528280a4b16fc9fef94a0d22560c98a7406acd6ea42a4d2c560c99a51354c8c31c9340870a08ed481aabb9b024b2d4547ee1314233b296029be118b482d9ed847014bc98d6a85e59852f309b0d4bc1f1c73d2168a1fb74ffcb078070144d6d85f2a8e40a682f6143ae830b29a0c4b05a0a5743ae83096efb2e6cb68e0c422252c554885a556ba1061a9524a2c2c4570216ec7c3523728b1102e0e84a5fcd0927b14582ac38548ff6eeaf5bb053e58aa9f4287a50e7fa7a96f631f3f758a492ba5b0f4022a2ccd35be38084b9b516069551722450496b61d5d3d632941978187a5210a2c6d38b1be47197f6b130596f619798bfec35b3b29b074e8c45b64c884168b151685a54f1360e962586ac885c862a52a961a07c2d2f62ce0423858fafec883f811238f454b8aa8e878bbef29b074d31f572361193ed662242cfd7aac5558467a84c33f52ea8d50ca084fe60f80207a1ccaa18c330196711ae750c6338e1a3fc2e176168732ebc61fa02c9bc032b1230fc659c667fc61751a96c9a5c032693f725239cac9be094e201c95ce62a38900cb3c9d60e30d9d1a3bd1c8d8f4b3cc109565bab18664675060993e96516425ff6814590d0a2ccb3e49e86fdf7fd020793a280ccbba106059675856cb8548a4ea32f093f771c0b2110458361c96d543d9c2d1c0743c0d02a9181a8896a51160d9545876910b71a29f238f28971c97804a255b4c80654f8d4b255b99404d0461591917e20e967265efb11ea0cacd642957b665e441fc88faa13850f73b7ee4b004580e034b635d8844584e60a43a13d43419787cc60e7cc60ec6f6eff42aa74380e5168c7320b77444aff693f40acb398d38c41fcc251732622e39eb9f005b2e9900cb6d9ba877cf1f802d776cfcc104b0ffce6e2b58eeebf79bad607901022c3f03963b3bbed36adadb5460793b2acb67d2f1b0bc1b8df575d21601583e9c00cb87c1f2a213cbf6accd0ccb03e1083f1bffe075863838282432781dce7ba3a7b7b757042e88b5992106dec82259190207ff9c11dcd8960758be01d2a0b16223cac4732a2cbf114d0ffe74bb038cc35260f9ea499b1dfe10b2a9149a3e3a7e6005665613383d5a2c8ce361455f9c192d960ee3a45d88306e256d34f432262d5e212ce3e302d1c61259c687719b50ec278cfe88834c68603c2b9ec0b8ed104403e3583f5006c92c068f50e871304e1d65316b271e3fbea2301e4c71d72930ee34cb6f71f726fbad3ddaf42b0a8cbbf46388c00d1360dcd038e414f85950c6354c82f20fd6f10f5e0f07fa7be1c2bdd7458607e3d68f5a2730f2977f363ac93a0ae190f2b87514b6506105b15f5b47219b022b784fb20eac707a1c630ae513181bdd1d022b3c24c00a0f7ec49821cecbdb33dc1b8ef0f6c2c18181211be0604f6f1cc93b3064c38814ac4d34539342d1009a352e85a219155668fab5148abe145851635c8a1ff4ba213c24d817b72e24c03b78d4b126daca81a427da3a498515837fb97d0756aca7c08a59136dd96d08864981de86b860ef0db8900dc1dee138ff8849bb8646a41fdd3b3415e995f4a0d9e31c29995261c527bf965ec99b022ba9fd417a431c1c1a1a1eb2de1be7131e12f4dd2ea6118e7ecdcff71cdd98842aa57a2aac14f81b8e3e5360a50b7fcad10fbbaa4638fa353fdf71a4ec06298e73a4ec4d8595867ecd9172220556b6f98123ffe088481f1f7f4f7fefe07513b0fd1e21cad721d989b6ee516165c6af11a2fc89022b97fdd0d6ba703838c2c73bfc07838c22e437069924fdac5593fc6396271556fefa6be967c553e059d67fced11f0d32c2d16f00f21d476f20a5098e3e51e159a9bfe668b624059ed5fce71cfda19f228d45c251f3fc9ea3d9d193bc68763c159e8dfb0d47c728f0ec909ff8b5271c1838e2d4c121eb587a6279f92484cc7e0de126daeaa3c2b38b7f8d1015710a3cfbe90fd24f61cb21ace204c98fb7a5b2860aabc8fda62d1a0556b1f8a12d12dac1fc101ac2bd23467d1198b22faab4430a131cbda7c22a49bfd6b4aa28055679fc738efe6877d4e2231c797a4f9923d58d93a2832a8d0aabcafc86a33c0aac1af0078e1c83e1d008bf10b45bf642adaf3939319b68ab15129b68eb1d15562dfcb53dd4665260d5477fda567048b0f746ff88756840f2f7fabe2d35fca448a446a4c26a52bf692b8602ab994db435bd4d9c5322179e9c9faabd1bcf1dd406c77307589d8700ab73c36a68ea4b45536456e23074c8cb3fd4276295a2300e42f2d627d33db73d2e215cb5582376872c7f78913f55a7ecc1de0bdb63dae58dbc2242023dcd002e6160412588987173ae8e5b27cf4f7aff45cd789beb623d3257a7d987e01bc744a564495bf45e22b622f60c4299f92c7e0176a0831accecffa49c527fab463d9dbd2e79fd368b79a54903090ba6f507d4f92ffd8e10198bcd14acf8bb6b396a37973eeab665fd31772387554c5dc6d1a3cd9ab752acde3d37601a2d8f84c0a57bf5380469a7af9f7b89c86fc9b58b0c192ccd59a7286c622ab7e6a09ebfcfc0f21b9b3e5992c29f71debfffdd611b7a13876d0ce800cb5f8a85c3ecda17e7473a29cbf408a595fcc70edbf8e7fe1e58eac4ce7beca97babdd2d73308addc04600589c8f0531d8ffd2611ba00cb2cbfe17f73d61b4b51de4257e51ae175e5774fc57e509aa949cdf1d8651a12f5e5f107db9d63d717763b87540f7056e97eaaaa13967a8d8769d756bdf3d9a79c6edee968c37a0cb9d3da27b9f6f5d5935bb5c2e7287cef5eaab83fb08363586bfab3f7cf0525012670ea652ccac4c26c6e5f055bb3b4c25ef973b1c3f53da9e2b0e58b27d7c224917afbe5690beb725cbefe09b6371a79c5e2846dcd8c6df41db79ffb169258898da3baa42ebdf0db917bb9a2cd5d077a0dfbba64e0cc3c844b7d8749d9fbf401859b196193df322d703cd96c48f85ae9d4b86b6bd791a95b369e9c0fb28a28b69ef9cf18301664deb608016bf37d71e0c959c557940e6cbb1a57cec4ade78b41244f25579b61edf6a6a6d76d63ca67d97294dbb708de30701fed8f564eb87678ad6442378d2936376699f3a9c382fec4c63ef70680783b006da4dd7f56e78e75ccc9c1758869d0f30b11ac871f35bd1999e87be191938dfd876f0b0ddd015419fd398c7b6a53efa56f77a4ee54ef96f873d9898e632cc130c13f370e4fca7ebe38703dcfdaf9f96f30ffe41ffcf4ecbc162c1bfd5c8df3b2da7c7eacbaf4fcbd1bff1ebd3706c9ffdb2fcd37a95df3958aae660c1e0aefb222e9d22e1bc5ca5ef177a540cd51faeec332c5ed1a85ea4f676ddba35fa37d9573ad7dc32ed345ac00ff770d739c8e4ea7fb4b8bdcf791934f0bb536731361eaffb234b29abd5df955fac2ab7b19c2556cfec5bbde106ffb621e058506ca45b489b4468bbef57be4367ed45d7dc3e15f56691f5a5f26d5767ae38793c31d3c2b4928c34dfe792edf7bf8bdd30e0ec5c34681054a83127ce17283930c7d007ab0e3db6463c664458e262a5afc7a45775d83bab757a2bef29e5fe68a69751abd84d0aff5c58862d0198d8d3c8e6dc35a56a2e72e27d43ecef9bb21796f6e2b4df735679c5ec55727cf075c0559d46c7982043f47bdb0566a489bd0aeb28a433fcae75303addac5c5f5fa06e5ede8cf3800ea11e0331b1ded33a8d1fa3504c6afed92132afd72203576cf6166c8adb6e9555bc252167be5bee7fe0f449a4f7d529f2d5f52fc436ef375ab75144e4e31ed1f6595107d3a2f2b744b57aec588688cdea71e0b0376ad0d0400849cb63edcaeba859e40b8f3e712be8b31f5f593d84e61d6ba79577545569633092dafa1b485b07773c3b9375b1b6559d9577845ea687b5c52a8add5ffef9eaf28550650455dd97f3a2a293b9ddd6d32f228ea722162dad9f940645b784ec5b70b92aa6bee240f74a64a1dda2f925bc1ffbb615fae4a2bc38fd3307da2cdc838481d78d8fcfbcbe92a9738570d113b83958cdd79122eab161d7994b455d089758583c367ad68b8e60da9b3de96e4a292b6bed77776e5ab0203aea2e9735b56de4a493a07ff6a4939f9d76ffaf38e9e4f5420d2d4d0d3fe7757250c93262c9cc5ebb0e19cf83afcf6a9c2fb6555bc15b82cc8a765d1cc57d4c0c4aea945dcea66c3953f5aa6258fd76a7ba0f518dc9ca6fa44bdb8181570865c52b2b719a4707e7cc674dd6d0d04be81c59dbfd5ecff1add6dafe8d36f724a7ecb7a4819de3b70d89fe95db86847a8af42ec6eddcd8eba9a2fffec54cd307a4b3d44a32d27da963f95a5b5dbfd21d5bd45e7da9d9472d7e5ec2bdc6cf4eb5b7bf490d799b84444bf2ae6e911e6a6a150a65cb977bef5505e1d2e6ca5f176e1754d1bcfbaa5db20c0c0298a03f32074e19ea482ef7d66953ace9d20a95d54830da146fabd5b3b6e1907069c9bc5d5396d48b094aa37ea1332dbf98c7b620a0b741aa7afdfd0a7f7cbbfb7d0fcc8037cb907b4e5e153a6a6cccd979e919d648759e5d9ba79a68c3870637e9baab6edcf96b3d9195cbe1abc78fe6c404d1d6cd33ad2c49a6ea362ff1c25dde7cb630fa9c5ec5ae67e339941cc6671a3994a7b4e422f752874c152e1fb354dd7a4422ffa34b2588cc30d4de56539ab1ccd43f4c90a344a9caa65fb238cfef4a71824c5d453bcf85b588f7cb8556a722dc9a3738489ceff802710eac0fb9be769ffe605a20efcaf5378343c7cedf7fa6e45780177eb2e3b367e58ea36def7431f9e7f6de9f41b821db53798693ff55f994f5ed3372fe7ef0f4cecefd0b47184ded50e8778a09af45ab62be7eb469616fdd71fe1b368590cad96452edfce66c5d9155d02b448291cd6598947f50b2e8f40bd2dba3f2dec75f0ead259e6aef693b659bc85e2d5986f10398182fa4467df656d292f543b948c846ae27ecadbd315629214e86e6af2d16087d583b77c99415e4c7c4888d7799a47fe181cd5e87cb35f15bd6ee7549da2c58a7d3fd7a79a397ff12eca73cb677973fec7a3b7f0db24cc3a2648656a80e589692641f722c090857e9ae52b5caacc5462eeb4dfa701375c78069b96368efe226e1c30098574ec2ee513bdbeb3cb72e9065def5073fa4be316e13c3c9ab0b7743cf5b6eecdc2d6c17b0d7f0915982baf909291bc4daeccab7f3f7522d021ecbb7765db43856a27b8fa47162a3e1a0c2a607e75a375d437971fe278e7d4f42b6fb9a78bec6da1b13b92e1eca6a2b709dcbe3a12f351454b72ed0d96c438af23564eb7d8900dd3df5ab0b6fb53d176e219c5eea6061aebcd0202e99c3cb4af1a4b16b19580d30c12bc88288e604bdeb98ddbe0c53c34b47d722c7ceaeb76d5eddb31c6f9cfea1dfb0e9f094a1b69609468e1f74a638f5dbcf4044e75afdfc17caedf39d06dbefcc34715ff1e933fd5c5535ad375641e3c23db1b52b9079e5865c8992c72ed5e50ce95ec67646a5ddae7d548995bcf45c0eebadfc98c4f393a4d0e84f118e3be9faf6ddcf102e52ced3f5764df2fa067eb5a75ea70d050ec4b477fd070ed12ae7a9bfbc5baa90c3345a79cb97e75a6c0fb27dd964aa579df6d8bb82e2f1a6e332a2a0f526a93455c131c93e40f644fe0937578ef50f4c254b1845a09ce02645ede2324c1dc0c4d4200ae6f194bd6da4ab7b376e5978a2f9ce85c08e6df8a84fabbdf44ccf2f9bcd85659fb225039998ad932e5ec44ce568ca1fd3ab85fb7456e70b06cf5a73f2746a90bfc99502d703772797fb24f069e57f4e00927b56fa155c9e9b207d6ca7fcff7a7a554946ba3ccf168928dce79fed5473a262d623e387af7dc959331e241d7fa57241d4d12d1309ad192c22c9ac320895f556313b223fac82975948d4bb676c6da3aa39cbe64b77e94eccc076d6881f8c9d04d729274306af0ac3bbaf34d6b45bfbbf56583f2f7b11ee8d6b258854b4be6e93c2a8a5ad585825b7babe46a46e5f6a99ca7d99e836c32f9a335e7a1d46562721da1b2e447f34dbd8e5989ccc56646af1f90ec5a64cbc546aa5c7eb3e9d323438e9fe33f9fc7611e2666ffd4b5bd602f319cb3b0f54b938575f1d006f495eeef572b0c699462292eeda2dce6baf9223d66df4b1d551106bc052eb5fea751dbeec7974b6a8d4375c19c80d304176c4eee8c74b995eaf8cd87949d9333d9e35f2eb29343d152268390d2f7971cb392568ca900e1e282d3d871938cd3aa5edc5c4296dd41281ccaa334ea52503fd77025cad78760824efcb55996f4d2e35e7f6c83bfdf7ee5b901faa04912b56add25970f83771c7900a3e678dad2762ec782282535b12cf5ca075de6ddb8f2c7c69fa7c26b8cbcd8862eb47ad3db78729b142988bb24266c7ed93359a9a3be78c5c8dc5f886e4add54c8f28ba5fde7c83cc10ebf03a1b156b5a74fc134fb631b7ed9a8d53d644e8c8d5582153396d3d09a940c0b0dcab5c3565267616774379fc12be84bbc794a40fc52ff4632e75333744a264670708cef5dc1b710d7ce32e8898a87eda8a0935ae6f280998c9c7b3cf6e43198727c0e45883449f6a0ba3056cdbc5bdec80b5ca5efdc282aa24fbfd166b0e3ce8ed64323992be4c99ff702687d0c8d5584ad3bf1a4bbd63bd5de5e75abb1ec9b977973614fb952fb6f4ff5de2fb5f8e4953b91a2b09094e91cc2e7838ff3c69d12b45be450bef6725c5455fdff1a5e2ababa8515f4e6323027a3f2c189c3b3baea14b48dafa74bb732678413c94db499023e2d3303975b7c3a4782ff1d72edafddd70f9d509bb66effe0e1b6d46da716ebdec6d94fb73fbffe7e33d88dc5493dc4f69e278efee965e5ab85b7ed329bbaf72314733535f6dfd6492fb4d6a0962dfa4372be41ac7c90277c255c53d350d408ac05320a7a37cf9ed5514c69e24e7c9eb3302d594bb5450eebfbe3e03fcdfaecfb003580cf8df99dec5e8453ff53cffabf27e05c6c35f94ebcbd4a925fcaa7ce3f69d06bf9b7e6513b85560bdd93a49353fb7494a6b1746e831c702c6a1d876e5b79ebcf147b419d7ec367bdc3e367859be6fb82af7f88e142eb9ec7589273adf9e2899afc53b58dcf1bbfa030d1c33d7c6f5a53b1fef3b3d3f4a78759d74dd9138de77b7cbf69bd9b8ef8879be38f49b6ce2f2b673164a12fc396a9f5235e44b186f6f37a8d56749e429bffb86af242309183933cb8a8b579d95e7151f78d86efe5e9ae78d85c8c5855497bbe5f03ead14c45cafa7e3a094a3fac1baccd5c7fa25edec1b3514cfcd5deee4c8b1fac2d20bcc54345f709956bef0b3cb9858f9c2be8470bb752598cb745a97ca9bed6fc181f4e5fbeeb93fbdd61c124d5d3927a41b5987e195589496714d78bd2397dda645ba552be9a488c88d38f5e379490afead1bcb30960013638ed4a79a75dc8aaa5829b541b9981ebf6c16ce3de4f66ccd859a42ca6e09a6ab3a64a6dccbac6382fde3a30acf298c2afed7c6cdc203d073e52fc9c5d1856d2ee485c7300a96aaafcb94d9b59243ea3b691e852b10310db7974d7bb34befaddd3fd79c229e6b2caccf99da7a2685bd2d64cecc1689443449089c5a9270a66ecfb7c5f854bad8fe1747973ed7fe665ceff9f298a3fab0ed5200c833492222726aaf13173ce1cee60c3e7275c9f6e72909bb0a4ef03759f4dc4c9ef3e6957786260a25bd694169454f0bffaefd5b949ff1efdb9c9d78b007a4b8e6b278c9feb0dd25e735247a63f91ea5f543c6516f37bff5bba5e4aa77f6cbeed715aa05414884220e5ed34bd3166b65cf6b1c50bfba982bb167dfeb3aa3eb360749f74e0af18edcd3736cf62646c62ee5d4cf2b7d9f9d3dd69037df85bfe2f53d05db7a24660dfcd09e7bca405a5f598639013031054834cd27d840ed65fbdce1ed29efe35d1d0d56b7a99b15dcb50c5d56e4561b95866640a688dc96eb7d31a6550a671cbf3dded3e16f5d737ffd16d17bfb9f25ee2bb2ebecd61d42abdcc8c41047ee54cc9db8539154b7fa1c3692ca79d0dba495d3337d0e8d0cdbfde14ec5e06a7e0f4697d190b05ca3f991ba47ad75067dbc2bb3de9e2bee7a2cde607d4216d9087f783317df7621578087cbcaf7a3586cf2d5c44f43c71d92e62a3b50931edd1cbfac80f2723c83f6a21e2afd79069db37467a0df6f80ca5f494616dfdede5c6953f16260752e9c45dfb55d2f89246bafba738ea543f91d2b73ec5b8467f683c7cdedbdd9db3747cd122d19d4513821c9ceddbb555066f3f58c82f9dbe78e4cfe87feb393ff06c5a11c65cd7389d5d66a7b8efbbc78710b8a14f8174cfe27222efc7e74bd1c98f3884467b638e3ce7be9aa1bb3bb8fad70b5a9ef2a983b33e50e22d51dea5bd5faad78de90fdc10e47a719853cf88557f248ee811ee73755bdecd319c3abfc5094a9652370b1b3dcf26c9c86f2de70430f8941051d67cea297596215379029e3350ac56bedc01de5e95fdff7bb7cfd2fced426223c5a417509f4dd15e77862ce6f0bb7a19d3da3607cd46367c8b2afd64bcc86eb3088de270a5620ffcc1981270f36e987e55fc8bbaa3ba810b7dc2a391ff6f2341fe41bef1c38a6d039fce93ae47fe5ca7932b2abd8f4e3f2968bd8bdc2724eab07f92f55fb9bd8149dacb64c322a3bc07ee6f900e26ad07265de1b33eea017b73825ece4dd42031b938e852df93420baa433509bc2bae38df0cfdc0ace5d5630fc499bf0799ec0f5708dfefdfb1f2cf55e57ed946c3fe3b2b269eee134552462561897338effa6dd1dac6b67e497b28fcccd356e4edf743bc55e208df3a51ccb40358009ce426abeacf7f6da35436c2567a30562fb44f8c4968ff3961cfaec9fad7ef6cdaaf076dc94f11a3dd058fa1033508f5a5770c2ba34506470aab81568ad891f72af987f39e07dc232832e8bb3477bfff60a43258844c62f4d6abc7041c820aa7ca8eb90fa4afb55a5060d73bcdfa67d01f1d22e895710f0a29dc40185561ba6733bc375f70c77cf3031d0d19cdedd7970e155c62ac7e1328e4b0093a30c79f2cc033b57c2ed6693ca296fa5a153cd3b8779a343797085bea4797d6050d8d929eb6a2b9323a0740366601daa2cb649aee0c09509983d9c117fad99eb46a096920e277bb673a08564bc28fe7353deacf9e44a32725ddba6fb2ae35dc2e2bcdb7ef657ec8f3a398b8a6fe67f6a305ce0ba93c195aa83ac53e4d7319e19b4ff63b8b017f6a60878bc2d7adecd4d34e6a9259564770c1e9cdeb46f74806ffdcf7cb029d5bbb653c2966d9f907d52407ae867cce13cb5ffc0b4ef5a3ac1cb77bd096753e04b524b4ccc815877aafbd61acf79f35e95cc8d18e0a120562619f47ba927b5aec327331478b81047932fcb2ccc17d9cab8ba8349ea7d8746ba3dfde9757bbf9be0f8d7deee71108b7de8ca57bb7585af469878f02da924cbb59cef3d4eee8cae3f24d430d3b5105996bf5de9442155f6e88b9365874f78e428a5ea55dd52b418548dbd1e71ace034f2dd364afdff91abf8feb93bcb7e76151f0788fd6fde59f69babf6def7d5fcb2fc833ef9d7bbb4dc7ebb8d727d3a533d66cbad63f39958639f2417d0698f032757575fcf5cfe85daa0af87d5708874bf6af5fb85079b7702b33c81dc5df197575665c7a8777677e3ee76b697fdaefe2dd9a9fee147bc1fdb575d7ec031d83ab4dcec6ca67db4fb01f3fd29ef2e8671399a9d5b32e38b2e8f884bcaeb9033253afeebe6846d4ffb76ffc5b194d3fbd3a50edfaa242338eb1505f72fc845db87e6ceadd83428bff2c88b6a695fafba9d05ed73f63c73388e2cad5f926960659fcb5917a0dfdafe285fd3ffc2a60fc9ee9a51f5a47cfd4739acf5f1b0ff89f5f144c4fb66d5dc01e5edade5f107dc43afcef9585ddd1961f36ace66a354f7878577536621a6974e35d816ac12d3098e1172ea911c7cb2d0acbea06cc6bae7372ecd3ea854d930b62e40caefaad6ac99d958f5b44d2023bed3e77c9fdf4deca768e323891fbe896337c64fb9ff224f5e176899b42e70f9c49fad0b6caaf165fcbd750180ad928cc80cf9c6e49c28b1e08ebc40e2eeb06d9ba9e4cca315356397a68e0cd675ab6907429891a8bab7f2c693e39ed677452b39795c783dddb08015724f29bba38efd464019d80430c146a48922e81e6cb6c87c83e860ca37bf4a27d3d6fe84fc790ff82b4fcc3159c6afdb39655d509960d27897eaf52fdc2b90adb9fdd0fcab0642f34fbfb8850815f7f21f0d292c3911f7a2e2ddbbc4c3e6f50a888bf63259cd0daf766f363f6a6d2dbe897670556fbacb894afdc646e2a0fc81072bd0b476d5b4d2da19ab92755615a4cec899b3b5fff63e0b8b38efaca52ca8575eccd6f45ba9480adb36c41f6bf964edaefe07ca225b0a45407089369d90ba03c1cb9eb23750ad5ff385d1631e98356740acf123d476fbc5b1c3590ada816ef53565986a8089b982043d894ba3088b75787ceedb967931f623b69caf77c155f8ead2e2fa6f8331b93e343a6629d2c8f398a1608d8d9f4dcf95a05012771cdd9fae4eaca7debeecb9f1fd92ea6721a879e94c4c64e9da01bfa0a94deab464608ded756266dee0caaef6edd735d0e1bdadae6063717be1e6ce050673027510d7fba73bb35d796c1a1fb1edb86bb0cb6837653342eb2f6fdf2390d6ac7ff97c0b1a780ca61778fec2f2cbd436e6a463d85f3ee7f0ac9634b8eee738ef86eac6971a430ca399da2d8e0e3912d9bb1d1005a3c53378b7b5f4377f7d12ca7f29e78a28a088b49e594c8d7b7420b7e52e44fc8b9bd17fba918a8cdc483ebc45c3ed3e59cba0d372e92a8147a106d5ff8fbb2f0f8772fdff9f194b832c85ecbb644b96905d681864295bb652b66c59b33396c328644bb678b2644d945d458821eb945df63142488591e57739ae3aaeeb774e679cbabed7399f3fe6afe79ae79ee7fdbaeff7fd7abddfaf7b1edb92ea14987071ea8c13ae760180e9cf04d615f5e48c0a3067222b9f4ca90b43032ccea3a43229571218527b78ab0ad7f3834958c44220f1fa091f2bb4b48e940f16848f4bf1f8620fdb67b3741620aa54e842cc98ffbf68b83f4edafd8018b26d41a01fbeca16b49b1d7f0f9ea4a1631fc813a937f452dd50577479dbfd963af4b542ed2903e1e09b6c6cf6db192f7866318e11ee628c2cd242cd55a415259f02081a0cee86df389283f93c5a5f0d7e00c281ef0357aa9a7a79247fb3f4411fbfc62da7abc87e72e87ee1b08b4c71f475610ea9462fbc6772180eacbdc77e5d7f6dd127cd3296529da988786d8cddbe6e96355d3d5a8ee83f51f4813d4d3b19e4dfc12c3daeb04eaec59eb8f462c2502e3d54e6c5a171a608394934a0bb22466f94d63d3c21debdc46370ddd1b53c37a0a1d4c88ac67ae3c5333462ea9b8896b97ddd223c4a9d4885c572b455285347e24a610d04b97089c99b533a10e03a873746c87d229afc9f89e81cba0c354191ae561356034037a1c489f0158ee8a745340200483ce9df7d9e8d70a0975883d1896fb55dafd259179b9e164c8c8c2f51862e03015e386fc679e32a7e7a018ff366ba48e262c226cdb6279467259342656d8873aa0950201c411330d299e5c01c1948155071a66004c910529d9849d95a363f9f365a77cc93f1550bdeb1ba8523b8f9070b99dac7423c607fc542b20d1bfa7f928510d58381cd6d53472f92b02cc97b56fdac19132a67fb8802e8275e87c355830b9b97d20d00e7e177b1728d2c27aac86cdee4918c8a0c9cf88dc67c715bfeb9879931f3e680c477c717fb411c5f66fef90bc2be304b87a3f04469d326d457b832f3631ff7c4582b8af6345de9c3802d9629c9fbf69015268922da35314f48e32dee9a5a68054ea9e5c28ed74ee79bbde5ef74b0e5ff6735a8835cffd72eff73e9758e85627e60a38e47e6120068788061eb6bb68de493538bde6225ae163e8047a05aea293e73519d2c860c2d6627484a8cf02bb25cb12ed5f418dd50d466cf2e2fb884dffbf75db4b95ae0561d9b74e57e18817cf2aefefeb238df9796c9d95a22797728ef14008209cc3223e7b33448df67642642ad385643903e51cdfab7c6a2cb863facca2ced922ca95fd1ec89006ab7ce9a57f4083569b3483c1ab8e63c56a71d04e39924b359ba669de2aae82c049c99469b64caf1e6b0adf2ea4d9aea1a4a170482c71539513d172291aba76dc9bf19922ff149130a278dbfbdcae75458de51c4a6203c9bf3ec8edf45736b939449d68b77f05eca917b8664b77f89e0f2dd843f2be5bfe06c37c7e7ce78b96d16c2888ab62d9b599468adaf465cba7611a0b32d6a7d4333c14b61de3f4bae014f78c0fde471ad8e3553db75f1f6ae681fdf6a702508077e0a7c66ab3c6278ab9e694518ed77e62502ab8a3dff86d324c4aef890476a8013cb32de018ac681adbee70ce87ea7096deb8f7346ec5dbeb77c0fb411911e9b44921462d96172c7da939a26af8a97192bc7982b9002fc5c370280c63e54fdb272c686ba0c99f0b62f5557367965c6fc8add35bb39d5efc3921c64d813204862166c896880e1716ca776bcff25f233a41b30bdcec80c8735c3931e35c071770b2abea98240b9a6a5b3b9d3d44ccfe966faf22548b424c2cb4f18762106bf0f4bba7f1bfcbb618bcc54f886de7d585c199b34fde2fdc4c68432457c0b56db58f1406447a3776a01e099106d21338488beb83c04cdc9b09c8531323fd112de6e17218321aba5da73f6fa981730f10d9a5c823e6313ae62759d5802d94e63b567b95eec225b57278582b57b434221cac0430da8a12fb0aaa8d889b1c716f82087d64eb2357f00053e788a0a826b938077718ba9af26a205e1888e00d051651e8139d4e455adcd12d9707ab3a31fc37cb050aa4eec6d18a7fc64e704deb78cc31136ee39b9380eeee4820f59d322636a7dd80eb378cc45b7a8587d2c8bfb97e7727c9c5c1180958e7bf66cb31c2832e6d92cbfeaea369350f6adcad2ce8bd0abf4592b95c061c0e76e3dc1722d98da4d869da7c7ef5629249566f45509ddeb410d21a7873529b0ef12deea3f28e1e7c3328349b0a7d30cb8238094cab4b35fdb481f893ce41145850919e25eeec40146812ad8d5ca693deda352a6aa794b5845a273b70b02edea4a2451fc3b67b00adf7bd4c4fb17b9701c9e5b8d3285fa8ad767f10ba9348773e41f50a73a8c0586d6230048340a639faec54a7a41354b76e3ed8c95c38c1b8d48a94b058dc290d8a5f348e0ba2c751b91b9c5c504e355c932f123d471500f849d183cd167ca4909d3ae706f8faf181f8caffc5971e17fe2805ad70295920b5a9d425263838bf70b46a9222cf7a61b51086dc6b593f6b3cd9c01c0b9eca50f4e2f9008b113cf6a74387448aa3f4ddea17f55e43a1c48434bdf777b6e9743481f8843008b1c9e9a4bfc3c748b5276ab41819fbb1eb64ffcfe5b8815cd1d578f267de0b5e7bdefeb694a003240bdb8f7e2ec08474d90eb95c4866ec08d596bc9d3a8fa7a029d92896c9d7205ec29347fdd9dd9939f81ede3ac2f895b350403c2412600cda3cfdba0415c57a268f97f0b94c3c42852703a600a8e0b1a093ced92e38f4bc73b2f26e020f17fc881e9fd72a0feafe480944ebcee4fca01e27a04c0c860ddfe7051bc7eb0a83d91c8d1adfb9dbff1e711afb420916c1a448168c857801663ebfd6640cdc2103ea137b53c3569c3d8290f49f778c7ee956ae23e9a77631718f70301036f1614747850728b2ccea69d31f7da90f2e649ffdf136172a4653f307ef37c7698048c667d1ab130a2d038e55cac055e5b966c0dafdc02f469b55cf2c4ce0979255defb21f7fcff3fe4d09ad01a8aae6e3c7cb3e8dbe92647b6beec6afd508d7aea6b5f9b5e80c8b8ebfb6a63a9fe19060533bfd9f58736ede03e59943dae5d4f5d2023b3bc4645f3ed569aa070c905a0f16d6c2f3357b01d618cae20eb22a3d78cfcc391345c93bc5341cd657f559adf99220d8b4e3d43e7b87425fe7cfa62fa0c12ca9156b8d0d98dbba63693e6942433225f4b7e23af4d2d9d3f09ee589fb0e851edbb7537d68feb9544df8825c8d58c2ea5d17eda9b7646f1972b912b4cd593d3daea4aa7fdd24171850060ec9717871e4d731a13fccd527f61535e6de66121077b25639db5434df9998eff74d13e47d72e531876f6bd159b2f913930ce6c1d5cd4b37d846a2ac6db891924a157d783f69d29e2630399826f8bbe4ff8f354109f9715213553d6355818a76497b47c63838ea5e780bf7a6acc0c8734c54f23d002a6496d48b75f832a1b166c472c2c331f30282ea665e66607afb910ee913fd65d5e065100ebc00385e3ff17c6653d5cf74b22d92fb26e1dbbbc76e64a8c06adadd027da92ba3ce7ae31da0141c38bdaa6bbd83f3e006a1bfa381ffb862acafb37151882a3a81d95db79a7fddf8dafb23d0f317ae425978529fd75241474e0214c14484665d32d0fec3332dd45c0587f3a1b26fc3535a9e5a3b5f6c77e10dc3ed42ee7c30c8ff0167c50f72494ff10537e788dcc75f4d89233b121ed0849324f42550e4197af1850a4a43f50038abce58ab3fdb97c36ed30123e501299fe6ebf2da57641bbd9b1dcb03099937aa4640eb830076c52e4344d96b9ef96ca6fb43274ce1cc74e33944eb0aa26068f0ac8b0f78136fc0d3d62377370a995f711432027846dafea4b6d8993d0379a682c943a9dee6f4c6a7fc49ced512f9ee8af75ccd148029733fcb51d39b14e82ee9b595c9de3ef74bf22a8e3708300c15fde8cd858d8fd584c6201ca10110620cb2dca07add2e1f089bf05473c54595d984131f2a80c8b71abffaf8b05b10efe74bc71142abc12238b050f0a189507b385a3a048c284ad097a4a0acbd6c12553ce855c37cc8189e5e7aa80a51d5e442079bfc1b18d97f6e1a9cf0ffe1657be0dd8fee6d91e55afe37e353fd0e04efac02fac9a94f4cad36da0659fcb6342bcbeed3324c371202b87a775843f50601db165de5649f4be414dc2f83bb798ffb7c8589bce20c73c435062f7e94af3b1ff42d6693ff86983dfa51675f8f6cfa87dff7b26608c02b66a237a8a21763730fbff1e4a07edfbdb3c16b9dea0a3fe7ce503094af258745da0090e5de0f61f54a56ada14cc96aaf06ecd59d079f9e66582c6e49ba37a8da1f4ef12d6653ff869845fc44cc88f9d93aedf088d92de0b4d2cc1d27ff88cc42bb64abecb0e8471e8f6a47f3087afafb7b1727ad32cd8d01f2d3495b1990cd378b4c02a26cbe16616acf95b86256a52763c96322ac75dce7aaecd66d39f02b77a22c6d0d3e838dbcb70dd36a1ea7c913a4385c6e34cb4737151de14bbcdb3bce02088ff0760d8b2d7bc35081bf853b16d7570ed2081ec58683bfa87d40bdd09775ac06278270e0388081bbbf3f5ee87295478fb88524da5eacd4e77e0955ef619a90d202c8d5c2bc28bc930b8003abfc210f30fbe4c1a3eebf92078a2f29197e4e1e10c8d58381a3626e23fdf14f1b261402da750767331a1ca2065f691dc73c5f3575ce545d4b02fc4ba7e706f5dc8695dcdedd0e7abff205414f5e1d298c72af3c26d2d1969fa2b29bf54d7f4dd6b7dbda2229b430599e9b12324445e545da2077348bdb569c4607e60760845acf00a7c6f1ecac116edeb5e2c910dfd4fb7e1b8ae9141a3b40d9329ad3cace2dbea01a920ec24152006e228e37d26766c7b91b5649635d7bc8a4d0f3062b264ca03b75cf08bb86efa3f106261307d1acfa0a595fc7f3ef89c2da7a6450cb7f527b29c7b632ddf7a0f71098e4f017687ee03607e585fc1f38125d241db744eeba6ee4396707dae590296a84d2d05b8e7ff22b1c4b22ce0eb39e05a4128e1bfa7e323d9673a572baa660bdfdf69965cbd8da159c981cff9df93922fa3dc1e5f26b05d711544c4b22cdc9e5b98756aa8c6a6b0dbea16941ff09c18584d2c4c66c57d20adc2aa917bcf4785bef50de2663c5cd2b0647e62bec3e138b02a61770236d5dce412e8564e853a3913df3dd102343bb1ad2b759d85287906d996a88300807110444eb4a9315a2e73e37f1075bf0713812703ebd328188437629b950da747e09c59f6767e3c0a37b18711e0c23cfd703fd3e335d12ddf7270e45d06b680a299e92fe1f28444500c69e4ed69878761ca577100512bed36e3630e59ddcab5eb53c245d2ef59cf82a20b3186f7a51aa8035f9f5b2b5a6522f6b475627ef73a9741706e15e969b719a6cdf7d215c07f285fcd9a4af070329c746938d422f67de7022d37f8498459f4f149ef50f71f92097c6547526895b1670999a96e9e36fe315d1379379894db6569ead7eb460763b52fa6d992fc2ef02e65b1bdf656c504bf6b4088f1ccb3c0a162b2bb465cc390cdd316fb821ee21b34c0fa1c27bca3cdcd7c667d85f51c5bf8dff0f26073e5ef870c7e0ba37b9a74ec9bd93e047493b472a050130456e64d4c360e34b77e55d8d000d4a61ddbe8b3af09a00356dea2f26d1e68a3c5fa508c68aeee4a189178edaebffbf000000ffff1ed9a0d101","nonce":"0x128cd","to":"0x8453100000000000000000000000000000000000","transactionIndex":"0x3b","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x41535904d7b20be8d733e03d95ec725d0c6ee4307d899cd00e0ca0de91533b13","s":"0x3f98c81207d078199bf74a600a77cfa389574646d63ff55ccfd194491faf7226","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xd3343d473f624c02045a01f4e7ab604bc56c4f42","gas":"0x156c0","gasPrice":"0x7d9f6fbd8","maxFeePerGas":"0xf49895cde","maxPriorityFeePerGas":"0xcfd6ae0","hash":"0x00b5b05c6d1a2eb8abe2c383da600516515e383fc8a29953bb6e6d167e9705b2","input":"0x9aaab64814636b3e36ce9c4227a5fb53273a04c3fdc94c8a00a4d6d5b6521571b94ec7ac00000000000000000000000000000000000000000000000000000000000028a416eb20a9e75d33ef7eeb4a0bad7413cea6c0b3a7f6ea249a93a428c0c36b52240000000000000000000000000000000000000000000000000000000000840244","nonce":"0x6c7","to":"0x1a8b038f5dff48f541e8cc658b9e186b9828a726","transactionIndex":"0x3c","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xfcd40d6ec6fa94f40f866c18457c22ebf5d8e3aaf2616c4c1cee5245ce8f042c","s":"0x45e5962efdda48e38f706cf8fb7c2f722d80da6e0a1d2589b6627627b44feb82","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x9aba7eeb134fa94dfe735205dda6ac6447d76f9b","gas":"0x3e64f","gasPrice":"0x7d9f6fbd8","maxFeePerGas":"0xf49895cde","maxPriorityFeePerGas":"0xcfd6ae0","hash":"0x6fc411f24c7b4b8d821b45de32b9edc5ac998d1ac748a98abe8e983c6f39fc19","input":"0x2e260ac30000000000000000000000000000000000000000000000000000000000000200a5c46e2dd70854a0fe8167b705eb7df71cc927469c345248c81b21a5ab2f5f19000000000000000000000000000000000000000000000000000000000000051d000000000000000000000000000000000000000000000000000000000000051e000000000000000000000000000000000000000000000000000000000084024700000000000000000000000000000000000000000000000000000001b3fd9f800000000000000000000000007ebc0d2451003f2d3bc5f6eafbb7e6bad81e250d0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000640fdea40000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002e43c000000000000000000000000000000000000000000000000000000000002e7d600000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000f6cb686532a3ece4a20f823e59cc386e1ba384d8504e902c932fa1497c4afdfb0b000000000008008402470000051e00000000000000082ffe82e7b18f0778493c989ecae1740325207ea29328999d5ae646723a4bb75a1305c8ca593670972f535ff8afda050351549ed800e9b98c805788acfe20e6ac076ae024efa64ac3ceb8f0a3cc9ce93d122f6faf8376c854da95567fb7576f762299ca2135608c7ac5a824257b50043526903fc8e01ad88006448a69a4afda4c01ad8a6ed1260582538f2311e902c1e7d5853a75b74482117f2cf920897c1b9428eaeb7e74a95d3d32db03931d157a48aaca9748bfebfecffc2d140caddc66b300000000000000000000","nonce":"0x108af","to":"0x7ebc0d2451003f2d3bc5f6eafbb7e6bad81e250d","transactionIndex":"0x3d","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x1b284cf86146fa2094c7c709cf9fcb8a177f4fde1d1c5ca112e41f82a5e973d2","s":"0x5618261c40d23e5beb7ac0bac77b16ead56e547f103f649462387c5acdf18ba5","yParity":"0x0"}],"transactionsRoot":"0x709b85056e1bc5d3ba99dff25f42906bf99d8cd57201621ded11072fad4db62e","uncles":[]} diff --git a/op-service/sources/testdata/data/blocks/pre-shanghai-bad-transactions-hash_metadata.json b/op-service/sources/testdata/data/blocks/pre-shanghai-bad-transactions-hash_metadata.json new file mode 100644 index 0000000000000..c4008f7f082cd --- /dev/null +++ b/op-service/sources/testdata/data/blocks/pre-shanghai-bad-transactions-hash_metadata.json @@ -0,0 +1 @@ +{"name":"pre-shanghai-bad-transactions-hash","fail":true, "reason":"failed to verify block hash"} diff --git a/op-service/sources/testdata/data/blocks/pre-shanghai-bad-transactions_data.json b/op-service/sources/testdata/data/blocks/pre-shanghai-bad-transactions_data.json new file mode 100644 index 0000000000000..eeb34e1709102 --- /dev/null +++ b/op-service/sources/testdata/data/blocks/pre-shanghai-bad-transactions_data.json @@ -0,0 +1 @@ +{"baseFeePerGas":"0x7ccf990f8","difficulty":"0x0","extraData":"0xd883010b02846765746888676f312e32302e31856c696e7578","gasLimit":"0x1c9c380","gasUsed":"0xa79638","hash":"0x11f97ccd0591e9746603e95797e835d6f972384bd8d48053624c99a611cf9b03","logsBloom":"0xb034000008010014411408c080a0018440087220211154100005a1388807241142a2504080034a00111212a47f05008520200000280202a12800538cc06488486a0141989c7800c0c848011f02249661800e08449145b040a252d18082c009000641004052c80102000804ac10901c24032000980010438a01e50a90a0d8008c138c21204040000b20425000833041028000148124c2012d0aa8d1d0548301808228002015184090000224021040d68220100210220480420308455c382a40020130dc42502986080600000115034c0401c81828490410308005610048026b822e10b4228071ba00bdd20140621b2000c02012300808084181ac308200000011","miner":"0x0000000000000000000000000000000000000000","mixHash":"0x31f0c0305fc07a93b1a33da339c79aadbe8d9811c78d2b514cd18d64e1328f25","nonce":"0x0000000000000000","number":"0x840249","parentHash":"0x2303b55af4add799b19275a491b150c1a03075395f87a7856a4e3327595ed7df","receiptsRoot":"0x99da71b17ae1929db912c3315ebe349d37f2bb600454616fdde0ee90d6dbc59e","sha3Uncles":"0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347","size":"0xea6d","stateRoot":"0xd12bf4cf3941cf48be329a939b13d3403d326841c69cdcc9a9c13ab2f227e904","timestamp":"0x640fdeb0","totalDifficulty":"0xa4a470","transactions":[{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x1b7aa44088a0ea95bdc65fef6e5071e946bf7d8f","gas":"0x5208","gasPrice":"0x174876e800","hash":"0x39c666d9b5cec429accad7b0f94f789ca2ebeb5294b8b129c1b76f552daf57d3","input":"0x","nonce":"0x26bd1","to":"0x68643ada5885f14e7c15c13bee06168eff0f7c36","transactionIndex":"0x0","value":"0xb1a2bc2ec50000","type":"0x0","chainId":"0x5","v":"0x2e","r":"0x26e648625520c256d87d8e15769e8c4290d2a7e27147594815da42070870825b","s":"0x7db34c91603e51494b59b020597e7118433d50ed548bc7efad8880cbe7820ca"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x030b1cddf635e9e71ad70b8668e235e8ec3c67c4","gas":"0xf618","gasPrice":"0x1701ca2b9d","hash":"0x2ca7289ab3738d17e0f5093bd96c97c06c9a2ea4c22fc84a6a7fbfda93ce55ee","input":"0x","nonce":"0x456d","to":"0x89416096a0a1acad3436a357478c5c548e4d382b","transactionIndex":"0x1","value":"0x16345785d8a0000","type":"0x0","chainId":"0x5","v":"0x2e","r":"0x5aa6ad410ea42dbff3781de67b4815a376cd459206595fa6655c966a7709e5cb","s":"0x82f620f8dbc356dc38ef346d1e152656a1d318becbcc41884f61e85972355c0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x9c67435ce8a33ad23f377ddf08260ffc56417f21","gas":"0xf618","gasPrice":"0x1701ca2b9d","hash":"0xb0085de1476530de3efc6928c4683e7c40f8fac18875f74cbcc47df159de17d9","input":"0x","nonce":"0x446c","to":"0x471f3a988a77472e971112e7ff2ce65996b6c8cd","transactionIndex":"0x2","value":"0x2c68af0bb140000","type":"0x0","chainId":"0x5","v":"0x2d","r":"0x75425f21a6e66e6feaee79455c897656c4a94b6189c4c033facab1b67812fc3f","s":"0x7014f4b9f760165c7757f9d6dccea349b3d00b0a9c2f845af8010140842f826"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x168f6dec26cbbb3749654e0e3cc4fc29314fdf6c","gas":"0xf618","gasPrice":"0x1701ca2b9d","hash":"0xe01c8631c86ded63af95b8dbc0c8aac5d31254c14d6ecb4cc51d98259d838e52","input":"0x","nonce":"0x403c","to":"0xf2119a49a3ae35453c1c2704da248d08977084f1","transactionIndex":"0x3","value":"0x16345785d8a0000","type":"0x0","chainId":"0x5","v":"0x2e","r":"0x56bba57ee69c09dbbd5167d0fee07d5803130fea7c278f4d8b7bc54b34be8ff9","s":"0x7eea69c0de47b6b808ea1bdd9ecf5d25f4f2743e867b1f838db59c456026d7e6"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xc9af69904b4ba7f0fb69ab1a8719bd8950265e73","gas":"0xf618","gasPrice":"0x1701ca2b9d","hash":"0x69414a126a6f07ab5e31ad2f9069fb986b7c490e096898473873e41ece6af783","input":"0x","nonce":"0x44c20","to":"0x6adc3f5394e00cd067d1fad5a33756791e303c25","transactionIndex":"0x4","value":"0x16345785d8a0000","type":"0x0","chainId":"0x5","v":"0x2e","r":"0xdc9a52b87755cd07143bf032d57258d0d6c36500b38a574a9a5addc1293343da","s":"0x581e6fd051d0c72d64303c1f90edecfef46580f84f24dba930cde910923f7c21"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x92964e63cd52450e6e09a266e0c226e524754563","gas":"0x2625a0","gasPrice":"0xf5686c7be","hash":"0xa2fef1133ee726533c7f190f246fede123e3706a03933c1febc92618f90d2804","input":"0xa9059cbb00000000000000000000000011f7db5a824eaa5737c935ad09a925dd707f092b0000000000000000000000000000000000000000000000008ac7230489e80000","nonce":"0x2636","to":"0xbc071c64ed8f536011c78e847755680740d6b73c","transactionIndex":"0x5","value":"0x0","type":"0x0","chainId":"0x5","v":"0x2d","r":"0x422c5026584cd8fb8a1fe66e6edc7a020bc513cc3114083fb35f9846cd9a9792","s":"0x7fcd4e48ac5b53d881531a5651e587188157ed88d85c51533f7c6eda94c67ff7"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xdec1bc71bf91431d60ef2742f412dcd1c5a204b8","gas":"0x7a120","gasPrice":"0xb80e515ce","hash":"0x6585ec5c4c2bbf1f683f90f58e18f3b38d875e94457fe4cbb7bc5bf6581f83af","input":"0x67a5cd060000000000000000000000006343e96c99e2725e845ba04f90e03d853cc9bb2d","nonce":"0x6a5a4","to":"0xf5de760f2e916647fd766b4ad9e85ff943ce3a2b","transactionIndex":"0x6","value":"0x0","type":"0x0","chainId":"0x5","v":"0x2d","r":"0xcb7b32949ac0dedd3151d06d85ec4e99483c8ea706f12a009d97b055975241eb","s":"0x69f0009bce12e24408f9a3d5ad5a8578e2b23efb09002f7b86b3425cf8748889"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xdb954dd5d224004b26cfbb089312e0542e5d1c31","gas":"0xd5ef","gasPrice":"0x9fc748df1","maxFeePerGas":"0x116482c049","maxPriorityFeePerGas":"0x22f7afcf9","hash":"0x1db276b864fbf01dcf8cededf8d597553ecb0eb9438edfaf2f5bd0cc93297c66","input":"0xa3e35f36000000000000000000000000f18f2320e4779f21d6882d83f9133e582dfaa9b6","nonce":"0x570","to":"0x11672c0bbff498c72bc2200f42461c0414855042","transactionIndex":"0x7","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xf23a1fb0d17cdbc2831a2cb0b779795e12533e34425a3abbc4b7e7bde262b92d","s":"0xd4a2c8189378696065b7fc5d13e9cf6595d96047a31a4fcb812c2e677d22a26","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xe84d601e5d945031129a83e5602be0cc7f182cf3","gas":"0x249f0","gasPrice":"0x9502f9000","hash":"0xcbe7ed31654af4e191ca53445b82de040ae2cd92459a3f951bdcce423d780f08","input":"0xa9059cbb000000000000000000000000355f96e3261cc8237d2d36fd81cc9b9cdcbfc5ea0000000000000000000000000000000000000000000000000de0b6b3a7640000","nonce":"0x4f1f0","to":"0x499d11e0b6eac7c0593d8fb292dcbbf815fb29ae","transactionIndex":"0x8","value":"0x0","type":"0x0","chainId":"0x5","v":"0x2e","r":"0xadf7dce5f34d482bb19ff0c85f43be7008cb838043f9abb5fc08421245ac4228","s":"0x5d2c0f0b9d2e68bb8da6084e4971d57bd76bf0cd9d893c9c985962812d2df026"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xea0193f88a0d9c36e83e6fb6d382212b6373faba","gas":"0x43238","gasPrice":"0x933ea77d8","hash":"0x808ba5211f03cc78a732ff0f9383c6355e63c83ae8c6035ced2ba6f7c331dc63","input":"0x9f8420b300000000000000000000000000000000000000000000000000470de4df8200000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x0","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x9","value":"0x470e9f23394000","type":"0x0","chainId":"0x5","v":"0x2e","r":"0x9536f87e8c3433ea23ef7211c0c32689551906dfdf31bcc73b89fcf18fe86a92","s":"0x3e94bfe3b4ba32a6ce71ee6e0ff9f26dfc2b0d61b5c0fe049469e3c4b88ac227"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x1f9ab300b380313e6a2208e44c01a0602538385d","gas":"0x32b38","gasPrice":"0x87fc9eef8","maxFeePerGas":"0x2e90edd000","maxPriorityFeePerGas":"0xb2d05e00","hash":"0xdd66f1f26672849ef54c420210f479c9f0c46924d8e9f7b210981ffe8d3fac82","input":"0x32db5470000000000000000000000000000000000000000000000000000000000084021000000000000000000000000000000000000000000000085b0af981975a40fc5a00000000000000000000000000000000000000000000053ae1f470262f3b01c4000000000000000000000000000000000000000000000813bca9f8389ffd193f","nonce":"0x5699","to":"0x28cea7b0f3916c1dba667d3d58ec4836ad843c49","transactionIndex":"0xa","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xbe8eddd463a3518a4c94b5922c0f2fb26a32c8afcd819f7deaf4f0416757ad13","s":"0x3e234182acd5261dfba3cf4f125d1a8377fc707b3b1900b565d1a6b8987b398c","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x1d990a2cf61b46f37582dd31a7b242e989e1a1ee","gas":"0x493e0","gasPrice":"0x86f96eddb","hash":"0x254abb2f8cdcffe9ef62ab924312a1e4142578db87e4f7c199fd35991e92f014","input":"0x9f8420b3000000000000000000000000000000000000000000000000002386f26fc100000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x0","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0xb","value":"0x2387acb3784000","type":"0x0","chainId":"0x5","v":"0x2e","r":"0xbfe9b99fd2e9bbd2d65bb4cc17da88130d8f6b569a26afa642ed1cc8efd2e2ef","s":"0x7003dd3962eec2369bc5abe5e3d5b73a9086a3219643b1741f3a9832369448fa"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x1124bbb196fd7b61947f6f03b7d7cebde8340b6f","gas":"0x493e0","gasPrice":"0x86f96eddb","hash":"0xa7b7c654e7073b8043b680b7ffc95d3f2099abaa0b0578d6f954a2a7c99404e1","input":"0x9f8420b3000000000000000000000000000000000000000000000000002386f26fc100000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x0","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0xc","value":"0x2387acb3784000","type":"0x0","chainId":"0x5","v":"0x2e","r":"0xe8dae9efa8fa73a3aebdaa75ba12acf56712b1f99fc128ab802a7610d014547b","s":"0x2ef347ea90a0db21b035637342bfc916c9962d3ec610a4e99cfaf555a2606fe2"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xdedf52a88fe47f6a11d629badd0096d201aef86a","gas":"0x493e0","gasPrice":"0x86f96eddb","hash":"0x7ccdfa698c8acf47ab9316ed078eb40819ff575bcf612c6f59f29e7726df3f96","input":"0x9f8420b3000000000000000000000000000000000000000000000000000003a3529440000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x1","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0xd","value":"0x45d964b8000","type":"0x0","chainId":"0x5","v":"0x2d","r":"0xfc4e092094abc7fed9cf11eea8ad6ec3a760d13b9c603b5570c2143e48090f2f","s":"0x31a0a6016ab51ed6375891bf532d9031bf91c1d0e01df63cf7e46076aeee83a3"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xe1db1fd154b344ce7dfcb53a65279559b298f0df","gas":"0x493e0","gasPrice":"0x86f96eddb","hash":"0xa0b035ef315824a6f6a6565fa8de27042ade3af9cf0583a36dea83d6e01bf2a8","input":"0x9f8420b3000000000000000000000000000000000000000000000000002386f26fc100000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x0","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0xe","value":"0x2387acb3784000","type":"0x0","chainId":"0x5","v":"0x2d","r":"0x79c316492bfa36fa4de2dca02ffac77f6c1772714e153aad8c947ce848d4106f","s":"0x4fe3e083943ca8f974cb0752a2ffb70e4d6c8b615e16ece7e19b2c464be66929"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xd4c3777e1821f6fb532957104e1317a9d3f881ec","gas":"0x493e0","gasPrice":"0x86f96eddb","hash":"0x1ebad7f3e8cb3543d4963686a94d99f61839f666831eab9c9c1b4711de11d3d9","input":"0x9f8420b3000000000000000000000000000000000000000000000000000003a3529440000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x1","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0xf","value":"0x45d964b8000","type":"0x0","chainId":"0x5","v":"0x2d","r":"0x5c1f544ca92b28a014129a9d04f8e895dc8a6987ddc1717c26b0619bb9bac420","s":"0x47574643bd92a0f129f9c5ce3caebe7943cfd828d67fb0e5bdc1eb2ca202822a"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x127418955b15f5ff2fa232431a798b53fd006c82","gas":"0x493e0","gasPrice":"0x86f96eddb","hash":"0x501750278e91d8b5be1ccf60e793d4bbcd9b3bb3ccc518d3634a71caeac65f48","input":"0x9f8420b3000000000000000000000000000000000000000000000000000003a3529440000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x1","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x10","value":"0x45d964b8000","type":"0x0","chainId":"0x5","v":"0x2d","r":"0xcfc9894bf716ba707521f0969082afb688b7d47cc21f1423b239c40867128f47","s":"0x5d9b9c66d8437d0a37768fb9c3241ef64b7e795d0d908196e1f707215ac1f56"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xc2ac1bdcb3dd77864b99eb2cafef2ed36c1487c3","gas":"0x493e0","gasPrice":"0x86f96eddb","hash":"0xd80ff8af29ae163d5811ba511e60b3a87a279f677bb3872a0f1aa6d0a226e880","input":"0x9f8420b3000000000000000000000000000000000000000000000000002386f26fc100000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x0","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x11","value":"0x2387acb3784000","type":"0x0","chainId":"0x5","v":"0x2e","r":"0x8bd7220d176d18cfbc824063448cf864c494fcf0958dec82126f26d3fc6c0b6e","s":"0x2f4de3d2fc3be6d2812ee10aee16a995af5affcfec27f9953ae609886d2b563e"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x11a5ad000f8494233df5bd2f2573fe20bad744ab","gas":"0x493e0","gasPrice":"0x86f96eddb","hash":"0x096acab3b3fe47b149d375782d1eb00b9fef7904076d60c54b3c197b04e6bf82","input":"0x9f8420b3000000000000000000000000000000000000000000000000000003a3529440000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x1","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x12","value":"0x45d964b8000","type":"0x0","chainId":"0x5","v":"0x2d","r":"0x43726c3165958e94d80cb6992121f55df2904a1de4356e0a6ff3d8bfd03c0928","s":"0x6244361e31daccbb5c7e9f3f7d01004080d2efa314d614fdc2aad4c1b7d71613"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x90f8b290ec2929cce086826e971cad3857c6dbb5","gas":"0x50f46","gasPrice":"0x861fc89f8","maxFeePerGas":"0xe22924cba","maxPriorityFeePerGas":"0x9502f900","hash":"0xbe9d1738af74a22400591a9a808fb01a25ab41e2e56f202dd7251eb113e8ceeb","input":"0x6ab150710000000000000000000000000000000000000000000000001bc16d674ec800000000000000000000000000000000000000000000000000000de0b6b3a7640000","nonce":"0xe4","to":"0x2e84c9894f628fd209f48b06d10b46c8cada4c10","transactionIndex":"0x13","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x412c7bfb0236a4317da40645ee4e60f19185e7d0cd2cc9bc88f7629de505b939","s":"0x4f6bd485d10fa134926ec3e3a83e212f3c5d903ba52da87f07794a2ba0a5c1eb","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x7915ec065b644568155c4772a286addad3864c1b","gas":"0xb71b00","gasPrice":"0x861fc89f8","maxFeePerGas":"0x1176592e000","maxPriorityFeePerGas":"0x9502f900","hash":"0x0834c720e55cccd97aaf4f8fb0cb66afb9881fb6a762c0f70473ec53f98a712e","input":"0xedce8b4d6a1fb55588eadfd3a0c3350435a31d31e7c236125eafcc2a892d50711d9a4939a4282888c956c070cd83400fd47ab83bd5287244053b8228711b07386dccacbd000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000001a0000000000000000000000000000000000000000000000000000000000000082000000000000000000000000000000000000000000000000000000000000008a0000000000000000000000000000000000000000000000000000000000000092000888ad4975d4079d80bc6da5ded57746f889644719ec160efc2e4a96ad645df10b1683afcd7ce41ba6c06528761f821cbc6e806ef4b71c189603ec218b12a1f1478883498e67b97ae4babef6996acc582db1377d8755374602e00b8148025ac2d2f52e78d7484919cef14bf96e5b7a3f7f8cf09989551888f2c697052ce2bdb02a9296b20016c78683a9ca137037e57c8ff25198146f9d4cdb5a25ab9c95a03038f22f83c8604ca7c035ef756d2963c3657eea4ffb18ef967752d8cff15a16124a1d92a1cda613624c98e3078742803da1417b78bb264b7bb2197515cb4facc2ea395c6241664dbd953d0034900a86eb94897bf89aae775a1d73e6fd034785400000000000000000000000000000000000000000000000000000000000009a0000000000000000000000000000000000000000000000000000000000000000300000000000000000000000000000000000000000000000000000000000000600000000000000000000000000000000000000000000000000000000000000260000000000000000000000000000000000000000000000000000000000000046000000000000000000000000000000000000000000000000000000000000001d802f901d482e7041b846de27f7b846de27f8383026c28946aa397cab00a2a40025dbf839a83f16d5ec7c1eb841dcd6500b901a45ae401dc00000000000000000000000000000000000000000000000000000000640fdf5900000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000e404e45aaf0000000000000000000000002c1b868d6596a18e32e61b901e4060c872647b6c000000000000000000000000964ff70695da981027c81020b1c58d833d49a64000000000000000000000000000000000000000000000000000000000000027100000000000000000000000009a1a41127726f74560a57990fb928120eed6f55e000000000000000000000000000000000000000000000000000000001dcd6500000000000000000000000000000002d4766adcf72ef2d996edfadc866be12c28000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0000000000000000000000000000000000000000000000000000000000000000000000000000001d802f901d482e7041c846a969541846a96954983026c28946aa397cab00a2a40025dbf839a83f16d5ec7c1eb841dcd6500b901a45ae401dc00000000000000000000000000000000000000000000000000000000640fdf5a00000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000e404e45aaf0000000000000000000000002c1b868d6596a18e32e61b901e4060c872647b6c000000000000000000000000964ff70695da981027c81020b1c58d833d49a64000000000000000000000000000000000000000000000000000000000000027100000000000000000000000009a1a41127726f74560a57990fb928120eed6f55e000000000000000000000000000000000000000000000000000000001dcd6500000000000000000000000000000002d4766adcf72ef2d996edfadc866be12c28000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0000000000000000000000000000000000000000000000000000000000000000000000000000001db02f901d782e70480846a969541846a9695498302e100946aa397cab00a2a40025dbf839a83f16d5ec7c1eb870aa87bee538000b901a45ae401dc00000000000000000000000000000000000000000000000000000000640fdf8d00000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000e404e45aaf0000000000000000000000002c1b868d6596a18e32e61b901e4060c872647b6c000000000000000000000000964ff70695da981027c81020b1c58d833d49a6400000000000000000000000000000000000000000000000000000000000000bb800000000000000000000000048f2c17f8885e135c8689626d5841d0b94013556000000000000000000000000000000000000000000000000000aa87bee5380000000000000000000000000017a8db2711fe83b10bbfabb6a8b86c3e26ca154ef000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c000000000000000000000000000000000000000000000000000000000000000000000000003000000000000000000000000000000000000000000000000000000000000001b000000000000000000000000000000000000000000000000000000000000001b000000000000000000000000000000000000000000000000000000000000001c0000000000000000000000000000000000000000000000000000000000000003760f4e19e59be10b323fe1b42e42de2754c5da54ff316cef74ef09dbc0144bbf73e609a8d21a38f393bae9a3de6bebbf362608d907d941c8166f44d8ee2c6686b5dbbd6681f5467219d9bb530db013b7c067db659c03efe935caeb7bab36699d00000000000000000000000000000000000000000000000000000000000000032d2d7436bd45b5e81824945ff3dda846e270c81e72929841f4b14f56e02eef39477f9c162a2759c8d7c7e1feefdd064f6aefb4360d483f70671f36fc11ccc6db6c53f74e3019c12d859545ad75b51998b2238887dc0be3c78522c8356150526a0000000000000000000000000000000000000000000000000000000000000000","nonce":"0x48f08","to":"0xe87d317eb8dcc9afe24d9f63d6c760e52bc18a40","transactionIndex":"0x14","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x54159a63b8ce19097cb8afeaffc84cfb5257f9709dcb0f0a258befa0b924b13","s":"0x17f5ef5aeceb6f082a8a0f8fa28e55d453c52e5f86d48dfb4d4f039aad7fa493","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x52db522edf50fc32b8fc0f77d51140031da11da3","gas":"0x201568","gasPrice":"0x861fc89f8","maxFeePerGas":"0xe22924cba","maxPriorityFeePerGas":"0x9502f900","hash":"0x51a0c33c9b37245b416575bdd2751c0d8a5d8bead49585ac427bfc873d4016af","input":"0x96d3f83c0000000000000000000000008cd194f4ced354a14960f76f49305feb8510f73f00000000000000000000000000000000000000000000000000000000000000e000000000000000000000000000000000000000000000000000000000641024ef0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001b3fd330d479974ad52e18b8767d9f18cf9ff024fa749b1066a803b237570cb73e2868e821124c8128505d883124711ae7fdca0339f4f5cd5dadd8eb6956eb4af500000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000003","nonce":"0x2d9","to":"0x29c1442d7e3b6ed179ceb55fe996e1f4384880da","transactionIndex":"0x15","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xac84f403fa0347be3246ad695f8f6a780332357d49dfa67388fae3e051e5566c","s":"0xac2e148c1045af0ebdb334f20743af7d5499558af5eea43393159ce26a3fb1b","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x3aea5f857b75a946d5f5b329bdcf4db46aec5d2c","gas":"0x50f46","gasPrice":"0x861fc89f8","maxFeePerGas":"0xe22924cba","maxPriorityFeePerGas":"0x9502f900","hash":"0x531c25d51ccda59aa9ea82e85c99be9dd4e285af9b8973cbab9ac4a38e26e55a","input":"0x6ab150710000000000000000000000000000000000000000000000000de0b6b3a76400000000000000000000000000000000000000000000000000000de0b6b3a7640000","nonce":"0x1d","to":"0x6c23a4586cc791d2be6767532e12264992aef74a","transactionIndex":"0x16","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x81abc4fdf3b57fdf3a951fb293853fdd86aadce8f319576ac78c60caac186c43","s":"0x452742335bd1f63fd623d5e6cf91f6339361f863dba1a57fc3c1da8292e82c77","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x7915ec065b644568155c4772a286addad3864c1b","gas":"0xb71b00","gasPrice":"0x861fc89f8","maxFeePerGas":"0x1176592e000","maxPriorityFeePerGas":"0x9502f900","hash":"0x93ac6c08d21cb1b61ff59e5e2d6fa3f9ad54008b0a66c669199050bef219f6e3","input":"0xedce8b4da4282888c956c070cd83400fd47ab83bd5287244053b8228711b07386dccacbdb54cb66757631f9f22e2faf7da0eecc43474ab1a1af21aec22dcf949e2579241000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000001a00000000000000000000000000000000000000000000000000000000000000860000000000000000000000000000000000000000000000000000000000000092000000000000000000000000000000000000000000000000000000000000009e011cb7bbabfab668b42b5582cec8d60f326ae14ad55f8d675060dd111dee6c88d0937435261929ba3a881bea107593a10e13c917a0ef5ae4e8bde40de2d1da4ba25ab3a239ba53eb4e260d23b98a7db944f644f40ab75992a89fad40e8d692ad62f8671604db415b54238c5522f6c4e6b25785bffa696d173659309b95a2fae8700d4b9c14382973ea34a3cd8b8428594908dcad2d5d7a01056b8e49a8c25087f12f9e9fec1f4b5fdc57509dba6839100e28016b2e3fec4928bbe11d3789b6cab280c17bebfa5a0e06aea22764e1a18d2d11316bdf81028e65755582586ebdf571cbd0ef59800ba3405539187dfc03eac1dba0cf590e2131a56ef7f260aa38f940000000000000000000000000000000000000000000000000000000000000aa0000000000000000000000000000000000000000000000000000000000000000500000000000000000000000000000000000000000000000000000000000000a000000000000000000000000000000000000000000000000000000000000001a00000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000032000000000000000000000000000000000000000000000000000000000000005c000000000000000000000000000000000000000000000000000000000000000da02f8d782e704820101846a969541846a96954982dc1994a59477f7742ba7d51bb1e487a8540ab339d6801d87470de4df820000b8a4220b5b82000000000000000000000000f6213f16f3db9b50c684b2da37ff080895ae4a02000000000000000000000000000000000000000000000000002386f26fc100000000000000000000000000000000000000000000000000000000000064376b6900000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000000c0000000000000000000000000000000000000000000000000000000000000000000000000003202f082e70411846de27f7b846de27f8382520894b6605a717a2447edac46b1cdafe35e3e91130c8d87038d7ea4c6800080c0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000f202f8ef82e7040d846de27f7b846de27f838303335f947191061d5d4c60f598214cc6913502184baddf1880b8c44d49e87d00000000000000000000000000000000000000000000000000000000000000600000000000000000000000000000000000000000000000000160f9854c9f595e000000000000000000000000000000000000000000000000000000006417d4b8000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000b1a2bc2ec5000000000000000000000000000000000000000000000000000000b2f4f1df2e372ec00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000027502f9027182e7048197846a969541846a96954983029eb1946aa397cab00a2a40025dbf839a83f16d5ec7c1eb80b902445ae401dc00000000000000000000000000000000000000000000000000000000640fdf0b000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000016000000000000000000000000000000000000000000000000000000000000000e404e45aaf000000000000000000000000964ff70695da981027c81020b1c58d833d49a6400000000000000000000000002c1b868d6596a18e32e61b901e4060c872647b6c00000000000000000000000000000000000000000000000000000000000001f400000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000c097ce7bc90715b34b9f10000000000000000000000000000000000000000000000000000000000000000000000614000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000004449404b7c0000000000000000000000000000000000000000000000000000000000000614000000000000000000000000694b3f194e94c80b2d7a0e986e1440f204f0503f00000000000000000000000000000000000000000000000000000000c0000000000000000000000000000000000000000000000000000000000000000000000000000000000000b902f8b682e70427846a969541846a969549830dbba094964ff70695da981027c81020b1c58d833d49a640872aa1efb94e0000b884437471fd0000000000000000000000004e44260732136caeffc7d076e17b2a3554b9ce2a000000000000000000000000000000000000000000000000002aa1efb94e00000000000000000000000000000000000000000000000000000000000064376b6600000000000000000000000000000000000000000000000000000000000dbba0c0000000000000000000000000000000000000000000000000000000000000000000000000000005000000000000000000000000000000000000000000000000000000000000001b000000000000000000000000000000000000000000000000000000000000001b000000000000000000000000000000000000000000000000000000000000001b000000000000000000000000000000000000000000000000000000000000001b000000000000000000000000000000000000000000000000000000000000001b0000000000000000000000000000000000000000000000000000000000000005b0efccaa7c845eddd4fb98211c7a58a37abdf06b264fade6cbff8a73ed22fccc602337b33a81e2cc4127be9d913fb3aec24194e14a61515a26429a00cfb86196aa3c2e6983f1a05dec045f0e63db7bd8619cd2a770ed1f7f470eb7c297e8e19d61277fb276ed8a63fd666b4a5ab02347065a3c16539f4ccccbed8fa39f2a7dc6606fc04c49f3d69463ba1c86c6ddcef8b9f06b9741dc2ebae9f5f1c0523b320b00000000000000000000000000000000000000000000000000000000000000050668b9ca5e5b17e2e79f9f5a7d9ea27e4e7f0302e878584fef3c2304c70c1ef53da311342341f89df488646b97a83994a3d07cc622ffde98598548c5326b7ccc0cf77d5d6fca6cf3f5b5b41a266fa2aaf697fd976dddc710fca834c96d2dfd725eec5980733db3c4e8f779f9fde3a598b2860d819419c961012825f0e160ee7b220989005b6ac5c48734db18158c2d85c8499bea1972c9f875c2d2aeafccb33700000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000014000000000000000000000000000000000000000000000000000000000000000e0000000000000000000000000f6213f16f3db9b50c684b2da37ff080895ae4a02000000000000000000000000f6213f16f3db9b50c684b2da37ff080895ae4a02000000000000000000000000000000000000000000000000002386f26fc10000000000000000000000000000000000000000000000000000002386f26fc100000000000000000000000000000000000000000000000000000000000064376b6900000000000000000000000000000000000000000000000000000000000000c000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000140000000000000000000000000964ff70695da981027c81020b1c58d833d49a64000000000000000000000000073fee82ba7f6b98d27bcdc2befc1d3f6597fb02d000000000000000000000000000000000000000000000000002aa1efb94e000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000064376b6600000000000000000000000000000000000000000000000000000000000000c00000000000000000000000000000000000000000000000000000000000000044a1c058fa0000000000000000000000004e44260732136caeffc7d076e17b2a3554b9ce2a00000000000000000000000000000000000000000000000000000000000dbba000000000000000000000000000000000000000000000000000000000","nonce":"0x48f09","to":"0xe87d317eb8dcc9afe24d9f63d6c760e52bc18a40","transactionIndex":"0x17","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xb5f185933d49064643686594f44a2584b1d57ba6a91f2a45d1a122892488f209","s":"0x7bb4af7ea30290b36fa7c266ee2387eff9e3ee0cd79b48aed27f5bfaaf34114c","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x4281ecf07378ee595c564a59048801330f3084ee","gas":"0xea60","gasPrice":"0x861fc89f8","maxFeePerGas":"0xfd18eeafe","maxPriorityFeePerGas":"0x9502f900","hash":"0x3792db6dd6285f409e4281951e9f78dad16c4a78072ff1c909dfadea5658d857","input":"0xa9059cbb0000000000000000000000000cc351a97c2fafde4cfa8a00c4fd79881cf13b53000000000000000000000000000000000000000000000001158e460913d00000","nonce":"0x77ffb2","to":"0x326c977e6efc84e512bb9c30f76e30c160ed06fb","transactionIndex":"0x18","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xef4173dd45060791cfb6dfc3cdc8a9b417ff6a4b3ba57759ea91fd875b01a522","s":"0x4de926b5099c7d60cc24add3c2eecd8e9550c1fe7f878430eccb887a2ff932ff","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x53e2c2479833ca17f946aeb16dcc49f5e2194701","gas":"0x431eb","gasPrice":"0x8442f24f8","maxFeePerGas":"0xd6aac8818","maxPriorityFeePerGas":"0x77359400","hash":"0xd2d51764c01e8c0a43fbe362704388df5bacf7e5e620c3864e242530ffb3e828","input":"0x9f8420b300000000000000000000000000000000000000000000000000470de4df8200000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x2","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x19","value":"0x470e9f23394000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x155352758fb04a6c0816c3dd9ca16bd6c66c37e2e19f2aa5d969225e3cb7f118","s":"0x6a4a1237db75dac4322fe12aee8b94edf7083ea661d6e93334c667d2d5c2c101","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x535619cf2bd2e84e567bda1a6164f195cb2bba21","gas":"0x55730","gasPrice":"0x83152e5b0","hash":"0x516b0227d9e64eb6e0de6862764d40f5376b5f12fec878436fea3479b4c36bb8","input":"0xa9059cbb00000000000000000000000030509945d2b329cc253a8bb2e2c54bdbb08b1070000000000000000000000000000000000000000000000010ce1d3d8cb3180000","nonce":"0x2176","to":"0x1173069b0e472a64ce2b6203fec8fb25a05b75c2","transactionIndex":"0x1a","value":"0x0","type":"0x0","chainId":"0x5","v":"0x2e","r":"0x289ee9948b80fc623b8c5d85c7df6fd25786fcc118163042b77a00560f53c3fb","s":"0x5b0a79e30d05370b27664b2a10cf964e110387bd62098561b6ea6a9dcc4634a"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x339d413ccefd986b1b3647a9cfa9cbbe70a30749","gas":"0x180ac","gasPrice":"0x83152e5af","hash":"0x81b0abc78b82840adb666775b182a9e292f663b64bcd35004c04436ed3c8281c","input":"0x711746e200000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000009a00000000000000000000000000000000000000000000000000000002540be40100000000000000000000000000000000000000000000000000000006d3c514bd0000000000000000000000000000000000000000000000000000000000000010","nonce":"0x2689","to":"0x7cbd185f21bef4d87310d0171ad5f740bc240e26","transactionIndex":"0x1b","value":"0x0","type":"0x0","chainId":"0x5","v":"0x2d","r":"0x1f70a3d0933aab069a55fb2b16a259d21ea5fb3255e2032c5ff194a600ed2ab1","s":"0x3ac2142fc9f2009d68b08855eb5bc85e889e15d043c33bfc516f28ea38715485"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x339d413ccefd986b1b3647a9cfa9cbbe70a30749","gas":"0x180ac","gasPrice":"0x933ea77d8","hash":"0xd0287570d431d2baea96ecc81cb890e7f4f06ab5df02f9b4067768abca19acb5","input":"0x711746e200000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000006500000000000000000000000000000000000000000000000000003a09994473bc00000000000000000000000000000000000000000000000000000005672af7e00000000000000000000000000000000000000000000000000000000000000010","nonce":"0x268a","to":"0x7cbd185f21bef4d87310d0171ad5f740bc240e26","transactionIndex":"0x1c","value":"0x0","type":"0x0","chainId":"0x5","v":"0x2e","r":"0x73a68e10ef9726d47ff314cd16d1846a0876d2b63a65014909140de7e45aa8b3","s":"0x580de27e4626139fbad4129a249c7ac2b22e1062659293e5fc3a244fd74907c"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xb5b9345e21f34b6cfa538f49e2b14ad4c3db3f7e","gas":"0x431e0","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x76ddab2674369f34946c5fa2f05e2aa8566d86235b83e808e9b27bc106e04ac7","input":"0x9f8420b3000000000000000000000000000000000000000000000000016345785d8a00000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x38","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x1d","value":"0x1634632a1414000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x4314a4757076c92ca696f14cbe037bcc0178f8b10749418d4535195e90b2cdc9","s":"0x15ee917bc3e27928196ad987b61e3fd35ac92a4200b139d355b30502bff7fceb","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xac2fde165d9f13a223f58b9ac1dde51b63feff2b","gas":"0x5208","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x34a5c74011a2c8a00103bc91bfbfd94aa99cd569be69066e4bf64d188fe8714e","input":"0x","nonce":"0x38","to":"0x7155eba8ef327ac3b36fe59b5e00ab85f735f4f4","transactionIndex":"0x1e","value":"0x1c9f78d2893e40000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x52178c5dce512607a6242f501f78bc894917a482e99a3368caea6bca94c6dd69","s":"0x728be90654231b65f790eba478ccab574e2468fc4e031b712efa88af31fc6592","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x1ddedd674bfacb6587e0c68cee8f2f7d8a71e9d7","gas":"0x1d4c0","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x7b9730ead1b9f59b206d0ddea87be9383ba3fc7b496c7863b0cb847889b86617","input":"0x607019b9000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000041971588d95d4d664ac84a45e59fc81871b7051d679376d86cef6b9e1453c762dc33a84a125774319ee47f2a8b8d588da6c8ff7ad84fd9eed22fa124b1a5c5ed4d1b00000000000000000000000000000000000000000000000000000000000000","nonce":"0x1","to":"0xe1e6aef7642b6609e6c54884d1bda4a3cb152461","transactionIndex":"0x1f","value":"0x4380663abb8000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xc0d3e609b2e9f844d300a7784aa9e7cb956415d025cb573a73848f49e4be69e5","s":"0x6ce01527c00c1a93341a541824aed7a1c895f5a0d998f4415cf6d88171c5ad3e","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xf6df8ead0bdabfba61d9b2457d5a5ccec67fb7f3","gas":"0xc836","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x77166ee0409ba86bd26e7c03ad1a927abaf5af8a8a37149e725cd37512091dd6","input":"0x67a5cd06000000000000000000000000fa8449189744799ad2ace7e0ebac8bb7575eff47","nonce":"0xbd","to":"0xccb0f4cf5d3f97f4a55bb5f5ca321c3ed033f244","transactionIndex":"0x20","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x5649e1ff58fa9b6ee27a7316904df02db1ba1c471a2f3409f370a31c6b3d5ec4","s":"0x386b766277e267f8796ba6e92af71a752335bbe45cb3385b9cdcab9ef6c53e41","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xf37cbbc2dad42e8826898d45933afd3a04937e71","gas":"0x112c1","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x3c2b6c2ae505c5c36d5f316c1fcb5f54f7346ed35ae35c93462991ded7968a68","input":"0x095ea7b300000000000000000000000071bcefe9e9fbad3f12f2e6c14ea0cae7f0c91e7900000000000000000000000000000000000000000000000000000004912e6bef","nonce":"0x9","to":"0xb5d86e1f237d52f1f19793d3265e9340394f75b8","transactionIndex":"0x21","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x3ee4d5bfc575fa4b241b4d23e6f099eba5f1e6a20b8cea663c63db6400d01506","s":"0x21481ea7a3e7ad758f2e149829f70f43d67b3cc0d44112cd3744e290a06dd985","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x52b6255b7810d97de8f751737547d1792dff4fe0","gas":"0xece2","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0xf99a792837e13827b5e0a8915fb59c760babc95d242feca99a5594e64ff6b6e2","input":"0x095ea7b3000000000000000000000000c92470d7ffa21473611ab6c6e2fcfb8637c8f330ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff","nonce":"0x51","to":"0x07865c6e87b9f70255377e024ace6630c1eaa37f","transactionIndex":"0x22","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x5237f7449c0df409c1a4d6cb09005a9224860aa74737debd961e2a24668d1022","s":"0x17e5e842e3f5ffb5a16eca0ec2a92e5b52d43bf9856f97e2083b2e951499b970","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x3c70503d83c5a681aab503d724f47fe810ae8205","gas":"0x17eb2","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x522313f5d923f048ae5bd0b5595c1f4fc883bc0b3cf3cb0939d3fcf8b08c829c","input":"0x94d008ef0000000000000000000000003c70503d83c5a681aab503d724f47fe810ae82050000000000000000000000000000000000000000000000000000000316195298000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000","nonce":"0x5","to":"0xb5d86e1f237d52f1f19793d3265e9340394f75b8","transactionIndex":"0x23","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x6741309799fccf0f1359bd710291ec1bb66eed23522d6ed60c5924264d4d283e","s":"0x69c43182ee8a650b0042cdb2352781b23eb1de72f1c3a8903a1a33360e7d9732","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x4da9a48963c158a88bf6d4845a6a1890d20e55ad","gas":"0x431eb","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x471ceb0e85af594aa56deca54cb8198567b2afd8406722ea530077aaa6b641b3","input":"0x9f8420b3000000000000000000000000000000000000000000000000001dd7c1681d00000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x0","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x24","value":"0x1dd87babd44000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xf977ce19da80b7e155ee2d8b7656e5c89004851407bd5370785befe2c89d82f6","s":"0x1d76177407e73d8b73b0909158825ee375a25fa7c18b04884f4be77bb60795a8","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xe40a2cd9efde08fb7664bcdbbdd877c52c4bd228","gas":"0xf4f6","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x3e9dca502e9039ae0c6d642f62e9562ff00010c6bfbb8234a6135712ba70dfda","input":"0xa1ddc5460000000000000000000000000000000000000000000000000000000000000738","nonce":"0xa","to":"0xdef65f8e2f62bde60cd86ad3b4ad7fa6741cf175","transactionIndex":"0x25","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x34df85658956c9eb71549db3a73abca70dd01b8e91284afcd372c1212a36605d","s":"0x5036e2984bb2edbb5fd647bba873f1f5c5ee4845e539c9b0bc70d3d12a4bd93f","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x17299065e99b12b0c8cad06638624cff8d507334","gas":"0x5208","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0xc95cac67267f4accb9b5950316ac64772f7d082bed6b712c09cf2da0bdc237b7","input":"0x","nonce":"0x7","to":"0x02647cbb1714fa9a5747ec5be6333e06d806e85a","transactionIndex":"0x26","value":"0x71afd498d0000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x82ee5cafbd010cdf7a4604df728d1b8713a5bd26a708f5c92f6b6a55864c9576","s":"0x2b9a70d812123b2ddce1108c4101ddce182f6c83fc8aa0a139ba597aa178b270","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x9aef7b879787baf0c2dfe888e67a7edb7a233209","gas":"0x431eb","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0xfca28fdbd13fc16daf7aec7d4a2ad2c6b5f0b2a7b0fb1d9167c09b5e115ff26e","input":"0x9f8420b3000000000000000000000000000000000000000000000000002386f26fc100000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x2","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x27","value":"0x2387acb3784000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x7e5f1a27ea5e652ec8705f80365f1703d2fd50c1de7c22ee0181d556dd2fcc38","s":"0xb22fb8b31dbfff8ad0457ba4b659fb0d7031cd86f08fc3cb78d81c97248034e","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x06006a25e0fe65f0eeaad1f4813940b68db782a7","gas":"0x17ea3","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0xc73124ca798b2f7a5df2ea4d568efab2f41b135130ea5cc41d4bcb4b5c57d5bd","input":"0x94d008ef00000000000000000000000006006a25e0fe65f0eeaad1f4813940b68db782a700000000000000000000000000000000000000000000000000000002726bc7f1000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000","nonce":"0x6","to":"0xb5d86e1f237d52f1f19793d3265e9340394f75b8","transactionIndex":"0x28","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xabe4fc843d3a1628a464884c13c21bd21ae9a0a5738d9ae2761ec7cb24b059d0","s":"0x68408d8096e542b2c06cbbecb9494a3778c3ab644e69dde1fac078079c4bcad4","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x2501bf5c8ddf04a60fdd47a95d53d99b315604e2","gas":"0x5208","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x29abb76b5e7a5ce137bf9c22474d386eb58d249f43178d2b2e15c16dfdc5ca80","input":"0x","nonce":"0xa","to":"0x901a4e04f1513443c6efc6ce4e913d1b960ecd20","transactionIndex":"0x29","value":"0x1a3385ff37f0000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x1a1789d5b19950f45383cb1909cff9128dc2b332e2ea7ba42cfca5806376e3cb","s":"0x617a5a4339503a9c9d08705d98e7a202ed7ede1d1192fd7d98b648c8c102716c","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x507832c92ade971b9a2880427353c6ce6d0ffe53","gas":"0x61a80","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x03e5ab25a58bd44fb9dd0c698b323eab8b8363479dfcbcbb16d0a0bd983880ae","input":"0x85ff842c00000000000000000000000000000000000000000000000000000000000000c0000000000000000000000000000080383847bd75f91c168269aa74004877592f00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000006100000000000000000000000000000000000000000000000000000000000557300000000000000000000000000000000000000000000000000000000000000014507832c92ade971b9a2880427353c6ce6d0ffe53000000000000000000000000","nonce":"0x1e7","to":"0x805fe47d1fe7d86496753bb4b36206953c1ae660","transactionIndex":"0x2a","value":"0x214e8348c4f0000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xf707322f65ba56c95ced5654efafcf9bfd60a2dd80e74bded3190673cda55d8e","s":"0x46412ec3d2137fcef30f53cc4644769f4da126128979920ed4e209acb1c8ebc9","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xd44c850ce9103d6b2398d4ed9bbce321f3b769c7","gas":"0x1e0cf","gasPrice":"0x82661bff8","maxFeePerGas":"0xde6f782ba","maxPriorityFeePerGas":"0x59682f00","hash":"0x3c8ee80ddea7fa2d2b75e44563c10c10756f598e8ad252a49c5d3e8a5c8e6cbf","input":"0xeb672419000000000000000000000000d44c850ce9103d6b2398d4ed9bbce321f3b769c7000000000000000000000000000000000000000000000000002e2f6e5e14800000000000000000000000000000000000000000000000000000000000000000e0000000000000000000000000000000000000000000000000000000000098968000000000000000000000000000000000000000000000000000000000000003200000000000000000000000000000000000000000000000000000000000000100000000000000000000000000d44c850ce9103d6b2398d4ed9bbce321f3b769c700000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000","nonce":"0x9","to":"0x1908e2bf4a88f91e4ef0dc72f02b8ea36bea2319","transactionIndex":"0x2b","value":"0x2e2f6e5e148000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x327a6fbcaa2ac3cfb0ce64b47f6e61de4d18297f1305f23c6bfd42d88e8d068","s":"0x6b3a9b5252ced14b2e2f2833ad7cc62c46fbd0785d57f2747473af3fff7d46b8","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x78aa9046272fec8d51a402681d7c37481db01c6f","gas":"0x431e0","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0xaffa73b68bc7ab0c3f5e28377f5ca0a5df33c0a485f64dc094b7f6ae23353203","input":"0x9f8420b3000000000000000000000000000000000000000000000000016345785d8a00000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x36","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x2c","value":"0x1634632a1414000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x925370b51dda3e1d1bc6b86580fda3b40875157ea594a9a14174436c726ad46c","s":"0x516c88bf3cb2f46ca81572140b41e5db2d74c4a736ee7d572b508415c438f779","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x56784e51c2ce28dbe9aa68342638d1e95ea4324b","gas":"0xb72e","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0xc66c9c66fbc8fe97fcc16506cde7a58689af1004a18c6171cfe763bcd94f50b2","input":"0x095ea7b3000000000000000000000000805fe47d1fe7d86496753bb4b36206953c1ae66000000000000000000000000000000000000000000000000029a2241af62c0000","nonce":"0x9","to":"0xcc7bb2d219a0fc08033e130629c2b854b7ba9195","transactionIndex":"0x2d","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x407c855bed0fb088e886c3721ee9abee4761221d110512ac29b8fb143c4b34d4","s":"0x1e47aa957d9ebdb564dfa41b72022d525383ffd825a307fbfa9ca13a59994dcc","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x805e39acf2f170251c48a35df16411cfb2f761e3","gas":"0x56a8","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x80fec96707519172b53790610d5800cd09a4243aca9bacfa956c56337d06f820","input":"0x71ec5c05aa669c4922569c1d33f7a81aaa21813800000000000000000000000013a0c5930c028511dc02665e7285134b6d11a5f4000000000000000000000000805e39acf2f170251c48a35df16411cfb2f761e30000000000000000000000000000000000000000000000000000000000000000","nonce":"0xc","to":"0x7c125c1d515b8945841b3d5144a060115c58725f","transactionIndex":"0x2e","value":"0xb1a2bc2ec50000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x8fcf376106af19aac48ecb840ea51df90a5e3ba557eeaad41cd3c8a90785d416","s":"0x4a9e9021ddb5f839bf7f54b54ad52c57b21b6ed285773eea022e3ccae69d1b99","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x4199614bf74f6b3ef47a812d976dd1f57a8f082c","gas":"0x431eb","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x61b33bfcf11214906dcdce7d7ed83ad82f38184c03ded07f7782059d02eeedea","input":"0x9f8420b3000000000000000000000000000000000000000000000000002386f26fc100000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x6","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x2f","value":"0x2387acb3784000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x3d295f5fa2dbec04793f07adec57e29c03376c628a0256ee297fb3070a1e3364","s":"0x6f115dd4505bd320bd7460a47bab0c20e6bcb4b3f17c6d0e00e3ff1d936ed2af","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xf6df8ead0bdabfba61d9b2457d5a5ccec67fb7f3","gas":"0xc7c7","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x5d4138d4e28a8327e506cb012346b1b38b65f615a2b991d35cf5d4de244b3e6d","input":"0x67a5cd060000000000000000000000001f1f156e0317167c11aa412e3d1435ea29dc3cce","nonce":"0xbe","to":"0xccb0f4cf5d3f97f4a55bb5f5ca321c3ed033f244","transactionIndex":"0x30","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x47bfb48eb89a8b110749d34d171db36a8ad21c8d7cc78c7489e72f21cd86ba14","s":"0xa525976583b19b3d2c2dd6b34324cf55b1a61595cb53e3c58acaf203f8709e6","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x9eda8333e09828571db26576a566668f79f98946","gas":"0x50df20","gasPrice":"0x82661bff8","maxFeePerGas":"0xc8d5e2427","maxPriorityFeePerGas":"0x59682f00","hash":"0x875a142b6dfcf10ffb71a7afe0ce4672c047fc7e162ba0383390516d6334d45d","input":"0xb1dc65a400011a04d404e571ead64b2f08cfae623a0d96b9beb326c20e322001cbbd34470000000000000000000000000000000000000000000000000000000000bd780a7d2e00ee03a29f787096cae99da52d07803c76c13473654239118e2cf0491bcb00000000000000000000000000000000000000000000000000000000000000e000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000480000001000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003000000000000000000000000000000000000000000000000000000000077359400000000000000000000000000000000000000000000000000000e50bb6420faa6000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000e0000000000000000000000000000000000000000000000000000000000000000217f0aee859cd78a5cdf79c68c8de4342658d52ccc6420181b5fcb7c657c5fdfa5ca2c8f2dd7e6e5799d44d6818e6dd8fee19b2530bed2045e0c665041f053fe70000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000001200000000000000000000000000000000000000000000000000000000000840235df8360bffc902a68675311f5eaa79ea2c25e2cc394bff0a43d5d608e98c97de200000000000000000000000000000000000000000000000000000000000000600000000000000000000000000000000000000000000000000000000000000060000000000000000000000000000000000000000000000000000000000000002a00000000000000000000000000000000000000000000000000000000000004b000000000000000000000000000000000000000000000000000000000000493e00000000000000000000000000000000000000000000000000000000000840235df8360bffc902a68675311f5eaa79ea2c25e2cc394bff0a43d5d608e98c97de200000000000000000000000000000000000000000000000000000000000000600000000000000000000000000000000000000000000000000000000000000060000000000000000000000000000000000000000000000000000000000000003f00000000000000000000000000000000000000000000000000000000000007080000000000000000000000000000000000000000000000000000000000061a800000000000000000000000000000000000000000000000000000000000000003312d88cdb7cfd5fc5458d9a424da374cd818847f87fc4fb6eae2c3b97e541a6b81e108e55daf857b71514fb7213db7ba15bd6adc12253afc3c5e949144c13696faabe22d1b7ace91532134a5cc65bed9afdd897d6f84ad1b0b6da463bda8fde5000000000000000000000000000000000000000000000000000000000000000352c2a75f88112864819de485c392c349f718fc257934181c4d8ac8eb3a9b1fdd3b7bfb96496290f2b41fcd20fc8d29bd8e29be38550775dc97d21b17c2d679ad05f519787eb2c92a9a897c9f02f15316865cfeb4bcc2c0ba5ac2dc4aaab5c0c9","nonce":"0x3705a","to":"0x233a95ccebf3c9f934482c637c08b4015cdd6ddd","transactionIndex":"0x31","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x7e9247209bede2c21548c6e4f26e41d2636a2490e09ad062f9235e978094073d","s":"0x288d820793b48e55777e794f1694b1605d74dc8726fff438b481125f219eaec","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x6df2b54f23ed4e95235c6e21ada2cfff5a2615a6","gas":"0x5208","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x79b6df832bfbd04085d0b005a6e3ad8f00fc8717eed59280aa8107268b71e7e0","input":"0x","nonce":"0x17f","to":"0x6143d939b2d117f4b998d8d88a56eb0e0a1e9c31","transactionIndex":"0x32","value":"0x186cc6acd4b0000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xcb641be908976bc0a035b0b31a96039da9e63e829e0a24a092ecfbce7724b9c7","s":"0x4034e7dc4001cf9f62a2e5dc4390229655b85e9aac5a5b263278e9d2cb43abb2","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x3f5ceedd435b6143eba2254811a39fc3423f18dd","gas":"0x186a0","gasPrice":"0x82661bff8","maxFeePerGas":"0xaa246a58c","maxPriorityFeePerGas":"0x59682f00","hash":"0xcb2fb25d268f65dc9312e89bd3c328c9847a3c9da282026793c54a745f825ab5","input":"0xe9e05c420000000000000000000000003f5ceedd435b6143eba2254811a39fc3423f18dd000000000000000000000000000000000000000000000000001c6bf52634000000000000000000000000000000000000000000000000000000000000000186a0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000a00000000000000000000000000000000000000000000000000000000000000000","nonce":"0x0","to":"0xe93c8cd0d409341205a592f8c4ac1a5fe5585cfa","transactionIndex":"0x33","value":"0x1c6bf526340000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xa48a4ece6fbe881e342a4eda767c82097c3bd47dc70c09ef6a4e7f90c0f8e843","s":"0x66c92f16907488d115f5088ed8ff4d71c966232458479245bf6dae45358c0429","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xdb4f0eeb7c89b00118cc74de8c9ed55d65c2b933","gas":"0xb72e","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0xe483d4a36ad19fd5eacb7f6d9ad3ce080ad70ac673273e710f6e3d5acbc6559c","input":"0x095ea7b3000000000000000000000000805fe47d1fe7d86496753bb4b36206953c1ae66000000000000000000000000000000000000000000000000029a2241af62c0000","nonce":"0x120","to":"0xcc7bb2d219a0fc08033e130629c2b854b7ba9195","transactionIndex":"0x34","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x6d73169394cb6a9bceb2dcb16aacd261705096f50f30ffe146a09659e25dae48","s":"0x496a1cccf01ad2ae7094b8da2ce50c0a990baba6300625c48ca12c5f20005a64","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x9ac253db14a434cbe7653a99c5039648fa4f7353","gas":"0xb4f8","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x0564242c37d5013b671ef4864394cc0f3924c589f8aad64118223a9af2f164f6","input":"0x095ea7b300000000000000000000000028ac7dbbf9ed6ece39a902e76780fba60f1b2e3b000000000000000000000000000000000000000c9f2c9cd04674edea40000000","nonce":"0x4a","to":"0x0dece1605795461158538302b5f0936afe78c4db","transactionIndex":"0x35","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x15684c9697dcc8d89abe562c4315bfb959938fe7644c00615d9e147a4e496ff6","s":"0x7c58abea24e1fa8caeb73a70219b0d63007785c39694fe5ed2a5a342c99292a6","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x22496eece162f52d185c07524d452b9506e9fe12","gas":"0x186a0","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x48db358e80b278c3a46c2a166339797060a40f33984a5d974992cd9722139d5d","input":"0xe9e05c4200000000000000000000000022496eece162f52d185c07524d452b9506e9fe12000000000000000000000000000000000000000000000000001c6bf52634000000000000000000000000000000000000000000000000000000000000000186a0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000a00000000000000000000000000000000000000000000000000000000000000000","nonce":"0x0","to":"0xe93c8cd0d409341205a592f8c4ac1a5fe5585cfa","transactionIndex":"0x36","value":"0x1c6bf526340000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xa50e6ea1eff21fd33d69f8c74b90c28303b92ebc4a77c71b65c4c8bf3e92ac8c","s":"0x29af3bce2365578b76dc528917b44e96e4fe2e7a8f948eff3e379721f35664d8","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x9ce3f4210dc06889ad5267ef0ce3ded4bd96dc50","gas":"0x249f0","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x69d7758db91fae31fa35ecbed4d40897c5087f45dc796cd796b8ceead21f972e","input":"0x47e7ef2400000000000000000000000089f01bc9865324583380d8d7ed08b8046bffd7fd0000000000000000000000000000000000000000000000000de0b6b3a7640000","nonce":"0x1c","to":"0x6cf3df5d00e842aab1eb504bcf01ebf81646f7b7","transactionIndex":"0x37","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xeefc19e8dca874308c84712c3e48c032a25971a0f7dff16dc47633ba7a4f5b96","s":"0xc0994cf21d29cb0c5f1e666538b58d6dff3b9ba2aa7545337da732c4b5938cc","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xbd1c4e36842c06e53b378eca310cd2dc79a78cbe","gas":"0x35965","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x2951478916ecd27a8e808d08f85be4bf2c0b0e0546f21f4e309145dd96eb8df1","input":"0xab7d7969102507275d685f3f55d10ee45f7b9fa39c29a8a604a7a971c05eee739e63938500000000000000000000000000000000000000000000000000000000641cfd18","nonce":"0x252","to":"0x96e6192eeaf7bb308f79fb5017a9085754b9e12a","transactionIndex":"0x38","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x87fcffa38e0c84cf80fb37ac1e538faeca21462b0a9ec25af0ca0517af22789a","s":"0x72cffece99e79edb7425a9d660590fbc395cdd0db8fd4848074c85f814b3cf63","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x5dbcb3e489fbef1656dbbd7bc4848ed0e520a089","gas":"0x7a120","gasPrice":"0x82661bff8","maxFeePerGas":"0xc8d5e2427","maxPriorityFeePerGas":"0x59682f00","hash":"0xaca9028cb5d55bbf71b7bff9884a9a3b0b38a575ffc8f8807ce345cf8bd298ef","input":"0xc9807539000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000001a00000000000000000000000000000000000000000000000000000000000000200010100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001000000000000000000000000a7a9d91e687decaa6b045797c2e002d70001b48f03020003010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000600000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000002361273ef6f000000000000000000000000000000000000000000000000000002368a4faa14000000000000000000000000000000000000000000000000000002368a4faa1400000000000000000000000000000000000000000000000000000237b9042149000000000000000000000000000000000000000000000000000000000000000288e1b54f6e54124deb78bdb67cbfd0bf63612da12868fc281afc34bb26200a1771f9e00fce297da11cf49427becf350d0bd20a2277439fbb2e8db0fbb5e3d34700000000000000000000000000000000000000000000000000000000000000027d16a90ad0e1f8d924255e6380764fa7c7d46427c8e8ea19f5ba6a9d595297a340f141f74e705d0fe851d7564eba89fcde574deb5975d9126867cd927a0d92cc","nonce":"0x11d38","to":"0xbe57bac491de9a260abb6ba2c9ad4c5d2eaea09a","transactionIndex":"0x39","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x1eba7bf95bf63d02b74d20554af050eedd78ecfbe1a42ec70badb36ccfae4bfd","s":"0x4d7f8d0ac2be28e59374453f24ae6506a81707cc57f0d1c6877b49b3949a9a79","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x3079be9d8622173f02618ba2b793f00795d4f320","gas":"0xf848e","gasPrice":"0x7d9f6fbd8","maxFeePerGas":"0xd9a8cbe9a","maxPriorityFeePerGas":"0xcfd6ae0","hash":"0xc7f625a19ee41a1750eac9428b4394a9a2476b8ea2d31b4c2f9f5b4fcb86cae3","input":"0x2169f79f000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000fdce50000000000000000000000000000000000000000000000000000000000003f2000000000000000000000000000000000000000000000000000000000000001f579a43ce4f3e38c6a948f1ef3bf7954c2059b087b18fdb22c7b69d61727a5d2aa16090b4d1f3281bce660a31d3e2789eeb360192a54e3ac3513c5c8f67b7346fda957c92c1a2981bc68a47d0282e78df2fb63822f06f410e1ffbee7eb83c425122be9be94d817e2e42099632fb9eb5ce7c414cf6ce48e4ed2e64e46e1558ca809742159e841e3de803a8cdc628f7877bfa6d75af4b4ebb185e6d0670ce83332478137fec243a38c0a80d067c955cbe13103294dadfc8c356d0e7996cb62fb2c683e6dd5ad58be934f57375920142990074f8a161ad2390a1e6bea9fc3a58dc3f7e002e9952a68bff229437d3fb4cc1cd8097032b22c884868253d8f2f69c75ada0fbe1dd57145610ae5f451b47645718aca7432d8cd3193d0b96417df6638fd47062a1cb1f63636236fb72195e5a46d1b37f493b8380315e5bb1a6fe67cc6546d62f2c73aad5699e6ffa0d49ce653bcefa173fe0de7b4328aad75f74d15f4f570a1839514550d576e21b8d16c8355b770442f0740e6e5e77ab450ee1fadff8daeeb25a91585192fcd3cdd64dcb6a35e41ff47e854337ebd0923ce280cdacff2ced48eac96bc9f910391a44cfec243a8660ff80c10ff844ea22411953e0387f87d2c2ae81055fc8e87d59e04cd7a923d6aa5204b3eaaf5b842b5fd656e9fda16c59e90c64ef51124fb32f8e63442b1f79d3ba3c0cd5fb90895103719629857d5999b44aad2d69380f48dd824795a89dce14bb82600701ad8fa9bbb36fe93a97d75da26ffcb1a8828918e0293680ecb12e1b772fd98637a7a83cffbca1a994fc889ed0c0b20d447ff727b9f5dcb9a83e1aae9a3518dfe1d7ddab1da48310eaa7ab293d85dd9ca811bfdfee990459fa044c9a9fa6460e5ff7612e42021f16854d790710684663bb6a10ba475fa602b02519f03eb544fe486d9cdde47ab7d4027bfb8f29d778b3a7cc35a9f78dbb05943062efe3b388f1a8c496682a0215265b99fed0363a1061556a40e0539a6656b6cf8967c8fb3092a7fc9b56af124c8f1bd0abbb9af753884b22b333410d47d80c083c9fee52dda8907be0c87c5496f1fe9ac4bf4dd4f06d6ac0ac0cde22138b67bf782e8e9b5c991d58a2a828b4c68620e6d3d26abf8d41005a00866cb4095518b2711636f2fac3b5e26403ef96f5b1765519787ed74c6802b445de029d7bc696aeef5a2e605376aeda4f495c29af66e357c6e1232d7a2c3f22c0bae0c62372d6b2690e503804e2ad314c38a4ffc080d36213458f606075d32dc0a365087616e94a972bf76d7e5eb4a53292fd0d7570cb6fbb4540b3c5ee6deee0f257fe8703d5d8d0180d09754bd9a05894e77318b8c8fb6b4a56999bfc6c405c09d9ce7fe424812db5bf778d7d8634b2f44ad6d00f18615e4c3695d9c5965ba51991508405187275840a3f27cb3101a9742c49edf42dea79ae5418ada42dfe2042f931af15a205e64196b04ef53492a450423c2b63dc849ef72a166fac5f36b25c72d9cb4a2507d5ad15094a979b4ac4ff8eb4c90f448a81fc6dbfcf6a228675ab3308bca37bda8eda22b61ec7e596f2448ee6b7cb6eef589f43f28fc5444d1da3f82ddbe574b774719a3a7869e897e642735517832959ea9cb9164eb2f7665bca1d2e44e1093acc7088271f2be20459c383f5762303b553af1ccfb3371e4eef1f102ce70d62620c5164972facbfbe03b5018265ed62c4c3cc49522166913517e2f2718edb591047a72e818f07c645a18aed87c0384d180dc0bb7fe63bd335b1c09e58571b92e2267ffa5712a33e4a92231d9da7b005730f6d6559ee685edad9a9031c4708c8642c297287af3a3e637d9b5ac6b23218977cf4d30231a79063987f98313a2bc0ca4a73a97e441a45b58cdd8731fc269255b415a9d2ef2bb8a311587f39f6dc82f537cf86a68af19a68c409910f4dbebdfa66445361877a3bf551480d115d8768e8650e9979472a64802da3625cdbddee8f02678a3cc6400824d91b3c7d4c9274b74fb11a9538f1990fc314d35564a0cb0b384590e15cb93db1de1a837b9319828b3fd6b76f1d2bca4ac765f9ec4366905f2dca69a4c8c194cf0a5d821c58bd291e8dd4ddd829a873d093042c1b8e1bb2bb1a95e150c0a0d5c3369c4a791dfcfbc3e631da3d1e704214c3cf8318901f9c58465be78a870a040f34c567c27eb077db2d1ff825a127a038eb14c2890ff9a8a1dc8d6360a91fd788fec97599a318ab03f69bd50a5ece92d96c49413b517579ececf71371b6b1d902b1dbbf40c728c64fadf368582cc4b3c51712c8d6441c0c61802943624e93f9de9eedde87056c21ecf66b3a6977af0261ef48b4c6191ca7ea70d6acc5af910ebf247e2a4429c506c6a41f865175a9bfc81dbb69e59ec2c47370fcee9169b8749c852e7a1275c1278aa3f88bc16d311e58aa9a579ed7bed62f12b4c4dfe9c493cf33f979f667eda043c2aaaf863a747b208f3aa2ccc34f07b12d89bfd75b696a82c493e7eedcdc41eb01321ecfdcb691d14996c3ed7487b5f831436bb7c25876c4149cb6222dbee9e1a05771a8abfd0fd530266476e1bf69d9a15e99c901243585f56a77ef0e6c684a4d49417133ebb91f896176ec3a8f0b966eaffce96f129d18960fdbf5917f8aa0926d52c57192f99e55959369e57ce85ae84ad944e40652f6a81ab8da1dbe81a827366b8b8d2ffb9c7b93087f7a356a16d0022ee8ae891060e29ff11f9f17b01f39b8024baefc8b928a6816309a5c3fc92ed6007499353b5f1bc5700d5fe67f3e34ef3654712b9c67c231f30dff485213b94c20afaa91540560df80ba9ff1cc0f6ea75bf1dac0566551050873c112478f3fce6af162397161e1b41e1ca295f327a4f0ccf4d15fbe58e20a23698bdc25c751d020df371cd1fc59fa51dbf7ad619d208d7084c5752984b5fd0e3a7978f2c11e6b26531fe03c0cb85519483d668bf1dc4dce24509b00aa6e146adb49f31c2c937a2d3a08f1cc0b73cd66f2cb926f0453cf78618e39cbfccd6e6a3b4909d6874872eefed0e395ac2582d8c1d0483007fa6ed7b735323fe8fa1c4be83c725c6b743f63cbd0d6017f1145634b0b905552a2a237561b37c415146d0555a276b4b45d515ed7dab942f9bf40a26d5366032f23fc5fad8b98a1625a841c8cc97dfe0e2074a363a951946df16d1261ef6b2da7f5789dada153448b076637f9d2e04f4390e9dd32fd5e9ab3f5939807bb451bd19d962403da9dd118f1cfa91731973bc721e5ae4a687bb2270e3e76966dd2156e95796d4bfa6b4c10caaee46e1d8f8495f901cfc241c6f9a690349eb0752adb220996ebb95ed26ef376dbb9eea201906a6a3eb346c64eba3c9e4d1b3088baa0ed868cdaf063a4c2434b9d1bbbd69f44ef659262fad9535988ce729aadafcfc6c3ff741dbf8b784b3465fb05f6d5daec91e915f89117e01c9b0c99d7b7cb78e44f5c28de0d3b782de981be058ffa1294072c4e5a66d2d81641d1c07a9a04012f9f1ad15028709fba761a659becf01963de0cc42b0e16bc5432cffa00722a84628373198dbbe75f209115c4e30e60297c2d737996dd9aac330f4a3e82609dd33460438026ae287c172af8aeed0d6c71b1f9470d60588ebd365f20d596999d97c7a6f265890c719dfe43ae1ee5bba122d9d4cfc96b399f610a90606add4f0d25b903c7ddf6eb7bfdc3b9f926243108f591678b0e92a48d52b1dbcdf30ef8af74cfe34d48d0e02d0f99af2adb090c489d4214f3562d3f6a6e9b83b54bb6cfe6c1961ecd2eb2b7eda63601c835c5dc696b32bc495bda9b6567984f83e79a9d4ee88b140dc78cdb64a2ba8761a827cdc8d2b27e690c22402178ade602f2e9092a1b07d56d142bd24d665d7b10bc7646eb6d6823d5622f1fb08f2e48b8deda6cde324d6508fc428e3bf1a9ed608c196786db4e8d6b7271a07e4f73d9ef76244e3e10aa13fd9b82ce2ce72af2df7faaecaf95d885e64bcae16f9b59ab8e0f21a2f459d00a290b0dc57e10bf21ce06a029224ae15cb86bb1cf060ddccb1f6ae82d767eb077fa4ab0f37d02a4bede5d3f8ee3972a6a3a438a3cd92ffd6c1fb11cf2c68c2c6d1efff62b9f769e302f6c5eec96b0c05a942321ef8b9cf0ff2bb80073a8fe138bac5bd8e93f3b27e7ec7a78512059fa37b0b6939f3b1311cb6ea154909e9d316567e013df315e8f02a80e17feb8f3248cc3f11d1253ef3156d7f12d1f6d7a382d6b6ac6abd38fdb5d954e13ce005ce16bd5625a5df01883409f4ab938a59a75b7a816af6a2447b2c65ea55c0ec4e4f23fde145a26ef0b13b740b352809c10b54bfdf30592a8b0d507cb8210391d66d6f68d06f3a4663756697d472adb6ba78976b423ad9ccb3a3bead9de51e324fb77609729c78664f4d37c7c748ad9fad95af355be4f00a76cd5cc2c0b6170fdf3efaa2571bc8fc2d0d24682fec5e034460de55cd0426b8ad448551032e1f6ade6d96682bc38a92c296e5bdbf42fcf106d14c5e8a4acbfc0cc1f0bd6877c4469be8b204ffd5d7c0ee85e7b3265011ad5e4896f9f8a69997e321a797549cd3c1cbb0301ff30c3a136068ba37b2176e556b574a542db90250eca38f3b0e418e352b5728206d6d531ea253d781d771ad974b476a045ff14718d9a1820fb469e981c7b71ae8fe423b0a04278bcfc967ca602254de37751127fe3716456df3fae50ed508e529c2181d63479b6464bfcde6629e8179f8d5fa5b61003edfc2f129affa58608d6145de98ca8f1c0b3b9b5ae996a7fbc6326a9ac2880206fbeb1c99d0448cd1ac5f275b84e4be03258f9fd0d3f44a692513957fa083a462086787315e38aec8c09b96cca034cc6294359fe00285c607d41fb4e3bf25760ed1ef0802bcc40b2fce2cfe1c64f7c34b21d0bb1f5210360079ca8638ab42943b0ab8277f1cfb1e529073d2068a36a4d8ae8179c32bf66ca335d698f76db1cfe5236e6427e01804464c1ed4facf18ae09148c5a0cc9ebcf6fb6c7d03ec6782b7595816245ac2d1fdb3184ea49800d5d0f1dd880ff99d6016549d63ba2a44ab96f0db0d0cbd5fd4f67af1f1da0b1023883d4b2e7cb23cf85c617c180a771267fe63c70f19eee28fdc50c57d73b2718f8001383135b859f4c2fa3b9a12d095beba8857df13e921d9dcda5b87e1fce6038fc2f92282c717305157b6fca5ca2c23cb7307a093512f985628e75326e0bca2c4dc5ed44bed8e0cbce1238f4023089a81bf62b04a31539de9c8a0c867b791c18a34abcc721c0e90a1604e8d2855e78673367ce463307f6036850b81e0aadc9f81d8c9ad6e3b81d7850d4a46bd6772e651e03581a7a55568c9d63c1b1e8ca947174d68afcae6401b75dc7397be3c0dd76ad1827424f9ea9de8ac99803641535dae3eb57ee1eb1e2c193bf66addd488da55055bcf93172b1966364db4412e44bde64c50f7692a38d1536683af14fa057569cc7ef11f614a58995ade1b12f979005a53bee0769847deceab4f58f3d062767f7ac0511a04fea349e7688ab26425cfc369127325ab7fd24d73c4a8b23f099892b3bf52f35f0d775ba753098611ce35c56873a7455737a42672747bcfa99da8c8d0f06d8754d2babe3eb303cb06ce69e4046541ce63b6c28ded5a6fbf729200060132e9b01d8646b512356c92d8a642de0f62d169b195cc2e7ea2efebe550b1cddb5df7668a0d1f94a2f5cdf7897e46cb03b958ad906393c7d252b58493ce6c7d813c8fdfd5ef577a9e778c64d48c21b130c4f6a57985b8122f3cb69de015081cd3e247de65643f9d863fac6935cffb2ca23083d4fca9b8707679d9d4c3cb34d05d092334b1740ccf4b2aeae724902ad4fb4bceaa642b3ffdd5b564d7bfb725fae91f5c7ab9583abc2d80afd2272b14ec6fafbc51e35bebecce63bd95fa3f39e4e689034c47628345c4d8e30a73c36d87d289b6ec715a2769efacf39c9f19eefdb311b9800377c5c61aadeac78dba6946da4e7914415eced875b66f10b96ec98f64e58320bff09e8ac4f5969608171dbd4ab5883548a289b52d55aa82da62ba3d9fa59734d8f810bc1a40a0e3b2e116873116fdd8bad95471f16a14054fe247637febb6081d00e7ded3019ec03f76ebef5401a27f380fbe8a55bb4a0014f61276d9aa5626a34e7fe5a129a75ff130ccfd78cfbde65416882ce9ae9da57a3a04c67d22d3a12e811b2578fce5f6a64a09a86782bc15e5872e546dcca46bd9ccce5b787d17c70d6b075bf4c789ca184dedad3485a0526a61d280dcecd984fcb7ec663f8f491e91253675877987433e11b9cfcb5940a1357b55fcc5f977fc898f72e8199ed5d8d2554d54a55d6b4b3726e7fd7093996e271e218533f3b31257aa989f5efbdb12dce02d18a5188ec32c3c1c91845a17011ffede3f060f19d59b6565a352e90c5ca30eb252c6fb0cc845833e553f0bbe1822b5d6b26eb817608799b5b77c2cce27beb151060261f34ea73db94bb2fee11864aff76da5b10b17aba6634ae655dd396fd7e7155013fe3c6f840ab1ba9b25489c67f6bd5967a62134b238c325986c87aa005396c54af6357ca88baf5a03e353c8b0175386157d9221833585921d581f1fd3f5d9932b24d41895a5c35be91b35643e7091a7585ede900853aebc260b1fbe8b72d527390ddf46472f7c8d5844355ffc0b731dd5e584e13d65f2347131ba8a5161a6749458c1899b60cf9f9f8810889fc23b5d0fe2c843fb5675cfac6dc8ec8125d1c582186eac82d5e0b3f6df2a83eb2fc23c4c3f873267deb5ea86dcf1e3c5bb39df23f06560609b9fbd89511281fc7d69fb19764c41168a539b44f0603a52577c266fd601c0cc849b067746b4da78d280385ef80a3a553dabe4b137c50152f4e1de456d43e015e26f7d76e612b7be29b9f8e15c6a73653f5f7dc28aa245e64f076130bad58bbbd3b024c97e267a96365f019846d965c037116c74ef18415ed5500f12a1816997895f3bbe7b0fa1eb12a565255a64d5eceb2272027e45ecb0a1a8b5dc99128c002058c569076371703e1f10368c6cfb830ae8bc688eb143da7a1780dbe29cc4c83743b25d570f5d8609df46c807edbbc96358cde9ed0d9b8936271b3ade28001a6bfa6ff7ffeb4e6a6687e803b5e8f67b82e6dff215ee4f2caee571b8febeeff368a89539d145842526fef110174ba3a2d9f1b4a348dd25dd964efcf88847d3eef1c18fde81ce84b80cca8588bc1fbf9c9f34059808d3eef3fc2cef7636f7a76c533933b79a9dd2ae2791d1ab5e1e715837a766d9df1947d5986c21808eac758461596870b744a6a2862f7f5bff0c7a3460875b3b326e45fcec1cdad1cb4b99085748d69a62320f7e6c53c061a55ae20368a4e6cfc126cf2c0b410af545f169fcc741cfcec4947f577a1bfad47b5080ecb41760b5056a9bd10a10ca43677de0e06bf36b0d2bf7ca605b9217240871ed1ce43bbd07a7e77d1901dde15e173ca344ee8078ff115e954a2fa660bd4af61ac32256fa7d62af17a4f95adbdcd09b933fa47828d91a6b710a5c67195797bc789647db90107fb527b8ccbc1200bac302dc47a366d170314f5fd7b60535130d76832ab7a06ebcd83d064c1a1c5a7386b0945d39f8ddfc3503415ea22514a0ebd0ad74e3ece5508d83355cba944b12b669d6355a6143921533190eaeda0337a1b89ff9db0cae62a239025bef078137362db71a9eaa6d0a26fcda7e80a9b8fa4a1799819f0489b899cba4048c999fda79e0bb046d7e765d9abb445279efd13d47fde8b731a944af92da8d8965bc4e90d9da8ba0a9c385357e16788cfb663573d9d34810c754e86e3293a868461b241d7872911e676e73136557db1261573962221589850fa5ce049d2356e6630a142427a2cb2efecfed09445edd112323f0071f63f6a42035a9248efe155aae056db25b8004204d530d27027c34eb6937a5a05bd2096eeb1fa266a0325cbc7ac03270b751013b53429aa2d8da2de8c12e7d4996b5f1dd365e270285d2f3a65bdeea9346d960ecf015215a88f465a66417d12d95be2c0bb3d8e15163e0dc66028a30f1f5506558ef534ab28cf6dc2b7d12f49b0e319995efbde71978ef7121df58bbd16be908298b0abb6197bec22c598413283e7893f0fa7398369b83d30b29560ad09a0a24e029d0c22a7cc6fe53d84a7b2104681df35cf4c3ffd90b14cacb2ebbb673ddbbba291feae96498b30d024398676107d3efdce47353a544c9d885cd5cae19588a4b9e29c700c539bbcc119926e3d1adcbf4e8fa3dfb0d5c2686a3fb4ae7b4b278fd94db5efcad7f280488702d9f7675aafd248960806df3e8f95325298968a8e7bf54cd2797decb5bbea7bd3cbe34081c0b65ca9a4d0d08d86ff39f97751471e09f25b486dddfb2975edd51ec77d949862dd4a658ec974b8a5a381ca5b7314b677c4491e07b43a5a9964d95e1a29fc1d87cbf1a64296f4cbd8128ab13dcb60dfa8593a575140f5a9fa6a3708052b3bbed4b129aea88e66b72e583f1fc285ed6f835df0d4751c5d5f004ee0c65203ba9fbd8ff70fc255e497748f24c476d18c94089bcab8ae3f933563c6682e5452da8f760943c7efa631b2980e6589ad4ee83c88fe0b2ed9900571c3df6bac839df1a6d9d281a5ff627d41ada13b867735aa7377386182b1b113f237c14b6d806079d2f7c234a7cb585e12a5b16f7064fccff99386d58f91d9c235eef730660a02ad37dcfb0352b1da76d739ba7bd4982cbb8be48494acab84451bb39bc59521c9873ec9f53cedb527332c47afd919c94d777e603b405e8563248c9ca72f3b2fb52f08a876778d18e7d179f6437b64f79ca01f6be06d7b115b8d3c3320c2dc0ac59c860aca8c92407ca2239998613f44945bbe2c6a0ef0890ceb27467d1ab805ec960e6e58e49678a0841823632f62c58f540f19e82bf719e12bdc63db5363fc0749877539865a05786106b58dcf50bbdd015893b043b21bc1f24ef9eee5f2487d986db13c143d3366260ade522ab824fe82218daafe5e42c50ef740cb9ac570a13cb55fc30c9017228f2c60680f75ca89affdd376ce70ca5223078a47da0aab9bd18333c14aa021e6c088609d7a2460744006f149b648116152e7c814a5730bedeb6ebb59fe395e6b15d379909f197c4703dff34f8915b26a36e30088cb227fc1df108560fce419f462181e468b5d94251fe1373e0dd004fad02d690f8f28bd972e85ec49485cfcdba717db66e6a343044a2453ceb6403fa0795485f8014225d283da4c3aa6fcbbbdd6b04c30c96fce04579578882a44fe7b781285daa11ee71239c1b69791b8fe45868fe6e85341b7ba4292d6da1ae079875b33d7aa2becb02327a17bf2d09f6a42e9681df41890f17de5cf4752880660a35dab912d10480f20f92589d52ef4780ec28920d11de0de06bf63d61829a3d0894f9a32f911ac79041ef51fbcdf3f5b03f6a0b16f0b9e47444b82efa7c012e3bb9324c8649053433306d0640ae953737336cebe9b854186f9dbfda861fd7eedd76fc24634acb9cb925302d0bfd3751b7b6bab36ebe2ea80cb7c5359a505689ed5642118ce93cd783c80a2cf050f57d5acb62853367ac606fc1b8a01abb7b29e49fdb190e2b586e249639889bcf5ad23161f278086f244d0db0f9ff520e6858b68f5bfa0f5ca700096277ddfbcd14a4cf4358c0f042b1eb34bca6353a1383f5d310176262ba45512ea4f172f321efe971c391fa9e9876a250ab653fd6d5a8b046028018ae043da256b78eb26d86e6e89873476ae24dad26ec1d39da44ffdcd93d8c5c1fe0796bd46dbe9b01be0aeae841662c10ea28cbfbef76f0197cee86dd4c7dae3ba46d5c2884ae977c456681d5d9859d854a3e0708bc35fd8415c22ef4cb889bf0e66da72ebc635b71f5df04db801c76564d2fbd946ac17e27fbf995994ad26c3d577ac86b3b19f855d87bf3f0f7c3fd574b89901732dfacf2e13960975176f7418893b31747d96bd981e9b1463590bd35b51b7a2eacf1a7733f76a7d4b02fa2afc5925f5483f82cb529682f785c21cb951d5678a7d09f99c0e2bd98948b79456e4e0b5d9de80943f1df0c639ab8acd6c99a6297cc5a53a829561a6615c6c44b24a30a75174aac207a35fc429e1a415b0813857ed85ab49db6e523cdf9b122c2442a4fc2b4fc21685c9c4a5de8f36c0b405e34ddee91832cc6567d458ab76b4650020d270a65a562e75e06a3d8f1313b4d1d4d29d597bae9eee653bf8e31b82f9cad2d0848ed5daff73d99472c7e71d2f1be60bca4ee9d315196c096cd8260192597c8ce3cefa9cb6f129dcfbcbd65b5b0e19df5a1e81bdd423a2e26d11ca4f7aee99104530c1c8e3b1150669f16acf415559a38cb27eb6d637c78b1c90ddb5eef14ab9b2ff14ddababd7a349b7f6f5b6caa3a28c45835c9beaf8f836848f579598ae80ff9af739cdd800c5a3d7675c780ad66b2c449824d8ccf55a7669fb720604eeab427a0308122c3039ef9be6df46e34b719aca7a001b884e3f7b1d1579176aa4d365a25b6f3d420190e3cd9babefd8382b6bb12b4c38b981b08b5a139cd46e9382c01f361abdac7fb16b87e2c61f3241191028c770c3e3be939c8825c63bc4e523b389d1ee28189b5a2c11ccbe0aa7d3c2b47443028c89f3d4bc1bcac39eb61d91e75e0d372b9f27c8dc622a86bc0cc0a9c9dafa5e2bc67834a75805f3bf1571fbc5528e4c69f3e64ed27c1f2d93f43215ea0d4213bf2809391b8b9201f36ee2a275dc7c44d0d83de3b82490b65d2b399a7348133c4df7ef40e6dcc114d040f65de00a70cc0c9fe615c6fa90a2fad6dbcb39370af043345ebd9d8af094c831f341fa5f7658c2c1ea062948fef5015696eddd181d87dea49ac8bbcc2c7a1ea01ba1d04239153ca401bdc27aa87093a78b2020109d7cbdd39f279a7d67b14a5822fae28854323a2620033a5fcf9817a0d45eca7e2d120a113fd5ccd9fc0011e89398767f7f6b7d01d5a670b4fcb9c5648991817a62edf43d6964de204541a8b5573d7cc10bacaa1bb835f87d12985ad5fc6ac4834ce76c76e5dc34cc322c4220d9d65ca77051e7c1d4edcfb4595db16c641fa445401c72a24e36567631ea02e4875b7f9ac2ddb4712b79d1468c7ed2384ad5d90ea0825f817e42413de33eb30861ac92e19b1aada118beaddb179399008137f28a8f3df1509ab12d6f6ce7872521f5cfe4738722fdb410b3824f139ccf8ea63817d154b1e497a70e6f55b75e4decb73d10ddb0c57d7e0f74b3f4fb41ee57c2da1e4399c2577f28b7e911db08e877c366f231114cc9553c7f3cda2b75895fb60ce9eef4e0c25d253f689dff5e4f9cdc744c301b6f13e9fa9e30bdba8abc203c05879ff01bf8c3a3aa742ea5fffabbd6d165e50bc412bf5e18c60bbdd4fdb276f3bbfef246cfe36612ad61fcbd4498c18321a1ee12e6dee902c737999f9c6b3919f52125cc77e237a788640f262ab76d5c9db9ceb2d988c261dca63455658293b10842ee0b30cc1f928215e0308cf258ee39ba666b16319d0e21df8b9ed91be2e2feb9e117682cdc9edbc20b0b3b9ddaa93ec7a2d8f752ebaae57b7d74037c5cd64cb04746a38c0ea3ba3241319360e585c257fb593c123a653e6e0420fc540bcc0f072de6ae1a31b57dd5acf0b8607e04d21b727c93623e5227202a7c6432b308f74266dd1e1447a2d637a5259fdcd1d8729f341a7dc383b4c8a6ae0e78c34a55793043d2dddbbca1d161c300a8a7cb760298541c90a1c5a890b5257369b8fea0b4d14dc0848e644953cfd5196494e4c1b422f8e188314f2fa903fe93393193e9b76bb71c0caddba43d8586d72657a2d717e4b2c3a0e8bc33a6f8d89b871244eb04e4ecee26f9b71ae7d5c44f828083b0c1920d37cb5d7db86be3b18ef16653863762939cd1ab5c5e0cd1c495ebd0a3037725470d526bf12d21c2fbf4946ec224619c79906e8c87f0699be8a3621ae718aa232e26e43bf7cace7918ce34577a5e27261a4a6bdbbb8ac21a8a40b0c9682a0e0a37b7fc43306820b0db5fb5bbeed529102187fc3e5019185588d1ca6222a5e2b60faa2a93857bd7224e1e1c3c86128fd16993aaacaa34d8679e194ac0da6bf617144a2b1e844e7f6f8884df05ce1624ef1fe5d0895265bef2de61d637a74f78f6e3402923c9363656b7b91131dfc8f8f7360d14e01a25869f0f15a9355c07bba82e4969f5643519611d99ee9566138e4610712d55f22ad36c7acdc9e32b4e1e9b1ee9bd14ca122db05938840b8f47a5fd25a26072e2055494eb4ba916473e973c1efcef8dd7f0f04711b7e968d59d144fc04b9c6d8f951ab973441a6086ab6ab896f4d282793fb14c74322c7ff1c4c1c6d0544b7457635a6fe2632644344b1fabe12633b2f7d8fcb6e0929a05aeb2749fbc99671283c47c0eabe152fb6215bbc6e03d61b1ae955838a8b7b3bfa883a04f5156982ba433dcb21311fe9027a5b2e133cce16ac15786d2d44b5e4979cf2a8667d2976ea386eef4c85bcebc39b9d2dd216e8b4f7c68b7e0a5d7ff570770a20cc605e66470d995ef96f1e0acf6136716cd8a26b3b725db3ff48364f19cb2c640600d00d0d728d8fdac7b8a205ba8109318eb5519ee03848e79a1c33898555b298aa62d6da66188506638918b46926a99ebfccb649cd6bea1eb87fa6c1999a70937f51c4a2d485c6aa2bb5f98b1c8ae558e82287b9f34ad70954f8dbf3a9736604c43bc3062f8707fe88483b0865bd6df65f7e085593d5046554ee465a10ddb0c0b651e2b1031d56f5130e100e4544809a093026b88277e4e1f1e3aa40997871ced6e6eca44f183ee09ca679e4fb0796af62cec931c553ea788e75fd37ced477f9a58e54410c513fa79a4b5552b049fffd7d261d90a16f253a0782ec75219d1f7492ac2a242fc04c0216e6c804f8fd8f761a70eb747e1545313706136b085fc72dff1714ced89ba14a65a34168dc0e997ea8718ff304a962cbe8c7df8b759d76eb0f18155e49822d21d91dc8913c323a824da271f8c57d44a27be3f04991e2a47e5c8da2f0d71610be89dd4459b9a9f5cd4bb5ebf730a72617613667984d9a0e0ccf81c803e46425899b2fffe9158f9e3d7c36c2c42938d9433f764ed1f6d9c7d69e9ebf854db44c398c00b2612cdf19927de8bf45df70a5d4307e3a628a88a09a79d4e03742f89363d891b241383887b4447d0cf3e0eebe4a9143cd6873abfe2993b1f4d1b3b3a18aae4db4465385500ebef246adf17f1d9196f78749dba2b12deecc5c957e022f5b9dfcc3536bfd306a1a70e50f7bab1db22e98c8705328fedf3686938eccea04e7db4abfbdd939d56c0c357612ee3536356c0f5bbf1d428fb31c7b06a75c5b4fd5b020e6d9894b50eaf1df723131712344888adb5a0b4c07d23f6e853c88b51fcd56beefa721557256bd9978caca155db7f9c325f9564479c39b589431ee7d5da402e79ee6e04061c62c1f369176f6b35174b65a978ae3a4e8a25032d987dbaa5ca048734cc1da5f875f72db399df6e6a300db183e96ade56ecae019c4559c8f7c94899178c98e5071aece48a3e9f5a795159b2dfd0a1aa784b263ae5d352a890b7c2c6887d76f0364e2028d4f9046408e76efd6b5092590d39ec343facb16ccfc0000bfe7bebca2575b1f02c8a0aaaf5fb0bb13ac3246e245ace99f2186160a12792fabc0b390cb4c32f87c46f741c8fc940c4aa7843d650f90d422504bf97dd4825e533f646c6b77c4f004b7036b5480b587a913f05bb8ee470f0ab148727835b1659d8c046fd24276c95d30158424914e75d9b01fe52b34d5f76b2a1c98bc5236945fb46724e02851d46aca237fbf047f3055d6331dccab91c0bc20be2260086552fa7c958840843a3c38acfb24f9dcb506ee3cfc67f3125954d9090c1fcd629d1c3fc557b7d6ab33b9369ebc8b5b43f9e23673f688ffe50e6c3dfb12ac58aac60590991c9ce68502873fbdea04455459f6ee721570a87f87ae03a9f97f6e457ce1447358d8e3453632618701d62885ec4f8dd201e26405499dd7f317a8d2456940348827a08950d548b5c0b24cf494eb76dd0a51e3f5c6fda9f8f6545e3a6d1009775d78720f9b20ddded15c162f226873162a5076bc0cfc151e655e29d100b7a0d32c9c783375d1c6af0f39b51d927442386cc2c26337cbe5f4a34bfbb65b544b50b4947f72d839e6255a95fc859d6f1e34bb63dbfae1469be613472f22cbc703468d8552b9c691c829bdaf0d2e7e4093e940398f9ab8837baad8d9e4c710e4584685df01ea15ed9ed95ba9f6420e5766363e86ab8dfd1626eb1c7d2dba91d360821da99977be4642488972ec61fce7d754dd45a4d7fd9fc3498a6b7e0b7235c7843dfe8980bbd3a52c8868c1832f62d9e25a40986d061d7ca9d8fe29c7f234e3448fa315d749a09cf29556060307b970e5e080e90dcdbec4ecab1a7868cc5bad1037c07e17f961f3cb5641405f3d3c1439596a243f83b4f8576019712320ccc40581bf02a0788e3ad9cf4c44113d47f587e96061c61c06be84f6e35711d105f0c46b31f036356f6abd329c4e1e74f7d97ae6e4e0879be998a85257b6de6277d9c18980208e83d9bf266c9909a26f3e19941e728fe4ab0866d103644fd86b203029271361ea97fa93079ff227861aceb55e68d7454d1dc25aa8a7c780590a04756c840d13dfbde1d52d7df47d4146ed8d530907fcb13f6071e5c18acfd0a694938bca6cb081b7dbef2a646aaf55d4da9f3d42996a90655cb48144a4dd2789d75692530dc02a2635c26d428f2c6b66779bd9facebcd73274ebf333b8de26609bedad5739e73ed68798cf9882ebcb12902bed483bd905b92b3df495e708a0914a96840761da66379d85105f29e14e47a3e5273cc23ef5053077ecc513363379d2e6cb3aed80098589032cab7c20eeaaeb7bdae7e3a1c7a704cda4568138ce1ed94e944eb4ea72120ec91117338d0c86116db36f3807a70bcd98de03cc46ae9dd0c5fd3b26d78fed5a8b53c0c8f9566f921175fd193ec521c9914be68f2864715a572cd6b25948fb8dfbd75f4315967d5a6a707f1ceb81b98972e615d3e81b08ad5ef1838af673af9b6d63dccc226eda6d0b6fc1fd104f62b80662ff157999d7508f625fa2408b6f9ab4deb410ebef73750dca3e63d5045300d9b52845afc42f064bd78ce574ba9b4fce22aa3158bd058772ac2eadbf9fc77bfdf85dc745b529e8baf248a0bc1963f8fad78471116b9ac11679a326e92d87e03e316c90d15d2f9e3921e0bb6ab4b7ce91f12e7cdcd9dd141b8ef160e5db1faa47525a77a038558abd98757ac5f6313afb4f4c84b2c768e456f6de4a78b5b25f90926352fbfe83037f81b31251249fe52860f3cfa7ae1b20c73acb015821840dde2ff2de0470450b11aed7c1f84d4020147f8b9aeed4a37909bbb63508e533f939f23c2f5952ba6734745c51b837b72a398a4eb8dd6b4ee7648ecb55799cee7b6385ecb0b2e36b9518439ba550b257230885b83f72312e53afce7e7670b26342e4eb0a6286c0693c54abceaed1811418a9a289b4b09b65e84b3149cada8114e830c0403884ffb74c515bac074e4a981c61447ac99368dbe9cab8830911ba9cbb64633f444716f401aa17f599174581538918e88cd255765142a49412841deb528f44a64acb372498bd66f979d9189fa0f0e70e305015dcd3c9aea085cb0f1d79a63e92eb39b2dd2fb1b9ee9aec0213f3a4a848f3450e4a6d902f5435e234588ce4a7d2c9dbf60de27227ff02ee4ca19314d72674fb06c00ac7e5d15cd05fb35e973f0974a4718ea9b0d35bb4064a6280b654a15a7188c5d5a5998ba1f031a3baecdf7b608169c0ede84d91c9a5f73b0176e5ab2958169ccc6022e0c43481bb8e6217ddb1bd9ba8e8446aebed6afd163dbb6873d81afcb74b034085afec0d626b02fb10839bdf2279acec3d8f3f7c47fcc3ddc8cf1f08de8c8e120d9c06648acbd1ba6824ff74419776b73b05d797a0bc43d77eb75029112380ff4e87e543863ae29065e40c1b2b1b2d62a409a299ee5868036835627dacf4f9f7c84fd2f6707d823eebca0e8ceb2bd258038b137aaf43e0e937be762be5d3a6545e439a45090d397c8d4a068286836780536ad99cb138cbdc6fe5e9db3bd405ae6eb86084be3a49c8af88682dd52a5fa8f7fdad76cc0b452b3c37b27dc3cf66c57a4ae59a3687950ad3f1fdab3002fb2281365348cfcd9306583eb79a9555e8750dc95260a1b277c566babda92cf2b3ef177854fcc3dbac88da1536eb3c6d6fa3e336ed3a7a6da006901c845619fa00596af8e54bc1980aec4aa97bc98266c248bc038013020fdd128db0b9425e8f7e3165f5b9190fbf2dae5e317485d9d103695cd209d5d247ac7e1122bee4538b5b74790277ecfd2051e43a34b7c5440d1198a1875a0501eb3f519ac2f17553c5e99a9c83412200a519251d4d4ed1c84baecf7d8cfbfe4a7e50d789cc034a21043fc13fc3150314bd7a7801bf9c31aa00b7cbd9d0fa4ef0636504f0dab63316d9b9a1f4703b3be23170549fa3a29ec02f418d687589f77939fe068e41abce460fe118b04fd418f28edba4fe70d8fd24b38078a5c47ea236d73610ea116666a49acec52fbd810bb99af1dc5bfc4eaa634dbf2178151acc453f93567f015f2a25002eebc1f778da195b7e9cf683db1a85da98a99d98614f2c25b2237d4393f5799d06cd36254d3f22a53df5133cb1f43836991d3f7529cd260df88bc47e4172ab045b66e081940dff797b28c632898140425c3f81a60236b82522c0da7f0e0ec7a8ccdc73cee175d3b4543293135c31c0e0c926c7506920cea1d0a1eed64ede7572b8c77ade1d95bce10dfa69fab7fb5ba64055800593465dd4c26717e37a66089f550202a0530157e5274f3d3fdae187444f5ed641c608643eee1b361d78c9ed8070a85150c80368a84b14c9dba5b20a9059f1a05a60de938ab914a093b2e741e891c02f638c73c730e60ef8cb5d9e5031fdaf6918750f192ea7a76e035eb05d7556ad64a77109c5e13bb3ac7627d99165567dfbcfb7fdc7bd847ee7dedd7864353f8fdb7a9939867d9a5ff4d9ec9727fd432d8abb43628519cdb6fa49ce49064a421a89bc924cf6286fdec8bea6b5a7b8eb606f584d44c7194d5424f98576dc4b5ce7dccf65509727ed52f8d7210095252403023473af96eb5892cd3881f2e1f4dedd4c9b0755b70776aedead14e2606bbc1ea3c300984ebf27ca69f36beb03c0fe3c13d9df79791d828d52260103be72b832ba235bf1165250b608e2cbda0c9c8d3c96534802534080b2a4ddd5be4f269f37c4cde9d43dbb42fef8d507cce8b8e2eed799c72a2fb836f4160b5e5729192f088ab8557d51b58940065ceb4b48fec1873cc4b178166d15d441f45625f45af62c1d13863feaa8afc320bb36af0d151165c122a47d4306d075b344974835363818009d86c81e90345cf4b7d81786c40318a371fbedcfc325cf0e853fdfe6e91e99c07dc9430c04e6069b9e2efeed0eccfb161ca85d96298ae6dd67c395b78668d5818f567f2039111a7a0c52a21d84ef72dedbabe83f811184a95976b1a90dba5aca60d0313c546ea97d7b2e40b34ae88ccf4f45e28f05f16732d7a0d62dfd86e40a51de7f2b9b66ed780476cebeca547c8eb71ac20a245b1bf7445e64bce260b8871ead95f708974c3a93dcc4ee979975daa399055108854c1c3fe5a07046d13169c084b2e4e81821ff73d5d20e7556f40fa152226a6da48d5f86cfcf1a5520451c3c1e534db654b1a58adea167ffeea90023cc2b0b01710323177059e1c610154cb234d5ea165dcaebdc2fd9d9b66413b8a6848ea11a673f207ad76bd3ab5399dc0ed58a3ac0ac9d3c53781c36415d54b452a4a78e1eaa7046d062e3105541fec8819439da85ce53aa683aaed543704aa8210b26c1e6c8f1d1814595e3bce2d98a36089bd722110bcefd651937892ffd36dbc34f1284eb32c49a1c134ad460c19e01b3f3f2d40f664d90020ae8c546bba9ccf5500171ad07a55f9fd299d7518f00c0017f6c25d4aa01615fc7eec160ac2cc1ecd38bb0324e54cb466c3df4d56508f5239e1b392a50a8c20946a6db9220088d77c494406296921e3ac9997c34f15fc5c39f2529eb2bf6b41b0415e90cc9d7e8a83256cc59b4607be49eb76a7dc07c1ce3d0512888705c9ea145079085273f2236d5bb151dbe7d1bda2ed607fe51847ba09ea6431dcae727ec1ef0a201b8df9e148885e1308425d5c7fde473e90b4382de8bf5e215c3be357f8a2356348bab00a2b629dee017ecbd76d7ebd45fe4df2884e34ecbb86ea371fca29496fd05327c3b985a069a24a32380ac9e4b131ff48d58b1c528b941dc6290cbb41ab4aad2a55e5e03a63813c2113c0740029529eca008d906dcda1094571f5d2cd31ed79e9bca8e815e206b3ff3a7b4b82b0d30775e0b77260a42b1ccd0a58a91f0378df95cfc7f8dcabcabd2d7ae3b603e9061c1e126d00fde94b4b625e953b6b781da167c71a6a7ce0792e7de070863deaff94d74a7ab9dd2e3d39519a6c5c864036f7bcd4663fecd163d78a72a74d2838b6949eb7ba85dacb2eecbff1af2792047b036f77d488e5256ea16252257bdbdc1ca3d18d01c5de00ae8ce7d1c4cf103b2bd7a31dd52fa92d945da38eb9070d6f11aa9cb8bfaebe133cdd7a72f94f0fa067da0481dcc86e6eabe115cdfd8fe2e2c63c3cb3c0f75a4655eacfd337ddc82f770442d18ef9cf3993a9d1830217f50917153de7576917c533247a6725a0cb7447ebb0cf7516e19781a8ea8d1854349db9d3bc4e4931a1fa4fc075186dfc37ac10db1d3feb6298c1fabc8d897e1c806e38981c3fe7f252371b0e92efc61b2e787279f4a8138e7c6527ffc4092de912378ae692e9941d0b6d14354dd25900912f9a907dd970db649dd965c959e60f4d174ab0aeb7bc016735e8b847e231bdd240042aca16731926f537fe388b6496967b750a94cf514c9296805607b5f44451bc622486ff62e7af5c0d243503ff31d1c753d9fa3adecc8f555445298aa10a877250455c43d412719aade5a202076fdf080589a28cbeace5a63de77d188c1fb486d888528c5142f92e54f005239285cc4f8695c05ed32fddf0b0072bbf7642a1daff7246055cf35e077acb567b78c73094e583b9bac3ccea986305eb4322bcb923b93187bb3061fc00ee0b3d10702d7890c4eaf4e5f3da2143282dea0b12c3f043818914ae3ea98cb1322d73878b5d9920e87e6e00ae831a3b76484e0f69d35eb15b053c545464811f9c381337a80a603ca91ddebab47b72d6c80db4cf0646c579a136326be69bae46cb6ecbe23ae355cf7181981d8f7b8e16b3303aade349f44c005602c34878690d91fb7b4bbbaa75a91528fab18c3c8c1380c0c26a98dae3a2e441527e8c7e7df331a506eeaa2d299757e8b0cbba97a91f64e36e5a24cc83b00fa14b8a41e6fcbafab7eaa905c04c30755c551b2f0f1a24fb422bbd76090e212efa160103344200e83545a119cd7d2f53e8e5e6d89b1c75f12a44ddce7b9e9bb4710e30c853ac8d024be6f5b3d162941e2767c61a7f7ac5265d08a680b87f07bdb4d4e2037b99a6eeabef33b7ca6e7e6f4428f6814e294b7c08783525e1f632fc2a43dc057264bed23898edcc35493222a92dbe28da74c07c49fd725670ded86494fbce9476d3a594f4d96ccc3302a9e861933dcf46d03b7648bbe7bca88d9791b5a62694b34a9ee0d6c9d5600f0758e7e0a2721cadd048bf59d84bcd7ab33a5ffa8c1a237dbdf3481f03e6368b0c1a86ddf01b962520372bbb8e330a70cc684e84e1a438fc571ad9bfd297288135934aa4f1310849bc9c1658006eb1639d4b8ad2f858fdec1d5a4aa89259e591e2cc2948ff126caffa24bf41bf71b408da6b5107e1d65fcf37697d307ef3a3ce742e5d117e7bd4d095dfe8598213e0925bc9c8da414b09fd21451ad8f3531a756f15269614ea1ed728d3d37820c6e90578aa43f8f4cddeb9ce97b345840899a016591690a810c5773572f34b68d1f2f1538dd7c541508c990621d54dc2653bb4a7e9a1c637515538840f836d38333de92ff70997478fa7e4eb0b447ef04a96b2376d3e7319b49f8eb0b9c656bbaeb8a000104f3407e33c23030ee9d5d92a2aa7ff76f419ea3b1c9a8953b30a92759a8d0fd37b50e66c8f664792da1448f8d12d60e169382da435c038f10be62dd1c0430f18eb30af8c14512d3311a28d4252fd4b4dcc04b5da190a22c6eda7ad837e470b9d8ca3254f89a3e613ddc74c1865b5386efc7a8811e95163fc4c2a61b738bab3ce75e9450dfc38a52a59b89746cbb216cafa6faa0236db5b86747e7d9d3b6515bb19aee0a85bd4c2bfd76c1916e04db2e0d0382efd97d2ce79eb9370087b19faf4f269e7fdf64f6c30eabdef01c5a4f347dea6e28c48a55643ca36881ac5b283a9f85a56b203c3076e592779f91d3a00344a29eefcda31e2c66e38c6386367a5b43dfcb3978c891feda33c7907d7e4a501376e1786b9cc2ae1e0a60b9c0c979a0c1c96b9c126f647c3bb21abca0d4498c08a4544fc46ad1a33b17b105db91390689ecdbe0b9e6b5cc1d65a52a51d7d3a714c850c14c9329410c9efdbbd55cbc43e8568b01957d664de2a82c04caaf9e55ae5a34c533bc4da5c2a715409a900c7dbda950463131367613ddb0ae44c73625fc8f293e4002d5b704645c08098ead5a0fde1980d8addf0af0efa1288d569fa62d6b3f6227d1b4d628d1142f5eab4f7f1302bc97809b1b022e5976b32da3537a192938b8716307aac1972cc5b97019f4b7a9e5e650d0569ef4e7d12f8b123b1ff1d95d3d713a18dce009364a07d01b3b62a1f3ffe29130bee4f3b275dd27fd6860423629b181194a10ac44077eb2323e931cfdf64504a94a1e7683110ee8a21e67396d09b85237a51d824966527f9e3681ba9fa6db51e571d7d6a1d04d0f9bbd9d1036316a67ce225705018d1f0a9b9817b0d01dc092beb4e1290a7f12b22cc32697a75e17b9a93ff817a721ed0c696643353b80478a8d41e92b0dde35d7f2918f310e829305711683fc8c2119f0759e4bdca673ec93f4f0837aaab4c925925504fab72f35bc494a4d8bca2b2ee392af02422b2f80f174519fc83a06f99290cc7f1812a32511dc9fce9499947c92cc12c241923e62e98824b85ff3ea4979bd4362f87b7a89204598f51629ba1bc6d42354cb13c093d00c7da85b2523fee61b85573aa7d4a3145d518689ffcae21ff6470a8210cc6302bcce2459244e6f9173e1d9447726942749fb6bb13bd0d3479ac5f1e6d70e104990f2c9311046798f906aa215c002ae0b918af3db1bc591a937d5f485489a132fe9098bb77387906ae54d92d368ded939a069d0866279e0f7cd815062dc25c664c168ae4a11b9f1fedcaff8e3c37b6f7b075e737354074381a135291383a35047b1dcc7cf3b815c1b7ac187a4dcbf64fa5ef83c4fa2c0b4f5b7e024af32ab5d72e4e86a92acf858ff0aaf0fb8fc64fa12d0733c6fc530ad739df51038fceaa88e6e47fd80a357f501dc4ba5de4b6c0c573534a84e5aac913bdfd30e548c8009f06e7281d4b91b968852033af7b9e79b644b1532b9324b9788ab6ed930236c5bb2de248231f3046f490131ac34586b43a3c8e0a73cc756a816c79f3f10f12c23501947b29617fdc2a45c7f361d27966f73b1b3a1f50cb0052dcee33ce739cf2da8fbf9b7e5734c5a7fb8eea9f5a598ec6c207735409ca3401894f634fc787fbae311d4bdc8c99e8986f306883d7185a18e71b5166cb9b84cdaa3cb03231ac3053beb31ff3d87838e53ef698f9921a0ebe69c9b1526ba5940bdf21fd745f6f2653adc2d3c36340a6dd7c9ada045dfee2349e26a62b437e0c8f4fae2c7eb9eb577c20886d8a8fdbd02d245c1a1478f52e339e8ddd71fbc6d2cd1668a44e2c82b311720996b8da7111658a04f4b756d84418ef3e99713cb73d87bb4a14f69d5ef4a8b8cd6d0008164fa0a802c0679b26e155d801b40a2c77453dbdaa5a582d7c9d967e8a5706358c68c6da6c3e6746f0648401f896f1674797b0e14b354c27ea94fb12ad6d8494ecb0eca0eb5795b1920c618b429b4e95979174fd21685ead022e7ca4f87958c8a101b8b3a5e0a9d64393395b12dfdbe7e7503b62db0fa8813c4eaf1ffe5f190de55e83fc3a01b10a647d77cc49b07a258cc4e65d489451f849f6aeea5bde2aedd8e184cb9c778a3676dcf87d2bcbc19647bff28953c5d06fa73b860a16785238f9765c0fa958757b4791272cd8d1fae302b8dc47282b782d5c4c5ae75a9c02a3e911a79547df96d2c2306a2e347e83a8d8a126e6a3a21cc46e476a706af9c42a97b3f8fbcc0de5cdfb59bd6cecba11bbb93ec1bac6422b61277eccecb8b28b3d97f0051b89997c8c22a9f517d9fee5e16606614fda11940cf388c04daa1b302d3b0590a9bd0692d6139b77546d71454054197adf346bb94b4f2e85e502e3cd919bb43e8b424339e2af0e7070b035271783b1d7d48ecb6e63f3597d08a9d0677a44c29948d9cf9570e7fab1ab0d8262bb963d62e895c9bc8ea999f6f8770ed5ebf75a39dc0fe2eff88d75ae19690e0f0d52090f18bbfbe39697042cfb5293692f1e66d76aad38bd919b634ee20000000000000000000000000000000000000000000000000000000000000041187a86f715ea1475c76d354d556242c15f6b8f7c441cd862cc7c89d89a58bca02ac74c422eb01833db93e4b067e507da65080f93cf1815f4cf1dc0d53a2802230100000000000000000000000000000000000000000000000000000000000000","nonce":"0x190ed","to":"0x91a5d806ba73d0aa4bfa9b318126dde60582e92a","transactionIndex":"0x3a","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x1f02737dec59ce5f29b7e11309a33cea7b370eddefa1a8007ed3fadfd1c6b23b","s":"0x106ff6938ec0a46da92e74768b54926633945ab503e2f2dcb69469b544907586","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x2d679b567db6187c0c8323fa982cfb88b74dbcc7","gas":"0x5c90c","gasPrice":"0x7d9f6fbd8","maxFeePerGas":"0xf49895cde","maxPriorityFeePerGas":"0xcfd6ae0","hash":"0x45499074aa521ac4151138f0aad969bcc2dfc1648d22ff8c42e51c74cb77414d","input":"0x003851f8368551cdf133121c7cf32ee5690000000057b378dadc7d07581359f7f74c422f52a4d750946601a4898820282002a14608e24ce8d2412c889246951210c5eea0206041c4025828362c2828a8a860418a28208a224185ef99505d5d85ddfdbfefbb9ffb3cd964ee997b4ff99d73cf2ddc5b063a034cd01e114eddde75618857bf21dae562932ea35bbe70493443b0d3bda8e6161bdf9a2e6e1a1d63845cef77f151ab3e17f6819ec2bc7388893dbbbf49e9f0c76d8f4e3a6d5cb9c46eff41ba97c0b3794c105b1a891908a7812b16b0d1d7780802e8c7621a188764369f6bba1bb0c95c54c4e3ecad237716b875175c0e27d3cb133dee5692910d9eb1ceb4679f65e7247f51ad58b4609f4c41fb91c48acf7b7d2a8532654b741723ce4f70eb38a521e9948c62bb5d73328e2aa5e7174426f5da2a4b1c6ef04eb66b2d4d1a48f0a20cd3d8b6bff8794b3975124f8d8149ff9c0b714da5e23b8ff418940c5dadad787c4298fc8486c94c44d45593bb8dcf6cbea18578904b0c99dd61f2b7653a1562b2cfdc3dc96fb15db01fd11710145c7d6b0957b60eb6fe886a047920fc64a496565e715ce7ac34a51a8fb632f62680c9de88bce189d008e29a23679115012cd789ae2fdf6cf5f4dac0cc4aa2e092b846d3d3b36974cc62244625394645ce73c1eaeec885e6dedb131a1d420a57f945698a9e7c57befcea025554af9a4cf6a432908061828ea86605e8ae7ef301f4c388060625fc5cded2d60f4bcdd4270b2cd05a133fe45e31ff72c0fb8465065d16678ff60a4f2ebf901d2403345bd6c4459c6c6b97bc038b3cbf9f0ffcbd7fe06fca91bff93e504946e2051d05e23e28dcf2d35dd2d1c2b16da8fffcf65ec0b789efb1afec71cf481e5b4476b7df95109b64e2c1950beb3cf3ec9a671ecbebbca59aade6ca79f06328bb06669266f9fe9a6673c50f5aced1aabd49947341ec338b82d9ae31d9fff59a0511ed938e016432f9c5a001a7d5d34b54a7d9a2419456e3bd0eaa860ff52e69806188aec7e559a70415ccb6653c885fa17efcfccdb680026e43c9ad0bd5b379d4da2127d429e74dcb29f3e45b3ead08e1e85c2be6505fac13244c6e528ea261329310d9b80b16bb7b562d9477dd95f6415de5bddec30bbcfab9cb9bbf88e71eb47c16df81087fa93c4b39b5e0e1cbad17cb1bbae73eca0e2c75f73e12e89371e79a4d42babb71e9da013fdf5ff1c20a45ac00a02bf1ee09b0efb1254f4862526e5abc8cafc311bb27abd9af1464ed617acf4c1647dc8765d530e4b40fed95768dcfb24a0782f32fa6cb29e165a5745f2b44a8875a96812b99a095edaf5afb1144335625ebac2a489d9133676bffed7d161671de594b27973fdebe55eef99d65ca83e607ce6ed86d32efc36bcb4bffeb2062a99371c93d2eea8a0f47519e0b40ef21ee8d9de5e8d8da61657072561ab1cf9a4b1d51da9926a2d934cb9be7a548af7a5835758b5164f249ef0f0b53051779089dab29284dc10c24a1ee298ff1faf3aee4072cfd4ca19520b23941a4852bf56dfdf0eb075ff435f87aa51ebedab52cc3ebcb4db9e133e57c2aeb10a836d1f5484807f73a9d411e059283bb45fc028cc8f919abb8ad2b008ff7a95ca576c0c04aa4f243f10d2fcbc425ce014f5fa6793335650b99beb722faab1bae677d9939a02d3de5e0ae5d5906ba024cd019c11f0d51c89e73b8cb3609f7faf3d127f969f3beddda1a756fef93ba1a4d33e4c3992957a9c304394b7760063250a5519ae83b304c00fdf0a21e2acdec12482b724df3ac5ea472c065a9e2b7c8de28454d72ced29d817ebf3126b6928c2cd7cabbf0cee395489744896faea55699fc7ec581ad49b782e1bb83bcf535468b91703bcda0c48fef1e919dbbf30aa45b162c92f0e01496643bab3d9020b8e471695769f04020557e8d0fd5812bf346deaabcc118c92dfa146a1b5fa6aaf5db5e6fd704d073d9c6d549004066b97db487f857716ddbe6cc6332f7ddba3ce2df47f0f25911e833adf8f345677a96c7223a3efc77a3f7a5d24e543525591d1fe4afde76a4a3fa883efb81fb9e324c5727a5d2e7c04013a249366aa8f8242373f9c0aa55a7366d364b0bb89ca1da127046eea1de1d39b917fa53d6acde40da381a71d342e3fdbb19254d7df86704eb979ebcb905762ad78a852bc948b97aba45e99ea4fd7e0340ba70097b4884abc81c20e99276eadce78b6b5f075620424b9a83af6457cf29d9fa52b6df6bb7054711e789cbfdfd1bccf3081ed96225866598328089398b84ac237a46aeb513780c62f5ba256d9de6392fb333debe7b2ebf00571be5b6dfb5298b68c0c4f8a281db7b5a819b91297d29e586e6e78dd685f9810e830dad91e79459de4f2cc484ed9cb3a49eebe9b51975dbedfa1699e3c2fb9cd6a7e9ecde33677fd57e07847bdfb9bef75f07bb9f55f73c695a97ac188df3280a5e92f0a4f1c4adaf8f53bbab4682a9dff482e9cfb43db9dcfcda1a466cbfae58cb09a97d8336c88b124bf1cfff8a603a78299b6e6a9ffec57be9c75d73fa3a86049c56f127d5f3a6645bec138e6f9ee98510eef2dfcaba7f894ce575889ed3c89b3c1caaa37f0901d49f7ef9d46c955095899a76feb44cab15d918d6f9e924e77ef594b9af6e7a2bcbd2190758bcdc73a2cb5f7e25e9afd87f893b653e7d81b294fd6e0bfca1f5565a21f725312a2108c950f275a4c0a698ebabc567bc1d0e7b1d74b027f1dd7187cb584fccf0206d997519a61060628e2255ba437bdffb3cba91b64c87899fb19b5790ebbe92b0d55d2b0eeceed76d6e91aa53c6ae2113e33e299d531c4fe70c696050e654c13387f0f5a9006691089779741473c7c7dacc4503fe93cbf7565bbbc4f715dade96b451a21f1e36920bdd10f42f48946f8ac56ab3afafd84800b2a9fb6d643cb17cde43a619d7ceaa915e6f5d209ce489a8b47bab1eeb9a93792c6dc3b7676dbacfbf3e3cf43e2d68c79522b62530e423f3ac341333908eea556442afd4a7035384916fe5ea257e3af6655cd75ed06f3498afbed542b0ad0491373609b66dc14b70fb96868a8962a2d7ee4d16ceebdbf334a8758b9721bc879a8ff8bf9f2fbcc6f63a9718a35d8b5df1d6a38bf1c6123b43566a079d88b94f3870ea1b9ad8d94d2db14bf12db3ba58dee361949713c756937de91dffcef9fabe2f9714589d51e3a72c7c896ce9b1fde893f5ea895975986ed8766eb7c7598bf7371fdab658e7bad069a9b52f9e9761ae014c4c15c25b1f98e3e0dc1d831cbaddb6f4d3a993f2257d61f345b3cec990f79d3edeb2f5ea94016bc4c4448c8f9815e81b7433017a719d074003d7307e3d627653f5cae3753642527b0a49b76bae643e4f0cb4fe00bc7b71202d6b1ed7329f6ec4ae64ae463ba7cae1375d3ae4b36741ed88e3dbfc48efbabebde8c1eedd487fb8a9f42b66808936bb6692353b37642efd113c62f14a711f42aa00a0947ef974dbf1c9455e3c1ef175af9cbd8bb729f5a7069685775d8ba8fc3552e37e8765680a58eed27db682227eb6f9f12e9378bed42d4292a77ca86c2eb79f2d289b557e5be66535a2f7bef852cfa2dea5d97c52fee7124916123d91d6d6911564a5c2be40110b99de71e9d9a6203de69a6f7b57e54fa4af76b82daad4021a3fdf1ed0cb5f2118646dbd38f2ff5c7a107967eff06986db9e2bb8996f3dd20b7905cb8f091bfa1f9ab52307226009181925c4cf729b64c39add884cc606b5cd0ffd92167e5871ca3b85b0eda19eecd1f3876fb98ea4b0ba1df9cb8b5e5a87dc74399170e34ec1a2b29df609aa1f86f24fac697de3bdd5eec694516c5c59c6160a30d90211319e50ed9384a8c8e316331b2a64f65a2f2f72b3793163870b4fbec75e81af7d4353aed284c926575a821938c34a619bc75358126deef5ca9fe7b0a5e69b6a7c19935505c73df8f2c06ceb3c09fabd79df5e67c5f209579df95d20ad0491ca79df3ae257b8ac3e95aa302f84de6fc847c8cb147bbef136f355a240aebf1d19e1db26bab8ad4c6cc6d6e27c92d0cc8420e0f9e9cd2bab9e9ef2196e07f04997abc6c1054e015c72da67366699fc045c21974f9d6433740a3abc30b8fea46456ddc7c3adf8ff00b85cfd8e8b6ea2ead437ba951d6d5c6c73322d29be2a35e63081d752933b7938c212b1289d2775222261d18633dad1e73e5f323ff2e0ecf36784f52179e6bdc31c5c19616886a139ad0c632e47d0d32d1ba2ac6c0807fae7bd766ec53b94fab2d2ff22a93483fbb6445e72d409a398840f476eb72f1a0ae8143b70fd04676db9411782f83dee540fbe6aa82664c779605bf155030785e13d8f0bbf86951c62ecaa7e25881f491ef1ffec48fc67ecfe2b9247df77673fee6cb0f66f64fb982379d6deb13a79a3f893488596938b1bd7369f9b99832c4c3c23b04cd34cec0dc5236c4105ede9dcad1943c5813cd18525daa70fcbacda879ad6675aa6bdd5174f0b9e9b6c53e67f7771408aabf9fefe79e92c5e8a6638ae8f1e38b621647d0d51aad753ad3b5a5dffd869f18bcb9a8f73c76b452f45c2f8ef6bbc39c9a479bd1c66bb74f6e3f555db06f55a1566364ace5a637cabb4b6b5f422305086e8542d0ebfcdfff1d1e7ac9d2deab374165267cd49df53bcfaecc76a6139337e9fd029079ca503816826e13fb54ca2dd757e147bf8cb7d793ab299cb920dfd306ab4654bb7661cd83814994236d8b50cd984ccb5d210aa54dc73415c96b92d6079d19ad0da60496d2b64f3d687b8cb154565602ec004b311f96d330f172d255bc6f0c550afe9acd9927abfc7bf67c37ca527edf3f61625f6dd9d32ffe64cd0b10cc433411bc558b67cf11bc09f8f4d7f44bcdf6395fde7ea9f70c80cd66aed764d8dd0ce88679b5caed8fc9c2ee8e32d2ef5a8ed9efd1e418feb40aacf7f19f16c9a1b35357f8bf8049ea7fb91c7ba47d670ec211f547ddfac75bc552f487263f859af5dea16f91baf2104b6dac8af88eefba672312ee7fb9f96886ca51ead0fda9213f8aafb5bc4a7840f65a01cc004a510ee5ad1dcfb0fb650b747acbfff26a26f568544c0d24186f8ee4b169615fdec32de53b6d3f2813ba5b7076edaff3224797d524bba359d90f417140cb222acc5ea65d83c0e7bab279f4bd8b9f44e0e7c907865bb83d3ededf3f539ee85c3420f10ebfb0725fd91f3cd2f3cb28d9ea9911fe136e6acee0bb05a7f18bcd4b5caa9784b19f63dc0c47623730f54eb3f52b2610e9cac31bf560d29def6b778e3a6512fec915eff7cb1c18981292bc892893d581a311046dd9c132b6eb9fe354075e0caece17f573454c035ec85e973988dedccbb7041ce2801733da9f782c8d85491ddce93a943b1b647b41d02902ccebdc3c82b7901adb91cbad9d18b7915866a1d9098e1c43de52e70477048d02ab565547ad68c33c7138d30fb165f1e5e76a837bd74a4af58fbcf4e34203d0a1b56be539f2ddeb3706d3f25e663ed919a97ff8abe62a76be6bc6fa6e61aaf2c8ec01768c7eadc9bee7ceae30c31dcba975d6b558ea932e22a71a5c728d2dce05067b1d4a27dcfe0438fefcca5cb4a95efe83e63a7dc247570449dbed353e7efbad6ad8c981a2b47de139ff5bab370c969e154b9e4f07f813a9310a9c021f52b22829622dba52fc47814892fca57ded9158663b293356decac92b391c56d7ab26702767e30b9726aa51bb16b79ead28fb4e00b815b66ed75006e443a9e41bb5ead6975bd3f8326cbb4de758e7907ef62dfdbaddcb7b1fd85b3785ab27cc0128d4a8f0306ce3c92cfe0f708ffdb335bf69c55348e88597f711e5d35efb6e05bfb9d266f107bf8497e8ef403b791e1c3f23d6f83f7c7f2c7bdc63776dd4f3ab24178e30daebb616cec37cecfc9756e2809a6d131c648f88c6eaae019a9c3579c6287d7681f8b5a24bedd607ed629eae12f9e2bdf55ca28a01ebfa2b20cf30460621e22b49241d178f5884481f3cb5e062f2b5a1f90e4a66da24bcd9328d9501e5f7369ef94ab5cc9c42494d60edc51fa6d5ff843a8fd5d5ff89743ad44ca92594df4fd090a213696a51aa7c3845fb4d89b7c8ce12a9e57ea61d3651b8868e7d8af070f78ec48dfba75613df791126e81aefbbeed1911f5ee74eca37da5f0c478e8d9d4c6433984cb8ffef678888c982b7fdbd36c736ccbc9c74f65d3b6659d3f23ea63f6614974a4d62507951089c22d885256b29d96a7f196cdde15515ef5b95bed572ef4bd1b712467c7bd67f96b1674378d8f87a07fe35443630157d419d038c7fbb0486d5ff6dc908db1319271d24b7d8ec8b0cd7fa16d812828368871866b96fbd5fbc63f5db2e85991c937e1e7fe1dd93972d9013b5e56e69661f40026461bc9fde8a9a46f19da2be783f9f07695579e22609fe4b6252ef1ddbc0bbbbf687d9e316570db32c1563487f09b5e0ef117862d5301762222e99860629271f05b8d38d06658ead0e686113b9aa67ba89cb26bdd3e8fa4d64244cb955fef548f69f9c5059c0de748799e245be3b9cac822e2927319db667124ee46639bc3b462dbd6ba6f375e94842e4e5dfde5d409975afdb02d03b52c27f33f98f745c0d9ca2d2d3405f2babb8231fb446e87f1f97b776e3e7a862db3fc7a05512b633f75ab70bd7244aefa306fe9c5975202ef0d360dc8b725b06b961c6257d02b4d1c8867d3a1817257a7c80adf3e15ac7108cfcca555bde972db3b1bcf38bb19b35839f0fad1166f936c23877501f220ff81b93c06ad91f798214b63bbfc9e9cb6af0f41548c3772da35590ca55d22b6decc5d1d7b3149fb5e71e09a40fcd997da77eed62a8d84d9aee853c68fcbdd79b210ce34a9ac25093a57572d557d47cfeeac5beaf9eaa9e0bc29c3065f59c6190a303903918dd88b9b4c7624db2ee1b48de9cd4d0ca875095650d5c8b5d903717d33bc5b1635e52a1d989c72e3d397e29367db456ffe6afa124496a6f331d5243f40dd192b1a2e230badcf97acb3130f5e2af588fda4bac803875788d425867687a67dfbbb7da5fefd9443c7b565b79d3dd9e669e76d59a797b3ed7a1e3a580b98da60adba5c7c71d0acfd5bde9ab5ccb69fefbf6915976653797ef913ed65260a5c6286eb11e962d9358e3bfa3c8fef1526293c72e4bbba4522a7e07a5f6da6012775d5b1d487283eb5ff89e5b024e4b918e98ca203a0eac6bb26a5be64bb478ba936f1b410c298db9260f6969ef4023125bdbc7db8b725cf7e4b69e0c0bb1733f3a4ce5f6b2eb374713fbfd4f488c5d1be324c038689a943154e1568a3dca5823234ce6c5c26ed2da769d0b1a78bdb4fa9a71d59a2af1241315f462ec378dd24472efc8d17937fe3e4bf89a2987f3201db5ebf41726d27cf6c26b167556dfbbd0c00589c8fc1827fab8ddf45f95f76efec6f8d3ffcb2bc9754f9ebf26c935f967f74e5fe0d7f18c35eb6fe9b112b9767b418c56d9ef750f7725ad45de079a5d42b2569d5857cbdba2f426619e57273da74b5cf5af951e76b3dfc6843519c8e6ed6dc7b8290fdb0b1f7efeae73a579a7cb26abf03c7e7e8bdce598e578a5a6f1dd57f77ec99edba37793aef1fee973cb8ae75cee284055e15d62e19178d3707522ae7e3ee9ae5d00e9d4d82d21e79578288e3068737f317a7c865c4ce6f38eedfa4502deb116b7735b897b77f8d41b7cdb7fd07973e715eb9995a40986da462fa51b9e682506f2559526a6bffbe8b6f6ebcbe97568679806162eeb1602d386302d65aadbb374419f9dd1e08dcad0467c5f3e96934cdf94fc11a04ff3158473a8a7e3db77f79c292f017ed42a28ab2ff7d58f7ae65fcba3cb1ee97e5ef3feafe1ad6a4dfcd1061fa5d171d2f21debb4a99b5ec48d57adee17b492faac44efb1bed06b538a30302078e9e17bbb15b25d3ba8a4e9255b1ebb3905ab17ccebefd6591d9feea87e3660fe17e57bf9f60cf0992dab3aacb619b0902162a967eaa4709aa8b0c65aef4bbb2a56fe2695b51f950ea8b5544e6fc4d5d81b96fdccbd55df29cbae1ac667efbf62b51c39c6b2ac9c839cf8f85c7869fe8162a5f6a3925e16cea1e6cba00bffb4863d8c73c355ead66692428b3a88f939c136818237f256159881265b37aadff156ec96f73aaa3b7f8783f2bed00065a914715bb57d12b5f65a5ddda5ea31c67d9b9e6d2aab2c0a425ba857c471fd552097a343a660972b6d4cefe7e3671d5d34d5da54312451d414f00d3944635dad335e7f56b00b30ab4c3751ac81adfd8c33e950db63ff44c85b901983717a35575561570ef166c747d3abfb8a112440aeed6cc8f575a3d285f3a6c1c163bf745b4d79172d13da49263bb2415b00f520d118b3767240e1dd82f7666b352989c7a6fc8e7dde6c5ee6bcfd79e9ea9bf4ba342865886f90c30317d88903d4fc501a706f9b7070c15ef543ed850963cab079ef72e75090761717efdca575316d58589c9fdf9424ac0cf070ef2cc885b83e49f0c1c82e91a1a00b3ac246599bcc4db1ebdbbd70d956efd071652cc5e2d14f79a0f78614f7fb472185af9cabfd138b7705b9f9bf6725e29faa5804f8838a6e5f5ca00385808eb2ab34363ab50b2f2f9f39233eddd4e463d18d6352ada86a61dfeffc4424a22b2986f9791436fd96cc3ed2bdaa399b32dfad71bdd1e36cedf2f6996f6c2b6ebab2bb2ea4bf11b2295f77d0bdd9e91295cdd23ea548e8b8839e7dfec6bb74976a68232ca8be3b478f1bf6ce7868db922b5bad6f87ab1e162b27256ed71560a54aa622cdc91785046ee2dbbb4c8f220a9334b8aa9d6bbf73fe724f69fc8a0bec2236e0d39769befbf3128e88811c39d55dfccdefed9a8fdcdaac78c8df18882b467cff80e2ce569edc0fad9247625883cf6577f16f08d9efc2ce1f8c3976b73e789773f6c32b6d1baeded08ee286e68f046148b66e61ea93da5735c56a5c956b076d067db079b76bce5add735a078b5db7ce3328c04c0c488205ee15f6f3b81b559f9bc83df308fb6b974bce453e894adb0df2061d8b3c3cf62ef9491bf8a095e1fcfaab174aede7b64f4e32c0d84737f9d559b16bb8b3acccf662b81b5a01d5f8da95ea91483152a4c93feb61db3f5d2aa8791009f43820bce2c1076edf0d56a31311c6c40b4bd9bd65764de5cf8e886805e3c6d64d22ef09f9d03fd5df9ffeca41dc983f7d403e190d873607781e2d756177c31b750dea08658fba0dd215e28a501096dfbe83e5b51e068a650ebbca797ea4508fd1a570e3cc5bfa6d46fce6e35580e9581150013bc8004a93d12b222cd5dfffaa8ecc66fa9694daf5e333b4ceb24d584bd67573d34f50c9e3234dc9860d0785084ff75b32920b2539af3f26d5363e70b94bbc71615c564d61d5df3527885b8dae59373333db7ecad439655a79c12b0c39c0f552cbafd6ef742e2e682ea274bcd9a5a7a7de6de1f7a1ec5561a341040e5e75ec0da406ab741f458c3a11bf714f23f730c19ca32d78af3c52b6d79a2600b698e2c0ac8dc7548b658bc4bc3f975bf2ebfdb916e214be74fcdd8c60737bbd2e5bf68de1e444c28562b70515cc9bbce2cbf911b7ac2aa18a20b1dbbe556bb8e6788921c34285766b410601ae9221fe28ffb48169cac5e277cef909925dbec8f8e3b6fa884553a865f085fd7f9992b75ca1674672eea28d37f8f61ea77b3a6f29e4f9aca9bfde138995ca6cf80c89089830e59940400420408207f23e221137b32640242260e64084b718070600caca5ff4b6d531cfee25b1408cba09000202d9d4102b86a5c887832c4c67a923dfe048f2701c05512009492009007c2494338191722090085277d675b400280c724006c1c7b08f19000a003ad85d7cc85e8c9fee92540028001d6834cd63b2f27dee7d7752142c002069e81fe1fe2860086130306011e065bc4f04ffe8931f014940a25a138517e4a83911463d07efe36469ce18cfff95b627ff23866db0bce7d8e62ae2233cdefc8d7e57ca04b5ac564291e7e72f2d5198990002fc20bc8c41eb5413a9671188f6749213c2acecf2ba4fefc319604601c0990897d0cd7954dc8afcd07b1812400b3824102f84c5c88a3ad7f2392008c2f04d06824006b3ba662328481002ad589046036a326e023b91033f0780ac3194f860032fde7ccfc8986507431589f108063550b8ed6f527cafb331dc4347f703821dd7263afffe522bfaffa29477768e4bdf7bc9a2da6fac9cde693d2e97734c8c49e0460e7b1582e1c97f13009c0ae181531604c4454eb2400eb43633d0e8570d224802f4a7cb40c3ffa4102b0092c0a367f1605bff608c59fb148fb5333615b0924007b974a02d88227908c7d4602d8ee4dfc66f3fa2b1060332190003675daf775b319fea16e4fd6a7fd1fc948dff144fc4e7ab6bb103b04d0febabd4900db65b4c14f130db22f1eb701ab893e888304b0759000f69b3f23421542fe5b3c3831f0e90c96939100763b12c05e3f5637034f2601ec3e7408004900fbfbb1c782a22480fd2a810a0120854186408a1348a63a93d3f1780864601910e000e12000ad9b918efe8777a64220489d1ae9886a2100c2388d7a3c0960ef82b8480087f908c6f4c54799639592a96427061e4b0238b80910c0c093008e252e440a04d2d0e72480439605f7db2e448a134590047068114800872609e0e770211227387062e089a36aa0400038a1148afde8d7185bcbcd61bfeec71d205388cd015286806f5323571c274725a6b231f01048152393008e06021443154bc713211c559082caf70665bc93047024bb1089e3dca1b17b54867196211c244f03d9c67f53a9d20c7c46faa862b9681812c0e91433fc9b7f5412c0298a828d138aa38d7cdf81274bd2c5b6e3c9716274f10c3c1ebf3d63d45c14c6248ec6e1c479820470e69100ce6c3a09e0dcc8aa8ccafadc881af00f6f9000ce9b6843c9acaf2f49006723cac31917229dee440238155d885467fc68830c16d10009e0ec44bf71b153e8681be5a3be49a450509872cd2590002e0508402bea71214220054451c1c53b12e22079aa104a168d922da790008e5e566df6685dec2e440a08e1625915c1040a038f166d22015ca1b123c534904a02b878d0bac6704ba5ca4ce89a0470654380241de2c290002e8a0b51924c134bc74f2ebf88864fae5417623a9e0a613054f1b1b74900d7232a09e0707021fa8e9984c262b60f65f60309e058ed4244c986d19e88e302fa0a371f951a4b02b8b44660c0c043f2342108a48890006e730204d0454900f77c02351eb46749c3bd281695a0d08518e78c2701dcc7509548d2c54800b753dc883620804865e9927b2b819e08da539d21900aa6e3215c2c98898770230ae526b810e3682cb2032c3212c0bd07924f14a38e484773c6132110c22460c004d486a8ba581a9b929b084d72130a04ca8c43874c4dc7d31868d5b1a86a784c09e4383696967824092480478204709f7621a2e562e8433502998a49c713c9140cca35cfc25812c0dde242cc444560a2ffcf1c43349504f0b813209674bcf35d881412c013381a6258bf47d4ca134b8030ac2f0cb4c1eb28c6d2f1a334d0309dc54b2e5a9433ca0b0dc2f0a4e3e92ce0f154a025e5a325a36fe1211c4d100617d004c5205bba20c44b171413172501bc00814ae561e06923020ea2af32475f1d799304f00ad0e974082401dcefd09c8481a7d047f4c1ab462001bcaaa3e414547ee2b8f742c354b1496ecb8ba78eb8683acad16a1a09e0d5436b2301bcc9bf0d1ba81bf2ac40dd7b02e5bcd9932b2ca48dfcc8c053a91812c05b4e192ba452d9e82234517112c0db88b2fb684c31635551a90e108e0a8ed51db3ccc14c5bd31017e41fbc0eb72e04b7cecf1b17e51d1e8283bdbcc2bd23220008a0820ea34cf0a942f2a828cf47d8e0d3a592005e14e0ac0ac74327fa8342c142000d7420017ca8ddf92427452b12c01732491abee849d2800c3c996557be2c0209e0db39cafe9843f3e58f4a4a75c04f6a8d04f05d439ba39300befd2ec409b5f1354e6ea86d5243589447b4217e006d68f8bb86a6e452dae32e05ab5b934900ff32085808017d4363832818101c1b43b1e909c2a00d010274a1173264cf5084aa250403570864cf5dd2ca754230103dfa5504c62204b2670ee1f22311185b47207b16b0efbb2002b30104b2e7e3c7c9ad22309b2681ecd94cea361681d92002d9f3c3b757db4460360601066d5c8823958bc0583602d9330c2f714404c6ea10c89e9b6a7c192230d69840f64cc9bd4d1481b16e04b2e78ec6bda62230762381ec992514e6260263778e55b310bfdd5e08064509235f45600c1f81ec695225202902638c0864cfa53b03fd4460cc2a02d9d3b6e5ce561118b38e40f6741fee7c2602637208644f58dbf998088c6918ab91e3db33ac080c3a10c89edc1e79a74560309440f69410e36f168141546aa5d270f46b3981eca965d4e62b02833d04224b8330e806b31d6725dc30e89bce80a59ac6b3ef3e220c26416c643d2c0564c0606c3a0396dee74284d98d47e9b3d0279fbfa3cf87d9e1d1d2b3e90c5846e1bbd2c689daead15223b4b68051fab61f6beb87d9f78c9462b028fdb1c9a598d9e3b56114c6793b3c4abfe087da302e13f4f6e3f44f5c880011c6844f9405a12d5d47cb7a47ca5227ca12c7dee3601b6d67ef0f5262ca27e8cbd219b0ec4e947edd28fded1ff9ea99a0ef4c67c072722e44986b548b982f3fd48f951ba7c74a8ed3378ed063357ea43782b9712c49b0ab26de741c93845b67a48c04733b8dd61182d6eaf65d1d64987beb6869ca0f28c11e807904476a393fd1c2d9313df2288dbe59fd236f6f26e8dbc638e219e3e3f30fba62931aa767131da7bf3d42cfa6f223fd8a09fa65e3f43da3f4841ff8618b9aa08f44b510e94284794347e9e37fa43f3a419f3b660bdecfa82e2008c2929d60b60b0c58ae151d98cb83108e9cce8641873626f60c0a6b0e27239d41618d76a8286dc728ad28ccae432043f282303b3701060132cd890d4373488770603accaee342a482e9e3e303063a7c70604020c8807020992604b38b13a80c2c242f4605d347b299b11109cc6e05f32f43bb0c98dd85121b0bf3db8c6605e339f8f8e0860cb3af1f27a6c55263610131d42b52636363618143a3ef4d74d4c213ef158ebf578b36c25e199bc8d222cc7e2b9d01cb9bbb10ffd830ccde020b4ba0ffefa25261e19d233930cc01c2ec5f589551e1995dac71276b4c0973d8d3d1f16dc25f1f5bc2a26568ef958ea7c01c7e0498c33396e54430c75a172299884a35a61298232696e59074215198a36aea933630472903967f3369ca06adec4e5c1c0b820c3cccf1383e8e256c8c59ba65ef85ebd45b9c07963f6cb9dc5bf5aa14f7fe507a917f63827a45f2fb94c7f13f17c953e915dfb605898971494990897dbce7c82ccc0be991e63917efdc91b93d239d01e308683281b241c3522020deedbd285914e674272c8600b2f162b4af45610299d82f86e42521792a284605d1de168f429b938c56d1e9421481392ba7213e6709035648f85e7cce5bb058214b78ce96044d7a22ccd93c0609145e10401521c35cb204fc9f4da6fcc9d493085114e63222c05cfa09b404984b7bac521435309703fab13c217ef4a77d0295ce82301102514befc8c48f0dde34a73585230273ed274000cc750fad3697d5f9fd360d85b9ead219b0423e3ac81f1f2dfc23f32430b7ea8817716b43002c76da85887e5f4e85b94d584e441b71616e3c75d49df0539e86455d1b82d8c84e3077cad4231a77d97844e3e1188968dc4f7f88683c1cbf8b68dc9d3f8d68308fc488bc3c38587cd3a4f0c0b3800e714cf2701e2b02cc63ce320fcc633de6e063ba8779d68c062cf4d5206a1c2b58a1a319415198a7781a88e72960c08ab693100ff35450e3e2e8d8d1783739ac90619e87637192e7156572501d23d19cd65ca508cceb310d5e799d19b0e2f9c9bcf2fad168b078ede401120442c0df9a34fe7ba81eed1c788759669e6648c0c27cc1d3d0079f3703565a39591f7c1b282c274259e08ba5d16830bff6f4679061be5a02cc77990a8b3f42ebb9054ba8a3fddfdce9cf17c3fc9204989f8f365213bfc8684d73d00fc5b1a71a230d4d9e0dfee3bce1825f2e58fca91cfc17a7a14dfed30c58e9d977b17f9ac2ced0984673331419b072e8a4e6c8287263ff0e72ff06ec7fb144f227da8d4926be6c7bdbb58578cf2e6ce916397a5f3356a4f273b19a1c11c773a3fa4ad92c1a9a810a707f9f811e1e352f2ca048a78f06addf763f141158601f8182c63681d469a8582096012b374df60f81bd743a7d34b611c73ad069824a50681a2c087231e059c17f075482e4e934b78101cf06264b2cb80d8d0212c6a3fd4cecdf0a6e2c13084d477e212e063c3b631243acd92072dcdf442a049063ffa185c13f513cfd2fae0bd251d40b0dff01f5b0b0309d4e87256c5d4651070be3583de9cf5b81858d5963db3feb358533a76102e16d0c78f6d02413fc85303e937d3a0d7e65c02a6b278370a610048ca2706cb9179ea9349af0fe4b167be1990d7f34eaccd72362d98ee5a5d3d4aa08711a5a157160c02a5f276b55c4970a01937c9bfef77d5ba47b3a1cb53260d5d41f7c3bf6effaf60840b0a3b69c667c9e9a838a227fb4a5e8191a048c7be898468560d1e1696844b49f01ab0e4eb69118272ce138320e17b39a464d62260c58cde7fb81a8181c1b0b01202ce1c548678c0c9c59393f048064d48058586c2b0102c819f80c3c1e16cb4353733a0482548a13451016db4980c576c06a71dfafd4b2888919f80cc6d84ae0ff2fbb5c60f158880b96941df99ec6b203031f43d67cbd88ad71f33b47cb19b3676bfb3cbce51367988f5f7b2b6496ebbda4ecdbbe14141fe295dfe3239b9c8e1fc94047f37b0995bfb959019650a48d4cdf482e18c9d7258c200e58427f64c8873e449f59a1bd375f94cb77b9312cb106e282f9f527d6ed59ebf35858228ab5a6064b8ab39ed2d1a70c3c914c15148525eea2c37e89dd341a2cc99acea0c31247e269b064034a0b3a0989c212a504723a1e96b8c15adb8525ae8d4768221e968865cd7508914561897e029e064bf4c641602c2cf176746a60bc2611a2282c294480402a2cc9355a880e23596c51d06f63cb32209ae57f17b947e4935c3c6a2d322cb9928e625eb2df8528280a4b16fc9fef94a0d22560c98a7406acd6ea42a4d2c560c99a51354c8c31c9340870a08ed481aabb9b024b2d4547ee1314233b296029be118b482d9ed847014bc98d6a85e59852f309b0d4bc1f1c73d2168a1fb74ffcb078070144d6d85f2a8e40a682f6143ae830b29a0c4b05a0a5743ae83096efb2e6cb68e0c422252c554885a556ba1061a9524a2c2c4570216ec7c3523728b1102e0e84a5fcd0927b14582ac38548ff6eeaf5bb053e58aa9f4287a50e7fa7a96f631f3f758a492ba5b0f4022a2ccd35be38084b9b516069551722450496b61d5d3d632941978187a5210a2c6d38b1be47197f6b130596f619798bfec35b3b29b074e8c45b64c884168b151685a54f1360e962586ac885c862a52a961a07c2d2f62ce0423858fafec883f811238f454b8aa8e878bbef29b074d31f572361193ed662242cfd7aac5558467a84c33f52ea8d50ca084fe60f80207a1ccaa18c330196711ae750c6338e1a3fc2e176168732ebc61fa02c9bc032b1230fc659c667fc61751a96c9a5c032693f725239cac9be094e201c95ce62a38900cb3c9d60e30d9d1a3bd1c8d8f4b3cc109565bab18664675060993e96516425ff6814590d0a2ccb3e49e86fdf7fd020793a280ccbba106059675856cb8548a4ea32f093f771c0b2110458361c96d543d9c2d1c0743c0d02a9181a8896a51160d9545876910b71a29f238f28971c97804a255b4c80654f8d4b255b99404d0461591917e20e967265efb11ea0cacd642957b665e441fc88faa13850f73b7ee4b004580e034b635d8844584e60a43a13d43419787cc60e7cc60ec6f6eff42aa74380e5168c7320b77444aff693f40acb398d38c41fcc251732622e39eb9f005b2e9900cb6d9ba877cf1f802d776cfcc104b0ffce6e2b58eeebf79bad607901022c3f03963b3bbed36adadb5460793b2acb67d2f1b0bc1b8df575d21601583e9c00cb87c1f2a213cbf6accd0ccb03e1083f1bffe075863838282432781dce7ba3a7b7b757042e88b5992106dec82259190207ff9c11dcd8960758be01d2a0b16223cac4732a2cbf114d0ffe74bb038cc35260f9ea499b1dfe10b2a9149a3e3a7e6005665613383d5a2c8ce361455f9c192d960ee3a45d88306e256d34f432262d5e212ce3e302d1c61259c687719b50ec278cfe88834c68603c2b9ec0b8ed104403e3583f5006c92c068f50e871304e1d65316b271e3fbea2301e4c71d72930ee34cb6f71f726fbad3ddaf42b0a8cbbf46388c00d1360dcd038e414f85950c6354c82f20fd6f10f5e0f07fa7be1c2bdd7458607e3d68f5a2730f2977f363ac93a0ae190f2b87514b6506105b15f5b47219b022b784fb20eac707a1c630ae513181bdd1d022b3c24c00a0f7ec49821cecbdb33dc1b8ef0f6c2c18181211be0604f6f1cc93b3064c38814ac4d34539342d1009a352e85a219155668fab5148abe145851635c8a1ff4ba213c24d817b72e24c03b78d4b126daca81a427da3a498515837fb97d0756aca7c08a59136dd96d08864981de86b860ef0db8900dc1dee138ff8849bb8646a41fdd3b3415e995f4a0d9e31c29995261c527bf965ec99b022ba9fd417a431c1c1a1a1eb2de1be7131e12f4dd2ea6118e7ecdcff71cdd98842aa57a2aac14f81b8e3e5360a50b7fcad10fbbaa4638fa353fdf71a4ec06298e73a4ec4d8595867ecd9172220556b6f98123ffe088481f1f7f4f7fefe07513b0fd1e21cad721d989b6ee516165c6af11a2fc89022b97fdd0d6ba703838c2c73bfc07838c22e437069924fdac5593fc6396271556fefa6be967c553e059d67fced11f0d32c2d16f00f21d476f20a5098e3e51e159a9bfe668b624059ed5fce71cfda19f228d45c251f3fc9ea3d9d193bc68763c159e8dfb0d47c728f0ec909ff8b5271c1838e2d4c121eb587a6279f92484cc7e0de126daeaa3c2b38b7f8d1015710a3cfbe90fd24f61cb21ace204c98fb7a5b2860aabc8fda62d1a0556b1f8a12d12dac1fc101ac2bd23467d1198b22faab4430a131cbda7c22a49bfd6b4aa28055679fc738efe6877d4e2231c797a4f9923d58d93a2832a8d0aabcafc86a33c0aac1af0078e1c83e1d008bf10b45bf642adaf3939319b68ab15129b68eb1d15562dfcb53dd4665260d5477fda567048b0f746ff88756840f2f7fabe2d35fca448a446a4c26a52bf692b8602ab994db435bd4d9c5322179e9c9faabd1bcf1dd406c77307589d8700ab73c36a68ea4b45536456e23074c8cb3fd4276295a2300e42f2d627d33db73d2e215cb5582376872c7f78913f55a7ecc1de0bdb63dae58dbc2242023dcd002e6160412588987173ae8e5b27cf4f7aff45cd789beb623d3257a7d987e01bc744a564495bf45e22b622f60c4299f92c7e0176a0831accecffa49c527fab463d9dbd2e79fd368b79a54903090ba6f507d4f92ffd8e10198bcd14acf8bb6b396a37973eeab665fd31772387554c5dc6d1a3cd9ab752acde3d37601a2d8f84c0a57bf5380469a7af9f7b89c86fc9b58b0c192ccd59a7286c622ab7e6a09ebfcfc0f21b9b3e5992c29f71debfffdd611b7a13876d0ce800cb5f8a85c3ecda17e7473a29cbf408a595fcc70edbf8e7fe1e58eac4ce7beca97babdd2d73308addc04600589c8f0531d8ffd2611ba00cb2cbfe17f73d61b4b51de4257e51ae175e5774fc57e509aa949cdf1d8651a12f5e5f107db9d63d717763b87540f7056e97eaaaa13967a8d8769d756bdf3d9a79c6edee968c37a0cb9d3da27b9f6f5d5935bb5c2e7287cef5eaab83fb08363586bfab3f7cf0525012670ea652ccac4c26c6e5f055bb3b4c25ef973b1c3f53da9e2b0e58b27d7c224917afbe5690beb725cbefe09b6371a79c5e2846dcd8c6df41db79ffb169258898da3baa42ebdf0db917bb9a2cd5d077a0dfbba64e0cc3c844b7d8749d9fbf401859b196193df322d703cd96c48f85ae9d4b86b6bd791a95b369e9c0fb28a28b69ef9cf18301664deb608016bf37d71e0c959c557940e6cbb1a57cec4ade78b41244f25579b61edf6a6a6d76d63ca67d97294dbb708de30701fed8f564eb87678ad6442378d2936376699f3a9c382fec4c63ef70680783b006da4dd7f56e78e75ccc9c1758869d0f30b11ac871f35bd1999e87be191938dfd876f0b0ddd015419fd398c7b6a53efa56f77a4ee54ef96f873d9898e632cc130c13f370e4fca7ebe38703dcfdaf9f96f30ffe41ffcf4ecbc162c1bfd5c8df3b2da7c7eacbaf4fcbd1bff1ebd3706c9ffdb2fcd37a95df3958aae660c1e0aefb222e9d22e1bc5ca5ef177a540cd51faeec332c5ed1a85ea4f676ddba35fa37d9573ad7dc32ed345ac00ff770d739c8e4ea7fb4b8bdcf791934f0bb536731361eaffb234b29abd5df955fac2ab7b19c2556cfec5bbde106ffb621e058506ca45b489b4468bbef57be4367ed45d7dc3e15f56691f5a5f26d5767ae38793c31d3c2b4928c34dfe792edf7bf8bdd30e0ec5c34681054a83127ce17283930c7d007ab0e3db6463c664458e262a5afc7a45775d83bab757a2bef29e5fe68a69751abd84d0aff5c58862d0198d8d3c8e6dc35a56a2e72e27d43ecef9bb21796f6e2b4df735679c5ec55727cf075c0559d46c7982043f47bdb0566a489bd0aeb28a433fcae75303addac5c5f5fa06e5ede8cf3800ea11e0331b1ded33a8d1fa3504c6afed92132afd72203576cf6166c8adb6e9555bc252167be5bee7fe0f449a4f7d529f2d5f52fc436ef375ab75144e4e31ed1f6595107d3a2f2b744b57aec588688cdea71e0b0376ad0d0400849cb63edcaeba859e40b8f3e712be8b31f5f593d84e61d6ba79577545569633092dafa1b485b07773c3b9375b1b6559d9577845ea687b5c52a8add5ffef9eaf28550650455dd97f3a2a293b9ddd6d32f228ea722162dad9f940645b784ec5b70b92aa6bee240f74a64a1dda2f925bc1ffbb615fae4a2bc38fd3307da2cdc838481d78d8fcfbcbe92a9738570d113b83958cdd79122eab161d7994b455d089758583c367ad68b8e60da9b3de96e4a292b6bed77776e5ab0203aea2e9735b56de4a493a07ff6a4939f9d76ffaf38e9e4f5420d2d4d0d3fe7757250c93262c9cc5ebb0e19cf83afcf6a9c2fb6555bc15b82cc8a765d1cc57d4c0c4aea945dcea66c3953f5aa6258fd76a7ba0f518dc9ca6fa44bdb8181570865c52b2b719a4707e7cc674dd6d0d04be81c59dbfd5ecff1add6dafe8d36f724a7ecb7a4819de3b70d89fe95db86847a8af42ec6eddcd8eba9a2fffec54cd307a4b3d44a32d27da963f95a5b5dbfd21d5bd45e7da9d9472d7e5ec2bdc6cf4eb5b7bf490d799b84444bf2ae6e911e6a6a150a65cb977bef5505e1d2e6ca5f176e1754d1bcfbaa5db20c0c0298a03f32074e19ea482ef7d66953ace9d20a95d54830da146fabd5b3b6e1907069c9bc5d5396d48b094aa37ea1332dbf98c7b620a0b741aa7afdfd0a7f7cbbfb7d0fcc8037cb907b4e5e153a6a6cccd979e919d648759e5d9ba79a68c3870637e9baab6edcf96b3d9195cbe1abc78fe6c404d1d6cd33ad2c49a6ea362ff1c25dde7cb630fa9c5ec5ae67e339941cc6671a3994a7b4e422f752874c152e1fb354dd7a4422ffa34b2588cc30d4de56539ab1ccd43f4c90a344a9caa65fb238cfef4a71824c5d453bcf85b588f7cb8556a722dc9a3738489ceff802710eac0fb9be769ffe605a20efcaf5378343c7cedf7fa6e45780177eb2e3b367e58ea36def7431f9e7f6de9f41b821db53798693ff55f994f5ed3372fe7ef0f4cecefd0b47184ded50e8778a09af45ab62be7eb469616fdd71fe1b368590cad96452edfce66c5d9155d02b448291cd6598947f50b2e8f40bd2dba3f2dec75f0ead259e6aef693b659bc85e2d5986f10398182fa4467df656d292f543b948c846ae27ecadbd315629214e86e6af2d16087d583b77c99415e4c7c4888d7799a47fe181cd5e87cb35f15bd6ee7549da2c58a7d3fd7a79a397ff12eca73cb677973fec7a3b7f0db24cc3a2648656a80e589692641f722c090857e9ae52b5caacc5462eeb4dfa701375c78069b96368efe226e1c30098574ec2ee513bdbeb3cb72e9065def5073fa4be316e13c3c9ab0b7743cf5b6eecdc2d6c17b0d7f0915982baf909291bc4daeccab7f3f7522d021ecbb7765db43856a27b8fa47162a3e1a0c2a607e75a375d437971fe278e7d4f42b6fb9a78bec6da1b13b92e1eca6a2b709dcbe3a12f351454b72ed0d96c438af23564eb7d8900dd3df5ab0b6fb53d176e219c5eea6061aebcd0202e99c3cb4af1a4b16b19580d30c12bc88288e604bdeb98ddbe0c53c34b47d722c7ceaeb76d5eddb31c6f9cfea1dfb0e9f094a1b69609468e1f74a638f5dbcf4044e75afdfc17caedf39d06dbefcc34715ff1e933fd5c5535ad375641e3c23db1b52b9079e5865c8992c72ed5e50ce95ec67646a5ddae7d548995bcf45c0eebadfc98c4f393a4d0e84f118e3be9faf6ddcf102e52ced3f5764df2fa067eb5a75ea70d050ec4b477fd070ed12ae7a9bfbc5baa90c3345a79cb97e75a6c0fb27dd964aa579df6d8bb82e2f1a6e332a2a0f526a93455c131c93e40f644fe0937578ef50f4c254b1845a09ce02645ede2324c1dc0c4d4200ae6f194bd6da4ab7b376e5978a2f9ce85c08e6df8a84fabbdf44ccf2f9bcd85659fb225039998ad932e5ec44ce568ca1fd3ab85fb7456e70b06cf5a73f2746a90bfc99502d703772797fb24f069e57f4e00927b56fa155c9e9b207d6ca7fcff7a7a554946ba3ccf168928dce79fed5473a262d623e387af7dc959331e241d7fa57241d4d12d1309ad192c22c9ac320895f556313b223fac82975948d4bb676c6da3aa39cbe64b77e94eccc076d6881f8c9d04d729274306af0ac3bbaf34d6b45bfbbf56583f2f7b11ee8d6b258854b4be6e93c2a8a5ad585825b7babe46a46e5f6a99ca7d99e836c32f9a335e7a1d46562721da1b2e447f34dbd8e5989ccc56646af1f90ec5a64cbc546aa5c7eb3e9d323438e9fe33f9fc7611e2666ffd4b5bd602f319cb3b0f54b938575f1d006f495eeef572b0c699462292eeda2dce6baf9223d66df4b1d551106bc052eb5fea751dbeec7974b6a8d4375c19c80d304176c4eee8c74b995eaf8cd87949d9333d9e35f2eb29343d152268390d2f7971cb392568ca900e1e282d3d871938cd3aa5edc5c4296dd41281ccaa334ea52503fd77025cad78760824efcb55996f4d2e35e7f6c83bfdf7ee5b901faa04912b56add25970f83771c7900a3e678dad2762ec782282535b12cf5ca075de6ddb8f2c7c69fa7c26b8cbcd8862eb47ad3db78729b142988bb24266c7ed93359a9a3be78c5c8dc5f886e4add54c8f28ba5fde7c83cc10ebf03a1b156b5a74fc134fb631b7ed9a8d53d644e8c8d5582153396d3d09a940c0b0dcab5c3565267616774379fc12be84bbc794a40fc52ff4632e75333744a264670708cef5dc1b710d7ce32e8898a87eda8a0935ae6f280998c9c7b3cf6e43198727c0e45883449f6a0ba3056cdbc5bdec80b5ca5efdc282aa24fbfd166b0e3ce8ed64323992be4c99ff702687d0c8d5584ad3bf1a4bbd63bd5de5e75abb1ec9b977973614fb952fb6f4ff5de2fb5f8e4953b91a2b09094e91cc2e7838ff3c69d12b45be450bef6725c5455fdff1a5e2ababa8515f4e6323027a3f2c189c3b3baea14b48dafa74bb732678413c94db499023e2d3303975b7c3a4782ff1d72edafddd70f9d509bb66effe0e1b6d46da716ebdec6d94fb73fbffe7e33d88dc5493dc4f69e278efee965e5ab85b7ed329bbaf72314733535f6dfd6492fb4d6a0962dfa4372be41ac7c90277c255c53d350d408ac05320a7a37cf9ed5514c69e24e7c9eb3302d594bb5450eebfbe3e03fcdfaecfb003580cf8df99dec5e8453ff53cffabf27e05c6c35f94ebcbd4a925fcaa7ce3f69d06bf9b7e6513b85560bdd93a49353fb7494a6b1746e831c702c6a1d876e5b79ebcf147b419d7ec367bdc3e367859be6fb82af7f88e142eb9ec7589273adf9e2899afc53b58dcf1bbfa030d1c33d7c6f5a53b1fef3b3d3f4a78759d74dd9138de77b7cbf69bd9b8ef8879be38f49b6ce2f2b673164a12fc396a9f5235e44b186f6f37a8d56749e429bffb86af242309183933cb8a8b579d95e7151f78d86efe5e9ae78d85c8c5855497bbe5f03ead14c45cafa7e3a094a3fac1baccd5c7fa25edec1b3514cfcd5deee4c8b1fac2d20bcc54345f709956bef0b3cb9858f9c2be8470bb752598cb745a97ca9bed6fc181f4e5fbeeb93fbdd61c124d5d3927a41b5987e195589496714d78bd2397dda645ba552be9a488c88d38f5e379490afead1bcb30960013638ed4a79a75dc8aaa5829b541b9981ebf6c16ce3de4f66ccd859a42ca6e09a6ab3a64a6dccbac6382fde3a30acf298c2afed7c6cdc203d073e52fc9c5d1856d2ee485c7300a96aaafcb94d9b59243ea3b691e852b10310db7974d7bb34befaddd3fd79c229e6b2caccf99da7a2685bd2d64cecc1689443449089c5a9270a66ecfb7c5f854bad8fe1747973ed7fe665ceff9f298a3fab0ed5200c833492222726aaf13173ce1cee60c3e7275c9f6e72909bb0a4ef03759f4dc4c9ef3e6957786260a25bd694169454f0bffaefd5b949ff1efdb9c9d78b007a4b8e6b278c9feb0dd25e735247a63f91ea5f543c6516f37bff5bba5e4aa77f6cbeed715aa05414884220e5ed34bd3166b65cf6b1c50bfba982bb167dfeb3aa3eb360749f74e0af18edcd3736cf62646c62ee5d4cf2b7d9f9d3dd69037df85bfe2f53d05db7a24660dfcd09e7bca405a5f598639013031054834cd27d840ed65fbdce1ed29efe35d1d0d56b7a99b15dcb50c5d56e4561b95866640a688dc96eb7d31a6550a671cbf3dded3e16f5d737ffd16d17bfb9f25ee2bb2ebecd61d42abdcc8c41047ee54cc9db8539154b7fa1c3692ca79d0dba495d3337d0e8d0cdbfde14ec5e06a7e0f4697d190b05ca3f991ba47ad75067dbc2bb3de9e2bee7a2cde607d4216d9087f783317df7621578087cbcaf7a3586cf2d5c44f43c71d92e62a3b50931edd1cbfac80f2723c83f6a21e2afd79069db37467a0df6f80ca5f494616dfdede5c6953f16260752e9c45dfb55d2f89246bafba738ea543f91d2b73ec5b8467f683c7cdedbdd9db3747cd122d19d4513821c9ceddbb555066f3f58c82f9dbe78e4cfe87feb393ff06c5a11c65cd7389d5d66a7b8efbbc78710b8a14f8174cfe27222efc7e74bd1c98f3884467b638e3ce7be9aa1bb3bb8fad70b5a9ef2a983b33e50e22d51dea5bd5faad78de90fdc10e47a719853cf88557f248ee811ee73755bdecd319c3abfc5094a9652370b1b3dcf26c9c86f2de70430f8941051d67cea297596215379029e3350ac56bedc01de5e95fdff7bb7cfd2fced426223c5a417509f4dd15e77862ce6f0bb7a19d3da3607cd46367c8b2afd64bcc86eb3088de270a5620ffcc1981270f36e987e55fc8bbaa3ba810b7dc2a391ff6f2341fe41bef1c38a6d039fce93ae47fe5ca7932b2abd8f4e3f2968bd8bdc2724eab07f92f55fb9bd8149dacb64c322a3bc07ee6f900e26ad07265de1b33eea017b73825ece4dd42031b938e852df93420baa433509bc2bae38df0cfdc0ace5d5630fc499bf0799ec0f5708dfefdfb1f2cf55e57ed946c3fe3b2b269eee134552462561897338effa6dd1dac6b67e497b28fcccd356e4edf743bc55e208df3a51ccb40358009ce426abeacf7f6da35436c2567a30562fb44f8c4968ff3961cfaec9fad7ef6cdaaf076dc94f11a3dd058fa1033508f5a5770c2ba34506470aab81568ad891f72af987f39e07dc232832e8bb3477bfff60a43258844c62f4d6abc7041c820aa7ca8eb90fa4afb55a5060d73bcdfa67d01f1d22e895710f0a29dc40185561ba6733bc375f70c77cf3031d0d19cdedd7970e155c62ac7e1328e4b0093a30c79f2cc033b57c2ed6693ca296fa5a153cd3b8779a343797085bea4797d6050d8d929eb6a2b9323a0740366601daa2cb649aee0c09509983d9c117fad99eb46a096920e277bb673a08564bc28fe7353deacf9e44a32725ddba6fb2ae35dc2e2bcdb7ef657ec8f3a398b8a6fe67f6a305ce0ba93c195aa83ac53e4d7319e19b4ff63b8b017f6a60878bc2d7adecd4d34e6a9259564770c1e9cdeb46f74806ffdcf7cb029d5bbb653c2966d9f907d52407ae867cce13cb5ffc0b4ef5a3ac1cb77bd096753e04b524b4ccc815877aafbd61acf79f35e95cc8d18e0a120562619f47ba927b5aec327331478b81047932fcb2ccc17d9cab8ba8349ea7d8746ba3dfde9757bbf9be0f8d7deee71108b7de8ca57bb7585af469878f02da924cbb59cef3d4eee8cae3f24d430d3b5105996bf5de9442155f6e88b9365874f78e428a5ea55dd52b418548dbd1e71ace034f2dd364afdff91abf8feb93bcb7e76151f0788fd6fde59f69babf6def7d5fcb2fc833ef9d7bbb4dc7ebb8d727d3a533d66cbad63f39958639f2417d0698f032757575fcf5cfe85daa0af87d5708874bf6af5fb85079b7702b33c81dc5df197575665c7a8777677e3ee76b697fdaefe2dd9a9fee147bc1fdb575d7ec031d83ab4dcec6ca67db4fb01f3fd29ef2e8671399a9d5b32e38b2e8f884bcaeb9033253afeebe6846d4ffb76ffc5b194d3fbd3a50edfaa242338eb1505f72fc845db87e6ceadd83428bff2c88b6a695fafba9d05ed73f63c73388e2cad5f926960659fcb5917a0dfdafe285fd3ffc2a60fc9ee9a51f5a47cfd4739acf5f1b0ff89f5f144c4fb66d5dc01e5edade5f107dc43afcef9585ddd1961f36ace66a354f7878577536621a6974e35d816ac12d3098e1172ea911c7cb2d0acbea06cc6bae7372ecd3ea854d930b62e40caefaad6ac99d958f5b44d2023bed3e77c9fdf4deca768e323891fbe896337c64fb9ff224f5e176899b42e70f9c49fad0b6caaf165fcbd750180ad928cc80cf9c6e49c28b1e08ebc40e2eeb06d9ba9e4cca315356397a68e0cd675ab6907429891a8bab7f2c693e39ed677452b39795c783dddb08015724f29bba38efd464019d80430c146a48922e81e6cb6c87c83e860ca37bf4a27d3d6fe84fc790ff82b4fcc3159c6afdb39655d509960d27897eaf52fdc2b90adb9fdd0fcab0642f34fbfb8850815f7f21f0d292c3911f7a2e2ddbbc4c3e6f50a888bf63259cd0daf766f363f6a6d2dbe897670556fbacb894afdc646e2a0fc81072bd0b476d5b4d2da19ab92755615a4cec899b3b5fff63e0b8b38efaca52ca8575eccd6f45ba9480adb36c41f6bf964edaefe07ca225b0a45407089369d90ba03c1cb9eb23750ad5ff385d1631e98356740acf123d476fbc5b1c3590ada816ef53565986a8089b982043d894ba3088b75787ceedb967931f623b69caf77c155f8ead2e2fa6f8331b93e343a6629d2c8f398a1608d8d9f4dcf95a05012771cdd9fae4eaca7debeecb9f1fd92ea6721a879e94c4c64e9da01bfa0a94deab464608ded756266dee0caaef6edd735d0e1bdadae6063717be1e6ce050673027510d7fba73bb35d796c1a1fb1edb86bb0cb6837653342eb2f6fdf2390d6ac7ff97c0b1a780ca61778fec2f2cbd436e6a463d85f3ee7f0ac9634b8eee738ef86eac6971a430ca399da2d8e0e3912d9bb1d1005a3c53378b7b5f4377f7d12ca7f29e78a28a088b49e594c8d7b7420b7e52e44fc8b9bd17fba918a8cdc483ebc45c3ed3e59cba0d372e92a8147a106d5ff8fbb2f0f8772fdff9f194b832c85ecbb644b96905d681864295bb652b66c59b33396c328644bb678b2644d945d458821eb945df63142488591e57739ae3aaeeb774e679cbabed7399f3fe6afe79ae79ee7fdbaeff7fd7abddfaf7b1edb92ea14987071ea8c13ae760180e9cf04d615f5e48c0a3067222b9f4ca90b43032ccea3a43229571218527b78ab0ad7f3834958c44220f1fa091f2bb4b48e940f16848f4bf1f8620fdb67b3741620aa54e842cc98ffbf68b83f4edafd8018b26d41a01fbeca16b49b1d7f0f9ea4a1631fc813a937f452dd50577479dbfd963af4b542ed2903e1e09b6c6cf6db192f7866318e11ee628c2cd242cd55a415259f02081a0cee86df389283f93c5a5f0d7e00c281ef0357aa9a7a79247fb3f4411fbfc62da7abc87e72e87ee1b08b4c71f475610ea9462fbc6772180eacbdc77e5d7f6dd127cd3296529da988786d8cddbe6e96355d3d5a8ee83f51f4813d4d3b19e4dfc12c3daeb04eaec59eb8f462c2502e3d54e6c5a171a608394934a0bb22466f94d63d3c21debdc46370ddd1b53c37a0a1d4c88ac67ae3c5333462ea9b8896b97ddd223c4a9d4885c572b455285347e24a610d04b97089c99b533a10e03a873746c87d229afc9f89e81cba0c354191ae561356034037a1c489f0158ee8a745340200483ce9df7d9e8d70a0975883d1896fb55dafd259179b9e164c8c8c2f51862e03015e386fc679e32a7e7a018ff366ba48e262c226cdb6279467259342656d8873aa0950201c411330d299e5c01c1948155071a66004c910529d9849d95a363f9f365a77cc93f1550bdeb1ba8523b8f9070b99dac7423c607fc542b20d1bfa7f928510d58381cd6d53472f92b02cc97b56fdac19132a67fb8802e8275e87c355830b9b97d20d00e7e177b1728d2c27aac86cdee4918c8a0c9cf88dc67c715bfeb9879931f3e680c477c717fb411c5f66fef90bc2be304b87a3f04469d326d457b832f3631ff7c4582b8af6345de9c3802d9629c9fbf69015268922da35314f48e32dee9a5a68054ea9e5c28ed74ee79bbde5ef74b0e5ff6735a8835cffd72eff73e9758e85627e60a38e47e6120068788061eb6bb68de493538bde6225ae163e8047a05aea293e73519d2c860c2d6627484a8cf02bb25cb12ed5f418dd50d466cf2e2fb884dffbf75db4b95ae0561d9b74e57e18817cf2aefefeb238df9796c9d95a22797728ef14008209cc3223e7b33448df67642642ad385643903e51cdfab7c6a2cb863facca2ced922ca95fd1ec89006ab7ce9a57f4083569b3483c1ab8e63c56a71d04e39924b359ba669de2aae82c049c99469b64caf1e6b0adf2ea4d9aea1a4a170482c71539513d172291aba76dc9bf19922ff149130a278dbfbdcae75458de51c4a6203c9bf3ec8edf45736b939449d68b77f05eca917b8664b77f89e0f2dd843f2be5bfe06c37c7e7ce78b96d16c2888ab62d9b599468adaf465cba7611a0b32d6a7d4333c14b61de3f4bae014f78c0fde471ad8e3553db75f1f6ae681fdf6a702508077e0a7c66ab3c6278ab9e694518ed77e62502ab8a3dff86d324c4aef890476a8013cb32de018ac681adbee70ce87ea7096deb8f7346ec5dbeb77c0fb411911e9b44921462d96172c7da939a26af8a97192bc7982b9002fc5c370280c63e54fdb272c686ba0c99f0b62f5557367965c6fc8add35bb39d5efc3921c64d813204862166c896880e1716ca776bcff25f233a41b30bdcec80c8735c3931e35c071770b2abea98240b9a6a5b3b9d3d44ccfe966faf22548b424c2cb4f18762106bf0f4bba7f1bfcbb618bcc54f886de7d585c199b34fde2fdc4c68432457c0b56db58f1406447a3776a01e099106d21338488beb83c04cdc9b09c8531323fd112de6e17218321aba5da73f6fa981730f10d9a5c823e6313ae62759d5802d94e63b567b95eec225b57278582b57b434221cac0430da8a12fb0aaa8d889b1c716f82087d64eb2357f00053e788a0a826b938077718ba9af26a205e1888e00d051651e8139d4e455adcd12d9707ab3a31fc37cb050aa4eec6d18a7fc64e704deb78cc31136ee39b9380eeee4820f59d322636a7dd80eb378cc45b7a8587d2c8bfb97e7727c9c5c1180958e7bf66cb31c2832e6d92cbfeaea369350f6adcad2ce8bd0abf4592b95c061c0e76e3dc1722d98da4d869da7c7ef5629249566f45509ddeb410d21a7873529b0ef12deea3f28e1e7c3328349b0a7d30cb8238094cab4b35fdb481f893ce41145850919e25eeec40146812ad8d5ca693deda352a6aa794b5845a273b70b02edea4a2451fc3b67b00adf7bd4c4fb17b9701c9e5b8d3285fa8ad767f10ba9348773e41f50a73a8c0586d6230048340a639faec54a7a41354b76e3ed8c95c38c1b8d48a94b058dc290d8a5f348e0ba2c751b91b9c5c504e355c932f123d471500f849d183cd167ca4909d3ae706f8faf181f8caffc5971e17fe2805ad70295920b5a9d425263838bf70b46a9222cf7a61b51086dc6b593f6b3cd9c01c0b9eca50f4e2f9008b113cf6a74387448aa3f4ddea17f55e43a1c48434bdf777b6e9743481f8843008b1c9e9a4bfc3c748b5276ab41819fbb1eb64ffcfe5b8815cd1d578f267de0b5e7bdefeb694a003240bdb8f7e2ec08474d90eb95c4866ec08d596bc9d3a8fa7a029d92896c9d7205ec29347fdd9dd9939f81ede3ac2f895b350403c2412600cda3cfdba0415c57a268f97f0b94c3c42852703a600a8e0b1a093ced92e38f4bc73b2f26e020f17fc881e9fd72a0feafe480944ebcee4fca01e27a04c0c860ddfe7051bc7eb0a83d91c8d1adfb9dbff1e711afb420916c1a448168c857801663ebfd6640cdc2103ea137b53c3569c3d8290f49f778c7ee956ae23e9a77631718f70301036f1614747850728b2ccea69d31f7da90f2e649ffdf136172a4653f307ef37c7698048c667d1ab130a2d038e55cac055e5b966c0dafdc02f469b55cf2c4ce0979255defb21f7fcff3fe4d09ad01a8aae6e3c7cb3e8dbe92647b6beec6afd508d7aea6b5f9b5e80c8b8ebfb6a63a9fe19060533bfd9f58736ede03e59943dae5d4f5d2023b3bc4645f3ed569aa070c905a0f16d6c2f3357b01d618cae20eb22a3d78cfcc391345c93bc5341cd657f559adf99220d8b4e3d43e7b87425fe7cfa62fa0c12ca9156b8d0d98dbba63693e6942433225f4b7e23af4d2d9d3f09ee589fb0e851edbb7537d68feb9544df8825c8d58c2ea5d17eda9b7646f1972b912b4cd593d3daea4aa7fdd24171850060ec9717871e4d731a13fccd527f61535e6de66121077b25639db5434df9998eff74d13e47d72e531876f6bd159b2f913930ce6c1d5cd4b37d846a2ac6db891924a157d783f69d29e2630399826f8bbe4ff8f354109f9715213553d6355818a76497b47c63838ea5e780bf7a6acc0c8734c54f23d002a6496d48b75f832a1b166c472c2c331f30282ea665e66607afb910ee913fd65d5e065100ebc00385e3ff17c6653d5cf74b22d92fb26e1dbbbc76e64a8c06adadd027da92ba3ce7ae31da0141c38bdaa6bbd83f3e006a1bfa381ffb862acafb37151882a3a81d95db79a7fddf8dafb23d0f317ae425978529fd75241474e0214c14484665d32d0fec3332dd45c0587f3a1b26fc3535a9e5a3b5f6c77e10dc3ed42ee7c30c8ff0167c50f72494ff10537e788dcc75f4d89233b121ed0849324f42550e4197af1850a4a43f50038abce58ab3fdb97c36ed30123e501299fe6ebf2da57641bbd9b1dcb03099937aa4640eb830076c52e4344d96b9ef96ca6fb43274ce1cc74e33944eb0aa26068f0ac8b0f78136fc0d3d62377370a995f711432027846dafea4b6d8993d0379a682c943a9dee6f4c6a7fc49ced512f9ee8af75ccd148029733fcb51d39b14e82ee9b595c9de3ef74bf22a8e3708300c15fde8cd858d8fd584c6201ca10110620cb2dca07add2e1f089bf05473c54595d984131f2a80c8b71abffaf8b05b10efe74bc71142abc12238b050f0a189507b385a3a048c284ad097a4a0acbd6c12553ce855c37cc8189e5e7aa80a51d5e442079bfc1b18d97f6e1a9cf0ffe1657be0dd8fee6d91e55afe37e353fd0e04efac02fac9a94f4cad36da0659fcb6342bcbeed3324c371202b87a775843f50601db165de5649f4be414dc2f83bb798ffb7c8589bce20c73c435062f7e94af3b1ff42d6693ff86983dfa51675f8f6cfa87dff7b26608c02b66a237a8a21763730fbff1e4a07edfbdb3c16b9dea0a3fe7ce503094af258745da0090e5de0f61f54a56ada14cc96aaf06ecd59d079f9e66582c6e49ba37a8da1f4ef12d6653ff869845fc44cc88f9d93aedf088d92de0b4d2cc1d27ff88cc42bb64abecb0e8471e8f6a47f3087afafb7b1727ad32cd8d01f2d3495b1990cd378b4c02a26cbe16616acf95b86256a52763c96322ac75dce7aaecd66d39f02b77a22c6d0d3e838dbcb70dd36a1ea7c913a4385c6e34cb4737151de14bbcdb3bce02088ff0760d8b2d7bc35081bf853b16d7570ed2081ec58683bfa87d40bdd09775ac06278270e0388081bbbf3f5ee87295478fb88524da5eacd4e77e0955ef619a90d202c8d5c2bc28bc930b8003abfc210f30fbe4c1a3eebf92078a2f29197e4e1e10c8d58381a3626e23fdf14f1b261402da750767331a1ca2065f691dc73c5f3575ce545d4b02fc4ba7e706f5dc8695dcdedd0e7abff205414f5e1d298c72af3c26d2d1969fa2b29bf54d7f4dd6b7dbda2229b430599e9b12324445e545da2077348bdb569c4607e60760845acf00a7c6f1ecac116edeb5e2c910dfd4fb7e1b8ae9141a3b40d9329ad3cace2dbea01a920ec24152006e228e37d26766c7b91b5649635d7bc8a4d0f3062b264ca03b75cf08bb86efa3f106261307d1acfa0a595fc7f3ef89c2da7a6450cb7f527b29c7b632ddf7a0f71098e4f017687ee03607e585fc1f38125d241db744eeba6ee4396707dae590296a84d2d05b8e7ff22b1c4b22ce0eb39e05a4128e1bfa7e323d9673a572baa660bdfdf69965cbd8da159c981cff9df93922fa3dc1e5f26b05d711544c4b22cdc9e5b98756aa8c6a6b0dbea16941ff09c18584d2c4c66c57d20adc2aa917bcf4785bef50de2663c5cd2b0647e62bec3e138b02a61770236d5dce412e8564e853a3913df3dd102343bb1ad2b759d85287906d996a88300807110444eb4a9315a2e73e37f1075bf0713812703ebd328188437629b950da747e09c59f6767e3c0a37b18711e0c23cfd703fd3e335d12ddf7270e45d06b680a299e92fe1f28444500c69e4ed69878761ca577100512bed36e3630e59ddcab5eb53c245d2ef59cf82a20b3186f7a51aa8035f9f5b2b5a6522f6b475627ef73a9741706e15e969b719a6cdf7d215c07f285fcd9a4af070329c746938d422f67de7022d37f8498459f4f149ef50f71f92097c6547526895b1670999a96e9e36fe315d1379379894db6569ead7eb460763b52fa6d992fc2ef02e65b1bdf656c504bf6b4088f1ccb3c0a162b2bb465cc390cdd316fb821ee21b34c0fa1c27bca3cdcd7c667d85f51c5bf8dff0f26073e5ef870c7e0ba37b9a74ec9bd93e047493b472a050130456e64d4c360e34b77e55d8d000d4a61ddbe8b3af09a00356dea2f26d1e68a3c5fa508c68aeee4a189178edaebffbf000000ffff1ed9a0d101","nonce":"0x128cd","to":"0x8453100000000000000000000000000000000000","transactionIndex":"0x3b","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x41535904d7b20be8d733e03d95ec725d0c6ee4307d899cd00e0ca0de91533b13","s":"0x3f98c81207d078199bf74a600a77cfa389574646d63ff55ccfd194491faf7226","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xd3343d473f624c02045a01f4e7ab604bc56c4f42","gas":"0x156c0","gasPrice":"0x7d9f6fbd8","maxFeePerGas":"0xf49895cde","maxPriorityFeePerGas":"0xcfd6ae0","hash":"0x00b5b05c6d1a2eb8abe2c383da600516515e383fc8a29953bb6e6d167e9705b2","input":"0x9aaab64814636b3e36ce9c4227a5fb53273a04c3fdc94c8a00a4d6d5b6521571b94ec7ac00000000000000000000000000000000000000000000000000000000000028a416eb20a9e75d33ef7eeb4a0bad7413cea6c0b3a7f6ea249a93a428c0c36b52240000000000000000000000000000000000000000000000000000000000840244","nonce":"0x6c7","to":"0x1a8b038f5dff48f541e8cc658b9e186b9828a726","transactionIndex":"0x3c","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xfcd40d6ec6fa94f40f866c18457c22ebf5d8e3aaf2616c4c1cee5245ce8f042c","s":"0x45e5962efdda48e38f706cf8fb7c2f722d80da6e0a1d2589b6627627b44feb82","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x9aba7eeb134fa94dfe735205dda6ac6447d76f9b","gas":"0x3e64f","gasPrice":"0x7d9f6fbd8","maxFeePerGas":"0xf49895cde","maxPriorityFeePerGas":"0xcfd6ae0","hash":"0x6fc411f24c7b4b8d821b45de32b9edc5ac998d1ac748a98abe8e983c6f39fc19","input":"0x2e260ac30000000000000000000000000000000000000000000000000000000000000200a5c46e2dd70854a0fe8167b705eb7df71cc927469c345248c81b21a5ab2f5f19000000000000000000000000000000000000000000000000000000000000051d000000000000000000000000000000000000000000000000000000000000051e000000000000000000000000000000000000000000000000000000000084024700000000000000000000000000000000000000000000000000000001b3fd9f800000000000000000000000007ebc0d2451003f2d3bc5f6eafbb7e6bad81e250d0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000640fdea40000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002e43c000000000000000000000000000000000000000000000000000000000002e7d600000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000f6cb686532a3ece4a20f823e59cc386e1ba384d8504e902c932fa1497c4afdfb0b000000000008008402470000051e00000000000000082ffe82e7b18f0778493c989ecae1740325207ea29328999d5ae646723a4bb75a1305c8ca593670972f535ff8afda050351549ed800e9b98c805788acfe20e6ac076ae024efa64ac3ceb8f0a3cc9ce93d122f6faf8376c854da95567fb7576f762299ca2135608c7ac5a824257b50043526903fc8e01ad88006448a69a4afda4c01ad8a6ed1260582538f2311e902c1e7d5853a75b74482117f2cf920897c1b9428eaeb7e74a95d3d32db03931d157a48aaca9748bfebfecffc2d140caddc66b300000000000000000000","nonce":"0x108af","to":"0x7ebc0d2451003f2d3bc5f6eafbb7e6bad81e250d","transactionIndex":"0x3d","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x1b284cf86146fa2094c7c709cf9fcb8a177f4fde1d1c5ca112e41f82a5e973d2","s":"0x5618261c40d23e5beb7ac0bac77b16ead56e547f103f649462387c5acdf18ba5","yParity":"0x0"}],"transactionsRoot":"0xaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa","uncles":[]} diff --git a/op-service/sources/testdata/data/blocks/pre-shanghai-bad-transactions_metadata.json b/op-service/sources/testdata/data/blocks/pre-shanghai-bad-transactions_metadata.json new file mode 100644 index 0000000000000..3673671aee608 --- /dev/null +++ b/op-service/sources/testdata/data/blocks/pre-shanghai-bad-transactions_metadata.json @@ -0,0 +1 @@ +{"name":"pre-shanghai-bad-transactions","fail":true,"reason": "failed to verify transactions list"} diff --git a/op-service/sources/testdata/data/blocks/pre-shanghai-success_data.json b/op-service/sources/testdata/data/blocks/pre-shanghai-success_data.json new file mode 100644 index 0000000000000..fefd87d7b0719 --- /dev/null +++ b/op-service/sources/testdata/data/blocks/pre-shanghai-success_data.json @@ -0,0 +1 @@ +{"baseFeePerGas":"0x7ccf990f8","difficulty":"0x0","extraData":"0xd883010b02846765746888676f312e32302e31856c696e7578","gasLimit":"0x1c9c380","gasUsed":"0xa79638","hash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","logsBloom":"0xb034000008010014411408c080a0018440087220211154100005a1388807241142a2504080034a00111212a47f05008520200000280202a12800538cc06488486a0141989c7800c0c848011f02249661800e08449145b040a252d18082c009000641004052c80102000804ac10901c24032000980010438a01e50a90a0d8008c138c21204040000b20425000833041028000148124c2012d0aa8d1d0548301808228002015184090000224021040d68220100210220480420308455c382a40020130dc42502986080600000115034c0401c81828490410308005610048026b822e10b4228071ba00bdd20140621b2000c02012300808084181ac308200000011","miner":"0x0000000000000000000000000000000000000000","mixHash":"0x31f0c0305fc07a93b1a33da339c79aadbe8d9811c78d2b514cd18d64e1328f25","nonce":"0x0000000000000000","number":"0x840249","parentHash":"0x2303b55af4add799b19275a491b150c1a03075395f87a7856a4e3327595ed7df","receiptsRoot":"0x99da71b17ae1929db912c3315ebe349d37f2bb600454616fdde0ee90d6dbc59e","sha3Uncles":"0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347","size":"0xea6d","stateRoot":"0xd12bf4cf3941cf48be329a939b13d3403d326841c69cdcc9a9c13ab2f227e904","timestamp":"0x640fdeb0","totalDifficulty":"0xa4a470","transactions":[{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x1b7aa44088a0ea95bdc65fef6e5071e946bf7d8f","gas":"0x5208","gasPrice":"0x174876e800","hash":"0x39c666d9b5cec429accad7b0f94f789ca2ebeb5294b8b129c1b76f552daf57d3","input":"0x","nonce":"0x26bd1","to":"0x68643ada5885f14e7c15c13bee06168eff0f7c36","transactionIndex":"0x0","value":"0xb1a2bc2ec50000","type":"0x0","chainId":"0x5","v":"0x2e","r":"0x26e648625520c256d87d8e15769e8c4290d2a7e27147594815da42070870825b","s":"0x7db34c91603e51494b59b020597e7118433d50ed548bc7efad8880cbe7820ca"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x030b1cddf635e9e71ad70b8668e235e8ec3c67c4","gas":"0xf618","gasPrice":"0x1701ca2b9d","hash":"0x2ca7289ab3738d17e0f5093bd96c97c06c9a2ea4c22fc84a6a7fbfda93ce55ee","input":"0x","nonce":"0x456d","to":"0x89416096a0a1acad3436a357478c5c548e4d382b","transactionIndex":"0x1","value":"0x16345785d8a0000","type":"0x0","chainId":"0x5","v":"0x2e","r":"0x5aa6ad410ea42dbff3781de67b4815a376cd459206595fa6655c966a7709e5cb","s":"0x82f620f8dbc356dc38ef346d1e152656a1d318becbcc41884f61e85972355c0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x9c67435ce8a33ad23f377ddf08260ffc56417f21","gas":"0xf618","gasPrice":"0x1701ca2b9d","hash":"0xb0085de1476530de3efc6928c4683e7c40f8fac18875f74cbcc47df159de17d9","input":"0x","nonce":"0x446c","to":"0x471f3a988a77472e971112e7ff2ce65996b6c8cd","transactionIndex":"0x2","value":"0x2c68af0bb140000","type":"0x0","chainId":"0x5","v":"0x2d","r":"0x75425f21a6e66e6feaee79455c897656c4a94b6189c4c033facab1b67812fc3f","s":"0x7014f4b9f760165c7757f9d6dccea349b3d00b0a9c2f845af8010140842f826"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x168f6dec26cbbb3749654e0e3cc4fc29314fdf6c","gas":"0xf618","gasPrice":"0x1701ca2b9d","hash":"0xe01c8631c86ded63af95b8dbc0c8aac5d31254c14d6ecb4cc51d98259d838e52","input":"0x","nonce":"0x403c","to":"0xf2119a49a3ae35453c1c2704da248d08977084f1","transactionIndex":"0x3","value":"0x16345785d8a0000","type":"0x0","chainId":"0x5","v":"0x2e","r":"0x56bba57ee69c09dbbd5167d0fee07d5803130fea7c278f4d8b7bc54b34be8ff9","s":"0x7eea69c0de47b6b808ea1bdd9ecf5d25f4f2743e867b1f838db59c456026d7e6"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xc9af69904b4ba7f0fb69ab1a8719bd8950265e73","gas":"0xf618","gasPrice":"0x1701ca2b9d","hash":"0x69414a126a6f07ab5e31ad2f9069fb986b7c490e096898473873e41ece6af783","input":"0x","nonce":"0x44c20","to":"0x6adc3f5394e00cd067d1fad5a33756791e303c25","transactionIndex":"0x4","value":"0x16345785d8a0000","type":"0x0","chainId":"0x5","v":"0x2e","r":"0xdc9a52b87755cd07143bf032d57258d0d6c36500b38a574a9a5addc1293343da","s":"0x581e6fd051d0c72d64303c1f90edecfef46580f84f24dba930cde910923f7c21"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x92964e63cd52450e6e09a266e0c226e524754563","gas":"0x2625a0","gasPrice":"0xf5686c7be","hash":"0xa2fef1133ee726533c7f190f246fede123e3706a03933c1febc92618f90d2804","input":"0xa9059cbb00000000000000000000000011f7db5a824eaa5737c935ad09a925dd707f092b0000000000000000000000000000000000000000000000008ac7230489e80000","nonce":"0x2636","to":"0xbc071c64ed8f536011c78e847755680740d6b73c","transactionIndex":"0x5","value":"0x0","type":"0x0","chainId":"0x5","v":"0x2d","r":"0x422c5026584cd8fb8a1fe66e6edc7a020bc513cc3114083fb35f9846cd9a9792","s":"0x7fcd4e48ac5b53d881531a5651e587188157ed88d85c51533f7c6eda94c67ff7"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xdec1bc71bf91431d60ef2742f412dcd1c5a204b8","gas":"0x7a120","gasPrice":"0xb80e515ce","hash":"0x6585ec5c4c2bbf1f683f90f58e18f3b38d875e94457fe4cbb7bc5bf6581f83af","input":"0x67a5cd060000000000000000000000006343e96c99e2725e845ba04f90e03d853cc9bb2d","nonce":"0x6a5a4","to":"0xf5de760f2e916647fd766b4ad9e85ff943ce3a2b","transactionIndex":"0x6","value":"0x0","type":"0x0","chainId":"0x5","v":"0x2d","r":"0xcb7b32949ac0dedd3151d06d85ec4e99483c8ea706f12a009d97b055975241eb","s":"0x69f0009bce12e24408f9a3d5ad5a8578e2b23efb09002f7b86b3425cf8748889"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xdb954dd5d224004b26cfbb089312e0542e5d1c31","gas":"0xd5ef","gasPrice":"0x9fc748df1","maxFeePerGas":"0x116482c049","maxPriorityFeePerGas":"0x22f7afcf9","hash":"0x1db276b864fbf01dcf8cededf8d597553ecb0eb9438edfaf2f5bd0cc93297c66","input":"0xa3e35f36000000000000000000000000f18f2320e4779f21d6882d83f9133e582dfaa9b6","nonce":"0x570","to":"0x11672c0bbff498c72bc2200f42461c0414855042","transactionIndex":"0x7","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xf23a1fb0d17cdbc2831a2cb0b779795e12533e34425a3abbc4b7e7bde262b92d","s":"0xd4a2c8189378696065b7fc5d13e9cf6595d96047a31a4fcb812c2e677d22a26","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xe84d601e5d945031129a83e5602be0cc7f182cf3","gas":"0x249f0","gasPrice":"0x9502f9000","hash":"0xcbe7ed31654af4e191ca53445b82de040ae2cd92459a3f951bdcce423d780f08","input":"0xa9059cbb000000000000000000000000355f96e3261cc8237d2d36fd81cc9b9cdcbfc5ea0000000000000000000000000000000000000000000000000de0b6b3a7640000","nonce":"0x4f1f0","to":"0x499d11e0b6eac7c0593d8fb292dcbbf815fb29ae","transactionIndex":"0x8","value":"0x0","type":"0x0","chainId":"0x5","v":"0x2e","r":"0xadf7dce5f34d482bb19ff0c85f43be7008cb838043f9abb5fc08421245ac4228","s":"0x5d2c0f0b9d2e68bb8da6084e4971d57bd76bf0cd9d893c9c985962812d2df026"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xea0193f88a0d9c36e83e6fb6d382212b6373faba","gas":"0x43238","gasPrice":"0x933ea77d8","hash":"0x808ba5211f03cc78a732ff0f9383c6355e63c83ae8c6035ced2ba6f7c331dc63","input":"0x9f8420b300000000000000000000000000000000000000000000000000470de4df8200000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x0","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x9","value":"0x470e9f23394000","type":"0x0","chainId":"0x5","v":"0x2e","r":"0x9536f87e8c3433ea23ef7211c0c32689551906dfdf31bcc73b89fcf18fe86a92","s":"0x3e94bfe3b4ba32a6ce71ee6e0ff9f26dfc2b0d61b5c0fe049469e3c4b88ac227"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x1f9ab300b380313e6a2208e44c01a0602538385d","gas":"0x32b38","gasPrice":"0x87fc9eef8","maxFeePerGas":"0x2e90edd000","maxPriorityFeePerGas":"0xb2d05e00","hash":"0xdd66f1f26672849ef54c420210f479c9f0c46924d8e9f7b210981ffe8d3fac82","input":"0x32db5470000000000000000000000000000000000000000000000000000000000084021000000000000000000000000000000000000000000000085b0af981975a40fc5a00000000000000000000000000000000000000000000053ae1f470262f3b01c4000000000000000000000000000000000000000000000813bca9f8389ffd193f","nonce":"0x5699","to":"0x28cea7b0f3916c1dba667d3d58ec4836ad843c49","transactionIndex":"0xa","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xbe8eddd463a3518a4c94b5922c0f2fb26a32c8afcd819f7deaf4f0416757ad13","s":"0x3e234182acd5261dfba3cf4f125d1a8377fc707b3b1900b565d1a6b8987b398c","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x1d990a2cf61b46f37582dd31a7b242e989e1a1ee","gas":"0x493e0","gasPrice":"0x86f96eddb","hash":"0x254abb2f8cdcffe9ef62ab924312a1e4142578db87e4f7c199fd35991e92f014","input":"0x9f8420b3000000000000000000000000000000000000000000000000002386f26fc100000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x0","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0xb","value":"0x2387acb3784000","type":"0x0","chainId":"0x5","v":"0x2e","r":"0xbfe9b99fd2e9bbd2d65bb4cc17da88130d8f6b569a26afa642ed1cc8efd2e2ef","s":"0x7003dd3962eec2369bc5abe5e3d5b73a9086a3219643b1741f3a9832369448fa"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x1124bbb196fd7b61947f6f03b7d7cebde8340b6f","gas":"0x493e0","gasPrice":"0x86f96eddb","hash":"0xa7b7c654e7073b8043b680b7ffc95d3f2099abaa0b0578d6f954a2a7c99404e1","input":"0x9f8420b3000000000000000000000000000000000000000000000000002386f26fc100000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x0","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0xc","value":"0x2387acb3784000","type":"0x0","chainId":"0x5","v":"0x2e","r":"0xe8dae9efa8fa73a3aebdaa75ba12acf56712b1f99fc128ab802a7610d014547b","s":"0x2ef347ea90a0db21b035637342bfc916c9962d3ec610a4e99cfaf555a2606fe2"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xdedf52a88fe47f6a11d629badd0096d201aef86a","gas":"0x493e0","gasPrice":"0x86f96eddb","hash":"0x7ccdfa698c8acf47ab9316ed078eb40819ff575bcf612c6f59f29e7726df3f96","input":"0x9f8420b3000000000000000000000000000000000000000000000000000003a3529440000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x1","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0xd","value":"0x45d964b8000","type":"0x0","chainId":"0x5","v":"0x2d","r":"0xfc4e092094abc7fed9cf11eea8ad6ec3a760d13b9c603b5570c2143e48090f2f","s":"0x31a0a6016ab51ed6375891bf532d9031bf91c1d0e01df63cf7e46076aeee83a3"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xe1db1fd154b344ce7dfcb53a65279559b298f0df","gas":"0x493e0","gasPrice":"0x86f96eddb","hash":"0xa0b035ef315824a6f6a6565fa8de27042ade3af9cf0583a36dea83d6e01bf2a8","input":"0x9f8420b3000000000000000000000000000000000000000000000000002386f26fc100000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x0","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0xe","value":"0x2387acb3784000","type":"0x0","chainId":"0x5","v":"0x2d","r":"0x79c316492bfa36fa4de2dca02ffac77f6c1772714e153aad8c947ce848d4106f","s":"0x4fe3e083943ca8f974cb0752a2ffb70e4d6c8b615e16ece7e19b2c464be66929"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xd4c3777e1821f6fb532957104e1317a9d3f881ec","gas":"0x493e0","gasPrice":"0x86f96eddb","hash":"0x1ebad7f3e8cb3543d4963686a94d99f61839f666831eab9c9c1b4711de11d3d9","input":"0x9f8420b3000000000000000000000000000000000000000000000000000003a3529440000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x1","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0xf","value":"0x45d964b8000","type":"0x0","chainId":"0x5","v":"0x2d","r":"0x5c1f544ca92b28a014129a9d04f8e895dc8a6987ddc1717c26b0619bb9bac420","s":"0x47574643bd92a0f129f9c5ce3caebe7943cfd828d67fb0e5bdc1eb2ca202822a"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x127418955b15f5ff2fa232431a798b53fd006c82","gas":"0x493e0","gasPrice":"0x86f96eddb","hash":"0x501750278e91d8b5be1ccf60e793d4bbcd9b3bb3ccc518d3634a71caeac65f48","input":"0x9f8420b3000000000000000000000000000000000000000000000000000003a3529440000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x1","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x10","value":"0x45d964b8000","type":"0x0","chainId":"0x5","v":"0x2d","r":"0xcfc9894bf716ba707521f0969082afb688b7d47cc21f1423b239c40867128f47","s":"0x5d9b9c66d8437d0a37768fb9c3241ef64b7e795d0d908196e1f707215ac1f56"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xc2ac1bdcb3dd77864b99eb2cafef2ed36c1487c3","gas":"0x493e0","gasPrice":"0x86f96eddb","hash":"0xd80ff8af29ae163d5811ba511e60b3a87a279f677bb3872a0f1aa6d0a226e880","input":"0x9f8420b3000000000000000000000000000000000000000000000000002386f26fc100000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x0","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x11","value":"0x2387acb3784000","type":"0x0","chainId":"0x5","v":"0x2e","r":"0x8bd7220d176d18cfbc824063448cf864c494fcf0958dec82126f26d3fc6c0b6e","s":"0x2f4de3d2fc3be6d2812ee10aee16a995af5affcfec27f9953ae609886d2b563e"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x11a5ad000f8494233df5bd2f2573fe20bad744ab","gas":"0x493e0","gasPrice":"0x86f96eddb","hash":"0x096acab3b3fe47b149d375782d1eb00b9fef7904076d60c54b3c197b04e6bf82","input":"0x9f8420b3000000000000000000000000000000000000000000000000000003a3529440000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x1","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x12","value":"0x45d964b8000","type":"0x0","chainId":"0x5","v":"0x2d","r":"0x43726c3165958e94d80cb6992121f55df2904a1de4356e0a6ff3d8bfd03c0928","s":"0x6244361e31daccbb5c7e9f3f7d01004080d2efa314d614fdc2aad4c1b7d71613"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x90f8b290ec2929cce086826e971cad3857c6dbb5","gas":"0x50f46","gasPrice":"0x861fc89f8","maxFeePerGas":"0xe22924cba","maxPriorityFeePerGas":"0x9502f900","hash":"0xbe9d1738af74a22400591a9a808fb01a25ab41e2e56f202dd7251eb113e8ceeb","input":"0x6ab150710000000000000000000000000000000000000000000000001bc16d674ec800000000000000000000000000000000000000000000000000000de0b6b3a7640000","nonce":"0xe4","to":"0x2e84c9894f628fd209f48b06d10b46c8cada4c10","transactionIndex":"0x13","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x412c7bfb0236a4317da40645ee4e60f19185e7d0cd2cc9bc88f7629de505b939","s":"0x4f6bd485d10fa134926ec3e3a83e212f3c5d903ba52da87f07794a2ba0a5c1eb","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x7915ec065b644568155c4772a286addad3864c1b","gas":"0xb71b00","gasPrice":"0x861fc89f8","maxFeePerGas":"0x1176592e000","maxPriorityFeePerGas":"0x9502f900","hash":"0x0834c720e55cccd97aaf4f8fb0cb66afb9881fb6a762c0f70473ec53f98a712e","input":"0xedce8b4d6a1fb55588eadfd3a0c3350435a31d31e7c236125eafcc2a892d50711d9a4939a4282888c956c070cd83400fd47ab83bd5287244053b8228711b07386dccacbd000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000001a0000000000000000000000000000000000000000000000000000000000000082000000000000000000000000000000000000000000000000000000000000008a0000000000000000000000000000000000000000000000000000000000000092000888ad4975d4079d80bc6da5ded57746f889644719ec160efc2e4a96ad645df10b1683afcd7ce41ba6c06528761f821cbc6e806ef4b71c189603ec218b12a1f1478883498e67b97ae4babef6996acc582db1377d8755374602e00b8148025ac2d2f52e78d7484919cef14bf96e5b7a3f7f8cf09989551888f2c697052ce2bdb02a9296b20016c78683a9ca137037e57c8ff25198146f9d4cdb5a25ab9c95a03038f22f83c8604ca7c035ef756d2963c3657eea4ffb18ef967752d8cff15a16124a1d92a1cda613624c98e3078742803da1417b78bb264b7bb2197515cb4facc2ea395c6241664dbd953d0034900a86eb94897bf89aae775a1d73e6fd034785400000000000000000000000000000000000000000000000000000000000009a0000000000000000000000000000000000000000000000000000000000000000300000000000000000000000000000000000000000000000000000000000000600000000000000000000000000000000000000000000000000000000000000260000000000000000000000000000000000000000000000000000000000000046000000000000000000000000000000000000000000000000000000000000001d802f901d482e7041b846de27f7b846de27f8383026c28946aa397cab00a2a40025dbf839a83f16d5ec7c1eb841dcd6500b901a45ae401dc00000000000000000000000000000000000000000000000000000000640fdf5900000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000e404e45aaf0000000000000000000000002c1b868d6596a18e32e61b901e4060c872647b6c000000000000000000000000964ff70695da981027c81020b1c58d833d49a64000000000000000000000000000000000000000000000000000000000000027100000000000000000000000009a1a41127726f74560a57990fb928120eed6f55e000000000000000000000000000000000000000000000000000000001dcd6500000000000000000000000000000002d4766adcf72ef2d996edfadc866be12c28000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0000000000000000000000000000000000000000000000000000000000000000000000000000001d802f901d482e7041c846a969541846a96954983026c28946aa397cab00a2a40025dbf839a83f16d5ec7c1eb841dcd6500b901a45ae401dc00000000000000000000000000000000000000000000000000000000640fdf5a00000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000e404e45aaf0000000000000000000000002c1b868d6596a18e32e61b901e4060c872647b6c000000000000000000000000964ff70695da981027c81020b1c58d833d49a64000000000000000000000000000000000000000000000000000000000000027100000000000000000000000009a1a41127726f74560a57990fb928120eed6f55e000000000000000000000000000000000000000000000000000000001dcd6500000000000000000000000000000002d4766adcf72ef2d996edfadc866be12c28000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0000000000000000000000000000000000000000000000000000000000000000000000000000001db02f901d782e70480846a969541846a9695498302e100946aa397cab00a2a40025dbf839a83f16d5ec7c1eb870aa87bee538000b901a45ae401dc00000000000000000000000000000000000000000000000000000000640fdf8d00000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000e404e45aaf0000000000000000000000002c1b868d6596a18e32e61b901e4060c872647b6c000000000000000000000000964ff70695da981027c81020b1c58d833d49a6400000000000000000000000000000000000000000000000000000000000000bb800000000000000000000000048f2c17f8885e135c8689626d5841d0b94013556000000000000000000000000000000000000000000000000000aa87bee5380000000000000000000000000017a8db2711fe83b10bbfabb6a8b86c3e26ca154ef000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c000000000000000000000000000000000000000000000000000000000000000000000000003000000000000000000000000000000000000000000000000000000000000001b000000000000000000000000000000000000000000000000000000000000001b000000000000000000000000000000000000000000000000000000000000001c0000000000000000000000000000000000000000000000000000000000000003760f4e19e59be10b323fe1b42e42de2754c5da54ff316cef74ef09dbc0144bbf73e609a8d21a38f393bae9a3de6bebbf362608d907d941c8166f44d8ee2c6686b5dbbd6681f5467219d9bb530db013b7c067db659c03efe935caeb7bab36699d00000000000000000000000000000000000000000000000000000000000000032d2d7436bd45b5e81824945ff3dda846e270c81e72929841f4b14f56e02eef39477f9c162a2759c8d7c7e1feefdd064f6aefb4360d483f70671f36fc11ccc6db6c53f74e3019c12d859545ad75b51998b2238887dc0be3c78522c8356150526a0000000000000000000000000000000000000000000000000000000000000000","nonce":"0x48f08","to":"0xe87d317eb8dcc9afe24d9f63d6c760e52bc18a40","transactionIndex":"0x14","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x54159a63b8ce19097cb8afeaffc84cfb5257f9709dcb0f0a258befa0b924b13","s":"0x17f5ef5aeceb6f082a8a0f8fa28e55d453c52e5f86d48dfb4d4f039aad7fa493","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x52db522edf50fc32b8fc0f77d51140031da11da3","gas":"0x201568","gasPrice":"0x861fc89f8","maxFeePerGas":"0xe22924cba","maxPriorityFeePerGas":"0x9502f900","hash":"0x51a0c33c9b37245b416575bdd2751c0d8a5d8bead49585ac427bfc873d4016af","input":"0x96d3f83c0000000000000000000000008cd194f4ced354a14960f76f49305feb8510f73f00000000000000000000000000000000000000000000000000000000000000e000000000000000000000000000000000000000000000000000000000641024ef0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001b3fd330d479974ad52e18b8767d9f18cf9ff024fa749b1066a803b237570cb73e2868e821124c8128505d883124711ae7fdca0339f4f5cd5dadd8eb6956eb4af500000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000003","nonce":"0x2d9","to":"0x29c1442d7e3b6ed179ceb55fe996e1f4384880da","transactionIndex":"0x15","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xac84f403fa0347be3246ad695f8f6a780332357d49dfa67388fae3e051e5566c","s":"0xac2e148c1045af0ebdb334f20743af7d5499558af5eea43393159ce26a3fb1b","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x3aea5f857b75a946d5f5b329bdcf4db46aec5d2c","gas":"0x50f46","gasPrice":"0x861fc89f8","maxFeePerGas":"0xe22924cba","maxPriorityFeePerGas":"0x9502f900","hash":"0x531c25d51ccda59aa9ea82e85c99be9dd4e285af9b8973cbab9ac4a38e26e55a","input":"0x6ab150710000000000000000000000000000000000000000000000000de0b6b3a76400000000000000000000000000000000000000000000000000000de0b6b3a7640000","nonce":"0x1d","to":"0x6c23a4586cc791d2be6767532e12264992aef74a","transactionIndex":"0x16","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x81abc4fdf3b57fdf3a951fb293853fdd86aadce8f319576ac78c60caac186c43","s":"0x452742335bd1f63fd623d5e6cf91f6339361f863dba1a57fc3c1da8292e82c77","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x7915ec065b644568155c4772a286addad3864c1b","gas":"0xb71b00","gasPrice":"0x861fc89f8","maxFeePerGas":"0x1176592e000","maxPriorityFeePerGas":"0x9502f900","hash":"0x93ac6c08d21cb1b61ff59e5e2d6fa3f9ad54008b0a66c669199050bef219f6e3","input":"0xedce8b4da4282888c956c070cd83400fd47ab83bd5287244053b8228711b07386dccacbdb54cb66757631f9f22e2faf7da0eecc43474ab1a1af21aec22dcf949e2579241000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000001a00000000000000000000000000000000000000000000000000000000000000860000000000000000000000000000000000000000000000000000000000000092000000000000000000000000000000000000000000000000000000000000009e011cb7bbabfab668b42b5582cec8d60f326ae14ad55f8d675060dd111dee6c88d0937435261929ba3a881bea107593a10e13c917a0ef5ae4e8bde40de2d1da4ba25ab3a239ba53eb4e260d23b98a7db944f644f40ab75992a89fad40e8d692ad62f8671604db415b54238c5522f6c4e6b25785bffa696d173659309b95a2fae8700d4b9c14382973ea34a3cd8b8428594908dcad2d5d7a01056b8e49a8c25087f12f9e9fec1f4b5fdc57509dba6839100e28016b2e3fec4928bbe11d3789b6cab280c17bebfa5a0e06aea22764e1a18d2d11316bdf81028e65755582586ebdf571cbd0ef59800ba3405539187dfc03eac1dba0cf590e2131a56ef7f260aa38f940000000000000000000000000000000000000000000000000000000000000aa0000000000000000000000000000000000000000000000000000000000000000500000000000000000000000000000000000000000000000000000000000000a000000000000000000000000000000000000000000000000000000000000001a00000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000032000000000000000000000000000000000000000000000000000000000000005c000000000000000000000000000000000000000000000000000000000000000da02f8d782e704820101846a969541846a96954982dc1994a59477f7742ba7d51bb1e487a8540ab339d6801d87470de4df820000b8a4220b5b82000000000000000000000000f6213f16f3db9b50c684b2da37ff080895ae4a02000000000000000000000000000000000000000000000000002386f26fc100000000000000000000000000000000000000000000000000000000000064376b6900000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000000c0000000000000000000000000000000000000000000000000000000000000000000000000003202f082e70411846de27f7b846de27f8382520894b6605a717a2447edac46b1cdafe35e3e91130c8d87038d7ea4c6800080c0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000f202f8ef82e7040d846de27f7b846de27f838303335f947191061d5d4c60f598214cc6913502184baddf1880b8c44d49e87d00000000000000000000000000000000000000000000000000000000000000600000000000000000000000000000000000000000000000000160f9854c9f595e000000000000000000000000000000000000000000000000000000006417d4b8000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000b1a2bc2ec5000000000000000000000000000000000000000000000000000000b2f4f1df2e372ec00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000027502f9027182e7048197846a969541846a96954983029eb1946aa397cab00a2a40025dbf839a83f16d5ec7c1eb80b902445ae401dc00000000000000000000000000000000000000000000000000000000640fdf0b000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000016000000000000000000000000000000000000000000000000000000000000000e404e45aaf000000000000000000000000964ff70695da981027c81020b1c58d833d49a6400000000000000000000000002c1b868d6596a18e32e61b901e4060c872647b6c00000000000000000000000000000000000000000000000000000000000001f400000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000c097ce7bc90715b34b9f10000000000000000000000000000000000000000000000000000000000000000000000614000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000004449404b7c0000000000000000000000000000000000000000000000000000000000000614000000000000000000000000694b3f194e94c80b2d7a0e986e1440f204f0503f00000000000000000000000000000000000000000000000000000000c0000000000000000000000000000000000000000000000000000000000000000000000000000000000000b902f8b682e70427846a969541846a969549830dbba094964ff70695da981027c81020b1c58d833d49a640872aa1efb94e0000b884437471fd0000000000000000000000004e44260732136caeffc7d076e17b2a3554b9ce2a000000000000000000000000000000000000000000000000002aa1efb94e00000000000000000000000000000000000000000000000000000000000064376b6600000000000000000000000000000000000000000000000000000000000dbba0c0000000000000000000000000000000000000000000000000000000000000000000000000000005000000000000000000000000000000000000000000000000000000000000001b000000000000000000000000000000000000000000000000000000000000001b000000000000000000000000000000000000000000000000000000000000001b000000000000000000000000000000000000000000000000000000000000001b000000000000000000000000000000000000000000000000000000000000001b0000000000000000000000000000000000000000000000000000000000000005b0efccaa7c845eddd4fb98211c7a58a37abdf06b264fade6cbff8a73ed22fccc602337b33a81e2cc4127be9d913fb3aec24194e14a61515a26429a00cfb86196aa3c2e6983f1a05dec045f0e63db7bd8619cd2a770ed1f7f470eb7c297e8e19d61277fb276ed8a63fd666b4a5ab02347065a3c16539f4ccccbed8fa39f2a7dc6606fc04c49f3d69463ba1c86c6ddcef8b9f06b9741dc2ebae9f5f1c0523b320b00000000000000000000000000000000000000000000000000000000000000050668b9ca5e5b17e2e79f9f5a7d9ea27e4e7f0302e878584fef3c2304c70c1ef53da311342341f89df488646b97a83994a3d07cc622ffde98598548c5326b7ccc0cf77d5d6fca6cf3f5b5b41a266fa2aaf697fd976dddc710fca834c96d2dfd725eec5980733db3c4e8f779f9fde3a598b2860d819419c961012825f0e160ee7b220989005b6ac5c48734db18158c2d85c8499bea1972c9f875c2d2aeafccb33700000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000014000000000000000000000000000000000000000000000000000000000000000e0000000000000000000000000f6213f16f3db9b50c684b2da37ff080895ae4a02000000000000000000000000f6213f16f3db9b50c684b2da37ff080895ae4a02000000000000000000000000000000000000000000000000002386f26fc10000000000000000000000000000000000000000000000000000002386f26fc100000000000000000000000000000000000000000000000000000000000064376b6900000000000000000000000000000000000000000000000000000000000000c000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000140000000000000000000000000964ff70695da981027c81020b1c58d833d49a64000000000000000000000000073fee82ba7f6b98d27bcdc2befc1d3f6597fb02d000000000000000000000000000000000000000000000000002aa1efb94e000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000064376b6600000000000000000000000000000000000000000000000000000000000000c00000000000000000000000000000000000000000000000000000000000000044a1c058fa0000000000000000000000004e44260732136caeffc7d076e17b2a3554b9ce2a00000000000000000000000000000000000000000000000000000000000dbba000000000000000000000000000000000000000000000000000000000","nonce":"0x48f09","to":"0xe87d317eb8dcc9afe24d9f63d6c760e52bc18a40","transactionIndex":"0x17","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xb5f185933d49064643686594f44a2584b1d57ba6a91f2a45d1a122892488f209","s":"0x7bb4af7ea30290b36fa7c266ee2387eff9e3ee0cd79b48aed27f5bfaaf34114c","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x4281ecf07378ee595c564a59048801330f3084ee","gas":"0xea60","gasPrice":"0x861fc89f8","maxFeePerGas":"0xfd18eeafe","maxPriorityFeePerGas":"0x9502f900","hash":"0x3792db6dd6285f409e4281951e9f78dad16c4a78072ff1c909dfadea5658d857","input":"0xa9059cbb0000000000000000000000000cc351a97c2fafde4cfa8a00c4fd79881cf13b53000000000000000000000000000000000000000000000001158e460913d00000","nonce":"0x77ffb2","to":"0x326c977e6efc84e512bb9c30f76e30c160ed06fb","transactionIndex":"0x18","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xef4173dd45060791cfb6dfc3cdc8a9b417ff6a4b3ba57759ea91fd875b01a522","s":"0x4de926b5099c7d60cc24add3c2eecd8e9550c1fe7f878430eccb887a2ff932ff","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x53e2c2479833ca17f946aeb16dcc49f5e2194701","gas":"0x431eb","gasPrice":"0x8442f24f8","maxFeePerGas":"0xd6aac8818","maxPriorityFeePerGas":"0x77359400","hash":"0xd2d51764c01e8c0a43fbe362704388df5bacf7e5e620c3864e242530ffb3e828","input":"0x9f8420b300000000000000000000000000000000000000000000000000470de4df8200000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x2","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x19","value":"0x470e9f23394000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x155352758fb04a6c0816c3dd9ca16bd6c66c37e2e19f2aa5d969225e3cb7f118","s":"0x6a4a1237db75dac4322fe12aee8b94edf7083ea661d6e93334c667d2d5c2c101","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x535619cf2bd2e84e567bda1a6164f195cb2bba21","gas":"0x55730","gasPrice":"0x83152e5b0","hash":"0x516b0227d9e64eb6e0de6862764d40f5376b5f12fec878436fea3479b4c36bb8","input":"0xa9059cbb00000000000000000000000030509945d2b329cc253a8bb2e2c54bdbb08b1070000000000000000000000000000000000000000000000010ce1d3d8cb3180000","nonce":"0x2176","to":"0x1173069b0e472a64ce2b6203fec8fb25a05b75c2","transactionIndex":"0x1a","value":"0x0","type":"0x0","chainId":"0x5","v":"0x2e","r":"0x289ee9948b80fc623b8c5d85c7df6fd25786fcc118163042b77a00560f53c3fb","s":"0x5b0a79e30d05370b27664b2a10cf964e110387bd62098561b6ea6a9dcc4634a"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x339d413ccefd986b1b3647a9cfa9cbbe70a30749","gas":"0x180ac","gasPrice":"0x83152e5af","hash":"0x81b0abc78b82840adb666775b182a9e292f663b64bcd35004c04436ed3c8281c","input":"0x711746e200000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000009a00000000000000000000000000000000000000000000000000000002540be40100000000000000000000000000000000000000000000000000000006d3c514bd0000000000000000000000000000000000000000000000000000000000000010","nonce":"0x2689","to":"0x7cbd185f21bef4d87310d0171ad5f740bc240e26","transactionIndex":"0x1b","value":"0x0","type":"0x0","chainId":"0x5","v":"0x2d","r":"0x1f70a3d0933aab069a55fb2b16a259d21ea5fb3255e2032c5ff194a600ed2ab1","s":"0x3ac2142fc9f2009d68b08855eb5bc85e889e15d043c33bfc516f28ea38715485"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x339d413ccefd986b1b3647a9cfa9cbbe70a30749","gas":"0x180ac","gasPrice":"0x933ea77d8","hash":"0xd0287570d431d2baea96ecc81cb890e7f4f06ab5df02f9b4067768abca19acb5","input":"0x711746e200000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000006500000000000000000000000000000000000000000000000000003a09994473bc00000000000000000000000000000000000000000000000000000005672af7e00000000000000000000000000000000000000000000000000000000000000010","nonce":"0x268a","to":"0x7cbd185f21bef4d87310d0171ad5f740bc240e26","transactionIndex":"0x1c","value":"0x0","type":"0x0","chainId":"0x5","v":"0x2e","r":"0x73a68e10ef9726d47ff314cd16d1846a0876d2b63a65014909140de7e45aa8b3","s":"0x580de27e4626139fbad4129a249c7ac2b22e1062659293e5fc3a244fd74907c"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xb5b9345e21f34b6cfa538f49e2b14ad4c3db3f7e","gas":"0x431e0","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x76ddab2674369f34946c5fa2f05e2aa8566d86235b83e808e9b27bc106e04ac7","input":"0x9f8420b3000000000000000000000000000000000000000000000000016345785d8a00000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x38","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x1d","value":"0x1634632a1414000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x4314a4757076c92ca696f14cbe037bcc0178f8b10749418d4535195e90b2cdc9","s":"0x15ee917bc3e27928196ad987b61e3fd35ac92a4200b139d355b30502bff7fceb","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xac2fde165d9f13a223f58b9ac1dde51b63feff2b","gas":"0x5208","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x34a5c74011a2c8a00103bc91bfbfd94aa99cd569be69066e4bf64d188fe8714e","input":"0x","nonce":"0x38","to":"0x7155eba8ef327ac3b36fe59b5e00ab85f735f4f4","transactionIndex":"0x1e","value":"0x1c9f78d2893e40000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x52178c5dce512607a6242f501f78bc894917a482e99a3368caea6bca94c6dd69","s":"0x728be90654231b65f790eba478ccab574e2468fc4e031b712efa88af31fc6592","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x1ddedd674bfacb6587e0c68cee8f2f7d8a71e9d7","gas":"0x1d4c0","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x7b9730ead1b9f59b206d0ddea87be9383ba3fc7b496c7863b0cb847889b86617","input":"0x607019b9000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000041971588d95d4d664ac84a45e59fc81871b7051d679376d86cef6b9e1453c762dc33a84a125774319ee47f2a8b8d588da6c8ff7ad84fd9eed22fa124b1a5c5ed4d1b00000000000000000000000000000000000000000000000000000000000000","nonce":"0x1","to":"0xe1e6aef7642b6609e6c54884d1bda4a3cb152461","transactionIndex":"0x1f","value":"0x4380663abb8000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xc0d3e609b2e9f844d300a7784aa9e7cb956415d025cb573a73848f49e4be69e5","s":"0x6ce01527c00c1a93341a541824aed7a1c895f5a0d998f4415cf6d88171c5ad3e","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xf6df8ead0bdabfba61d9b2457d5a5ccec67fb7f3","gas":"0xc836","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x77166ee0409ba86bd26e7c03ad1a927abaf5af8a8a37149e725cd37512091dd6","input":"0x67a5cd06000000000000000000000000fa8449189744799ad2ace7e0ebac8bb7575eff47","nonce":"0xbd","to":"0xccb0f4cf5d3f97f4a55bb5f5ca321c3ed033f244","transactionIndex":"0x20","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x5649e1ff58fa9b6ee27a7316904df02db1ba1c471a2f3409f370a31c6b3d5ec4","s":"0x386b766277e267f8796ba6e92af71a752335bbe45cb3385b9cdcab9ef6c53e41","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xf37cbbc2dad42e8826898d45933afd3a04937e71","gas":"0x112c1","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x3c2b6c2ae505c5c36d5f316c1fcb5f54f7346ed35ae35c93462991ded7968a68","input":"0x095ea7b300000000000000000000000071bcefe9e9fbad3f12f2e6c14ea0cae7f0c91e7900000000000000000000000000000000000000000000000000000004912e6bef","nonce":"0x9","to":"0xb5d86e1f237d52f1f19793d3265e9340394f75b8","transactionIndex":"0x21","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x3ee4d5bfc575fa4b241b4d23e6f099eba5f1e6a20b8cea663c63db6400d01506","s":"0x21481ea7a3e7ad758f2e149829f70f43d67b3cc0d44112cd3744e290a06dd985","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x52b6255b7810d97de8f751737547d1792dff4fe0","gas":"0xece2","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0xf99a792837e13827b5e0a8915fb59c760babc95d242feca99a5594e64ff6b6e2","input":"0x095ea7b3000000000000000000000000c92470d7ffa21473611ab6c6e2fcfb8637c8f330ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff","nonce":"0x51","to":"0x07865c6e87b9f70255377e024ace6630c1eaa37f","transactionIndex":"0x22","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x5237f7449c0df409c1a4d6cb09005a9224860aa74737debd961e2a24668d1022","s":"0x17e5e842e3f5ffb5a16eca0ec2a92e5b52d43bf9856f97e2083b2e951499b970","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x3c70503d83c5a681aab503d724f47fe810ae8205","gas":"0x17eb2","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x522313f5d923f048ae5bd0b5595c1f4fc883bc0b3cf3cb0939d3fcf8b08c829c","input":"0x94d008ef0000000000000000000000003c70503d83c5a681aab503d724f47fe810ae82050000000000000000000000000000000000000000000000000000000316195298000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000","nonce":"0x5","to":"0xb5d86e1f237d52f1f19793d3265e9340394f75b8","transactionIndex":"0x23","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x6741309799fccf0f1359bd710291ec1bb66eed23522d6ed60c5924264d4d283e","s":"0x69c43182ee8a650b0042cdb2352781b23eb1de72f1c3a8903a1a33360e7d9732","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x4da9a48963c158a88bf6d4845a6a1890d20e55ad","gas":"0x431eb","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x471ceb0e85af594aa56deca54cb8198567b2afd8406722ea530077aaa6b641b3","input":"0x9f8420b3000000000000000000000000000000000000000000000000001dd7c1681d00000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x0","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x24","value":"0x1dd87babd44000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xf977ce19da80b7e155ee2d8b7656e5c89004851407bd5370785befe2c89d82f6","s":"0x1d76177407e73d8b73b0909158825ee375a25fa7c18b04884f4be77bb60795a8","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xe40a2cd9efde08fb7664bcdbbdd877c52c4bd228","gas":"0xf4f6","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x3e9dca502e9039ae0c6d642f62e9562ff00010c6bfbb8234a6135712ba70dfda","input":"0xa1ddc5460000000000000000000000000000000000000000000000000000000000000738","nonce":"0xa","to":"0xdef65f8e2f62bde60cd86ad3b4ad7fa6741cf175","transactionIndex":"0x25","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x34df85658956c9eb71549db3a73abca70dd01b8e91284afcd372c1212a36605d","s":"0x5036e2984bb2edbb5fd647bba873f1f5c5ee4845e539c9b0bc70d3d12a4bd93f","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x17299065e99b12b0c8cad06638624cff8d507334","gas":"0x5208","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0xc95cac67267f4accb9b5950316ac64772f7d082bed6b712c09cf2da0bdc237b7","input":"0x","nonce":"0x7","to":"0x02647cbb1714fa9a5747ec5be6333e06d806e85a","transactionIndex":"0x26","value":"0x71afd498d0000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x82ee5cafbd010cdf7a4604df728d1b8713a5bd26a708f5c92f6b6a55864c9576","s":"0x2b9a70d812123b2ddce1108c4101ddce182f6c83fc8aa0a139ba597aa178b270","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x9aef7b879787baf0c2dfe888e67a7edb7a233209","gas":"0x431eb","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0xfca28fdbd13fc16daf7aec7d4a2ad2c6b5f0b2a7b0fb1d9167c09b5e115ff26e","input":"0x9f8420b3000000000000000000000000000000000000000000000000002386f26fc100000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x2","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x27","value":"0x2387acb3784000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x7e5f1a27ea5e652ec8705f80365f1703d2fd50c1de7c22ee0181d556dd2fcc38","s":"0xb22fb8b31dbfff8ad0457ba4b659fb0d7031cd86f08fc3cb78d81c97248034e","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x06006a25e0fe65f0eeaad1f4813940b68db782a7","gas":"0x17ea3","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0xc73124ca798b2f7a5df2ea4d568efab2f41b135130ea5cc41d4bcb4b5c57d5bd","input":"0x94d008ef00000000000000000000000006006a25e0fe65f0eeaad1f4813940b68db782a700000000000000000000000000000000000000000000000000000002726bc7f1000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000","nonce":"0x6","to":"0xb5d86e1f237d52f1f19793d3265e9340394f75b8","transactionIndex":"0x28","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xabe4fc843d3a1628a464884c13c21bd21ae9a0a5738d9ae2761ec7cb24b059d0","s":"0x68408d8096e542b2c06cbbecb9494a3778c3ab644e69dde1fac078079c4bcad4","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x2501bf5c8ddf04a60fdd47a95d53d99b315604e2","gas":"0x5208","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x29abb76b5e7a5ce137bf9c22474d386eb58d249f43178d2b2e15c16dfdc5ca80","input":"0x","nonce":"0xa","to":"0x901a4e04f1513443c6efc6ce4e913d1b960ecd20","transactionIndex":"0x29","value":"0x1a3385ff37f0000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x1a1789d5b19950f45383cb1909cff9128dc2b332e2ea7ba42cfca5806376e3cb","s":"0x617a5a4339503a9c9d08705d98e7a202ed7ede1d1192fd7d98b648c8c102716c","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x507832c92ade971b9a2880427353c6ce6d0ffe53","gas":"0x61a80","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x03e5ab25a58bd44fb9dd0c698b323eab8b8363479dfcbcbb16d0a0bd983880ae","input":"0x85ff842c00000000000000000000000000000000000000000000000000000000000000c0000000000000000000000000000080383847bd75f91c168269aa74004877592f00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000006100000000000000000000000000000000000000000000000000000000000557300000000000000000000000000000000000000000000000000000000000000014507832c92ade971b9a2880427353c6ce6d0ffe53000000000000000000000000","nonce":"0x1e7","to":"0x805fe47d1fe7d86496753bb4b36206953c1ae660","transactionIndex":"0x2a","value":"0x214e8348c4f0000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xf707322f65ba56c95ced5654efafcf9bfd60a2dd80e74bded3190673cda55d8e","s":"0x46412ec3d2137fcef30f53cc4644769f4da126128979920ed4e209acb1c8ebc9","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xd44c850ce9103d6b2398d4ed9bbce321f3b769c7","gas":"0x1e0cf","gasPrice":"0x82661bff8","maxFeePerGas":"0xde6f782ba","maxPriorityFeePerGas":"0x59682f00","hash":"0x3c8ee80ddea7fa2d2b75e44563c10c10756f598e8ad252a49c5d3e8a5c8e6cbf","input":"0xeb672419000000000000000000000000d44c850ce9103d6b2398d4ed9bbce321f3b769c7000000000000000000000000000000000000000000000000002e2f6e5e14800000000000000000000000000000000000000000000000000000000000000000e0000000000000000000000000000000000000000000000000000000000098968000000000000000000000000000000000000000000000000000000000000003200000000000000000000000000000000000000000000000000000000000000100000000000000000000000000d44c850ce9103d6b2398d4ed9bbce321f3b769c700000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000","nonce":"0x9","to":"0x1908e2bf4a88f91e4ef0dc72f02b8ea36bea2319","transactionIndex":"0x2b","value":"0x2e2f6e5e148000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x327a6fbcaa2ac3cfb0ce64b47f6e61de4d18297f1305f23c6bfd42d88e8d068","s":"0x6b3a9b5252ced14b2e2f2833ad7cc62c46fbd0785d57f2747473af3fff7d46b8","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x78aa9046272fec8d51a402681d7c37481db01c6f","gas":"0x431e0","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0xaffa73b68bc7ab0c3f5e28377f5ca0a5df33c0a485f64dc094b7f6ae23353203","input":"0x9f8420b3000000000000000000000000000000000000000000000000016345785d8a00000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x36","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x2c","value":"0x1634632a1414000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x925370b51dda3e1d1bc6b86580fda3b40875157ea594a9a14174436c726ad46c","s":"0x516c88bf3cb2f46ca81572140b41e5db2d74c4a736ee7d572b508415c438f779","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x56784e51c2ce28dbe9aa68342638d1e95ea4324b","gas":"0xb72e","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0xc66c9c66fbc8fe97fcc16506cde7a58689af1004a18c6171cfe763bcd94f50b2","input":"0x095ea7b3000000000000000000000000805fe47d1fe7d86496753bb4b36206953c1ae66000000000000000000000000000000000000000000000000029a2241af62c0000","nonce":"0x9","to":"0xcc7bb2d219a0fc08033e130629c2b854b7ba9195","transactionIndex":"0x2d","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x407c855bed0fb088e886c3721ee9abee4761221d110512ac29b8fb143c4b34d4","s":"0x1e47aa957d9ebdb564dfa41b72022d525383ffd825a307fbfa9ca13a59994dcc","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x805e39acf2f170251c48a35df16411cfb2f761e3","gas":"0x56a8","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x80fec96707519172b53790610d5800cd09a4243aca9bacfa956c56337d06f820","input":"0x71ec5c05aa669c4922569c1d33f7a81aaa21813800000000000000000000000013a0c5930c028511dc02665e7285134b6d11a5f4000000000000000000000000805e39acf2f170251c48a35df16411cfb2f761e30000000000000000000000000000000000000000000000000000000000000000","nonce":"0xc","to":"0x7c125c1d515b8945841b3d5144a060115c58725f","transactionIndex":"0x2e","value":"0xb1a2bc2ec50000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x8fcf376106af19aac48ecb840ea51df90a5e3ba557eeaad41cd3c8a90785d416","s":"0x4a9e9021ddb5f839bf7f54b54ad52c57b21b6ed285773eea022e3ccae69d1b99","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x4199614bf74f6b3ef47a812d976dd1f57a8f082c","gas":"0x431eb","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x61b33bfcf11214906dcdce7d7ed83ad82f38184c03ded07f7782059d02eeedea","input":"0x9f8420b3000000000000000000000000000000000000000000000000002386f26fc100000000000000000000000000000000000000000000000000000000000000009c40","nonce":"0x6","to":"0xe5e30e7c24e4dfcb281a682562e53154c15d3332","transactionIndex":"0x2f","value":"0x2387acb3784000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x3d295f5fa2dbec04793f07adec57e29c03376c628a0256ee297fb3070a1e3364","s":"0x6f115dd4505bd320bd7460a47bab0c20e6bcb4b3f17c6d0e00e3ff1d936ed2af","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xf6df8ead0bdabfba61d9b2457d5a5ccec67fb7f3","gas":"0xc7c7","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x5d4138d4e28a8327e506cb012346b1b38b65f615a2b991d35cf5d4de244b3e6d","input":"0x67a5cd060000000000000000000000001f1f156e0317167c11aa412e3d1435ea29dc3cce","nonce":"0xbe","to":"0xccb0f4cf5d3f97f4a55bb5f5ca321c3ed033f244","transactionIndex":"0x30","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x47bfb48eb89a8b110749d34d171db36a8ad21c8d7cc78c7489e72f21cd86ba14","s":"0xa525976583b19b3d2c2dd6b34324cf55b1a61595cb53e3c58acaf203f8709e6","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x9eda8333e09828571db26576a566668f79f98946","gas":"0x50df20","gasPrice":"0x82661bff8","maxFeePerGas":"0xc8d5e2427","maxPriorityFeePerGas":"0x59682f00","hash":"0x875a142b6dfcf10ffb71a7afe0ce4672c047fc7e162ba0383390516d6334d45d","input":"0xb1dc65a400011a04d404e571ead64b2f08cfae623a0d96b9beb326c20e322001cbbd34470000000000000000000000000000000000000000000000000000000000bd780a7d2e00ee03a29f787096cae99da52d07803c76c13473654239118e2cf0491bcb00000000000000000000000000000000000000000000000000000000000000e000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000480000001000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003000000000000000000000000000000000000000000000000000000000077359400000000000000000000000000000000000000000000000000000e50bb6420faa6000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000e0000000000000000000000000000000000000000000000000000000000000000217f0aee859cd78a5cdf79c68c8de4342658d52ccc6420181b5fcb7c657c5fdfa5ca2c8f2dd7e6e5799d44d6818e6dd8fee19b2530bed2045e0c665041f053fe70000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000001200000000000000000000000000000000000000000000000000000000000840235df8360bffc902a68675311f5eaa79ea2c25e2cc394bff0a43d5d608e98c97de200000000000000000000000000000000000000000000000000000000000000600000000000000000000000000000000000000000000000000000000000000060000000000000000000000000000000000000000000000000000000000000002a00000000000000000000000000000000000000000000000000000000000004b000000000000000000000000000000000000000000000000000000000000493e00000000000000000000000000000000000000000000000000000000000840235df8360bffc902a68675311f5eaa79ea2c25e2cc394bff0a43d5d608e98c97de200000000000000000000000000000000000000000000000000000000000000600000000000000000000000000000000000000000000000000000000000000060000000000000000000000000000000000000000000000000000000000000003f00000000000000000000000000000000000000000000000000000000000007080000000000000000000000000000000000000000000000000000000000061a800000000000000000000000000000000000000000000000000000000000000003312d88cdb7cfd5fc5458d9a424da374cd818847f87fc4fb6eae2c3b97e541a6b81e108e55daf857b71514fb7213db7ba15bd6adc12253afc3c5e949144c13696faabe22d1b7ace91532134a5cc65bed9afdd897d6f84ad1b0b6da463bda8fde5000000000000000000000000000000000000000000000000000000000000000352c2a75f88112864819de485c392c349f718fc257934181c4d8ac8eb3a9b1fdd3b7bfb96496290f2b41fcd20fc8d29bd8e29be38550775dc97d21b17c2d679ad05f519787eb2c92a9a897c9f02f15316865cfeb4bcc2c0ba5ac2dc4aaab5c0c9","nonce":"0x3705a","to":"0x233a95ccebf3c9f934482c637c08b4015cdd6ddd","transactionIndex":"0x31","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x7e9247209bede2c21548c6e4f26e41d2636a2490e09ad062f9235e978094073d","s":"0x288d820793b48e55777e794f1694b1605d74dc8726fff438b481125f219eaec","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x6df2b54f23ed4e95235c6e21ada2cfff5a2615a6","gas":"0x5208","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x79b6df832bfbd04085d0b005a6e3ad8f00fc8717eed59280aa8107268b71e7e0","input":"0x","nonce":"0x17f","to":"0x6143d939b2d117f4b998d8d88a56eb0e0a1e9c31","transactionIndex":"0x32","value":"0x186cc6acd4b0000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xcb641be908976bc0a035b0b31a96039da9e63e829e0a24a092ecfbce7724b9c7","s":"0x4034e7dc4001cf9f62a2e5dc4390229655b85e9aac5a5b263278e9d2cb43abb2","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x3f5ceedd435b6143eba2254811a39fc3423f18dd","gas":"0x186a0","gasPrice":"0x82661bff8","maxFeePerGas":"0xaa246a58c","maxPriorityFeePerGas":"0x59682f00","hash":"0xcb2fb25d268f65dc9312e89bd3c328c9847a3c9da282026793c54a745f825ab5","input":"0xe9e05c420000000000000000000000003f5ceedd435b6143eba2254811a39fc3423f18dd000000000000000000000000000000000000000000000000001c6bf52634000000000000000000000000000000000000000000000000000000000000000186a0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000a00000000000000000000000000000000000000000000000000000000000000000","nonce":"0x0","to":"0xe93c8cd0d409341205a592f8c4ac1a5fe5585cfa","transactionIndex":"0x33","value":"0x1c6bf526340000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xa48a4ece6fbe881e342a4eda767c82097c3bd47dc70c09ef6a4e7f90c0f8e843","s":"0x66c92f16907488d115f5088ed8ff4d71c966232458479245bf6dae45358c0429","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xdb4f0eeb7c89b00118cc74de8c9ed55d65c2b933","gas":"0xb72e","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0xe483d4a36ad19fd5eacb7f6d9ad3ce080ad70ac673273e710f6e3d5acbc6559c","input":"0x095ea7b3000000000000000000000000805fe47d1fe7d86496753bb4b36206953c1ae66000000000000000000000000000000000000000000000000029a2241af62c0000","nonce":"0x120","to":"0xcc7bb2d219a0fc08033e130629c2b854b7ba9195","transactionIndex":"0x34","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x6d73169394cb6a9bceb2dcb16aacd261705096f50f30ffe146a09659e25dae48","s":"0x496a1cccf01ad2ae7094b8da2ce50c0a990baba6300625c48ca12c5f20005a64","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x9ac253db14a434cbe7653a99c5039648fa4f7353","gas":"0xb4f8","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x0564242c37d5013b671ef4864394cc0f3924c589f8aad64118223a9af2f164f6","input":"0x095ea7b300000000000000000000000028ac7dbbf9ed6ece39a902e76780fba60f1b2e3b000000000000000000000000000000000000000c9f2c9cd04674edea40000000","nonce":"0x4a","to":"0x0dece1605795461158538302b5f0936afe78c4db","transactionIndex":"0x35","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x15684c9697dcc8d89abe562c4315bfb959938fe7644c00615d9e147a4e496ff6","s":"0x7c58abea24e1fa8caeb73a70219b0d63007785c39694fe5ed2a5a342c99292a6","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x22496eece162f52d185c07524d452b9506e9fe12","gas":"0x186a0","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x48db358e80b278c3a46c2a166339797060a40f33984a5d974992cd9722139d5d","input":"0xe9e05c4200000000000000000000000022496eece162f52d185c07524d452b9506e9fe12000000000000000000000000000000000000000000000000001c6bf52634000000000000000000000000000000000000000000000000000000000000000186a0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000a00000000000000000000000000000000000000000000000000000000000000000","nonce":"0x0","to":"0xe93c8cd0d409341205a592f8c4ac1a5fe5585cfa","transactionIndex":"0x36","value":"0x1c6bf526340000","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0xa50e6ea1eff21fd33d69f8c74b90c28303b92ebc4a77c71b65c4c8bf3e92ac8c","s":"0x29af3bce2365578b76dc528917b44e96e4fe2e7a8f948eff3e379721f35664d8","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x9ce3f4210dc06889ad5267ef0ce3ded4bd96dc50","gas":"0x249f0","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x69d7758db91fae31fa35ecbed4d40897c5087f45dc796cd796b8ceead21f972e","input":"0x47e7ef2400000000000000000000000089f01bc9865324583380d8d7ed08b8046bffd7fd0000000000000000000000000000000000000000000000000de0b6b3a7640000","nonce":"0x1c","to":"0x6cf3df5d00e842aab1eb504bcf01ebf81646f7b7","transactionIndex":"0x37","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xeefc19e8dca874308c84712c3e48c032a25971a0f7dff16dc47633ba7a4f5b96","s":"0xc0994cf21d29cb0c5f1e666538b58d6dff3b9ba2aa7545337da732c4b5938cc","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xbd1c4e36842c06e53b378eca310cd2dc79a78cbe","gas":"0x35965","gasPrice":"0x82661bff8","maxFeePerGas":"0x97f5c211e","maxPriorityFeePerGas":"0x59682f00","hash":"0x2951478916ecd27a8e808d08f85be4bf2c0b0e0546f21f4e309145dd96eb8df1","input":"0xab7d7969102507275d685f3f55d10ee45f7b9fa39c29a8a604a7a971c05eee739e63938500000000000000000000000000000000000000000000000000000000641cfd18","nonce":"0x252","to":"0x96e6192eeaf7bb308f79fb5017a9085754b9e12a","transactionIndex":"0x38","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x87fcffa38e0c84cf80fb37ac1e538faeca21462b0a9ec25af0ca0517af22789a","s":"0x72cffece99e79edb7425a9d660590fbc395cdd0db8fd4848074c85f814b3cf63","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x5dbcb3e489fbef1656dbbd7bc4848ed0e520a089","gas":"0x7a120","gasPrice":"0x82661bff8","maxFeePerGas":"0xc8d5e2427","maxPriorityFeePerGas":"0x59682f00","hash":"0xaca9028cb5d55bbf71b7bff9884a9a3b0b38a575ffc8f8807ce345cf8bd298ef","input":"0xc9807539000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000001a00000000000000000000000000000000000000000000000000000000000000200010100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001000000000000000000000000a7a9d91e687decaa6b045797c2e002d70001b48f03020003010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000600000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000002361273ef6f000000000000000000000000000000000000000000000000000002368a4faa14000000000000000000000000000000000000000000000000000002368a4faa1400000000000000000000000000000000000000000000000000000237b9042149000000000000000000000000000000000000000000000000000000000000000288e1b54f6e54124deb78bdb67cbfd0bf63612da12868fc281afc34bb26200a1771f9e00fce297da11cf49427becf350d0bd20a2277439fbb2e8db0fbb5e3d34700000000000000000000000000000000000000000000000000000000000000027d16a90ad0e1f8d924255e6380764fa7c7d46427c8e8ea19f5ba6a9d595297a340f141f74e705d0fe851d7564eba89fcde574deb5975d9126867cd927a0d92cc","nonce":"0x11d38","to":"0xbe57bac491de9a260abb6ba2c9ad4c5d2eaea09a","transactionIndex":"0x39","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x1eba7bf95bf63d02b74d20554af050eedd78ecfbe1a42ec70badb36ccfae4bfd","s":"0x4d7f8d0ac2be28e59374453f24ae6506a81707cc57f0d1c6877b49b3949a9a79","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x3079be9d8622173f02618ba2b793f00795d4f320","gas":"0xf848e","gasPrice":"0x7d9f6fbd8","maxFeePerGas":"0xd9a8cbe9a","maxPriorityFeePerGas":"0xcfd6ae0","hash":"0xc7f625a19ee41a1750eac9428b4394a9a2476b8ea2d31b4c2f9f5b4fcb86cae3","input":"0x2169f79f000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000fdce50000000000000000000000000000000000000000000000000000000000003f2000000000000000000000000000000000000000000000000000000000000001f579a43ce4f3e38c6a948f1ef3bf7954c2059b087b18fdb22c7b69d61727a5d2aa16090b4d1f3281bce660a31d3e2789eeb360192a54e3ac3513c5c8f67b7346fda957c92c1a2981bc68a47d0282e78df2fb63822f06f410e1ffbee7eb83c425122be9be94d817e2e42099632fb9eb5ce7c414cf6ce48e4ed2e64e46e1558ca809742159e841e3de803a8cdc628f7877bfa6d75af4b4ebb185e6d0670ce83332478137fec243a38c0a80d067c955cbe13103294dadfc8c356d0e7996cb62fb2c683e6dd5ad58be934f57375920142990074f8a161ad2390a1e6bea9fc3a58dc3f7e002e9952a68bff229437d3fb4cc1cd8097032b22c884868253d8f2f69c75ada0fbe1dd57145610ae5f451b47645718aca7432d8cd3193d0b96417df6638fd47062a1cb1f63636236fb72195e5a46d1b37f493b8380315e5bb1a6fe67cc6546d62f2c73aad5699e6ffa0d49ce653bcefa173fe0de7b4328aad75f74d15f4f570a1839514550d576e21b8d16c8355b770442f0740e6e5e77ab450ee1fadff8daeeb25a91585192fcd3cdd64dcb6a35e41ff47e854337ebd0923ce280cdacff2ced48eac96bc9f910391a44cfec243a8660ff80c10ff844ea22411953e0387f87d2c2ae81055fc8e87d59e04cd7a923d6aa5204b3eaaf5b842b5fd656e9fda16c59e90c64ef51124fb32f8e63442b1f79d3ba3c0cd5fb90895103719629857d5999b44aad2d69380f48dd824795a89dce14bb82600701ad8fa9bbb36fe93a97d75da26ffcb1a8828918e0293680ecb12e1b772fd98637a7a83cffbca1a994fc889ed0c0b20d447ff727b9f5dcb9a83e1aae9a3518dfe1d7ddab1da48310eaa7ab293d85dd9ca811bfdfee990459fa044c9a9fa6460e5ff7612e42021f16854d790710684663bb6a10ba475fa602b02519f03eb544fe486d9cdde47ab7d4027bfb8f29d778b3a7cc35a9f78dbb05943062efe3b388f1a8c496682a0215265b99fed0363a1061556a40e0539a6656b6cf8967c8fb3092a7fc9b56af124c8f1bd0abbb9af753884b22b333410d47d80c083c9fee52dda8907be0c87c5496f1fe9ac4bf4dd4f06d6ac0ac0cde22138b67bf782e8e9b5c991d58a2a828b4c68620e6d3d26abf8d41005a00866cb4095518b2711636f2fac3b5e26403ef96f5b1765519787ed74c6802b445de029d7bc696aeef5a2e605376aeda4f495c29af66e357c6e1232d7a2c3f22c0bae0c62372d6b2690e503804e2ad314c38a4ffc080d36213458f606075d32dc0a365087616e94a972bf76d7e5eb4a53292fd0d7570cb6fbb4540b3c5ee6deee0f257fe8703d5d8d0180d09754bd9a05894e77318b8c8fb6b4a56999bfc6c405c09d9ce7fe424812db5bf778d7d8634b2f44ad6d00f18615e4c3695d9c5965ba51991508405187275840a3f27cb3101a9742c49edf42dea79ae5418ada42dfe2042f931af15a205e64196b04ef53492a450423c2b63dc849ef72a166fac5f36b25c72d9cb4a2507d5ad15094a979b4ac4ff8eb4c90f448a81fc6dbfcf6a228675ab3308bca37bda8eda22b61ec7e596f2448ee6b7cb6eef589f43f28fc5444d1da3f82ddbe574b774719a3a7869e897e642735517832959ea9cb9164eb2f7665bca1d2e44e1093acc7088271f2be20459c383f5762303b553af1ccfb3371e4eef1f102ce70d62620c5164972facbfbe03b5018265ed62c4c3cc49522166913517e2f2718edb591047a72e818f07c645a18aed87c0384d180dc0bb7fe63bd335b1c09e58571b92e2267ffa5712a33e4a92231d9da7b005730f6d6559ee685edad9a9031c4708c8642c297287af3a3e637d9b5ac6b23218977cf4d30231a79063987f98313a2bc0ca4a73a97e441a45b58cdd8731fc269255b415a9d2ef2bb8a311587f39f6dc82f537cf86a68af19a68c409910f4dbebdfa66445361877a3bf551480d115d8768e8650e9979472a64802da3625cdbddee8f02678a3cc6400824d91b3c7d4c9274b74fb11a9538f1990fc314d35564a0cb0b384590e15cb93db1de1a837b9319828b3fd6b76f1d2bca4ac765f9ec4366905f2dca69a4c8c194cf0a5d821c58bd291e8dd4ddd829a873d093042c1b8e1bb2bb1a95e150c0a0d5c3369c4a791dfcfbc3e631da3d1e704214c3cf8318901f9c58465be78a870a040f34c567c27eb077db2d1ff825a127a038eb14c2890ff9a8a1dc8d6360a91fd788fec97599a318ab03f69bd50a5ece92d96c49413b517579ececf71371b6b1d902b1dbbf40c728c64fadf368582cc4b3c51712c8d6441c0c61802943624e93f9de9eedde87056c21ecf66b3a6977af0261ef48b4c6191ca7ea70d6acc5af910ebf247e2a4429c506c6a41f865175a9bfc81dbb69e59ec2c47370fcee9169b8749c852e7a1275c1278aa3f88bc16d311e58aa9a579ed7bed62f12b4c4dfe9c493cf33f979f667eda043c2aaaf863a747b208f3aa2ccc34f07b12d89bfd75b696a82c493e7eedcdc41eb01321ecfdcb691d14996c3ed7487b5f831436bb7c25876c4149cb6222dbee9e1a05771a8abfd0fd530266476e1bf69d9a15e99c901243585f56a77ef0e6c684a4d49417133ebb91f896176ec3a8f0b966eaffce96f129d18960fdbf5917f8aa0926d52c57192f99e55959369e57ce85ae84ad944e40652f6a81ab8da1dbe81a827366b8b8d2ffb9c7b93087f7a356a16d0022ee8ae891060e29ff11f9f17b01f39b8024baefc8b928a6816309a5c3fc92ed6007499353b5f1bc5700d5fe67f3e34ef3654712b9c67c231f30dff485213b94c20afaa91540560df80ba9ff1cc0f6ea75bf1dac0566551050873c112478f3fce6af162397161e1b41e1ca295f327a4f0ccf4d15fbe58e20a23698bdc25c751d020df371cd1fc59fa51dbf7ad619d208d7084c5752984b5fd0e3a7978f2c11e6b26531fe03c0cb85519483d668bf1dc4dce24509b00aa6e146adb49f31c2c937a2d3a08f1cc0b73cd66f2cb926f0453cf78618e39cbfccd6e6a3b4909d6874872eefed0e395ac2582d8c1d0483007fa6ed7b735323fe8fa1c4be83c725c6b743f63cbd0d6017f1145634b0b905552a2a237561b37c415146d0555a276b4b45d515ed7dab942f9bf40a26d5366032f23fc5fad8b98a1625a841c8cc97dfe0e2074a363a951946df16d1261ef6b2da7f5789dada153448b076637f9d2e04f4390e9dd32fd5e9ab3f5939807bb451bd19d962403da9dd118f1cfa91731973bc721e5ae4a687bb2270e3e76966dd2156e95796d4bfa6b4c10caaee46e1d8f8495f901cfc241c6f9a690349eb0752adb220996ebb95ed26ef376dbb9eea201906a6a3eb346c64eba3c9e4d1b3088baa0ed868cdaf063a4c2434b9d1bbbd69f44ef659262fad9535988ce729aadafcfc6c3ff741dbf8b784b3465fb05f6d5daec91e915f89117e01c9b0c99d7b7cb78e44f5c28de0d3b782de981be058ffa1294072c4e5a66d2d81641d1c07a9a04012f9f1ad15028709fba761a659becf01963de0cc42b0e16bc5432cffa00722a84628373198dbbe75f209115c4e30e60297c2d737996dd9aac330f4a3e82609dd33460438026ae287c172af8aeed0d6c71b1f9470d60588ebd365f20d596999d97c7a6f265890c719dfe43ae1ee5bba122d9d4cfc96b399f610a90606add4f0d25b903c7ddf6eb7bfdc3b9f926243108f591678b0e92a48d52b1dbcdf30ef8af74cfe34d48d0e02d0f99af2adb090c489d4214f3562d3f6a6e9b83b54bb6cfe6c1961ecd2eb2b7eda63601c835c5dc696b32bc495bda9b6567984f83e79a9d4ee88b140dc78cdb64a2ba8761a827cdc8d2b27e690c22402178ade602f2e9092a1b07d56d142bd24d665d7b10bc7646eb6d6823d5622f1fb08f2e48b8deda6cde324d6508fc428e3bf1a9ed608c196786db4e8d6b7271a07e4f73d9ef76244e3e10aa13fd9b82ce2ce72af2df7faaecaf95d885e64bcae16f9b59ab8e0f21a2f459d00a290b0dc57e10bf21ce06a029224ae15cb86bb1cf060ddccb1f6ae82d767eb077fa4ab0f37d02a4bede5d3f8ee3972a6a3a438a3cd92ffd6c1fb11cf2c68c2c6d1efff62b9f769e302f6c5eec96b0c05a942321ef8b9cf0ff2bb80073a8fe138bac5bd8e93f3b27e7ec7a78512059fa37b0b6939f3b1311cb6ea154909e9d316567e013df315e8f02a80e17feb8f3248cc3f11d1253ef3156d7f12d1f6d7a382d6b6ac6abd38fdb5d954e13ce005ce16bd5625a5df01883409f4ab938a59a75b7a816af6a2447b2c65ea55c0ec4e4f23fde145a26ef0b13b740b352809c10b54bfdf30592a8b0d507cb8210391d66d6f68d06f3a4663756697d472adb6ba78976b423ad9ccb3a3bead9de51e324fb77609729c78664f4d37c7c748ad9fad95af355be4f00a76cd5cc2c0b6170fdf3efaa2571bc8fc2d0d24682fec5e034460de55cd0426b8ad448551032e1f6ade6d96682bc38a92c296e5bdbf42fcf106d14c5e8a4acbfc0cc1f0bd6877c4469be8b204ffd5d7c0ee85e7b3265011ad5e4896f9f8a69997e321a797549cd3c1cbb0301ff30c3a136068ba37b2176e556b574a542db90250eca38f3b0e418e352b5728206d6d531ea253d781d771ad974b476a045ff14718d9a1820fb469e981c7b71ae8fe423b0a04278bcfc967ca602254de37751127fe3716456df3fae50ed508e529c2181d63479b6464bfcde6629e8179f8d5fa5b61003edfc2f129affa58608d6145de98ca8f1c0b3b9b5ae996a7fbc6326a9ac2880206fbeb1c99d0448cd1ac5f275b84e4be03258f9fd0d3f44a692513957fa083a462086787315e38aec8c09b96cca034cc6294359fe00285c607d41fb4e3bf25760ed1ef0802bcc40b2fce2cfe1c64f7c34b21d0bb1f5210360079ca8638ab42943b0ab8277f1cfb1e529073d2068a36a4d8ae8179c32bf66ca335d698f76db1cfe5236e6427e01804464c1ed4facf18ae09148c5a0cc9ebcf6fb6c7d03ec6782b7595816245ac2d1fdb3184ea49800d5d0f1dd880ff99d6016549d63ba2a44ab96f0db0d0cbd5fd4f67af1f1da0b1023883d4b2e7cb23cf85c617c180a771267fe63c70f19eee28fdc50c57d73b2718f8001383135b859f4c2fa3b9a12d095beba8857df13e921d9dcda5b87e1fce6038fc2f92282c717305157b6fca5ca2c23cb7307a093512f985628e75326e0bca2c4dc5ed44bed8e0cbce1238f4023089a81bf62b04a31539de9c8a0c867b791c18a34abcc721c0e90a1604e8d2855e78673367ce463307f6036850b81e0aadc9f81d8c9ad6e3b81d7850d4a46bd6772e651e03581a7a55568c9d63c1b1e8ca947174d68afcae6401b75dc7397be3c0dd76ad1827424f9ea9de8ac99803641535dae3eb57ee1eb1e2c193bf66addd488da55055bcf93172b1966364db4412e44bde64c50f7692a38d1536683af14fa057569cc7ef11f614a58995ade1b12f979005a53bee0769847deceab4f58f3d062767f7ac0511a04fea349e7688ab26425cfc369127325ab7fd24d73c4a8b23f099892b3bf52f35f0d775ba753098611ce35c56873a7455737a42672747bcfa99da8c8d0f06d8754d2babe3eb303cb06ce69e4046541ce63b6c28ded5a6fbf729200060132e9b01d8646b512356c92d8a642de0f62d169b195cc2e7ea2efebe550b1cddb5df7668a0d1f94a2f5cdf7897e46cb03b958ad906393c7d252b58493ce6c7d813c8fdfd5ef577a9e778c64d48c21b130c4f6a57985b8122f3cb69de015081cd3e247de65643f9d863fac6935cffb2ca23083d4fca9b8707679d9d4c3cb34d05d092334b1740ccf4b2aeae724902ad4fb4bceaa642b3ffdd5b564d7bfb725fae91f5c7ab9583abc2d80afd2272b14ec6fafbc51e35bebecce63bd95fa3f39e4e689034c47628345c4d8e30a73c36d87d289b6ec715a2769efacf39c9f19eefdb311b9800377c5c61aadeac78dba6946da4e7914415eced875b66f10b96ec98f64e58320bff09e8ac4f5969608171dbd4ab5883548a289b52d55aa82da62ba3d9fa59734d8f810bc1a40a0e3b2e116873116fdd8bad95471f16a14054fe247637febb6081d00e7ded3019ec03f76ebef5401a27f380fbe8a55bb4a0014f61276d9aa5626a34e7fe5a129a75ff130ccfd78cfbde65416882ce9ae9da57a3a04c67d22d3a12e811b2578fce5f6a64a09a86782bc15e5872e546dcca46bd9ccce5b787d17c70d6b075bf4c789ca184dedad3485a0526a61d280dcecd984fcb7ec663f8f491e91253675877987433e11b9cfcb5940a1357b55fcc5f977fc898f72e8199ed5d8d2554d54a55d6b4b3726e7fd7093996e271e218533f3b31257aa989f5efbdb12dce02d18a5188ec32c3c1c91845a17011ffede3f060f19d59b6565a352e90c5ca30eb252c6fb0cc845833e553f0bbe1822b5d6b26eb817608799b5b77c2cce27beb151060261f34ea73db94bb2fee11864aff76da5b10b17aba6634ae655dd396fd7e7155013fe3c6f840ab1ba9b25489c67f6bd5967a62134b238c325986c87aa005396c54af6357ca88baf5a03e353c8b0175386157d9221833585921d581f1fd3f5d9932b24d41895a5c35be91b35643e7091a7585ede900853aebc260b1fbe8b72d527390ddf46472f7c8d5844355ffc0b731dd5e584e13d65f2347131ba8a5161a6749458c1899b60cf9f9f8810889fc23b5d0fe2c843fb5675cfac6dc8ec8125d1c582186eac82d5e0b3f6df2a83eb2fc23c4c3f873267deb5ea86dcf1e3c5bb39df23f06560609b9fbd89511281fc7d69fb19764c41168a539b44f0603a52577c266fd601c0cc849b067746b4da78d280385ef80a3a553dabe4b137c50152f4e1de456d43e015e26f7d76e612b7be29b9f8e15c6a73653f5f7dc28aa245e64f076130bad58bbbd3b024c97e267a96365f019846d965c037116c74ef18415ed5500f12a1816997895f3bbe7b0fa1eb12a565255a64d5eceb2272027e45ecb0a1a8b5dc99128c002058c569076371703e1f10368c6cfb830ae8bc688eb143da7a1780dbe29cc4c83743b25d570f5d8609df46c807edbbc96358cde9ed0d9b8936271b3ade28001a6bfa6ff7ffeb4e6a6687e803b5e8f67b82e6dff215ee4f2caee571b8febeeff368a89539d145842526fef110174ba3a2d9f1b4a348dd25dd964efcf88847d3eef1c18fde81ce84b80cca8588bc1fbf9c9f34059808d3eef3fc2cef7636f7a76c533933b79a9dd2ae2791d1ab5e1e715837a766d9df1947d5986c21808eac758461596870b744a6a2862f7f5bff0c7a3460875b3b326e45fcec1cdad1cb4b99085748d69a62320f7e6c53c061a55ae20368a4e6cfc126cf2c0b410af545f169fcc741cfcec4947f577a1bfad47b5080ecb41760b5056a9bd10a10ca43677de0e06bf36b0d2bf7ca605b9217240871ed1ce43bbd07a7e77d1901dde15e173ca344ee8078ff115e954a2fa660bd4af61ac32256fa7d62af17a4f95adbdcd09b933fa47828d91a6b710a5c67195797bc789647db90107fb527b8ccbc1200bac302dc47a366d170314f5fd7b60535130d76832ab7a06ebcd83d064c1a1c5a7386b0945d39f8ddfc3503415ea22514a0ebd0ad74e3ece5508d83355cba944b12b669d6355a6143921533190eaeda0337a1b89ff9db0cae62a239025bef078137362db71a9eaa6d0a26fcda7e80a9b8fa4a1799819f0489b899cba4048c999fda79e0bb046d7e765d9abb445279efd13d47fde8b731a944af92da8d8965bc4e90d9da8ba0a9c385357e16788cfb663573d9d34810c754e86e3293a868461b241d7872911e676e73136557db1261573962221589850fa5ce049d2356e6630a142427a2cb2efecfed09445edd112323f0071f63f6a42035a9248efe155aae056db25b8004204d530d27027c34eb6937a5a05bd2096eeb1fa266a0325cbc7ac03270b751013b53429aa2d8da2de8c12e7d4996b5f1dd365e270285d2f3a65bdeea9346d960ecf015215a88f465a66417d12d95be2c0bb3d8e15163e0dc66028a30f1f5506558ef534ab28cf6dc2b7d12f49b0e319995efbde71978ef7121df58bbd16be908298b0abb6197bec22c598413283e7893f0fa7398369b83d30b29560ad09a0a24e029d0c22a7cc6fe53d84a7b2104681df35cf4c3ffd90b14cacb2ebbb673ddbbba291feae96498b30d024398676107d3efdce47353a544c9d885cd5cae19588a4b9e29c700c539bbcc119926e3d1adcbf4e8fa3dfb0d5c2686a3fb4ae7b4b278fd94db5efcad7f280488702d9f7675aafd248960806df3e8f95325298968a8e7bf54cd2797decb5bbea7bd3cbe34081c0b65ca9a4d0d08d86ff39f97751471e09f25b486dddfb2975edd51ec77d949862dd4a658ec974b8a5a381ca5b7314b677c4491e07b43a5a9964d95e1a29fc1d87cbf1a64296f4cbd8128ab13dcb60dfa8593a575140f5a9fa6a3708052b3bbed4b129aea88e66b72e583f1fc285ed6f835df0d4751c5d5f004ee0c65203ba9fbd8ff70fc255e497748f24c476d18c94089bcab8ae3f933563c6682e5452da8f760943c7efa631b2980e6589ad4ee83c88fe0b2ed9900571c3df6bac839df1a6d9d281a5ff627d41ada13b867735aa7377386182b1b113f237c14b6d806079d2f7c234a7cb585e12a5b16f7064fccff99386d58f91d9c235eef730660a02ad37dcfb0352b1da76d739ba7bd4982cbb8be48494acab84451bb39bc59521c9873ec9f53cedb527332c47afd919c94d777e603b405e8563248c9ca72f3b2fb52f08a876778d18e7d179f6437b64f79ca01f6be06d7b115b8d3c3320c2dc0ac59c860aca8c92407ca2239998613f44945bbe2c6a0ef0890ceb27467d1ab805ec960e6e58e49678a0841823632f62c58f540f19e82bf719e12bdc63db5363fc0749877539865a05786106b58dcf50bbdd015893b043b21bc1f24ef9eee5f2487d986db13c143d3366260ade522ab824fe82218daafe5e42c50ef740cb9ac570a13cb55fc30c9017228f2c60680f75ca89affdd376ce70ca5223078a47da0aab9bd18333c14aa021e6c088609d7a2460744006f149b648116152e7c814a5730bedeb6ebb59fe395e6b15d379909f197c4703dff34f8915b26a36e30088cb227fc1df108560fce419f462181e468b5d94251fe1373e0dd004fad02d690f8f28bd972e85ec49485cfcdba717db66e6a343044a2453ceb6403fa0795485f8014225d283da4c3aa6fcbbbdd6b04c30c96fce04579578882a44fe7b781285daa11ee71239c1b69791b8fe45868fe6e85341b7ba4292d6da1ae079875b33d7aa2becb02327a17bf2d09f6a42e9681df41890f17de5cf4752880660a35dab912d10480f20f92589d52ef4780ec28920d11de0de06bf63d61829a3d0894f9a32f911ac79041ef51fbcdf3f5b03f6a0b16f0b9e47444b82efa7c012e3bb9324c8649053433306d0640ae953737336cebe9b854186f9dbfda861fd7eedd76fc24634acb9cb925302d0bfd3751b7b6bab36ebe2ea80cb7c5359a505689ed5642118ce93cd783c80a2cf050f57d5acb62853367ac606fc1b8a01abb7b29e49fdb190e2b586e249639889bcf5ad23161f278086f244d0db0f9ff520e6858b68f5bfa0f5ca700096277ddfbcd14a4cf4358c0f042b1eb34bca6353a1383f5d310176262ba45512ea4f172f321efe971c391fa9e9876a250ab653fd6d5a8b046028018ae043da256b78eb26d86e6e89873476ae24dad26ec1d39da44ffdcd93d8c5c1fe0796bd46dbe9b01be0aeae841662c10ea28cbfbef76f0197cee86dd4c7dae3ba46d5c2884ae977c456681d5d9859d854a3e0708bc35fd8415c22ef4cb889bf0e66da72ebc635b71f5df04db801c76564d2fbd946ac17e27fbf995994ad26c3d577ac86b3b19f855d87bf3f0f7c3fd574b89901732dfacf2e13960975176f7418893b31747d96bd981e9b1463590bd35b51b7a2eacf1a7733f76a7d4b02fa2afc5925f5483f82cb529682f785c21cb951d5678a7d09f99c0e2bd98948b79456e4e0b5d9de80943f1df0c639ab8acd6c99a6297cc5a53a829561a6615c6c44b24a30a75174aac207a35fc429e1a415b0813857ed85ab49db6e523cdf9b122c2442a4fc2b4fc21685c9c4a5de8f36c0b405e34ddee91832cc6567d458ab76b4650020d270a65a562e75e06a3d8f1313b4d1d4d29d597bae9eee653bf8e31b82f9cad2d0848ed5daff73d99472c7e71d2f1be60bca4ee9d315196c096cd8260192597c8ce3cefa9cb6f129dcfbcbd65b5b0e19df5a1e81bdd423a2e26d11ca4f7aee99104530c1c8e3b1150669f16acf415559a38cb27eb6d637c78b1c90ddb5eef14ab9b2ff14ddababd7a349b7f6f5b6caa3a28c45835c9beaf8f836848f579598ae80ff9af739cdd800c5a3d7675c780ad66b2c449824d8ccf55a7669fb720604eeab427a0308122c3039ef9be6df46e34b719aca7a001b884e3f7b1d1579176aa4d365a25b6f3d420190e3cd9babefd8382b6bb12b4c38b981b08b5a139cd46e9382c01f361abdac7fb16b87e2c61f3241191028c770c3e3be939c8825c63bc4e523b389d1ee28189b5a2c11ccbe0aa7d3c2b47443028c89f3d4bc1bcac39eb61d91e75e0d372b9f27c8dc622a86bc0cc0a9c9dafa5e2bc67834a75805f3bf1571fbc5528e4c69f3e64ed27c1f2d93f43215ea0d4213bf2809391b8b9201f36ee2a275dc7c44d0d83de3b82490b65d2b399a7348133c4df7ef40e6dcc114d040f65de00a70cc0c9fe615c6fa90a2fad6dbcb39370af043345ebd9d8af094c831f341fa5f7658c2c1ea062948fef5015696eddd181d87dea49ac8bbcc2c7a1ea01ba1d04239153ca401bdc27aa87093a78b2020109d7cbdd39f279a7d67b14a5822fae28854323a2620033a5fcf9817a0d45eca7e2d120a113fd5ccd9fc0011e89398767f7f6b7d01d5a670b4fcb9c5648991817a62edf43d6964de204541a8b5573d7cc10bacaa1bb835f87d12985ad5fc6ac4834ce76c76e5dc34cc322c4220d9d65ca77051e7c1d4edcfb4595db16c641fa445401c72a24e36567631ea02e4875b7f9ac2ddb4712b79d1468c7ed2384ad5d90ea0825f817e42413de33eb30861ac92e19b1aada118beaddb179399008137f28a8f3df1509ab12d6f6ce7872521f5cfe4738722fdb410b3824f139ccf8ea63817d154b1e497a70e6f55b75e4decb73d10ddb0c57d7e0f74b3f4fb41ee57c2da1e4399c2577f28b7e911db08e877c366f231114cc9553c7f3cda2b75895fb60ce9eef4e0c25d253f689dff5e4f9cdc744c301b6f13e9fa9e30bdba8abc203c05879ff01bf8c3a3aa742ea5fffabbd6d165e50bc412bf5e18c60bbdd4fdb276f3bbfef246cfe36612ad61fcbd4498c18321a1ee12e6dee902c737999f9c6b3919f52125cc77e237a788640f262ab76d5c9db9ceb2d988c261dca63455658293b10842ee0b30cc1f928215e0308cf258ee39ba666b16319d0e21df8b9ed91be2e2feb9e117682cdc9edbc20b0b3b9ddaa93ec7a2d8f752ebaae57b7d74037c5cd64cb04746a38c0ea3ba3241319360e585c257fb593c123a653e6e0420fc540bcc0f072de6ae1a31b57dd5acf0b8607e04d21b727c93623e5227202a7c6432b308f74266dd1e1447a2d637a5259fdcd1d8729f341a7dc383b4c8a6ae0e78c34a55793043d2dddbbca1d161c300a8a7cb760298541c90a1c5a890b5257369b8fea0b4d14dc0848e644953cfd5196494e4c1b422f8e188314f2fa903fe93393193e9b76bb71c0caddba43d8586d72657a2d717e4b2c3a0e8bc33a6f8d89b871244eb04e4ecee26f9b71ae7d5c44f828083b0c1920d37cb5d7db86be3b18ef16653863762939cd1ab5c5e0cd1c495ebd0a3037725470d526bf12d21c2fbf4946ec224619c79906e8c87f0699be8a3621ae718aa232e26e43bf7cace7918ce34577a5e27261a4a6bdbbb8ac21a8a40b0c9682a0e0a37b7fc43306820b0db5fb5bbeed529102187fc3e5019185588d1ca6222a5e2b60faa2a93857bd7224e1e1c3c86128fd16993aaacaa34d8679e194ac0da6bf617144a2b1e844e7f6f8884df05ce1624ef1fe5d0895265bef2de61d637a74f78f6e3402923c9363656b7b91131dfc8f8f7360d14e01a25869f0f15a9355c07bba82e4969f5643519611d99ee9566138e4610712d55f22ad36c7acdc9e32b4e1e9b1ee9bd14ca122db05938840b8f47a5fd25a26072e2055494eb4ba916473e973c1efcef8dd7f0f04711b7e968d59d144fc04b9c6d8f951ab973441a6086ab6ab896f4d282793fb14c74322c7ff1c4c1c6d0544b7457635a6fe2632644344b1fabe12633b2f7d8fcb6e0929a05aeb2749fbc99671283c47c0eabe152fb6215bbc6e03d61b1ae955838a8b7b3bfa883a04f5156982ba433dcb21311fe9027a5b2e133cce16ac15786d2d44b5e4979cf2a8667d2976ea386eef4c85bcebc39b9d2dd216e8b4f7c68b7e0a5d7ff570770a20cc605e66470d995ef96f1e0acf6136716cd8a26b3b725db3ff48364f19cb2c640600d00d0d728d8fdac7b8a205ba8109318eb5519ee03848e79a1c33898555b298aa62d6da66188506638918b46926a99ebfccb649cd6bea1eb87fa6c1999a70937f51c4a2d485c6aa2bb5f98b1c8ae558e82287b9f34ad70954f8dbf3a9736604c43bc3062f8707fe88483b0865bd6df65f7e085593d5046554ee465a10ddb0c0b651e2b1031d56f5130e100e4544809a093026b88277e4e1f1e3aa40997871ced6e6eca44f183ee09ca679e4fb0796af62cec931c553ea788e75fd37ced477f9a58e54410c513fa79a4b5552b049fffd7d261d90a16f253a0782ec75219d1f7492ac2a242fc04c0216e6c804f8fd8f761a70eb747e1545313706136b085fc72dff1714ced89ba14a65a34168dc0e997ea8718ff304a962cbe8c7df8b759d76eb0f18155e49822d21d91dc8913c323a824da271f8c57d44a27be3f04991e2a47e5c8da2f0d71610be89dd4459b9a9f5cd4bb5ebf730a72617613667984d9a0e0ccf81c803e46425899b2fffe9158f9e3d7c36c2c42938d9433f764ed1f6d9c7d69e9ebf854db44c398c00b2612cdf19927de8bf45df70a5d4307e3a628a88a09a79d4e03742f89363d891b241383887b4447d0cf3e0eebe4a9143cd6873abfe2993b1f4d1b3b3a18aae4db4465385500ebef246adf17f1d9196f78749dba2b12deecc5c957e022f5b9dfcc3536bfd306a1a70e50f7bab1db22e98c8705328fedf3686938eccea04e7db4abfbdd939d56c0c357612ee3536356c0f5bbf1d428fb31c7b06a75c5b4fd5b020e6d9894b50eaf1df723131712344888adb5a0b4c07d23f6e853c88b51fcd56beefa721557256bd9978caca155db7f9c325f9564479c39b589431ee7d5da402e79ee6e04061c62c1f369176f6b35174b65a978ae3a4e8a25032d987dbaa5ca048734cc1da5f875f72db399df6e6a300db183e96ade56ecae019c4559c8f7c94899178c98e5071aece48a3e9f5a795159b2dfd0a1aa784b263ae5d352a890b7c2c6887d76f0364e2028d4f9046408e76efd6b5092590d39ec343facb16ccfc0000bfe7bebca2575b1f02c8a0aaaf5fb0bb13ac3246e245ace99f2186160a12792fabc0b390cb4c32f87c46f741c8fc940c4aa7843d650f90d422504bf97dd4825e533f646c6b77c4f004b7036b5480b587a913f05bb8ee470f0ab148727835b1659d8c046fd24276c95d30158424914e75d9b01fe52b34d5f76b2a1c98bc5236945fb46724e02851d46aca237fbf047f3055d6331dccab91c0bc20be2260086552fa7c958840843a3c38acfb24f9dcb506ee3cfc67f3125954d9090c1fcd629d1c3fc557b7d6ab33b9369ebc8b5b43f9e23673f688ffe50e6c3dfb12ac58aac60590991c9ce68502873fbdea04455459f6ee721570a87f87ae03a9f97f6e457ce1447358d8e3453632618701d62885ec4f8dd201e26405499dd7f317a8d2456940348827a08950d548b5c0b24cf494eb76dd0a51e3f5c6fda9f8f6545e3a6d1009775d78720f9b20ddded15c162f226873162a5076bc0cfc151e655e29d100b7a0d32c9c783375d1c6af0f39b51d927442386cc2c26337cbe5f4a34bfbb65b544b50b4947f72d839e6255a95fc859d6f1e34bb63dbfae1469be613472f22cbc703468d8552b9c691c829bdaf0d2e7e4093e940398f9ab8837baad8d9e4c710e4584685df01ea15ed9ed95ba9f6420e5766363e86ab8dfd1626eb1c7d2dba91d360821da99977be4642488972ec61fce7d754dd45a4d7fd9fc3498a6b7e0b7235c7843dfe8980bbd3a52c8868c1832f62d9e25a40986d061d7ca9d8fe29c7f234e3448fa315d749a09cf29556060307b970e5e080e90dcdbec4ecab1a7868cc5bad1037c07e17f961f3cb5641405f3d3c1439596a243f83b4f8576019712320ccc40581bf02a0788e3ad9cf4c44113d47f587e96061c61c06be84f6e35711d105f0c46b31f036356f6abd329c4e1e74f7d97ae6e4e0879be998a85257b6de6277d9c18980208e83d9bf266c9909a26f3e19941e728fe4ab0866d103644fd86b203029271361ea97fa93079ff227861aceb55e68d7454d1dc25aa8a7c780590a04756c840d13dfbde1d52d7df47d4146ed8d530907fcb13f6071e5c18acfd0a694938bca6cb081b7dbef2a646aaf55d4da9f3d42996a90655cb48144a4dd2789d75692530dc02a2635c26d428f2c6b66779bd9facebcd73274ebf333b8de26609bedad5739e73ed68798cf9882ebcb12902bed483bd905b92b3df495e708a0914a96840761da66379d85105f29e14e47a3e5273cc23ef5053077ecc513363379d2e6cb3aed80098589032cab7c20eeaaeb7bdae7e3a1c7a704cda4568138ce1ed94e944eb4ea72120ec91117338d0c86116db36f3807a70bcd98de03cc46ae9dd0c5fd3b26d78fed5a8b53c0c8f9566f921175fd193ec521c9914be68f2864715a572cd6b25948fb8dfbd75f4315967d5a6a707f1ceb81b98972e615d3e81b08ad5ef1838af673af9b6d63dccc226eda6d0b6fc1fd104f62b80662ff157999d7508f625fa2408b6f9ab4deb410ebef73750dca3e63d5045300d9b52845afc42f064bd78ce574ba9b4fce22aa3158bd058772ac2eadbf9fc77bfdf85dc745b529e8baf248a0bc1963f8fad78471116b9ac11679a326e92d87e03e316c90d15d2f9e3921e0bb6ab4b7ce91f12e7cdcd9dd141b8ef160e5db1faa47525a77a038558abd98757ac5f6313afb4f4c84b2c768e456f6de4a78b5b25f90926352fbfe83037f81b31251249fe52860f3cfa7ae1b20c73acb015821840dde2ff2de0470450b11aed7c1f84d4020147f8b9aeed4a37909bbb63508e533f939f23c2f5952ba6734745c51b837b72a398a4eb8dd6b4ee7648ecb55799cee7b6385ecb0b2e36b9518439ba550b257230885b83f72312e53afce7e7670b26342e4eb0a6286c0693c54abceaed1811418a9a289b4b09b65e84b3149cada8114e830c0403884ffb74c515bac074e4a981c61447ac99368dbe9cab8830911ba9cbb64633f444716f401aa17f599174581538918e88cd255765142a49412841deb528f44a64acb372498bd66f979d9189fa0f0e70e305015dcd3c9aea085cb0f1d79a63e92eb39b2dd2fb1b9ee9aec0213f3a4a848f3450e4a6d902f5435e234588ce4a7d2c9dbf60de27227ff02ee4ca19314d72674fb06c00ac7e5d15cd05fb35e973f0974a4718ea9b0d35bb4064a6280b654a15a7188c5d5a5998ba1f031a3baecdf7b608169c0ede84d91c9a5f73b0176e5ab2958169ccc6022e0c43481bb8e6217ddb1bd9ba8e8446aebed6afd163dbb6873d81afcb74b034085afec0d626b02fb10839bdf2279acec3d8f3f7c47fcc3ddc8cf1f08de8c8e120d9c06648acbd1ba6824ff74419776b73b05d797a0bc43d77eb75029112380ff4e87e543863ae29065e40c1b2b1b2d62a409a299ee5868036835627dacf4f9f7c84fd2f6707d823eebca0e8ceb2bd258038b137aaf43e0e937be762be5d3a6545e439a45090d397c8d4a068286836780536ad99cb138cbdc6fe5e9db3bd405ae6eb86084be3a49c8af88682dd52a5fa8f7fdad76cc0b452b3c37b27dc3cf66c57a4ae59a3687950ad3f1fdab3002fb2281365348cfcd9306583eb79a9555e8750dc95260a1b277c566babda92cf2b3ef177854fcc3dbac88da1536eb3c6d6fa3e336ed3a7a6da006901c845619fa00596af8e54bc1980aec4aa97bc98266c248bc038013020fdd128db0b9425e8f7e3165f5b9190fbf2dae5e317485d9d103695cd209d5d247ac7e1122bee4538b5b74790277ecfd2051e43a34b7c5440d1198a1875a0501eb3f519ac2f17553c5e99a9c83412200a519251d4d4ed1c84baecf7d8cfbfe4a7e50d789cc034a21043fc13fc3150314bd7a7801bf9c31aa00b7cbd9d0fa4ef0636504f0dab63316d9b9a1f4703b3be23170549fa3a29ec02f418d687589f77939fe068e41abce460fe118b04fd418f28edba4fe70d8fd24b38078a5c47ea236d73610ea116666a49acec52fbd810bb99af1dc5bfc4eaa634dbf2178151acc453f93567f015f2a25002eebc1f778da195b7e9cf683db1a85da98a99d98614f2c25b2237d4393f5799d06cd36254d3f22a53df5133cb1f43836991d3f7529cd260df88bc47e4172ab045b66e081940dff797b28c632898140425c3f81a60236b82522c0da7f0e0ec7a8ccdc73cee175d3b4543293135c31c0e0c926c7506920cea1d0a1eed64ede7572b8c77ade1d95bce10dfa69fab7fb5ba64055800593465dd4c26717e37a66089f550202a0530157e5274f3d3fdae187444f5ed641c608643eee1b361d78c9ed8070a85150c80368a84b14c9dba5b20a9059f1a05a60de938ab914a093b2e741e891c02f638c73c730e60ef8cb5d9e5031fdaf6918750f192ea7a76e035eb05d7556ad64a77109c5e13bb3ac7627d99165567dfbcfb7fdc7bd847ee7dedd7864353f8fdb7a9939867d9a5ff4d9ec9727fd432d8abb43628519cdb6fa49ce49064a421a89bc924cf6286fdec8bea6b5a7b8eb606f584d44c7194d5424f98576dc4b5ce7dccf65509727ed52f8d7210095252403023473af96eb5892cd3881f2e1f4dedd4c9b0755b70776aedead14e2606bbc1ea3c300984ebf27ca69f36beb03c0fe3c13d9df79791d828d52260103be72b832ba235bf1165250b608e2cbda0c9c8d3c96534802534080b2a4ddd5be4f269f37c4cde9d43dbb42fef8d507cce8b8e2eed799c72a2fb836f4160b5e5729192f088ab8557d51b58940065ceb4b48fec1873cc4b178166d15d441f45625f45af62c1d13863feaa8afc320bb36af0d151165c122a47d4306d075b344974835363818009d86c81e90345cf4b7d81786c40318a371fbedcfc325cf0e853fdfe6e91e99c07dc9430c04e6069b9e2efeed0eccfb161ca85d96298ae6dd67c395b78668d5818f567f2039111a7a0c52a21d84ef72dedbabe83f811184a95976b1a90dba5aca60d0313c546ea97d7b2e40b34ae88ccf4f45e28f05f16732d7a0d62dfd86e40a51de7f2b9b66ed780476cebeca547c8eb71ac20a245b1bf7445e64bce260b8871ead95f708974c3a93dcc4ee979975daa399055108854c1c3fe5a07046d13169c084b2e4e81821ff73d5d20e7556f40fa152226a6da48d5f86cfcf1a5520451c3c1e534db654b1a58adea167ffeea90023cc2b0b01710323177059e1c610154cb234d5ea165dcaebdc2fd9d9b66413b8a6848ea11a673f207ad76bd3ab5399dc0ed58a3ac0ac9d3c53781c36415d54b452a4a78e1eaa7046d062e3105541fec8819439da85ce53aa683aaed543704aa8210b26c1e6c8f1d1814595e3bce2d98a36089bd722110bcefd651937892ffd36dbc34f1284eb32c49a1c134ad460c19e01b3f3f2d40f664d90020ae8c546bba9ccf5500171ad07a55f9fd299d7518f00c0017f6c25d4aa01615fc7eec160ac2cc1ecd38bb0324e54cb466c3df4d56508f5239e1b392a50a8c20946a6db9220088d77c494406296921e3ac9997c34f15fc5c39f2529eb2bf6b41b0415e90cc9d7e8a83256cc59b4607be49eb76a7dc07c1ce3d0512888705c9ea145079085273f2236d5bb151dbe7d1bda2ed607fe51847ba09ea6431dcae727ec1ef0a201b8df9e148885e1308425d5c7fde473e90b4382de8bf5e215c3be357f8a2356348bab00a2b629dee017ecbd76d7ebd45fe4df2884e34ecbb86ea371fca29496fd05327c3b985a069a24a32380ac9e4b131ff48d58b1c528b941dc6290cbb41ab4aad2a55e5e03a63813c2113c0740029529eca008d906dcda1094571f5d2cd31ed79e9bca8e815e206b3ff3a7b4b82b0d30775e0b77260a42b1ccd0a58a91f0378df95cfc7f8dcabcabd2d7ae3b603e9061c1e126d00fde94b4b625e953b6b781da167c71a6a7ce0792e7de070863deaff94d74a7ab9dd2e3d39519a6c5c864036f7bcd4663fecd163d78a72a74d2838b6949eb7ba85dacb2eecbff1af2792047b036f77d488e5256ea16252257bdbdc1ca3d18d01c5de00ae8ce7d1c4cf103b2bd7a31dd52fa92d945da38eb9070d6f11aa9cb8bfaebe133cdd7a72f94f0fa067da0481dcc86e6eabe115cdfd8fe2e2c63c3cb3c0f75a4655eacfd337ddc82f770442d18ef9cf3993a9d1830217f50917153de7576917c533247a6725a0cb7447ebb0cf7516e19781a8ea8d1854349db9d3bc4e4931a1fa4fc075186dfc37ac10db1d3feb6298c1fabc8d897e1c806e38981c3fe7f252371b0e92efc61b2e787279f4a8138e7c6527ffc4092de912378ae692e9941d0b6d14354dd25900912f9a907dd970db649dd965c959e60f4d174ab0aeb7bc016735e8b847e231bdd240042aca16731926f537fe388b6496967b750a94cf514c9296805607b5f44451bc622486ff62e7af5c0d243503ff31d1c753d9fa3adecc8f555445298aa10a877250455c43d412719aade5a202076fdf080589a28cbeace5a63de77d188c1fb486d888528c5142f92e54f005239285cc4f8695c05ed32fddf0b0072bbf7642a1daff7246055cf35e077acb567b78c73094e583b9bac3ccea986305eb4322bcb923b93187bb3061fc00ee0b3d10702d7890c4eaf4e5f3da2143282dea0b12c3f043818914ae3ea98cb1322d73878b5d9920e87e6e00ae831a3b76484e0f69d35eb15b053c545464811f9c381337a80a603ca91ddebab47b72d6c80db4cf0646c579a136326be69bae46cb6ecbe23ae355cf7181981d8f7b8e16b3303aade349f44c005602c34878690d91fb7b4bbbaa75a91528fab18c3c8c1380c0c26a98dae3a2e441527e8c7e7df331a506eeaa2d299757e8b0cbba97a91f64e36e5a24cc83b00fa14b8a41e6fcbafab7eaa905c04c30755c551b2f0f1a24fb422bbd76090e212efa160103344200e83545a119cd7d2f53e8e5e6d89b1c75f12a44ddce7b9e9bb4710e30c853ac8d024be6f5b3d162941e2767c61a7f7ac5265d08a680b87f07bdb4d4e2037b99a6eeabef33b7ca6e7e6f4428f6814e294b7c08783525e1f632fc2a43dc057264bed23898edcc35493222a92dbe28da74c07c49fd725670ded86494fbce9476d3a594f4d96ccc3302a9e861933dcf46d03b7648bbe7bca88d9791b5a62694b34a9ee0d6c9d5600f0758e7e0a2721cadd048bf59d84bcd7ab33a5ffa8c1a237dbdf3481f03e6368b0c1a86ddf01b962520372bbb8e330a70cc684e84e1a438fc571ad9bfd297288135934aa4f1310849bc9c1658006eb1639d4b8ad2f858fdec1d5a4aa89259e591e2cc2948ff126caffa24bf41bf71b408da6b5107e1d65fcf37697d307ef3a3ce742e5d117e7bd4d095dfe8598213e0925bc9c8da414b09fd21451ad8f3531a756f15269614ea1ed728d3d37820c6e90578aa43f8f4cddeb9ce97b345840899a016591690a810c5773572f34b68d1f2f1538dd7c541508c990621d54dc2653bb4a7e9a1c637515538840f836d38333de92ff70997478fa7e4eb0b447ef04a96b2376d3e7319b49f8eb0b9c656bbaeb8a000104f3407e33c23030ee9d5d92a2aa7ff76f419ea3b1c9a8953b30a92759a8d0fd37b50e66c8f664792da1448f8d12d60e169382da435c038f10be62dd1c0430f18eb30af8c14512d3311a28d4252fd4b4dcc04b5da190a22c6eda7ad837e470b9d8ca3254f89a3e613ddc74c1865b5386efc7a8811e95163fc4c2a61b738bab3ce75e9450dfc38a52a59b89746cbb216cafa6faa0236db5b86747e7d9d3b6515bb19aee0a85bd4c2bfd76c1916e04db2e0d0382efd97d2ce79eb9370087b19faf4f269e7fdf64f6c30eabdef01c5a4f347dea6e28c48a55643ca36881ac5b283a9f85a56b203c3076e592779f91d3a00344a29eefcda31e2c66e38c6386367a5b43dfcb3978c891feda33c7907d7e4a501376e1786b9cc2ae1e0a60b9c0c979a0c1c96b9c126f647c3bb21abca0d4498c08a4544fc46ad1a33b17b105db91390689ecdbe0b9e6b5cc1d65a52a51d7d3a714c850c14c9329410c9efdbbd55cbc43e8568b01957d664de2a82c04caaf9e55ae5a34c533bc4da5c2a715409a900c7dbda950463131367613ddb0ae44c73625fc8f293e4002d5b704645c08098ead5a0fde1980d8addf0af0efa1288d569fa62d6b3f6227d1b4d628d1142f5eab4f7f1302bc97809b1b022e5976b32da3537a192938b8716307aac1972cc5b97019f4b7a9e5e650d0569ef4e7d12f8b123b1ff1d95d3d713a18dce009364a07d01b3b62a1f3ffe29130bee4f3b275dd27fd6860423629b181194a10ac44077eb2323e931cfdf64504a94a1e7683110ee8a21e67396d09b85237a51d824966527f9e3681ba9fa6db51e571d7d6a1d04d0f9bbd9d1036316a67ce225705018d1f0a9b9817b0d01dc092beb4e1290a7f12b22cc32697a75e17b9a93ff817a721ed0c696643353b80478a8d41e92b0dde35d7f2918f310e829305711683fc8c2119f0759e4bdca673ec93f4f0837aaab4c925925504fab72f35bc494a4d8bca2b2ee392af02422b2f80f174519fc83a06f99290cc7f1812a32511dc9fce9499947c92cc12c241923e62e98824b85ff3ea4979bd4362f87b7a89204598f51629ba1bc6d42354cb13c093d00c7da85b2523fee61b85573aa7d4a3145d518689ffcae21ff6470a8210cc6302bcce2459244e6f9173e1d9447726942749fb6bb13bd0d3479ac5f1e6d70e104990f2c9311046798f906aa215c002ae0b918af3db1bc591a937d5f485489a132fe9098bb77387906ae54d92d368ded939a069d0866279e0f7cd815062dc25c664c168ae4a11b9f1fedcaff8e3c37b6f7b075e737354074381a135291383a35047b1dcc7cf3b815c1b7ac187a4dcbf64fa5ef83c4fa2c0b4f5b7e024af32ab5d72e4e86a92acf858ff0aaf0fb8fc64fa12d0733c6fc530ad739df51038fceaa88e6e47fd80a357f501dc4ba5de4b6c0c573534a84e5aac913bdfd30e548c8009f06e7281d4b91b968852033af7b9e79b644b1532b9324b9788ab6ed930236c5bb2de248231f3046f490131ac34586b43a3c8e0a73cc756a816c79f3f10f12c23501947b29617fdc2a45c7f361d27966f73b1b3a1f50cb0052dcee33ce739cf2da8fbf9b7e5734c5a7fb8eea9f5a598ec6c207735409ca3401894f634fc787fbae311d4bdc8c99e8986f306883d7185a18e71b5166cb9b84cdaa3cb03231ac3053beb31ff3d87838e53ef698f9921a0ebe69c9b1526ba5940bdf21fd745f6f2653adc2d3c36340a6dd7c9ada045dfee2349e26a62b437e0c8f4fae2c7eb9eb577c20886d8a8fdbd02d245c1a1478f52e339e8ddd71fbc6d2cd1668a44e2c82b311720996b8da7111658a04f4b756d84418ef3e99713cb73d87bb4a14f69d5ef4a8b8cd6d0008164fa0a802c0679b26e155d801b40a2c77453dbdaa5a582d7c9d967e8a5706358c68c6da6c3e6746f0648401f896f1674797b0e14b354c27ea94fb12ad6d8494ecb0eca0eb5795b1920c618b429b4e95979174fd21685ead022e7ca4f87958c8a101b8b3a5e0a9d64393395b12dfdbe7e7503b62db0fa8813c4eaf1ffe5f190de55e83fc3a01b10a647d77cc49b07a258cc4e65d489451f849f6aeea5bde2aedd8e184cb9c778a3676dcf87d2bcbc19647bff28953c5d06fa73b860a16785238f9765c0fa958757b4791272cd8d1fae302b8dc47282b782d5c4c5ae75a9c02a3e911a79547df96d2c2306a2e347e83a8d8a126e6a3a21cc46e476a706af9c42a97b3f8fbcc0de5cdfb59bd6cecba11bbb93ec1bac6422b61277eccecb8b28b3d97f0051b89997c8c22a9f517d9fee5e16606614fda11940cf388c04daa1b302d3b0590a9bd0692d6139b77546d71454054197adf346bb94b4f2e85e502e3cd919bb43e8b424339e2af0e7070b035271783b1d7d48ecb6e63f3597d08a9d0677a44c29948d9cf9570e7fab1ab0d8262bb963d62e895c9bc8ea999f6f8770ed5ebf75a39dc0fe2eff88d75ae19690e0f0d52090f18bbfbe39697042cfb5293692f1e66d76aad38bd919b634ee20000000000000000000000000000000000000000000000000000000000000041187a86f715ea1475c76d354d556242c15f6b8f7c441cd862cc7c89d89a58bca02ac74c422eb01833db93e4b067e507da65080f93cf1815f4cf1dc0d53a2802230100000000000000000000000000000000000000000000000000000000000000","nonce":"0x190ed","to":"0x91a5d806ba73d0aa4bfa9b318126dde60582e92a","transactionIndex":"0x3a","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0x1f02737dec59ce5f29b7e11309a33cea7b370eddefa1a8007ed3fadfd1c6b23b","s":"0x106ff6938ec0a46da92e74768b54926633945ab503e2f2dcb69469b544907586","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x2d679b567db6187c0c8323fa982cfb88b74dbcc7","gas":"0x5c90c","gasPrice":"0x7d9f6fbd8","maxFeePerGas":"0xf49895cde","maxPriorityFeePerGas":"0xcfd6ae0","hash":"0x45499074aa521ac4151138f0aad969bcc2dfc1648d22ff8c42e51c74cb77414d","input":"0x003851f8368551cdf133121c7cf32ee5690000000057b378dadc7d07581359f7f74c422f52a4d750946601a4898820282002a14608e24ce8d2412c889246951210c5eea0206041c4025828362c2828a8a860418a28208a224185ef99505d5d85ddfdbfefbb9ffb3cd964ee997b4ff99d73cf2ddc5b063a034cd01e114eddde75618857bf21dae562932ea35bbe70493443b0d3bda8e6161bdf9a2e6e1a1d63845cef77f151ab3e17f6819ec2bc7388893dbbbf49e9f0c76d8f4e3a6d5cb9c46eff41ba97c0b3794c105b1a891908a7812b16b0d1d7780802e8c7621a188764369f6bba1bb0c95c54c4e3ecad237716b875175c0e27d3cb133dee5692910d9eb1ceb4679f65e7247f51ad58b4609f4c41fb91c48acf7b7d2a8532654b741723ce4f70eb38a521e9948c62bb5d73328e2aa5e7174426f5da2a4b1c6ef04eb66b2d4d1a48f0a20cd3d8b6bff8794b3975124f8d8149ff9c0b714da5e23b8ff418940c5dadad787c4298fc8486c94c44d45593bb8dcf6cbea18578904b0c99dd61f2b7653a1562b2cfdc3dc96fb15db01fd11710145c7d6b0957b60eb6fe886a047920fc64a496565e715ce7ac34a51a8fb632f62680c9de88bce189d008e29a23679115012cd789ae2fdf6cf5f4dac0cc4aa2e092b846d3d3b36974cc62244625394645ce73c1eaeec885e6dedb131a1d420a57f945698a9e7c57befcea025554af9a4cf6a432908061828ea86605e8ae7ef301f4c388060625fc5cded2d60f4bcdd4270b2cd05a133fe45e31ff72c0fb8465065d16678ff60a4f2ebf901d2403345bd6c4459c6c6b97bc038b3cbf9f0ffcbd7fe06fca91bff93e504946e2051d05e23e28dcf2d35dd2d1c2b16da8fffcf65ec0b789efb1afec71cf481e5b4476b7df95109b64e2c1950beb3cf3ec9a671ecbebbca59aade6ca79f06328bb06669266f9fe9a6673c50f5aced1aabd49947341ec338b82d9ae31d9fff59a0511ed938e016432f9c5a001a7d5d34b54a7d9a2419456e3bd0eaa860ff52e69806188aec7e559a70415ccb6653c885fa17efcfccdb680026e43c9ad0bd5b379d4da2127d429e74dcb29f3e45b3ead08e1e85c2be6505fac13244c6e528ea261329310d9b80b16bb7b562d9477dd95f6415de5bddec30bbcfab9cb9bbf88e71eb47c16df81087fa93c4b39b5e0e1cbad17cb1bbae73eca0e2c75f73e12e89371e79a4d42babb71e9da013fdf5ff1c20a45ac00a02bf1ee09b0efb1254f4862526e5abc8cafc311bb27abd9af1464ed617acf4c1647dc8765d530e4b40fed95768dcfb24a0782f32fa6cb29e165a5745f2b44a8875a96812b99a095edaf5afb1144335625ebac2a489d9133676bffed7d161671de594b27973fdebe55eef99d65ca83e607ce6ed86d32efc36bcb4bffeb2062a99371c93d2eea8a0f47519e0b40ef21ee8d9de5e8d8da61657072561ab1cf9a4b1d51da9926a2d934cb9be7a548af7a5835758b5164f249ef0f0b53051779089dab29284dc10c24a1ee298ff1faf3aee4072cfd4ca19520b23941a4852bf56dfdf0eb075ff435f87aa51ebedab52cc3ebcb4db9e133e57c2aeb10a836d1f5484807f73a9d411e059283bb45fc028cc8f919abb8ad2b008ff7a95ca576c0c04aa4f243f10d2fcbc425ce014f5fa6793335650b99beb722faab1bae677d9939a02d3de5e0ae5d5906ba024cd019c11f0d51c89e73b8cb3609f7faf3d127f969f3beddda1a756fef93ba1a4d33e4c3992957a9c304394b7760063250a5519ae83b304c00fdf0a21e2acdec12482b724df3ac5ea472c065a9e2b7c8de28454d72ced29d817ebf3126b6928c2cd7cabbf0cee395489744896faea55699fc7ec581ad49b782e1bb83bcf535468b91703bcda0c48fef1e919dbbf30aa45b162c92f0e01496643bab3d9020b8e471695769f04020557e8d0fd5812bf346deaabcc118c92dfa146a1b5fa6aaf5db5e6fd704d073d9c6d549004066b97db487f857716ddbe6cc6332f7ddba3ce2df47f0f25911e833adf8f345677a96c7223a3efc77a3f7a5d24e543525591d1fe4afde76a4a3fa883efb81fb9e324c5727a5d2e7c04013a249366aa8f8242373f9c0aa55a7366d364b0bb89ca1da127046eea1de1d39b917fa53d6acde40da381a71d342e3fdbb19254d7df86704eb979ebcb905762ad78a852bc948b97aba45e99ea4fd7e0340ba70097b4884abc81c20e99276eadce78b6b5f075620424b9a83af6457cf29d9fa52b6df6bb7054711e789cbfdfd1bccf3081ed96225866598328089398b84ac237a46aeb513780c62f5ba256d9de6392fb333debe7b2ebf00571be5b6dfb5298b68c0c4f8a281db7b5a819b91297d29e586e6e78dd685f9810e830dad91e79459de4f2cc484ed9cb3a49eebe9b51975dbedfa1699e3c2fb9cd6a7e9ecde33677fd57e07847bdfb9bef75f07bb9f55f73c695a97ac188df3280a5e92f0a4f1c4adaf8f53bbab4682a9dff482e9cfb43db9dcfcda1a466cbfae58cb09a97d8336c88b124bf1cfff8a603a78299b6e6a9ffec57be9c75d73fa3a86049c56f127d5f3a6645bec138e6f9ee98510eef2dfcaba7f894ce575889ed3c89b3c1caaa37f0901d49f7ef9d46c955095899a76feb44cab15d918d6f9e924e77ef594b9af6e7a2bcbd2190758bcdc73a2cb5f7e25e9afd87f893b653e7d81b294fd6e0bfca1f5565a21f725312a2108c950f275a4c0a698ebabc567bc1d0e7b1d74b027f1dd7187cb584fccf0206d997519a61060628e2255ba437bdffb3cba91b64c87899fb19b5790ebbe92b0d55d2b0eeceed76d6e91aa53c6ae2113e33e299d531c4fe70c696050e654c13387f0f5a9006691089779741473c7c7dacc4503fe93cbf7565bbbc4f715dade96b451a21f1e36920bdd10f42f48946f8ac56ab3afafd84800b2a9fb6d643cb17cde43a619d7ceaa915e6f5d209ce489a8b47bab1eeb9a93792c6dc3b7676dbacfbf3e3cf43e2d68c79522b62530e423f3ac341333908eea556442afd4a7035384916fe5ea257e3af6655cd75ed06f3498afbed542b0ad0491373609b66dc14b70fb96868a8962a2d7ee4d16ceebdbf334a8758b9721bc879a8ff8bf9f2fbcc6f63a9718a35d8b5df1d6a38bf1c6123b43566a079d88b94f3870ea1b9ad8d94d2db14bf12db3ba58dee361949713c756937de91dffcef9fabe2f9714589d51e3a72c7c896ce9b1fde893f5ea895975986ed8766eb7c7598bf7371fdab658e7bad069a9b52f9e9761ae014c4c15c25b1f98e3e0dc1d831cbaddb6f4d3a993f2257d61f345b3cec990f79d3edeb2f5ea94016bc4c4448c8f9815e81b7433017a719d074003d7307e3d627653f5cae3753642527b0a49b76bae643e4f0cb4fe00bc7b71202d6b1ed7329f6ec4ae64ae463ba7cae1375d3ae4b36741ed88e3dbfc48efbabebde8c1eedd487fb8a9f42b66808936bb6692353b37642efd113c62f14a711f42aa00a0947ef974dbf1c9455e3c1ef175af9cbd8bb729f5a7069685775d8ba8fc3552e37e8765680a58eed27db682227eb6f9f12e9378bed42d4292a77ca86c2eb79f2d289b557e5be66535a2f7bef852cfa2dea5d97c52fee7124916123d91d6d6911564a5c2be40110b99de71e9d9a6203de69a6f7b57e54fa4af76b82daad4021a3fdf1ed0cb5f2118646dbd38f2ff5c7a107967eff06986db9e2bb8996f3dd20b7905cb8f091bfa1f9ab52307226009181925c4cf729b64c39add884cc606b5cd0ffd92167e5871ca3b85b0eda19eecd1f3876fb98ea4b0ba1df9cb8b5e5a87dc74399170e34ec1a2b29df609aa1f86f24fac697de3bdd5eec694516c5c59c6160a30d90211319e50ed9384a8c8e316331b2a64f65a2f2f72b3793163870b4fbec75e81af7d4353aed284c926575a821938c34a619bc75358126deef5ca9fe7b0a5e69b6a7c19935505c73df8f2c06ceb3c09fabd79df5e67c5f209579df95d20ad0491ca79df3ae257b8ac3e95aa302f84de6fc847c8cb147bbef136f355a240aebf1d19e1db26bab8ad4c6cc6d6e27c92d0cc8420e0f9e9cd2bab9e9ef2196e07f04997abc6c1054e015c72da67366699fc045c21974f9d6433740a3abc30b8fea46456ddc7c3adf8ff00b85cfd8e8b6ea2ead437ba951d6d5c6c73322d29be2a35e63081d752933b7938c212b1289d2775222261d18633dad1e73e5f323ff2e0ecf36784f52179e6bdc31c5c19616886a139ad0c632e47d0d32d1ba2ac6c0807fae7bd766ec53b94fab2d2ff22a93483fbb6445e72d409a398840f476eb72f1a0ae8143b70fd04676db9411782f83dee540fbe6aa82664c779605bf155030785e13d8f0bbf86951c62ecaa7e25881f491ef1ffec48fc67ecfe2b9247df77673fee6cb0f66f64fb982379d6deb13a79a3f893488596938b1bd7369f9b99832c4c3c23b04cd34cec0dc5236c4105ede9dcad1943c5813cd18525daa70fcbacda879ad6675aa6bdd5174f0b9e9b6c53e67f7771408aabf9fefe79e92c5e8a6638ae8f1e38b621647d0d51aad753ad3b5a5dffd869f18bcb9a8f73c76b452f45c2f8ef6bbc39c9a479bd1c66bb74f6e3f555db06f55a1566364ace5a637cabb4b6b5f422305086e8542d0ebfcdfff1d1e7ac9d2deab374165267cd49df53bcfaecc76a6139337e9fd029079ca503816826e13fb54ca2dd757e147bf8cb7d793ab299cb920dfd306ab4654bb7661cd83814994236d8b50cd984ccb5d210aa54dc73415c96b92d6079d19ad0da60496d2b64f3d687b8cb154565602ec004b311f96d330f172d255bc6f0c550afe9acd9927abfc7bf67c37ca527edf3f61625f6dd9d32ffe64cd0b10cc433411bc558b67cf11bc09f8f4d7f44bcdf6395fde7ea9f70c80cd66aed764d8dd0ce88679b5caed8fc9c2ee8e32d2ef5a8ed9efd1e418feb40aacf7f19f16c9a1b35357f8bf8049ea7fb91c7ba47d670ec211f547ddfac75bc552f487263f859af5dea16f91baf2104b6dac8af88eefba672312ee7fb9f96886ca51ead0fda9213f8aafb5bc4a7840f65a01cc004a510ee5ad1dcfb0fb650b747acbfff26a26f568544c0d24186f8ee4b169615fdec32de53b6d3f2813ba5b7076edaff3224797d524bba359d90f417140cb222acc5ea65d83c0e7bab279f4bd8b9f44e0e7c907865bb83d3ededf3f539ee85c3420f10ebfb0725fd91f3cd2f3cb28d9ea9911fe136e6acee0bb05a7f18bcd4b5caa9784b19f63dc0c47623730f54eb3f52b2610e9cac31bf560d29def6b778e3a6512fec915eff7cb1c18981292bc892893d581a311046dd9c132b6eb9fe354075e0caece17f573454c035ec85e973988dedccbb7041ce2801733da9f782c8d85491ddce93a943b1b647b41d02902ccebdc3c82b7901adb91cbad9d18b7915866a1d9098e1c43de52e70477048d02ab565547ad68c33c7138d30fb165f1e5e76a837bd74a4af58fbcf4e34203d0a1b56be539f2ddeb3706d3f25e663ed919a97ff8abe62a76be6bc6fa6e61aaf2c8ec01768c7eadc9bee7ceae30c31dcba975d6b558ea932e22a71a5c728d2dce05067b1d4a27dcfe0438fefcca5cb4a95efe83e63a7dc247570449dbed353e7efbad6ad8c981a2b47de139ff5bab370c969e154b9e4f07f813a9310a9c021f52b22829622dba52fc47814892fca57ded9158663b293356decac92b391c56d7ab26702767e30b9726aa51bb16b79ead28fb4e00b815b66ed75006e443a9e41bb5ead6975bd3f8326cbb4de758e7907ef62dfdbaddcb7b1fd85b3785ab27cc0128d4a8f0306ce3c92cfe0f708ffdb335bf69c55348e88597f711e5d35efb6e05bfb9d266f107bf8497e8ef403b791e1c3f23d6f83f7c7f2c7bdc63776dd4f3ab24178e30daebb616cec37cecfc9756e2809a6d131c648f88c6eaae019a9c3579c6287d7681f8b5a24bedd607ed629eae12f9e2bdf55ca28a01ebfa2b20cf30460621e22b49241d178f5884481f3cb5e062f2b5a1f90e4a66da24bcd9328d9501e5f7369ef94ab5cc9c42494d60edc51fa6d5ff843a8fd5d5ff89743ad44ca92594df4fd090a213696a51aa7c3845fb4d89b7c8ce12a9e57ea61d3651b8868e7d8af070f78ec48dfba75613df791126e81aefbbeed1911f5ee74eca37da5f0c478e8d9d4c6433984cb8ffef678888c982b7fdbd36c736ccbc9c74f65d3b6659d3f23ea63f6614974a4d62507951089c22d885256b29d96a7f196cdde15515ef5b95bed572ef4bd1b712467c7bd67f96b1674378d8f87a07fe35443630157d419d038c7fbb0486d5ff6dc908db1319271d24b7d8ec8b0cd7fa16d812828368871866b96fbd5fbc63f5db2e85991c937e1e7fe1dd93972d9013b5e56e69661f40026461bc9fde8a9a46f19da2be783f9f07695579e22609fe4b6252ef1ddbc0bbbbf687d9e316570db32c1563487f09b5e0ef117862d5301762222e99860629271f05b8d38d06658ead0e686113b9aa67ba89cb26bdd3e8fa4d64244cb955fef548f69f9c5059c0de748799e245be3b9cac822e2927319db667124ee46639bc3b462dbd6ba6f375e94842e4e5dfde5d409975afdb02d03b52c27f33f98f745c0d9ca2d2d3405f2babb8231fb446e87f1f97b776e3e7a862db3fc7a05512b633f75ab70bd7244aefa306fe9c5975202ef0d360dc8b725b06b961c6257d02b4d1c8867d3a1817257a7c80adf3e15ac7108cfcca555bde972db3b1bcf38bb19b35839f0fad1166f936c23877501f220ff81b93c06ad91f798214b63bbfc9e9cb6af0f41548c3772da35590ca55d22b6decc5d1d7b3149fb5e71e09a40fcd997da77eed62a8d84d9aee853c68fcbdd79b210ce34a9ac25093a57572d557d47cfeeac5beaf9eaa9e0bc29c3065f59c6190a303903918dd88b9b4c7624db2ee1b48de9cd4d0ca875095650d5c8b5d903717d33bc5b1635e52a1d989c72e3d397e29367db456ffe6afa124496a6f331d5243f40dd192b1a2e230badcf97acb3130f5e2af588fda4bac803875788d425867687a67dfbbb7da5fefd9443c7b565b79d3dd9e669e76d59a797b3ed7a1e3a580b98da60adba5c7c71d0acfd5bde9ab5ccb69fefbf6915976653797ef913ed65260a5c6286eb11e962d9358e3bfa3c8fef1526293c72e4bbba4522a7e07a5f6da6012775d5b1d487283eb5ff89e5b024e4b918e98ca203a0eac6bb26a5be64bb478ba936f1b410c298db9260f6969ef4023125bdbc7db8b725cf7e4b69e0c0bb1733f3a4ce5f6b2eb374713fbfd4f488c5d1be324c038689a943154e1568a3dca5823234ce6c5c26ed2da769d0b1a78bdb4fa9a71d59a2af1241315f462ec378dd24472efc8d17937fe3e4bf89a2987f3201db5ebf41726d27cf6c26b167556dfbbd0c00589c8fc1827fab8ddf45f95f76efec6f8d3ffcb2bc9754f9ebf26c935f967f74e5fe0d7f18c35eb6fe9b112b9767b418c56d9ef750f7725ad45de079a5d42b2569d5857cbdba2f426619e57273da74b5cf5af951e76b3dfc6843519c8e6ed6dc7b8290fdb0b1f7efeae73a579a7cb26abf03c7e7e8bdce598e578a5a6f1dd57f77ec99edba37793aef1fee973cb8ae75cee284055e15d62e19178d3707522ae7e3ee9ae5d00e9d4d82d21e79578288e3068737f317a7c865c4ce6f38eedfa4502deb116b7735b897b77f8d41b7cdb7fd07973e715eb9995a40986da462fa51b9e682506f2559526a6bffbe8b6f6ebcbe97568679806162eeb1602d386302d65aadbb374419f9dd1e08dcad0467c5f3e96934cdf94fc11a04ff3158473a8a7e3db77f79c292f017ed42a28ab2ff7d58f7ae65fcba3cb1ee97e5ef3feafe1ad6a4dfcd1061fa5d171d2f21debb4a99b5ec48d57adee17b492faac44efb1bed06b538a30302078e9e17bbb15b25d3ba8a4e9255b1ebb3905ab17ccebefd6591d9feea87e3660fe17e57bf9f60cf0992dab3aacb619b0902162a967eaa4709aa8b0c65aef4bbb2a56fe2695b51f950ea8b5544e6fc4d5d81b96fdccbd55df29cbae1ac667efbf62b51c39c6b2ac9c839cf8f85c7869fe8162a5f6a3925e16cea1e6cba00bffb4863d8c73c355ead66692428b3a88f939c136818237f256159881265b37aadff156ec96f73aaa3b7f8783f2bed00065a914715bb57d12b5f65a5ddda5ea31c67d9b9e6d2aab2c0a425ba857c471fd552097a343a660972b6d4cefe7e3671d5d34d5da54312451d414f00d3944635dad335e7f56b00b30ab4c3751ac81adfd8c33e950db63ff44c85b901983717a35575561570ef166c747d3abfb8a112440aeed6cc8f575a3d285f3a6c1c163bf745b4d79172d13da49263bb2415b00f520d118b3767240e1dd82f7666b352989c7a6fc8e7dde6c5ee6bcfd79e9ea9bf4ba342865886f90c30317d88903d4fc501a706f9b7070c15ef543ed850963cab079ef72e75090761717efdca575316d58589c9fdf9424ac0cf070ef2cc885b83e49f0c1c82e91a1a00b3ac246599bcc4db1ebdbbd70d956efd071652cc5e2d14f79a0f78614f7fb472185af9cabfd138b7705b9f9bf6725e29faa5804f8838a6e5f5ca00385808eb2ab34363ab50b2f2f9f39233eddd4e463d18d6352ada86a61dfeffc4424a22b2986f9791436fd96cc3ed2bdaa399b32dfad71bdd1e36cedf2f6996f6c2b6ebab2bb2ea4bf11b2295f77d0bdd9e91295cdd23ea548e8b8839e7dfec6bb74976a68232ca8be3b478f1bf6ce7868db922b5bad6f87ab1e162b27256ed71560a54aa622cdc91785046ee2dbbb4c8f220a9334b8aa9d6bbf73fe724f69fc8a0bec2236e0d39769befbf3128e88811c39d55dfccdefed9a8fdcdaac78c8df18882b467cff80e2ce569edc0fad9247625883cf6577f16f08d9efc2ce1f8c3976b73e789773f6c32b6d1baeded08ee286e68f046148b66e61ea93da5735c56a5c956b076d067db079b76bce5add735a078b5db7ce3328c04c0c488205ee15f6f3b81b559f9bc83df308fb6b974bce453e894adb0df2061d8b3c3cf62ef9491bf8a095e1fcfaab174aede7b64f4e32c0d84737f9d559b16bb8b3acccf662b81b5a01d5f8da95ea91483152a4c93feb61db3f5d2aa8791009f43820bce2c1076edf0d56a31311c6c40b4bd9bd65764de5cf8e886805e3c6d64d22ef09f9d03fd5df9ffeca41dc983f7d403e190d873607781e2d756177c31b750dea08658fba0dd215e28a501096dfbe83e5b51e068a650ebbca797ea4508fd1a570e3cc5bfa6d46fce6e35580e9581150013bc8004a93d12b222cd5dfffaa8ecc66fa9694daf5e333b4ceb24d584bd67573d34f50c9e3234dc9860d0785084ff75b32920b2539af3f26d5363e70b94bbc71615c564d61d5df3527885b8dae59373333db7ecad439655a79c12b0c39c0f552cbafd6ef742e2e682ea274bcd9a5a7a7de6de1f7a1ec5561a341040e5e75ec0da406ab741f458c3a11bf714f23f730c19ca32d78af3c52b6d79a2600b698e2c0ac8dc7548b658bc4bc3f975bf2ebfdb916e214be74fcdd8c60737bbd2e5bf68de1e444c28562b70515cc9bbce2cbf911b7ac2aa18a20b1dbbe556bb8e6788921c34285766b410601ae9221fe28ffb48169cac5e277cef909925dbec8f8e3b6fa884553a865f085fd7f9992b75ca1674672eea28d37f8f61ea77b3a6f29e4f9aca9bfde138995ca6cf80c89089830e59940400420408207f23e221137b32640242260e64084b718070600caca5ff4b6d531cfee25b1408cba09000202d9d4102b86a5c887832c4c67a923dfe048f2701c05512009492009007c2494338191722090085277d675b400280c724006c1c7b08f19000a003ad85d7cc85e8c9fee92540028001d6834cd63b2f27dee7d7752142c002069e81fe1fe2860086130306011e065bc4f04ffe8931f014940a25a138517e4a83911463d07efe36469ce18cfff95b627ff23866db0bce7d8e62ae2233cdefc8d7e57ca04b5ac564291e7e72f2d5198990002fc20bc8c41eb5413a9671188f6749213c2acecf2ba4fefc319604601c0990897d0cd7954dc8afcd07b1812400b3824102f84c5c88a3ad7f2392008c2f04d06824006b3ba662328481002ad589046036a326e023b91033f0780ac3194f860032fde7ccfc8986507431589f108063550b8ed6f527cafb331dc4347f703821dd7263afffe522bfaffa29477768e4bdf7bc9a2da6fac9cde693d2e97734c8c49e0460e7b1582e1c97f13009c0ae181531604c4454eb2400eb43633d0e8570d224802f4a7cb40c3ffa4102b0092c0a367f1605bff608c59fb148fb5333615b0924007b974a02d88227908c7d4602d8ee4dfc66f3fa2b1060332190003675daf775b319fea16e4fd6a7fd1fc948dff144fc4e7ab6bb103b04d0febabd4900db65b4c14f130db22f1eb701ab893e888304b0759000f69b3f23421542fe5b3c3831f0e90c96939100763b12c05e3f5637034f2601ec3e7408004900fbfbb1c782a22480fd2a810a0120854186408a1348a63a93d3f1780864601910e000e12000ad9b918efe8777a64220489d1ae9886a2100c2388d7a3c0960ef82b8480087f908c6f4c54799639592a96427061e4b0238b80910c0c093008e252e440a04d2d0e72480439605f7db2e448a134590047068114800872609e0e770211227387062e089a36aa0400038a1148afde8d7185bcbcd61bfeec71d205388cd015286806f5323571c274725a6b231f01048152393008e06021443154bc713211c559082caf70665bc93047024bb1089e3dca1b17b54867196211c244f03d9c67f53a9d20c7c46faa862b9681812c0e91433fc9b7f5412c0298a828d138aa38d7cdf81274bd2c5b6e3c9716274f10c3c1ebf3d63d45c14c6248ec6e1c479820470e69100ce6c3a09e0dcc8aa8ccafadc881af00f6f9000ce9b6843c9acaf2f49006723cac31917229dee440238155d885467fc68830c16d10009e0ec44bf71b153e8681be5a3be49a450509872cd2590002e0508402bea71214220054451c1c53b12e22079aa104a168d922da790008e5e566df6685dec2e440a08e1625915c1040a038f166d22015ca1b123c534904a02b878d0bac6704ba5ca4ce89a0470654380241de2c290002e8a0b51924c134bc74f2ebf88864fae5417623a9e0a613054f1b1b74900d7232a09e0707021fa8e9984c262b60f65f60309e058ed4244c986d19e88e302fa0a371f951a4b02b8b44660c0c043f2342108a48890006e730204d0454900f77c02351eb46749c3bd281695a0d08518e78c2701dcc7509548d2c54800b753dc883620804865e9927b2b819e08da539d21900aa6e3215c2c98898770230ae526b810e3682cb2032c3212c0bd07924f14a38e484773c6132110c22460c004d486a8ba581a9b929b084d72130a04ca8c43874c4dc7d31868d5b1a86a784c09e4383696967824092480478204709f7621a2e562e8433502998a49c713c9140cca35cfc25812c0dde242cc444560a2ffcf1c43349504f0b813209674bcf35d881412c013381a6258bf47d4ca134b8030ac2f0cb4c1eb28c6d2f1a334d0309dc54b2e5a9433ca0b0dc2f0a4e3e92ce0f154a025e5a325a36fe1211c4d100617d004c5205bba20c44b171413172501bc00814ae561e06923020ea2af32475f1d799304f00ad0e974082401dcefd09c8481a7d047f4c1ab462001bcaaa3e414547ee2b8f742c354b1496ecb8ba78eb8683acad16a1a09e0d5436b2301bcc9bf0d1ba81bf2ac40dd7b02e5bcd9932b2ca48dfcc8c053a91812c05b4e192ba452d9e82234517112c0db88b2fb684c31635551a90e108e0a8ed51db3ccc14c5bd31017e41fbc0eb72e04b7cecf1b17e51d1e8283bdbcc2bd23220008a0820ea34cf0a942f2a828cf47d8e0d3a592005e14e0ac0ac74327fa8342c142000d7420017ca8ddf92427452b12c01732491abee849d2800c3c996557be2c0209e0db39cafe9843f3e58f4a4a75c04f6a8d04f05d439ba39300befd2ec409b5f1354e6ea86d5243589447b4217e006d68f8bb86a6e452dae32e05ab5b934900ff32085808017d4363832818101c1b43b1e909c2a00d010274a1173264cf5084aa250403570864cf5dd2ca754230103dfa5504c62204b2670ee1f22311185b47207b16b0efbb2002b30104b2e7e3c7c9ad22309b2681ecd94cea361681d92002d9f3c3b757db4460360601066d5c8823958bc0583602d9330c2f714404c6ea10c89e9b6a7c192230d69840f64cc9bd4d1481b16e04b2e78ec6bda62230762381ec992514e6260263778e55b310bfdd5e08064509235f45600c1f81ec695225202902638c0864cfa53b03fd4460cc2a02d9d3b6e5ce561118b38e40f6741fee7c2602637208644f58dbf998088c6918ab91e3db33ac080c3a10c89edc1e79a74560309440f69410e36f168141546aa5d270f46b3981eca965d4e62b02833d04224b8330e806b31d6725dc30e89bce80a59ac6b3ef3e220c26416c643d2c0564c0606c3a0396dee74284d98d47e9b3d0279fbfa3cf87d9e1d1d2b3e90c5846e1bbd2c689daead15223b4b68051fab61f6beb87d9f78c9462b028fdb1c9a598d9e3b56114c6793b3c4abfe087da302e13f4f6e3f44f5c880011c6844f9405a12d5d47cb7a47ca5227ca12c7dee3601b6d67ef0f5262ca27e8cbd219b0ec4e947edd28fded1ff9ea99a0ef4c67c072722e44986b548b982f3fd48f951ba7c74a8ed3378ed063357ea43782b9712c49b0ab26de741c93845b67a48c04733b8dd61182d6eaf65d1d64987beb6869ca0f28c11e807904476a393fd1c2d9313df2288dbe59fd236f6f26e8dbc638e219e3e3f30fba62931aa767131da7bf3d42cfa6f223fd8a09fa65e3f43da3f4841ff8618b9aa08f44b510e94284794347e9e37fa43f3a419f3b660bdecfa82e2008c2929d60b60b0c58ae151d98cb83108e9cce8641873626f60c0a6b0e27239d41618d76a8286dc728ad28ccae432043f282303b3701060132cd890d4373488770603accaee342a482e9e3e303063a7c70604020c8807020992604b38b13a80c2c242f4605d347b299b11109cc6e05f32f43bb0c98dd85121b0bf3db8c6605e339f8f8e0860cb3af1f27a6c55263610131d42b52636363618143a3ef4d74d4c213ef158ebf578b36c25e199bc8d222cc7e2b9d01cb9bbb10ffd830ccde020b4ba0ffefa25261e19d233930cc01c2ec5f589551e1995dac71276b4c0973d8d3d1f16dc25f1f5bc2a26568ef958ea7c01c7e0498c33396e54430c75a172299884a35a61298232696e59074215198a36aea933630472903967f3369ca06adec4e5c1c0b820c3cccf1383e8e256c8c59ba65ef85ebd45b9c07963f6cb9dc5bf5aa14f7fe507a917f63827a45f2fb94c7f13f17c953e915dfb605898971494990897dbce7c82ccc0be991e63917efdc91b93d239d01e308683281b241c3522020deedbd285914e674272c8600b2f162b4af45610299d82f86e42521792a284605d1de168f429b938c56d1e9421481392ba7213e6709035648f85e7cce5bb058214b78ce96044d7a22ccd93c0609145e10401521c35cb204fc9f4da6fcc9d493085114e63222c05cfa09b404984b7bac521435309703fab13c217ef4a77d0295ce82301102514befc8c48f0dde34a73585230273ed274000cc750fad3697d5f9fd360d85b9ead219b0423e3ac81f1f2dfc23f32430b7ea8817716b43002c76da85887e5f4e85b94d584e441b71616e3c75d49df0539e86455d1b82d8c84e3077cad4231a77d97844e3e1188968dc4f7f88683c1cbf8b68dc9d3f8d68308fc488bc3c38587cd3a4f0c0b3800e714cf2701e2b02cc63ce320fcc633de6e063ba8779d68c062cf4d5206a1c2b58a1a319415198a7781a88e72960c08ab693100ff35450e3e2e8d8d1783739ac90619e87637192e7156572501d23d19cd65ca508cceb310d5e799d19b0e2f9c9bcf2fad168b078ede401120442c0df9a34fe7ba81eed1c788759669e6648c0c27cc1d3d0079f3703565a39591f7c1b282c274259e08ba5d16830bff6f4679061be5a02cc77990a8b3f42ebb9054ba8a3fddfdce9cf17c3fc9204989f8f365213bfc8684d73d00fc5b1a71a230d4d9e0dfee3bce1825f2e58fca91cfc17a7a14dfed30c58e9d977b17f9ac2ced0984673331419b072e8a4e6c8287263ff0e72ff06ec7fb144f227da8d4926be6c7bdbb58578cf2e6ce916397a5f3356a4f273b19a1c11c773a3fa4ad92c1a9a810a707f9f811e1e352f2ca048a78f06addf763f141158601f8182c63681d469a8582096012b374df60f81bd743a7d34b611c73ad069824a50681a2c087231e059c17f075482e4e934b78101cf06264b2cb80d8d0212c6a3fd4cecdf0a6e2c13084d477e212e063c3b631243acd92072dcdf442a049063ffa185c13f513cfd2fae0bd251d40b0dff01f5b0b0309d4e87256c5d4651070be3583de9cf5b81858d5963db3feb358533a76102e16d0c78f6d02413fc85303e937d3a0d7e65c02a6b278370a610048ca2706cb9179ea9349af0fe4b167be1990d7f34eaccd72362d98ee5a5d3d4aa08711a5a157160c02a5f276b55c4970a01937c9bfef77d5ba47b3a1cb53260d5d41f7c3bf6effaf60840b0a3b69c667c9e9a838a227fb4a5e8191a048c7be898468560d1e1696844b49f01ab0e4eb69118272ce138320e17b39a464d62260c58cde7fb81a8181c1b0b01202ce1c548678c0c9c59393f048064d48058586c2b0102c819f80c3c1e16cb4353733a0482548a13451016db4980c576c06a71dfafd4b2888919f80cc6d84ae0ff2fbb5c60f158880b96941df99ec6b203031f43d67cbd88ad71f33b47cb19b3676bfb3cbce51367988f5f7b2b6496ebbda4ecdbbe14141fe295dfe3239b9c8e1fc94047f37b0995bfb959019650a48d4cdf482e18c9d7258c200e58427f64c8873e449f59a1bd375f94cb77b9312cb106e282f9f527d6ed59ebf35858228ab5a6064b8ab39ed2d1a70c3c914c15148525eea2c37e89dd341a2cc99acea0c31247e269b064034a0b3a0989c212a504723a1e96b8c15adb8525ae8d4768221e968865cd7508914561897e029e064bf4c641602c2cf176746a60bc2611a2282c294480402a2cc9355a880e23596c51d06f63cb32209ae57f17b947e4935c3c6a2d322cb9928e625eb2df8528280a4b16fc9fef94a0d22560c98a7406acd6ea42a4d2c560c99a51354c8c31c9340870a08ed481aabb9b024b2d4547ee1314233b296029be118b482d9ed847014bc98d6a85e59852f309b0d4bc1f1c73d2168a1fb74ffcb078070144d6d85f2a8e40a682f6143ae830b29a0c4b05a0a5743ae83096efb2e6cb68e0c422252c554885a556ba1061a9524a2c2c4570216ec7c3523728b1102e0e84a5fcd0927b14582ac38548ff6eeaf5bb053e58aa9f4287a50e7fa7a96f631f3f758a492ba5b0f4022a2ccd35be38084b9b516069551722450496b61d5d3d632941978187a5210a2c6d38b1be47197f6b130596f619798bfec35b3b29b074e8c45b64c884168b151685a54f1360e962586ac885c862a52a961a07c2d2f62ce0423858fafec883f811238f454b8aa8e878bbef29b074d31f572361193ed662242cfd7aac5558467a84c33f52ea8d50ca084fe60f80207a1ccaa18c330196711ae750c6338e1a3fc2e176168732ebc61fa02c9bc032b1230fc659c667fc61751a96c9a5c032693f725239cac9be094e201c95ce62a38900cb3c9d60e30d9d1a3bd1c8d8f4b3cc109565bab18664675060993e96516425ff6814590d0a2ccb3e49e86fdf7fd020793a280ccbba106059675856cb8548a4ea32f093f771c0b2110458361c96d543d9c2d1c0743c0d02a9181a8896a51160d9545876910b71a29f238f28971c97804a255b4c80654f8d4b255b99404d0461591917e20e967265efb11ea0cacd642957b665e441fc88faa13850f73b7ee4b004580e034b635d8844584e60a43a13d43419787cc60e7cc60ec6f6eff42aa74380e5168c7320b77444aff693f40acb398d38c41fcc251732622e39eb9f005b2e9900cb6d9ba877cf1f802d776cfcc104b0ffce6e2b58eeebf79bad607901022c3f03963b3bbed36adadb5460793b2acb67d2f1b0bc1b8df575d21601583e9c00cb87c1f2a213cbf6accd0ccb03e1083f1bffe075863838282432781dce7ba3a7b7b757042e88b5992106dec82259190207ff9c11dcd8960758be01d2a0b16223cac4732a2cbf114d0ffe74bb038cc35260f9ea499b1dfe10b2a9149a3e3a7e6005665613383d5a2c8ce361455f9c192d960ee3a45d88306e256d34f432262d5e212ce3e302d1c61259c687719b50ec278cfe88834c68603c2b9ec0b8ed104403e3583f5006c92c068f50e871304e1d65316b271e3fbea2301e4c71d72930ee34cb6f71f726fbad3ddaf42b0a8cbbf46388c00d1360dcd038e414f85950c6354c82f20fd6f10f5e0f07fa7be1c2bdd7458607e3d68f5a2730f2977f363ac93a0ae190f2b87514b6506105b15f5b47219b022b784fb20eac707a1c630ae513181bdd1d022b3c24c00a0f7ec49821cecbdb33dc1b8ef0f6c2c18181211be0604f6f1cc93b3064c38814ac4d34539342d1009a352e85a219155668fab5148abe145851635c8a1ff4ba213c24d817b72e24c03b78d4b126daca81a427da3a498515837fb97d0756aca7c08a59136dd96d08864981de86b860ef0db8900dc1dee138ff8849bb8646a41fdd3b3415e995f4a0d9e31c29995261c527bf965ec99b022ba9fd417a431c1c1a1a1eb2de1be7131e12f4dd2ea6118e7ecdcff71cdd98842aa57a2aac14f81b8e3e5360a50b7fcad10fbbaa4638fa353fdf71a4ec06298e73a4ec4d8595867ecd9172220556b6f98123ffe088481f1f7f4f7fefe07513b0fd1e21cad721d989b6ee516165c6af11a2fc89022b97fdd0d6ba703838c2c73bfc07838c22e437069924fdac5593fc6396271556fefa6be967c553e059d67fced11f0d32c2d16f00f21d476f20a5098e3e51e159a9bfe668b624059ed5fce71cfda19f228d45c251f3fc9ea3d9d193bc68763c159e8dfb0d47c728f0ec909ff8b5271c1838e2d4c121eb587a6279f92484cc7e0de126daeaa3c2b38b7f8d1015710a3cfbe90fd24f61cb21ace204c98fb7a5b2860aabc8fda62d1a0556b1f8a12d12dac1fc101ac2bd23467d1198b22faab4430a131cbda7c22a49bfd6b4aa28055679fc738efe6877d4e2231c797a4f9923d58d93a2832a8d0aabcafc86a33c0aac1af0078e1c83e1d008bf10b45bf642adaf3939319b68ab15129b68eb1d15562dfcb53dd4665260d5477fda567048b0f746ff88756840f2f7fabe2d35fca448a446a4c26a52bf692b8602ab994db435bd4d9c5322179e9c9faabd1bcf1dd406c77307589d8700ab73c36a68ea4b45536456e23074c8cb3fd4276295a2300e42f2d627d33db73d2e215cb5582376872c7f78913f55a7ecc1de0bdb63dae58dbc2242023dcd002e6160412588987173ae8e5b27cf4f7aff45cd789beb623d3257a7d987e01bc744a564495bf45e22b622f60c4299f92c7e0176a0831accecffa49c527fab463d9dbd2e79fd368b79a54903090ba6f507d4f92ffd8e10198bcd14acf8bb6b396a37973eeab665fd31772387554c5dc6d1a3cd9ab752acde3d37601a2d8f84c0a57bf5380469a7af9f7b89c86fc9b58b0c192ccd59a7286c622ab7e6a09ebfcfc0f21b9b3e5992c29f71debfffdd611b7a13876d0ce800cb5f8a85c3ecda17e7473a29cbf408a595fcc70edbf8e7fe1e58eac4ce7beca97babdd2d73308addc04600589c8f0531d8ffd2611ba00cb2cbfe17f73d61b4b51de4257e51ae175e5774fc57e509aa949cdf1d8651a12f5e5f107db9d63d717763b87540f7056e97eaaaa13967a8d8769d756bdf3d9a79c6edee968c37a0cb9d3da27b9f6f5d5935bb5c2e7287cef5eaab83fb08363586bfab3f7cf0525012670ea652ccac4c26c6e5f055bb3b4c25ef973b1c3f53da9e2b0e58b27d7c224917afbe5690beb725cbefe09b6371a79c5e2846dcd8c6df41db79ffb169258898da3baa42ebdf0db917bb9a2cd5d077a0dfbba64e0cc3c844b7d8749d9fbf401859b196193df322d703cd96c48f85ae9d4b86b6bd791a95b369e9c0fb28a28b69ef9cf18301664deb608016bf37d71e0c959c557940e6cbb1a57cec4ade78b41244f25579b61edf6a6a6d76d63ca67d97294dbb708de30701fed8f564eb87678ad6442378d2936376699f3a9c382fec4c63ef70680783b006da4dd7f56e78e75ccc9c1758869d0f30b11ac871f35bd1999e87be191938dfd876f0b0ddd015419fd398c7b6a53efa56f77a4ee54ef96f873d9898e632cc130c13f370e4fca7ebe38703dcfdaf9f96f30ffe41ffcf4ecbc162c1bfd5c8df3b2da7c7eacbaf4fcbd1bff1ebd3706c9ffdb2fcd37a95df3958aae660c1e0aefb222e9d22e1bc5ca5ef177a540cd51faeec332c5ed1a85ea4f676ddba35fa37d9573ad7dc32ed345ac00ff770d739c8e4ea7fb4b8bdcf791934f0bb536731361eaffb234b29abd5df955fac2ab7b19c2556cfec5bbde106ffb621e058506ca45b489b4468bbef57be4367ed45d7dc3e15f56691f5a5f26d5767ae38793c31d3c2b4928c34dfe792edf7bf8bdd30e0ec5c34681054a83127ce17283930c7d007ab0e3db6463c664458e262a5afc7a45775d83bab757a2bef29e5fe68a69751abd84d0aff5c58862d0198d8d3c8e6dc35a56a2e72e27d43ecef9bb21796f6e2b4df735679c5ec55727cf075c0559d46c7982043f47bdb0566a489bd0aeb28a433fcae75303addac5c5f5fa06e5ede8cf3800ea11e0331b1ded33a8d1fa3504c6afed92132afd72203576cf6166c8adb6e9555bc252167be5bee7fe0f449a4f7d529f2d5f52fc436ef375ab75144e4e31ed1f6595107d3a2f2b744b57aec588688cdea71e0b0376ad0d0400849cb63edcaeba859e40b8f3e712be8b31f5f593d84e61d6ba79577545569633092dafa1b485b07773c3b9375b1b6559d9577845ea687b5c52a8add5ffef9eaf28550650455dd97f3a2a293b9ddd6d32f228ea722162dad9f940645b784ec5b70b92aa6bee240f74a64a1dda2f925bc1ffbb615fae4a2bc38fd3307da2cdc838481d78d8fcfbcbe92a9738570d113b83958cdd79122eab161d7994b455d089758583c367ad68b8e60da9b3de96e4a292b6bed77776e5ab0203aea2e9735b56de4a493a07ff6a4939f9d76ffaf38e9e4f5420d2d4d0d3fe7757250c93262c9cc5ebb0e19cf83afcf6a9c2fb6555bc15b82cc8a765d1cc57d4c0c4aea945dcea66c3953f5aa6258fd76a7ba0f518dc9ca6fa44bdb8181570865c52b2b719a4707e7cc674dd6d0d04be81c59dbfd5ecff1add6dafe8d36f724a7ecb7a4819de3b70d89fe95db86847a8af42ec6eddcd8eba9a2fffec54cd307a4b3d44a32d27da963f95a5b5dbfd21d5bd45e7da9d9472d7e5ec2bdc6cf4eb5b7bf490d799b84444bf2ae6e911e6a6a150a65cb977bef5505e1d2e6ca5f176e1754d1bcfbaa5db20c0c0298a03f32074e19ea482ef7d66953ace9d20a95d54830da146fabd5b3b6e1907069c9bc5d5396d48b094aa37ea1332dbf98c7b620a0b741aa7afdfd0a7f7cbbfb7d0fcc8037cb907b4e5e153a6a6cccd979e919d648759e5d9ba79a68c3870637e9baab6edcf96b3d9195cbe1abc78fe6c404d1d6cd33ad2c49a6ea362ff1c25dde7cb630fa9c5ec5ae67e339941cc6671a3994a7b4e422f752874c152e1fb354dd7a4422ffa34b2588cc30d4de56539ab1ccd43f4c90a344a9caa65fb238cfef4a71824c5d453bcf85b588f7cb8556a722dc9a3738489ceff802710eac0fb9be769ffe605a20efcaf5378343c7cedf7fa6e45780177eb2e3b367e58ea36def7431f9e7f6de9f41b821db53798693ff55f994f5ed3372fe7ef0f4cecefd0b47184ded50e8778a09af45ab62be7eb469616fdd71fe1b368590cad96452edfce66c5d9155d02b448291cd6598947f50b2e8f40bd2dba3f2dec75f0ead259e6aef693b659bc85e2d5986f10398182fa4467df656d292f543b948c846ae27ecadbd315629214e86e6af2d16087d583b77c99415e4c7c4888d7799a47fe181cd5e87cb35f15bd6ee7549da2c58a7d3fd7a79a397ff12eca73cb677973fec7a3b7f0db24cc3a2648656a80e589692641f722c090857e9ae52b5caacc5462eeb4dfa701375c78069b96368efe226e1c30098574ec2ee513bdbeb3cb72e9065def5073fa4be316e13c3c9ab0b7743cf5b6eecdc2d6c17b0d7f0915982baf909291bc4daeccab7f3f7522d021ecbb7765db43856a27b8fa47162a3e1a0c2a607e75a375d437971fe278e7d4f42b6fb9a78bec6da1b13b92e1eca6a2b709dcbe3a12f351454b72ed0d96c438af23564eb7d8900dd3df5ab0b6fb53d176e219c5eea6061aebcd0202e99c3cb4af1a4b16b19580d30c12bc88288e604bdeb98ddbe0c53c34b47d722c7ceaeb76d5eddb31c6f9cfea1dfb0e9f094a1b69609468e1f74a638f5dbcf4044e75afdfc17caedf39d06dbefcc34715ff1e933fd5c5535ad375641e3c23db1b52b9079e5865c8992c72ed5e50ce95ec67646a5ddae7d548995bcf45c0eebadfc98c4f393a4d0e84f118e3be9faf6ddcf102e52ced3f5764df2fa067eb5a75ea70d050ec4b477fd070ed12ae7a9bfbc5baa90c3345a79cb97e75a6c0fb27dd964aa579df6d8bb82e2f1a6e332a2a0f526a93455c131c93e40f644fe0937578ef50f4c254b1845a09ce02645ede2324c1dc0c4d4200ae6f194bd6da4ab7b376e5978a2f9ce85c08e6df8a84fabbdf44ccf2f9bcd85659fb225039998ad932e5ec44ce568ca1fd3ab85fb7456e70b06cf5a73f2746a90bfc99502d703772797fb24f069e57f4e00927b56fa155c9e9b207d6ca7fcff7a7a554946ba3ccf168928dce79fed5473a262d623e387af7dc959331e241d7fa57241d4d12d1309ad192c22c9ac320895f556313b223fac82975948d4bb676c6da3aa39cbe64b77e94eccc076d6881f8c9d04d729274306af0ac3bbaf34d6b45bfbbf56583f2f7b11ee8d6b258854b4be6e93c2a8a5ad585825b7babe46a46e5f6a99ca7d99e836c32f9a335e7a1d46562721da1b2e447f34dbd8e5989ccc56646af1f90ec5a64cbc546aa5c7eb3e9d323438e9fe33f9fc7611e2666ffd4b5bd602f319cb3b0f54b938575f1d006f495eeef572b0c699462292eeda2dce6baf9223d66df4b1d551106bc052eb5fea751dbeec7974b6a8d4375c19c80d304176c4eee8c74b995eaf8cd87949d9333d9e35f2eb29343d152268390d2f7971cb392568ca900e1e282d3d871938cd3aa5edc5c4296dd41281ccaa334ea52503fd77025cad78760824efcb55996f4d2e35e7f6c83bfdf7ee5b901faa04912b56add25970f83771c7900a3e678dad2762ec782282535b12cf5ca075de6ddb8f2c7c69fa7c26b8cbcd8862eb47ad3db78729b142988bb24266c7ed93359a9a3be78c5c8dc5f886e4add54c8f28ba5fde7c83cc10ebf03a1b156b5a74fc134fb631b7ed9a8d53d644e8c8d5582153396d3d09a940c0b0dcab5c3565267616774379fc12be84bbc794a40fc52ff4632e75333744a264670708cef5dc1b710d7ce32e8898a87eda8a0935ae6f280998c9c7b3cf6e43198727c0e45883449f6a0ba3056cdbc5bdec80b5ca5efdc282aa24fbfd166b0e3ce8ed64323992be4c99ff702687d0c8d5584ad3bf1a4bbd63bd5de5e75abb1ec9b977973614fb952fb6f4ff5de2fb5f8e4953b91a2b09094e91cc2e7838ff3c69d12b45be450bef6725c5455fdff1a5e2ababa8515f4e6323027a3f2c189c3b3baea14b48dafa74bb732678413c94db499023e2d3303975b7c3a4782ff1d72edafddd70f9d509bb66effe0e1b6d46da716ebdec6d94fb73fbffe7e33d88dc5493dc4f69e278efee965e5ab85b7ed329bbaf72314733535f6dfd6492fb4d6a0962dfa4372be41ac7c90277c255c53d350d408ac05320a7a37cf9ed5514c69e24e7c9eb3302d594bb5450eebfbe3e03fcdfaecfb003580cf8df99dec5e8453ff53cffabf27e05c6c35f94ebcbd4a925fcaa7ce3f69d06bf9b7e6513b85560bdd93a49353fb7494a6b1746e831c702c6a1d876e5b79ebcf147b419d7ec367bdc3e367859be6fb82af7f88e142eb9ec7589273adf9e2899afc53b58dcf1bbfa030d1c33d7c6f5a53b1fef3b3d3f4a78759d74dd9138de77b7cbf69bd9b8ef8879be38f49b6ce2f2b673164a12fc396a9f5235e44b186f6f37a8d56749e429bffb86af242309183933cb8a8b579d95e7151f78d86efe5e9ae78d85c8c5855497bbe5f03ead14c45cafa7e3a094a3fac1baccd5c7fa25edec1b3514cfcd5deee4c8b1fac2d20bcc54345f709956bef0b3cb9858f9c2be8470bb752598cb745a97ca9bed6fc181f4e5fbeeb93fbdd61c124d5d3927a41b5987e195589496714d78bd2397dda645ba552be9a488c88d38f5e379490afead1bcb30960013638ed4a79a75dc8aaa5829b541b9981ebf6c16ce3de4f66ccd859a42ca6e09a6ab3a64a6dccbac6382fde3a30acf298c2afed7c6cdc203d073e52fc9c5d1856d2ee485c7300a96aaafcb94d9b59243ea3b691e852b10310db7974d7bb34befaddd3fd79c229e6b2caccf99da7a2685bd2d64cecc1689443449089c5a9270a66ecfb7c5f854bad8fe1747973ed7fe665ceff9f298a3fab0ed5200c833492222726aaf13173ce1cee60c3e7275c9f6e72909bb0a4ef03759f4dc4c9ef3e6957786260a25bd694169454f0bffaefd5b949ff1efdb9c9d78b007a4b8e6b278c9feb0dd25e735247a63f91ea5f543c6516f37bff5bba5e4aa77f6cbeed715aa05414884220e5ed34bd3166b65cf6b1c50bfba982bb167dfeb3aa3eb360749f74e0af18edcd3736cf62646c62ee5d4cf2b7d9f9d3dd69037df85bfe2f53d05db7a24660dfcd09e7bca405a5f598639013031054834cd27d840ed65fbdce1ed29efe35d1d0d56b7a99b15dcb50c5d56e4561b95866640a688dc96eb7d31a6550a671cbf3dded3e16f5d737ffd16d17bfb9f25ee2bb2ebecd61d42abdcc8c41047ee54cc9db8539154b7fa1c3692ca79d0dba495d3337d0e8d0cdbfde14ec5e06a7e0f4697d190b05ca3f991ba47ad75067dbc2bb3de9e2bee7a2cde607d4216d9087f783317df7621578087cbcaf7a3586cf2d5c44f43c71d92e62a3b50931edd1cbfac80f2723c83f6a21e2afd79069db37467a0df6f80ca5f494616dfdede5c6953f16260752e9c45dfb55d2f89246bafba738ea543f91d2b73ec5b8467f683c7cdedbdd9db3747cd122d19d4513821c9ceddbb555066f3f58c82f9dbe78e4cfe87feb393ff06c5a11c65cd7389d5d66a7b8efbbc78710b8a14f8174cfe27222efc7e74bd1c98f3884467b638e3ce7be9aa1bb3bb8fad70b5a9ef2a983b33e50e22d51dea5bd5faad78de90fdc10e47a719853cf88557f248ee811ee73755bdecd319c3abfc5094a9652370b1b3dcf26c9c86f2de70430f8941051d67cea297596215379029e3350ac56bedc01de5e95fdff7bb7cfd2fced426223c5a417509f4dd15e77862ce6f0bb7a19d3da3607cd46367c8b2afd64bcc86eb3088de270a5620ffcc1981270f36e987e55fc8bbaa3ba810b7dc2a391ff6f2341fe41bef1c38a6d039fce93ae47fe5ca7932b2abd8f4e3f2968bd8bdc2724eab07f92f55fb9bd8149dacb64c322a3bc07ee6f900e26ad07265de1b33eea017b73825ece4dd42031b938e852df93420baa433509bc2bae38df0cfdc0ace5d5630fc499bf0799ec0f5708dfefdfb1f2cf55e57ed946c3fe3b2b269eee134552462561897338effa6dd1dac6b67e497b28fcccd356e4edf743bc55e208df3a51ccb40358009ce426abeacf7f6da35436c2567a30562fb44f8c4968ff3961cfaec9fad7ef6cdaaf076dc94f11a3dd058fa1033508f5a5770c2ba34506470aab81568ad891f72af987f39e07dc232832e8bb3477bfff60a43258844c62f4d6abc7041c820aa7ca8eb90fa4afb55a5060d73bcdfa67d01f1d22e895710f0a29dc40185561ba6733bc375f70c77cf3031d0d19cdedd7970e155c62ac7e1328e4b0093a30c79f2cc033b57c2ed6693ca296fa5a153cd3b8779a343797085bea4797d6050d8d929eb6a2b9323a0740366601daa2cb649aee0c09509983d9c117fad99eb46a096920e277bb673a08564bc28fe7353deacf9e44a32725ddba6fb2ae35dc2e2bcdb7ef657ec8f3a398b8a6fe67f6a305ce0ba93c195aa83ac53e4d7319e19b4ff63b8b017f6a60878bc2d7adecd4d34e6a9259564770c1e9cdeb46f74806ffdcf7cb029d5bbb653c2966d9f907d52407ae867cce13cb5ffc0b4ef5a3ac1cb77bd096753e04b524b4ccc815877aafbd61acf79f35e95cc8d18e0a120562619f47ba927b5aec327331478b81047932fcb2ccc17d9cab8ba8349ea7d8746ba3dfde9757bbf9be0f8d7deee71108b7de8ca57bb7585af469878f02da924cbb59cef3d4eee8cae3f24d430d3b5105996bf5de9442155f6e88b9365874f78e428a5ea55dd52b418548dbd1e71ace034f2dd364afdff91abf8feb93bcb7e76151f0788fd6fde59f69babf6def7d5fcb2fc833ef9d7bbb4dc7ebb8d727d3a533d66cbad63f39958639f2417d0698f032757575fcf5cfe85daa0af87d5708874bf6af5fb85079b7702b33c81dc5df197575665c7a8777677e3ee76b697fdaefe2dd9a9fee147bc1fdb575d7ec031d83ab4dcec6ca67db4fb01f3fd29ef2e8671399a9d5b32e38b2e8f884bcaeb9033253afeebe6846d4ffb76ffc5b194d3fbd3a50edfaa242338eb1505f72fc845db87e6ceadd83428bff2c88b6a695fafba9d05ed73f63c73388e2cad5f926960659fcb5917a0dfdafe285fd3ffc2a60fc9ee9a51f5a47cfd4739acf5f1b0ff89f5f144c4fb66d5dc01e5edade5f107dc43afcef9585ddd1961f36ace66a354f7878577536621a6974e35d816ac12d3098e1172ea911c7cb2d0acbea06cc6bae7372ecd3ea854d930b62e40caefaad6ac99d958f5b44d2023bed3e77c9fdf4deca768e323891fbe896337c64fb9ff224f5e176899b42e70f9c49fad0b6caaf165fcbd750180ad928cc80cf9c6e49c28b1e08ebc40e2eeb06d9ba9e4cca315356397a68e0cd675ab6907429891a8bab7f2c693e39ed677452b39795c783dddb08015724f29bba38efd464019d80430c146a48922e81e6cb6c87c83e860ca37bf4a27d3d6fe84fc790ff82b4fcc3159c6afdb39655d509960d27897eaf52fdc2b90adb9fdd0fcab0642f34fbfb8850815f7f21f0d292c3911f7a2e2ddbbc4c3e6f50a888bf63259cd0daf766f363f6a6d2dbe897670556fbacb894afdc646e2a0fc81072bd0b476d5b4d2da19ab92755615a4cec899b3b5fff63e0b8b38efaca52ca8575eccd6f45ba9480adb36c41f6bf964edaefe07ca225b0a45407089369d90ba03c1cb9eb23750ad5ff385d1631e98356740acf123d476fbc5b1c3590ada816ef53565986a8089b982043d894ba3088b75787ceedb967931f623b69caf77c155f8ead2e2fa6f8331b93e343a6629d2c8f398a1608d8d9f4dcf95a05012771cdd9fae4eaca7debeecb9f1fd92ea6721a879e94c4c64e9da01bfa0a94deab464608ded756266dee0caaef6edd735d0e1bdadae6063717be1e6ce050673027510d7fba73bb35d796c1a1fb1edb86bb0cb6837653342eb2f6fdf2390d6ac7ff97c0b1a780ca61778fec2f2cbd436e6a463d85f3ee7f0ac9634b8eee738ef86eac6971a430ca399da2d8e0e3912d9bb1d1005a3c53378b7b5f4377f7d12ca7f29e78a28a088b49e594c8d7b7420b7e52e44fc8b9bd17fba918a8cdc483ebc45c3ed3e59cba0d372e92a8147a106d5ff8fbb2f0f8772fdff9f194b832c85ecbb644b96905d681864295bb652b66c59b33396c328644bb678b2644d945d458821eb945df63142488591e57739ae3aaeeb774e679cbabed7399f3fe6afe79ae79ee7fdbaeff7fd7abddfaf7b1edb92ea14987071ea8c13ae760180e9cf04d615f5e48c0a3067222b9f4ca90b43032ccea3a43229571218527b78ab0ad7f3834958c44220f1fa091f2bb4b48e940f16848f4bf1f8620fdb67b3741620aa54e842cc98ffbf68b83f4edafd8018b26d41a01fbeca16b49b1d7f0f9ea4a1631fc813a937f452dd50577479dbfd963af4b542ed2903e1e09b6c6cf6db192f7866318e11ee628c2cd242cd55a415259f02081a0cee86df389283f93c5a5f0d7e00c281ef0357aa9a7a79247fb3f4411fbfc62da7abc87e72e87ee1b08b4c71f475610ea9462fbc6772180eacbdc77e5d7f6dd127cd3296529da988786d8cddbe6e96355d3d5a8ee83f51f4813d4d3b19e4dfc12c3daeb04eaec59eb8f462c2502e3d54e6c5a171a608394934a0bb22466f94d63d3c21debdc46370ddd1b53c37a0a1d4c88ac67ae3c5333462ea9b8896b97ddd223c4a9d4885c572b455285347e24a610d04b97089c99b533a10e03a873746c87d229afc9f89e81cba0c354191ae561356034037a1c489f0158ee8a745340200483ce9df7d9e8d70a0975883d1896fb55dafd259179b9e164c8c8c2f51862e03015e386fc679e32a7e7a018ff366ba48e262c226cdb6279467259342656d8873aa0950201c411330d299e5c01c1948155071a66004c910529d9849d95a363f9f365a77cc93f1550bdeb1ba8523b8f9070b99dac7423c607fc542b20d1bfa7f928510d58381cd6d53472f92b02cc97b56fdac19132a67fb8802e8275e87c355830b9b97d20d00e7e177b1728d2c27aac86cdee4918c8a0c9cf88dc67c715bfeb9879931f3e680c477c717fb411c5f66fef90bc2be304b87a3f04469d326d457b832f3631ff7c4582b8af6345de9c3802d9629c9fbf69015268922da35314f48e32dee9a5a68054ea9e5c28ed74ee79bbde5ef74b0e5ff6735a8835cffd72eff73e9758e85627e60a38e47e6120068788061eb6bb68de493538bde6225ae163e8047a05aea293e73519d2c860c2d6627484a8cf02bb25cb12ed5f418dd50d466cf2e2fb884dffbf75db4b95ae0561d9b74e57e18817cf2aefefeb238df9796c9d95a22797728ef14008209cc3223e7b33448df67642642ad385643903e51cdfab7c6a2cb863facca2ced922ca95fd1ec89006ab7ce9a57f4083569b3483c1ab8e63c56a71d04e39924b359ba669de2aae82c049c99469b64caf1e6b0adf2ea4d9aea1a4a170482c71539513d172291aba76dc9bf19922ff149130a278dbfbdcae75458de51c4a6203c9bf3ec8edf45736b939449d68b77f05eca917b8664b77f89e0f2dd843f2be5bfe06c37c7e7ce78b96d16c2888ab62d9b599468adaf465cba7611a0b32d6a7d4333c14b61de3f4bae014f78c0fde471ad8e3553db75f1f6ae681fdf6a702508077e0a7c66ab3c6278ab9e694518ed77e62502ab8a3dff86d324c4aef890476a8013cb32de018ac681adbee70ce87ea7096deb8f7346ec5dbeb77c0fb411911e9b44921462d96172c7da939a26af8a97192bc7982b9002fc5c370280c63e54fdb272c686ba0c99f0b62f5557367965c6fc8add35bb39d5efc3921c64d813204862166c896880e1716ca776bcff25f233a41b30bdcec80c8735c3931e35c071770b2abea98240b9a6a5b3b9d3d44ccfe966faf22548b424c2cb4f18762106bf0f4bba7f1bfcbb618bcc54f886de7d585c199b34fde2fdc4c68432457c0b56db58f1406447a3776a01e099106d21338488beb83c04cdc9b09c8531323fd112de6e17218321aba5da73f6fa981730f10d9a5c823e6313ae62759d5802d94e63b567b95eec225b57278582b57b434221cac0430da8a12fb0aaa8d889b1c716f82087d64eb2357f00053e788a0a826b938077718ba9af26a205e1888e00d051651e8139d4e455adcd12d9707ab3a31fc37cb050aa4eec6d18a7fc64e704deb78cc31136ee39b9380eeee4820f59d322636a7dd80eb378cc45b7a8587d2c8bfb97e7727c9c5c1180958e7bf66cb31c2832e6d92cbfeaea369350f6adcad2ce8bd0abf4592b95c061c0e76e3dc1722d98da4d869da7c7ef5629249566f45509ddeb410d21a7873529b0ef12deea3f28e1e7c3328349b0a7d30cb8238094cab4b35fdb481f893ce41145850919e25eeec40146812ad8d5ca693deda352a6aa794b5845a273b70b02edea4a2451fc3b67b00adf7bd4c4fb17b9701c9e5b8d3285fa8ad767f10ba9348773e41f50a73a8c0586d6230048340a639faec54a7a41354b76e3ed8c95c38c1b8d48a94b058dc290d8a5f348e0ba2c751b91b9c5c504e355c932f123d471500f849d183cd167ca4909d3ae706f8faf181f8caffc5971e17fe2805ad70295920b5a9d425263838bf70b46a9222cf7a61b51086dc6b593f6b3cd9c01c0b9eca50f4e2f9008b113cf6a74387448aa3f4ddea17f55e43a1c48434bdf777b6e9743481f8843008b1c9e9a4bfc3c748b5276ab41819fbb1eb64ffcfe5b8815cd1d578f267de0b5e7bdefeb694a003240bdb8f7e2ec08474d90eb95c4866ec08d596bc9d3a8fa7a029d92896c9d7205ec29347fdd9dd9939f81ede3ac2f895b350403c2412600cda3cfdba0415c57a268f97f0b94c3c42852703a600a8e0b1a093ced92e38f4bc73b2f26e020f17fc881e9fd72a0feafe480944ebcee4fca01e27a04c0c860ddfe7051bc7eb0a83d91c8d1adfb9dbff1e711afb420916c1a448168c857801663ebfd6640cdc2103ea137b53c3569c3d8290f49f778c7ee956ae23e9a77631718f70301036f1614747850728b2ccea69d31f7da90f2e649ffdf136172a4653f307ef37c7698048c667d1ab130a2d038e55cac055e5b966c0dafdc02f469b55cf2c4ce0979255defb21f7fcff3fe4d09ad01a8aae6e3c7cb3e8dbe92647b6beec6afd508d7aea6b5f9b5e80c8b8ebfb6a63a9fe19060533bfd9f58736ede03e59943dae5d4f5d2023b3bc4645f3ed569aa070c905a0f16d6c2f3357b01d618cae20eb22a3d78cfcc391345c93bc5341cd657f559adf99220d8b4e3d43e7b87425fe7cfa62fa0c12ca9156b8d0d98dbba63693e6942433225f4b7e23af4d2d9d3f09ee589fb0e851edbb7537d68feb9544df8825c8d58c2ea5d17eda9b7646f1972b912b4cd593d3daea4aa7fdd24171850060ec9717871e4d731a13fccd527f61535e6de66121077b25639db5434df9998eff74d13e47d72e531876f6bd159b2f913930ce6c1d5cd4b37d846a2ac6db891924a157d783f69d29e2630399826f8bbe4ff8f354109f9715213553d6355818a76497b47c63838ea5e780bf7a6acc0c8734c54f23d002a6496d48b75f832a1b166c472c2c331f30282ea665e66607afb910ee913fd65d5e065100ebc00385e3ff17c6653d5cf74b22d92fb26e1dbbbc76e64a8c06adadd027da92ba3ce7ae31da0141c38bdaa6bbd83f3e006a1bfa381ffb862acafb37151882a3a81d95db79a7fddf8dafb23d0f317ae425978529fd75241474e0214c14484665d32d0fec3332dd45c0587f3a1b26fc3535a9e5a3b5f6c77e10dc3ed42ee7c30c8ff0167c50f72494ff10537e788dcc75f4d89233b121ed0849324f42550e4197af1850a4a43f50038abce58ab3fdb97c36ed30123e501299fe6ebf2da57641bbd9b1dcb03099937aa4640eb830076c52e4344d96b9ef96ca6fb43274ce1cc74e33944eb0aa26068f0ac8b0f78136fc0d3d62377370a995f711432027846dafea4b6d8993d0379a682c943a9dee6f4c6a7fc49ced512f9ee8af75ccd148029733fcb51d39b14e82ee9b595c9de3ef74bf22a8e3708300c15fde8cd858d8fd584c6201ca10110620cb2dca07add2e1f089bf05473c54595d984131f2a80c8b71abffaf8b05b10efe74bc71142abc12238b050f0a189507b385a3a048c284ad097a4a0acbd6c12553ce855c37cc8189e5e7aa80a51d5e442079bfc1b18d97f6e1a9cf0ffe1657be0dd8fee6d91e55afe37e353fd0e04efac02fac9a94f4cad36da0659fcb6342bcbeed3324c371202b87a775843f50601db165de5649f4be414dc2f83bb798ffb7c8589bce20c73c435062f7e94af3b1ff42d6693ff86983dfa51675f8f6cfa87dff7b26608c02b66a237a8a21763730fbff1e4a07edfbdb3c16b9dea0a3fe7ce503094af258745da0090e5de0f61f54a56ada14cc96aaf06ecd59d079f9e66582c6e49ba37a8da1f4ef12d6653ff869845fc44cc88f9d93aedf088d92de0b4d2cc1d27ff88cc42bb64abecb0e8471e8f6a47f3087afafb7b1727ad32cd8d01f2d3495b1990cd378b4c02a26cbe16616acf95b86256a52763c96322ac75dce7aaecd66d39f02b77a22c6d0d3e838dbcb70dd36a1ea7c913a4385c6e34cb4737151de14bbcdb3bce02088ff0760d8b2d7bc35081bf853b16d7570ed2081ec58683bfa87d40bdd09775ac06278270e0388081bbbf3f5ee87295478fb88524da5eacd4e77e0955ef619a90d202c8d5c2bc28bc930b8003abfc210f30fbe4c1a3eebf92078a2f29197e4e1e10c8d58381a3626e23fdf14f1b261402da750767331a1ca2065f691dc73c5f3575ce545d4b02fc4ba7e706f5dc8695dcdedd0e7abff205414f5e1d298c72af3c26d2d1969fa2b29bf54d7f4dd6b7dbda2229b430599e9b12324445e545da2077348bdb569c4607e60760845acf00a7c6f1ecac116edeb5e2c910dfd4fb7e1b8ae9141a3b40d9329ad3cace2dbea01a920ec24152006e228e37d26766c7b91b5649635d7bc8a4d0f3062b264ca03b75cf08bb86efa3f106261307d1acfa0a595fc7f3ef89c2da7a6450cb7f527b29c7b632ddf7a0f71098e4f017687ee03607e585fc1f38125d241db744eeba6ee4396707dae590296a84d2d05b8e7ff22b1c4b22ce0eb39e05a4128e1bfa7e323d9673a572baa660bdfdf69965cbd8da159c981cff9df93922fa3dc1e5f26b05d711544c4b22cdc9e5b98756aa8c6a6b0dbea16941ff09c18584d2c4c66c57d20adc2aa917bcf4785bef50de2663c5cd2b0647e62bec3e138b02a61770236d5dce412e8564e853a3913df3dd102343bb1ad2b759d85287906d996a88300807110444eb4a9315a2e73e37f1075bf0713812703ebd328188437629b950da747e09c59f6767e3c0a37b18711e0c23cfd703fd3e335d12ddf7270e45d06b680a299e92fe1f28444500c69e4ed69878761ca577100512bed36e3630e59ddcab5eb53c245d2ef59cf82a20b3186f7a51aa8035f9f5b2b5a6522f6b475627ef73a9741706e15e969b719a6cdf7d215c07f285fcd9a4af070329c746938d422f67de7022d37f8498459f4f149ef50f71f92097c6547526895b1670999a96e9e36fe315d1379379894db6569ead7eb460763b52fa6d992fc2ef02e65b1bdf656c504bf6b4088f1ccb3c0a162b2bb465cc390cdd316fb821ee21b34c0fa1c27bca3cdcd7c667d85f51c5bf8dff0f26073e5ef870c7e0ba37b9a74ec9bd93e047493b472a050130456e64d4c360e34b77e55d8d000d4a61ddbe8b3af09a00356dea2f26d1e68a3c5fa508c68aeee4a189178edaebffbf000000ffff1ed9a0d101","nonce":"0x128cd","to":"0x8453100000000000000000000000000000000000","transactionIndex":"0x3b","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x41535904d7b20be8d733e03d95ec725d0c6ee4307d899cd00e0ca0de91533b13","s":"0x3f98c81207d078199bf74a600a77cfa389574646d63ff55ccfd194491faf7226","yParity":"0x0"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0xd3343d473f624c02045a01f4e7ab604bc56c4f42","gas":"0x156c0","gasPrice":"0x7d9f6fbd8","maxFeePerGas":"0xf49895cde","maxPriorityFeePerGas":"0xcfd6ae0","hash":"0x00b5b05c6d1a2eb8abe2c383da600516515e383fc8a29953bb6e6d167e9705b2","input":"0x9aaab64814636b3e36ce9c4227a5fb53273a04c3fdc94c8a00a4d6d5b6521571b94ec7ac00000000000000000000000000000000000000000000000000000000000028a416eb20a9e75d33ef7eeb4a0bad7413cea6c0b3a7f6ea249a93a428c0c36b52240000000000000000000000000000000000000000000000000000000000840244","nonce":"0x6c7","to":"0x1a8b038f5dff48f541e8cc658b9e186b9828a726","transactionIndex":"0x3c","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x1","r":"0xfcd40d6ec6fa94f40f866c18457c22ebf5d8e3aaf2616c4c1cee5245ce8f042c","s":"0x45e5962efdda48e38f706cf8fb7c2f722d80da6e0a1d2589b6627627b44feb82","yParity":"0x1"},{"blockHash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","blockNumber":"0x840249","from":"0x9aba7eeb134fa94dfe735205dda6ac6447d76f9b","gas":"0x3e64f","gasPrice":"0x7d9f6fbd8","maxFeePerGas":"0xf49895cde","maxPriorityFeePerGas":"0xcfd6ae0","hash":"0x6fc411f24c7b4b8d821b45de32b9edc5ac998d1ac748a98abe8e983c6f39fc19","input":"0x2e260ac30000000000000000000000000000000000000000000000000000000000000200a5c46e2dd70854a0fe8167b705eb7df71cc927469c345248c81b21a5ab2f5f19000000000000000000000000000000000000000000000000000000000000051d000000000000000000000000000000000000000000000000000000000000051e000000000000000000000000000000000000000000000000000000000084024700000000000000000000000000000000000000000000000000000001b3fd9f800000000000000000000000007ebc0d2451003f2d3bc5f6eafbb7e6bad81e250d0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000640fdea40000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002e43c000000000000000000000000000000000000000000000000000000000002e7d600000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000f6cb686532a3ece4a20f823e59cc386e1ba384d8504e902c932fa1497c4afdfb0b000000000008008402470000051e00000000000000082ffe82e7b18f0778493c989ecae1740325207ea29328999d5ae646723a4bb75a1305c8ca593670972f535ff8afda050351549ed800e9b98c805788acfe20e6ac076ae024efa64ac3ceb8f0a3cc9ce93d122f6faf8376c854da95567fb7576f762299ca2135608c7ac5a824257b50043526903fc8e01ad88006448a69a4afda4c01ad8a6ed1260582538f2311e902c1e7d5853a75b74482117f2cf920897c1b9428eaeb7e74a95d3d32db03931d157a48aaca9748bfebfecffc2d140caddc66b300000000000000000000","nonce":"0x108af","to":"0x7ebc0d2451003f2d3bc5f6eafbb7e6bad81e250d","transactionIndex":"0x3d","value":"0x0","type":"0x2","accessList":[],"chainId":"0x5","v":"0x0","r":"0x1b284cf86146fa2094c7c709cf9fcb8a177f4fde1d1c5ca112e41f82a5e973d2","s":"0x5618261c40d23e5beb7ac0bac77b16ead56e547f103f649462387c5acdf18ba5","yParity":"0x0"}],"transactionsRoot":"0x1ad3212eca045505cfc4cacf675b5fa2e7dc7b9f9cee88191464f97d1c9fbca4","uncles":[]} diff --git a/op-service/sources/testdata/data/blocks/pre-shanghai-success_metadata.json b/op-service/sources/testdata/data/blocks/pre-shanghai-success_metadata.json new file mode 100644 index 0000000000000..87c9db722e782 --- /dev/null +++ b/op-service/sources/testdata/data/blocks/pre-shanghai-success_metadata.json @@ -0,0 +1 @@ +{"name":"pre-shanghai-success"} diff --git a/op-service/sources/testdata/data/headers/post-shanghai-bad-receipts_data.json b/op-service/sources/testdata/data/headers/post-shanghai-bad-receipts_data.json new file mode 100644 index 0000000000000..1318d2ab45a3e --- /dev/null +++ b/op-service/sources/testdata/data/headers/post-shanghai-bad-receipts_data.json @@ -0,0 +1 @@ +{"baseFeePerGas":"0x3fb7c357","difficulty":"0x0","extraData":"0x","gasLimit":"0x1c9c380","gasUsed":"0x18f759","hash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","logsBloom":"0x020010404000001a0000021000000080001100410000100001000010040200980220400000008806200200000100000000000000000000008000000400042000000050000040000112080808800002044000040004042008800480002000000000000002020020000042002400000820000080040000000010200010020010100101212050000008000000008000001010200c80000112010000438040020400000000202400000000002002a0210402000622010000000001700144000040000000002204000000c000410105024010000808000000002004002000000261000000822200200800881000000012500400400000000000000040010000800000","miner":"0x000095e79eac4d76aab57cb2c1f091d553b36ca0","mixHash":"0x5b53dc49cbab268ef9950b1d81b5e36a1b2f1b97aee1b7ff6e4db0e06c29a8b0","nonce":"0x0000000000000000","number":"0x84161e","parentHash":"0x72d92c1498e05952988d4e79a695928a6bcbd37239f8a1734051263b4d3504b8","receiptsRoot":"0xaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa","sha3Uncles":"0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347","size":"0x2a51","stateRoot":"0xc56738518b2c7854a640ae25996d2211c9ef0dd2e4dd9e59e9d9cacef39622da","timestamp":"0x64110a5c","totalDifficulty":"0xa4a470","transactions":["0x1e8f148a9aea7d8d16ea6e9446723b8f262e8bcd89c7c961d52046ebd43b4598","0xab5c870f4c367012bd763172afbfbe68fbf35336a66ae41aff3f2c9dbf4ea3f8","0xa81fd92b2d0f0bbd3cc355f869cca3243c98c5e2641db9ecf3eeabb3b13bff6a","0xa92c7b720c08c83f1a0ed7e4c163200e30a3a8c03fcc5a51e685ea20cd0cb577","0x6921b429ad2ec1e97d3457049ad2e893b5a0349beba47ca1c74a9540af75347a","0xf776b2da0b835dde05d0d8b76fd19385d61e7055036cf637f804b36dc94f2384","0x9a08d899cd14ebb930ed59fa774afdb88a22615b3a931e930931ea54d26dc0bc","0x0fe0d97e25d5eb11a33a3e8278584c3780941fc2675bdf8fc547cee3d1fd3b17","0xef47a60f57f177a683c723c658137efab66d311e1c5abbc4d74f653535144d03","0xe23a5b35faae5335adc5aca38c5d633b00438b798c2053104b8df48406c9b141","0xd8cea4ba619b317bc05d58534af73beec6c2548b31b24d4dc61c9bbd29cfa17a","0x79a4b9d90b02c768baaad305f266281213cc75062cbe99a13222cc0c4b509498","0x6790a3bbddbeb21fcb736a59b3775755051c3a6344d8390cf8ca27f2e8a814f0","0x87ec7ace5442db252b5751ffddd38dcb04b088d36b6b0e526ff25607a4293c81","0x40cb487ecffda94f97ce7fc0f7163f2f024235df2c8291169edc80dac063e6d0","0xb76bb3d88c9b30d927c45ccfcf8d5b0054411ac8501ad588822a7d04690cccf6","0x798ebe823209869347c08bd81e04fbf60e9bdfe44b1cc923215182d0cf3d4edb","0xbe68a7e02725f799a65ebb069ccc83a014ac7c40e4119bf7c220a2f6ddfee295","0xc90c3a72efe81331727fcce4b5bd4906066da314ca9a0b44023a6b09ea7e8114","0x619a6cbd43cde074d314c19623bd66d9fb1e13c158d7138775236f798dc1245e","0xca5a56cd77b9e5b0e79020cc6346edf205bc11e901984d805125f28c2e6686e6","0x999c9ddeed67c6ef6fbf02a6e977a6c1b68e18d24814e51643c7157b87a43e0a","0x47c8f5d0b3778e4c34eba7fcc356fa04a5afd954ccf484728e72c002764dd3c4","0x396797ae0ebcdb72ff1f96fd08b6128f78acc7417353f142f1a5facd425a33e6","0x454aa43d6546a6f62246826c16b7a49c6c704238c18802ef0d659922f23a573c","0x317ecb5bd19caa42a69f836d41556ebb0e0e00e1c6cd2dee230e6e6192612527","0xc879285db5ef0a6bce98021584d16f134c1dc0aed8cc988802c4f72ba6877ff6","0xecaa2d6f597608307e5084854854ba6dc1e69395e2abea14f2c6a2fa1d6faf9a","0x4dd69b69a568ff30ae439e2ded72fbd7f2e7aaa345836703663f155c749c5eed"],"transactionsRoot":"0x4a87d0cf5990b1c5bac631583e5965c2ba943858bebb2e07f74d0b697f73821a","uncles":[],"withdrawals":[{"index":"0x1170","validatorIndex":"0x38c2c","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x66edfd65"},{"index":"0x1171","validatorIndex":"0x38c2d","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6cd228e4"},{"index":"0x1172","validatorIndex":"0x38c2e","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x77f3431b"},{"index":"0x1173","validatorIndex":"0x38c2f","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6b61f268"},{"index":"0x1174","validatorIndex":"0x38c30","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6e10bb21"},{"index":"0x1175","validatorIndex":"0x38c31","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6eb115a5"},{"index":"0x1176","validatorIndex":"0x38c32","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x7caead1d"},{"index":"0x1177","validatorIndex":"0x38c33","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x772c0ddf"},{"index":"0x1178","validatorIndex":"0x38c34","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x75930a95"},{"index":"0x1179","validatorIndex":"0x38c35","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x76a4db09"},{"index":"0x117a","validatorIndex":"0x38c36","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x7e692b27"},{"index":"0x117b","validatorIndex":"0x38c37","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x72038ae6"},{"index":"0x117c","validatorIndex":"0x38c38","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6ccce352"},{"index":"0x117d","validatorIndex":"0x38c39","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x79ef6898"},{"index":"0x117e","validatorIndex":"0x38c3a","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6d58977d"},{"index":"0x117f","validatorIndex":"0x38c3b","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x76f7d208"}],"withdrawalsRoot":"0xbe712c930a0665264b025ced87cc7839eef95a3cbc26dadc93e9e185a350ad28"} diff --git a/op-service/sources/testdata/data/headers/post-shanghai-bad-receipts_metadata.json b/op-service/sources/testdata/data/headers/post-shanghai-bad-receipts_metadata.json new file mode 100644 index 0000000000000..4da07c88cd37e --- /dev/null +++ b/op-service/sources/testdata/data/headers/post-shanghai-bad-receipts_metadata.json @@ -0,0 +1 @@ +{"name":"post-shanghai-bad-receipts","fail":true} diff --git a/op-service/sources/testdata/data/headers/post-shanghai-bad-transactions_data.json b/op-service/sources/testdata/data/headers/post-shanghai-bad-transactions_data.json new file mode 100644 index 0000000000000..075f7f0583c5c --- /dev/null +++ b/op-service/sources/testdata/data/headers/post-shanghai-bad-transactions_data.json @@ -0,0 +1 @@ +{"baseFeePerGas":"0x3fb7c357","difficulty":"0x0","extraData":"0x","gasLimit":"0x1c9c380","gasUsed":"0x18f759","hash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","logsBloom":"0x020010404000001a0000021000000080001100410000100001000010040200980220400000008806200200000100000000000000000000008000000400042000000050000040000112080808800002044000040004042008800480002000000000000002020020000042002400000820000080040000000010200010020010100101212050000008000000008000001010200c80000112010000438040020400000000202400000000002002a0210402000622010000000001700144000040000000002204000000c000410105024010000808000000002004002000000261000000822200200800881000000012500400400000000000000040010000800000","miner":"0x000095e79eac4d76aab57cb2c1f091d553b36ca0","mixHash":"0x5b53dc49cbab268ef9950b1d81b5e36a1b2f1b97aee1b7ff6e4db0e06c29a8b0","nonce":"0x0000000000000000","number":"0x84161e","parentHash":"0x72d92c1498e05952988d4e79a695928a6bcbd37239f8a1734051263b4d3504b8","receiptsRoot":"0xaff90ae18dcc35924a4bddb68d403b8b7812c10c3ea2a114f34105c87d75bcdb","sha3Uncles":"0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347","size":"0x2a51","stateRoot":"0xc56738518b2c7854a640ae25996d2211c9ef0dd2e4dd9e59e9d9cacef39622da","timestamp":"0x64110a5c","totalDifficulty":"0xa4a470","transactions":["0x1e8f148a9aea7d8d16ea6e9446723b8f262e8bcd89c7c961d52046ebd43b4598","0xab5c870f4c367012bd763172afbfbe68fbf35336a66ae41aff3f2c9dbf4ea3f8","0xa81fd92b2d0f0bbd3cc355f869cca3243c98c5e2641db9ecf3eeabb3b13bff6a","0xa92c7b720c08c83f1a0ed7e4c163200e30a3a8c03fcc5a51e685ea20cd0cb577","0x6921b429ad2ec1e97d3457049ad2e893b5a0349beba47ca1c74a9540af75347a","0xf776b2da0b835dde05d0d8b76fd19385d61e7055036cf637f804b36dc94f2384","0x9a08d899cd14ebb930ed59fa774afdb88a22615b3a931e930931ea54d26dc0bc","0x0fe0d97e25d5eb11a33a3e8278584c3780941fc2675bdf8fc547cee3d1fd3b17","0xef47a60f57f177a683c723c658137efab66d311e1c5abbc4d74f653535144d03","0xe23a5b35faae5335adc5aca38c5d633b00438b798c2053104b8df48406c9b141","0xd8cea4ba619b317bc05d58534af73beec6c2548b31b24d4dc61c9bbd29cfa17a","0x79a4b9d90b02c768baaad305f266281213cc75062cbe99a13222cc0c4b509498","0x6790a3bbddbeb21fcb736a59b3775755051c3a6344d8390cf8ca27f2e8a814f0","0x87ec7ace5442db252b5751ffddd38dcb04b088d36b6b0e526ff25607a4293c81","0x40cb487ecffda94f97ce7fc0f7163f2f024235df2c8291169edc80dac063e6d0","0xb76bb3d88c9b30d927c45ccfcf8d5b0054411ac8501ad588822a7d04690cccf6","0x798ebe823209869347c08bd81e04fbf60e9bdfe44b1cc923215182d0cf3d4edb","0xbe68a7e02725f799a65ebb069ccc83a014ac7c40e4119bf7c220a2f6ddfee295","0xc90c3a72efe81331727fcce4b5bd4906066da314ca9a0b44023a6b09ea7e8114","0x619a6cbd43cde074d314c19623bd66d9fb1e13c158d7138775236f798dc1245e","0xca5a56cd77b9e5b0e79020cc6346edf205bc11e901984d805125f28c2e6686e6","0x999c9ddeed67c6ef6fbf02a6e977a6c1b68e18d24814e51643c7157b87a43e0a","0x47c8f5d0b3778e4c34eba7fcc356fa04a5afd954ccf484728e72c002764dd3c4","0x396797ae0ebcdb72ff1f96fd08b6128f78acc7417353f142f1a5facd425a33e6","0x454aa43d6546a6f62246826c16b7a49c6c704238c18802ef0d659922f23a573c","0x317ecb5bd19caa42a69f836d41556ebb0e0e00e1c6cd2dee230e6e6192612527","0xc879285db5ef0a6bce98021584d16f134c1dc0aed8cc988802c4f72ba6877ff6","0xecaa2d6f597608307e5084854854ba6dc1e69395e2abea14f2c6a2fa1d6faf9a","0x4dd69b69a568ff30ae439e2ded72fbd7f2e7aaa345836703663f155c749c5eed"],"transactionsRoot":"0xaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa","uncles":[],"withdrawals":[{"index":"0x1170","validatorIndex":"0x38c2c","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x66edfd65"},{"index":"0x1171","validatorIndex":"0x38c2d","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6cd228e4"},{"index":"0x1172","validatorIndex":"0x38c2e","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x77f3431b"},{"index":"0x1173","validatorIndex":"0x38c2f","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6b61f268"},{"index":"0x1174","validatorIndex":"0x38c30","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6e10bb21"},{"index":"0x1175","validatorIndex":"0x38c31","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6eb115a5"},{"index":"0x1176","validatorIndex":"0x38c32","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x7caead1d"},{"index":"0x1177","validatorIndex":"0x38c33","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x772c0ddf"},{"index":"0x1178","validatorIndex":"0x38c34","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x75930a95"},{"index":"0x1179","validatorIndex":"0x38c35","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x76a4db09"},{"index":"0x117a","validatorIndex":"0x38c36","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x7e692b27"},{"index":"0x117b","validatorIndex":"0x38c37","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x72038ae6"},{"index":"0x117c","validatorIndex":"0x38c38","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6ccce352"},{"index":"0x117d","validatorIndex":"0x38c39","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x79ef6898"},{"index":"0x117e","validatorIndex":"0x38c3a","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6d58977d"},{"index":"0x117f","validatorIndex":"0x38c3b","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x76f7d208"}],"withdrawalsRoot":"0xbe712c930a0665264b025ced87cc7839eef95a3cbc26dadc93e9e185a350ad28"} diff --git a/op-service/sources/testdata/data/headers/post-shanghai-bad-transactions_metadata.json b/op-service/sources/testdata/data/headers/post-shanghai-bad-transactions_metadata.json new file mode 100644 index 0000000000000..03c892fc1ea30 --- /dev/null +++ b/op-service/sources/testdata/data/headers/post-shanghai-bad-transactions_metadata.json @@ -0,0 +1 @@ +{"name":"post-shanghai-bad-transactions","fail":true} diff --git a/op-service/sources/testdata/data/headers/post-shanghai-bad-withdrawals_data.json b/op-service/sources/testdata/data/headers/post-shanghai-bad-withdrawals_data.json new file mode 100644 index 0000000000000..1e0a4d51d173f --- /dev/null +++ b/op-service/sources/testdata/data/headers/post-shanghai-bad-withdrawals_data.json @@ -0,0 +1 @@ +{"baseFeePerGas":"0x3fb7c357","difficulty":"0x0","extraData":"0x","gasLimit":"0x1c9c380","gasUsed":"0x18f759","hash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","logsBloom":"0x020010404000001a0000021000000080001100410000100001000010040200980220400000008806200200000100000000000000000000008000000400042000000050000040000112080808800002044000040004042008800480002000000000000002020020000042002400000820000080040000000010200010020010100101212050000008000000008000001010200c80000112010000438040020400000000202400000000002002a0210402000622010000000001700144000040000000002204000000c000410105024010000808000000002004002000000261000000822200200800881000000012500400400000000000000040010000800000","miner":"0x000095e79eac4d76aab57cb2c1f091d553b36ca0","mixHash":"0x5b53dc49cbab268ef9950b1d81b5e36a1b2f1b97aee1b7ff6e4db0e06c29a8b0","nonce":"0x0000000000000000","number":"0x84161e","parentHash":"0x72d92c1498e05952988d4e79a695928a6bcbd37239f8a1734051263b4d3504b8","receiptsRoot":"0xaff90ae18dcc35924a4bddb68d403b8b7812c10c3ea2a114f34105c87d75bcdb","sha3Uncles":"0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347","size":"0x2a51","stateRoot":"0xc56738518b2c7854a640ae25996d2211c9ef0dd2e4dd9e59e9d9cacef39622da","timestamp":"0x64110a5c","totalDifficulty":"0xa4a470","transactions":["0x1e8f148a9aea7d8d16ea6e9446723b8f262e8bcd89c7c961d52046ebd43b4598","0xab5c870f4c367012bd763172afbfbe68fbf35336a66ae41aff3f2c9dbf4ea3f8","0xa81fd92b2d0f0bbd3cc355f869cca3243c98c5e2641db9ecf3eeabb3b13bff6a","0xa92c7b720c08c83f1a0ed7e4c163200e30a3a8c03fcc5a51e685ea20cd0cb577","0x6921b429ad2ec1e97d3457049ad2e893b5a0349beba47ca1c74a9540af75347a","0xf776b2da0b835dde05d0d8b76fd19385d61e7055036cf637f804b36dc94f2384","0x9a08d899cd14ebb930ed59fa774afdb88a22615b3a931e930931ea54d26dc0bc","0x0fe0d97e25d5eb11a33a3e8278584c3780941fc2675bdf8fc547cee3d1fd3b17","0xef47a60f57f177a683c723c658137efab66d311e1c5abbc4d74f653535144d03","0xe23a5b35faae5335adc5aca38c5d633b00438b798c2053104b8df48406c9b141","0xd8cea4ba619b317bc05d58534af73beec6c2548b31b24d4dc61c9bbd29cfa17a","0x79a4b9d90b02c768baaad305f266281213cc75062cbe99a13222cc0c4b509498","0x6790a3bbddbeb21fcb736a59b3775755051c3a6344d8390cf8ca27f2e8a814f0","0x87ec7ace5442db252b5751ffddd38dcb04b088d36b6b0e526ff25607a4293c81","0x40cb487ecffda94f97ce7fc0f7163f2f024235df2c8291169edc80dac063e6d0","0xb76bb3d88c9b30d927c45ccfcf8d5b0054411ac8501ad588822a7d04690cccf6","0x798ebe823209869347c08bd81e04fbf60e9bdfe44b1cc923215182d0cf3d4edb","0xbe68a7e02725f799a65ebb069ccc83a014ac7c40e4119bf7c220a2f6ddfee295","0xc90c3a72efe81331727fcce4b5bd4906066da314ca9a0b44023a6b09ea7e8114","0x619a6cbd43cde074d314c19623bd66d9fb1e13c158d7138775236f798dc1245e","0xca5a56cd77b9e5b0e79020cc6346edf205bc11e901984d805125f28c2e6686e6","0x999c9ddeed67c6ef6fbf02a6e977a6c1b68e18d24814e51643c7157b87a43e0a","0x47c8f5d0b3778e4c34eba7fcc356fa04a5afd954ccf484728e72c002764dd3c4","0x396797ae0ebcdb72ff1f96fd08b6128f78acc7417353f142f1a5facd425a33e6","0x454aa43d6546a6f62246826c16b7a49c6c704238c18802ef0d659922f23a573c","0x317ecb5bd19caa42a69f836d41556ebb0e0e00e1c6cd2dee230e6e6192612527","0xc879285db5ef0a6bce98021584d16f134c1dc0aed8cc988802c4f72ba6877ff6","0xecaa2d6f597608307e5084854854ba6dc1e69395e2abea14f2c6a2fa1d6faf9a","0x4dd69b69a568ff30ae439e2ded72fbd7f2e7aaa345836703663f155c749c5eed"],"transactionsRoot":"0x4a87d0cf5990b1c5bac631583e5965c2ba943858bebb2e07f74d0b697f73821a","uncles":[],"withdrawals":[{"index":"0x1170","validatorIndex":"0x38c2c","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x66edfd65"},{"index":"0x1171","validatorIndex":"0x38c2d","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6cd228e4"},{"index":"0x1172","validatorIndex":"0x38c2e","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x77f3431b"},{"index":"0x1173","validatorIndex":"0x38c2f","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6b61f268"},{"index":"0x1174","validatorIndex":"0x38c30","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6e10bb21"},{"index":"0x1175","validatorIndex":"0x38c31","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6eb115a5"},{"index":"0x1176","validatorIndex":"0x38c32","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x7caead1d"},{"index":"0x1177","validatorIndex":"0x38c33","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x772c0ddf"},{"index":"0x1178","validatorIndex":"0x38c34","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x75930a95"},{"index":"0x1179","validatorIndex":"0x38c35","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x76a4db09"},{"index":"0x117a","validatorIndex":"0x38c36","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x7e692b27"},{"index":"0x117b","validatorIndex":"0x38c37","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x72038ae6"},{"index":"0x117c","validatorIndex":"0x38c38","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6ccce352"},{"index":"0x117d","validatorIndex":"0x38c39","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x79ef6898"},{"index":"0x117e","validatorIndex":"0x38c3a","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6d58977d"},{"index":"0x117f","validatorIndex":"0x38c3b","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x76f7d208"}],"withdrawalsRoot":"0xaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"} diff --git a/op-service/sources/testdata/data/headers/post-shanghai-bad-withdrawals_metadata.json b/op-service/sources/testdata/data/headers/post-shanghai-bad-withdrawals_metadata.json new file mode 100644 index 0000000000000..16d4bd5bcc0e7 --- /dev/null +++ b/op-service/sources/testdata/data/headers/post-shanghai-bad-withdrawals_metadata.json @@ -0,0 +1 @@ +{"name":"post-shanghai-bad-withdrawals","fail":true} diff --git a/op-service/sources/testdata/data/headers/post-shanghai-success_data.json b/op-service/sources/testdata/data/headers/post-shanghai-success_data.json new file mode 100644 index 0000000000000..bbaf3af1589d3 --- /dev/null +++ b/op-service/sources/testdata/data/headers/post-shanghai-success_data.json @@ -0,0 +1 @@ +{"baseFeePerGas":"0x3fb7c357","difficulty":"0x0","extraData":"0x","gasLimit":"0x1c9c380","gasUsed":"0x18f759","hash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","logsBloom":"0x020010404000001a0000021000000080001100410000100001000010040200980220400000008806200200000100000000000000000000008000000400042000000050000040000112080808800002044000040004042008800480002000000000000002020020000042002400000820000080040000000010200010020010100101212050000008000000008000001010200c80000112010000438040020400000000202400000000002002a0210402000622010000000001700144000040000000002204000000c000410105024010000808000000002004002000000261000000822200200800881000000012500400400000000000000040010000800000","miner":"0x000095e79eac4d76aab57cb2c1f091d553b36ca0","mixHash":"0x5b53dc49cbab268ef9950b1d81b5e36a1b2f1b97aee1b7ff6e4db0e06c29a8b0","nonce":"0x0000000000000000","number":"0x84161e","parentHash":"0x72d92c1498e05952988d4e79a695928a6bcbd37239f8a1734051263b4d3504b8","receiptsRoot":"0xaff90ae18dcc35924a4bddb68d403b8b7812c10c3ea2a114f34105c87d75bcdb","sha3Uncles":"0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347","size":"0x2a51","stateRoot":"0xc56738518b2c7854a640ae25996d2211c9ef0dd2e4dd9e59e9d9cacef39622da","timestamp":"0x64110a5c","totalDifficulty":"0xa4a470","transactions":["0x1e8f148a9aea7d8d16ea6e9446723b8f262e8bcd89c7c961d52046ebd43b4598","0xab5c870f4c367012bd763172afbfbe68fbf35336a66ae41aff3f2c9dbf4ea3f8","0xa81fd92b2d0f0bbd3cc355f869cca3243c98c5e2641db9ecf3eeabb3b13bff6a","0xa92c7b720c08c83f1a0ed7e4c163200e30a3a8c03fcc5a51e685ea20cd0cb577","0x6921b429ad2ec1e97d3457049ad2e893b5a0349beba47ca1c74a9540af75347a","0xf776b2da0b835dde05d0d8b76fd19385d61e7055036cf637f804b36dc94f2384","0x9a08d899cd14ebb930ed59fa774afdb88a22615b3a931e930931ea54d26dc0bc","0x0fe0d97e25d5eb11a33a3e8278584c3780941fc2675bdf8fc547cee3d1fd3b17","0xef47a60f57f177a683c723c658137efab66d311e1c5abbc4d74f653535144d03","0xe23a5b35faae5335adc5aca38c5d633b00438b798c2053104b8df48406c9b141","0xd8cea4ba619b317bc05d58534af73beec6c2548b31b24d4dc61c9bbd29cfa17a","0x79a4b9d90b02c768baaad305f266281213cc75062cbe99a13222cc0c4b509498","0x6790a3bbddbeb21fcb736a59b3775755051c3a6344d8390cf8ca27f2e8a814f0","0x87ec7ace5442db252b5751ffddd38dcb04b088d36b6b0e526ff25607a4293c81","0x40cb487ecffda94f97ce7fc0f7163f2f024235df2c8291169edc80dac063e6d0","0xb76bb3d88c9b30d927c45ccfcf8d5b0054411ac8501ad588822a7d04690cccf6","0x798ebe823209869347c08bd81e04fbf60e9bdfe44b1cc923215182d0cf3d4edb","0xbe68a7e02725f799a65ebb069ccc83a014ac7c40e4119bf7c220a2f6ddfee295","0xc90c3a72efe81331727fcce4b5bd4906066da314ca9a0b44023a6b09ea7e8114","0x619a6cbd43cde074d314c19623bd66d9fb1e13c158d7138775236f798dc1245e","0xca5a56cd77b9e5b0e79020cc6346edf205bc11e901984d805125f28c2e6686e6","0x999c9ddeed67c6ef6fbf02a6e977a6c1b68e18d24814e51643c7157b87a43e0a","0x47c8f5d0b3778e4c34eba7fcc356fa04a5afd954ccf484728e72c002764dd3c4","0x396797ae0ebcdb72ff1f96fd08b6128f78acc7417353f142f1a5facd425a33e6","0x454aa43d6546a6f62246826c16b7a49c6c704238c18802ef0d659922f23a573c","0x317ecb5bd19caa42a69f836d41556ebb0e0e00e1c6cd2dee230e6e6192612527","0xc879285db5ef0a6bce98021584d16f134c1dc0aed8cc988802c4f72ba6877ff6","0xecaa2d6f597608307e5084854854ba6dc1e69395e2abea14f2c6a2fa1d6faf9a","0x4dd69b69a568ff30ae439e2ded72fbd7f2e7aaa345836703663f155c749c5eed"],"transactionsRoot":"0x4a87d0cf5990b1c5bac631583e5965c2ba943858bebb2e07f74d0b697f73821a","uncles":[],"withdrawals":[{"index":"0x1170","validatorIndex":"0x38c2c","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x66edfd65"},{"index":"0x1171","validatorIndex":"0x38c2d","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6cd228e4"},{"index":"0x1172","validatorIndex":"0x38c2e","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x77f3431b"},{"index":"0x1173","validatorIndex":"0x38c2f","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6b61f268"},{"index":"0x1174","validatorIndex":"0x38c30","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6e10bb21"},{"index":"0x1175","validatorIndex":"0x38c31","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6eb115a5"},{"index":"0x1176","validatorIndex":"0x38c32","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x7caead1d"},{"index":"0x1177","validatorIndex":"0x38c33","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x772c0ddf"},{"index":"0x1178","validatorIndex":"0x38c34","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x75930a95"},{"index":"0x1179","validatorIndex":"0x38c35","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x76a4db09"},{"index":"0x117a","validatorIndex":"0x38c36","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x7e692b27"},{"index":"0x117b","validatorIndex":"0x38c37","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x72038ae6"},{"index":"0x117c","validatorIndex":"0x38c38","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6ccce352"},{"index":"0x117d","validatorIndex":"0x38c39","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x79ef6898"},{"index":"0x117e","validatorIndex":"0x38c3a","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6d58977d"},{"index":"0x117f","validatorIndex":"0x38c3b","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x76f7d208"}],"withdrawalsRoot":"0xbe712c930a0665264b025ced87cc7839eef95a3cbc26dadc93e9e185a350ad28"} diff --git a/op-service/sources/testdata/data/headers/post-shanghai-success_metadata.json b/op-service/sources/testdata/data/headers/post-shanghai-success_metadata.json new file mode 100644 index 0000000000000..d6179c6587c35 --- /dev/null +++ b/op-service/sources/testdata/data/headers/post-shanghai-success_metadata.json @@ -0,0 +1 @@ +{"name":"post-shanghai-success"} diff --git a/op-service/sources/testdata/data/headers/pre-shanghai-bad-receipts_data.json b/op-service/sources/testdata/data/headers/pre-shanghai-bad-receipts_data.json new file mode 100644 index 0000000000000..98d9a33040320 --- /dev/null +++ b/op-service/sources/testdata/data/headers/pre-shanghai-bad-receipts_data.json @@ -0,0 +1 @@ +{"baseFeePerGas":"0x7ccf990f8","difficulty":"0x0","extraData":"0xd883010b02846765746888676f312e32302e31856c696e7578","gasLimit":"0x1c9c380","gasUsed":"0xa79638","hash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","logsBloom":"0xb034000008010014411408c080a0018440087220211154100005a1388807241142a2504080034a00111212a47f05008520200000280202a12800538cc06488486a0141989c7800c0c848011f02249661800e08449145b040a252d18082c009000641004052c80102000804ac10901c24032000980010438a01e50a90a0d8008c138c21204040000b20425000833041028000148124c2012d0aa8d1d0548301808228002015184090000224021040d68220100210220480420308455c382a40020130dc42502986080600000115034c0401c81828490410308005610048026b822e10b4228071ba00bdd20140621b2000c02012300808084181ac308200000011","miner":"0x0000000000000000000000000000000000000000","mixHash":"0x31f0c0305fc07a93b1a33da339c79aadbe8d9811c78d2b514cd18d64e1328f25","nonce":"0x0000000000000000","number":"0x840249","parentHash":"0x2303b55af4add799b19275a491b150c1a03075395f87a7856a4e3327595ed7df","receiptsRoot":"0xaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa","sha3Uncles":"0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347","size":"0xea6d","stateRoot":"0xd12bf4cf3941cf48be329a939b13d3403d326841c69cdcc9a9c13ab2f227e904","timestamp":"0x640fdeb0","totalDifficulty":"0xa4a470","transactions":["0x39c666d9b5cec429accad7b0f94f789ca2ebeb5294b8b129c1b76f552daf57d3","0x2ca7289ab3738d17e0f5093bd96c97c06c9a2ea4c22fc84a6a7fbfda93ce55ee","0xb0085de1476530de3efc6928c4683e7c40f8fac18875f74cbcc47df159de17d9","0xe01c8631c86ded63af95b8dbc0c8aac5d31254c14d6ecb4cc51d98259d838e52","0x69414a126a6f07ab5e31ad2f9069fb986b7c490e096898473873e41ece6af783","0xa2fef1133ee726533c7f190f246fede123e3706a03933c1febc92618f90d2804","0x6585ec5c4c2bbf1f683f90f58e18f3b38d875e94457fe4cbb7bc5bf6581f83af","0x1db276b864fbf01dcf8cededf8d597553ecb0eb9438edfaf2f5bd0cc93297c66","0xcbe7ed31654af4e191ca53445b82de040ae2cd92459a3f951bdcce423d780f08","0x808ba5211f03cc78a732ff0f9383c6355e63c83ae8c6035ced2ba6f7c331dc63","0xdd66f1f26672849ef54c420210f479c9f0c46924d8e9f7b210981ffe8d3fac82","0x254abb2f8cdcffe9ef62ab924312a1e4142578db87e4f7c199fd35991e92f014","0xa7b7c654e7073b8043b680b7ffc95d3f2099abaa0b0578d6f954a2a7c99404e1","0x7ccdfa698c8acf47ab9316ed078eb40819ff575bcf612c6f59f29e7726df3f96","0xa0b035ef315824a6f6a6565fa8de27042ade3af9cf0583a36dea83d6e01bf2a8","0x1ebad7f3e8cb3543d4963686a94d99f61839f666831eab9c9c1b4711de11d3d9","0x501750278e91d8b5be1ccf60e793d4bbcd9b3bb3ccc518d3634a71caeac65f48","0xd80ff8af29ae163d5811ba511e60b3a87a279f677bb3872a0f1aa6d0a226e880","0x096acab3b3fe47b149d375782d1eb00b9fef7904076d60c54b3c197b04e6bf82","0xbe9d1738af74a22400591a9a808fb01a25ab41e2e56f202dd7251eb113e8ceeb","0x0834c720e55cccd97aaf4f8fb0cb66afb9881fb6a762c0f70473ec53f98a712e","0x51a0c33c9b37245b416575bdd2751c0d8a5d8bead49585ac427bfc873d4016af","0x531c25d51ccda59aa9ea82e85c99be9dd4e285af9b8973cbab9ac4a38e26e55a","0x93ac6c08d21cb1b61ff59e5e2d6fa3f9ad54008b0a66c669199050bef219f6e3","0x3792db6dd6285f409e4281951e9f78dad16c4a78072ff1c909dfadea5658d857","0xd2d51764c01e8c0a43fbe362704388df5bacf7e5e620c3864e242530ffb3e828","0x516b0227d9e64eb6e0de6862764d40f5376b5f12fec878436fea3479b4c36bb8","0x81b0abc78b82840adb666775b182a9e292f663b64bcd35004c04436ed3c8281c","0xd0287570d431d2baea96ecc81cb890e7f4f06ab5df02f9b4067768abca19acb5","0x76ddab2674369f34946c5fa2f05e2aa8566d86235b83e808e9b27bc106e04ac7","0x34a5c74011a2c8a00103bc91bfbfd94aa99cd569be69066e4bf64d188fe8714e","0x7b9730ead1b9f59b206d0ddea87be9383ba3fc7b496c7863b0cb847889b86617","0x77166ee0409ba86bd26e7c03ad1a927abaf5af8a8a37149e725cd37512091dd6","0x3c2b6c2ae505c5c36d5f316c1fcb5f54f7346ed35ae35c93462991ded7968a68","0xf99a792837e13827b5e0a8915fb59c760babc95d242feca99a5594e64ff6b6e2","0x522313f5d923f048ae5bd0b5595c1f4fc883bc0b3cf3cb0939d3fcf8b08c829c","0x471ceb0e85af594aa56deca54cb8198567b2afd8406722ea530077aaa6b641b3","0x3e9dca502e9039ae0c6d642f62e9562ff00010c6bfbb8234a6135712ba70dfda","0xc95cac67267f4accb9b5950316ac64772f7d082bed6b712c09cf2da0bdc237b7","0xfca28fdbd13fc16daf7aec7d4a2ad2c6b5f0b2a7b0fb1d9167c09b5e115ff26e","0xc73124ca798b2f7a5df2ea4d568efab2f41b135130ea5cc41d4bcb4b5c57d5bd","0x29abb76b5e7a5ce137bf9c22474d386eb58d249f43178d2b2e15c16dfdc5ca80","0x03e5ab25a58bd44fb9dd0c698b323eab8b8363479dfcbcbb16d0a0bd983880ae","0x3c8ee80ddea7fa2d2b75e44563c10c10756f598e8ad252a49c5d3e8a5c8e6cbf","0xaffa73b68bc7ab0c3f5e28377f5ca0a5df33c0a485f64dc094b7f6ae23353203","0xc66c9c66fbc8fe97fcc16506cde7a58689af1004a18c6171cfe763bcd94f50b2","0x80fec96707519172b53790610d5800cd09a4243aca9bacfa956c56337d06f820","0x61b33bfcf11214906dcdce7d7ed83ad82f38184c03ded07f7782059d02eeedea","0x5d4138d4e28a8327e506cb012346b1b38b65f615a2b991d35cf5d4de244b3e6d","0x875a142b6dfcf10ffb71a7afe0ce4672c047fc7e162ba0383390516d6334d45d","0x79b6df832bfbd04085d0b005a6e3ad8f00fc8717eed59280aa8107268b71e7e0","0xcb2fb25d268f65dc9312e89bd3c328c9847a3c9da282026793c54a745f825ab5","0xe483d4a36ad19fd5eacb7f6d9ad3ce080ad70ac673273e710f6e3d5acbc6559c","0x0564242c37d5013b671ef4864394cc0f3924c589f8aad64118223a9af2f164f6","0x48db358e80b278c3a46c2a166339797060a40f33984a5d974992cd9722139d5d","0x69d7758db91fae31fa35ecbed4d40897c5087f45dc796cd796b8ceead21f972e","0x2951478916ecd27a8e808d08f85be4bf2c0b0e0546f21f4e309145dd96eb8df1","0xaca9028cb5d55bbf71b7bff9884a9a3b0b38a575ffc8f8807ce345cf8bd298ef","0xc7f625a19ee41a1750eac9428b4394a9a2476b8ea2d31b4c2f9f5b4fcb86cae3","0x45499074aa521ac4151138f0aad969bcc2dfc1648d22ff8c42e51c74cb77414d","0x00b5b05c6d1a2eb8abe2c383da600516515e383fc8a29953bb6e6d167e9705b2","0x6fc411f24c7b4b8d821b45de32b9edc5ac998d1ac748a98abe8e983c6f39fc19"],"transactionsRoot":"0x1ad3212eca045505cfc4cacf675b5fa2e7dc7b9f9cee88191464f97d1c9fbca4","uncles":[]} diff --git a/op-service/sources/testdata/data/headers/pre-shanghai-bad-receipts_metadata.json b/op-service/sources/testdata/data/headers/pre-shanghai-bad-receipts_metadata.json new file mode 100644 index 0000000000000..7deed556e8b27 --- /dev/null +++ b/op-service/sources/testdata/data/headers/pre-shanghai-bad-receipts_metadata.json @@ -0,0 +1 @@ +{"name":"pre-shanghai-bad-receipts","fail":true} diff --git a/op-service/sources/testdata/data/headers/pre-shanghai-bad-transactions_data.json b/op-service/sources/testdata/data/headers/pre-shanghai-bad-transactions_data.json new file mode 100644 index 0000000000000..70866d79962f9 --- /dev/null +++ b/op-service/sources/testdata/data/headers/pre-shanghai-bad-transactions_data.json @@ -0,0 +1 @@ +{"baseFeePerGas":"0x7ccf990f8","difficulty":"0x0","extraData":"0xd883010b02846765746888676f312e32302e31856c696e7578","gasLimit":"0x1c9c380","gasUsed":"0xa79638","hash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","logsBloom":"0xb034000008010014411408c080a0018440087220211154100005a1388807241142a2504080034a00111212a47f05008520200000280202a12800538cc06488486a0141989c7800c0c848011f02249661800e08449145b040a252d18082c009000641004052c80102000804ac10901c24032000980010438a01e50a90a0d8008c138c21204040000b20425000833041028000148124c2012d0aa8d1d0548301808228002015184090000224021040d68220100210220480420308455c382a40020130dc42502986080600000115034c0401c81828490410308005610048026b822e10b4228071ba00bdd20140621b2000c02012300808084181ac308200000011","miner":"0x0000000000000000000000000000000000000000","mixHash":"0x31f0c0305fc07a93b1a33da339c79aadbe8d9811c78d2b514cd18d64e1328f25","nonce":"0x0000000000000000","number":"0x840249","parentHash":"0x2303b55af4add799b19275a491b150c1a03075395f87a7856a4e3327595ed7df","receiptsRoot":"0x99da71b17ae1929db912c3315ebe349d37f2bb600454616fdde0ee90d6dbc59e","sha3Uncles":"0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347","size":"0xea6d","stateRoot":"0xd12bf4cf3941cf48be329a939b13d3403d326841c69cdcc9a9c13ab2f227e904","timestamp":"0x640fdeb0","totalDifficulty":"0xa4a470","transactions":["0x39c666d9b5cec429accad7b0f94f789ca2ebeb5294b8b129c1b76f552daf57d3","0x2ca7289ab3738d17e0f5093bd96c97c06c9a2ea4c22fc84a6a7fbfda93ce55ee","0xb0085de1476530de3efc6928c4683e7c40f8fac18875f74cbcc47df159de17d9","0xe01c8631c86ded63af95b8dbc0c8aac5d31254c14d6ecb4cc51d98259d838e52","0x69414a126a6f07ab5e31ad2f9069fb986b7c490e096898473873e41ece6af783","0xa2fef1133ee726533c7f190f246fede123e3706a03933c1febc92618f90d2804","0x6585ec5c4c2bbf1f683f90f58e18f3b38d875e94457fe4cbb7bc5bf6581f83af","0x1db276b864fbf01dcf8cededf8d597553ecb0eb9438edfaf2f5bd0cc93297c66","0xcbe7ed31654af4e191ca53445b82de040ae2cd92459a3f951bdcce423d780f08","0x808ba5211f03cc78a732ff0f9383c6355e63c83ae8c6035ced2ba6f7c331dc63","0xdd66f1f26672849ef54c420210f479c9f0c46924d8e9f7b210981ffe8d3fac82","0x254abb2f8cdcffe9ef62ab924312a1e4142578db87e4f7c199fd35991e92f014","0xa7b7c654e7073b8043b680b7ffc95d3f2099abaa0b0578d6f954a2a7c99404e1","0x7ccdfa698c8acf47ab9316ed078eb40819ff575bcf612c6f59f29e7726df3f96","0xa0b035ef315824a6f6a6565fa8de27042ade3af9cf0583a36dea83d6e01bf2a8","0x1ebad7f3e8cb3543d4963686a94d99f61839f666831eab9c9c1b4711de11d3d9","0x501750278e91d8b5be1ccf60e793d4bbcd9b3bb3ccc518d3634a71caeac65f48","0xd80ff8af29ae163d5811ba511e60b3a87a279f677bb3872a0f1aa6d0a226e880","0x096acab3b3fe47b149d375782d1eb00b9fef7904076d60c54b3c197b04e6bf82","0xbe9d1738af74a22400591a9a808fb01a25ab41e2e56f202dd7251eb113e8ceeb","0x0834c720e55cccd97aaf4f8fb0cb66afb9881fb6a762c0f70473ec53f98a712e","0x51a0c33c9b37245b416575bdd2751c0d8a5d8bead49585ac427bfc873d4016af","0x531c25d51ccda59aa9ea82e85c99be9dd4e285af9b8973cbab9ac4a38e26e55a","0x93ac6c08d21cb1b61ff59e5e2d6fa3f9ad54008b0a66c669199050bef219f6e3","0x3792db6dd6285f409e4281951e9f78dad16c4a78072ff1c909dfadea5658d857","0xd2d51764c01e8c0a43fbe362704388df5bacf7e5e620c3864e242530ffb3e828","0x516b0227d9e64eb6e0de6862764d40f5376b5f12fec878436fea3479b4c36bb8","0x81b0abc78b82840adb666775b182a9e292f663b64bcd35004c04436ed3c8281c","0xd0287570d431d2baea96ecc81cb890e7f4f06ab5df02f9b4067768abca19acb5","0x76ddab2674369f34946c5fa2f05e2aa8566d86235b83e808e9b27bc106e04ac7","0x34a5c74011a2c8a00103bc91bfbfd94aa99cd569be69066e4bf64d188fe8714e","0x7b9730ead1b9f59b206d0ddea87be9383ba3fc7b496c7863b0cb847889b86617","0x77166ee0409ba86bd26e7c03ad1a927abaf5af8a8a37149e725cd37512091dd6","0x3c2b6c2ae505c5c36d5f316c1fcb5f54f7346ed35ae35c93462991ded7968a68","0xf99a792837e13827b5e0a8915fb59c760babc95d242feca99a5594e64ff6b6e2","0x522313f5d923f048ae5bd0b5595c1f4fc883bc0b3cf3cb0939d3fcf8b08c829c","0x471ceb0e85af594aa56deca54cb8198567b2afd8406722ea530077aaa6b641b3","0x3e9dca502e9039ae0c6d642f62e9562ff00010c6bfbb8234a6135712ba70dfda","0xc95cac67267f4accb9b5950316ac64772f7d082bed6b712c09cf2da0bdc237b7","0xfca28fdbd13fc16daf7aec7d4a2ad2c6b5f0b2a7b0fb1d9167c09b5e115ff26e","0xc73124ca798b2f7a5df2ea4d568efab2f41b135130ea5cc41d4bcb4b5c57d5bd","0x29abb76b5e7a5ce137bf9c22474d386eb58d249f43178d2b2e15c16dfdc5ca80","0x03e5ab25a58bd44fb9dd0c698b323eab8b8363479dfcbcbb16d0a0bd983880ae","0x3c8ee80ddea7fa2d2b75e44563c10c10756f598e8ad252a49c5d3e8a5c8e6cbf","0xaffa73b68bc7ab0c3f5e28377f5ca0a5df33c0a485f64dc094b7f6ae23353203","0xc66c9c66fbc8fe97fcc16506cde7a58689af1004a18c6171cfe763bcd94f50b2","0x80fec96707519172b53790610d5800cd09a4243aca9bacfa956c56337d06f820","0x61b33bfcf11214906dcdce7d7ed83ad82f38184c03ded07f7782059d02eeedea","0x5d4138d4e28a8327e506cb012346b1b38b65f615a2b991d35cf5d4de244b3e6d","0x875a142b6dfcf10ffb71a7afe0ce4672c047fc7e162ba0383390516d6334d45d","0x79b6df832bfbd04085d0b005a6e3ad8f00fc8717eed59280aa8107268b71e7e0","0xcb2fb25d268f65dc9312e89bd3c328c9847a3c9da282026793c54a745f825ab5","0xe483d4a36ad19fd5eacb7f6d9ad3ce080ad70ac673273e710f6e3d5acbc6559c","0x0564242c37d5013b671ef4864394cc0f3924c589f8aad64118223a9af2f164f6","0x48db358e80b278c3a46c2a166339797060a40f33984a5d974992cd9722139d5d","0x69d7758db91fae31fa35ecbed4d40897c5087f45dc796cd796b8ceead21f972e","0x2951478916ecd27a8e808d08f85be4bf2c0b0e0546f21f4e309145dd96eb8df1","0xaca9028cb5d55bbf71b7bff9884a9a3b0b38a575ffc8f8807ce345cf8bd298ef","0xc7f625a19ee41a1750eac9428b4394a9a2476b8ea2d31b4c2f9f5b4fcb86cae3","0x45499074aa521ac4151138f0aad969bcc2dfc1648d22ff8c42e51c74cb77414d","0x00b5b05c6d1a2eb8abe2c383da600516515e383fc8a29953bb6e6d167e9705b2","0x6fc411f24c7b4b8d821b45de32b9edc5ac998d1ac748a98abe8e983c6f39fc19"],"transactionsRoot":"0xaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa","uncles":[]} diff --git a/op-service/sources/testdata/data/headers/pre-shanghai-bad-transactions_metadata.json b/op-service/sources/testdata/data/headers/pre-shanghai-bad-transactions_metadata.json new file mode 100644 index 0000000000000..6ae97b067cf5a --- /dev/null +++ b/op-service/sources/testdata/data/headers/pre-shanghai-bad-transactions_metadata.json @@ -0,0 +1 @@ +{"name":"pre-shanghai-bad-transactions","fail":true} diff --git a/op-service/sources/testdata/data/headers/pre-shanghai-success_data.json b/op-service/sources/testdata/data/headers/pre-shanghai-success_data.json new file mode 100644 index 0000000000000..c01c454a7321b --- /dev/null +++ b/op-service/sources/testdata/data/headers/pre-shanghai-success_data.json @@ -0,0 +1 @@ +{"baseFeePerGas":"0x7ccf990f8","difficulty":"0x0","extraData":"0xd883010b02846765746888676f312e32302e31856c696e7578","gasLimit":"0x1c9c380","gasUsed":"0xa79638","hash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","logsBloom":"0xb034000008010014411408c080a0018440087220211154100005a1388807241142a2504080034a00111212a47f05008520200000280202a12800538cc06488486a0141989c7800c0c848011f02249661800e08449145b040a252d18082c009000641004052c80102000804ac10901c24032000980010438a01e50a90a0d8008c138c21204040000b20425000833041028000148124c2012d0aa8d1d0548301808228002015184090000224021040d68220100210220480420308455c382a40020130dc42502986080600000115034c0401c81828490410308005610048026b822e10b4228071ba00bdd20140621b2000c02012300808084181ac308200000011","miner":"0x0000000000000000000000000000000000000000","mixHash":"0x31f0c0305fc07a93b1a33da339c79aadbe8d9811c78d2b514cd18d64e1328f25","nonce":"0x0000000000000000","number":"0x840249","parentHash":"0x2303b55af4add799b19275a491b150c1a03075395f87a7856a4e3327595ed7df","receiptsRoot":"0x99da71b17ae1929db912c3315ebe349d37f2bb600454616fdde0ee90d6dbc59e","sha3Uncles":"0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347","size":"0xea6d","stateRoot":"0xd12bf4cf3941cf48be329a939b13d3403d326841c69cdcc9a9c13ab2f227e904","timestamp":"0x640fdeb0","totalDifficulty":"0xa4a470","transactions":["0x39c666d9b5cec429accad7b0f94f789ca2ebeb5294b8b129c1b76f552daf57d3","0x2ca7289ab3738d17e0f5093bd96c97c06c9a2ea4c22fc84a6a7fbfda93ce55ee","0xb0085de1476530de3efc6928c4683e7c40f8fac18875f74cbcc47df159de17d9","0xe01c8631c86ded63af95b8dbc0c8aac5d31254c14d6ecb4cc51d98259d838e52","0x69414a126a6f07ab5e31ad2f9069fb986b7c490e096898473873e41ece6af783","0xa2fef1133ee726533c7f190f246fede123e3706a03933c1febc92618f90d2804","0x6585ec5c4c2bbf1f683f90f58e18f3b38d875e94457fe4cbb7bc5bf6581f83af","0x1db276b864fbf01dcf8cededf8d597553ecb0eb9438edfaf2f5bd0cc93297c66","0xcbe7ed31654af4e191ca53445b82de040ae2cd92459a3f951bdcce423d780f08","0x808ba5211f03cc78a732ff0f9383c6355e63c83ae8c6035ced2ba6f7c331dc63","0xdd66f1f26672849ef54c420210f479c9f0c46924d8e9f7b210981ffe8d3fac82","0x254abb2f8cdcffe9ef62ab924312a1e4142578db87e4f7c199fd35991e92f014","0xa7b7c654e7073b8043b680b7ffc95d3f2099abaa0b0578d6f954a2a7c99404e1","0x7ccdfa698c8acf47ab9316ed078eb40819ff575bcf612c6f59f29e7726df3f96","0xa0b035ef315824a6f6a6565fa8de27042ade3af9cf0583a36dea83d6e01bf2a8","0x1ebad7f3e8cb3543d4963686a94d99f61839f666831eab9c9c1b4711de11d3d9","0x501750278e91d8b5be1ccf60e793d4bbcd9b3bb3ccc518d3634a71caeac65f48","0xd80ff8af29ae163d5811ba511e60b3a87a279f677bb3872a0f1aa6d0a226e880","0x096acab3b3fe47b149d375782d1eb00b9fef7904076d60c54b3c197b04e6bf82","0xbe9d1738af74a22400591a9a808fb01a25ab41e2e56f202dd7251eb113e8ceeb","0x0834c720e55cccd97aaf4f8fb0cb66afb9881fb6a762c0f70473ec53f98a712e","0x51a0c33c9b37245b416575bdd2751c0d8a5d8bead49585ac427bfc873d4016af","0x531c25d51ccda59aa9ea82e85c99be9dd4e285af9b8973cbab9ac4a38e26e55a","0x93ac6c08d21cb1b61ff59e5e2d6fa3f9ad54008b0a66c669199050bef219f6e3","0x3792db6dd6285f409e4281951e9f78dad16c4a78072ff1c909dfadea5658d857","0xd2d51764c01e8c0a43fbe362704388df5bacf7e5e620c3864e242530ffb3e828","0x516b0227d9e64eb6e0de6862764d40f5376b5f12fec878436fea3479b4c36bb8","0x81b0abc78b82840adb666775b182a9e292f663b64bcd35004c04436ed3c8281c","0xd0287570d431d2baea96ecc81cb890e7f4f06ab5df02f9b4067768abca19acb5","0x76ddab2674369f34946c5fa2f05e2aa8566d86235b83e808e9b27bc106e04ac7","0x34a5c74011a2c8a00103bc91bfbfd94aa99cd569be69066e4bf64d188fe8714e","0x7b9730ead1b9f59b206d0ddea87be9383ba3fc7b496c7863b0cb847889b86617","0x77166ee0409ba86bd26e7c03ad1a927abaf5af8a8a37149e725cd37512091dd6","0x3c2b6c2ae505c5c36d5f316c1fcb5f54f7346ed35ae35c93462991ded7968a68","0xf99a792837e13827b5e0a8915fb59c760babc95d242feca99a5594e64ff6b6e2","0x522313f5d923f048ae5bd0b5595c1f4fc883bc0b3cf3cb0939d3fcf8b08c829c","0x471ceb0e85af594aa56deca54cb8198567b2afd8406722ea530077aaa6b641b3","0x3e9dca502e9039ae0c6d642f62e9562ff00010c6bfbb8234a6135712ba70dfda","0xc95cac67267f4accb9b5950316ac64772f7d082bed6b712c09cf2da0bdc237b7","0xfca28fdbd13fc16daf7aec7d4a2ad2c6b5f0b2a7b0fb1d9167c09b5e115ff26e","0xc73124ca798b2f7a5df2ea4d568efab2f41b135130ea5cc41d4bcb4b5c57d5bd","0x29abb76b5e7a5ce137bf9c22474d386eb58d249f43178d2b2e15c16dfdc5ca80","0x03e5ab25a58bd44fb9dd0c698b323eab8b8363479dfcbcbb16d0a0bd983880ae","0x3c8ee80ddea7fa2d2b75e44563c10c10756f598e8ad252a49c5d3e8a5c8e6cbf","0xaffa73b68bc7ab0c3f5e28377f5ca0a5df33c0a485f64dc094b7f6ae23353203","0xc66c9c66fbc8fe97fcc16506cde7a58689af1004a18c6171cfe763bcd94f50b2","0x80fec96707519172b53790610d5800cd09a4243aca9bacfa956c56337d06f820","0x61b33bfcf11214906dcdce7d7ed83ad82f38184c03ded07f7782059d02eeedea","0x5d4138d4e28a8327e506cb012346b1b38b65f615a2b991d35cf5d4de244b3e6d","0x875a142b6dfcf10ffb71a7afe0ce4672c047fc7e162ba0383390516d6334d45d","0x79b6df832bfbd04085d0b005a6e3ad8f00fc8717eed59280aa8107268b71e7e0","0xcb2fb25d268f65dc9312e89bd3c328c9847a3c9da282026793c54a745f825ab5","0xe483d4a36ad19fd5eacb7f6d9ad3ce080ad70ac673273e710f6e3d5acbc6559c","0x0564242c37d5013b671ef4864394cc0f3924c589f8aad64118223a9af2f164f6","0x48db358e80b278c3a46c2a166339797060a40f33984a5d974992cd9722139d5d","0x69d7758db91fae31fa35ecbed4d40897c5087f45dc796cd796b8ceead21f972e","0x2951478916ecd27a8e808d08f85be4bf2c0b0e0546f21f4e309145dd96eb8df1","0xaca9028cb5d55bbf71b7bff9884a9a3b0b38a575ffc8f8807ce345cf8bd298ef","0xc7f625a19ee41a1750eac9428b4394a9a2476b8ea2d31b4c2f9f5b4fcb86cae3","0x45499074aa521ac4151138f0aad969bcc2dfc1648d22ff8c42e51c74cb77414d","0x00b5b05c6d1a2eb8abe2c383da600516515e383fc8a29953bb6e6d167e9705b2","0x6fc411f24c7b4b8d821b45de32b9edc5ac998d1ac748a98abe8e983c6f39fc19"],"transactionsRoot":"0x1ad3212eca045505cfc4cacf675b5fa2e7dc7b9f9cee88191464f97d1c9fbca4","uncles":[]} diff --git a/op-service/sources/testdata/data/headers/pre-shanghai-success_metadata.json b/op-service/sources/testdata/data/headers/pre-shanghai-success_metadata.json new file mode 100644 index 0000000000000..87c9db722e782 --- /dev/null +++ b/op-service/sources/testdata/data/headers/pre-shanghai-success_metadata.json @@ -0,0 +1 @@ +{"name":"pre-shanghai-success"} diff --git a/op-service/sources/testdata/gen.sh b/op-service/sources/testdata/gen.sh new file mode 100644 index 0000000000000..60fdbb2b436e5 --- /dev/null +++ b/op-service/sources/testdata/gen.sh @@ -0,0 +1,74 @@ +#!/bin/bash +set -euo pipefail + +SOURCE_DIR=$(cd $(dirname "${BASH_SOURCE[0]}") && pwd) +cd "$SOURCE_DIR" +export ETH_RPC_URL=https://ethereum-goerli-rpc.allthatnode.com + +jq_mutate() { + local name="$1" + jq -c "$2" "$name" > "$name.tmp" && mv "$name.tmp" "$name" +} + +success_case() { + # just format the files + jq_mutate "$1" . + jq_mutate "$2" . +} + +bad_receipts_root() { + local data_file="$1" + local metadata_file="$2" + jq_mutate "$data_file" '. + {"receiptsRoot": "0xaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"}' + jq_mutate "$metadata_file" '. + {"fail": true}' +} + +bad_withdrawals_root() { + local data_file="$1" + local metadata_file="$2" + jq_mutate "$data_file" '. + {"withdrawalsRoot": "0xaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"}' + jq_mutate "$metadata_file" '. + {"fail": true}' +} + +bad_transactions_root() { + local data_file="$1" + local metadata_file="$2" + jq_mutate "$data_file" '. + {"transactionsRoot": "0xaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"}' + jq_mutate "$metadata_file" '. + {"fail": true}' +} + +generate_test_vector() { + local name="$1" + local blockhash="$2" + local fulltxs="$3" + local mutation_func="$4" + + local metadata_file="" + local data_file="" + + if [[ "$fulltxs" == true ]]; then + metadata_file="data/blocks/${name}_metadata.json" + data_file="data/blocks/${name}_data.json" + else + metadata_file="data/headers/${name}_metadata.json" + data_file="data/headers/${name}_data.json" + fi + + echo "{\"name\": \"$name\"}" > "$metadata_file" + + cast rpc eth_getBlockByHash $blockhash $fulltxs > $data_file + + # Mutate data using the provided function + $mutation_func "$data_file" $metadata_file +} + +mkdir -p data/headers + +# Headers +generate_test_vector "pre-shanghai-success" "0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663" false success_case +generate_test_vector "pre-shanghai-bad-transactions" "0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663" false bad_transactions_root +generate_test_vector "pre-shanghai-bad-receipts" "0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663" false bad_receipts_root +generate_test_vector "post-shanghai-success" "0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452" false success_case +generate_test_vector "post-shanghai-bad-withdrawals" "0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452" false bad_withdrawals_root +generate_test_vector "post-shanghai-bad-transactions" "0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452" false bad_transactions_root +generate_test_vector "post-shanghai-bad-receipts" "0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452" false bad_receipts_root diff --git a/op-service/sources/types.go b/op-service/sources/types.go index 6768ce3ba3cb4..c3e62b238e301 100644 --- a/op-service/sources/types.go +++ b/op-service/sources/types.go @@ -1,7 +1,6 @@ package sources import ( - "context" "fmt" "math/big" "strings" @@ -18,10 +17,6 @@ import ( "github.com/ethereum-optimism/optimism/op-service/eth" ) -type BatchCallContextFn func(ctx context.Context, b []rpc.BatchElem) error - -type CallContextFn func(ctx context.Context, result any, method string, args ...any) error - // Note: these types are used, instead of the geth types, to enable: // - batched calls of many block requests (standard bindings do extra uncle-header fetches, cannot be batched nicely) // - ignore uncle data (does not even exist anymore post-Merge) @@ -83,6 +78,10 @@ func (h headerInfo) GasUsed() uint64 { return h.Header.GasUsed } +func (h headerInfo) GasLimit() uint64 { + return h.Header.GasLimit +} + func (h headerInfo) HeaderRLP() ([]byte, error) { return rlp.EncodeToBytes(h.Header) } @@ -108,7 +107,16 @@ type rpcHeader struct { BaseFee *hexutil.Big `json:"baseFeePerGas"` // WithdrawalsRoot was added by EIP-4895 and is ignored in legacy headers. - WithdrawalsRoot *common.Hash `json:"withdrawalsRoot"` + WithdrawalsRoot *common.Hash `json:"withdrawalsRoot,omitempty"` + + // BlobGasUsed was added by EIP-4844 and is ignored in legacy headers. + BlobGasUsed *hexutil.Uint64 `json:"blobGasUsed,omitempty"` + + // ExcessBlobGas was added by EIP-4844 and is ignored in legacy headers. + ExcessBlobGas *hexutil.Uint64 `json:"excessBlobGas,omitempty"` + + // ParentBeaconRoot was added by EIP-4788 and is ignored in legacy headers. + ParentBeaconRoot *common.Hash `json:"parentBeaconBlockRoot,omitempty"` // untrusted info included by RPC, may have to be checked Hash common.Hash `json:"hash"` @@ -161,6 +169,10 @@ func (hdr *rpcHeader) createGethHeader() *types.Header { Nonce: hdr.Nonce, BaseFee: (*big.Int)(hdr.BaseFee), WithdrawalsHash: hdr.WithdrawalsRoot, + // Cancun + BlobGasUsed: (*uint64)(hdr.BlobGasUsed), + ExcessBlobGas: (*uint64)(hdr.ExcessBlobGas), + ParentBeaconRoot: hdr.ParentBeaconRoot, } } @@ -181,15 +193,38 @@ func (hdr *rpcHeader) Info(trustCache bool, mustBePostMerge bool) (eth.BlockInfo type rpcBlock struct { rpcHeader Transactions []*types.Transaction `json:"transactions"` + Withdrawals *types.Withdrawals `json:"withdrawals,omitempty"` } func (block *rpcBlock) verify() error { if computed := block.computeBlockHash(); computed != block.Hash { return fmt.Errorf("failed to verify block hash: computed %s but RPC said %s", computed, block.Hash) } + for i, tx := range block.Transactions { + if tx == nil { + return fmt.Errorf("block tx %d is nil", i) + } + } if computed := types.DeriveSha(types.Transactions(block.Transactions), trie.NewStackTrie(nil)); block.TxHash != computed { return fmt.Errorf("failed to verify transactions list: computed %s but RPC said %s", computed, block.TxHash) } + if block.WithdrawalsRoot != nil { + if block.Withdrawals == nil { + return fmt.Errorf("expected withdrawals") + } + for i, w := range *block.Withdrawals { + if w == nil { + return fmt.Errorf("block withdrawal %d is null", i) + } + } + if computed := types.DeriveSha(*block.Withdrawals, trie.NewStackTrie(nil)); *block.WithdrawalsRoot != computed { + return fmt.Errorf("failed to verify withdrawals list: computed %s but RPC said %s", computed, block.WithdrawalsRoot) + } + } else { + if block.Withdrawals != nil { + return fmt.Errorf("expected no withdrawals due to missing withdrawals-root, but got %d", len(*block.Withdrawals)) + } + } return nil } @@ -252,6 +287,7 @@ func (block *rpcBlock) ExecutionPayload(trustCache bool) (*eth.ExecutionPayload, BaseFeePerGas: baseFee, BlockHash: block.Hash, Transactions: opaqueTxs, + Withdrawals: block.Withdrawals, }, nil } diff --git a/op-service/sources/types_test.go b/op-service/sources/types_test.go index 87bba2a98dd73..881809391e1bc 100644 --- a/op-service/sources/types_test.go +++ b/op-service/sources/types_test.go @@ -1,35 +1,77 @@ package sources import ( + "embed" "encoding/json" + "strings" "testing" "github.com/stretchr/testify/require" ) -func TestBlockJSON(t *testing.T) { - testCases := []struct { - Name string - OK bool - Data string - }{ - {Name: "pre-Shanghai good tx", OK: true, Data: `{"number":"0x840249","hash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","transactions":["0x39c666d9b5cec429accad7b0f94f789ca2ebeb5294b8b129c1b76f552daf57d3","0x2ca7289ab3738d17e0f5093bd96c97c06c9a2ea4c22fc84a6a7fbfda93ce55ee","0xb0085de1476530de3efc6928c4683e7c40f8fac18875f74cbcc47df159de17d9","0xe01c8631c86ded63af95b8dbc0c8aac5d31254c14d6ecb4cc51d98259d838e52","0x69414a126a6f07ab5e31ad2f9069fb986b7c490e096898473873e41ece6af783","0xa2fef1133ee726533c7f190f246fede123e3706a03933c1febc92618f90d2804","0x6585ec5c4c2bbf1f683f90f58e18f3b38d875e94457fe4cbb7bc5bf6581f83af","0x1db276b864fbf01dcf8cededf8d597553ecb0eb9438edfaf2f5bd0cc93297c66","0xcbe7ed31654af4e191ca53445b82de040ae2cd92459a3f951bdcce423d780f08","0x808ba5211f03cc78a732ff0f9383c6355e63c83ae8c6035ced2ba6f7c331dc63","0xdd66f1f26672849ef54c420210f479c9f0c46924d8e9f7b210981ffe8d3fac82","0x254abb2f8cdcffe9ef62ab924312a1e4142578db87e4f7c199fd35991e92f014","0xa7b7c654e7073b8043b680b7ffc95d3f2099abaa0b0578d6f954a2a7c99404e1","0x7ccdfa698c8acf47ab9316ed078eb40819ff575bcf612c6f59f29e7726df3f96","0xa0b035ef315824a6f6a6565fa8de27042ade3af9cf0583a36dea83d6e01bf2a8","0x1ebad7f3e8cb3543d4963686a94d99f61839f666831eab9c9c1b4711de11d3d9","0x501750278e91d8b5be1ccf60e793d4bbcd9b3bb3ccc518d3634a71caeac65f48","0xd80ff8af29ae163d5811ba511e60b3a87a279f677bb3872a0f1aa6d0a226e880","0x096acab3b3fe47b149d375782d1eb00b9fef7904076d60c54b3c197b04e6bf82","0xbe9d1738af74a22400591a9a808fb01a25ab41e2e56f202dd7251eb113e8ceeb","0x0834c720e55cccd97aaf4f8fb0cb66afb9881fb6a762c0f70473ec53f98a712e","0x51a0c33c9b37245b416575bdd2751c0d8a5d8bead49585ac427bfc873d4016af","0x531c25d51ccda59aa9ea82e85c99be9dd4e285af9b8973cbab9ac4a38e26e55a","0x93ac6c08d21cb1b61ff59e5e2d6fa3f9ad54008b0a66c669199050bef219f6e3","0x3792db6dd6285f409e4281951e9f78dad16c4a78072ff1c909dfadea5658d857","0xd2d51764c01e8c0a43fbe362704388df5bacf7e5e620c3864e242530ffb3e828","0x516b0227d9e64eb6e0de6862764d40f5376b5f12fec878436fea3479b4c36bb8","0x81b0abc78b82840adb666775b182a9e292f663b64bcd35004c04436ed3c8281c","0xd0287570d431d2baea96ecc81cb890e7f4f06ab5df02f9b4067768abca19acb5","0x76ddab2674369f34946c5fa2f05e2aa8566d86235b83e808e9b27bc106e04ac7","0x34a5c74011a2c8a00103bc91bfbfd94aa99cd569be69066e4bf64d188fe8714e","0x7b9730ead1b9f59b206d0ddea87be9383ba3fc7b496c7863b0cb847889b86617","0x77166ee0409ba86bd26e7c03ad1a927abaf5af8a8a37149e725cd37512091dd6","0x3c2b6c2ae505c5c36d5f316c1fcb5f54f7346ed35ae35c93462991ded7968a68","0xf99a792837e13827b5e0a8915fb59c760babc95d242feca99a5594e64ff6b6e2","0x522313f5d923f048ae5bd0b5595c1f4fc883bc0b3cf3cb0939d3fcf8b08c829c","0x471ceb0e85af594aa56deca54cb8198567b2afd8406722ea530077aaa6b641b3","0x3e9dca502e9039ae0c6d642f62e9562ff00010c6bfbb8234a6135712ba70dfda","0xc95cac67267f4accb9b5950316ac64772f7d082bed6b712c09cf2da0bdc237b7","0xfca28fdbd13fc16daf7aec7d4a2ad2c6b5f0b2a7b0fb1d9167c09b5e115ff26e","0xc73124ca798b2f7a5df2ea4d568efab2f41b135130ea5cc41d4bcb4b5c57d5bd","0x29abb76b5e7a5ce137bf9c22474d386eb58d249f43178d2b2e15c16dfdc5ca80","0x03e5ab25a58bd44fb9dd0c698b323eab8b8363479dfcbcbb16d0a0bd983880ae","0x3c8ee80ddea7fa2d2b75e44563c10c10756f598e8ad252a49c5d3e8a5c8e6cbf","0xaffa73b68bc7ab0c3f5e28377f5ca0a5df33c0a485f64dc094b7f6ae23353203","0xc66c9c66fbc8fe97fcc16506cde7a58689af1004a18c6171cfe763bcd94f50b2","0x80fec96707519172b53790610d5800cd09a4243aca9bacfa956c56337d06f820","0x61b33bfcf11214906dcdce7d7ed83ad82f38184c03ded07f7782059d02eeedea","0x5d4138d4e28a8327e506cb012346b1b38b65f615a2b991d35cf5d4de244b3e6d","0x875a142b6dfcf10ffb71a7afe0ce4672c047fc7e162ba0383390516d6334d45d","0x79b6df832bfbd04085d0b005a6e3ad8f00fc8717eed59280aa8107268b71e7e0","0xcb2fb25d268f65dc9312e89bd3c328c9847a3c9da282026793c54a745f825ab5","0xe483d4a36ad19fd5eacb7f6d9ad3ce080ad70ac673273e710f6e3d5acbc6559c","0x0564242c37d5013b671ef4864394cc0f3924c589f8aad64118223a9af2f164f6","0x48db358e80b278c3a46c2a166339797060a40f33984a5d974992cd9722139d5d","0x69d7758db91fae31fa35ecbed4d40897c5087f45dc796cd796b8ceead21f972e","0x2951478916ecd27a8e808d08f85be4bf2c0b0e0546f21f4e309145dd96eb8df1","0xaca9028cb5d55bbf71b7bff9884a9a3b0b38a575ffc8f8807ce345cf8bd298ef","0xc7f625a19ee41a1750eac9428b4394a9a2476b8ea2d31b4c2f9f5b4fcb86cae3","0x45499074aa521ac4151138f0aad969bcc2dfc1648d22ff8c42e51c74cb77414d","0x00b5b05c6d1a2eb8abe2c383da600516515e383fc8a29953bb6e6d167e9705b2","0x6fc411f24c7b4b8d821b45de32b9edc5ac998d1ac748a98abe8e983c6f39fc19"],"difficulty":"0x0","extraData":"0xd883010b02846765746888676f312e32302e31856c696e7578","gasLimit":"0x1c9c380","gasUsed":"0xa79638","logsBloom":"0xb034000008010014411408c080a0018440087220211154100005a1388807241142a2504080034a00111212a47f05008520200000280202a12800538cc06488486a0141989c7800c0c848011f02249661800e08449145b040a252d18082c009000641004052c80102000804ac10901c24032000980010438a01e50a90a0d8008c138c21204040000b20425000833041028000148124c2012d0aa8d1d0548301808228002015184090000224021040d68220100210220480420308455c382a40020130dc42502986080600000115034c0401c81828490410308005610048026b822e10b4228071ba00bdd20140621b2000c02012300808084181ac308200000011","miner":"0x0000000000000000000000000000000000000000","mixHash":"0x31f0c0305fc07a93b1a33da339c79aadbe8d9811c78d2b514cd18d64e1328f25","nonce":"0x0000000000000000","parentHash":"0x2303b55af4add799b19275a491b150c1a03075395f87a7856a4e3327595ed7df","receiptsRoot":"0x99da71b17ae1929db912c3315ebe349d37f2bb600454616fdde0ee90d6dbc59e","sha3Uncles":"0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347","size":"0xea6d","stateRoot":"0xd12bf4cf3941cf48be329a939b13d3403d326841c69cdcc9a9c13ab2f227e904","timestamp":"0x640fdeb0","totalDifficulty":"0xa4a470","transactionsRoot":"0x1ad3212eca045505cfc4cacf675b5fa2e7dc7b9f9cee88191464f97d1c9fbca4","uncles":[],"baseFeePerGas":"0x7ccf990f8"} -`}, - {Name: "pre-Shanghai bad receipts root", OK: false, Data: `{"number":"0x840249","hash":"0x9ef7cd2241202b919a0e51240818a8666c73f7ce4b908931e3ae6d26d30f7663","transactions":["0x39c666d9b5cec429accad7b0f94f789ca2ebeb5294b8b129c1b76f552daf57d3","0x2ca7289ab3738d17e0f5093bd96c97c06c9a2ea4c22fc84a6a7fbfda93ce55ee","0xb0085de1476530de3efc6928c4683e7c40f8fac18875f74cbcc47df159de17d9","0xe01c8631c86ded63af95b8dbc0c8aac5d31254c14d6ecb4cc51d98259d838e52","0x69414a126a6f07ab5e31ad2f9069fb986b7c490e096898473873e41ece6af783","0xa2fef1133ee726533c7f190f246fede123e3706a03933c1febc92618f90d2804","0x6585ec5c4c2bbf1f683f90f58e18f3b38d875e94457fe4cbb7bc5bf6581f83af","0x1db276b864fbf01dcf8cededf8d597553ecb0eb9438edfaf2f5bd0cc93297c66","0xcbe7ed31654af4e191ca53445b82de040ae2cd92459a3f951bdcce423d780f08","0x808ba5211f03cc78a732ff0f9383c6355e63c83ae8c6035ced2ba6f7c331dc63","0xdd66f1f26672849ef54c420210f479c9f0c46924d8e9f7b210981ffe8d3fac82","0x254abb2f8cdcffe9ef62ab924312a1e4142578db87e4f7c199fd35991e92f014","0xa7b7c654e7073b8043b680b7ffc95d3f2099abaa0b0578d6f954a2a7c99404e1","0x7ccdfa698c8acf47ab9316ed078eb40819ff575bcf612c6f59f29e7726df3f96","0xa0b035ef315824a6f6a6565fa8de27042ade3af9cf0583a36dea83d6e01bf2a8","0x1ebad7f3e8cb3543d4963686a94d99f61839f666831eab9c9c1b4711de11d3d9","0x501750278e91d8b5be1ccf60e793d4bbcd9b3bb3ccc518d3634a71caeac65f48","0xd80ff8af29ae163d5811ba511e60b3a87a279f677bb3872a0f1aa6d0a226e880","0x096acab3b3fe47b149d375782d1eb00b9fef7904076d60c54b3c197b04e6bf82","0xbe9d1738af74a22400591a9a808fb01a25ab41e2e56f202dd7251eb113e8ceeb","0x0834c720e55cccd97aaf4f8fb0cb66afb9881fb6a762c0f70473ec53f98a712e","0x51a0c33c9b37245b416575bdd2751c0d8a5d8bead49585ac427bfc873d4016af","0x531c25d51ccda59aa9ea82e85c99be9dd4e285af9b8973cbab9ac4a38e26e55a","0x93ac6c08d21cb1b61ff59e5e2d6fa3f9ad54008b0a66c669199050bef219f6e3","0x3792db6dd6285f409e4281951e9f78dad16c4a78072ff1c909dfadea5658d857","0xd2d51764c01e8c0a43fbe362704388df5bacf7e5e620c3864e242530ffb3e828","0x516b0227d9e64eb6e0de6862764d40f5376b5f12fec878436fea3479b4c36bb8","0x81b0abc78b82840adb666775b182a9e292f663b64bcd35004c04436ed3c8281c","0xd0287570d431d2baea96ecc81cb890e7f4f06ab5df02f9b4067768abca19acb5","0x76ddab2674369f34946c5fa2f05e2aa8566d86235b83e808e9b27bc106e04ac7","0x34a5c74011a2c8a00103bc91bfbfd94aa99cd569be69066e4bf64d188fe8714e","0x7b9730ead1b9f59b206d0ddea87be9383ba3fc7b496c7863b0cb847889b86617","0x77166ee0409ba86bd26e7c03ad1a927abaf5af8a8a37149e725cd37512091dd6","0x3c2b6c2ae505c5c36d5f316c1fcb5f54f7346ed35ae35c93462991ded7968a68","0xf99a792837e13827b5e0a8915fb59c760babc95d242feca99a5594e64ff6b6e2","0x522313f5d923f048ae5bd0b5595c1f4fc883bc0b3cf3cb0939d3fcf8b08c829c","0x471ceb0e85af594aa56deca54cb8198567b2afd8406722ea530077aaa6b641b3","0x3e9dca502e9039ae0c6d642f62e9562ff00010c6bfbb8234a6135712ba70dfda","0xc95cac67267f4accb9b5950316ac64772f7d082bed6b712c09cf2da0bdc237b7","0xfca28fdbd13fc16daf7aec7d4a2ad2c6b5f0b2a7b0fb1d9167c09b5e115ff26e","0xc73124ca798b2f7a5df2ea4d568efab2f41b135130ea5cc41d4bcb4b5c57d5bd","0x29abb76b5e7a5ce137bf9c22474d386eb58d249f43178d2b2e15c16dfdc5ca80","0x03e5ab25a58bd44fb9dd0c698b323eab8b8363479dfcbcbb16d0a0bd983880ae","0x3c8ee80ddea7fa2d2b75e44563c10c10756f598e8ad252a49c5d3e8a5c8e6cbf","0xaffa73b68bc7ab0c3f5e28377f5ca0a5df33c0a485f64dc094b7f6ae23353203","0xc66c9c66fbc8fe97fcc16506cde7a58689af1004a18c6171cfe763bcd94f50b2","0x80fec96707519172b53790610d5800cd09a4243aca9bacfa956c56337d06f820","0x61b33bfcf11214906dcdce7d7ed83ad82f38184c03ded07f7782059d02eeedea","0x5d4138d4e28a8327e506cb012346b1b38b65f615a2b991d35cf5d4de244b3e6d","0x875a142b6dfcf10ffb71a7afe0ce4672c047fc7e162ba0383390516d6334d45d","0x79b6df832bfbd04085d0b005a6e3ad8f00fc8717eed59280aa8107268b71e7e0","0xcb2fb25d268f65dc9312e89bd3c328c9847a3c9da282026793c54a745f825ab5","0xe483d4a36ad19fd5eacb7f6d9ad3ce080ad70ac673273e710f6e3d5acbc6559c","0x0564242c37d5013b671ef4864394cc0f3924c589f8aad64118223a9af2f164f6","0x48db358e80b278c3a46c2a166339797060a40f33984a5d974992cd9722139d5d","0x69d7758db91fae31fa35ecbed4d40897c5087f45dc796cd796b8ceead21f972e","0x2951478916ecd27a8e808d08f85be4bf2c0b0e0546f21f4e309145dd96eb8df1","0xaca9028cb5d55bbf71b7bff9884a9a3b0b38a575ffc8f8807ce345cf8bd298ef","0xc7f625a19ee41a1750eac9428b4394a9a2476b8ea2d31b4c2f9f5b4fcb86cae3","0x45499074aa521ac4151138f0aad969bcc2dfc1648d22ff8c42e51c74cb77414d","0x00b5b05c6d1a2eb8abe2c383da600516515e383fc8a29953bb6e6d167e9705b2","0x6fc411f24c7b4b8d821b45de32b9edc5ac998d1ac748a98abe8e983c6f39fc19"],"difficulty":"0x0","extraData":"0xd883010b02846765746888676f312e32302e31856c696e7578","gasLimit":"0x1c9c380","gasUsed":"0xa79638","logsBloom":"0xb034000008010014411408c080a0018440087220211154100005a1388807241142a2504080034a00111212a47f05008520200000280202a12800538cc06488486a0141989c7800c0c848011f02249661800e08449145b040a252d18082c009000641004052c80102000804ac10901c24032000980010438a01e50a90a0d8008c138c21204040000b20425000833041028000148124c2012d0aa8d1d0548301808228002015184090000224021040d68220100210220480420308455c382a40020130dc42502986080600000115034c0401c81828490410308005610048026b822e10b4228071ba00bdd20140621b2000c02012300808084181ac308200000011","miner":"0x0000000000000000000000000000000000000000","mixHash":"0x31f0c0305fc07a93b1a33da339c79aadbe8d9811c78d2b514cd18d64e1328f25","nonce":"0x0000000000000000","parentHash":"0x2303b55af4add799b19275a491b150c1a03075395f87a7856a4e3327595ed7df","receiptsRoot":"0x99da71b17ae1929db912c3315ebe349d37f2bb600454616fdde0ee90d6dbc59f","sha3Uncles":"0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347","size":"0xea6d","stateRoot":"0xd12bf4cf3941cf48be329a939b13d3403d326841c69cdcc9a9c13ab2f227e904","timestamp":"0x640fdeb0","totalDifficulty":"0xa4a470","transactionsRoot":"0x1ad3212eca045505cfc4cacf675b5fa2e7dc7b9f9cee88191464f97d1c9fbca4","uncles":[],"baseFeePerGas":"0x7ccf990f8"} -`}, - {Name: "Shanghai good tx", OK: true, Data: `{"baseFeePerGas":"0x3fb7c357","difficulty":"0x0","extraData":"0x","gasLimit":"0x1c9c380","gasUsed":"0x18f759","hash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","logsBloom":"0x020010404000001a0000021000000080001100410000100001000010040200980220400000008806200200000100000000000000000000008000000400042000000050000040000112080808800002044000040004042008800480002000000000000002020020000042002400000820000080040000000010200010020010100101212050000008000000008000001010200c80000112010000438040020400000000202400000000002002a0210402000622010000000001700144000040000000002204000000c000410105024010000808000000002004002000000261000000822200200800881000000012500400400000000000000040010000800000","miner":"0x000095e79eac4d76aab57cb2c1f091d553b36ca0","mixHash":"0x5b53dc49cbab268ef9950b1d81b5e36a1b2f1b97aee1b7ff6e4db0e06c29a8b0","nonce":"0x0000000000000000","number":"0x84161e","parentHash":"0x72d92c1498e05952988d4e79a695928a6bcbd37239f8a1734051263b4d3504b8","receiptsRoot":"0xaff90ae18dcc35924a4bddb68d403b8b7812c10c3ea2a114f34105c87d75bcdb","sha3Uncles":"0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347","size":"0x2a51","stateRoot":"0xc56738518b2c7854a640ae25996d2211c9ef0dd2e4dd9e59e9d9cacef39622da","timestamp":"0x64110a5c","totalDifficulty":"0xa4a470","transactions":["0x1e8f148a9aea7d8d16ea6e9446723b8f262e8bcd89c7c961d52046ebd43b4598","0xab5c870f4c367012bd763172afbfbe68fbf35336a66ae41aff3f2c9dbf4ea3f8","0xa81fd92b2d0f0bbd3cc355f869cca3243c98c5e2641db9ecf3eeabb3b13bff6a","0xa92c7b720c08c83f1a0ed7e4c163200e30a3a8c03fcc5a51e685ea20cd0cb577","0x6921b429ad2ec1e97d3457049ad2e893b5a0349beba47ca1c74a9540af75347a","0xf776b2da0b835dde05d0d8b76fd19385d61e7055036cf637f804b36dc94f2384","0x9a08d899cd14ebb930ed59fa774afdb88a22615b3a931e930931ea54d26dc0bc","0x0fe0d97e25d5eb11a33a3e8278584c3780941fc2675bdf8fc547cee3d1fd3b17","0xef47a60f57f177a683c723c658137efab66d311e1c5abbc4d74f653535144d03","0xe23a5b35faae5335adc5aca38c5d633b00438b798c2053104b8df48406c9b141","0xd8cea4ba619b317bc05d58534af73beec6c2548b31b24d4dc61c9bbd29cfa17a","0x79a4b9d90b02c768baaad305f266281213cc75062cbe99a13222cc0c4b509498","0x6790a3bbddbeb21fcb736a59b3775755051c3a6344d8390cf8ca27f2e8a814f0","0x87ec7ace5442db252b5751ffddd38dcb04b088d36b6b0e526ff25607a4293c81","0x40cb487ecffda94f97ce7fc0f7163f2f024235df2c8291169edc80dac063e6d0","0xb76bb3d88c9b30d927c45ccfcf8d5b0054411ac8501ad588822a7d04690cccf6","0x798ebe823209869347c08bd81e04fbf60e9bdfe44b1cc923215182d0cf3d4edb","0xbe68a7e02725f799a65ebb069ccc83a014ac7c40e4119bf7c220a2f6ddfee295","0xc90c3a72efe81331727fcce4b5bd4906066da314ca9a0b44023a6b09ea7e8114","0x619a6cbd43cde074d314c19623bd66d9fb1e13c158d7138775236f798dc1245e","0xca5a56cd77b9e5b0e79020cc6346edf205bc11e901984d805125f28c2e6686e6","0x999c9ddeed67c6ef6fbf02a6e977a6c1b68e18d24814e51643c7157b87a43e0a","0x47c8f5d0b3778e4c34eba7fcc356fa04a5afd954ccf484728e72c002764dd3c4","0x396797ae0ebcdb72ff1f96fd08b6128f78acc7417353f142f1a5facd425a33e6","0x454aa43d6546a6f62246826c16b7a49c6c704238c18802ef0d659922f23a573c","0x317ecb5bd19caa42a69f836d41556ebb0e0e00e1c6cd2dee230e6e6192612527","0xc879285db5ef0a6bce98021584d16f134c1dc0aed8cc988802c4f72ba6877ff6","0xecaa2d6f597608307e5084854854ba6dc1e69395e2abea14f2c6a2fa1d6faf9a","0x4dd69b69a568ff30ae439e2ded72fbd7f2e7aaa345836703663f155c749c5eed"],"transactionsRoot":"0x4a87d0cf5990b1c5bac631583e5965c2ba943858bebb2e07f74d0b697f73821a","uncles":[],"withdrawals":[{"index":"0x1170","validatorIndex":"0x38c2c","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x66edfd65"},{"index":"0x1171","validatorIndex":"0x38c2d","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6cd228e4"},{"index":"0x1172","validatorIndex":"0x38c2e","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x77f3431b"},{"index":"0x1173","validatorIndex":"0x38c2f","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6b61f268"},{"index":"0x1174","validatorIndex":"0x38c30","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6e10bb21"},{"index":"0x1175","validatorIndex":"0x38c31","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6eb115a5"},{"index":"0x1176","validatorIndex":"0x38c32","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x7caead1d"},{"index":"0x1177","validatorIndex":"0x38c33","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x772c0ddf"},{"index":"0x1178","validatorIndex":"0x38c34","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x75930a95"},{"index":"0x1179","validatorIndex":"0x38c35","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x76a4db09"},{"index":"0x117a","validatorIndex":"0x38c36","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x7e692b27"},{"index":"0x117b","validatorIndex":"0x38c37","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x72038ae6"},{"index":"0x117c","validatorIndex":"0x38c38","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6ccce352"},{"index":"0x117d","validatorIndex":"0x38c39","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x79ef6898"},{"index":"0x117e","validatorIndex":"0x38c3a","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6d58977d"},{"index":"0x117f","validatorIndex":"0x38c3b","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x76f7d208"}],"withdrawalsRoot":"0xbe712c930a0665264b025ced87cc7839eef95a3cbc26dadc93e9e185a350ad28"} -`}, - {Name: "Shanghai bad withdrawals root", OK: false, Data: `{"baseFeePerGas":"0x3fb7c357","difficulty":"0x0","extraData":"0x","gasLimit":"0x1c9c380","gasUsed":"0x18f759","hash":"0xa16c6bcda4fdca88b5761965c4d724f7afc6a6900d9051a204e544870adb3452","logsBloom":"0x020010404000001a0000021000000080001100410000100001000010040200980220400000008806200200000100000000000000000000008000000400042000000050000040000112080808800002044000040004042008800480002000000000000002020020000042002400000820000080040000000010200010020010100101212050000008000000008000001010200c80000112010000438040020400000000202400000000002002a0210402000622010000000001700144000040000000002204000000c000410105024010000808000000002004002000000261000000822200200800881000000012500400400000000000000040010000800000","miner":"0x000095e79eac4d76aab57cb2c1f091d553b36ca0","mixHash":"0x5b53dc49cbab268ef9950b1d81b5e36a1b2f1b97aee1b7ff6e4db0e06c29a8b0","nonce":"0x0000000000000000","number":"0x84161e","parentHash":"0x72d92c1498e05952988d4e79a695928a6bcbd37239f8a1734051263b4d3504b8","receiptsRoot":"0xaff90ae18dcc35924a4bddb68d403b8b7812c10c3ea2a114f34105c87d75bcdb","sha3Uncles":"0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347","size":"0x2a51","stateRoot":"0xc56738518b2c7854a640ae25996d2211c9ef0dd2e4dd9e59e9d9cacef39622da","timestamp":"0x64110a5c","totalDifficulty":"0xa4a470","transactions":["0x1e8f148a9aea7d8d16ea6e9446723b8f262e8bcd89c7c961d52046ebd43b4598","0xab5c870f4c367012bd763172afbfbe68fbf35336a66ae41aff3f2c9dbf4ea3f8","0xa81fd92b2d0f0bbd3cc355f869cca3243c98c5e2641db9ecf3eeabb3b13bff6a","0xa92c7b720c08c83f1a0ed7e4c163200e30a3a8c03fcc5a51e685ea20cd0cb577","0x6921b429ad2ec1e97d3457049ad2e893b5a0349beba47ca1c74a9540af75347a","0xf776b2da0b835dde05d0d8b76fd19385d61e7055036cf637f804b36dc94f2384","0x9a08d899cd14ebb930ed59fa774afdb88a22615b3a931e930931ea54d26dc0bc","0x0fe0d97e25d5eb11a33a3e8278584c3780941fc2675bdf8fc547cee3d1fd3b17","0xef47a60f57f177a683c723c658137efab66d311e1c5abbc4d74f653535144d03","0xe23a5b35faae5335adc5aca38c5d633b00438b798c2053104b8df48406c9b141","0xd8cea4ba619b317bc05d58534af73beec6c2548b31b24d4dc61c9bbd29cfa17a","0x79a4b9d90b02c768baaad305f266281213cc75062cbe99a13222cc0c4b509498","0x6790a3bbddbeb21fcb736a59b3775755051c3a6344d8390cf8ca27f2e8a814f0","0x87ec7ace5442db252b5751ffddd38dcb04b088d36b6b0e526ff25607a4293c81","0x40cb487ecffda94f97ce7fc0f7163f2f024235df2c8291169edc80dac063e6d0","0xb76bb3d88c9b30d927c45ccfcf8d5b0054411ac8501ad588822a7d04690cccf6","0x798ebe823209869347c08bd81e04fbf60e9bdfe44b1cc923215182d0cf3d4edb","0xbe68a7e02725f799a65ebb069ccc83a014ac7c40e4119bf7c220a2f6ddfee295","0xc90c3a72efe81331727fcce4b5bd4906066da314ca9a0b44023a6b09ea7e8114","0x619a6cbd43cde074d314c19623bd66d9fb1e13c158d7138775236f798dc1245e","0xca5a56cd77b9e5b0e79020cc6346edf205bc11e901984d805125f28c2e6686e6","0x999c9ddeed67c6ef6fbf02a6e977a6c1b68e18d24814e51643c7157b87a43e0a","0x47c8f5d0b3778e4c34eba7fcc356fa04a5afd954ccf484728e72c002764dd3c4","0x396797ae0ebcdb72ff1f96fd08b6128f78acc7417353f142f1a5facd425a33e6","0x454aa43d6546a6f62246826c16b7a49c6c704238c18802ef0d659922f23a573c","0x317ecb5bd19caa42a69f836d41556ebb0e0e00e1c6cd2dee230e6e6192612527","0xc879285db5ef0a6bce98021584d16f134c1dc0aed8cc988802c4f72ba6877ff6","0xecaa2d6f597608307e5084854854ba6dc1e69395e2abea14f2c6a2fa1d6faf9a","0x4dd69b69a568ff30ae439e2ded72fbd7f2e7aaa345836703663f155c749c5eed"],"transactionsRoot":"0x4a87d0cf5990b1c5bac631583e5965c2ba943858bebb2e07f74d0b697f73821a","uncles":[],"withdrawals":[{"index":"0x1170","validatorIndex":"0x38c2c","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x66edfd65"},{"index":"0x1171","validatorIndex":"0x38c2d","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6cd228e4"},{"index":"0x1172","validatorIndex":"0x38c2e","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x77f3431b"},{"index":"0x1173","validatorIndex":"0x38c2f","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6b61f268"},{"index":"0x1174","validatorIndex":"0x38c30","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6e10bb21"},{"index":"0x1175","validatorIndex":"0x38c31","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6eb115a5"},{"index":"0x1176","validatorIndex":"0x38c32","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x7caead1d"},{"index":"0x1177","validatorIndex":"0x38c33","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x772c0ddf"},{"index":"0x1178","validatorIndex":"0x38c34","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x75930a95"},{"index":"0x1179","validatorIndex":"0x38c35","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x76a4db09"},{"index":"0x117a","validatorIndex":"0x38c36","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x7e692b27"},{"index":"0x117b","validatorIndex":"0x38c37","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x72038ae6"},{"index":"0x117c","validatorIndex":"0x38c38","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6ccce352"},{"index":"0x117d","validatorIndex":"0x38c39","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x79ef6898"},{"index":"0x117e","validatorIndex":"0x38c3a","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x6d58977d"},{"index":"0x117f","validatorIndex":"0x38c3b","address":"0x8f0844fd51e31ff6bf5babe21dccf7328e19fd9f","amount":"0x76f7d208"}],"withdrawalsRoot":"0xbe712c930a0665264b025ced87cc7839eef95a3cbc26dadc93e9e185a350ad27"} -`}, +//go:embed testdata +var blocksTestdata embed.FS + +type testMetadata struct { + Name string `json:"name"` + Fail bool `json:"fail,omitempty"` + Reason string `json:"reason,omitempty"` +} + +func readJsonTestdata(t *testing.T, name string, dest any) { + f, err := blocksTestdata.Open(name) + require.NoError(t, err, "must open %q", name) + require.NoError(t, json.NewDecoder(f).Decode(dest), "must json-decode %q", name) + require.NoError(t, f.Close(), "must close %q", name) +} + +func TestBlockHeaderJSON(t *testing.T) { + headersDir, err := blocksTestdata.ReadDir("testdata/data/headers") + require.NoError(t, err) + + for _, entry := range headersDir { + if !strings.HasSuffix(entry.Name(), "_metadata.json") { + continue + } + + var metadata testMetadata + readJsonTestdata(t, "testdata/data/headers/"+entry.Name(), &metadata) + t.Run(metadata.Name, func(t *testing.T) { + var header rpcHeader + readJsonTestdata(t, "testdata/data/headers/"+strings.Replace(entry.Name(), "_metadata.json", "_data.json", 1), &header) + + h := header.computeBlockHash() + if metadata.Fail { + require.NotEqual(t, h, header.Hash, "expecting verification error") + } else { + require.Equal(t, h, header.Hash, "blockhash should verify ok") + } + }) } - for _, testCase := range testCases { - var x rpcHeader - require.NoError(t, json.Unmarshal([]byte(testCase.Data), &x)) - h := x.computeBlockHash() - if testCase.OK { - require.Equal(t, h, x.Hash, "blockhash should verify ok") - } else { - require.NotEqual(t, h, x.Hash, "expecting verification error") +} + +func TestBlockJSON(t *testing.T) { + blocksDir, err := blocksTestdata.ReadDir("testdata/data/blocks") + require.NoError(t, err) + + for _, entry := range blocksDir { + if !strings.HasSuffix(entry.Name(), "_metadata.json") { + continue } + + var metadata testMetadata + readJsonTestdata(t, "testdata/data/blocks/"+entry.Name(), &metadata) + t.Run(metadata.Name, func(t *testing.T) { + var block rpcBlock + readJsonTestdata(t, "testdata/data/blocks/"+strings.Replace(entry.Name(), "_metadata.json", "_data.json", 1), &block) + + err := block.verify() + if metadata.Fail { + require.NotNil(t, err, "expecting verification error") + require.ErrorContains(t, err, metadata.Reason, "validation failed for incorrect reason") + } else { + require.NoError(t, err, "verification should pass") + } + }) } } diff --git a/op-service/tasks/tasks.go b/op-service/tasks/tasks.go new file mode 100644 index 0000000000000..67675995b2c4e --- /dev/null +++ b/op-service/tasks/tasks.go @@ -0,0 +1,32 @@ +package tasks + +import ( + "fmt" + "runtime/debug" + + "golang.org/x/sync/errgroup" +) + +// Group is a tasks group, which can at any point be awaited to complete. +// Tasks in the group are run in separate go routines. +// If a task panics, the panic is recovered with HandleCrit. +type Group struct { + errGroup errgroup.Group + HandleCrit func(err error) +} + +func (t *Group) Go(fn func() error) { + t.errGroup.Go(func() error { + defer func() { + if err := recover(); err != nil { + debug.PrintStack() + t.HandleCrit(fmt.Errorf("panic: %v", err)) + } + }() + return fn() + }) +} + +func (t *Group) Wait() error { + return t.errGroup.Wait() +} diff --git a/op-service/testutils/l1info.go b/op-service/testutils/l1info.go index 0109f5e1650b7..249beb4df2153 100644 --- a/op-service/testutils/l1info.go +++ b/op-service/testutils/l1info.go @@ -23,6 +23,7 @@ type MockBlockInfo struct { InfoBaseFee *big.Int InfoReceiptRoot common.Hash InfoGasUsed uint64 + InfoGasLimit uint64 InfoHeaderRLP []byte } @@ -66,6 +67,10 @@ func (l *MockBlockInfo) GasUsed() uint64 { return l.InfoGasUsed } +func (l *MockBlockInfo) GasLimit() uint64 { + return l.InfoGasLimit +} + func (l *MockBlockInfo) ID() eth.BlockID { return eth.BlockID{Hash: l.InfoHash, Number: l.InfoNum} } diff --git a/op-service/testutils/mock_l2.go b/op-service/testutils/mock_l2.go index 18f5f4c82b1c3..6b01b401a4022 100644 --- a/op-service/testutils/mock_l2.go +++ b/op-service/testutils/mock_l2.go @@ -3,9 +3,8 @@ package testutils import ( "context" - "github.com/ethereum/go-ethereum/common" - "github.com/ethereum-optimism/optimism/op-service/eth" + "github.com/ethereum/go-ethereum/common" ) type MockL2Client struct { @@ -13,7 +12,8 @@ type MockL2Client struct { } func (c *MockL2Client) L2BlockRefByLabel(ctx context.Context, label eth.BlockLabel) (eth.L2BlockRef, error) { - return c.Mock.MethodCalled("L2BlockRefByLabel", label).Get(0).(eth.L2BlockRef), nil + out := c.Mock.MethodCalled("L2BlockRefByLabel", label) + return out[0].(eth.L2BlockRef), *out[1].(*error) } func (m *MockL2Client) ExpectL2BlockRefByLabel(label eth.BlockLabel, ref eth.L2BlockRef, err error) { @@ -21,7 +21,8 @@ func (m *MockL2Client) ExpectL2BlockRefByLabel(label eth.BlockLabel, ref eth.L2B } func (c *MockL2Client) L2BlockRefByNumber(ctx context.Context, num uint64) (eth.L2BlockRef, error) { - return c.Mock.MethodCalled("L2BlockRefByNumber", num).Get(0).(eth.L2BlockRef), nil + out := c.Mock.MethodCalled("L2BlockRefByNumber", num) + return out[0].(eth.L2BlockRef), *out[1].(*error) } func (m *MockL2Client) ExpectL2BlockRefByNumber(num uint64, ref eth.L2BlockRef, err error) { @@ -29,7 +30,8 @@ func (m *MockL2Client) ExpectL2BlockRefByNumber(num uint64, ref eth.L2BlockRef, } func (c *MockL2Client) L2BlockRefByHash(ctx context.Context, hash common.Hash) (eth.L2BlockRef, error) { - return c.Mock.MethodCalled("L2BlockRefByHash", hash).Get(0).(eth.L2BlockRef), nil + out := c.Mock.MethodCalled("L2BlockRefByHash", hash) + return out[0].(eth.L2BlockRef), *out[1].(*error) } func (m *MockL2Client) ExpectL2BlockRefByHash(hash common.Hash, ref eth.L2BlockRef, err error) { @@ -37,7 +39,8 @@ func (m *MockL2Client) ExpectL2BlockRefByHash(hash common.Hash, ref eth.L2BlockR } func (m *MockL2Client) SystemConfigByL2Hash(ctx context.Context, hash common.Hash) (eth.SystemConfig, error) { - return m.Mock.MethodCalled("SystemConfigByL2Hash", hash).Get(0).(eth.SystemConfig), nil + out := m.Mock.MethodCalled("SystemConfigByL2Hash", hash) + return out[0].(eth.SystemConfig), *out[1].(*error) } func (m *MockL2Client) ExpectSystemConfigByL2Hash(hash common.Hash, cfg eth.SystemConfig, err error) { @@ -45,7 +48,8 @@ func (m *MockL2Client) ExpectSystemConfigByL2Hash(hash common.Hash, cfg eth.Syst } func (m *MockL2Client) OutputV0AtBlock(ctx context.Context, blockHash common.Hash) (*eth.OutputV0, error) { - return m.Mock.MethodCalled("OutputV0AtBlock", blockHash).Get(0).(*eth.OutputV0), nil + out := m.Mock.MethodCalled("OutputV0AtBlock", blockHash) + return out[0].(*eth.OutputV0), *out[1].(*error) } func (m *MockL2Client) ExpectOutputV0AtBlock(blockHash common.Hash, output *eth.OutputV0, err error) { diff --git a/op-service/testutils/random.go b/op-service/testutils/random.go index f2d074aad9a2f..234dc1c64211c 100644 --- a/op-service/testutils/random.go +++ b/op-service/testutils/random.go @@ -141,49 +141,72 @@ func RandomTo(rng *rand.Rand) *common.Address { } func RandomTx(rng *rand.Rand, baseFee *big.Int, signer types.Signer) *types.Transaction { - gas := params.TxGas + uint64(rng.Int63n(2_000_000)) - key := InsecureRandomKey(rng) - tip := big.NewInt(rng.Int63n(10 * params.GWei)) - txTypeList := []int{types.LegacyTxType, types.AccessListTxType, types.DynamicFeeTxType} txType := txTypeList[rng.Intn(len(txTypeList))] - var txData types.TxData + var tx *types.Transaction switch txType { case types.LegacyTxType: - txData = &types.LegacyTx{ - Nonce: rng.Uint64(), - GasPrice: new(big.Int).SetUint64(rng.Uint64()), - Gas: gas, - To: RandomTo(rng), - Value: RandomETH(rng, 10), - Data: RandomData(rng, rng.Intn(1000)), - } + tx = RandomLegacyTx(rng, signer) case types.AccessListTxType: - txData = &types.AccessListTx{ - ChainID: signer.ChainID(), - Nonce: rng.Uint64(), - GasPrice: new(big.Int).SetUint64(rng.Uint64()), - Gas: gas, - To: RandomTo(rng), - Value: RandomETH(rng, 10), - Data: RandomData(rng, rng.Intn(1000)), - AccessList: nil, - } + tx = RandomAccessListTx(rng, signer) case types.DynamicFeeTxType: - txData = &types.DynamicFeeTx{ - ChainID: signer.ChainID(), - Nonce: rng.Uint64(), - GasTipCap: tip, - GasFeeCap: new(big.Int).Add(baseFee, tip), - Gas: gas, - To: RandomTo(rng), - Value: RandomETH(rng, 10), - Data: RandomData(rng, rng.Intn(1000)), - AccessList: nil, - } + tx = RandomDynamicFeeTxWithBaseFee(rng, baseFee, signer) default: panic("invalid tx type") } + return tx +} + +func RandomLegacyTx(rng *rand.Rand, signer types.Signer) *types.Transaction { + key := InsecureRandomKey(rng) + txData := &types.LegacyTx{ + Nonce: rng.Uint64(), + GasPrice: new(big.Int).SetUint64(rng.Uint64()), + Gas: params.TxGas + uint64(rng.Int63n(2_000_000)), + To: RandomTo(rng), + Value: RandomETH(rng, 10), + Data: RandomData(rng, rng.Intn(1000)), + } + tx, err := types.SignNewTx(key, signer, txData) + if err != nil { + panic(err) + } + return tx +} + +func RandomAccessListTx(rng *rand.Rand, signer types.Signer) *types.Transaction { + key := InsecureRandomKey(rng) + txData := &types.AccessListTx{ + ChainID: signer.ChainID(), + Nonce: rng.Uint64(), + GasPrice: new(big.Int).SetUint64(rng.Uint64()), + Gas: params.TxGas + uint64(rng.Int63n(2_000_000)), + To: RandomTo(rng), + Value: RandomETH(rng, 10), + Data: RandomData(rng, rng.Intn(1000)), + AccessList: nil, + } + tx, err := types.SignNewTx(key, signer, txData) + if err != nil { + panic(err) + } + return tx +} + +func RandomDynamicFeeTxWithBaseFee(rng *rand.Rand, baseFee *big.Int, signer types.Signer) *types.Transaction { + key := InsecureRandomKey(rng) + tip := big.NewInt(rng.Int63n(10 * params.GWei)) + txData := &types.DynamicFeeTx{ + ChainID: signer.ChainID(), + Nonce: rng.Uint64(), + GasTipCap: tip, + GasFeeCap: new(big.Int).Add(baseFee, tip), + Gas: params.TxGas + uint64(rng.Int63n(2_000_000)), + To: RandomTo(rng), + Value: RandomETH(rng, 10), + Data: RandomData(rng, rng.Intn(1000)), + AccessList: nil, + } tx, err := types.SignNewTx(key, signer, txData) if err != nil { panic(err) @@ -191,6 +214,11 @@ func RandomTx(rng *rand.Rand, baseFee *big.Int, signer types.Signer) *types.Tran return tx } +func RandomDynamicFeeTx(rng *rand.Rand, signer types.Signer) *types.Transaction { + baseFee := new(big.Int).SetUint64(rng.Uint64()) + return RandomDynamicFeeTxWithBaseFee(rng, baseFee, signer) +} + func RandomReceipt(rng *rand.Rand, signer types.Signer, tx *types.Transaction, txIndex uint64, cumulativeGasUsed uint64) *types.Receipt { gasUsed := params.TxGas + uint64(rng.Int63n(int64(tx.Gas()-params.TxGas+1))) logs := make([]*types.Log, rng.Intn(10)) @@ -296,6 +324,7 @@ func RandomOutputResponse(rng *rand.Rand) *eth.OutputResponse { UnsafeL2: RandomL2BlockRef(rng), SafeL2: RandomL2BlockRef(rng), FinalizedL2: RandomL2BlockRef(rng), + PendingSafeL2: RandomL2BlockRef(rng), EngineSyncTarget: RandomL2BlockRef(rng), }, } diff --git a/op-service/txmgr/cli.go b/op-service/txmgr/cli.go index cf8419ce60ac3..30f4225ecc459 100644 --- a/op-service/txmgr/cli.go +++ b/op-service/txmgr/cli.go @@ -26,6 +26,7 @@ const ( // TxMgr Flags (new + legacy + some shared flags) NumConfirmationsFlagName = "num-confirmations" SafeAbortNonceTooLowCountFlagName = "safe-abort-nonce-too-low-count" + FeeLimitMultiplierFlagName = "fee-limit-multiplier" ResubmissionTimeoutFlagName = "resubmission-timeout" NetworkTimeoutFlagName = "network-timeout" TxSendTimeoutFlagName = "txmgr.send-timeout" @@ -51,6 +52,7 @@ var ( type DefaultFlagValues struct { NumConfirmations uint64 SafeAbortNonceTooLowCount uint64 + FeeLimitMultiplier uint64 ResubmissionTimeout time.Duration NetworkTimeout time.Duration TxSendTimeout time.Duration @@ -62,6 +64,7 @@ var ( DefaultBatcherFlagValues = DefaultFlagValues{ NumConfirmations: uint64(10), SafeAbortNonceTooLowCount: uint64(3), + FeeLimitMultiplier: uint64(5), ResubmissionTimeout: 48 * time.Second, NetworkTimeout: 10 * time.Second, TxSendTimeout: 0 * time.Second, @@ -71,6 +74,7 @@ var ( DefaultChallengerFlagValues = DefaultFlagValues{ NumConfirmations: uint64(3), SafeAbortNonceTooLowCount: uint64(3), + FeeLimitMultiplier: uint64(5), ResubmissionTimeout: 24 * time.Second, NetworkTimeout: 10 * time.Second, TxSendTimeout: 2 * time.Minute, @@ -115,6 +119,12 @@ func CLIFlagsWithDefaults(envPrefix string, defaults DefaultFlagValues) []cli.Fl Value: defaults.SafeAbortNonceTooLowCount, EnvVars: prefixEnvVars("SAFE_ABORT_NONCE_TOO_LOW_COUNT"), }, + &cli.Uint64Flag{ + Name: FeeLimitMultiplierFlagName, + Usage: "The multiplier applied to fee suggestions to put a hard limit on fee increases", + Value: defaults.FeeLimitMultiplier, + EnvVars: prefixEnvVars("TXMGR_FEE_LIMIT_MULTIPLIER"), + }, &cli.DurationFlag{ Name: ResubmissionTimeoutFlagName, Usage: "Duration we will wait before resubmitting a transaction to L1", @@ -158,6 +168,7 @@ type CLIConfig struct { SignerCLIConfig opsigner.CLIConfig NumConfirmations uint64 SafeAbortNonceTooLowCount uint64 + FeeLimitMultiplier uint64 ResubmissionTimeout time.Duration ReceiptQueryInterval time.Duration NetworkTimeout time.Duration @@ -170,6 +181,7 @@ func NewCLIConfig(l1RPCURL string, defaults DefaultFlagValues) CLIConfig { L1RPCURL: l1RPCURL, NumConfirmations: defaults.NumConfirmations, SafeAbortNonceTooLowCount: defaults.SafeAbortNonceTooLowCount, + FeeLimitMultiplier: defaults.FeeLimitMultiplier, ResubmissionTimeout: defaults.ResubmissionTimeout, NetworkTimeout: defaults.NetworkTimeout, TxSendTimeout: defaults.TxSendTimeout, @@ -189,6 +201,9 @@ func (m CLIConfig) Check() error { if m.NetworkTimeout == 0 { return errors.New("must provide NetworkTimeout") } + if m.FeeLimitMultiplier == 0 { + return errors.New("must provide FeeLimitMultiplier") + } if m.ResubmissionTimeout == 0 { return errors.New("must provide ResubmissionTimeout") } @@ -218,6 +233,7 @@ func ReadCLIConfig(ctx *cli.Context) CLIConfig { SignerCLIConfig: opsigner.ReadCLIConfig(ctx), NumConfirmations: ctx.Uint64(NumConfirmationsFlagName), SafeAbortNonceTooLowCount: ctx.Uint64(SafeAbortNonceTooLowCountFlagName), + FeeLimitMultiplier: ctx.Uint64(FeeLimitMultiplierFlagName), ResubmissionTimeout: ctx.Duration(ResubmissionTimeoutFlagName), ReceiptQueryInterval: ctx.Duration(ReceiptQueryIntervalFlagName), NetworkTimeout: ctx.Duration(NetworkTimeoutFlagName), @@ -261,6 +277,7 @@ func NewConfig(cfg CLIConfig, l log.Logger) (Config, error) { return Config{ Backend: l1, ResubmissionTimeout: cfg.ResubmissionTimeout, + FeeLimitMultiplier: cfg.FeeLimitMultiplier, ChainID: chainID, TxSendTimeout: cfg.TxSendTimeout, TxNotInMempoolTimeout: cfg.TxNotInMempoolTimeout, @@ -282,6 +299,9 @@ type Config struct { // attempted. ResubmissionTimeout time.Duration + // The multiplier applied to fee suggestions to put a hard limit on fee increases. + FeeLimitMultiplier uint64 + // ChainID is the chain ID of the L1 chain. ChainID *big.Int @@ -326,6 +346,9 @@ func (m Config) Check() error { if m.NetworkTimeout == 0 { return errors.New("must provide NetworkTimeout") } + if m.FeeLimitMultiplier == 0 { + return errors.New("must provide FeeLimitMultiplier") + } if m.ResubmissionTimeout == 0 { return errors.New("must provide ResubmissionTimeout") } diff --git a/op-service/txmgr/mocks/TxManager.go b/op-service/txmgr/mocks/TxManager.go index 75058e3dabc50..7c29710046191 100644 --- a/op-service/txmgr/mocks/TxManager.go +++ b/op-service/txmgr/mocks/TxManager.go @@ -4,12 +4,9 @@ package mocks import ( context "context" - big "math/big" common "github.com/ethereum/go-ethereum/common" - ethereum "github.com/ethereum/go-ethereum" - mock "github.com/stretchr/testify/mock" txmgr "github.com/ethereum-optimism/optimism/op-service/txmgr" @@ -46,32 +43,6 @@ func (_m *TxManager) BlockNumber(ctx context.Context) (uint64, error) { return r0, r1 } -// Call provides a mock function with given fields: ctx, msg, blockNumber -func (_m *TxManager) Call(ctx context.Context, msg ethereum.CallMsg, blockNumber *big.Int) ([]byte, error) { - ret := _m.Called(ctx, msg, blockNumber) - - var r0 []byte - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, ethereum.CallMsg, *big.Int) ([]byte, error)); ok { - return rf(ctx, msg, blockNumber) - } - if rf, ok := ret.Get(0).(func(context.Context, ethereum.CallMsg, *big.Int) []byte); ok { - r0 = rf(ctx, msg, blockNumber) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).([]byte) - } - } - - if rf, ok := ret.Get(1).(func(context.Context, ethereum.CallMsg, *big.Int) error); ok { - r1 = rf(ctx, msg, blockNumber) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - // From provides a mock function with given fields: func (_m *TxManager) From() common.Address { ret := _m.Called() diff --git a/op-service/txmgr/send_state.go b/op-service/txmgr/send_state.go index f6d9c202737a8..e1878c64f9dde 100644 --- a/op-service/txmgr/send_state.go +++ b/op-service/txmgr/send_state.go @@ -26,6 +26,9 @@ type SendState struct { // Counts of the different types of errors successFullPublishCount uint64 // nil error => tx made it to the mempool safeAbortNonceTooLowCount uint64 // nonce too low error + + // Miscellaneous tracking + bumpCount int // number of times we have bumped the gas price } // NewSendStateWithNow creates a new send state with the provided clock. diff --git a/op-service/txmgr/txmgr.go b/op-service/txmgr/txmgr.go index b613faa406822..0a2109af8647a 100644 --- a/op-service/txmgr/txmgr.go +++ b/op-service/txmgr/txmgr.go @@ -24,9 +24,6 @@ import ( const ( // Geth requires a minimum fee bump of 10% for tx resubmission priceBump int64 = 10 - - // The multiplier applied to fee suggestions to put a hard limit on fee increases - feeLimitMultiplier = 5 ) // new = old * (100 + priceBump) / 100 @@ -46,10 +43,6 @@ type TxManager interface { // NOTE: Send can be called concurrently, the nonce will be managed internally. Send(ctx context.Context, candidate TxCandidate) (*types.Receipt, error) - // Call is used to call a contract. - // Internally, it uses the [ethclient.Client.CallContract] method. - Call(ctx context.Context, msg ethereum.CallMsg, blockNumber *big.Int) ([]byte, error) - // From returns the sending address associated with the instance of the transaction manager. // It is static for a single instance of a TxManager. From() common.Address @@ -172,12 +165,6 @@ func (m *SimpleTxManager) Send(ctx context.Context, candidate TxCandidate) (*typ return receipt, err } -// Call is used to call a contract. -// Internally, it uses the [ethclient.Client.CallContract] method. -func (m *SimpleTxManager) Call(ctx context.Context, msg ethereum.CallMsg, blockNumber *big.Int) ([]byte, error) { - return m.backend.CallContract(ctx, msg, blockNumber) -} - // send performs the actual transaction creation and sending. func (m *SimpleTxManager) send(ctx context.Context, candidate TxCandidate) (*types.Receipt, error) { if m.cfg.TxSendTimeout != 0 { @@ -241,23 +228,15 @@ func (m *SimpleTxManager) craftTx(ctx context.Context, candidate TxCandidate) (* rawTx.Gas = gas } - // Avoid bumping the nonce if the gas estimation fails. - nonce, err := m.nextNonce(ctx) - if err != nil { - return nil, err - } - rawTx.Nonce = nonce - - ctx, cancel := context.WithTimeout(ctx, m.cfg.NetworkTimeout) - defer cancel() - return m.cfg.Signer(ctx, m.cfg.From, types.NewTx(rawTx)) + return m.signWithNextNonce(ctx, rawTx) } -// nextNonce returns a nonce to use for the next transaction. It uses -// eth_getTransactionCount with "latest" once, and then subsequent calls simply -// increment this number. If the transaction manager is reset, it will query the -// eth_getTransactionCount nonce again. -func (m *SimpleTxManager) nextNonce(ctx context.Context) (uint64, error) { +// signWithNextNonce returns a signed transaction with the next available nonce. +// The nonce is fetched once using eth_getTransactionCount with "latest", and +// then subsequent calls simply increment this number. If the transaction manager +// is reset, it will query the eth_getTransactionCount nonce again. If signing +// fails, the nonce is not incremented. +func (m *SimpleTxManager) signWithNextNonce(ctx context.Context, rawTx *types.DynamicFeeTx) (*types.Transaction, error) { m.nonceLock.Lock() defer m.nonceLock.Unlock() @@ -268,15 +247,25 @@ func (m *SimpleTxManager) nextNonce(ctx context.Context) (uint64, error) { nonce, err := m.backend.NonceAt(childCtx, m.cfg.From, nil) if err != nil { m.metr.RPCError() - return 0, fmt.Errorf("failed to get nonce: %w", err) + return nil, fmt.Errorf("failed to get nonce: %w", err) } m.nonce = &nonce } else { *m.nonce++ } - m.metr.RecordNonce(*m.nonce) - return *m.nonce, nil + rawTx.Nonce = *m.nonce + ctx, cancel := context.WithTimeout(ctx, m.cfg.NetworkTimeout) + defer cancel() + tx, err := m.cfg.Signer(ctx, m.cfg.From, types.NewTx(rawTx)) + if err != nil { + // decrement the nonce, so we can retry signing with the same nonce next time + // signWithNextNonce is called + *m.nonce-- + } else { + m.metr.RecordNonce(*m.nonce) + } + return tx, err } // resetNonce resets the internal nonce tracking. This is called if any pending send @@ -297,19 +286,26 @@ func (m *SimpleTxManager) sendTx(ctx context.Context, tx *types.Transaction) (*t sendState := NewSendState(m.cfg.SafeAbortNonceTooLowCount, m.cfg.TxNotInMempoolTimeout) receiptChan := make(chan *types.Receipt, 1) - sendTxAsync := func(tx *types.Transaction) { - defer wg.Done() - m.publishAndWaitForTx(ctx, tx, sendState, receiptChan) + publishAndWait := func(tx *types.Transaction, bumpFees bool) *types.Transaction { + wg.Add(1) + tx, published := m.publishTx(ctx, tx, sendState, bumpFees) + if published { + go func() { + defer wg.Done() + m.waitForTx(ctx, tx, sendState, receiptChan) + }() + } else { + wg.Done() + } + return tx } // Immediately publish a transaction before starting the resumbission loop - wg.Add(1) - go sendTxAsync(tx) + tx = publishAndWait(tx, false) ticker := time.NewTicker(m.cfg.ResubmissionTimeout) defer ticker.Stop() - bumpCounter := 0 for { select { case <-ticker.C: @@ -322,73 +318,95 @@ func (m *SimpleTxManager) sendTx(ctx context.Context, tx *types.Transaction) (*t m.l.Warn("Aborting transaction submission") return nil, errors.New("aborted transaction sending") } - // Increase the gas price & submit the new transaction - newTx, err := m.increaseGasPrice(ctx, tx) - if err != nil || sendState.IsWaitingForConfirmation() { - // there is a chance the previous tx goes into "waiting for confirmation" state - // during the increaseGasPrice call. In some (but not all) cases increaseGasPrice - // will error out during gas estimation. In either case we should continue waiting - // rather than resubmit the tx. - continue - } - tx = newTx - wg.Add(1) - bumpCounter += 1 - go sendTxAsync(tx) + tx = publishAndWait(tx, true) case <-ctx.Done(): return nil, ctx.Err() case receipt := <-receiptChan: - m.metr.RecordGasBumpCount(bumpCounter) + m.metr.RecordGasBumpCount(sendState.bumpCount) m.metr.TxConfirmed(receipt) return receipt, nil } } } -// publishAndWaitForTx publishes the transaction to the transaction pool and then waits for it with [waitMined]. -// It should be called in a new go-routine. It will send the receipt to receiptChan in a non-blocking way if a receipt is found -// for the transaction. -func (m *SimpleTxManager) publishAndWaitForTx(ctx context.Context, tx *types.Transaction, sendState *SendState, receiptChan chan *types.Receipt) { - log := m.l.New("hash", tx.Hash(), "nonce", tx.Nonce(), "gasTipCap", tx.GasTipCap(), "gasFeeCap", tx.GasFeeCap()) - log.Info("Publishing transaction") +// publishTx publishes the transaction to the transaction pool. If it receives any underpriced errors +// it will bump the fees and retry. +// Returns the latest fee bumped tx, and a boolean indicating whether the tx was sent or not +func (m *SimpleTxManager) publishTx(ctx context.Context, tx *types.Transaction, sendState *SendState, bumpFeesImmediately bool) (*types.Transaction, bool) { + updateLogFields := func(tx *types.Transaction) log.Logger { + return m.l.New("hash", tx.Hash(), "nonce", tx.Nonce(), "gasTipCap", tx.GasTipCap(), "gasFeeCap", tx.GasFeeCap()) + } + l := updateLogFields(tx) - cCtx, cancel := context.WithTimeout(ctx, m.cfg.NetworkTimeout) - defer cancel() - t := time.Now() - err := m.backend.SendTransaction(cCtx, tx) - sendState.ProcessSendError(err) + l.Info("Publishing transaction") + + for { + if bumpFeesImmediately { + newTx, err := m.increaseGasPrice(ctx, tx) + if err != nil { + l.Error("unable to increase gas", "err", err) + m.metr.TxPublished("bump_failed") + return tx, false + } + tx = newTx + sendState.bumpCount++ + l = updateLogFields(tx) + } + bumpFeesImmediately = true // bump fees next loop + + if sendState.IsWaitingForConfirmation() { + // there is a chance the previous tx goes into "waiting for confirmation" state + // during the increaseGasPrice call; continue waiting rather than resubmit the tx + return tx, false + } + + cCtx, cancel := context.WithTimeout(ctx, m.cfg.NetworkTimeout) + err := m.backend.SendTransaction(cCtx, tx) + cancel() + sendState.ProcessSendError(err) + + if err == nil { + m.metr.TxPublished("") + log.Info("Transaction successfully published") + return tx, true + } - // Properly log & exit if there is an error - if err != nil { switch { case errStringMatch(err, core.ErrNonceTooLow): - log.Warn("nonce too low", "err", err) + l.Warn("nonce too low", "err", err) m.metr.TxPublished("nonce_to_low") case errStringMatch(err, context.Canceled): m.metr.RPCError() - log.Warn("transaction send cancelled", "err", err) + l.Warn("transaction send cancelled", "err", err) m.metr.TxPublished("context_cancelled") case errStringMatch(err, txpool.ErrAlreadyKnown): - log.Warn("resubmitted already known transaction", "err", err) + l.Warn("resubmitted already known transaction", "err", err) m.metr.TxPublished("tx_already_known") case errStringMatch(err, txpool.ErrReplaceUnderpriced): - log.Warn("transaction replacement is underpriced", "err", err) + l.Warn("transaction replacement is underpriced", "err", err) m.metr.TxPublished("tx_replacement_underpriced") + continue // retry with fee bump case errStringMatch(err, txpool.ErrUnderpriced): - log.Warn("transaction is underpriced", "err", err) + l.Warn("transaction is underpriced", "err", err) m.metr.TxPublished("tx_underpriced") + continue // retry with fee bump default: m.metr.RPCError() - log.Error("unable to publish transaction", "err", err) + l.Error("unable to publish transaction", "err", err) m.metr.TxPublished("unknown_error") } - return + + // on non-underpriced error return immediately; will retry on next resubmission timeout + return tx, false } - m.metr.TxPublished("") +} - log.Info("Transaction successfully published") +// waitForTx calls waitMined, and then sends the receipt to receiptChan in a non-blocking way if a receipt is found +// for the transaction. It should be called in a separate goroutine. +func (m *SimpleTxManager) waitForTx(ctx context.Context, tx *types.Transaction, sendState *SendState, receiptChan chan *types.Receipt) { + t := time.Now() // Poll for the transaction to be ready & then send the result to receiptChan receipt, err := m.waitMined(ctx, tx, sendState) if err != nil { @@ -484,16 +502,14 @@ func (m *SimpleTxManager) increaseGasPrice(ctx context.Context, tx *types.Transa } bumpedTip, bumpedFee := updateFees(tx.GasTipCap(), tx.GasFeeCap(), tip, basefee, m.l) - // Make sure increase is at most 5x the suggested values - maxTip := new(big.Int).Mul(tip, big.NewInt(feeLimitMultiplier)) + // Make sure increase is at most [FeeLimitMultiplier] the suggested values + maxTip := new(big.Int).Mul(tip, big.NewInt(int64(m.cfg.FeeLimitMultiplier))) if bumpedTip.Cmp(maxTip) > 0 { - m.l.Warn(fmt.Sprintf("bumped tip getting capped at %dx multiple of the suggested value", feeLimitMultiplier), "bumped", bumpedTip, "suggestion", tip) - bumpedTip.Set(maxTip) + return nil, fmt.Errorf("bumped tip 0x%s is over %dx multiple of the suggested value", bumpedTip.Text(16), m.cfg.FeeLimitMultiplier) } - maxFee := calcGasFeeCap(new(big.Int).Mul(basefee, big.NewInt(feeLimitMultiplier)), maxTip) + maxFee := calcGasFeeCap(new(big.Int).Mul(basefee, big.NewInt(int64(m.cfg.FeeLimitMultiplier))), maxTip) if bumpedFee.Cmp(maxFee) > 0 { - m.l.Warn("bumped fee getting capped at multiple of the implied suggested value", "bumped", bumpedFee, "suggestion", maxFee) - bumpedFee.Set(maxFee) + return nil, fmt.Errorf("bumped fee 0x%s is over %dx multiple of the suggested value", bumpedFee.Text(16), m.cfg.FeeLimitMultiplier) } rawTx := &types.DynamicFeeTx{ ChainID: tx.ChainId(), diff --git a/op-service/txmgr/txmgr_test.go b/op-service/txmgr/txmgr_test.go index e60cbb15eea65..d15eae373148a 100644 --- a/op-service/txmgr/txmgr_test.go +++ b/op-service/txmgr/txmgr_test.go @@ -80,6 +80,7 @@ func configWithNumConfs(numConfirmations uint64) Config { ReceiptQueryInterval: 50 * time.Millisecond, NumConfirmations: numConfirmations, SafeAbortNonceTooLowCount: 3, + FeeLimitMultiplier: 5, TxNotInMempoolTimeout: 1 * time.Hour, Signer: func(ctx context.Context, from common.Address, tx *types.Transaction) (*types.Transaction, error) { return tx, nil @@ -449,6 +450,40 @@ func TestTxMgr_EstimateGasFails(t *testing.T) { require.Equal(t, lastNonce+1, tx.Nonce()) } +func TestTxMgr_SigningFails(t *testing.T) { + t.Parallel() + errorSigning := false + cfg := configWithNumConfs(1) + cfg.Signer = func(ctx context.Context, from common.Address, tx *types.Transaction) (*types.Transaction, error) { + if errorSigning { + return nil, fmt.Errorf("signer error") + } else { + return tx, nil + } + } + h := newTestHarnessWithConfig(t, cfg) + candidate := h.createTxCandidate() + + // Set the gas limit to zero to trigger gas estimation. + candidate.GasLimit = 0 + + // Craft a successful transaction. + tx, err := h.mgr.craftTx(context.Background(), candidate) + require.Nil(t, err) + lastNonce := tx.Nonce() + + // Mock signer failure. + errorSigning = true + _, err = h.mgr.craftTx(context.Background(), candidate) + require.ErrorContains(t, err, "signer error") + + // Ensure successful craft uses the correct nonce + errorSigning = false + tx, err = h.mgr.craftTx(context.Background(), candidate) + require.Nil(t, err) + require.Equal(t, lastNonce+1, tx.Nonce()) +} + // TestTxMgrOnlyOnePublicationSucceeds asserts that the tx manager will return a // receipt so long as at least one of the publications is able to succeed with a // simulated rpc failure. @@ -766,6 +801,7 @@ func doGasPriceIncrease(t *testing.T, txTipCap, txFeeCap, newTip, newBaseFee int ReceiptQueryInterval: 50 * time.Millisecond, NumConfirmations: 1, SafeAbortNonceTooLowCount: 3, + FeeLimitMultiplier: 5, Signer: func(ctx context.Context, from common.Address, tx *types.Transaction) (*types.Transaction, error) { return tx, nil }, @@ -867,6 +903,7 @@ func TestIncreaseGasPriceNotExponential(t *testing.T) { ReceiptQueryInterval: 50 * time.Millisecond, NumConfirmations: 1, SafeAbortNonceTooLowCount: 3, + FeeLimitMultiplier: 5, Signer: func(ctx context.Context, from common.Address, tx *types.Transaction) (*types.Transaction, error) { return tx, nil }, @@ -883,23 +920,20 @@ func TestIncreaseGasPriceNotExponential(t *testing.T) { }) // Run IncreaseGasPrice a bunch of times in a row to simulate a very fast resubmit loop. - var err error - for i := 0; i < 30; i++ { - ctx := context.Background() - tx, err = mgr.increaseGasPrice(ctx, tx) - require.NoError(t, err) + ctx := context.Background() + for { + newTx, err := mgr.increaseGasPrice(ctx, tx) + if err != nil { + break + } + tx = newTx } lastTip, lastFee := tx.GasTipCap(), tx.GasFeeCap() - require.Equal(t, lastTip.Int64(), feeLimitMultiplier*borkedTip) - require.Equal(t, lastFee.Int64(), feeLimitMultiplier*(borkedTip+2*borkedFee)) + require.Equal(t, lastTip.Int64(), int64(36)) + require.Equal(t, lastFee.Int64(), int64(493)) // Confirm that fees stop rising - for i := 0; i < 5; i++ { - ctx := context.Background() - tx, err := mgr.increaseGasPrice(ctx, tx) - require.NoError(t, err) - require.True(t, tx.GasTipCap().Cmp(lastTip) == 0, "suggested tx tip must stop increasing") - require.True(t, tx.GasFeeCap().Cmp(lastFee) == 0, "suggested tx fee must stop increasing") - } + _, err := mgr.increaseGasPrice(ctx, tx) + require.Error(t, err) } func TestErrStringMatch(t *testing.T) { diff --git a/op-service/version.go b/op-service/version.go new file mode 100644 index 0000000000000..81a039b34d532 --- /dev/null +++ b/op-service/version.go @@ -0,0 +1,19 @@ +package op_service + +func FormatVersion(version string, gitCommit string, gitDate string, meta string) string { + v := version + if gitCommit != "" { + if len(gitCommit) >= 8 { + v += "-" + gitCommit[:8] + } else { + v += "-" + gitCommit + } + } + if gitDate != "" { + v += "-" + gitDate + } + if meta != "" { + v += "-" + meta + } + return v +} diff --git a/op-service/version_test.go b/op-service/version_test.go new file mode 100644 index 0000000000000..f3f543304bfdd --- /dev/null +++ b/op-service/version_test.go @@ -0,0 +1,75 @@ +package op_service + +import ( + "testing" + + "github.com/stretchr/testify/require" +) + +func TestFormatVersion(t *testing.T) { + tests := []struct { + version string + gitCommit string + gitDate string + meta string + expected string + }{ + { + version: "v1.0.0", + gitCommit: "c90a760cfaccefb60b942ffe4ccf4f9692587cec", + gitDate: "1698107786", + meta: "", + expected: "v1.0.0-c90a760c-1698107786", + }, + { + version: "v1.0.0", + gitCommit: "dev", + gitDate: "1698107786", + meta: "", + expected: "v1.0.0-dev-1698107786", + }, + { + version: "v1.0.0", + gitCommit: "", + gitDate: "1698107786", + meta: "", + expected: "v1.0.0-1698107786", + }, + { + version: "v1.0.0", + gitCommit: "dev", + gitDate: "", + meta: "", + expected: "v1.0.0-dev", + }, + { + version: "v1.0.0", + gitCommit: "", + gitDate: "", + meta: "rc.1", + expected: "v1.0.0-rc.1", + }, + { + version: "v1.0.0", + gitCommit: "", + gitDate: "", + meta: "", + expected: "v1.0.0", + }, + { + version: "v1.0.0", + gitCommit: "c90a760cfaccefb60b942ffe4ccf4f9692587cec", + gitDate: "1698107786", + meta: "beta", + expected: "v1.0.0-c90a760c-1698107786-beta", + }, + } + + for _, test := range tests { + test := test + t.Run(test.expected, func(t *testing.T) { + actual := FormatVersion(test.version, test.gitCommit, test.gitDate, test.meta) + require.Equal(t, test.expected, actual) + }) + } +} diff --git a/op-wheel/Dockerfile b/op-wheel/Dockerfile index 0ac56b73cdfdf..30f7a8a3713a5 100644 --- a/op-wheel/Dockerfile +++ b/op-wheel/Dockerfile @@ -1,21 +1,8 @@ -FROM golang:1.21.1-alpine3.18 as builder - -RUN apk add --no-cache make gcc musl-dev linux-headers - -COPY ./op-wheel /app/op-wheel -COPY ./op-node /app/op-node -COPY ./op-chain-ops /app/op-chain-ops -COPY ./op-service /app/op-service -COPY ./op-bindings /app/op-bindings -COPY ./go.mod /app/go.mod -COPY ./go.sum /app/go.sum - -WORKDIR /app/op-wheel - -RUN go build -o op-wheel ./cmd/main.go - +ARG OP_STACK_GO_BUILDER=us-docker.pkg.dev/oplabs-tools-artifacts/images/op-stack-go:latest +FROM $OP_STACK_GO_BUILDER as builder +# See "make golang-docker" and /ops/docker/op-stack-go FROM alpine:3.18 -COPY --from=builder /app/op-wheel/op-wheel /usr/local/bin +COPY --from=builder /app/op-wheel/bin/op-wheel /usr/local/bin CMD ["op-wheel"] diff --git a/op-wheel/Dockerfile.dockerignore b/op-wheel/Dockerfile.dockerignore new file mode 100644 index 0000000000000..4f26140750a08 --- /dev/null +++ b/op-wheel/Dockerfile.dockerignore @@ -0,0 +1,2 @@ +# ignore everything but the dockerfile, the op-stack-go base image performs the build +* diff --git a/op-wheel/Makefile b/op-wheel/Makefile index f5ca16953e4dd..6496e3bc8c549 100644 --- a/op-wheel/Makefile +++ b/op-wheel/Makefile @@ -1,6 +1,5 @@ - -GITCOMMIT := $(shell git rev-parse HEAD) -GITDATE := $(shell git show -s --format='%ct') +GITCOMMIT ?= $(shell git rev-parse HEAD) +GITDATE ?= $(shell git show -s --format='%ct') VERSION := v0.0.0 LDFLAGSSTRING +=-X main.GitCommit=$(GITCOMMIT) @@ -10,6 +9,3 @@ LDFLAGS := -ldflags "$(LDFLAGSSTRING)" op-wheel: env GO111MODULE=on GOOS=$(TARGETOS) GOARCH=$(TARGETARCH) go build -v $(LDFLAGS) -o ./bin/op-wheel ./cmd - -lint: - golangci-lint run -E goimports,sqlclosecheck,bodyclose,asciicheck,misspell,errorlint --timeout 5m -e "errors.As" -e "errors.Is" ./... diff --git a/op-wheel/cheat/cheat.go b/op-wheel/cheat/cheat.go index e572179ee9772..debffacc11824 100644 --- a/op-wheel/cheat/cheat.go +++ b/op-wheel/cheat/cheat.go @@ -371,19 +371,19 @@ func OvmOwners(conf *OvmOwnersConfig) HeadFn { // Address manager owner // Ownable, first storage slot - headState.SetState(addressManager, common.Hash{}, conf.Owner.Hash()) + headState.SetState(addressManager, common.Hash{}, eth.AddressAsLeftPaddedHash(conf.Owner)) // L1SB proxy owner - headState.SetState(l1SBProxy, ownerSlot, conf.Owner.Hash()) + headState.SetState(l1SBProxy, ownerSlot, eth.AddressAsLeftPaddedHash(conf.Owner)) // L1XDM owner // 0x33 = 51. L1CrossDomainMessenger is L1CrossDomainMessenger (0) Lib_AddressResolver (1) OwnableUpgradeable (1, but covered by gap) + ContextUpgradeable (special gap of 50) and then _owner - headState.SetState(l1XDMProxy, common.Hash{31: 0x33}, conf.Owner.Hash()) + headState.SetState(l1XDMProxy, common.Hash{31: 0x33}, eth.AddressAsLeftPaddedHash(conf.Owner)) // L1 ERC721 bridge owner - headState.SetState(l1ERC721BridgeProxy, ownerSlot, conf.Owner.Hash()) + headState.SetState(l1ERC721BridgeProxy, ownerSlot, eth.AddressAsLeftPaddedHash(conf.Owner)) // Legacy sequencer/proposer addresses // See AddressManager.sol "addresses" mapping(bytes32 => address), at slot position 1 addressesSlot := common.BigToHash(big.NewInt(1)) - headState.SetState(addressManager, crypto.Keccak256Hash(crypto.Keccak256([]byte("OVM_Sequencer")), addressesSlot.Bytes()), conf.Sequencer.Hash()) - headState.SetState(addressManager, crypto.Keccak256Hash(crypto.Keccak256([]byte("OVM_Proposer")), addressesSlot.Bytes()), conf.Proposer.Hash()) + headState.SetState(addressManager, crypto.Keccak256Hash(crypto.Keccak256([]byte("OVM_Sequencer")), addressesSlot.Bytes()), eth.AddressAsLeftPaddedHash(conf.Sequencer)) + headState.SetState(addressManager, crypto.Keccak256Hash(crypto.Keccak256([]byte("OVM_Proposer")), addressesSlot.Bytes()), eth.AddressAsLeftPaddedHash(conf.Proposer)) // Fund sequencer and proposer with 100 ETH headState.SetBalance(conf.Sequencer, HundredETH) headState.SetBalance(conf.Proposer, HundredETH) diff --git a/op-wheel/cmd/main.go b/op-wheel/cmd/main.go index f906ada46eec4..29c726cddb21f 100644 --- a/op-wheel/cmd/main.go +++ b/op-wheel/cmd/main.go @@ -2,9 +2,9 @@ package main import ( "errors" - "fmt" "os" + opservice "github.com/ethereum-optimism/optimism/op-service" "github.com/urfave/cli/v2" "github.com/ethereum/go-ethereum/log" @@ -21,7 +21,7 @@ var ( func main() { app := cli.NewApp() - app.Version = fmt.Sprintf("%s-%s-%s", Version, GitCommit, GitDate) + app.Version = opservice.FormatVersion(Version, GitCommit, GitDate, "") app.Name = "op-wheel" app.Usage = "Optimism Wheel is a CLI tool for the execution engine" app.Description = "Optimism Wheel is a CLI tool to direct the engine one way or the other with DB cheats and Engine API routines." diff --git a/ops-bedrock/Dockerfile.l1 b/ops-bedrock/Dockerfile.l1 index f537afd9b7f96..1e1491c824107 100644 --- a/ops-bedrock/Dockerfile.l1 +++ b/ops-bedrock/Dockerfile.l1 @@ -1,4 +1,4 @@ -FROM ethereum/client-go:v1.13.3 +FROM ethereum/client-go:v1.13.4 RUN apk add --no-cache jq diff --git a/ops-bedrock/docker-compose.yml b/ops-bedrock/docker-compose.yml index 26178ac259841..12216ab510ff7 100644 --- a/ops-bedrock/docker-compose.yml +++ b/ops-bedrock/docker-compose.yml @@ -11,6 +11,16 @@ volumes: services: + op_stack_go_builder: # Not an actual service, but builds the prerequisite go images + build: + context: ../ + dockerfile: ops/docker/op-stack-go/Dockerfile + args: + GIT_COMMIT: "dev" + GIT_DATE: "0" + image: us-docker.pkg.dev/oplabs-tools-artifacts/images/op-stack-go:devnet + entrypoint: ["echo", "build complete"] + l1: build: context: . @@ -23,6 +33,8 @@ services: - "l1_data:/db" - "${PWD}/../.devnet/genesis-l1.json:/genesis.json" - "${PWD}/test-jwt-secret.txt:/config/test-jwt-secret.txt" + environment: + GETH_MINER_RECOMMIT: 100ms l2: build: @@ -39,14 +51,20 @@ services: - "/bin/sh" - "/entrypoint.sh" - "--authrpc.jwtsecret=/config/test-jwt-secret.txt" + environment: + GETH_MINER_RECOMMIT: 100ms op-node: depends_on: + - op_stack_go_builder - l1 - l2 build: context: ../ dockerfile: ./op-node/Dockerfile + args: + OP_STACK_GO_BUILDER: us-docker.pkg.dev/oplabs-tools-artifacts/images/op-stack-go:devnet + image: us-docker.pkg.dev/oplabs-tools-artifacts/images/op-node:devnet command: > op-node --l1=ws://l1:8546 @@ -85,12 +103,16 @@ services: op-proposer: depends_on: + - op_stack_go_builder - l1 - l2 - op-node build: context: ../ dockerfile: ./op-proposer/Dockerfile + args: + OP_STACK_GO_BUILDER: us-docker.pkg.dev/oplabs-tools-artifacts/images/op-stack-go:devnet + image: us-docker.pkg.dev/oplabs-tools-artifacts/images/op-proposer:devnet ports: - "6062:6060" - "7302:7300" @@ -110,12 +132,16 @@ services: op-batcher: depends_on: + - op_stack_go_builder - l1 - l2 - op-node build: context: ../ dockerfile: ./op-batcher/Dockerfile + args: + OP_STACK_GO_BUILDER: us-docker.pkg.dev/oplabs-tools-artifacts/images/op-stack-go:devnet + image: us-docker.pkg.dev/oplabs-tools-artifacts/images/op-batcher:devnet ports: - "6061:6060" - "7301:7300" @@ -133,6 +159,7 @@ services: OP_BATCHER_PPROF_ENABLED: "true" OP_BATCHER_METRICS_ENABLED: "true" OP_BATCHER_RPC_ENABLE_ADMIN: "true" + OP_BATCHER_BATCH_TYPE: 0 artifact-server: depends_on: @@ -145,16 +172,16 @@ services: security_opt: - "no-new-privileges:true" - stateviz: - build: - context: ../ - dockerfile: ./ops-bedrock/Dockerfile.stateviz - command: - - stateviz - - -addr=0.0.0.0:8080 - - -snapshot=/op_log/snapshot.log - - -refresh=10s - ports: - - "9090:8080" - volumes: - - op_log:/op_log:ro +# stateviz: +# build: +# context: ../ +# dockerfile: ./ops-bedrock/Dockerfile.stateviz +# command: +# - stateviz +# - -addr=0.0.0.0:8080 +# - -snapshot=/op_log/snapshot.log +# - -refresh=10s +# ports: +# - "9090:8080" +# volumes: +# - op_log:/op_log:ro diff --git a/ops/check-changed/requirements.txt b/ops/check-changed/requirements.txt index 3d7d83b86eb2b..2cd9e559bf961 100644 --- a/ops/check-changed/requirements.txt +++ b/ops/check-changed/requirements.txt @@ -8,5 +8,5 @@ PyGithub==1.57 PyJWT==2.6.0 PyNaCl==1.5.0 requests==2.28.1 -urllib3==1.26.17 +urllib3==1.26.18 wrapt==1.14.1 diff --git a/ops/docker/Dockerfile.packages b/ops/docker/Dockerfile.packages index 2fdf67bde525f..fbd14af127487 100644 --- a/ops/docker/Dockerfile.packages +++ b/ops/docker/Dockerfile.packages @@ -35,7 +35,7 @@ FROM us-docker.pkg.dev/oplabs-tools-artifacts/images/ci-builder:latest as foundr # we use it rather than alpine because it's not much # bigger and alpine is often missing packages for node applications # alpine is not officially supported by node.js -FROM node:18.17.1-bullseye-slim as base +FROM node:20.8.1-bullseye-slim as base # Base: install deps RUN apt-get update && apt-get install -y \ @@ -79,26 +79,39 @@ RUN git submodule update --init --recursive RUN pnpm build -FROM base as replica-mon +ENTRYPOINT ["pnpm", "run"] + +FROM base as chain-mon WORKDIR /opt/optimism/packages/chain-mon -ENTRYPOINT ["pnpm", "run", "start:replica-mon"] +# TODO keeping the rest of these here for now because they are being used +# but we should really delete them we only need one image FROM base as balance-mon WORKDIR /opt/optimism/packages/chain-mon -ENTRYPOINT ["pnpm", "run", "start:balance-mon"] +CMD ["start:balance-mon"] FROM base as drippie-mon WORKDIR /opt/optimism/packages/chain-mon -ENTRYPOINT ["pnpm", "run", "start:drippie-mon"] +CMD ["start:drippie-mon"] -FROM base as wd-mon +from base as fault-mon +WORKDIR /opt/optimism/packages/chain-mon +CMD ["start:fault-mon"] + +from base as multisig-mon +WORKDIR /opt/optimism/packages/multisig-mon +CMD ["start:multisig-mon"] + +FROM base as replica-mon WORKDIR /opt/optimism/packages/chain-mon -ENTRYPOINT ["pnpm", "run", "start:wd-mon"] +CMD ["start:replica-mon"] FROM base as wallet-mon WORKDIR /opt/optimism/packages/chain-mon -ENTRYPOINT ["pnpm", "run", "start:wallet-mon"] +CMD ["start:wallet-mon"] -from base as fault-mon +FROM base as wd-mon WORKDIR /opt/optimism/packages/chain-mon -ENTRYPOINT ["pnpm", "run", "start:fault-mon"] +CMD ["start:wd-mon"] + + diff --git a/ops/docker/ci-builder/Dockerfile b/ops/docker/ci-builder/Dockerfile index 2abece5f95448..38d6dacf9e701 100644 --- a/ops/docker/ci-builder/Dockerfile +++ b/ops/docker/ci-builder/Dockerfile @@ -1,4 +1,4 @@ -FROM debian:bullseye-20220822-slim as foundry-build +FROM --platform=linux/amd64 debian:bullseye-slim as rust-build SHELL ["/bin/bash", "-c"] @@ -6,11 +6,18 @@ WORKDIR /opt ENV DEBIAN_FRONTEND=noninteractive RUN apt-get update && \ - apt-get install -y curl build-essential git && \ - curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs > rustup.sh && \ + apt-get install -y curl build-essential git clang lld curl + +RUN curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs > rustup.sh && \ chmod +x ./rustup.sh && \ ./rustup.sh -y +# Install nightly toolchain +RUN source $HOME/.profile && rustup update nightly + +RUN source $HOME/.profile && cargo install just +RUN source $HOME/.profile && cargo install svm-rs + # Only diff from upstream docker image is this clone instead # of COPY. We select a specific commit to use. COPY ./.foundryrc ./.foundryrc @@ -25,70 +32,90 @@ RUN source $HOME/.profile && \ strip /opt/foundry/target/release/cast && \ strip /opt/foundry/target/release/anvil -FROM ghcr.io/crytic/echidna/echidna:v2.0.4 as echidna-test +FROM --platform=linux/amd64 ghcr.io/crytic/echidna/echidna:v2.0.4 as echidna-test + +FROM --platform=linux/amd64 debian:bullseye-slim as go-build -FROM python:3.11.4-slim-bullseye +RUN apt-get update && apt-get install -y curl ca-certificates + +ENV GO_VERSION=1.21.1 + +# Fetch go manually, rather than using a Go base image, so we can copy the installation into the final stage +RUN curl -sL https://go.dev/dl/go$GO_VERSION.linux-amd64.tar.gz -o go$GO_VERSION.linux-amd64.tar.gz && \ + tar -C /usr/local/ -xzvf go$GO_VERSION.linux-amd64.tar.gz ENV GOPATH=/go ENV PATH=/usr/local/go/bin:$GOPATH/bin:$PATH + +# Install the specific version of abigen from .abigenrc +COPY ./.abigenrc ./.abigenrc +RUN go install github.com/ethereum/go-ethereum/cmd/abigen@$(cat .abigenrc) + +COPY ./.gethrc ./.gethrc +RUN go install github.com/ethereum/go-ethereum/cmd/geth@$(cat .gethrc) + +RUN go install gotest.tools/gotestsum@latest +RUN go install github.com/vektra/mockery/v2@v2.28.1 +RUN go install github.com/golangci/golangci-lint/cmd/golangci-lint@v1.54.2 + +FROM --platform=linux/amd64 python:3.11.4-slim-bullseye + +ENV GOPATH=/go +ENV PATH=/usr/local/go/bin:$GOPATH/bin:$PATH +ENV PATH=/root/.cargo/bin:$PATH ENV DEBIAN_FRONTEND=noninteractive -COPY --from=foundry-build /opt/foundry/target/release/forge /usr/local/bin/forge -COPY --from=foundry-build /opt/foundry/target/release/cast /usr/local/bin/cast -COPY --from=foundry-build /opt/foundry/target/release/anvil /usr/local/bin/anvil +# Create rust directories for copying the installation into +RUN mkdir /root/.cargo && mkdir /root/.cargo/bin && mkdir /root/.rustup + +# copy the go installation, but not the module cache (cache will get stale, and would add a lot of weight) +COPY --from=go-build /usr/local/go /usr/local/go +# copy tools +COPY --from=go-build /go/bin/gotestsum /go/bin/gotestsum +COPY --from=go-build /go/bin/mockery /go/bin/mockery +COPY --from=go-build /go/bin/golangci-lint /go/bin/golangci-lint +COPY --from=go-build /go/bin/abigen /usr/local/bin/abigen +COPY --from=go-build /go/bin/geth /usr/local/bin/geth + +# copy the rust installation, alongside the installed toolchains +COPY --from=rust-build /root/.cargo/bin /root/.cargo/bin +COPY --from=rust-build /root/.rustup /root/.rustup +# copy tools +COPY --from=rust-build /opt/foundry/target/release/forge /usr/local/bin/forge +COPY --from=rust-build /opt/foundry/target/release/cast /usr/local/bin/cast +COPY --from=rust-build /opt/foundry/target/release/anvil /usr/local/bin/anvil + COPY --from=echidna-test /usr/local/bin/echidna-test /usr/local/bin/echidna-test -RUN apt-get update && \ - apt-get install -y bash curl openssh-client git build-essential ca-certificates jq musl gnupg coreutils && \ - curl -sL https://deb.nodesource.com/setup_16.x -o nodesource_setup.sh && \ - curl -sL https://go.dev/dl/go1.21.1.linux-amd64.tar.gz -o go1.21.1.linux-amd64.tar.gz && \ - tar -C /usr/local/ -xzvf go1.21.1.linux-amd64.tar.gz && \ - ln -s /usr/local/go/bin/gofmt /usr/local/bin/gofmt && \ - bash nodesource_setup.sh && \ - apt-get install -y nodejs && \ - npm i -g depcheck && \ - pip install slither-analyzer==0.9.3 && \ - go install gotest.tools/gotestsum@latest && \ - curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(go env GOPATH)/bin v1.53.3 && \ - curl -fLSs https://raw.githubusercontent.com/CircleCI-Public/circleci-cli/master/install.sh | bash +COPY .nvmrc .nvmrc -COPY ./.abigenrc ./.abigenrc +ENV NODE_MAJOR=20 +ENV SLITHER_VERSION=0.10.0 + +# note: python3 package in apt is python 3.9, while base image already has python 3.11 +RUN /bin/sh -c set -eux; \ + apt-get update; \ + apt-get install -y --no-install-recommends bash curl openssh-client git build-essential pkg-config libssl-dev clang libclang-dev ca-certificates jq gnupg binutils-mips-linux-gnu; \ + mkdir -p /etc/apt/keyrings; \ + curl -fsSL https://deb.nodesource.com/gpgkey/nodesource-repo.gpg.key | gpg --dearmor -o /etc/apt/keyrings/nodesource.gpg; \ + echo "deb [signed-by=/etc/apt/keyrings/nodesource.gpg] https://deb.nodesource.com/node_$NODE_MAJOR.x nodistro main" | tee /etc/apt/sources.list.d/nodesource.list; \ + apt-get update; \ + apt-get install -y nodejs; \ + ln -s /usr/local/go/bin/gofmt /usr/local/bin/gofmt; \ + npm i -g depcheck; \ + pip install slither-analyzer==$SLITHER_VERSION capstone pyelftools; \ + curl -fLSs https://raw.githubusercontent.com/CircleCI-Public/circleci-cli/master/install.sh | bash; \ + apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false; \ + rm -rf /var/lib/apt/lists/*; \ + rm -rf /root/.cache/pip; \ + rm -rf /root/.cache/npm; -# Install the specific version of abigen from .abigenrc -RUN go install github.com/ethereum/go-ethereum/cmd/abigen@$(cat .abigenrc) -# We need to isntall yarn because a bespoke dependency installed from github https://codeload.github.com/Saw-mon-and-Natalie/clones-with-immutable-arg needs it -# it is installed from github which means it's postpack script which uses yarn is ran when unpacked into node_modules -RUN echo "downloading pnpm and yarn" && npm i -g pnpm && npm i -g yarn@1 && pnpm --version && yarn --version - -RUN echo "downloading solidity compilers" && \ - curl -o solc-linux-amd64-v0.5.17+commit.d19bba13 -sL https://binaries.soliditylang.org/linux-amd64/solc-linux-amd64-v0.5.17+commit.d19bba13 && \ - curl -o solc-linux-amd64-v0.8.9+commit.e5eed63a -sL https://binaries.soliditylang.org/linux-amd64/solc-linux-amd64-v0.8.9+commit.e5eed63a && \ - curl -o solc-linux-amd64-v0.8.10+commit.fc410830 -sL https://binaries.soliditylang.org/linux-amd64/solc-linux-amd64-v0.8.10+commit.fc410830 && \ - curl -o solc-linux-amd64-v0.8.12+commit.f00d7308 -sL https://binaries.soliditylang.org/linux-amd64/solc-linux-amd64-v0.8.12+commit.f00d7308 && \ - echo "verifying checksums" && \ - (echo "c35ce7a4d3ffa5747c178b1e24c8541b2e5d8a82c1db3719eb4433a1f19e16f3 solc-linux-amd64-v0.5.17+commit.d19bba13" | sha256sum --check --status - || exit 1) && \ - (echo "f851f11fad37496baabaf8d6cb5c057ca0d9754fddb7a351ab580d7fd728cb94 solc-linux-amd64-v0.8.9+commit.e5eed63a" | sha256sum --check --status - || exit 1) && \ - (echo "c7effacf28b9d64495f81b75228fbf4266ac0ec87e8f1adc489ddd8a4dd06d89 solc-linux-amd64-v0.8.10+commit.fc410830" | sha256sum --check --status - || exit 1) && \ - (echo "556c3ec44faf8ff6b67933fa8a8a403abe82c978d6e581dbfec4bd07360bfbf3 solc-linux-amd64-v0.8.12+commit.f00d7308" | sha256sum --check --status - || exit 1) && \ - echo "caching compilers" && \ - mkdir -p ~/.cache/hardhat-nodejs/compilers/linux-amd64 && \ - cp solc-linux-amd64-v0.5.17+commit.d19bba13 ~/.cache/hardhat-nodejs/compilers/linux-amd64/ && \ - cp solc-linux-amd64-v0.8.9+commit.e5eed63a ~/.cache/hardhat-nodejs/compilers/linux-amd64/ && \ - cp solc-linux-amd64-v0.8.10+commit.fc410830 ~/.cache/hardhat-nodejs/compilers/linux-amd64/ && \ - cp solc-linux-amd64-v0.8.12+commit.f00d7308 ~/.cache/hardhat-nodejs/compilers/linux-amd64/ && \ - mkdir -p ~/.svm/0.5.17 && \ - cp solc-linux-amd64-v0.5.17+commit.d19bba13 ~/.svm/0.5.17/solc-0.5.17 && \ - mkdir -p ~/.svm/0.8.9 && \ - cp solc-linux-amd64-v0.8.9+commit.e5eed63a ~/.svm/0.8.9/solc-0.8.9 && \ - mkdir -p ~/.svm/0.8.10 && \ - cp solc-linux-amd64-v0.8.10+commit.fc410830 ~/.svm/0.8.10/solc-0.8.10 && \ - mkdir -p ~/.svm/0.8.12 && \ - cp solc-linux-amd64-v0.8.12+commit.f00d7308 ~/.svm/0.8.12/solc-0.8.12 && \ - rm solc-linux-amd64-v0.5.17+commit.d19bba13 && \ - rm solc-linux-amd64-v0.8.9+commit.e5eed63a && \ - rm solc-linux-amd64-v0.8.10+commit.fc410830 && \ - rm solc-linux-amd64-v0.8.12+commit.f00d7308 +RUN npm i -g pnpm && npm i -g yarn@1 && pnpm --version && yarn --version + +RUN svm install 0.5.17 && \ + svm install 0.8.15 && \ + svm install 0.8.19 RUN echo "downloading and verifying Codecov uploader" && \ curl https://keybase.io/codecovsecurity/pgp_keys.asc | gpg --no-default-keyring --keyring trustedkeys.gpg --import && \ @@ -101,15 +128,10 @@ RUN echo "downloading and verifying Codecov uploader" && \ chmod +x /usr/local/bin/codecov && \ rm codecov -RUN echo "downloading mockery tool" && \ - mkdir -p mockery-tmp-dir && \ - curl -o mockery-tmp-dir/mockery.tar.gz -sL https://github.com/vektra/mockery/releases/download/v2.28.1/mockery_2.28.1_Linux_x86_64.tar.gz && \ - tar -xzvf mockery-tmp-dir/mockery.tar.gz -C mockery-tmp-dir && \ - cp mockery-tmp-dir/mockery /usr/local/bin/mockery && \ - chmod +x /usr/local/bin/mockery && \ - rm -rf mockery-tmp-dir - +# within docker use bash +SHELL ["/bin/bash", "-c"] +# set env to use bash +ENV SHELL=/bin/bash +ENV BASH=/bin/bash -RUN echo "installing mips binutils" && \ - apt-get install -y binutils-mips-linux-gnu python3 python3-pip && \ - pip3 install capstone pyelftools +ENTRYPOINT ["/bin/bash", "-c"] diff --git a/ops/docker/ci-builder/Dockerfile.dockerignore b/ops/docker/ci-builder/Dockerfile.dockerignore new file mode 100644 index 0000000000000..ea0c3e1441465 --- /dev/null +++ b/ops/docker/ci-builder/Dockerfile.dockerignore @@ -0,0 +1,5 @@ +* +!/.foundryrc +!/.abigenrc +!/.gethrc +!/.nvmrc diff --git a/ops/docker/op-stack-go/Dockerfile b/ops/docker/op-stack-go/Dockerfile new file mode 100644 index 0000000000000..87d92ca39233f --- /dev/null +++ b/ops/docker/op-stack-go/Dockerfile @@ -0,0 +1,84 @@ +FROM --platform=$BUILDPLATFORM golang:1.21.3-alpine3.18 as builder + +RUN apk add --no-cache make gcc musl-dev linux-headers git jq bash + +# We copy the go.mod/sum first, so the `go mod download` does not have to re-run if dependencies do not change. +COPY ./go.mod /app/go.mod +COPY ./go.sum /app/go.sum + +WORKDIR /app + +RUN echo "go mod cache: $(go env GOMODCACHE)" +RUN echo "go build cache: $(go env GOCACHE)" + +RUN --mount=type=cache,target=/go/pkg/mod --mount=type=cache,target=/root/.cache/go-build go mod download + +# NOTE: the Dockerfile.dockerignore file effectively describes all dependencies +COPY . /app + +# We avoid copying the full .git dir into the build for just some metadata. +# Instead, specify: +# --build-arg GIT_COMMIT=$(git rev-parse HEAD) +# --build-arg GIT_DATE=$(git show -s --format='%ct') +ARG GIT_COMMIT +ARG GIT_DATE + +ARG CANNON_VERSION=v0.0.0 +ARG OP_PROGRAM_VERSION=v0.0.0 + +ARG OP_HEARTBEAT_VERSION=v0.0.0 +ARG OP_WHEEL_VERSION=v0.0.0 + +ARG OP_NODE_VERSION=v0.0.0 +ARG OP_CHALLENGER_VERSION=v0.0.0 +ARG OP_BATCHER_VERSION=v0.0.0 +ARG OP_PROPOSER_VERSION=v0.0.0 + + +# separate docker-builds: +# - op-exporter +# - op-ufm +# - proxyd +# - any JS/TS/smart-contract builds + +ARG TARGETOS TARGETARCH + +# Build the Go services, utilizing caches and share the many common packages. +# The "id" defaults to the value of "target", the cache will thus be reused during this build. +# "sharing" defaults to "shared", the cache will thus be available to other concurrent docker builds. + +RUN --mount=type=cache,target=/root/.cache/go-build cd cannon && make cannon \ + GOOS=$TARGETOS GOARCH=$TARGETARCH GITCOMMIT=$GIT_COMMIT GITDATE=$GIT_DATE VERSION="$CANNON_VERSION" +# note: we only build the host, that's all the user needs. No Go MIPS cross-build in docker +RUN --mount=type=cache,target=/root/.cache/go-build cd op-program && make op-program-host \ + GOOS=$TARGETOS GOARCH=$TARGETARCH GITCOMMIT=$GIT_COMMIT GITDATE=$GIT_DATE VERSION="$OP_PROGRAM_VERSION" + +RUN --mount=type=cache,target=/root/.cache/go-build cd op-heartbeat && make op-heartbeat \ + GOOS=$TARGETOS GOARCH=$TARGETARCH GITCOMMIT=$GIT_COMMIT GITDATE=$GIT_DATE VERSION="$OP_HEARTBEAT_VERSION" +RUN --mount=type=cache,target=/root/.cache/go-build cd op-wheel && make op-wheel \ + GOOS=$TARGETOS GOARCH=$TARGETARCH GITCOMMIT=$GIT_COMMIT GITDATE=$GIT_DATE VERSION="$OP_WHEEL_VERSION" + +RUN --mount=type=cache,target=/root/.cache/go-build cd op-node && make op-node \ + GOOS=$TARGETOS GOARCH=$TARGETARCH GITCOMMIT=$GIT_COMMIT GITDATE=$GIT_DATE VERSION="$OP_NODE_VERSION" +RUN --mount=type=cache,target=/root/.cache/go-build cd op-challenger && make op-challenger \ + GOOS=$TARGETOS GOARCH=$TARGETARCH GITCOMMIT=$GIT_COMMIT GITDATE=$GIT_DATE VERSION="$OP_CHALLENGER_VERSION" +RUN --mount=type=cache,target=/root/.cache/go-build cd op-batcher && make op-batcher \ + GOOS=$TARGETOS GOARCH=$TARGETARCH GITCOMMIT=$GIT_COMMIT GITDATE=$GIT_DATE VERSION="$OP_BATCHER_VERSION" +RUN --mount=type=cache,target=/root/.cache/go-build cd op-proposer && make op-proposer \ + GOOS=$TARGETOS GOARCH=$TARGETARCH GITCOMMIT=$GIT_COMMIT GITDATE=$GIT_DATE VERSION="$OP_PROPOSER_VERSION" + + +FROM alpine:3.18 + +COPY --from=builder /app/cannon/bin/cannon /usr/local/bin/ +COPY --from=builder /app/op-program/bin/op-program /usr/local/bin/ + +COPY --from=builder /app/op-heartbeat/bin/op-heartbeat /usr/local/bin/ +COPY --from=builder /app/op-wheel/bin/op-wheel /usr/local/bin/ + +COPY --from=builder /app/op-node/bin/op-node /usr/local/bin/ +COPY --from=builder /app/op-challenger/bin/op-challenger /usr/local/bin/ +COPY --from=builder /app/op-batcher/bin/op-batcher /usr/local/bin/ +COPY --from=builder /app/op-proposer/bin/op-proposer /usr/local/bin/ + + diff --git a/ops/docker/op-stack-go/Dockerfile.dockerignore b/ops/docker/op-stack-go/Dockerfile.dockerignore new file mode 100644 index 0000000000000..ccd041a996f6c --- /dev/null +++ b/ops/docker/op-stack-go/Dockerfile.dockerignore @@ -0,0 +1,19 @@ +# All the files we depend on. We are using a negative pattern to not include anything by accident. +# node_modules, packages (contains git submodules and node modules etc.), devnet dirs etc. all add up a lot. +* + +!/cannon +!/op-batcher +!/op-bindings +!/op-bootnode +!/op-chain-ops +!/op-challenger +!/op-heartbeat +!/op-node +!/op-preimage +!/op-program +!/op-proposer +!/op-service +!/op-wheel +!/go.mod +!/go.sum diff --git a/ops/scripts/ci-docker-tag-op-stack-release.sh b/ops/scripts/ci-docker-tag-op-stack-release.sh index 040c76134fb75..9edd98f2cae8e 100755 --- a/ops/scripts/ci-docker-tag-op-stack-release.sh +++ b/ops/scripts/ci-docker-tag-op-stack-release.sh @@ -6,7 +6,7 @@ DOCKER_REPO=$1 GIT_TAG=$2 GIT_SHA=$3 -IMAGE_NAME=$(echo "$GIT_TAG" | grep -Eow '^(ci-builder|proxyd|indexer|ufm-[a-z0-9\-]*|op-[a-z0-9\-]*)' || true) +IMAGE_NAME=$(echo "$GIT_TAG" | grep -Eow '^(ci-builder|chain-mon|proxyd|indexer|ufm-[a-z0-9\-]*|op-[a-z0-9\-]*)' || true) if [ -z "$IMAGE_NAME" ]; then echo "image name could not be parsed from git tag '$GIT_TAG'" exit 1 diff --git a/ops/scripts/ci-match-values-between-files.sh b/ops/scripts/ci-match-values-between-files.sh new file mode 100755 index 0000000000000..53d680cd31974 --- /dev/null +++ b/ops/scripts/ci-match-values-between-files.sh @@ -0,0 +1,57 @@ +#!/usr/bin/env bash + +set -euo pipefail + +FILE1=$1 +PATTERN1=$2 +FILE2=$3 +PATTERN2=$4 + +# shellcheck disable=SC2016 +SCRIPT=' +BEGIN { + in_comment = 0; + matches = 0; +} + +/^ *\/\*/ { + in_comment = 1; +} + +in_comment && /\*\// { + in_comment = 0; + next; +} + +!in_comment && !/^ *\/\// && $0 ~ PATTERN { + matches++; + matched_line = $0; +} + +END { + if (matches == 1) { + print matched_line; + } else if (matches > 1) { + print "Multiple matches found. Exiting."; + exit 1; + } else { + print "No matches found. Exiting."; + exit 1; + } +}' + +VALUE1_MATCH=$(echo "$SCRIPT" | awk -v PATTERN="$PATTERN1" -f- "$FILE1") +VALUE1=$(echo "$VALUE1_MATCH" | awk -F'=' '{print $2}' | tr -d ' ;') +echo "Value from File 1: $VALUE1" + +VALUE2_MATCH=$(echo "$SCRIPT" | awk -v PATTERN="$PATTERN2" -f- "$FILE2") +VALUE2=$(echo "$VALUE2_MATCH" | awk -F'=' '{print $2}' | tr -d ' ;') +echo "Value from File 2: $VALUE2" + +if [ "$VALUE1" != "$VALUE2" ]; then + echo "Error: Values from file1 ($VALUE1) and file2 ($VALUE2) don't match." + exit 1 +fi + +echo "Values match!" + diff --git a/ops/scripts/geth-version-checker.sh b/ops/scripts/geth-version-checker.sh new file mode 100755 index 0000000000000..22bf1d37b1b68 --- /dev/null +++ b/ops/scripts/geth-version-checker.sh @@ -0,0 +1,23 @@ +#!/bin/bash + +# Extract the version from the geth command output +GETH_VERSION="v$(geth version | grep '^Version:' | awk '{print $2}')" + +# Read the version from the .gethrc file +GETHRC_VERSION=$(cat .gethrc) + +# Check if GETHRC_VERSION contains a '-'. If not, append '-stable'. +if [[ $GETHRC_VERSION != *-* ]]; then + GETHRC_VERSION="${GETHRC_VERSION}-stable" +fi + +# Compare the versions +if [[ "$GETH_VERSION" == "$GETHRC_VERSION" ]]; then + echo "Geth version $GETH_VERSION is correct!" + exit 0 +else + echo "Geth version does not match!" + echo "geth version: $GETH_VERSION" + echo ".gethrc version: $GETHRC_VERSION" + exit 1 +fi diff --git a/ops/tag-service/tag-service.py b/ops/tag-service/tag-service.py index 90b248174a96a..37d875e6abbcb 100755 --- a/ops/tag-service/tag-service.py +++ b/ops/tag-service/tag-service.py @@ -11,6 +11,7 @@ # Minimum version numbers for packages migrating from legacy versioning. MIN_VERSIONS = { 'ci-builder': '0.6.0', + 'chain-mon': '0.2.2', 'indexer': '0.5.0', 'op-node': '0.10.14', 'op-batcher': '0.10.14', diff --git a/package.json b/package.json index 555db1a874ff9..cbbcfc90b6ea4 100644 --- a/package.json +++ b/package.json @@ -40,32 +40,32 @@ "devDependencies": { "@babel/eslint-parser": "^7.18.2", "@changesets/changelog-github": "^0.4.8", - "@types/chai": "^4.3.7", + "@types/chai": "^4.3.8", "@types/chai-as-promised": "^7.1.4", - "@types/mocha": "^10.0.2", - "@types/node": "^20.8.5", - "@typescript-eslint/eslint-plugin": "^6.7.5", - "@typescript-eslint/parser": "^6.7.5", + "@types/mocha": "^10.0.4", + "@types/node": "^20.8.9", + "@typescript-eslint/eslint-plugin": "^6.10.0", + "@typescript-eslint/parser": "^6.9.1", "chai": "^4.3.10", - "depcheck": "^1.4.3", + "depcheck": "^1.4.7", "doctoc": "^2.2.0", - "eslint": "^8.51.0", + "eslint": "^8.53.0", "eslint-config-prettier": "^8.3.0", "eslint-config-standard": "^16.0.3", - "eslint-plugin-import": "^2.26.0", + "eslint-plugin-import": "^2.29.0", "eslint-plugin-jsdoc": "^35.1.2", "eslint-plugin-node": "^11.1.0", "eslint-plugin-prefer-arrow": "^1.2.3", "eslint-plugin-prettier": "^4.0.0", "eslint-plugin-promise": "^5.1.0", "eslint-plugin-react": "^7.24.0", - "eslint-plugin-unicorn": "^48.0.1", + "eslint-plugin-unicorn": "^49.0.0", "husky": "^8.0.3", - "lint-staged": "14.0.1", + "lint-staged": "15.0.2", "markdownlint": "^0.31.0", "markdownlint-cli2": "0.4.0", "mocha": "^10.2.0", - "nx": "16.10.0", + "nx": "17.0.3", "nyc": "^15.1.0", "patch-package": "^8.0.0", "prettier": "^2.8.0", diff --git a/packages/chain-mon/.env.example b/packages/chain-mon/.env.example index 3e952b04ca071..68354e4b43138 100644 --- a/packages/chain-mon/.env.example +++ b/packages/chain-mon/.env.example @@ -8,6 +8,18 @@ BALANCE_MON__RPC= # JSON array in the format [{ "address":
, "nickname": }, ... ] BALANCE_MON__ACCOUNTS= + +############################################################################### +# ↓ multisig-mon ↓ # +############################################################################### + +# RPC pointing to network to monitor safe nonces on +MULTISIG_MON__RPC= + +# JSON array in the format [{ "address":
, "nickname": }, ... ] +MULTISIG_MON__ACCOUNTS= + + ############################################################################### # ↓ wallet-mon ↓ # ############################################################################### diff --git a/packages/chain-mon/CHANGELOG.md b/packages/chain-mon/CHANGELOG.md index 0585ce35ce45e..7d989cd321f03 100644 --- a/packages/chain-mon/CHANGELOG.md +++ b/packages/chain-mon/CHANGELOG.md @@ -1,5 +1,11 @@ # @eth-optimism/drippie-mon +## 0.5.2 + +### Patch Changes + +- [#7824](https://github.com/ethereum-optimism/optimism/pull/7824) [`98eb885f5`](https://github.com/ethereum-optimism/optimism/commit/98eb885f5003ee5e6b9bbd532a42bba2ad39cb4b) Thanks [@roninjin10](https://github.com/roninjin10)! - Bump node version to LTS node 20.9.0 + ## 0.5.1 ### Patch Changes diff --git a/packages/chain-mon/package.json b/packages/chain-mon/package.json index d66969e11ab21..75fc807a43345 100644 --- a/packages/chain-mon/package.json +++ b/packages/chain-mon/package.json @@ -1,7 +1,7 @@ { "private": true, "name": "@eth-optimism/chain-mon", - "version": "0.5.1", + "version": "0.5.2", "description": "[Optimism] Chain monitoring services", "main": "dist/index", "types": "dist/index", @@ -9,12 +9,22 @@ "dist/*" ], "scripts": { + "dev:balance-mon": "tsx watch ./src/balance-mon/service.ts", + "dev:drippie-mon": "tsx watch ./src/drippie-mon/service.ts", + "dev:fault-mon": "tsx watch ./src/fault-mon/service.ts", + "dev:multisig-mon": "tsx watch ./src/multisig-mon/service.ts", + "dev:replica-mon": "tsx watch ./src/replica-mon/service.ts", + "dev:wallet-mon": "tsx watch ./src/wallet-mon/service.ts", + "dev:wd-mon": "tsx watch ./src/wd-mon/service.ts", + "start:balance-mon": "tsx ./src/balance-mon/service.ts", - "start:wallet-mon": "tsx ./src/wallet-mon/service.ts", "start:drippie-mon": "tsx ./src/drippie-mon/service.ts", - "start:wd-mon": "tsx ./src/wd-mon/service.ts", "start:fault-mon": "tsx ./src/fault-mon/service.ts", + "start:multisig-mon": "tsx ./src/multisig-mon/service.ts", "start:replica-mon": "tsx ./src/replica-mon/service.ts", + "start:wallet-mon": "tsx ./src/wallet-mon/service.ts", + "start:wd-mon": "tsx ./src/wd-mon/service.ts", + "test": "hardhat test", "test:coverage": "nyc hardhat test && nyc merge .nyc_output coverage.json", "build": "tsc -p ./tsconfig.json", @@ -53,8 +63,8 @@ "@ethersproject/abstract-provider": "^5.7.0", "@nomiclabs/hardhat-ethers": "^2.2.3", "@nomiclabs/hardhat-waffle": "^2.0.6", - "hardhat": "^2.18.1", + "hardhat": "^2.19.0", "ts-node": "^10.9.1", - "tsx": "^3.12.7" + "tsx": "^3.14.0" } } diff --git a/packages/chain-mon/src/abi/IGnosisSafe.0.8.19.json b/packages/chain-mon/src/abi/IGnosisSafe.0.8.19.json new file mode 100644 index 0000000000000..2153157f38717 --- /dev/null +++ b/packages/chain-mon/src/abi/IGnosisSafe.0.8.19.json @@ -0,0 +1,6991 @@ +{ + "abi": [ + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "owner", + "type": "address" + } + ], + "name": "AddedOwner", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "bytes32", + "name": "approvedHash", + "type": "bytes32" + }, + { + "indexed": true, + "internalType": "address", + "name": "owner", + "type": "address" + } + ], + "name": "ApproveHash", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "handler", + "type": "address" + } + ], + "name": "ChangedFallbackHandler", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "guard", + "type": "address" + } + ], + "name": "ChangedGuard", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "threshold", + "type": "uint256" + } + ], + "name": "ChangedThreshold", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "module", + "type": "address" + } + ], + "name": "DisabledModule", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "module", + "type": "address" + } + ], + "name": "EnabledModule", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "bytes32", + "name": "txHash", + "type": "bytes32" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "payment", + "type": "uint256" + } + ], + "name": "ExecutionFailure", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "module", + "type": "address" + } + ], + "name": "ExecutionFromModuleFailure", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "module", + "type": "address" + } + ], + "name": "ExecutionFromModuleSuccess", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "bytes32", + "name": "txHash", + "type": "bytes32" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "payment", + "type": "uint256" + } + ], + "name": "ExecutionSuccess", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "owner", + "type": "address" + } + ], + "name": "RemovedOwner", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "sender", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "value", + "type": "uint256" + } + ], + "name": "SafeReceived", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "initiator", + "type": "address" + }, + { + "indexed": false, + "internalType": "address[]", + "name": "owners", + "type": "address[]" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "threshold", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "address", + "name": "initializer", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "fallbackHandler", + "type": "address" + } + ], + "name": "SafeSetup", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "bytes32", + "name": "msgHash", + "type": "bytes32" + } + ], + "name": "SignMsg", + "type": "event" + }, + { + "inputs": [], + "name": "VERSION", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "owner", + "type": "address" + }, + { + "internalType": "uint256", + "name": "_threshold", + "type": "uint256" + } + ], + "name": "addOwnerWithThreshold", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "bytes32", + "name": "hashToApprove", + "type": "bytes32" + } + ], + "name": "approveHash", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + }, + { + "internalType": "bytes32", + "name": "", + "type": "bytes32" + } + ], + "name": "approvedHashes", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_threshold", + "type": "uint256" + } + ], + "name": "changeThreshold", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "bytes32", + "name": "dataHash", + "type": "bytes32" + }, + { + "internalType": "bytes", + "name": "data", + "type": "bytes" + }, + { + "internalType": "bytes", + "name": "signatures", + "type": "bytes" + }, + { + "internalType": "uint256", + "name": "requiredSignatures", + "type": "uint256" + } + ], + "name": "checkNSignatures", + "outputs": [], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "bytes32", + "name": "dataHash", + "type": "bytes32" + }, + { + "internalType": "bytes", + "name": "data", + "type": "bytes" + }, + { + "internalType": "bytes", + "name": "signatures", + "type": "bytes" + } + ], + "name": "checkSignatures", + "outputs": [], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "prevModule", + "type": "address" + }, + { + "internalType": "address", + "name": "module", + "type": "address" + } + ], + "name": "disableModule", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "domainSeparator", + "outputs": [ + { + "internalType": "bytes32", + "name": "", + "type": "bytes32" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "module", + "type": "address" + } + ], + "name": "enableModule", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "value", + "type": "uint256" + }, + { + "internalType": "bytes", + "name": "data", + "type": "bytes" + }, + { + "internalType": "enum Enum.Operation", + "name": "operation", + "type": "uint8" + }, + { + "internalType": "uint256", + "name": "safeTxGas", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "baseGas", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "gasPrice", + "type": "uint256" + }, + { + "internalType": "address", + "name": "gasToken", + "type": "address" + }, + { + "internalType": "address", + "name": "refundReceiver", + "type": "address" + }, + { + "internalType": "uint256", + "name": "_nonce", + "type": "uint256" + } + ], + "name": "encodeTransactionData", + "outputs": [ + { + "internalType": "bytes", + "name": "", + "type": "bytes" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "value", + "type": "uint256" + }, + { + "internalType": "bytes", + "name": "data", + "type": "bytes" + }, + { + "internalType": "enum Enum.Operation", + "name": "operation", + "type": "uint8" + }, + { + "internalType": "uint256", + "name": "safeTxGas", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "baseGas", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "gasPrice", + "type": "uint256" + }, + { + "internalType": "address", + "name": "gasToken", + "type": "address" + }, + { + "internalType": "address", + "name": "refundReceiver", + "type": "address" + }, + { + "internalType": "bytes", + "name": "signatures", + "type": "bytes" + } + ], + "name": "execTransaction", + "outputs": [ + { + "internalType": "bool", + "name": "success", + "type": "bool" + } + ], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "value", + "type": "uint256" + }, + { + "internalType": "bytes", + "name": "data", + "type": "bytes" + }, + { + "internalType": "enum Enum.Operation", + "name": "operation", + "type": "uint8" + } + ], + "name": "execTransactionFromModule", + "outputs": [ + { + "internalType": "bool", + "name": "success", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "value", + "type": "uint256" + }, + { + "internalType": "bytes", + "name": "data", + "type": "bytes" + }, + { + "internalType": "enum Enum.Operation", + "name": "operation", + "type": "uint8" + } + ], + "name": "execTransactionFromModuleReturnData", + "outputs": [ + { + "internalType": "bool", + "name": "success", + "type": "bool" + }, + { + "internalType": "bytes", + "name": "returnData", + "type": "bytes" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "getChainId", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "start", + "type": "address" + }, + { + "internalType": "uint256", + "name": "pageSize", + "type": "uint256" + } + ], + "name": "getModulesPaginated", + "outputs": [ + { + "internalType": "address[]", + "name": "array", + "type": "address[]" + }, + { + "internalType": "address", + "name": "next", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getOwners", + "outputs": [ + { + "internalType": "address[]", + "name": "", + "type": "address[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "offset", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "length", + "type": "uint256" + } + ], + "name": "getStorageAt", + "outputs": [ + { + "internalType": "bytes", + "name": "", + "type": "bytes" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "getThreshold", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "value", + "type": "uint256" + }, + { + "internalType": "bytes", + "name": "data", + "type": "bytes" + }, + { + "internalType": "enum Enum.Operation", + "name": "operation", + "type": "uint8" + }, + { + "internalType": "uint256", + "name": "safeTxGas", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "baseGas", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "gasPrice", + "type": "uint256" + }, + { + "internalType": "address", + "name": "gasToken", + "type": "address" + }, + { + "internalType": "address", + "name": "refundReceiver", + "type": "address" + }, + { + "internalType": "uint256", + "name": "_nonce", + "type": "uint256" + } + ], + "name": "getTransactionHash", + "outputs": [ + { + "internalType": "bytes32", + "name": "", + "type": "bytes32" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "module", + "type": "address" + } + ], + "name": "isModuleEnabled", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "owner", + "type": "address" + } + ], + "name": "isOwner", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "nonce", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "prevOwner", + "type": "address" + }, + { + "internalType": "address", + "name": "owner", + "type": "address" + }, + { + "internalType": "uint256", + "name": "_threshold", + "type": "uint256" + } + ], + "name": "removeOwner", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "value", + "type": "uint256" + }, + { + "internalType": "bytes", + "name": "data", + "type": "bytes" + }, + { + "internalType": "enum Enum.Operation", + "name": "operation", + "type": "uint8" + } + ], + "name": "requiredTxGas", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "handler", + "type": "address" + } + ], + "name": "setFallbackHandler", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "guard", + "type": "address" + } + ], + "name": "setGuard", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address[]", + "name": "_owners", + "type": "address[]" + }, + { + "internalType": "uint256", + "name": "_threshold", + "type": "uint256" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "bytes", + "name": "data", + "type": "bytes" + }, + { + "internalType": "address", + "name": "fallbackHandler", + "type": "address" + }, + { + "internalType": "address", + "name": "paymentToken", + "type": "address" + }, + { + "internalType": "uint256", + "name": "payment", + "type": "uint256" + }, + { + "internalType": "address", + "name": "paymentReceiver", + "type": "address" + } + ], + "name": "setup", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "bytes32", + "name": "", + "type": "bytes32" + } + ], + "name": "signedMessages", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "targetContract", + "type": "address" + }, + { + "internalType": "bytes", + "name": "calldataPayload", + "type": "bytes" + } + ], + "name": "simulateAndRevert", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "prevOwner", + "type": "address" + }, + { + "internalType": "address", + "name": "oldOwner", + "type": "address" + }, + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "swapOwner", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } + ], + "bytecode": { + "object": "0x", + "sourceMap": "", + "linkReferences": {} + }, + "deployedBytecode": { + "object": "0x", + "sourceMap": "", + "linkReferences": {} + }, + "methodIdentifiers": { + "VERSION()": "ffa1ad74", + "addOwnerWithThreshold(address,uint256)": "0d582f13", + "approveHash(bytes32)": "d4d9bdcd", + "approvedHashes(address,bytes32)": "7d832974", + "changeThreshold(uint256)": "694e80c3", + "checkNSignatures(bytes32,bytes,bytes,uint256)": "12fb68e0", + "checkSignatures(bytes32,bytes,bytes)": "934f3a11", + "disableModule(address,address)": "e009cfde", + "domainSeparator()": "f698da25", + "enableModule(address)": "610b5925", + "encodeTransactionData(address,uint256,bytes,uint8,uint256,uint256,uint256,address,address,uint256)": "e86637db", + "execTransaction(address,uint256,bytes,uint8,uint256,uint256,uint256,address,address,bytes)": "6a761202", + "execTransactionFromModule(address,uint256,bytes,uint8)": "468721a7", + "execTransactionFromModuleReturnData(address,uint256,bytes,uint8)": "5229073f", + "getChainId()": "3408e470", + "getModulesPaginated(address,uint256)": "cc2f8452", + "getOwners()": "a0e67e2b", + "getStorageAt(uint256,uint256)": "5624b25b", + "getThreshold()": "e75235b8", + "getTransactionHash(address,uint256,bytes,uint8,uint256,uint256,uint256,address,address,uint256)": "d8d11f78", + "isModuleEnabled(address)": "2d9ad53d", + "isOwner(address)": "2f54bf6e", + "nonce()": "affed0e0", + "removeOwner(address,address,uint256)": "f8dc5dd9", + "requiredTxGas(address,uint256,bytes,uint8)": "c4ca3a9c", + "setFallbackHandler(address)": "f08a0323", + "setGuard(address)": "e19a9dd9", + "setup(address[],uint256,address,bytes,address,address,uint256,address)": "b63e800d", + "signedMessages(bytes32)": "5ae6bd37", + "simulateAndRevert(address,bytes)": "b4faba09", + "swapOwner(address,address,address)": "e318b52b" + }, + "rawMetadata": "{\"compiler\":{\"version\":\"0.8.19+commit.7dd6d404\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"AddedOwner\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"approvedHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"ApproveHash\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"handler\",\"type\":\"address\"}],\"name\":\"ChangedFallbackHandler\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"guard\",\"type\":\"address\"}],\"name\":\"ChangedGuard\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"threshold\",\"type\":\"uint256\"}],\"name\":\"ChangedThreshold\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"module\",\"type\":\"address\"}],\"name\":\"DisabledModule\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"module\",\"type\":\"address\"}],\"name\":\"EnabledModule\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"txHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"payment\",\"type\":\"uint256\"}],\"name\":\"ExecutionFailure\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"module\",\"type\":\"address\"}],\"name\":\"ExecutionFromModuleFailure\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"module\",\"type\":\"address\"}],\"name\":\"ExecutionFromModuleSuccess\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"txHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"payment\",\"type\":\"uint256\"}],\"name\":\"ExecutionSuccess\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"RemovedOwner\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"SafeReceived\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"initiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"owners\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"threshold\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"initializer\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"fallbackHandler\",\"type\":\"address\"}],\"name\":\"SafeSetup\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"msgHash\",\"type\":\"bytes32\"}],\"name\":\"SignMsg\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"VERSION\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_threshold\",\"type\":\"uint256\"}],\"name\":\"addOwnerWithThreshold\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"hashToApprove\",\"type\":\"bytes32\"}],\"name\":\"approveHash\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"approvedHashes\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_threshold\",\"type\":\"uint256\"}],\"name\":\"changeThreshold\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"dataHash\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signatures\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"requiredSignatures\",\"type\":\"uint256\"}],\"name\":\"checkNSignatures\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"dataHash\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"signatures\",\"type\":\"bytes\"}],\"name\":\"checkSignatures\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"prevModule\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"module\",\"type\":\"address\"}],\"name\":\"disableModule\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"domainSeparator\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"module\",\"type\":\"address\"}],\"name\":\"enableModule\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"enum Enum.Operation\",\"name\":\"operation\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"safeTxGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"baseGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"gasToken\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"refundReceiver\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_nonce\",\"type\":\"uint256\"}],\"name\":\"encodeTransactionData\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"enum Enum.Operation\",\"name\":\"operation\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"safeTxGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"baseGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"gasToken\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"refundReceiver\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"signatures\",\"type\":\"bytes\"}],\"name\":\"execTransaction\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"}],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"enum Enum.Operation\",\"name\":\"operation\",\"type\":\"uint8\"}],\"name\":\"execTransactionFromModule\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"enum Enum.Operation\",\"name\":\"operation\",\"type\":\"uint8\"}],\"name\":\"execTransactionFromModuleReturnData\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"returnData\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getChainId\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"start\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"pageSize\",\"type\":\"uint256\"}],\"name\":\"getModulesPaginated\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"array\",\"type\":\"address[]\"},{\"internalType\":\"address\",\"name\":\"next\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getOwners\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"offset\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"length\",\"type\":\"uint256\"}],\"name\":\"getStorageAt\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getThreshold\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"enum Enum.Operation\",\"name\":\"operation\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"safeTxGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"baseGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"gasToken\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"refundReceiver\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_nonce\",\"type\":\"uint256\"}],\"name\":\"getTransactionHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"module\",\"type\":\"address\"}],\"name\":\"isModuleEnabled\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"isOwner\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"nonce\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"prevOwner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_threshold\",\"type\":\"uint256\"}],\"name\":\"removeOwner\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"enum Enum.Operation\",\"name\":\"operation\",\"type\":\"uint8\"}],\"name\":\"requiredTxGas\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"handler\",\"type\":\"address\"}],\"name\":\"setFallbackHandler\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"guard\",\"type\":\"address\"}],\"name\":\"setGuard\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_owners\",\"type\":\"address[]\"},{\"internalType\":\"uint256\",\"name\":\"_threshold\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"fallbackHandler\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"paymentToken\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"payment\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"paymentReceiver\",\"type\":\"address\"}],\"name\":\"setup\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"signedMessages\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"targetContract\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"calldataPayload\",\"type\":\"bytes\"}],\"name\":\"simulateAndRevert\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"prevOwner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"oldOwner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"swapOwner\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}],\"devdoc\":{\"kind\":\"dev\",\"methods\":{},\"title\":\"IGnosisSafe - Gnosis Safe Interface\",\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{},\"version\":1}},\"settings\":{\"compilationTarget\":{\"scripts/interfaces/IGnosisSafe.sol\":\"IGnosisSafe\"},\"evmVersion\":\"paris\",\"libraries\":{},\"metadata\":{\"bytecodeHash\":\"none\"},\"optimizer\":{\"enabled\":true,\"runs\":999999},\"remappings\":[\":@cwia/=lib/clones-with-immutable-args/src/\",\":@openzeppelin/contracts-upgradeable/=lib/openzeppelin-contracts-upgradeable/contracts/\",\":@openzeppelin/contracts/=lib/openzeppelin-contracts/contracts/\",\":@rari-capital/solmate/=lib/solmate/\",\":clones-with-immutable-args/=lib/clones-with-immutable-args/src/\",\":ds-test/=lib/forge-std/lib/ds-test/src/\",\":forge-std/=lib/forge-std/src/\",\":openzeppelin-contracts-upgradeable/=lib/openzeppelin-contracts-upgradeable/\",\":openzeppelin-contracts/=lib/openzeppelin-contracts/\",\":safe-contracts/=lib/safe-contracts/contracts/\",\":solmate/=lib/solmate/src/\"]},\"sources\":{\"scripts/interfaces/IGnosisSafe.sol\":{\"keccak256\":\"0xb9a55c98ef4d6a18260d6432f633a4bd6c5f540bfa80c4dc89c5ec33fd9aeec5\",\"license\":\"LGPL-3.0-only\",\"urls\":[\"bzz-raw://e953fc0cb723a9197006697e372f1729af1de1860a9845f2574f98aa9add72aa\",\"dweb:/ipfs/QmTdBba1DFqPNcaBmEFDSN8JmR7xPKwWno2vqnhmBjoGMD\"]}},\"version\":1}", + "metadata": { + "compiler": { + "version": "0.8.19+commit.7dd6d404" + }, + "language": "Solidity", + "output": { + "abi": [ + { + "inputs": [ + { + "internalType": "address", + "name": "owner", + "type": "address", + "indexed": false + } + ], + "type": "event", + "name": "AddedOwner", + "anonymous": false + }, + { + "inputs": [ + { + "internalType": "bytes32", + "name": "approvedHash", + "type": "bytes32", + "indexed": true + }, + { + "internalType": "address", + "name": "owner", + "type": "address", + "indexed": true + } + ], + "type": "event", + "name": "ApproveHash", + "anonymous": false + }, + { + "inputs": [ + { + "internalType": "address", + "name": "handler", + "type": "address", + "indexed": false + } + ], + "type": "event", + "name": "ChangedFallbackHandler", + "anonymous": false + }, + { + "inputs": [ + { + "internalType": "address", + "name": "guard", + "type": "address", + "indexed": false + } + ], + "type": "event", + "name": "ChangedGuard", + "anonymous": false + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "threshold", + "type": "uint256", + "indexed": false + } + ], + "type": "event", + "name": "ChangedThreshold", + "anonymous": false + }, + { + "inputs": [ + { + "internalType": "address", + "name": "module", + "type": "address", + "indexed": false + } + ], + "type": "event", + "name": "DisabledModule", + "anonymous": false + }, + { + "inputs": [ + { + "internalType": "address", + "name": "module", + "type": "address", + "indexed": false + } + ], + "type": "event", + "name": "EnabledModule", + "anonymous": false + }, + { + "inputs": [ + { + "internalType": "bytes32", + "name": "txHash", + "type": "bytes32", + "indexed": false + }, + { + "internalType": "uint256", + "name": "payment", + "type": "uint256", + "indexed": false + } + ], + "type": "event", + "name": "ExecutionFailure", + "anonymous": false + }, + { + "inputs": [ + { + "internalType": "address", + "name": "module", + "type": "address", + "indexed": true + } + ], + "type": "event", + "name": "ExecutionFromModuleFailure", + "anonymous": false + }, + { + "inputs": [ + { + "internalType": "address", + "name": "module", + "type": "address", + "indexed": true + } + ], + "type": "event", + "name": "ExecutionFromModuleSuccess", + "anonymous": false + }, + { + "inputs": [ + { + "internalType": "bytes32", + "name": "txHash", + "type": "bytes32", + "indexed": false + }, + { + "internalType": "uint256", + "name": "payment", + "type": "uint256", + "indexed": false + } + ], + "type": "event", + "name": "ExecutionSuccess", + "anonymous": false + }, + { + "inputs": [ + { + "internalType": "address", + "name": "owner", + "type": "address", + "indexed": false + } + ], + "type": "event", + "name": "RemovedOwner", + "anonymous": false + }, + { + "inputs": [ + { + "internalType": "address", + "name": "sender", + "type": "address", + "indexed": true + }, + { + "internalType": "uint256", + "name": "value", + "type": "uint256", + "indexed": false + } + ], + "type": "event", + "name": "SafeReceived", + "anonymous": false + }, + { + "inputs": [ + { + "internalType": "address", + "name": "initiator", + "type": "address", + "indexed": true + }, + { + "internalType": "address[]", + "name": "owners", + "type": "address[]", + "indexed": false + }, + { + "internalType": "uint256", + "name": "threshold", + "type": "uint256", + "indexed": false + }, + { + "internalType": "address", + "name": "initializer", + "type": "address", + "indexed": false + }, + { + "internalType": "address", + "name": "fallbackHandler", + "type": "address", + "indexed": false + } + ], + "type": "event", + "name": "SafeSetup", + "anonymous": false + }, + { + "inputs": [ + { + "internalType": "bytes32", + "name": "msgHash", + "type": "bytes32", + "indexed": true + } + ], + "type": "event", + "name": "SignMsg", + "anonymous": false + }, + { + "inputs": [], + "stateMutability": "view", + "type": "function", + "name": "VERSION", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ] + }, + { + "inputs": [ + { + "internalType": "address", + "name": "owner", + "type": "address" + }, + { + "internalType": "uint256", + "name": "_threshold", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function", + "name": "addOwnerWithThreshold" + }, + { + "inputs": [ + { + "internalType": "bytes32", + "name": "hashToApprove", + "type": "bytes32" + } + ], + "stateMutability": "nonpayable", + "type": "function", + "name": "approveHash" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + }, + { + "internalType": "bytes32", + "name": "", + "type": "bytes32" + } + ], + "stateMutability": "view", + "type": "function", + "name": "approvedHashes", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ] + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "_threshold", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function", + "name": "changeThreshold" + }, + { + "inputs": [ + { + "internalType": "bytes32", + "name": "dataHash", + "type": "bytes32" + }, + { + "internalType": "bytes", + "name": "data", + "type": "bytes" + }, + { + "internalType": "bytes", + "name": "signatures", + "type": "bytes" + }, + { + "internalType": "uint256", + "name": "requiredSignatures", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function", + "name": "checkNSignatures" + }, + { + "inputs": [ + { + "internalType": "bytes32", + "name": "dataHash", + "type": "bytes32" + }, + { + "internalType": "bytes", + "name": "data", + "type": "bytes" + }, + { + "internalType": "bytes", + "name": "signatures", + "type": "bytes" + } + ], + "stateMutability": "view", + "type": "function", + "name": "checkSignatures" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "prevModule", + "type": "address" + }, + { + "internalType": "address", + "name": "module", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "function", + "name": "disableModule" + }, + { + "inputs": [], + "stateMutability": "view", + "type": "function", + "name": "domainSeparator", + "outputs": [ + { + "internalType": "bytes32", + "name": "", + "type": "bytes32" + } + ] + }, + { + "inputs": [ + { + "internalType": "address", + "name": "module", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "function", + "name": "enableModule" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "value", + "type": "uint256" + }, + { + "internalType": "bytes", + "name": "data", + "type": "bytes" + }, + { + "internalType": "enum Enum.Operation", + "name": "operation", + "type": "uint8" + }, + { + "internalType": "uint256", + "name": "safeTxGas", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "baseGas", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "gasPrice", + "type": "uint256" + }, + { + "internalType": "address", + "name": "gasToken", + "type": "address" + }, + { + "internalType": "address", + "name": "refundReceiver", + "type": "address" + }, + { + "internalType": "uint256", + "name": "_nonce", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function", + "name": "encodeTransactionData", + "outputs": [ + { + "internalType": "bytes", + "name": "", + "type": "bytes" + } + ] + }, + { + "inputs": [ + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "value", + "type": "uint256" + }, + { + "internalType": "bytes", + "name": "data", + "type": "bytes" + }, + { + "internalType": "enum Enum.Operation", + "name": "operation", + "type": "uint8" + }, + { + "internalType": "uint256", + "name": "safeTxGas", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "baseGas", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "gasPrice", + "type": "uint256" + }, + { + "internalType": "address", + "name": "gasToken", + "type": "address" + }, + { + "internalType": "address", + "name": "refundReceiver", + "type": "address" + }, + { + "internalType": "bytes", + "name": "signatures", + "type": "bytes" + } + ], + "stateMutability": "payable", + "type": "function", + "name": "execTransaction", + "outputs": [ + { + "internalType": "bool", + "name": "success", + "type": "bool" + } + ] + }, + { + "inputs": [ + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "value", + "type": "uint256" + }, + { + "internalType": "bytes", + "name": "data", + "type": "bytes" + }, + { + "internalType": "enum Enum.Operation", + "name": "operation", + "type": "uint8" + } + ], + "stateMutability": "nonpayable", + "type": "function", + "name": "execTransactionFromModule", + "outputs": [ + { + "internalType": "bool", + "name": "success", + "type": "bool" + } + ] + }, + { + "inputs": [ + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "value", + "type": "uint256" + }, + { + "internalType": "bytes", + "name": "data", + "type": "bytes" + }, + { + "internalType": "enum Enum.Operation", + "name": "operation", + "type": "uint8" + } + ], + "stateMutability": "nonpayable", + "type": "function", + "name": "execTransactionFromModuleReturnData", + "outputs": [ + { + "internalType": "bool", + "name": "success", + "type": "bool" + }, + { + "internalType": "bytes", + "name": "returnData", + "type": "bytes" + } + ] + }, + { + "inputs": [], + "stateMutability": "view", + "type": "function", + "name": "getChainId", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ] + }, + { + "inputs": [ + { + "internalType": "address", + "name": "start", + "type": "address" + }, + { + "internalType": "uint256", + "name": "pageSize", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function", + "name": "getModulesPaginated", + "outputs": [ + { + "internalType": "address[]", + "name": "array", + "type": "address[]" + }, + { + "internalType": "address", + "name": "next", + "type": "address" + } + ] + }, + { + "inputs": [], + "stateMutability": "view", + "type": "function", + "name": "getOwners", + "outputs": [ + { + "internalType": "address[]", + "name": "", + "type": "address[]" + } + ] + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "offset", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "length", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function", + "name": "getStorageAt", + "outputs": [ + { + "internalType": "bytes", + "name": "", + "type": "bytes" + } + ] + }, + { + "inputs": [], + "stateMutability": "view", + "type": "function", + "name": "getThreshold", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ] + }, + { + "inputs": [ + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "value", + "type": "uint256" + }, + { + "internalType": "bytes", + "name": "data", + "type": "bytes" + }, + { + "internalType": "enum Enum.Operation", + "name": "operation", + "type": "uint8" + }, + { + "internalType": "uint256", + "name": "safeTxGas", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "baseGas", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "gasPrice", + "type": "uint256" + }, + { + "internalType": "address", + "name": "gasToken", + "type": "address" + }, + { + "internalType": "address", + "name": "refundReceiver", + "type": "address" + }, + { + "internalType": "uint256", + "name": "_nonce", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function", + "name": "getTransactionHash", + "outputs": [ + { + "internalType": "bytes32", + "name": "", + "type": "bytes32" + } + ] + }, + { + "inputs": [ + { + "internalType": "address", + "name": "module", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function", + "name": "isModuleEnabled", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ] + }, + { + "inputs": [ + { + "internalType": "address", + "name": "owner", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function", + "name": "isOwner", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ] + }, + { + "inputs": [], + "stateMutability": "view", + "type": "function", + "name": "nonce", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ] + }, + { + "inputs": [ + { + "internalType": "address", + "name": "prevOwner", + "type": "address" + }, + { + "internalType": "address", + "name": "owner", + "type": "address" + }, + { + "internalType": "uint256", + "name": "_threshold", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function", + "name": "removeOwner" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "value", + "type": "uint256" + }, + { + "internalType": "bytes", + "name": "data", + "type": "bytes" + }, + { + "internalType": "enum Enum.Operation", + "name": "operation", + "type": "uint8" + } + ], + "stateMutability": "nonpayable", + "type": "function", + "name": "requiredTxGas", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ] + }, + { + "inputs": [ + { + "internalType": "address", + "name": "handler", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "function", + "name": "setFallbackHandler" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "guard", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "function", + "name": "setGuard" + }, + { + "inputs": [ + { + "internalType": "address[]", + "name": "_owners", + "type": "address[]" + }, + { + "internalType": "uint256", + "name": "_threshold", + "type": "uint256" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "bytes", + "name": "data", + "type": "bytes" + }, + { + "internalType": "address", + "name": "fallbackHandler", + "type": "address" + }, + { + "internalType": "address", + "name": "paymentToken", + "type": "address" + }, + { + "internalType": "uint256", + "name": "payment", + "type": "uint256" + }, + { + "internalType": "address", + "name": "paymentReceiver", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "function", + "name": "setup" + }, + { + "inputs": [ + { + "internalType": "bytes32", + "name": "", + "type": "bytes32" + } + ], + "stateMutability": "view", + "type": "function", + "name": "signedMessages", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ] + }, + { + "inputs": [ + { + "internalType": "address", + "name": "targetContract", + "type": "address" + }, + { + "internalType": "bytes", + "name": "calldataPayload", + "type": "bytes" + } + ], + "stateMutability": "nonpayable", + "type": "function", + "name": "simulateAndRevert" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "prevOwner", + "type": "address" + }, + { + "internalType": "address", + "name": "oldOwner", + "type": "address" + }, + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "function", + "name": "swapOwner" + } + ], + "devdoc": { + "kind": "dev", + "methods": {}, + "version": 1 + }, + "userdoc": { + "kind": "user", + "methods": {}, + "version": 1 + } + }, + "settings": { + "remappings": [ + "@cwia/=lib/clones-with-immutable-args/src/", + "@openzeppelin/contracts-upgradeable/=lib/openzeppelin-contracts-upgradeable/contracts/", + "@openzeppelin/contracts/=lib/openzeppelin-contracts/contracts/", + "@rari-capital/solmate/=lib/solmate/", + "clones-with-immutable-args/=lib/clones-with-immutable-args/src/", + "ds-test/=lib/forge-std/lib/ds-test/src/", + "forge-std/=lib/forge-std/src/", + "openzeppelin-contracts-upgradeable/=lib/openzeppelin-contracts-upgradeable/", + "openzeppelin-contracts/=lib/openzeppelin-contracts/", + "safe-contracts/=lib/safe-contracts/contracts/", + "solmate/=lib/solmate/src/" + ], + "optimizer": { + "enabled": true, + "runs": 999999 + }, + "metadata": { + "bytecodeHash": "none" + }, + "compilationTarget": { + "scripts/interfaces/IGnosisSafe.sol": "IGnosisSafe" + }, + "libraries": {} + }, + "sources": { + "scripts/interfaces/IGnosisSafe.sol": { + "keccak256": "0xb9a55c98ef4d6a18260d6432f633a4bd6c5f540bfa80c4dc89c5ec33fd9aeec5", + "urls": [ + "bzz-raw://e953fc0cb723a9197006697e372f1729af1de1860a9845f2574f98aa9add72aa", + "dweb:/ipfs/QmTdBba1DFqPNcaBmEFDSN8JmR7xPKwWno2vqnhmBjoGMD" + ], + "license": "LGPL-3.0-only" + } + }, + "version": 1 + }, + "storageLayout": { + "storage": [], + "types": {} + }, + "userdoc": { + "version": 1, + "kind": "user" + }, + "devdoc": { + "version": 1, + "kind": "dev", + "title": "IGnosisSafe - Gnosis Safe Interface" + }, + "ast": { + "absolutePath": "scripts/interfaces/IGnosisSafe.sol", + "id": 36017, + "exportedSymbols": { + "Enum": [ + 35629 + ], + "IGnosisSafe": [ + 36016 + ] + }, + "nodeType": "SourceUnit", + "src": "42:5070:43", + "nodes": [ + { + "id": 35624, + "nodeType": "PragmaDirective", + "src": "42:24:43", + "nodes": [], + "literals": [ + "solidity", + "^", + "0.8", + ".10" + ] + }, + { + "id": 35629, + "nodeType": "ContractDefinition", + "src": "172:88:43", + "nodes": [ + { + "id": 35628, + "nodeType": "EnumDefinition", + "src": "201:57:43", + "nodes": [], + "canonicalName": "Enum.Operation", + "members": [ + { + "id": 35626, + "name": "Call", + "nameLocation": "226:4:43", + "nodeType": "EnumValue", + "src": "226:4:43" + }, + { + "id": 35627, + "name": "DelegateCall", + "nameLocation": "240:12:43", + "nodeType": "EnumValue", + "src": "240:12:43" + } + ], + "name": "Operation", + "nameLocation": "206:9:43" + } + ], + "abstract": true, + "baseContracts": [], + "canonicalName": "Enum", + "contractDependencies": [], + "contractKind": "contract", + "documentation": { + "id": 35625, + "nodeType": "StructuredDocumentation", + "src": "68:104:43", + "text": "@title Enum - Collection of enums used in Safe contracts.\n @author Richard Meissner - @rmeissner" + }, + "fullyImplemented": true, + "linearizedBaseContracts": [ + 35629 + ], + "name": "Enum", + "nameLocation": "190:4:43", + "scope": 36017, + "usedErrors": [] + }, + { + "id": 36016, + "nodeType": "ContractDefinition", + "src": "309:4802:43", + "nodes": [ + { + "id": 35634, + "nodeType": "EventDefinition", + "src": "337:32:43", + "nodes": [], + "anonymous": false, + "eventSelector": "9465fa0c962cc76958e6373a993326400c1c94f8be2fe3a952adfa7f60b2ea26", + "name": "AddedOwner", + "nameLocation": "343:10:43", + "parameters": { + "id": 35633, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35632, + "indexed": false, + "mutability": "mutable", + "name": "owner", + "nameLocation": "362:5:43", + "nodeType": "VariableDeclaration", + "scope": 35634, + "src": "354:13:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 35631, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "354:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "visibility": "internal" + } + ], + "src": "353:15:43" + } + }, + { + "id": 35640, + "nodeType": "EventDefinition", + "src": "374:71:43", + "nodes": [], + "anonymous": false, + "eventSelector": "f2a0eb156472d1440255b0d7c1e19cc07115d1051fe605b0dce69acfec884d9c", + "name": "ApproveHash", + "nameLocation": "380:11:43", + "parameters": { + "id": 35639, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35636, + "indexed": true, + "mutability": "mutable", + "name": "approvedHash", + "nameLocation": "408:12:43", + "nodeType": "VariableDeclaration", + "scope": 35640, + "src": "392:28:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 35635, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "392:7:43", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35638, + "indexed": true, + "mutability": "mutable", + "name": "owner", + "nameLocation": "438:5:43", + "nodeType": "VariableDeclaration", + "scope": 35640, + "src": "422:21:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 35637, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "422:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "visibility": "internal" + } + ], + "src": "391:53:43" + } + }, + { + "id": 35644, + "nodeType": "EventDefinition", + "src": "450:46:43", + "nodes": [], + "anonymous": false, + "eventSelector": "5ac6c46c93c8d0e53714ba3b53db3e7c046da994313d7ed0d192028bc7c228b0", + "name": "ChangedFallbackHandler", + "nameLocation": "456:22:43", + "parameters": { + "id": 35643, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35642, + "indexed": false, + "mutability": "mutable", + "name": "handler", + "nameLocation": "487:7:43", + "nodeType": "VariableDeclaration", + "scope": 35644, + "src": "479:15:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 35641, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "479:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "visibility": "internal" + } + ], + "src": "478:17:43" + } + }, + { + "id": 35648, + "nodeType": "EventDefinition", + "src": "501:34:43", + "nodes": [], + "anonymous": false, + "eventSelector": "1151116914515bc0891ff9047a6cb32cf902546f83066499bcf8ba33d2353fa2", + "name": "ChangedGuard", + "nameLocation": "507:12:43", + "parameters": { + "id": 35647, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35646, + "indexed": false, + "mutability": "mutable", + "name": "guard", + "nameLocation": "528:5:43", + "nodeType": "VariableDeclaration", + "scope": 35648, + "src": "520:13:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 35645, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "520:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "visibility": "internal" + } + ], + "src": "519:15:43" + } + }, + { + "id": 35652, + "nodeType": "EventDefinition", + "src": "540:42:43", + "nodes": [], + "anonymous": false, + "eventSelector": "610f7ff2b304ae8903c3de74c60c6ab1f7d6226b3f52c5161905bb5ad4039c93", + "name": "ChangedThreshold", + "nameLocation": "546:16:43", + "parameters": { + "id": 35651, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35650, + "indexed": false, + "mutability": "mutable", + "name": "threshold", + "nameLocation": "571:9:43", + "nodeType": "VariableDeclaration", + "scope": 35652, + "src": "563:17:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 35649, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "563:7:43", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "visibility": "internal" + } + ], + "src": "562:19:43" + } + }, + { + "id": 35656, + "nodeType": "EventDefinition", + "src": "587:37:43", + "nodes": [], + "anonymous": false, + "eventSelector": "aab4fa2b463f581b2b32cb3b7e3b704b9ce37cc209b5fb4d77e593ace4054276", + "name": "DisabledModule", + "nameLocation": "593:14:43", + "parameters": { + "id": 35655, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35654, + "indexed": false, + "mutability": "mutable", + "name": "module", + "nameLocation": "616:6:43", + "nodeType": "VariableDeclaration", + "scope": 35656, + "src": "608:14:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 35653, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "608:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "visibility": "internal" + } + ], + "src": "607:16:43" + } + }, + { + "id": 35660, + "nodeType": "EventDefinition", + "src": "629:36:43", + "nodes": [], + "anonymous": false, + "eventSelector": "ecdf3a3effea5783a3c4c2140e677577666428d44ed9d474a0b3a4c9943f8440", + "name": "EnabledModule", + "nameLocation": "635:13:43", + "parameters": { + "id": 35659, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35658, + "indexed": false, + "mutability": "mutable", + "name": "module", + "nameLocation": "657:6:43", + "nodeType": "VariableDeclaration", + "scope": 35660, + "src": "649:14:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 35657, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "649:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "visibility": "internal" + } + ], + "src": "648:16:43" + } + }, + { + "id": 35666, + "nodeType": "EventDefinition", + "src": "670:56:43", + "nodes": [], + "anonymous": false, + "eventSelector": "23428b18acfb3ea64b08dc0c1d296ea9c09702c09083ca5272e64d115b687d23", + "name": "ExecutionFailure", + "nameLocation": "676:16:43", + "parameters": { + "id": 35665, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35662, + "indexed": false, + "mutability": "mutable", + "name": "txHash", + "nameLocation": "701:6:43", + "nodeType": "VariableDeclaration", + "scope": 35666, + "src": "693:14:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 35661, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "693:7:43", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35664, + "indexed": false, + "mutability": "mutable", + "name": "payment", + "nameLocation": "717:7:43", + "nodeType": "VariableDeclaration", + "scope": 35666, + "src": "709:15:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 35663, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "709:7:43", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "visibility": "internal" + } + ], + "src": "692:33:43" + } + }, + { + "id": 35670, + "nodeType": "EventDefinition", + "src": "731:57:43", + "nodes": [], + "anonymous": false, + "eventSelector": "acd2c8702804128fdb0db2bb49f6d127dd0181c13fd45dbfe16de0930e2bd375", + "name": "ExecutionFromModuleFailure", + "nameLocation": "737:26:43", + "parameters": { + "id": 35669, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35668, + "indexed": true, + "mutability": "mutable", + "name": "module", + "nameLocation": "780:6:43", + "nodeType": "VariableDeclaration", + "scope": 35670, + "src": "764:22:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 35667, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "764:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "visibility": "internal" + } + ], + "src": "763:24:43" + } + }, + { + "id": 35674, + "nodeType": "EventDefinition", + "src": "793:57:43", + "nodes": [], + "anonymous": false, + "eventSelector": "6895c13664aa4f67288b25d7a21d7aaa34916e355fb9b6fae0a139a9085becb8", + "name": "ExecutionFromModuleSuccess", + "nameLocation": "799:26:43", + "parameters": { + "id": 35673, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35672, + "indexed": true, + "mutability": "mutable", + "name": "module", + "nameLocation": "842:6:43", + "nodeType": "VariableDeclaration", + "scope": 35674, + "src": "826:22:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 35671, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "826:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "visibility": "internal" + } + ], + "src": "825:24:43" + } + }, + { + "id": 35680, + "nodeType": "EventDefinition", + "src": "855:56:43", + "nodes": [], + "anonymous": false, + "eventSelector": "442e715f626346e8c54381002da614f62bee8d27386535b2521ec8540898556e", + "name": "ExecutionSuccess", + "nameLocation": "861:16:43", + "parameters": { + "id": 35679, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35676, + "indexed": false, + "mutability": "mutable", + "name": "txHash", + "nameLocation": "886:6:43", + "nodeType": "VariableDeclaration", + "scope": 35680, + "src": "878:14:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 35675, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "878:7:43", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35678, + "indexed": false, + "mutability": "mutable", + "name": "payment", + "nameLocation": "902:7:43", + "nodeType": "VariableDeclaration", + "scope": 35680, + "src": "894:15:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 35677, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "894:7:43", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "visibility": "internal" + } + ], + "src": "877:33:43" + } + }, + { + "id": 35684, + "nodeType": "EventDefinition", + "src": "916:34:43", + "nodes": [], + "anonymous": false, + "eventSelector": "f8d49fc529812e9a7c5c50e69c20f0dccc0db8fa95c98bc58cc9a4f1c1299eaf", + "name": "RemovedOwner", + "nameLocation": "922:12:43", + "parameters": { + "id": 35683, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35682, + "indexed": false, + "mutability": "mutable", + "name": "owner", + "nameLocation": "943:5:43", + "nodeType": "VariableDeclaration", + "scope": 35684, + "src": "935:13:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 35681, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "935:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "visibility": "internal" + } + ], + "src": "934:15:43" + } + }, + { + "id": 35690, + "nodeType": "EventDefinition", + "src": "955:58:43", + "nodes": [], + "anonymous": false, + "eventSelector": "3d0ce9bfc3ed7d6862dbb28b2dea94561fe714a1b4d019aa8af39730d1ad7c3d", + "name": "SafeReceived", + "nameLocation": "961:12:43", + "parameters": { + "id": 35689, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35686, + "indexed": true, + "mutability": "mutable", + "name": "sender", + "nameLocation": "990:6:43", + "nodeType": "VariableDeclaration", + "scope": 35690, + "src": "974:22:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 35685, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "974:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35688, + "indexed": false, + "mutability": "mutable", + "name": "value", + "nameLocation": "1006:5:43", + "nodeType": "VariableDeclaration", + "scope": 35690, + "src": "998:13:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 35687, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "998:7:43", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "visibility": "internal" + } + ], + "src": "973:39:43" + } + }, + { + "id": 35703, + "nodeType": "EventDefinition", + "src": "1018:140:43", + "nodes": [], + "anonymous": false, + "eventSelector": "141df868a6331af528e38c83b7aa03edc19be66e37ae67f9285bf4f8e3c6a1a8", + "name": "SafeSetup", + "nameLocation": "1024:9:43", + "parameters": { + "id": 35702, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35692, + "indexed": true, + "mutability": "mutable", + "name": "initiator", + "nameLocation": "1059:9:43", + "nodeType": "VariableDeclaration", + "scope": 35703, + "src": "1043:25:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 35691, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1043:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35695, + "indexed": false, + "mutability": "mutable", + "name": "owners", + "nameLocation": "1080:6:43", + "nodeType": "VariableDeclaration", + "scope": 35703, + "src": "1070:16:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr", + "typeString": "address[]" + }, + "typeName": { + "baseType": { + "id": 35693, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1070:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 35694, + "nodeType": "ArrayTypeName", + "src": "1070:9:43", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr", + "typeString": "address[]" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35697, + "indexed": false, + "mutability": "mutable", + "name": "threshold", + "nameLocation": "1096:9:43", + "nodeType": "VariableDeclaration", + "scope": 35703, + "src": "1088:17:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 35696, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1088:7:43", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35699, + "indexed": false, + "mutability": "mutable", + "name": "initializer", + "nameLocation": "1115:11:43", + "nodeType": "VariableDeclaration", + "scope": 35703, + "src": "1107:19:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 35698, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1107:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35701, + "indexed": false, + "mutability": "mutable", + "name": "fallbackHandler", + "nameLocation": "1136:15:43", + "nodeType": "VariableDeclaration", + "scope": 35703, + "src": "1128:23:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 35700, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1128:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "visibility": "internal" + } + ], + "src": "1033:124:43" + } + }, + { + "id": 35707, + "nodeType": "EventDefinition", + "src": "1163:39:43", + "nodes": [], + "anonymous": false, + "eventSelector": "e7f4675038f4f6034dfcbbb24c4dc08e4ebf10eb9d257d3d02c0f38d122ac6e4", + "name": "SignMsg", + "nameLocation": "1169:7:43", + "parameters": { + "id": 35706, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35705, + "indexed": true, + "mutability": "mutable", + "name": "msgHash", + "nameLocation": "1193:7:43", + "nodeType": "VariableDeclaration", + "scope": 35707, + "src": "1177:23:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 35704, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "1177:7:43", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "visibility": "internal" + } + ], + "src": "1176:25:43" + } + }, + { + "id": 35712, + "nodeType": "FunctionDefinition", + "src": "1208:57:43", + "nodes": [], + "functionSelector": "ffa1ad74", + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "VERSION", + "nameLocation": "1217:7:43", + "parameters": { + "id": 35708, + "nodeType": "ParameterList", + "parameters": [], + "src": "1224:2:43" + }, + "returnParameters": { + "id": 35711, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35710, + "mutability": "mutable", + "name": "", + "nameLocation": "-1:-1:-1", + "nodeType": "VariableDeclaration", + "scope": 35712, + "src": "1250:13:43", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string" + }, + "typeName": { + "id": 35709, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "1250:6:43", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "visibility": "internal" + } + ], + "src": "1249:15:43" + }, + "scope": 36016, + "stateMutability": "view", + "virtual": false, + "visibility": "external" + }, + { + "id": 35719, + "nodeType": "FunctionDefinition", + "src": "1270:75:43", + "nodes": [], + "functionSelector": "0d582f13", + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "addOwnerWithThreshold", + "nameLocation": "1279:21:43", + "parameters": { + "id": 35717, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35714, + "mutability": "mutable", + "name": "owner", + "nameLocation": "1309:5:43", + "nodeType": "VariableDeclaration", + "scope": 35719, + "src": "1301:13:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 35713, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1301:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35716, + "mutability": "mutable", + "name": "_threshold", + "nameLocation": "1324:10:43", + "nodeType": "VariableDeclaration", + "scope": 35719, + "src": "1316:18:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 35715, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1316:7:43", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "visibility": "internal" + } + ], + "src": "1300:35:43" + }, + "returnParameters": { + "id": 35718, + "nodeType": "ParameterList", + "parameters": [], + "src": "1344:0:43" + }, + "scope": 36016, + "stateMutability": "nonpayable", + "virtual": false, + "visibility": "external" + }, + { + "id": 35724, + "nodeType": "FunctionDefinition", + "src": "1350:53:43", + "nodes": [], + "functionSelector": "d4d9bdcd", + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "approveHash", + "nameLocation": "1359:11:43", + "parameters": { + "id": 35722, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35721, + "mutability": "mutable", + "name": "hashToApprove", + "nameLocation": "1379:13:43", + "nodeType": "VariableDeclaration", + "scope": 35724, + "src": "1371:21:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 35720, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "1371:7:43", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "visibility": "internal" + } + ], + "src": "1370:23:43" + }, + "returnParameters": { + "id": 35723, + "nodeType": "ParameterList", + "parameters": [], + "src": "1402:0:43" + }, + "scope": 36016, + "stateMutability": "nonpayable", + "virtual": false, + "visibility": "external" + }, + { + "id": 35733, + "nodeType": "FunctionDefinition", + "src": "1408:74:43", + "nodes": [], + "functionSelector": "7d832974", + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "approvedHashes", + "nameLocation": "1417:14:43", + "parameters": { + "id": 35729, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35726, + "mutability": "mutable", + "name": "", + "nameLocation": "-1:-1:-1", + "nodeType": "VariableDeclaration", + "scope": 35733, + "src": "1432:7:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 35725, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1432:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35728, + "mutability": "mutable", + "name": "", + "nameLocation": "-1:-1:-1", + "nodeType": "VariableDeclaration", + "scope": 35733, + "src": "1441:7:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 35727, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "1441:7:43", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "visibility": "internal" + } + ], + "src": "1431:18:43" + }, + "returnParameters": { + "id": 35732, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35731, + "mutability": "mutable", + "name": "", + "nameLocation": "-1:-1:-1", + "nodeType": "VariableDeclaration", + "scope": 35733, + "src": "1473:7:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 35730, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1473:7:43", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "visibility": "internal" + } + ], + "src": "1472:9:43" + }, + "scope": 36016, + "stateMutability": "view", + "virtual": false, + "visibility": "external" + }, + { + "id": 35738, + "nodeType": "FunctionDefinition", + "src": "1487:54:43", + "nodes": [], + "functionSelector": "694e80c3", + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "changeThreshold", + "nameLocation": "1496:15:43", + "parameters": { + "id": 35736, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35735, + "mutability": "mutable", + "name": "_threshold", + "nameLocation": "1520:10:43", + "nodeType": "VariableDeclaration", + "scope": 35738, + "src": "1512:18:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 35734, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1512:7:43", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "visibility": "internal" + } + ], + "src": "1511:20:43" + }, + "returnParameters": { + "id": 35737, + "nodeType": "ParameterList", + "parameters": [], + "src": "1540:0:43" + }, + "scope": 36016, + "stateMutability": "nonpayable", + "virtual": false, + "visibility": "external" + }, + { + "id": 35749, + "nodeType": "FunctionDefinition", + "src": "1546:184:43", + "nodes": [], + "functionSelector": "12fb68e0", + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "checkNSignatures", + "nameLocation": "1555:16:43", + "parameters": { + "id": 35747, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35740, + "mutability": "mutable", + "name": "dataHash", + "nameLocation": "1589:8:43", + "nodeType": "VariableDeclaration", + "scope": 35749, + "src": "1581:16:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 35739, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "1581:7:43", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35742, + "mutability": "mutable", + "name": "data", + "nameLocation": "1620:4:43", + "nodeType": "VariableDeclaration", + "scope": 35749, + "src": "1607:17:43", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes" + }, + "typeName": { + "id": 35741, + "name": "bytes", + "nodeType": "ElementaryTypeName", + "src": "1607:5:43", + "typeDescriptions": { + "typeIdentifier": "t_bytes_storage_ptr", + "typeString": "bytes" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35744, + "mutability": "mutable", + "name": "signatures", + "nameLocation": "1647:10:43", + "nodeType": "VariableDeclaration", + "scope": 35749, + "src": "1634:23:43", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes" + }, + "typeName": { + "id": 35743, + "name": "bytes", + "nodeType": "ElementaryTypeName", + "src": "1634:5:43", + "typeDescriptions": { + "typeIdentifier": "t_bytes_storage_ptr", + "typeString": "bytes" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35746, + "mutability": "mutable", + "name": "requiredSignatures", + "nameLocation": "1675:18:43", + "nodeType": "VariableDeclaration", + "scope": 35749, + "src": "1667:26:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 35745, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1667:7:43", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "visibility": "internal" + } + ], + "src": "1571:128:43" + }, + "returnParameters": { + "id": 35748, + "nodeType": "ParameterList", + "parameters": [], + "src": "1729:0:43" + }, + "scope": 36016, + "stateMutability": "view", + "virtual": false, + "visibility": "external" + }, + { + "id": 35758, + "nodeType": "FunctionDefinition", + "src": "1735:101:43", + "nodes": [], + "functionSelector": "934f3a11", + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "checkSignatures", + "nameLocation": "1744:15:43", + "parameters": { + "id": 35756, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35751, + "mutability": "mutable", + "name": "dataHash", + "nameLocation": "1768:8:43", + "nodeType": "VariableDeclaration", + "scope": 35758, + "src": "1760:16:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 35750, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "1760:7:43", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35753, + "mutability": "mutable", + "name": "data", + "nameLocation": "1791:4:43", + "nodeType": "VariableDeclaration", + "scope": 35758, + "src": "1778:17:43", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes" + }, + "typeName": { + "id": 35752, + "name": "bytes", + "nodeType": "ElementaryTypeName", + "src": "1778:5:43", + "typeDescriptions": { + "typeIdentifier": "t_bytes_storage_ptr", + "typeString": "bytes" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35755, + "mutability": "mutable", + "name": "signatures", + "nameLocation": "1810:10:43", + "nodeType": "VariableDeclaration", + "scope": 35758, + "src": "1797:23:43", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes" + }, + "typeName": { + "id": 35754, + "name": "bytes", + "nodeType": "ElementaryTypeName", + "src": "1797:5:43", + "typeDescriptions": { + "typeIdentifier": "t_bytes_storage_ptr", + "typeString": "bytes" + } + }, + "visibility": "internal" + } + ], + "src": "1759:62:43" + }, + "returnParameters": { + "id": 35757, + "nodeType": "ParameterList", + "parameters": [], + "src": "1835:0:43" + }, + "scope": 36016, + "stateMutability": "view", + "virtual": false, + "visibility": "external" + }, + { + "id": 35765, + "nodeType": "FunctionDefinition", + "src": "1841:68:43", + "nodes": [], + "functionSelector": "e009cfde", + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "disableModule", + "nameLocation": "1850:13:43", + "parameters": { + "id": 35763, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35760, + "mutability": "mutable", + "name": "prevModule", + "nameLocation": "1872:10:43", + "nodeType": "VariableDeclaration", + "scope": 35765, + "src": "1864:18:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 35759, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1864:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35762, + "mutability": "mutable", + "name": "module", + "nameLocation": "1892:6:43", + "nodeType": "VariableDeclaration", + "scope": 35765, + "src": "1884:14:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 35761, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1884:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "visibility": "internal" + } + ], + "src": "1863:36:43" + }, + "returnParameters": { + "id": 35764, + "nodeType": "ParameterList", + "parameters": [], + "src": "1908:0:43" + }, + "scope": 36016, + "stateMutability": "nonpayable", + "virtual": false, + "visibility": "external" + }, + { + "id": 35770, + "nodeType": "FunctionDefinition", + "src": "1914:59:43", + "nodes": [], + "functionSelector": "f698da25", + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "domainSeparator", + "nameLocation": "1923:15:43", + "parameters": { + "id": 35766, + "nodeType": "ParameterList", + "parameters": [], + "src": "1938:2:43" + }, + "returnParameters": { + "id": 35769, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35768, + "mutability": "mutable", + "name": "", + "nameLocation": "-1:-1:-1", + "nodeType": "VariableDeclaration", + "scope": 35770, + "src": "1964:7:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 35767, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "1964:7:43", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "visibility": "internal" + } + ], + "src": "1963:9:43" + }, + "scope": 36016, + "stateMutability": "view", + "virtual": false, + "visibility": "external" + }, + { + "id": 35775, + "nodeType": "FunctionDefinition", + "src": "1978:47:43", + "nodes": [], + "functionSelector": "610b5925", + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "enableModule", + "nameLocation": "1987:12:43", + "parameters": { + "id": 35773, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35772, + "mutability": "mutable", + "name": "module", + "nameLocation": "2008:6:43", + "nodeType": "VariableDeclaration", + "scope": 35775, + "src": "2000:14:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 35771, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2000:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "visibility": "internal" + } + ], + "src": "1999:16:43" + }, + "returnParameters": { + "id": 35774, + "nodeType": "ParameterList", + "parameters": [], + "src": "2024:0:43" + }, + "scope": 36016, + "stateMutability": "nonpayable", + "virtual": false, + "visibility": "external" + }, + { + "id": 35801, + "nodeType": "FunctionDefinition", + "src": "2030:362:43", + "nodes": [], + "functionSelector": "e86637db", + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "encodeTransactionData", + "nameLocation": "2039:21:43", + "parameters": { + "id": 35797, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35777, + "mutability": "mutable", + "name": "to", + "nameLocation": "2078:2:43", + "nodeType": "VariableDeclaration", + "scope": 35801, + "src": "2070:10:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 35776, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2070:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35779, + "mutability": "mutable", + "name": "value", + "nameLocation": "2098:5:43", + "nodeType": "VariableDeclaration", + "scope": 35801, + "src": "2090:13:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 35778, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2090:7:43", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35781, + "mutability": "mutable", + "name": "data", + "nameLocation": "2126:4:43", + "nodeType": "VariableDeclaration", + "scope": 35801, + "src": "2113:17:43", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes" + }, + "typeName": { + "id": 35780, + "name": "bytes", + "nodeType": "ElementaryTypeName", + "src": "2113:5:43", + "typeDescriptions": { + "typeIdentifier": "t_bytes_storage_ptr", + "typeString": "bytes" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35784, + "mutability": "mutable", + "name": "operation", + "nameLocation": "2155:9:43", + "nodeType": "VariableDeclaration", + "scope": 35801, + "src": "2140:24:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_enum$_Operation_$35628", + "typeString": "enum Enum.Operation" + }, + "typeName": { + "id": 35783, + "nodeType": "UserDefinedTypeName", + "pathNode": { + "id": 35782, + "name": "Enum.Operation", + "nameLocations": [ + "2140:4:43", + "2145:9:43" + ], + "nodeType": "IdentifierPath", + "referencedDeclaration": 35628, + "src": "2140:14:43" + }, + "referencedDeclaration": 35628, + "src": "2140:14:43", + "typeDescriptions": { + "typeIdentifier": "t_enum$_Operation_$35628", + "typeString": "enum Enum.Operation" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35786, + "mutability": "mutable", + "name": "safeTxGas", + "nameLocation": "2182:9:43", + "nodeType": "VariableDeclaration", + "scope": 35801, + "src": "2174:17:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 35785, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2174:7:43", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35788, + "mutability": "mutable", + "name": "baseGas", + "nameLocation": "2209:7:43", + "nodeType": "VariableDeclaration", + "scope": 35801, + "src": "2201:15:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 35787, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2201:7:43", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35790, + "mutability": "mutable", + "name": "gasPrice", + "nameLocation": "2234:8:43", + "nodeType": "VariableDeclaration", + "scope": 35801, + "src": "2226:16:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 35789, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2226:7:43", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35792, + "mutability": "mutable", + "name": "gasToken", + "nameLocation": "2260:8:43", + "nodeType": "VariableDeclaration", + "scope": 35801, + "src": "2252:16:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 35791, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2252:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35794, + "mutability": "mutable", + "name": "refundReceiver", + "nameLocation": "2286:14:43", + "nodeType": "VariableDeclaration", + "scope": 35801, + "src": "2278:22:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 35793, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2278:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35796, + "mutability": "mutable", + "name": "_nonce", + "nameLocation": "2318:6:43", + "nodeType": "VariableDeclaration", + "scope": 35801, + "src": "2310:14:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 35795, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2310:7:43", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "visibility": "internal" + } + ], + "src": "2060:270:43" + }, + "returnParameters": { + "id": 35800, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35799, + "mutability": "mutable", + "name": "", + "nameLocation": "-1:-1:-1", + "nodeType": "VariableDeclaration", + "scope": 35801, + "src": "2378:12:43", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes" + }, + "typeName": { + "id": 35798, + "name": "bytes", + "nodeType": "ElementaryTypeName", + "src": "2378:5:43", + "typeDescriptions": { + "typeIdentifier": "t_bytes_storage_ptr", + "typeString": "bytes" + } + }, + "visibility": "internal" + } + ], + "src": "2377:14:43" + }, + "scope": 36016, + "stateMutability": "view", + "virtual": false, + "visibility": "external" + }, + { + "id": 35827, + "nodeType": "FunctionDefinition", + "src": "2397:368:43", + "nodes": [], + "functionSelector": "6a761202", + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "execTransaction", + "nameLocation": "2406:15:43", + "parameters": { + "id": 35823, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35803, + "mutability": "mutable", + "name": "to", + "nameLocation": "2439:2:43", + "nodeType": "VariableDeclaration", + "scope": 35827, + "src": "2431:10:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 35802, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2431:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35805, + "mutability": "mutable", + "name": "value", + "nameLocation": "2459:5:43", + "nodeType": "VariableDeclaration", + "scope": 35827, + "src": "2451:13:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 35804, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2451:7:43", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35807, + "mutability": "mutable", + "name": "data", + "nameLocation": "2487:4:43", + "nodeType": "VariableDeclaration", + "scope": 35827, + "src": "2474:17:43", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes" + }, + "typeName": { + "id": 35806, + "name": "bytes", + "nodeType": "ElementaryTypeName", + "src": "2474:5:43", + "typeDescriptions": { + "typeIdentifier": "t_bytes_storage_ptr", + "typeString": "bytes" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35810, + "mutability": "mutable", + "name": "operation", + "nameLocation": "2516:9:43", + "nodeType": "VariableDeclaration", + "scope": 35827, + "src": "2501:24:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_enum$_Operation_$35628", + "typeString": "enum Enum.Operation" + }, + "typeName": { + "id": 35809, + "nodeType": "UserDefinedTypeName", + "pathNode": { + "id": 35808, + "name": "Enum.Operation", + "nameLocations": [ + "2501:4:43", + "2506:9:43" + ], + "nodeType": "IdentifierPath", + "referencedDeclaration": 35628, + "src": "2501:14:43" + }, + "referencedDeclaration": 35628, + "src": "2501:14:43", + "typeDescriptions": { + "typeIdentifier": "t_enum$_Operation_$35628", + "typeString": "enum Enum.Operation" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35812, + "mutability": "mutable", + "name": "safeTxGas", + "nameLocation": "2543:9:43", + "nodeType": "VariableDeclaration", + "scope": 35827, + "src": "2535:17:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 35811, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2535:7:43", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35814, + "mutability": "mutable", + "name": "baseGas", + "nameLocation": "2570:7:43", + "nodeType": "VariableDeclaration", + "scope": 35827, + "src": "2562:15:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 35813, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2562:7:43", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35816, + "mutability": "mutable", + "name": "gasPrice", + "nameLocation": "2595:8:43", + "nodeType": "VariableDeclaration", + "scope": 35827, + "src": "2587:16:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 35815, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2587:7:43", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35818, + "mutability": "mutable", + "name": "gasToken", + "nameLocation": "2621:8:43", + "nodeType": "VariableDeclaration", + "scope": 35827, + "src": "2613:16:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 35817, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2613:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35820, + "mutability": "mutable", + "name": "refundReceiver", + "nameLocation": "2647:14:43", + "nodeType": "VariableDeclaration", + "scope": 35827, + "src": "2639:22:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 35819, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2639:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35822, + "mutability": "mutable", + "name": "signatures", + "nameLocation": "2684:10:43", + "nodeType": "VariableDeclaration", + "scope": 35827, + "src": "2671:23:43", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes" + }, + "typeName": { + "id": 35821, + "name": "bytes", + "nodeType": "ElementaryTypeName", + "src": "2671:5:43", + "typeDescriptions": { + "typeIdentifier": "t_bytes_storage_ptr", + "typeString": "bytes" + } + }, + "visibility": "internal" + } + ], + "src": "2421:279:43" + }, + "returnParameters": { + "id": 35826, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35825, + "mutability": "mutable", + "name": "success", + "nameLocation": "2756:7:43", + "nodeType": "VariableDeclaration", + "scope": 35827, + "src": "2751:12:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 35824, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "2751:4:43", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "visibility": "internal" + } + ], + "src": "2750:14:43" + }, + "scope": 36016, + "stateMutability": "payable", + "virtual": false, + "visibility": "external" + }, + { + "id": 35841, + "nodeType": "FunctionDefinition", + "src": "2770:193:43", + "nodes": [], + "functionSelector": "468721a7", + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "execTransactionFromModule", + "nameLocation": "2779:25:43", + "parameters": { + "id": 35837, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35829, + "mutability": "mutable", + "name": "to", + "nameLocation": "2822:2:43", + "nodeType": "VariableDeclaration", + "scope": 35841, + "src": "2814:10:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 35828, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2814:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35831, + "mutability": "mutable", + "name": "value", + "nameLocation": "2842:5:43", + "nodeType": "VariableDeclaration", + "scope": 35841, + "src": "2834:13:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 35830, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2834:7:43", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35833, + "mutability": "mutable", + "name": "data", + "nameLocation": "2870:4:43", + "nodeType": "VariableDeclaration", + "scope": 35841, + "src": "2857:17:43", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes" + }, + "typeName": { + "id": 35832, + "name": "bytes", + "nodeType": "ElementaryTypeName", + "src": "2857:5:43", + "typeDescriptions": { + "typeIdentifier": "t_bytes_storage_ptr", + "typeString": "bytes" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35836, + "mutability": "mutable", + "name": "operation", + "nameLocation": "2899:9:43", + "nodeType": "VariableDeclaration", + "scope": 35841, + "src": "2884:24:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_enum$_Operation_$35628", + "typeString": "enum Enum.Operation" + }, + "typeName": { + "id": 35835, + "nodeType": "UserDefinedTypeName", + "pathNode": { + "id": 35834, + "name": "Enum.Operation", + "nameLocations": [ + "2884:4:43", + "2889:9:43" + ], + "nodeType": "IdentifierPath", + "referencedDeclaration": 35628, + "src": "2884:14:43" + }, + "referencedDeclaration": 35628, + "src": "2884:14:43", + "typeDescriptions": { + "typeIdentifier": "t_enum$_Operation_$35628", + "typeString": "enum Enum.Operation" + } + }, + "visibility": "internal" + } + ], + "src": "2804:110:43" + }, + "returnParameters": { + "id": 35840, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35839, + "mutability": "mutable", + "name": "success", + "nameLocation": "2954:7:43", + "nodeType": "VariableDeclaration", + "scope": 35841, + "src": "2949:12:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 35838, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "2949:4:43", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "visibility": "internal" + } + ], + "src": "2948:14:43" + }, + "scope": 36016, + "stateMutability": "nonpayable", + "virtual": false, + "visibility": "external" + }, + { + "id": 35857, + "nodeType": "FunctionDefinition", + "src": "2968:228:43", + "nodes": [], + "functionSelector": "5229073f", + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "execTransactionFromModuleReturnData", + "nameLocation": "2977:35:43", + "parameters": { + "id": 35851, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35843, + "mutability": "mutable", + "name": "to", + "nameLocation": "3030:2:43", + "nodeType": "VariableDeclaration", + "scope": 35857, + "src": "3022:10:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 35842, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "3022:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35845, + "mutability": "mutable", + "name": "value", + "nameLocation": "3050:5:43", + "nodeType": "VariableDeclaration", + "scope": 35857, + "src": "3042:13:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 35844, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3042:7:43", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35847, + "mutability": "mutable", + "name": "data", + "nameLocation": "3078:4:43", + "nodeType": "VariableDeclaration", + "scope": 35857, + "src": "3065:17:43", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes" + }, + "typeName": { + "id": 35846, + "name": "bytes", + "nodeType": "ElementaryTypeName", + "src": "3065:5:43", + "typeDescriptions": { + "typeIdentifier": "t_bytes_storage_ptr", + "typeString": "bytes" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35850, + "mutability": "mutable", + "name": "operation", + "nameLocation": "3107:9:43", + "nodeType": "VariableDeclaration", + "scope": 35857, + "src": "3092:24:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_enum$_Operation_$35628", + "typeString": "enum Enum.Operation" + }, + "typeName": { + "id": 35849, + "nodeType": "UserDefinedTypeName", + "pathNode": { + "id": 35848, + "name": "Enum.Operation", + "nameLocations": [ + "3092:4:43", + "3097:9:43" + ], + "nodeType": "IdentifierPath", + "referencedDeclaration": 35628, + "src": "3092:14:43" + }, + "referencedDeclaration": 35628, + "src": "3092:14:43", + "typeDescriptions": { + "typeIdentifier": "t_enum$_Operation_$35628", + "typeString": "enum Enum.Operation" + } + }, + "visibility": "internal" + } + ], + "src": "3012:110:43" + }, + "returnParameters": { + "id": 35856, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35853, + "mutability": "mutable", + "name": "success", + "nameLocation": "3162:7:43", + "nodeType": "VariableDeclaration", + "scope": 35857, + "src": "3157:12:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 35852, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "3157:4:43", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35855, + "mutability": "mutable", + "name": "returnData", + "nameLocation": "3184:10:43", + "nodeType": "VariableDeclaration", + "scope": 35857, + "src": "3171:23:43", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes" + }, + "typeName": { + "id": 35854, + "name": "bytes", + "nodeType": "ElementaryTypeName", + "src": "3171:5:43", + "typeDescriptions": { + "typeIdentifier": "t_bytes_storage_ptr", + "typeString": "bytes" + } + }, + "visibility": "internal" + } + ], + "src": "3156:39:43" + }, + "scope": 36016, + "stateMutability": "nonpayable", + "virtual": false, + "visibility": "external" + }, + { + "id": 35862, + "nodeType": "FunctionDefinition", + "src": "3201:54:43", + "nodes": [], + "functionSelector": "3408e470", + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "getChainId", + "nameLocation": "3210:10:43", + "parameters": { + "id": 35858, + "nodeType": "ParameterList", + "parameters": [], + "src": "3220:2:43" + }, + "returnParameters": { + "id": 35861, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35860, + "mutability": "mutable", + "name": "", + "nameLocation": "-1:-1:-1", + "nodeType": "VariableDeclaration", + "scope": 35862, + "src": "3246:7:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 35859, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3246:7:43", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "visibility": "internal" + } + ], + "src": "3245:9:43" + }, + "scope": 36016, + "stateMutability": "view", + "virtual": false, + "visibility": "external" + }, + { + "id": 35874, + "nodeType": "FunctionDefinition", + "src": "3260:169:43", + "nodes": [], + "functionSelector": "cc2f8452", + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "getModulesPaginated", + "nameLocation": "3269:19:43", + "parameters": { + "id": 35867, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35864, + "mutability": "mutable", + "name": "start", + "nameLocation": "3306:5:43", + "nodeType": "VariableDeclaration", + "scope": 35874, + "src": "3298:13:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 35863, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "3298:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35866, + "mutability": "mutable", + "name": "pageSize", + "nameLocation": "3329:8:43", + "nodeType": "VariableDeclaration", + "scope": 35874, + "src": "3321:16:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 35865, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3321:7:43", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "visibility": "internal" + } + ], + "src": "3288:55:43" + }, + "returnParameters": { + "id": 35873, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35870, + "mutability": "mutable", + "name": "array", + "nameLocation": "3408:5:43", + "nodeType": "VariableDeclaration", + "scope": 35874, + "src": "3391:22:43", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr", + "typeString": "address[]" + }, + "typeName": { + "baseType": { + "id": 35868, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "3391:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 35869, + "nodeType": "ArrayTypeName", + "src": "3391:9:43", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr", + "typeString": "address[]" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35872, + "mutability": "mutable", + "name": "next", + "nameLocation": "3423:4:43", + "nodeType": "VariableDeclaration", + "scope": 35874, + "src": "3415:12:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 35871, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "3415:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "visibility": "internal" + } + ], + "src": "3390:38:43" + }, + "scope": 36016, + "stateMutability": "view", + "virtual": false, + "visibility": "external" + }, + { + "id": 35880, + "nodeType": "FunctionDefinition", + "src": "3434:62:43", + "nodes": [], + "functionSelector": "a0e67e2b", + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "getOwners", + "nameLocation": "3443:9:43", + "parameters": { + "id": 35875, + "nodeType": "ParameterList", + "parameters": [], + "src": "3452:2:43" + }, + "returnParameters": { + "id": 35879, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35878, + "mutability": "mutable", + "name": "", + "nameLocation": "-1:-1:-1", + "nodeType": "VariableDeclaration", + "scope": 35880, + "src": "3478:16:43", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr", + "typeString": "address[]" + }, + "typeName": { + "baseType": { + "id": 35876, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "3478:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 35877, + "nodeType": "ArrayTypeName", + "src": "3478:9:43", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr", + "typeString": "address[]" + } + }, + "visibility": "internal" + } + ], + "src": "3477:18:43" + }, + "scope": 36016, + "stateMutability": "view", + "virtual": false, + "visibility": "external" + }, + { + "id": 35889, + "nodeType": "FunctionDefinition", + "src": "3501:91:43", + "nodes": [], + "functionSelector": "5624b25b", + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "getStorageAt", + "nameLocation": "3510:12:43", + "parameters": { + "id": 35885, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35882, + "mutability": "mutable", + "name": "offset", + "nameLocation": "3531:6:43", + "nodeType": "VariableDeclaration", + "scope": 35889, + "src": "3523:14:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 35881, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3523:7:43", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35884, + "mutability": "mutable", + "name": "length", + "nameLocation": "3547:6:43", + "nodeType": "VariableDeclaration", + "scope": 35889, + "src": "3539:14:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 35883, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3539:7:43", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "visibility": "internal" + } + ], + "src": "3522:32:43" + }, + "returnParameters": { + "id": 35888, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35887, + "mutability": "mutable", + "name": "", + "nameLocation": "-1:-1:-1", + "nodeType": "VariableDeclaration", + "scope": 35889, + "src": "3578:12:43", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes" + }, + "typeName": { + "id": 35886, + "name": "bytes", + "nodeType": "ElementaryTypeName", + "src": "3578:5:43", + "typeDescriptions": { + "typeIdentifier": "t_bytes_storage_ptr", + "typeString": "bytes" + } + }, + "visibility": "internal" + } + ], + "src": "3577:14:43" + }, + "scope": 36016, + "stateMutability": "view", + "virtual": false, + "visibility": "external" + }, + { + "id": 35894, + "nodeType": "FunctionDefinition", + "src": "3597:56:43", + "nodes": [], + "functionSelector": "e75235b8", + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "getThreshold", + "nameLocation": "3606:12:43", + "parameters": { + "id": 35890, + "nodeType": "ParameterList", + "parameters": [], + "src": "3618:2:43" + }, + "returnParameters": { + "id": 35893, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35892, + "mutability": "mutable", + "name": "", + "nameLocation": "-1:-1:-1", + "nodeType": "VariableDeclaration", + "scope": 35894, + "src": "3644:7:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 35891, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3644:7:43", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "visibility": "internal" + } + ], + "src": "3643:9:43" + }, + "scope": 36016, + "stateMutability": "view", + "virtual": false, + "visibility": "external" + }, + { + "id": 35920, + "nodeType": "FunctionDefinition", + "src": "3658:354:43", + "nodes": [], + "functionSelector": "d8d11f78", + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "getTransactionHash", + "nameLocation": "3667:18:43", + "parameters": { + "id": 35916, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35896, + "mutability": "mutable", + "name": "to", + "nameLocation": "3703:2:43", + "nodeType": "VariableDeclaration", + "scope": 35920, + "src": "3695:10:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 35895, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "3695:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35898, + "mutability": "mutable", + "name": "value", + "nameLocation": "3723:5:43", + "nodeType": "VariableDeclaration", + "scope": 35920, + "src": "3715:13:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 35897, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3715:7:43", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35900, + "mutability": "mutable", + "name": "data", + "nameLocation": "3751:4:43", + "nodeType": "VariableDeclaration", + "scope": 35920, + "src": "3738:17:43", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes" + }, + "typeName": { + "id": 35899, + "name": "bytes", + "nodeType": "ElementaryTypeName", + "src": "3738:5:43", + "typeDescriptions": { + "typeIdentifier": "t_bytes_storage_ptr", + "typeString": "bytes" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35903, + "mutability": "mutable", + "name": "operation", + "nameLocation": "3780:9:43", + "nodeType": "VariableDeclaration", + "scope": 35920, + "src": "3765:24:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_enum$_Operation_$35628", + "typeString": "enum Enum.Operation" + }, + "typeName": { + "id": 35902, + "nodeType": "UserDefinedTypeName", + "pathNode": { + "id": 35901, + "name": "Enum.Operation", + "nameLocations": [ + "3765:4:43", + "3770:9:43" + ], + "nodeType": "IdentifierPath", + "referencedDeclaration": 35628, + "src": "3765:14:43" + }, + "referencedDeclaration": 35628, + "src": "3765:14:43", + "typeDescriptions": { + "typeIdentifier": "t_enum$_Operation_$35628", + "typeString": "enum Enum.Operation" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35905, + "mutability": "mutable", + "name": "safeTxGas", + "nameLocation": "3807:9:43", + "nodeType": "VariableDeclaration", + "scope": 35920, + "src": "3799:17:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 35904, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3799:7:43", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35907, + "mutability": "mutable", + "name": "baseGas", + "nameLocation": "3834:7:43", + "nodeType": "VariableDeclaration", + "scope": 35920, + "src": "3826:15:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 35906, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3826:7:43", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35909, + "mutability": "mutable", + "name": "gasPrice", + "nameLocation": "3859:8:43", + "nodeType": "VariableDeclaration", + "scope": 35920, + "src": "3851:16:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 35908, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3851:7:43", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35911, + "mutability": "mutable", + "name": "gasToken", + "nameLocation": "3885:8:43", + "nodeType": "VariableDeclaration", + "scope": 35920, + "src": "3877:16:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 35910, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "3877:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35913, + "mutability": "mutable", + "name": "refundReceiver", + "nameLocation": "3911:14:43", + "nodeType": "VariableDeclaration", + "scope": 35920, + "src": "3903:22:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 35912, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "3903:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35915, + "mutability": "mutable", + "name": "_nonce", + "nameLocation": "3943:6:43", + "nodeType": "VariableDeclaration", + "scope": 35920, + "src": "3935:14:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 35914, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3935:7:43", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "visibility": "internal" + } + ], + "src": "3685:270:43" + }, + "returnParameters": { + "id": 35919, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35918, + "mutability": "mutable", + "name": "", + "nameLocation": "-1:-1:-1", + "nodeType": "VariableDeclaration", + "scope": 35920, + "src": "4003:7:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 35917, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "4003:7:43", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "visibility": "internal" + } + ], + "src": "4002:9:43" + }, + "scope": 36016, + "stateMutability": "view", + "virtual": false, + "visibility": "external" + }, + { + "id": 35927, + "nodeType": "FunctionDefinition", + "src": "4017:70:43", + "nodes": [], + "functionSelector": "2d9ad53d", + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "isModuleEnabled", + "nameLocation": "4026:15:43", + "parameters": { + "id": 35923, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35922, + "mutability": "mutable", + "name": "module", + "nameLocation": "4050:6:43", + "nodeType": "VariableDeclaration", + "scope": 35927, + "src": "4042:14:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 35921, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "4042:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "visibility": "internal" + } + ], + "src": "4041:16:43" + }, + "returnParameters": { + "id": 35926, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35925, + "mutability": "mutable", + "name": "", + "nameLocation": "-1:-1:-1", + "nodeType": "VariableDeclaration", + "scope": 35927, + "src": "4081:4:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 35924, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "4081:4:43", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "visibility": "internal" + } + ], + "src": "4080:6:43" + }, + "scope": 36016, + "stateMutability": "view", + "virtual": false, + "visibility": "external" + }, + { + "id": 35934, + "nodeType": "FunctionDefinition", + "src": "4092:61:43", + "nodes": [], + "functionSelector": "2f54bf6e", + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "isOwner", + "nameLocation": "4101:7:43", + "parameters": { + "id": 35930, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35929, + "mutability": "mutable", + "name": "owner", + "nameLocation": "4117:5:43", + "nodeType": "VariableDeclaration", + "scope": 35934, + "src": "4109:13:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 35928, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "4109:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "visibility": "internal" + } + ], + "src": "4108:15:43" + }, + "returnParameters": { + "id": 35933, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35932, + "mutability": "mutable", + "name": "", + "nameLocation": "-1:-1:-1", + "nodeType": "VariableDeclaration", + "scope": 35934, + "src": "4147:4:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 35931, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "4147:4:43", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "visibility": "internal" + } + ], + "src": "4146:6:43" + }, + "scope": 36016, + "stateMutability": "view", + "virtual": false, + "visibility": "external" + }, + { + "id": 35939, + "nodeType": "FunctionDefinition", + "src": "4158:49:43", + "nodes": [], + "functionSelector": "affed0e0", + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "nonce", + "nameLocation": "4167:5:43", + "parameters": { + "id": 35935, + "nodeType": "ParameterList", + "parameters": [], + "src": "4172:2:43" + }, + "returnParameters": { + "id": 35938, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35937, + "mutability": "mutable", + "name": "", + "nameLocation": "-1:-1:-1", + "nodeType": "VariableDeclaration", + "scope": 35939, + "src": "4198:7:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 35936, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "4198:7:43", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "visibility": "internal" + } + ], + "src": "4197:9:43" + }, + "scope": 36016, + "stateMutability": "view", + "virtual": false, + "visibility": "external" + }, + { + "id": 35948, + "nodeType": "FunctionDefinition", + "src": "4212:84:43", + "nodes": [], + "functionSelector": "f8dc5dd9", + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "removeOwner", + "nameLocation": "4221:11:43", + "parameters": { + "id": 35946, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35941, + "mutability": "mutable", + "name": "prevOwner", + "nameLocation": "4241:9:43", + "nodeType": "VariableDeclaration", + "scope": 35948, + "src": "4233:17:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 35940, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "4233:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35943, + "mutability": "mutable", + "name": "owner", + "nameLocation": "4260:5:43", + "nodeType": "VariableDeclaration", + "scope": 35948, + "src": "4252:13:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 35942, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "4252:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35945, + "mutability": "mutable", + "name": "_threshold", + "nameLocation": "4275:10:43", + "nodeType": "VariableDeclaration", + "scope": 35948, + "src": "4267:18:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 35944, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "4267:7:43", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "visibility": "internal" + } + ], + "src": "4232:54:43" + }, + "returnParameters": { + "id": 35947, + "nodeType": "ParameterList", + "parameters": [], + "src": "4295:0:43" + }, + "scope": 36016, + "stateMutability": "nonpayable", + "virtual": false, + "visibility": "external" + }, + { + "id": 35962, + "nodeType": "FunctionDefinition", + "src": "4301:176:43", + "nodes": [], + "functionSelector": "c4ca3a9c", + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "requiredTxGas", + "nameLocation": "4310:13:43", + "parameters": { + "id": 35958, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35950, + "mutability": "mutable", + "name": "to", + "nameLocation": "4341:2:43", + "nodeType": "VariableDeclaration", + "scope": 35962, + "src": "4333:10:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 35949, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "4333:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35952, + "mutability": "mutable", + "name": "value", + "nameLocation": "4361:5:43", + "nodeType": "VariableDeclaration", + "scope": 35962, + "src": "4353:13:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 35951, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "4353:7:43", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35954, + "mutability": "mutable", + "name": "data", + "nameLocation": "4389:4:43", + "nodeType": "VariableDeclaration", + "scope": 35962, + "src": "4376:17:43", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes" + }, + "typeName": { + "id": 35953, + "name": "bytes", + "nodeType": "ElementaryTypeName", + "src": "4376:5:43", + "typeDescriptions": { + "typeIdentifier": "t_bytes_storage_ptr", + "typeString": "bytes" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35957, + "mutability": "mutable", + "name": "operation", + "nameLocation": "4418:9:43", + "nodeType": "VariableDeclaration", + "scope": 35962, + "src": "4403:24:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_enum$_Operation_$35628", + "typeString": "enum Enum.Operation" + }, + "typeName": { + "id": 35956, + "nodeType": "UserDefinedTypeName", + "pathNode": { + "id": 35955, + "name": "Enum.Operation", + "nameLocations": [ + "4403:4:43", + "4408:9:43" + ], + "nodeType": "IdentifierPath", + "referencedDeclaration": 35628, + "src": "4403:14:43" + }, + "referencedDeclaration": 35628, + "src": "4403:14:43", + "typeDescriptions": { + "typeIdentifier": "t_enum$_Operation_$35628", + "typeString": "enum Enum.Operation" + } + }, + "visibility": "internal" + } + ], + "src": "4323:110:43" + }, + "returnParameters": { + "id": 35961, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35960, + "mutability": "mutable", + "name": "", + "nameLocation": "-1:-1:-1", + "nodeType": "VariableDeclaration", + "scope": 35962, + "src": "4468:7:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 35959, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "4468:7:43", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "visibility": "internal" + } + ], + "src": "4467:9:43" + }, + "scope": 36016, + "stateMutability": "nonpayable", + "virtual": false, + "visibility": "external" + }, + { + "id": 35967, + "nodeType": "FunctionDefinition", + "src": "4482:54:43", + "nodes": [], + "functionSelector": "f08a0323", + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "setFallbackHandler", + "nameLocation": "4491:18:43", + "parameters": { + "id": 35965, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35964, + "mutability": "mutable", + "name": "handler", + "nameLocation": "4518:7:43", + "nodeType": "VariableDeclaration", + "scope": 35967, + "src": "4510:15:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 35963, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "4510:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "visibility": "internal" + } + ], + "src": "4509:17:43" + }, + "returnParameters": { + "id": 35966, + "nodeType": "ParameterList", + "parameters": [], + "src": "4535:0:43" + }, + "scope": 36016, + "stateMutability": "nonpayable", + "virtual": false, + "visibility": "external" + }, + { + "id": 35972, + "nodeType": "FunctionDefinition", + "src": "4541:42:43", + "nodes": [], + "functionSelector": "e19a9dd9", + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "setGuard", + "nameLocation": "4550:8:43", + "parameters": { + "id": 35970, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35969, + "mutability": "mutable", + "name": "guard", + "nameLocation": "4567:5:43", + "nodeType": "VariableDeclaration", + "scope": 35972, + "src": "4559:13:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 35968, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "4559:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "visibility": "internal" + } + ], + "src": "4558:15:43" + }, + "returnParameters": { + "id": 35971, + "nodeType": "ParameterList", + "parameters": [], + "src": "4582:0:43" + }, + "scope": 36016, + "stateMutability": "nonpayable", + "virtual": false, + "visibility": "external" + }, + { + "id": 35992, + "nodeType": "FunctionDefinition", + "src": "4588:268:43", + "nodes": [], + "functionSelector": "b63e800d", + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "setup", + "nameLocation": "4597:5:43", + "parameters": { + "id": 35990, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35975, + "mutability": "mutable", + "name": "_owners", + "nameLocation": "4629:7:43", + "nodeType": "VariableDeclaration", + "scope": 35992, + "src": "4612:24:43", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr", + "typeString": "address[]" + }, + "typeName": { + "baseType": { + "id": 35973, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "4612:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 35974, + "nodeType": "ArrayTypeName", + "src": "4612:9:43", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr", + "typeString": "address[]" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35977, + "mutability": "mutable", + "name": "_threshold", + "nameLocation": "4654:10:43", + "nodeType": "VariableDeclaration", + "scope": 35992, + "src": "4646:18:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 35976, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "4646:7:43", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35979, + "mutability": "mutable", + "name": "to", + "nameLocation": "4682:2:43", + "nodeType": "VariableDeclaration", + "scope": 35992, + "src": "4674:10:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 35978, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "4674:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35981, + "mutability": "mutable", + "name": "data", + "nameLocation": "4707:4:43", + "nodeType": "VariableDeclaration", + "scope": 35992, + "src": "4694:17:43", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes" + }, + "typeName": { + "id": 35980, + "name": "bytes", + "nodeType": "ElementaryTypeName", + "src": "4694:5:43", + "typeDescriptions": { + "typeIdentifier": "t_bytes_storage_ptr", + "typeString": "bytes" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35983, + "mutability": "mutable", + "name": "fallbackHandler", + "nameLocation": "4729:15:43", + "nodeType": "VariableDeclaration", + "scope": 35992, + "src": "4721:23:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 35982, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "4721:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35985, + "mutability": "mutable", + "name": "paymentToken", + "nameLocation": "4762:12:43", + "nodeType": "VariableDeclaration", + "scope": 35992, + "src": "4754:20:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 35984, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "4754:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35987, + "mutability": "mutable", + "name": "payment", + "nameLocation": "4792:7:43", + "nodeType": "VariableDeclaration", + "scope": 35992, + "src": "4784:15:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 35986, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "4784:7:43", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 35989, + "mutability": "mutable", + "name": "paymentReceiver", + "nameLocation": "4817:15:43", + "nodeType": "VariableDeclaration", + "scope": 35992, + "src": "4809:23:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 35988, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "4809:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "visibility": "internal" + } + ], + "src": "4602:236:43" + }, + "returnParameters": { + "id": 35991, + "nodeType": "ParameterList", + "parameters": [], + "src": "4855:0:43" + }, + "scope": 36016, + "stateMutability": "nonpayable", + "virtual": false, + "visibility": "external" + }, + { + "id": 35999, + "nodeType": "FunctionDefinition", + "src": "4861:65:43", + "nodes": [], + "functionSelector": "5ae6bd37", + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "signedMessages", + "nameLocation": "4870:14:43", + "parameters": { + "id": 35995, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35994, + "mutability": "mutable", + "name": "", + "nameLocation": "-1:-1:-1", + "nodeType": "VariableDeclaration", + "scope": 35999, + "src": "4885:7:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 35993, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "4885:7:43", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "visibility": "internal" + } + ], + "src": "4884:9:43" + }, + "returnParameters": { + "id": 35998, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 35997, + "mutability": "mutable", + "name": "", + "nameLocation": "-1:-1:-1", + "nodeType": "VariableDeclaration", + "scope": 35999, + "src": "4917:7:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 35996, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "4917:7:43", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "visibility": "internal" + } + ], + "src": "4916:9:43" + }, + "scope": 36016, + "stateMutability": "view", + "virtual": false, + "visibility": "external" + }, + { + "id": 36006, + "nodeType": "FunctionDefinition", + "src": "4931:90:43", + "nodes": [], + "functionSelector": "b4faba09", + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "simulateAndRevert", + "nameLocation": "4940:17:43", + "parameters": { + "id": 36004, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 36001, + "mutability": "mutable", + "name": "targetContract", + "nameLocation": "4966:14:43", + "nodeType": "VariableDeclaration", + "scope": 36006, + "src": "4958:22:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 36000, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "4958:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 36003, + "mutability": "mutable", + "name": "calldataPayload", + "nameLocation": "4995:15:43", + "nodeType": "VariableDeclaration", + "scope": 36006, + "src": "4982:28:43", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes" + }, + "typeName": { + "id": 36002, + "name": "bytes", + "nodeType": "ElementaryTypeName", + "src": "4982:5:43", + "typeDescriptions": { + "typeIdentifier": "t_bytes_storage_ptr", + "typeString": "bytes" + } + }, + "visibility": "internal" + } + ], + "src": "4957:54:43" + }, + "returnParameters": { + "id": 36005, + "nodeType": "ParameterList", + "parameters": [], + "src": "5020:0:43" + }, + "scope": 36016, + "stateMutability": "nonpayable", + "virtual": false, + "visibility": "external" + }, + { + "id": 36015, + "nodeType": "FunctionDefinition", + "src": "5026:83:43", + "nodes": [], + "functionSelector": "e318b52b", + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "swapOwner", + "nameLocation": "5035:9:43", + "parameters": { + "id": 36013, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 36008, + "mutability": "mutable", + "name": "prevOwner", + "nameLocation": "5053:9:43", + "nodeType": "VariableDeclaration", + "scope": 36015, + "src": "5045:17:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 36007, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "5045:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 36010, + "mutability": "mutable", + "name": "oldOwner", + "nameLocation": "5072:8:43", + "nodeType": "VariableDeclaration", + "scope": 36015, + "src": "5064:16:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 36009, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "5064:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 36012, + "mutability": "mutable", + "name": "newOwner", + "nameLocation": "5090:8:43", + "nodeType": "VariableDeclaration", + "scope": 36015, + "src": "5082:16:43", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 36011, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "5082:7:43", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "visibility": "internal" + } + ], + "src": "5044:55:43" + }, + "returnParameters": { + "id": 36014, + "nodeType": "ParameterList", + "parameters": [], + "src": "5108:0:43" + }, + "scope": 36016, + "stateMutability": "nonpayable", + "virtual": false, + "visibility": "external" + } + ], + "abstract": false, + "baseContracts": [], + "canonicalName": "IGnosisSafe", + "contractDependencies": [], + "contractKind": "interface", + "documentation": { + "id": 35630, + "nodeType": "StructuredDocumentation", + "src": "262:47:43", + "text": "@title IGnosisSafe - Gnosis Safe Interface" + }, + "fullyImplemented": false, + "linearizedBaseContracts": [ + 36016 + ], + "name": "IGnosisSafe", + "nameLocation": "319:11:43", + "scope": 36017, + "usedErrors": [] + } + ], + "license": "LGPL-3.0-only" + }, + "id": 43 +} \ No newline at end of file diff --git a/packages/chain-mon/src/balance-mon/service.ts b/packages/chain-mon/src/balance-mon/service.ts index a18e2d73c1d44..3382fc8bc8bb4 100644 --- a/packages/chain-mon/src/balance-mon/service.ts +++ b/packages/chain-mon/src/balance-mon/service.ts @@ -6,7 +6,6 @@ import { validators, } from '@eth-optimism/common-ts' import { Provider } from '@ethersproject/abstract-provider' -import { ethers } from 'ethers' import { version } from '../../package.json' @@ -45,7 +44,7 @@ export class BalanceMonService extends BaseServiceV2< }, accounts: { validator: validators.str, - desc: 'JSON array of [{ address, nickname }] to monitor balances of', + desc: 'JSON array of [{ address, nickname, safe }] to monitor balances and nonces of', public: true, }, }, @@ -70,9 +69,21 @@ export class BalanceMonService extends BaseServiceV2< protected async main(): Promise { for (const account of this.state.accounts) { - let balance: ethers.BigNumber try { - balance = await this.options.rpc.getBalance(account.address) + const balance = await this.options.rpc.getBalance(account.address) + this.logger.info(`got balance`, { + address: account.address, + nickname: account.nickname, + balance: balance.toString(), + }) + + // Parse the balance as an integer instead of via toNumber() to avoid ethers throwing an + // an error. We might get rounding errors but we don't need perfect precision here, just a + // generally accurate sense for what the current balance is. + this.metrics.balances.set( + { address: account.address, nickname: account.nickname }, + parseInt(balance.toString(), 10) + ) } catch (err) { this.logger.info(`got unexpected RPC error`, { section: 'balances', @@ -83,22 +94,7 @@ export class BalanceMonService extends BaseServiceV2< section: 'balances', name: 'getBalance', }) - continue } - - this.logger.info(`got balance`, { - address: account.address, - nickname: account.nickname, - balance: balance.toString(), - }) - - // Parse the balance as an integer instead of via toNumber() to avoid ethers throwing an - // an error. We might get rounding errors but we don't need perfect precision here, just a - // generally accurate sense for what the current balance is. - this.metrics.balances.set( - { address: account.address, nickname: account.nickname }, - parseInt(balance.toString(), 10) - ) } } } diff --git a/packages/chain-mon/src/index.ts b/packages/chain-mon/src/index.ts index 98817368bbeb5..8e4d4163c0a19 100644 --- a/packages/chain-mon/src/index.ts +++ b/packages/chain-mon/src/index.ts @@ -1,5 +1,6 @@ export * from './balance-mon/service' export * from './drippie-mon/service' +export * from './fault-mon/index' +export * from './multisig-mon/service' export * from './wd-mon/service' export * from './wallet-mon/service' -export * from './fault-mon/index' diff --git a/packages/chain-mon/src/multisig-mon/service.ts b/packages/chain-mon/src/multisig-mon/service.ts new file mode 100644 index 0000000000000..da769a65cd75d --- /dev/null +++ b/packages/chain-mon/src/multisig-mon/service.ts @@ -0,0 +1,109 @@ +import { + BaseServiceV2, + StandardOptions, + Gauge, + Counter, + validators, +} from '@eth-optimism/common-ts' +import { Provider } from '@ethersproject/abstract-provider' +import { ethers } from 'ethers' + +import Safe from '../abi/IGnosisSafe.0.8.19.json' +import { version } from '../../package.json' + +type MultisigMonOptions = { + rpc: Provider + accounts: string +} + +type MultisigMonMetrics = { + safeNonce: Gauge + unexpectedRpcErrors: Counter +} + +type MultisigMonState = { + accounts: Array<{ address: string; nickname: string }> +} + +export class MultisigMonService extends BaseServiceV2< + MultisigMonOptions, + MultisigMonMetrics, + MultisigMonState +> { + constructor(options?: Partial) { + super({ + version, + name: 'multisig-mon', + loop: true, + options: { + loopIntervalMs: 60_000, + ...options, + }, + optionsSpec: { + rpc: { + validator: validators.provider, + desc: 'Provider for network to monitor balances on', + }, + accounts: { + validator: validators.str, + desc: 'JSON array of [{ address, nickname, safe }] to monitor balances and nonces of', + public: true, + }, + }, + metricsSpec: { + safeNonce: { + type: Gauge, + desc: 'Safe nonce', + labels: ['address', 'nickname'], + }, + unexpectedRpcErrors: { + type: Counter, + desc: 'Number of unexpected RPC errors', + labels: ['section', 'name'], + }, + }, + }) + } + + protected async init(): Promise { + this.state.accounts = JSON.parse(this.options.accounts) + } + + protected async main(): Promise { + for (const account of this.state.accounts) { + try { + const safeContract = new ethers.Contract( + account.address, + Safe.abi, + this.options.rpc + ) + const safeNonce = await safeContract.nonce() + this.logger.info(`got nonce`, { + address: account.address, + nickname: account.nickname, + nonce: safeNonce.toString(), + }) + + this.metrics.safeNonce.set( + { address: account.address, nickname: account.nickname }, + parseInt(safeNonce.toString(), 10) + ) + } catch (err) { + this.logger.error(`got unexpected RPC error`, { + section: 'safeNonce', + name: 'getSafeNonce', + err, + }) + this.metrics.unexpectedRpcErrors.inc({ + section: 'safeNonce', + name: 'getSafeNonce', + }) + } + } + } +} + +if (require.main === module) { + const service = new MultisigMonService() + service.run() +} diff --git a/packages/chain-mon/tsconfig.json b/packages/chain-mon/tsconfig.json index 51d474888dca1..003732e17523d 100644 --- a/packages/chain-mon/tsconfig.json +++ b/packages/chain-mon/tsconfig.json @@ -6,6 +6,7 @@ }, "include": [ "package.json", + "src/abi/IGnosisSafe.0.8.19.json", "src/**/*" ] } diff --git a/packages/common-ts/package.json b/packages/common-ts/package.json index 8ec207cea11a2..a16362195b7b4 100644 --- a/packages/common-ts/package.json +++ b/packages/common-ts/package.json @@ -35,10 +35,10 @@ }, "dependencies": { "@eth-optimism/core-utils": "workspace:*", - "@sentry/node": "^7.74.0", + "@sentry/node": "^7.77.0", "bcfg": "^0.2.1", "body-parser": "^1.20.2", - "commander": "^11.0.0", + "commander": "^11.1.0", "dotenv": "^16.3.1", "envalid": "^8.0.0", "ethers": "^5.7.2", @@ -46,7 +46,7 @@ "express-prom-bundle": "^6.6.0", "lodash": "^4.17.21", "morgan": "^1.10.0", - "pino": "^8.16.0", + "pino": "^8.16.1", "pino-multi-stream": "^6.0.0", "pino-sentry": "^0.14.0", "prom-client": "^14.2.0" @@ -55,9 +55,9 @@ "@ethersproject/abstract-provider": "^5.7.0", "@ethersproject/abstract-signer": "^5.7.0", "@types/express": "^4.17.19", - "@types/morgan": "^1.9.6", + "@types/morgan": "^1.9.7", "@types/pino": "^7.0.5", - "@types/pino-multi-stream": "^5.1.4", + "@types/pino-multi-stream": "^5.1.5", "chai": "^4.3.10", "supertest": "^6.3.3" } diff --git a/packages/common-ts/src/base-service/base-service-v2.ts b/packages/common-ts/src/base-service/base-service-v2.ts index e6b34a0d44f1b..79672e9b41e60 100644 --- a/packages/common-ts/src/base-service/base-service-v2.ts +++ b/packages/common-ts/src/base-service/base-service-v2.ts @@ -336,7 +336,8 @@ export abstract class BaseServiceV2< app.use( bodyParser.json({ verify: (req, res, buf, encoding) => { - ;(req as any).rawBody = buf?.toString(encoding || 'utf8') || '' + ;(req as any).rawBody = + buf?.toString((encoding as BufferEncoding) || 'utf8') || '' }, ...(this.params.bodyParserParams ?? {}), }) diff --git a/packages/contracts-bedrock/.envrc.example b/packages/contracts-bedrock/.envrc.example deleted file mode 100644 index fb10f785ff65e..0000000000000 --- a/packages/contracts-bedrock/.envrc.example +++ /dev/null @@ -1,18 +0,0 @@ -# RPC for the network to deploy to -export ETH_RPC_URL= - -# Sets the deployer's key to match the first default hardhat account -export PRIVATE_KEY=ac0974bec39a17e36ba4a6b4d238ff944bacb478cbed5efcae784d7bf4f2ff80 - -# Name of the deployed network -export DEPLOYMENT_CONTEXT=getting-started - -# Optional Tenderly details for a simulation link during deployment -export TENDERLY_PROJECT= -export TENDERLY_USERNAME= - -export ETHERSCAN_API_KEY= - -# Optional create2 salt for deterministic deployment of -# contract implementations -export IMPL_SALT=$(openssl rand -hex 32) diff --git a/packages/contracts-bedrock/.gas-snapshot b/packages/contracts-bedrock/.gas-snapshot index bfd8b24a237fe..353c6c6f105c5 100644 --- a/packages/contracts-bedrock/.gas-snapshot +++ b/packages/contracts-bedrock/.gas-snapshot @@ -1,576 +1,592 @@ -AdminFaucetAuthModuleTest:test_adminProof_verify_succeeds() (gas: 57573) +AdminFaucetAuthModuleTest:test_adminProof_verify_succeeds() (gas: 57607) AdminFaucetAuthModuleTest:test_nonAdminProof_verify_succeeds() (gas: 59050) AdminFaucetAuthModuleTest:test_proofWithWrongId_verify_succeeds() (gas: 60673) -AssetReceiverTest:test_constructor_succeeds() (gas: 9696) +AssetReceiverTest:test_constructor_succeeds() (gas: 9693) AssetReceiverTest:test_receive_succeeds() (gas: 20844) AssetReceiverTest:test_withdrawERC20_succeeds() (gas: 183383) AssetReceiverTest:test_withdrawERC20_unauthorized_reverts() (gas: 153517) AssetReceiverTest:test_withdrawERC20withAmount_succeeds() (gas: 182567) -AssetReceiverTest:test_withdrawERC20withAmount_unauthorized_reverts() (gas: 153528) +AssetReceiverTest:test_withdrawERC20withAmount_unauthorized_reverts() (gas: 153564) AssetReceiverTest:test_withdrawERC721_succeeds() (gas: 50755) AssetReceiverTest:test_withdrawERC721_unauthorized_reverts() (gas: 51063) AssetReceiverTest:test_withdrawETH_succeeds() (gas: 28344) AssetReceiverTest:test_withdrawETH_unauthorized_reverts() (gas: 10680) AssetReceiverTest:test_withdrawETHwithAmount_succeeds() (gas: 28241) AssetReceiverTest:test_withdrawETHwithAmount_unauthorized_reverts() (gas: 10738) -AttestationStationTest:test_attest_bulk_succeeds() (gas: 703749) -AttestationStationTest:test_attest_individual_succeeds() (gas: 632087) -AttestationStationTest:test_attest_single_succeeds() (gas: 651325) +AttestationStationTest:test_attest_bulk_succeeds() (gas: 544321) +AttestationStationTest:test_attest_individual_succeeds() (gas: 472850) +AttestationStationTest:test_attest_single_succeeds() (gas: 491962) BlockOracle_Test:test_checkpointAndLoad_succeeds() (gas: 58396) -BlockOracle_Test:test_load_noBlockHash_reverts() (gas: 12827) +BlockOracle_Test:test_load_noBlockHash_reverts() (gas: 13681) Bytes_slice_Test:test_slice_acrossMultipleWords_works() (gas: 9413) Bytes_slice_Test:test_slice_acrossWords_works() (gas: 1430) Bytes_slice_Test:test_slice_fromNonZeroIdx_works() (gas: 17240) Bytes_slice_Test:test_slice_fromZeroIdx_works() (gas: 20804) Bytes_toNibbles_Test:test_toNibbles_expectedResult128Bytes_works() (gas: 78882) Bytes_toNibbles_Test:test_toNibbles_expectedResult5Bytes_works() (gas: 3992) -Bytes_toNibbles_Test:test_toNibbles_zeroLengthInput_works() (gas: 823) +Bytes_toNibbles_Test:test_toNibbles_zeroLengthInput_works() (gas: 845) Constants_Test:test_eip1967Constants_succeeds() (gas: 453) -CrossDomainMessenger_BaseGas_Test:test_baseGas_succeeds() (gas: 20435) -CrossDomainOwnable2_Test:test_onlyOwner_notMessenger_reverts() (gas: 8461) -CrossDomainOwnable2_Test:test_onlyOwner_notOwner2_reverts() (gas: 57494) -CrossDomainOwnable2_Test:test_onlyOwner_notOwner_reverts() (gas: 16610) -CrossDomainOwnable2_Test:test_onlyOwner_succeeds() (gas: 73522) -CrossDomainOwnable3_Test:test_constructor_succeeds() (gas: 10554) -CrossDomainOwnable3_Test:test_crossDomainOnlyOwner_notMessenger_reverts() (gas: 28289) -CrossDomainOwnable3_Test:test_crossDomainOnlyOwner_notOwner2_reverts() (gas: 73970) -CrossDomainOwnable3_Test:test_crossDomainOnlyOwner_notOwner_reverts() (gas: 32000) -CrossDomainOwnable3_Test:test_crossDomainTransferOwnership_succeeds() (gas: 91527) -CrossDomainOwnable3_Test:test_localOnlyOwner_notOwner_reverts() (gas: 13215) -CrossDomainOwnable3_Test:test_localOnlyOwner_succeeds() (gas: 35242) -CrossDomainOwnable3_Test:test_localTransferOwnership_succeeds() (gas: 52084) -CrossDomainOwnable3_Test:test_transferOwnershipNoLocal_succeeds() (gas: 48610) -CrossDomainOwnable3_Test:test_transferOwnership_noLocalZeroAddress_reverts() (gas: 12037) -CrossDomainOwnable3_Test:test_transferOwnership_notOwner_reverts() (gas: 13437) -CrossDomainOwnable3_Test:test_transferOwnership_zeroAddress_reverts() (gas: 12081) -CrossDomainOwnableThroughPortal_Test:test_depositTransaction_crossDomainOwner_succeeds() (gas: 81417) +CrossDomainMessenger_BaseGas_Test:test_baseGas_succeeds() (gas: 20481) +CrossDomainOwnable2_Test:test_onlyOwner_notMessenger_reverts() (gas: 8539) +CrossDomainOwnable2_Test:test_onlyOwner_notOwner2_reverts() (gas: 57518) +CrossDomainOwnable2_Test:test_onlyOwner_notOwner_reverts() (gas: 16655) +CrossDomainOwnable2_Test:test_onlyOwner_succeeds() (gas: 73619) +CrossDomainOwnable3_Test:test_constructor_succeeds() (gas: 10627) +CrossDomainOwnable3_Test:test_crossDomainOnlyOwner_notMessenger_reverts() (gas: 28363) +CrossDomainOwnable3_Test:test_crossDomainOnlyOwner_notOwner2_reverts() (gas: 74002) +CrossDomainOwnable3_Test:test_crossDomainOnlyOwner_notOwner_reverts() (gas: 32118) +CrossDomainOwnable3_Test:test_crossDomainTransferOwnership_succeeds() (gas: 91600) +CrossDomainOwnable3_Test:test_localOnlyOwner_notOwner_reverts() (gas: 13260) +CrossDomainOwnable3_Test:test_localOnlyOwner_succeeds() (gas: 35271) +CrossDomainOwnable3_Test:test_localTransferOwnership_succeeds() (gas: 52158) +CrossDomainOwnable3_Test:test_transferOwnershipNoLocal_succeeds() (gas: 48662) +CrossDomainOwnable3_Test:test_transferOwnership_noLocalZeroAddress_reverts() (gas: 12090) +CrossDomainOwnable3_Test:test_transferOwnership_notOwner_reverts() (gas: 13460) +CrossDomainOwnable3_Test:test_transferOwnership_zeroAddress_reverts() (gas: 12177) +CrossDomainOwnableThroughPortal_Test:test_depositTransaction_crossDomainOwner_succeeds() (gas: 81574) CrossDomainOwnable_Test:test_onlyOwner_notOwner_reverts() (gas: 10597) -CrossDomainOwnable_Test:test_onlyOwner_succeeds() (gas: 34883) -DelayedVetoable_Getters_Test:test_getters() (gas: 24466) -DelayedVetoable_Getters_TestFail:test_getters_notZeroAddress_reverts() (gas: 31206) -DelayedVetoable_HandleCall_TestFail:test_handleCall_unauthorizedInitiation_reverts() (gas: 20291) -DeleteOutput:test_script_succeeds() (gas: 3100) +CrossDomainOwnable_Test:test_onlyOwner_succeeds() (gas: 34905) +DelayedVetoable_Getters_Test:test_getters() (gas: 24620) +DelayedVetoable_Getters_TestFail:test_getters_notZeroAddress_reverts() (gas: 36289) +DelayedVetoable_HandleCall_TestFail:test_handleCall_unauthorizedInitiation_reverts() (gas: 15165) DeployerWhitelist_Test:test_owner_succeeds() (gas: 7582) -DeployerWhitelist_Test:test_storageSlots_succeeds() (gas: 33395) -DisputeGameFactory_Owner_Test:test_owner_succeeds() (gas: 12581) -DisputeGameFactory_SetImplementation_Test:test_setImplementation_notOwner_reverts() (gas: 16042) -DisputeGameFactory_SetImplementation_Test:test_setImplementation_succeeds() (gas: 44301) -DisputeGameFactory_TransferOwnership_Test:test_transferOwnership_notOwner_reverts() (gas: 15950) -DisputeGameFactory_TransferOwnership_Test:test_transferOwnership_succeeds() (gas: 18642) -Drippie_Test:test_create_calledTwice_reverts() (gas: 168953) +DeployerWhitelist_Test:test_storageSlots_succeeds() (gas: 33417) +DisputeGameFactory_Owner_Test:test_owner_succeeds() (gas: 12611) +DisputeGameFactory_SetImplementation_Test:test_setImplementation_notOwner_reverts() (gas: 16078) +DisputeGameFactory_SetImplementation_Test:test_setImplementation_succeeds() (gas: 44323) +DisputeGameFactory_TransferOwnership_Test:test_transferOwnership_notOwner_reverts() (gas: 15974) +DisputeGameFactory_TransferOwnership_Test:test_transferOwnership_succeeds() (gas: 18738) +Drippie_Test:test_create_calledTwice_reverts() (gas: 168887) Drippie_Test:test_create_succeeds() (gas: 183401) -Drippie_Test:test_drip_amount_succeeds() (gas: 285353) +Drippie_Test:test_drip_amount_succeeds() (gas: 285375) Drippie_Test:test_drip_notExist_reverts() (gas: 14920) Drippie_Test:test_drip_reentrant_reverts() (gas: 18875) Drippie_Test:test_name_notExist_reverts() (gas: 16056) -Drippie_Test:test_notReentrant_zeroInterval_reverts() (gas: 18867) -Drippie_Test:test_not_active_reverts() (gas: 171162) -Drippie_Test:test_reentrant_succeeds() (gas: 180158) -Drippie_Test:test_set_statusNone_reverts() (gas: 168809) -Drippie_Test:test_set_statusSame_reverts() (gas: 169195) -Drippie_Test:test_set_status_succeeds() (gas: 198603) +Drippie_Test:test_notReentrant_zeroInterval_reverts() (gas: 18889) +Drippie_Test:test_not_active_reverts() (gas: 171184) +Drippie_Test:test_reentrant_succeeds() (gas: 180180) +Drippie_Test:test_set_statusNone_reverts() (gas: 168743) +Drippie_Test:test_set_statusSame_reverts() (gas: 169240) +Drippie_Test:test_set_status_succeeds() (gas: 198536) Drippie_Test:test_shouldArchive_ifPaused_succeeds() (gas: 177348) -Drippie_Test:test_shouldNotAllowActive_ifArchived_reverts() (gas: 174669) -Drippie_Test:test_shouldNotAllowPaused_ifArchived_reverts() (gas: 174692) -Drippie_Test:test_shouldNotArchive_ifActive_reverts() (gas: 175732) -Drippie_Test:test_status_unauthorized_reverts() (gas: 167388) -Drippie_Test:test_trigger_oneFunction_succeeds() (gas: 338226) -Drippie_Test:test_trigger_twoFunctions_succeeds() (gas: 491907) -Drippie_Test:test_twice_inOneInterval_reverts() (gas: 303933) -EASUpgrader:test_script_succeeds() (gas: 3078) -FaucetTest:test_authAdmin_drip_succeeds() (gas: 366107) -FaucetTest:test_drip_afterTimeout_succeeds() (gas: 447891) -FaucetTest:test_drip_beforeTimeout_reverts() (gas: 378884) -FaucetTest:test_drip_disabledModule_reverts() (gas: 352401) -FaucetTest:test_drip_emitsEvent_succeeds() (gas: 369161) -FaucetTest:test_drip_githubSendsCorrectAmount_succeeds() (gas: 366607) -FaucetTest:test_drip_optimistNftSendsCorrectAmount_succeeds() (gas: 366551) -FaucetTest:test_drip_preventsReplayAttacks_succeeds() (gas: 369214) -FaucetTest:test_initialize_succeeds() (gas: 7626) +Drippie_Test:test_shouldNotAllowActive_ifArchived_reverts() (gas: 174691) +Drippie_Test:test_shouldNotAllowPaused_ifArchived_reverts() (gas: 174714) +Drippie_Test:test_shouldNotArchive_ifActive_reverts() (gas: 175754) +Drippie_Test:test_status_unauthorized_reverts() (gas: 167410) +Drippie_Test:test_trigger_oneFunction_succeeds() (gas: 338248) +Drippie_Test:test_trigger_twoFunctions_succeeds() (gas: 491929) +Drippie_Test:test_twice_inOneInterval_reverts() (gas: 303889) +FaucetTest:test_authAdmin_drip_succeeds() (gas: 366064) +FaucetTest:test_drip_afterTimeout_succeeds() (gas: 447913) +FaucetTest:test_drip_beforeTimeout_reverts() (gas: 378906) +FaucetTest:test_drip_disabledModule_reverts() (gas: 352423) +FaucetTest:test_drip_emitsEvent_succeeds() (gas: 369116) +FaucetTest:test_drip_githubSendsCorrectAmount_succeeds() (gas: 366562) +FaucetTest:test_drip_optimistNftSendsCorrectAmount_succeeds() (gas: 366573) +FaucetTest:test_drip_preventsReplayAttacks_succeeds() (gas: 369236) +FaucetTest:test_initialize_succeeds() (gas: 7648) FaucetTest:test_nonAdmin_drip_fails() (gas: 262520) -FaucetTest:test_receive_succeeds() (gas: 17401) -FaucetTest:test_withdraw_nonAdmin_reverts() (gas: 13145) -FaucetTest:test_withdraw_succeeds() (gas: 78359) -FaultDisputeGame_ResolvesCorrectly_CorrectRoot1:test_resolvesCorrectly_succeeds() (gas: 660411) -FaultDisputeGame_ResolvesCorrectly_CorrectRoot2:test_resolvesCorrectly_succeeds() (gas: 667293) -FaultDisputeGame_ResolvesCorrectly_CorrectRoot3:test_resolvesCorrectly_succeeds() (gas: 663974) -FaultDisputeGame_ResolvesCorrectly_CorrectRoot4:test_resolvesCorrectly_succeeds() (gas: 667169) -FaultDisputeGame_ResolvesCorrectly_CorrectRoot5:test_resolvesCorrectly_succeeds() (gas: 666460) -FaultDisputeGame_ResolvesCorrectly_IncorrectRoot1:test_resolvesCorrectly_succeeds() (gas: 653092) -FaultDisputeGame_ResolvesCorrectly_IncorrectRoot2:test_resolvesCorrectly_succeeds() (gas: 658598) -FaultDisputeGame_ResolvesCorrectly_IncorrectRoot3:test_resolvesCorrectly_succeeds() (gas: 655943) -FaultDisputeGame_ResolvesCorrectly_IncorrectRoot4:test_resolvesCorrectly_succeeds() (gas: 656899) -FaultDisputeGame_ResolvesCorrectly_IncorrectRoot5:test_resolvesCorrectly_succeeds() (gas: 656332) -FaultDisputeGame_Test:test_addLocalData_static_succeeds() (gas: 640567) -FaultDisputeGame_Test:test_createdAt_succeeds() (gas: 10342) -FaultDisputeGame_Test:test_extraData_succeeds() (gas: 32328) -FaultDisputeGame_Test:test_gameData_succeeds() (gas: 32755) -FaultDisputeGame_Test:test_gameType_succeeds() (gas: 8265) -FaultDisputeGame_Test:test_initialize_correctData_succeeds() (gas: 57712) -FaultDisputeGame_Test:test_initialize_firstOutput_reverts() (gas: 210563) -FaultDisputeGame_Test:test_initialize_l1HeadTooOld_reverts() (gas: 228401) -FaultDisputeGame_Test:test_move_clockCorrectness_succeeds() (gas: 594268) -FaultDisputeGame_Test:test_move_clockTimeExceeded_reverts() (gas: 23175) -FaultDisputeGame_Test:test_move_defendRoot_reverts() (gas: 13366) -FaultDisputeGame_Test:test_move_duplicateClaim_reverts() (gas: 147389) -FaultDisputeGame_Test:test_move_duplicateClaimsDifferentSubgames_succeeds() (gas: 556885) -FaultDisputeGame_Test:test_move_gameDepthExceeded_reverts() (gas: 585897) -FaultDisputeGame_Test:test_move_gameNotInProgress_reverts() (gas: 11002) -FaultDisputeGame_Test:test_move_nonExistentParent_reverts() (gas: 24666) -FaultDisputeGame_Test:test_move_simpleAttack_succeeds() (gas: 151959) -FaultDisputeGame_Test:test_resolve_challengeContested_succeeds() (gas: 269413) +FaucetTest:test_receive_succeeds() (gas: 17423) +FaucetTest:test_withdraw_nonAdmin_reverts() (gas: 13167) +FaucetTest:test_withdraw_succeeds() (gas: 78381) +FaultDisputeGame_ResolvesCorrectly_CorrectRoot1:test_resolvesCorrectly_succeeds() (gas: 660030) +FaultDisputeGame_ResolvesCorrectly_CorrectRoot2:test_resolvesCorrectly_succeeds() (gas: 666890) +FaultDisputeGame_ResolvesCorrectly_CorrectRoot3:test_resolvesCorrectly_succeeds() (gas: 663593) +FaultDisputeGame_ResolvesCorrectly_CorrectRoot4:test_resolvesCorrectly_succeeds() (gas: 666766) +FaultDisputeGame_ResolvesCorrectly_CorrectRoot5:test_resolvesCorrectly_succeeds() (gas: 666079) +FaultDisputeGame_ResolvesCorrectly_IncorrectRoot1:test_resolvesCorrectly_succeeds() (gas: 652788) +FaultDisputeGame_ResolvesCorrectly_IncorrectRoot2:test_resolvesCorrectly_succeeds() (gas: 658276) +FaultDisputeGame_ResolvesCorrectly_IncorrectRoot3:test_resolvesCorrectly_succeeds() (gas: 655638) +FaultDisputeGame_ResolvesCorrectly_IncorrectRoot4:test_resolvesCorrectly_succeeds() (gas: 656576) +FaultDisputeGame_ResolvesCorrectly_IncorrectRoot5:test_resolvesCorrectly_succeeds() (gas: 656027) +FaultDisputeGame_Test:test_addLocalData_static_succeeds() (gas: 642366) +FaultDisputeGame_Test:test_createdAt_succeeds() (gas: 10461) +FaultDisputeGame_Test:test_extraData_succeeds() (gas: 32407) +FaultDisputeGame_Test:test_gameData_succeeds() (gas: 32857) +FaultDisputeGame_Test:test_gameType_succeeds() (gas: 8287) +FaultDisputeGame_Test:test_initialize_correctData_succeeds() (gas: 57761) +FaultDisputeGame_Test:test_initialize_firstOutput_reverts() (gas: 213868) +FaultDisputeGame_Test:test_initialize_l1HeadTooOld_reverts() (gas: 228482) +FaultDisputeGame_Test:test_move_clockCorrectness_succeeds() (gas: 594223) +FaultDisputeGame_Test:test_move_clockTimeExceeded_reverts() (gas: 23197) +FaultDisputeGame_Test:test_move_defendRoot_reverts() (gas: 13322) +FaultDisputeGame_Test:test_move_duplicateClaim_reverts() (gas: 147390) +FaultDisputeGame_Test:test_move_duplicateClaimsDifferentSubgames_succeeds() (gas: 556832) +FaultDisputeGame_Test:test_move_gameDepthExceeded_reverts() (gas: 585875) +FaultDisputeGame_Test:test_move_gameNotInProgress_reverts() (gas: 11010) +FaultDisputeGame_Test:test_move_nonExistentParent_reverts() (gas: 24668) +FaultDisputeGame_Test:test_move_simpleAttack_succeeds() (gas: 152008) +FaultDisputeGame_Test:test_resolve_challengeContested_succeeds() (gas: 269473) FaultDisputeGame_Test:test_resolve_claimAlreadyResolved_reverts() (gas: 272356) -FaultDisputeGame_Test:test_resolve_claimAtMaxDepthAlreadyResolved_reverts() (gas: 586672) -FaultDisputeGame_Test:test_resolve_notInProgress_reverts() (gas: 9732) -FaultDisputeGame_Test:test_resolve_outOfOrderResolution_reverts() (gas: 309037) -FaultDisputeGame_Test:test_resolve_rootContested_succeeds() (gas: 139044) -FaultDisputeGame_Test:test_resolve_rootUncontestedButUnresolved_reverts() (gas: 15883) -FaultDisputeGame_Test:test_resolve_rootUncontestedClockNotExpired_succeeds() (gas: 18406) -FaultDisputeGame_Test:test_resolve_rootUncontested_succeeds() (gas: 51409) -FaultDisputeGame_Test:test_resolve_stepReached_succeeds() (gas: 498476) -FaultDisputeGame_Test:test_resolve_teamDeathmatch_succeeds() (gas: 443373) +FaultDisputeGame_Test:test_resolve_claimAtMaxDepthAlreadyResolved_reverts() (gas: 586606) +FaultDisputeGame_Test:test_resolve_notInProgress_reverts() (gas: 9776) +FaultDisputeGame_Test:test_resolve_outOfOrderResolution_reverts() (gas: 309015) +FaultDisputeGame_Test:test_resolve_rootContested_succeeds() (gas: 139119) +FaultDisputeGame_Test:test_resolve_rootUncontestedButUnresolved_reverts() (gas: 15935) +FaultDisputeGame_Test:test_resolve_rootUncontestedClockNotExpired_succeeds() (gas: 18428) +FaultDisputeGame_Test:test_resolve_rootUncontested_succeeds() (gas: 51484) +FaultDisputeGame_Test:test_resolve_stepReached_succeeds() (gas: 498448) +FaultDisputeGame_Test:test_resolve_teamDeathmatch_succeeds() (gas: 443399) FaultDisputeGame_Test:test_rootClaim_succeeds() (gas: 8232) -FeeVault_Test:test_constructor_succeeds() (gas: 18185) -GasBenchMark_L1CrossDomainMessenger:test_sendMessage_benchmark_0() (gas: 354421) -GasBenchMark_L1CrossDomainMessenger:test_sendMessage_benchmark_1() (gas: 2952628) -GasBenchMark_L1StandardBridge_Deposit:test_depositERC20_benchmark_0() (gas: 542325) -GasBenchMark_L1StandardBridge_Deposit:test_depositERC20_benchmark_1() (gas: 4054518) -GasBenchMark_L1StandardBridge_Deposit:test_depositETH_benchmark_0() (gas: 443561) -GasBenchMark_L1StandardBridge_Deposit:test_depositETH_benchmark_1() (gas: 3489288) -GasBenchMark_L1StandardBridge_Finalize:test_finalizeETHWithdrawal_benchmark() (gas: 42714) -GasBenchMark_L2OutputOracle:test_proposeL2Output_benchmark() (gas: 90658) -GasBenchMark_OptimismPortal:test_depositTransaction_benchmark() (gas: 75076) -GasBenchMark_OptimismPortal:test_depositTransaction_benchmark_1() (gas: 75697) -GasBenchMark_OptimismPortal:test_proveWithdrawalTransaction_benchmark() (gas: 143181) -GasPriceOracle_Test:test_baseFee_succeeds() (gas: 8325) -GasPriceOracle_Test:test_decimals_succeeds() (gas: 6167) -GasPriceOracle_Test:test_gasPrice_succeeds() (gas: 8294) -GasPriceOracle_Test:test_l1BaseFee_succeeds() (gas: 10656) -GasPriceOracle_Test:test_overhead_succeeds() (gas: 10636) -GasPriceOracle_Test:test_scalar_succeeds() (gas: 10677) -GasPriceOracle_Test:test_setGasPrice_doesNotExist_reverts() (gas: 5910) -GasPriceOracle_Test:test_setL1BaseFee_doesNotExist_reverts() (gas: 5911) -GovernanceToken_Test:test_approve_succeeds() (gas: 133293) -GovernanceToken_Test:test_burnFrom_succeeds() (gas: 122733) -GovernanceToken_Test:test_burn_succeeds() (gas: 114588) -GovernanceToken_Test:test_constructor_succeeds() (gas: 21298) -GovernanceToken_Test:test_decreaseAllowance_succeeds() (gas: 137008) -GovernanceToken_Test:test_increaseAllowance_succeeds() (gas: 137118) -GovernanceToken_Test:test_mint_fromNotOwner_reverts() (gas: 17030) -GovernanceToken_Test:test_mint_fromOwner_succeeds() (gas: 108592) -GovernanceToken_Test:test_transferFrom_succeeds() (gas: 146273) -GovernanceToken_Test:test_transfer_succeeds() (gas: 138108) -Hashing_hashDepositSource_Test:test_hashDepositSource_succeeds() (gas: 633) -L1BlockNumberTest:test_fallback_succeeds() (gas: 18655) -L1BlockNumberTest:test_getL1BlockNumber_succeeds() (gas: 10625) +FeeVault_Test:test_constructor_baseFeeVault_succeeds() (gas: 17450) +FeeVault_Test:test_constructor_l1FeeVault_succeeds() (gas: 17418) +GasBenchMark_L1CrossDomainMessenger:test_sendMessage_benchmark_0() (gas: 354446) +GasBenchMark_L1CrossDomainMessenger:test_sendMessage_benchmark_1() (gas: 2952696) +GasBenchMark_L1StandardBridge_Deposit:test_depositERC20_benchmark_0() (gas: 544952) +GasBenchMark_L1StandardBridge_Deposit:test_depositERC20_benchmark_1() (gas: 4057122) +GasBenchMark_L1StandardBridge_Deposit:test_depositETH_benchmark_0() (gas: 446183) +GasBenchMark_L1StandardBridge_Deposit:test_depositETH_benchmark_1() (gas: 3491910) +GasBenchMark_L1StandardBridge_Finalize:test_finalizeETHWithdrawal_benchmark() (gas: 45337) +GasBenchMark_L2OutputOracle:test_proposeL2Output_benchmark() (gas: 88797) +GasBenchMark_OptimismPortal:test_depositTransaction_benchmark() (gas: 68317) +GasBenchMark_OptimismPortal:test_depositTransaction_benchmark_1() (gas: 68970) +GasBenchMark_OptimismPortal:test_proveWithdrawalTransaction_benchmark() (gas: 143303) +GasPriceOracle_Test:test_baseFee_succeeds() (gas: 8348) +GasPriceOracle_Test:test_decimals_succeeds() (gas: 6234) +GasPriceOracle_Test:test_gasPrice_succeeds() (gas: 8340) +GasPriceOracle_Test:test_l1BaseFee_succeeds() (gas: 10680) +GasPriceOracle_Test:test_overhead_succeeds() (gas: 10637) +GasPriceOracle_Test:test_scalar_succeeds() (gas: 10700) +GasPriceOracle_Test:test_setGasPrice_doesNotExist_reverts() (gas: 5956) +GasPriceOracle_Test:test_setL1BaseFee_doesNotExist_reverts() (gas: 5976) +GovernanceToken_Test:test_approve_succeeds() (gas: 138023) +GovernanceToken_Test:test_burnFrom_succeeds() (gas: 127582) +GovernanceToken_Test:test_burn_succeeds() (gas: 119092) +GovernanceToken_Test:test_constructor_succeeds() (gas: 23693) +GovernanceToken_Test:test_decreaseAllowance_succeeds() (gas: 141912) +GovernanceToken_Test:test_increaseAllowance_succeeds() (gas: 142022) +GovernanceToken_Test:test_mint_fromNotOwner_reverts() (gas: 21378) +GovernanceToken_Test:test_mint_fromOwner_succeeds() (gas: 110940) +GovernanceToken_Test:test_transferFrom_succeeds() (gas: 151340) +GovernanceToken_Test:test_transfer_succeeds() (gas: 142867) +Hashing_hashDepositSource_Test:test_hashDepositSource_succeeds() (gas: 700) +Initializer_Test:test_cannotReinitializeL1_succeeds() (gas: 101024) +L1BlockNumberTest:test_fallback_succeeds() (gas: 18677) +L1BlockNumberTest:test_getL1BlockNumber_succeeds() (gas: 10647) L1BlockNumberTest:test_receive_succeeds() (gas: 25384) -L1BlockTest:test_basefee_succeeds() (gas: 7554) -L1BlockTest:test_hash_succeeds() (gas: 7576) -L1BlockTest:test_number_succeeds() (gas: 7629) -L1BlockTest:test_sequenceNumber_succeeds() (gas: 7630) -L1BlockTest:test_timestamp_succeeds() (gas: 7640) -L1BlockTest:test_updateValues_succeeds() (gas: 60482) -L1CrossDomainMessenger_Test:test_messageVersion_succeeds() (gas: 24781) -L1CrossDomainMessenger_Test:test_relayMessage_legacyOldReplay_reverts() (gas: 49384) -L1CrossDomainMessenger_Test:test_relayMessage_legacyRetryAfterFailureThenSuccess_reverts() (gas: 212329) -L1CrossDomainMessenger_Test:test_relayMessage_legacyRetryAfterFailure_succeeds() (gas: 206087) +L1BlockTest:test_basefee_succeeds() (gas: 7576) +L1BlockTest:test_hash_succeeds() (gas: 7694) +L1BlockTest:test_number_succeeds() (gas: 7674) +L1BlockTest:test_sequenceNumber_succeeds() (gas: 7676) +L1BlockTest:test_timestamp_succeeds() (gas: 7663) +L1BlockTest:test_updateValues_succeeds() (gas: 63327) +L1CrossDomainMessenger_Test:test_messageVersion_succeeds() (gas: 24803) +L1CrossDomainMessenger_Test:test_relayMessage_legacyOldReplay_reverts() (gas: 49407) +L1CrossDomainMessenger_Test:test_relayMessage_legacyRetryAfterFailureThenSuccess_reverts() (gas: 239747) +L1CrossDomainMessenger_Test:test_relayMessage_legacyRetryAfterFailure_succeeds() (gas: 233439) L1CrossDomainMessenger_Test:test_relayMessage_legacyRetryAfterSuccess_reverts() (gas: 126344) -L1CrossDomainMessenger_Test:test_relayMessage_legacy_succeeds() (gas: 79599) -L1CrossDomainMessenger_Test:test_relayMessage_retryAfterFailure_succeeds() (gas: 200127) -L1CrossDomainMessenger_Test:test_relayMessage_succeeds() (gas: 76590) -L1CrossDomainMessenger_Test:test_relayMessage_toSystemContract_reverts() (gas: 60779) -L1CrossDomainMessenger_Test:test_relayMessage_v2_reverts() (gas: 12343) -L1CrossDomainMessenger_Test:test_replayMessage_withValue_reverts() (gas: 33133) -L1CrossDomainMessenger_Test:test_sendMessage_succeeds() (gas: 392933) -L1CrossDomainMessenger_Test:test_sendMessage_twice_succeeds() (gas: 1669172) -L1CrossDomainMessenger_Test:test_xDomainMessageSender_reset_succeeds() (gas: 86992) -L1CrossDomainMessenger_Test:test_xDomainSender_notSet_reverts() (gas: 24253) -L1ERC721Bridge_Test:test_bridgeERC721To_localTokenZeroAddress_reverts() (gas: 62677) -L1ERC721Bridge_Test:test_bridgeERC721To_remoteTokenZeroAddress_reverts() (gas: 37273) -L1ERC721Bridge_Test:test_bridgeERC721To_succeeds() (gas: 455254) -L1ERC721Bridge_Test:test_bridgeERC721To_wrongOwner_reverts() (gas: 70985) -L1ERC721Bridge_Test:test_bridgeERC721_fromContract_reverts() (gas: 35669) -L1ERC721Bridge_Test:test_bridgeERC721_localTokenZeroAddress_reverts() (gas: 60552) -L1ERC721Bridge_Test:test_bridgeERC721_remoteTokenZeroAddress_reverts() (gas: 35192) -L1ERC721Bridge_Test:test_bridgeERC721_succeeds() (gas: 454951) -L1ERC721Bridge_Test:test_bridgeERC721_wrongOwner_reverts() (gas: 70811) -L1ERC721Bridge_Test:test_constructor_succeeds() (gas: 18861) -L1ERC721Bridge_Test:test_finalizeBridgeERC721_notEscrowed_reverts() (gas: 29472) -L1ERC721Bridge_Test:test_finalizeBridgeERC721_notFromRemoteMessenger_reverts() (gas: 27217) -L1ERC721Bridge_Test:test_finalizeBridgeERC721_notViaLocalMessenger_reverts() (gas: 23238) -L1ERC721Bridge_Test:test_finalizeBridgeERC721_selfToken_reverts() (gas: 24990) -L1ERC721Bridge_Test:test_finalizeBridgeERC721_succeeds() (gas: 425227) -L1StandardBridge_BridgeETHTo_Test:test_bridgeETHTo_succeeds() (gas: 514756) -L1StandardBridge_BridgeETH_Test:test_bridgeETH_succeeds() (gas: 501934) -L1StandardBridge_DepositERC20To_Test:test_depositERC20To_succeeds() (gas: 720272) -L1StandardBridge_DepositERC20_Test:test_depositERC20_succeeds() (gas: 717849) -L1StandardBridge_DepositERC20_TestFail:test_depositERC20_notEoa_reverts() (gas: 22276) -L1StandardBridge_DepositETHTo_Test:test_depositETHTo_succeeds() (gas: 514789) -L1StandardBridge_DepositETH_Test:test_depositETH_succeeds() (gas: 502006) -L1StandardBridge_DepositETH_TestFail:test_depositETH_notEoa_reverts() (gas: 40759) -L1StandardBridge_FinalizeBridgeETH_Test:test_finalizeBridgeETH_succeeds() (gas: 54102) -L1StandardBridge_FinalizeBridgeETH_TestFail:test_finalizeBridgeETH_incorrectValue_reverts() (gas: 36551) -L1StandardBridge_FinalizeBridgeETH_TestFail:test_finalizeBridgeETH_sendToMessenger_reverts() (gas: 36738) -L1StandardBridge_FinalizeBridgeETH_TestFail:test_finalizeBridgeETH_sendToSelf_reverts() (gas: 36623) -L1StandardBridge_FinalizeERC20Withdrawal_Test:test_finalizeERC20Withdrawal_succeeds() (gas: 498144) -L1StandardBridge_FinalizeERC20Withdrawal_TestFail:test_finalizeERC20Withdrawal_notMessenger_reverts() (gas: 33452) -L1StandardBridge_FinalizeERC20Withdrawal_TestFail:test_finalizeERC20Withdrawal_notOtherBridge_reverts() (gas: 34118) -L1StandardBridge_FinalizeETHWithdrawal_Test:test_finalizeETHWithdrawal_succeeds() (gas: 64673) -L1StandardBridge_Getter_Test:test_getters_succeeds() (gas: 28383) -L1StandardBridge_Initialize_Test:test_initialize_succeeds() (gas: 27239) -L1StandardBridge_Receive_Test:test_receive_succeeds() (gas: 615130) -L2CrossDomainMessenger_Test:test_messageVersion_succeeds() (gas: 8477) -L2CrossDomainMessenger_Test:test_relayMessage_retry_succeeds() (gas: 163749) -L2CrossDomainMessenger_Test:test_relayMessage_succeeds() (gas: 48913) -L2CrossDomainMessenger_Test:test_relayMessage_toSystemContract_reverts() (gas: 31136) -L2CrossDomainMessenger_Test:test_relayMessage_v2_reverts() (gas: 11689) -L2CrossDomainMessenger_Test:test_sendMessage_succeeds() (gas: 123957) -L2CrossDomainMessenger_Test:test_sendMessage_twice_succeeds() (gas: 135812) -L2CrossDomainMessenger_Test:test_xDomainMessageSender_reset_succeeds() (gas: 48371) -L2CrossDomainMessenger_Test:test_xDomainSender_senderNotSet_reverts() (gas: 10590) -L2ERC721Bridge_Test:test_bridgeERC721To_localTokenZeroAddress_reverts() (gas: 31428) -L2ERC721Bridge_Test:test_bridgeERC721To_remoteTokenZeroAddress_reverts() (gas: 26826) -L2ERC721Bridge_Test:test_bridgeERC721To_succeeds() (gas: 157122) -L2ERC721Bridge_Test:test_bridgeERC721To_wrongOwner_reverts() (gas: 34461) -L2ERC721Bridge_Test:test_bridgeERC721_fromContract_reverts() (gas: 27177) -L2ERC721Bridge_Test:test_bridgeERC721_localTokenZeroAddress_reverts() (gas: 29302) -L2ERC721Bridge_Test:test_bridgeERC721_remoteTokenZeroAddress_reverts() (gas: 24635) -L2ERC721Bridge_Test:test_bridgeERC721_succeeds() (gas: 154737) -L2ERC721Bridge_Test:test_bridgeERC721_wrongOwner_reverts() (gas: 34265) -L2ERC721Bridge_Test:test_constructor_succeeds() (gas: 21027) -L2ERC721Bridge_Test:test_finalizeBridgeERC721_alreadyExists_reverts() (gas: 38658) -L2ERC721Bridge_Test:test_finalizeBridgeERC721_interfaceNotCompliant_reverts() (gas: 246925) -L2ERC721Bridge_Test:test_finalizeBridgeERC721_notFromRemoteMessenger_reverts() (gas: 27205) -L2ERC721Bridge_Test:test_finalizeBridgeERC721_notViaLocalMessenger_reverts() (gas: 23271) -L2ERC721Bridge_Test:test_finalizeBridgeERC721_selfToken_reverts() (gas: 27124) -L2ERC721Bridge_Test:test_finalizeBridgeERC721_succeeds() (gas: 179964) -L2OutputOracleUpgradeable_Test:test_initValuesOnImpl_succeeds() (gas: 23902) -L2OutputOracleUpgradeable_Test:test_initValuesOnProxy_succeeds() (gas: 46800) -L2OutputOracleUpgradeable_Test:test_initializeImpl_alreadyInitialized_reverts() (gas: 15216) -L2OutputOracleUpgradeable_Test:test_initializeProxy_alreadyInitialized_reverts() (gas: 20216) -L2OutputOracleUpgradeable_Test:test_upgrading_succeeds() (gas: 191455) -L2OutputOracle_constructor_Test:test_constructor_l2BlockTimeZero_reverts() (gas: 39022) -L2OutputOracle_constructor_Test:test_constructor_submissionInterval_reverts() (gas: 39032) -L2OutputOracle_constructor_Test:test_constructor_succeeds() (gas: 51777) -L2OutputOracle_constructor_Test:test_initialize_badTimestamp_reverts() (gas: 12353) -L2OutputOracle_deleteOutputs_Test:test_deleteL2Outputs_afterLatest_reverts() (gas: 217031) -L2OutputOracle_deleteOutputs_Test:test_deleteL2Outputs_finalized_reverts() (gas: 113258) -L2OutputOracle_deleteOutputs_Test:test_deleteL2Outputs_ifNotChallenger_reverts() (gas: 21018) -L2OutputOracle_deleteOutputs_Test:test_deleteL2Outputs_nonExistent_reverts() (gas: 111651) -L2OutputOracle_deleteOutputs_Test:test_deleteOutputs_multipleOutputs_succeeds() (gas: 307411) -L2OutputOracle_deleteOutputs_Test:test_deleteOutputs_singleOutput_succeeds() (gas: 185564) -L2OutputOracle_getter_Test:test_computeL2Timestamp_succeeds() (gas: 37341) -L2OutputOracle_getter_Test:test_getL2OutputIndexAfter_multipleOutputsExist_succeeds() (gas: 269700) -L2OutputOracle_getter_Test:test_getL2OutputIndexAfter_noOutputsExis_reverts() (gas: 17892) -L2OutputOracle_getter_Test:test_getL2OutputIndexAfter_previousBlock_succeeds() (gas: 98188) -L2OutputOracle_getter_Test:test_getL2OutputIndexAfter_sameBlock_succeeds() (gas: 98096) -L2OutputOracle_getter_Test:test_getL2Output_succeeds() (gas: 103735) -L2OutputOracle_getter_Test:test_latestBlockNumber_succeeds() (gas: 99129) -L2OutputOracle_getter_Test:test_nextBlockNumber_succeeds() (gas: 17447) -L2OutputOracle_proposeL2Output_Test:test_proposeL2Output_emptyOutput_reverts() (gas: 28812) -L2OutputOracle_proposeL2Output_Test:test_proposeL2Output_futureTimetamp_reverts() (gas: 30792) -L2OutputOracle_proposeL2Output_Test:test_proposeL2Output_notProposer_reverts() (gas: 27928) -L2OutputOracle_proposeL2Output_Test:test_proposeL2Output_proposeAnotherOutput_succeeds() (gas: 103242) -L2OutputOracle_proposeL2Output_Test:test_proposeL2Output_unexpectedBlockNumber_reverts() (gas: 30526) -L2OutputOracle_proposeL2Output_Test:test_proposeL2Output_unmatchedBlockhash_reverts() (gas: 31526) -L2OutputOracle_proposeL2Output_Test:test_proposeL2Output_wrongFork_reverts() (gas: 31129) -L2OutputOracle_proposeL2Output_Test:test_proposeWithBlockhashAndHeight_succeeds() (gas: 97442) -L2StandardBridge_BridgeERC20To_Test:test_bridgeERC20To_succeeds() (gas: 392297) -L2StandardBridge_BridgeERC20To_Test:test_withdrawTo_withdrawingERC20_succeeds() (gas: 392530) -L2StandardBridge_BridgeERC20_Test:test_bridgeERC20_succeeds() (gas: 387821) -L2StandardBridge_BridgeERC20_Test:test_bridgeLegacyERC20_succeeds() (gas: 396094) -L2StandardBridge_BridgeERC20_Test:test_withdrawLegacyERC20_succeeds() (gas: 396456) -L2StandardBridge_BridgeERC20_Test:test_withdraw_notEOA_reverts() (gas: 251807) -L2StandardBridge_BridgeERC20_Test:test_withdraw_withdrawingERC20_succeeds() (gas: 388103) -L2StandardBridge_Bridge_Test:test_finalizeBridgeETH_incorrectValue_reverts() (gas: 26132) -L2StandardBridge_Bridge_Test:test_finalizeBridgeETH_sendToMessenger_reverts() (gas: 26400) -L2StandardBridge_Bridge_Test:test_finalizeBridgeETH_sendToSelf_reverts() (gas: 26159) -L2StandardBridge_Bridge_Test:test_finalizeDeposit_depositingERC20_succeeds() (gas: 96091) -L2StandardBridge_Bridge_Test:test_finalizeDeposit_depositingETH_succeeds() (gas: 94945) -L2StandardBridge_FinalizeBridgeETH_Test:test_finalizeBridgeETH_succeeds() (gas: 45528) -L2StandardBridge_Test:test_initialize_succeeds() (gas: 26316) -L2StandardBridge_Test:test_receive_succeeds() (gas: 177125) -L2StandardBridge_Test:test_withdraw_ether_succeeds() (gas: 143366) -L2StandardBridge_Test:test_withdraw_insufficientValue_reverts() (gas: 16552) -L2ToL1MessagePasserTest:test_burn_succeeds() (gas: 112530) -L2ToL1MessagePasserTest:test_initiateWithdrawal_fromContract_succeeds() (gas: 70343) -L2ToL1MessagePasserTest:test_initiateWithdrawal_fromEOA_succeeds() (gas: 75830) -LegacyERC20ETH_Test:test_approve_doesNotExist_reverts() (gas: 10702) -LegacyERC20ETH_Test:test_burn_doesNotExist_reverts() (gas: 10637) -LegacyERC20ETH_Test:test_crossDomain_succeeds() (gas: 6341) -LegacyERC20ETH_Test:test_decreaseAllowance_doesNotExist_reverts() (gas: 10724) -LegacyERC20ETH_Test:test_increaseAllowance_doesNotExist_reverts() (gas: 10690) -LegacyERC20ETH_Test:test_metadata_succeeds() (gas: 15476) -LegacyERC20ETH_Test:test_mint_doesNotExist_reverts() (gas: 10627) -LegacyERC20ETH_Test:test_transferFrom_doesNotExist_reverts() (gas: 12957) -LegacyERC20ETH_Test:test_transfer_doesNotExist_reverts() (gas: 10755) -LegacyMessagePasser_Test:test_passMessageToL1_succeeds() (gas: 34524) -LibPosition_Test:test_pos_correctness_succeeds() (gas: 38689) -MIPS_Test:test_add_succeeds() (gas: 122420) -MIPS_Test:test_addiSign_succeeds() (gas: 122411) -MIPS_Test:test_addi_succeeds() (gas: 122608) -MIPS_Test:test_addu_succeeds() (gas: 122462) -MIPS_Test:test_addui_succeeds() (gas: 122670) -MIPS_Test:test_and_succeeds() (gas: 122481) -MIPS_Test:test_andi_succeeds() (gas: 122414) -MIPS_Test:test_beq_succeeds() (gas: 202801) -MIPS_Test:test_bgez_succeeds() (gas: 121707) -MIPS_Test:test_bgtz_succeeds() (gas: 121628) -MIPS_Test:test_blez_succeeds() (gas: 121584) -MIPS_Test:test_bltz_succeeds() (gas: 121727) -MIPS_Test:test_bne_succeeds() (gas: 121793) -MIPS_Test:test_branch_inDelaySlot_fails() (gas: 85999) -MIPS_Test:test_brk_succeeds() (gas: 122092) -MIPS_Test:test_clo_succeeds() (gas: 122149) -MIPS_Test:test_clone_succeeds() (gas: 122045) -MIPS_Test:test_clz_succeeds() (gas: 122620) -MIPS_Test:test_div_succeeds() (gas: 122599) -MIPS_Test:test_divu_succeeds() (gas: 122584) -MIPS_Test:test_exit_succeeds() (gas: 122094) -MIPS_Test:test_fcntl_succeeds() (gas: 204273) -MIPS_Test:test_illegal_instruction_fails() (gas: 91462) -MIPS_Test:test_invalid_root_fails() (gas: 435636) -MIPS_Test:test_jal_nonzeroRegion_succeeds() (gas: 120737) -MIPS_Test:test_jal_succeeds() (gas: 120726) -MIPS_Test:test_jalr_succeeds() (gas: 121845) -MIPS_Test:test_jr_succeeds() (gas: 121539) -MIPS_Test:test_jump_inDelaySlot_fails() (gas: 85367) -MIPS_Test:test_jump_nonzeroRegion_succeeds() (gas: 120481) -MIPS_Test:test_jump_succeeds() (gas: 120411) -MIPS_Test:test_lb_succeeds() (gas: 127652) -MIPS_Test:test_lbu_succeeds() (gas: 127550) -MIPS_Test:test_lh_succeeds() (gas: 127673) -MIPS_Test:test_lhu_succeeds() (gas: 127590) -MIPS_Test:test_ll_succeeds() (gas: 127812) -MIPS_Test:test_lui_succeeds() (gas: 121693) -MIPS_Test:test_lw_succeeds() (gas: 127441) -MIPS_Test:test_lwl_succeeds() (gas: 242046) -MIPS_Test:test_lwr_succeeds() (gas: 242334) -MIPS_Test:test_mfhi_succeeds() (gas: 122054) -MIPS_Test:test_mflo_succeeds() (gas: 122183) -MIPS_Test:test_mmap_succeeds() (gas: 119012) -MIPS_Test:test_movn_succeeds() (gas: 203473) -MIPS_Test:test_movz_succeeds() (gas: 203341) -MIPS_Test:test_mthi_succeeds() (gas: 122098) -MIPS_Test:test_mtlo_succeeds() (gas: 122206) -MIPS_Test:test_mul_succeeds() (gas: 121698) -MIPS_Test:test_mult_succeeds() (gas: 122402) -MIPS_Test:test_multu_succeeds() (gas: 122439) -MIPS_Test:test_nor_succeeds() (gas: 122531) -MIPS_Test:test_or_succeeds() (gas: 122488) -MIPS_Test:test_ori_succeeds() (gas: 122491) -MIPS_Test:test_preimage_read_succeeds() (gas: 234408) -MIPS_Test:test_preimage_write_succeeds() (gas: 127034) -MIPS_Test:test_prestate_exited_succeeds() (gas: 113280) -MIPS_Test:test_sb_succeeds() (gas: 160523) -MIPS_Test:test_sc_succeeds() (gas: 160717) -MIPS_Test:test_sh_succeeds() (gas: 160560) -MIPS_Test:test_sll_succeeds() (gas: 121659) -MIPS_Test:test_sllv_succeeds() (gas: 121888) -MIPS_Test:test_slt_succeeds() (gas: 204668) -MIPS_Test:test_sltu_succeeds() (gas: 122705) -MIPS_Test:test_sra_succeeds() (gas: 121910) -MIPS_Test:test_srav_succeeds() (gas: 122178) -MIPS_Test:test_srl_succeeds() (gas: 121741) -MIPS_Test:test_srlv_succeeds() (gas: 121906) -MIPS_Test:test_step_abi_succeeds() (gas: 58417) -MIPS_Test:test_sub_succeeds() (gas: 122515) -MIPS_Test:test_subu_succeeds() (gas: 122512) -MIPS_Test:test_sw_succeeds() (gas: 160535) -MIPS_Test:test_swl_succeeds() (gas: 160596) -MIPS_Test:test_swr_succeeds() (gas: 160671) -MIPS_Test:test_xor_succeeds() (gas: 122516) -MIPS_Test:test_xori_succeeds() (gas: 122568) -MerkleTrie_get_Test:test_get_corruptedProof_reverts() (gas: 5733) +L1CrossDomainMessenger_Test:test_relayMessage_legacy_succeeds() (gas: 79600) +L1CrossDomainMessenger_Test:test_relayMessage_retryAfterFailure_succeeds() (gas: 227457) +L1CrossDomainMessenger_Test:test_relayMessage_succeeds() (gas: 76636) +L1CrossDomainMessenger_Test:test_relayMessage_toSystemContract_reverts() (gas: 60802) +L1CrossDomainMessenger_Test:test_relayMessage_v2_reverts() (gas: 12410) +L1CrossDomainMessenger_Test:test_replayMessage_withValue_reverts() (gas: 33134) +L1CrossDomainMessenger_Test:test_sendMessage_succeeds() (gas: 392934) +L1CrossDomainMessenger_Test:test_sendMessage_twice_succeeds() (gas: 1669240) +L1CrossDomainMessenger_Test:test_xDomainMessageSender_reset_succeeds() (gas: 87957) +L1CrossDomainMessenger_Test:test_xDomainSender_notSet_reverts() (gas: 24282) +L1ERC721Bridge_Test:test_bridgeERC721To_localTokenZeroAddress_reverts() (gas: 62744) +L1ERC721Bridge_Test:test_bridgeERC721To_remoteTokenZeroAddress_reverts() (gas: 37318) +L1ERC721Bridge_Test:test_bridgeERC721To_succeeds() (gas: 455255) +L1ERC721Bridge_Test:test_bridgeERC721To_wrongOwner_reverts() (gas: 71007) +L1ERC721Bridge_Test:test_bridgeERC721_fromContract_reverts() (gas: 35737) +L1ERC721Bridge_Test:test_bridgeERC721_localTokenZeroAddress_reverts() (gas: 60596) +L1ERC721Bridge_Test:test_bridgeERC721_remoteTokenZeroAddress_reverts() (gas: 35173) +L1ERC721Bridge_Test:test_bridgeERC721_succeeds() (gas: 454995) +L1ERC721Bridge_Test:test_bridgeERC721_wrongOwner_reverts() (gas: 70855) +L1ERC721Bridge_Test:test_constructor_succeeds() (gas: 18883) +L1ERC721Bridge_Test:test_finalizeBridgeERC721_notEscrowed_reverts() (gas: 29495) +L1ERC721Bridge_Test:test_finalizeBridgeERC721_notFromRemoteMessenger_reverts() (gas: 27261) +L1ERC721Bridge_Test:test_finalizeBridgeERC721_notViaLocalMessenger_reverts() (gas: 23305) +L1ERC721Bridge_Test:test_finalizeBridgeERC721_selfToken_reverts() (gas: 25035) +L1ERC721Bridge_Test:test_finalizeBridgeERC721_succeeds() (gas: 425294) +L1StandardBridge_BridgeETHTo_Test:test_bridgeETHTo_succeeds() (gas: 517211) +L1StandardBridge_BridgeETH_Test:test_bridgeETH_succeeds() (gas: 504443) +L1StandardBridge_DepositERC20To_Test:test_depositERC20To_succeeds() (gas: 723456) +L1StandardBridge_DepositERC20_Test:test_depositERC20_succeeds() (gas: 721010) +L1StandardBridge_DepositERC20_TestFail:test_depositERC20_notEoa_reverts() (gas: 24955) +L1StandardBridge_DepositETHTo_Test:test_depositETHTo_succeeds() (gas: 517308) +L1StandardBridge_DepositETH_Test:test_depositETH_succeeds() (gas: 504582) +L1StandardBridge_DepositETH_TestFail:test_depositETH_notEoa_reverts() (gas: 43427) +L1StandardBridge_FinalizeBridgeETH_Test:test_finalizeBridgeETH_succeeds() (gas: 57849) +L1StandardBridge_FinalizeBridgeETH_TestFail:test_finalizeBridgeETH_incorrectValue_reverts() (gas: 40320) +L1StandardBridge_FinalizeBridgeETH_TestFail:test_finalizeBridgeETH_sendToMessenger_reverts() (gas: 40461) +L1StandardBridge_FinalizeBridgeETH_TestFail:test_finalizeBridgeETH_sendToSelf_reverts() (gas: 40347) +L1StandardBridge_FinalizeERC20Withdrawal_Test:test_finalizeERC20Withdrawal_succeeds() (gas: 478308) +L1StandardBridge_FinalizeERC20Withdrawal_TestFail:test_finalizeERC20Withdrawal_notMessenger_reverts() (gas: 37188) +L1StandardBridge_FinalizeERC20Withdrawal_TestFail:test_finalizeERC20Withdrawal_notOtherBridge_reverts() (gas: 37877) +L1StandardBridge_FinalizeETHWithdrawal_Test:test_finalizeETHWithdrawal_succeeds() (gas: 70062) +L1StandardBridge_Getter_Test:test_getters_succeeds() (gas: 32693) +L1StandardBridge_Initialize_Test:test_initialize_succeeds() (gas: 30372) +L1StandardBridge_Receive_Test:test_receive_succeeds() (gas: 617691) +L2CrossDomainMessenger_Test:test_messageVersion_succeeds() (gas: 8521) +L2CrossDomainMessenger_Test:test_relayMessage_retry_succeeds() (gas: 191101) +L2CrossDomainMessenger_Test:test_relayMessage_succeeds() (gas: 48936) +L2CrossDomainMessenger_Test:test_relayMessage_toSystemContract_reverts() (gas: 31159) +L2CrossDomainMessenger_Test:test_relayMessage_v2_reverts() (gas: 11756) +L2CrossDomainMessenger_Test:test_sendMessage_succeeds() (gas: 124025) +L2CrossDomainMessenger_Test:test_sendMessage_twice_succeeds() (gas: 135857) +L2CrossDomainMessenger_Test:test_xDomainMessageSender_reset_succeeds() (gas: 49311) +L2CrossDomainMessenger_Test:test_xDomainSender_senderNotSet_reverts() (gas: 10686) +L2ERC721Bridge_Test:test_bridgeERC721To_localTokenZeroAddress_reverts() (gas: 26498) +L2ERC721Bridge_Test:test_bridgeERC721To_remoteTokenZeroAddress_reverts() (gas: 21814) +L2ERC721Bridge_Test:test_bridgeERC721To_succeeds() (gas: 152123) +L2ERC721Bridge_Test:test_bridgeERC721To_wrongOwner_reverts() (gas: 29494) +L2ERC721Bridge_Test:test_bridgeERC721_fromContract_reverts() (gas: 22193) +L2ERC721Bridge_Test:test_bridgeERC721_localTokenZeroAddress_reverts() (gas: 24354) +L2ERC721Bridge_Test:test_bridgeERC721_remoteTokenZeroAddress_reverts() (gas: 19651) +L2ERC721Bridge_Test:test_bridgeERC721_succeeds() (gas: 149786) +L2ERC721Bridge_Test:test_bridgeERC721_wrongOwner_reverts() (gas: 29326) +L2ERC721Bridge_Test:test_constructor_succeeds() (gas: 14682) +L2ERC721Bridge_Test:test_finalizeBridgeERC721_alreadyExists_reverts() (gas: 33650) +L2ERC721Bridge_Test:test_finalizeBridgeERC721_interfaceNotCompliant_reverts() (gas: 241375) +L2ERC721Bridge_Test:test_finalizeBridgeERC721_notFromRemoteMessenger_reverts() (gas: 22215) +L2ERC721Bridge_Test:test_finalizeBridgeERC721_notViaLocalMessenger_reverts() (gas: 18282) +L2ERC721Bridge_Test:test_finalizeBridgeERC721_selfToken_reverts() (gas: 22113) +L2ERC721Bridge_Test:test_finalizeBridgeERC721_succeeds() (gas: 174514) +L2OutputOracleUpgradeable_Test:test_initValuesOnImpl_succeeds() (gas: 32635) +L2OutputOracleUpgradeable_Test:test_initValuesOnProxy_succeeds() (gas: 56622) +L2OutputOracleUpgradeable_Test:test_initializeImpl_alreadyInitialized_reverts() (gas: 24782) +L2OutputOracleUpgradeable_Test:test_initializeProxy_alreadyInitialized_reverts() (gas: 26380) +L2OutputOracleUpgradeable_Test:test_upgrading_succeeds() (gas: 191207) +L2OutputOracle_constructor_Test:test_constructor_l2BlockTimeZero_reverts() (gas: 44322) +L2OutputOracle_constructor_Test:test_constructor_submissionInterval_reverts() (gas: 44354) +L2OutputOracle_constructor_Test:test_constructor_succeeds() (gas: 61399) +L2OutputOracle_constructor_Test:test_initialize_badTimestamp_reverts() (gas: 12433) +L2OutputOracle_deleteOutputs_Test:test_deleteL2Outputs_afterLatest_reverts() (gas: 226802) +L2OutputOracle_deleteOutputs_Test:test_deleteL2Outputs_finalized_reverts() (gas: 118576) +L2OutputOracle_deleteOutputs_Test:test_deleteL2Outputs_ifNotChallenger_reverts() (gas: 21053) +L2OutputOracle_deleteOutputs_Test:test_deleteL2Outputs_nonExistent_reverts() (gas: 117047) +L2OutputOracle_deleteOutputs_Test:test_deleteOutputs_multipleOutputs_succeeds() (gas: 318177) +L2OutputOracle_deleteOutputs_Test:test_deleteOutputs_singleOutput_succeeds() (gas: 193280) +L2OutputOracle_getter_Test:test_computeL2Timestamp_succeeds() (gas: 44553) +L2OutputOracle_getter_Test:test_getL2OutputIndexAfter_multipleOutputsExist_succeeds() (gas: 277454) +L2OutputOracle_getter_Test:test_getL2OutputIndexAfter_noOutputsExis_reverts() (gas: 17937) +L2OutputOracle_getter_Test:test_getL2OutputIndexAfter_previousBlock_succeeds() (gas: 103541) +L2OutputOracle_getter_Test:test_getL2OutputIndexAfter_sameBlock_succeeds() (gas: 103449) +L2OutputOracle_getter_Test:test_getL2Output_succeeds() (gas: 109931) +L2OutputOracle_getter_Test:test_latestBlockNumber_succeeds() (gas: 104526) +L2OutputOracle_getter_Test:test_nextBlockNumber_succeeds() (gas: 17492) +L2OutputOracle_proposeL2Output_Test:test_proposeL2Output_emptyOutput_reverts() (gas: 34188) +L2OutputOracle_proposeL2Output_Test:test_proposeL2Output_futureTimetamp_reverts() (gas: 34217) +L2OutputOracle_proposeL2Output_Test:test_proposeL2Output_notProposer_reverts() (gas: 26098) +L2OutputOracle_proposeL2Output_Test:test_proposeL2Output_proposeAnotherOutput_succeeds() (gas: 109345) +L2OutputOracle_proposeL2Output_Test:test_proposeL2Output_unexpectedBlockNumber_reverts() (gas: 33945) +L2OutputOracle_proposeL2Output_Test:test_proposeL2Output_unmatchedBlockhash_reverts() (gas: 34968) +L2OutputOracle_proposeL2Output_Test:test_proposeL2Output_wrongFork_reverts() (gas: 34466) +L2OutputOracle_proposeL2Output_Test:test_proposeWithBlockhashAndHeight_succeeds() (gas: 100845) +L2StandardBridge_BridgeERC20To_Test:test_bridgeERC20To_succeeds() (gas: 392336) +L2StandardBridge_BridgeERC20To_Test:test_withdrawTo_withdrawingERC20_succeeds() (gas: 392584) +L2StandardBridge_BridgeERC20_Test:test_bridgeERC20_succeeds() (gas: 387967) +L2StandardBridge_BridgeERC20_Test:test_bridgeLegacyERC20_succeeds() (gas: 396235) +L2StandardBridge_BridgeERC20_Test:test_withdrawLegacyERC20_succeeds() (gas: 396580) +L2StandardBridge_BridgeERC20_Test:test_withdraw_notEOA_reverts() (gas: 251904) +L2StandardBridge_BridgeERC20_Test:test_withdraw_withdrawingERC20_succeeds() (gas: 388246) +L2StandardBridge_Bridge_Test:test_finalizeBridgeETH_incorrectValue_reverts() (gas: 26200) +L2StandardBridge_Bridge_Test:test_finalizeBridgeETH_sendToMessenger_reverts() (gas: 26422) +L2StandardBridge_Bridge_Test:test_finalizeBridgeETH_sendToSelf_reverts() (gas: 26227) +L2StandardBridge_Bridge_Test:test_finalizeDeposit_depositingERC20_succeeds() (gas: 96147) +L2StandardBridge_Bridge_Test:test_finalizeDeposit_depositingETH_succeeds() (gas: 95044) +L2StandardBridge_FinalizeBridgeETH_Test:test_finalizeBridgeETH_succeeds() (gas: 45610) +L2StandardBridge_Test:test_initialize_succeeds() (gas: 28894) +L2StandardBridge_Test:test_receive_succeeds() (gas: 177147) +L2StandardBridge_Test:test_withdraw_ether_succeeds() (gas: 143411) +L2StandardBridge_Test:test_withdraw_insufficientValue_reverts() (gas: 16586) +LegacyERC20ETH_Test:test_approve_doesNotExist_reverts() (gas: 10745) +LegacyERC20ETH_Test:test_burn_doesNotExist_reverts() (gas: 10705) +LegacyERC20ETH_Test:test_crossDomain_succeeds() (gas: 6400) +LegacyERC20ETH_Test:test_decreaseAllowance_doesNotExist_reverts() (gas: 10747) +LegacyERC20ETH_Test:test_increaseAllowance_doesNotExist_reverts() (gas: 10757) +LegacyERC20ETH_Test:test_metadata_succeeds() (gas: 15795) +LegacyERC20ETH_Test:test_mint_doesNotExist_reverts() (gas: 10672) +LegacyERC20ETH_Test:test_transferFrom_doesNotExist_reverts() (gas: 13002) +LegacyERC20ETH_Test:test_transfer_doesNotExist_reverts() (gas: 10801) +LegacyMessagePasser_Test:test_passMessageToL1_succeeds() (gas: 34629) +LibPosition_Test:test_pos_correctness_succeeds() (gas: 38711) +LivenessGuard_CheckAfterExecution_TestFails:test_checkAfterExecution_callerIsNotSafe_revert() (gas: 8576) +LivenessGuard_CheckTx_Test:test_checkTransaction_succeeds() (gas: 233535) +LivenessGuard_CheckTx_TestFails:test_checkTransaction_callerIsNotSafe_revert() (gas: 10358) +LivenessGuard_Constructor_Test:test_constructor_works() (gas: 1198965) +LivenessGuard_Getters_Test:test_getters_works() (gas: 10662) +LivenessGuard_OwnerManagement_Test:test_addOwner_succeeds() (gas: 274384) +LivenessGuard_OwnerManagement_Test:test_removeOwner_succeeds() (gas: 243663) +LivenessGuard_OwnerManagement_Test:test_swapOwner_succeeds() (gas: 282261) +LivenessGuard_ShowLiveness_Test:test_showLiveness_succeeds() (gas: 28850) +LivenessGuard_ShowLiveness_TestFail:test_showLiveness_callIsNotSafeOwner_reverts() (gas: 18770) +LivenessModule_CanRemove_Test:test_canRemove_works() (gas: 33071) +LivenessModule_CanRemove_TestFail:test_canRemove_notSafeOwner_reverts() (gas: 20534) +LivenessModule_Constructor_TestFail:test_constructor_minOwnersGreaterThanOwners_reverts() (gas: 83623) +LivenessModule_Constructor_TestFail:test_constructor_wrongThreshold_reverts() (gas: 92903) +LivenessModule_Get75PercentThreshold_Test:test_get75PercentThreshold_Works() (gas: 26384) +LivenessModule_Getters_Test:test_getters_works() (gas: 14853) +LivenessModule_RemoveOwners_Test:test_removeOwners_allOwners_succeeds() (gas: 1316416) +LivenessModule_RemoveOwners_Test:test_removeOwners_oneOwner_succeeds() (gas: 130750) +LivenessModule_RemoveOwners_TestFail:test_removeOwners_belowEmptiedButNotShutDown_reverts() (gas: 1269620) +LivenessModule_RemoveOwners_TestFail:test_removeOwners_belowMinButNotEmptied_reverts() (gas: 1273409) +LivenessModule_RemoveOwners_TestFail:test_removeOwners_differentArrayLengths_reverts() (gas: 10502) +LivenessModule_RemoveOwners_TestFail:test_removeOwners_guardChanged_reverts() (gas: 2836151) +LivenessModule_RemoveOwners_TestFail:test_removeOwners_invalidThreshold_reverts() (gas: 69313) +LivenessModule_RemoveOwners_TestFail:test_removeOwners_ownerHasShownLivenessRecently_reverts() (gas: 77771) +LivenessModule_RemoveOwners_TestFail:test_removeOwners_ownerHasSignedRecently_reverts() (gas: 615047) +LivenessModule_RemoveOwners_TestFail:test_removeOwners_swapToFallbackOwner_reverts() (gas: 1278252) +LivenessModule_RemoveOwners_TestFail:test_removeOwners_wrongPreviousOwner_reverts() (gas: 73954) +MIPS_Test:test_add_succeeds() (gas: 123021) +MIPS_Test:test_addiSign_succeeds() (gas: 122946) +MIPS_Test:test_addi_succeeds() (gas: 123166) +MIPS_Test:test_addu_succeeds() (gas: 122975) +MIPS_Test:test_addui_succeeds() (gas: 123162) +MIPS_Test:test_and_succeeds() (gas: 123017) +MIPS_Test:test_andi_succeeds() (gas: 122994) +MIPS_Test:test_beq_succeeds() (gas: 203427) +MIPS_Test:test_bgez_succeeds() (gas: 122265) +MIPS_Test:test_bgtz_succeeds() (gas: 122205) +MIPS_Test:test_blez_succeeds() (gas: 122142) +MIPS_Test:test_bltz_succeeds() (gas: 122262) +MIPS_Test:test_bne_succeeds() (gas: 122351) +MIPS_Test:test_branch_inDelaySlot_fails() (gas: 86536) +MIPS_Test:test_brk_succeeds() (gas: 122655) +MIPS_Test:test_clo_succeeds() (gas: 122707) +MIPS_Test:test_clone_succeeds() (gas: 122563) +MIPS_Test:test_clz_succeeds() (gas: 123177) +MIPS_Test:test_div_succeeds() (gas: 123134) +MIPS_Test:test_divu_succeeds() (gas: 123142) +MIPS_Test:test_exit_succeeds() (gas: 122657) +MIPS_Test:test_fcntl_succeeds() (gas: 204864) +MIPS_Test:test_illegal_instruction_fails() (gas: 92045) +MIPS_Test:test_invalid_root_fails() (gas: 436238) +MIPS_Test:test_jal_nonzeroRegion_succeeds() (gas: 121250) +MIPS_Test:test_jal_succeeds() (gas: 121217) +MIPS_Test:test_jalr_succeeds() (gas: 122425) +MIPS_Test:test_jr_succeeds() (gas: 122096) +MIPS_Test:test_jump_inDelaySlot_fails() (gas: 85884) +MIPS_Test:test_jump_nonzeroRegion_succeeds() (gas: 120994) +MIPS_Test:test_jump_succeeds() (gas: 120969) +MIPS_Test:test_lb_succeeds() (gas: 128187) +MIPS_Test:test_lbu_succeeds() (gas: 128085) +MIPS_Test:test_lh_succeeds() (gas: 128229) +MIPS_Test:test_lhu_succeeds() (gas: 128103) +MIPS_Test:test_ll_succeeds() (gas: 128303) +MIPS_Test:test_lui_succeeds() (gas: 122293) +MIPS_Test:test_lw_succeeds() (gas: 127976) +MIPS_Test:test_lwl_succeeds() (gas: 243161) +MIPS_Test:test_lwr_succeeds() (gas: 243428) +MIPS_Test:test_mfhi_succeeds() (gas: 122634) +MIPS_Test:test_mflo_succeeds() (gas: 122718) +MIPS_Test:test_mmap_succeeds() (gas: 119637) +MIPS_Test:test_movn_succeeds() (gas: 204054) +MIPS_Test:test_movz_succeeds() (gas: 203945) +MIPS_Test:test_mthi_succeeds() (gas: 122678) +MIPS_Test:test_mtlo_succeeds() (gas: 122741) +MIPS_Test:test_mul_succeeds() (gas: 122278) +MIPS_Test:test_mult_succeeds() (gas: 122959) +MIPS_Test:test_multu_succeeds() (gas: 123018) +MIPS_Test:test_nor_succeeds() (gas: 123109) +MIPS_Test:test_or_succeeds() (gas: 123024) +MIPS_Test:test_ori_succeeds() (gas: 123026) +MIPS_Test:test_preimage_read_succeeds() (gas: 235502) +MIPS_Test:test_preimage_write_succeeds() (gas: 127574) +MIPS_Test:test_prestate_exited_succeeds() (gas: 113835) +MIPS_Test:test_sb_succeeds() (gas: 161547) +MIPS_Test:test_sc_succeeds() (gas: 161752) +MIPS_Test:test_sh_succeeds() (gas: 161606) +MIPS_Test:test_sll_succeeds() (gas: 122260) +MIPS_Test:test_sllv_succeeds() (gas: 122402) +MIPS_Test:test_slt_succeeds() (gas: 205250) +MIPS_Test:test_sltu_succeeds() (gas: 123285) +MIPS_Test:test_sra_succeeds() (gas: 122490) +MIPS_Test:test_srav_succeeds() (gas: 122758) +MIPS_Test:test_srl_succeeds() (gas: 122276) +MIPS_Test:test_srlv_succeeds() (gas: 122506) +MIPS_Test:test_step_abi_succeeds() (gas: 58532) +MIPS_Test:test_sub_succeeds() (gas: 123007) +MIPS_Test:test_subu_succeeds() (gas: 123092) +MIPS_Test:test_sw_succeeds() (gas: 161604) +MIPS_Test:test_swl_succeeds() (gas: 161621) +MIPS_Test:test_swr_succeeds() (gas: 161696) +MIPS_Test:test_xor_succeeds() (gas: 123029) +MIPS_Test:test_xori_succeeds() (gas: 123147) +MerkleTrie_get_Test:test_get_corruptedProof_reverts() (gas: 5710) MerkleTrie_get_Test:test_get_extraProofElements_reverts() (gas: 58889) -MerkleTrie_get_Test:test_get_invalidDataRemainder_reverts() (gas: 35845) -MerkleTrie_get_Test:test_get_invalidInternalNodeHash_reverts() (gas: 49654) -MerkleTrie_get_Test:test_get_nonexistentKey1_reverts() (gas: 54770) +MerkleTrie_get_Test:test_get_invalidDataRemainder_reverts() (gas: 35867) +MerkleTrie_get_Test:test_get_invalidInternalNodeHash_reverts() (gas: 49676) +MerkleTrie_get_Test:test_get_nonexistentKey1_reverts() (gas: 54792) MerkleTrie_get_Test:test_get_nonexistentKey2_reverts() (gas: 16699) -MerkleTrie_get_Test:test_get_smallerPathThanKey1_reverts() (gas: 51403) -MerkleTrie_get_Test:test_get_smallerPathThanKey2_reverts() (gas: 52884) +MerkleTrie_get_Test:test_get_smallerPathThanKey1_reverts() (gas: 51425) +MerkleTrie_get_Test:test_get_smallerPathThanKey2_reverts() (gas: 52840) MerkleTrie_get_Test:test_get_validProof10_succeeds() (gas: 48845) MerkleTrie_get_Test:test_get_validProof1_succeeds() (gas: 55970) -MerkleTrie_get_Test:test_get_validProof2_succeeds() (gas: 65861) +MerkleTrie_get_Test:test_get_validProof2_succeeds() (gas: 65883) MerkleTrie_get_Test:test_get_validProof3_succeeds() (gas: 27309) -MerkleTrie_get_Test:test_get_validProof4_succeeds() (gas: 18105) +MerkleTrie_get_Test:test_get_validProof4_succeeds() (gas: 18127) MerkleTrie_get_Test:test_get_validProof5_succeeds() (gas: 80701) MerkleTrie_get_Test:test_get_validProof6_succeeds() (gas: 69460) -MerkleTrie_get_Test:test_get_validProof7_succeeds() (gas: 76158) -MerkleTrie_get_Test:test_get_validProof8_succeeds() (gas: 48802) +MerkleTrie_get_Test:test_get_validProof7_succeeds() (gas: 76115) +MerkleTrie_get_Test:test_get_validProof8_succeeds() (gas: 48824) MerkleTrie_get_Test:test_get_validProof9_succeeds() (gas: 48802) -MerkleTrie_get_Test:test_get_wrongKeyProof_reverts() (gas: 50730) -MerkleTrie_get_Test:test_get_zeroBranchValueLength_reverts() (gas: 41684) +MerkleTrie_get_Test:test_get_wrongKeyProof_reverts() (gas: 50752) +MerkleTrie_get_Test:test_get_zeroBranchValueLength_reverts() (gas: 41706) MerkleTrie_get_Test:test_get_zeroLengthKey_reverts() (gas: 3632) -MintManager_constructor_Test:test_constructor_succeeds() (gas: 10579) -MintManager_mint_Test:test_mint_afterPeriodElapsed_succeeds() (gas: 148117) -MintManager_mint_Test:test_mint_beforePeriodElapsed_reverts() (gas: 140433) -MintManager_mint_Test:test_mint_fromNotOwner_reverts() (gas: 10987) -MintManager_mint_Test:test_mint_fromOwner_succeeds() (gas: 137219) -MintManager_mint_Test:test_mint_moreThanCap_reverts() (gas: 142523) -MintManager_upgrade_Test:test_upgrade_fromNotOwner_reverts() (gas: 10974) -MintManager_upgrade_Test:test_upgrade_fromOwner_succeeds() (gas: 23434) -MintManager_upgrade_Test:test_upgrade_toZeroAddress_reverts() (gas: 11003) +MintManager_constructor_Test:test_constructor_succeeds() (gas: 10623) +MintManager_mint_Test:test_mint_afterPeriodElapsed_succeeds() (gas: 148184) +MintManager_mint_Test:test_mint_beforePeriodElapsed_reverts() (gas: 140479) +MintManager_mint_Test:test_mint_fromNotOwner_reverts() (gas: 11054) +MintManager_mint_Test:test_mint_fromOwner_succeeds() (gas: 137330) +MintManager_mint_Test:test_mint_moreThanCap_reverts() (gas: 142590) +MintManager_upgrade_Test:test_upgrade_fromNotOwner_reverts() (gas: 11041) +MintManager_upgrade_Test:test_upgrade_fromOwner_succeeds() (gas: 23509) +MintManager_upgrade_Test:test_upgrade_toZeroAddress_reverts() (gas: 11070) Multichain:test_script_succeeds() (gas: 3078) -OptimismMintableERC20_Test:test_bridge_succeeds() (gas: 7621) -OptimismMintableERC20_Test:test_burn_notBridge_reverts() (gas: 11164) -OptimismMintableERC20_Test:test_burn_succeeds() (gas: 50996) -OptimismMintableERC20_Test:test_erc165_supportsInterface_succeeds() (gas: 7787) -OptimismMintableERC20_Test:test_l1Token_succeeds() (gas: 7621) -OptimismMintableERC20_Test:test_l2Bridge_succeeds() (gas: 7621) -OptimismMintableERC20_Test:test_legacy_succeeds() (gas: 14322) -OptimismMintableERC20_Test:test_mint_notBridge_reverts() (gas: 11165) -OptimismMintableERC20_Test:test_mint_succeeds() (gas: 63544) -OptimismMintableERC20_Test:test_remoteToken_succeeds() (gas: 7667) -OptimismMintableERC721Factory_Test:test_constructor_succeeds() (gas: 8351) -OptimismMintableERC721Factory_Test:test_createOptimismMintableERC721_sameTwice_reverts() (gas: 8937393460516800041) -OptimismMintableERC721Factory_Test:test_createOptimismMintableERC721_succeeds() (gas: 2316109) -OptimismMintableERC721Factory_Test:test_createOptimismMintableERC721_zeroRemoteToken_reverts() (gas: 9418) -OptimismMintableERC721_Test:test_burn_notBridge_reverts() (gas: 136966) -OptimismMintableERC721_Test:test_burn_succeeds() (gas: 118832) -OptimismMintableERC721_Test:test_constructor_succeeds() (gas: 24162) -OptimismMintableERC721_Test:test_safeMint_notBridge_reverts() (gas: 11121) -OptimismMintableERC721_Test:test_safeMint_succeeds() (gas: 140547) -OptimismMintableERC721_Test:test_supportsInterfaces_succeeds() (gas: 9005) -OptimismMintableERC721_Test:test_tokenURI_succeeds() (gas: 163441) -OptimismMintableTokenFactory_Test:test_bridge_succeeds() (gas: 9760) -OptimismMintableTokenFactory_Test:test_createStandardL2TokenWithDecimals_succeeds() (gas: 1303953) -OptimismMintableTokenFactory_Test:test_createStandardL2Token_remoteIsZero_reverts() (gas: 9570) -OptimismMintableTokenFactory_Test:test_createStandardL2Token_sameTwice_reverts() (gas: 8937393460516769327) -OptimismMintableTokenFactory_Test:test_createStandardL2Token_succeeds() (gas: 1303943) -OptimismPortalUpgradeable_Test:test_initialize_cannotInitImpl_reverts() (gas: 11178) -OptimismPortalUpgradeable_Test:test_initialize_cannotInitProxy_reverts() (gas: 16111) -OptimismPortalUpgradeable_Test:test_params_initValuesOnProxy_succeeds() (gas: 26781) -OptimismPortalUpgradeable_Test:test_upgradeToAndCall_upgrading_succeeds() (gas: 191521) -OptimismPortal_FinalizeWithdrawal_Test:test_finalizeWithdrawalTransaction_ifOutputRootChanges_reverts() (gas: 178667) -OptimismPortal_FinalizeWithdrawal_Test:test_finalizeWithdrawalTransaction_ifOutputTimestampIsNotFinalized_reverts() (gas: 182306) -OptimismPortal_FinalizeWithdrawal_Test:test_finalizeWithdrawalTransaction_ifWithdrawalNotProven_reverts() (gas: 41780) -OptimismPortal_FinalizeWithdrawal_Test:test_finalizeWithdrawalTransaction_ifWithdrawalProofNotOldEnough_reverts() (gas: 173953) -OptimismPortal_FinalizeWithdrawal_Test:test_finalizeWithdrawalTransaction_onInsufficientGas_reverts() (gas: 180724) -OptimismPortal_FinalizeWithdrawal_Test:test_finalizeWithdrawalTransaction_onRecentWithdrawal_reverts() (gas: 154740) -OptimismPortal_FinalizeWithdrawal_Test:test_finalizeWithdrawalTransaction_onReentrancy_reverts() (gas: 218770) -OptimismPortal_FinalizeWithdrawal_Test:test_finalizeWithdrawalTransaction_onReplay_reverts() (gas: 220983) -OptimismPortal_FinalizeWithdrawal_Test:test_finalizeWithdrawalTransaction_paused_reverts() (gas: 38706) -OptimismPortal_FinalizeWithdrawal_Test:test_finalizeWithdrawalTransaction_provenWithdrawalHash_succeeds() (gas: 209679) -OptimismPortal_FinalizeWithdrawal_Test:test_finalizeWithdrawalTransaction_targetFails_fails() (gas: 8797746687696162676) -OptimismPortal_FinalizeWithdrawal_Test:test_finalizeWithdrawalTransaction_timestampLessThanL2OracleStart_reverts() (gas: 171302) -OptimismPortal_FinalizeWithdrawal_Test:test_proveWithdrawalTransaction_onInvalidOutputRootProof_reverts() (gas: 85805) -OptimismPortal_FinalizeWithdrawal_Test:test_proveWithdrawalTransaction_onInvalidWithdrawalProof_reverts() (gas: 111317) -OptimismPortal_FinalizeWithdrawal_Test:test_proveWithdrawalTransaction_onSelfCall_reverts() (gas: 52973) -OptimismPortal_FinalizeWithdrawal_Test:test_proveWithdrawalTransaction_paused_reverts() (gas: 58846) -OptimismPortal_FinalizeWithdrawal_Test:test_proveWithdrawalTransaction_replayProveChangedOutputRootAndOutputIndex_succeeds() (gas: 297494) -OptimismPortal_FinalizeWithdrawal_Test:test_proveWithdrawalTransaction_replayProveChangedOutputRoot_succeeds() (gas: 227596) +OptimismMintableERC20_Test:test_bridge_succeeds() (gas: 7732) +OptimismMintableERC20_Test:test_burn_notBridge_reverts() (gas: 11168) +OptimismMintableERC20_Test:test_burn_succeeds() (gas: 51057) +OptimismMintableERC20_Test:test_erc165_supportsInterface_succeeds() (gas: 7863) +OptimismMintableERC20_Test:test_l1Token_succeeds() (gas: 7732) +OptimismMintableERC20_Test:test_l2Bridge_succeeds() (gas: 7687) +OptimismMintableERC20_Test:test_legacy_succeeds() (gas: 14630) +OptimismMintableERC20_Test:test_mint_notBridge_reverts() (gas: 11212) +OptimismMintableERC20_Test:test_mint_succeeds() (gas: 63595) +OptimismMintableERC20_Test:test_remoteToken_succeeds() (gas: 7755) +OptimismMintableERC721Factory_Test:test_constructor_succeeds() (gas: 8424) +OptimismMintableERC721Factory_Test:test_createOptimismMintableERC721_sameTwice_reverts() (gas: 8937393460516800078) +OptimismMintableERC721Factory_Test:test_createOptimismMintableERC721_succeeds() (gas: 2316545) +OptimismMintableERC721Factory_Test:test_createOptimismMintableERC721_zeroRemoteToken_reverts() (gas: 9542) +OptimismMintableERC721_Test:test_burn_notBridge_reverts() (gas: 136967) +OptimismMintableERC721_Test:test_burn_succeeds() (gas: 118874) +OptimismMintableERC721_Test:test_constructor_succeeds() (gas: 24516) +OptimismMintableERC721_Test:test_safeMint_notBridge_reverts() (gas: 11209) +OptimismMintableERC721_Test:test_safeMint_succeeds() (gas: 140599) +OptimismMintableERC721_Test:test_supportsInterfaces_succeeds() (gas: 9050) +OptimismMintableERC721_Test:test_tokenURI_succeeds() (gas: 163605) +OptimismMintableTokenFactory_Test:test_bridge_succeeds() (gas: 9856) +OptimismMintableTokenFactory_Test:test_createStandardL2TokenWithDecimals_succeeds() (gas: 1142627) +OptimismMintableTokenFactory_Test:test_createStandardL2Token_remoteIsZero_reverts() (gas: 9621) +OptimismMintableTokenFactory_Test:test_createStandardL2Token_sameTwice_reverts() (gas: 8937393460516764416) +OptimismMintableTokenFactory_Test:test_createStandardL2Token_succeeds() (gas: 1142619) +OptimismPortalUpgradeable_Test:test_initialize_cannotInitImpl_reverts() (gas: 14615) +OptimismPortalUpgradeable_Test:test_initialize_cannotInitProxy_reverts() (gas: 16222) +OptimismPortalUpgradeable_Test:test_params_initValuesOnProxy_succeeds() (gas: 26667) +OptimismPortalUpgradeable_Test:test_upgradeToAndCall_upgrading_succeeds() (gas: 186084) +OptimismPortal_FinalizeWithdrawal_Test:test_finalizeWithdrawalTransaction_ifOutputRootChanges_reverts() (gas: 178756) +OptimismPortal_FinalizeWithdrawal_Test:test_finalizeWithdrawalTransaction_ifOutputTimestampIsNotFinalized_reverts() (gas: 182307) +OptimismPortal_FinalizeWithdrawal_Test:test_finalizeWithdrawalTransaction_ifWithdrawalNotProven_reverts() (gas: 41781) +OptimismPortal_FinalizeWithdrawal_Test:test_finalizeWithdrawalTransaction_ifWithdrawalProofNotOldEnough_reverts() (gas: 174020) +OptimismPortal_FinalizeWithdrawal_Test:test_finalizeWithdrawalTransaction_onInsufficientGas_reverts() (gas: 181245) +OptimismPortal_FinalizeWithdrawal_Test:test_finalizeWithdrawalTransaction_onRecentWithdrawal_reverts() (gas: 154807) +OptimismPortal_FinalizeWithdrawal_Test:test_finalizeWithdrawalTransaction_onReentrancy_reverts() (gas: 219301) +OptimismPortal_FinalizeWithdrawal_Test:test_finalizeWithdrawalTransaction_onReplay_reverts() (gas: 220984) +OptimismPortal_FinalizeWithdrawal_Test:test_finalizeWithdrawalTransaction_paused_reverts() (gas: 38773) +OptimismPortal_FinalizeWithdrawal_Test:test_finalizeWithdrawalTransaction_provenWithdrawalHash_succeeds() (gas: 209680) +OptimismPortal_FinalizeWithdrawal_Test:test_finalizeWithdrawalTransaction_targetFails_fails() (gas: 8797746687696162679) +OptimismPortal_FinalizeWithdrawal_Test:test_finalizeWithdrawalTransaction_timestampLessThanL2OracleStart_reverts() (gas: 171324) +OptimismPortal_FinalizeWithdrawal_Test:test_proveWithdrawalTransaction_onInvalidOutputRootProof_reverts() (gas: 85828) +OptimismPortal_FinalizeWithdrawal_Test:test_proveWithdrawalTransaction_onInvalidWithdrawalProof_reverts() (gas: 111318) +OptimismPortal_FinalizeWithdrawal_Test:test_proveWithdrawalTransaction_onSelfCall_reverts() (gas: 52993) +OptimismPortal_FinalizeWithdrawal_Test:test_proveWithdrawalTransaction_paused_reverts() (gas: 58914) +OptimismPortal_FinalizeWithdrawal_Test:test_proveWithdrawalTransaction_replayProveChangedOutputRootAndOutputIndex_succeeds() (gas: 297495) +OptimismPortal_FinalizeWithdrawal_Test:test_proveWithdrawalTransaction_replayProveChangedOutputRoot_succeeds() (gas: 227597) OptimismPortal_FinalizeWithdrawal_Test:test_proveWithdrawalTransaction_replayProve_reverts() (gas: 166699) -OptimismPortal_FinalizeWithdrawal_Test:test_proveWithdrawalTransaction_validWithdrawalProof_succeeds() (gas: 154430) -OptimismPortal_Test:test_constructor_succeeds() (gas: 28164) -OptimismPortal_Test:test_depositTransaction_contractCreation_reverts() (gas: 14292) -OptimismPortal_Test:test_depositTransaction_createWithZeroValueForContract_succeeds() (gas: 76814) -OptimismPortal_Test:test_depositTransaction_createWithZeroValueForEOA_succeeds() (gas: 77115) -OptimismPortal_Test:test_depositTransaction_largeData_reverts() (gas: 512149) -OptimismPortal_Test:test_depositTransaction_noValueContract_succeeds() (gas: 76767) -OptimismPortal_Test:test_depositTransaction_noValueEOA_succeeds() (gas: 77112) -OptimismPortal_Test:test_depositTransaction_smallGasLimit_reverts() (gas: 14528) -OptimismPortal_Test:test_depositTransaction_withEthValueAndContractContractCreation_succeeds() (gas: 83773) -OptimismPortal_Test:test_depositTransaction_withEthValueAndEOAContractCreation_succeeds() (gas: 75929) -OptimismPortal_Test:test_depositTransaction_withEthValueFromContract_succeeds() (gas: 83476) -OptimismPortal_Test:test_depositTransaction_withEthValueFromEOA_succeeds() (gas: 84069) -OptimismPortal_Test:test_isOutputFinalized_succeeds() (gas: 126749) -OptimismPortal_Test:test_minimumGasLimit_succeeds() (gas: 17430) +OptimismPortal_FinalizeWithdrawal_Test:test_proveWithdrawalTransaction_validWithdrawalProof_succeeds() (gas: 154431) +OptimismPortal_Test:test_constructor_succeeds() (gas: 33476) +OptimismPortal_Test:test_depositTransaction_contractCreation_reverts() (gas: 14294) +OptimismPortal_Test:test_depositTransaction_largeData_reverts() (gas: 512224) +OptimismPortal_Test:test_depositTransaction_smallGasLimit_reverts() (gas: 14550) +OptimismPortal_Test:test_isOutputFinalized_succeeds() (gas: 127639) +OptimismPortal_Test:test_minimumGasLimit_succeeds() (gas: 17643) OptimismPortal_Test:test_pause_onlyGuardian_reverts() (gas: 24487) -OptimismPortal_Test:test_pause_succeeds() (gas: 27344) -OptimismPortal_Test:test_receive_succeeds() (gas: 127564) -OptimismPortal_Test:test_simple_isOutputFinalized_succeeds() (gas: 35651) -OptimismPortal_Test:test_unpause_onlyGuardian_reverts() (gas: 31514) -OptimismPortal_Test:test_unpause_succeeds() (gas: 27451) -OptimistAllowlistTest:test_constructor_succeeds() (gas: 16407) -OptimistAllowlistTest:test_isAllowedToMint_fromAllowlistAttestorWithFalsyValue_fails() (gas: 49842) -OptimistAllowlistTest:test_isAllowedToMint_fromAllowlistAttestor_succeeds() (gas: 49304) -OptimistAllowlistTest:test_isAllowedToMint_fromCoinbaseQuestAttestorWithFalsyValue_fails() (gas: 49544) -OptimistAllowlistTest:test_isAllowedToMint_fromCoinbaseQuestAttestor_succeeds() (gas: 53534) -OptimistAllowlistTest:test_isAllowedToMint_fromInvite_succeeds() (gas: 235508) -OptimistAllowlistTest:test_isAllowedToMint_fromWrongAllowlistAttestor_fails() (gas: 58311) -OptimistAllowlistTest:test_isAllowedToMint_fromWrongCoinbaseQuestAttestor_fails() (gas: 58268) -OptimistAllowlistTest:test_isAllowedToMint_fromWrongOptimistInviter_fails() (gas: 57601) -OptimistAllowlistTest:test_isAllowedToMint_withMultipleAttestations_succeeds() (gas: 324909) -OptimistAllowlistTest:test_isAllowedToMint_withoutAnyAttestations_fails() (gas: 23210) -OptimistInviterTest:test_claimInvite_claimBeforeMinCommitmentPeriod_reverts() (gas: 142819) -OptimistInviterTest:test_claimInvite_claimForSomeoneElse_succeeds() (gas: 245467) -OptimistInviterTest:test_claimInvite_replayingUsedNonce_reverts() (gas: 288437) -OptimistInviterTest:test_claimInvite_succeeds() (gas: 241374) -OptimistInviterTest:test_claimInvite_usingERC1271Wallet_succeeds() (gas: 245742) -OptimistInviterTest:test_claimInvite_usingSignatureIssuedForDifferentChain_reverts() (gas: 156587) -OptimistInviterTest:test_claimInvite_usingSignatureIssuedForDifferentContract_reverts() (gas: 156478) -OptimistInviterTest:test_claimInvite_usingSignatureIssuedForDifferentVersion_reverts() (gas: 155102) -OptimistInviterTest:test_claimInvite_whenIssuerHasNoInvitesLeft_reverts() (gas: 562110) +OptimismPortal_Test:test_pause_succeeds() (gas: 27329) +OptimismPortal_Test:test_simple_isOutputFinalized_succeeds() (gas: 40883) +OptimismPortal_Test:test_unpause_onlyGuardian_reverts() (gas: 31580) +OptimismPortal_Test:test_unpause_succeeds() (gas: 27349) +OptimistAllowlistTest:test_constructor_succeeds() (gas: 16362) +OptimistAllowlistTest:test_isAllowedToMint_fromAllowlistAttestorWithFalsyValue_fails() (gas: 49652) +OptimistAllowlistTest:test_isAllowedToMint_fromAllowlistAttestor_succeeds() (gas: 49276) +OptimistAllowlistTest:test_isAllowedToMint_fromCoinbaseQuestAttestorWithFalsyValue_fails() (gas: 49347) +OptimistAllowlistTest:test_isAllowedToMint_fromCoinbaseQuestAttestor_succeeds() (gas: 53455) +OptimistAllowlistTest:test_isAllowedToMint_fromInvite_succeeds() (gas: 235314) +OptimistAllowlistTest:test_isAllowedToMint_fromWrongAllowlistAttestor_fails() (gas: 58119) +OptimistAllowlistTest:test_isAllowedToMint_fromWrongCoinbaseQuestAttestor_fails() (gas: 58098) +OptimistAllowlistTest:test_isAllowedToMint_fromWrongOptimistInviter_fails() (gas: 57409) +OptimistAllowlistTest:test_isAllowedToMint_withMultipleAttestations_succeeds() (gas: 324717) +OptimistAllowlistTest:test_isAllowedToMint_withoutAnyAttestations_fails() (gas: 23046) +OptimistInviterTest:test_claimInvite_claimBeforeMinCommitmentPeriod_reverts() (gas: 142794) +OptimistInviterTest:test_claimInvite_claimForSomeoneElse_succeeds() (gas: 245304) +OptimistInviterTest:test_claimInvite_replayingUsedNonce_reverts() (gas: 288334) +OptimistInviterTest:test_claimInvite_succeeds() (gas: 241271) +OptimistInviterTest:test_claimInvite_usingERC1271Wallet_succeeds() (gas: 245678) +OptimistInviterTest:test_claimInvite_usingSignatureIssuedForDifferentChain_reverts() (gas: 156562) +OptimistInviterTest:test_claimInvite_usingSignatureIssuedForDifferentContract_reverts() (gas: 156475) +OptimistInviterTest:test_claimInvite_usingSignatureIssuedForDifferentVersion_reverts() (gas: 155077) +OptimistInviterTest:test_claimInvite_whenIssuerHasNoInvitesLeft_reverts() (gas: 561851) OptimistInviterTest:test_claimInvite_whenIssuerNeverReceivedInvites_reverts() (gas: 110711) -OptimistInviterTest:test_claimInvite_withIncorrectSignature_reverts() (gas: 253095) -OptimistInviterTest:test_claimInvite_withoutCommittingHash_reverts() (gas: 119210) -OptimistInviterTest:test_commitInvite_committingForSomeoneElse_succeeds() (gas: 140584) -OptimistInviterTest:test_commitInvite_committingForYourself_succeeds() (gas: 138628) -OptimistInviterTest:test_commitInvite_committingSameHashTwice_reverts() (gas: 142056) -OptimistInviterTest:test_grantInvites_adminAddingInvites_succeeds() (gas: 190757) -OptimistInviterTest:test_grantInvites_nonAdminAddingInvites_reverts() (gas: 14026) -OptimistInviterTest:test_initialize_succeeds() (gas: 10573) +OptimistInviterTest:test_claimInvite_withIncorrectSignature_reverts() (gas: 253045) +OptimistInviterTest:test_claimInvite_withoutCommittingHash_reverts() (gas: 119185) +OptimistInviterTest:test_commitInvite_committingForSomeoneElse_succeeds() (gas: 140559) +OptimistInviterTest:test_commitInvite_committingForYourself_succeeds() (gas: 138625) +OptimistInviterTest:test_commitInvite_committingSameHashTwice_reverts() (gas: 142031) +OptimistInviterTest:test_grantInvites_adminAddingInvites_succeeds() (gas: 190670) +OptimistInviterTest:test_grantInvites_nonAdminAddingInvites_reverts() (gas: 14048) +OptimistInviterTest:test_initialize_succeeds() (gas: 10507) OptimistTest:test_approve_soulbound_reverts() (gas: 70487) -OptimistTest:test_baseURI_returnsCorrectBaseURI_succeeds() (gas: 124568) +OptimistTest:test_baseURI_returnsCorrectBaseURI_succeeds() (gas: 124566) OptimistTest:test_burn_byNonOwner_reverts() (gas: 73197) OptimistTest:test_burn_byOwner_succeeds() (gas: 54487) -OptimistTest:test_initialize_succeeds() (gas: 20840) -OptimistTest:test_mint_afterAllowlistAttestation_succeeds() (gas: 121465) -OptimistTest:test_mint_afterCoinbaseQuestAttestation_succeeds() (gas: 130362) -OptimistTest:test_mint_afterInviteClaimed_succeeds() (gas: 311331) -OptimistTest:test_mint_afterMultipleAttestations_succeeds() (gas: 377762) -OptimistTest:test_mint_forAlreadyMintedClaimer_reverts() (gas: 118023) -OptimistTest:test_mint_forNonAllowlistedClaimer_reverts() (gas: 29886) +OptimistTest:test_initialize_succeeds() (gas: 20862) +OptimistTest:test_mint_afterAllowlistAttestation_succeeds() (gas: 121365) +OptimistTest:test_mint_afterCoinbaseQuestAttestation_succeeds() (gas: 130109) +OptimistTest:test_mint_afterInviteClaimed_succeeds() (gas: 310811) +OptimistTest:test_mint_afterMultipleAttestations_succeeds() (gas: 377472) +OptimistTest:test_mint_forAlreadyMintedClaimer_reverts() (gas: 117923) +OptimistTest:test_mint_forNonAllowlistedClaimer_reverts() (gas: 29722) OptimistTest:test_mint_secondaryMinter_succeeds() (gas: 72711) -OptimistTest:test_multicall_batchingClaimAndMint_succeeds() (gas: 308376) +OptimistTest:test_multicall_batchingClaimAndMint_succeeds() (gas: 307999) OptimistTest:test_setApprovalForAll_soulbound_reverts() (gas: 74239) OptimistTest:test_supportsInterface_returnsCorrectInterfaceForERC721_succeeds() (gas: 5805) OptimistTest:test_tokenIdOfAddress_returnsOwnerID_succeeds() (gas: 63730) -OptimistTest:test_tokenURI_returnsCorrectTokenURI_succeeds() (gas: 195908) +OptimistTest:test_tokenURI_returnsCorrectTokenURI_succeeds() (gas: 195905) OptimistTest:test_transferFrom_soulbound_reverts() (gas: 75512) -PreimageOracle_Test:test_keccak256PreimageKey_succeeds() (gas: 319) -PreimageOracle_Test:test_loadKeccak256PreimagePart_outOfBoundsOffset_reverts() (gas: 8993) +PreimageOracle_Test:test_keccak256PreimageKey_succeeds() (gas: 342) +PreimageOracle_Test:test_loadKeccak256PreimagePart_outOfBoundsOffset_reverts() (gas: 8971) PreimageOracle_Test:test_loadKeccak256PreimagePart_succeeds() (gas: 76076) -PreimageOracle_Test:test_loadLocalData_onePart_succeeds() (gas: 75818) -PreimageOracle_Test:test_loadLocalData_outOfBoundsOffset_reverts() (gas: 8803) -ProtocolVersions_Initialize_Test:test_initialize_events_succeeds() (gas: 52181) -ProtocolVersions_Initialize_Test:test_initialize_values_succeeds() (gas: 32301) -ProtocolVersions_Setters_TestFail:test_setRecommended_notOwner_reverts() (gas: 15508) -ProtocolVersions_Setters_TestFail:test_setRequired_notOwner_reverts() (gas: 15520) -ProxyAdmin_Test:test_chugsplashChangeProxyAdmin_succeeds() (gas: 35586) -ProxyAdmin_Test:test_chugsplashGetProxyAdmin_succeeds() (gas: 15675) -ProxyAdmin_Test:test_chugsplashGetProxyImplementation_succeeds() (gas: 51084) -ProxyAdmin_Test:test_chugsplashUpgradeAndCall_succeeds() (gas: 82311) -ProxyAdmin_Test:test_chugsplashUpgrade_succeeds() (gas: 48988) +PreimageOracle_Test:test_loadLocalData_multipleContexts_succeeds() (gas: 147718) +PreimageOracle_Test:test_loadLocalData_onePart_succeeds() (gas: 75905) +PreimageOracle_Test:test_loadLocalData_outOfBoundsOffset_reverts() (gas: 8882) +ProtocolVersions_Initialize_Test:test_initialize_events_succeeds() (gas: 41623) +ProtocolVersions_Initialize_Test:test_initialize_values_succeeds() (gas: 45046) +ProtocolVersions_Setters_TestFail:test_setRecommended_notOwner_reverts() (gas: 15553) +ProtocolVersions_Setters_TestFail:test_setRequired_notOwner_reverts() (gas: 15587) +ProxyAdmin_Test:test_chugsplashChangeProxyAdmin_succeeds() (gas: 36440) +ProxyAdmin_Test:test_chugsplashGetProxyAdmin_succeeds() (gas: 15610) +ProxyAdmin_Test:test_chugsplashGetProxyImplementation_succeeds() (gas: 51040) +ProxyAdmin_Test:test_chugsplashUpgradeAndCall_succeeds() (gas: 82239) +ProxyAdmin_Test:test_chugsplashUpgrade_succeeds() (gas: 48965) ProxyAdmin_Test:test_delegateResolvedChangeProxyAdmin_succeeds() (gas: 33936) -ProxyAdmin_Test:test_delegateResolvedGetProxyAdmin_succeeds() (gas: 17691) +ProxyAdmin_Test:test_delegateResolvedGetProxyAdmin_succeeds() (gas: 17647) ProxyAdmin_Test:test_delegateResolvedGetProxyImplementation_succeeds() (gas: 62028) -ProxyAdmin_Test:test_delegateResolvedUpgradeAndCall_succeeds() (gas: 98039) +ProxyAdmin_Test:test_delegateResolvedUpgradeAndCall_succeeds() (gas: 98033) ProxyAdmin_Test:test_delegateResolvedUpgrade_succeeds() (gas: 58482) -ProxyAdmin_Test:test_erc1967ChangeProxyAdmin_succeeds() (gas: 33820) +ProxyAdmin_Test:test_erc1967ChangeProxyAdmin_succeeds() (gas: 34696) ProxyAdmin_Test:test_erc1967GetProxyAdmin_succeeds() (gas: 15616) ProxyAdmin_Test:test_erc1967GetProxyImplementation_succeeds() (gas: 52073) -ProxyAdmin_Test:test_erc1967UpgradeAndCall_succeeds() (gas: 78971) +ProxyAdmin_Test:test_erc1967UpgradeAndCall_succeeds() (gas: 78987) ProxyAdmin_Test:test_erc1967Upgrade_succeeds() (gas: 50080) -ProxyAdmin_Test:test_isUpgrading_succeeds() (gas: 19442) +ProxyAdmin_Test:test_isUpgrading_succeeds() (gas: 19497) ProxyAdmin_Test:test_onlyOwner_notOwner_reverts() (gas: 22767) ProxyAdmin_Test:test_owner_succeeds() (gas: 9738) ProxyAdmin_Test:test_proxyType_succeeds() (gas: 20533) -ProxyAdmin_Test:test_setAddressManager_notOwner_reverts() (gas: 10578) -ProxyAdmin_Test:test_setImplementationName_notOwner_reverts() (gas: 11111) -ProxyAdmin_Test:test_setImplementationName_succeeds() (gas: 38945) +ProxyAdmin_Test:test_setAddressManager_notOwner_reverts() (gas: 10600) +ProxyAdmin_Test:test_setImplementationName_notOwner_reverts() (gas: 11156) +ProxyAdmin_Test:test_setImplementationName_succeeds() (gas: 38967) ProxyAdmin_Test:test_setProxyType_notOwner_reverts() (gas: 10814) Proxy_Test:test_delegatesToImpl_succeeds() (gas: 45207) -Proxy_Test:test_implementationKey_succeeds() (gas: 20911) -Proxy_Test:test_implementation_isZeroAddress_reverts() (gas: 47628) +Proxy_Test:test_implementationKey_succeeds() (gas: 20933) +Proxy_Test:test_implementation_isZeroAddress_reverts() (gas: 47650) Proxy_Test:test_implementation_zeroAddressCaller_succeeds() (gas: 14752) Proxy_Test:test_ownerKey_succeeds() (gas: 19067) -Proxy_Test:test_ownerProxyCall_notAdmin_succeeds() (gas: 34623) +Proxy_Test:test_ownerProxyCall_notAdmin_succeeds() (gas: 35499) Proxy_Test:test_proxyCallToImp_notAdmin_succeeds() (gas: 30010) -Proxy_Test:test_upgradeToAndCall_functionDoesNotExist_reverts() (gas: 104567) +Proxy_Test:test_upgradeToAndCall_functionDoesNotExist_reverts() (gas: 107935) Proxy_Test:test_upgradeToAndCall_isPayable_succeeds() (gas: 53744) -Proxy_Test:test_upgradeToAndCall_succeeds() (gas: 125192) +Proxy_Test:test_upgradeToAndCall_succeeds() (gas: 125214) Proxy_Test:test_upgradeTo_clashingFunctionSignatures_succeeds() (gas: 101363) RLPReader_readBytes_Test:test_readBytes_bytestring00_succeeds() (gas: 1863) RLPReader_readBytes_Test:test_readBytes_bytestring01_succeeds() (gas: 1840) @@ -609,7 +625,7 @@ RLPReader_readList_Test:test_readList_notEnoughContentForString2_reverts() (gas: RLPReader_readList_Test:test_readList_notLongEnough_reverts() (gas: 3955) RLPReader_readList_Test:test_readList_shortListMax1_succeeds() (gas: 39602) RLPWriter_writeList_Test:test_writeList_dictTest1_succeeds() (gas: 36979) -RLPWriter_writeList_Test:test_writeList_empty_succeeds() (gas: 1711) +RLPWriter_writeList_Test:test_writeList_empty_succeeds() (gas: 1689) RLPWriter_writeList_Test:test_writeList_listoflists2_succeeds() (gas: 16566) RLPWriter_writeList_Test:test_writeList_listoflists_succeeds() (gas: 10841) RLPWriter_writeList_Test:test_writeList_longlist1_succeeds() (gas: 40383) @@ -617,10 +633,10 @@ RLPWriter_writeList_Test:test_writeList_longlist2_succeeds() (gas: 280754) RLPWriter_writeList_Test:test_writeList_multiList_succeeds() (gas: 22446) RLPWriter_writeList_Test:test_writeList_shortListMax1_succeeds() (gas: 36793) RLPWriter_writeList_Test:test_writeList_stringList_succeeds() (gas: 10697) -RLPWriter_writeString_Test:test_writeString_bytestring00_succeeds() (gas: 951) +RLPWriter_writeString_Test:test_writeString_bytestring00_succeeds() (gas: 929) RLPWriter_writeString_Test:test_writeString_bytestring01_succeeds() (gas: 951) RLPWriter_writeString_Test:test_writeString_bytestring7f_succeeds() (gas: 972) -RLPWriter_writeString_Test:test_writeString_empty_succeeds() (gas: 1633) +RLPWriter_writeString_Test:test_writeString_empty_succeeds() (gas: 1611) RLPWriter_writeString_Test:test_writeString_longstring2_succeeds() (gas: 258768) RLPWriter_writeString_Test:test_writeString_longstring_succeeds() (gas: 16961) RLPWriter_writeString_Test:test_writeString_shortstring2_succeeds() (gas: 15376) @@ -633,8 +649,8 @@ RLPWriter_writeUint_Test:test_writeUint_smallint3_succeeds() (gas: 7271) RLPWriter_writeUint_Test:test_writeUint_smallint4_succeeds() (gas: 7272) RLPWriter_writeUint_Test:test_writeUint_smallint_succeeds() (gas: 7250) RLPWriter_writeUint_Test:test_writeUint_zero_succeeds() (gas: 7734) -ResolvedDelegateProxy_Test:test_fallback_addressManagerNotSet_reverts() (gas: 605906) -ResolvedDelegateProxy_Test:test_fallback_delegateCallBar_reverts() (gas: 24783) +ResolvedDelegateProxy_Test:test_fallback_addressManagerNotSet_reverts() (gas: 605928) +ResolvedDelegateProxy_Test:test_fallback_delegateCallBar_reverts() (gas: 24805) ResourceMetering_Test:test_meter_denominatorEq1_reverts() (gas: 20024064) ResourceMetering_Test:test_meter_initialResourceParams_succeeds() (gas: 12423) ResourceMetering_Test:test_meter_updateNoGasDelta_succeeds() (gas: 2011591) @@ -644,41 +660,39 @@ ResourceMetering_Test:test_meter_updateTenEmptyBlocks_succeeds() (gas: 23747) ResourceMetering_Test:test_meter_updateTwoEmptyBlocks_succeeds() (gas: 23703) ResourceMetering_Test:test_meter_useMax_succeeds() (gas: 20020816) ResourceMetering_Test:test_meter_useMoreThanMax_reverts() (gas: 19549) -SafeCall_Test:test_callWithMinGas_noLeakageHigh_succeeds() (gas: 1021670598) -SafeCall_Test:test_callWithMinGas_noLeakageLow_succeeds() (gas: 1095190710) -Semver_Test:test_behindProxy_succeeds() (gas: 507558) -Semver_Test:test_version_succeeds() (gas: 9418) -SequencerFeeVault_L2Withdrawal_Test:test_withdraw_toL2_succeeds() (gas: 78333) -SequencerFeeVault_L2Withdrawal_Test:test_withdraw_toL2recipientReverts_fails() (gas: 46486) -SequencerFeeVault_Test:test_constructor_succeeds() (gas: 5526) -SequencerFeeVault_Test:test_minWithdrawalAmount_succeeds() (gas: 5464) -SequencerFeeVault_Test:test_receive_succeeds() (gas: 17373) -SequencerFeeVault_Test:test_withdraw_notEnough_reverts() (gas: 9332) -SequencerFeeVault_Test:test_withdraw_toL1_succeeds() (gas: 171675) -SetPrevBaseFee_Test:test_setPrevBaseFee_succeeds() (gas: 11549) -StandardBridge_Stateless_Test:test_isCorrectTokenPair_succeeds() (gas: 49936) -StandardBridge_Stateless_Test:test_isOptimismMintableERC20_succeeds() (gas: 33072) -Storage_Roundtrip_Test:test_setGetAddress_succeeds(bytes32,address) (runs: 64, μ: 31199, ~: 31821) -Storage_Roundtrip_Test:test_setGetBytes32_succeeds(bytes32,bytes32) (runs: 64, μ: 31598, ~: 31598) -Storage_Roundtrip_Test:test_setGetUint_succeeds(bytes32,uint256) (runs: 64, μ: 31042, ~: 31664) -SystemConfig_Initialize_Test:test_initialize_events_succeeds() (gas: 71972) -SystemConfig_Initialize_Test:test_initialize_startBlockNoop_reverts() (gas: 81247) -SystemConfig_Initialize_Test:test_initialize_startBlockOverride_succeeds() (gas: 65143) -SystemConfig_Initialize_Test:test_initialize_values_succeeds() (gas: 64968) -SystemConfig_Initialize_TestFail:test_initialize_lowGasLimit_reverts() (gas: 55589) -SystemConfig_Setters_TestFail:test_setBatcherHash_notOwner_reverts() (gas: 15607) -SystemConfig_Setters_TestFail:test_setGasConfig_notOwner_reverts() (gas: 15577) -SystemConfig_Setters_TestFail:test_setGasLimit_notOwner_reverts() (gas: 15676) -SystemConfig_Setters_TestFail:test_setResourceConfig_badMinMax_reverts() (gas: 18541) -SystemConfig_Setters_TestFail:test_setResourceConfig_badPrecision_reverts() (gas: 21142) -SystemConfig_Setters_TestFail:test_setResourceConfig_lowGasLimit_reverts() (gas: 22146) -SystemConfig_Setters_TestFail:test_setResourceConfig_notOwner_reverts() (gas: 16799) -SystemConfig_Setters_TestFail:test_setResourceConfig_zeroDenominator_reverts() (gas: 18578) -SystemConfig_Setters_TestFail:test_setUnsafeBlockSigner_notOwner_reverts() (gas: 15590) -TransactorTest:test_call_succeeds() (gas: 26709) -TransactorTest:test_call_unauthorized_reverts() (gas: 16543) -TransactorTest:test_constructor_succeeds() (gas: 9739) -TransactorTest:test_delegateCall_succeeds() (gas: 20909) -TransactorTest:test_delegateCall_unauthorized_reverts() (gas: 16550) -TransferOnionTest:test_constructor_succeeds() (gas: 564855) +SafeCall_Test:test_callWithMinGas_noLeakageHigh_succeeds() (gas: 1020805932) +SafeCall_Test:test_callWithMinGas_noLeakageLow_succeeds() (gas: 1094905711) +SequencerFeeVault_L2Withdrawal_Test:test_withdraw_toL2_succeeds() (gas: 80640) +SequencerFeeVault_L2Withdrawal_Test:test_withdraw_toL2recipientReverts_fails() (gas: 48948) +SequencerFeeVault_Test:test_constructor_succeeds() (gas: 7705) +SequencerFeeVault_Test:test_minWithdrawalAmount_succeeds() (gas: 12794) +SequencerFeeVault_Test:test_receive_succeeds() (gas: 17395) +SequencerFeeVault_Test:test_withdraw_notEnough_reverts() (gas: 9399) +SequencerFeeVault_Test:test_withdraw_toL1_succeeds() (gas: 618343) +SetPrevBaseFee_Test:test_setPrevBaseFee_succeeds() (gas: 11595) +StandardBridge_Stateless_Test:test_isCorrectTokenPair_succeeds() (gas: 50149) +StandardBridge_Stateless_Test:test_isOptimismMintableERC20_succeeds() (gas: 33142) +Storage_Roundtrip_Test:test_setGetAddress_succeeds(bytes32,address) (runs: 64, μ: 31221, ~: 31843) +Storage_Roundtrip_Test:test_setGetBytes32_succeeds(bytes32,bytes32) (runs: 64, μ: 31654, ~: 31654) +Storage_Roundtrip_Test:test_setGetUint_succeeds(bytes32,uint256) (runs: 64, μ: 30731, ~: 31664) +SystemConfig_Initialize_Test:test_initialize_events_succeeds() (gas: 88186) +SystemConfig_Initialize_Test:test_initialize_startBlockNoop_reverts() (gas: 77216) +SystemConfig_Initialize_Test:test_initialize_startBlockOverride_succeeds() (gas: 81116) +SystemConfig_Initialize_Test:test_initialize_values_succeeds() (gas: 88546) +SystemConfig_Initialize_TestFail:test_initialize_lowGasLimit_reverts() (gas: 59900) +SystemConfig_Setters_TestFail:test_setBatcherHash_notOwner_reverts() (gas: 15675) +SystemConfig_Setters_TestFail:test_setGasConfig_notOwner_reverts() (gas: 15644) +SystemConfig_Setters_TestFail:test_setGasLimit_notOwner_reverts() (gas: 15743) +SystemConfig_Setters_TestFail:test_setResourceConfig_badMinMax_reverts() (gas: 18592) +SystemConfig_Setters_TestFail:test_setResourceConfig_badPrecision_reverts() (gas: 21216) +SystemConfig_Setters_TestFail:test_setResourceConfig_lowGasLimit_reverts() (gas: 22264) +SystemConfig_Setters_TestFail:test_setResourceConfig_notOwner_reverts() (gas: 16867) +SystemConfig_Setters_TestFail:test_setResourceConfig_zeroDenominator_reverts() (gas: 18629) +SystemConfig_Setters_TestFail:test_setUnsafeBlockSigner_notOwner_reverts() (gas: 15658) +TransactorTest:test_call_succeeds() (gas: 26754) +TransactorTest:test_call_unauthorized_reverts() (gas: 18139) +TransactorTest:test_constructor_succeeds() (gas: 9673) +TransactorTest:test_delegateCall_succeeds() (gas: 20931) +TransactorTest:test_delegateCall_unauthorized_reverts() (gas: 18124) +TransferOnionTest:test_constructor_succeeds() (gas: 564789) TransferOnionTest:test_unwrap_succeeds() (gas: 724955) \ No newline at end of file diff --git a/packages/contracts-bedrock/.gitignore b/packages/contracts-bedrock/.gitignore index d82f192d9f55d..182e7983b2a13 100644 --- a/packages/contracts-bedrock/.gitignore +++ b/packages/contracts-bedrock/.gitignore @@ -9,11 +9,8 @@ typechain coverage.out .resource-metering.csv -# Tests -test-case-generator/fuzz - # Scripts -scripts/differential-testing/differential-testing +scripts/go-ffi/go-ffi # Environment Variables .envrc @@ -29,3 +26,6 @@ deployments/1337 # Devnet config which changes with each 'make devnet-up' deploy-config/devnetL1.json + +# Getting Started guide deploy config +deploy-config/getting-started.json diff --git a/packages/contracts-bedrock/README.md b/packages/contracts-bedrock/README.md index 0178142c147fd..fd33f581433a7 100644 --- a/packages/contracts-bedrock/README.md +++ b/packages/contracts-bedrock/README.md @@ -15,7 +15,7 @@ A style guide we follow for writing contracts can be found [here](./STYLE_GUIDE. | Name | Proxy Type | Description | | ---------------------------------------------------------------------------------------- | ----------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------- | | [`L1CrossDomainMessenger`](../../specs/messengers.md) | [`ResolvedDelegateProxy`](./contracts/legacy/ResolvedDelegateProxy.sol) | High-level interface for sending messages to and receiving messages from Optimism | -| [`L1StandardBridge`](../../specs/bridges.md) | [`L1ChugSplashProxy`](./contracts/legacy/L1ChugSplashProxy.sol) | Standardized system for transfering ERC20 tokens to/from Optimism | +| [`L1StandardBridge`](../../specs/bridges.md) | [`L1ChugSplashProxy`](./contracts/legacy/L1ChugSplashProxy.sol) | Standardized system for transferring ERC20 tokens to/from Optimism | | [`L2OutputOracle`](../../specs/proposals.md#l2-output-oracle-smart-contract) | [`Proxy`](./contracts/universal/Proxy.sol) | Stores commitments to the state of Optimism which can be used by contracts on L1 to access L2 state | | [`OptimismPortal`](../../specs/deposits.md#deposit-contract) | [`Proxy`](./contracts/universal/Proxy.sol) | Low-level message passing interface | | [`OptimismMintableERC20Factory`](../../specs/predeploys.md#optimismmintableerc20factory) | [`Proxy`](./contracts/universal/Proxy.sol) | Deploys standard `OptimismMintableERC20` tokens that are compatible with either `StandardBridge` | diff --git a/packages/contracts-bedrock/STYLE_GUIDE.md b/packages/contracts-bedrock/STYLE_GUIDE.md index 1bc6a28447dfd..f8584b188ec0a 100644 --- a/packages/contracts-bedrock/STYLE_GUIDE.md +++ b/packages/contracts-bedrock/STYLE_GUIDE.md @@ -21,9 +21,10 @@ with additional rules. These are: We also have the following custom tags: - `@custom:proxied`: Add to a contract whenever it's meant to live behind a proxy. -- `@custom:upgradeable`: Add to a contract whenever it's meant to be used in an upgradeable contract. -- `@custom:semver`: Add to a constructor to indicate the version of a contract. +- `@custom:upgradeable`: Add to a contract whenever it's meant to be inherited by an upgradeable contract. +- `@custom:semver`: Add to `version` variable which indicate the contracts semver. - `@custom:legacy`: Add to an event or function when it only exists for legacy support. +- `@custom:network-specific`: Add to state variables which vary between OP Chains. #### Errors @@ -45,6 +46,18 @@ We also have the following custom tags: - Event parameters should NOT be prefixed with an underscore. +#### Immutable variables + +Immutable variables: + +- should be in `SCREAMING_SNAKE_CASE` +- should be `internal` +- should have a hand written getter function + +This approach clearly indicates to the developer that the value is immutable, without exposing +the non-standard casing to the interface. It also ensure that we don’t need to break the ABIs if +we switch between values being in storage and immutable. + #### Spacers We use spacer variables to account for old storage slots that are no longer being used. @@ -118,7 +131,7 @@ _Note: This is a work in progress, not all test files are compliant with these g Test function names are split by underscores, into 3 or 4 parts. An example function name is `test_onlyOwner_callerIsNotOwner_reverts()`. -The parts are: `[method]_[FunctionName]_[reason]_[success]`, where: +The parts are: `[method]_[FunctionName]_[reason]_[status]`, where: - `[method]` is either `test`, `testFuzz`, or `testDiff` - `[FunctionName]` is the name of the function or higher level behavior being tested. diff --git a/packages/contracts-bedrock/deploy-config/devnetL1-template.json b/packages/contracts-bedrock/deploy-config/devnetL1-template.json index 10badc81e0df9..46b8f146b4937 100644 --- a/packages/contracts-bedrock/deploy-config/devnetL1-template.json +++ b/packages/contracts-bedrock/deploy-config/devnetL1-template.json @@ -11,7 +11,7 @@ "cliqueSignerAddress": "0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266", "l1UseClique": true, "l1StartingBlockTag": "earliest", - "l2OutputOracleSubmissionInterval": 6, + "l2OutputOracleSubmissionInterval": 10, "l2OutputOracleStartingTimestamp": 0, "l2OutputOracleStartingBlockNumber": 0, "l2OutputOracleProposer": "0x70997970C51812dc3A010C7d01b50e0d17dc79C8", @@ -40,10 +40,12 @@ "governanceTokenName": "Optimism", "governanceTokenOwner": "0xa0Ee7A142d267C1f36714E4a8F75612F20a79720", "eip1559Denominator": 50, + "eip1559DenominatorCanyon": 250, "eip1559Elasticity": 6, "l1GenesisBlockTimestamp": "0x64c811bf", "l2GenesisRegolithTimeOffset": "0x0", "l2GenesisSpanBatchTimeOffset": "0x0", + "l2GenesisCanyonTimeOffset": "0x40", "faultGameAbsolutePrestate": "0x03c7ae758795765c6664a5d39bf63841c71ff191e9189522bad8ebff5d4eca98", "faultGameMaxDepth": 30, "faultGameMaxDuration": 1200, diff --git a/packages/contracts-bedrock/deploy-config/getting-started.json b/packages/contracts-bedrock/deploy-config/getting-started.json deleted file mode 100644 index 1757c3d049fac..0000000000000 --- a/packages/contracts-bedrock/deploy-config/getting-started.json +++ /dev/null @@ -1,60 +0,0 @@ -{ - "finalSystemOwner": "ADMIN", - "portalGuardian": "ADMIN", - - "l1StartingBlockTag": "BLOCKHASH", - - "l1ChainID": 5, - "l2ChainID": 42069, - "l2BlockTime": 2, - "l1BlockTime": 12, - - "maxSequencerDrift": 600, - "sequencerWindowSize": 3600, - "channelTimeout": 300, - - "p2pSequencerAddress": "SEQUENCER", - "batchInboxAddress": "0xff00000000000000000000000000000000042069", - "batchSenderAddress": "BATCHER", - - "l2OutputOracleSubmissionInterval": 120, - "l2OutputOracleStartingBlockNumber": 0, - "l2OutputOracleStartingTimestamp": TIMESTAMP, - - "l2OutputOracleProposer": "PROPOSER", - "l2OutputOracleChallenger": "ADMIN", - - "finalizationPeriodSeconds": 12, - - "proxyAdminOwner": "ADMIN", - "baseFeeVaultRecipient": "ADMIN", - "l1FeeVaultRecipient": "ADMIN", - "sequencerFeeVaultRecipient": "ADMIN", - - "baseFeeVaultMinimumWithdrawalAmount": "0x8ac7230489e80000", - "l1FeeVaultMinimumWithdrawalAmount": "0x8ac7230489e80000", - "sequencerFeeVaultMinimumWithdrawalAmount": "0x8ac7230489e80000", - "baseFeeVaultWithdrawalNetwork": 0, - "l1FeeVaultWithdrawalNetwork": 0, - "sequencerFeeVaultWithdrawalNetwork": 0, - - "gasPriceOracleOverhead": 2100, - "gasPriceOracleScalar": 1000000, - - "enableGovernance": true, - "governanceTokenSymbol": "OP", - "governanceTokenName": "Optimism", - "governanceTokenOwner": "ADMIN", - - "l2GenesisBlockGasLimit": "0x1c9c380", - "l2GenesisBlockBaseFeePerGas": "0x3b9aca00", - "l2GenesisRegolithTimeOffset": "0x0", - - "eip1559Denominator": 50, - "eip1559Elasticity": 10, - - "systemConfigStartBlock": 0, - - "requiredProtocolVersion": "0x0000000000000000000000000000000000000000000000000000000000000000", - "recommendedProtocolVersion": "0x0000000000000000000000000000000000000000000000000000000000000000" -} diff --git a/packages/contracts-bedrock/deploy-config/goerli.json b/packages/contracts-bedrock/deploy-config/goerli.json index 1fa80b8c75ad8..a724c1b7dd31c 100644 --- a/packages/contracts-bedrock/deploy-config/goerli.json +++ b/packages/contracts-bedrock/deploy-config/goerli.json @@ -37,8 +37,9 @@ "l2GenesisBlockGasLimit": "0x2faf080", "l2GenesisBlockBaseFeePerGas": "0x3b9aca00", "eip1559Denominator": 50, + "eip1559DenominatorCanyon": 250, "eip1559Elasticity": 10, "systemConfigStartBlock": 8300214, - "requiredProtocolVersion": "0x0000000000000000000000000000000000000000000000000000000000000000", - "recommendedProtocolVersion": "0x0000000000000000000000000000000000000000000000000000000000000000" + "requiredProtocolVersion": "0x0000000000000000000000000000000000000003000000010000000000000000", + "recommendedProtocolVersion": "0x0000000000000000000000000000000000000003000000010000000000000000" } diff --git a/packages/contracts-bedrock/deploy-config/hardhat.json b/packages/contracts-bedrock/deploy-config/hardhat.json index d52ffe5b01e51..79ebd620d1d8b 100644 --- a/packages/contracts-bedrock/deploy-config/hardhat.json +++ b/packages/contracts-bedrock/deploy-config/hardhat.json @@ -5,8 +5,8 @@ "l1StartingBlockTag": "earliest", "l1ChainID": 900, "l2ChainID": 901, - "l2BlockTime": 1, - "l1BlockTime": 2, + "l2BlockTime": 2, + "l1BlockTime": 12, "maxSequencerDrift": 300, "sequencerWindowSize": 15, "channelTimeout": 40, @@ -14,8 +14,8 @@ "batchInboxAddress": "0xff00000000000000000000000000000000000000", "batchSenderAddress": "0x3C44CdDdB6a900fa2b585dd299e03d12FA4293BC", "l2OutputOracleSubmissionInterval": 6, - "l2OutputOracleStartingTimestamp": 0, - "l2OutputOracleStartingBlockNumber": 0, + "l2OutputOracleStartingTimestamp": 1, + "l2OutputOracleStartingBlockNumber": 1, "gasPriceOracleOverhead": 2100, "gasPriceOracleScalar": 1000000, "l2OutputOracleProposer": "0x70997970C51812dc3A010C7d01b50e0d17dc79C8", @@ -35,9 +35,12 @@ "governanceTokenName": "Optimism", "governanceTokenSymbol": "OP", "governanceTokenOwner": "0x9965507D1a55bcC2695C58ba16FB37d819B0A4dc", - "finalizationPeriodSeconds": 2, + "finalizationPeriodSeconds": 36, "eip1559Denominator": 50, + "eip1559DenominatorCanyon": 250, "eip1559Elasticity": 10, "l2GenesisRegolithTimeOffset": "0x0", - "systemConfigStartBlock": 0 + "systemConfigStartBlock": 0, + "requiredProtocolVersion": "0x0000000000000000000000000000000000000000000000000000000000000000", + "recommendedProtocolVersion": "0x0000000000000000000000000000000000000000000000000000000000000000" } diff --git a/packages/contracts-bedrock/deploy-config/mainnet.json b/packages/contracts-bedrock/deploy-config/mainnet.json index c211a17ce8883..5f956d6326202 100644 --- a/packages/contracts-bedrock/deploy-config/mainnet.json +++ b/packages/contracts-bedrock/deploy-config/mainnet.json @@ -39,5 +39,7 @@ "eip1559Denominator": 50, "eip1559Elasticity": 6, "l2GenesisRegolithTimeOffset": "0x0", - "systemConfigStartBlock": 17422444 + "systemConfigStartBlock": 17422444, + "requiredProtocolVersion": "0x0000000000000000000000000000000000000003000000010000000000000000", + "recommendedProtocolVersion": "0x0000000000000000000000000000000000000003000000010000000000000000" } diff --git a/packages/contracts-bedrock/deploy-config/sepolia.json b/packages/contracts-bedrock/deploy-config/sepolia.json index ce2014d3a01c1..642b167af9d8e 100644 --- a/packages/contracts-bedrock/deploy-config/sepolia.json +++ b/packages/contracts-bedrock/deploy-config/sepolia.json @@ -40,6 +40,6 @@ "eip1559Elasticity": 6, "l2GenesisRegolithTimeOffset": "0x0", "systemConfigStartBlock": 0, - "requiredProtocolVersion": "0x0000000000000000000000000000000000000000000000000000000000000000", - "recommendedProtocolVersion": "0x0000000000000000000000000000000000000000000000000000000000000000" + "requiredProtocolVersion": "0x0000000000000000000000000000000000000003000000010000000000000001", + "recommendedProtocolVersion": "0x0000000000000000000000000000000000000003000000010000000000000001" } diff --git a/packages/contracts-bedrock/deployments/4460/.chainId b/packages/contracts-bedrock/deployments/4460/.chainId new file mode 100644 index 0000000000000..361dd3a2f486c --- /dev/null +++ b/packages/contracts-bedrock/deployments/4460/.chainId @@ -0,0 +1 @@ +4460 \ No newline at end of file diff --git a/packages/contracts-bedrock/deployments/58008/.chainId b/packages/contracts-bedrock/deployments/58008/.chainId new file mode 100644 index 0000000000000..df498f3fb9d47 --- /dev/null +++ b/packages/contracts-bedrock/deployments/58008/.chainId @@ -0,0 +1 @@ +58008 \ No newline at end of file diff --git a/packages/contracts-bedrock/deployments/84532/.chainId b/packages/contracts-bedrock/deployments/84532/.chainId new file mode 100644 index 0000000000000..667f99daf6e68 --- /dev/null +++ b/packages/contracts-bedrock/deployments/84532/.chainId @@ -0,0 +1 @@ +84532 \ No newline at end of file diff --git a/packages/contracts-bedrock/deployments/919/.chainId b/packages/contracts-bedrock/deployments/919/.chainId new file mode 100644 index 0000000000000..8cef75946fe36 --- /dev/null +++ b/packages/contracts-bedrock/deployments/919/.chainId @@ -0,0 +1 @@ +919 \ No newline at end of file diff --git a/packages/contracts-bedrock/deployments/999999999/.chainId b/packages/contracts-bedrock/deployments/999999999/.chainId new file mode 100644 index 0000000000000..d2caa99e08071 --- /dev/null +++ b/packages/contracts-bedrock/deployments/999999999/.chainId @@ -0,0 +1 @@ +999999999 \ No newline at end of file diff --git a/packages/contracts-bedrock/deployments/mainnet/ProtocolVersions.json b/packages/contracts-bedrock/deployments/mainnet/ProtocolVersions.json new file mode 100644 index 0000000000000..ed490ec191c08 --- /dev/null +++ b/packages/contracts-bedrock/deployments/mainnet/ProtocolVersions.json @@ -0,0 +1,496 @@ +{ + "abi": [ + { + "inputs": [], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "uint256", + "name": "version", + "type": "uint256" + }, + { + "indexed": true, + "internalType": "enum ProtocolVersions.UpdateType", + "name": "updateType", + "type": "uint8" + }, + { + "indexed": false, + "internalType": "bytes", + "name": "data", + "type": "bytes" + } + ], + "name": "ConfigUpdate", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint8", + "name": "version", + "type": "uint8" + } + ], + "name": "Initialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "inputs": [], + "name": "RECOMMENDED_SLOT", + "outputs": [ + { + "internalType": "bytes32", + "name": "", + "type": "bytes32" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "REQUIRED_SLOT", + "outputs": [ + { + "internalType": "bytes32", + "name": "", + "type": "bytes32" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "VERSION", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "_owner", + "type": "address" + }, + { + "internalType": "ProtocolVersion", + "name": "_required", + "type": "uint256" + }, + { + "internalType": "ProtocolVersion", + "name": "_recommended", + "type": "uint256" + } + ], + "name": "initialize", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "owner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "recommended", + "outputs": [ + { + "internalType": "ProtocolVersion", + "name": "out_", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "required", + "outputs": [ + { + "internalType": "ProtocolVersion", + "name": "out_", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "ProtocolVersion", + "name": "_recommended", + "type": "uint256" + } + ], + "name": "setRecommended", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "ProtocolVersion", + "name": "_required", + "type": "uint256" + } + ], + "name": "setRequired", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "version", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + } + ], + "address": "0x42F0bD8313ad456A38061308857b2383fe2c72a0", + "args": [], + "bytecode": "0x60806040523480156200001157600080fd5b506200002261dead60008062000028565b620004c9565b600054600390610100900460ff161580156200004b575060005460ff8083169116105b620000b45760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084015b60405180910390fd5b6000805461ffff191660ff831617610100179055620000d26200013a565b620000dd84620001a2565b620000e88362000221565b620000f382620002d1565b6000805461ff001916905560405160ff821681527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a150505050565b600054610100900460ff16620001965760405162461bcd60e51b815260206004820152602b602482015260008051602062000e9683398151915260448201526a6e697469616c697a696e6760a81b6064820152608401620000ab565b620001a062000332565b565b620001ac62000399565b6001600160a01b038116620002135760405162461bcd60e51b815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201526564647265737360d01b6064820152608401620000ab565b6200021e81620003f5565b50565b620002676200025260017f4aaefe95bd84fd3f32700cf3b7566bc944b73138e41958b5785826df2aecace16200044b565b60001b826200044760201b620004f51760201c565b6000816040516020016200027d91815260200190565b60408051601f19818403018152919052905060005b60007f1d2b0bda21d56b8bd12d4f94ebacffdfb35f5e226f84b461103bb8beab6353be83604051620002c5919062000471565b60405180910390a35050565b620003026200025260017fe314dfc40f0025322aacc0ba8ef420b62fb3b702cf01e0cdf3d829117ac2ff1b6200044b565b6000816040516020016200031891815260200190565b60408051601f198184030181529190529050600162000292565b600054610100900460ff166200038e5760405162461bcd60e51b815260206004820152602b602482015260008051602062000e9683398151915260448201526a6e697469616c697a696e6760a81b6064820152608401620000ab565b620001a033620003f5565b6033546001600160a01b03163314620001a05760405162461bcd60e51b815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e65726044820152606401620000ab565b603380546001600160a01b038381166001600160a01b0319831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b9055565b6000828210156200046c57634e487b7160e01b600052601160045260246000fd5b500390565b600060208083528351808285015260005b81811015620004a05785810183015185820160400152820162000482565b81811115620004b3576000604083870101525b50601f01601f1916929092016040019392505050565b6109bd80620004d96000396000f3fe608060405234801561001057600080fd5b50600436106100d45760003560e01c80638da5cb5b11610081578063f2fde38b1161005b578063f2fde38b146101b8578063f7d12760146101cb578063ffa1ad74146101d357600080fd5b80638da5cb5b14610180578063d798b1ac146101a8578063dc8452cd146101b057600080fd5b80635fd579af116100b25780635fd579af14610152578063715018a6146101655780637a1ac61e1461016d57600080fd5b80630457d6f2146100d9578063206a8300146100ee57806354fd4d5014610109575b600080fd5b6100ec6100e736600461085d565b6101db565b005b6100f66101ef565b6040519081526020015b60405180910390f35b6101456040518060400160405280600581526020017f312e302e3000000000000000000000000000000000000000000000000000000081525081565b60405161010091906108e1565b6100ec61016036600461085d565b61021d565b6100ec61022e565b6100ec61017b366004610924565b610242565b60335460405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610100565b6100f66103ad565b6100f66103e6565b6100ec6101c6366004610957565b610416565b6100f66104ca565b6100f6600081565b6101e36104f9565b6101ec8161057a565b50565b61021a60017f4aaefe95bd84fd3f32700cf3b7566bc944b73138e41958b5785826df2aecace1610972565b81565b6102256104f9565b6101ec81610632565b6102366104f9565b61024060006106ac565b565b600054600390610100900460ff16158015610264575060005460ff8083169116105b6102f5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a656400000000000000000000000000000000000060648201526084015b60405180910390fd5b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001660ff83161761010017905561032e610723565b61033784610416565b6103408361057a565b61034982610632565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff16905560405160ff821681527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a150505050565b60006103e16103dd60017fe314dfc40f0025322aacc0ba8ef420b62fb3b702cf01e0cdf3d829117ac2ff1b610972565b5490565b905090565b60006103e16103dd60017f4aaefe95bd84fd3f32700cf3b7566bc944b73138e41958b5785826df2aecace1610972565b61041e6104f9565b73ffffffffffffffffffffffffffffffffffffffff81166104c1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f646472657373000000000000000000000000000000000000000000000000000060648201526084016102ec565b6101ec816106ac565b61021a60017fe314dfc40f0025322aacc0ba8ef420b62fb3b702cf01e0cdf3d829117ac2ff1b610972565b9055565b60335473ffffffffffffffffffffffffffffffffffffffff163314610240576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016102ec565b6105ad6105a860017f4aaefe95bd84fd3f32700cf3b7566bc944b73138e41958b5785826df2aecace1610972565b829055565b6000816040516020016105c291815260200190565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152919052905060005b60007f1d2b0bda21d56b8bd12d4f94ebacffdfb35f5e226f84b461103bb8beab6353be8360405161062691906108e1565b60405180910390a35050565b6106606105a860017fe314dfc40f0025322aacc0ba8ef420b62fb3b702cf01e0cdf3d829117ac2ff1b610972565b60008160405160200161067591815260200190565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152919052905060016105f5565b6033805473ffffffffffffffffffffffffffffffffffffffff8381167fffffffffffffffffffffffff0000000000000000000000000000000000000000831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b600054610100900460ff166107ba576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e6700000000000000000000000000000000000000000060648201526084016102ec565b610240600054610100900460ff16610854576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e6700000000000000000000000000000000000000000060648201526084016102ec565b610240336106ac565b60006020828403121561086f57600080fd5b5035919050565b6000815180845260005b8181101561089c57602081850181015186830182015201610880565b818111156108ae576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b6020815260006108f46020830184610876565b9392505050565b803573ffffffffffffffffffffffffffffffffffffffff8116811461091f57600080fd5b919050565b60008060006060848603121561093957600080fd5b610942846108fb565b95602085013595506040909401359392505050565b60006020828403121561096957600080fd5b6108f4826108fb565b6000828210156109ab577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b50039056fea164736f6c634300080f000a496e697469616c697a61626c653a20636f6e7472616374206973206e6f742069", + "deployedBytecode": "0x608060405234801561001057600080fd5b50600436106100d45760003560e01c80638da5cb5b11610081578063f2fde38b1161005b578063f2fde38b146101b8578063f7d12760146101cb578063ffa1ad74146101d357600080fd5b80638da5cb5b14610180578063d798b1ac146101a8578063dc8452cd146101b057600080fd5b80635fd579af116100b25780635fd579af14610152578063715018a6146101655780637a1ac61e1461016d57600080fd5b80630457d6f2146100d9578063206a8300146100ee57806354fd4d5014610109575b600080fd5b6100ec6100e736600461085d565b6101db565b005b6100f66101ef565b6040519081526020015b60405180910390f35b6101456040518060400160405280600581526020017f312e302e3000000000000000000000000000000000000000000000000000000081525081565b60405161010091906108e1565b6100ec61016036600461085d565b61021d565b6100ec61022e565b6100ec61017b366004610924565b610242565b60335460405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610100565b6100f66103ad565b6100f66103e6565b6100ec6101c6366004610957565b610416565b6100f66104ca565b6100f6600081565b6101e36104f9565b6101ec8161057a565b50565b61021a60017f4aaefe95bd84fd3f32700cf3b7566bc944b73138e41958b5785826df2aecace1610972565b81565b6102256104f9565b6101ec81610632565b6102366104f9565b61024060006106ac565b565b600054600390610100900460ff16158015610264575060005460ff8083169116105b6102f5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a656400000000000000000000000000000000000060648201526084015b60405180910390fd5b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001660ff83161761010017905561032e610723565b61033784610416565b6103408361057a565b61034982610632565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff16905560405160ff821681527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a150505050565b60006103e16103dd60017fe314dfc40f0025322aacc0ba8ef420b62fb3b702cf01e0cdf3d829117ac2ff1b610972565b5490565b905090565b60006103e16103dd60017f4aaefe95bd84fd3f32700cf3b7566bc944b73138e41958b5785826df2aecace1610972565b61041e6104f9565b73ffffffffffffffffffffffffffffffffffffffff81166104c1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f4f776e61626c653a206e6577206f776e657220697320746865207a65726f206160448201527f646472657373000000000000000000000000000000000000000000000000000060648201526084016102ec565b6101ec816106ac565b61021a60017fe314dfc40f0025322aacc0ba8ef420b62fb3b702cf01e0cdf3d829117ac2ff1b610972565b9055565b60335473ffffffffffffffffffffffffffffffffffffffff163314610240576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657260448201526064016102ec565b6105ad6105a860017f4aaefe95bd84fd3f32700cf3b7566bc944b73138e41958b5785826df2aecace1610972565b829055565b6000816040516020016105c291815260200190565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152919052905060005b60007f1d2b0bda21d56b8bd12d4f94ebacffdfb35f5e226f84b461103bb8beab6353be8360405161062691906108e1565b60405180910390a35050565b6106606105a860017fe314dfc40f0025322aacc0ba8ef420b62fb3b702cf01e0cdf3d829117ac2ff1b610972565b60008160405160200161067591815260200190565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152919052905060016105f5565b6033805473ffffffffffffffffffffffffffffffffffffffff8381167fffffffffffffffffffffffff0000000000000000000000000000000000000000831681179093556040519116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a35050565b600054610100900460ff166107ba576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e6700000000000000000000000000000000000000000060648201526084016102ec565b610240600054610100900460ff16610854576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e6700000000000000000000000000000000000000000060648201526084016102ec565b610240336106ac565b60006020828403121561086f57600080fd5b5035919050565b6000815180845260005b8181101561089c57602081850181015186830182015201610880565b818111156108ae576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b6020815260006108f46020830184610876565b9392505050565b803573ffffffffffffffffffffffffffffffffffffffff8116811461091f57600080fd5b919050565b60008060006060848603121561093957600080fd5b610942846108fb565b95602085013595506040909401359392505050565b60006020828403121561096957600080fd5b6108f4826108fb565b6000828210156109ab577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b50039056fea164736f6c634300080f000a", + "devdoc": { + "version": 1, + "kind": "dev", + "methods": { + "initialize(address,uint256,uint256)": { + "params": { + "_owner": "Initial owner of the contract.", + "_recommended": "Recommended protocol version to operate on thi chain.", + "_required": "Required protocol version to operate on this chain." + } + }, + "owner()": { + "details": "Returns the address of the current owner." + }, + "recommended()": { + "returns": { + "out_": "Recommended protocol version to sync to the head of the chain." + } + }, + "renounceOwnership()": { + "details": "Leaves the contract without owner. It will not be possible to call `onlyOwner` functions anymore. Can only be called by the current owner. NOTE: Renouncing ownership will leave the contract without an owner, thereby removing any functionality that is only available to the owner." + }, + "required()": { + "returns": { + "out_": "Required protocol version to sync to the head of the chain." + } + }, + "setRecommended(uint256)": { + "params": { + "_recommended": "New recommended protocol version." + } + }, + "setRequired(uint256)": { + "params": { + "_required": "New required protocol version." + } + }, + "transferOwnership(address)": { + "details": "Transfers ownership of the contract to a new account (`newOwner`). Can only be called by the current owner." + } + }, + "events": { + "ConfigUpdate(uint256,uint8,bytes)": { + "params": { + "data": "Encoded update data.", + "updateType": "Type of update.", + "version": "ProtocolVersion version." + } + } + }, + "title": "ProtocolVersions" + }, + "metadata": "{\"compiler\":{\"version\":\"0.8.15+commit.e14f2714\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"version\",\"type\":\"uint256\",\"indexed\":true},{\"internalType\":\"enum ProtocolVersions.UpdateType\",\"name\":\"updateType\",\"type\":\"uint8\",\"indexed\":true},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\",\"indexed\":false}],\"type\":\"event\",\"name\":\"ConfigUpdate\",\"anonymous\":false},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"version\",\"type\":\"uint8\",\"indexed\":false}],\"type\":\"event\",\"name\":\"Initialized\",\"anonymous\":false},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"previousOwner\",\"type\":\"address\",\"indexed\":true},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\",\"indexed\":true}],\"type\":\"event\",\"name\":\"OwnershipTransferred\",\"anonymous\":false},{\"inputs\":[],\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"RECOMMENDED_SLOT\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}]},{\"inputs\":[],\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"REQUIRED_SLOT\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}]},{\"inputs\":[],\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"VERSION\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}]},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_owner\",\"type\":\"address\"},{\"internalType\":\"ProtocolVersion\",\"name\":\"_required\",\"type\":\"uint256\"},{\"internalType\":\"ProtocolVersion\",\"name\":\"_recommended\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\",\"name\":\"initialize\"},{\"inputs\":[],\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}]},{\"inputs\":[],\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"recommended\",\"outputs\":[{\"internalType\":\"ProtocolVersion\",\"name\":\"out_\",\"type\":\"uint256\"}]},{\"inputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\",\"name\":\"renounceOwnership\"},{\"inputs\":[],\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"required\",\"outputs\":[{\"internalType\":\"ProtocolVersion\",\"name\":\"out_\",\"type\":\"uint256\"}]},{\"inputs\":[{\"internalType\":\"ProtocolVersion\",\"name\":\"_recommended\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\",\"name\":\"setRecommended\"},{\"inputs\":[{\"internalType\":\"ProtocolVersion\",\"name\":\"_required\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\",\"name\":\"setRequired\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\",\"name\":\"transferOwnership\"},{\"inputs\":[],\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"version\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}]}],\"devdoc\":{\"kind\":\"dev\",\"methods\":{\"initialize(address,uint256,uint256)\":{\"params\":{\"_owner\":\"Initial owner of the contract.\",\"_recommended\":\"Recommended protocol version to operate on thi chain.\",\"_required\":\"Required protocol version to operate on this chain.\"}},\"owner()\":{\"details\":\"Returns the address of the current owner.\"},\"recommended()\":{\"returns\":{\"out_\":\"Recommended protocol version to sync to the head of the chain.\"}},\"renounceOwnership()\":{\"details\":\"Leaves the contract without owner. It will not be possible to call `onlyOwner` functions anymore. Can only be called by the current owner. NOTE: Renouncing ownership will leave the contract without an owner, thereby removing any functionality that is only available to the owner.\"},\"required()\":{\"returns\":{\"out_\":\"Required protocol version to sync to the head of the chain.\"}},\"setRecommended(uint256)\":{\"params\":{\"_recommended\":\"New recommended protocol version.\"}},\"setRequired(uint256)\":{\"params\":{\"_required\":\"New required protocol version.\"}},\"transferOwnership(address)\":{\"details\":\"Transfers ownership of the contract to a new account (`newOwner`). Can only be called by the current owner.\"}},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{\"RECOMMENDED_SLOT()\":{\"notice\":\"Storage slot that the recommended protocol version is stored at.\"},\"REQUIRED_SLOT()\":{\"notice\":\"Storage slot that the required protocol version is stored at.\"},\"VERSION()\":{\"notice\":\"Version identifier, used for upgrades.\"},\"constructor\":{\"notice\":\"Constructs the ProtocolVersion contract. Cannot set the owner to `address(0)` due to the Ownable contract's implementation, so set it to `address(0xdEaD)` A zero version is considered empty and is ignored by nodes.\"},\"initialize(address,uint256,uint256)\":{\"notice\":\"Initializer.\"},\"recommended()\":{\"notice\":\"High level getter for the recommended protocol version.\"},\"required()\":{\"notice\":\"High level getter for the required protocol version.\"},\"setRecommended(uint256)\":{\"notice\":\"Updates the recommended protocol version. Can only be called by the owner.\"},\"setRequired(uint256)\":{\"notice\":\"Updates the required protocol version. Can only be called by the owner.\"},\"version()\":{\"notice\":\"Semantic version.\"}},\"version\":1}},\"settings\":{\"remappings\":[\":@cwia/=lib/clones-with-immutable-args/src/\",\":@openzeppelin/contracts-upgradeable/=lib/openzeppelin-contracts-upgradeable/contracts/\",\":@openzeppelin/contracts/=lib/openzeppelin-contracts/contracts/\",\":@rari-capital/solmate/=lib/solmate/\",\":clones-with-immutable-args/=lib/clones-with-immutable-args/src/\",\":ds-test/=lib/forge-std/lib/ds-test/src/\",\":forge-std/=lib/forge-std/src/\",\":openzeppelin-contracts-upgradeable/=lib/openzeppelin-contracts-upgradeable/\",\":openzeppelin-contracts/=lib/openzeppelin-contracts/\",\":safe-contracts/=lib/safe-contracts/contracts/\",\":solmate/=lib/solmate/src/\"],\"optimizer\":{\"enabled\":true,\"runs\":999999},\"metadata\":{\"bytecodeHash\":\"none\"},\"compilationTarget\":{\"src/L1/ProtocolVersions.sol\":\"ProtocolVersions\"},\"libraries\":{}},\"sources\":{\"lib/openzeppelin-contracts-upgradeable/contracts/access/OwnableUpgradeable.sol\":{\"keccak256\":\"0x247c62047745915c0af6b955470a72d1696ebad4352d7d3011aef1a2463cd888\",\"urls\":[\"bzz-raw://d7fc8396619de513c96b6e00301b88dd790e83542aab918425633a5f7297a15a\",\"dweb:/ipfs/QmXbP4kiZyp7guuS7xe8KaybnwkRPGrBc2Kbi3vhcTfpxb\"],\"license\":\"MIT\"},\"lib/openzeppelin-contracts-upgradeable/contracts/proxy/utils/Initializable.sol\":{\"keccak256\":\"0x0203dcadc5737d9ef2c211d6fa15d18ebc3b30dfa51903b64870b01a062b0b4e\",\"urls\":[\"bzz-raw://6eb2fd1e9894dbe778f4b8131adecebe570689e63cf892f4e21257bfe1252497\",\"dweb:/ipfs/QmXgUGNfZvrn6N2miv3nooSs7Jm34A41qz94fu2GtDFcx8\"],\"license\":\"MIT\"},\"lib/openzeppelin-contracts-upgradeable/contracts/utils/AddressUpgradeable.sol\":{\"keccak256\":\"0x611aa3f23e59cfdd1863c536776407b3e33d695152a266fa7cfb34440a29a8a3\",\"urls\":[\"bzz-raw://9b4b2110b7f2b3eb32951bc08046fa90feccffa594e1176cb91cdfb0e94726b4\",\"dweb:/ipfs/QmSxLwYjicf9zWFuieRc8WQwE4FisA1Um5jp1iSa731TGt\"],\"license\":\"MIT\"},\"lib/openzeppelin-contracts-upgradeable/contracts/utils/ContextUpgradeable.sol\":{\"keccak256\":\"0x963ea7f0b48b032eef72fe3a7582edf78408d6f834115b9feadd673a4d5bd149\",\"urls\":[\"bzz-raw://d6520943ea55fdf5f0bafb39ed909f64de17051bc954ff3e88c9e5621412c79c\",\"dweb:/ipfs/QmWZ4rAKTQbNG2HxGs46AcTXShsVytKeLs7CUCdCSv5N7a\"],\"license\":\"MIT\"},\"lib/openzeppelin-contracts/contracts/proxy/utils/Initializable.sol\":{\"keccak256\":\"0x2a21b14ff90012878752f230d3ffd5c3405e5938d06c97a7d89c0a64561d0d66\",\"urls\":[\"bzz-raw://3313a8f9bb1f9476857c9050067b31982bf2140b83d84f3bc0cec1f62bbe947f\",\"dweb:/ipfs/Qma17Pk8NRe7aB4UD3jjVxk7nSFaov3eQyv86hcyqkwJRV\"],\"license\":\"MIT\"},\"lib/openzeppelin-contracts/contracts/utils/Address.sol\":{\"keccak256\":\"0xd6153ce99bcdcce22b124f755e72553295be6abcd63804cfdffceb188b8bef10\",\"urls\":[\"bzz-raw://35c47bece3c03caaa07fab37dd2bb3413bfbca20db7bd9895024390e0a469487\",\"dweb:/ipfs/QmPGWT2x3QHcKxqe6gRmAkdakhbaRgx3DLzcakHz5M4eXG\"],\"license\":\"MIT\"},\"lib/openzeppelin-contracts/contracts/utils/math/Math.sol\":{\"keccak256\":\"0xd15c3e400531f00203839159b2b8e7209c5158b35618f570c695b7e47f12e9f0\",\"urls\":[\"bzz-raw://b600b852e0597aa69989cc263111f02097e2827edc1bdc70306303e3af5e9929\",\"dweb:/ipfs/QmU4WfM28A1nDqghuuGeFmN3CnVrk6opWtiF65K4vhFPeC\"],\"license\":\"MIT\"},\"lib/openzeppelin-contracts/contracts/utils/math/SignedMath.sol\":{\"keccak256\":\"0xb3ebde1c8d27576db912d87c3560dab14adfb9cd001be95890ec4ba035e652e7\",\"urls\":[\"bzz-raw://a709421c4f5d4677db8216055d2d4dac96a613efdb08178a9f7041f0c5cef689\",\"dweb:/ipfs/QmYs2rStvVLDnSJs8HgaMD1ABwoKKWdiVbQyNfLfFWTjTy\"],\"license\":\"MIT\"},\"lib/solmate/src/utils/FixedPointMathLib.sol\":{\"keccak256\":\"0x622fcd8a49e132df5ec7651cc6ae3aaf0cf59bdcd67a9a804a1b9e2485113b7d\",\"urls\":[\"bzz-raw://af77088eb606427d4c55e578984a615779c86bc30646a20f7bb27299ba390f7c\",\"dweb:/ipfs/QmZGQdhdQDtHc7gZXWrKXgA3govc74X8U63BiWhPQK3mK8\"],\"license\":\"MIT\"},\"src/L1/ProtocolVersions.sol\":{\"keccak256\":\"0xa283721c36e2ba3ea1c61faebc364a8884bf3a276f80374cc8017d0e23ea1dfc\",\"urls\":[\"bzz-raw://4ee23cbc9772213c637c767747e5fb1db7c3f0f17d6a1ff576b638f25c6799e8\",\"dweb:/ipfs/QmfKZfFC6fyhQdLk2YrjVBL6eRX1d9CTrPHj7fNPUNXmEq\"],\"license\":\"MIT\"},\"src/L1/ResourceMetering.sol\":{\"keccak256\":\"0xa4d524f2a5e91a0b63a62603e712001c51c77e8371b93cbb576bcb7d074b7588\",\"urls\":[\"bzz-raw://d6d8141b6c6dc72d2e684c1ae388c005fd78c9ca7fc9c15dddebd227ca4fd730\",\"dweb:/ipfs/QmPfJrR4qssu769TDWJnxdTozqKtZUxiY8fs95bhfECTvG\"],\"license\":\"MIT\"},\"src/libraries/Arithmetic.sol\":{\"keccak256\":\"0x06a5a8b00527843f0cfc1bb3c0661316966a6cc432f88be31f23cde78cd07560\",\"urls\":[\"bzz-raw://d5209e78e5415c0bf8b350362a825cc56152811abd6fcf2df3d4fa47766d3dee\",\"dweb:/ipfs/Qmf43xyc4Um32NmccayDfhm8kSnS2mhHXpPZnwABJS7cWm\"],\"license\":\"MIT\"},\"src/libraries/Burn.sol\":{\"keccak256\":\"0x90a795bcea3ef06d6d5011256c4bd63d1a4271f519246dbf1ee3e8f1c0e21010\",\"urls\":[\"bzz-raw://9f60c3aa77cf0c484ddda4754157cff4dc0e2eace4bea67990daff4c0612ab5f\",\"dweb:/ipfs/QmSYGanMFve9uBC17X7hFneSFnwnJxz86Jgh6MX9BRMweb\"],\"license\":\"MIT\"},\"src/libraries/Constants.sol\":{\"keccak256\":\"0xe12e392f05f80d3837c9392d016471181ae1ee6b84ea91b4e125e6523e5f18a2\",\"urls\":[\"bzz-raw://a3509231c228b7a4352573cd422cf0260dcbb94cfd915e5b664643db5475a5b7\",\"dweb:/ipfs/QmU2QERY4mHxqWFqSE5Exsy6Ftc5MTjTtYHC11fahLJWDC\"],\"license\":\"MIT\"},\"src/libraries/Storage.sol\":{\"keccak256\":\"0x902a0a815272a5b76c647d9e82101aca765e9835a6624d0857088b9da0f58afd\",\"urls\":[\"bzz-raw://9c39a697aacb0a2eac0bf1fbd7790d835a685c61006f6d3464e19cbc96a24480\",\"dweb:/ipfs/QmV3T8ZTRWPB5CNuZjxwWQNoENd7W4SoBMnFG6Y6g6xYV4\"],\"license\":\"MIT\"},\"src/universal/ISemver.sol\":{\"keccak256\":\"0xba34562a8026f59886d2e07d1d58d90b9691d00e0788c6263cef6c22740cab44\",\"urls\":[\"bzz-raw://0826f998632f83c103c3085bf2e872db79a69022b6d2e0444c83a64ca5283c2a\",\"dweb:/ipfs/QmcJ7PNqkAfKqbjFGRordtAg1v9DvcBSKvdTkVvciLyvQR\"],\"license\":\"MIT\"}},\"version\":1}", + "numDeployments": 1, + "receipt": { + "transactionHash": "0x34e5f1585a2404da7aa6108fbef8d63a4e9d5b077b17b791dfb3aed69d9486cc", + "transactionIndex": "0x7f", + "blockHash": "0x209f9de05c2399a0abd737a44aa0ec55bf2221c7dfedbfe61724b0a831c8f0c8", + "blockNumber": "0x11842d9", + "from": "0x354F3f4ECdcA5E0A7acE08d71348cdC1Dab48960", + "to": "0x4e59b44847b379578588920cA78FbF26c0B4956C", + "cumulativeGasUsed": "0x12caf91", + "gasUsed": "0xa3523", + "contractAddress": "0x42F0bD8313ad456A38061308857b2383fe2c72a0", + "logs": [ + { + "address": "0x42F0bD8313ad456A38061308857b2383fe2c72a0", + "topics": [ + "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", + "0x0000000000000000000000000000000000000000000000000000000000000000", + "0x0000000000000000000000004e59b44847b379578588920ca78fbf26c0b4956c" + ], + "data": "0x", + "blockHash": "0x209f9de05c2399a0abd737a44aa0ec55bf2221c7dfedbfe61724b0a831c8f0c8", + "blockNumber": "0x11842d9", + "transactionHash": "0x34e5f1585a2404da7aa6108fbef8d63a4e9d5b077b17b791dfb3aed69d9486cc", + "transactionIndex": "0x7f", + "logIndex": "0x63e", + "removed": false + }, + { + "address": "0x42F0bD8313ad456A38061308857b2383fe2c72a0", + "topics": [ + "0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0", + "0x0000000000000000000000004e59b44847b379578588920ca78fbf26c0b4956c", + "0x000000000000000000000000000000000000000000000000000000000000dead" + ], + "data": "0x", + "blockHash": "0x209f9de05c2399a0abd737a44aa0ec55bf2221c7dfedbfe61724b0a831c8f0c8", + "blockNumber": "0x11842d9", + "transactionHash": "0x34e5f1585a2404da7aa6108fbef8d63a4e9d5b077b17b791dfb3aed69d9486cc", + "transactionIndex": "0x7f", + "logIndex": "0x63f", + "removed": false + }, + { + "address": "0x42F0bD8313ad456A38061308857b2383fe2c72a0", + "topics": [ + "0x1d2b0bda21d56b8bd12d4f94ebacffdfb35f5e226f84b461103bb8beab6353be", + "0x0000000000000000000000000000000000000000000000000000000000000000", + "0x0000000000000000000000000000000000000000000000000000000000000000" + ], + "data": "0x000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000000", + "blockHash": "0x209f9de05c2399a0abd737a44aa0ec55bf2221c7dfedbfe61724b0a831c8f0c8", + "blockNumber": "0x11842d9", + "transactionHash": "0x34e5f1585a2404da7aa6108fbef8d63a4e9d5b077b17b791dfb3aed69d9486cc", + "transactionIndex": "0x7f", + "logIndex": "0x640", + "removed": false + }, + { + "address": "0x42F0bD8313ad456A38061308857b2383fe2c72a0", + "topics": [ + "0x1d2b0bda21d56b8bd12d4f94ebacffdfb35f5e226f84b461103bb8beab6353be", + "0x0000000000000000000000000000000000000000000000000000000000000000", + "0x0000000000000000000000000000000000000000000000000000000000000001" + ], + "data": "0x000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000000", + "blockHash": "0x209f9de05c2399a0abd737a44aa0ec55bf2221c7dfedbfe61724b0a831c8f0c8", + "blockNumber": "0x11842d9", + "transactionHash": "0x34e5f1585a2404da7aa6108fbef8d63a4e9d5b077b17b791dfb3aed69d9486cc", + "transactionIndex": "0x7f", + "logIndex": "0x641", + "removed": false + }, + { + "address": "0x42F0bD8313ad456A38061308857b2383fe2c72a0", + "topics": [ + "0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498" + ], + "data": "0x0000000000000000000000000000000000000000000000000000000000000003", + "blockHash": "0x209f9de05c2399a0abd737a44aa0ec55bf2221c7dfedbfe61724b0a831c8f0c8", + "blockNumber": "0x11842d9", + "transactionHash": "0x34e5f1585a2404da7aa6108fbef8d63a4e9d5b077b17b791dfb3aed69d9486cc", + "transactionIndex": "0x7f", + "logIndex": "0x642", + "removed": false + } + ], + "status": "0x1", + "logsBloom": "0x00000000000010000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000008000001000000040000000000000000000000000000000000000001000000040000000000000000000000000000020000000000000000000800000000000000000000000800000000400000000000000000000004040000000000000000001080000000000000000000000000000001000000000080000400000000000000000000000000000000000000000400000000000000000000040000000000000000000000000000000060000000000000000000000000000000000080000000000000000000008000000000", + "type": "0x2", + "effectiveGasPrice": "0x200dd2d8d" + }, + "solcInputHash": "0x0000000000000000000000000000000000000000000000000000000000000000", + "storageLayout": { + "storage": [ + { + "astId": 29536, + "contract": "src/L1/ProtocolVersions.sol:ProtocolVersions", + "label": "_initialized", + "offset": 0, + "slot": "0", + "type": "t_uint8" + }, + { + "astId": 29539, + "contract": "src/L1/ProtocolVersions.sol:ProtocolVersions", + "label": "_initializing", + "offset": 1, + "slot": "0", + "type": "t_bool" + }, + { + "astId": 29964, + "contract": "src/L1/ProtocolVersions.sol:ProtocolVersions", + "label": "__gap", + "offset": 0, + "slot": "1", + "type": "t_array(t_uint256)50_storage" + }, + { + "astId": 29408, + "contract": "src/L1/ProtocolVersions.sol:ProtocolVersions", + "label": "_owner", + "offset": 0, + "slot": "51", + "type": "t_address" + }, + { + "astId": 29528, + "contract": "src/L1/ProtocolVersions.sol:ProtocolVersions", + "label": "__gap", + "offset": 0, + "slot": "52", + "type": "t_array(t_uint256)49_storage" + } + ], + "types": { + "t_address": { + "encoding": "inplace", + "label": "address", + "numberOfBytes": "20" + }, + "t_array(t_uint256)49_storage": { + "encoding": "inplace", + "label": "uint256[49]", + "numberOfBytes": "1568", + "base": "t_uint256" + }, + "t_array(t_uint256)50_storage": { + "encoding": "inplace", + "label": "uint256[50]", + "numberOfBytes": "1600", + "base": "t_uint256" + }, + "t_bool": { + "encoding": "inplace", + "label": "bool", + "numberOfBytes": "1" + }, + "t_uint256": { + "encoding": "inplace", + "label": "uint256", + "numberOfBytes": "32" + }, + "t_uint8": { + "encoding": "inplace", + "label": "uint8", + "numberOfBytes": "1" + } + } + }, + "transactionHash": "0x34e5f1585a2404da7aa6108fbef8d63a4e9d5b077b17b791dfb3aed69d9486cc", + "userdoc": { + "version": 1, + "kind": "user", + "methods": { + "RECOMMENDED_SLOT()": { + "notice": "Storage slot that the recommended protocol version is stored at." + }, + "REQUIRED_SLOT()": { + "notice": "Storage slot that the required protocol version is stored at." + }, + "VERSION()": { + "notice": "Version identifier, used for upgrades." + }, + "constructor": { + "notice": "Constructs the ProtocolVersion contract. Cannot set the owner to `address(0)` due to the Ownable contract's implementation, so set it to `address(0xdEaD)` A zero version is considered empty and is ignored by nodes." + }, + "initialize(address,uint256,uint256)": { + "notice": "Initializer." + }, + "recommended()": { + "notice": "High level getter for the recommended protocol version." + }, + "required()": { + "notice": "High level getter for the required protocol version." + }, + "setRecommended(uint256)": { + "notice": "Updates the recommended protocol version. Can only be called by the owner." + }, + "setRequired(uint256)": { + "notice": "Updates the required protocol version. Can only be called by the owner." + }, + "version()": { + "notice": "Semantic version." + } + }, + "events": { + "ConfigUpdate(uint256,uint8,bytes)": { + "notice": "Emitted when configuration is updated." + } + }, + "notice": "The ProtocolVersions contract is used to manage superchain protocol version information." + } +} \ No newline at end of file diff --git a/packages/contracts-bedrock/deployments/mainnet/ProtocolVersionsProxy.json b/packages/contracts-bedrock/deployments/mainnet/ProtocolVersionsProxy.json new file mode 100644 index 0000000000000..571d13eef0f5c --- /dev/null +++ b/packages/contracts-bedrock/deployments/mainnet/ProtocolVersionsProxy.json @@ -0,0 +1,256 @@ +{ + "abi": [ + { + "inputs": [ + { + "internalType": "address", + "name": "_admin", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "previousAdmin", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAdmin", + "type": "address" + } + ], + "name": "AdminChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "implementation", + "type": "address" + } + ], + "name": "Upgraded", + "type": "event" + }, + { + "stateMutability": "payable", + "type": "fallback" + }, + { + "inputs": [], + "name": "admin", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "_admin", + "type": "address" + } + ], + "name": "changeAdmin", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "implementation", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "_implementation", + "type": "address" + } + ], + "name": "upgradeTo", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "_implementation", + "type": "address" + }, + { + "internalType": "bytes", + "name": "_data", + "type": "bytes" + } + ], + "name": "upgradeToAndCall", + "outputs": [ + { + "internalType": "bytes", + "name": "", + "type": "bytes" + } + ], + "stateMutability": "payable", + "type": "function" + }, + { + "stateMutability": "payable", + "type": "receive" + } + ], + "address": "0x8062AbC286f5e7D9428a0Ccb9AbD71e50d93b935", + "args": [ + "0x354F3f4ECdcA5E0A7acE08d71348cdC1Dab48960" + ], + "bytecode": "0x608060405234801561001057600080fd5b5060405161091f38038061091f83398101604081905261002f916100b5565b6100388161003e565b506100e5565b60006100566000805160206108ff8339815191525490565b6000805160206108ff833981519152838155604080516001600160a01b0380851682528616602082015292935090917f7e644d79422f17c01e4894b5f4f588d331ebfa28653d42ae832dc59e38c9798f910160405180910390a1505050565b6000602082840312156100c757600080fd5b81516001600160a01b03811681146100de57600080fd5b9392505050565b61080b806100f46000396000f3fe60806040526004361061005e5760003560e01c80635c60da1b116100435780635c60da1b146100be5780638f283970146100f8578063f851a440146101185761006d565b80633659cfe6146100755780634f1ef286146100955761006d565b3661006d5761006b61012d565b005b61006b61012d565b34801561008157600080fd5b5061006b6100903660046106dd565b610224565b6100a86100a33660046106f8565b610296565b6040516100b5919061077b565b60405180910390f35b3480156100ca57600080fd5b506100d3610419565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020016100b5565b34801561010457600080fd5b5061006b6101133660046106dd565b6104b0565b34801561012457600080fd5b506100d3610517565b60006101577f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc5490565b905073ffffffffffffffffffffffffffffffffffffffff8116610201576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602560248201527f50726f78793a20696d706c656d656e746174696f6e206e6f7420696e6974696160448201527f6c697a656400000000000000000000000000000000000000000000000000000060648201526084015b60405180910390fd5b3660008037600080366000845af43d6000803e8061021e573d6000fd5b503d6000f35b7fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61035473ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16148061027d575033155b1561028e5761028b816105a3565b50565b61028b61012d565b60606102c07fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61035490565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614806102f7575033155b1561040a57610305846105a3565b6000808573ffffffffffffffffffffffffffffffffffffffff16858560405161032f9291906107ee565b600060405180830381855af49150503d806000811461036a576040519150601f19603f3d011682016040523d82523d6000602084013e61036f565b606091505b509150915081610401576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603960248201527f50726f78793a2064656c656761746563616c6c20746f206e657720696d706c6560448201527f6d656e746174696f6e20636f6e7472616374206661696c65640000000000000060648201526084016101f8565b91506104129050565b61041261012d565b9392505050565b60006104437fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61035490565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16148061047a575033155b156104a557507f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc5490565b6104ad61012d565b90565b7fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61035473ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161480610509575033155b1561028e5761028b8161060c565b60006105417fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61035490565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161480610578575033155b156104a557507fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61035490565b7f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc81815560405173ffffffffffffffffffffffffffffffffffffffff8316907fbc7cd75a20ee27fd9adebab32041f755214dbc6bffa90cc0225b39da2e5c2d3b90600090a25050565b60006106367fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61035490565b7fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61038381556040805173ffffffffffffffffffffffffffffffffffffffff80851682528616602082015292935090917f7e644d79422f17c01e4894b5f4f588d331ebfa28653d42ae832dc59e38c9798f910160405180910390a1505050565b803573ffffffffffffffffffffffffffffffffffffffff811681146106d857600080fd5b919050565b6000602082840312156106ef57600080fd5b610412826106b4565b60008060006040848603121561070d57600080fd5b610716846106b4565b9250602084013567ffffffffffffffff8082111561073357600080fd5b818601915086601f83011261074757600080fd5b81358181111561075657600080fd5b87602082850101111561076857600080fd5b6020830194508093505050509250925092565b600060208083528351808285015260005b818110156107a85785810183015185820160400152820161078c565b818111156107ba576000604083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016929092016040019392505050565b818382376000910190815291905056fea164736f6c634300080f000ab53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d6103", + "deployedBytecode": "0x60806040526004361061005e5760003560e01c80635c60da1b116100435780635c60da1b146100be5780638f283970146100f8578063f851a440146101185761006d565b80633659cfe6146100755780634f1ef286146100955761006d565b3661006d5761006b61012d565b005b61006b61012d565b34801561008157600080fd5b5061006b6100903660046106dd565b610224565b6100a86100a33660046106f8565b610296565b6040516100b5919061077b565b60405180910390f35b3480156100ca57600080fd5b506100d3610419565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020016100b5565b34801561010457600080fd5b5061006b6101133660046106dd565b6104b0565b34801561012457600080fd5b506100d3610517565b60006101577f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc5490565b905073ffffffffffffffffffffffffffffffffffffffff8116610201576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602560248201527f50726f78793a20696d706c656d656e746174696f6e206e6f7420696e6974696160448201527f6c697a656400000000000000000000000000000000000000000000000000000060648201526084015b60405180910390fd5b3660008037600080366000845af43d6000803e8061021e573d6000fd5b503d6000f35b7fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61035473ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16148061027d575033155b1561028e5761028b816105a3565b50565b61028b61012d565b60606102c07fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61035490565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614806102f7575033155b1561040a57610305846105a3565b6000808573ffffffffffffffffffffffffffffffffffffffff16858560405161032f9291906107ee565b600060405180830381855af49150503d806000811461036a576040519150601f19603f3d011682016040523d82523d6000602084013e61036f565b606091505b509150915081610401576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603960248201527f50726f78793a2064656c656761746563616c6c20746f206e657720696d706c6560448201527f6d656e746174696f6e20636f6e7472616374206661696c65640000000000000060648201526084016101f8565b91506104129050565b61041261012d565b9392505050565b60006104437fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61035490565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16148061047a575033155b156104a557507f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc5490565b6104ad61012d565b90565b7fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61035473ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161480610509575033155b1561028e5761028b8161060c565b60006105417fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61035490565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161480610578575033155b156104a557507fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61035490565b7f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc81815560405173ffffffffffffffffffffffffffffffffffffffff8316907fbc7cd75a20ee27fd9adebab32041f755214dbc6bffa90cc0225b39da2e5c2d3b90600090a25050565b60006106367fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61035490565b7fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61038381556040805173ffffffffffffffffffffffffffffffffffffffff80851682528616602082015292935090917f7e644d79422f17c01e4894b5f4f588d331ebfa28653d42ae832dc59e38c9798f910160405180910390a1505050565b803573ffffffffffffffffffffffffffffffffffffffff811681146106d857600080fd5b919050565b6000602082840312156106ef57600080fd5b610412826106b4565b60008060006040848603121561070d57600080fd5b610716846106b4565b9250602084013567ffffffffffffffff8082111561073357600080fd5b818601915086601f83011261074757600080fd5b81358181111561075657600080fd5b87602082850101111561076857600080fd5b6020830194508093505050509250925092565b600060208083528351808285015260005b818110156107a85785810183015185820160400152820161078c565b818111156107ba576000604083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016929092016040019392505050565b818382376000910190815291905056fea164736f6c634300080f000a", + "devdoc": { + "version": 1, + "kind": "dev", + "methods": { + "admin()": { + "returns": { + "_0": "Owner address." + } + }, + "changeAdmin(address)": { + "params": { + "_admin": "New owner of the proxy contract." + } + }, + "constructor": { + "params": { + "_admin": "Address of the initial contract admin. Admin as the ability to access the transparent proxy interface." + } + }, + "implementation()": { + "returns": { + "_0": "Implementation address." + } + }, + "upgradeTo(address)": { + "params": { + "_implementation": "Address of the implementation contract." + } + }, + "upgradeToAndCall(address,bytes)": { + "params": { + "_data": "Calldata to delegatecall the new implementation with.", + "_implementation": "Address of the implementation contract." + } + } + }, + "events": { + "AdminChanged(address,address)": { + "params": { + "newAdmin": "The new owner of the contract", + "previousAdmin": "The previous owner of the contract" + } + }, + "Upgraded(address)": { + "params": { + "implementation": "The address of the implementation contract" + } + } + }, + "title": "Proxy" + }, + "metadata": "{\"compiler\":{\"version\":\"0.8.15+commit.e14f2714\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_admin\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"previousAdmin\",\"type\":\"address\",\"indexed\":false},{\"internalType\":\"address\",\"name\":\"newAdmin\",\"type\":\"address\",\"indexed\":false}],\"type\":\"event\",\"name\":\"AdminChanged\",\"anonymous\":false},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"implementation\",\"type\":\"address\",\"indexed\":true}],\"type\":\"event\",\"name\":\"Upgraded\",\"anonymous\":false},{\"inputs\":[],\"stateMutability\":\"payable\",\"type\":\"fallback\"},{\"inputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\",\"name\":\"admin\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}]},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_admin\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\",\"name\":\"changeAdmin\"},{\"inputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\",\"name\":\"implementation\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}]},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_implementation\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\",\"name\":\"upgradeTo\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_implementation\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"_data\",\"type\":\"bytes\"}],\"stateMutability\":\"payable\",\"type\":\"function\",\"name\":\"upgradeToAndCall\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}]},{\"inputs\":[],\"stateMutability\":\"payable\",\"type\":\"receive\"}],\"devdoc\":{\"kind\":\"dev\",\"methods\":{\"admin()\":{\"returns\":{\"_0\":\"Owner address.\"}},\"changeAdmin(address)\":{\"params\":{\"_admin\":\"New owner of the proxy contract.\"}},\"constructor\":{\"params\":{\"_admin\":\"Address of the initial contract admin. Admin as the ability to access the transparent proxy interface.\"}},\"implementation()\":{\"returns\":{\"_0\":\"Implementation address.\"}},\"upgradeTo(address)\":{\"params\":{\"_implementation\":\"Address of the implementation contract.\"}},\"upgradeToAndCall(address,bytes)\":{\"params\":{\"_data\":\"Calldata to delegatecall the new implementation with.\",\"_implementation\":\"Address of the implementation contract.\"}}},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{\"admin()\":{\"notice\":\"Gets the owner of the proxy contract.\"},\"changeAdmin(address)\":{\"notice\":\"Changes the owner of the proxy contract. Only callable by the owner.\"},\"constructor\":{\"notice\":\"Sets the initial admin during contract deployment. Admin address is stored at the EIP-1967 admin storage slot so that accidental storage collision with the implementation is not possible.\"},\"upgradeTo(address)\":{\"notice\":\"Set the implementation contract address. The code at the given address will execute when this contract is called.\"},\"upgradeToAndCall(address,bytes)\":{\"notice\":\"Set the implementation and call a function in a single transaction. Useful to ensure atomic execution of initialization-based upgrades.\"}},\"version\":1}},\"settings\":{\"remappings\":[\":@cwia/=lib/clones-with-immutable-args/src/\",\":@openzeppelin/contracts-upgradeable/=lib/openzeppelin-contracts-upgradeable/contracts/\",\":@openzeppelin/contracts/=lib/openzeppelin-contracts/contracts/\",\":@rari-capital/solmate/=lib/solmate/\",\":clones-with-immutable-args/=lib/clones-with-immutable-args/src/\",\":ds-test/=lib/forge-std/lib/ds-test/src/\",\":forge-std/=lib/forge-std/src/\",\":openzeppelin-contracts-upgradeable/=lib/openzeppelin-contracts-upgradeable/\",\":openzeppelin-contracts/=lib/openzeppelin-contracts/\",\":safe-contracts/=lib/safe-contracts/contracts/\",\":solmate/=lib/solmate/src/\"],\"optimizer\":{\"enabled\":true,\"runs\":999999},\"metadata\":{\"bytecodeHash\":\"none\"},\"compilationTarget\":{\"src/universal/Proxy.sol\":\"Proxy\"},\"libraries\":{}},\"sources\":{\"lib/openzeppelin-contracts/contracts/proxy/utils/Initializable.sol\":{\"keccak256\":\"0x2a21b14ff90012878752f230d3ffd5c3405e5938d06c97a7d89c0a64561d0d66\",\"urls\":[\"bzz-raw://3313a8f9bb1f9476857c9050067b31982bf2140b83d84f3bc0cec1f62bbe947f\",\"dweb:/ipfs/Qma17Pk8NRe7aB4UD3jjVxk7nSFaov3eQyv86hcyqkwJRV\"],\"license\":\"MIT\"},\"lib/openzeppelin-contracts/contracts/utils/Address.sol\":{\"keccak256\":\"0xd6153ce99bcdcce22b124f755e72553295be6abcd63804cfdffceb188b8bef10\",\"urls\":[\"bzz-raw://35c47bece3c03caaa07fab37dd2bb3413bfbca20db7bd9895024390e0a469487\",\"dweb:/ipfs/QmPGWT2x3QHcKxqe6gRmAkdakhbaRgx3DLzcakHz5M4eXG\"],\"license\":\"MIT\"},\"lib/openzeppelin-contracts/contracts/utils/math/Math.sol\":{\"keccak256\":\"0xd15c3e400531f00203839159b2b8e7209c5158b35618f570c695b7e47f12e9f0\",\"urls\":[\"bzz-raw://b600b852e0597aa69989cc263111f02097e2827edc1bdc70306303e3af5e9929\",\"dweb:/ipfs/QmU4WfM28A1nDqghuuGeFmN3CnVrk6opWtiF65K4vhFPeC\"],\"license\":\"MIT\"},\"lib/openzeppelin-contracts/contracts/utils/math/SignedMath.sol\":{\"keccak256\":\"0xb3ebde1c8d27576db912d87c3560dab14adfb9cd001be95890ec4ba035e652e7\",\"urls\":[\"bzz-raw://a709421c4f5d4677db8216055d2d4dac96a613efdb08178a9f7041f0c5cef689\",\"dweb:/ipfs/QmYs2rStvVLDnSJs8HgaMD1ABwoKKWdiVbQyNfLfFWTjTy\"],\"license\":\"MIT\"},\"lib/solmate/src/utils/FixedPointMathLib.sol\":{\"keccak256\":\"0x622fcd8a49e132df5ec7651cc6ae3aaf0cf59bdcd67a9a804a1b9e2485113b7d\",\"urls\":[\"bzz-raw://af77088eb606427d4c55e578984a615779c86bc30646a20f7bb27299ba390f7c\",\"dweb:/ipfs/QmZGQdhdQDtHc7gZXWrKXgA3govc74X8U63BiWhPQK3mK8\"],\"license\":\"MIT\"},\"src/L1/ResourceMetering.sol\":{\"keccak256\":\"0xa4d524f2a5e91a0b63a62603e712001c51c77e8371b93cbb576bcb7d074b7588\",\"urls\":[\"bzz-raw://d6d8141b6c6dc72d2e684c1ae388c005fd78c9ca7fc9c15dddebd227ca4fd730\",\"dweb:/ipfs/QmPfJrR4qssu769TDWJnxdTozqKtZUxiY8fs95bhfECTvG\"],\"license\":\"MIT\"},\"src/libraries/Arithmetic.sol\":{\"keccak256\":\"0x06a5a8b00527843f0cfc1bb3c0661316966a6cc432f88be31f23cde78cd07560\",\"urls\":[\"bzz-raw://d5209e78e5415c0bf8b350362a825cc56152811abd6fcf2df3d4fa47766d3dee\",\"dweb:/ipfs/Qmf43xyc4Um32NmccayDfhm8kSnS2mhHXpPZnwABJS7cWm\"],\"license\":\"MIT\"},\"src/libraries/Burn.sol\":{\"keccak256\":\"0x90a795bcea3ef06d6d5011256c4bd63d1a4271f519246dbf1ee3e8f1c0e21010\",\"urls\":[\"bzz-raw://9f60c3aa77cf0c484ddda4754157cff4dc0e2eace4bea67990daff4c0612ab5f\",\"dweb:/ipfs/QmSYGanMFve9uBC17X7hFneSFnwnJxz86Jgh6MX9BRMweb\"],\"license\":\"MIT\"},\"src/libraries/Constants.sol\":{\"keccak256\":\"0xe12e392f05f80d3837c9392d016471181ae1ee6b84ea91b4e125e6523e5f18a2\",\"urls\":[\"bzz-raw://a3509231c228b7a4352573cd422cf0260dcbb94cfd915e5b664643db5475a5b7\",\"dweb:/ipfs/QmU2QERY4mHxqWFqSE5Exsy6Ftc5MTjTtYHC11fahLJWDC\"],\"license\":\"MIT\"},\"src/universal/Proxy.sol\":{\"keccak256\":\"0xc56de5e39cd44eaeb93f0f8705dd07f4a89f66d5c186522532cf899a104cdbca\",\"urls\":[\"bzz-raw://cd1b595148fa62a798343a23e3330e79fef7d747f039d664482044be9ec0ccf3\",\"dweb:/ipfs/QmeAft6H9wbc9zZZ3prtRaBGGzcPy9yExKAhZHjp1iZ8UF\"],\"license\":\"MIT\"}},\"version\":1}", + "numDeployments": 2, + "receipt": { + "transactionHash": "0x4ab7f052e31b73b021e814069aca71203829101066362541ba8e14113932ea99", + "transactionIndex": "0x9", + "blockHash": "0x0d0787545a87d78f45279d585b9b25c4aeeb8d2110d56f2c5307b80445d45c53", + "blockNumber": "0x1184344", + "from": "0x354F3f4ECdcA5E0A7acE08d71348cdC1Dab48960", + "to": null, + "cumulativeGasUsed": "0x2afbc6", + "gasUsed": "0x80250", + "contractAddress": "0x8062AbC286f5e7D9428a0Ccb9AbD71e50d93b935", + "logs": [ + { + "address": "0x8062AbC286f5e7D9428a0Ccb9AbD71e50d93b935", + "topics": [ + "0x7e644d79422f17c01e4894b5f4f588d331ebfa28653d42ae832dc59e38c9798f" + ], + "data": "0x0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000354f3f4ecdca5e0a7ace08d71348cdc1dab48960", + "blockHash": "0x0d0787545a87d78f45279d585b9b25c4aeeb8d2110d56f2c5307b80445d45c53", + "blockNumber": "0x1184344", + "transactionHash": "0x4ab7f052e31b73b021e814069aca71203829101066362541ba8e14113932ea99", + "transactionIndex": "0x9", + "logIndex": "0x31", + "removed": false + } + ], + "status": "0x1", + "logsBloom": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000800000000000000000000000000000000000000000000000000000000000000000000000000000000000800000000000000000004000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000040000000000000000000000000000000000000000000000000000000000000000000000000000", + "type": "0x2", + "effectiveGasPrice": "0x22f2c5d4c" + }, + "solcInputHash": "0x0000000000000000000000000000000000000000000000000000000000000000", + "storageLayout": { + "storage": [], + "types": {} + }, + "transactionHash": "0x4ab7f052e31b73b021e814069aca71203829101066362541ba8e14113932ea99", + "userdoc": { + "version": 1, + "kind": "user", + "methods": { + "admin()": { + "notice": "Gets the owner of the proxy contract." + }, + "changeAdmin(address)": { + "notice": "Changes the owner of the proxy contract. Only callable by the owner." + }, + "constructor": { + "notice": "Sets the initial admin during contract deployment. Admin address is stored at the EIP-1967 admin storage slot so that accidental storage collision with the implementation is not possible." + }, + "upgradeTo(address)": { + "notice": "Set the implementation contract address. The code at the given address will execute when this contract is called." + }, + "upgradeToAndCall(address,bytes)": { + "notice": "Set the implementation and call a function in a single transaction. Useful to ensure atomic execution of initialization-based upgrades." + } + }, + "events": { + "AdminChanged(address,address)": { + "notice": "An event that is emitted each time the owner is upgraded. This event is part of the EIP-1967 specification." + }, + "Upgraded(address)": { + "notice": "An event that is emitted each time the implementation is changed. This event is part of the EIP-1967 specification." + } + }, + "notice": "Proxy is a transparent proxy that passes through the call if the caller is the owner or if the caller is address(0), meaning that the call originated from an off-chain simulation." + } +} \ No newline at end of file diff --git a/packages/contracts-bedrock/deployments/optimism-sepolia/.chainId b/packages/contracts-bedrock/deployments/optimism-sepolia/.chainId new file mode 100644 index 0000000000000..03f37de82513e --- /dev/null +++ b/packages/contracts-bedrock/deployments/optimism-sepolia/.chainId @@ -0,0 +1 @@ +11155420 \ No newline at end of file diff --git a/packages/contracts-bedrock/deployments/sepolia/ProtocolVersionsProxy.json b/packages/contracts-bedrock/deployments/sepolia/ProtocolVersionsProxy.json new file mode 100644 index 0000000000000..740dae1754689 --- /dev/null +++ b/packages/contracts-bedrock/deployments/sepolia/ProtocolVersionsProxy.json @@ -0,0 +1,256 @@ +{ + "abi": [ + { + "inputs": [ + { + "internalType": "address", + "name": "_admin", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "address", + "name": "previousAdmin", + "type": "address" + }, + { + "indexed": false, + "internalType": "address", + "name": "newAdmin", + "type": "address" + } + ], + "name": "AdminChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "implementation", + "type": "address" + } + ], + "name": "Upgraded", + "type": "event" + }, + { + "stateMutability": "payable", + "type": "fallback" + }, + { + "inputs": [], + "name": "admin", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "_admin", + "type": "address" + } + ], + "name": "changeAdmin", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "implementation", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "_implementation", + "type": "address" + } + ], + "name": "upgradeTo", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "_implementation", + "type": "address" + }, + { + "internalType": "bytes", + "name": "_data", + "type": "bytes" + } + ], + "name": "upgradeToAndCall", + "outputs": [ + { + "internalType": "bytes", + "name": "", + "type": "bytes" + } + ], + "stateMutability": "payable", + "type": "function" + }, + { + "stateMutability": "payable", + "type": "receive" + } + ], + "address": "0x79ADD5713B383DAa0a138d3C4780C7A1804a8090", + "args": [ + "0x0a08E04c73f22C65D6dBFF20f87171240df6E519" + ], + "bytecode": "0x608060405234801561001057600080fd5b5060405161091f38038061091f83398101604081905261002f916100b5565b6100388161003e565b506100e5565b60006100566000805160206108ff8339815191525490565b6000805160206108ff833981519152838155604080516001600160a01b0380851682528616602082015292935090917f7e644d79422f17c01e4894b5f4f588d331ebfa28653d42ae832dc59e38c9798f910160405180910390a1505050565b6000602082840312156100c757600080fd5b81516001600160a01b03811681146100de57600080fd5b9392505050565b61080b806100f46000396000f3fe60806040526004361061005e5760003560e01c80635c60da1b116100435780635c60da1b146100be5780638f283970146100f8578063f851a440146101185761006d565b80633659cfe6146100755780634f1ef286146100955761006d565b3661006d5761006b61012d565b005b61006b61012d565b34801561008157600080fd5b5061006b6100903660046106dd565b610224565b6100a86100a33660046106f8565b610296565b6040516100b5919061077b565b60405180910390f35b3480156100ca57600080fd5b506100d3610419565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020016100b5565b34801561010457600080fd5b5061006b6101133660046106dd565b6104b0565b34801561012457600080fd5b506100d3610517565b60006101577f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc5490565b905073ffffffffffffffffffffffffffffffffffffffff8116610201576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602560248201527f50726f78793a20696d706c656d656e746174696f6e206e6f7420696e6974696160448201527f6c697a656400000000000000000000000000000000000000000000000000000060648201526084015b60405180910390fd5b3660008037600080366000845af43d6000803e8061021e573d6000fd5b503d6000f35b7fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61035473ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16148061027d575033155b1561028e5761028b816105a3565b50565b61028b61012d565b60606102c07fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61035490565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614806102f7575033155b1561040a57610305846105a3565b6000808573ffffffffffffffffffffffffffffffffffffffff16858560405161032f9291906107ee565b600060405180830381855af49150503d806000811461036a576040519150601f19603f3d011682016040523d82523d6000602084013e61036f565b606091505b509150915081610401576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603960248201527f50726f78793a2064656c656761746563616c6c20746f206e657720696d706c6560448201527f6d656e746174696f6e20636f6e7472616374206661696c65640000000000000060648201526084016101f8565b91506104129050565b61041261012d565b9392505050565b60006104437fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61035490565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16148061047a575033155b156104a557507f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc5490565b6104ad61012d565b90565b7fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61035473ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161480610509575033155b1561028e5761028b8161060c565b60006105417fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61035490565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161480610578575033155b156104a557507fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61035490565b7f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc81815560405173ffffffffffffffffffffffffffffffffffffffff8316907fbc7cd75a20ee27fd9adebab32041f755214dbc6bffa90cc0225b39da2e5c2d3b90600090a25050565b60006106367fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61035490565b7fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61038381556040805173ffffffffffffffffffffffffffffffffffffffff80851682528616602082015292935090917f7e644d79422f17c01e4894b5f4f588d331ebfa28653d42ae832dc59e38c9798f910160405180910390a1505050565b803573ffffffffffffffffffffffffffffffffffffffff811681146106d857600080fd5b919050565b6000602082840312156106ef57600080fd5b610412826106b4565b60008060006040848603121561070d57600080fd5b610716846106b4565b9250602084013567ffffffffffffffff8082111561073357600080fd5b818601915086601f83011261074757600080fd5b81358181111561075657600080fd5b87602082850101111561076857600080fd5b6020830194508093505050509250925092565b600060208083528351808285015260005b818110156107a85785810183015185820160400152820161078c565b818111156107ba576000604083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016929092016040019392505050565b818382376000910190815291905056fea164736f6c634300080f000ab53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d6103", + "deployedBytecode": "0x60806040526004361061005e5760003560e01c80635c60da1b116100435780635c60da1b146100be5780638f283970146100f8578063f851a440146101185761006d565b80633659cfe6146100755780634f1ef286146100955761006d565b3661006d5761006b61012d565b005b61006b61012d565b34801561008157600080fd5b5061006b6100903660046106dd565b610224565b6100a86100a33660046106f8565b610296565b6040516100b5919061077b565b60405180910390f35b3480156100ca57600080fd5b506100d3610419565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020016100b5565b34801561010457600080fd5b5061006b6101133660046106dd565b6104b0565b34801561012457600080fd5b506100d3610517565b60006101577f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc5490565b905073ffffffffffffffffffffffffffffffffffffffff8116610201576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602560248201527f50726f78793a20696d706c656d656e746174696f6e206e6f7420696e6974696160448201527f6c697a656400000000000000000000000000000000000000000000000000000060648201526084015b60405180910390fd5b3660008037600080366000845af43d6000803e8061021e573d6000fd5b503d6000f35b7fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61035473ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16148061027d575033155b1561028e5761028b816105a3565b50565b61028b61012d565b60606102c07fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61035490565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614806102f7575033155b1561040a57610305846105a3565b6000808573ffffffffffffffffffffffffffffffffffffffff16858560405161032f9291906107ee565b600060405180830381855af49150503d806000811461036a576040519150601f19603f3d011682016040523d82523d6000602084013e61036f565b606091505b509150915081610401576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152603960248201527f50726f78793a2064656c656761746563616c6c20746f206e657720696d706c6560448201527f6d656e746174696f6e20636f6e7472616374206661696c65640000000000000060648201526084016101f8565b91506104129050565b61041261012d565b9392505050565b60006104437fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61035490565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16148061047a575033155b156104a557507f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc5490565b6104ad61012d565b90565b7fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61035473ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161480610509575033155b1561028e5761028b8161060c565b60006105417fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61035490565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161480610578575033155b156104a557507fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61035490565b7f360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc81815560405173ffffffffffffffffffffffffffffffffffffffff8316907fbc7cd75a20ee27fd9adebab32041f755214dbc6bffa90cc0225b39da2e5c2d3b90600090a25050565b60006106367fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61035490565b7fb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d61038381556040805173ffffffffffffffffffffffffffffffffffffffff80851682528616602082015292935090917f7e644d79422f17c01e4894b5f4f588d331ebfa28653d42ae832dc59e38c9798f910160405180910390a1505050565b803573ffffffffffffffffffffffffffffffffffffffff811681146106d857600080fd5b919050565b6000602082840312156106ef57600080fd5b610412826106b4565b60008060006040848603121561070d57600080fd5b610716846106b4565b9250602084013567ffffffffffffffff8082111561073357600080fd5b818601915086601f83011261074757600080fd5b81358181111561075657600080fd5b87602082850101111561076857600080fd5b6020830194508093505050509250925092565b600060208083528351808285015260005b818110156107a85785810183015185820160400152820161078c565b818111156107ba576000604083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016929092016040019392505050565b818382376000910190815291905056fea164736f6c634300080f000a", + "devdoc": { + "version": 1, + "kind": "dev", + "methods": { + "admin()": { + "returns": { + "_0": "Owner address." + } + }, + "changeAdmin(address)": { + "params": { + "_admin": "New owner of the proxy contract." + } + }, + "constructor": { + "params": { + "_admin": "Address of the initial contract admin. Admin as the ability to access the transparent proxy interface." + } + }, + "implementation()": { + "returns": { + "_0": "Implementation address." + } + }, + "upgradeTo(address)": { + "params": { + "_implementation": "Address of the implementation contract." + } + }, + "upgradeToAndCall(address,bytes)": { + "params": { + "_data": "Calldata to delegatecall the new implementation with.", + "_implementation": "Address of the implementation contract." + } + } + }, + "events": { + "AdminChanged(address,address)": { + "params": { + "newAdmin": "The new owner of the contract", + "previousAdmin": "The previous owner of the contract" + } + }, + "Upgraded(address)": { + "params": { + "implementation": "The address of the implementation contract" + } + } + }, + "title": "Proxy" + }, + "metadata": "{\"compiler\":{\"version\":\"0.8.15+commit.e14f2714\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_admin\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"previousAdmin\",\"type\":\"address\",\"indexed\":false},{\"internalType\":\"address\",\"name\":\"newAdmin\",\"type\":\"address\",\"indexed\":false}],\"type\":\"event\",\"name\":\"AdminChanged\",\"anonymous\":false},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"implementation\",\"type\":\"address\",\"indexed\":true}],\"type\":\"event\",\"name\":\"Upgraded\",\"anonymous\":false},{\"inputs\":[],\"stateMutability\":\"payable\",\"type\":\"fallback\"},{\"inputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\",\"name\":\"admin\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}]},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_admin\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\",\"name\":\"changeAdmin\"},{\"inputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\",\"name\":\"implementation\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}]},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_implementation\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\",\"name\":\"upgradeTo\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_implementation\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"_data\",\"type\":\"bytes\"}],\"stateMutability\":\"payable\",\"type\":\"function\",\"name\":\"upgradeToAndCall\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}]},{\"inputs\":[],\"stateMutability\":\"payable\",\"type\":\"receive\"}],\"devdoc\":{\"kind\":\"dev\",\"methods\":{\"admin()\":{\"returns\":{\"_0\":\"Owner address.\"}},\"changeAdmin(address)\":{\"params\":{\"_admin\":\"New owner of the proxy contract.\"}},\"constructor\":{\"params\":{\"_admin\":\"Address of the initial contract admin. Admin as the ability to access the transparent proxy interface.\"}},\"implementation()\":{\"returns\":{\"_0\":\"Implementation address.\"}},\"upgradeTo(address)\":{\"params\":{\"_implementation\":\"Address of the implementation contract.\"}},\"upgradeToAndCall(address,bytes)\":{\"params\":{\"_data\":\"Calldata to delegatecall the new implementation with.\",\"_implementation\":\"Address of the implementation contract.\"}}},\"version\":1},\"userdoc\":{\"kind\":\"user\",\"methods\":{\"admin()\":{\"notice\":\"Gets the owner of the proxy contract.\"},\"changeAdmin(address)\":{\"notice\":\"Changes the owner of the proxy contract. Only callable by the owner.\"},\"constructor\":{\"notice\":\"Sets the initial admin during contract deployment. Admin address is stored at the EIP-1967 admin storage slot so that accidental storage collision with the implementation is not possible.\"},\"upgradeTo(address)\":{\"notice\":\"Set the implementation contract address. The code at the given address will execute when this contract is called.\"},\"upgradeToAndCall(address,bytes)\":{\"notice\":\"Set the implementation and call a function in a single transaction. Useful to ensure atomic execution of initialization-based upgrades.\"}},\"version\":1}},\"settings\":{\"remappings\":[\":@cwia/=lib/clones-with-immutable-args/src/\",\":@openzeppelin/contracts-upgradeable/=lib/openzeppelin-contracts-upgradeable/contracts/\",\":@openzeppelin/contracts/=lib/openzeppelin-contracts/contracts/\",\":@rari-capital/solmate/=lib/solmate/\",\":clones-with-immutable-args/=lib/clones-with-immutable-args/src/\",\":ds-test/=lib/forge-std/lib/ds-test/src/\",\":forge-std/=lib/forge-std/src/\",\":openzeppelin-contracts-upgradeable/=lib/openzeppelin-contracts-upgradeable/\",\":openzeppelin-contracts/=lib/openzeppelin-contracts/\",\":safe-contracts/=lib/safe-contracts/contracts/\",\":solmate/=lib/solmate/src/\"],\"optimizer\":{\"enabled\":true,\"runs\":999999},\"metadata\":{\"bytecodeHash\":\"none\"},\"compilationTarget\":{\"src/universal/Proxy.sol\":\"Proxy\"},\"libraries\":{}},\"sources\":{\"lib/openzeppelin-contracts/contracts/proxy/utils/Initializable.sol\":{\"keccak256\":\"0x2a21b14ff90012878752f230d3ffd5c3405e5938d06c97a7d89c0a64561d0d66\",\"urls\":[\"bzz-raw://3313a8f9bb1f9476857c9050067b31982bf2140b83d84f3bc0cec1f62bbe947f\",\"dweb:/ipfs/Qma17Pk8NRe7aB4UD3jjVxk7nSFaov3eQyv86hcyqkwJRV\"],\"license\":\"MIT\"},\"lib/openzeppelin-contracts/contracts/utils/Address.sol\":{\"keccak256\":\"0xd6153ce99bcdcce22b124f755e72553295be6abcd63804cfdffceb188b8bef10\",\"urls\":[\"bzz-raw://35c47bece3c03caaa07fab37dd2bb3413bfbca20db7bd9895024390e0a469487\",\"dweb:/ipfs/QmPGWT2x3QHcKxqe6gRmAkdakhbaRgx3DLzcakHz5M4eXG\"],\"license\":\"MIT\"},\"lib/openzeppelin-contracts/contracts/utils/math/Math.sol\":{\"keccak256\":\"0xd15c3e400531f00203839159b2b8e7209c5158b35618f570c695b7e47f12e9f0\",\"urls\":[\"bzz-raw://b600b852e0597aa69989cc263111f02097e2827edc1bdc70306303e3af5e9929\",\"dweb:/ipfs/QmU4WfM28A1nDqghuuGeFmN3CnVrk6opWtiF65K4vhFPeC\"],\"license\":\"MIT\"},\"lib/openzeppelin-contracts/contracts/utils/math/SignedMath.sol\":{\"keccak256\":\"0xb3ebde1c8d27576db912d87c3560dab14adfb9cd001be95890ec4ba035e652e7\",\"urls\":[\"bzz-raw://a709421c4f5d4677db8216055d2d4dac96a613efdb08178a9f7041f0c5cef689\",\"dweb:/ipfs/QmYs2rStvVLDnSJs8HgaMD1ABwoKKWdiVbQyNfLfFWTjTy\"],\"license\":\"MIT\"},\"lib/solmate/src/utils/FixedPointMathLib.sol\":{\"keccak256\":\"0x622fcd8a49e132df5ec7651cc6ae3aaf0cf59bdcd67a9a804a1b9e2485113b7d\",\"urls\":[\"bzz-raw://af77088eb606427d4c55e578984a615779c86bc30646a20f7bb27299ba390f7c\",\"dweb:/ipfs/QmZGQdhdQDtHc7gZXWrKXgA3govc74X8U63BiWhPQK3mK8\"],\"license\":\"MIT\"},\"src/L1/ResourceMetering.sol\":{\"keccak256\":\"0xa4d524f2a5e91a0b63a62603e712001c51c77e8371b93cbb576bcb7d074b7588\",\"urls\":[\"bzz-raw://d6d8141b6c6dc72d2e684c1ae388c005fd78c9ca7fc9c15dddebd227ca4fd730\",\"dweb:/ipfs/QmPfJrR4qssu769TDWJnxdTozqKtZUxiY8fs95bhfECTvG\"],\"license\":\"MIT\"},\"src/libraries/Arithmetic.sol\":{\"keccak256\":\"0x06a5a8b00527843f0cfc1bb3c0661316966a6cc432f88be31f23cde78cd07560\",\"urls\":[\"bzz-raw://d5209e78e5415c0bf8b350362a825cc56152811abd6fcf2df3d4fa47766d3dee\",\"dweb:/ipfs/Qmf43xyc4Um32NmccayDfhm8kSnS2mhHXpPZnwABJS7cWm\"],\"license\":\"MIT\"},\"src/libraries/Burn.sol\":{\"keccak256\":\"0x90a795bcea3ef06d6d5011256c4bd63d1a4271f519246dbf1ee3e8f1c0e21010\",\"urls\":[\"bzz-raw://9f60c3aa77cf0c484ddda4754157cff4dc0e2eace4bea67990daff4c0612ab5f\",\"dweb:/ipfs/QmSYGanMFve9uBC17X7hFneSFnwnJxz86Jgh6MX9BRMweb\"],\"license\":\"MIT\"},\"src/libraries/Constants.sol\":{\"keccak256\":\"0xe12e392f05f80d3837c9392d016471181ae1ee6b84ea91b4e125e6523e5f18a2\",\"urls\":[\"bzz-raw://a3509231c228b7a4352573cd422cf0260dcbb94cfd915e5b664643db5475a5b7\",\"dweb:/ipfs/QmU2QERY4mHxqWFqSE5Exsy6Ftc5MTjTtYHC11fahLJWDC\"],\"license\":\"MIT\"},\"src/universal/Proxy.sol\":{\"keccak256\":\"0xc56de5e39cd44eaeb93f0f8705dd07f4a89f66d5c186522532cf899a104cdbca\",\"urls\":[\"bzz-raw://cd1b595148fa62a798343a23e3330e79fef7d747f039d664482044be9ec0ccf3\",\"dweb:/ipfs/QmeAft6H9wbc9zZZ3prtRaBGGzcPy9yExKAhZHjp1iZ8UF\"],\"license\":\"MIT\"}},\"version\":1}", + "numDeployments": 1, + "receipt": { + "transactionHash": "0xb38d6a449755fc90b9b4a96879c896aa21e156b0363aabec9959d71b554c1060", + "transactionIndex": "0x1", + "blockHash": "0x294120db9ff8f22f5d95b4bcc5dffb23af2cc6f7b02ce2726de0de377f10e03a", + "blockNumber": "0x44bb94", + "from": "0x0a08E04c73f22C65D6dBFF20f87171240df6E519", + "to": null, + "cumulativeGasUsed": "0x135be4", + "gasUsed": "0x80250", + "contractAddress": "0x79ADD5713B383DAa0a138d3C4780C7A1804a8090", + "logs": [ + { + "address": "0x79ADD5713B383DAa0a138d3C4780C7A1804a8090", + "topics": [ + "0x7e644d79422f17c01e4894b5f4f588d331ebfa28653d42ae832dc59e38c9798f" + ], + "data": "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000a08e04c73f22c65d6dbff20f87171240df6e519", + "blockHash": "0x294120db9ff8f22f5d95b4bcc5dffb23af2cc6f7b02ce2726de0de377f10e03a", + "blockNumber": "0x44bb94", + "transactionHash": "0xb38d6a449755fc90b9b4a96879c896aa21e156b0363aabec9959d71b554c1060", + "transactionIndex": "0x1", + "logIndex": "0x4", + "removed": false + } + ], + "status": "0x1", + "logsBloom": "0x00000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000800000800000000000000000000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000080000400000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "type": "0x2", + "effectiveGasPrice": "0xb2d05e10" + }, + "solcInputHash": "0x0000000000000000000000000000000000000000000000000000000000000000", + "storageLayout": { + "storage": [], + "types": {} + }, + "transactionHash": "0xb38d6a449755fc90b9b4a96879c896aa21e156b0363aabec9959d71b554c1060", + "userdoc": { + "version": 1, + "kind": "user", + "methods": { + "admin()": { + "notice": "Gets the owner of the proxy contract." + }, + "changeAdmin(address)": { + "notice": "Changes the owner of the proxy contract. Only callable by the owner." + }, + "constructor": { + "notice": "Sets the initial admin during contract deployment. Admin address is stored at the EIP-1967 admin storage slot so that accidental storage collision with the implementation is not possible." + }, + "upgradeTo(address)": { + "notice": "Set the implementation contract address. The code at the given address will execute when this contract is called." + }, + "upgradeToAndCall(address,bytes)": { + "notice": "Set the implementation and call a function in a single transaction. Useful to ensure atomic execution of initialization-based upgrades." + } + }, + "events": { + "AdminChanged(address,address)": { + "notice": "An event that is emitted each time the owner is upgraded. This event is part of the EIP-1967 specification." + }, + "Upgraded(address)": { + "notice": "An event that is emitted each time the implementation is changed. This event is part of the EIP-1967 specification." + } + }, + "notice": "Proxy is a transparent proxy that passes through the call if the caller is the owner or if the caller is address(0), meaning that the call originated from an off-chain simulation." + } +} \ No newline at end of file diff --git a/packages/contracts-bedrock/foundry.toml b/packages/contracts-bedrock/foundry.toml index 8c1cc245b6811..abd0cde2ba8ba 100644 --- a/packages/contracts-bedrock/foundry.toml +++ b/packages/contracts-bedrock/foundry.toml @@ -52,3 +52,10 @@ ignore = ['src/vendor/WETH9.sol'] [profile.ci.fuzz] runs = 512 + +################################################################ +# PROFILE: LITE # +################################################################ + +[profile.lite] +optimizer = false diff --git a/packages/contracts-bedrock/invariant-docs/CrossDomainMessenger.md b/packages/contracts-bedrock/invariant-docs/CrossDomainMessenger.md index 3fae2cddfa877..95ed2ffdfc19b 100644 --- a/packages/contracts-bedrock/invariant-docs/CrossDomainMessenger.md +++ b/packages/contracts-bedrock/invariant-docs/CrossDomainMessenger.md @@ -1,14 +1,14 @@ # `CrossDomainMessenger` Invariants ## A call to `relayMessage` should succeed if at least the minimum gas limit can be supplied to the target context, there is enough gas to complete execution of `relayMessage` after the target context's execution is finished, and the target context did not revert. -**Test:** [`CrossDomainMessenger.t.sol#L136`](../test/invariants/CrossDomainMessenger.t.sol#L136) +**Test:** [`CrossDomainMessenger.t.sol#L137`](../test/invariants/CrossDomainMessenger.t.sol#L137) There are two minimum gas limits here: - The outer min gas limit is for the call from the `OptimismPortal` to the `L1CrossDomainMessenger`, and it can be retrieved by calling the xdm's `baseGas` function with the `message` and inner limit. - The inner min gas limit is for the call from the `L1CrossDomainMessenger` to the target contract. ## A call to `relayMessage` should assign the message hash to the `failedMessages` mapping if not enough gas is supplied to forward `minGasLimit` to the target context or if there is not enough gas to complete execution of `relayMessage` after the target context's execution is finished. -**Test:** [`CrossDomainMessenger.t.sol#L169`](../test/invariants/CrossDomainMessenger.t.sol#L169) +**Test:** [`CrossDomainMessenger.t.sol#L170`](../test/invariants/CrossDomainMessenger.t.sol#L170) There are two minimum gas limits here: - The outer min gas limit is for the call from the `OptimismPortal` to the `L1CrossDomainMessenger`, and it can be retrieved by calling the xdm's `baseGas` function with the `message` and inner limit. diff --git a/packages/contracts-bedrock/invariant-docs/OptimismPortal.md b/packages/contracts-bedrock/invariant-docs/OptimismPortal.md index d9f5bf7d8a970..b1b2c38cb2786 100644 --- a/packages/contracts-bedrock/invariant-docs/OptimismPortal.md +++ b/packages/contracts-bedrock/invariant-docs/OptimismPortal.md @@ -1,21 +1,21 @@ # `OptimismPortal` Invariants ## Deposits of any value should always succeed unless `_to` = `address(0)` or `_isCreation` = `true`. -**Test:** [`OptimismPortal.t.sol#L147`](../test/invariants/OptimismPortal.t.sol#L147) +**Test:** [`OptimismPortal.t.sol#L151`](../test/invariants/OptimismPortal.t.sol#L151) All deposits, barring creation transactions and transactions sent to `address(0)`, should always succeed. ## `finalizeWithdrawalTransaction` should revert if the finalization period has not elapsed. -**Test:** [`OptimismPortal.t.sol#L170`](../test/invariants/OptimismPortal.t.sol#L170) +**Test:** [`OptimismPortal.t.sol#L174`](../test/invariants/OptimismPortal.t.sol#L174) A withdrawal that has been proven should not be able to be finalized until after the finalization period has elapsed. ## `finalizeWithdrawalTransaction` should revert if the withdrawal has already been finalized. -**Test:** [`OptimismPortal.t.sol#L200`](../test/invariants/OptimismPortal.t.sol#L200) +**Test:** [`OptimismPortal.t.sol#L204`](../test/invariants/OptimismPortal.t.sol#L204) Ensures that there is no chain of calls that can be made that allows a withdrawal to be finalized twice. ## A withdrawal should **always** be able to be finalized `FINALIZATION_PERIOD_SECONDS` after it was successfully proven. -**Test:** [`OptimismPortal.t.sol#L229`](../test/invariants/OptimismPortal.t.sol#L229) +**Test:** [`OptimismPortal.t.sol#L233`](../test/invariants/OptimismPortal.t.sol#L233) This invariant asserts that there is no chain of calls that can be made that will prevent a withdrawal from being finalized exactly `FINALIZATION_PERIOD_SECONDS` after it was successfully proven. \ No newline at end of file diff --git a/packages/contracts-bedrock/invariant-docs/SystemConfig.md b/packages/contracts-bedrock/invariant-docs/SystemConfig.md index 9fdb692296fa8..48e635492de19 100644 --- a/packages/contracts-bedrock/invariant-docs/SystemConfig.md +++ b/packages/contracts-bedrock/invariant-docs/SystemConfig.md @@ -1,5 +1,5 @@ # `SystemConfig` Invariants ## The gas limit of the `SystemConfig` contract can never be lower than the hard-coded lower bound. -**Test:** [`SystemConfig.t.sol#L62`](../test/invariants/SystemConfig.t.sol#L62) +**Test:** [`SystemConfig.t.sol#L70`](../test/invariants/SystemConfig.t.sol#L70) diff --git a/packages/contracts-bedrock/lib/forge-std b/packages/contracts-bedrock/lib/forge-std index e8a047e3f40f1..37a37ab73364d 160000 --- a/packages/contracts-bedrock/lib/forge-std +++ b/packages/contracts-bedrock/lib/forge-std @@ -1 +1 @@ -Subproject commit e8a047e3f40f13fa37af6fe14e6e06283d9a060e +Subproject commit 37a37ab73364d6644bfe11edf88a07880f99bd56 diff --git a/packages/contracts-bedrock/package.json b/packages/contracts-bedrock/package.json index 0898fef8f6c8d..9da53b0ff2950 100644 --- a/packages/contracts-bedrock/package.json +++ b/packages/contracts-bedrock/package.json @@ -11,18 +11,17 @@ "scripts": { "bindings": "pnpm bindings:ts && pnpm bindings:go", "bindings:ts": "nx generate @eth-optimism/contracts-ts", - "bindings:go:no-build": "cd ../../op-bindings && make binding-build", - "bindings:go": "pnpm clean && pnpm build && bindings:go:no-build", + "bindings:go:no-build": "cd ../../op-bindings && make bindings-build", + "bindings:go": "pnpm clean && pnpm build && pnpm bindings:go:no-build", "prebuild": "./scripts/verify-foundry-install.sh", "build": "forge build", - "build:differential": "go build -o ./scripts/differential-testing/differential-testing ./scripts/differential-testing", - "build:fuzz": "(cd test-case-generator && go build ./cmd/fuzz.go)", + "build:go-ffi": "(cd scripts/go-ffi && go build)", "autogen:invariant-docs": "npx tsx scripts/invariant-doc-gen.ts", - "test": "pnpm build:differential && pnpm build:fuzz && forge test", - "coverage": "pnpm build:differential && pnpm build:fuzz && forge coverage", - "coverage:lcov": "pnpm build:differential && pnpm build:fuzz && forge coverage --report lcov", + "test": "pnpm build:go-ffi && forge test", + "coverage": "pnpm build:go-ffi && forge coverage", + "coverage:lcov": "pnpm build:go-ffi && forge coverage --report lcov", "gas-snapshot:no-build": "forge snapshot --no-match-test 'testDiff|testFuzz|invariant|generateArtifact'", - "gas-snapshot": "pnpm build:differential && pnpm build:fuzz && pnpm gas-snapshot:no-build", + "gas-snapshot": "pnpm build:go-ffi && pnpm gas-snapshot:no-build", "storage-snapshot": "./scripts/storage-snapshot.sh", "semver-lock": "forge script scripts/SemverLock.s.sol", "validate-deploy-configs": "./scripts/check-deploy-configs.sh", @@ -30,10 +29,10 @@ "validate-spacers": "pnpm build && pnpm validate-spacers:no-build", "slither": "./scripts/slither.sh", "slither:triage": "TRIAGE_MODE=1 ./scripts/slither.sh", - "clean": "rm -rf ./artifacts ./forge-artifacts ./cache ./tsconfig.tsbuildinfo ./tsconfig.build.tsbuildinfo ./test-case-generator/fuzz ./scripts/differential-testing/differential-testing", + "clean": "rm -rf ./artifacts ./forge-artifacts ./cache ./tsconfig.tsbuildinfo ./tsconfig.build.tsbuildinfo ./scripts/go-ffi/go-ffi", "preinstall": "npx only-allow pnpm", "pre-pr:no-build": "pnpm gas-snapshot:no-build && pnpm storage-snapshot && pnpm semver-lock && pnpm autogen:invariant-docs && pnpm lint && pnpm bindings:go", - "pre-pr": "pnpm clean && pnpm build:differential && pnpm build:fuzz && pnpm build && pnpm pre-pr:no-build", + "pre-pr": "pnpm clean && pnpm build:go-ffi && pnpm build && pnpm pre-pr:no-build", "pre-pr:full": "pnpm test && pnpm slither && pnpm validate-deploy-configs && pnpm validate-spacers && pnpm pre-pr", "lint:ts:check": "eslint . --max-warnings=0", "lint:forge-tests:check": "npx tsx scripts/forge-test-names.ts", @@ -45,9 +44,9 @@ "lint": "pnpm lint:fix && pnpm lint:check" }, "devDependencies": { - "@typescript-eslint/eslint-plugin": "^6.7.5", - "@typescript-eslint/parser": "^6.7.5", - "tsx": "^3.12.7", + "@typescript-eslint/eslint-plugin": "^6.10.0", + "@typescript-eslint/parser": "^6.9.1", + "tsx": "^3.14.0", "typescript": "^5.2.2" } } diff --git a/packages/contracts-bedrock/periphery-deploy-config/4460.json b/packages/contracts-bedrock/periphery-deploy-config/4460.json new file mode 100644 index 0000000000000..baa776ddd80ae --- /dev/null +++ b/packages/contracts-bedrock/periphery-deploy-config/4460.json @@ -0,0 +1,41 @@ +{ + "faucetAdmin": "0x212E789D4523D4BAF464f8Fb2A9B9dff2B36e5A6", + "faucetDrippieOwner": "0x10ab157483dd308f8B38aCF2ad823dfD255F56b5", + "faucetDripV1Value": 20000000000000000000, + "faucetDripV1Interval": 3600, + "faucetDripV1Threshold": 100000000000000000000, + "faucetDripV2Interval": 604800, + "faucetDripV2Threshold": 20000000000000000000, + "faucetDripV2Value": 500000000000000000000, + "faucetAdminDripV1Interval": 86400, + "faucetAdminDripV1Threshold": 100000000000000000, + "faucetAdminDripV1Value": 1000000000000000000, + "faucetGelatoTreasury": "0x644CB00854EDC55FE8CCC9c1967BABb22F08Ad2f", + "faucetGelatoRecipient": "0x0E9b4649eB0760A4F01646636E032D68cFDe58FF", + "faucetGelatoBalanceV1DripInterval": 86400, + "faucetGelatoBalanceV1Value": 1000000000000000000, + "faucetGelatoThreshold": 100000000000000000, + "faucetOnchainAuthModuleAdmin": "0xFe44Ae787A632c45ACea658492dDBebE39f002aC", + "faucetOnchainAuthModuleTtl": 86400, + "faucetOnchainAuthModuleAmount": 1000000000000000000, + "faucetOffchainAuthModuleAdmin": "0xFe44Ae787A632c45ACea658492dDBebE39f002aC", + "faucetOffchainAuthModuleTtl": 86400, + "faucetOffchainAuthModuleAmount": 50000000000000000, + "opL1BridgeAddress": "0xFBb0621E0B23b5478B630BD55a5f21f67730B0F1", + "baseL1BridgeAddress": "0xfd0Bf71F60660E2f608ed56e1659C450eB113120", + "pgnL1BridgeAddress": "0xFaE6abCAF30D23e233AC7faF747F2fC3a5a6Bfa3", + "zoraL1BridgeAddress": "0x5376f1D543dcbB5BD416c56C189e4cB7399fCcCB", + "orderlyL1BridgeAddress": "0x1Af0494040d6904A9F3EE21921de4b359C736333", + "modeL1BridgeAddress": "0xbC5C679879B2965296756CD959C3C739769995E2", + "lyraL1BridgeAddress": "0x915f179A77FB2e1AeA8b56Ebc0D75A7e1A8a7A17", + "installOpChainFaucetsDrips": false, + "archivePreviousOpChainFaucetsDrips": false, + "dripVersion": 1, + "previousDripVersion": 0, + "smallOpChainFaucetDripValue": 2000000000000000000, + "smallOpChainFaucetDripInterval": 86400, + "largeOpChainFaucetDripValue": 34000000000000000000, + "largeOpChainFaucetDripInterval": 86400, + "opChainAdminWalletDripValue": 1000000000000000000, + "opChainAdminWalletDripInterval": 2592000 +} diff --git a/packages/contracts-bedrock/periphery-deploy-config/58008.json b/packages/contracts-bedrock/periphery-deploy-config/58008.json new file mode 100644 index 0000000000000..baa776ddd80ae --- /dev/null +++ b/packages/contracts-bedrock/periphery-deploy-config/58008.json @@ -0,0 +1,41 @@ +{ + "faucetAdmin": "0x212E789D4523D4BAF464f8Fb2A9B9dff2B36e5A6", + "faucetDrippieOwner": "0x10ab157483dd308f8B38aCF2ad823dfD255F56b5", + "faucetDripV1Value": 20000000000000000000, + "faucetDripV1Interval": 3600, + "faucetDripV1Threshold": 100000000000000000000, + "faucetDripV2Interval": 604800, + "faucetDripV2Threshold": 20000000000000000000, + "faucetDripV2Value": 500000000000000000000, + "faucetAdminDripV1Interval": 86400, + "faucetAdminDripV1Threshold": 100000000000000000, + "faucetAdminDripV1Value": 1000000000000000000, + "faucetGelatoTreasury": "0x644CB00854EDC55FE8CCC9c1967BABb22F08Ad2f", + "faucetGelatoRecipient": "0x0E9b4649eB0760A4F01646636E032D68cFDe58FF", + "faucetGelatoBalanceV1DripInterval": 86400, + "faucetGelatoBalanceV1Value": 1000000000000000000, + "faucetGelatoThreshold": 100000000000000000, + "faucetOnchainAuthModuleAdmin": "0xFe44Ae787A632c45ACea658492dDBebE39f002aC", + "faucetOnchainAuthModuleTtl": 86400, + "faucetOnchainAuthModuleAmount": 1000000000000000000, + "faucetOffchainAuthModuleAdmin": "0xFe44Ae787A632c45ACea658492dDBebE39f002aC", + "faucetOffchainAuthModuleTtl": 86400, + "faucetOffchainAuthModuleAmount": 50000000000000000, + "opL1BridgeAddress": "0xFBb0621E0B23b5478B630BD55a5f21f67730B0F1", + "baseL1BridgeAddress": "0xfd0Bf71F60660E2f608ed56e1659C450eB113120", + "pgnL1BridgeAddress": "0xFaE6abCAF30D23e233AC7faF747F2fC3a5a6Bfa3", + "zoraL1BridgeAddress": "0x5376f1D543dcbB5BD416c56C189e4cB7399fCcCB", + "orderlyL1BridgeAddress": "0x1Af0494040d6904A9F3EE21921de4b359C736333", + "modeL1BridgeAddress": "0xbC5C679879B2965296756CD959C3C739769995E2", + "lyraL1BridgeAddress": "0x915f179A77FB2e1AeA8b56Ebc0D75A7e1A8a7A17", + "installOpChainFaucetsDrips": false, + "archivePreviousOpChainFaucetsDrips": false, + "dripVersion": 1, + "previousDripVersion": 0, + "smallOpChainFaucetDripValue": 2000000000000000000, + "smallOpChainFaucetDripInterval": 86400, + "largeOpChainFaucetDripValue": 34000000000000000000, + "largeOpChainFaucetDripInterval": 86400, + "opChainAdminWalletDripValue": 1000000000000000000, + "opChainAdminWalletDripInterval": 2592000 +} diff --git a/packages/contracts-bedrock/periphery-deploy-config/84532.json b/packages/contracts-bedrock/periphery-deploy-config/84532.json new file mode 100644 index 0000000000000..baa776ddd80ae --- /dev/null +++ b/packages/contracts-bedrock/periphery-deploy-config/84532.json @@ -0,0 +1,41 @@ +{ + "faucetAdmin": "0x212E789D4523D4BAF464f8Fb2A9B9dff2B36e5A6", + "faucetDrippieOwner": "0x10ab157483dd308f8B38aCF2ad823dfD255F56b5", + "faucetDripV1Value": 20000000000000000000, + "faucetDripV1Interval": 3600, + "faucetDripV1Threshold": 100000000000000000000, + "faucetDripV2Interval": 604800, + "faucetDripV2Threshold": 20000000000000000000, + "faucetDripV2Value": 500000000000000000000, + "faucetAdminDripV1Interval": 86400, + "faucetAdminDripV1Threshold": 100000000000000000, + "faucetAdminDripV1Value": 1000000000000000000, + "faucetGelatoTreasury": "0x644CB00854EDC55FE8CCC9c1967BABb22F08Ad2f", + "faucetGelatoRecipient": "0x0E9b4649eB0760A4F01646636E032D68cFDe58FF", + "faucetGelatoBalanceV1DripInterval": 86400, + "faucetGelatoBalanceV1Value": 1000000000000000000, + "faucetGelatoThreshold": 100000000000000000, + "faucetOnchainAuthModuleAdmin": "0xFe44Ae787A632c45ACea658492dDBebE39f002aC", + "faucetOnchainAuthModuleTtl": 86400, + "faucetOnchainAuthModuleAmount": 1000000000000000000, + "faucetOffchainAuthModuleAdmin": "0xFe44Ae787A632c45ACea658492dDBebE39f002aC", + "faucetOffchainAuthModuleTtl": 86400, + "faucetOffchainAuthModuleAmount": 50000000000000000, + "opL1BridgeAddress": "0xFBb0621E0B23b5478B630BD55a5f21f67730B0F1", + "baseL1BridgeAddress": "0xfd0Bf71F60660E2f608ed56e1659C450eB113120", + "pgnL1BridgeAddress": "0xFaE6abCAF30D23e233AC7faF747F2fC3a5a6Bfa3", + "zoraL1BridgeAddress": "0x5376f1D543dcbB5BD416c56C189e4cB7399fCcCB", + "orderlyL1BridgeAddress": "0x1Af0494040d6904A9F3EE21921de4b359C736333", + "modeL1BridgeAddress": "0xbC5C679879B2965296756CD959C3C739769995E2", + "lyraL1BridgeAddress": "0x915f179A77FB2e1AeA8b56Ebc0D75A7e1A8a7A17", + "installOpChainFaucetsDrips": false, + "archivePreviousOpChainFaucetsDrips": false, + "dripVersion": 1, + "previousDripVersion": 0, + "smallOpChainFaucetDripValue": 2000000000000000000, + "smallOpChainFaucetDripInterval": 86400, + "largeOpChainFaucetDripValue": 34000000000000000000, + "largeOpChainFaucetDripInterval": 86400, + "opChainAdminWalletDripValue": 1000000000000000000, + "opChainAdminWalletDripInterval": 2592000 +} diff --git a/packages/contracts-bedrock/periphery-deploy-config/901.json b/packages/contracts-bedrock/periphery-deploy-config/901.json new file mode 100644 index 0000000000000..baa776ddd80ae --- /dev/null +++ b/packages/contracts-bedrock/periphery-deploy-config/901.json @@ -0,0 +1,41 @@ +{ + "faucetAdmin": "0x212E789D4523D4BAF464f8Fb2A9B9dff2B36e5A6", + "faucetDrippieOwner": "0x10ab157483dd308f8B38aCF2ad823dfD255F56b5", + "faucetDripV1Value": 20000000000000000000, + "faucetDripV1Interval": 3600, + "faucetDripV1Threshold": 100000000000000000000, + "faucetDripV2Interval": 604800, + "faucetDripV2Threshold": 20000000000000000000, + "faucetDripV2Value": 500000000000000000000, + "faucetAdminDripV1Interval": 86400, + "faucetAdminDripV1Threshold": 100000000000000000, + "faucetAdminDripV1Value": 1000000000000000000, + "faucetGelatoTreasury": "0x644CB00854EDC55FE8CCC9c1967BABb22F08Ad2f", + "faucetGelatoRecipient": "0x0E9b4649eB0760A4F01646636E032D68cFDe58FF", + "faucetGelatoBalanceV1DripInterval": 86400, + "faucetGelatoBalanceV1Value": 1000000000000000000, + "faucetGelatoThreshold": 100000000000000000, + "faucetOnchainAuthModuleAdmin": "0xFe44Ae787A632c45ACea658492dDBebE39f002aC", + "faucetOnchainAuthModuleTtl": 86400, + "faucetOnchainAuthModuleAmount": 1000000000000000000, + "faucetOffchainAuthModuleAdmin": "0xFe44Ae787A632c45ACea658492dDBebE39f002aC", + "faucetOffchainAuthModuleTtl": 86400, + "faucetOffchainAuthModuleAmount": 50000000000000000, + "opL1BridgeAddress": "0xFBb0621E0B23b5478B630BD55a5f21f67730B0F1", + "baseL1BridgeAddress": "0xfd0Bf71F60660E2f608ed56e1659C450eB113120", + "pgnL1BridgeAddress": "0xFaE6abCAF30D23e233AC7faF747F2fC3a5a6Bfa3", + "zoraL1BridgeAddress": "0x5376f1D543dcbB5BD416c56C189e4cB7399fCcCB", + "orderlyL1BridgeAddress": "0x1Af0494040d6904A9F3EE21921de4b359C736333", + "modeL1BridgeAddress": "0xbC5C679879B2965296756CD959C3C739769995E2", + "lyraL1BridgeAddress": "0x915f179A77FB2e1AeA8b56Ebc0D75A7e1A8a7A17", + "installOpChainFaucetsDrips": false, + "archivePreviousOpChainFaucetsDrips": false, + "dripVersion": 1, + "previousDripVersion": 0, + "smallOpChainFaucetDripValue": 2000000000000000000, + "smallOpChainFaucetDripInterval": 86400, + "largeOpChainFaucetDripValue": 34000000000000000000, + "largeOpChainFaucetDripInterval": 86400, + "opChainAdminWalletDripValue": 1000000000000000000, + "opChainAdminWalletDripInterval": 2592000 +} diff --git a/packages/contracts-bedrock/periphery-deploy-config/919.json b/packages/contracts-bedrock/periphery-deploy-config/919.json new file mode 100644 index 0000000000000..baa776ddd80ae --- /dev/null +++ b/packages/contracts-bedrock/periphery-deploy-config/919.json @@ -0,0 +1,41 @@ +{ + "faucetAdmin": "0x212E789D4523D4BAF464f8Fb2A9B9dff2B36e5A6", + "faucetDrippieOwner": "0x10ab157483dd308f8B38aCF2ad823dfD255F56b5", + "faucetDripV1Value": 20000000000000000000, + "faucetDripV1Interval": 3600, + "faucetDripV1Threshold": 100000000000000000000, + "faucetDripV2Interval": 604800, + "faucetDripV2Threshold": 20000000000000000000, + "faucetDripV2Value": 500000000000000000000, + "faucetAdminDripV1Interval": 86400, + "faucetAdminDripV1Threshold": 100000000000000000, + "faucetAdminDripV1Value": 1000000000000000000, + "faucetGelatoTreasury": "0x644CB00854EDC55FE8CCC9c1967BABb22F08Ad2f", + "faucetGelatoRecipient": "0x0E9b4649eB0760A4F01646636E032D68cFDe58FF", + "faucetGelatoBalanceV1DripInterval": 86400, + "faucetGelatoBalanceV1Value": 1000000000000000000, + "faucetGelatoThreshold": 100000000000000000, + "faucetOnchainAuthModuleAdmin": "0xFe44Ae787A632c45ACea658492dDBebE39f002aC", + "faucetOnchainAuthModuleTtl": 86400, + "faucetOnchainAuthModuleAmount": 1000000000000000000, + "faucetOffchainAuthModuleAdmin": "0xFe44Ae787A632c45ACea658492dDBebE39f002aC", + "faucetOffchainAuthModuleTtl": 86400, + "faucetOffchainAuthModuleAmount": 50000000000000000, + "opL1BridgeAddress": "0xFBb0621E0B23b5478B630BD55a5f21f67730B0F1", + "baseL1BridgeAddress": "0xfd0Bf71F60660E2f608ed56e1659C450eB113120", + "pgnL1BridgeAddress": "0xFaE6abCAF30D23e233AC7faF747F2fC3a5a6Bfa3", + "zoraL1BridgeAddress": "0x5376f1D543dcbB5BD416c56C189e4cB7399fCcCB", + "orderlyL1BridgeAddress": "0x1Af0494040d6904A9F3EE21921de4b359C736333", + "modeL1BridgeAddress": "0xbC5C679879B2965296756CD959C3C739769995E2", + "lyraL1BridgeAddress": "0x915f179A77FB2e1AeA8b56Ebc0D75A7e1A8a7A17", + "installOpChainFaucetsDrips": false, + "archivePreviousOpChainFaucetsDrips": false, + "dripVersion": 1, + "previousDripVersion": 0, + "smallOpChainFaucetDripValue": 2000000000000000000, + "smallOpChainFaucetDripInterval": 86400, + "largeOpChainFaucetDripValue": 34000000000000000000, + "largeOpChainFaucetDripInterval": 86400, + "opChainAdminWalletDripValue": 1000000000000000000, + "opChainAdminWalletDripInterval": 2592000 +} diff --git a/packages/contracts-bedrock/periphery-deploy-config/999999999.json b/packages/contracts-bedrock/periphery-deploy-config/999999999.json new file mode 100644 index 0000000000000..baa776ddd80ae --- /dev/null +++ b/packages/contracts-bedrock/periphery-deploy-config/999999999.json @@ -0,0 +1,41 @@ +{ + "faucetAdmin": "0x212E789D4523D4BAF464f8Fb2A9B9dff2B36e5A6", + "faucetDrippieOwner": "0x10ab157483dd308f8B38aCF2ad823dfD255F56b5", + "faucetDripV1Value": 20000000000000000000, + "faucetDripV1Interval": 3600, + "faucetDripV1Threshold": 100000000000000000000, + "faucetDripV2Interval": 604800, + "faucetDripV2Threshold": 20000000000000000000, + "faucetDripV2Value": 500000000000000000000, + "faucetAdminDripV1Interval": 86400, + "faucetAdminDripV1Threshold": 100000000000000000, + "faucetAdminDripV1Value": 1000000000000000000, + "faucetGelatoTreasury": "0x644CB00854EDC55FE8CCC9c1967BABb22F08Ad2f", + "faucetGelatoRecipient": "0x0E9b4649eB0760A4F01646636E032D68cFDe58FF", + "faucetGelatoBalanceV1DripInterval": 86400, + "faucetGelatoBalanceV1Value": 1000000000000000000, + "faucetGelatoThreshold": 100000000000000000, + "faucetOnchainAuthModuleAdmin": "0xFe44Ae787A632c45ACea658492dDBebE39f002aC", + "faucetOnchainAuthModuleTtl": 86400, + "faucetOnchainAuthModuleAmount": 1000000000000000000, + "faucetOffchainAuthModuleAdmin": "0xFe44Ae787A632c45ACea658492dDBebE39f002aC", + "faucetOffchainAuthModuleTtl": 86400, + "faucetOffchainAuthModuleAmount": 50000000000000000, + "opL1BridgeAddress": "0xFBb0621E0B23b5478B630BD55a5f21f67730B0F1", + "baseL1BridgeAddress": "0xfd0Bf71F60660E2f608ed56e1659C450eB113120", + "pgnL1BridgeAddress": "0xFaE6abCAF30D23e233AC7faF747F2fC3a5a6Bfa3", + "zoraL1BridgeAddress": "0x5376f1D543dcbB5BD416c56C189e4cB7399fCcCB", + "orderlyL1BridgeAddress": "0x1Af0494040d6904A9F3EE21921de4b359C736333", + "modeL1BridgeAddress": "0xbC5C679879B2965296756CD959C3C739769995E2", + "lyraL1BridgeAddress": "0x915f179A77FB2e1AeA8b56Ebc0D75A7e1A8a7A17", + "installOpChainFaucetsDrips": false, + "archivePreviousOpChainFaucetsDrips": false, + "dripVersion": 1, + "previousDripVersion": 0, + "smallOpChainFaucetDripValue": 2000000000000000000, + "smallOpChainFaucetDripInterval": 86400, + "largeOpChainFaucetDripValue": 34000000000000000000, + "largeOpChainFaucetDripInterval": 86400, + "opChainAdminWalletDripValue": 1000000000000000000, + "opChainAdminWalletDripInterval": 2592000 +} diff --git a/packages/contracts-bedrock/periphery-deploy-config/optimism-goerli.json b/packages/contracts-bedrock/periphery-deploy-config/optimism-goerli.json index ecc0e38255af4..4ba3a39a8d13e 100644 --- a/packages/contracts-bedrock/periphery-deploy-config/optimism-goerli.json +++ b/packages/contracts-bedrock/periphery-deploy-config/optimism-goerli.json @@ -1,6 +1,6 @@ { - "faucetAdmin": "0x8F0EBDaA1cF7106bE861753B0f9F5c0250fE0819", - "faucetDrippieOwner": "0xEa193Fd9565284E7534dDDA15b07B119e7792644", + "faucetAdmin": "0x212E789D4523D4BAF464f8Fb2A9B9dff2B36e5A6", + "faucetDrippieOwner": "0x10ab157483dd308f8B38aCF2ad823dfD255F56b5", "faucetDripV1Value": 20000000000000000000, "faucetDripV1Interval": 3600, "faucetDripV1Threshold": 100000000000000000000, @@ -11,14 +11,31 @@ "faucetAdminDripV1Threshold": 100000000000000000, "faucetAdminDripV1Value": 1000000000000000000, "faucetGelatoTreasury": "0x644CB00854EDC55FE8CCC9c1967BABb22F08Ad2f", - "faucetGelatoRecipient": "0x789e58a4B08A23a7f60141959C6ABbdC0D0C4Aba", + "faucetGelatoRecipient": "0x0E9b4649eB0760A4F01646636E032D68cFDe58FF", "faucetGelatoBalanceV1DripInterval": 86400, "faucetGelatoBalanceV1Value": 1000000000000000000, "faucetGelatoThreshold": 100000000000000000, - "faucetOnchainAuthModuleAdmin": "0x8F0EBDaA1cF7106bE861753B0f9F5c0250fE0819", + "faucetOnchainAuthModuleAdmin": "0xFe44Ae787A632c45ACea658492dDBebE39f002aC", "faucetOnchainAuthModuleTtl": 86400, "faucetOnchainAuthModuleAmount": 1000000000000000000, - "faucetOffchainAuthModuleAdmin": "0x8F0EBDaA1cF7106bE861753B0f9F5c0250fE0819", + "faucetOffchainAuthModuleAdmin": "0xFe44Ae787A632c45ACea658492dDBebE39f002aC", "faucetOffchainAuthModuleTtl": 86400, - "faucetOffchainAuthModuleAmount": 50000000000000000 + "faucetOffchainAuthModuleAmount": 50000000000000000, + "opL1BridgeAddress": "0x636Af16bf2f682dD3109e60102b8E1A089FedAa8", + "baseL1BridgeAddress": "0xfd0Bf71F60660E2f608ed56e1659C450eB113120", + "pgnL1BridgeAddress": "0xFaE6abCAF30D23e233AC7faF747F2fC3a5a6Bfa3", + "zoraL1BridgeAddress": "0x5376f1D543dcbB5BD416c56C189e4cB7399fCcCB", + "orderlyL1BridgeAddress": "0x1Af0494040d6904A9F3EE21921de4b359C736333", + "modeL1BridgeAddress": "0xbC5C679879B2965296756CD959C3C739769995E2", + "lyraL1BridgeAddress": "0x915f179A77FB2e1AeA8b56Ebc0D75A7e1A8a7A17", + "installOpChainFaucetsDrips": false, + "archivePreviousOpChainFaucetsDrips": false, + "dripVersion": 1, + "previousDripVersion": 0, + "smallOpChainFaucetDripValue": 2000000000000000000, + "smallOpChainFaucetDripInterval": 86400, + "largeOpChainFaucetDripValue": 34000000000000000000, + "largeOpChainFaucetDripInterval": 86400, + "opChainAdminWalletDripValue": 1000000000000000000, + "opChainAdminWalletDripInterval": 2592000 } diff --git a/packages/contracts-bedrock/periphery-deploy-config/optimism-sepolia.json b/packages/contracts-bedrock/periphery-deploy-config/optimism-sepolia.json new file mode 100644 index 0000000000000..baa776ddd80ae --- /dev/null +++ b/packages/contracts-bedrock/periphery-deploy-config/optimism-sepolia.json @@ -0,0 +1,41 @@ +{ + "faucetAdmin": "0x212E789D4523D4BAF464f8Fb2A9B9dff2B36e5A6", + "faucetDrippieOwner": "0x10ab157483dd308f8B38aCF2ad823dfD255F56b5", + "faucetDripV1Value": 20000000000000000000, + "faucetDripV1Interval": 3600, + "faucetDripV1Threshold": 100000000000000000000, + "faucetDripV2Interval": 604800, + "faucetDripV2Threshold": 20000000000000000000, + "faucetDripV2Value": 500000000000000000000, + "faucetAdminDripV1Interval": 86400, + "faucetAdminDripV1Threshold": 100000000000000000, + "faucetAdminDripV1Value": 1000000000000000000, + "faucetGelatoTreasury": "0x644CB00854EDC55FE8CCC9c1967BABb22F08Ad2f", + "faucetGelatoRecipient": "0x0E9b4649eB0760A4F01646636E032D68cFDe58FF", + "faucetGelatoBalanceV1DripInterval": 86400, + "faucetGelatoBalanceV1Value": 1000000000000000000, + "faucetGelatoThreshold": 100000000000000000, + "faucetOnchainAuthModuleAdmin": "0xFe44Ae787A632c45ACea658492dDBebE39f002aC", + "faucetOnchainAuthModuleTtl": 86400, + "faucetOnchainAuthModuleAmount": 1000000000000000000, + "faucetOffchainAuthModuleAdmin": "0xFe44Ae787A632c45ACea658492dDBebE39f002aC", + "faucetOffchainAuthModuleTtl": 86400, + "faucetOffchainAuthModuleAmount": 50000000000000000, + "opL1BridgeAddress": "0xFBb0621E0B23b5478B630BD55a5f21f67730B0F1", + "baseL1BridgeAddress": "0xfd0Bf71F60660E2f608ed56e1659C450eB113120", + "pgnL1BridgeAddress": "0xFaE6abCAF30D23e233AC7faF747F2fC3a5a6Bfa3", + "zoraL1BridgeAddress": "0x5376f1D543dcbB5BD416c56C189e4cB7399fCcCB", + "orderlyL1BridgeAddress": "0x1Af0494040d6904A9F3EE21921de4b359C736333", + "modeL1BridgeAddress": "0xbC5C679879B2965296756CD959C3C739769995E2", + "lyraL1BridgeAddress": "0x915f179A77FB2e1AeA8b56Ebc0D75A7e1A8a7A17", + "installOpChainFaucetsDrips": false, + "archivePreviousOpChainFaucetsDrips": false, + "dripVersion": 1, + "previousDripVersion": 0, + "smallOpChainFaucetDripValue": 2000000000000000000, + "smallOpChainFaucetDripInterval": 86400, + "largeOpChainFaucetDripValue": 34000000000000000000, + "largeOpChainFaucetDripInterval": 86400, + "opChainAdminWalletDripValue": 1000000000000000000, + "opChainAdminWalletDripInterval": 2592000 +} diff --git a/packages/contracts-bedrock/periphery-deploy-config/sepolia.json b/packages/contracts-bedrock/periphery-deploy-config/sepolia.json new file mode 100644 index 0000000000000..d4c80d0104803 --- /dev/null +++ b/packages/contracts-bedrock/periphery-deploy-config/sepolia.json @@ -0,0 +1,41 @@ +{ + "faucetAdmin": "0x212E789D4523D4BAF464f8Fb2A9B9dff2B36e5A6", + "faucetDrippieOwner": "0x10ab157483dd308f8B38aCF2ad823dfD255F56b5", + "faucetDripV1Value": 20000000000000000000, + "faucetDripV1Interval": 3600, + "faucetDripV1Threshold": 100000000000000000000, + "faucetDripV2Interval": 604800, + "faucetDripV2Threshold": 20000000000000000000, + "faucetDripV2Value": 500000000000000000000, + "faucetAdminDripV1Interval": 86400, + "faucetAdminDripV1Threshold": 100000000000000000, + "faucetAdminDripV1Value": 1000000000000000000, + "faucetGelatoTreasury": "0x644CB00854EDC55FE8CCC9c1967BABb22F08Ad2f", + "faucetGelatoRecipient": "0x0E9b4649eB0760A4F01646636E032D68cFDe58FF", + "faucetGelatoBalanceV1DripInterval": 86400, + "faucetGelatoBalanceV1Value": 1000000000000000000, + "faucetGelatoThreshold": 100000000000000000, + "faucetOnchainAuthModuleAdmin": "0xFe44Ae787A632c45ACea658492dDBebE39f002aC", + "faucetOnchainAuthModuleTtl": 86400, + "faucetOnchainAuthModuleAmount": 1000000000000000000, + "faucetOffchainAuthModuleAdmin": "0xFe44Ae787A632c45ACea658492dDBebE39f002aC", + "faucetOffchainAuthModuleTtl": 86400, + "faucetOffchainAuthModuleAmount": 50000000000000000, + "opL1BridgeAddress": "0xFBb0621E0B23b5478B630BD55a5f21f67730B0F1", + "baseL1BridgeAddress": "0xfd0Bf71F60660E2f608ed56e1659C450eB113120", + "pgnL1BridgeAddress": "0xFaE6abCAF30D23e233AC7faF747F2fC3a5a6Bfa3", + "zoraL1BridgeAddress": "0x5376f1D543dcbB5BD416c56C189e4cB7399fCcCB", + "orderlyL1BridgeAddress": "0x1Af0494040d6904A9F3EE21921de4b359C736333", + "modeL1BridgeAddress": "0xbC5C679879B2965296756CD959C3C739769995E2", + "lyraL1BridgeAddress": "0x915f179A77FB2e1AeA8b56Ebc0D75A7e1A8a7A17", + "installOpChainFaucetsDrips": true, + "archivePreviousOpChainFaucetsDrips": false, + "dripVersion": 2, + "previousDripVersion": 1, + "smallOpChainFaucetDripValue": 2000000000000000000, + "smallOpChainFaucetDripInterval": 86400, + "largeOpChainFaucetDripValue": 34000000000000000000, + "largeOpChainFaucetDripInterval": 86400, + "opChainAdminWalletDripValue": 1000000000000000000, + "opChainAdminWalletDripInterval": 2592000 +} diff --git a/packages/contracts-bedrock/scripts/ChainAssertions.sol b/packages/contracts-bedrock/scripts/ChainAssertions.sol new file mode 100644 index 0000000000000..324afea5ed5ff --- /dev/null +++ b/packages/contracts-bedrock/scripts/ChainAssertions.sol @@ -0,0 +1,141 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.0; + +import { ProxyAdmin } from "src/universal/ProxyAdmin.sol"; +import { ResourceMetering } from "src/L1/ResourceMetering.sol"; +import { DeployConfig } from "scripts/DeployConfig.s.sol"; +import { SystemConfig } from "src/L1/SystemConfig.sol"; +import { Constants } from "src/libraries/Constants.sol"; +import { L1StandardBridge } from "src/L1/L1StandardBridge.sol"; +import { L2OutputOracle } from "src/L1/L2OutputOracle.sol"; +import { ProtocolVersion, ProtocolVersions } from "src/L1/ProtocolVersions.sol"; +import { OptimismPortal } from "src/L1/OptimismPortal.sol"; +import { L1CrossDomainMessenger } from "src/L1/L1CrossDomainMessenger.sol"; +import { OptimismMintableERC20Factory } from "src/universal/OptimismMintableERC20Factory.sol"; +import { L1ERC721Bridge } from "src/L1/L1ERC721Bridge.sol"; +import { Predeploys } from "src/libraries/Predeploys.sol"; +import { Types } from "scripts/Types.sol"; +import { Vm } from "forge-std/Vm.sol"; +import { ISystemConfigV0 } from "scripts/interfaces/ISystemConfigV0.sol"; + +library ChainAssertions { + /// @notice Asserts the correctness of an L1 deployment + function postDeployAssertions( + Types.ContractSet memory prox, + DeployConfig cfg, + uint256 l2OutputOracleStartingTimestamp, + Vm vm + ) + internal + view + { + ResourceMetering.ResourceConfig memory rcfg = SystemConfig(prox.SystemConfig).resourceConfig(); + ResourceMetering.ResourceConfig memory dflt = Constants.DEFAULT_RESOURCE_CONFIG(); + require(keccak256(abi.encode(rcfg)) == keccak256(abi.encode(dflt))); + + checkSystemConfig(prox, cfg); + checkL1CrossDomainMessenger(prox, vm); + checkL1StandardBridge(prox, vm); + checkL2OutputOracle(prox, cfg, l2OutputOracleStartingTimestamp); + checkOptimismMintableERC20Factory(prox); + checkL1ERC721Bridge(prox); + checkOptimismPortal(prox, cfg); + checkProtocolVersions(prox, cfg); + } + + /// @notice Asserts that the SystemConfig is setup correctly + function checkSystemConfig(Types.ContractSet memory proxies, DeployConfig cfg) internal view { + ISystemConfigV0 config = ISystemConfigV0(proxies.SystemConfig); + require(config.owner() == cfg.finalSystemOwner()); + require(config.overhead() == cfg.gasPriceOracleOverhead()); + require(config.scalar() == cfg.gasPriceOracleScalar()); + require(config.batcherHash() == bytes32(uint256(uint160(cfg.batchSenderAddress())))); + require(config.unsafeBlockSigner() == cfg.p2pSequencerAddress()); + + ResourceMetering.ResourceConfig memory rconfig = Constants.DEFAULT_RESOURCE_CONFIG(); + ResourceMetering.ResourceConfig memory resourceConfig = config.resourceConfig(); + require(resourceConfig.maxResourceLimit == rconfig.maxResourceLimit); + require(resourceConfig.elasticityMultiplier == rconfig.elasticityMultiplier); + require(resourceConfig.baseFeeMaxChangeDenominator == rconfig.baseFeeMaxChangeDenominator); + require(resourceConfig.systemTxMaxGas == rconfig.systemTxMaxGas); + require(resourceConfig.minimumBaseFee == rconfig.minimumBaseFee); + require(resourceConfig.maximumBaseFee == rconfig.maximumBaseFee); + } + + /// @notice Asserts that the L1CrossDomainMessenger is setup correctly + function checkL1CrossDomainMessenger(Types.ContractSet memory proxies, Vm vm) internal view { + L1CrossDomainMessenger messenger = L1CrossDomainMessenger(proxies.L1CrossDomainMessenger); + require(address(messenger.portal()) == proxies.OptimismPortal); + require(address(messenger.PORTAL()) == proxies.OptimismPortal); + bytes32 xdmSenderSlot = vm.load(address(messenger), bytes32(uint256(204))); + require(address(uint160(uint256(xdmSenderSlot))) == Constants.DEFAULT_L2_SENDER); + } + + /// @notice Asserts that the L1StandardBridge is setup correctly + function checkL1StandardBridge(Types.ContractSet memory proxies, Vm vm) internal view { + L1StandardBridge bridge = L1StandardBridge(payable(proxies.L1StandardBridge)); + require(address(bridge.MESSENGER()) == proxies.L1CrossDomainMessenger); + require(address(bridge.messenger()) == proxies.L1CrossDomainMessenger); + require(address(bridge.OTHER_BRIDGE()) == Predeploys.L2_STANDARD_BRIDGE); + require(address(bridge.otherBridge()) == Predeploys.L2_STANDARD_BRIDGE); + // Ensures that the legacy slot is modified correctly. This will fail + // during predeployment simulation on OP Mainnet if there is a bug. + bytes32 slot0 = vm.load(address(bridge), bytes32(uint256(0))); + require(slot0 == bytes32(uint256(Constants.INITIALIZER))); + } + + /// @notice Asserts that the L2OutputOracle is setup correctly + function checkL2OutputOracle( + Types.ContractSet memory proxies, + DeployConfig cfg, + uint256 l2OutputOracleStartingTimestamp + ) + internal + view + { + L2OutputOracle oracle = L2OutputOracle(proxies.L2OutputOracle); + require(oracle.SUBMISSION_INTERVAL() == cfg.l2OutputOracleSubmissionInterval()); + require(oracle.submissionInterval() == cfg.l2OutputOracleSubmissionInterval()); + require(oracle.L2_BLOCK_TIME() == cfg.l2BlockTime()); + require(oracle.l2BlockTime() == cfg.l2BlockTime()); + require(oracle.PROPOSER() == cfg.l2OutputOracleProposer()); + require(oracle.proposer() == cfg.l2OutputOracleProposer()); + require(oracle.CHALLENGER() == cfg.l2OutputOracleChallenger()); + require(oracle.challenger() == cfg.l2OutputOracleChallenger()); + require(oracle.FINALIZATION_PERIOD_SECONDS() == cfg.finalizationPeriodSeconds()); + require(oracle.finalizationPeriodSeconds() == cfg.finalizationPeriodSeconds()); + require(oracle.startingBlockNumber() == cfg.l2OutputOracleStartingBlockNumber()); + require(oracle.startingTimestamp() == l2OutputOracleStartingTimestamp); + } + + /// @notice Asserts that the OptimismMintableERC20Factory is setup correctly + function checkOptimismMintableERC20Factory(Types.ContractSet memory proxies) internal view { + OptimismMintableERC20Factory factory = OptimismMintableERC20Factory(proxies.OptimismMintableERC20Factory); + require(factory.BRIDGE() == proxies.L1StandardBridge); + require(factory.bridge() == proxies.L1StandardBridge); + } + + /// @notice Asserts that the L1ERC721Bridge is setup correctly + function checkL1ERC721Bridge(Types.ContractSet memory proxies) internal view { + L1ERC721Bridge bridge = L1ERC721Bridge(proxies.L1ERC721Bridge); + require(address(bridge.MESSENGER()) == proxies.L1CrossDomainMessenger); + require(bridge.OTHER_BRIDGE() == Predeploys.L2_ERC721_BRIDGE); + } + + /// @notice Asserts the OptimismPortal is setup correctly + function checkOptimismPortal(Types.ContractSet memory proxies, DeployConfig cfg) internal view { + OptimismPortal portal = OptimismPortal(payable(proxies.OptimismPortal)); + require(address(portal.L2_ORACLE()) == proxies.L2OutputOracle); + require(portal.GUARDIAN() == cfg.portalGuardian()); + require(address(portal.SYSTEM_CONFIG()) == proxies.SystemConfig); + require(portal.paused() == false); + } + + /// @notice Asserts that the ProtocolVersions is setup correctly + function checkProtocolVersions(Types.ContractSet memory proxies, DeployConfig cfg) internal view { + ProtocolVersions versions = ProtocolVersions(proxies.ProtocolVersions); + require(versions.owner() == cfg.finalSystemOwner()); + require(ProtocolVersion.unwrap(versions.required()) == cfg.requiredProtocolVersion()); + require(ProtocolVersion.unwrap(versions.recommended()) == cfg.recommendedProtocolVersion()); + } +} diff --git a/packages/contracts-bedrock/scripts/Deploy.s.sol b/packages/contracts-bedrock/scripts/Deploy.s.sol index b65ea490f6627..6e8bd39659790 100644 --- a/packages/contracts-bedrock/scripts/Deploy.s.sol +++ b/packages/contracts-bedrock/scripts/Deploy.s.sol @@ -10,8 +10,8 @@ import { Safe } from "safe-contracts/Safe.sol"; import { SafeProxyFactory } from "safe-contracts/proxies/SafeProxyFactory.sol"; import { Enum as SafeOps } from "safe-contracts/common/Enum.sol"; -import { Deployer } from "./Deployer.sol"; -import { DeployConfig } from "./DeployConfig.s.sol"; +import { Deployer } from "scripts/Deployer.sol"; +import { DeployConfig } from "scripts/DeployConfig.s.sol"; import { Safe } from "safe-contracts/Safe.sol"; import { SafeProxyFactory } from "safe-contracts/proxies/SafeProxyFactory.sol"; @@ -37,12 +37,14 @@ import { L1ERC721Bridge } from "src/L1/L1ERC721Bridge.sol"; import { ProtocolVersions, ProtocolVersion } from "src/L1/ProtocolVersions.sol"; import { StorageSetter } from "src/universal/StorageSetter.sol"; import { Predeploys } from "src/libraries/Predeploys.sol"; -import { Chains } from "./Chains.sol"; +import { Chains } from "scripts/Chains.sol"; import { IBigStepper } from "src/dispute/interfaces/IBigStepper.sol"; import { IPreimageOracle } from "src/cannon/interfaces/IPreimageOracle.sol"; -import { AlphabetVM } from "../test/FaultDisputeGame.t.sol"; +import { AlphabetVM } from "test/mocks/AlphabetVM.sol"; import "src/libraries/DisputeTypes.sol"; +import { ChainAssertions } from "scripts/ChainAssertions.sol"; +import { Types } from "scripts/Types.sol"; /// @title Deploy /// @notice Script used to deploy a bedrock system. The entire system is deployed within the `run` function. @@ -52,13 +54,12 @@ import "src/libraries/DisputeTypes.sol"; contract Deploy is Deployer { DeployConfig cfg; - /// @notice The name of the script, used to ensure the right deploy artifacts - /// are used. + /// @inheritdoc Deployer function name() public pure override returns (string memory name_) { name_ = "Deploy"; } - function setUp() public override { + function setUp() public virtual override { super.setUp(); string memory path = string.concat(vm.projectRoot(), "/deploy-config/", deploymentContext, ".json"); @@ -97,7 +98,7 @@ contract Deploy is Deployer { /// @notice The create2 salt used for deployment of the contract implementations. /// Using this helps to reduce config across networks as the implementation /// addresses will be the same across networks when deployed with create2. - function implSalt() public returns (bytes32) { + function implSalt() internal returns (bytes32) { return keccak256(bytes(vm.envOr("IMPL_SALT", string("ethers phoenix")))); } @@ -353,7 +354,7 @@ contract Deploy is Deployer { } /// @notice Deploy the ProtocolVersionsProxy - function deployProtocolVersionsProxy() public onlyTestnetOrDevnet broadcast returns (address addr_) { + function deployProtocolVersionsProxy() public broadcast returns (address addr_) { address proxyAdmin = mustGetAddress("ProxyAdmin"); Proxy proxy = new Proxy({ _admin: proxyAdmin @@ -458,7 +459,7 @@ contract Deploy is Deployer { } /// @notice Deploy the ProtocolVersions - function deployProtocolVersions() public onlyTestnetOrDevnet broadcast returns (address addr_) { + function deployProtocolVersions() public broadcast returns (address addr_) { ProtocolVersions versions = new ProtocolVersions{ salt: implSalt() }(); save("ProtocolVersions", address(versions)); console.log("ProtocolVersions deployed at %s", address(versions)); @@ -643,33 +644,7 @@ contract Deploy is Deployer { string memory version = config.version(); console.log("SystemConfig version: %s", version); - require(config.owner() == cfg.finalSystemOwner()); - require(config.overhead() == cfg.gasPriceOracleOverhead()); - require(config.scalar() == cfg.gasPriceOracleScalar()); - require(config.unsafeBlockSigner() == cfg.p2pSequencerAddress()); - require(config.batcherHash() == batcherHash); - - ResourceMetering.ResourceConfig memory rconfig = Constants.DEFAULT_RESOURCE_CONFIG(); - ResourceMetering.ResourceConfig memory resourceConfig = config.resourceConfig(); - require(resourceConfig.maxResourceLimit == rconfig.maxResourceLimit); - require(resourceConfig.elasticityMultiplier == rconfig.elasticityMultiplier); - require(resourceConfig.baseFeeMaxChangeDenominator == rconfig.baseFeeMaxChangeDenominator); - require(resourceConfig.systemTxMaxGas == rconfig.systemTxMaxGas); - require(resourceConfig.minimumBaseFee == rconfig.minimumBaseFee); - require(resourceConfig.maximumBaseFee == rconfig.maximumBaseFee); - - require(config.l1ERC721Bridge() == mustGetAddress("L1ERC721BridgeProxy")); - require(config.l1StandardBridge() == mustGetAddress("L1StandardBridgeProxy")); - require(config.l2OutputOracle() == mustGetAddress("L2OutputOracleProxy")); - require(config.optimismPortal() == mustGetAddress("OptimismPortalProxy")); - require(config.l1CrossDomainMessenger() == mustGetAddress("L1CrossDomainMessengerProxy")); - - // A non zero start block is an override - if (startBlock != 0) { - require(config.startBlock() == startBlock); - } else { - require(config.startBlock() == block.number); - } + ChainAssertions.checkSystemConfig(_proxies(), cfg); } /// @notice Initialize the L1StandardBridge @@ -699,11 +674,7 @@ contract Deploy is Deployer { string memory version = L1StandardBridge(payable(l1StandardBridgeProxy)).version(); console.log("L1StandardBridge version: %s", version); - L1StandardBridge bridge = L1StandardBridge(payable(l1StandardBridgeProxy)); - require(address(bridge.MESSENGER()) == l1CrossDomainMessengerProxy); - require(address(bridge.messenger()) == l1CrossDomainMessengerProxy); - require(address(bridge.OTHER_BRIDGE()) == Predeploys.L2_STANDARD_BRIDGE); - require(address(bridge.otherBridge()) == Predeploys.L2_STANDARD_BRIDGE); + ChainAssertions.checkL1StandardBridge(_proxies(), vm); } /// @notice Initialize the L1ERC721Bridge @@ -722,8 +693,7 @@ contract Deploy is Deployer { string memory version = bridge.version(); console.log("L1ERC721Bridge version: %s", version); - require(address(bridge.MESSENGER()) == l1CrossDomainMessengerProxy); - require(bridge.OTHER_BRIDGE() == Predeploys.L2_ERC721_BRIDGE); + ChainAssertions.checkL1ERC721Bridge(_proxies()); } /// @notice Ininitialize the OptimismMintableERC20Factory @@ -742,8 +712,7 @@ contract Deploy is Deployer { string memory version = factory.version(); console.log("OptimismMintableERC20Factory version: %s", version); - require(factory.BRIDGE() == l1StandardBridgeProxy); - require(factory.bridge() == l1StandardBridgeProxy); + ChainAssertions.checkOptimismMintableERC20Factory(_proxies()); } /// @notice initializeL1CrossDomainMessenger @@ -787,10 +756,7 @@ contract Deploy is Deployer { string memory version = messenger.version(); console.log("L1CrossDomainMessenger version: %s", version); - require(address(messenger.PORTAL()) == optimismPortalProxy); - require(address(messenger.portal()) == optimismPortalProxy); - bytes32 xdmSenderSlot = vm.load(address(messenger), bytes32(uint256(204))); - require(address(uint160(uint256(xdmSenderSlot))) == Constants.DEFAULT_L2_SENDER); + ChainAssertions.checkL1CrossDomainMessenger(_proxies(), vm); } /// @notice Initialize the L2OutputOracle @@ -816,18 +782,7 @@ contract Deploy is Deployer { string memory version = oracle.version(); console.log("L2OutputOracle version: %s", version); - require(oracle.SUBMISSION_INTERVAL() == cfg.l2OutputOracleSubmissionInterval()); - require(oracle.submissionInterval() == cfg.l2OutputOracleSubmissionInterval()); - require(oracle.L2_BLOCK_TIME() == cfg.l2BlockTime()); - require(oracle.l2BlockTime() == cfg.l2BlockTime()); - require(oracle.PROPOSER() == cfg.l2OutputOracleProposer()); - require(oracle.proposer() == cfg.l2OutputOracleProposer()); - require(oracle.CHALLENGER() == cfg.l2OutputOracleChallenger()); - require(oracle.challenger() == cfg.l2OutputOracleChallenger()); - require(oracle.FINALIZATION_PERIOD_SECONDS() == cfg.finalizationPeriodSeconds()); - require(oracle.finalizationPeriodSeconds() == cfg.finalizationPeriodSeconds()); - require(oracle.startingBlockNumber() == cfg.l2OutputOracleStartingBlockNumber()); - require(oracle.startingTimestamp() == cfg.l2OutputOracleStartingTimestamp()); + ChainAssertions.checkL2OutputOracle(_proxies(), cfg, cfg.l2OutputOracleStartingTimestamp()); } /// @notice Initialize the OptimismPortal @@ -855,13 +810,10 @@ contract Deploy is Deployer { string memory version = portal.version(); console.log("OptimismPortal version: %s", version); - require(address(portal.L2_ORACLE()) == l2OutputOracleProxy); - require(portal.GUARDIAN() == cfg.portalGuardian()); - require(address(portal.SYSTEM_CONFIG()) == systemConfigProxy); - require(portal.paused() == false); + ChainAssertions.checkOptimismPortal(_proxies(), cfg); } - function initializeProtocolVersions() public onlyTestnetOrDevnet broadcast { + function initializeProtocolVersions() public broadcast { address protocolVersionsProxy = mustGetAddress("ProtocolVersionsProxy"); address protocolVersions = mustGetAddress("ProtocolVersions"); @@ -886,9 +838,7 @@ contract Deploy is Deployer { string memory version = versions.version(); console.log("ProtocolVersions version: %s", version); - require(versions.owner() == finalSystemOwner); - require(ProtocolVersion.unwrap(versions.required()) == requiredProtocolVersion); - require(ProtocolVersion.unwrap(versions.recommended()) == recommendedProtocolVersion); + ChainAssertions.checkProtocolVersions(_proxies(), cfg); } /// @notice Transfer ownership of the ProxyAdmin contract to the final system owner @@ -1009,4 +959,18 @@ contract Deploy is Deployer { console.log("StorageSetter version: %s", version); addr_ = address(setter); } + + /// @notice Returns the proxy addresses + function _proxies() private view returns (Types.ContractSet memory proxies_) { + proxies_ = Types.ContractSet({ + L1CrossDomainMessenger: mustGetAddress("L1CrossDomainMessengerProxy"), + L1StandardBridge: mustGetAddress("L1StandardBridgeProxy"), + L2OutputOracle: mustGetAddress("L2OutputOracleProxy"), + OptimismMintableERC20Factory: mustGetAddress("OptimismMintableERC20FactoryProxy"), + OptimismPortal: mustGetAddress("OptimismPortalProxy"), + SystemConfig: mustGetAddress("SystemConfigProxy"), + L1ERC721Bridge: mustGetAddress("L1ERC721BridgeProxy"), + ProtocolVersions: mustGetAddress("ProtocolVersionsProxy") + }); + } } diff --git a/packages/contracts-bedrock/scripts/DeployConfig.s.sol b/packages/contracts-bedrock/scripts/DeployConfig.s.sol index 897dc9b3f18cc..b2b924b9cb60f 100644 --- a/packages/contracts-bedrock/scripts/DeployConfig.s.sol +++ b/packages/contracts-bedrock/scripts/DeployConfig.s.sol @@ -4,8 +4,8 @@ pragma solidity ^0.8.0; import { Script } from "forge-std/Script.sol"; import { console2 as console } from "forge-std/console2.sol"; import { stdJson } from "forge-std/StdJson.sol"; -import { Executables } from "./Executables.sol"; -import { Chains } from "./Chains.sol"; +import { Executables } from "scripts/Executables.sol"; +import { Chains } from "scripts/Chains.sol"; /// @title DeployConfig /// @notice Represents the configuration required to deploy the system. It is expected @@ -33,8 +33,11 @@ contract DeployConfig is Script { uint256 public finalizationPeriodSeconds; address public proxyAdminOwner; address public baseFeeVaultRecipient; + uint256 public baseFeeVaultMinimumWithdrawalAmount; address public l1FeeVaultRecipient; + uint256 public l1FeeVaultMinimumWithdrawalAmount; address public sequencerFeeVaultRecipient; + uint256 public sequencerFeeVaultMinimumWithdrawalAmount; string public governanceTokenName; string public governanceTokenSymbol; address public governanceTokenOwner; @@ -79,8 +82,11 @@ contract DeployConfig is Script { finalizationPeriodSeconds = stdJson.readUint(_json, "$.finalizationPeriodSeconds"); proxyAdminOwner = stdJson.readAddress(_json, "$.proxyAdminOwner"); baseFeeVaultRecipient = stdJson.readAddress(_json, "$.baseFeeVaultRecipient"); + baseFeeVaultMinimumWithdrawalAmount = stdJson.readUint(_json, "$.baseFeeVaultMinimumWithdrawalAmount"); l1FeeVaultRecipient = stdJson.readAddress(_json, "$.l1FeeVaultRecipient"); + l1FeeVaultMinimumWithdrawalAmount = stdJson.readUint(_json, "$.l1FeeVaultMinimumWithdrawalAmount"); sequencerFeeVaultRecipient = stdJson.readAddress(_json, "$.sequencerFeeVaultRecipient"); + sequencerFeeVaultMinimumWithdrawalAmount = stdJson.readUint(_json, "$.sequencerFeeVaultMinimumWithdrawalAmount"); governanceTokenName = stdJson.readString(_json, "$.governanceTokenName"); governanceTokenSymbol = stdJson.readString(_json, "$.governanceTokenSymbol"); governanceTokenOwner = stdJson.readAddress(_json, "$.governanceTokenOwner"); @@ -91,18 +97,13 @@ contract DeployConfig is Script { eip1559Denominator = stdJson.readUint(_json, "$.eip1559Denominator"); eip1559Elasticity = stdJson.readUint(_json, "$.eip1559Elasticity"); systemConfigStartBlock = stdJson.readUint(_json, "$.systemConfigStartBlock"); + requiredProtocolVersion = stdJson.readUint(_json, "$.requiredProtocolVersion"); + recommendedProtocolVersion = stdJson.readUint(_json, "$.recommendedProtocolVersion"); if (block.chainid == Chains.LocalDevnet || block.chainid == Chains.GethDevnet) { faultGameAbsolutePrestate = stdJson.readUint(_json, "$.faultGameAbsolutePrestate"); faultGameMaxDepth = stdJson.readUint(_json, "$.faultGameMaxDepth"); faultGameMaxDuration = stdJson.readUint(_json, "$.faultGameMaxDuration"); - requiredProtocolVersion = stdJson.readUint(_json, "$.requiredProtocolVersion"); - recommendedProtocolVersion = stdJson.readUint(_json, "$.recommendedProtocolVersion"); - } - - if (block.chainid == Chains.Goerli || block.chainid == Chains.Sepolia) { - requiredProtocolVersion = stdJson.readUint(_json, "$.requiredProtocolVersion"); - recommendedProtocolVersion = stdJson.readUint(_json, "$.recommendedProtocolVersion"); } } diff --git a/packages/contracts-bedrock/scripts/DeployPeriphery.s.sol b/packages/contracts-bedrock/scripts/DeployPeriphery.s.sol index 3cb7519832d52..97a75b3c6c0ca 100644 --- a/packages/contracts-bedrock/scripts/DeployPeriphery.s.sol +++ b/packages/contracts-bedrock/scripts/DeployPeriphery.s.sol @@ -12,7 +12,6 @@ import { Proxy } from "src/universal/Proxy.sol"; import { Faucet } from "src/periphery/faucet/Faucet.sol"; import { Drippie } from "src/periphery/drippie/Drippie.sol"; import { CheckGelatoLow } from "src/periphery/drippie/dripchecks/CheckGelatoLow.sol"; -import { CheckBalanceHigh } from "src/periphery/drippie/dripchecks/CheckBalanceHigh.sol"; import { CheckBalanceLow } from "src/periphery/drippie/dripchecks/CheckBalanceLow.sol"; import { CheckTrue } from "src/periphery/drippie/dripchecks/CheckTrue.sol"; import { AdminFaucetAuthModule } from "src/periphery/faucet/authmodules/AdminFaucetAuthModule.sol"; @@ -47,6 +46,14 @@ contract DeployPeriphery is Deployer { initializeFaucet(); installFaucetAuthModulesConfigs(); + + if (cfg.installOpChainFaucetsDrips()) { + installOpChainFaucetsDrippieConfigs(); + } + + if (cfg.archivePreviousOpChainFaucetsDrips()) { + archivePreviousOpChainFaucetsDrippieConfigs(); + } } /// @notice Deploy all of the proxies @@ -62,7 +69,6 @@ contract DeployPeriphery is Deployer { deployFaucetDrippie(); deployCheckTrue(); deployCheckBalanceLow(); - deployCheckBalanceHigh(); deployCheckGelatoLow(); deployOnChainAuthModule(); deployOffChainAuthModule(); @@ -199,25 +205,6 @@ contract DeployPeriphery is Deployer { } } - /// @notice Deploy CheckBalanceHigh contract. - function deployCheckBalanceHigh() public broadcast returns (address addr_) { - bytes32 salt = keccak256(bytes("CheckBalanceHigh")); - bytes32 initCodeHash = keccak256(abi.encodePacked(type(CheckBalanceHigh).creationCode)); - address preComputedAddress = computeCreate2Address(salt, initCodeHash); - if (preComputedAddress.code.length > 0) { - console.log("CheckBalanceHigh already deployed at %s", preComputedAddress); - save("CheckBalanceHigh", preComputedAddress); - addr_ = preComputedAddress; - } else { - CheckBalanceHigh checkBalanceHigh = new CheckBalanceHigh{ salt: salt }(); - - save("CheckBalanceHigh", address(checkBalanceHigh)); - console.log("CheckBalanceHigh deployed at %s", address(checkBalanceHigh)); - - addr_ = address(checkBalanceHigh); - } - } - /// @notice Deploy CheckGelatoLow contract. function deployCheckGelatoLow() public broadcast returns (address addr_) { bytes32 salt = keccak256(bytes("CheckGelatoLow")); @@ -264,6 +251,113 @@ contract DeployPeriphery is Deployer { console.log("Faucet drip configs successfully installed"); } + /// @notice installs drip configs that deposit funds to all OP Chain faucets. This function + /// should only be called on an L1 testnet. + function installOpChainFaucetsDrippieConfigs() public { + uint256 drippieOwnerPrivateKey = vm.envUint("DRIPPIE_OWNER_PRIVATE_KEY"); + vm.startBroadcast(drippieOwnerPrivateKey); + + Drippie drippie = Drippie(mustGetAddress("FaucetDrippie")); + console.log("Installing OP Chain faucet drips at %s", address(drippie)); + installSmallOpChainFaucetsDrips(); + installLargeOpChainFaucetsDrips(); + installSmallOpChainAdminWalletDrips(); + installLargeOpChainAdminWalletDrips(); + + vm.stopBroadcast(); + + console.log("OP chain faucet drip configs successfully installed"); + } + + /// @notice archives the previous OP Chain drip configs. + function archivePreviousOpChainFaucetsDrippieConfigs() public { + uint256 drippieOwnerPrivateKey = vm.envUint("DRIPPIE_OWNER_PRIVATE_KEY"); + vm.startBroadcast(drippieOwnerPrivateKey); + + Drippie drippie = Drippie(mustGetAddress("FaucetDrippie")); + console.log("Archiving OP Chain faucet drips at %s", address(drippie)); + archivePreviousSmallOpChainFaucetsDrips(); + archivePreviousLargeOpChainFaucetsDrips(); + + vm.stopBroadcast(); + + console.log("OP chain faucet drip configs successfully installed"); + } + + /// @notice installs drips that send funds to small OP chain faucets on the scheduled interval. + function installSmallOpChainFaucetsDrips() public { + address faucetProxy = mustGetAddress("FaucetProxy"); + uint256 arrayLength = cfg.getSmallFaucetsL1BridgeAddressesCount(); + for (uint256 i = 0; i < arrayLength; i++) { + address l1BridgeAddress = cfg.smallFaucetsL1BridgeAddresses(i); + _installDepositEthToDrip( + faucetProxy, + l1BridgeAddress, + cfg.smallOpChainFaucetDripValue(), + cfg.smallOpChainFaucetDripInterval(), + _faucetDripName(l1BridgeAddress, cfg.dripVersion()) + ); + } + } + + /// @notice installs drips that send funds to the admin wallets for small OP chain faucets + /// on the scheduled interval. + function installSmallOpChainAdminWalletDrips() public { + require( + cfg.faucetOnchainAuthModuleAdmin() == cfg.faucetOffchainAuthModuleAdmin(), + "installSmallOpChainAdminWalletDrips: Only handles identical admin wallet addresses" + ); + address adminWallet = cfg.faucetOnchainAuthModuleAdmin(); + uint256 arrayLength = cfg.getSmallFaucetsL1BridgeAddressesCount(); + for (uint256 i = 0; i < arrayLength; i++) { + address l1BridgeAddress = cfg.smallFaucetsL1BridgeAddresses(i); + _installDepositEthToDrip( + adminWallet, + l1BridgeAddress, + cfg.opChainAdminWalletDripValue(), + cfg.opChainAdminWalletDripInterval(), + _adminWalletDripName(l1BridgeAddress, cfg.dripVersion()) + ); + } + } + + /// @notice installs drips that send funds to the admin wallets for large OP chain faucets + /// on the scheduled interval. + function installLargeOpChainAdminWalletDrips() public { + require( + cfg.faucetOnchainAuthModuleAdmin() == cfg.faucetOffchainAuthModuleAdmin(), + "installLargeOpChainAdminWalletDrips: Only handles identical admin wallet addresses" + ); + address adminWallet = cfg.faucetOnchainAuthModuleAdmin(); + uint256 arrayLength = cfg.getLargeFaucetsL1BridgeAddressesCount(); + for (uint256 i = 0; i < arrayLength; i++) { + address l1BridgeAddress = cfg.largeFaucetsL1BridgeAddresses(i); + _installDepositEthToDrip( + adminWallet, + l1BridgeAddress, + cfg.opChainAdminWalletDripValue(), + cfg.opChainAdminWalletDripInterval(), + _adminWalletDripName(l1BridgeAddress, cfg.dripVersion()) + ); + } + } + + /// @notice installs drips that send funds to large OP chain faucets on the scheduled interval. + function installLargeOpChainFaucetsDrips() public { + address faucetProxy = mustGetAddress("FaucetProxy"); + uint256 arrayLength = cfg.getLargeFaucetsL1BridgeAddressesCount(); + for (uint256 i = 0; i < arrayLength; i++) { + address l1BridgeAddress = cfg.largeFaucetsL1BridgeAddresses(i); + _installDepositEthToDrip( + faucetProxy, + l1BridgeAddress, + cfg.largeOpChainFaucetDripValue(), + cfg.largeOpChainFaucetDripInterval(), + _faucetDripName(l1BridgeAddress, cfg.dripVersion()) + ); + } + } + /// @notice installs the FaucetDripV1 drip on the faucet drippie contract. function installFaucetDripV1() public broadcast { Drippie drippie = Drippie(mustGetAddress("FaucetDrippie")); @@ -399,12 +493,75 @@ contract DeployPeriphery is Deployer { _activateIfPausedDrip(drippie, dripName); } + function archivePreviousSmallOpChainFaucetsDrips() public { + Drippie drippie = Drippie(mustGetAddress("FaucetDrippie")); + uint256 arrayLength = cfg.getSmallFaucetsL1BridgeAddressesCount(); + for (uint256 i = 0; i < arrayLength; i++) { + address l1BridgeAddress = cfg.smallFaucetsL1BridgeAddresses(i); + _pauseIfActivatedDrip(drippie, _faucetDripName(l1BridgeAddress, cfg.previousDripVersion())); + _pauseIfActivatedDrip(drippie, _adminWalletDripName(l1BridgeAddress, cfg.previousDripVersion())); + _archiveIfPausedDrip(drippie, _faucetDripName(l1BridgeAddress, cfg.previousDripVersion())); + _archiveIfPausedDrip(drippie, _adminWalletDripName(l1BridgeAddress, cfg.previousDripVersion())); + } + } + + function archivePreviousLargeOpChainFaucetsDrips() public { + Drippie drippie = Drippie(mustGetAddress("FaucetDrippie")); + uint256 arrayLength = cfg.getLargeFaucetsL1BridgeAddressesCount(); + for (uint256 i = 0; i < arrayLength; i++) { + address l1BridgeAddress = cfg.largeFaucetsL1BridgeAddresses(i); + _pauseIfActivatedDrip(drippie, _faucetDripName(l1BridgeAddress, cfg.previousDripVersion())); + _pauseIfActivatedDrip(drippie, _adminWalletDripName(l1BridgeAddress, cfg.previousDripVersion())); + _archiveIfPausedDrip(drippie, _faucetDripName(l1BridgeAddress, cfg.previousDripVersion())); + _archiveIfPausedDrip(drippie, _adminWalletDripName(l1BridgeAddress, cfg.previousDripVersion())); + } + } + function _activateIfPausedDrip(Drippie drippie, string memory dripName) internal { + require( + drippie.getDripStatus(dripName) == Drippie.DripStatus.ACTIVE + || drippie.getDripStatus(dripName) == Drippie.DripStatus.PAUSED, + "attempting to activate a drip that is not currently paused or activated" + ); if (drippie.getDripStatus(dripName) == Drippie.DripStatus.PAUSED) { console.log("%s is paused, activating", dripName); drippie.status(dripName, Drippie.DripStatus.ACTIVE); console.log("%s activated", dripName); require(drippie.getDripStatus(dripName) == Drippie.DripStatus.ACTIVE); + } else { + console.log("%s already activated", dripName); + } + } + + function _pauseIfActivatedDrip(Drippie drippie, string memory dripName) internal { + require( + drippie.getDripStatus(dripName) == Drippie.DripStatus.ACTIVE + || drippie.getDripStatus(dripName) == Drippie.DripStatus.PAUSED, + "attempting to pause a drip that is not currently paused or activated" + ); + if (drippie.getDripStatus(dripName) == Drippie.DripStatus.ACTIVE) { + console.log("%s is active, pausing", dripName); + drippie.status(dripName, Drippie.DripStatus.PAUSED); + console.log("%s paused", dripName); + require(drippie.getDripStatus(dripName) == Drippie.DripStatus.PAUSED); + } else { + console.log("%s already paused", dripName); + } + } + + function _archiveIfPausedDrip(Drippie drippie, string memory dripName) internal { + require( + drippie.getDripStatus(dripName) == Drippie.DripStatus.PAUSED + || drippie.getDripStatus(dripName) == Drippie.DripStatus.ARCHIVED, + "attempting to archive a drip that is not currently paused or archived" + ); + if (drippie.getDripStatus(dripName) == Drippie.DripStatus.PAUSED) { + console.log("%s is paused, archiving", dripName); + drippie.status(dripName, Drippie.DripStatus.ARCHIVED); + console.log("%s archived", dripName); + require(drippie.getDripStatus(dripName) == Drippie.DripStatus.ARCHIVED); + } else { + console.log("%s already archived", dripName); } } @@ -468,7 +625,7 @@ contract DeployPeriphery is Deployer { /// @notice installs the OnChain AuthModule on the Faucet contract. function installOnChainAuthModule() public broadcast { string memory moduleName = "OnChainAuthModule"; - Faucet faucet = Faucet(mustGetAddress("Faucet")); + Faucet faucet = Faucet(mustGetAddress("FaucetProxy")); AdminFaucetAuthModule onChainAuthModule = AdminFaucetAuthModule(mustGetAddress(moduleName)); if (faucet.isModuleEnabled(onChainAuthModule)) { console.log("%s already installed.", moduleName); @@ -488,7 +645,7 @@ contract DeployPeriphery is Deployer { /// @notice installs the OffChain AuthModule on the Faucet contract. function installOffChainAuthModule() public broadcast { string memory moduleName = "OffChainAuthModule"; - Faucet faucet = Faucet(mustGetAddress("Faucet")); + Faucet faucet = Faucet(mustGetAddress("FaucetProxy")); AdminFaucetAuthModule offChainAuthModule = AdminFaucetAuthModule(mustGetAddress(moduleName)); if (faucet.isModuleEnabled(offChainAuthModule)) { console.log("%s already installed.", moduleName); @@ -507,11 +664,59 @@ contract DeployPeriphery is Deployer { /// @notice installs all of the auth module in the faucet contract. function installFaucetAuthModulesConfigs() public { - Faucet faucet = Faucet(mustGetAddress("Faucet")); + Faucet faucet = Faucet(mustGetAddress("FaucetProxy")); console.log("Installing auth modules at %s", address(faucet)); installOnChainAuthModule(); installOffChainAuthModule(); console.log("Faucet Auth Module configs successfully installed"); } + + function _faucetDripName(address _l1Bridge, uint256 version) internal pure returns (string memory) { + string memory dripNamePrefixWithBridgeAddress = string.concat("faucet-drip-", vm.toString(_l1Bridge)); + string memory versionSuffix = string.concat("-", vm.toString(version)); + return string.concat(dripNamePrefixWithBridgeAddress, versionSuffix); + } + + function _adminWalletDripName(address _l1Bridge, uint256 version) internal pure returns (string memory) { + string memory dripNamePrefixWithBridgeAddress = string.concat("faucet-admin-drip-", vm.toString(_l1Bridge)); + string memory versionSuffix = string.concat("-", vm.toString(version)); + return string.concat(dripNamePrefixWithBridgeAddress, versionSuffix); + } + + function _installDepositEthToDrip( + address _depositTo, + address _l1Bridge, + uint256 _dripValue, + uint256 _dripInterval, + string memory dripName + ) + internal + { + Drippie drippie = Drippie(mustGetAddress("FaucetDrippie")); + if (drippie.getDripStatus(dripName) == Drippie.DripStatus.NONE) { + console.log("installing %s", dripName); + Drippie.DripAction[] memory actions = new Drippie.DripAction[](1); + actions[0] = Drippie.DripAction({ + target: payable(_l1Bridge), + data: abi.encodeWithSignature("depositETHTo(address,uint32,bytes)", _depositTo, 200000, ""), + value: _dripValue + }); + drippie.create({ + _name: dripName, + _config: Drippie.DripConfig({ + reentrant: false, + interval: _dripInterval, + dripcheck: CheckTrue(mustGetAddress("CheckTrue")), + checkparams: abi.encode(""), + actions: actions + }) + }); + console.log("%s installed successfully", dripName); + } else { + console.log("%s already installed.", dripName); + } + + _activateIfPausedDrip(drippie, dripName); + } } diff --git a/packages/contracts-bedrock/scripts/Deployer.sol b/packages/contracts-bedrock/scripts/Deployer.sol index 19b719a1636c1..35c70b1b8d2d1 100644 --- a/packages/contracts-bedrock/scripts/Deployer.sol +++ b/packages/contracts-bedrock/scripts/Deployer.sol @@ -88,7 +88,10 @@ abstract contract Deployer is Script { string memory chainIdPath = string.concat(deploymentsDir, "/.chainId"); try vm.readFile(chainIdPath) returns (string memory localChainId) { if (vm.envOr("STRICT_DEPLOYMENT", true)) { - require(vm.parseUint(localChainId) == chainId, "Misconfigured networks"); + require( + vm.parseUint(localChainId) == chainId, + string.concat("Misconfigured networks: ", localChainId, " != ", vm.toString(chainId)) + ); } } catch { vm.writeFile(chainIdPath, vm.toString(chainId)); @@ -163,6 +166,8 @@ abstract contract Deployer is Script { /// @notice Returns the name of the deployment script. Children contracts /// must implement this to ensure that the deploy artifacts can be found. + /// This should be the same as the name of the script and is used as the file + /// name inside of the `broadcast` directory when looking up deployment artifacts. function name() public pure virtual returns (string memory); /// @notice Returns all of the deployments done in the current context. @@ -279,7 +284,7 @@ abstract contract Deployer is Script { } /// @notice Returns the contract name from a deploy transaction. - function _getContractNameFromDeployTransaction(string memory _deployTx) internal returns (string memory) { + function _getContractNameFromDeployTransaction(string memory _deployTx) internal pure returns (string memory) { return stdJson.readString(_deployTx, ".contractName"); } diff --git a/packages/contracts-bedrock/scripts/PeripheryDeployConfig.s.sol b/packages/contracts-bedrock/scripts/PeripheryDeployConfig.s.sol index 900d6b898950e..9da41818b3859 100644 --- a/packages/contracts-bedrock/scripts/PeripheryDeployConfig.s.sol +++ b/packages/contracts-bedrock/scripts/PeripheryDeployConfig.s.sol @@ -34,6 +34,25 @@ contract PeripheryDeployConfig is Script { address public faucetOffchainAuthModuleAdmin; uint256 public faucetOffchainAuthModuleTtl; uint256 public faucetOffchainAuthModuleAmount; + bool public installOpChainFaucetsDrips; + bool public archivePreviousOpChainFaucetsDrips; + uint256 public smallOpChainFaucetDripValue; + uint256 public smallOpChainFaucetDripInterval; + uint256 public largeOpChainFaucetDripValue; + uint256 public largeOpChainFaucetDripInterval; + uint256 public opChainAdminWalletDripValue; + uint256 public opChainAdminWalletDripInterval; + address public opL1BridgeAddress; + address public baseL1BridgeAddress; + address public zoraL1BridgeAddress; + address public pgnL1BridgeAddress; + address public orderlyL1BridgeAddress; + address public modeL1BridgeAddress; + address public lyraL1BridgeAddress; + address[5] public smallFaucetsL1BridgeAddresses; + address[2] public largeFaucetsL1BridgeAddresses; + uint256 public dripVersion; + uint256 public previousDripVersion; constructor(string memory _path) { console.log("PeripheryDeployConfig: reading file %s", _path); @@ -66,5 +85,37 @@ contract PeripheryDeployConfig is Script { faucetOffchainAuthModuleAdmin = stdJson.readAddress(_json, "$.faucetOffchainAuthModuleAdmin"); faucetOffchainAuthModuleTtl = stdJson.readUint(_json, "$.faucetOffchainAuthModuleTtl"); faucetOffchainAuthModuleAmount = stdJson.readUint(_json, "$.faucetOffchainAuthModuleAmount"); + installOpChainFaucetsDrips = stdJson.readBool(_json, "$.installOpChainFaucetsDrips"); + archivePreviousOpChainFaucetsDrips = stdJson.readBool(_json, "$.archivePreviousOpChainFaucetsDrips"); + opL1BridgeAddress = stdJson.readAddress(_json, "$.opL1BridgeAddress"); + baseL1BridgeAddress = stdJson.readAddress(_json, "$.baseL1BridgeAddress"); + zoraL1BridgeAddress = stdJson.readAddress(_json, "$.zoraL1BridgeAddress"); + pgnL1BridgeAddress = stdJson.readAddress(_json, "$.pgnL1BridgeAddress"); + orderlyL1BridgeAddress = stdJson.readAddress(_json, "$.orderlyL1BridgeAddress"); + modeL1BridgeAddress = stdJson.readAddress(_json, "$.modeL1BridgeAddress"); + lyraL1BridgeAddress = stdJson.readAddress(_json, "$.lyraL1BridgeAddress"); + dripVersion = stdJson.readUint(_json, "$.dripVersion"); + previousDripVersion = stdJson.readUint(_json, "$.previousDripVersion"); + smallOpChainFaucetDripValue = stdJson.readUint(_json, "$.smallOpChainFaucetDripValue"); + smallOpChainFaucetDripInterval = stdJson.readUint(_json, "$.smallOpChainFaucetDripInterval"); + largeOpChainFaucetDripValue = stdJson.readUint(_json, "$.largeOpChainFaucetDripValue"); + largeOpChainFaucetDripInterval = stdJson.readUint(_json, "$.largeOpChainFaucetDripInterval"); + opChainAdminWalletDripValue = stdJson.readUint(_json, "$.opChainAdminWalletDripValue"); + opChainAdminWalletDripInterval = stdJson.readUint(_json, "$.opChainAdminWalletDripInterval"); + largeFaucetsL1BridgeAddresses[0] = opL1BridgeAddress; + largeFaucetsL1BridgeAddresses[1] = baseL1BridgeAddress; + smallFaucetsL1BridgeAddresses[0] = zoraL1BridgeAddress; + smallFaucetsL1BridgeAddresses[1] = pgnL1BridgeAddress; + smallFaucetsL1BridgeAddresses[2] = orderlyL1BridgeAddress; + smallFaucetsL1BridgeAddresses[3] = modeL1BridgeAddress; + smallFaucetsL1BridgeAddresses[4] = lyraL1BridgeAddress; + } + + function getSmallFaucetsL1BridgeAddressesCount() public view returns (uint256 count) { + return smallFaucetsL1BridgeAddresses.length; + } + + function getLargeFaucetsL1BridgeAddressesCount() public view returns (uint256 count) { + return largeFaucetsL1BridgeAddresses.length; } } diff --git a/packages/contracts-bedrock/scripts/Types.sol b/packages/contracts-bedrock/scripts/Types.sol new file mode 100644 index 0000000000000..2c19f2402f341 --- /dev/null +++ b/packages/contracts-bedrock/scripts/Types.sol @@ -0,0 +1,16 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.0; + +library Types { + /// @notice Represents a set of L1 contracts. Used to represent a set of proxies. + struct ContractSet { + address L1CrossDomainMessenger; + address L1StandardBridge; + address L2OutputOracle; + address OptimismMintableERC20Factory; + address OptimismPortal; + address SystemConfig; + address L1ERC721Bridge; + address ProtocolVersions; + } +} diff --git a/packages/contracts-bedrock/scripts/check-deploy-configs.sh b/packages/contracts-bedrock/scripts/check-deploy-configs.sh index 36c5dce1aa104..3074f09675bce 100755 --- a/packages/contracts-bedrock/scripts/check-deploy-configs.sh +++ b/packages/contracts-bedrock/scripts/check-deploy-configs.sh @@ -11,11 +11,6 @@ CONTRACTS_BASE=$(dirname $SCRIPT_DIR) MONOREPO_BASE=$(dirname $(dirname $CONTRACTS_BASE)) for config in $CONTRACTS_BASE/deploy-config/*.json; do - if grep -q "getting-started" <<< "$config"; then - echo "Skipping getting-started.json" - continue - fi - go run $MONOREPO_BASE/op-chain-ops/cmd/check-deploy-config/main.go --path $config [ $? -eq 0 ] || code=$? done diff --git a/packages/contracts-bedrock/scripts/getting-started/config.sh b/packages/contracts-bedrock/scripts/getting-started/config.sh new file mode 100755 index 0000000000000..f9896a4be2b36 --- /dev/null +++ b/packages/contracts-bedrock/scripts/getting-started/config.sh @@ -0,0 +1,94 @@ +#!/usr/bin/env bash + +# This script is used to generate the getting-started.json configuration file +# used in the Getting Started quickstart guide on the docs site. Avoids the +# need to have the getting-started.json committed to the repo since it's an +# invalid JSON file when not filled in, which is annoying. + +reqenv() { + if [ -z "${!1}" ]; then + echo "Error: environment variable '$1' is undefined" + exit 1 + fi +} + +# Check required environment variables +reqenv "GS_ADMIN_ADDRESS" +reqenv "GS_BATCHER_ADDRESS" +reqenv "GS_PROPOSER_ADDRESS" +reqenv "GS_SEQUENCER_ADDRESS" +reqenv "L1_RPC_URL" + +# Get the finalized block timestamp and hash +block=$(cast block finalized --rpc-url $L1_RPC_URL) +timestamp=$(echo "$block" | awk '/timestamp/ { print $2 }') +blockhash=$(echo "$block" | awk '/hash/ { print $2 }') + +# Generate the config file +config=$(cat << EOL +{ + "finalSystemOwner": "$GS_ADMIN_ADDRESS", + "portalGuardian": "$GS_ADMIN_ADDRESS", + + "l1StartingBlockTag": "$blockhash", + + "l1ChainID": 11155111, + "l2ChainID": 42069, + "l2BlockTime": 2, + "l1BlockTime": 12, + + "maxSequencerDrift": 600, + "sequencerWindowSize": 3600, + "channelTimeout": 300, + + "p2pSequencerAddress": "$GS_SEQUENCER_ADDRESS", + "batchInboxAddress": "0xff00000000000000000000000000000000042069", + "batchSenderAddress": "$GS_BATCHER_ADDRESS", + + "l2OutputOracleSubmissionInterval": 120, + "l2OutputOracleStartingBlockNumber": 0, + "l2OutputOracleStartingTimestamp": $timestamp, + + "l2OutputOracleProposer": "$GS_PROPOSER_ADDRESS", + "l2OutputOracleChallenger": "$GS_ADMIN_ADDRESS", + + "finalizationPeriodSeconds": 12, + + "proxyAdminOwner": "$GS_ADMIN_ADDRESS", + "baseFeeVaultRecipient": "$GS_ADMIN_ADDRESS", + "l1FeeVaultRecipient": "$GS_ADMIN_ADDRESS", + "sequencerFeeVaultRecipient": "$GS_ADMIN_ADDRESS", + + "baseFeeVaultMinimumWithdrawalAmount": "0x8ac7230489e80000", + "l1FeeVaultMinimumWithdrawalAmount": "0x8ac7230489e80000", + "sequencerFeeVaultMinimumWithdrawalAmount": "0x8ac7230489e80000", + "baseFeeVaultWithdrawalNetwork": 0, + "l1FeeVaultWithdrawalNetwork": 0, + "sequencerFeeVaultWithdrawalNetwork": 0, + + "gasPriceOracleOverhead": 2100, + "gasPriceOracleScalar": 1000000, + + "enableGovernance": true, + "governanceTokenSymbol": "OP", + "governanceTokenName": "Optimism", + "governanceTokenOwner": "$GS_ADMIN_ADDRESS", + + "l2GenesisBlockGasLimit": "0x1c9c380", + "l2GenesisBlockBaseFeePerGas": "0x3b9aca00", + "l2GenesisRegolithTimeOffset": "0x0", + + "eip1559Denominator": 50, + "eip1559DenominatorCanyon": 250, + "eip1559Elasticity": 10, + + "systemConfigStartBlock": 0, + + "requiredProtocolVersion": "0x0000000000000000000000000000000000000000000000000000000000000000", + "recommendedProtocolVersion": "0x0000000000000000000000000000000000000000000000000000000000000000" +} +EOL +) + +# Write the config file +echo "$config" > deploy-config/getting-started.json diff --git a/packages/contracts-bedrock/scripts/getting-started/versions.sh b/packages/contracts-bedrock/scripts/getting-started/versions.sh new file mode 100755 index 0000000000000..ef8bfaf6a2ef6 --- /dev/null +++ b/packages/contracts-bedrock/scripts/getting-started/versions.sh @@ -0,0 +1,36 @@ +#!/usr/bin/env bash + +# This script prints out the versions of the various tools used in the Getting +# Started quickstart guide on the docs site. Simplifies things for users so +# they can easily see if they're using the right versions of everything. + +version() { + local string=$1 + local version_regex='([0-9]+(\.[0-9]+)+)' + if [[ $string =~ $version_regex ]]; then + echo "${BASH_REMATCH[1]}" + else + echo "No version found." + fi +} + +# Grab versions +ver_git=$(version "$(git --version)") +ver_go=$(version "$(go version)") +ver_node=$(version "$(node --version)") +ver_pnpm=$(version "$(pnpm --version)") +ver_foundry=$(version "$(forge --version)") +ver_make=$(version "$(make --version)") +ver_jq=$(version "$(jq --version)") +ver_direnv=$(version "$(direnv --version)") + +# Print versions +echo "Dependency | Minimum | Actual" +echo "git 2 $ver_git" +echo "go 1.21 $ver_go" +echo "node 20 $ver_node" +echo "pnpm 8 $ver_pnpm" +echo "foundry 0.2.0 $ver_foundry" +echo "make 3 $ver_make" +echo "jq 1.6 $ver_jq" +echo "direnv 2 $ver_direnv" diff --git a/packages/contracts-bedrock/scripts/getting-started/wallets.sh b/packages/contracts-bedrock/scripts/getting-started/wallets.sh new file mode 100755 index 0000000000000..4d1426d8db5be --- /dev/null +++ b/packages/contracts-bedrock/scripts/getting-started/wallets.sh @@ -0,0 +1,43 @@ +#!/usr/bin/env bash + +# This script is used to generate the four wallets that are used in the Getting +# Started quickstart guide on the docs site. Simplifies things for users +# slightly while also avoiding the need for users to manually copy/paste a +# bunch of stuff over to the environment file. + +# Generate wallets +wallet1=$(cast wallet new) +wallet2=$(cast wallet new) +wallet3=$(cast wallet new) +wallet4=$(cast wallet new) + +# Grab wallet addresses +address1=$(echo "$wallet1" | awk '/Address/ { print $2 }') +address2=$(echo "$wallet2" | awk '/Address/ { print $2 }') +address3=$(echo "$wallet3" | awk '/Address/ { print $2 }') +address4=$(echo "$wallet4" | awk '/Address/ { print $2 }') + +# Grab wallet private keys +key1=$(echo "$wallet1" | awk '/Private key/ { print $3 }') +key2=$(echo "$wallet2" | awk '/Private key/ { print $3 }') +key3=$(echo "$wallet3" | awk '/Private key/ { print $3 }') +key4=$(echo "$wallet4" | awk '/Private key/ { print $3 }') + +# Print out the environment variables to copy +echo "Copy the following into your .envrc file:" +echo +echo "# Admin account" +echo "export GS_ADMIN_ADDRESS=$address1" +echo "export GS_ADMIN_PRIVATE_KEY=$key1" +echo +echo "# Batcher account" +echo "export GS_BATCHER_ADDRESS=$address2" +echo "export GS_BATCHER_PRIVATE_KEY=$key2" +echo +echo "# Proposer account" +echo "export GS_PROPOSER_ADDRESS=$address3" +echo "export GS_PROPOSER_PRIVATE_KEY=$key3" +echo +echo "# Sequencer account" +echo "export GS_SEQUENCER_ADDRESS=$address4" +echo "export GS_SEQUENCER_PRIVATE_KEY=$key4" diff --git a/packages/contracts-bedrock/scripts/go-ffi/README.md b/packages/contracts-bedrock/scripts/go-ffi/README.md new file mode 100644 index 0000000000000..8348100fb8a3f --- /dev/null +++ b/packages/contracts-bedrock/scripts/go-ffi/README.md @@ -0,0 +1,68 @@ +# `ctb-go-ffi` + +A lightweight binary for utilities accessed via `forge`'s `ffi` cheatcode in the `contracts-bedrock` test suite. + +
+├── go-ffi
+│   ├── bin: `go-ffi`'s binary
+│   ├── trie: Utility for generating random merkle trie roots / inclusion proofs
+│   └── diff-testing: Utility for differential testing Solidity implementations against their respective Go implementations.
+
+ +## Usage + +To build, run `pnpm build:go-ffi` from this directory or the `contract-bedrock` package. + +### In a Forge Test + +To use `go-ffi` in a forge test, simply invoke the binary via the `vm.ffi` cheatcode. + +```solidity +function myFFITest() public { + string[] memory commands = new string[](3); + commands[0] = "./scripts/go-ffi/go-ffi"; + commands[1] = "trie"; + commands[2] = "valid"; + bytes memory result = vm.ffi(commands); + + // Do something with the result of the command +} +``` + +### Available Modes + +There are two modes available in `go-ffi`: `diff` and `trie`. Each are present as a subcommand to the `go-ffi` binary, with their own set of variants. + +#### `diff` + +> **Note** +> Variant required for diff mode. + +| Variant | Description | +| ------------------------------------- | -------------------------------------------------------------------------------------------------------------------- +| `decodeVersionedNonce` | Decodes a versioned nonce and prints the decoded arguments | +| `encodeCrossDomainMessage` | Encodes a cross domain message and prints the encoded message | +| `hashCrossDomainMessage` | Encodes and hashes a cross domain message and prints the digest | +| `hashDepositTransaction` | Encodes and hashes a deposit transaction and prints the digest | +| `encodeDepositTransaction` | RLP encodes a deposit transaction | +| `hashWithdrawal` | Hashes a withdrawal message and prints the digest | +| `hashOutputRootProof` | Hashes an output root proof and prints the digest | +| `getProveWithdrawalTransactionInputs` | Generates the inputs for a `getProveWithdrawalTransaction` call to the `OptimismPortal` given a withdrawal message | +| `cannonMemoryProof` | Computes a merkle proof of Cannon's memory | + +#### `trie` + +> **Note** +> Variant required for `trie` mode. + +| Variant | Description | +| ----------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------- | +| `valid` | Generate a test case with a valid proof of inclusion for the k/v pair in the trie. | +| `extra_proof_elems` | Generate an invalid test case with an extra proof element attached to an otherwise valid proof of inclusion for the passed k/v. | +| `corrupted_proof` | Generate an invalid test case where the proof is malformed. | +| `invalid_data_remainder` | Generate an invalid test case where a random element of the proof has more bytes than the length designates within the RLP list encoding. | +| `invalid_large_internal_hash` | Generate an invalid test case where a long proof element is incorrect for the root. | +| `invalid_internal_node_hash` | Generate an invalid test case where a small proof element is incorrect for the root. | +| `prefixed_valid_key` | Generate a valid test case with a key that has been given a random prefix | +| `empty_key` | Generate a valid test case with a proof of inclusion for an empty key. | +| `partial_proof` | Generate an invalid test case with a partially correct proof | diff --git a/packages/contracts-bedrock/scripts/go-ffi/bin.go b/packages/contracts-bedrock/scripts/go-ffi/bin.go new file mode 100644 index 0000000000000..da74753926230 --- /dev/null +++ b/packages/contracts-bedrock/scripts/go-ffi/bin.go @@ -0,0 +1,17 @@ +package main + +import ( + "log" + "os" +) + +func main() { + switch os.Args[1] { + case "diff": + DiffTestUtils() + case "trie": + FuzzTrie() + default: + log.Fatal("Must pass a subcommand") + } +} diff --git a/packages/contracts-bedrock/scripts/differential-testing/differential-testing.go b/packages/contracts-bedrock/scripts/go-ffi/differential-testing.go similarity index 99% rename from packages/contracts-bedrock/scripts/differential-testing/differential-testing.go rename to packages/contracts-bedrock/scripts/go-ffi/differential-testing.go index adf19dc941190..6c48d31de96a0 100644 --- a/packages/contracts-bedrock/scripts/differential-testing/differential-testing.go +++ b/packages/contracts-bedrock/scripts/go-ffi/differential-testing.go @@ -74,15 +74,16 @@ var ( } ) -func main() { - args := os.Args[1:] +func DiffTestUtils() { + args := os.Args[2:] + variant := args[0] // This command requires arguments if len(args) == 0 { panic("Error: No arguments provided") } - switch args[0] { + switch variant { case "decodeVersionedNonce": // Parse input arguments input, ok := new(big.Int).SetString(args[1], 10) diff --git a/packages/contracts-bedrock/test-case-generator/trie/trie.go b/packages/contracts-bedrock/scripts/go-ffi/trie.go similarity index 85% rename from packages/contracts-bedrock/test-case-generator/trie/trie.go rename to packages/contracts-bedrock/scripts/go-ffi/trie.go index 26b1bed0dd39e..4666816f6d7aa 100644 --- a/packages/contracts-bedrock/test-case-generator/trie/trie.go +++ b/packages/contracts-bedrock/scripts/go-ffi/trie.go @@ -1,15 +1,16 @@ -package trie +package main import ( "crypto/rand" "fmt" "log" "math/big" + "os" "github.com/ethereum/go-ethereum/accounts/abi" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common/hexutil" - "github.com/ethereum/go-ethereum/ethdb/memorydb" + "github.com/ethereum/go-ethereum/core/rawdb" "github.com/ethereum/go-ethereum/rlp" "github.com/ethereum/go-ethereum/trie" ) @@ -39,7 +40,8 @@ const ( ) // Generate an abi-encoded `trieTestCase` of a specified variant -func FuzzTrie(variant string) { +func FuzzTrie() { + variant := os.Args[2] if len(variant) < 1 { log.Fatal("Must pass a variant to the trie fuzzer!") } @@ -48,12 +50,10 @@ func FuzzTrie(variant string) { switch variant { case valid: testCase = genTrieTestCase(false) - break case extraProofElems: testCase = genTrieTestCase(false) // Duplicate the last element of the proof testCase.Proof = append(testCase.Proof, [][]byte{testCase.Proof[len(testCase.Proof)-1]}...) - break case corruptedProof: testCase = genTrieTestCase(false) @@ -61,17 +61,17 @@ func FuzzTrie(variant string) { idx := randRange(0, int64(len(testCase.Proof))) encoded, _ := rlp.EncodeToBytes(testCase.Proof[idx]) testCase.Proof[idx] = encoded - break case invalidDataRemainder: testCase = genTrieTestCase(false) // Alter true length of random proof element by appending random bytes // Do not update the encoded length idx := randRange(0, int64(len(testCase.Proof))) - bytes := make([]byte, randRange(1, 512)) - rand.Read(bytes) - testCase.Proof[idx] = append(testCase.Proof[idx], bytes...) - break + b := make([]byte, randRange(1, 512)) + if _, err := rand.Read(b); err != nil { + log.Fatal("Error generating random bytes") + } + testCase.Proof[idx] = append(testCase.Proof[idx], b...) case invalidLargeInternalHash: testCase = genTrieTestCase(false) @@ -80,7 +80,9 @@ func FuzzTrie(variant string) { // bytes to overwrite. idx := randRange(1, int64(len(testCase.Proof))) b := make([]byte, 4) - rand.Read(b) + if _, err := rand.Read(b); err != nil { + log.Fatal("Error generating random bytes") + } testCase.Proof[idx] = append( testCase.Proof[idx][:20], append( @@ -88,27 +90,26 @@ func FuzzTrie(variant string) { testCase.Proof[idx][24:]..., )..., ) - - break case invalidInternalNodeHash: testCase = genTrieTestCase(false) // Assign the last proof element to an encoded list containing a // random 29 byte value b := make([]byte, 29) - rand.Read(b) + if _, err := rand.Read(b); err != nil { + log.Fatal("Error generating random bytes") + } e, _ := rlp.EncodeToBytes(b) testCase.Proof[len(testCase.Proof)-1] = append([]byte{0xc0 + 30}, e...) - break case prefixedValidKey: testCase = genTrieTestCase(false) - bytes := make([]byte, randRange(1, 16)) - rand.Read(bytes) - testCase.Key = append(bytes, testCase.Key...) - break + b := make([]byte, randRange(1, 16)) + if _, err := rand.Read(b); err != nil { + log.Fatal("Error generating random bytes") + } + testCase.Key = append(b, testCase.Key...) case emptyKey: testCase = genTrieTestCase(true) - break case partialProof: testCase = genTrieTestCase(false) @@ -120,7 +121,6 @@ func FuzzTrie(variant string) { } testCase.Proof = newProof - break default: log.Fatal("Invalid variant passed to trie fuzzer!") } @@ -132,8 +132,8 @@ func FuzzTrie(variant string) { // Generate a random test case for Bedrock's MerkleTrie verifier. func genTrieTestCase(selectEmptyKey bool) trieTestCase { // Create an empty merkle trie - memdb := memorydb.New() - randTrie := trie.NewEmpty(trie.NewDatabase(memdb)) + memdb := rawdb.NewMemoryDatabase() + randTrie := trie.NewEmpty(trie.NewDatabase(memdb, nil)) // Get a random number of elements to put into the trie randN := randRange(2, 1024) @@ -152,8 +152,12 @@ func genTrieTestCase(selectEmptyKey bool) trieTestCase { // Add `randN` elements to the trie for i := int64(0); i < randN; i++ { // Randomize the contents of `randKey` and `randValue` - rand.Read(randKey) - rand.Read(randValue) + if _, err := rand.Read(randKey); err != nil { + log.Fatal("Error generating random bytes") + } + if _, err := rand.Read(randValue); err != nil { + log.Fatal("Error generating random bytes") + } // Clear the selected key if `selectEmptyKey` is true if i == randSelect && selectEmptyKey { @@ -161,7 +165,7 @@ func genTrieTestCase(selectEmptyKey bool) trieTestCase { } // Insert the random k/v pair into the trie - if err := randTrie.TryUpdate(randKey, randValue); err != nil { + if err := randTrie.Update(randKey, randValue); err != nil { log.Fatal("Error adding key-value pair to trie") } @@ -174,7 +178,7 @@ func genTrieTestCase(selectEmptyKey bool) trieTestCase { // Generate proof for `key`'s inclusion in our trie var proof proofList - if err := randTrie.Prove(key, 0, &proof); err != nil { + if err := randTrie.Prove(key, &proof); err != nil { log.Fatal("Error creating proof for randomly selected key's inclusion in generated trie") } @@ -233,15 +237,3 @@ func randRange(min int64, max int64) int64 { return (new(big.Int).Add(r, new(big.Int).SetInt64(min))).Int64() } - -// Custom type to write the generated proof to -type proofList [][]byte - -func (n *proofList) Put(key []byte, value []byte) error { - *n = append(*n, value) - return nil -} - -func (n *proofList) Delete(key []byte) error { - panic("not supported") -} diff --git a/packages/contracts-bedrock/scripts/differential-testing/utils.go b/packages/contracts-bedrock/scripts/go-ffi/utils.go similarity index 100% rename from packages/contracts-bedrock/scripts/differential-testing/utils.go rename to packages/contracts-bedrock/scripts/go-ffi/utils.go diff --git a/packages/contracts-bedrock/scripts/interfaces/ISystemConfigV0.sol b/packages/contracts-bedrock/scripts/interfaces/ISystemConfigV0.sol new file mode 100644 index 0000000000000..2871d76b8238c --- /dev/null +++ b/packages/contracts-bedrock/scripts/interfaces/ISystemConfigV0.sol @@ -0,0 +1,19 @@ +// SPDX-License-Identifier: MIT +pragma solidity 0.8.15; + +import { ResourceMetering } from "src/L1/ResourceMetering.sol"; + +/// @title ISystemConfigV0 +/// @notice Minimal interface of the Legacy SystemConfig containing only getters. +/// Based on +/// https://github.com/ethereum-optimism/optimism/blob/f54a2234f2f350795552011f35f704a3feb56a08/packages/contracts-bedrock/src/L1/SystemConfig.sol +interface ISystemConfigV0 { + function owner() external view returns (address); + function VERSION() external view returns (uint256); + function overhead() external view returns (uint256); + function scalar() external view returns (uint256); + function batcherHash() external view returns (bytes32); + function gasLimit() external view returns (uint64); + function resourceConfig() external view returns (ResourceMetering.ResourceConfig memory); + function unsafeBlockSigner() external view returns (address); +} diff --git a/packages/contracts-bedrock/scripts/outputs/DeleteOutput.s.sol b/packages/contracts-bedrock/scripts/outputs/DeleteOutput.s.sol deleted file mode 100644 index 2e79e88000acd..0000000000000 --- a/packages/contracts-bedrock/scripts/outputs/DeleteOutput.s.sol +++ /dev/null @@ -1,152 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity 0.8.15; - -import { console } from "forge-std/console.sol"; -import { IMulticall3 } from "forge-std/interfaces/IMulticall3.sol"; - -import { LibSort } from "../libraries/LibSort.sol"; -import { IGnosisSafe, Enum } from "../interfaces/IGnosisSafe.sol"; -import { SafeBuilder } from "../universal/SafeBuilder.sol"; - -import { Types } from "../../src/libraries/Types.sol"; -import { FeeVault } from "../../src/universal/FeeVault.sol"; -import { L2OutputOracle } from "../../src/L1/L2OutputOracle.sol"; -import { Predeploys } from "../../src/libraries/Predeploys.sol"; - -/// @title DeleteOutput -/// @notice Deletes an output root from the L2OutputOracle. -/// @notice Example usage is provided in the README documentation. -contract DeleteOutput is SafeBuilder { - /// @notice A set of contract addresses for the script. - struct ContractSet { - address Safe; - address ProxyAdmin; - address L2OutputOracleProxy; - } - - /// @notice A mapping of chainid to a ContractSet. - mapping(uint256 => ContractSet) internal _contracts; - - /// @notice The l2 output index we will delete. - uint256 internal index; - - /// @notice The address of the L2OutputOracle to target. - address internal oracle; - - /// @notice Place the contract addresses in storage for ux. - function setUp() external { - _contracts[GOERLI] = ContractSet({ - Safe: 0xBc1233d0C3e6B5d53Ab455cF65A6623F6dCd7e4f, - ProxyAdmin: 0x01d3670863c3F4b24D7b107900f0b75d4BbC6e0d, - L2OutputOracleProxy: 0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0 - }); - } - - /// @notice Returns the ContractSet for the defined block chainid. - /// @dev Reverts if no ContractSet is defined. - function contracts() public view returns (ContractSet memory) { - ContractSet memory cs = _contracts[block.chainid]; - if (cs.Safe == address(0) || cs.ProxyAdmin == address(0) || cs.L2OutputOracleProxy == address(0)) { - revert("Missing Contract Set for the given block.chainid"); - } - return cs; - } - - /// @notice Executes the gnosis safe transaction to delete an L2 Output Root. - function run(uint256 _index) external returns (bool) { - address _safe = contracts().Safe; - address _proxyAdmin = contracts().ProxyAdmin; - index = _index; - return run(_safe, _proxyAdmin); - } - - /// @notice Follow up assertions to ensure that the script ran to completion. - function _postCheck() internal view override { - L2OutputOracle l2oo = L2OutputOracle(contracts().L2OutputOracleProxy); - Types.OutputProposal memory proposal = l2oo.getL2Output(index); - require(proposal.l2BlockNumber == 0, "DeleteOutput: Output deletion failed."); - } - - /// @notice Test coverage of the script. - function test_script_succeeds() external skipWhenNotForking { - uint256 _index = getLatestIndex(); - require(_index != 0, "DeleteOutput: No outputs to delete."); - - index = _index; - - address safe = contracts().Safe; - require(safe != address(0), "DeleteOutput: Invalid safe address."); - - address proxyAdmin = contracts().ProxyAdmin; - require(proxyAdmin != address(0), "DeleteOutput: Invalid proxy admin address."); - - address[] memory owners = IGnosisSafe(payable(safe)).getOwners(); - - for (uint256 i; i < owners.length; i++) { - address owner = owners[i]; - vm.startBroadcast(owner); - bool success = _run(safe, proxyAdmin); - vm.stopBroadcast(); - - if (success) { - console.log("tx success"); - break; - } - } - - _postCheck(); - } - - function buildCalldata(address) internal view override returns (bytes memory) { - IMulticall3.Call3[] memory calls = new IMulticall3.Call3[](1); - - calls[0] = IMulticall3.Call3({ - target: oracle, - allowFailure: false, - callData: abi.encodeCall(L2OutputOracle.deleteL2Outputs, (index)) - }); - - return abi.encodeCall(IMulticall3.aggregate3, (calls)); - } - - /// @notice Computes the safe transaction hash. - function computeSafeTransactionHash(uint256 _index) public returns (bytes32) { - ContractSet memory cs = contracts(); - address _safe = cs.Safe; - address _proxyAdmin = cs.ProxyAdmin; - index = _index; - oracle = cs.L2OutputOracleProxy; - - return _getTransactionHash(_safe, _proxyAdmin); - } - - /// @notice Returns the challenger for the L2OutputOracle. - function getChallenger() public view returns (address) { - L2OutputOracle l2oo = L2OutputOracle(contracts().L2OutputOracleProxy); - return l2oo.CHALLENGER(); - } - - /// @notice Returns the L2 Block Number for the given index. - function getL2BlockNumber(uint256 _index) public view returns (uint256) { - L2OutputOracle l2oo = L2OutputOracle(contracts().L2OutputOracleProxy); - return l2oo.getL2Output(_index).l2BlockNumber; - } - - /// @notice Returns the output root for the given index. - function getOutputFromIndex(uint256 _index) public view returns (bytes32) { - L2OutputOracle l2oo = L2OutputOracle(contracts().L2OutputOracleProxy); - return l2oo.getL2Output(_index).outputRoot; - } - - /// @notice Returns the output root with the corresponding to the L2 Block Number. - function getOutputFromL2BlockNumber(uint256 l2BlockNumber) public view returns (bytes32) { - L2OutputOracle l2oo = L2OutputOracle(contracts().L2OutputOracleProxy); - return l2oo.getL2OutputAfter(l2BlockNumber).outputRoot; - } - - /// @notice Returns the latest l2 output index. - function getLatestIndex() public view returns (uint256) { - L2OutputOracle l2oo = L2OutputOracle(contracts().L2OutputOracleProxy); - return l2oo.latestOutputIndex(); - } -} diff --git a/packages/contracts-bedrock/scripts/outputs/README.md b/packages/contracts-bedrock/scripts/outputs/README.md deleted file mode 100644 index 24621bc43921b..0000000000000 --- a/packages/contracts-bedrock/scripts/outputs/README.md +++ /dev/null @@ -1,38 +0,0 @@ -## L2 Output Oracle Scripts - -A collection of scripts to interact with the L2OutputOracle. - -### Output Deletion - -[DeleteOutput](./DeleteOutput.s.sol) contains a variety of functions that deal -with deleting an output root from the [L2OutputOracle](../../contracts/L1/L2OutputOracle.sol). - -To delete an output root, the script can be run as follows, where `` is -the index of the posted output to delete. - -```bash -$ forge script scripts/output/DeleteOutput.s.sol \ - --sig "run(uint256)" \ - --rpc-url $ETH_RPC_URL \ - --broadcast \ - --private-key $PRIVATE_KEY \ - -``` - -To find and confirm the output index, there are a variety of helper functions that -can be run using the script `--sig` flag, passing the function signatures in as arguments. -These are outlined below. - -### Retrieving an L2 Block Number - -The output's associated L2 block number can be retrieved using the following command, where -`` is the index of the output in the [L2OutputOracle](../../contracts/L1/L2OutputOracle.sol). - -```bash -$ forge script scripts/output/DeleteOutput.s.sol \ - --sig "getL2BlockNumber(uint256)" \ - --rpc-url $ETH_RPC_URL \ - -``` - - diff --git a/packages/contracts-bedrock/scripts/universal/EnhancedScript.sol b/packages/contracts-bedrock/scripts/universal/EnhancedScript.sol index fea9521ef7337..065756db5b738 100644 --- a/packages/contracts-bedrock/scripts/universal/EnhancedScript.sol +++ b/packages/contracts-bedrock/scripts/universal/EnhancedScript.sol @@ -3,16 +3,16 @@ pragma solidity 0.8.15; import { console } from "forge-std/console.sol"; import { Script } from "forge-std/Script.sol"; -import { Semver } from "../../src/universal/Semver.sol"; +import { ISemver } from "../../src/universal/ISemver.sol"; /// @title EnhancedScript /// @notice Enhances forge-std' Script.sol with some additional application-specific functionality. /// Logs simulation links using Tenderly. abstract contract EnhancedScript is Script { - /// @notice Helper function used to compute the hash of Semver's version string to be used in a + /// @notice Helper function used to compute the hash of ISemver's version string to be used in a /// comparison. function _versionHash(address _addr) internal view returns (bytes32) { - return keccak256(bytes(Semver(_addr).version())); + return keccak256(bytes(ISemver(_addr).version())); } /// @notice Log a tenderly simulation link. The TENDERLY_USERNAME and TENDERLY_PROJECT diff --git a/packages/contracts-bedrock/scripts/upgrades/EASUpgrade.s.sol b/packages/contracts-bedrock/scripts/upgrades/EASUpgrade.s.sol deleted file mode 100644 index 3eb8db286721b..0000000000000 --- a/packages/contracts-bedrock/scripts/upgrades/EASUpgrade.s.sol +++ /dev/null @@ -1,130 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity ^0.8.0; - -import { console2 as console } from "forge-std/console2.sol"; -import { SafeBuilder } from "../universal/SafeBuilder.sol"; -import { IGnosisSafe, Enum } from "../interfaces/IGnosisSafe.sol"; -import { IMulticall3 } from "forge-std/interfaces/IMulticall3.sol"; -import { Predeploys } from "../../src/libraries/Predeploys.sol"; -import { ProxyAdmin } from "../../src/universal/ProxyAdmin.sol"; -import { Deployer } from "../Deployer.sol"; - -/// @title EASUpgrader -/// @notice Upgrades the EAS predeploys. -contract EASUpgrader is SafeBuilder, Deployer { - /// @notice The proxy admin predeploy on L2. - ProxyAdmin immutable PROXY_ADMIN = ProxyAdmin(Predeploys.PROXY_ADMIN); - - /// @notice Represents the EAS contracts predeploys - struct ContractSet { - address EAS; - address SchemaRegistry; - } - - /// @notice A mapping of chainid to a ContractSet of implementations. - mapping(uint256 => ContractSet) internal implementations; - - /// @notice A mapping of chainid to ContractSet of proxy addresses. - mapping(uint256 => ContractSet) internal proxies; - - /// @notice The expected versions for the contracts to be upgraded to. - string internal constant EAS_Version = "1.0.0"; - string internal constant SchemaRegistry_Version = "1.0.0"; - - /// @notice Place the contract addresses in storage so they can be used when building calldata. - function setUp() public override { - super.setUp(); - - implementations[OP_GOERLI] = - ContractSet({ EAS: getAddress("EAS"), SchemaRegistry: getAddress("SchemaRegistry") }); - - proxies[OP_GOERLI] = ContractSet({ EAS: Predeploys.EAS, SchemaRegistry: Predeploys.SCHEMA_REGISTRY }); - } - - /// @notice - function name() public pure override returns (string memory) { - return "EASUpgrader"; - } - - /// @notice Follow up assertions to ensure that the script ran to completion. - function _postCheck() internal view override { - ContractSet memory prox = getProxies(); - require(_versionHash(prox.EAS) == keccak256(bytes(EAS_Version)), "EAS"); - require(_versionHash(prox.SchemaRegistry) == keccak256(bytes(SchemaRegistry_Version)), "SchemaRegistry"); - - // Check that the codehashes of all implementations match the proxies set implementations. - ContractSet memory impl = getImplementations(); - require(PROXY_ADMIN.getProxyImplementation(prox.EAS).codehash == impl.EAS.codehash); - require(PROXY_ADMIN.getProxyImplementation(prox.SchemaRegistry).codehash == impl.SchemaRegistry.codehash); - } - - /// @notice Test coverage of the logic. Should only run on goerli but other chains - /// could be added. - function test_script_succeeds() external skipWhenNotForking { - address _safe; - address _proxyAdmin; - - if (block.chainid == OP_GOERLI) { - _safe = 0xE534ccA2753aCFbcDBCeB2291F596fc60495257e; - _proxyAdmin = 0x4200000000000000000000000000000000000018; - } - - require(_safe != address(0) && _proxyAdmin != address(0)); - - address[] memory owners = IGnosisSafe(payable(_safe)).getOwners(); - - for (uint256 i; i < owners.length; i++) { - address owner = owners[i]; - vm.startBroadcast(owner); - bool success = _run(_safe, _proxyAdmin); - vm.stopBroadcast(); - - if (success) { - console.log("tx success"); - break; - } - } - - _postCheck(); - } - - /// @notice Builds the calldata that the multisig needs to make for the upgrade to happen. - /// A total of 9 calls are made to the proxy admin to upgrade the implementations - /// of the predeploys. - function buildCalldata(address _proxyAdmin) internal view override returns (bytes memory) { - IMulticall3.Call3[] memory calls = new IMulticall3.Call3[](2); - - ContractSet memory impl = getImplementations(); - ContractSet memory prox = getProxies(); - - // Upgrade EAS - calls[0] = IMulticall3.Call3({ - target: _proxyAdmin, - allowFailure: false, - callData: abi.encodeCall(ProxyAdmin.upgrade, (payable(prox.EAS), impl.EAS)) - }); - - // Upgrade SchemaRegistry - calls[1] = IMulticall3.Call3({ - target: _proxyAdmin, - allowFailure: false, - callData: abi.encodeCall(ProxyAdmin.upgrade, (payable(prox.SchemaRegistry), impl.SchemaRegistry)) - }); - - return abi.encodeCall(IMulticall3.aggregate3, (calls)); - } - - /// @notice Returns the ContractSet that represents the implementations for a given network. - function getImplementations() internal view returns (ContractSet memory) { - ContractSet memory set = implementations[block.chainid]; - require(set.EAS != address(0), "no implementations for this network"); - return set; - } - - /// @notice Returns the ContractSet that represents the proxies for a given network. - function getProxies() internal view returns (ContractSet memory) { - ContractSet memory set = proxies[block.chainid]; - require(set.EAS != address(0), "no proxies for this network"); - return set; - } -} diff --git a/packages/contracts-bedrock/scripts/upgrades/Multichain.s.sol b/packages/contracts-bedrock/scripts/upgrades/Multichain.s.sol deleted file mode 100644 index 1afb79f4c9de6..0000000000000 --- a/packages/contracts-bedrock/scripts/upgrades/Multichain.s.sol +++ /dev/null @@ -1,492 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity 0.8.15; - -import { console } from "forge-std/console.sol"; -import { SafeBuilder } from "../universal/SafeBuilder.sol"; -import { IMulticall3 } from "forge-std/interfaces/IMulticall3.sol"; -import { IGnosisSafe, Enum } from "../interfaces/IGnosisSafe.sol"; -import { LibSort } from "../libraries/LibSort.sol"; -import { ProxyAdmin } from "src/universal/ProxyAdmin.sol"; -import { Constants } from "src/libraries/Constants.sol"; -import { SystemConfig } from "src/L1/SystemConfig.sol"; -import { ResourceMetering } from "src/L1/ResourceMetering.sol"; -import { Semver } from "src/universal/Semver.sol"; - -import { DeployConfig } from "scripts/DeployConfig.s.sol"; -import { SystemConfig } from "src/L1/SystemConfig.sol"; -import { L1StandardBridge } from "src/L1/L1StandardBridge.sol"; -import { L2OutputOracle } from "src/L1/L2OutputOracle.sol"; -import { OptimismPortal } from "src/L1/OptimismPortal.sol"; -import { L1CrossDomainMessenger } from "src/L1/L1CrossDomainMessenger.sol"; -import { OptimismMintableERC20Factory } from "src/universal/OptimismMintableERC20Factory.sol"; -import { L1ERC721Bridge } from "src/L1/L1ERC721Bridge.sol"; -import { Predeploys } from "src/libraries/Predeploys.sol"; - -/// @title Multichain -/// @notice Upgrade script for upgrading the L1 contracts after the multichain upgrade. -/// This upgrade involves all of the contracts having the same implementations. -/// The implementation addresses are known ahead of time. -/// Configure the network using the `NETWORK` env var, the options are: -/// `goerli-prod`, `chaosnet` and `devnet`. -contract Multichain is SafeBuilder { - /// @notice Address of the ProxyAdmin, passed in via constructor of `run`. - ProxyAdmin internal PROXY_ADMIN; - - /// @notice An instance of the deployconfig contract, the NETWORK env var determines - /// which file is read from disk to populate this contract. - DeployConfig internal cfg; - - /// @notice Represents a set of L1 contracts. Used to represent a set of proxies. - struct ContractSet { - address L1CrossDomainMessenger; - address L1StandardBridge; - address L2OutputOracle; - address OptimismMintableERC20Factory; - address OptimismPortal; - address SystemConfig; - address L1ERC721Bridge; - } - - /// @notice Possible value of NETWORK env var, for goerli - string internal constant GOERLI_PROD = "goerli-prod"; - /// @notice Possible value of NETWORK env var, for chaosnet - string internal constant CHAOSNET = "chaosnet"; - /// @notice Possible value of NETWORK env var, for devnet - string internal constant DEVNET = "devnet"; - /// @notice Digest of goerli-prod for comparison purposes - bytes32 internal goerli = keccak256(bytes(GOERLI_PROD)); - /// @notice Digest of chaosnet for comparison purposes - bytes32 internal chaosnet = keccak256(bytes(CHAOSNET)); - /// @notice Digest of devnet for comparison purposes - bytes32 internal devnet = keccak256(bytes(DEVNET)); - - /// @notice L1CrossDomainMessenger implementation to upgrade to - address internal constant L1CrossDomainMessengerImplementation = 0xb5df97bB67f5AA7254d40E1B7034bBFF7F183a38; - /// @notice L1StandardBridge implementation to upgrade to - address internal constant L1StandardBridgeImplementation = 0xd9aA10f75a2a93Bfc73AaDD41ae777e900CEdBc9; - /// @notice L2OutputOracle implementation to upgrade to - address internal constant L2OutputOracleImplementation = 0xaBd96C062c6B640d5670455E9d1cD98383Dd23CA; - /// @notice OptimismMintableERC20Factory to upgrade to - address internal constant OptimismMintableERC20FactoryImplementation = 0xdfe97868233d1aa22e815a266982f2cf17685a27; - /// @notice OptimismPortal implementation to upgrade to - address internal constant OptimismPortalImplementation = 0x345D27c7B6C90fef5beA9631037C36119f4bF93e; - /// @notice SystemConfig implementation to upgrade to - address internal constant SystemConfigImplementation = 0x543bA4AADBAb8f9025686Bd03993043599c6fB04; - /// @notice L1ERC721Bridge implementation to upgrade to - address internal constant L1ERC721BridgeImplementation = 0x53C115eD8D9902f4999fDBd8B93Ea79BF37cb588; - - /// @notice A mapping of deployment name to ContractSet of proxy addresses. - ContractSet internal proxies; - - /// @notice The expected versions for the contracts to be upgraded to. - string internal constant L1CrossDomainMessengerVersion = "1.5.1"; - string internal constant L1StandardBridgeVersion = "1.2.1"; - string internal constant L2OutputOracleVersion = "1.4.1"; - string internal constant OptimismMintableERC20FactoryVersion = "1.3.0"; - string internal constant OptimismPortalVersion = "1.8.1"; - string internal constant SystemConfigVersion = "1.6.0"; - string internal constant L1ERC721BridgeVersion = "1.2.1"; - - /// @notice The value of the NETWORK env var - string internal NETWORK; - // @notice Cache a non view function call to the SystemConfig contract - uint256 internal l2OutputOracleStartingTimestamp; - - /// @notice Place the contract addresses in storage so they can be used when building calldata. - function setUp() external { - // Set the network in storage - NETWORK = vm.envOr("NETWORK", GOERLI_PROD); - - // TODO: hack - PROXY_ADMIN = ProxyAdmin(vm.envOr("PROXY_ADMIN", 0x01d3670863c3F4b24D7b107900f0b75d4BbC6e0d)); - - // For simple comparisons of dynamic types - bytes32 network = keccak256(bytes(NETWORK)); - - string memory deployConfigPath; - if (network == goerli) { - console.log("Using goerli-prod"); - deployConfigPath = string.concat(vm.projectRoot(), "/deploy-config/goerli.json"); - proxies = ContractSet({ - L1CrossDomainMessenger: 0x5086d1eEF304eb5284A0f6720f79403b4e9bE294, - L1StandardBridge: 0x636Af16bf2f682dD3109e60102b8E1A089FedAa8, - L2OutputOracle: 0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0, - OptimismMintableERC20Factory: 0x883dcF8B05364083D849D8bD226bC8Cb4c42F9C5, - OptimismPortal: 0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383, - SystemConfig: 0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60, - L1ERC721Bridge: 0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9 - }); - } else if (network == chaosnet) { - console.log("Using chaosnet"); - deployConfigPath = string.concat(vm.projectRoot(), "/deploy-config/chaosnet.json"); - proxies = ContractSet({ - L1CrossDomainMessenger: 0xfc428D28D197fFf99A5EbAc6be8B761FEd8718Da, - L1StandardBridge: 0x60859421Ed85C0B11071230cf61dcEeEf54630Ff, - L2OutputOracle: 0x7D00A03f180d8C07B88d8c1384a15326c38FF9Ff, - OptimismMintableERC20Factory: 0x526920419b61153c1F80fD306B5Ab52b69110A6C, - OptimismPortal: 0x1566c8Eea4A255C07Ef58edF91431c8A73ae0B62, - SystemConfig: 0xf2Fa3621cAa534a2AE9Eb36667da57890E5C9E6a, - L1ERC721Bridge: 0x058BBf091232afE99BC2481F809254cD15e64Df5 - }); - } else if (network == devnet) { - console.log("Using devnet"); - deployConfigPath = string.concat(vm.projectRoot(), "/deploy-config/internal-devnet.json"); - proxies = ContractSet({ - L1CrossDomainMessenger: 0x71A046D793C71af209960DCb8bD5388d2c5D2a78, - L1StandardBridge: 0x791590936abB3531c9d54CD10CEC4B14415B0Ba7, - L2OutputOracle: 0xA57B9f15AA204b9D68DF58849b02Df16c80C0999, - OptimismMintableERC20Factory: 0x2998dDaF6AaA00Fa8A7104214688d29Bc749B78F, - OptimismPortal: 0x83a242F8481D4F8a605Aa82BA9D42BA574054258, - SystemConfig: 0x9673B370b773D9FFc4C282B3aF315ab05f17E20C, - L1ERC721Bridge: 0x60e0f047FfA2Fad2AF197c9CDb404bDF47277Ed4 - }); - } else { - revert("Invalid network"); - } - - cfg = new DeployConfig(deployConfigPath); - // cache the starting timestamp here as to not break the view functions below - l2OutputOracleStartingTimestamp = cfg.l2OutputOracleStartingTimestamp(); - } - - /// @notice Follow up assertions to ensure that the script ran to completion. - function _postCheck() internal view override { - ContractSet memory prox = getProxies(); - require( - _versionHash(prox.L1CrossDomainMessenger) == keccak256(bytes(L1CrossDomainMessengerVersion)), - "L1CrossDomainMessenger" - ); - require(_versionHash(prox.L1StandardBridge) == keccak256(bytes(L1StandardBridgeVersion)), "L1StandardBridge"); - require(_versionHash(prox.L2OutputOracle) == keccak256(bytes(L2OutputOracleVersion)), "L2OutputOracle"); - require( - _versionHash(prox.OptimismMintableERC20Factory) == keccak256(bytes(OptimismMintableERC20FactoryVersion)), - "OptimismMintableERC20Factory" - ); - require(_versionHash(prox.OptimismPortal) == keccak256(bytes(OptimismPortalVersion)), "OptimismPortal"); - require(_versionHash(prox.SystemConfig) == keccak256(bytes(SystemConfigVersion)), "SystemConfig"); - require(_versionHash(prox.L1ERC721Bridge) == keccak256(bytes(L1ERC721BridgeVersion)), "L1ERC721Bridge"); - - ResourceMetering.ResourceConfig memory rcfg = SystemConfig(prox.SystemConfig).resourceConfig(); - ResourceMetering.ResourceConfig memory dflt = Constants.DEFAULT_RESOURCE_CONFIG(); - require(keccak256(abi.encode(rcfg)) == keccak256(abi.encode(dflt))); - - // Check that the codehashes of all implementations match the proxies set implementations. - require( - PROXY_ADMIN.getProxyImplementation(prox.L1CrossDomainMessenger).codehash - == L1CrossDomainMessengerImplementation.codehash, - "L1CrossDomainMessenger codehash" - ); - require( - PROXY_ADMIN.getProxyImplementation(prox.L1StandardBridge).codehash - == L1StandardBridgeImplementation.codehash, - "L1StandardBridge codehash" - ); - require( - PROXY_ADMIN.getProxyImplementation(prox.L2OutputOracle).codehash == L2OutputOracleImplementation.codehash, - "L2OutputOracle codehash" - ); - require( - PROXY_ADMIN.getProxyImplementation(prox.OptimismMintableERC20Factory).codehash - == OptimismMintableERC20FactoryImplementation.codehash, - "OptimismMintableERC20Factory codehash" - ); - require( - PROXY_ADMIN.getProxyImplementation(prox.OptimismPortal).codehash == OptimismPortalImplementation.codehash, - "OptimismPortal codehash" - ); - require( - PROXY_ADMIN.getProxyImplementation(prox.SystemConfig).codehash == SystemConfigImplementation.codehash, - "SystemConfig codehash" - ); - require( - PROXY_ADMIN.getProxyImplementation(prox.L1ERC721Bridge).codehash == L1ERC721BridgeImplementation.codehash, - "L1ERC721Bridge codehash" - ); - - _postCheckSystemConfig(); - _postCheckL1CrossDomainMessenger(); - _postCheckL1StandardBridge(); - _postCheckL2OutputOracle(); - _postCheckOptimismMintableERC20Factory(); - _postCheckL1ERC721Bridge(); - _postCheckOptimismPortal(); - } - - /// @notice Post check hook for the system config - function _postCheckSystemConfig() internal view { - SystemConfig config = SystemConfig(proxies.SystemConfig); - - require(config.owner() == cfg.finalSystemOwner()); - require(config.overhead() == cfg.gasPriceOracleOverhead()); - require(config.scalar() == cfg.gasPriceOracleScalar()); - require(config.unsafeBlockSigner() == cfg.p2pSequencerAddress()); - require(config.batcherHash() == bytes32(uint256(uint160(cfg.batchSenderAddress())))); - - ResourceMetering.ResourceConfig memory rconfig = Constants.DEFAULT_RESOURCE_CONFIG(); - ResourceMetering.ResourceConfig memory resourceConfig = config.resourceConfig(); - require(resourceConfig.maxResourceLimit == rconfig.maxResourceLimit); - require(resourceConfig.elasticityMultiplier == rconfig.elasticityMultiplier); - require(resourceConfig.baseFeeMaxChangeDenominator == rconfig.baseFeeMaxChangeDenominator); - require(resourceConfig.systemTxMaxGas == rconfig.systemTxMaxGas); - require(resourceConfig.minimumBaseFee == rconfig.minimumBaseFee); - require(resourceConfig.maximumBaseFee == rconfig.maximumBaseFee); - - require(config.l1ERC721Bridge() == proxies.L1ERC721Bridge); - require(config.l1StandardBridge() == proxies.L1StandardBridge); - require(config.l2OutputOracle() == proxies.L2OutputOracle); - require(config.optimismPortal() == proxies.OptimismPortal); - require(config.l1CrossDomainMessenger() == proxies.L1CrossDomainMessenger); - - // A non zero start block is an override - uint256 startBlock = cfg.systemConfigStartBlock(); - if (startBlock != 0) { - require(config.startBlock() == startBlock); - } else { - require(config.startBlock() == block.number); - } - } - - /// @notice Post check hook for the L1CrossDomainMessenger - function _postCheckL1CrossDomainMessenger() internal view { - L1CrossDomainMessenger messenger = L1CrossDomainMessenger(proxies.L1CrossDomainMessenger); - require(address(messenger.portal()) == proxies.OptimismPortal); - } - - /// @notice Post check hook for the L1StandardBridge - function _postCheckL1StandardBridge() internal view { - L1StandardBridge bridge = L1StandardBridge(payable(proxies.L1StandardBridge)); - require(address(bridge.MESSENGER()) == proxies.L1CrossDomainMessenger); - require(address(bridge.messenger()) == proxies.L1CrossDomainMessenger); - require(address(bridge.OTHER_BRIDGE()) == Predeploys.L2_STANDARD_BRIDGE); - require(address(bridge.otherBridge()) == Predeploys.L2_STANDARD_BRIDGE); - // Ensures that the legacy slot is modified correctly. This will fail - // during predeployment simulation on OP Mainnet if there is a bug. - bytes32 slot0 = vm.load(address(bridge), bytes32(uint256(0))); - require(slot0 == bytes32(uint256(2))); - } - - /// @notice Post check hook for the L2OutputOracle - function _postCheckL2OutputOracle() internal view { - L2OutputOracle oracle = L2OutputOracle(proxies.L2OutputOracle); - require(oracle.SUBMISSION_INTERVAL() == cfg.l2OutputOracleSubmissionInterval()); - require(oracle.submissionInterval() == cfg.l2OutputOracleSubmissionInterval()); - require(oracle.L2_BLOCK_TIME() == cfg.l2BlockTime()); - require(oracle.l2BlockTime() == cfg.l2BlockTime()); - require(oracle.PROPOSER() == cfg.l2OutputOracleProposer()); - require(oracle.proposer() == cfg.l2OutputOracleProposer()); - require(oracle.CHALLENGER() == cfg.l2OutputOracleChallenger()); - require(oracle.challenger() == cfg.l2OutputOracleChallenger()); - require(oracle.FINALIZATION_PERIOD_SECONDS() == cfg.finalizationPeriodSeconds()); - require(oracle.finalizationPeriodSeconds() == cfg.finalizationPeriodSeconds()); - require(oracle.startingBlockNumber() == cfg.l2OutputOracleStartingBlockNumber()); - require(oracle.startingTimestamp() == l2OutputOracleStartingTimestamp); - } - - /// @notice Post check hook for the OptimismMintableERC20Factory - function _postCheckOptimismMintableERC20Factory() internal view { - OptimismMintableERC20Factory factory = OptimismMintableERC20Factory(proxies.OptimismMintableERC20Factory); - require(factory.BRIDGE() == proxies.L1StandardBridge); - } - - /// @notice Post check hook for the L1ERC721Bridge - function _postCheckL1ERC721Bridge() internal view { - L1ERC721Bridge bridge = L1ERC721Bridge(proxies.L1ERC721Bridge); - require(address(bridge.MESSENGER()) == proxies.L1CrossDomainMessenger); - require(bridge.OTHER_BRIDGE() == Predeploys.L2_ERC721_BRIDGE); - } - - /// @notice Post check hook for the OptimismPortal - function _postCheckOptimismPortal() internal view { - OptimismPortal portal = OptimismPortal(payable(proxies.OptimismPortal)); - require(address(portal.L2_ORACLE()) == proxies.L2OutputOracle); - require(portal.GUARDIAN() == cfg.portalGuardian()); - require(address(portal.SYSTEM_CONFIG()) == proxies.SystemConfig); - require(portal.paused() == false); - } - - /// @notice Test coverage of the logic. Should only run on goerli but other chains - /// could be added. - function test_script_succeeds() external skipWhenNotForking { - address _safe; - address _proxyAdmin; - - if (block.chainid == GOERLI) { - _safe = 0xBc1233d0C3e6B5d53Ab455cF65A6623F6dCd7e4f; - _proxyAdmin = 0x01d3670863c3F4b24D7b107900f0b75d4BbC6e0d; - // Set the proxy admin for the `_postCheck` function - PROXY_ADMIN = ProxyAdmin(_proxyAdmin); - } - - require(_safe != address(0) && _proxyAdmin != address(0)); - - address[] memory owners = IGnosisSafe(payable(_safe)).getOwners(); - for (uint256 i; i < owners.length; i++) { - address owner = owners[i]; - vm.startBroadcast(owner); - bool success = _run(_safe, _proxyAdmin); - vm.stopBroadcast(); - - if (success) { - console.log("tx success"); - break; - } - } - - _postCheck(); - } - - /// @notice Builds the calldata that the multisig needs to make for the upgrade to happen. - /// A total of 8 calls are made, 7 upgrade implementations and 1 sets the resource - /// config to the default value in the SystemConfig contract. - function buildCalldata(address _proxyAdmin) internal view override returns (bytes memory) { - IMulticall3.Call3[] memory calls = new IMulticall3.Call3[](7); - - ContractSet memory prox = getProxies(); - - // Upgrade the L1CrossDomainMessenger - calls[0] = IMulticall3.Call3({ - target: _proxyAdmin, - allowFailure: false, - callData: abi.encodeCall( - ProxyAdmin.upgradeAndCall, - ( - payable(prox.L1CrossDomainMessenger), // proxy - L1CrossDomainMessengerImplementation, // implementation - abi.encodeCall( // data - L1CrossDomainMessenger.initialize, (OptimismPortal(payable(prox.OptimismPortal)))) - ) - ) - }); - - // Upgrade the L1StandardBridge - calls[1] = IMulticall3.Call3({ - target: _proxyAdmin, - allowFailure: false, - callData: abi.encodeCall( - ProxyAdmin.upgradeAndCall, - ( - payable(prox.L1StandardBridge), // proxy - L1StandardBridgeImplementation, // implementation - abi.encodeCall(L1StandardBridge.initialize, (L1CrossDomainMessenger(prox.L1CrossDomainMessenger))) // data - ) - ) - }); - - // Upgrade the L2OutputOracle - calls[2] = IMulticall3.Call3({ - target: _proxyAdmin, - allowFailure: false, - callData: abi.encodeCall( - ProxyAdmin.upgradeAndCall, - ( - payable(prox.L2OutputOracle), // proxy - L2OutputOracleImplementation, // implementation - abi.encodeCall( // data - L2OutputOracle.initialize, - ( - cfg.l2OutputOracleStartingBlockNumber(), - l2OutputOracleStartingTimestamp, - cfg.l2OutputOracleProposer(), - cfg.l2OutputOracleChallenger() - ) - ) - ) - ) - }); - - // Upgrade the OptimismMintableERC20Factory. No initialize function. - calls[3] = IMulticall3.Call3({ - target: _proxyAdmin, - allowFailure: false, - callData: abi.encodeCall( - ProxyAdmin.upgradeAndCall, - ( - payable(prox.OptimismMintableERC20Factory), // proxy - OptimismMintableERC20FactoryImplementation, // implementation - abi.encodeCall( // data - OptimismMintableERC20Factory.initialize, (prox.L1StandardBridge)) - ) - ) - }); - - // Upgrade the OptimismPortal - calls[4] = IMulticall3.Call3({ - target: _proxyAdmin, - allowFailure: false, - callData: abi.encodeCall( - ProxyAdmin.upgradeAndCall, - ( - payable(prox.OptimismPortal), // proxy - OptimismPortalImplementation, // implementation - abi.encodeCall( // data - OptimismPortal.initialize, - ( - L2OutputOracle(prox.L2OutputOracle), - cfg.portalGuardian(), - SystemConfig(prox.SystemConfig), - false - ) - ) - ) - ) - }); - - // Upgrade the SystemConfig - calls[5] = IMulticall3.Call3({ - target: _proxyAdmin, - allowFailure: false, - callData: abi.encodeCall( - ProxyAdmin.upgradeAndCall, - ( - payable(prox.SystemConfig), // proxy - SystemConfigImplementation, // implementation - abi.encodeCall( // data - SystemConfig.initialize, - ( - cfg.finalSystemOwner(), - cfg.gasPriceOracleOverhead(), - cfg.gasPriceOracleScalar(), - bytes32(uint256(uint160(cfg.batchSenderAddress()))), - uint64(cfg.l2GenesisBlockGasLimit()), - cfg.p2pSequencerAddress(), - Constants.DEFAULT_RESOURCE_CONFIG(), - cfg.systemConfigStartBlock(), - cfg.batchInboxAddress(), - SystemConfig.Addresses({ - l1CrossDomainMessenger: prox.L1CrossDomainMessenger, - l1ERC721Bridge: prox.L1ERC721Bridge, - l1StandardBridge: prox.L1StandardBridge, - l2OutputOracle: prox.L2OutputOracle, - optimismPortal: prox.OptimismPortal, - optimismMintableERC20Factory: prox.OptimismMintableERC20Factory - }) - ) - ) - ) - ) - }); - - // Upgrade the L1ERC721Bridge - calls[6] = IMulticall3.Call3({ - target: _proxyAdmin, - allowFailure: false, - callData: abi.encodeCall( - ProxyAdmin.upgradeAndCall, - ( - payable(prox.L1ERC721Bridge), - L1ERC721BridgeImplementation, - abi.encodeCall(L1ERC721Bridge.initialize, (L1CrossDomainMessenger(prox.L1CrossDomainMessenger))) - ) - ) - }); - - return abi.encodeCall(IMulticall3.aggregate3, (calls)); - } - - /// @notice Returns the ContractSet that represents the proxies for a given network. - /// Configure the network with the NETWORK env var. - function getProxies() internal view returns (ContractSet memory) { - require(proxies.L1CrossDomainMessenger != address(0), "no proxies for this network"); - return proxies; - } -} diff --git a/packages/contracts-bedrock/semver-lock.json b/packages/contracts-bedrock/semver-lock.json index 4095a79176b56..5fc7af5025900 100644 --- a/packages/contracts-bedrock/semver-lock.json +++ b/packages/contracts-bedrock/semver-lock.json @@ -1,36 +1,38 @@ { - "src/EAS/EAS.sol": "0xea04b7a9ec170ce9cbd466ede87650f9e9ffe3d725d7951cef5777a98a840173", + "src/EAS/EAS.sol": "0x850a0eb089d5a01f489c7239f5b9a1b09120afb1bc80239268215c2dfe1de26c", "src/EAS/SchemaRegistry.sol": "0x5ee1a0c3b2bf1eb5edb53fb0967cf13856be546f0f16fe7acdc3e4f286db6831", "src/L1/DelayedVetoable.sol": "0x276c6276292095e6aa37a70008cf4e0d1cbcc020dbc9107459bbc72ab5ed744f", - "src/L1/L1CrossDomainMessenger.sol": "0x314a831b10500182a932ca6a8c34939ba45b6844e78a656c46790641e5811a66", - "src/L1/L1ERC721Bridge.sol": "0x679dc0ab891843253bab269a09218bd2706984cae0f52c0f25789c0797096308", - "src/L1/L1StandardBridge.sol": "0x22f77bfdf75e71bb92e38a58ce181131d4ffbdd930e4af8691dc0406735df8d0", + "src/L1/L1CrossDomainMessenger.sol": "0x2aa4e06827bc48484212eb2bdc30fd604ffd23b37e401b78ef428c12fa9b8385", + "src/L1/L1ERC721Bridge.sol": "0x18219b763fcff3caf54c9fc590ada9e1e2ead50bce1f68f232d444b27ad0fb23", + "src/L1/L1StandardBridge.sol": "0xdf268cf35ddb89c4c820bd19e13eb43e91c837e0d10fea704cb4d5676baa6e8f", "src/L1/L2OutputOracle.sol": "0x1cfa6e41f3449896d2b0f5fba85d759acefe7012d6bffbcdf0bba883a78b50ee", "src/L1/OptimismPortal.sol": "0xc4753409d6aca7f7b8a48b9a8ac9542a5c5e0b7e7cb71ca3b6b35dd714806c73", "src/L1/ProtocolVersions.sol": "0xfc92dfc0e4518470c48c74fa9c5b15347da2a791273afd1968ac3eada7c45dd6", "src/L1/SystemConfig.sol": "0x9b1c9225283d4944ad722d11d5650a0d84809156cfb1bcab8a7288bc3e5f247f", - "src/L2/BaseFeeVault.sol": "0xc347c1aebe69178e72d2b1d3e700bbf84e39975319465bb85d69fd0d60fc1759", + "src/L2/BaseFeeVault.sol": "0xe36f9be65c910694e60a14f266f9b6569f01b4ddd74fa0557305eb83e7e9d112", "src/L2/GasPriceOracle.sol": "0x88efffbd40f8d012d700a5d7fde0d92266f65e9d7006cd8f034bacaa036d0eb2", "src/L2/L1Block.sol": "0x1ed9aa36036ded00a0383692eca81a22f668d64e22af973559d2ccefc86825c0", - "src/L2/L1FeeVault.sol": "0x90b264176d02c9ac423a8279b3d64817c7927ee9b6faf81776a49fad34407250", - "src/L2/L2CrossDomainMessenger.sol": "0x95779726c0a912e4367396577cc32c19b2e94c22bb42c35a461653e00de17ea4", - "src/L2/L2ERC721Bridge.sol": "0x2c91c9ab2e97761f3b52a4d78882473c505b9f5b8b83df703faccee412b6d752", - "src/L2/L2StandardBridge.sol": "0xfe01bcb1ddc947b9b8a7093d0971854b9fa8d49da5bd933a3dd106167907f882", + "src/L2/L1FeeVault.sol": "0x6a7a9a262c0a4c9781d812ea343f984944a8dd2b45bc1967dfcc3805c0053518", + "src/L2/L2CrossDomainMessenger.sol": "0x8fe4a79b3e8dd4d53dcd437c1731503beec744836273c114960f1a60ff38a930", + "src/L2/L2ERC721Bridge.sol": "0xdbe75ee8c8163ed5164cc6b293e422c718303b46a8df91e832fa9e5c6a023fb6", + "src/L2/L2StandardBridge.sol": "0x284ebf5569c75d98f2d1920a276d1116524399355708c4a60ea5892283c56719", "src/L2/L2ToL1MessagePasser.sol": "0xafc710b4d320ef450586d96a61cbd58cac814cb3b0c4fdc280eace3efdcdf321", - "src/L2/SequencerFeeVault.sol": "0xc2f733c1128d06ad60bf1e1d98c8f684a4825b11875ccdf2376ede33f5aad4e6", + "src/L2/SequencerFeeVault.sol": "0x883e434a69b4789997a4a9a32060dbbd2e12db6f1970927f1310820336119575", + "src/Safe/LivenessGuard.sol": "0xa08460138c22a337f8f5d3a17e02beffe8136c4dba58935cc5c9c2d7ffe1222c", + "src/Safe/LivenessModule.sol": "0x45621d74ea464c75064f9194261d29d47552cf4a9c4f4b3a733f5df5803fc0dd", "src/dispute/BlockOracle.sol": "0x7e724b1ee0116dfd744f556e6237af449c2f40c6426d6f1462ae2a47589283bb", "src/dispute/DisputeGameFactory.sol": "0xfdfa141408d7f8de7e230ff4bef088e30d0e4d569ca743d60d292abdd21ff270", - "src/dispute/FaultDisputeGame.sol": "0xfdf4be4d6ed4bcbf6492c43fdbfd04d0c62ebee11b8fe9ee2e7757bde8f7383d", + "src/dispute/FaultDisputeGame.sol": "0x0766707ab32338a6586c2340ddfbfd4e9023eeb9dfa3ef87e4b404fb0260479f", "src/legacy/DeployerWhitelist.sol": "0x0a6840074734c9d167321d3299be18ef911a415e4c471fa92af7d6cfaa8336d4", "src/legacy/L1BlockNumber.sol": "0x20d83a636c5e2067fca8c0ed505b295174e6eddb25960d8705e6b6fea8e77fa6", "src/legacy/LegacyMessagePasser.sol": "0x80f355c9710af586f58cf6a86d1925e0073d1e504d0b3d814284af1bafe4dece", - "src/periphery/op-nft/AttestationStation.sol": "0x9cf6f2fd909f9bcff229a137198186749a839cfa3d11ddbb3021fe71c30a2fa9", - "src/periphery/op-nft/Optimist.sol": "0x38407f766aa9d394403e9da388dd0265b48901789f3e8a28af50014f9f5251d9", - "src/periphery/op-nft/OptimistAllowlist.sol": "0x53e9a9dfecbae036fd468e8f34c80c7d9c35bd8908c8a6483db44dbc5128ad69", - "src/periphery/op-nft/OptimistInviter.sol": "0xfdd5b9d45205ef9372ba37f7a6394724695e676d27a47cb154ee6e4148490013", - "src/universal/OptimismMintableERC20.sol": "0x17fe6e955dc7e9e480e57bc62c227206838b204dcb660b8cb8f6f217319a22ba", - "src/universal/OptimismMintableERC20Factory.sol": "0x684a9445515e3797722b211e2c0d6a94b6244d6fa028cd2825a31538ef2dc59c", + "src/periphery/op-nft/AttestationStation.sol": "0x067b29fe24734c121469c1cb2e9b2602ddabb9e07792338b766cab341776cd78", + "src/periphery/op-nft/Optimist.sol": "0x128113cd97433987220f25b59d883d5ee7e70ff2214a536c0df3d892e13287fc", + "src/periphery/op-nft/OptimistAllowlist.sol": "0x12e5d0a79c8c05cfd41be8a1bcbd5c889652182a723aeb5eccb35e0ee2a5b6c0", + "src/periphery/op-nft/OptimistInviter.sol": "0xe5353f882475396ca8c3c0f8905baf3450697612ee6ac1d7053a80f6e1ecdd3b", + "src/universal/OptimismMintableERC20.sol": "0x099bea9f5d2f0a827f87485a4e51b8055981f6d84a0e974d226ba6d8ed5ba73d", + "src/universal/OptimismMintableERC20Factory.sol": "0x8d4cbf4cc30a0bb72925b5d2e0386b8f91559f00933a9c7cf3dcc118e34fe61b", "src/universal/OptimismMintableERC721.sol": "0x4c73bf8474fa7eb091796a4db7e57bc5f26d50a3d1cfcb78d5efa47ced5ced2b", "src/universal/OptimismMintableERC721Factory.sol": "0x935fd97018b6ef10fa813d9d43ab7a77c80885f7a8d7feb430097645cb2abd2c", - "src/universal/StorageSetter.sol": "0x6372647d8a67d243bc2fb40d2c4bf5807022d94d52d9423cfed27a7d57918635" + "src/universal/StorageSetter.sol": "0x394ec39ef24b44f54549deec6183cace8eea2e5313cde8d5a6e0411a481c5953" } \ No newline at end of file diff --git a/packages/contracts-bedrock/src/EAS/EAS.sol b/packages/contracts-bedrock/src/EAS/EAS.sol index 387688e834bed..f4872eeed26e8 100644 --- a/packages/contracts-bedrock/src/EAS/EAS.sol +++ b/packages/contracts-bedrock/src/EAS/EAS.sol @@ -16,7 +16,7 @@ import { NotFound, NO_EXPIRATION_TIME, uncheckedInc -} from "./Common.sol"; +} from "src/EAS/Common.sol"; import { Attestation, @@ -31,9 +31,9 @@ import { MultiRevocationRequest, RevocationRequest, RevocationRequestData -} from "./IEAS.sol"; +} from "src/EAS/IEAS.sol"; -import { ISchemaRegistry, SchemaRecord } from "./ISchemaRegistry.sol"; +import { ISchemaRegistry, SchemaRecord } from "src/EAS/ISchemaRegistry.sol"; struct AttestationsResult { uint256 usedValue; // Total ETH amount that was sent to resolvers. @@ -80,11 +80,11 @@ contract EAS is IEAS, ISemver, EIP1271Verifier { uint256[MAX_GAP - 3] private __gap; /// @notice Semantic version. - /// @custom:semver 1.3.0 - string public constant version = "1.3.0"; + /// @custom:semver 1.4.0 + string public constant version = "1.4.0"; /// @dev Creates a new EAS instance. - constructor() EIP1271Verifier("EAS", "1.2.0") { } + constructor() EIP1271Verifier("EAS", "1.3.0") { } /// @inheritdoc IEAS function getSchemaRegistry() external pure returns (ISchemaRegistry) { diff --git a/packages/contracts-bedrock/src/EAS/eip1271/EIP1271Verifier.sol b/packages/contracts-bedrock/src/EAS/eip1271/EIP1271Verifier.sol index 22c5860bab0cb..2b9ba7191fb21 100644 --- a/packages/contracts-bedrock/src/EAS/eip1271/EIP1271Verifier.sol +++ b/packages/contracts-bedrock/src/EAS/eip1271/EIP1271Verifier.sol @@ -10,7 +10,7 @@ import { DelegatedAttestationRequest, DelegatedRevocationRequest, RevocationRequestData -} from "../IEAS.sol"; +} from "src/EAS/IEAS.sol"; import { DeadlineExpired, @@ -20,7 +20,7 @@ import { MAX_GAP, stringToBytes32, bytes32ToString -} from "../Common.sol"; +} from "src/EAS/Common.sol"; /// @title EIP1271Verifier /// @notice EIP1271Verifier typed signatures verifier for EAS delegated attestations. @@ -30,13 +30,13 @@ abstract contract EIP1271Verifier is EIP712 { error InvalidNonce(); // The hash of the data type used to relay calls to the attest function. It's the value of - // keccak256("Attest(bytes32 schema,address recipient,uint64 expirationTime,bool revocable,bytes32 refUID,bytes - // data,uint256 value,uint256 nonce,uint64 deadline)"). - bytes32 private constant ATTEST_TYPEHASH = 0xf83bb2b0ede93a840239f7e701a54d9bc35f03701f51ae153d601c6947ff3d3f; + // keccak256("Attest(address attester,bytes32 schema,address recipient,uint64 expirationTime,bool revocable,bytes32 + // refUID,bytes data,uint256 value,uint256 nonce,uint64 deadline)"). + bytes32 private constant ATTEST_TYPEHASH = 0xfeb2925a02bae3dae48d424a0437a2b6ac939aa9230ddc55a1a76f065d988076; // The hash of the data type used to relay calls to the revoke function. It's the value of - // keccak256("Revoke(bytes32 schema,bytes32 uid,uint256 value,uint256 nonce,uint64 deadline)"). - bytes32 private constant REVOKE_TYPEHASH = 0x2d4116d8c9824e4c316453e5c2843a1885580374159ce8768603c49085ef424c; + // keccak256("Revoke(address revoker,bytes32 schema,bytes32 uid,uint256 value,uint256 nonce,uint64 deadline)"). + bytes32 private constant REVOKE_TYPEHASH = 0xb5d556f07587ec0f08cf386545cc4362c702a001650c2058002615ee5c9d1e75; // The user readable name of the signing domain. bytes32 private immutable _name; @@ -116,6 +116,7 @@ abstract contract EIP1271Verifier is EIP712 { keccak256( abi.encode( ATTEST_TYPEHASH, + request.attester, request.schema, data.recipient, data.expirationTime, @@ -150,7 +151,13 @@ abstract contract EIP1271Verifier is EIP712 { bytes32 hash = _hashTypedDataV4( keccak256( abi.encode( - REVOKE_TYPEHASH, request.schema, data.uid, data.value, _nonces[request.revoker]++, request.deadline + REVOKE_TYPEHASH, + request.revoker, + request.schema, + data.uid, + data.value, + _nonces[request.revoker]++, + request.deadline ) ) ); diff --git a/packages/contracts-bedrock/src/EAS/resolver/SchemaResolver.sol b/packages/contracts-bedrock/src/EAS/resolver/SchemaResolver.sol index bd3898bebffcc..4e51c3e89c0d7 100644 --- a/packages/contracts-bedrock/src/EAS/resolver/SchemaResolver.sol +++ b/packages/contracts-bedrock/src/EAS/resolver/SchemaResolver.sol @@ -1,16 +1,14 @@ // SPDX-License-Identifier: MIT pragma solidity 0.8.19; -import { Semver } from "../../universal/Semver.sol"; +import { IEAS, Attestation } from "src/EAS/IEAS.sol"; +import { AccessDenied, InvalidEAS, InvalidLength, uncheckedInc } from "src/EAS/Common.sol"; -import { IEAS, Attestation } from "../IEAS.sol"; -import { AccessDenied, InvalidEAS, InvalidLength, uncheckedInc } from "../Common.sol"; - -import { ISchemaResolver } from "./ISchemaResolver.sol"; +import { ISchemaResolver } from "src/EAS/resolver/ISchemaResolver.sol"; /// @title SchemaResolver /// @notice The base schema resolver contract. -abstract contract SchemaResolver is ISchemaResolver, Semver { +abstract contract SchemaResolver is ISchemaResolver { error InsufficientValue(); error NotPayable(); @@ -19,7 +17,7 @@ abstract contract SchemaResolver is ISchemaResolver, Semver { /// @dev Creates a new resolver. /// @param eas The address of the global EAS contract. - constructor(IEAS eas) Semver(1, 2, 0) { + constructor(IEAS eas) { if (address(eas) == address(0)) { revert InvalidEAS(); } diff --git a/packages/contracts-bedrock/src/L1/L1CrossDomainMessenger.sol b/packages/contracts-bedrock/src/L1/L1CrossDomainMessenger.sol index dd1f6c4278227..5bc5a347e1a48 100644 --- a/packages/contracts-bedrock/src/L1/L1CrossDomainMessenger.sol +++ b/packages/contracts-bedrock/src/L1/L1CrossDomainMessenger.sol @@ -20,8 +20,8 @@ contract L1CrossDomainMessenger is CrossDomainMessenger, ISemver { OptimismPortal public PORTAL; /// @notice Semantic version. - /// @custom:semver 1.7.0 - string public constant version = "1.7.0"; + /// @custom:semver 1.7.1 + string public constant version = "1.7.1"; /// @notice Constructs the L1CrossDomainMessenger contract. constructor() CrossDomainMessenger(Predeploys.L2_CROSS_DOMAIN_MESSENGER) { diff --git a/packages/contracts-bedrock/src/L1/L1ERC721Bridge.sol b/packages/contracts-bedrock/src/L1/L1ERC721Bridge.sol index f88e8431962fb..97b6fa8beb505 100644 --- a/packages/contracts-bedrock/src/L1/L1ERC721Bridge.sol +++ b/packages/contracts-bedrock/src/L1/L1ERC721Bridge.sol @@ -19,8 +19,8 @@ contract L1ERC721Bridge is ERC721Bridge, ISemver { mapping(address => mapping(address => mapping(uint256 => bool))) public deposits; /// @notice Semantic version. - /// @custom:semver 1.4.0 - string public constant version = "1.4.0"; + /// @custom:semver 1.4.1 + string public constant version = "1.4.1"; /// @notice Constructs the contract. constructor() ERC721Bridge(Predeploys.L2_ERC721_BRIDGE) { diff --git a/packages/contracts-bedrock/src/L1/L1StandardBridge.sol b/packages/contracts-bedrock/src/L1/L1StandardBridge.sol index 6cc783fb9c2ab..e4e9914ed8c75 100644 --- a/packages/contracts-bedrock/src/L1/L1StandardBridge.sol +++ b/packages/contracts-bedrock/src/L1/L1StandardBridge.sol @@ -69,8 +69,8 @@ contract L1StandardBridge is StandardBridge, ISemver { ); /// @notice Semantic version. - /// @custom:semver 1.4.0 - string public constant version = "1.4.0"; + /// @custom:semver 1.4.1 + string public constant version = "1.4.1"; /// @notice Constructs the L1StandardBridge contract. constructor() StandardBridge(StandardBridge(payable(Predeploys.L2_STANDARD_BRIDGE))) { diff --git a/packages/contracts-bedrock/src/L2/BaseFeeVault.sol b/packages/contracts-bedrock/src/L2/BaseFeeVault.sol index d19ae4cf986b8..e5313d93ace4e 100644 --- a/packages/contracts-bedrock/src/L2/BaseFeeVault.sol +++ b/packages/contracts-bedrock/src/L2/BaseFeeVault.sol @@ -10,8 +10,8 @@ import { FeeVault } from "src/universal/FeeVault.sol"; /// @notice The BaseFeeVault accumulates the base fee that is paid by transactions. contract BaseFeeVault is FeeVault, ISemver { /// @notice Semantic version. - /// @custom:semver 1.4.0 - string public constant version = "1.4.0"; + /// @custom:semver 1.4.1 + string public constant version = "1.4.1"; /// @notice Constructs the BaseFeeVault contract. /// @param _recipient Wallet that will receive the fees. diff --git a/packages/contracts-bedrock/src/L2/L1FeeVault.sol b/packages/contracts-bedrock/src/L2/L1FeeVault.sol index efcacfdf57c14..b815dbfbbf79a 100644 --- a/packages/contracts-bedrock/src/L2/L1FeeVault.sol +++ b/packages/contracts-bedrock/src/L2/L1FeeVault.sol @@ -10,8 +10,8 @@ import { FeeVault } from "src/universal/FeeVault.sol"; /// @notice The L1FeeVault accumulates the L1 portion of the transaction fees. contract L1FeeVault is FeeVault, ISemver { /// @notice Semantic version. - /// @custom:semver 1.4.0 - string public constant version = "1.4.0"; + /// @custom:semver 1.4.1 + string public constant version = "1.4.1"; /// @notice Constructs the L1FeeVault contract. /// @param _recipient Wallet that will receive the fees. diff --git a/packages/contracts-bedrock/src/L2/L2CrossDomainMessenger.sol b/packages/contracts-bedrock/src/L2/L2CrossDomainMessenger.sol index e7bb39a0faf0e..7867f1b878034 100644 --- a/packages/contracts-bedrock/src/L2/L2CrossDomainMessenger.sol +++ b/packages/contracts-bedrock/src/L2/L2CrossDomainMessenger.sol @@ -6,6 +6,7 @@ import { Predeploys } from "src/libraries/Predeploys.sol"; import { CrossDomainMessenger } from "src/universal/CrossDomainMessenger.sol"; import { ISemver } from "src/universal/ISemver.sol"; import { L2ToL1MessagePasser } from "src/L2/L2ToL1MessagePasser.sol"; +import { Constants } from "src/libraries/Constants.sol"; /// @custom:proxied /// @custom:predeploy 0x4200000000000000000000000000000000000007 @@ -14,8 +15,8 @@ import { L2ToL1MessagePasser } from "src/L2/L2ToL1MessagePasser.sol"; /// L2 on the L2 side. Users are generally encouraged to use this contract instead of lower /// level message passing contracts. contract L2CrossDomainMessenger is CrossDomainMessenger, ISemver { - /// @custom:semver 1.6.0 - string public constant version = "1.6.0"; + /// @custom:semver 1.7.0 + string public constant version = "1.7.0"; /// @notice Constructs the L2CrossDomainMessenger contract. /// @param _l1CrossDomainMessenger Address of the L1CrossDomainMessenger contract. @@ -24,7 +25,7 @@ contract L2CrossDomainMessenger is CrossDomainMessenger, ISemver { } /// @notice Initializer. - function initialize() public reinitializer(2) { + function initialize() public reinitializer(Constants.INITIALIZER) { __CrossDomainMessenger_init(); } diff --git a/packages/contracts-bedrock/src/L2/L2ERC721Bridge.sol b/packages/contracts-bedrock/src/L2/L2ERC721Bridge.sol index 584a4de822ce9..11d746f1bf058 100644 --- a/packages/contracts-bedrock/src/L2/L2ERC721Bridge.sol +++ b/packages/contracts-bedrock/src/L2/L2ERC721Bridge.sol @@ -7,6 +7,8 @@ import { L1ERC721Bridge } from "src/L1/L1ERC721Bridge.sol"; import { IOptimismMintableERC721 } from "src/universal/IOptimismMintableERC721.sol"; import { CrossDomainMessenger } from "src/universal/CrossDomainMessenger.sol"; import { ISemver } from "src/universal/ISemver.sol"; +import { Constants } from "src/libraries/Constants.sol"; +import { Predeploys } from "src/libraries/Predeploys.sol"; /// @title L2ERC721Bridge /// @notice The L2 ERC721 bridge is a contract which works together with the L1 ERC721 bridge to @@ -18,19 +20,18 @@ import { ISemver } from "src/universal/ISemver.sol"; /// wait for the one-week challenge period to elapse before their Optimism-native NFT /// can be refunded on L2. contract L2ERC721Bridge is ERC721Bridge, ISemver { - /// @custom:semver 1.3.0 - string public constant version = "1.3.0"; + /// @custom:semver 1.4.0 + string public constant version = "1.4.0"; /// @notice Constructs the L2ERC721Bridge contract. /// @param _otherBridge Address of the ERC721 bridge on the other network. constructor(address _otherBridge) ERC721Bridge(_otherBridge) { - initialize({ _messenger: CrossDomainMessenger(address(0)) }); + initialize(); } /// @notice Initializes the contract. - /// @param _messenger Address of the CrossDomainMessenger on this network. - function initialize(CrossDomainMessenger _messenger) public reinitializer(2) { - __ERC721Bridge_init({ _messenger: _messenger }); + function initialize() public reinitializer(Constants.INITIALIZER) { + __ERC721Bridge_init({ _messenger: CrossDomainMessenger(Predeploys.L2_CROSS_DOMAIN_MESSENGER) }); } /// @notice Completes an ERC721 bridge from the other domain and sends the ERC721 token to the diff --git a/packages/contracts-bedrock/src/L2/L2StandardBridge.sol b/packages/contracts-bedrock/src/L2/L2StandardBridge.sol index 8c971593ec53f..9e42e13f2b7b3 100644 --- a/packages/contracts-bedrock/src/L2/L2StandardBridge.sol +++ b/packages/contracts-bedrock/src/L2/L2StandardBridge.sol @@ -6,6 +6,7 @@ import { StandardBridge } from "src/universal/StandardBridge.sol"; import { ISemver } from "src/universal/ISemver.sol"; import { OptimismMintableERC20 } from "src/universal/OptimismMintableERC20.sol"; import { CrossDomainMessenger } from "src/universal/CrossDomainMessenger.sol"; +import { Constants } from "src/libraries/Constants.sol"; /// @custom:proxied /// @custom:predeploy 0x4200000000000000000000000000000000000010 @@ -51,8 +52,8 @@ contract L2StandardBridge is StandardBridge, ISemver { bytes extraData ); - /// @custom:semver 1.3.0 - string public constant version = "1.3.0"; + /// @custom:semver 1.4.0 + string public constant version = "1.4.0"; /// @notice Constructs the L2StandardBridge contract. /// @param _otherBridge Address of the L1StandardBridge. @@ -61,7 +62,7 @@ contract L2StandardBridge is StandardBridge, ISemver { } /// @notice Initializer - function initialize() public reinitializer(2) { + function initialize() public reinitializer(Constants.INITIALIZER) { __StandardBridge_init({ _messenger: CrossDomainMessenger(Predeploys.L2_CROSS_DOMAIN_MESSENGER) }); } diff --git a/packages/contracts-bedrock/src/L2/SequencerFeeVault.sol b/packages/contracts-bedrock/src/L2/SequencerFeeVault.sol index a1fde29d413ed..5f2c329db1923 100644 --- a/packages/contracts-bedrock/src/L2/SequencerFeeVault.sol +++ b/packages/contracts-bedrock/src/L2/SequencerFeeVault.sol @@ -10,8 +10,8 @@ import { FeeVault } from "src/universal/FeeVault.sol"; /// @notice The SequencerFeeVault is the contract that holds any fees paid to the Sequencer during /// transaction processing and block production. contract SequencerFeeVault is FeeVault, ISemver { - /// @custom:semver 1.4.0 - string public constant version = "1.4.0"; + /// @custom:semver 1.4.1 + string public constant version = "1.4.1"; /// @notice Constructs the SequencerFeeVault contract. /// @param _recipient Wallet that will receive the fees. diff --git a/packages/contracts-bedrock/src/Safe/LivenessGuard.sol b/packages/contracts-bedrock/src/Safe/LivenessGuard.sol new file mode 100644 index 0000000000000..ae2c5145514b5 --- /dev/null +++ b/packages/contracts-bedrock/src/Safe/LivenessGuard.sol @@ -0,0 +1,159 @@ +// SPDX-License-Identifier: MIT +pragma solidity 0.8.15; + +import { Safe } from "safe-contracts/Safe.sol"; +import { BaseGuard, GuardManager } from "safe-contracts/base/GuardManager.sol"; +import { ModuleManager } from "safe-contracts/base/ModuleManager.sol"; +import { SafeSigners } from "src/Safe/SafeSigners.sol"; +import { Enum } from "safe-contracts/common/Enum.sol"; +import { ISemver } from "src/universal/ISemver.sol"; +import { EnumerableSet } from "@openzeppelin/contracts/utils/structs/EnumerableSet.sol"; + +/// @title LivenessGuard +/// @notice This Guard contract is used to track the liveness of Safe owners. +/// @dev It keeps track of the last time each owner participated in signing a transaction. +/// If an owner does not participate in a transaction for a certain period of time, they are considered inactive. +/// This Guard is intended to be used in conjunction with the LivenessModule contract, but does +/// not depend on it. +/// Note: Both `checkTransaction` and `checkAfterExecution` are called once each by the Safe contract +/// before and after the execution of a transaction. It is critical that neither function revert, +/// otherwise the Safe contract will be unable to execute a transaction. +contract LivenessGuard is ISemver, BaseGuard { + using EnumerableSet for EnumerableSet.AddressSet; + + /// @notice Emitted when an owner is recorded. + /// @param owner The owner's address. + event OwnerRecorded(address owner); + + /// @notice Semantic version. + /// @custom:semver 1.0.0 + string public constant version = "1.0.0"; + + /// @notice The safe account for which this contract will be the guard. + Safe internal immutable SAFE; + + /// @notice A mapping of the timestamp at which an owner last participated in signing a + /// an executed transaction, or called showLiveness. + mapping(address => uint256) public lastLive; + + /// @notice An enumerable set of addresses used to store the list of owners before execution, + /// and then to update the lastLive mapping according to changes in the set observed + /// after execution. + EnumerableSet.AddressSet internal ownersBefore; + + /// @notice Constructor. + /// @param _safe The safe account for which this contract will be the guard. + constructor(Safe _safe) { + SAFE = _safe; + address[] memory owners = _safe.getOwners(); + for (uint256 i = 0; i < owners.length; i++) { + address owner = owners[i]; + lastLive[owner] = block.timestamp; + emit OwnerRecorded(owner); + } + } + + /// @notice Getter function for the Safe contract instance + /// @return safe_ The Safe contract instance + function safe() public view returns (Safe safe_) { + safe_ = SAFE; + } + + /// @notice Internal function to ensure that only the Safe can call certain functions. + function _requireOnlySafe() internal view { + require(msg.sender == address(SAFE), "LivenessGuard: only Safe can call this function"); + } + + /// @notice Records the most recent time which any owner has signed a transaction. + /// @dev Called by the Safe contract before execution of a transaction. + function checkTransaction( + address to, + uint256 value, + bytes memory data, + Enum.Operation operation, + uint256 safeTxGas, + uint256 baseGas, + uint256 gasPrice, + address gasToken, + address payable refundReceiver, + bytes memory signatures, + address msgSender + ) + external + { + msgSender; // silence unused variable warning + _requireOnlySafe(); + + // Cache the set of owners prior to execution. + // This will be used in the checkAfterExecution method. + address[] memory owners = SAFE.getOwners(); + for (uint256 i = 0; i < owners.length; i++) { + ownersBefore.add(owners[i]); + } + + // This call will reenter to the Safe which is calling it. This is OK because it is only reading the + // nonce, and using the getTransactionHash() method. + bytes32 txHash = SAFE.getTransactionHash({ + to: to, + value: value, + data: data, + operation: operation, + safeTxGas: safeTxGas, + baseGas: baseGas, + gasPrice: gasPrice, + gasToken: gasToken, + refundReceiver: refundReceiver, + _nonce: SAFE.nonce() - 1 + }); + + uint256 threshold = SAFE.getThreshold(); + address[] memory signers = + SafeSigners.getNSigners({ dataHash: txHash, signatures: signatures, requiredSignatures: threshold }); + + for (uint256 i = 0; i < signers.length; i++) { + lastLive[signers[i]] = block.timestamp; + emit OwnerRecorded(signers[i]); + } + } + + /// @notice Update the lastLive mapping according to the set of owners before and after execution. + /// @dev Called by the Safe contract after the execution of a transaction. + /// We use this post execution hook to compare the set of owners before and after. + /// If the set of owners has changed then we: + /// 1. Add new owners to the lastLive mapping + /// 2. Delete removed owners from the lastLive mapping + function checkAfterExecution(bytes32, bool) external { + _requireOnlySafe(); + // Get the current set of owners + address[] memory ownersAfter = SAFE.getOwners(); + + // Iterate over the current owners, and remove one at a time from the ownersBefore set. + for (uint256 i = 0; i < ownersAfter.length; i++) { + // If the value was present, remove() returns true. + address ownerAfter = ownersAfter[i]; + if (ownersBefore.remove(ownerAfter) == false) { + // This address was not already an owner, add it to the lastLive mapping + lastLive[ownerAfter] = block.timestamp; + } + } + + // Now iterate over the remaining ownersBefore entries. Any remaining addresses are no longer an owner, so we + // delete them from the lastLive mapping. + // We cache the ownersBefore set before iterating over it, because the remove() method mutates the set. + address[] memory ownersBeforeCache = ownersBefore.values(); + for (uint256 i = 0; i < ownersBeforeCache.length; i++) { + address ownerBefore = ownersBeforeCache[i]; + delete lastLive[ownerBefore]; + ownersBefore.remove(ownerBefore); + } + } + + /// @notice Enables an owner to demonstrate liveness by calling this method directly. + /// This is useful for owners who have not recently signed a transaction via the Safe. + function showLiveness() external { + require(SAFE.isOwner(msg.sender), "LivenessGuard: only Safe owners may demonstrate liveness"); + lastLive[msg.sender] = block.timestamp; + + emit OwnerRecorded(msg.sender); + } +} diff --git a/packages/contracts-bedrock/src/Safe/LivenessModule.sol b/packages/contracts-bedrock/src/Safe/LivenessModule.sol new file mode 100644 index 0000000000000..41f2ed64708e8 --- /dev/null +++ b/packages/contracts-bedrock/src/Safe/LivenessModule.sol @@ -0,0 +1,231 @@ +// SPDX-License-Identifier: MIT +pragma solidity 0.8.15; + +import { Safe, OwnerManager } from "safe-contracts/Safe.sol"; +import { Enum } from "safe-contracts/common/Enum.sol"; +import { OwnerManager } from "safe-contracts/base/OwnerManager.sol"; +import { LivenessGuard } from "src/Safe/LivenessGuard.sol"; +import { ISemver } from "src/universal/ISemver.sol"; + +/// @title LivenessModule +/// @notice This module is intended to be used in conjunction with the LivenessGuard. In the event +/// that an owner of the safe is not recorded by the guard during the liveness interval, +/// the owner will be considered inactive and will be removed from the list of owners. +/// If the number of owners falls below the minimum number of owners, the ownership of the +/// safe will be transferred to the fallback owner. +contract LivenessModule is ISemver { + /// @notice The Safe contract instance + Safe internal immutable SAFE; + + /// @notice The LivenessGuard contract instance + /// This can be updated by replacing with a new module and switching out the guard. + LivenessGuard internal immutable LIVENESS_GUARD; + + /// @notice The interval, in seconds, during which an owner must have demonstrated liveness + /// This can be updated by replacing with a new module. + uint256 internal immutable LIVENESS_INTERVAL; + + /// @notice The minimum number of owners before ownership of the safe is transferred to the fallback owner. + /// This can be updated by replacing with a new module. + uint256 internal immutable MIN_OWNERS; + + /// @notice The fallback owner of the Safe + /// This can be updated by replacing with a new module. + address internal immutable FALLBACK_OWNER; + + /// @notice The storage slot used in the safe to store the guard address + /// keccak256("guard_manager.guard.address") + uint256 internal constant GUARD_STORAGE_SLOT = 0x4a204f620c8c5ccdca3fd54d003badd85ba500436a431f0cbda4f558c93c34c8; + + /// @notice Semantic version. + /// @custom:semver 1.0.0 + string public constant version = "1.0.0"; + + // Constructor to initialize the Safe and baseModule instances + constructor( + Safe _safe, + LivenessGuard _livenessGuard, + uint256 _livenessInterval, + uint256 _minOwners, + address _fallbackOwner + ) { + SAFE = _safe; + LIVENESS_GUARD = _livenessGuard; + LIVENESS_INTERVAL = _livenessInterval; + FALLBACK_OWNER = _fallbackOwner; + MIN_OWNERS = _minOwners; + address[] memory owners = _safe.getOwners(); + require(_minOwners <= owners.length, "LivenessModule: minOwners must be less than the number of owners"); + require( + _safe.getThreshold() >= get75PercentThreshold(owners.length), + "LivenessModule: Safe must have a threshold of at least 75% of the number of owners" + ); + } + + /// @notice For a given number of owners, return the lowest threshold which is greater than 75. + /// Note: this function returns 1 for numOwners == 1. + function get75PercentThreshold(uint256 _numOwners) public pure returns (uint256 threshold_) { + threshold_ = (_numOwners * 75 + 99) / 100; + } + + /// @notice Getter function for the Safe contract instance + /// @return safe_ The Safe contract instance + function safe() public view returns (Safe safe_) { + safe_ = SAFE; + } + + /// @notice Getter function for the LivenessGuard contract instance + /// @return livenessGuard_ The LivenessGuard contract instance + function livenessGuard() public view returns (LivenessGuard livenessGuard_) { + livenessGuard_ = LIVENESS_GUARD; + } + + /// @notice Getter function for the liveness interval + /// @return livenessInterval_ The liveness interval, in seconds + function livenessInterval() public view returns (uint256 livenessInterval_) { + livenessInterval_ = LIVENESS_INTERVAL; + } + + /// @notice Getter function for the minimum number of owners + /// @return minOwners_ The minimum number of owners + function minOwners() public view returns (uint256 minOwners_) { + minOwners_ = MIN_OWNERS; + } + + /// @notice Getter function for the fallback owner + /// @return fallbackOwner_ The fallback owner of the Safe + function fallbackOwner() public view returns (address fallbackOwner_) { + fallbackOwner_ = FALLBACK_OWNER; + } + + /// @notice Checks if the owner can be removed + /// @param _owner The owner to be removed + /// @return canRemove_ bool indicating if the owner can be removed + function canRemove(address _owner) public view returns (bool canRemove_) { + require(SAFE.isOwner(_owner), "LivenessModule: the owner to remove must be an owner of the Safe"); + canRemove_ = LIVENESS_GUARD.lastLive(_owner) + LIVENESS_INTERVAL < block.timestamp; + } + + /// @notice This function can be called by anyone to remove a set of owners that have not signed a transaction + /// during the liveness interval. If the number of owners drops below the minimum, then all owners + /// must be removed. + /// @param _previousOwners The previous owners in the linked list of owners + /// @param _ownersToRemove The owners to remove + function removeOwners(address[] memory _previousOwners, address[] memory _ownersToRemove) external { + require(_previousOwners.length == _ownersToRemove.length, "LivenessModule: arrays must be the same length"); + + // Initialize the ownersCount count to the current number of owners, so that we can track the number of + // owners in the Safe after each removal. The Safe will revert if an owner cannot be removed, so it is safe + // keep a local count of the number of owners this way. + uint256 ownersCount = SAFE.getOwners().length; + for (uint256 i = 0; i < _previousOwners.length; i++) { + // Validate that the owner can be removed, which means that either: + // 1. the ownersCount is now less than MIN_OWNERS, in which case all owners should be removed regardless + // of liveness, + // 2. the owner has not signed a transaction during the liveness interval. + if (ownersCount >= MIN_OWNERS) { + require(canRemove(_ownersToRemove[i]), "LivenessModule: the owner to remove has signed recently"); + } + + // Pre-emptively update our local count of the number of owners. + // This is safe because _removeOwner will bubble up any revert from the Safe if the owner cannot be removed. + ownersCount--; + + // We now attempt remove the owner from the safe. + _removeOwner({ + _prevOwner: _previousOwners[i], + _ownerToRemove: _ownersToRemove[i], + _newOwnersCount: ownersCount + }); + + // when all owners are removed and the sole owner is the fallback owner, the + // ownersCount variable will be incorrectly set to zero. + // This reflects the fact that all prior owners have been removed. The loop should naturally exit at this + // point, but for safety we detect this condition and force the loop to terminate. + if (ownersCount == 0) { + break; + } + } + _verifyFinalState(); + } + + /// @notice Removes an owner from the Safe and updates the threshold. + /// @param _prevOwner Owner that pointed to the owner to be removed in the linked list + /// @param _ownerToRemove Owner address to be removed. + /// @param _newOwnersCount New number of owners after removal. + function _removeOwner(address _prevOwner, address _ownerToRemove, uint256 _newOwnersCount) internal { + if (_newOwnersCount > 0) { + uint256 newThreshold = get75PercentThreshold(_newOwnersCount); + // Remove the owner and update the threshold + _removeOwnerSafeCall({ _prevOwner: _prevOwner, _owner: _ownerToRemove, _threshold: newThreshold }); + } else { + // There is only one owner left. The Safe will not allow a safe with no owners, so we will + // need to swap owners instead. + _swapToFallbackOwnerSafeCall({ _prevOwner: _prevOwner, _oldOwner: _ownerToRemove }); + } + } + + /// @notice Sets the fallback owner as the sole owner of the Safe with a threshold of 1 + /// @param _prevOwner Owner that pointed to the owner to be replaced in the linked list + /// @param _oldOwner Owner address to be replaced. + function _swapToFallbackOwnerSafeCall(address _prevOwner, address _oldOwner) internal { + require( + SAFE.execTransactionFromModule({ + to: address(SAFE), + value: 0, + operation: Enum.Operation.Call, + data: abi.encodeCall(OwnerManager.swapOwner, (_prevOwner, _oldOwner, FALLBACK_OWNER)) + }), + "LivenessModule: failed to swap to fallback owner" + ); + } + + /// @notice Removes the owner `owner` from the Safe and updates the threshold to `_threshold`. + /// @param _prevOwner Owner that pointed to the owner to be removed in the linked list + /// @param _owner Owner address to be removed. + /// @param _threshold New threshold. + function _removeOwnerSafeCall(address _prevOwner, address _owner, uint256 _threshold) internal { + require( + SAFE.execTransactionFromModule({ + to: address(SAFE), + value: 0, + operation: Enum.Operation.Call, + data: abi.encodeCall(OwnerManager.removeOwner, (_prevOwner, _owner, _threshold)) + }), + "LivenessModule: failed to remove owner" + ); + } + + /// @notice A FREI-PI invariant check enforcing requirements on number of owners and threshold. + function _verifyFinalState() internal view { + address[] memory owners = SAFE.getOwners(); + uint256 numOwners = owners.length; + + // Ensure that the safe is not being left in a safe state such that either: + // 1. there are at least the minimum number of owners, or + // 2. there is a single owner and that owner is the fallback owner. + if (numOwners == 1) { + require(owners[0] == FALLBACK_OWNER, "LivenessModule: must transfer ownership to fallback owner"); + } else { + require( + numOwners >= MIN_OWNERS, + "LivenessModule: must remove all owners and transfer to fallback owner if numOwners < minOwners" + ); + } + + // Check that"LivenessModule: must remove all owners and transfer to fallback owner if numOwners < minOwners" + // the threshold is correct. This check is also correct when there is a single + // owner, because get75PercentThreshold(1) returns 1. + uint256 threshold = SAFE.getThreshold(); + require( + threshold == get75PercentThreshold(numOwners), + "LivenessModule: Safe must have a threshold of 75% of the number of owners" + ); + + // Check that the guard has not been changed + require( + address(LIVENESS_GUARD) == address(uint160(uint256(bytes32(SAFE.getStorageAt(GUARD_STORAGE_SLOT, 1))))), + "LivenessModule: guard has been changed" + ); + } +} diff --git a/packages/contracts-bedrock/src/Safe/SafeSigners.sol b/packages/contracts-bedrock/src/Safe/SafeSigners.sol new file mode 100644 index 0000000000000..32e65913dda55 --- /dev/null +++ b/packages/contracts-bedrock/src/Safe/SafeSigners.sol @@ -0,0 +1,86 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.0; + +library SafeSigners { + /// @notice Splits signature bytes into `uint8 v, bytes32 r, bytes32 s`. + /// Copied directly from + /// https://github.com/safe-global/safe-contracts/blob/e870f514ad34cd9654c72174d6d4a839e3c6639f/contracts/common/SignatureDecoder.sol + /// @dev Make sure to perform a bounds check for @param pos, to avoid out of bounds access on @param signatures + /// The signature format is a compact form of {bytes32 r}{bytes32 s}{uint8 v} + /// Compact means uint8 is not padded to 32 bytes. + /// @param pos Which signature to read. + /// A prior bounds check of this parameter should be performed, to avoid out of bounds access. + /// @param signatures Concatenated {r, s, v} signatures. + /// @return v Recovery ID or Safe signature type. + /// @return r Output value r of the signature. + /// @return s Output value s of the signature. + function signatureSplit( + bytes memory signatures, + uint256 pos + ) + internal + pure + returns (uint8 v, bytes32 r, bytes32 s) + { + // solhint-disable-next-line no-inline-assembly + assembly { + let signaturePos := mul(0x41, pos) + r := mload(add(signatures, add(signaturePos, 0x20))) + s := mload(add(signatures, add(signaturePos, 0x40))) + /** + * Here we are loading the last 32 bytes, including 31 bytes + * of 's'. There is no 'mload8' to do this. + * 'byte' is not working due to the Solidity parser, so lets + * use the second best option, 'and' + */ + v := and(mload(add(signatures, add(signaturePos, 0x41))), 0xff) + } + } + + /// @notice Extract the signers from a set of signatures. + /// This method is based closely on the code in the Safe.checkNSignatures() method. + /// https://github.com/safe-global/safe-contracts/blob/e870f514ad34cd9654c72174d6d4a839e3c6639f/contracts/Safe.sol#L274 + /// It has been modified by removing all signature _validation_ code. We trust the Safe to properly validate + /// the signatures. + /// This method therefore simply extracts the addresses from the signatures. + function getNSigners( + bytes32 dataHash, + bytes memory signatures, + uint256 requiredSignatures + ) + internal + pure + returns (address[] memory _owners) + { + _owners = new address[](requiredSignatures); + + address currentOwner; + uint8 v; + bytes32 r; + bytes32 s; + uint256 i; + for (i = 0; i < requiredSignatures; i++) { + (v, r, s) = signatureSplit(signatures, i); + if (v == 0) { + // If v is 0 then it is a contract signature + // When handling contract signatures the address of the contract is encoded into r + currentOwner = address(uint160(uint256(r))); + } else if (v == 1) { + // If v is 1 then it is an approved hash + // When handling approved hashes the address of the approver is encoded into r + currentOwner = address(uint160(uint256(r))); + } else if (v > 30) { + // If v > 30 then default va (27,28) has been adjusted for eth_sign flow + // To support eth_sign and similar we adjust v and hash the messageHash with the Ethereum message prefix + // before applying ecrecover + currentOwner = + ecrecover(keccak256(abi.encodePacked("\x19Ethereum Signed Message:\n32", dataHash)), v - 4, r, s); + } else { + // Default is the ecrecover flow with the provided data hash + // Use ecrecover with the messageHash for EOA signatures + currentOwner = ecrecover(dataHash, v, r, s); + } + _owners[i] = currentOwner; + } + } +} diff --git a/packages/contracts-bedrock/src/cannon/MIPS.sol b/packages/contracts-bedrock/src/cannon/MIPS.sol index db7cd7526b809..5ea6560c19e4f 100644 --- a/packages/contracts-bedrock/src/cannon/MIPS.sol +++ b/packages/contracts-bedrock/src/cannon/MIPS.sol @@ -141,8 +141,9 @@ contract MIPS { } /// @notice Handles a syscall. + /// @param _localContext The local key context for the preimage oracle. /// @return out_ The hashed MIPS state. - function handleSyscall() internal returns (bytes32 out_) { + function handleSyscall(uint256 _localContext) internal returns (bytes32 out_) { unchecked { // Load state from memory State memory state; @@ -202,7 +203,7 @@ contract MIPS { bytes32 preimageKey = state.preimageKey; // If the preimage key is a local key, localize it in the context of the caller. if (uint8(preimageKey[0]) == 1) { - preimageKey = PreimageKeyLib.localize(preimageKey); + preimageKey = PreimageKeyLib.localize(preimageKey, _localContext); } (bytes32 dat, uint256 datLen) = ORACLE.readPreimage(preimageKey, state.preimageOffset); @@ -508,8 +509,8 @@ contract MIPS { function proofOffset(uint8 _proofIndex) internal pure returns (uint256 offset_) { unchecked { // A proof of 32 bit memory, with 32-byte leaf values, is (32-5)=27 bytes32 entries. - // And the leaf value itself needs to be encoded as well. And proof.offset == 388 - offset_ = 388 + (uint256(_proofIndex) * (28 * 32)); + // And the leaf value itself needs to be encoded as well. And proof.offset == 420 + offset_ = 420 + (uint256(_proofIndex) * (28 * 32)); uint256 s = 0; assembly { s := calldatasize() @@ -621,7 +622,11 @@ contract MIPS { /// @notice Executes a single step of the vm. /// Will revert if any required input state is missing. - function step(bytes calldata stateData, bytes calldata proof) public returns (bytes32) { + /// @param _stateData The encoded state witness data. + /// @param _proof The encoded proof data for leaves within the MIPS VM's memory. + /// @param _localContext The local key context for the preimage oracle. Optional, can be set as a constant + /// if the caller only requires one set of local keys. + function step(bytes calldata _stateData, bytes calldata _proof, uint256 _localContext) public returns (bytes32) { unchecked { State memory state; @@ -631,16 +636,16 @@ contract MIPS { // expected state mem offset check revert(0, 0) } - if iszero(eq(mload(0x40), mul(32, 48))) { + if iszero(eq(mload(0x40), shl(5, 48))) { // expected memory check revert(0, 0) } - if iszero(eq(stateData.offset, 100)) { - // 32*3+4=100 expected state data offset + if iszero(eq(_stateData.offset, 132)) { + // 32*4+4=132 expected state data offset revert(0, 0) } - if iszero(eq(proof.offset, 388)) { - // 100+32+256=388 expected proof offset + if iszero(eq(_proof.offset, 420)) { + // 132+32+256=420 expected proof offset revert(0, 0) } @@ -653,7 +658,7 @@ contract MIPS { } // Unpack state from calldata into memory - let c := stateData.offset // calldata offset + let c := _stateData.offset // calldata offset let m := 0x80 // mem offset c, m := putField(c, m, 32) // memRoot c, m := putField(c, m, 32) // preimageKey @@ -764,7 +769,7 @@ contract MIPS { // syscall (can read and write) if (func == 0xC) { - return handleSyscall(); + return handleSyscall(_localContext); } // lo and hi registers diff --git a/packages/contracts-bedrock/src/cannon/PreimageKeyLib.sol b/packages/contracts-bedrock/src/cannon/PreimageKeyLib.sol index 0e1174c500d30..3894fef733c44 100644 --- a/packages/contracts-bedrock/src/cannon/PreimageKeyLib.sol +++ b/packages/contracts-bedrock/src/cannon/PreimageKeyLib.sol @@ -7,29 +7,37 @@ library PreimageKeyLib { /// @notice Generates a context-specific local key for the given local data identifier. /// @dev See `localize` for a description of the localization operation. /// @param _ident The identifier of the local data. [0, 32) bytes in size. + /// @param _localContext The local context for the key. /// @return key_ The context-specific local key. - function localizeIdent(uint256 _ident) internal view returns (bytes32 key_) { + function localizeIdent(uint256 _ident, uint256 _localContext) internal view returns (bytes32 key_) { assembly { // Set the type byte in the given identifier to `1` (Local). We only care about // the [1, 32) bytes in this value. key_ := or(shl(248, 1), and(_ident, not(shl(248, 0xFF)))) } - key_ = localize(key_); + // Localize the key with the given local context. + key_ = localize(key_, _localContext); } /// @notice Localizes a given local data key for the caller's context. /// @dev The localization operation is defined as: - /// localize(k) = H(k .. sender) & ~(0xFF << 248) | (0x01 << 248) + /// localize(k) = H(k .. sender .. local_context) & ~(0xFF << 248) | (0x01 << 248) /// where H is the Keccak-256 hash function. /// @param _key The local data key to localize. + /// @param _localContext The local context for the key. /// @return localizedKey_ The localized local data key. - function localize(bytes32 _key) internal view returns (bytes32 localizedKey_) { + function localize(bytes32 _key, uint256 _localContext) internal view returns (bytes32 localizedKey_) { assembly { + // Grab the current free memory pointer to restore later. + let ptr := mload(0x40) // Store the local data key and caller next to each other in memory for hashing. mstore(0, _key) mstore(0x20, caller()) + mstore(0x40, _localContext) // Localize the key with the above `localize` operation. - localizedKey_ := or(and(keccak256(0, 0x40), not(shl(248, 0xFF))), shl(248, 1)) + localizedKey_ := or(and(keccak256(0, 0x60), not(shl(248, 0xFF))), shl(248, 1)) + // Restore the free memory pointer. + mstore(0x40, ptr) } } diff --git a/packages/contracts-bedrock/src/cannon/PreimageOracle.sol b/packages/contracts-bedrock/src/cannon/PreimageOracle.sol index 55d7f4d491be1..63986c36b8498 100644 --- a/packages/contracts-bedrock/src/cannon/PreimageOracle.sol +++ b/packages/contracts-bedrock/src/cannon/PreimageOracle.sol @@ -34,6 +34,7 @@ contract PreimageOracle is IPreimageOracle { /// @inheritdoc IPreimageOracle function loadLocalData( uint256 _ident, + uint256 _localContext, bytes32 _word, uint256 _size, uint256 _partOffset @@ -42,7 +43,7 @@ contract PreimageOracle is IPreimageOracle { returns (bytes32 key_) { // Compute the localized key from the given local identifier. - key_ = PreimageKeyLib.localizeIdent(_ident); + key_ = PreimageKeyLib.localizeIdent(_ident, _localContext); // Revert if the given part offset is not within bounds. if (_partOffset > _size + 8 || _size > 32) { diff --git a/packages/contracts-bedrock/src/cannon/interfaces/IPreimageOracle.sol b/packages/contracts-bedrock/src/cannon/interfaces/IPreimageOracle.sol index 9475479a83e34..78b1805185eda 100644 --- a/packages/contracts-bedrock/src/cannon/interfaces/IPreimageOracle.sol +++ b/packages/contracts-bedrock/src/cannon/interfaces/IPreimageOracle.sol @@ -13,6 +13,8 @@ interface IPreimageOracle { /// @notice Loads of local data part into the preimage oracle. /// @param _ident The identifier of the local data. + /// @param _localContext The local key context for the preimage oracle. Optionally, can be set as a constant + /// if the caller only requires one set of local keys. /// @param _word The local data word. /// @param _size The number of bytes in `_word` to load. /// @param _partOffset The offset of the local data part to write to the oracle. @@ -32,6 +34,7 @@ interface IPreimageOracle { /// └────────────┴────────────────────────┘ function loadLocalData( uint256 _ident, + uint256 _localContext, bytes32 _word, uint256 _size, uint256 _partOffset diff --git a/packages/contracts-bedrock/src/dispute/FaultDisputeGame.sol b/packages/contracts-bedrock/src/dispute/FaultDisputeGame.sol index fd1c9c1c8b6e5..7ff3a7562b20f 100644 --- a/packages/contracts-bedrock/src/dispute/FaultDisputeGame.sol +++ b/packages/contracts-bedrock/src/dispute/FaultDisputeGame.sol @@ -82,8 +82,8 @@ contract FaultDisputeGame is IFaultDisputeGame, Clone, ISemver { bool internal subgameAtRootResolved; /// @notice Semantic version. - /// @custom:semver 0.0.10 - string public constant version = "0.0.10"; + /// @custom:semver 0.0.11 + string public constant version = "0.0.11"; /// @param _gameType The type ID of the game. /// @param _absolutePrestate The absolute prestate of the instruction trace. @@ -174,7 +174,10 @@ contract FaultDisputeGame is IFaultDisputeGame, Clone, ISemver { // SAFETY: While the `attack` path does not need an extra check for the post // state's depth in relation to the parent, we don't need another // branch because (n - n) % 2 == 0. - bool validStep = VM.step(_stateData, _proof) == Claim.unwrap(postState.claim); + // TODO(client-pod#94): Once output bisection is implemented, the local context will no longer + // be constant. We will need to pass it in here based off of the ancestor + // disputed output root's L2 block number. + bool validStep = VM.step(_stateData, _proof, 0) == Claim.unwrap(postState.claim); bool parentPostAgree = (parentPos.depth() - postState.position.depth()) % 2 == 0; if (parentPostAgree == validStep) revert ValidStep(); @@ -278,7 +281,7 @@ contract FaultDisputeGame is IFaultDisputeGame, Clone, ISemver { } /// @inheritdoc IFaultDisputeGame - function addLocalData(uint256 _ident, uint256 _partOffset) external { + function addLocalData(uint256 _ident, uint256 _l2BlockNumber, uint256 _partOffset) external { // INVARIANT: Local data can only be added if the game is currently in progress. if (status != GameStatus.IN_PROGRESS) revert GameNotInProgress(); @@ -289,6 +292,8 @@ contract FaultDisputeGame is IFaultDisputeGame, Clone, ISemver { mstore(0x1C, loadLocalDataSelector) // Store the `_ident` argument mstore(0x20, _ident) + // Store the `_localContext` argument + mstore(0x40, _l2BlockNumber) // Store the data to load let data switch _ident @@ -319,16 +324,16 @@ contract FaultDisputeGame is IFaultDisputeGame, Clone, ISemver { // Revert with `InvalidLocalIdent()` revert(0x1C, 0x04) } - mstore(0x40, data) + mstore(0x60, data) // Store the size of the data to load // _ident > 3 ? 8 : 32 - mstore(0x60, shl(sub(0x05, shl(0x01, gt(_ident, 0x03))), 0x01)) + mstore(0x80, shl(sub(0x05, shl(0x01, gt(_ident, 0x03))), 0x01)) // Store the part offset of the data - mstore(0x80, _partOffset) + mstore(0xA0, _partOffset) // Attempt to add the local data to the preimage oracle and bubble up the revert // if it fails. - if iszero(call(gas(), oracle, 0x00, 0x1C, 0x84, 0x00, 0x00)) { + if iszero(call(gas(), oracle, 0x00, 0x1C, 0xA4, 0x00, 0x00)) { returndatacopy(0x00, 0x00, returndatasize()) revert(0x00, returndatasize()) } diff --git a/packages/contracts-bedrock/src/dispute/interfaces/IBigStepper.sol b/packages/contracts-bedrock/src/dispute/interfaces/IBigStepper.sol index 36834d2632b09..39265bc5721a0 100644 --- a/packages/contracts-bedrock/src/dispute/interfaces/IBigStepper.sol +++ b/packages/contracts-bedrock/src/dispute/interfaces/IBigStepper.sol @@ -29,8 +29,16 @@ interface IBigStepper { /// hash. /// @param _stateData The preimage of the prestate hash. /// @param _proof A proof for the inclusion of the prestate's memory in the merkle tree. + /// @param _localContext The local key context for the preimage oracle. Optional, can be set as a constant + /// if the caller only requires one set of local keys. /// @return postState_ The poststate hash after the instruction step. - function step(bytes calldata _stateData, bytes calldata _proof) external returns (bytes32 postState_); + function step( + bytes calldata _stateData, + bytes calldata _proof, + uint256 _localContext + ) + external + returns (bytes32 postState_); /// @notice Returns the preimage oracle used by the stepper. function oracle() external view returns (IPreimageOracle oracle_); diff --git a/packages/contracts-bedrock/src/dispute/interfaces/IFaultDisputeGame.sol b/packages/contracts-bedrock/src/dispute/interfaces/IFaultDisputeGame.sol index c6506599e9e25..452770de98329 100644 --- a/packages/contracts-bedrock/src/dispute/interfaces/IFaultDisputeGame.sol +++ b/packages/contracts-bedrock/src/dispute/interfaces/IFaultDisputeGame.sol @@ -70,8 +70,10 @@ interface IFaultDisputeGame is IDisputeGame { /// @notice Posts the requested local data to the VM's `PreimageOralce`. /// @param _ident The local identifier of the data to post. + /// @param _l2BlockNumber The L2 block number being disputed. This serves as the local context for the + /// `PreimageOracle` key. /// @param _partOffset The offset of the data to post. - function addLocalData(uint256 _ident, uint256 _partOffset) external; + function addLocalData(uint256 _ident, uint256 _l2BlockNumber, uint256 _partOffset) external; /// @notice Resolves the subgame rooted at the given claim index. /// @dev This function must be called bottom-up in the DAG diff --git a/packages/contracts-bedrock/src/periphery/drippie/dripchecks/CheckBalanceHigh.sol b/packages/contracts-bedrock/src/periphery/drippie/dripchecks/CheckBalanceHigh.sol deleted file mode 100644 index b531c93acb448..0000000000000 --- a/packages/contracts-bedrock/src/periphery/drippie/dripchecks/CheckBalanceHigh.sol +++ /dev/null @@ -1,25 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity 0.8.15; - -import { IDripCheck } from "../IDripCheck.sol"; - -/// @title CheckBalanceHigh -/// @notice DripCheck for checking if an account's balance is above a given threshold. -contract CheckBalanceHigh is IDripCheck { - struct Params { - address target; - uint256 threshold; - } - - /// @notice External event used to help client-side tooling encode parameters. - /// @param params Parameters to encode. - event _EventToExposeStructInABI__Params(Params params); - - /// @inheritdoc IDripCheck - function check(bytes memory _params) external view returns (bool execute_) { - Params memory params = abi.decode(_params, (Params)); - - // Check target balance is above threshold. - execute_ = params.target.balance > params.threshold; - } -} diff --git a/packages/contracts-bedrock/src/periphery/faucet/authmodules/AdminFaucetAuthModule.sol b/packages/contracts-bedrock/src/periphery/faucet/authmodules/AdminFaucetAuthModule.sol index d162b5b2b4ec9..115810d9d1392 100644 --- a/packages/contracts-bedrock/src/periphery/faucet/authmodules/AdminFaucetAuthModule.sol +++ b/packages/contracts-bedrock/src/periphery/faucet/authmodules/AdminFaucetAuthModule.sol @@ -14,7 +14,7 @@ contract AdminFaucetAuthModule is IFaucetAuthModule, EIP712 { address public immutable ADMIN; /// @notice EIP712 typehash for the Proof type. - bytes32 public constant PROOF_TYPEHASH = keccak256("Proof(address recipient,bytes32 nonce,bytes32 id)"); + bytes32 public immutable PROOF_TYPEHASH = keccak256("Proof(address recipient,bytes32 nonce,bytes32 id)"); /// @notice Struct that represents a proof that verifies the admin. /// @custom:field recipient Address that will be receiving the faucet funds. diff --git a/packages/contracts-bedrock/src/periphery/op-nft/AttestationStation.sol b/packages/contracts-bedrock/src/periphery/op-nft/AttestationStation.sol index c36beb497f721..b9af730a71d4a 100644 --- a/packages/contracts-bedrock/src/periphery/op-nft/AttestationStation.sol +++ b/packages/contracts-bedrock/src/periphery/op-nft/AttestationStation.sol @@ -1,13 +1,13 @@ // SPDX-License-Identifier: MIT pragma solidity 0.8.15; -import { Semver } from "../../universal/Semver.sol"; +import { ISemver } from "src/universal/ISemver.sol"; /// @title AttestationStation /// @author Optimism Collective /// @author Gitcoin /// @notice Where attestations live. -contract AttestationStation is Semver { +contract AttestationStation is ISemver { /// @notice Struct representing data that is being attested. /// @custom:field about Address for which the attestation is about. /// @custom:field key A bytes32 key for the attestation. @@ -28,8 +28,9 @@ contract AttestationStation is Semver { /// @param val Value of the attestation. event AttestationCreated(address indexed creator, address indexed about, bytes32 indexed key, bytes val); - /// @custom:semver 1.1.2 - constructor() Semver(1, 1, 2) { } + /// @notice Semantic version. + /// @custom:semver 1.2.0 + string public constant version = "1.2.0"; /// @notice Allows anyone to create an attestation. /// @param _about Address that the attestation is about. diff --git a/packages/contracts-bedrock/src/periphery/op-nft/Optimist.sol b/packages/contracts-bedrock/src/periphery/op-nft/Optimist.sol index 9fef8007b01c6..74d04b087d865 100644 --- a/packages/contracts-bedrock/src/periphery/op-nft/Optimist.sol +++ b/packages/contracts-bedrock/src/periphery/op-nft/Optimist.sol @@ -1,18 +1,18 @@ // SPDX-License-Identifier: MIT pragma solidity 0.8.15; -import { Semver } from "../../universal/Semver.sol"; +import { ISemver } from "src/universal/ISemver.sol"; import { ERC721BurnableUpgradeable } from "@openzeppelin/contracts-upgradeable/token/ERC721/extensions/ERC721BurnableUpgradeable.sol"; -import { AttestationStation } from "./AttestationStation.sol"; -import { OptimistAllowlist } from "./OptimistAllowlist.sol"; +import { AttestationStation } from "src/periphery/op-nft/AttestationStation.sol"; +import { OptimistAllowlist } from "src/periphery/op-nft/OptimistAllowlist.sol"; import { Strings } from "@openzeppelin/contracts/utils/Strings.sol"; /// @author Optimism Collective /// @author Gitcoin /// @title Optimist /// @notice A Soul Bound Token for real humans only(tm). -contract Optimist is ERC721BurnableUpgradeable, Semver { +contract Optimist is ERC721BurnableUpgradeable, ISemver { /// @notice Attestation key used by the attestor to attest the baseURI. bytes32 public constant BASE_URI_ATTESTATION_KEY = bytes32("optimist.base-uri"); @@ -25,7 +25,10 @@ contract Optimist is ERC721BurnableUpgradeable, Semver { /// @notice Address of the OptimistAllowlist contract. OptimistAllowlist public immutable OPTIMIST_ALLOWLIST; - /// @custom:semver 2.0.2 + /// @notice Semantic version. + /// @custom:semver 2.1.0 + string public constant version = "2.1.0"; + /// @param _name Token name. /// @param _symbol Token symbol. /// @param _baseURIAttestor Address of the baseURI attestor. @@ -37,9 +40,7 @@ contract Optimist is ERC721BurnableUpgradeable, Semver { address _baseURIAttestor, AttestationStation _attestationStation, OptimistAllowlist _optimistAllowlist - ) - Semver(2, 0, 2) - { + ) { BASE_URI_ATTESTOR = _baseURIAttestor; ATTESTATION_STATION = _attestationStation; OPTIMIST_ALLOWLIST = _optimistAllowlist; diff --git a/packages/contracts-bedrock/src/periphery/op-nft/OptimistAllowlist.sol b/packages/contracts-bedrock/src/periphery/op-nft/OptimistAllowlist.sol index ad576261bed61..b8212a37c6744 100644 --- a/packages/contracts-bedrock/src/periphery/op-nft/OptimistAllowlist.sol +++ b/packages/contracts-bedrock/src/periphery/op-nft/OptimistAllowlist.sol @@ -1,15 +1,15 @@ // SPDX-License-Identifier: MIT pragma solidity 0.8.15; -import { Semver } from "../../universal/Semver.sol"; -import { AttestationStation } from "./AttestationStation.sol"; -import { OptimistConstants } from "./libraries/OptimistConstants.sol"; +import { ISemver } from "src/universal/ISemver.sol"; +import { AttestationStation } from "src/periphery/op-nft/AttestationStation.sol"; +import { OptimistConstants } from "src/periphery/op-nft/libraries/OptimistConstants.sol"; /// @title OptimistAllowlist /// @notice Source of truth for whether an address is able to mint an Optimist NFT. /// isAllowedToMint function checks various signals to return boolean value /// for whether an address is eligible or not. -contract OptimistAllowlist is Semver { +contract OptimistAllowlist is ISemver { /// @notice Attestation key used by the AllowlistAttestor to manually add addresses to the /// allowlist. bytes32 public constant OPTIMIST_CAN_MINT_ATTESTATION_KEY = bytes32("optimist.can-mint"); @@ -30,7 +30,10 @@ contract OptimistAllowlist is Semver { /// attestations. address public immutable OPTIMIST_INVITER; - /// @custom:semver 1.0.2 + /// @notice Semantic version. + /// @custom:semver 1.1.0 + string public constant version = "1.1.0"; + /// @param _attestationStation Address of the AttestationStation contract. /// @param _allowlistAttestor Address of the allowlist attestor. /// @param _coinbaseQuestAttestor Address of the Coinbase Quest attestor. @@ -40,9 +43,7 @@ contract OptimistAllowlist is Semver { address _allowlistAttestor, address _coinbaseQuestAttestor, address _optimistInviter - ) - Semver(1, 0, 2) - { + ) { ATTESTATION_STATION = _attestationStation; ALLOWLIST_ATTESTOR = _allowlistAttestor; COINBASE_QUEST_ATTESTOR = _coinbaseQuestAttestor; diff --git a/packages/contracts-bedrock/src/periphery/op-nft/OptimistInviter.sol b/packages/contracts-bedrock/src/periphery/op-nft/OptimistInviter.sol index 805a2a648cf70..222405d77c336 100644 --- a/packages/contracts-bedrock/src/periphery/op-nft/OptimistInviter.sol +++ b/packages/contracts-bedrock/src/periphery/op-nft/OptimistInviter.sol @@ -1,9 +1,9 @@ // SPDX-License-Identifier: MIT pragma solidity 0.8.15; -import { OptimistConstants } from "./libraries/OptimistConstants.sol"; -import { Semver } from "../../universal/Semver.sol"; -import { AttestationStation } from "./AttestationStation.sol"; +import { OptimistConstants } from "src/periphery/op-nft/libraries/OptimistConstants.sol"; +import { ISemver } from "src/universal/ISemver.sol"; +import { AttestationStation } from "src/periphery/op-nft/AttestationStation.sol"; import { SignatureChecker } from "@openzeppelin/contracts/utils/cryptography/SignatureChecker.sol"; import { EIP712Upgradeable } from "@openzeppelin/contracts-upgradeable/utils/cryptography/draft-EIP712Upgradeable.sol"; @@ -32,7 +32,7 @@ import { EIP712Upgradeable } from "@openzeppelin/contracts-upgradeable/utils/cry /// 6) claimer waits for the MIN_COMMITMENT_PERIOD to pass. /// 7) claimer reveals the plaintext ClaimableInvite and the signature using the /// claimInvite function, receiving the "optimist.can-mint-from-invite" attestation -contract OptimistInviter is Semver, EIP712Upgradeable { +contract OptimistInviter is ISemver, EIP712Upgradeable { /// @notice Emitted when an invite is claimed. /// @param issuer Address that issued the signature. /// @param claimer Address that claimed the invite. @@ -87,10 +87,13 @@ contract OptimistInviter is Semver, EIP712Upgradeable { /// @notice Maps from addresses to number of invites they have. mapping(address => uint256) public inviteCounts; - /// @custom:semver 1.0.2 + /// @notice Semantic version. + /// @custom:semver 1.1.0 + string public constant version = "1.1.0"; + /// @param _inviteGranter Address of the invite granter. /// @param _attestationStation Address of the AttestationStation contract. - constructor(address _inviteGranter, AttestationStation _attestationStation) Semver(1, 0, 2) { + constructor(address _inviteGranter, AttestationStation _attestationStation) { INVITE_GRANTER = _inviteGranter; ATTESTATION_STATION = _attestationStation; } diff --git a/packages/contracts-bedrock/src/universal/CrossDomainMessenger.sol b/packages/contracts-bedrock/src/universal/CrossDomainMessenger.sol index 017699618cab8..6243266bb31c0 100644 --- a/packages/contracts-bedrock/src/universal/CrossDomainMessenger.sol +++ b/packages/contracts-bedrock/src/universal/CrossDomainMessenger.sol @@ -2,10 +2,10 @@ pragma solidity 0.8.15; import { Initializable } from "@openzeppelin/contracts-upgradeable/proxy/utils/Initializable.sol"; -import { SafeCall } from "../libraries/SafeCall.sol"; -import { Hashing } from "../libraries/Hashing.sol"; -import { Encoding } from "../libraries/Encoding.sol"; -import { Constants } from "../libraries/Constants.sol"; +import { SafeCall } from "src/libraries/SafeCall.sol"; +import { Hashing } from "src/libraries/Hashing.sol"; +import { Encoding } from "src/libraries/Encoding.sol"; +import { Constants } from "src/libraries/Constants.sol"; /// @custom:legacy /// @title CrossDomainMessengerLegacySpacer0 diff --git a/packages/contracts-bedrock/src/universal/ERC721Bridge.sol b/packages/contracts-bedrock/src/universal/ERC721Bridge.sol index 0a42b4c1f000d..9c50cb6f41acb 100644 --- a/packages/contracts-bedrock/src/universal/ERC721Bridge.sol +++ b/packages/contracts-bedrock/src/universal/ERC721Bridge.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity 0.8.15; -import { CrossDomainMessenger } from "./CrossDomainMessenger.sol"; +import { CrossDomainMessenger } from "src/universal/CrossDomainMessenger.sol"; import { Address } from "@openzeppelin/contracts/utils/Address.sol"; import { Initializable } from "@openzeppelin/contracts/proxy/utils/Initializable.sol"; diff --git a/packages/contracts-bedrock/src/universal/FeeVault.sol b/packages/contracts-bedrock/src/universal/FeeVault.sol index 9ac3bf6d3c7d4..626251c7a9717 100644 --- a/packages/contracts-bedrock/src/universal/FeeVault.sol +++ b/packages/contracts-bedrock/src/universal/FeeVault.sol @@ -1,8 +1,8 @@ // SPDX-License-Identifier: MIT pragma solidity 0.8.15; -import { L2StandardBridge } from "../L2/L2StandardBridge.sol"; -import { Predeploys } from "../libraries/Predeploys.sol"; +import { L2StandardBridge } from "src/L2/L2StandardBridge.sol"; +import { Predeploys } from "src/libraries/Predeploys.sol"; /// @title FeeVault /// @notice The FeeVault contract contains the basic logic for the various different vault contracts diff --git a/packages/contracts-bedrock/src/universal/OptimismMintableERC20.sol b/packages/contracts-bedrock/src/universal/OptimismMintableERC20.sol index dbf14de1a950b..43ddd65424f89 100644 --- a/packages/contracts-bedrock/src/universal/OptimismMintableERC20.sol +++ b/packages/contracts-bedrock/src/universal/OptimismMintableERC20.sol @@ -3,8 +3,8 @@ pragma solidity 0.8.15; import { ERC20 } from "@openzeppelin/contracts/token/ERC20/ERC20.sol"; import { IERC165 } from "@openzeppelin/contracts/utils/introspection/IERC165.sol"; -import { ILegacyMintableERC20, IOptimismMintableERC20 } from "./IOptimismMintableERC20.sol"; -import { Semver } from "../universal/Semver.sol"; +import { ILegacyMintableERC20, IOptimismMintableERC20 } from "src/universal/IOptimismMintableERC20.sol"; +import { ISemver } from "src/universal/ISemver.sol"; /// @title OptimismMintableERC20 /// @notice OptimismMintableERC20 is a standard extension of the base ERC20 token contract designed @@ -12,7 +12,7 @@ import { Semver } from "../universal/Semver.sol"; /// use an OptimismMintablERC20 as the L2 representation of an L1 token, or vice-versa. /// Designed to be backwards compatible with the older StandardL2ERC20 token which was only /// meant for use on L2. -contract OptimismMintableERC20 is IOptimismMintableERC20, ILegacyMintableERC20, ERC20, Semver { +contract OptimismMintableERC20 is IOptimismMintableERC20, ILegacyMintableERC20, ERC20, ISemver { /// @notice Address of the corresponding version of this token on the remote chain. address public immutable REMOTE_TOKEN; @@ -38,7 +38,10 @@ contract OptimismMintableERC20 is IOptimismMintableERC20, ILegacyMintableERC20, _; } - /// @custom:semver 1.2.0 + /// @notice Semantic version. + /// @custom:semver 1.3.0 + string public constant version = "1.3.0"; + /// @param _bridge Address of the L2 standard bridge. /// @param _remoteToken Address of the corresponding L1 token. /// @param _name ERC20 name. @@ -51,7 +54,6 @@ contract OptimismMintableERC20 is IOptimismMintableERC20, ILegacyMintableERC20, uint8 _decimals ) ERC20(_name, _symbol) - Semver(1, 2, 0) { REMOTE_TOKEN = _remoteToken; BRIDGE = _bridge; diff --git a/packages/contracts-bedrock/src/universal/OptimismMintableERC20Factory.sol b/packages/contracts-bedrock/src/universal/OptimismMintableERC20Factory.sol index 4cae13fec055d..c254dab3802bc 100644 --- a/packages/contracts-bedrock/src/universal/OptimismMintableERC20Factory.sol +++ b/packages/contracts-bedrock/src/universal/OptimismMintableERC20Factory.sol @@ -32,8 +32,8 @@ contract OptimismMintableERC20Factory is ISemver, Initializable { event OptimismMintableERC20Created(address indexed localToken, address indexed remoteToken, address deployer); /// @notice Semantic version. - /// @custom:semver 1.6.0 - string public constant version = "1.6.0"; + /// @custom:semver 1.7.0 + string public constant version = "1.7.0"; /// @notice The semver MUST be bumped any time that there is a change in /// the OptimismMintableERC20 token contract since this contract diff --git a/packages/contracts-bedrock/src/universal/Proxy.sol b/packages/contracts-bedrock/src/universal/Proxy.sol index 031f79a36c5fb..0325a61d3aabe 100644 --- a/packages/contracts-bedrock/src/universal/Proxy.sol +++ b/packages/contracts-bedrock/src/universal/Proxy.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity 0.8.15; -import { Constants } from "../libraries/Constants.sol"; +import { Constants } from "src/libraries/Constants.sol"; /// @title Proxy /// @notice Proxy is a transparent proxy that passes through the call if the caller is the owner or diff --git a/packages/contracts-bedrock/src/universal/ProxyAdmin.sol b/packages/contracts-bedrock/src/universal/ProxyAdmin.sol index 186ed39fef25c..8558d421bb46f 100644 --- a/packages/contracts-bedrock/src/universal/ProxyAdmin.sol +++ b/packages/contracts-bedrock/src/universal/ProxyAdmin.sol @@ -2,10 +2,10 @@ pragma solidity 0.8.15; import { Ownable } from "@openzeppelin/contracts/access/Ownable.sol"; -import { Proxy } from "./Proxy.sol"; -import { AddressManager } from "../legacy/AddressManager.sol"; -import { L1ChugSplashProxy } from "../legacy/L1ChugSplashProxy.sol"; -import { Constants } from "../libraries/Constants.sol"; +import { Proxy } from "src/universal/Proxy.sol"; +import { AddressManager } from "src/legacy/AddressManager.sol"; +import { L1ChugSplashProxy } from "src/legacy/L1ChugSplashProxy.sol"; +import { Constants } from "src/libraries/Constants.sol"; /// @title IStaticERC1967Proxy /// @notice IStaticERC1967Proxy is a static version of the ERC1967 proxy interface. diff --git a/packages/contracts-bedrock/src/universal/Semver.sol b/packages/contracts-bedrock/src/universal/Semver.sol deleted file mode 100644 index 5f81053a776aa..0000000000000 --- a/packages/contracts-bedrock/src/universal/Semver.sol +++ /dev/null @@ -1,40 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity ^0.8.0; - -import { Strings } from "@openzeppelin/contracts/utils/Strings.sol"; - -/// @title Semver -/// @notice Semver is a simple contract for managing contract versions. -contract Semver { - /// @notice Contract version number (major). - uint256 private immutable MAJOR_VERSION; - - /// @notice Contract version number (minor). - uint256 private immutable MINOR_VERSION; - - /// @notice Contract version number (patch). - uint256 private immutable PATCH_VERSION; - - /// @param _major Version number (major). - /// @param _minor Version number (minor). - /// @param _patch Version number (patch). - constructor(uint256 _major, uint256 _minor, uint256 _patch) { - MAJOR_VERSION = _major; - MINOR_VERSION = _minor; - PATCH_VERSION = _patch; - } - - /// @notice Returns the full semver contract version. - /// @return Semver contract version as a string. - function version() public view returns (string memory) { - return string( - abi.encodePacked( - Strings.toString(MAJOR_VERSION), - ".", - Strings.toString(MINOR_VERSION), - ".", - Strings.toString(PATCH_VERSION) - ) - ); - } -} diff --git a/packages/contracts-bedrock/src/universal/StandardBridge.sol b/packages/contracts-bedrock/src/universal/StandardBridge.sol index 0f7f111673d06..665d75ee4cbeb 100644 --- a/packages/contracts-bedrock/src/universal/StandardBridge.sol +++ b/packages/contracts-bedrock/src/universal/StandardBridge.sol @@ -5,10 +5,10 @@ import { IERC20 } from "@openzeppelin/contracts/token/ERC20/IERC20.sol"; import { ERC165Checker } from "@openzeppelin/contracts/utils/introspection/ERC165Checker.sol"; import { Address } from "@openzeppelin/contracts/utils/Address.sol"; import { SafeERC20 } from "@openzeppelin/contracts/token/ERC20/utils/SafeERC20.sol"; -import { SafeCall } from "../libraries/SafeCall.sol"; -import { IOptimismMintableERC20, ILegacyMintableERC20 } from "./IOptimismMintableERC20.sol"; -import { CrossDomainMessenger } from "./CrossDomainMessenger.sol"; -import { OptimismMintableERC20 } from "./OptimismMintableERC20.sol"; +import { SafeCall } from "src/libraries/SafeCall.sol"; +import { IOptimismMintableERC20, ILegacyMintableERC20 } from "src/universal/IOptimismMintableERC20.sol"; +import { CrossDomainMessenger } from "src/universal/CrossDomainMessenger.sol"; +import { OptimismMintableERC20 } from "src/universal/OptimismMintableERC20.sol"; import { Initializable } from "@openzeppelin/contracts/proxy/utils/Initializable.sol"; /// @custom:upgradeable diff --git a/packages/contracts-bedrock/src/universal/StorageSetter.sol b/packages/contracts-bedrock/src/universal/StorageSetter.sol index dcf07dba451a7..375ecdca5f63e 100644 --- a/packages/contracts-bedrock/src/universal/StorageSetter.sol +++ b/packages/contracts-bedrock/src/universal/StorageSetter.sol @@ -9,9 +9,15 @@ import { Storage } from "src/libraries/Storage.sol"; /// WARNING: this contract is not safe to be called by untrusted parties. /// It is only meant as an intermediate step during upgrades. contract StorageSetter is ISemver { + /// @notice Represents a storage slot key value pair. + struct Slot { + bytes32 key; + bytes32 value; + } + /// @notice Semantic version. - /// @custom:semver 1.0.0 - string public constant version = "1.0.0"; + /// @custom:semver 1.1.0 + string public constant version = "1.1.0"; /// @notice Stores a bytes32 `_value` at `_slot`. Any storage slots that /// are packed should be set through this interface. @@ -19,6 +25,14 @@ contract StorageSetter is ISemver { Storage.setBytes32(_slot, _value); } + /// @notice Stores a bytes32 value at each key in `_slots`. + function setBytes32(Slot[] calldata slots) public { + uint256 length = slots.length; + for (uint256 i; i < length; i++) { + Storage.setBytes32(slots[i].key, slots[i].value); + } + } + /// @notice Retrieves a bytes32 value from `_slot`. function getBytes32(bytes32 _slot) external view returns (bytes32) { return Storage.getBytes32(_slot); diff --git a/packages/contracts-bedrock/test-case-generator/README.md b/packages/contracts-bedrock/test-case-generator/README.md deleted file mode 100644 index 1cd4af47c09c8..0000000000000 --- a/packages/contracts-bedrock/test-case-generator/README.md +++ /dev/null @@ -1,34 +0,0 @@ -# `ctb-test-case-generator` - -A lightweight input fuzzing utility used for testing various Bedrock contracts. - -
-├── test-case-generator
-│   ├── cmd: `ctb-test-case-genertor`'s binary
-│   └── trie: Utility for generating random merkle trie roots / inclusion proofs
-
- -## Usage - -To build, run `pnpm build:fuzz` from this directory or the `contract-bedrock` package. - -To generate an abi-encoded fuzz case, pass in a mode via the `-m` flag as well as an optional variant via the `-v` flag. - -### Available Modes - -#### `trie` - -> **Note** -> Variant required for `trie` mode. - -| Variant | Description | -| ----------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------- | -| `valid` | Generate a test case with a valid proof of inclusion for the k/v pair in the trie. | -| `extra_proof_elems` | Generate an invalid test case with an extra proof element attached to an otherwise valid proof of inclusion for the passed k/v. | -| `corrupted_proof` | Generate an invalid test case where the proof is malformed. | -| `invalid_data_remainder` | Generate an invalid test case where a random element of the proof has more bytes than the length designates within the RLP list encoding. | -| `invalid_large_internal_hash` | Generate an invalid test case where a long proof element is incorrect for the root. | -| `invalid_internal_node_hash` | Generate an invalid test case where a small proof element is incorrect for the root. | -| `prefixed_valid_key` | Generate a valid test case with a key that has been given a random prefix | -| `empty_key` | Generate a valid test case with a proof of inclusion for an empty key. | -| `partial_proof` | Generate an invalid test case with a partially correct proof | diff --git a/packages/contracts-bedrock/test-case-generator/cmd/fuzz.go b/packages/contracts-bedrock/test-case-generator/cmd/fuzz.go deleted file mode 100644 index b1516ce77d1e3..0000000000000 --- a/packages/contracts-bedrock/test-case-generator/cmd/fuzz.go +++ /dev/null @@ -1,31 +0,0 @@ -package main - -import ( - "flag" - "log" - - t "github.com/ethereum-optimism/optimism/packages/contracts-bedrock/ctb-test-case-generator/trie" -) - -// Mode enum -const ( - // Enables the `trie` fuzzer - trie string = "trie" -) - -func main() { - mode := flag.String("m", "", "Fuzzer mode") - variant := flag.String("v", "", "Mode variant") - flag.Parse() - - if len(*mode) < 1 { - log.Fatal("Must pass a mode for the fuzzer!") - } - - switch *mode { - case trie: - t.FuzzTrie(*variant) - default: - log.Fatal("Invalid mode!") - } -} diff --git a/packages/contracts-bedrock/test-case-generator/go.mod b/packages/contracts-bedrock/test-case-generator/go.mod deleted file mode 100644 index 061d0da0637b1..0000000000000 --- a/packages/contracts-bedrock/test-case-generator/go.mod +++ /dev/null @@ -1,26 +0,0 @@ -module github.com/ethereum-optimism/optimism/packages/contracts-bedrock/ctb-test-case-generator - -go 1.20 - -require github.com/ethereum/go-ethereum v1.10.26 - -require ( - github.com/StackExchange/wmi v0.0.0-20180116203802-5d049714c4a6 // indirect - github.com/VictoriaMetrics/fastcache v1.6.0 // indirect - github.com/btcsuite/btcd/btcec/v2 v2.2.0 // indirect - github.com/cespare/xxhash/v2 v2.1.1 // indirect - github.com/decred/dcrd/dcrec/secp256k1/v4 v4.0.1 // indirect - github.com/go-ole/go-ole v1.2.1 // indirect - github.com/go-stack/stack v1.8.0 // indirect - github.com/golang/snappy v0.0.4 // indirect - github.com/mattn/go-runewidth v0.0.9 // indirect - github.com/olekukonko/tablewriter v0.0.5 // indirect - github.com/pkg/errors v0.9.1 // indirect - github.com/prometheus/tsdb v0.7.1 // indirect - github.com/shirou/gopsutil v3.21.4-0.20210419000835-c7a38de76ee5+incompatible // indirect - github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7 // indirect - github.com/tklauser/go-sysconf v0.3.5 // indirect - github.com/tklauser/numcpus v0.2.2 // indirect - golang.org/x/crypto v0.1.0 // indirect - golang.org/x/sys v0.1.0 // indirect -) diff --git a/packages/contracts-bedrock/test-case-generator/go.sum b/packages/contracts-bedrock/test-case-generator/go.sum deleted file mode 100644 index 3f846df0ffedc..0000000000000 --- a/packages/contracts-bedrock/test-case-generator/go.sum +++ /dev/null @@ -1,141 +0,0 @@ -github.com/OneOfOne/xxhash v1.2.2/go.mod h1:HSdplMjZKSmBqAxg5vPj2TmRDmfkzw+cTzAElWljhcU= -github.com/StackExchange/wmi v0.0.0-20180116203802-5d049714c4a6 h1:fLjPD/aNc3UIOA6tDi6QXUemppXK3P9BI7mr2hd6gx8= -github.com/StackExchange/wmi v0.0.0-20180116203802-5d049714c4a6/go.mod h1:3eOhrUMpNV+6aFIbp5/iudMxNCF27Vw2OZgy4xEx0Fg= -github.com/VictoriaMetrics/fastcache v1.6.0 h1:C/3Oi3EiBCqufydp1neRZkqcwmEiuRT9c3fqvvgKm5o= -github.com/VictoriaMetrics/fastcache v1.6.0/go.mod h1:0qHz5QP0GMX4pfmMA/zt5RgfNuXJrTP0zS7DqpHGGTw= -github.com/alecthomas/template v0.0.0-20160405071501-a0175ee3bccc/go.mod h1:LOuyumcjzFXgccqObfd/Ljyb9UuFJ6TxHnclSeseNhc= -github.com/alecthomas/units v0.0.0-20151022065526-2efee857e7cf/go.mod h1:ybxpYRFXyAe+OPACYpWeL0wqObRcbAqCMya13uyzqw0= -github.com/allegro/bigcache v1.2.1-0.20190218064605-e24eb225f156 h1:eMwmnE/GDgah4HI848JfFxHt+iPb26b4zyfspmqY0/8= -github.com/allegro/bigcache v1.2.1-0.20190218064605-e24eb225f156/go.mod h1:Cb/ax3seSYIx7SuZdm2G2xzfwmv3TPSk2ucNfQESPXM= -github.com/beorn7/perks v0.0.0-20180321164747-3a771d992973/go.mod h1:Dwedo/Wpr24TaqPxmxbtue+5NUziq4I4S80YR8gNf3Q= -github.com/btcsuite/btcd/btcec/v2 v2.2.0 h1:fzn1qaOt32TuLjFlkzYSsBC35Q3KUjT1SwPxiMSCF5k= -github.com/btcsuite/btcd/btcec/v2 v2.2.0/go.mod h1:U7MHm051Al6XmscBQ0BoNydpOTsFAn707034b5nY8zU= -github.com/btcsuite/btcd/chaincfg/chainhash v1.0.1 h1:q0rUy8C/TYNBQS1+CGKw68tLOFYSNEs0TFnxxnS9+4U= -github.com/cespare/xxhash v1.1.0/go.mod h1:XrSqR1VqqWfGrhpAt58auRo0WTKS1nRRg3ghfAqPWnc= -github.com/cespare/xxhash/v2 v2.1.1 h1:6MnRN8NT7+YBpUIWxHtefFZOKTAPgGjpQSxqLNn0+qY= -github.com/cespare/xxhash/v2 v2.1.1/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= -github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= -github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c= -github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= -github.com/decred/dcrd/crypto/blake256 v1.0.0 h1:/8DMNYp9SGi5f0w7uCm6d6M4OU2rGFK09Y2A4Xv7EE0= -github.com/decred/dcrd/crypto/blake256 v1.0.0/go.mod h1:sQl2p6Y26YV+ZOcSTP6thNdn47hh8kt6rqSlvmrXFAc= -github.com/decred/dcrd/dcrec/secp256k1/v4 v4.0.1 h1:YLtO71vCjJRCBcrPMtQ9nqBsqpA1m5sE92cU+pd5Mcc= -github.com/decred/dcrd/dcrec/secp256k1/v4 v4.0.1/go.mod h1:hyedUtir6IdtD/7lIxGeCxkaw7y45JueMRL4DIyJDKs= -github.com/dgryski/go-sip13 v0.0.0-20181026042036-e10d5fee7954/go.mod h1:vAd38F8PWV+bWy6jNmig1y/TA+kYO4g3RSRF0IAv0no= -github.com/ethereum/go-ethereum v1.10.26 h1:i/7d9RBBwiXCEuyduBQzJw/mKmnvzsN14jqBmytw72s= -github.com/ethereum/go-ethereum v1.10.26/go.mod h1:EYFyF19u3ezGLD4RqOkLq+ZCXzYbLoNDdZlMt7kyKFg= -github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo= -github.com/fsnotify/fsnotify v1.4.9 h1:hsms1Qyu0jgnwNXIxa+/V/PDsU6CfLf6CNO8H7IWoS4= -github.com/fsnotify/fsnotify v1.4.9/go.mod h1:znqG4EE+3YCdAaPaxE2ZRY/06pZUdp0tY4IgpuI1SZQ= -github.com/go-kit/kit v0.8.0 h1:Wz+5lgoB0kkuqLEc6NVmwRknTKP6dTGbSqvhZtBI/j0= -github.com/go-kit/kit v0.8.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as= -github.com/go-logfmt/logfmt v0.3.0/go.mod h1:Qt1PoO58o5twSAckw1HlFXLmHsOX5/0LbT9GBnD5lWE= -github.com/go-logfmt/logfmt v0.4.0 h1:MP4Eh7ZCb31lleYCFuwm0oe4/YGak+5l1vA2NOE80nA= -github.com/go-ole/go-ole v1.2.1 h1:2lOsA72HgjxAuMlKpFiCbHTvu44PIVkZ5hqm3RSdI/E= -github.com/go-ole/go-ole v1.2.1/go.mod h1:7FAglXiTm7HKlQRDeOQ6ZNUHidzCWXuZWq/1dTyBNF8= -github.com/go-stack/stack v1.8.0 h1:5SgMzNM5HxrEjV0ww2lTmX6E2Izsfxas4+YHWRs3Lsk= -github.com/go-stack/stack v1.8.0/go.mod h1:v0f6uXyyMGvRgIKkXu+yp6POWl0qKG85gN/melR3HDY= -github.com/gogo/protobuf v1.1.1/go.mod h1:r8qH/GZQm5c6nD/R0oafs1akxWv10x8SbQlK7atdtwQ= -github.com/golang/protobuf v1.2.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= -github.com/golang/protobuf v1.4.0-rc.1/go.mod h1:ceaxUfeHdC40wWswd/P6IGgMaK3YpKi5j83Wpe3EHw8= -github.com/golang/protobuf v1.4.0-rc.1.0.20200221234624-67d41d38c208/go.mod h1:xKAWHe0F5eneWXFV3EuXVDTCmh+JuBKY0li0aMyXATA= -github.com/golang/protobuf v1.4.0-rc.2/go.mod h1:LlEzMj4AhA7rCAGe4KMBDvJI+AwstrUpVNzEA03Pprs= -github.com/golang/protobuf v1.4.0-rc.4.0.20200313231945-b860323f09d0/go.mod h1:WU3c8KckQ9AFe+yFwt9sWVRKCVIyN9cPHBJSNnbL67w= -github.com/golang/protobuf v1.4.0/go.mod h1:jodUvKwWbYaEsadDk5Fwe5c77LiNKVO9IDvqG2KuDX0= -github.com/golang/protobuf v1.4.2/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI= -github.com/golang/snappy v0.0.3/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= -github.com/golang/snappy v0.0.4 h1:yAGX7huGHXlcLOEtBnF4w7FQwA26wojNCwOYAEhLjQM= -github.com/golang/snappy v0.0.4/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= -github.com/google/go-cmp v0.3.0/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU= -github.com/google/go-cmp v0.3.1/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU= -github.com/google/go-cmp v0.4.0/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= -github.com/hpcloud/tail v1.0.0/go.mod h1:ab1qPbhIpdTxEkNHXyeSf5vhxWSCs/tWer42PpOxQnU= -github.com/kr/logfmt v0.0.0-20140226030751-b84e30acd515 h1:T+h1c/A9Gawja4Y9mFVWj2vyii2bbUNDw3kt9VxK2EY= -github.com/kr/logfmt v0.0.0-20140226030751-b84e30acd515/go.mod h1:+0opPa2QZZtGFBFZlji/RkVcI2GknAs/DXo4wKdlNEc= -github.com/mattn/go-runewidth v0.0.9 h1:Lm995f3rfxdpd6TSmuVCHVb/QhupuXlYr8sCI/QdE+0= -github.com/mattn/go-runewidth v0.0.9/go.mod h1:H031xJmbD/WCDINGzjvQ9THkh0rPKHF+m2gUSrubnMI= -github.com/matttproud/golang_protobuf_extensions v1.0.1/go.mod h1:D8He9yQNgCq6Z5Ld7szi9bcBfOoFv/3dc6xSMkL2PC0= -github.com/nxadm/tail v1.4.4 h1:DQuhQpB1tVlglWS2hLQ5OV6B5r8aGxSrPc5Qo6uTN78= -github.com/nxadm/tail v1.4.4/go.mod h1:kenIhsEOeOJmVchQTgglprH7qJGnHDVpk1VPCcaMI8A= -github.com/oklog/ulid v1.3.1/go.mod h1:CirwcVhetQ6Lv90oh/F+FBtV6XMibvdAFo93nm5qn4U= -github.com/olekukonko/tablewriter v0.0.5 h1:P2Ga83D34wi1o9J6Wh1mRuqd4mF/x/lgBS7N7AbDhec= -github.com/olekukonko/tablewriter v0.0.5/go.mod h1:hPp6KlRPjbx+hW8ykQs1w3UBbZlj6HuIJcUGPhkA7kY= -github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= -github.com/onsi/ginkgo v1.12.1/go.mod h1:zj2OWP4+oCPe1qIXoGWkgMRwljMUYCdkwsT2108oapk= -github.com/onsi/ginkgo v1.14.0 h1:2mOpI4JVVPBN+WQRa0WKH2eXR+Ey+uK4n7Zj0aYpIQA= -github.com/onsi/ginkgo v1.14.0/go.mod h1:iSB4RoI2tjJc9BBv4NKIKWKya62Rps+oPG/Lv9klQyY= -github.com/onsi/gomega v1.7.1/go.mod h1:XdKZgCCFLUoM/7CFJVPcG8C1xQ1AJ0vpAezJrB7JYyY= -github.com/onsi/gomega v1.10.1 h1:o0+MgICZLuZ7xjH7Vx6zS/zcu93/BEp1VwkIW1mEXCE= -github.com/onsi/gomega v1.10.1/go.mod h1:iN09h71vgCQne3DLsj+A5owkum+a2tYe+TOCB1ybHNo= -github.com/pkg/errors v0.8.0/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= -github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4= -github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= -github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= -github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= -github.com/prometheus/client_golang v0.9.1/go.mod h1:7SWBe2y4D6OKWSNQJUaRYU/AaXPKyh/dDVn+NZz0KFw= -github.com/prometheus/client_model v0.0.0-20180712105110-5c3871d89910/go.mod h1:MbSGuTsp3dbXC40dX6PRTWyKYBIrTGTE9sqQNg2J8bo= -github.com/prometheus/common v0.0.0-20181113130724-41aa239b4cce/go.mod h1:daVV7qP5qjZbuso7PdcryaAu0sAZbrN9i7WWcTMWvro= -github.com/prometheus/procfs v0.0.0-20181005140218-185b4288413d/go.mod h1:c3At6R/oaqEKCNdg8wHV1ftS6bRYblBhIjjI8uT2IGk= -github.com/prometheus/tsdb v0.7.1 h1:YZcsG11NqnK4czYLrWd9mpEuAJIHVQLwdrleYfszMAA= -github.com/prometheus/tsdb v0.7.1/go.mod h1:qhTCs0VvXwvX/y3TZrWD7rabWM+ijKTux40TwIPHuXU= -github.com/shirou/gopsutil v3.21.4-0.20210419000835-c7a38de76ee5+incompatible h1:Bn1aCHHRnjv4Bl16T8rcaFjYSrGrIZvpiGO6P3Q4GpU= -github.com/shirou/gopsutil v3.21.4-0.20210419000835-c7a38de76ee5+incompatible/go.mod h1:5b4v6he4MtMOwMlS0TUMTu2PcXUg8+E1lC7eC3UO/RA= -github.com/spaolacci/murmur3 v0.0.0-20180118202830-f09979ecbc72/go.mod h1:JwIasOWyU6f++ZhiEuf87xNszmSA2myDM2Kzu9HwQUA= -github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= -github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs= -github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI= -github.com/stretchr/testify v1.7.2 h1:4jaiDzPyXQvSd7D0EjG45355tLlV3VOECpq10pLC+8s= -github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7 h1:epCh84lMvA70Z7CTTCmYQn2CKbY8j86K7/FAIr141uY= -github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7/go.mod h1:q4W45IWZaF22tdD+VEXcAWRA037jwmWEB5VWYORlTpc= -github.com/tklauser/go-sysconf v0.3.5 h1:uu3Xl4nkLzQfXNsWn15rPc/HQCJKObbt1dKJeWp3vU4= -github.com/tklauser/go-sysconf v0.3.5/go.mod h1:MkWzOF4RMCshBAMXuhXJs64Rte09mITnppBXY/rYEFI= -github.com/tklauser/numcpus v0.2.2 h1:oyhllyrScuYI6g+h/zUvNXNp1wy7x8qQy3t/piefldA= -github.com/tklauser/numcpus v0.2.2/go.mod h1:x3qojaO3uyYt0i56EW/VUYs7uBvdl2fkfZFu0T9wgjM= -golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= -golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= -golang.org/x/crypto v0.1.0 h1:MDRAIl0xIo9Io2xV565hzXHw3zVseKrJKodhohM5CjU= -golang.org/x/crypto v0.1.0/go.mod h1:RecgLatLF4+eUMCP1PoPZQb+cVrJcOPbHkTkbkB9sbw= -golang.org/x/net v0.0.0-20180906233101-161cd47e91fd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= -golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= -golang.org/x/net v0.0.0-20200520004742-59133d7f0dd7/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A= -golang.org/x/net v0.0.0-20200813134508-3edf25e44fcc/go.mod h1:/O7V0waA8r7cgGh81Ro3o1hOxt32SMVPicZroKQ2sZA= -golang.org/x/net v0.1.0 h1:hZ/3BUoy5aId7sCpA/Tc5lt8DkFgdVS2onTpJsZ/fl0= -golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.0.0-20181108010431-42b317875d0f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sys v0.0.0-20180909124046-d0be0721c37e/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20181107165924-66b7b1311ac8/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20190904154756-749cb33beabd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20191005200804-aed5e4c7ecf9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20191120155948-bd437916bb0e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200323222414-85ca7c5b95cd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200519105757-fe76b779f299/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200814200057-3d37ad5750ed/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210316164454-77fc1eacc6aa/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210324051608-47abb6519492/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.1.0 h1:kunALQeHf1/185U1i0GOB/fy1IPRDDpuoOOqRReG57U= -golang.org/x/sys v0.1.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= -golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= -golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= -golang.org/x/text v0.4.0 h1:BrVqGRd7+k1DiOgtnFvAkoQEWQvBc25ouMJM6429SFg= -golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= -golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= -golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= -golang.org/x/xerrors v0.0.0-20220517211312-f3a8303e98df h1:5Pf6pFKu98ODmgnpvkJ3kFUOQGGLIzLIkbzUHp47618= -google.golang.org/protobuf v0.0.0-20200109180630-ec00e32a8dfd/go.mod h1:DFci5gLYBciE7Vtevhsrf46CRTquxDuWsQurQQe4oz8= -google.golang.org/protobuf v0.0.0-20200221191635-4d8936d0db64/go.mod h1:kwYJMbMJ01Woi6D6+Kah6886xMZcty6N08ah7+eCXa0= -google.golang.org/protobuf v0.0.0-20200228230310-ab0ca4ff8a60/go.mod h1:cfTl7dwQJ+fmap5saPgwCLgHXTUD7jkjRqWcaiX5VyM= -google.golang.org/protobuf v1.20.1-0.20200309200217-e05f789c0967/go.mod h1:A+miEFZTKqfCUM6K7xSMQL9OKL/b6hQv+e19PK+JZNE= -google.golang.org/protobuf v1.21.0/go.mod h1:47Nbq4nVaFHyn7ilMalzfO3qCViNmqZ2kzikPIcrTAo= -google.golang.org/protobuf v1.23.0/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU= -gopkg.in/alecthomas/kingpin.v2 v2.2.6/go.mod h1:FMv+mEhP44yOT+4EoQTLFTRgOQ1FBLkstjWtayDeSgw= -gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= -gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMys= -gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 h1:uRGJdciOHaEIrze2W8Q3AKkepLTh2hOroT7a+7czfdQ= -gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7/go.mod h1:dt/ZhP58zS4L8KSrWDmTeBkI65Dw0HsyUHuEVlX15mw= -gopkg.in/yaml.v2 v2.2.4/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= -gopkg.in/yaml.v2 v2.3.0/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= -gopkg.in/yaml.v2 v2.4.0 h1:D8xgwECY7CYvx+Y2n4sBz93Jn9JRvxdiyyo8CTfuKaY= -gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= diff --git a/packages/contracts-bedrock/test/AddressAliasHelper.t.sol b/packages/contracts-bedrock/test/AddressAliasHelper.t.sol index d0c5440a5511c..45211879c17fc 100644 --- a/packages/contracts-bedrock/test/AddressAliasHelper.t.sol +++ b/packages/contracts-bedrock/test/AddressAliasHelper.t.sol @@ -2,7 +2,7 @@ pragma solidity 0.8.15; import { Test } from "forge-std/Test.sol"; -import { AddressAliasHelper } from "../src/vendor/AddressAliasHelper.sol"; +import { AddressAliasHelper } from "src/vendor/AddressAliasHelper.sol"; contract AddressAliasHelper_applyAndUndo_Test is Test { /// @notice Tests that applying and then undoing an alias results in the original address. diff --git a/packages/contracts-bedrock/test/AdminFaucetAuthModule.t.sol b/packages/contracts-bedrock/test/AdminFaucetAuthModule.t.sol index 3a59ba7e70a4a..93a10329b4527 100644 --- a/packages/contracts-bedrock/test/AdminFaucetAuthModule.t.sol +++ b/packages/contracts-bedrock/test/AdminFaucetAuthModule.t.sol @@ -2,9 +2,9 @@ pragma solidity 0.8.15; import { Test } from "forge-std/Test.sol"; -import { AdminFaucetAuthModule } from "../src/periphery/faucet/authmodules/AdminFaucetAuthModule.sol"; -import { Faucet } from "../src/periphery/faucet/Faucet.sol"; -import { FaucetHelper } from "./Helpers.sol"; +import { AdminFaucetAuthModule } from "src/periphery/faucet/authmodules/AdminFaucetAuthModule.sol"; +import { Faucet } from "src/periphery/faucet/Faucet.sol"; +import { FaucetHelper } from "test/mocks/FaucetHelper.sol"; /// @title AdminFaucetAuthModuleTest /// @notice Tests the AdminFaucetAuthModule contract. diff --git a/packages/contracts-bedrock/test/AssetReceiver.t.sol b/packages/contracts-bedrock/test/AssetReceiver.t.sol index a7f3693423c74..4ee74e43d1278 100644 --- a/packages/contracts-bedrock/test/AssetReceiver.t.sol +++ b/packages/contracts-bedrock/test/AssetReceiver.t.sol @@ -3,9 +3,9 @@ pragma solidity 0.8.15; // Testing utilities import { Test } from "forge-std/Test.sol"; -import { TestERC20 } from "./Helpers.sol"; -import { TestERC721 } from "./Helpers.sol"; -import { AssetReceiver } from "../src/periphery/AssetReceiver.sol"; +import { TestERC20 } from "test/mocks/TestERC20.sol"; +import { TestERC721 } from "test/mocks/TestERC721.sol"; +import { AssetReceiver } from "src/periphery/AssetReceiver.sol"; contract AssetReceiver_Initializer is Test { address alice = address(128); diff --git a/packages/contracts-bedrock/test/AttestationStation.t.sol b/packages/contracts-bedrock/test/AttestationStation.t.sol index 5d17fcd0e14fa..4c9b72254d347 100644 --- a/packages/contracts-bedrock/test/AttestationStation.t.sol +++ b/packages/contracts-bedrock/test/AttestationStation.t.sol @@ -3,7 +3,7 @@ pragma solidity 0.8.15; /* Testing utilities */ import { Test } from "forge-std/Test.sol"; -import { AttestationStation } from "../src/periphery/op-nft/AttestationStation.sol"; +import { AttestationStation } from "src/periphery/op-nft/AttestationStation.sol"; contract AttestationStation_Initializer is Test { address alice_attestor = address(128); diff --git a/packages/contracts-bedrock/test/BenchmarkTest.t.sol b/packages/contracts-bedrock/test/BenchmarkTest.t.sol index 64b9d982cf7d7..ef5662d17e6db 100644 --- a/packages/contracts-bedrock/test/BenchmarkTest.t.sol +++ b/packages/contracts-bedrock/test/BenchmarkTest.t.sol @@ -4,19 +4,21 @@ pragma solidity 0.8.15; // Testing utilities import { Test } from "forge-std/Test.sol"; import { Vm } from "forge-std/Vm.sol"; -import "./CommonTest.t.sol"; -import { CrossDomainMessenger } from "../src/universal/CrossDomainMessenger.sol"; -import { ResourceMetering } from "../src/L1/ResourceMetering.sol"; +import { CommonTest } from "test/setup/CommonTest.sol"; +import { Bridge_Initializer } from "test/setup/Bridge_Initializer.sol"; +import { CrossDomainMessenger } from "src/universal/CrossDomainMessenger.sol"; +import { ResourceMetering } from "src/L1/ResourceMetering.sol"; +import { Types } from "src/libraries/Types.sol"; // Free function for setting the prevBaseFee param in the OptimismPortal. function setPrevBaseFee(Vm _vm, address _op, uint128 _prevBaseFee) { _vm.store(address(_op), bytes32(uint256(1)), bytes32((block.number << 192) | _prevBaseFee)); } -contract SetPrevBaseFee_Test is Portal_Initializer { +contract SetPrevBaseFee_Test is CommonTest { function test_setPrevBaseFee_succeeds() external { - setPrevBaseFee(vm, address(op), 100 gwei); - (uint128 prevBaseFee,, uint64 prevBlockNum) = op.params(); + setPrevBaseFee(vm, address(optimismPortal), 100 gwei); + (uint128 prevBaseFee,, uint64 prevBlockNum) = optimismPortal.params(); assertEq(uint256(prevBaseFee), 100 gwei); assertEq(uint256(prevBlockNum), block.number); } @@ -27,7 +29,7 @@ contract SetPrevBaseFee_Test is Portal_Initializer { // so that they are nothing more than the call we want measure the gas cost of. // In order to achieve this we make no assertions, and handle everything else in the setUp() // function. -contract GasBenchMark_OptimismPortal is Portal_Initializer { +contract GasBenchMark_OptimismPortal is CommonTest { // Reusable default values for a test withdrawal Types.WithdrawalTransaction _defaultTx; @@ -61,61 +63,64 @@ contract GasBenchMark_OptimismPortal is Portal_Initializer { messagePasserStorageRoot: _storageRoot, latestBlockhash: bytes32(uint256(0)) }); - _proposedBlockNumber = oracle.nextBlockNumber(); - _proposedOutputIndex = oracle.nextOutputIndex(); + _proposedBlockNumber = l2OutputOracle.nextBlockNumber(); + _proposedOutputIndex = l2OutputOracle.nextOutputIndex(); } // Get the system into a nice ready-to-use state. function setUp() public virtual override { // Configure the oracle to return the output root we've prepared. - vm.warp(oracle.computeL2Timestamp(_proposedBlockNumber) + 1); - vm.prank(oracle.PROPOSER()); - oracle.proposeL2Output(_outputRoot, _proposedBlockNumber, 0, 0); + vm.warp(l2OutputOracle.computeL2Timestamp(_proposedBlockNumber) + 1); + vm.prank(l2OutputOracle.PROPOSER()); + l2OutputOracle.proposeL2Output(_outputRoot, _proposedBlockNumber, 0, 0); // Warp beyond the finalization period for the block we've proposed. - vm.warp(oracle.getL2Output(_proposedOutputIndex).timestamp + oracle.FINALIZATION_PERIOD_SECONDS() + 1); + vm.warp( + l2OutputOracle.getL2Output(_proposedOutputIndex).timestamp + l2OutputOracle.FINALIZATION_PERIOD_SECONDS() + + 1 + ); // Fund the portal so that we can withdraw ETH. - vm.deal(address(op), 0xFFFFFFFF); + vm.deal(address(optimismPortal), 0xFFFFFFFF); } function test_depositTransaction_benchmark() external { - op.depositTransaction{ value: NON_ZERO_VALUE }( - NON_ZERO_ADDRESS, ZERO_VALUE, NON_ZERO_GASLIMIT, false, NON_ZERO_DATA + optimismPortal.depositTransaction{ value: 100 }( + address(1), 0, 50000, false, hex"0000111122223333444455556666777788889999aaaabbbbccccddddeeeeffff0000" ); } function test_depositTransaction_benchmark_1() external { - setPrevBaseFee(vm, address(op), 1 gwei); - op.depositTransaction{ value: NON_ZERO_VALUE }( - NON_ZERO_ADDRESS, ZERO_VALUE, NON_ZERO_GASLIMIT, false, NON_ZERO_DATA + setPrevBaseFee(vm, address(optimismPortal), 1 gwei); + optimismPortal.depositTransaction{ value: 100 }( + address(1), 0, 50000, false, hex"0000111122223333444455556666777788889999aaaabbbbccccddddeeeeffff0000" ); } function test_proveWithdrawalTransaction_benchmark() external { - op.proveWithdrawalTransaction(_defaultTx, _proposedOutputIndex, _outputRootProof, _withdrawalProof); + optimismPortal.proveWithdrawalTransaction(_defaultTx, _proposedOutputIndex, _outputRootProof, _withdrawalProof); } } -contract GasBenchMark_L1CrossDomainMessenger is Messenger_Initializer { +contract GasBenchMark_L1CrossDomainMessenger is Bridge_Initializer { function test_sendMessage_benchmark_0() external { vm.pauseGasMetering(); - setPrevBaseFee(vm, address(op), 1 gwei); + setPrevBaseFee(vm, address(optimismPortal), 1 gwei); // The amount of data typically sent during a bridge deposit. bytes memory data = hex"ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff"; vm.resumeGasMetering(); - L1Messenger.sendMessage(bob, data, uint32(100)); + l1CrossDomainMessenger.sendMessage(bob, data, uint32(100)); } function test_sendMessage_benchmark_1() external { vm.pauseGasMetering(); - setPrevBaseFee(vm, address(op), 10 gwei); + setPrevBaseFee(vm, address(optimismPortal), 10 gwei); // The amount of data typically sent during a bridge deposit. bytes memory data = hex"ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff"; vm.resumeGasMetering(); - L1Messenger.sendMessage(bob, data, uint32(100)); + l1CrossDomainMessenger.sendMessage(bob, data, uint32(100)); } } @@ -124,28 +129,28 @@ contract GasBenchMark_L1StandardBridge_Deposit is Bridge_Initializer { super.setUp(); deal(address(L1Token), alice, 100000, true); vm.startPrank(alice, alice); - L1Token.approve(address(L1Bridge), type(uint256).max); + L1Token.approve(address(l1StandardBridge), type(uint256).max); } function test_depositETH_benchmark_0() external { vm.pauseGasMetering(); - setPrevBaseFee(vm, address(op), 1 gwei); + setPrevBaseFee(vm, address(optimismPortal), 1 gwei); vm.resumeGasMetering(); - L1Bridge.depositETH{ value: 500 }(50000, hex""); + l1StandardBridge.depositETH{ value: 500 }(50000, hex""); } function test_depositETH_benchmark_1() external { vm.pauseGasMetering(); - setPrevBaseFee(vm, address(op), 10 gwei); + setPrevBaseFee(vm, address(optimismPortal), 10 gwei); vm.resumeGasMetering(); - L1Bridge.depositETH{ value: 500 }(50000, hex""); + l1StandardBridge.depositETH{ value: 500 }(50000, hex""); } function test_depositERC20_benchmark_0() external { vm.pauseGasMetering(); - setPrevBaseFee(vm, address(op), 1 gwei); + setPrevBaseFee(vm, address(optimismPortal), 1 gwei); vm.resumeGasMetering(); - L1Bridge.bridgeERC20({ + l1StandardBridge.bridgeERC20({ _localToken: address(L1Token), _remoteToken: address(L2Token), _amount: 100, @@ -156,9 +161,9 @@ contract GasBenchMark_L1StandardBridge_Deposit is Bridge_Initializer { function test_depositERC20_benchmark_1() external { vm.pauseGasMetering(); - setPrevBaseFee(vm, address(op), 10 gwei); + setPrevBaseFee(vm, address(optimismPortal), 10 gwei); vm.resumeGasMetering(); - L1Bridge.bridgeERC20({ + l1StandardBridge.bridgeERC20({ _localToken: address(L1Token), _remoteToken: address(L2Token), _amount: 100, @@ -171,35 +176,36 @@ contract GasBenchMark_L1StandardBridge_Deposit is Bridge_Initializer { contract GasBenchMark_L1StandardBridge_Finalize is Bridge_Initializer { function setUp() public virtual override { super.setUp(); - deal(address(L1Token), address(L1Bridge), 100, true); + deal(address(L1Token), address(l1StandardBridge), 100, true); vm.mockCall( - address(L1Bridge.messenger()), + address(l1StandardBridge.messenger()), abi.encodeWithSelector(CrossDomainMessenger.xDomainMessageSender.selector), - abi.encode(address(L1Bridge.OTHER_BRIDGE())) + abi.encode(address(l1StandardBridge.OTHER_BRIDGE())) ); - vm.startPrank(address(L1Bridge.messenger())); - vm.deal(address(L1Bridge.messenger()), 100); + vm.startPrank(address(l1StandardBridge.messenger())); + vm.deal(address(l1StandardBridge.messenger()), 100); } function test_finalizeETHWithdrawal_benchmark() external { // TODO: Make this more accurate. It is underestimating the cost because it pranks // the call coming from the messenger, which bypasses the portal // and oracle. - L1Bridge.finalizeETHWithdrawal{ value: 100 }(alice, alice, 100, hex""); + l1StandardBridge.finalizeETHWithdrawal{ value: 100 }(alice, alice, 100, hex""); } } -contract GasBenchMark_L2OutputOracle is L2OutputOracle_Initializer { +contract GasBenchMark_L2OutputOracle is CommonTest { uint256 nextBlockNumber; function setUp() public override { super.setUp(); - nextBlockNumber = oracle.nextBlockNumber(); + nextBlockNumber = l2OutputOracle.nextBlockNumber(); warpToProposeTime(nextBlockNumber); + address proposer = cfg.l2OutputOracleProposer(); vm.startPrank(proposer); } function test_proposeL2Output_benchmark() external { - oracle.proposeL2Output(nonZeroHash, nextBlockNumber, 0, 0); + l2OutputOracle.proposeL2Output(nonZeroHash, nextBlockNumber, 0, 0); } } diff --git a/packages/contracts-bedrock/test/Bytes.t.sol b/packages/contracts-bedrock/test/Bytes.t.sol index 79174d029667a..766cf7e01f5ba 100644 --- a/packages/contracts-bedrock/test/Bytes.t.sol +++ b/packages/contracts-bedrock/test/Bytes.t.sol @@ -5,7 +5,7 @@ pragma solidity 0.8.15; import { Test } from "forge-std/Test.sol"; // Target contract -import { Bytes } from "../src/libraries/Bytes.sol"; +import { Bytes } from "src/libraries/Bytes.sol"; contract Bytes_slice_Test is Test { /// @notice Tests that the `slice` function works as expected when starting from index 0. diff --git a/packages/contracts-bedrock/test/CheckBalanceHigh.t.sol b/packages/contracts-bedrock/test/CheckBalanceHigh.t.sol deleted file mode 100644 index 07505b85f9e5a..0000000000000 --- a/packages/contracts-bedrock/test/CheckBalanceHigh.t.sol +++ /dev/null @@ -1,40 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity 0.8.15; - -import { Test } from "forge-std/Test.sol"; -import { CheckBalanceHigh } from "../src/periphery/drippie/dripchecks/CheckBalanceHigh.sol"; - -/// @title CheckBalanceHighTest -/// @notice Tests the CheckBalanceHigh contract via fuzzing both the success case -/// and the failure case. -contract CheckBalanceHighTest is Test { - /// @notice An instance of the CheckBalanceHigh contract. - CheckBalanceHigh c; - - /// @notice Deploy the `CheckTrue` contract. - function setUp() external { - c = new CheckBalanceHigh(); - } - - /// @notice Fuzz the `check` function and assert that it always returns true - /// when the target's balance is larger than the threshold. - function testFuzz_check_succeeds(address _target, uint256 _threshold) external { - CheckBalanceHigh.Params memory p = CheckBalanceHigh.Params({ target: _target, threshold: _threshold }); - - // prevent overflows - vm.assume(_threshold != type(uint256).max); - vm.deal(_target, _threshold + 1); - - assertEq(c.check(abi.encode(p)), true); - } - - /// @notice Fuzz the `check` function and assert that it always returns false - /// when the target's balance is smaller than the threshold. - function testFuzz_check_lowBalance_fails(address _target, uint256 _threshold) external { - CheckBalanceHigh.Params memory p = CheckBalanceHigh.Params({ target: _target, threshold: _threshold }); - - vm.assume(_target.balance < _threshold); - - assertEq(c.check(abi.encode(p)), false); - } -} diff --git a/packages/contracts-bedrock/test/CheckBalanceLow.t.sol b/packages/contracts-bedrock/test/CheckBalanceLow.t.sol index 71bcf199ff716..0345fa248a8a2 100644 --- a/packages/contracts-bedrock/test/CheckBalanceLow.t.sol +++ b/packages/contracts-bedrock/test/CheckBalanceLow.t.sol @@ -2,7 +2,7 @@ pragma solidity 0.8.15; import { Test } from "forge-std/Test.sol"; -import { CheckBalanceLow } from "../src/periphery/drippie/dripchecks/CheckBalanceLow.sol"; +import { CheckBalanceLow } from "src/periphery/drippie/dripchecks/CheckBalanceLow.sol"; /// @title CheckBalanceLowTest /// @notice Tests the CheckBalanceLow contract via fuzzing both the success case diff --git a/packages/contracts-bedrock/test/CheckGelatoLow.t.sol b/packages/contracts-bedrock/test/CheckGelatoLow.t.sol index a89f49251f685..b8a25a72e3b3a 100644 --- a/packages/contracts-bedrock/test/CheckGelatoLow.t.sol +++ b/packages/contracts-bedrock/test/CheckGelatoLow.t.sol @@ -2,7 +2,7 @@ pragma solidity 0.8.15; import { Test } from "forge-std/Test.sol"; -import { CheckGelatoLow, IGelatoTreasury } from "../src/periphery/drippie/dripchecks/CheckGelatoLow.sol"; +import { CheckGelatoLow, IGelatoTreasury } from "src/periphery/drippie/dripchecks/CheckGelatoLow.sol"; /// @title MockGelatoTreasury /// @notice Mocks the Gelato treasury for testing purposes. Allows arbitrary @@ -20,7 +20,7 @@ contract MockGelatoTreasury is IGelatoTreasury { } /// @title CheckGelatoLowTest -/// @notice Tests the CheckBalanceHigh contract via fuzzing both the success case +/// @notice Tests the CheckGelatoLow contract via fuzzing both the success case /// and the failure case. contract CheckGelatoLowTest is Test { /// @notice An instance of the CheckGelatoLow contract. diff --git a/packages/contracts-bedrock/test/CheckTrue.t.sol b/packages/contracts-bedrock/test/CheckTrue.t.sol index c0b1016fa842d..2c7e4be070a2a 100644 --- a/packages/contracts-bedrock/test/CheckTrue.t.sol +++ b/packages/contracts-bedrock/test/CheckTrue.t.sol @@ -2,7 +2,7 @@ pragma solidity 0.8.15; import { Test } from "forge-std/Test.sol"; -import { CheckTrue } from "../src/periphery/drippie/dripchecks/CheckTrue.sol"; +import { CheckTrue } from "src/periphery/drippie/dripchecks/CheckTrue.sol"; /// @title CheckTrueTest /// @notice Ensures that the CheckTrue DripCheck contract always returns true. diff --git a/packages/contracts-bedrock/test/Clones.t.sol b/packages/contracts-bedrock/test/Clones.t.sol index e207b246ad672..4b8802c287e52 100644 --- a/packages/contracts-bedrock/test/Clones.t.sol +++ b/packages/contracts-bedrock/test/Clones.t.sol @@ -5,7 +5,7 @@ import "forge-std/Test.sol"; import { ClonesWithImmutableArgs } from "@cwia/ClonesWithImmutableArgs.sol"; -import { Clone } from "../src/libraries/Clone.sol"; +import { Clone } from "src/libraries/Clone.sol"; contract ExampleClone is Clone { uint256 argOffset; diff --git a/packages/contracts-bedrock/test/CommonTest.t.sol b/packages/contracts-bedrock/test/CommonTest.t.sol deleted file mode 100644 index 999dd3f8fc6d0..0000000000000 --- a/packages/contracts-bedrock/test/CommonTest.t.sol +++ /dev/null @@ -1,808 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity 0.8.15; - -// Testing utilities -import { Test, StdUtils } from "forge-std/Test.sol"; -import { L2OutputOracle } from "../src/L1/L2OutputOracle.sol"; -import { L2ToL1MessagePasser } from "../src/L2/L2ToL1MessagePasser.sol"; -import { L1StandardBridge } from "../src/L1/L1StandardBridge.sol"; -import { L2StandardBridge } from "../src/L2/L2StandardBridge.sol"; -import { StandardBridge } from "../src/universal/StandardBridge.sol"; -import { L1ERC721Bridge } from "../src/L1/L1ERC721Bridge.sol"; -import { L2ERC721Bridge } from "../src/L2/L2ERC721Bridge.sol"; -import { OptimismMintableERC20Factory } from "../src/universal/OptimismMintableERC20Factory.sol"; -import { OptimismMintableERC721Factory } from "../src/universal/OptimismMintableERC721Factory.sol"; -import { OptimismMintableERC20 } from "../src/universal/OptimismMintableERC20.sol"; -import { OptimismPortal } from "../src/L1/OptimismPortal.sol"; -import { L1CrossDomainMessenger } from "../src/L1/L1CrossDomainMessenger.sol"; -import { L2CrossDomainMessenger } from "../src/L2/L2CrossDomainMessenger.sol"; -import { SequencerFeeVault } from "../src/L2/SequencerFeeVault.sol"; -import { FeeVault } from "../src/universal/FeeVault.sol"; -import { AddressAliasHelper } from "../src/vendor/AddressAliasHelper.sol"; -import { LegacyERC20ETH } from "../src/legacy/LegacyERC20ETH.sol"; -import { Predeploys } from "../src/libraries/Predeploys.sol"; -import { Types } from "../src/libraries/Types.sol"; -import { ERC20 } from "@openzeppelin/contracts/token/ERC20/ERC20.sol"; -import { Proxy } from "../src/universal/Proxy.sol"; -import { Initializable } from "@openzeppelin/contracts-upgradeable/proxy/utils/Initializable.sol"; -import { ResolvedDelegateProxy } from "../src/legacy/ResolvedDelegateProxy.sol"; -import { AddressManager } from "../src/legacy/AddressManager.sol"; -import { L1ChugSplashProxy } from "../src/legacy/L1ChugSplashProxy.sol"; -import { IL1ChugSplashDeployer } from "../src/legacy/L1ChugSplashProxy.sol"; -import { CrossDomainMessenger } from "../src/universal/CrossDomainMessenger.sol"; -import { Strings } from "@openzeppelin/contracts/utils/Strings.sol"; -import { LegacyMintableERC20 } from "../src/legacy/LegacyMintableERC20.sol"; -import { SystemConfig } from "../src/L1/SystemConfig.sol"; -import { ResourceMetering } from "../src/L1/ResourceMetering.sol"; -import { Constants } from "../src/libraries/Constants.sol"; - -contract CommonTest is Test { - address alice = address(128); - address bob = address(256); - address multisig = address(512); - - address immutable ZERO_ADDRESS = address(0); - address immutable NON_ZERO_ADDRESS = address(1); - uint256 immutable NON_ZERO_VALUE = 100; - uint256 immutable ZERO_VALUE = 0; - uint64 immutable NON_ZERO_GASLIMIT = 50000; - bytes32 nonZeroHash = keccak256(abi.encode("NON_ZERO")); - bytes NON_ZERO_DATA = hex"0000111122223333444455556666777788889999aaaabbbbccccddddeeeeffff0000"; - - event TransactionDeposited(address indexed from, address indexed to, uint256 indexed version, bytes opaqueData); - - /// @dev OpenZeppelin Ownable.sol transferOwnership event - event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); - - FFIInterface ffi; - - function setUp() public virtual { - // Give alice and bob some ETH - vm.deal(alice, 1 << 16); - vm.deal(bob, 1 << 16); - vm.deal(multisig, 1 << 16); - - vm.label(alice, "alice"); - vm.label(bob, "bob"); - vm.label(multisig, "multisig"); - - // Make sure we have a non-zero base fee - vm.fee(1000000000); - - ffi = new FFIInterface(); - } - - function emitTransactionDeposited( - address _from, - address _to, - uint256 _mint, - uint256 _value, - uint64 _gasLimit, - bool _isCreation, - bytes memory _data - ) - internal - { - emit TransactionDeposited(_from, _to, 0, abi.encodePacked(_mint, _value, _gasLimit, _isCreation, _data)); - } -} - -contract L2OutputOracle_Initializer is CommonTest { - // Test target - L2OutputOracle oracle; - L2OutputOracle oracleImpl; - - L2ToL1MessagePasser messagePasser = L2ToL1MessagePasser(payable(Predeploys.L2_TO_L1_MESSAGE_PASSER)); - - // Constructor arguments - address internal proposer = 0x000000000000000000000000000000000000AbBa; - address internal owner = 0x000000000000000000000000000000000000ACDC; - uint256 internal submissionInterval = 1800; - uint256 internal l2BlockTime = 2; - uint256 internal startingBlockNumber = 200; - uint256 internal startingTimestamp = 1000; - uint256 internal finalizationPeriodSeconds = 7 days; - address guardian; - - // Test data - uint256 initL1Time; - - event OutputProposed( - bytes32 indexed outputRoot, uint256 indexed l2OutputIndex, uint256 indexed l2BlockNumber, uint256 l1Timestamp - ); - - event OutputsDeleted(uint256 indexed prevNextOutputIndex, uint256 indexed newNextOutputIndex); - - // Advance the evm's time to meet the L2OutputOracle's requirements for proposeL2Output - function warpToProposeTime(uint256 _nextBlockNumber) public { - vm.warp(oracle.computeL2Timestamp(_nextBlockNumber) + 1); - } - - /// @dev Helper function to propose an output. - function proposeAnotherOutput() public { - bytes32 proposedOutput2 = keccak256(abi.encode()); - uint256 nextBlockNumber = oracle.nextBlockNumber(); - uint256 nextOutputIndex = oracle.nextOutputIndex(); - warpToProposeTime(nextBlockNumber); - uint256 proposedNumber = oracle.latestBlockNumber(); - - // Ensure the submissionInterval is enforced - assertEq(nextBlockNumber, proposedNumber + submissionInterval); - - vm.roll(nextBlockNumber + 1); - - vm.expectEmit(true, true, true, true); - emit OutputProposed(proposedOutput2, nextOutputIndex, nextBlockNumber, block.timestamp); - - vm.prank(proposer); - oracle.proposeL2Output(proposedOutput2, nextBlockNumber, 0, 0); - } - - function setUp() public virtual override { - super.setUp(); - guardian = makeAddr("guardian"); - - // By default the first block has timestamp and number zero, which will cause underflows in the - // tests, so we'll move forward to these block values. - initL1Time = startingTimestamp + 1; - vm.warp(initL1Time); - vm.roll(startingBlockNumber); - // Deploy the L2OutputOracle and transfer owernship to the proposer - oracleImpl = new L2OutputOracle({ - _submissionInterval: submissionInterval, - _l2BlockTime: l2BlockTime, - _finalizationPeriodSeconds: finalizationPeriodSeconds - }); - Proxy proxy = new Proxy(multisig); - vm.prank(multisig); - proxy.upgradeToAndCall( - address(oracleImpl), - abi.encodeCall(L2OutputOracle.initialize, (startingBlockNumber, startingTimestamp, proposer, owner)) - ); - oracle = L2OutputOracle(address(proxy)); - vm.label(address(oracle), "L2OutputOracle"); - - // Set the L2ToL1MessagePasser at the correct address - vm.etch(Predeploys.L2_TO_L1_MESSAGE_PASSER, address(new L2ToL1MessagePasser()).code); - - vm.label(Predeploys.L2_TO_L1_MESSAGE_PASSER, "L2ToL1MessagePasser"); - } -} - -contract Portal_Initializer is L2OutputOracle_Initializer { - // Test target - OptimismPortal internal opImpl; - OptimismPortal internal op; - SystemConfig systemConfig; - - event WithdrawalFinalized(bytes32 indexed withdrawalHash, bool success); - event WithdrawalProven(bytes32 indexed withdrawalHash, address indexed from, address indexed to); - - function setUp() public virtual override { - super.setUp(); - - Proxy systemConfigProxy = new Proxy(multisig); - - SystemConfig systemConfigImpl = new SystemConfig(); - - vm.prank(multisig); - systemConfigProxy.upgradeToAndCall( - address(systemConfigImpl), - abi.encodeCall( - SystemConfig.initialize, - ( - address(1), //_owner, - 0, //_overhead, - 10000, //_scalar, - bytes32(0), //_batcherHash, - 30_000_000, //_gasLimit, - address(0), //_unsafeBlockSigner, - Constants.DEFAULT_RESOURCE_CONFIG(), //_config, - 0, //_startBlock - address(0xff), // _batchInbox - SystemConfig.Addresses({ // _addresses - l1CrossDomainMessenger: address(0), - l1ERC721Bridge: address(0), - l1StandardBridge: address(0), - l2OutputOracle: address(oracle), - optimismPortal: address(op), - optimismMintableERC20Factory: address(0) - }) - ) - ) - ); - - systemConfig = SystemConfig(address(systemConfigProxy)); - - opImpl = new OptimismPortal(); - - Proxy proxy = new Proxy(multisig); - vm.prank(multisig); - proxy.upgradeToAndCall( - address(opImpl), abi.encodeCall(OptimismPortal.initialize, (oracle, guardian, systemConfig, false)) - ); - op = OptimismPortal(payable(address(proxy))); - vm.label(address(op), "OptimismPortal"); - } -} - -contract Messenger_Initializer is Portal_Initializer { - AddressManager internal addressManager; - L1CrossDomainMessenger internal L1Messenger; - L2CrossDomainMessenger internal L2Messenger = L2CrossDomainMessenger(Predeploys.L2_CROSS_DOMAIN_MESSENGER); - - event SentMessage(address indexed target, address sender, bytes message, uint256 messageNonce, uint256 gasLimit); - - event SentMessageExtension1(address indexed sender, uint256 value); - - event MessagePassed( - uint256 indexed nonce, - address indexed sender, - address indexed target, - uint256 value, - uint256 gasLimit, - bytes data, - bytes32 withdrawalHash - ); - - event RelayedMessage(bytes32 indexed msgHash); - event FailedRelayedMessage(bytes32 indexed msgHash); - - event TransactionDeposited( - address indexed from, - address indexed to, - uint256 mint, - uint256 value, - uint64 gasLimit, - bool isCreation, - bytes data - ); - - event WhatHappened(bool success, bytes returndata); - - function setUp() public virtual override { - super.setUp(); - - // Deploy the address manager - vm.prank(multisig); - addressManager = new AddressManager(); - - // Setup implementation - L1CrossDomainMessenger L1MessengerImpl = new L1CrossDomainMessenger(); - - // Setup the address manager and proxy - vm.prank(multisig); - addressManager.setAddress("OVM_L1CrossDomainMessenger", address(L1MessengerImpl)); - ResolvedDelegateProxy proxy = new ResolvedDelegateProxy( - addressManager, - "OVM_L1CrossDomainMessenger" - ); - L1Messenger = L1CrossDomainMessenger(address(proxy)); - L1Messenger.initialize(op); - - vm.etch(Predeploys.L2_CROSS_DOMAIN_MESSENGER, address(new L2CrossDomainMessenger(address(L1Messenger))).code); - - L2Messenger.initialize(); - - // Label addresses - vm.label(address(addressManager), "AddressManager"); - vm.label(address(L1MessengerImpl), "L1CrossDomainMessenger_Impl"); - vm.label(address(L1Messenger), "L1CrossDomainMessenger_Proxy"); - vm.label(Predeploys.LEGACY_ERC20_ETH, "LegacyERC20ETH"); - vm.label(Predeploys.L2_CROSS_DOMAIN_MESSENGER, "L2CrossDomainMessenger"); - - vm.label(AddressAliasHelper.applyL1ToL2Alias(address(L1Messenger)), "L1CrossDomainMessenger_aliased"); - } -} - -contract Bridge_Initializer is Messenger_Initializer { - L1StandardBridge L1Bridge; - L2StandardBridge L2Bridge; - OptimismMintableERC20Factory L2TokenFactory; - OptimismMintableERC20Factory L1TokenFactory; - ERC20 L1Token; - ERC20 BadL1Token; - OptimismMintableERC20 L2Token; - LegacyMintableERC20 LegacyL2Token; - ERC20 NativeL2Token; - ERC20 BadL2Token; - OptimismMintableERC20 RemoteL1Token; - - event ETHDepositInitiated(address indexed from, address indexed to, uint256 amount, bytes data); - - event ETHWithdrawalFinalized(address indexed from, address indexed to, uint256 amount, bytes data); - - event ERC20DepositInitiated( - address indexed l1Token, address indexed l2Token, address indexed from, address to, uint256 amount, bytes data - ); - - event ERC20WithdrawalFinalized( - address indexed l1Token, address indexed l2Token, address indexed from, address to, uint256 amount, bytes data - ); - - event WithdrawalInitiated( - address indexed l1Token, address indexed l2Token, address indexed from, address to, uint256 amount, bytes data - ); - - event DepositFinalized( - address indexed l1Token, address indexed l2Token, address indexed from, address to, uint256 amount, bytes data - ); - - event DepositFailed( - address indexed l1Token, address indexed l2Token, address indexed from, address to, uint256 amount, bytes data - ); - - event ETHBridgeInitiated(address indexed from, address indexed to, uint256 amount, bytes data); - - event ETHBridgeFinalized(address indexed from, address indexed to, uint256 amount, bytes data); - - event ERC20BridgeInitiated( - address indexed localToken, - address indexed remoteToken, - address indexed from, - address to, - uint256 amount, - bytes data - ); - - event ERC20BridgeFinalized( - address indexed localToken, - address indexed remoteToken, - address indexed from, - address to, - uint256 amount, - bytes data - ); - - function setUp() public virtual override { - super.setUp(); - - vm.label(Predeploys.L2_STANDARD_BRIDGE, "L2StandardBridge"); - vm.label(Predeploys.OPTIMISM_MINTABLE_ERC20_FACTORY, "OptimismMintableERC20Factory"); - - // Deploy the L1 bridge and initialize it with the address of the - // L1CrossDomainMessenger - L1ChugSplashProxy proxy = new L1ChugSplashProxy(multisig); - vm.mockCall(multisig, abi.encodeWithSelector(IL1ChugSplashDeployer.isUpgrading.selector), abi.encode(true)); - vm.startPrank(multisig); - proxy.setCode(address(new L1StandardBridge()).code); - vm.clearMockedCalls(); - address L1Bridge_Impl = proxy.getImplementation(); - vm.stopPrank(); - - L1Bridge = L1StandardBridge(payable(address(proxy))); - L1Bridge.initialize({ _messenger: L1Messenger }); - - vm.label(address(proxy), "L1StandardBridge_Proxy"); - vm.label(address(L1Bridge_Impl), "L1StandardBridge_Impl"); - - // Deploy the L2StandardBridge, move it to the correct predeploy - // address and then initialize it. It is safe to call initialize directly - // on the proxy because the bytecode was set in state with `etch`. - vm.etch(Predeploys.L2_STANDARD_BRIDGE, address(new L2StandardBridge(StandardBridge(payable(proxy)))).code); - L2Bridge = L2StandardBridge(payable(Predeploys.L2_STANDARD_BRIDGE)); - L2Bridge.initialize(); - - // Set up the L2 mintable token factory - OptimismMintableERC20Factory factory = new OptimismMintableERC20Factory(); - vm.etch(Predeploys.OPTIMISM_MINTABLE_ERC20_FACTORY, address(factory).code); - L2TokenFactory = OptimismMintableERC20Factory(Predeploys.OPTIMISM_MINTABLE_ERC20_FACTORY); - L2TokenFactory.initialize(Predeploys.L2_STANDARD_BRIDGE); - - vm.etch(Predeploys.LEGACY_ERC20_ETH, address(new LegacyERC20ETH()).code); - - L1Token = new ERC20("Native L1 Token", "L1T"); - - LegacyL2Token = new LegacyMintableERC20({ - _l2Bridge: address(L2Bridge), - _l1Token: address(L1Token), - _name: string.concat("LegacyL2-", L1Token.name()), - _symbol: string.concat("LegacyL2-", L1Token.symbol()) - }); - vm.label(address(LegacyL2Token), "LegacyMintableERC20"); - - // Deploy the L2 ERC20 now - L2Token = OptimismMintableERC20( - L2TokenFactory.createStandardL2Token( - address(L1Token), - string(abi.encodePacked("L2-", L1Token.name())), - string(abi.encodePacked("L2-", L1Token.symbol())) - ) - ); - - BadL2Token = OptimismMintableERC20( - L2TokenFactory.createStandardL2Token( - address(1), - string(abi.encodePacked("L2-", L1Token.name())), - string(abi.encodePacked("L2-", L1Token.symbol())) - ) - ); - - NativeL2Token = new ERC20("Native L2 Token", "L2T"); - Proxy factoryProxy = new Proxy(multisig); - OptimismMintableERC20Factory L1TokenFactoryImpl = new OptimismMintableERC20Factory(); - - vm.prank(multisig); - factoryProxy.upgradeToAndCall( - address(L1TokenFactoryImpl), abi.encodeCall(OptimismMintableERC20Factory.initialize, address(L1Bridge)) - ); - - L1TokenFactory = OptimismMintableERC20Factory(address(factoryProxy)); - - RemoteL1Token = OptimismMintableERC20( - L1TokenFactory.createStandardL2Token( - address(NativeL2Token), - string(abi.encodePacked("L1-", NativeL2Token.name())), - string(abi.encodePacked("L1-", NativeL2Token.symbol())) - ) - ); - - BadL1Token = OptimismMintableERC20( - L1TokenFactory.createStandardL2Token( - address(1), - string(abi.encodePacked("L1-", NativeL2Token.name())), - string(abi.encodePacked("L1-", NativeL2Token.symbol())) - ) - ); - } -} - -contract ERC721Bridge_Initializer is Messenger_Initializer { - L1ERC721Bridge L1Bridge; - L2ERC721Bridge L2Bridge; - - function setUp() public virtual override { - super.setUp(); - - // Deploy the L1ERC721Bridge. - L1ERC721Bridge l1BridgeImpl = new L1ERC721Bridge(); - Proxy l1BridgeProxy = new Proxy(multisig); - - vm.prank(multisig); - l1BridgeProxy.upgradeToAndCall( - address(l1BridgeImpl), abi.encodeCall(L1ERC721Bridge.initialize, (CrossDomainMessenger(L1Messenger))) - ); - - L1Bridge = L1ERC721Bridge(address(l1BridgeProxy)); - - // Deploy the implementation for the L2ERC721Bridge and etch it into the predeploy address. - L2ERC721Bridge l2BridgeImpl = new L2ERC721Bridge(address(L1Bridge)); - Proxy l2BridgeProxy = new Proxy(multisig); - vm.etch(Predeploys.L2_ERC721_BRIDGE, address(l2BridgeProxy).code); - - // set the storage slot for admin - bytes32 OWNER_KEY = 0xb53127684a568b3173ae13b9f8a6016e243e63b6e8ee1178d6a717850b5d6103; - vm.store(Predeploys.L2_ERC721_BRIDGE, OWNER_KEY, bytes32(uint256(uint160(multisig)))); - - vm.prank(multisig); - Proxy(payable(Predeploys.L2_ERC721_BRIDGE)).upgradeToAndCall( - address(l2BridgeImpl), abi.encodeCall(L2ERC721Bridge.initialize, (L2Messenger)) - ); - - // Set up a reference to the L2ERC721Bridge. - L2Bridge = L2ERC721Bridge(Predeploys.L2_ERC721_BRIDGE); - - // Label the L1 and L2 bridges. - vm.label(address(L1Bridge), "L1ERC721Bridge"); - vm.label(address(L2Bridge), "L2ERC721Bridge"); - } -} - -contract FeeVault_Initializer is Bridge_Initializer { - SequencerFeeVault vault = SequencerFeeVault(payable(Predeploys.SEQUENCER_FEE_WALLET)); - address constant recipient = address(1024); - - event Withdrawal(uint256 value, address to, address from); - - event Withdrawal(uint256 value, address to, address from, FeeVault.WithdrawalNetwork withdrawalNetwork); -} - -contract FFIInterface is Test { - function getProveWithdrawalTransactionInputs(Types.WithdrawalTransaction memory _tx) - external - returns (bytes32, bytes32, bytes32, bytes32, bytes[] memory) - { - string[] memory cmds = new string[](8); - cmds[0] = "scripts/differential-testing/differential-testing"; - cmds[1] = "getProveWithdrawalTransactionInputs"; - cmds[2] = vm.toString(_tx.nonce); - cmds[3] = vm.toString(_tx.sender); - cmds[4] = vm.toString(_tx.target); - cmds[5] = vm.toString(_tx.value); - cmds[6] = vm.toString(_tx.gasLimit); - cmds[7] = vm.toString(_tx.data); - - bytes memory result = vm.ffi(cmds); - ( - bytes32 stateRoot, - bytes32 storageRoot, - bytes32 outputRoot, - bytes32 withdrawalHash, - bytes[] memory withdrawalProof - ) = abi.decode(result, (bytes32, bytes32, bytes32, bytes32, bytes[])); - - return (stateRoot, storageRoot, outputRoot, withdrawalHash, withdrawalProof); - } - - function hashCrossDomainMessage( - uint256 _nonce, - address _sender, - address _target, - uint256 _value, - uint256 _gasLimit, - bytes memory _data - ) - external - returns (bytes32) - { - string[] memory cmds = new string[](8); - cmds[0] = "scripts/differential-testing/differential-testing"; - cmds[1] = "hashCrossDomainMessage"; - cmds[2] = vm.toString(_nonce); - cmds[3] = vm.toString(_sender); - cmds[4] = vm.toString(_target); - cmds[5] = vm.toString(_value); - cmds[6] = vm.toString(_gasLimit); - cmds[7] = vm.toString(_data); - - bytes memory result = vm.ffi(cmds); - return abi.decode(result, (bytes32)); - } - - function hashWithdrawal( - uint256 _nonce, - address _sender, - address _target, - uint256 _value, - uint256 _gasLimit, - bytes memory _data - ) - external - returns (bytes32) - { - string[] memory cmds = new string[](8); - cmds[0] = "scripts/differential-testing/differential-testing"; - cmds[1] = "hashWithdrawal"; - cmds[2] = vm.toString(_nonce); - cmds[3] = vm.toString(_sender); - cmds[4] = vm.toString(_target); - cmds[5] = vm.toString(_value); - cmds[6] = vm.toString(_gasLimit); - cmds[7] = vm.toString(_data); - - bytes memory result = vm.ffi(cmds); - return abi.decode(result, (bytes32)); - } - - function hashOutputRootProof( - bytes32 _version, - bytes32 _stateRoot, - bytes32 _messagePasserStorageRoot, - bytes32 _latestBlockhash - ) - external - returns (bytes32) - { - string[] memory cmds = new string[](6); - cmds[0] = "scripts/differential-testing/differential-testing"; - cmds[1] = "hashOutputRootProof"; - cmds[2] = Strings.toHexString(uint256(_version)); - cmds[3] = Strings.toHexString(uint256(_stateRoot)); - cmds[4] = Strings.toHexString(uint256(_messagePasserStorageRoot)); - cmds[5] = Strings.toHexString(uint256(_latestBlockhash)); - - bytes memory result = vm.ffi(cmds); - return abi.decode(result, (bytes32)); - } - - function hashDepositTransaction( - address _from, - address _to, - uint256 _mint, - uint256 _value, - uint64 _gas, - bytes memory _data, - uint64 _logIndex - ) - external - returns (bytes32) - { - string[] memory cmds = new string[](10); - cmds[0] = "scripts/differential-testing/differential-testing"; - cmds[1] = "hashDepositTransaction"; - cmds[2] = "0x0000000000000000000000000000000000000000000000000000000000000000"; - cmds[3] = vm.toString(_logIndex); - cmds[4] = vm.toString(_from); - cmds[5] = vm.toString(_to); - cmds[6] = vm.toString(_mint); - cmds[7] = vm.toString(_value); - cmds[8] = vm.toString(_gas); - cmds[9] = vm.toString(_data); - - bytes memory result = vm.ffi(cmds); - return abi.decode(result, (bytes32)); - } - - function encodeDepositTransaction(Types.UserDepositTransaction calldata txn) external returns (bytes memory) { - string[] memory cmds = new string[](11); - cmds[0] = "scripts/differential-testing/differential-testing"; - cmds[1] = "encodeDepositTransaction"; - cmds[2] = vm.toString(txn.from); - cmds[3] = vm.toString(txn.to); - cmds[4] = vm.toString(txn.value); - cmds[5] = vm.toString(txn.mint); - cmds[6] = vm.toString(txn.gasLimit); - cmds[7] = vm.toString(txn.isCreation); - cmds[8] = vm.toString(txn.data); - cmds[9] = vm.toString(txn.l1BlockHash); - cmds[10] = vm.toString(txn.logIndex); - - bytes memory result = vm.ffi(cmds); - return abi.decode(result, (bytes)); - } - - function encodeCrossDomainMessage( - uint256 _nonce, - address _sender, - address _target, - uint256 _value, - uint256 _gasLimit, - bytes memory _data - ) - external - returns (bytes memory) - { - string[] memory cmds = new string[](8); - cmds[0] = "scripts/differential-testing/differential-testing"; - cmds[1] = "encodeCrossDomainMessage"; - cmds[2] = vm.toString(_nonce); - cmds[3] = vm.toString(_sender); - cmds[4] = vm.toString(_target); - cmds[5] = vm.toString(_value); - cmds[6] = vm.toString(_gasLimit); - cmds[7] = vm.toString(_data); - - bytes memory result = vm.ffi(cmds); - return abi.decode(result, (bytes)); - } - - function decodeVersionedNonce(uint256 nonce) external returns (uint256, uint256) { - string[] memory cmds = new string[](3); - cmds[0] = "scripts/differential-testing/differential-testing"; - cmds[1] = "decodeVersionedNonce"; - cmds[2] = vm.toString(nonce); - - bytes memory result = vm.ffi(cmds); - return abi.decode(result, (uint256, uint256)); - } - - function getMerkleTrieFuzzCase(string memory variant) - external - returns (bytes32, bytes memory, bytes memory, bytes[] memory) - { - string[] memory cmds = new string[](5); - cmds[0] = "./test-case-generator/fuzz"; - cmds[1] = "-m"; - cmds[2] = "trie"; - cmds[3] = "-v"; - cmds[4] = variant; - - return abi.decode(vm.ffi(cmds), (bytes32, bytes, bytes, bytes[])); - } - - function getCannonMemoryProof(uint32 pc, uint32 insn) external returns (bytes32, bytes memory) { - string[] memory cmds = new string[](4); - cmds[0] = "scripts/differential-testing/differential-testing"; - cmds[1] = "cannonMemoryProof"; - cmds[2] = vm.toString(pc); - cmds[3] = vm.toString(insn); - bytes memory result = vm.ffi(cmds); - (bytes32 memRoot, bytes memory proof) = abi.decode(result, (bytes32, bytes)); - return (memRoot, proof); - } - - function getCannonMemoryProof( - uint32 pc, - uint32 insn, - uint32 memAddr, - uint32 memVal - ) - external - returns (bytes32, bytes memory) - { - string[] memory cmds = new string[](6); - cmds[0] = "scripts/differential-testing/differential-testing"; - cmds[1] = "cannonMemoryProof"; - cmds[2] = vm.toString(pc); - cmds[3] = vm.toString(insn); - cmds[4] = vm.toString(memAddr); - cmds[5] = vm.toString(memVal); - bytes memory result = vm.ffi(cmds); - (bytes32 memRoot, bytes memory proof) = abi.decode(result, (bytes32, bytes)); - return (memRoot, proof); - } -} - -// Used for testing a future upgrade beyond the current implementations. -// We include some variables so that we can sanity check accessing storage values after an upgrade. -contract NextImpl is Initializable { - // Initializable occupies the zero-th slot. - bytes32 slot1; - bytes32[19] __gap; - bytes32 slot21; - bytes32 public constant slot21Init = bytes32(hex"1337"); - - function initialize(uint8 _init) public reinitializer(_init) { - // Slot21 is unused by an of our upgradeable contracts. - // This is used to verify that we can access this value after an upgrade. - slot21 = slot21Init; - } -} - -contract Reverter { - fallback() external { - revert(); - } -} - -// Useful for testing reentrancy guards -contract CallerCaller { - event WhatHappened(bool success, bytes returndata); - - fallback() external { - (bool success, bytes memory returndata) = msg.sender.call(msg.data); - emit WhatHappened(success, returndata); - assembly { - switch success - case 0 { revert(add(returndata, 0x20), mload(returndata)) } - default { return(add(returndata, 0x20), mload(returndata)) } - } - } -} - -// Used for testing the `CrossDomainMessenger`'s per-message reentrancy guard. -contract ConfigurableCaller { - bool doRevert = true; - address target; - bytes payload; - - event WhatHappened(bool success, bytes returndata); - - /// @notice Call the configured target with the configured payload OR revert. - function call() external { - if (doRevert) { - revert("ConfigurableCaller: revert"); - } else { - (bool success, bytes memory returndata) = address(target).call(payload); - emit WhatHappened(success, returndata); - assembly { - switch success - case 0 { revert(add(returndata, 0x20), mload(returndata)) } - default { return(add(returndata, 0x20), mload(returndata)) } - } - } - } - - /// @notice Set whether or not to have `call` revert. - function setDoRevert(bool _doRevert) external { - doRevert = _doRevert; - } - - /// @notice Set the target for the call made in `call`. - function setTarget(address _target) external { - target = _target; - } - - /// @notice Set the payload for the call made in `call`. - function setPayload(bytes calldata _payload) external { - payload = _payload; - } - - /// @notice Fallback function that reverts if `doRevert` is true. - /// Otherwise, it does nothing. - fallback() external { - if (doRevert) { - revert("ConfigurableCaller: revert"); - } - } -} diff --git a/packages/contracts-bedrock/test/CrossDomainMessenger.t.sol b/packages/contracts-bedrock/test/CrossDomainMessenger.t.sol index 712fa6da5e3c4..a254b7312eeec 100644 --- a/packages/contracts-bedrock/test/CrossDomainMessenger.t.sol +++ b/packages/contracts-bedrock/test/CrossDomainMessenger.t.sol @@ -2,26 +2,29 @@ pragma solidity 0.8.15; // Testing utilities -import { Messenger_Initializer, Reverter, CallerCaller, CommonTest } from "./CommonTest.t.sol"; -import { L1CrossDomainMessenger } from "../src/L1/L1CrossDomainMessenger.sol"; +import { Test } from "forge-std/Test.sol"; +import { Bridge_Initializer } from "test/setup/Bridge_Initializer.sol"; +import { CallerCaller, Reverter } from "test/mocks/Callers.sol"; // Libraries -import { Predeploys } from "../src/libraries/Predeploys.sol"; -import { Hashing } from "../src/libraries/Hashing.sol"; -import { Encoding } from "../src/libraries/Encoding.sol"; +import { Predeploys } from "src/libraries/Predeploys.sol"; +import { Hashing } from "src/libraries/Hashing.sol"; +import { Encoding } from "src/libraries/Encoding.sol"; + +import { L1CrossDomainMessenger } from "src/L1/L1CrossDomainMessenger.sol"; // CrossDomainMessenger_Test is for testing functionality which is common to both the L1 and L2 // CrossDomainMessenger contracts. For simplicity, we use the L1 Messenger as the test contract. -contract CrossDomainMessenger_BaseGas_Test is Messenger_Initializer { +contract CrossDomainMessenger_BaseGas_Test is Bridge_Initializer { /// @dev Ensure that baseGas passes for the max value of _minGasLimit, /// this is about 4 Billion. function test_baseGas_succeeds() external view { - L1Messenger.baseGas(hex"ff", type(uint32).max); + l1CrossDomainMessenger.baseGas(hex"ff", type(uint32).max); } /// @dev Fuzz for other values which might cause a revert in baseGas. function testFuzz_baseGas_succeeds(uint32 _minGasLimit) external view { - L1Messenger.baseGas(hex"ff", _minGasLimit); + l1CrossDomainMessenger.baseGas(hex"ff", _minGasLimit); } /// @notice The baseGas function should always return a value greater than @@ -30,8 +33,8 @@ contract CrossDomainMessenger_BaseGas_Test is Messenger_Initializer { /// gas to the OptimismPortal. function testFuzz_baseGas_portalMinGasLimit_succeeds(bytes memory _data, uint32 _minGasLimit) external { vm.assume(_data.length <= type(uint64).max); - uint64 baseGas = L1Messenger.baseGas(_data, _minGasLimit); - uint64 minGasLimit = op.minimumGasLimit(uint64(_data.length)); + uint64 baseGas = l1CrossDomainMessenger.baseGas(_data, _minGasLimit); + uint64 minGasLimit = optimismPortal.minimumGasLimit(uint64(_data.length)); assertTrue(baseGas >= minGasLimit); } } @@ -39,21 +42,21 @@ contract CrossDomainMessenger_BaseGas_Test is Messenger_Initializer { /// @title ExternalRelay /// @notice A mock external contract called via the SafeCall inside /// the CrossDomainMessenger's `relayMessage` function. -contract ExternalRelay is CommonTest { +contract ExternalRelay is Test { address internal op; address internal fuzzedSender; - L1CrossDomainMessenger internal L1Messenger; + L1CrossDomainMessenger internal l1CrossDomainMessenger; event FailedRelayedMessage(bytes32 indexed msgHash); constructor(L1CrossDomainMessenger _l1Messenger, address _op) { - L1Messenger = _l1Messenger; + l1CrossDomainMessenger = _l1Messenger; op = _op; } /// @notice Internal helper function to relay a message and perform assertions. function _internalRelay(address _innerSender) internal { - address initialSender = L1Messenger.xDomainMessageSender(); + address initialSender = l1CrossDomainMessenger.xDomainMessageSender(); bytes memory callMessage = getCallData(); @@ -70,7 +73,7 @@ contract ExternalRelay is CommonTest { emit FailedRelayedMessage(hash); vm.prank(address(op)); - L1Messenger.relayMessage({ + l1CrossDomainMessenger.relayMessage({ _nonce: Encoding.encodeVersionedNonce({ _nonce: 0, _version: 1 }), _sender: _innerSender, _target: address(this), @@ -79,9 +82,9 @@ contract ExternalRelay is CommonTest { _message: callMessage }); - assertTrue(L1Messenger.failedMessages(hash)); - assertFalse(L1Messenger.successfulMessages(hash)); - assertEq(initialSender, L1Messenger.xDomainMessageSender()); + assertTrue(l1CrossDomainMessenger.failedMessages(hash)); + assertFalse(l1CrossDomainMessenger.successfulMessages(hash)); + assertEq(initialSender, l1CrossDomainMessenger.xDomainMessageSender()); } /// @notice externalCallWithMinGas is called by the CrossDomainMessenger. @@ -108,7 +111,7 @@ contract ExternalRelay is CommonTest { /// @title CrossDomainMessenger_RelayMessage_Test /// @notice Fuzz tests re-entrancy into the CrossDomainMessenger relayMessage function. -contract CrossDomainMessenger_RelayMessage_Test is Messenger_Initializer { +contract CrossDomainMessenger_RelayMessage_Test is Bridge_Initializer { // Storage slot of the l2Sender uint256 constant senderSlotIndex = 50; @@ -116,7 +119,7 @@ contract CrossDomainMessenger_RelayMessage_Test is Messenger_Initializer { function setUp() public override { super.setUp(); - er = new ExternalRelay(L1Messenger, address(op)); + er = new ExternalRelay(l1CrossDomainMessenger, address(optimismPortal)); } /// @dev This test mocks an OptimismPortal call to the L1CrossDomainMessenger via @@ -148,9 +151,9 @@ contract CrossDomainMessenger_RelayMessage_Test is Messenger_Initializer { }); // set the value of op.l2Sender() to be the L2 Cross Domain Messenger. - vm.store(address(op), bytes32(senderSlotIndex), bytes32(abi.encode(sender))); - vm.prank(address(op)); - L1Messenger.relayMessage({ + vm.store(address(optimismPortal), bytes32(senderSlotIndex), bytes32(abi.encode(sender))); + vm.prank(address(optimismPortal)); + l1CrossDomainMessenger.relayMessage({ _nonce: Encoding.encodeVersionedNonce({ _nonce: 0, _version: 1 }), _sender: sender, _target: target, @@ -159,11 +162,11 @@ contract CrossDomainMessenger_RelayMessage_Test is Messenger_Initializer { _message: callMessage }); - assertTrue(L1Messenger.successfulMessages(hash)); - assertEq(L1Messenger.failedMessages(hash), false); + assertTrue(l1CrossDomainMessenger.successfulMessages(hash)); + assertEq(l1CrossDomainMessenger.failedMessages(hash), false); // Ensures that the `xDomainMsgSender` is set back to `Predeploys.L2_CROSS_DOMAIN_MESSENGER` vm.expectRevert("CrossDomainMessenger: xDomainMessageSender is not set"); - L1Messenger.xDomainMessageSender(); + l1CrossDomainMessenger.xDomainMessageSender(); } } diff --git a/packages/contracts-bedrock/test/CrossDomainOwnable.t.sol b/packages/contracts-bedrock/test/CrossDomainOwnable.t.sol index 51394e3695929..1e7c10556a536 100644 --- a/packages/contracts-bedrock/test/CrossDomainOwnable.t.sol +++ b/packages/contracts-bedrock/test/CrossDomainOwnable.t.sol @@ -2,17 +2,18 @@ pragma solidity 0.8.15; // Testing utilities -import { Vm, VmSafe } from "forge-std/Vm.sol"; -import { CommonTest, Portal_Initializer } from "./CommonTest.t.sol"; +import { VmSafe } from "forge-std/Vm.sol"; +import { Test } from "forge-std/Test.sol"; +import { CommonTest } from "test/setup/CommonTest.sol"; // Libraries import { Bytes32AddressLib } from "@rari-capital/solmate/src/utils/Bytes32AddressLib.sol"; // Target contract dependencies -import { AddressAliasHelper } from "../src/vendor/AddressAliasHelper.sol"; +import { AddressAliasHelper } from "src/vendor/AddressAliasHelper.sol"; // Target contract -import { CrossDomainOwnable } from "../src/L2/CrossDomainOwnable.sol"; +import { CrossDomainOwnable } from "src/L2/CrossDomainOwnable.sol"; contract XDomainSetter is CrossDomainOwnable { uint256 public value; @@ -22,11 +23,10 @@ contract XDomainSetter is CrossDomainOwnable { } } -contract CrossDomainOwnable_Test is CommonTest { +contract CrossDomainOwnable_Test is Test { XDomainSetter setter; - function setUp() public override { - super.setUp(); + function setUp() public { setter = new XDomainSetter(); } @@ -46,7 +46,7 @@ contract CrossDomainOwnable_Test is CommonTest { } } -contract CrossDomainOwnableThroughPortal_Test is Portal_Initializer { +contract CrossDomainOwnableThroughPortal_Test is CommonTest { XDomainSetter setter; /// @dev Sets up the test suite. @@ -63,7 +63,7 @@ contract CrossDomainOwnableThroughPortal_Test is Portal_Initializer { vm.recordLogs(); vm.prank(alice); - op.depositTransaction({ + optimismPortal.depositTransaction({ _to: address(setter), _value: 0, _gasLimit: 30_000, diff --git a/packages/contracts-bedrock/test/CrossDomainOwnable2.t.sol b/packages/contracts-bedrock/test/CrossDomainOwnable2.t.sol index 2eb3082d9dfe1..fa1244a0b0e12 100644 --- a/packages/contracts-bedrock/test/CrossDomainOwnable2.t.sol +++ b/packages/contracts-bedrock/test/CrossDomainOwnable2.t.sol @@ -2,18 +2,18 @@ pragma solidity 0.8.15; // Testing utilities -import { CommonTest, Messenger_Initializer } from "./CommonTest.t.sol"; +import { Bridge_Initializer } from "test/setup/Bridge_Initializer.sol"; // Libraries -import { Hashing } from "../src/libraries/Hashing.sol"; -import { Encoding } from "../src/libraries/Encoding.sol"; +import { Hashing } from "src/libraries/Hashing.sol"; +import { Encoding } from "src/libraries/Encoding.sol"; import { Bytes32AddressLib } from "@rari-capital/solmate/src/utils/Bytes32AddressLib.sol"; // Target contract dependencies -import { AddressAliasHelper } from "../src/vendor/AddressAliasHelper.sol"; +import { AddressAliasHelper } from "src/vendor/AddressAliasHelper.sol"; // Target contract -import { CrossDomainOwnable2 } from "../src/L2/CrossDomainOwnable2.sol"; +import { CrossDomainOwnable2 } from "src/L2/CrossDomainOwnable2.sol"; contract XDomainSetter2 is CrossDomainOwnable2 { uint256 public value; @@ -23,7 +23,7 @@ contract XDomainSetter2 is CrossDomainOwnable2 { } } -contract CrossDomainOwnable2_Test is Messenger_Initializer { +contract CrossDomainOwnable2_Test is Bridge_Initializer { XDomainSetter2 setter; /// @dev Sets up the test suite. @@ -44,9 +44,9 @@ contract CrossDomainOwnable2_Test is Messenger_Initializer { // set the xDomainMsgSender storage slot bytes32 key = bytes32(uint256(204)); bytes32 value = Bytes32AddressLib.fillLast12Bytes(address(alice)); - vm.store(address(L2Messenger), key, value); + vm.store(address(l2CrossDomainMessenger), key, value); - vm.prank(address(L2Messenger)); + vm.prank(address(l2CrossDomainMessenger)); vm.expectRevert("CrossDomainOwnable2: caller is not the owner"); setter.set(1); } @@ -69,8 +69,10 @@ contract CrossDomainOwnable2_Test is Messenger_Initializer { vm.expectEmit(true, true, true, true); emit FailedRelayedMessage(hash); - vm.prank(AddressAliasHelper.applyL1ToL2Alias(address(L1Messenger))); - L2Messenger.relayMessage(Encoding.encodeVersionedNonce(nonce, 1), sender, target, value, minGasLimit, message); + vm.prank(AddressAliasHelper.applyL1ToL2Alias(address(l1CrossDomainMessenger))); + l2CrossDomainMessenger.relayMessage( + Encoding.encodeVersionedNonce(nonce, 1), sender, target, value, minGasLimit, message + ); assertEq(setter.value(), 0); } @@ -81,8 +83,8 @@ contract CrossDomainOwnable2_Test is Messenger_Initializer { // Simulate the L2 execution where the call is coming from // the L1CrossDomainMessenger - vm.prank(AddressAliasHelper.applyL1ToL2Alias(address(L1Messenger))); - L2Messenger.relayMessage( + vm.prank(AddressAliasHelper.applyL1ToL2Alias(address(l1CrossDomainMessenger))); + l2CrossDomainMessenger.relayMessage( Encoding.encodeVersionedNonce(1, 1), owner, address(setter), diff --git a/packages/contracts-bedrock/test/CrossDomainOwnable3.t.sol b/packages/contracts-bedrock/test/CrossDomainOwnable3.t.sol index b2a7ff522c17e..24eab5f55a48e 100644 --- a/packages/contracts-bedrock/test/CrossDomainOwnable3.t.sol +++ b/packages/contracts-bedrock/test/CrossDomainOwnable3.t.sol @@ -2,18 +2,18 @@ pragma solidity 0.8.15; // Testing utilities -import { CommonTest, Messenger_Initializer } from "./CommonTest.t.sol"; +import { Bridge_Initializer } from "test/setup/Bridge_Initializer.sol"; // Libraries -import { Hashing } from "../src/libraries/Hashing.sol"; -import { Encoding } from "../src/libraries/Encoding.sol"; +import { Hashing } from "src/libraries/Hashing.sol"; +import { Encoding } from "src/libraries/Encoding.sol"; import { Bytes32AddressLib } from "@rari-capital/solmate/src/utils/Bytes32AddressLib.sol"; // Target contract dependencies -import { AddressAliasHelper } from "../src/vendor/AddressAliasHelper.sol"; +import { AddressAliasHelper } from "src/vendor/AddressAliasHelper.sol"; // Target contract -import { CrossDomainOwnable3 } from "../src/L2/CrossDomainOwnable3.sol"; +import { CrossDomainOwnable3 } from "src/L2/CrossDomainOwnable3.sol"; contract XDomainSetter3 is CrossDomainOwnable3 { uint256 public value; @@ -23,7 +23,7 @@ contract XDomainSetter3 is CrossDomainOwnable3 { } } -contract CrossDomainOwnable3_Test is Messenger_Initializer { +contract CrossDomainOwnable3_Test is Bridge_Initializer { XDomainSetter3 setter; /// @dev CrossDomainOwnable3.sol transferOwnership event @@ -73,9 +73,9 @@ contract CrossDomainOwnable3_Test is Messenger_Initializer { // set the xDomainMsgSender storage slot bytes32 key = bytes32(uint256(204)); bytes32 value = Bytes32AddressLib.fillLast12Bytes(bob); - vm.store(address(L2Messenger), key, value); + vm.store(address(l2CrossDomainMessenger), key, value); - vm.prank(address(L2Messenger)); + vm.prank(address(l2CrossDomainMessenger)); vm.expectRevert("CrossDomainOwnable3: caller is not the owner"); setter.set(1); } @@ -109,11 +109,13 @@ contract CrossDomainOwnable3_Test is Messenger_Initializer { // It should be a failed message. The revert is caught, // so we cannot expectRevert here. - vm.expectEmit(true, true, true, true, address(L2Messenger)); + vm.expectEmit(true, true, true, true, address(l2CrossDomainMessenger)); emit FailedRelayedMessage(hash); - vm.prank(AddressAliasHelper.applyL1ToL2Alias(address(L1Messenger))); - L2Messenger.relayMessage(Encoding.encodeVersionedNonce(nonce, 1), sender, target, value, minGasLimit, message); + vm.prank(AddressAliasHelper.applyL1ToL2Alias(address(l1CrossDomainMessenger))); + l2CrossDomainMessenger.relayMessage( + Encoding.encodeVersionedNonce(nonce, 1), sender, target, value, minGasLimit, message + ); assertEq(setter.value(), 0); } @@ -212,8 +214,8 @@ contract CrossDomainOwnable3_Test is Messenger_Initializer { // Simulate the L2 execution where the call is coming from // the L1CrossDomainMessenger - vm.prank(AddressAliasHelper.applyL1ToL2Alias(address(L1Messenger))); - L2Messenger.relayMessage( + vm.prank(AddressAliasHelper.applyL1ToL2Alias(address(l1CrossDomainMessenger))); + l2CrossDomainMessenger.relayMessage( Encoding.encodeVersionedNonce(1, 1), bob, address(setter), diff --git a/packages/contracts-bedrock/test/DelayedVetoable.t.sol b/packages/contracts-bedrock/test/DelayedVetoable.t.sol index cf891069da2b3..93063359cb2e5 100644 --- a/packages/contracts-bedrock/test/DelayedVetoable.t.sol +++ b/packages/contracts-bedrock/test/DelayedVetoable.t.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity 0.8.15; -import { CommonTest } from "./CommonTest.t.sol"; +import { CommonTest } from "test/setup/CommonTest.sol"; import { DelayedVetoable } from "src/L1/DelayedVetoable.sol"; contract DelayedVetoable_Init is CommonTest { @@ -146,7 +146,7 @@ contract DelayedVetoable_HandleCall_TestFail is DelayedVetoable_Init { /// @dev Only the initiator can initiate a call. function test_handleCall_unauthorizedInitiation_reverts() external { vm.expectRevert(abi.encodeWithSelector(Unauthorized.selector, initiator, address(this))); - (bool success,) = address(delayedVetoable).call(NON_ZERO_DATA); + (bool success,) = address(delayedVetoable).call(hex"00001234"); assertTrue(success); } diff --git a/packages/contracts-bedrock/test/DeployerWhitelist.t.sol b/packages/contracts-bedrock/test/DeployerWhitelist.t.sol index 0d8eda5dcd494..19dc879d44a28 100644 --- a/packages/contracts-bedrock/test/DeployerWhitelist.t.sol +++ b/packages/contracts-bedrock/test/DeployerWhitelist.t.sol @@ -2,16 +2,16 @@ pragma solidity 0.8.15; // Testing utilities -import { CommonTest } from "./CommonTest.t.sol"; +import { Test } from "forge-std/Test.sol"; // Target contract -import { DeployerWhitelist } from "../src/legacy/DeployerWhitelist.sol"; +import { DeployerWhitelist } from "src/legacy/DeployerWhitelist.sol"; -contract DeployerWhitelist_Test is CommonTest { +contract DeployerWhitelist_Test is Test { DeployerWhitelist list; /// @dev Sets up the test suite. - function setUp() public virtual override { + function setUp() public { list = new DeployerWhitelist(); } diff --git a/packages/contracts-bedrock/test/DisputeGameFactory.t.sol b/packages/contracts-bedrock/test/DisputeGameFactory.t.sol index 1f81c8b58b3dd..d9f058d2c558e 100644 --- a/packages/contracts-bedrock/test/DisputeGameFactory.t.sol +++ b/packages/contracts-bedrock/test/DisputeGameFactory.t.sol @@ -1,16 +1,16 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.15; -import "../src/libraries/DisputeTypes.sol"; -import "../src/libraries/DisputeErrors.sol"; +import "src/libraries/DisputeTypes.sol"; +import "src/libraries/DisputeErrors.sol"; import { Test } from "forge-std/Test.sol"; -import { DisputeGameFactory } from "../src/dispute/DisputeGameFactory.sol"; -import { IDisputeGame } from "../src/dispute/interfaces/IDisputeGame.sol"; -import { Proxy } from "../src/universal/Proxy.sol"; -import { L2OutputOracle_Initializer } from "./CommonTest.t.sol"; +import { DisputeGameFactory } from "src/dispute/DisputeGameFactory.sol"; +import { IDisputeGame } from "src/dispute/interfaces/IDisputeGame.sol"; +import { Proxy } from "src/universal/Proxy.sol"; +import { CommonTest } from "test/setup/CommonTest.sol"; -contract DisputeGameFactory_Init is L2OutputOracle_Initializer { +contract DisputeGameFactory_Init is CommonTest { DisputeGameFactory factory; FakeClone fakeClone; diff --git a/packages/contracts-bedrock/test/Drippie.t.sol b/packages/contracts-bedrock/test/Drippie.t.sol index 33a69d861111e..c56b9292378a8 100644 --- a/packages/contracts-bedrock/test/Drippie.t.sol +++ b/packages/contracts-bedrock/test/Drippie.t.sol @@ -2,10 +2,10 @@ pragma solidity 0.8.15; import { Test } from "forge-std/Test.sol"; -import { Drippie } from "../src/periphery/drippie/Drippie.sol"; -import { IDripCheck } from "../src/periphery/drippie/IDripCheck.sol"; -import { CheckTrue } from "../src/periphery/drippie/dripchecks/CheckTrue.sol"; -import { SimpleStorage } from "./Helpers.sol"; +import { Drippie } from "src/periphery/drippie/Drippie.sol"; +import { IDripCheck } from "src/periphery/drippie/IDripCheck.sol"; +import { CheckTrue } from "src/periphery/drippie/dripchecks/CheckTrue.sol"; +import { SimpleStorage } from "test/mocks/SimpleStorage.sol"; /// @title TestDrippie /// @notice This is a wrapper contract around Drippie used for testing. diff --git a/packages/contracts-bedrock/test/Encoding.t.sol b/packages/contracts-bedrock/test/Encoding.t.sol index f2261801bb250..35e9300f834e7 100644 --- a/packages/contracts-bedrock/test/Encoding.t.sol +++ b/packages/contracts-bedrock/test/Encoding.t.sol @@ -2,14 +2,14 @@ pragma solidity 0.8.15; // Testing utilities -import { CommonTest } from "./CommonTest.t.sol"; +import { CommonTest } from "test/setup/CommonTest.sol"; // Libraries -import { Types } from "../src/libraries/Types.sol"; -import { LegacyCrossDomainUtils } from "../src/libraries/LegacyCrossDomainUtils.sol"; +import { Types } from "src/libraries/Types.sol"; +import { LegacyCrossDomainUtils } from "src/libraries/LegacyCrossDomainUtils.sol"; // Target contract -import { Encoding } from "../src/libraries/Encoding.sol"; +import { Encoding } from "src/libraries/Encoding.sol"; contract Encoding_Test is CommonTest { /// @dev Tests encoding and decoding a nonce and version. diff --git a/packages/contracts-bedrock/test/Faucet.t.sol b/packages/contracts-bedrock/test/Faucet.t.sol index 3f3ca41a8963a..24494edfb1a60 100644 --- a/packages/contracts-bedrock/test/Faucet.t.sol +++ b/packages/contracts-bedrock/test/Faucet.t.sol @@ -2,9 +2,9 @@ pragma solidity 0.8.15; import { Test } from "forge-std/Test.sol"; -import { Faucet } from "../src/periphery/faucet/Faucet.sol"; -import { AdminFaucetAuthModule } from "../src/periphery/faucet/authmodules/AdminFaucetAuthModule.sol"; -import { FaucetHelper } from "./Helpers.sol"; +import { Faucet } from "src/periphery/faucet/Faucet.sol"; +import { AdminFaucetAuthModule } from "src/periphery/faucet/authmodules/AdminFaucetAuthModule.sol"; +import { FaucetHelper } from "test/mocks/FaucetHelper.sol"; contract Faucet_Initializer is Test { event Drip(string indexed authModule, bytes32 indexed userId, uint256 amount, address indexed recipient); diff --git a/packages/contracts-bedrock/test/FaultDisputeGame.t.sol b/packages/contracts-bedrock/test/FaultDisputeGame.t.sol index 782b6581d9229..134568776c3a4 100644 --- a/packages/contracts-bedrock/test/FaultDisputeGame.t.sol +++ b/packages/contracts-bedrock/test/FaultDisputeGame.t.sol @@ -3,7 +3,7 @@ pragma solidity ^0.8.15; import { Test } from "forge-std/Test.sol"; import { Vm } from "forge-std/Vm.sol"; -import { DisputeGameFactory_Init } from "./DisputeGameFactory.t.sol"; +import { DisputeGameFactory_Init } from "test/DisputeGameFactory.t.sol"; import { DisputeGameFactory } from "src/dispute/DisputeGameFactory.sol"; import { FaultDisputeGame } from "src/dispute/FaultDisputeGame.sol"; import { L2OutputOracle } from "src/L1/L2OutputOracle.sol"; @@ -17,6 +17,7 @@ import { Types } from "src/libraries/Types.sol"; import { LibClock } from "src/dispute/lib/LibClock.sol"; import { LibPosition } from "src/dispute/lib/LibPosition.sol"; import { IBigStepper, IPreimageOracle } from "src/dispute/interfaces/IBigStepper.sol"; +import { AlphabetVM } from "test/mocks/AlphabetVM.sol"; contract FaultDisputeGame_Init is DisputeGameFactory_Init { /// @dev The type of the game being tested. @@ -32,15 +33,13 @@ contract FaultDisputeGame_Init is DisputeGameFactory_Init { event Move(uint256 indexed parentIndex, Claim indexed pivot, address indexed claimant); function init(Claim rootClaim, Claim absolutePrestate) public { - super.setUp(); - // Set the time to a realistic date. vm.warp(1690906994); // Propose 2 mock outputs - vm.startPrank(oracle.PROPOSER()); + vm.startPrank(l2OutputOracle.PROPOSER()); for (uint256 i; i < 2; i++) { - oracle.proposeL2Output(bytes32(i + 1), oracle.nextBlockNumber(), blockhash(i), i); + l2OutputOracle.proposeL2Output(bytes32(i + 1), l2OutputOracle.nextBlockNumber(), blockhash(i), i); // Advance 1 block vm.roll(block.number + 1); @@ -53,7 +52,7 @@ contract FaultDisputeGame_Init is DisputeGameFactory_Init { blockOracle.checkpoint(); // Set the extra data for the game creation - extraData = abi.encode(oracle.SUBMISSION_INTERVAL() * 2, block.number - 1); + extraData = abi.encode(l2OutputOracle.SUBMISSION_INTERVAL() * 2, block.number - 1); // Deploy an implementation of the fault game gameImpl = new FaultDisputeGame( @@ -62,7 +61,7 @@ contract FaultDisputeGame_Init is DisputeGameFactory_Init { 4, Duration.wrap(7 days), new AlphabetVM(absolutePrestate), - oracle, + l2OutputOracle, blockOracle ); // Register the game implementation with the factory. @@ -82,6 +81,7 @@ contract FaultDisputeGame_Test is FaultDisputeGame_Init { Claim internal constant ABSOLUTE_PRESTATE = Claim.wrap(bytes32((uint256(3) << 248) | uint256(0))); function setUp() public override { + super.setUp(); super.init(ROOT_CLAIM, ABSOLUTE_PRESTATE); } @@ -127,7 +127,7 @@ contract FaultDisputeGame_Test is FaultDisputeGame_Init { function test_initialize_l1HeadTooOld_reverts() public { // Store a mock block hash for the genesis block. The timestamp will default to 0. vm.store(address(gameImpl.BLOCK_ORACLE()), keccak256(abi.encode(0, 0)), bytes32(uint256(1))); - bytes memory _extraData = abi.encode(oracle.SUBMISSION_INTERVAL() * 2, 0); + bytes memory _extraData = abi.encode(l2OutputOracle.SUBMISSION_INTERVAL() * 2, 0); vm.expectRevert(L1HeadTooOld.selector); factory.create(GAME_TYPE, ROOT_CLAIM, _extraData); @@ -139,8 +139,9 @@ contract FaultDisputeGame_Test is FaultDisputeGame_Init { /// For now, it is critical that the first proposed output root of an OP stack /// chain is done so by an honest party. function test_initialize_firstOutput_reverts() public { + uint256 submissionInterval = l2OutputOracle.submissionInterval(); vm.expectRevert(abi.encodeWithSignature("Panic(uint256)", 0x11)); - factory.create(GAME_TYPE, ROOT_CLAIM, abi.encode(1800, block.number - 1)); + factory.create(GAME_TYPE, ROOT_CLAIM, abi.encode(submissionInterval, block.number - 1)); } /// @dev Tests that the `create` function reverts when the rootClaim does not disagree with the outcome. @@ -159,12 +160,12 @@ contract FaultDisputeGame_Test is FaultDisputeGame_Init { // Starting (FaultDisputeGame.OutputProposal memory startingProp, FaultDisputeGame.OutputProposal memory disputedProp) = gameProxy.proposals(); - Types.OutputProposal memory starting = oracle.getL2Output(startingProp.index); + Types.OutputProposal memory starting = l2OutputOracle.getL2Output(startingProp.index); assertEq(startingProp.index, 0); assertEq(startingProp.l2BlockNumber, starting.l2BlockNumber); assertEq(Hash.unwrap(startingProp.outputRoot), starting.outputRoot); // Disputed - Types.OutputProposal memory disputed = oracle.getL2Output(disputedProp.index); + Types.OutputProposal memory disputed = l2OutputOracle.getL2Output(disputedProp.index); assertEq(disputedProp.index, 1); assertEq(disputedProp.l2BlockNumber, disputed.l2BlockNumber); assertEq(Hash.unwrap(disputedProp.outputRoot), disputed.outputRoot); @@ -483,12 +484,12 @@ contract FaultDisputeGame_Test is FaultDisputeGame_Init { } /// @dev Tests that adding local data with an out of bounds identifier reverts. - function testFuzz_addLocalData_oob_reverts(uint256 _ident) public { + function testFuzz_addLocalData_oob_reverts(uint256 _ident, uint256 _localContext) public { // [1, 5] are valid local data identifiers. if (_ident <= 5) _ident = 0; vm.expectRevert(InvalidLocalIdent.selector); - gameProxy.addLocalData(_ident, 0); + gameProxy.addLocalData(_ident, _localContext, 0); } /// @dev Tests that local data is loaded into the preimage oracle correctly. @@ -508,8 +509,8 @@ contract FaultDisputeGame_Test is FaultDisputeGame_Init { for (uint256 i = 1; i <= 5; i++) { uint256 expectedLen = i > 3 ? 8 : 32; - gameProxy.addLocalData(i, 0); - bytes32 key = _getKey(i); + gameProxy.addLocalData(i, 0, 0); + bytes32 key = _getKey(i, 0); (bytes32 dat, uint256 datLen) = oracle.readPreimage(key, 0); assertEq(dat >> 0xC0, bytes32(expectedLen)); // Account for the length prefix if i > 3 (the data stored @@ -519,8 +520,8 @@ contract FaultDisputeGame_Test is FaultDisputeGame_Init { // total.) assertEq(datLen, expectedLen + (i > 3 ? 8 : 0)); - gameProxy.addLocalData(i, 8); - key = _getKey(i); + gameProxy.addLocalData(i, 0, 8); + key = _getKey(i, 0); (dat, datLen) = oracle.readPreimage(key, 8); assertEq(dat, data[i - 1]); assertEq(datLen, expectedLen); @@ -528,8 +529,8 @@ contract FaultDisputeGame_Test is FaultDisputeGame_Init { } /// @dev Helper to get the localized key for an identifier in the context of the game proxy. - function _getKey(uint256 _ident) internal view returns (bytes32) { - bytes32 h = keccak256(abi.encode(_ident | (1 << 248), address(gameProxy))); + function _getKey(uint256 _ident, uint256 _localContext) internal view returns (bytes32) { + bytes32 h = keccak256(abi.encode(_ident | (1 << 248), address(gameProxy), _localContext)); return bytes32((uint256(h) & ~uint256(0xFF << 248)) | (1 << 248)); } @@ -755,6 +756,7 @@ contract OneVsOne_Arena is FaultDisputeGame_Init { contract FaultDisputeGame_ResolvesCorrectly_IncorrectRoot1 is OneVsOne_Arena { function setUp() public override { + super.setUp(); GamePlayer honest = new HonestPlayer(ABSOLUTE_PRESTATE); GamePlayer dishonest = new VariableDivergentPlayer(ABSOLUTE_PRESTATE, 16, 0); super.init(dishonest, honest, 15); @@ -777,6 +779,7 @@ contract FaultDisputeGame_ResolvesCorrectly_IncorrectRoot1 is OneVsOne_Arena { contract FaultDisputeGame_ResolvesCorrectly_CorrectRoot1 is OneVsOne_Arena { function setUp() public override { + super.setUp(); GamePlayer honest = new HonestPlayer(ABSOLUTE_PRESTATE); GamePlayer dishonest = new VariableDivergentPlayer(ABSOLUTE_PRESTATE, 16, 0); super.init(honest, dishonest, 15); @@ -799,6 +802,7 @@ contract FaultDisputeGame_ResolvesCorrectly_CorrectRoot1 is OneVsOne_Arena { contract FaultDisputeGame_ResolvesCorrectly_IncorrectRoot2 is OneVsOne_Arena { function setUp() public override { + super.setUp(); GamePlayer honest = new HonestPlayer(ABSOLUTE_PRESTATE); GamePlayer dishonest = new VariableDivergentPlayer(ABSOLUTE_PRESTATE, 16, 7); super.init(dishonest, honest, 15); @@ -821,6 +825,7 @@ contract FaultDisputeGame_ResolvesCorrectly_IncorrectRoot2 is OneVsOne_Arena { contract FaultDisputeGame_ResolvesCorrectly_CorrectRoot2 is OneVsOne_Arena { function setUp() public override { + super.setUp(); GamePlayer honest = new HonestPlayer(ABSOLUTE_PRESTATE); GamePlayer dishonest = new VariableDivergentPlayer(ABSOLUTE_PRESTATE, 16, 7); super.init(honest, dishonest, 15); @@ -843,6 +848,7 @@ contract FaultDisputeGame_ResolvesCorrectly_CorrectRoot2 is OneVsOne_Arena { contract FaultDisputeGame_ResolvesCorrectly_IncorrectRoot3 is OneVsOne_Arena { function setUp() public override { + super.setUp(); GamePlayer honest = new HonestPlayer(ABSOLUTE_PRESTATE); GamePlayer dishonest = new VariableDivergentPlayer(ABSOLUTE_PRESTATE, 16, 2); super.init(dishonest, honest, 15); @@ -865,6 +871,7 @@ contract FaultDisputeGame_ResolvesCorrectly_IncorrectRoot3 is OneVsOne_Arena { contract FaultDisputeGame_ResolvesCorrectly_CorrectRoot3 is OneVsOne_Arena { function setUp() public override { + super.setUp(); GamePlayer honest = new HonestPlayer(ABSOLUTE_PRESTATE); GamePlayer dishonest = new VariableDivergentPlayer(ABSOLUTE_PRESTATE, 16, 2); super.init(honest, dishonest, 15); @@ -887,6 +894,7 @@ contract FaultDisputeGame_ResolvesCorrectly_CorrectRoot3 is OneVsOne_Arena { contract FaultDisputeGame_ResolvesCorrectly_IncorrectRoot4 is OneVsOne_Arena { function setUp() public override { + super.setUp(); GamePlayer honest = new HonestPlayer_HalfTrace(ABSOLUTE_PRESTATE); GamePlayer dishonest = new VariableDivergentPlayer(ABSOLUTE_PRESTATE, 8, 5); super.init(dishonest, honest, 7); @@ -909,6 +917,7 @@ contract FaultDisputeGame_ResolvesCorrectly_IncorrectRoot4 is OneVsOne_Arena { contract FaultDisputeGame_ResolvesCorrectly_CorrectRoot4 is OneVsOne_Arena { function setUp() public override { + super.setUp(); GamePlayer honest = new HonestPlayer_HalfTrace(ABSOLUTE_PRESTATE); GamePlayer dishonest = new VariableDivergentPlayer(ABSOLUTE_PRESTATE, 8, 5); super.init(honest, dishonest, 7); @@ -931,6 +940,7 @@ contract FaultDisputeGame_ResolvesCorrectly_CorrectRoot4 is OneVsOne_Arena { contract FaultDisputeGame_ResolvesCorrectly_IncorrectRoot5 is OneVsOne_Arena { function setUp() public override { + super.setUp(); GamePlayer honest = new HonestPlayer_QuarterTrace(ABSOLUTE_PRESTATE); GamePlayer dishonest = new VariableDivergentPlayer(ABSOLUTE_PRESTATE, 4, 3); super.init(dishonest, honest, 3); @@ -953,6 +963,7 @@ contract FaultDisputeGame_ResolvesCorrectly_IncorrectRoot5 is OneVsOne_Arena { contract FaultDisputeGame_ResolvesCorrectly_CorrectRoot5 is OneVsOne_Arena { function setUp() public override { + super.setUp(); GamePlayer honest = new HonestPlayer_QuarterTrace(ABSOLUTE_PRESTATE); GamePlayer dishonest = new VariableDivergentPlayer(ABSOLUTE_PRESTATE, 4, 3); super.init(honest, dishonest, 3); @@ -1084,37 +1095,3 @@ contract VariableDivergentPlayer is GamePlayer { trace = _trace; } } - -//////////////////////////////////////////////////////////////// -// MOCK VMS // -//////////////////////////////////////////////////////////////// - -contract AlphabetVM is IBigStepper { - Claim internal immutable ABSOLUTE_PRESTATE; - IPreimageOracle public oracle; - - constructor(Claim _absolutePrestate) { - ABSOLUTE_PRESTATE = _absolutePrestate; - oracle = new PreimageOracle(); - } - - /// @inheritdoc IBigStepper - function step(bytes calldata _stateData, bytes calldata) external view returns (bytes32 postState_) { - uint256 traceIndex; - uint256 claim; - if ((keccak256(_stateData) << 8) == (Claim.unwrap(ABSOLUTE_PRESTATE) << 8)) { - // If the state data is empty, then the absolute prestate is the claim. - traceIndex = 0; - (claim) = abi.decode(_stateData, (uint256)); - } else { - // Otherwise, decode the state data. - (traceIndex, claim) = abi.decode(_stateData, (uint256, uint256)); - traceIndex++; - } - // STF: n -> n + 1 - postState_ = keccak256(abi.encode(traceIndex, claim + 1)); - assembly { - postState_ := or(and(postState_, not(shl(248, 0xFF))), shl(248, 1)) - } - } -} diff --git a/packages/contracts-bedrock/test/FeeVault.t.sol b/packages/contracts-bedrock/test/FeeVault.t.sol index dede09e762f66..98de404214425 100644 --- a/packages/contracts-bedrock/test/FeeVault.t.sol +++ b/packages/contracts-bedrock/test/FeeVault.t.sol @@ -2,49 +2,24 @@ pragma solidity 0.8.15; // Testing utilities -import { Bridge_Initializer } from "./CommonTest.t.sol"; -import { BaseFeeVault } from "../src/L2/BaseFeeVault.sol"; -import { StandardBridge } from "../src/universal/StandardBridge.sol"; - -// Libraries -import { Predeploys } from "../src/libraries/Predeploys.sol"; - -// Target contract dependencies -import { FeeVault } from "../src/universal/FeeVault.sol"; +import { Bridge_Initializer } from "test/setup/Bridge_Initializer.sol"; // Target contract -import { L1FeeVault } from "../src/L2/L1FeeVault.sol"; +import { FeeVault } from "src/universal/FeeVault.sol"; // Test the implementations of the FeeVault contract FeeVault_Test is Bridge_Initializer { - BaseFeeVault baseFeeVault = BaseFeeVault(payable(Predeploys.BASE_FEE_VAULT)); - L1FeeVault l1FeeVault = L1FeeVault(payable(Predeploys.L1_FEE_VAULT)); - - uint256 constant otherMinimumWithdrawalAmount = 10 ether; - - /// @dev Sets up the test suite. - function setUp() public override { - super.setUp(); - vm.etch( - Predeploys.BASE_FEE_VAULT, - address(new BaseFeeVault(alice, NON_ZERO_VALUE, FeeVault.WithdrawalNetwork.L1)).code - ); - vm.etch( - Predeploys.L1_FEE_VAULT, - address(new L1FeeVault(bob, otherMinimumWithdrawalAmount, FeeVault.WithdrawalNetwork.L2)).code - ); - - vm.label(Predeploys.BASE_FEE_VAULT, "BaseFeeVault"); - vm.label(Predeploys.L1_FEE_VAULT, "L1FeeVault"); + /// @dev Tests that the constructor sets the correct values. + function test_constructor_l1FeeVault_succeeds() external { + assertEq(l1FeeVault.RECIPIENT(), cfg.l1FeeVaultRecipient()); + assertEq(l1FeeVault.MIN_WITHDRAWAL_AMOUNT(), cfg.l1FeeVaultMinimumWithdrawalAmount()); + assertEq(uint8(l1FeeVault.WITHDRAWAL_NETWORK()), uint8(FeeVault.WithdrawalNetwork.L2)); } /// @dev Tests that the constructor sets the correct values. - function test_constructor_succeeds() external { - assertEq(baseFeeVault.RECIPIENT(), alice); - assertEq(l1FeeVault.RECIPIENT(), bob); - assertEq(baseFeeVault.MIN_WITHDRAWAL_AMOUNT(), NON_ZERO_VALUE); - assertEq(l1FeeVault.MIN_WITHDRAWAL_AMOUNT(), otherMinimumWithdrawalAmount); + function test_constructor_baseFeeVault_succeeds() external { + assertEq(baseFeeVault.RECIPIENT(), cfg.baseFeeVaultRecipient()); + assertEq(baseFeeVault.MIN_WITHDRAWAL_AMOUNT(), cfg.baseFeeVaultMinimumWithdrawalAmount()); assertEq(uint8(baseFeeVault.WITHDRAWAL_NETWORK()), uint8(FeeVault.WithdrawalNetwork.L1)); - assertEq(uint8(l1FeeVault.WITHDRAWAL_NETWORK()), uint8(FeeVault.WithdrawalNetwork.L2)); } } diff --git a/packages/contracts-bedrock/test/GasPriceOracle.t.sol b/packages/contracts-bedrock/test/GasPriceOracle.t.sol index 7a69ed1bf806a..5e9d71e7baa5b 100644 --- a/packages/contracts-bedrock/test/GasPriceOracle.t.sol +++ b/packages/contracts-bedrock/test/GasPriceOracle.t.sol @@ -2,22 +2,13 @@ pragma solidity 0.8.15; // Testing utilities -import { CommonTest } from "./CommonTest.t.sol"; - -// Target contract dependencies -import { L1Block } from "../src/L2/L1Block.sol"; -import { Predeploys } from "../src/libraries/Predeploys.sol"; - -// Target contract -import { GasPriceOracle } from "../src/L2/GasPriceOracle.sol"; +import { CommonTest } from "test/setup/CommonTest.sol"; contract GasPriceOracle_Test is CommonTest { event OverheadUpdated(uint256); event ScalarUpdated(uint256); event DecimalsUpdated(uint256); - GasPriceOracle gasOracle; - L1Block l1Block; address depositor; // The initial L1 context values @@ -33,17 +24,9 @@ contract GasPriceOracle_Test is CommonTest { /// @dev Sets up the test suite. function setUp() public virtual override { super.setUp(); - // place the L1Block contract at the predeploy address - vm.etch(Predeploys.L1_BLOCK_ATTRIBUTES, address(new L1Block()).code); - l1Block = L1Block(Predeploys.L1_BLOCK_ATTRIBUTES); depositor = l1Block.DEPOSITOR_ACCOUNT(); - // We are not setting the gas oracle at its predeploy - // address for simplicity purposes. Nothing in this test - // requires it to be at a particular address - gasOracle = new GasPriceOracle(); - vm.prank(depositor); l1Block.setL1BlockValues({ _number: number, @@ -59,43 +42,43 @@ contract GasPriceOracle_Test is CommonTest { /// @dev Tests that `l1BaseFee` is set correctly. function test_l1BaseFee_succeeds() external { - assertEq(gasOracle.l1BaseFee(), basefee); + assertEq(gasPriceOracle.l1BaseFee(), basefee); } /// @dev Tests that `gasPrice` is set correctly. function test_gasPrice_succeeds() external { vm.fee(100); - uint256 gasPrice = gasOracle.gasPrice(); + uint256 gasPrice = gasPriceOracle.gasPrice(); assertEq(gasPrice, 100); } /// @dev Tests that `baseFee` is set correctly. function test_baseFee_succeeds() external { vm.fee(64); - uint256 gasPrice = gasOracle.baseFee(); + uint256 gasPrice = gasPriceOracle.baseFee(); assertEq(gasPrice, 64); } /// @dev Tests that `scalar` is set correctly. function test_scalar_succeeds() external { - assertEq(gasOracle.scalar(), l1FeeScalar); + assertEq(gasPriceOracle.scalar(), l1FeeScalar); } /// @dev Tests that `overhead` is set correctly. function test_overhead_succeeds() external { - assertEq(gasOracle.overhead(), l1FeeOverhead); + assertEq(gasPriceOracle.overhead(), l1FeeOverhead); } /// @dev Tests that `decimals` is set correctly. function test_decimals_succeeds() external { - assertEq(gasOracle.decimals(), 6); - assertEq(gasOracle.DECIMALS(), 6); + assertEq(gasPriceOracle.decimals(), 6); + assertEq(gasPriceOracle.DECIMALS(), 6); } /// @dev Tests that `setGasPrice` reverts since it was removed in bedrock. function test_setGasPrice_doesNotExist_reverts() external { (bool success, bytes memory returndata) = - address(gasOracle).call(abi.encodeWithSignature("setGasPrice(uint256)", 1)); + address(gasPriceOracle).call(abi.encodeWithSignature("setGasPrice(uint256)", 1)); assertEq(success, false); assertEq(returndata, hex""); @@ -104,7 +87,7 @@ contract GasPriceOracle_Test is CommonTest { /// @dev Tests that `setL1BaseFee` reverts since it was removed in bedrock. function test_setL1BaseFee_doesNotExist_reverts() external { (bool success, bytes memory returndata) = - address(gasOracle).call(abi.encodeWithSignature("setL1BaseFee(uint256)", 1)); + address(gasPriceOracle).call(abi.encodeWithSignature("setL1BaseFee(uint256)", 1)); assertEq(success, false); assertEq(returndata, hex""); diff --git a/packages/contracts-bedrock/test/GovernanceToken.t.sol b/packages/contracts-bedrock/test/GovernanceToken.t.sol index c1b4b9595424f..93f0585b3ee09 100644 --- a/packages/contracts-bedrock/test/GovernanceToken.t.sol +++ b/packages/contracts-bedrock/test/GovernanceToken.t.sol @@ -2,41 +2,37 @@ pragma solidity 0.8.15; // Testing utilities -import { CommonTest } from "./CommonTest.t.sol"; - -// Target contract -import { GovernanceToken } from "../src/governance/GovernanceToken.sol"; +import { CommonTest } from "test/setup/CommonTest.sol"; contract GovernanceToken_Test is CommonTest { - address constant owner = address(0x1234); - address constant rando = address(0x5678); - GovernanceToken internal gov; + address owner; + address rando; /// @dev Sets up the test suite. function setUp() public virtual override { super.setUp(); - vm.prank(owner); - gov = new GovernanceToken(); + owner = governanceToken.owner(); + rando = makeAddr("rando"); } /// @dev Tests that the constructor sets the correct initial state. function test_constructor_succeeds() external { - assertEq(gov.owner(), owner); - assertEq(gov.name(), "Optimism"); - assertEq(gov.symbol(), "OP"); - assertEq(gov.decimals(), 18); - assertEq(gov.totalSupply(), 0); + assertEq(governanceToken.owner(), owner); + assertEq(governanceToken.name(), "Optimism"); + assertEq(governanceToken.symbol(), "OP"); + assertEq(governanceToken.decimals(), 18); + assertEq(governanceToken.totalSupply(), 0); } /// @dev Tests that the owner can successfully call `mint`. function test_mint_fromOwner_succeeds() external { // Mint 100 tokens. vm.prank(owner); - gov.mint(owner, 100); + governanceToken.mint(owner, 100); // Balances have updated correctly. - assertEq(gov.balanceOf(owner), 100); - assertEq(gov.totalSupply(), 100); + assertEq(governanceToken.balanceOf(owner), 100); + assertEq(governanceToken.totalSupply(), 100); } /// @dev Tests that `mint` reverts when called by a non-owner. @@ -44,130 +40,130 @@ contract GovernanceToken_Test is CommonTest { // Mint 100 tokens as rando. vm.prank(rando); vm.expectRevert("Ownable: caller is not the owner"); - gov.mint(owner, 100); + governanceToken.mint(owner, 100); // Balance does not update. - assertEq(gov.balanceOf(owner), 0); - assertEq(gov.totalSupply(), 0); + assertEq(governanceToken.balanceOf(owner), 0); + assertEq(governanceToken.totalSupply(), 0); } /// @dev Tests that the owner can successfully call `burn`. function test_burn_succeeds() external { // Mint 100 tokens to rando. vm.prank(owner); - gov.mint(rando, 100); + governanceToken.mint(rando, 100); // Rando burns their tokens. vm.prank(rando); - gov.burn(50); + governanceToken.burn(50); // Balances have updated correctly. - assertEq(gov.balanceOf(rando), 50); - assertEq(gov.totalSupply(), 50); + assertEq(governanceToken.balanceOf(rando), 50); + assertEq(governanceToken.totalSupply(), 50); } /// @dev Tests that the owner can successfully call `burnFrom`. function test_burnFrom_succeeds() external { // Mint 100 tokens to rando. vm.prank(owner); - gov.mint(rando, 100); + governanceToken.mint(rando, 100); // Rando approves owner to burn 50 tokens. vm.prank(rando); - gov.approve(owner, 50); + governanceToken.approve(owner, 50); // Owner burns 50 tokens from rando. vm.prank(owner); - gov.burnFrom(rando, 50); + governanceToken.burnFrom(rando, 50); // Balances have updated correctly. - assertEq(gov.balanceOf(rando), 50); - assertEq(gov.totalSupply(), 50); + assertEq(governanceToken.balanceOf(rando), 50); + assertEq(governanceToken.totalSupply(), 50); } /// @dev Tests that `transfer` correctly transfers tokens. function test_transfer_succeeds() external { // Mint 100 tokens to rando. vm.prank(owner); - gov.mint(rando, 100); + governanceToken.mint(rando, 100); // Rando transfers 50 tokens to owner. vm.prank(rando); - gov.transfer(owner, 50); + governanceToken.transfer(owner, 50); // Balances have updated correctly. - assertEq(gov.balanceOf(owner), 50); - assertEq(gov.balanceOf(rando), 50); - assertEq(gov.totalSupply(), 100); + assertEq(governanceToken.balanceOf(owner), 50); + assertEq(governanceToken.balanceOf(rando), 50); + assertEq(governanceToken.totalSupply(), 100); } /// @dev Tests that `approve` correctly sets allowances. function test_approve_succeeds() external { // Mint 100 tokens to rando. vm.prank(owner); - gov.mint(rando, 100); + governanceToken.mint(rando, 100); // Rando approves owner to spend 50 tokens. vm.prank(rando); - gov.approve(owner, 50); + governanceToken.approve(owner, 50); // Allowances have updated. - assertEq(gov.allowance(rando, owner), 50); + assertEq(governanceToken.allowance(rando, owner), 50); } /// @dev Tests that `transferFrom` correctly transfers tokens. function test_transferFrom_succeeds() external { // Mint 100 tokens to rando. vm.prank(owner); - gov.mint(rando, 100); + governanceToken.mint(rando, 100); // Rando approves owner to spend 50 tokens. vm.prank(rando); - gov.approve(owner, 50); + governanceToken.approve(owner, 50); // Owner transfers 50 tokens from rando to owner. vm.prank(owner); - gov.transferFrom(rando, owner, 50); + governanceToken.transferFrom(rando, owner, 50); // Balances have updated correctly. - assertEq(gov.balanceOf(owner), 50); - assertEq(gov.balanceOf(rando), 50); - assertEq(gov.totalSupply(), 100); + assertEq(governanceToken.balanceOf(owner), 50); + assertEq(governanceToken.balanceOf(rando), 50); + assertEq(governanceToken.totalSupply(), 100); } /// @dev Tests that `increaseAllowance` correctly increases allowances. function test_increaseAllowance_succeeds() external { // Mint 100 tokens to rando. vm.prank(owner); - gov.mint(rando, 100); + governanceToken.mint(rando, 100); // Rando approves owner to spend 50 tokens. vm.prank(rando); - gov.approve(owner, 50); + governanceToken.approve(owner, 50); // Rando increases allowance by 50 tokens. vm.prank(rando); - gov.increaseAllowance(owner, 50); + governanceToken.increaseAllowance(owner, 50); // Allowances have updated. - assertEq(gov.allowance(rando, owner), 100); + assertEq(governanceToken.allowance(rando, owner), 100); } /// @dev Tests that `decreaseAllowance` correctly decreases allowances. function test_decreaseAllowance_succeeds() external { // Mint 100 tokens to rando. vm.prank(owner); - gov.mint(rando, 100); + governanceToken.mint(rando, 100); // Rando approves owner to spend 100 tokens. vm.prank(rando); - gov.approve(owner, 100); + governanceToken.approve(owner, 100); // Rando decreases allowance by 50 tokens. vm.prank(rando); - gov.decreaseAllowance(owner, 50); + governanceToken.decreaseAllowance(owner, 50); // Allowances have updated. - assertEq(gov.allowance(rando, owner), 50); + assertEq(governanceToken.allowance(rando, owner), 50); } } diff --git a/packages/contracts-bedrock/test/Hashing.t.sol b/packages/contracts-bedrock/test/Hashing.t.sol index 33b8a10c5f416..98fa7ae485a00 100644 --- a/packages/contracts-bedrock/test/Hashing.t.sol +++ b/packages/contracts-bedrock/test/Hashing.t.sol @@ -2,15 +2,15 @@ pragma solidity 0.8.15; // Testing utilities -import { CommonTest } from "./CommonTest.t.sol"; +import { CommonTest } from "test/setup/CommonTest.sol"; // Libraries -import { Types } from "../src/libraries/Types.sol"; -import { Encoding } from "../src/libraries/Encoding.sol"; -import { LegacyCrossDomainUtils } from "../src/libraries/LegacyCrossDomainUtils.sol"; +import { Types } from "src/libraries/Types.sol"; +import { Encoding } from "src/libraries/Encoding.sol"; +import { LegacyCrossDomainUtils } from "src/libraries/LegacyCrossDomainUtils.sol"; // Target contract -import { Hashing } from "../src/libraries/Hashing.sol"; +import { Hashing } from "src/libraries/Hashing.sol"; contract Hashing_hashDepositSource_Test is CommonTest { /// @notice Tests that hashDepositSource returns the correct hash in a simple case. diff --git a/packages/contracts-bedrock/test/Helpers.sol b/packages/contracts-bedrock/test/Helpers.sol deleted file mode 100644 index 13a16e7af9f14..0000000000000 --- a/packages/contracts-bedrock/test/Helpers.sol +++ /dev/null @@ -1,221 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity ^0.8.0; - -import { ERC20 } from "@rari-capital/solmate/src/tokens/ERC20.sol"; -import { ERC721 } from "@rari-capital/solmate/src/tokens/ERC721.sol"; -import { ECDSA } from "@openzeppelin/contracts/utils/cryptography/ECDSA.sol"; -import { OptimistInviter } from "../src/periphery/op-nft/OptimistInviter.sol"; -import { IERC1271 } from "@openzeppelin/contracts/interfaces/IERC1271.sol"; -import { Ownable } from "@openzeppelin/contracts/access/Ownable.sol"; -import { ECDSAUpgradeable } from "@openzeppelin/contracts-upgradeable/utils/cryptography/ECDSAUpgradeable.sol"; -import { AdminFaucetAuthModule } from "../src/periphery/faucet/authmodules/AdminFaucetAuthModule.sol"; - -contract TestERC20 is ERC20 { - constructor() ERC20("TEST", "TST", 18) { } - - function mint(address to, uint256 value) public { - _mint(to, value); - } -} - -contract TestERC721 is ERC721 { - constructor() ERC721("TEST", "TST") { } - - function mint(address to, uint256 tokenId) public { - _mint(to, tokenId); - } - - function tokenURI(uint256) public pure virtual override returns (string memory) { } -} - -contract CallRecorder { - struct CallInfo { - address sender; - bytes data; - uint256 gas; - uint256 value; - } - - CallInfo public lastCall; - - function record() public payable { - lastCall.sender = msg.sender; - lastCall.data = msg.data; - lastCall.gas = gasleft(); - lastCall.value = msg.value; - } -} - -contract Reverter { - function doRevert() public pure { - revert("Reverter reverted"); - } -} - -contract SimpleStorage { - mapping(bytes32 => bytes32) public db; - - function set(bytes32 _key, bytes32 _value) public payable { - db[_key] = _value; - } - - function get(bytes32 _key) public view returns (bytes32) { - return db[_key]; - } -} - -/// @notice Simple helper contract that helps with testing flow and signature for -/// OptimistInviter contract. Made this a separate contract instead of including -/// in OptimistInviter.t.sol for reusability. -contract OptimistInviterHelper { - /// @notice EIP712 typehash for the ClaimableInvite type. - bytes32 public constant CLAIMABLE_INVITE_TYPEHASH = keccak256("ClaimableInvite(address issuer,bytes32 nonce)"); - - /// @notice EIP712 typehash for the EIP712Domain type that is included as part of the signature. - bytes32 public constant EIP712_DOMAIN_TYPEHASH = - keccak256("EIP712Domain(string name,string version,uint256 chainId,address verifyingContract)"); - - /// @notice Address of OptimistInviter contract we are testing. - OptimistInviter public optimistInviter; - - /// @notice OptimistInviter contract name. Used to construct the EIP-712 domain. - string public name; - - /// @notice Keeps track of current nonce to generate new nonces for each invite. - uint256 public currentNonce; - - constructor(OptimistInviter _optimistInviter, string memory _name) { - optimistInviter = _optimistInviter; - name = _name; - } - - /// @notice Returns the hash of the struct ClaimableInvite. - /// @param _claimableInvite ClaimableInvite struct to hash. - /// @return EIP-712 typed struct hash. - function getClaimableInviteStructHash(OptimistInviter.ClaimableInvite memory _claimableInvite) - public - pure - returns (bytes32) - { - return keccak256(abi.encode(CLAIMABLE_INVITE_TYPEHASH, _claimableInvite.issuer, _claimableInvite.nonce)); - } - - /// @notice Returns a bytes32 nonce that should change everytime. In practice, people should use - /// pseudorandom nonces. - /// @return Nonce that should be used as part of ClaimableInvite. - function consumeNonce() public returns (bytes32) { - return bytes32(keccak256(abi.encode(currentNonce++))); - } - - /// @notice Returns a ClaimableInvite with the issuer and current nonce. - /// @param _issuer Issuer to include in the ClaimableInvite. - /// @return ClaimableInvite that can be hashed & signed. - function getClaimableInviteWithNewNonce(address _issuer) public returns (OptimistInviter.ClaimableInvite memory) { - return OptimistInviter.ClaimableInvite(_issuer, consumeNonce()); - } - - /// @notice Computes the EIP712 digest with default correct parameters. - /// @param _claimableInvite ClaimableInvite struct to hash. - /// @return EIP-712 compatible digest. - function getDigest(OptimistInviter.ClaimableInvite calldata _claimableInvite) public view returns (bytes32) { - return getDigestWithEIP712Domain( - _claimableInvite, - bytes(name), - bytes(optimistInviter.EIP712_VERSION()), - block.chainid, - address(optimistInviter) - ); - } - - /// @notice Computes the EIP712 digest with the given domain parameters. - /// Used for testing that different domain parameters fail. - /// @param _claimableInvite ClaimableInvite struct to hash. - /// @param _name Contract name to use in the EIP712 domain. - /// @param _version Contract version to use in the EIP712 domain. - /// @param _chainid Chain ID to use in the EIP712 domain. - /// @param _verifyingContract Address to use in the EIP712 domain. - /// @return EIP-712 compatible digest. - function getDigestWithEIP712Domain( - OptimistInviter.ClaimableInvite calldata _claimableInvite, - bytes memory _name, - bytes memory _version, - uint256 _chainid, - address _verifyingContract - ) - public - pure - returns (bytes32) - { - bytes32 domainSeparator = keccak256( - abi.encode(EIP712_DOMAIN_TYPEHASH, keccak256(_name), keccak256(_version), _chainid, _verifyingContract) - ); - return ECDSA.toTypedDataHash(domainSeparator, getClaimableInviteStructHash(_claimableInvite)); - } -} - -/// @notice Simple ERC1271 wallet that can be used to test the ERC1271 signature checker. -/// @notice https://github.com/OpenZeppelin/openzeppelin-contracts/ -/// blob/master/contracts/mocks/ERC1271WalletMock.sol -contract TestERC1271Wallet is Ownable, IERC1271 { - constructor(address originalOwner) { - transferOwnership(originalOwner); - } - - function isValidSignature(bytes32 hash, bytes memory signature) public view override returns (bytes4 magicValue) { - return ECDSA.recover(hash, signature) == owner() ? this.isValidSignature.selector : bytes4(0); - } -} - -/// @notice Simple helper contract that helps with testing the Faucet contract. -contract FaucetHelper { - /// @notice EIP712 typehash for the Proof type. - bytes32 public constant PROOF_TYPEHASH = keccak256("Proof(address recipient,bytes32 nonce,bytes32 id)"); - - /// @notice EIP712 typehash for the EIP712Domain type that is included as part of the signature. - bytes32 public constant EIP712_DOMAIN_TYPEHASH = - keccak256("EIP712Domain(string name,string version,uint256 chainId,address verifyingContract)"); - - /// @notice Keeps track of current nonce to generate new nonces for each drip. - uint256 public currentNonce; - - /// @notice Returns a bytes32 nonce that should change everytime. In practice, people should use - /// pseudorandom nonces. - /// @return Nonce that should be used as part of drip parameters. - function consumeNonce() public returns (bytes32) { - return bytes32(keccak256(abi.encode(currentNonce++))); - } - - /// @notice Returns the hash of the struct Proof. - /// @param _proof Proof struct to hash. - /// @return EIP-712 typed struct hash. - function getProofStructHash(AdminFaucetAuthModule.Proof memory _proof) public pure returns (bytes32) { - return keccak256(abi.encode(PROOF_TYPEHASH, _proof.recipient, _proof.nonce, _proof.id)); - } - - /// @notice Computes the EIP712 digest with the given domain parameters. - /// Used for testing that different domain parameters fail. - /// @param _proof Proof struct to hash. - /// @param _name Contract name to use in the EIP712 domain. - /// @param _version Contract version to use in the EIP712 domain. - /// @param _chainid Chain ID to use in the EIP712 domain. - /// @param _verifyingContract Address to use in the EIP712 domain. - /// @param _verifyingContract Address to use in the EIP712 domain. - /// @param _verifyingContract Address to use in the EIP712 domain. - /// @return EIP-712 compatible digest. - function getDigestWithEIP712Domain( - AdminFaucetAuthModule.Proof memory _proof, - bytes memory _name, - bytes memory _version, - uint256 _chainid, - address _verifyingContract - ) - public - pure - returns (bytes32) - { - bytes32 domainSeparator = keccak256( - abi.encode(EIP712_DOMAIN_TYPEHASH, keccak256(_name), keccak256(_version), _chainid, _verifyingContract) - ); - return ECDSAUpgradeable.toTypedDataHash(domainSeparator, getProofStructHash(_proof)); - } -} diff --git a/packages/contracts-bedrock/test/Initializable.t.sol b/packages/contracts-bedrock/test/Initializable.t.sol new file mode 100644 index 0000000000000..a9daa7785a038 --- /dev/null +++ b/packages/contracts-bedrock/test/Initializable.t.sol @@ -0,0 +1,60 @@ +// SPDX-License-Identifier: MIT +pragma solidity 0.8.15; + +import { Bridge_Initializer } from "test/setup/Bridge_Initializer.sol"; +import { CrossDomainMessenger } from "src/universal/CrossDomainMessenger.sol"; +import { L2OutputOracle } from "src/L1/L2OutputOracle.sol"; +import { SystemConfig } from "src/L1/SystemConfig.sol"; +import { ResourceMetering } from "src/L1/ResourceMetering.sol"; +import { OptimismPortal } from "src/L1/OptimismPortal.sol"; + +/// @title Initializer_Test +/// @dev Ensures that the `initialize()` function on contracts cannot be called more than +/// once. This contract inherits from `ERC721Bridge_Initializer` because it is the +/// deepest contract in the inheritance chain for setting up the system contracts. +contract Initializer_Test is Bridge_Initializer { + function test_cannotReinitializeL1_succeeds() public { + vm.expectRevert("Initializable: contract is already initialized"); + l1CrossDomainMessenger.initialize(OptimismPortal(payable(address(0)))); + + vm.expectRevert("Initializable: contract is already initialized"); + l1StandardBridge.initialize(CrossDomainMessenger(address(0))); + + vm.expectRevert("Initializable: contract is already initialized"); + l2OutputOracle.initialize(0, 0, address(0), address(0)); + + vm.expectRevert("Initializable: contract is already initialized"); + optimismPortal.initialize(L2OutputOracle(address(0)), address(0), SystemConfig(address(0)), false); + + vm.expectRevert("Initializable: contract is already initialized"); + systemConfig.initialize({ + _owner: address(0xdEaD), + _overhead: 0, + _scalar: 0, + _batcherHash: bytes32(0), + _gasLimit: 1, + _unsafeBlockSigner: address(0), + _config: ResourceMetering.ResourceConfig({ + maxResourceLimit: 1, + elasticityMultiplier: 1, + baseFeeMaxChangeDenominator: 2, + minimumBaseFee: 0, + systemTxMaxGas: 0, + maximumBaseFee: 0 + }), + _startBlock: type(uint256).max, + _batchInbox: address(0), + _addresses: SystemConfig.Addresses({ + l1CrossDomainMessenger: address(0), + l1ERC721Bridge: address(0), + l1StandardBridge: address(0), + l2OutputOracle: address(0), + optimismPortal: address(0), + optimismMintableERC20Factory: address(0) + }) + }); + + vm.expectRevert("Initializable: contract is already initialized"); + l1ERC721Bridge.initialize(CrossDomainMessenger(address(0))); + } +} diff --git a/packages/contracts-bedrock/test/L1Block.t.sol b/packages/contracts-bedrock/test/L1Block.t.sol index 940db84940013..c62a32e446f99 100644 --- a/packages/contracts-bedrock/test/L1Block.t.sol +++ b/packages/contracts-bedrock/test/L1Block.t.sol @@ -2,27 +2,25 @@ pragma solidity 0.8.15; // Testing utilities -import { CommonTest } from "./CommonTest.t.sol"; +import { CommonTest } from "test/setup/CommonTest.sol"; // Target contract -import { L1Block } from "../src/L2/L1Block.sol"; +import { L1Block } from "src/L2/L1Block.sol"; contract L1BlockTest is CommonTest { - L1Block lb; address depositor; - bytes32 immutable NON_ZERO_HASH = keccak256(abi.encode(1)); /// @dev Sets up the test suite. function setUp() public virtual override { super.setUp(); - lb = new L1Block(); - depositor = lb.DEPOSITOR_ACCOUNT(); + + depositor = l1Block.DEPOSITOR_ACCOUNT(); vm.prank(depositor); - lb.setL1BlockValues({ + l1Block.setL1BlockValues({ _number: uint64(1), _timestamp: uint64(2), _basefee: 3, - _hash: NON_ZERO_HASH, + _hash: keccak256(abi.encode(block.number)), _sequenceNumber: uint64(4), _batcherHash: bytes32(0), _l1FeeOverhead: 2, @@ -44,46 +42,46 @@ contract L1BlockTest is CommonTest { external { vm.prank(depositor); - lb.setL1BlockValues(n, t, b, h, s, bt, fo, fs); - assertEq(lb.number(), n); - assertEq(lb.timestamp(), t); - assertEq(lb.basefee(), b); - assertEq(lb.hash(), h); - assertEq(lb.sequenceNumber(), s); - assertEq(lb.batcherHash(), bt); - assertEq(lb.l1FeeOverhead(), fo); - assertEq(lb.l1FeeScalar(), fs); + l1Block.setL1BlockValues(n, t, b, h, s, bt, fo, fs); + assertEq(l1Block.number(), n); + assertEq(l1Block.timestamp(), t); + assertEq(l1Block.basefee(), b); + assertEq(l1Block.hash(), h); + assertEq(l1Block.sequenceNumber(), s); + assertEq(l1Block.batcherHash(), bt); + assertEq(l1Block.l1FeeOverhead(), fo); + assertEq(l1Block.l1FeeScalar(), fs); } /// @dev Tests that `number` returns the correct value. function test_number_succeeds() external { - assertEq(lb.number(), uint64(1)); + assertEq(l1Block.number(), uint64(1)); } /// @dev Tests that `timestamp` returns the correct value. function test_timestamp_succeeds() external { - assertEq(lb.timestamp(), uint64(2)); + assertEq(l1Block.timestamp(), uint64(2)); } /// @dev Tests that `basefee` returns the correct value. function test_basefee_succeeds() external { - assertEq(lb.basefee(), 3); + assertEq(l1Block.basefee(), 3); } /// @dev Tests that `hash` returns the correct value. function test_hash_succeeds() external { - assertEq(lb.hash(), NON_ZERO_HASH); + assertEq(l1Block.hash(), keccak256(abi.encode(block.number))); } /// @dev Tests that `sequenceNumber` returns the correct value. function test_sequenceNumber_succeeds() external { - assertEq(lb.sequenceNumber(), uint64(4)); + assertEq(l1Block.sequenceNumber(), uint64(4)); } /// @dev Tests that `setL1BlockValues` can set max values. function test_updateValues_succeeds() external { vm.prank(depositor); - lb.setL1BlockValues({ + l1Block.setL1BlockValues({ _number: type(uint64).max, _timestamp: type(uint64).max, _basefee: type(uint256).max, diff --git a/packages/contracts-bedrock/test/L1BlockNumber.t.sol b/packages/contracts-bedrock/test/L1BlockNumber.t.sol index b80965feea232..8ac6ab140d6bc 100644 --- a/packages/contracts-bedrock/test/L1BlockNumber.t.sol +++ b/packages/contracts-bedrock/test/L1BlockNumber.t.sol @@ -5,11 +5,11 @@ pragma solidity 0.8.15; import { Test } from "forge-std/Test.sol"; // Target contract dependencies -import { L1Block } from "../src/L2/L1Block.sol"; -import { Predeploys } from "../src/libraries/Predeploys.sol"; +import { L1Block } from "src/L2/L1Block.sol"; +import { Predeploys } from "src/libraries/Predeploys.sol"; // Target contract -import { L1BlockNumber } from "../src/legacy/L1BlockNumber.sol"; +import { L1BlockNumber } from "src/legacy/L1BlockNumber.sol"; contract L1BlockNumberTest is Test { L1Block lb; diff --git a/packages/contracts-bedrock/test/L1CrossDomainMessenger.t.sol b/packages/contracts-bedrock/test/L1CrossDomainMessenger.t.sol index 5090cebb8156b..bf49d25f52241 100644 --- a/packages/contracts-bedrock/test/L1CrossDomainMessenger.t.sol +++ b/packages/contracts-bedrock/test/L1CrossDomainMessenger.t.sol @@ -2,23 +2,19 @@ pragma solidity 0.8.15; // Testing utilities -import { Messenger_Initializer, Reverter, ConfigurableCaller } from "./CommonTest.t.sol"; -import { L2OutputOracle_Initializer } from "./L2OutputOracle.t.sol"; +import { Bridge_Initializer } from "test/setup/Bridge_Initializer.sol"; +import { Reverter, ConfigurableCaller } from "test/mocks/Callers.sol"; // Libraries -import { AddressAliasHelper } from "../src/vendor/AddressAliasHelper.sol"; -import { Predeploys } from "../src/libraries/Predeploys.sol"; -import { Hashing } from "../src/libraries/Hashing.sol"; -import { Encoding } from "../src/libraries/Encoding.sol"; +import { AddressAliasHelper } from "src/vendor/AddressAliasHelper.sol"; +import { Predeploys } from "src/libraries/Predeploys.sol"; +import { Hashing } from "src/libraries/Hashing.sol"; +import { Encoding } from "src/libraries/Encoding.sol"; // Target contract dependencies -import { L2OutputOracle } from "../src/L1/L2OutputOracle.sol"; -import { OptimismPortal } from "../src/L1/OptimismPortal.sol"; +import { OptimismPortal } from "src/L1/OptimismPortal.sol"; -// Target contract -import { L1CrossDomainMessenger } from "../src/L1/L1CrossDomainMessenger.sol"; - -contract L1CrossDomainMessenger_Test is Messenger_Initializer { +contract L1CrossDomainMessenger_Test is Bridge_Initializer { /// @dev The receiver address address recipient = address(0xabbaacdc); @@ -27,8 +23,8 @@ contract L1CrossDomainMessenger_Test is Messenger_Initializer { /// @dev Tests that the version can be decoded from the message nonce. function test_messageVersion_succeeds() external { - (, uint16 version) = Encoding.decodeVersionedNonce(L1Messenger.messageNonce()); - assertEq(version, L1Messenger.MESSAGE_VERSION()); + (, uint16 version) = Encoding.decodeVersionedNonce(l1CrossDomainMessenger.messageNonce()); + assertEq(version, l1CrossDomainMessenger.MESSAGE_VERSION()); } /// @dev Tests that the sendMessage function is able to send a single message. @@ -37,55 +33,57 @@ contract L1CrossDomainMessenger_Test is Messenger_Initializer { function test_sendMessage_succeeds() external { // deposit transaction on the optimism portal should be called vm.expectCall( - address(op), + address(optimismPortal), abi.encodeWithSelector( OptimismPortal.depositTransaction.selector, Predeploys.L2_CROSS_DOMAIN_MESSENGER, 0, - L1Messenger.baseGas(hex"ff", 100), + l1CrossDomainMessenger.baseGas(hex"ff", 100), false, - Encoding.encodeCrossDomainMessage(L1Messenger.messageNonce(), alice, recipient, 0, 100, hex"ff") + Encoding.encodeCrossDomainMessage( + l1CrossDomainMessenger.messageNonce(), alice, recipient, 0, 100, hex"ff" + ) ) ); // TransactionDeposited event vm.expectEmit(true, true, true, true); emitTransactionDeposited( - AddressAliasHelper.applyL1ToL2Alias(address(L1Messenger)), + AddressAliasHelper.applyL1ToL2Alias(address(l1CrossDomainMessenger)), Predeploys.L2_CROSS_DOMAIN_MESSENGER, 0, 0, - L1Messenger.baseGas(hex"ff", 100), + l1CrossDomainMessenger.baseGas(hex"ff", 100), false, - Encoding.encodeCrossDomainMessage(L1Messenger.messageNonce(), alice, recipient, 0, 100, hex"ff") + Encoding.encodeCrossDomainMessage(l1CrossDomainMessenger.messageNonce(), alice, recipient, 0, 100, hex"ff") ); // SentMessage event vm.expectEmit(true, true, true, true); - emit SentMessage(recipient, alice, hex"ff", L1Messenger.messageNonce(), 100); + emit SentMessage(recipient, alice, hex"ff", l1CrossDomainMessenger.messageNonce(), 100); // SentMessageExtension1 event vm.expectEmit(true, true, true, true); emit SentMessageExtension1(alice, 0); vm.prank(alice); - L1Messenger.sendMessage(recipient, hex"ff", uint32(100)); + l1CrossDomainMessenger.sendMessage(recipient, hex"ff", uint32(100)); } /// @dev Tests that the sendMessage function is able to send /// the same message twice. function test_sendMessage_twice_succeeds() external { - uint256 nonce = L1Messenger.messageNonce(); - L1Messenger.sendMessage(recipient, hex"aa", uint32(500_000)); - L1Messenger.sendMessage(recipient, hex"aa", uint32(500_000)); + uint256 nonce = l1CrossDomainMessenger.messageNonce(); + l1CrossDomainMessenger.sendMessage(recipient, hex"aa", uint32(500_000)); + l1CrossDomainMessenger.sendMessage(recipient, hex"aa", uint32(500_000)); // the nonce increments for each message sent - assertEq(nonce + 2, L1Messenger.messageNonce()); + assertEq(nonce + 2, l1CrossDomainMessenger.messageNonce()); } /// @dev Tests that the xDomainMessageSender reverts when not set. function test_xDomainSender_notSet_reverts() external { vm.expectRevert("CrossDomainMessenger: xDomainMessageSender is not set"); - L1Messenger.xDomainMessageSender(); + l1CrossDomainMessenger.xDomainMessageSender(); } /// @dev Tests that the relayMessage function reverts when @@ -95,14 +93,14 @@ contract L1CrossDomainMessenger_Test is Messenger_Initializer { address sender = Predeploys.L2_CROSS_DOMAIN_MESSENGER; // Set the value of op.l2Sender() to be the L2 Cross Domain Messenger. - vm.store(address(op), bytes32(senderSlotIndex), bytes32(abi.encode(sender))); + vm.store(address(optimismPortal), bytes32(senderSlotIndex), bytes32(abi.encode(sender))); // Expect a revert. vm.expectRevert("CrossDomainMessenger: only version 0 or 1 messages are supported at this time"); // Try to relay a v2 message. - vm.prank(address(op)); - L2Messenger.relayMessage( + vm.prank(address(optimismPortal)); + l2CrossDomainMessenger.relayMessage( Encoding.encodeVersionedNonce({ _nonce: 0, _version: 2 }), // nonce sender, target, @@ -121,8 +119,8 @@ contract L1CrossDomainMessenger_Test is Messenger_Initializer { vm.expectCall(target, hex"1111"); // set the value of op.l2Sender() to be the L2 Cross Domain Messenger. - vm.store(address(op), bytes32(senderSlotIndex), bytes32(abi.encode(sender))); - vm.prank(address(op)); + vm.store(address(optimismPortal), bytes32(senderSlotIndex), bytes32(abi.encode(sender))); + vm.prank(address(optimismPortal)); vm.expectEmit(true, true, true, true); @@ -132,7 +130,7 @@ contract L1CrossDomainMessenger_Test is Messenger_Initializer { emit RelayedMessage(hash); - L1Messenger.relayMessage( + l1CrossDomainMessenger.relayMessage( Encoding.encodeVersionedNonce({ _nonce: 0, _version: 1 }), // nonce sender, target, @@ -142,28 +140,28 @@ contract L1CrossDomainMessenger_Test is Messenger_Initializer { ); // the message hash is in the successfulMessages mapping - assert(L1Messenger.successfulMessages(hash)); + assert(l1CrossDomainMessenger.successfulMessages(hash)); // it is not in the received messages mapping - assertEq(L1Messenger.failedMessages(hash), false); + assertEq(l1CrossDomainMessenger.failedMessages(hash), false); } /// @dev Tests that relayMessage reverts if attempting to relay a message /// sent to an L1 system contract. function test_relayMessage_toSystemContract_reverts() external { // set the target to be the OptimismPortal - address target = address(op); + address target = address(optimismPortal); address sender = Predeploys.L2_CROSS_DOMAIN_MESSENGER; bytes memory message = hex"1111"; - vm.prank(address(op)); + vm.prank(address(optimismPortal)); vm.expectRevert("CrossDomainMessenger: message cannot be replayed"); - L1Messenger.relayMessage( + l1CrossDomainMessenger.relayMessage( Encoding.encodeVersionedNonce({ _nonce: 0, _version: 1 }), sender, target, 0, 0, message ); - vm.store(address(op), 0, bytes32(abi.encode(sender))); + vm.store(address(optimismPortal), 0, bytes32(abi.encode(sender))); vm.expectRevert("CrossDomainMessenger: message cannot be replayed"); - L1Messenger.relayMessage( + l1CrossDomainMessenger.relayMessage( Encoding.encodeVersionedNonce({ _nonce: 0, _version: 1 }), sender, target, 0, 0, message ); } @@ -176,7 +174,7 @@ contract L1CrossDomainMessenger_Test is Messenger_Initializer { bytes memory message = hex"1111"; vm.expectRevert("CrossDomainMessenger: value must be zero unless message is from a system address"); - L1Messenger.relayMessage{ value: 100 }( + l1CrossDomainMessenger.relayMessage{ value: 100 }( Encoding.encodeVersionedNonce({ _nonce: 0, _version: 1 }), sender, target, 0, 0, message ); } @@ -185,18 +183,18 @@ contract L1CrossDomainMessenger_Test is Messenger_Initializer { /// after a message is relayed. function test_xDomainMessageSender_reset_succeeds() external { vm.expectRevert("CrossDomainMessenger: xDomainMessageSender is not set"); - L1Messenger.xDomainMessageSender(); + l1CrossDomainMessenger.xDomainMessageSender(); address sender = Predeploys.L2_CROSS_DOMAIN_MESSENGER; - vm.store(address(op), bytes32(senderSlotIndex), bytes32(abi.encode(sender))); - vm.prank(address(op)); - L1Messenger.relayMessage( + vm.store(address(optimismPortal), bytes32(senderSlotIndex), bytes32(abi.encode(sender))); + vm.prank(address(optimismPortal)); + l1CrossDomainMessenger.relayMessage( Encoding.encodeVersionedNonce({ _nonce: 0, _version: 1 }), address(0), address(0), 0, 0, hex"" ); vm.expectRevert("CrossDomainMessenger: xDomainMessageSender is not set"); - L1Messenger.xDomainMessageSender(); + l1CrossDomainMessenger.xDomainMessageSender(); } /// @dev Tests that relayMessage should successfully call the target contract after @@ -213,11 +211,11 @@ contract L1CrossDomainMessenger_Test is Messenger_Initializer { Encoding.encodeVersionedNonce({ _nonce: 0, _version: 1 }), sender, target, value, 0, hex"1111" ); - vm.store(address(op), bytes32(senderSlotIndex), bytes32(abi.encode(sender))); + vm.store(address(optimismPortal), bytes32(senderSlotIndex), bytes32(abi.encode(sender))); vm.etch(target, address(new Reverter()).code); - vm.deal(address(op), value); - vm.prank(address(op)); - L1Messenger.relayMessage{ value: value }( + vm.deal(address(optimismPortal), value); + vm.prank(address(optimismPortal)); + l1CrossDomainMessenger.relayMessage{ value: value }( Encoding.encodeVersionedNonce({ _nonce: 0, _version: 1 }), // nonce sender, target, @@ -226,10 +224,10 @@ contract L1CrossDomainMessenger_Test is Messenger_Initializer { hex"1111" ); - assertEq(address(L1Messenger).balance, value); + assertEq(address(l1CrossDomainMessenger).balance, value); assertEq(address(target).balance, 0); - assertEq(L1Messenger.successfulMessages(hash), false); - assertEq(L1Messenger.failedMessages(hash), true); + assertEq(l1CrossDomainMessenger.successfulMessages(hash), false); + assertEq(l1CrossDomainMessenger.failedMessages(hash), true); vm.expectEmit(true, true, true, true); @@ -237,7 +235,7 @@ contract L1CrossDomainMessenger_Test is Messenger_Initializer { vm.etch(target, address(0).code); vm.prank(address(sender)); - L1Messenger.relayMessage( + l1CrossDomainMessenger.relayMessage( Encoding.encodeVersionedNonce({ _nonce: 0, _version: 1 }), // nonce sender, target, @@ -246,10 +244,10 @@ contract L1CrossDomainMessenger_Test is Messenger_Initializer { hex"1111" ); - assertEq(address(L1Messenger).balance, 0); + assertEq(address(l1CrossDomainMessenger).balance, 0); assertEq(address(target).balance, value); - assertEq(L1Messenger.successfulMessages(hash), true); - assertEq(L1Messenger.failedMessages(hash), true); + assertEq(l1CrossDomainMessenger.successfulMessages(hash), true); + assertEq(l1CrossDomainMessenger.failedMessages(hash), true); } /// @dev Tests that relayMessage should successfully call the target contract after @@ -271,7 +269,7 @@ contract L1CrossDomainMessenger_Test is Messenger_Initializer { ); // Set the value of op.l2Sender() to be the L2 Cross Domain Messenger. - vm.store(address(op), bytes32(senderSlotIndex), bytes32(abi.encode(sender))); + vm.store(address(optimismPortal), bytes32(senderSlotIndex), bytes32(abi.encode(sender))); // Target should be called with expected data. vm.expectCall(target, hex"1111"); @@ -281,8 +279,8 @@ contract L1CrossDomainMessenger_Test is Messenger_Initializer { emit RelayedMessage(hash); // Relay the message. - vm.prank(address(op)); - L1Messenger.relayMessage( + vm.prank(address(optimismPortal)); + l1CrossDomainMessenger.relayMessage( Encoding.encodeVersionedNonce({ _nonce: 0, _version: 0 }), // nonce sender, target, @@ -292,8 +290,8 @@ contract L1CrossDomainMessenger_Test is Messenger_Initializer { ); // Message was successfully relayed. - assertEq(L1Messenger.successfulMessages(hash), true); - assertEq(L1Messenger.failedMessages(hash), false); + assertEq(l1CrossDomainMessenger.successfulMessages(hash), true); + assertEq(l1CrossDomainMessenger.failedMessages(hash), false); } /// @dev Tests that relayMessage should revert if the message is already replayed. @@ -313,20 +311,19 @@ contract L1CrossDomainMessenger_Test is Messenger_Initializer { ); // Set the value of op.l2Sender() to be the L2 Cross Domain Messenger. - vm.store(address(op), bytes32(senderSlotIndex), bytes32(abi.encode(sender))); - + vm.store(address(optimismPortal), bytes32(senderSlotIndex), bytes32(abi.encode(sender))); // Mark legacy message as already relayed. uint256 successfulMessagesSlot = 203; bytes32 oldHash = Hashing.hashCrossDomainMessageV0(target, sender, hex"1111", 0); bytes32 slot = keccak256(abi.encode(oldHash, successfulMessagesSlot)); - vm.store(address(L1Messenger), slot, bytes32(uint256(1))); + vm.store(address(l1CrossDomainMessenger), slot, bytes32(uint256(1))); // Expect revert. vm.expectRevert("CrossDomainMessenger: legacy withdrawal already relayed"); // Relay the message. - vm.prank(address(op)); - L1Messenger.relayMessage( + vm.prank(address(optimismPortal)); + l1CrossDomainMessenger.relayMessage( Encoding.encodeVersionedNonce({ _nonce: 0, _version: 0 }), // nonce sender, target, @@ -336,8 +333,8 @@ contract L1CrossDomainMessenger_Test is Messenger_Initializer { ); // Message was not relayed. - assertEq(L1Messenger.successfulMessages(hash), false); - assertEq(L1Messenger.failedMessages(hash), false); + assertEq(l1CrossDomainMessenger.successfulMessages(hash), false); + assertEq(l1CrossDomainMessenger.failedMessages(hash), false); } /// @dev Tests that relayMessage can be retried after a failure with a legacy message. @@ -358,7 +355,7 @@ contract L1CrossDomainMessenger_Test is Messenger_Initializer { ); // Set the value of op.l2Sender() to be the L2 Cross Domain Messenger. - vm.store(address(op), bytes32(senderSlotIndex), bytes32(abi.encode(sender))); + vm.store(address(optimismPortal), bytes32(senderSlotIndex), bytes32(abi.encode(sender))); // Turn the target into a Reverter. vm.etch(target, address(new Reverter()).code); @@ -371,9 +368,9 @@ contract L1CrossDomainMessenger_Test is Messenger_Initializer { emit FailedRelayedMessage(hash); // Relay the message. - vm.deal(address(op), value); - vm.prank(address(op)); - L1Messenger.relayMessage{ value: value }( + vm.deal(address(optimismPortal), value); + vm.prank(address(optimismPortal)); + l1CrossDomainMessenger.relayMessage{ value: value }( Encoding.encodeVersionedNonce({ _nonce: 0, _version: 0 }), // nonce sender, target, @@ -383,10 +380,10 @@ contract L1CrossDomainMessenger_Test is Messenger_Initializer { ); // Message failed. - assertEq(address(L1Messenger).balance, value); + assertEq(address(l1CrossDomainMessenger).balance, value); assertEq(address(target).balance, 0); - assertEq(L1Messenger.successfulMessages(hash), false); - assertEq(L1Messenger.failedMessages(hash), true); + assertEq(l1CrossDomainMessenger.successfulMessages(hash), false); + assertEq(l1CrossDomainMessenger.failedMessages(hash), true); // Make the target not revert anymore. vm.etch(target, address(0).code); @@ -400,7 +397,7 @@ contract L1CrossDomainMessenger_Test is Messenger_Initializer { // Retry the message. vm.prank(address(sender)); - L1Messenger.relayMessage( + l1CrossDomainMessenger.relayMessage( Encoding.encodeVersionedNonce({ _nonce: 0, _version: 0 }), // nonce sender, target, @@ -410,10 +407,10 @@ contract L1CrossDomainMessenger_Test is Messenger_Initializer { ); // Message was successfully relayed. - assertEq(address(L1Messenger).balance, 0); + assertEq(address(l1CrossDomainMessenger).balance, 0); assertEq(address(target).balance, value); - assertEq(L1Messenger.successfulMessages(hash), true); - assertEq(L1Messenger.failedMessages(hash), true); + assertEq(l1CrossDomainMessenger.successfulMessages(hash), true); + assertEq(l1CrossDomainMessenger.failedMessages(hash), true); } /// @dev Tests that relayMessage cannot be retried after success with a legacy message. @@ -434,7 +431,7 @@ contract L1CrossDomainMessenger_Test is Messenger_Initializer { ); // Set the value of op.l2Sender() to be the L2 Cross Domain Messenger. - vm.store(address(op), bytes32(senderSlotIndex), bytes32(abi.encode(sender))); + vm.store(address(optimismPortal), bytes32(senderSlotIndex), bytes32(abi.encode(sender))); // Target should be called with expected data. vm.expectCall(target, hex"1111"); @@ -444,9 +441,9 @@ contract L1CrossDomainMessenger_Test is Messenger_Initializer { emit RelayedMessage(hash); // Relay the message. - vm.deal(address(op), value); - vm.prank(address(op)); - L1Messenger.relayMessage{ value: value }( + vm.deal(address(optimismPortal), value); + vm.prank(address(optimismPortal)); + l1CrossDomainMessenger.relayMessage{ value: value }( Encoding.encodeVersionedNonce({ _nonce: 0, _version: 0 }), // nonce sender, target, @@ -456,17 +453,17 @@ contract L1CrossDomainMessenger_Test is Messenger_Initializer { ); // Message was successfully relayed. - assertEq(address(L1Messenger).balance, 0); + assertEq(address(l1CrossDomainMessenger).balance, 0); assertEq(address(target).balance, value); - assertEq(L1Messenger.successfulMessages(hash), true); - assertEq(L1Messenger.failedMessages(hash), false); + assertEq(l1CrossDomainMessenger.successfulMessages(hash), true); + assertEq(l1CrossDomainMessenger.failedMessages(hash), false); // Expect a revert. vm.expectRevert("CrossDomainMessenger: message cannot be replayed"); // Retry the message. vm.prank(address(sender)); - L1Messenger.relayMessage( + l1CrossDomainMessenger.relayMessage( Encoding.encodeVersionedNonce({ _nonce: 0, _version: 0 }), // nonce sender, target, @@ -494,7 +491,7 @@ contract L1CrossDomainMessenger_Test is Messenger_Initializer { ); // Set the value of op.l2Sender() to be the L2 Cross Domain Messenger. - vm.store(address(op), bytes32(senderSlotIndex), bytes32(abi.encode(sender))); + vm.store(address(optimismPortal), bytes32(senderSlotIndex), bytes32(abi.encode(sender))); // Turn the target into a Reverter. vm.etch(target, address(new Reverter()).code); @@ -503,9 +500,9 @@ contract L1CrossDomainMessenger_Test is Messenger_Initializer { vm.expectCall(target, hex"1111"); // Relay the message. - vm.deal(address(op), value); - vm.prank(address(op)); - L1Messenger.relayMessage{ value: value }( + vm.deal(address(optimismPortal), value); + vm.prank(address(optimismPortal)); + l1CrossDomainMessenger.relayMessage{ value: value }( Encoding.encodeVersionedNonce({ _nonce: 0, _version: 0 }), // nonce sender, target, @@ -515,10 +512,10 @@ contract L1CrossDomainMessenger_Test is Messenger_Initializer { ); // Message failed. - assertEq(address(L1Messenger).balance, value); + assertEq(address(l1CrossDomainMessenger).balance, value); assertEq(address(target).balance, 0); - assertEq(L1Messenger.successfulMessages(hash), false); - assertEq(L1Messenger.failedMessages(hash), true); + assertEq(l1CrossDomainMessenger.successfulMessages(hash), false); + assertEq(l1CrossDomainMessenger.failedMessages(hash), true); // Make the target not revert anymore. vm.etch(target, address(0).code); @@ -532,7 +529,7 @@ contract L1CrossDomainMessenger_Test is Messenger_Initializer { // Retry the message vm.prank(address(sender)); - L1Messenger.relayMessage( + l1CrossDomainMessenger.relayMessage( Encoding.encodeVersionedNonce({ _nonce: 0, _version: 0 }), // nonce sender, target, @@ -542,17 +539,17 @@ contract L1CrossDomainMessenger_Test is Messenger_Initializer { ); // Message was successfully relayed. - assertEq(address(L1Messenger).balance, 0); + assertEq(address(l1CrossDomainMessenger).balance, 0); assertEq(address(target).balance, value); - assertEq(L1Messenger.successfulMessages(hash), true); - assertEq(L1Messenger.failedMessages(hash), true); + assertEq(l1CrossDomainMessenger.successfulMessages(hash), true); + assertEq(l1CrossDomainMessenger.failedMessages(hash), true); // Expect a revert. vm.expectRevert("CrossDomainMessenger: message has already been relayed"); // Retry the message again. vm.prank(address(sender)); - L1Messenger.relayMessage( + l1CrossDomainMessenger.relayMessage( Encoding.encodeVersionedNonce({ _nonce: 0, _version: 0 }), // nonce sender, target, diff --git a/packages/contracts-bedrock/test/L1ERC721Bridge.t.sol b/packages/contracts-bedrock/test/L1ERC721Bridge.t.sol index 60d0ffe85bdee..db7648dfbbb07 100644 --- a/packages/contracts-bedrock/test/L1ERC721Bridge.t.sol +++ b/packages/contracts-bedrock/test/L1ERC721Bridge.t.sol @@ -2,15 +2,15 @@ pragma solidity 0.8.15; // Testing utilities -import { ERC721Bridge_Initializer } from "./CommonTest.t.sol"; +import { Bridge_Initializer } from "test/setup/Bridge_Initializer.sol"; import { ERC721 } from "@openzeppelin/contracts/token/ERC721/ERC721.sol"; // Target contract dependencies -import { L2ERC721Bridge } from "../src/L2/L2ERC721Bridge.sol"; -import { Predeploys } from "../src/libraries/Predeploys.sol"; +import { L2ERC721Bridge } from "src/L2/L2ERC721Bridge.sol"; +import { Predeploys } from "src/libraries/Predeploys.sol"; // Target contract -import { L1ERC721Bridge } from "../src/L1/L1ERC721Bridge.sol"; +import { L1ERC721Bridge } from "src/L1/L1ERC721Bridge.sol"; /// @dev Test ERC721 contract. contract TestERC721 is ERC721 { @@ -21,7 +21,7 @@ contract TestERC721 is ERC721 { } } -contract L1ERC721Bridge_Test is ERC721Bridge_Initializer { +contract L1ERC721Bridge_Test is Bridge_Initializer { TestERC721 internal localToken; TestERC721 internal remoteToken; uint256 internal constant tokenId = 1; @@ -56,26 +56,26 @@ contract L1ERC721Bridge_Test is ERC721Bridge_Initializer { // Approve the bridge to transfer the token. vm.prank(alice); - localToken.approve(address(L1Bridge), tokenId); + localToken.approve(address(l1ERC721Bridge), tokenId); } /// @dev Tests that the constructor sets the correct values. function test_constructor_succeeds() public { - assertEq(address(L1Bridge.MESSENGER()), address(L1Messenger)); - assertEq(address(L1Bridge.OTHER_BRIDGE()), Predeploys.L2_ERC721_BRIDGE); - assertEq(address(L1Bridge.messenger()), address(L1Messenger)); - assertEq(address(L1Bridge.otherBridge()), Predeploys.L2_ERC721_BRIDGE); + assertEq(address(l1ERC721Bridge.MESSENGER()), address(l1CrossDomainMessenger)); + assertEq(address(l1ERC721Bridge.OTHER_BRIDGE()), Predeploys.L2_ERC721_BRIDGE); + assertEq(address(l1ERC721Bridge.messenger()), address(l1CrossDomainMessenger)); + assertEq(address(l1ERC721Bridge.otherBridge()), Predeploys.L2_ERC721_BRIDGE); } /// @dev Tests that the ERC721 can be bridged successfully. function test_bridgeERC721_succeeds() public { // Expect a call to the messenger. vm.expectCall( - address(L1Messenger), + address(l1CrossDomainMessenger), abi.encodeCall( - L1Messenger.sendMessage, + l1CrossDomainMessenger.sendMessage, ( - address(L2Bridge), + address(l2ERC721Bridge), abi.encodeCall( L2ERC721Bridge.finalizeBridgeERC721, (address(remoteToken), address(localToken), alice, alice, tokenId, hex"5678") @@ -91,11 +91,11 @@ contract L1ERC721Bridge_Test is ERC721Bridge_Initializer { // Bridge the token. vm.prank(alice); - L1Bridge.bridgeERC721(address(localToken), address(remoteToken), tokenId, 1234, hex"5678"); + l1ERC721Bridge.bridgeERC721(address(localToken), address(remoteToken), tokenId, 1234, hex"5678"); // Token is locked in the bridge. - assertEq(L1Bridge.deposits(address(localToken), address(remoteToken), tokenId), true); - assertEq(localToken.ownerOf(tokenId), address(L1Bridge)); + assertEq(l1ERC721Bridge.deposits(address(localToken), address(remoteToken), tokenId), true); + assertEq(localToken.ownerOf(tokenId), address(l1ERC721Bridge)); } /// @dev Tests that the ERC721 bridge reverts for non externally owned accounts. @@ -104,10 +104,10 @@ contract L1ERC721Bridge_Test is ERC721Bridge_Initializer { vm.etch(alice, hex"01"); vm.prank(alice); vm.expectRevert("ERC721Bridge: account is not externally owned"); - L1Bridge.bridgeERC721(address(localToken), address(remoteToken), tokenId, 1234, hex"5678"); + l1ERC721Bridge.bridgeERC721(address(localToken), address(remoteToken), tokenId, 1234, hex"5678"); // Token is not locked in the bridge. - assertEq(L1Bridge.deposits(address(localToken), address(remoteToken), tokenId), false); + assertEq(l1ERC721Bridge.deposits(address(localToken), address(remoteToken), tokenId), false); assertEq(localToken.ownerOf(tokenId), alice); } @@ -116,10 +116,10 @@ contract L1ERC721Bridge_Test is ERC721Bridge_Initializer { // Bridge the token. vm.prank(alice); vm.expectRevert(); - L1Bridge.bridgeERC721(address(0), address(remoteToken), tokenId, 1234, hex"5678"); + l1ERC721Bridge.bridgeERC721(address(0), address(remoteToken), tokenId, 1234, hex"5678"); // Token is not locked in the bridge. - assertEq(L1Bridge.deposits(address(localToken), address(remoteToken), tokenId), false); + assertEq(l1ERC721Bridge.deposits(address(localToken), address(remoteToken), tokenId), false); assertEq(localToken.ownerOf(tokenId), alice); } @@ -128,10 +128,10 @@ contract L1ERC721Bridge_Test is ERC721Bridge_Initializer { // Bridge the token. vm.prank(alice); vm.expectRevert("L1ERC721Bridge: remote token cannot be address(0)"); - L1Bridge.bridgeERC721(address(localToken), address(0), tokenId, 1234, hex"5678"); + l1ERC721Bridge.bridgeERC721(address(localToken), address(0), tokenId, 1234, hex"5678"); // Token is not locked in the bridge. - assertEq(L1Bridge.deposits(address(localToken), address(remoteToken), tokenId), false); + assertEq(l1ERC721Bridge.deposits(address(localToken), address(remoteToken), tokenId), false); assertEq(localToken.ownerOf(tokenId), alice); } @@ -140,10 +140,10 @@ contract L1ERC721Bridge_Test is ERC721Bridge_Initializer { // Bridge the token. vm.prank(bob); vm.expectRevert("ERC721: transfer from incorrect owner"); - L1Bridge.bridgeERC721(address(localToken), address(remoteToken), tokenId, 1234, hex"5678"); + l1ERC721Bridge.bridgeERC721(address(localToken), address(remoteToken), tokenId, 1234, hex"5678"); // Token is not locked in the bridge. - assertEq(L1Bridge.deposits(address(localToken), address(remoteToken), tokenId), false); + assertEq(l1ERC721Bridge.deposits(address(localToken), address(remoteToken), tokenId), false); assertEq(localToken.ownerOf(tokenId), alice); } @@ -152,9 +152,9 @@ contract L1ERC721Bridge_Test is ERC721Bridge_Initializer { function test_bridgeERC721To_succeeds() external { // Expect a call to the messenger. vm.expectCall( - address(L1Messenger), + address(l1CrossDomainMessenger), abi.encodeCall( - L1Messenger.sendMessage, + l1CrossDomainMessenger.sendMessage, ( address(Predeploys.L2_ERC721_BRIDGE), abi.encodeCall( @@ -172,11 +172,11 @@ contract L1ERC721Bridge_Test is ERC721Bridge_Initializer { // Bridge the token. vm.prank(alice); - L1Bridge.bridgeERC721To(address(localToken), address(remoteToken), bob, tokenId, 1234, hex"5678"); + l1ERC721Bridge.bridgeERC721To(address(localToken), address(remoteToken), bob, tokenId, 1234, hex"5678"); // Token is locked in the bridge. - assertEq(L1Bridge.deposits(address(localToken), address(remoteToken), tokenId), true); - assertEq(localToken.ownerOf(tokenId), address(L1Bridge)); + assertEq(l1ERC721Bridge.deposits(address(localToken), address(remoteToken), tokenId), true); + assertEq(localToken.ownerOf(tokenId), address(l1ERC721Bridge)); } /// @dev Tests that the ERC721 bridge reverts for non externally owned accounts @@ -185,10 +185,10 @@ contract L1ERC721Bridge_Test is ERC721Bridge_Initializer { // Bridge the token. vm.prank(alice); vm.expectRevert(); - L1Bridge.bridgeERC721To(address(0), address(remoteToken), bob, tokenId, 1234, hex"5678"); + l1ERC721Bridge.bridgeERC721To(address(0), address(remoteToken), bob, tokenId, 1234, hex"5678"); // Token is not locked in the bridge. - assertEq(L1Bridge.deposits(address(localToken), address(remoteToken), tokenId), false); + assertEq(l1ERC721Bridge.deposits(address(localToken), address(remoteToken), tokenId), false); assertEq(localToken.ownerOf(tokenId), alice); } @@ -198,10 +198,10 @@ contract L1ERC721Bridge_Test is ERC721Bridge_Initializer { // Bridge the token. vm.prank(alice); vm.expectRevert("L1ERC721Bridge: remote token cannot be address(0)"); - L1Bridge.bridgeERC721To(address(localToken), address(0), bob, tokenId, 1234, hex"5678"); + l1ERC721Bridge.bridgeERC721To(address(localToken), address(0), bob, tokenId, 1234, hex"5678"); // Token is not locked in the bridge. - assertEq(L1Bridge.deposits(address(localToken), address(remoteToken), tokenId), false); + assertEq(l1ERC721Bridge.deposits(address(localToken), address(remoteToken), tokenId), false); assertEq(localToken.ownerOf(tokenId), alice); } @@ -211,10 +211,10 @@ contract L1ERC721Bridge_Test is ERC721Bridge_Initializer { // Bridge the token. vm.prank(bob); vm.expectRevert("ERC721: transfer from incorrect owner"); - L1Bridge.bridgeERC721To(address(localToken), address(remoteToken), bob, tokenId, 1234, hex"5678"); + l1ERC721Bridge.bridgeERC721To(address(localToken), address(remoteToken), bob, tokenId, 1234, hex"5678"); // Token is not locked in the bridge. - assertEq(L1Bridge.deposits(address(localToken), address(remoteToken), tokenId), false); + assertEq(l1ERC721Bridge.deposits(address(localToken), address(remoteToken), tokenId), false); assertEq(localToken.ownerOf(tokenId), alice); } @@ -222,7 +222,7 @@ contract L1ERC721Bridge_Test is ERC721Bridge_Initializer { function test_finalizeBridgeERC721_succeeds() external { // Bridge the token. vm.prank(alice); - L1Bridge.bridgeERC721(address(localToken), address(remoteToken), tokenId, 1234, hex"5678"); + l1ERC721Bridge.bridgeERC721(address(localToken), address(remoteToken), tokenId, 1234, hex"5678"); // Expect an event to be emitted. vm.expectEmit(true, true, true, true); @@ -230,15 +230,15 @@ contract L1ERC721Bridge_Test is ERC721Bridge_Initializer { // Finalize a withdrawal. vm.mockCall( - address(L1Messenger), - abi.encodeWithSelector(L1Messenger.xDomainMessageSender.selector), + address(l1CrossDomainMessenger), + abi.encodeWithSelector(l1CrossDomainMessenger.xDomainMessageSender.selector), abi.encode(Predeploys.L2_ERC721_BRIDGE) ); - vm.prank(address(L1Messenger)); - L1Bridge.finalizeBridgeERC721(address(localToken), address(remoteToken), alice, alice, tokenId, hex"5678"); + vm.prank(address(l1CrossDomainMessenger)); + l1ERC721Bridge.finalizeBridgeERC721(address(localToken), address(remoteToken), alice, alice, tokenId, hex"5678"); // Token is not locked in the bridge. - assertEq(L1Bridge.deposits(address(localToken), address(remoteToken), tokenId), false); + assertEq(l1ERC721Bridge.deposits(address(localToken), address(remoteToken), tokenId), false); assertEq(localToken.ownerOf(tokenId), alice); } @@ -248,7 +248,7 @@ contract L1ERC721Bridge_Test is ERC721Bridge_Initializer { // Finalize a withdrawal. vm.prank(alice); vm.expectRevert("ERC721Bridge: function can only be called from the other bridge"); - L1Bridge.finalizeBridgeERC721(address(localToken), address(remoteToken), alice, alice, tokenId, hex"5678"); + l1ERC721Bridge.finalizeBridgeERC721(address(localToken), address(remoteToken), alice, alice, tokenId, hex"5678"); } /// @dev Tests that the ERC721 bridge finalize reverts when not called @@ -256,11 +256,13 @@ contract L1ERC721Bridge_Test is ERC721Bridge_Initializer { function test_finalizeBridgeERC721_notFromRemoteMessenger_reverts() external { // Finalize a withdrawal. vm.mockCall( - address(L1Messenger), abi.encodeWithSelector(L1Messenger.xDomainMessageSender.selector), abi.encode(alice) + address(l1CrossDomainMessenger), + abi.encodeWithSelector(l1CrossDomainMessenger.xDomainMessageSender.selector), + abi.encode(alice) ); - vm.prank(address(L1Messenger)); + vm.prank(address(l1CrossDomainMessenger)); vm.expectRevert("ERC721Bridge: function can only be called from the other bridge"); - L1Bridge.finalizeBridgeERC721(address(localToken), address(remoteToken), alice, alice, tokenId, hex"5678"); + l1ERC721Bridge.finalizeBridgeERC721(address(localToken), address(remoteToken), alice, alice, tokenId, hex"5678"); } /// @dev Tests that the ERC721 bridge finalize reverts when the local token @@ -268,13 +270,15 @@ contract L1ERC721Bridge_Test is ERC721Bridge_Initializer { function test_finalizeBridgeERC721_selfToken_reverts() external { // Finalize a withdrawal. vm.mockCall( - address(L1Messenger), - abi.encodeWithSelector(L1Messenger.xDomainMessageSender.selector), + address(l1CrossDomainMessenger), + abi.encodeWithSelector(l1CrossDomainMessenger.xDomainMessageSender.selector), abi.encode(Predeploys.L2_ERC721_BRIDGE) ); - vm.prank(address(L1Messenger)); + vm.prank(address(l1CrossDomainMessenger)); vm.expectRevert("L1ERC721Bridge: local token cannot be self"); - L1Bridge.finalizeBridgeERC721(address(L1Bridge), address(remoteToken), alice, alice, tokenId, hex"5678"); + l1ERC721Bridge.finalizeBridgeERC721( + address(l1ERC721Bridge), address(remoteToken), alice, alice, tokenId, hex"5678" + ); } /// @dev Tests that the ERC721 bridge finalize reverts when the remote token @@ -282,12 +286,12 @@ contract L1ERC721Bridge_Test is ERC721Bridge_Initializer { function test_finalizeBridgeERC721_notEscrowed_reverts() external { // Finalize a withdrawal. vm.mockCall( - address(L1Messenger), - abi.encodeWithSelector(L1Messenger.xDomainMessageSender.selector), + address(l1CrossDomainMessenger), + abi.encodeWithSelector(l1CrossDomainMessenger.xDomainMessageSender.selector), abi.encode(Predeploys.L2_ERC721_BRIDGE) ); - vm.prank(address(L1Messenger)); + vm.prank(address(l1CrossDomainMessenger)); vm.expectRevert("L1ERC721Bridge: Token ID is not escrowed in the L1 Bridge"); - L1Bridge.finalizeBridgeERC721(address(localToken), address(remoteToken), alice, alice, tokenId, hex"5678"); + l1ERC721Bridge.finalizeBridgeERC721(address(localToken), address(remoteToken), alice, alice, tokenId, hex"5678"); } } diff --git a/packages/contracts-bedrock/test/L1StandardBridge.t.sol b/packages/contracts-bedrock/test/L1StandardBridge.t.sol index 18dc292946d71..8ffc4c0f67145 100644 --- a/packages/contracts-bedrock/test/L1StandardBridge.t.sol +++ b/packages/contracts-bedrock/test/L1StandardBridge.t.sol @@ -4,7 +4,7 @@ pragma solidity 0.8.15; // Testing utilities import { stdStorage, StdStorage } from "forge-std/Test.sol"; import { ERC20 } from "@openzeppelin/contracts/token/ERC20/ERC20.sol"; -import { Bridge_Initializer } from "./CommonTest.t.sol"; +import { Bridge_Initializer } from "test/setup/Bridge_Initializer.sol"; // Libraries import { Predeploys } from "src/libraries/Predeploys.sol"; @@ -22,20 +22,20 @@ import { OptimismPortal } from "src/L1/OptimismPortal.sol"; contract L1StandardBridge_Getter_Test is Bridge_Initializer { /// @dev Test that the accessors return the correct initialized values. function test_getters_succeeds() external view { - assert(L1Bridge.l2TokenBridge() == address(L2Bridge)); - assert(L1Bridge.OTHER_BRIDGE() == L2Bridge); - assert(L1Bridge.messenger() == L1Messenger); - assert(L1Bridge.MESSENGER() == L1Messenger); + assert(l1StandardBridge.l2TokenBridge() == address(l2StandardBridge)); + assert(l1StandardBridge.OTHER_BRIDGE() == l2StandardBridge); + assert(l1StandardBridge.messenger() == l1CrossDomainMessenger); + assert(l1StandardBridge.MESSENGER() == l1CrossDomainMessenger); } } contract L1StandardBridge_Initialize_Test is Bridge_Initializer { /// @dev Test that the initialize function sets the correct values. function test_initialize_succeeds() external { - assertEq(address(L1Bridge.messenger()), address(L1Messenger)); - assertEq(address(L1Bridge.OTHER_BRIDGE()), Predeploys.L2_STANDARD_BRIDGE); - assertEq(address(L2Bridge), Predeploys.L2_STANDARD_BRIDGE); - bytes32 slot0 = vm.load(address(L1Bridge), bytes32(uint256(0))); + assertEq(address(l1StandardBridge.messenger()), address(l1CrossDomainMessenger)); + assertEq(address(l1StandardBridge.OTHER_BRIDGE()), Predeploys.L2_STANDARD_BRIDGE); + assertEq(address(l2StandardBridge), Predeploys.L2_STANDARD_BRIDGE); + bytes32 slot0 = vm.load(address(l1StandardBridge), bytes32(uint256(0))); assertEq(slot0, bytes32(uint256(Constants.INITIALIZER))); } } @@ -45,29 +45,29 @@ contract L1StandardBridge_Initialize_TestFail is Bridge_Initializer { } contract L1StandardBridge_Receive_Test is Bridge_Initializer { /// @dev Tests receive bridges ETH successfully. function test_receive_succeeds() external { - assertEq(address(op).balance, 0); + assertEq(address(optimismPortal).balance, 0); // The legacy event must be emitted for backwards compatibility - vm.expectEmit(true, true, true, true, address(L1Bridge)); + vm.expectEmit(true, true, true, true, address(l1StandardBridge)); emit ETHDepositInitiated(alice, alice, 100, hex""); - vm.expectEmit(true, true, true, true, address(L1Bridge)); + vm.expectEmit(true, true, true, true, address(l1StandardBridge)); emit ETHBridgeInitiated(alice, alice, 100, hex""); vm.expectCall( - address(L1Messenger), + address(l1CrossDomainMessenger), abi.encodeWithSelector( CrossDomainMessenger.sendMessage.selector, - address(L2Bridge), + address(l2StandardBridge), abi.encodeWithSelector(StandardBridge.finalizeBridgeETH.selector, alice, alice, 100, hex""), 200_000 ) ); vm.prank(alice, alice); - (bool success,) = address(L1Bridge).call{ value: 100 }(hex""); + (bool success,) = address(l1StandardBridge).call{ value: 100 }(hex""); assertEq(success, true); - assertEq(address(op).balance, 100); + assertEq(address(optimismPortal).balance, 100); } } @@ -77,59 +77,76 @@ contract PreBridgeETH is Bridge_Initializer { /// @dev Asserts the expected calls and events for bridging ETH depending /// on whether the bridge call is legacy or not. function _preBridgeETH(bool isLegacy) internal { - assertEq(address(op).balance, 0); - uint256 nonce = L1Messenger.messageNonce(); + assertEq(address(optimismPortal).balance, 0); + uint256 nonce = l1CrossDomainMessenger.messageNonce(); uint256 version = 0; // Internal constant in the OptimismPortal: DEPOSIT_VERSION - address l1MessengerAliased = AddressAliasHelper.applyL1ToL2Alias(address(L1Messenger)); + address l1MessengerAliased = AddressAliasHelper.applyL1ToL2Alias(address(l1CrossDomainMessenger)); bytes memory message = abi.encodeWithSelector(StandardBridge.finalizeBridgeETH.selector, alice, alice, 500, hex"dead"); if (isLegacy) { vm.expectCall( - address(L1Bridge), 500, abi.encodeWithSelector(L1Bridge.depositETH.selector, 50000, hex"dead") + address(l1StandardBridge), + 500, + abi.encodeWithSelector(l1StandardBridge.depositETH.selector, 50000, hex"dead") ); } else { - vm.expectCall(address(L1Bridge), 500, abi.encodeWithSelector(L1Bridge.bridgeETH.selector, 50000, hex"dead")); + vm.expectCall( + address(l1StandardBridge), + 500, + abi.encodeWithSelector(l1StandardBridge.bridgeETH.selector, 50000, hex"dead") + ); } vm.expectCall( - address(L1Messenger), + address(l1CrossDomainMessenger), 500, - abi.encodeWithSelector(CrossDomainMessenger.sendMessage.selector, address(L2Bridge), message, 50000) + abi.encodeWithSelector(CrossDomainMessenger.sendMessage.selector, address(l2StandardBridge), message, 50000) ); bytes memory innerMessage = abi.encodeWithSelector( - CrossDomainMessenger.relayMessage.selector, nonce, address(L1Bridge), address(L2Bridge), 500, 50000, message + CrossDomainMessenger.relayMessage.selector, + nonce, + address(l1StandardBridge), + address(l2StandardBridge), + 500, + 50000, + message ); - uint64 baseGas = L1Messenger.baseGas(message, 50000); + uint64 baseGas = l1CrossDomainMessenger.baseGas(message, 50000); vm.expectCall( - address(op), + address(optimismPortal), 500, abi.encodeWithSelector( - OptimismPortal.depositTransaction.selector, address(L2Messenger), 500, baseGas, false, innerMessage + OptimismPortal.depositTransaction.selector, + address(l2CrossDomainMessenger), + 500, + baseGas, + false, + innerMessage ) ); bytes memory opaqueData = abi.encodePacked(uint256(500), uint256(500), baseGas, false, innerMessage); - vm.expectEmit(true, true, true, true, address(L1Bridge)); + vm.expectEmit(true, true, true, true, address(l1StandardBridge)); emit ETHDepositInitiated(alice, alice, 500, hex"dead"); - vm.expectEmit(true, true, true, true, address(L1Bridge)); + vm.expectEmit(true, true, true, true, address(l1StandardBridge)); emit ETHBridgeInitiated(alice, alice, 500, hex"dead"); // OptimismPortal emits a TransactionDeposited event on `depositTransaction` call - vm.expectEmit(true, true, true, true, address(op)); - emit TransactionDeposited(l1MessengerAliased, address(L2Messenger), version, opaqueData); + vm.expectEmit(true, true, true, true, address(optimismPortal)); + emit TransactionDeposited(l1MessengerAliased, address(l2CrossDomainMessenger), version, opaqueData); // SentMessage event emitted by the CrossDomainMessenger - vm.expectEmit(true, true, true, true, address(L1Messenger)); - emit SentMessage(address(L2Bridge), address(L1Bridge), message, nonce, 50000); + vm.expectEmit(true, true, true, true, address(l1CrossDomainMessenger)); + emit SentMessage(address(l2StandardBridge), address(l1StandardBridge), message, nonce, 50000); // SentMessageExtension1 event emitted by the CrossDomainMessenger - vm.expectEmit(true, true, true, true, address(L1Messenger)); - emit SentMessageExtension1(address(L1Bridge), 500); + vm.expectEmit(true, true, true, true, address(l1CrossDomainMessenger)); + emit SentMessageExtension1(address(l1StandardBridge), 500); vm.prank(alice, alice); } @@ -143,8 +160,8 @@ contract L1StandardBridge_DepositETH_Test is PreBridgeETH { /// ETH ends up in the optimismPortal. function test_depositETH_succeeds() external { _preBridgeETH({ isLegacy: true }); - L1Bridge.depositETH{ value: 500 }(50000, hex"dead"); - assertEq(address(op).balance, 500); + l1StandardBridge.depositETH{ value: 500 }(50000, hex"dead"); + assertEq(address(optimismPortal).balance, 500); } } @@ -156,8 +173,8 @@ contract L1StandardBridge_BridgeETH_Test is PreBridgeETH { /// ETH ends up in the optimismPortal. function test_bridgeETH_succeeds() external { _preBridgeETH({ isLegacy: false }); - L1Bridge.bridgeETH{ value: 500 }(50000, hex"dead"); - assertEq(address(op).balance, 500); + l1StandardBridge.bridgeETH{ value: 500 }(50000, hex"dead"); + assertEq(address(optimismPortal).balance, 500); } } @@ -167,7 +184,7 @@ contract L1StandardBridge_DepositETH_TestFail is Bridge_Initializer { vm.etch(alice, address(L1Token).code); vm.expectRevert("StandardBridge: function can only be called from an EOA"); vm.prank(alice); - L1Bridge.depositETH{ value: 1 }(300, hex""); + l1StandardBridge.depositETH{ value: 1 }(300, hex""); } } @@ -175,18 +192,22 @@ contract PreBridgeETHTo is Bridge_Initializer { /// @dev Asserts the expected calls and events for bridging ETH to a different /// address depending on whether the bridge call is legacy or not. function _preBridgeETHTo(bool isLegacy) internal { - assertEq(address(op).balance, 0); - uint256 nonce = L1Messenger.messageNonce(); + assertEq(address(optimismPortal).balance, 0); + uint256 nonce = l1CrossDomainMessenger.messageNonce(); uint256 version = 0; // Internal constant in the OptimismPortal: DEPOSIT_VERSION - address l1MessengerAliased = AddressAliasHelper.applyL1ToL2Alias(address(L1Messenger)); + address l1MessengerAliased = AddressAliasHelper.applyL1ToL2Alias(address(l1CrossDomainMessenger)); if (isLegacy) { vm.expectCall( - address(L1Bridge), 600, abi.encodeWithSelector(L1Bridge.depositETHTo.selector, bob, 60000, hex"dead") + address(l1StandardBridge), + 600, + abi.encodeWithSelector(l1StandardBridge.depositETHTo.selector, bob, 60000, hex"dead") ); } else { vm.expectCall( - address(L1Bridge), 600, abi.encodeWithSelector(L1Bridge.bridgeETHTo.selector, bob, 60000, hex"dead") + address(l1StandardBridge), + 600, + abi.encodeWithSelector(l1StandardBridge.bridgeETHTo.selector, bob, 60000, hex"dead") ); } @@ -196,41 +217,52 @@ contract PreBridgeETHTo is Bridge_Initializer { // the L1 bridge should call // L1CrossDomainMessenger.sendMessage vm.expectCall( - address(L1Messenger), - abi.encodeWithSelector(CrossDomainMessenger.sendMessage.selector, address(L2Bridge), message, 60000) + address(l1CrossDomainMessenger), + abi.encodeWithSelector(CrossDomainMessenger.sendMessage.selector, address(l2StandardBridge), message, 60000) ); bytes memory innerMessage = abi.encodeWithSelector( - CrossDomainMessenger.relayMessage.selector, nonce, address(L1Bridge), address(L2Bridge), 600, 60000, message + CrossDomainMessenger.relayMessage.selector, + nonce, + address(l1StandardBridge), + address(l2StandardBridge), + 600, + 60000, + message ); - uint64 baseGas = L1Messenger.baseGas(message, 60000); + uint64 baseGas = l1CrossDomainMessenger.baseGas(message, 60000); vm.expectCall( - address(op), + address(optimismPortal), abi.encodeWithSelector( - OptimismPortal.depositTransaction.selector, address(L2Messenger), 600, baseGas, false, innerMessage + OptimismPortal.depositTransaction.selector, + address(l2CrossDomainMessenger), + 600, + baseGas, + false, + innerMessage ) ); bytes memory opaqueData = abi.encodePacked(uint256(600), uint256(600), baseGas, false, innerMessage); - vm.expectEmit(true, true, true, true, address(L1Bridge)); + vm.expectEmit(true, true, true, true, address(l1StandardBridge)); emit ETHDepositInitiated(alice, bob, 600, hex"dead"); - vm.expectEmit(true, true, true, true, address(L1Bridge)); + vm.expectEmit(true, true, true, true, address(l1StandardBridge)); emit ETHBridgeInitiated(alice, bob, 600, hex"dead"); // OptimismPortal emits a TransactionDeposited event on `depositTransaction` call - vm.expectEmit(true, true, true, true, address(op)); - emit TransactionDeposited(l1MessengerAliased, address(L2Messenger), version, opaqueData); + vm.expectEmit(true, true, true, true, address(optimismPortal)); + emit TransactionDeposited(l1MessengerAliased, address(l2CrossDomainMessenger), version, opaqueData); // SentMessage event emitted by the CrossDomainMessenger - vm.expectEmit(true, true, true, true, address(L1Messenger)); - emit SentMessage(address(L2Bridge), address(L1Bridge), message, nonce, 60000); + vm.expectEmit(true, true, true, true, address(l1CrossDomainMessenger)); + emit SentMessage(address(l2StandardBridge), address(l1StandardBridge), message, nonce, 60000); // SentMessageExtension1 event emitted by the CrossDomainMessenger - vm.expectEmit(true, true, true, true, address(L1Messenger)); - emit SentMessageExtension1(address(L1Bridge), 600); + vm.expectEmit(true, true, true, true, address(l1CrossDomainMessenger)); + emit SentMessageExtension1(address(l1StandardBridge), 600); // deposit eth to bob vm.prank(alice, alice); @@ -245,8 +277,8 @@ contract L1StandardBridge_DepositETHTo_Test is PreBridgeETHTo { /// ETH ends up in the optimismPortal. function test_depositETHTo_succeeds() external { _preBridgeETHTo({ isLegacy: true }); - L1Bridge.depositETHTo{ value: 600 }(bob, 60000, hex"dead"); - assertEq(address(op).balance, 600); + l1StandardBridge.depositETHTo{ value: 600 }(bob, 60000, hex"dead"); + assertEq(address(optimismPortal).balance, 600); } } @@ -258,8 +290,8 @@ contract L1StandardBridge_BridgeETHTo_Test is PreBridgeETHTo { /// ETH ends up in the optimismPortal. function test_bridgeETHTo_succeeds() external { _preBridgeETHTo({ isLegacy: false }); - L1Bridge.bridgeETHTo{ value: 600 }(bob, 60000, hex"dead"); - assertEq(address(op).balance, 600); + l1StandardBridge.bridgeETHTo{ value: 600 }(bob, 60000, hex"dead"); + assertEq(address(optimismPortal).balance, 600); } } @@ -280,18 +312,18 @@ contract L1StandardBridge_DepositERC20_Test is Bridge_Initializer { /// Calls depositTransaction on the OptimismPortal. /// Only EOA can call depositERC20. function test_depositERC20_succeeds() external { - uint256 nonce = L1Messenger.messageNonce(); + uint256 nonce = l1CrossDomainMessenger.messageNonce(); uint256 version = 0; // Internal constant in the OptimismPortal: DEPOSIT_VERSION - address l1MessengerAliased = AddressAliasHelper.applyL1ToL2Alias(address(L1Messenger)); + address l1MessengerAliased = AddressAliasHelper.applyL1ToL2Alias(address(l1CrossDomainMessenger)); // Deal Alice's ERC20 State deal(address(L1Token), alice, 100000, true); vm.prank(alice); - L1Token.approve(address(L1Bridge), type(uint256).max); + L1Token.approve(address(l1StandardBridge), type(uint256).max); - // The L1Bridge should transfer alice's tokens to itself + // The l1StandardBridge should transfer alice's tokens to itself vm.expectCall( - address(L1Token), abi.encodeWithSelector(ERC20.transferFrom.selector, alice, address(L1Bridge), 100) + address(L1Token), abi.encodeWithSelector(ERC20.transferFrom.selector, alice, address(l1StandardBridge), 100) ); bytes memory message = abi.encodeWithSelector( @@ -300,46 +332,57 @@ contract L1StandardBridge_DepositERC20_Test is Bridge_Initializer { // the L1 bridge should call L1CrossDomainMessenger.sendMessage vm.expectCall( - address(L1Messenger), - abi.encodeWithSelector(CrossDomainMessenger.sendMessage.selector, address(L2Bridge), message, 10000) + address(l1CrossDomainMessenger), + abi.encodeWithSelector(CrossDomainMessenger.sendMessage.selector, address(l2StandardBridge), message, 10000) ); bytes memory innerMessage = abi.encodeWithSelector( - CrossDomainMessenger.relayMessage.selector, nonce, address(L1Bridge), address(L2Bridge), 0, 10000, message + CrossDomainMessenger.relayMessage.selector, + nonce, + address(l1StandardBridge), + address(l2StandardBridge), + 0, + 10000, + message ); - uint64 baseGas = L1Messenger.baseGas(message, 10000); + uint64 baseGas = l1CrossDomainMessenger.baseGas(message, 10000); vm.expectCall( - address(op), + address(optimismPortal), abi.encodeWithSelector( - OptimismPortal.depositTransaction.selector, address(L2Messenger), 0, baseGas, false, innerMessage + OptimismPortal.depositTransaction.selector, + address(l2CrossDomainMessenger), + 0, + baseGas, + false, + innerMessage ) ); bytes memory opaqueData = abi.encodePacked(uint256(0), uint256(0), baseGas, false, innerMessage); // Should emit both the bedrock and legacy events - vm.expectEmit(true, true, true, true, address(L1Bridge)); + vm.expectEmit(true, true, true, true, address(l1StandardBridge)); emit ERC20DepositInitiated(address(L1Token), address(L2Token), alice, alice, 100, hex""); - vm.expectEmit(true, true, true, true, address(L1Bridge)); + vm.expectEmit(true, true, true, true, address(l1StandardBridge)); emit ERC20BridgeInitiated(address(L1Token), address(L2Token), alice, alice, 100, hex""); // OptimismPortal emits a TransactionDeposited event on `depositTransaction` call - vm.expectEmit(true, true, true, true, address(op)); - emit TransactionDeposited(l1MessengerAliased, address(L2Messenger), version, opaqueData); + vm.expectEmit(true, true, true, true, address(optimismPortal)); + emit TransactionDeposited(l1MessengerAliased, address(l2CrossDomainMessenger), version, opaqueData); // SentMessage event emitted by the CrossDomainMessenger - vm.expectEmit(true, true, true, true, address(L1Messenger)); - emit SentMessage(address(L2Bridge), address(L1Bridge), message, nonce, 10000); + vm.expectEmit(true, true, true, true, address(l1CrossDomainMessenger)); + emit SentMessage(address(l2StandardBridge), address(l1StandardBridge), message, nonce, 10000); // SentMessageExtension1 event emitted by the CrossDomainMessenger - vm.expectEmit(true, true, true, true, address(L1Messenger)); - emit SentMessageExtension1(address(L1Bridge), 0); + vm.expectEmit(true, true, true, true, address(l1CrossDomainMessenger)); + emit SentMessageExtension1(address(l1StandardBridge), 0); vm.prank(alice); - L1Bridge.depositERC20(address(L1Token), address(L2Token), 100, 10000, hex""); - assertEq(L1Bridge.deposits(address(L1Token), address(L2Token)), 100); + l1StandardBridge.depositERC20(address(L1Token), address(L2Token), 100, 10000, hex""); + assertEq(l1StandardBridge.deposits(address(L1Token), address(L2Token)), 100); } } @@ -352,7 +395,7 @@ contract L1StandardBridge_DepositERC20_TestFail is Bridge_Initializer { vm.expectRevert("StandardBridge: function can only be called from an EOA"); vm.prank(alice, alice); - L1Bridge.depositERC20(address(0), address(0), 100, 100, hex""); + l1StandardBridge.depositERC20(address(0), address(0), 100, 100, hex""); } } @@ -364,65 +407,77 @@ contract L1StandardBridge_DepositERC20To_Test is Bridge_Initializer { /// Calls depositTransaction on the OptimismPortal. /// Contracts can call depositERC20. function test_depositERC20To_succeeds() external { - uint256 nonce = L1Messenger.messageNonce(); + uint256 nonce = l1CrossDomainMessenger.messageNonce(); uint256 version = 0; // Internal constant in the OptimismPortal: DEPOSIT_VERSION - address l1MessengerAliased = AddressAliasHelper.applyL1ToL2Alias(address(L1Messenger)); + address l1MessengerAliased = AddressAliasHelper.applyL1ToL2Alias(address(l1CrossDomainMessenger)); bytes memory message = abi.encodeWithSelector( StandardBridge.finalizeBridgeERC20.selector, address(L2Token), address(L1Token), alice, bob, 1000, hex"" ); bytes memory innerMessage = abi.encodeWithSelector( - CrossDomainMessenger.relayMessage.selector, nonce, address(L1Bridge), address(L2Bridge), 0, 10000, message + CrossDomainMessenger.relayMessage.selector, + nonce, + address(l1StandardBridge), + address(l2StandardBridge), + 0, + 10000, + message ); - uint64 baseGas = L1Messenger.baseGas(message, 10000); + uint64 baseGas = l1CrossDomainMessenger.baseGas(message, 10000); bytes memory opaqueData = abi.encodePacked(uint256(0), uint256(0), baseGas, false, innerMessage); deal(address(L1Token), alice, 100000, true); vm.prank(alice); - L1Token.approve(address(L1Bridge), type(uint256).max); + L1Token.approve(address(l1StandardBridge), type(uint256).max); // Should emit both the bedrock and legacy events - vm.expectEmit(true, true, true, true, address(L1Bridge)); + vm.expectEmit(true, true, true, true, address(l1StandardBridge)); emit ERC20DepositInitiated(address(L1Token), address(L2Token), alice, bob, 1000, hex""); - vm.expectEmit(true, true, true, true, address(L1Bridge)); + vm.expectEmit(true, true, true, true, address(l1StandardBridge)); emit ERC20BridgeInitiated(address(L1Token), address(L2Token), alice, bob, 1000, hex""); // OptimismPortal emits a TransactionDeposited event on `depositTransaction` call - vm.expectEmit(true, true, true, true, address(op)); - emit TransactionDeposited(l1MessengerAliased, address(L2Messenger), version, opaqueData); + vm.expectEmit(true, true, true, true, address(optimismPortal)); + emit TransactionDeposited(l1MessengerAliased, address(l2CrossDomainMessenger), version, opaqueData); // SentMessage event emitted by the CrossDomainMessenger - vm.expectEmit(true, true, true, true, address(L1Messenger)); - emit SentMessage(address(L2Bridge), address(L1Bridge), message, nonce, 10000); + vm.expectEmit(true, true, true, true, address(l1CrossDomainMessenger)); + emit SentMessage(address(l2StandardBridge), address(l1StandardBridge), message, nonce, 10000); // SentMessageExtension1 event emitted by the CrossDomainMessenger - vm.expectEmit(true, true, true, true, address(L1Messenger)); - emit SentMessageExtension1(address(L1Bridge), 0); + vm.expectEmit(true, true, true, true, address(l1CrossDomainMessenger)); + emit SentMessageExtension1(address(l1StandardBridge), 0); // the L1 bridge should call L1CrossDomainMessenger.sendMessage vm.expectCall( - address(L1Messenger), - abi.encodeWithSelector(CrossDomainMessenger.sendMessage.selector, address(L2Bridge), message, 10000) + address(l1CrossDomainMessenger), + abi.encodeWithSelector(CrossDomainMessenger.sendMessage.selector, address(l2StandardBridge), message, 10000) ); // The L1 XDM should call OptimismPortal.depositTransaction vm.expectCall( - address(op), + address(optimismPortal), abi.encodeWithSelector( - OptimismPortal.depositTransaction.selector, address(L2Messenger), 0, baseGas, false, innerMessage + OptimismPortal.depositTransaction.selector, + address(l2CrossDomainMessenger), + 0, + baseGas, + false, + innerMessage ) ); vm.expectCall( - address(L1Token), abi.encodeWithSelector(ERC20.transferFrom.selector, alice, address(L1Bridge), 1000) + address(L1Token), + abi.encodeWithSelector(ERC20.transferFrom.selector, alice, address(l1StandardBridge), 1000) ); vm.prank(alice); - L1Bridge.depositERC20To(address(L1Token), address(L2Token), bob, 1000, 10000, hex""); + l1StandardBridge.depositERC20To(address(L1Token), address(L2Token), bob, 1000, 10000, hex""); - assertEq(L1Bridge.deposits(address(L1Token), address(L2Token)), 1000); + assertEq(l1StandardBridge.deposits(address(L1Token), address(L2Token)), 1000); } } @@ -435,25 +490,25 @@ contract L1StandardBridge_FinalizeETHWithdrawal_Test is Bridge_Initializer { function test_finalizeETHWithdrawal_succeeds() external { uint256 aliceBalance = alice.balance; - vm.expectEmit(true, true, true, true, address(L1Bridge)); + vm.expectEmit(true, true, true, true, address(l1StandardBridge)); emit ETHWithdrawalFinalized(alice, alice, 100, hex""); - vm.expectEmit(true, true, true, true, address(L1Bridge)); + vm.expectEmit(true, true, true, true, address(l1StandardBridge)); emit ETHBridgeFinalized(alice, alice, 100, hex""); vm.expectCall(alice, hex""); vm.mockCall( - address(L1Bridge.messenger()), + address(l1StandardBridge.messenger()), abi.encodeWithSelector(CrossDomainMessenger.xDomainMessageSender.selector), - abi.encode(address(L1Bridge.OTHER_BRIDGE())) + abi.encode(address(l1StandardBridge.OTHER_BRIDGE())) ); // ensure that the messenger has ETH to call with - vm.deal(address(L1Bridge.messenger()), 100); - vm.prank(address(L1Bridge.messenger())); - L1Bridge.finalizeETHWithdrawal{ value: 100 }(alice, alice, 100, hex""); + vm.deal(address(l1StandardBridge.messenger()), 100); + vm.prank(address(l1StandardBridge.messenger())); + l1StandardBridge.finalizeETHWithdrawal{ value: 100 }(alice, alice, 100, hex""); - assertEq(address(L1Bridge.messenger()).balance, 0); + assertEq(address(l1StandardBridge.messenger()).balance, 0); assertEq(aliceBalance + 100, alice.balance); } } @@ -468,32 +523,33 @@ contract L1StandardBridge_FinalizeERC20Withdrawal_Test is Bridge_Initializer { /// Emits ERC20WithdrawalFinalized event. /// Only callable by the L2 bridge. function test_finalizeERC20Withdrawal_succeeds() external { - deal(address(L1Token), address(L1Bridge), 100, true); + deal(address(L1Token), address(l1StandardBridge), 100, true); - uint256 slot = stdstore.target(address(L1Bridge)).sig("deposits(address,address)").with_key(address(L1Token)) - .with_key(address(L2Token)).find(); + uint256 slot = stdstore.target(address(l1StandardBridge)).sig("deposits(address,address)").with_key( + address(L1Token) + ).with_key(address(L2Token)).find(); // Give the L1 bridge some ERC20 tokens - vm.store(address(L1Bridge), bytes32(slot), bytes32(uint256(100))); - assertEq(L1Bridge.deposits(address(L1Token), address(L2Token)), 100); + vm.store(address(l1StandardBridge), bytes32(slot), bytes32(uint256(100))); + assertEq(l1StandardBridge.deposits(address(L1Token), address(L2Token)), 100); - vm.expectEmit(true, true, true, true, address(L1Bridge)); + vm.expectEmit(true, true, true, true, address(l1StandardBridge)); emit ERC20WithdrawalFinalized(address(L1Token), address(L2Token), alice, alice, 100, hex""); - vm.expectEmit(true, true, true, true, address(L1Bridge)); + vm.expectEmit(true, true, true, true, address(l1StandardBridge)); emit ERC20BridgeFinalized(address(L1Token), address(L2Token), alice, alice, 100, hex""); vm.expectCall(address(L1Token), abi.encodeWithSelector(ERC20.transfer.selector, alice, 100)); vm.mockCall( - address(L1Bridge.messenger()), + address(l1StandardBridge.messenger()), abi.encodeWithSelector(CrossDomainMessenger.xDomainMessageSender.selector), - abi.encode(address(L1Bridge.OTHER_BRIDGE())) + abi.encode(address(l1StandardBridge.OTHER_BRIDGE())) ); - vm.prank(address(L1Bridge.messenger())); - L1Bridge.finalizeERC20Withdrawal(address(L1Token), address(L2Token), alice, alice, 100, hex""); + vm.prank(address(l1StandardBridge.messenger())); + l1StandardBridge.finalizeERC20Withdrawal(address(L1Token), address(L2Token), alice, alice, 100, hex""); - assertEq(L1Token.balanceOf(address(L1Bridge)), 0); + assertEq(L1Token.balanceOf(address(l1StandardBridge)), 0); assertEq(L1Token.balanceOf(address(alice)), 100); } } @@ -502,87 +558,87 @@ contract L1StandardBridge_FinalizeERC20Withdrawal_TestFail is Bridge_Initializer /// @dev Tests that finalizing an ERC20 withdrawal reverts if the caller is not the L2 bridge. function test_finalizeERC20Withdrawal_notMessenger_reverts() external { vm.mockCall( - address(L1Bridge.messenger()), + address(l1StandardBridge.messenger()), abi.encodeWithSelector(CrossDomainMessenger.xDomainMessageSender.selector), - abi.encode(address(L1Bridge.OTHER_BRIDGE())) + abi.encode(address(l1StandardBridge.OTHER_BRIDGE())) ); vm.prank(address(28)); vm.expectRevert("StandardBridge: function can only be called from the other bridge"); - L1Bridge.finalizeERC20Withdrawal(address(L1Token), address(L2Token), alice, alice, 100, hex""); + l1StandardBridge.finalizeERC20Withdrawal(address(L1Token), address(L2Token), alice, alice, 100, hex""); } /// @dev Tests that finalizing an ERC20 withdrawal reverts if the caller is not the L2 bridge. function test_finalizeERC20Withdrawal_notOtherBridge_reverts() external { vm.mockCall( - address(L1Bridge.messenger()), + address(l1StandardBridge.messenger()), abi.encodeWithSelector(CrossDomainMessenger.xDomainMessageSender.selector), abi.encode(address(address(0))) ); - vm.prank(address(L1Bridge.messenger())); + vm.prank(address(l1StandardBridge.messenger())); vm.expectRevert("StandardBridge: function can only be called from the other bridge"); - L1Bridge.finalizeERC20Withdrawal(address(L1Token), address(L2Token), alice, alice, 100, hex""); + l1StandardBridge.finalizeERC20Withdrawal(address(L1Token), address(L2Token), alice, alice, 100, hex""); } } contract L1StandardBridge_FinalizeBridgeETH_Test is Bridge_Initializer { /// @dev Tests that finalizing bridged ETH succeeds. function test_finalizeBridgeETH_succeeds() external { - address messenger = address(L1Bridge.messenger()); + address messenger = address(l1StandardBridge.messenger()); vm.mockCall( messenger, abi.encodeWithSelector(CrossDomainMessenger.xDomainMessageSender.selector), - abi.encode(address(L1Bridge.OTHER_BRIDGE())) + abi.encode(address(l1StandardBridge.OTHER_BRIDGE())) ); vm.deal(messenger, 100); vm.prank(messenger); - vm.expectEmit(true, true, true, true, address(L1Bridge)); + vm.expectEmit(true, true, true, true, address(l1StandardBridge)); emit ETHBridgeFinalized(alice, alice, 100, hex""); - L1Bridge.finalizeBridgeETH{ value: 100 }(alice, alice, 100, hex""); + l1StandardBridge.finalizeBridgeETH{ value: 100 }(alice, alice, 100, hex""); } } contract L1StandardBridge_FinalizeBridgeETH_TestFail is Bridge_Initializer { /// @dev Tests that finalizing bridged ETH reverts if the amount is incorrect. function test_finalizeBridgeETH_incorrectValue_reverts() external { - address messenger = address(L1Bridge.messenger()); + address messenger = address(l1StandardBridge.messenger()); vm.mockCall( messenger, abi.encodeWithSelector(CrossDomainMessenger.xDomainMessageSender.selector), - abi.encode(address(L1Bridge.OTHER_BRIDGE())) + abi.encode(address(l1StandardBridge.OTHER_BRIDGE())) ); vm.deal(messenger, 100); vm.prank(messenger); vm.expectRevert("StandardBridge: amount sent does not match amount required"); - L1Bridge.finalizeBridgeETH{ value: 50 }(alice, alice, 100, hex""); + l1StandardBridge.finalizeBridgeETH{ value: 50 }(alice, alice, 100, hex""); } /// @dev Tests that finalizing bridged ETH reverts if the destination is the L1 bridge. function test_finalizeBridgeETH_sendToSelf_reverts() external { - address messenger = address(L1Bridge.messenger()); + address messenger = address(l1StandardBridge.messenger()); vm.mockCall( messenger, abi.encodeWithSelector(CrossDomainMessenger.xDomainMessageSender.selector), - abi.encode(address(L1Bridge.OTHER_BRIDGE())) + abi.encode(address(l1StandardBridge.OTHER_BRIDGE())) ); vm.deal(messenger, 100); vm.prank(messenger); vm.expectRevert("StandardBridge: cannot send to self"); - L1Bridge.finalizeBridgeETH{ value: 100 }(alice, address(L1Bridge), 100, hex""); + l1StandardBridge.finalizeBridgeETH{ value: 100 }(alice, address(l1StandardBridge), 100, hex""); } /// @dev Tests that finalizing bridged ETH reverts if the destination is the messenger. function test_finalizeBridgeETH_sendToMessenger_reverts() external { - address messenger = address(L1Bridge.messenger()); + address messenger = address(l1StandardBridge.messenger()); vm.mockCall( messenger, abi.encodeWithSelector(CrossDomainMessenger.xDomainMessageSender.selector), - abi.encode(address(L1Bridge.OTHER_BRIDGE())) + abi.encode(address(l1StandardBridge.OTHER_BRIDGE())) ); vm.deal(messenger, 100); vm.prank(messenger); vm.expectRevert("StandardBridge: cannot send to messenger"); - L1Bridge.finalizeBridgeETH{ value: 100 }(alice, messenger, 100, hex""); + l1StandardBridge.finalizeBridgeETH{ value: 100 }(alice, messenger, 100, hex""); } } diff --git a/packages/contracts-bedrock/test/L2CrossDomainMessenger.t.sol b/packages/contracts-bedrock/test/L2CrossDomainMessenger.t.sol index b84d10ff86311..cbd13e5bfb412 100644 --- a/packages/contracts-bedrock/test/L2CrossDomainMessenger.t.sol +++ b/packages/contracts-bedrock/test/L2CrossDomainMessenger.t.sol @@ -2,41 +2,38 @@ pragma solidity 0.8.15; // Testing utilities -import { Messenger_Initializer, Reverter, ConfigurableCaller } from "./CommonTest.t.sol"; +import { Bridge_Initializer } from "test/setup/Bridge_Initializer.sol"; +import { Reverter, ConfigurableCaller } from "test/mocks/Callers.sol"; // Libraries -import { Hashing } from "../src/libraries/Hashing.sol"; -import { Encoding } from "../src/libraries/Encoding.sol"; -import { Types } from "../src/libraries/Types.sol"; +import { Hashing } from "src/libraries/Hashing.sol"; +import { Encoding } from "src/libraries/Encoding.sol"; +import { Types } from "src/libraries/Types.sol"; // Target contract dependencies -import { L2ToL1MessagePasser } from "../src/L2/L2ToL1MessagePasser.sol"; -import { AddressAliasHelper } from "../src/vendor/AddressAliasHelper.sol"; -import { L1CrossDomainMessenger } from "../src/L1/L1CrossDomainMessenger.sol"; +import { L2ToL1MessagePasser } from "src/L2/L2ToL1MessagePasser.sol"; +import { AddressAliasHelper } from "src/vendor/AddressAliasHelper.sol"; -// Target contract -import { L2CrossDomainMessenger } from "../src/L2/L2CrossDomainMessenger.sol"; - -contract L2CrossDomainMessenger_Test is Messenger_Initializer { +contract L2CrossDomainMessenger_Test is Bridge_Initializer { /// @dev Receiver address for testing address recipient = address(0xabbaacdc); /// @dev Tests that `messageNonce` can be decoded correctly. function test_messageVersion_succeeds() external { - (, uint16 version) = Encoding.decodeVersionedNonce(L2Messenger.messageNonce()); - assertEq(version, L2Messenger.MESSAGE_VERSION()); + (, uint16 version) = Encoding.decodeVersionedNonce(l2CrossDomainMessenger.messageNonce()); + assertEq(version, l2CrossDomainMessenger.MESSAGE_VERSION()); } /// @dev Tests that `sendMessage` executes successfully. function test_sendMessage_succeeds() external { bytes memory xDomainCallData = - Encoding.encodeCrossDomainMessage(L2Messenger.messageNonce(), alice, recipient, 0, 100, hex"ff"); + Encoding.encodeCrossDomainMessage(l2CrossDomainMessenger.messageNonce(), alice, recipient, 0, 100, hex"ff"); vm.expectCall( - address(messagePasser), + address(l2ToL1MessagePasser), abi.encodeWithSelector( L2ToL1MessagePasser.initiateWithdrawal.selector, - address(L1Messenger), - L2Messenger.baseGas(hex"ff", 100), + address(l1CrossDomainMessenger), + l2CrossDomainMessenger.baseGas(hex"ff", 100), xDomainCallData ) ); @@ -44,56 +41,56 @@ contract L2CrossDomainMessenger_Test is Messenger_Initializer { // MessagePassed event vm.expectEmit(true, true, true, true); emit MessagePassed( - messagePasser.messageNonce(), - address(L2Messenger), - address(L1Messenger), + l2ToL1MessagePasser.messageNonce(), + address(l2CrossDomainMessenger), + address(l1CrossDomainMessenger), 0, - L2Messenger.baseGas(hex"ff", 100), + l2CrossDomainMessenger.baseGas(hex"ff", 100), xDomainCallData, Hashing.hashWithdrawal( Types.WithdrawalTransaction({ - nonce: messagePasser.messageNonce(), - sender: address(L2Messenger), - target: address(L1Messenger), + nonce: l2ToL1MessagePasser.messageNonce(), + sender: address(l2CrossDomainMessenger), + target: address(l1CrossDomainMessenger), value: 0, - gasLimit: L2Messenger.baseGas(hex"ff", 100), + gasLimit: l2CrossDomainMessenger.baseGas(hex"ff", 100), data: xDomainCallData }) ) ); vm.prank(alice); - L2Messenger.sendMessage(recipient, hex"ff", uint32(100)); + l2CrossDomainMessenger.sendMessage(recipient, hex"ff", uint32(100)); } /// @dev Tests that `sendMessage` can be called twice and that /// the nonce increments correctly. function test_sendMessage_twice_succeeds() external { - uint256 nonce = L2Messenger.messageNonce(); - L2Messenger.sendMessage(recipient, hex"aa", uint32(500_000)); - L2Messenger.sendMessage(recipient, hex"aa", uint32(500_000)); + uint256 nonce = l2CrossDomainMessenger.messageNonce(); + l2CrossDomainMessenger.sendMessage(recipient, hex"aa", uint32(500_000)); + l2CrossDomainMessenger.sendMessage(recipient, hex"aa", uint32(500_000)); // the nonce increments for each message sent - assertEq(nonce + 2, L2Messenger.messageNonce()); + assertEq(nonce + 2, l2CrossDomainMessenger.messageNonce()); } /// @dev Tests that `sendMessage` reverts if the recipient is the zero address. function test_xDomainSender_senderNotSet_reverts() external { vm.expectRevert("CrossDomainMessenger: xDomainMessageSender is not set"); - L2Messenger.xDomainMessageSender(); + l2CrossDomainMessenger.xDomainMessageSender(); } /// @dev Tests that `sendMessage` reverts if the message version is not supported. function test_relayMessage_v2_reverts() external { address target = address(0xabcd); - address sender = address(L1Messenger); - address caller = AddressAliasHelper.applyL1ToL2Alias(address(L1Messenger)); + address sender = address(l1CrossDomainMessenger); + address caller = AddressAliasHelper.applyL1ToL2Alias(address(l1CrossDomainMessenger)); // Expect a revert. vm.expectRevert("CrossDomainMessenger: only version 0 or 1 messages are supported at this time"); // Try to relay a v2 message. vm.prank(caller); - L2Messenger.relayMessage( + l2CrossDomainMessenger.relayMessage( Encoding.encodeVersionedNonce(0, 2), // nonce sender, target, @@ -106,8 +103,8 @@ contract L2CrossDomainMessenger_Test is Messenger_Initializer { /// @dev Tests that `relayMessage` executes successfully. function test_relayMessage_succeeds() external { address target = address(0xabcd); - address sender = address(L1Messenger); - address caller = AddressAliasHelper.applyL1ToL2Alias(address(L1Messenger)); + address sender = address(l1CrossDomainMessenger); + address caller = AddressAliasHelper.applyL1ToL2Alias(address(l1CrossDomainMessenger)); vm.expectCall(target, hex"1111"); @@ -120,7 +117,7 @@ contract L2CrossDomainMessenger_Test is Messenger_Initializer { emit RelayedMessage(hash); - L2Messenger.relayMessage( + l2CrossDomainMessenger.relayMessage( Encoding.encodeVersionedNonce(0, 1), // nonce sender, target, @@ -130,36 +127,36 @@ contract L2CrossDomainMessenger_Test is Messenger_Initializer { ); // the message hash is in the successfulMessages mapping - assert(L2Messenger.successfulMessages(hash)); + assert(l2CrossDomainMessenger.successfulMessages(hash)); // it is not in the received messages mapping - assertEq(L2Messenger.failedMessages(hash), false); + assertEq(l2CrossDomainMessenger.failedMessages(hash), false); } /// @dev Tests that `relayMessage` reverts if attempting to relay /// a message sent to an L1 system contract. function test_relayMessage_toSystemContract_reverts() external { - address target = address(messagePasser); - address sender = address(L1Messenger); - address caller = AddressAliasHelper.applyL1ToL2Alias(address(L1Messenger)); + address target = address(l2ToL1MessagePasser); + address sender = address(l1CrossDomainMessenger); + address caller = AddressAliasHelper.applyL1ToL2Alias(address(l1CrossDomainMessenger)); bytes memory message = hex"1111"; vm.prank(caller); vm.expectRevert("CrossDomainMessenger: message cannot be replayed"); - L1Messenger.relayMessage(Encoding.encodeVersionedNonce(0, 1), sender, target, 0, 0, message); + l1CrossDomainMessenger.relayMessage(Encoding.encodeVersionedNonce(0, 1), sender, target, 0, 0, message); } /// @dev Tests that `relayMessage` correctly resets the `xDomainMessageSender` /// to the original value after a message is relayed. function test_xDomainMessageSender_reset_succeeds() external { vm.expectRevert("CrossDomainMessenger: xDomainMessageSender is not set"); - L2Messenger.xDomainMessageSender(); + l2CrossDomainMessenger.xDomainMessageSender(); - address caller = AddressAliasHelper.applyL1ToL2Alias(address(L1Messenger)); + address caller = AddressAliasHelper.applyL1ToL2Alias(address(l1CrossDomainMessenger)); vm.prank(caller); - L2Messenger.relayMessage(Encoding.encodeVersionedNonce(0, 1), address(0), address(0), 0, 0, hex""); + l2CrossDomainMessenger.relayMessage(Encoding.encodeVersionedNonce(0, 1), address(0), address(0), 0, 0, hex""); vm.expectRevert("CrossDomainMessenger: xDomainMessageSender is not set"); - L2Messenger.xDomainMessageSender(); + l2CrossDomainMessenger.xDomainMessageSender(); } /// @dev Tests that `relayMessage` is able to send a successful call @@ -167,8 +164,8 @@ contract L2CrossDomainMessenger_Test is Messenger_Initializer { /// gets stuck, but the second message succeeds. function test_relayMessage_retry_succeeds() external { address target = address(0xabcd); - address sender = address(L1Messenger); - address caller = AddressAliasHelper.applyL1ToL2Alias(address(L1Messenger)); + address sender = address(l1CrossDomainMessenger); + address caller = AddressAliasHelper.applyL1ToL2Alias(address(l1CrossDomainMessenger)); uint256 value = 100; bytes32 hash = @@ -177,7 +174,7 @@ contract L2CrossDomainMessenger_Test is Messenger_Initializer { vm.etch(target, address(new Reverter()).code); vm.deal(address(caller), value); vm.prank(caller); - L2Messenger.relayMessage{ value: value }( + l2CrossDomainMessenger.relayMessage{ value: value }( Encoding.encodeVersionedNonce(0, 1), // nonce sender, target, @@ -186,10 +183,10 @@ contract L2CrossDomainMessenger_Test is Messenger_Initializer { hex"1111" ); - assertEq(address(L2Messenger).balance, value); + assertEq(address(l2CrossDomainMessenger).balance, value); assertEq(address(target).balance, 0); - assertEq(L2Messenger.successfulMessages(hash), false); - assertEq(L2Messenger.failedMessages(hash), true); + assertEq(l2CrossDomainMessenger.successfulMessages(hash), false); + assertEq(l2CrossDomainMessenger.failedMessages(hash), true); vm.expectEmit(true, true, true, true); @@ -197,7 +194,7 @@ contract L2CrossDomainMessenger_Test is Messenger_Initializer { vm.etch(target, address(0).code); vm.prank(address(sender)); - L2Messenger.relayMessage( + l2CrossDomainMessenger.relayMessage( Encoding.encodeVersionedNonce(0, 1), // nonce sender, target, @@ -206,9 +203,9 @@ contract L2CrossDomainMessenger_Test is Messenger_Initializer { hex"1111" ); - assertEq(address(L2Messenger).balance, 0); + assertEq(address(l2CrossDomainMessenger).balance, 0); assertEq(address(target).balance, value); - assertEq(L2Messenger.successfulMessages(hash), true); - assertEq(L2Messenger.failedMessages(hash), true); + assertEq(l2CrossDomainMessenger.successfulMessages(hash), true); + assertEq(l2CrossDomainMessenger.failedMessages(hash), true); } } diff --git a/packages/contracts-bedrock/test/L2ERC721Bridge.t.sol b/packages/contracts-bedrock/test/L2ERC721Bridge.t.sol index 8c5686403a492..555724a7630f3 100644 --- a/packages/contracts-bedrock/test/L2ERC721Bridge.t.sol +++ b/packages/contracts-bedrock/test/L2ERC721Bridge.t.sol @@ -2,15 +2,15 @@ pragma solidity 0.8.15; // Testing utilities -import { ERC721Bridge_Initializer } from "./CommonTest.t.sol"; +import { Bridge_Initializer } from "test/setup/Bridge_Initializer.sol"; // Target contract dependencies import { ERC721 } from "@openzeppelin/contracts/token/ERC721/ERC721.sol"; -import { L1ERC721Bridge } from "../src/L1/L1ERC721Bridge.sol"; -import { OptimismMintableERC721 } from "../src/universal/OptimismMintableERC721.sol"; +import { L1ERC721Bridge } from "src/L1/L1ERC721Bridge.sol"; +import { OptimismMintableERC721 } from "src/universal/OptimismMintableERC721.sol"; // Target contract -import { L2ERC721Bridge } from "../src/L2/L2ERC721Bridge.sol"; +import { L2ERC721Bridge } from "src/L2/L2ERC721Bridge.sol"; contract TestERC721 is ERC721 { constructor() ERC721("Test", "TST") { } @@ -33,7 +33,7 @@ contract TestMintableERC721 is OptimismMintableERC721 { } } -contract L2ERC721Bridge_Test is ERC721Bridge_Initializer { +contract L2ERC721Bridge_Test is Bridge_Initializer { TestMintableERC721 internal localToken; TestERC721 internal remoteToken; uint256 internal constant tokenId = 1; @@ -61,22 +61,22 @@ contract L2ERC721Bridge_Test is ERC721Bridge_Initializer { super.setUp(); remoteToken = new TestERC721(); - localToken = new TestMintableERC721(address(L2Bridge), address(remoteToken)); + localToken = new TestMintableERC721(address(l2ERC721Bridge), address(remoteToken)); // Mint alice a token. localToken.mint(alice, tokenId); // Approve the bridge to transfer the token. vm.prank(alice); - localToken.approve(address(L2Bridge), tokenId); + localToken.approve(address(l2ERC721Bridge), tokenId); } /// @dev Tests that the constructor sets the correct variables. function test_constructor_succeeds() public { - assertEq(address(L2Bridge.MESSENGER()), address(L2Messenger)); - assertEq(address(L2Bridge.OTHER_BRIDGE()), address(L1Bridge)); - assertEq(address(L2Bridge.messenger()), address(L2Messenger)); - assertEq(address(L2Bridge.otherBridge()), address(L1Bridge)); + assertEq(address(l2ERC721Bridge.MESSENGER()), address(l2CrossDomainMessenger)); + assertEq(address(l2ERC721Bridge.OTHER_BRIDGE()), address(l1ERC721Bridge)); + assertEq(address(l2ERC721Bridge.messenger()), address(l2CrossDomainMessenger)); + assertEq(address(l2ERC721Bridge.otherBridge()), address(l1ERC721Bridge)); } /// @dev Tests that `bridgeERC721` correctly bridges a token and @@ -84,11 +84,11 @@ contract L2ERC721Bridge_Test is ERC721Bridge_Initializer { function test_bridgeERC721_succeeds() public { // Expect a call to the messenger. vm.expectCall( - address(L2Messenger), + address(l2CrossDomainMessenger), abi.encodeCall( - L2Messenger.sendMessage, + l2CrossDomainMessenger.sendMessage, ( - address(L1Bridge), + address(l1ERC721Bridge), abi.encodeCall( L2ERC721Bridge.finalizeBridgeERC721, (address(remoteToken), address(localToken), alice, alice, tokenId, hex"5678") @@ -104,7 +104,7 @@ contract L2ERC721Bridge_Test is ERC721Bridge_Initializer { // Bridge the token. vm.prank(alice); - L2Bridge.bridgeERC721(address(localToken), address(remoteToken), tokenId, 1234, hex"5678"); + l2ERC721Bridge.bridgeERC721(address(localToken), address(remoteToken), tokenId, 1234, hex"5678"); // Token is burned. vm.expectRevert("ERC721: invalid token ID"); @@ -117,7 +117,7 @@ contract L2ERC721Bridge_Test is ERC721Bridge_Initializer { vm.etch(alice, hex"01"); vm.prank(alice); vm.expectRevert("ERC721Bridge: account is not externally owned"); - L2Bridge.bridgeERC721(address(localToken), address(remoteToken), tokenId, 1234, hex"5678"); + l2ERC721Bridge.bridgeERC721(address(localToken), address(remoteToken), tokenId, 1234, hex"5678"); // Token is not locked in the bridge. assertEq(localToken.ownerOf(tokenId), alice); @@ -128,7 +128,7 @@ contract L2ERC721Bridge_Test is ERC721Bridge_Initializer { // Bridge the token. vm.prank(alice); vm.expectRevert(); - L2Bridge.bridgeERC721(address(0), address(remoteToken), tokenId, 1234, hex"5678"); + l2ERC721Bridge.bridgeERC721(address(0), address(remoteToken), tokenId, 1234, hex"5678"); // Token is not locked in the bridge. assertEq(localToken.ownerOf(tokenId), alice); @@ -139,7 +139,7 @@ contract L2ERC721Bridge_Test is ERC721Bridge_Initializer { // Bridge the token. vm.prank(alice); vm.expectRevert("L2ERC721Bridge: remote token cannot be address(0)"); - L2Bridge.bridgeERC721(address(localToken), address(0), tokenId, 1234, hex"5678"); + l2ERC721Bridge.bridgeERC721(address(localToken), address(0), tokenId, 1234, hex"5678"); // Token is not locked in the bridge. assertEq(localToken.ownerOf(tokenId), alice); @@ -150,7 +150,7 @@ contract L2ERC721Bridge_Test is ERC721Bridge_Initializer { // Bridge the token. vm.prank(bob); vm.expectRevert("L2ERC721Bridge: Withdrawal is not being initiated by NFT owner"); - L2Bridge.bridgeERC721(address(localToken), address(remoteToken), tokenId, 1234, hex"5678"); + l2ERC721Bridge.bridgeERC721(address(localToken), address(remoteToken), tokenId, 1234, hex"5678"); // Token is not locked in the bridge. assertEq(localToken.ownerOf(tokenId), alice); @@ -161,11 +161,11 @@ contract L2ERC721Bridge_Test is ERC721Bridge_Initializer { function test_bridgeERC721To_succeeds() external { // Expect a call to the messenger. vm.expectCall( - address(L2Messenger), + address(l2CrossDomainMessenger), abi.encodeCall( - L2Messenger.sendMessage, + l2CrossDomainMessenger.sendMessage, ( - address(L1Bridge), + address(l1ERC721Bridge), abi.encodeCall( L1ERC721Bridge.finalizeBridgeERC721, (address(remoteToken), address(localToken), alice, bob, tokenId, hex"5678") @@ -181,7 +181,7 @@ contract L2ERC721Bridge_Test is ERC721Bridge_Initializer { // Bridge the token. vm.prank(alice); - L2Bridge.bridgeERC721To(address(localToken), address(remoteToken), bob, tokenId, 1234, hex"5678"); + l2ERC721Bridge.bridgeERC721To(address(localToken), address(remoteToken), bob, tokenId, 1234, hex"5678"); // Token is burned. vm.expectRevert("ERC721: invalid token ID"); @@ -193,7 +193,7 @@ contract L2ERC721Bridge_Test is ERC721Bridge_Initializer { // Bridge the token. vm.prank(alice); vm.expectRevert(); - L2Bridge.bridgeERC721To(address(0), address(L1Bridge), bob, tokenId, 1234, hex"5678"); + l2ERC721Bridge.bridgeERC721To(address(0), address(l1ERC721Bridge), bob, tokenId, 1234, hex"5678"); // Token is not locked in the bridge. assertEq(localToken.ownerOf(tokenId), alice); @@ -204,7 +204,7 @@ contract L2ERC721Bridge_Test is ERC721Bridge_Initializer { // Bridge the token. vm.prank(alice); vm.expectRevert("L2ERC721Bridge: remote token cannot be address(0)"); - L2Bridge.bridgeERC721To(address(localToken), address(0), bob, tokenId, 1234, hex"5678"); + l2ERC721Bridge.bridgeERC721To(address(localToken), address(0), bob, tokenId, 1234, hex"5678"); // Token is not locked in the bridge. assertEq(localToken.ownerOf(tokenId), alice); @@ -215,7 +215,7 @@ contract L2ERC721Bridge_Test is ERC721Bridge_Initializer { // Bridge the token. vm.prank(bob); vm.expectRevert("L2ERC721Bridge: Withdrawal is not being initiated by NFT owner"); - L2Bridge.bridgeERC721To(address(localToken), address(remoteToken), bob, tokenId, 1234, hex"5678"); + l2ERC721Bridge.bridgeERC721To(address(localToken), address(remoteToken), bob, tokenId, 1234, hex"5678"); // Token is not locked in the bridge. assertEq(localToken.ownerOf(tokenId), alice); @@ -225,7 +225,7 @@ contract L2ERC721Bridge_Test is ERC721Bridge_Initializer { function test_finalizeBridgeERC721_succeeds() external { // Bridge the token. vm.prank(alice); - L2Bridge.bridgeERC721(address(localToken), address(remoteToken), tokenId, 1234, hex"5678"); + l2ERC721Bridge.bridgeERC721(address(localToken), address(remoteToken), tokenId, 1234, hex"5678"); // Expect an event to be emitted. vm.expectEmit(true, true, true, true); @@ -233,12 +233,12 @@ contract L2ERC721Bridge_Test is ERC721Bridge_Initializer { // Finalize a withdrawal. vm.mockCall( - address(L2Messenger), - abi.encodeWithSelector(L2Messenger.xDomainMessageSender.selector), - abi.encode(L1Bridge) + address(l2CrossDomainMessenger), + abi.encodeWithSelector(l2CrossDomainMessenger.xDomainMessageSender.selector), + abi.encode(l1ERC721Bridge) ); - vm.prank(address(L2Messenger)); - L2Bridge.finalizeBridgeERC721(address(localToken), address(remoteToken), alice, alice, tokenId, hex"5678"); + vm.prank(address(l2CrossDomainMessenger)); + l2ERC721Bridge.finalizeBridgeERC721(address(localToken), address(remoteToken), alice, alice, tokenId, hex"5678"); // Token is not locked in the bridge. assertEq(localToken.ownerOf(tokenId), alice); @@ -252,18 +252,18 @@ contract L2ERC721Bridge_Test is ERC721Bridge_Initializer { // Bridge the non-compliant token. vm.prank(alice); - L2Bridge.bridgeERC721(address(nonCompliantToken), address(0x01), tokenId, 1234, hex"5678"); + l2ERC721Bridge.bridgeERC721(address(nonCompliantToken), address(0x01), tokenId, 1234, hex"5678"); // Attempt to finalize the withdrawal. Should revert because the token does not claim // to be compliant with the `IOptimismMintableERC721` interface. vm.mockCall( - address(L2Messenger), - abi.encodeWithSelector(L2Messenger.xDomainMessageSender.selector), - abi.encode(L1Bridge) + address(l2CrossDomainMessenger), + abi.encodeWithSelector(l2CrossDomainMessenger.xDomainMessageSender.selector), + abi.encode(l1ERC721Bridge) ); - vm.prank(address(L2Messenger)); + vm.prank(address(l2CrossDomainMessenger)); vm.expectRevert("L2ERC721Bridge: local token interface is not compliant"); - L2Bridge.finalizeBridgeERC721( + l2ERC721Bridge.finalizeBridgeERC721( address(address(nonCompliantToken)), address(address(0x01)), alice, alice, tokenId, hex"5678" ); } @@ -273,18 +273,20 @@ contract L2ERC721Bridge_Test is ERC721Bridge_Initializer { // Finalize a withdrawal. vm.prank(alice); vm.expectRevert("ERC721Bridge: function can only be called from the other bridge"); - L2Bridge.finalizeBridgeERC721(address(localToken), address(remoteToken), alice, alice, tokenId, hex"5678"); + l2ERC721Bridge.finalizeBridgeERC721(address(localToken), address(remoteToken), alice, alice, tokenId, hex"5678"); } /// @dev Tests that `finalizeBridgeERC721` reverts when not called by the remote bridge. function test_finalizeBridgeERC721_notFromRemoteMessenger_reverts() external { // Finalize a withdrawal. vm.mockCall( - address(L2Messenger), abi.encodeWithSelector(L2Messenger.xDomainMessageSender.selector), abi.encode(alice) + address(l2CrossDomainMessenger), + abi.encodeWithSelector(l2CrossDomainMessenger.xDomainMessageSender.selector), + abi.encode(alice) ); - vm.prank(address(L2Messenger)); + vm.prank(address(l2CrossDomainMessenger)); vm.expectRevert("ERC721Bridge: function can only be called from the other bridge"); - L2Bridge.finalizeBridgeERC721(address(localToken), address(remoteToken), alice, alice, tokenId, hex"5678"); + l2ERC721Bridge.finalizeBridgeERC721(address(localToken), address(remoteToken), alice, alice, tokenId, hex"5678"); } /// @dev Tests that `finalizeBridgeERC721` reverts when the local token is the @@ -292,26 +294,28 @@ contract L2ERC721Bridge_Test is ERC721Bridge_Initializer { function test_finalizeBridgeERC721_selfToken_reverts() external { // Finalize a withdrawal. vm.mockCall( - address(L2Messenger), - abi.encodeWithSelector(L2Messenger.xDomainMessageSender.selector), - abi.encode(address(L1Bridge)) + address(l2CrossDomainMessenger), + abi.encodeWithSelector(l2CrossDomainMessenger.xDomainMessageSender.selector), + abi.encode(address(l1ERC721Bridge)) ); - vm.prank(address(L2Messenger)); + vm.prank(address(l2CrossDomainMessenger)); vm.expectRevert("L2ERC721Bridge: local token cannot be self"); - L2Bridge.finalizeBridgeERC721(address(L2Bridge), address(remoteToken), alice, alice, tokenId, hex"5678"); + l2ERC721Bridge.finalizeBridgeERC721( + address(l2ERC721Bridge), address(remoteToken), alice, alice, tokenId, hex"5678" + ); } /// @dev Tests that `finalizeBridgeERC721` reverts when already finalized. function test_finalizeBridgeERC721_alreadyExists_reverts() external { // Finalize a withdrawal. vm.mockCall( - address(L2Messenger), - abi.encodeWithSelector(L2Messenger.xDomainMessageSender.selector), - abi.encode(address(L1Bridge)) + address(l2CrossDomainMessenger), + abi.encodeWithSelector(l2CrossDomainMessenger.xDomainMessageSender.selector), + abi.encode(address(l1ERC721Bridge)) ); - vm.prank(address(L2Messenger)); + vm.prank(address(l2CrossDomainMessenger)); vm.expectRevert("ERC721: token already minted"); - L2Bridge.finalizeBridgeERC721(address(localToken), address(remoteToken), alice, alice, tokenId, hex"5678"); + l2ERC721Bridge.finalizeBridgeERC721(address(localToken), address(remoteToken), alice, alice, tokenId, hex"5678"); } } diff --git a/packages/contracts-bedrock/test/L2OutputOracle.t.sol b/packages/contracts-bedrock/test/L2OutputOracle.t.sol index f6c521f11ce65..ad523d5bbd3ff 100644 --- a/packages/contracts-bedrock/test/L2OutputOracle.t.sol +++ b/packages/contracts-bedrock/test/L2OutputOracle.t.sol @@ -3,7 +3,9 @@ pragma solidity 0.8.15; // Testing utilities import { stdError } from "forge-std/Test.sol"; -import { L2OutputOracle_Initializer, NextImpl } from "./CommonTest.t.sol"; +import { CommonTest } from "test/setup/CommonTest.sol"; +import { NextImpl } from "test/mocks/NextImpl.sol"; +import { EIP1967Helper } from "test/mocks/EIP1967Helper.sol"; // Libraries import { Types } from "src/libraries/Types.sol"; @@ -15,26 +17,35 @@ import { Proxy } from "src/universal/Proxy.sol"; // Target contract import { L2OutputOracle } from "src/L1/L2OutputOracle.sol"; -contract L2OutputOracle_constructor_Test is L2OutputOracle_Initializer { +contract L2OutputOracle_constructor_Test is CommonTest { /// @dev Tests that constructor sets the initial values correctly. function test_constructor_succeeds() external { - assertEq(oracle.PROPOSER(), proposer); - assertEq(oracle.proposer(), proposer); - assertEq(oracle.CHALLENGER(), owner); - assertEq(oracle.challenger(), owner); - assertEq(oracle.SUBMISSION_INTERVAL(), submissionInterval); - assertEq(oracle.submissionInterval(), submissionInterval); - assertEq(oracle.latestBlockNumber(), startingBlockNumber); - assertEq(oracle.startingBlockNumber(), startingBlockNumber); - assertEq(oracle.startingTimestamp(), startingTimestamp); - assertEq(oracle.L2_BLOCK_TIME(), l2BlockTime); - assertEq(oracle.l2BlockTime(), l2BlockTime); - assertEq(oracle.finalizationPeriodSeconds(), finalizationPeriodSeconds); - assertEq(oracle.FINALIZATION_PERIOD_SECONDS(), finalizationPeriodSeconds); + address proposer = cfg.l2OutputOracleProposer(); + address challenger = cfg.l2OutputOracleChallenger(); + uint256 submissionInterval = cfg.l2OutputOracleSubmissionInterval(); + uint256 startingBlockNumber = cfg.l2OutputOracleStartingBlockNumber(); + uint256 startingTimestamp = cfg.l2OutputOracleStartingTimestamp(); + uint256 l2BlockTime = cfg.l2BlockTime(); + uint256 finalizationPeriodSeconds = cfg.finalizationPeriodSeconds(); + + assertEq(l2OutputOracle.PROPOSER(), proposer); + assertEq(l2OutputOracle.proposer(), proposer); + assertEq(l2OutputOracle.CHALLENGER(), challenger); + assertEq(l2OutputOracle.challenger(), challenger); + assertEq(l2OutputOracle.SUBMISSION_INTERVAL(), submissionInterval); + assertEq(l2OutputOracle.submissionInterval(), submissionInterval); + assertEq(l2OutputOracle.latestBlockNumber(), startingBlockNumber); + assertEq(l2OutputOracle.startingBlockNumber(), startingBlockNumber); + assertEq(l2OutputOracle.startingTimestamp(), startingTimestamp); + assertEq(l2OutputOracle.L2_BLOCK_TIME(), l2BlockTime); + assertEq(l2OutputOracle.l2BlockTime(), l2BlockTime); + assertEq(l2OutputOracle.finalizationPeriodSeconds(), finalizationPeriodSeconds); + assertEq(l2OutputOracle.FINALIZATION_PERIOD_SECONDS(), finalizationPeriodSeconds); } /// @dev Tests that the constructor reverts if the l2BlockTime is invalid. function test_constructor_l2BlockTimeZero_reverts() external { + uint256 submissionInterval = cfg.l2OutputOracleSubmissionInterval(); vm.expectRevert("L2OutputOracle: L2 block time must be greater than 0"); new L2OutputOracle({ _submissionInterval: submissionInterval, @@ -45,6 +56,7 @@ contract L2OutputOracle_constructor_Test is L2OutputOracle_Initializer { /// @dev Tests that the constructor reverts if the submissionInterval is zero. function test_constructor_submissionInterval_reverts() external { + uint256 l2BlockTime = cfg.l2BlockTime(); vm.expectRevert("L2OutputOracle: submission interval must be greater than 0"); new L2OutputOracle({ _submissionInterval: 0, @@ -57,9 +69,9 @@ contract L2OutputOracle_constructor_Test is L2OutputOracle_Initializer { function test_initialize_badTimestamp_reverts() external { // Reset the initialized field in the 0th storage slot // so that initialize can be called again. - vm.store(address(oracle), bytes32(uint256(0)), bytes32(uint256(0))); + vm.store(address(l2OutputOracle), bytes32(uint256(0)), bytes32(uint256(0))); vm.expectRevert("L2OutputOracle: starting L2 timestamp must be less than current time"); - oracle.initialize({ + l2OutputOracle.initialize({ _startingBlockNumber: 0, _startingTimestamp: block.timestamp + 1, _proposer: address(0), @@ -68,48 +80,48 @@ contract L2OutputOracle_constructor_Test is L2OutputOracle_Initializer { } } -contract L2OutputOracle_getter_Test is L2OutputOracle_Initializer { +contract L2OutputOracle_getter_Test is CommonTest { bytes32 proposedOutput1 = keccak256(abi.encode(1)); /// @dev Tests that `latestBlockNumber` returns the correct value. function test_latestBlockNumber_succeeds() external { - uint256 proposedNumber = oracle.nextBlockNumber(); + uint256 proposedNumber = l2OutputOracle.nextBlockNumber(); // Roll to after the block number we'll propose warpToProposeTime(proposedNumber); - vm.prank(proposer); - oracle.proposeL2Output(proposedOutput1, proposedNumber, 0, 0); - assertEq(oracle.latestBlockNumber(), proposedNumber); + vm.prank(cfg.l2OutputOracleProposer()); + l2OutputOracle.proposeL2Output(proposedOutput1, proposedNumber, 0, 0); + assertEq(l2OutputOracle.latestBlockNumber(), proposedNumber); } /// @dev Tests that `getL2Output` returns the correct value. function test_getL2Output_succeeds() external { - uint256 nextBlockNumber = oracle.nextBlockNumber(); - uint256 nextOutputIndex = oracle.nextOutputIndex(); + uint256 nextBlockNumber = l2OutputOracle.nextBlockNumber(); + uint256 nextOutputIndex = l2OutputOracle.nextOutputIndex(); warpToProposeTime(nextBlockNumber); - vm.prank(proposer); - oracle.proposeL2Output(proposedOutput1, nextBlockNumber, 0, 0); + vm.prank(cfg.l2OutputOracleProposer()); + l2OutputOracle.proposeL2Output(proposedOutput1, nextBlockNumber, 0, 0); - Types.OutputProposal memory proposal = oracle.getL2Output(nextOutputIndex); + Types.OutputProposal memory proposal = l2OutputOracle.getL2Output(nextOutputIndex); assertEq(proposal.outputRoot, proposedOutput1); assertEq(proposal.timestamp, block.timestamp); // The block number is larger than the latest proposed output: vm.expectRevert(stdError.indexOOBError); - oracle.getL2Output(nextOutputIndex + 1); + l2OutputOracle.getL2Output(nextOutputIndex + 1); } /// @dev Tests that `getL2OutputIndexAfter` returns the correct value /// when the input is the exact block number of the proposal. function test_getL2OutputIndexAfter_sameBlock_succeeds() external { bytes32 output1 = keccak256(abi.encode(1)); - uint256 nextBlockNumber1 = oracle.nextBlockNumber(); + uint256 nextBlockNumber1 = l2OutputOracle.nextBlockNumber(); warpToProposeTime(nextBlockNumber1); - vm.prank(proposer); - oracle.proposeL2Output(output1, nextBlockNumber1, 0, 0); + vm.prank(cfg.l2OutputOracleProposer()); + l2OutputOracle.proposeL2Output(output1, nextBlockNumber1, 0, 0); // Querying with exact same block as proposed returns the proposal. - uint256 index1 = oracle.getL2OutputIndexAfter(nextBlockNumber1); + uint256 index1 = l2OutputOracle.getL2OutputIndexAfter(nextBlockNumber1); assertEq(index1, 0); } @@ -117,88 +129,94 @@ contract L2OutputOracle_getter_Test is L2OutputOracle_Initializer { /// when the input is the previous block number of the proposal. function test_getL2OutputIndexAfter_previousBlock_succeeds() external { bytes32 output1 = keccak256(abi.encode(1)); - uint256 nextBlockNumber1 = oracle.nextBlockNumber(); + uint256 nextBlockNumber1 = l2OutputOracle.nextBlockNumber(); warpToProposeTime(nextBlockNumber1); - vm.prank(proposer); - oracle.proposeL2Output(output1, nextBlockNumber1, 0, 0); + vm.prank(cfg.l2OutputOracleProposer()); + l2OutputOracle.proposeL2Output(output1, nextBlockNumber1, 0, 0); // Querying with previous block returns the proposal too. - uint256 index1 = oracle.getL2OutputIndexAfter(nextBlockNumber1 - 1); + uint256 index1 = l2OutputOracle.getL2OutputIndexAfter(nextBlockNumber1 - 1); assertEq(index1, 0); } /// @dev Tests that `getL2OutputIndexAfter` returns the correct value. function test_getL2OutputIndexAfter_multipleOutputsExist_succeeds() external { bytes32 output1 = keccak256(abi.encode(1)); - uint256 nextBlockNumber1 = oracle.nextBlockNumber(); + uint256 nextBlockNumber1 = l2OutputOracle.nextBlockNumber(); warpToProposeTime(nextBlockNumber1); - vm.prank(proposer); - oracle.proposeL2Output(output1, nextBlockNumber1, 0, 0); + vm.prank(cfg.l2OutputOracleProposer()); + l2OutputOracle.proposeL2Output(output1, nextBlockNumber1, 0, 0); bytes32 output2 = keccak256(abi.encode(2)); - uint256 nextBlockNumber2 = oracle.nextBlockNumber(); + uint256 nextBlockNumber2 = l2OutputOracle.nextBlockNumber(); warpToProposeTime(nextBlockNumber2); - vm.prank(proposer); - oracle.proposeL2Output(output2, nextBlockNumber2, 0, 0); + vm.prank(cfg.l2OutputOracleProposer()); + l2OutputOracle.proposeL2Output(output2, nextBlockNumber2, 0, 0); bytes32 output3 = keccak256(abi.encode(3)); - uint256 nextBlockNumber3 = oracle.nextBlockNumber(); + uint256 nextBlockNumber3 = l2OutputOracle.nextBlockNumber(); warpToProposeTime(nextBlockNumber3); - vm.prank(proposer); - oracle.proposeL2Output(output3, nextBlockNumber3, 0, 0); + vm.prank(cfg.l2OutputOracleProposer()); + l2OutputOracle.proposeL2Output(output3, nextBlockNumber3, 0, 0); bytes32 output4 = keccak256(abi.encode(4)); - uint256 nextBlockNumber4 = oracle.nextBlockNumber(); + uint256 nextBlockNumber4 = l2OutputOracle.nextBlockNumber(); warpToProposeTime(nextBlockNumber4); - vm.prank(proposer); - oracle.proposeL2Output(output4, nextBlockNumber4, 0, 0); + vm.prank(cfg.l2OutputOracleProposer()); + l2OutputOracle.proposeL2Output(output4, nextBlockNumber4, 0, 0); // Querying with a block number between the first and second proposal - uint256 index1 = oracle.getL2OutputIndexAfter(nextBlockNumber1 + 1); + uint256 index1 = l2OutputOracle.getL2OutputIndexAfter(nextBlockNumber1 + 1); assertEq(index1, 1); // Querying with a block number between the second and third proposal - uint256 index2 = oracle.getL2OutputIndexAfter(nextBlockNumber2 + 1); + uint256 index2 = l2OutputOracle.getL2OutputIndexAfter(nextBlockNumber2 + 1); assertEq(index2, 2); // Querying with a block number between the third and fourth proposal - uint256 index3 = oracle.getL2OutputIndexAfter(nextBlockNumber3 + 1); + uint256 index3 = l2OutputOracle.getL2OutputIndexAfter(nextBlockNumber3 + 1); assertEq(index3, 3); } /// @dev Tests that `getL2OutputIndexAfter` reverts when no output exists. function test_getL2OutputIndexAfter_noOutputsExis_reverts() external { vm.expectRevert("L2OutputOracle: cannot get output as no outputs have been proposed yet"); - oracle.getL2OutputIndexAfter(0); + l2OutputOracle.getL2OutputIndexAfter(0); } /// @dev Tests that `nextBlockNumber` returns the correct value. function test_nextBlockNumber_succeeds() external { assertEq( - oracle.nextBlockNumber(), + l2OutputOracle.nextBlockNumber(), // The return value should match this arithmetic - oracle.latestBlockNumber() + oracle.SUBMISSION_INTERVAL() + l2OutputOracle.latestBlockNumber() + l2OutputOracle.SUBMISSION_INTERVAL() ); } /// @dev Tests that `computeL2Timestamp` returns the correct value. function test_computeL2Timestamp_succeeds() external { + uint256 startingBlockNumber = cfg.l2OutputOracleStartingBlockNumber(); + uint256 startingTimestamp = cfg.l2OutputOracleStartingTimestamp(); + uint256 l2BlockTime = cfg.l2BlockTime(); + // reverts if timestamp is too low vm.expectRevert(stdError.arithmeticError); - oracle.computeL2Timestamp(startingBlockNumber - 1); + l2OutputOracle.computeL2Timestamp(startingBlockNumber - 1); // check timestamp for the very first block - assertEq(oracle.computeL2Timestamp(startingBlockNumber), startingTimestamp); + assertEq(l2OutputOracle.computeL2Timestamp(startingBlockNumber), startingTimestamp); // check timestamp for the first block after the starting block - assertEq(oracle.computeL2Timestamp(startingBlockNumber + 1), startingTimestamp + l2BlockTime); + assertEq(l2OutputOracle.computeL2Timestamp(startingBlockNumber + 1), startingTimestamp + l2BlockTime); // check timestamp for some other block number - assertEq(oracle.computeL2Timestamp(startingBlockNumber + 96024), startingTimestamp + l2BlockTime * 96024); + assertEq( + l2OutputOracle.computeL2Timestamp(startingBlockNumber + 96024), startingTimestamp + l2BlockTime * 96024 + ); } } -contract L2OutputOracle_proposeL2Output_Test is L2OutputOracle_Initializer { +contract L2OutputOracle_proposeL2Output_Test is CommonTest { /// @dev Test that `proposeL2Output` succeeds for a valid input /// and when a block hash and number are not specified. function test_proposeL2Output_proposeAnotherOutput_succeeds() public { @@ -212,62 +230,62 @@ contract L2OutputOracle_proposeL2Output_Test is L2OutputOracle_Initializer { uint256 prevL1BlockNumber = block.number - 1; bytes32 prevL1BlockHash = blockhash(prevL1BlockNumber); - uint256 nextBlockNumber = oracle.nextBlockNumber(); + uint256 nextBlockNumber = l2OutputOracle.nextBlockNumber(); warpToProposeTime(nextBlockNumber); - vm.prank(proposer); - oracle.proposeL2Output(nonZeroHash, nextBlockNumber, prevL1BlockHash, prevL1BlockNumber); + vm.prank(cfg.l2OutputOracleProposer()); + l2OutputOracle.proposeL2Output(nonZeroHash, nextBlockNumber, prevL1BlockHash, prevL1BlockNumber); } /// @dev Tests that `proposeL2Output` reverts when called by a party /// that is not the proposer. function test_proposeL2Output_notProposer_reverts() external { - uint256 nextBlockNumber = oracle.nextBlockNumber(); + uint256 nextBlockNumber = l2OutputOracle.nextBlockNumber(); warpToProposeTime(nextBlockNumber); vm.prank(address(128)); vm.expectRevert("L2OutputOracle: only the proposer address can propose new outputs"); - oracle.proposeL2Output(nonZeroHash, nextBlockNumber, 0, 0); + l2OutputOracle.proposeL2Output(nonZeroHash, nextBlockNumber, 0, 0); } /// @dev Tests that `proposeL2Output` reverts when given a zero blockhash. function test_proposeL2Output_emptyOutput_reverts() external { bytes32 outputToPropose = bytes32(0); - uint256 nextBlockNumber = oracle.nextBlockNumber(); + uint256 nextBlockNumber = l2OutputOracle.nextBlockNumber(); warpToProposeTime(nextBlockNumber); - vm.prank(proposer); + vm.prank(cfg.l2OutputOracleProposer()); vm.expectRevert("L2OutputOracle: L2 output proposal cannot be the zero hash"); - oracle.proposeL2Output(outputToPropose, nextBlockNumber, 0, 0); + l2OutputOracle.proposeL2Output(outputToPropose, nextBlockNumber, 0, 0); } /// @dev Tests that `proposeL2Output` reverts when given a block number /// that does not match the next expected block number. function test_proposeL2Output_unexpectedBlockNumber_reverts() external { - uint256 nextBlockNumber = oracle.nextBlockNumber(); + uint256 nextBlockNumber = l2OutputOracle.nextBlockNumber(); warpToProposeTime(nextBlockNumber); - vm.prank(proposer); + vm.prank(cfg.l2OutputOracleProposer()); vm.expectRevert("L2OutputOracle: block number must be equal to next expected block number"); - oracle.proposeL2Output(nonZeroHash, nextBlockNumber - 1, 0, 0); + l2OutputOracle.proposeL2Output(nonZeroHash, nextBlockNumber - 1, 0, 0); } /// @dev Tests that `proposeL2Output` reverts when given a block number /// that has a timestamp in the future. function test_proposeL2Output_futureTimetamp_reverts() external { - uint256 nextBlockNumber = oracle.nextBlockNumber(); - uint256 nextTimestamp = oracle.computeL2Timestamp(nextBlockNumber); + uint256 nextBlockNumber = l2OutputOracle.nextBlockNumber(); + uint256 nextTimestamp = l2OutputOracle.computeL2Timestamp(nextBlockNumber); vm.warp(nextTimestamp); - vm.prank(proposer); + vm.prank(cfg.l2OutputOracleProposer()); vm.expectRevert("L2OutputOracle: cannot propose L2 output in the future"); - oracle.proposeL2Output(nonZeroHash, nextBlockNumber, 0, 0); + l2OutputOracle.proposeL2Output(nonZeroHash, nextBlockNumber, 0, 0); } /// @dev Tests that `proposeL2Output` reverts when given a block number /// whose hash does not match the given block hash. function test_proposeL2Output_wrongFork_reverts() external { - uint256 nextBlockNumber = oracle.nextBlockNumber(); + uint256 nextBlockNumber = l2OutputOracle.nextBlockNumber(); warpToProposeTime(nextBlockNumber); - vm.prank(proposer); + vm.prank(cfg.l2OutputOracleProposer()); vm.expectRevert("L2OutputOracle: block hash does not match the hash at the expected height"); - oracle.proposeL2Output(nonZeroHash, nextBlockNumber, bytes32(uint256(0x01)), block.number - 1); + l2OutputOracle.proposeL2Output(nonZeroHash, nextBlockNumber, bytes32(uint256(0x01)), block.number); } /// @dev Tests that `proposeL2Output` reverts when given a block number @@ -280,38 +298,39 @@ contract L2OutputOracle_proposeL2Output_Test is L2OutputOracle_Initializer { uint256 l1BlockNumber = block.number - 1; bytes32 l1BlockHash = blockhash(l1BlockNumber); - uint256 nextBlockNumber = oracle.nextBlockNumber(); + uint256 nextBlockNumber = l2OutputOracle.nextBlockNumber(); warpToProposeTime(nextBlockNumber); - vm.prank(proposer); + vm.prank(cfg.l2OutputOracleProposer()); // This will fail when foundry no longer returns zerod block hashes vm.expectRevert("L2OutputOracle: block hash does not match the hash at the expected height"); - oracle.proposeL2Output(nonZeroHash, nextBlockNumber, l1BlockHash, l1BlockNumber - 1); + l2OutputOracle.proposeL2Output(nonZeroHash, nextBlockNumber, l1BlockHash, l1BlockNumber - 1); } } -contract L2OutputOracle_deleteOutputs_Test is L2OutputOracle_Initializer { +contract L2OutputOracle_deleteOutputs_Test is CommonTest { /// @dev Tests that `deleteL2Outputs` succeeds for a single output. function test_deleteOutputs_singleOutput_succeeds() external { proposeAnotherOutput(); proposeAnotherOutput(); - uint256 latestBlockNumber = oracle.latestBlockNumber(); - uint256 latestOutputIndex = oracle.latestOutputIndex(); - Types.OutputProposal memory newLatestOutput = oracle.getL2Output(latestOutputIndex - 1); + uint256 latestBlockNumber = l2OutputOracle.latestBlockNumber(); + uint256 latestOutputIndex = l2OutputOracle.latestOutputIndex(); + Types.OutputProposal memory newLatestOutput = l2OutputOracle.getL2Output(latestOutputIndex - 1); - vm.prank(owner); + vm.prank(l2OutputOracle.challenger()); vm.expectEmit(true, true, false, false); emit OutputsDeleted(latestOutputIndex + 1, latestOutputIndex); - oracle.deleteL2Outputs(latestOutputIndex); + l2OutputOracle.deleteL2Outputs(latestOutputIndex); // validate latestBlockNumber has been reduced - uint256 latestBlockNumberAfter = oracle.latestBlockNumber(); - uint256 latestOutputIndexAfter = oracle.latestOutputIndex(); + uint256 latestBlockNumberAfter = l2OutputOracle.latestBlockNumber(); + uint256 latestOutputIndexAfter = l2OutputOracle.latestOutputIndex(); + uint256 submissionInterval = cfg.l2OutputOracleSubmissionInterval(); assertEq(latestBlockNumber - submissionInterval, latestBlockNumberAfter); // validate that the new latest output is as expected. - Types.OutputProposal memory proposal = oracle.getL2Output(latestOutputIndexAfter); + Types.OutputProposal memory proposal = l2OutputOracle.getL2Output(latestOutputIndexAfter); assertEq(newLatestOutput.outputRoot, proposal.outputRoot); assertEq(newLatestOutput.timestamp, proposal.timestamp); } @@ -323,43 +342,44 @@ contract L2OutputOracle_deleteOutputs_Test is L2OutputOracle_Initializer { proposeAnotherOutput(); proposeAnotherOutput(); - uint256 latestBlockNumber = oracle.latestBlockNumber(); - uint256 latestOutputIndex = oracle.latestOutputIndex(); - Types.OutputProposal memory newLatestOutput = oracle.getL2Output(latestOutputIndex - 3); + uint256 latestBlockNumber = l2OutputOracle.latestBlockNumber(); + uint256 latestOutputIndex = l2OutputOracle.latestOutputIndex(); + Types.OutputProposal memory newLatestOutput = l2OutputOracle.getL2Output(latestOutputIndex - 3); - vm.prank(owner); + vm.prank(l2OutputOracle.challenger()); vm.expectEmit(true, true, false, false); emit OutputsDeleted(latestOutputIndex + 1, latestOutputIndex - 2); - oracle.deleteL2Outputs(latestOutputIndex - 2); + l2OutputOracle.deleteL2Outputs(latestOutputIndex - 2); // validate latestBlockNumber has been reduced - uint256 latestBlockNumberAfter = oracle.latestBlockNumber(); - uint256 latestOutputIndexAfter = oracle.latestOutputIndex(); + uint256 latestBlockNumberAfter = l2OutputOracle.latestBlockNumber(); + uint256 latestOutputIndexAfter = l2OutputOracle.latestOutputIndex(); + uint256 submissionInterval = cfg.l2OutputOracleSubmissionInterval(); assertEq(latestBlockNumber - submissionInterval * 3, latestBlockNumberAfter); // validate that the new latest output is as expected. - Types.OutputProposal memory proposal = oracle.getL2Output(latestOutputIndexAfter); + Types.OutputProposal memory proposal = l2OutputOracle.getL2Output(latestOutputIndexAfter); assertEq(newLatestOutput.outputRoot, proposal.outputRoot); assertEq(newLatestOutput.timestamp, proposal.timestamp); } /// @dev Tests that `deleteL2Outputs` reverts when not called by the challenger. function test_deleteL2Outputs_ifNotChallenger_reverts() external { - uint256 latestBlockNumber = oracle.latestBlockNumber(); + uint256 latestBlockNumber = l2OutputOracle.latestBlockNumber(); vm.expectRevert("L2OutputOracle: only the challenger address can delete outputs"); - oracle.deleteL2Outputs(latestBlockNumber); + l2OutputOracle.deleteL2Outputs(latestBlockNumber); } /// @dev Tests that `deleteL2Outputs` reverts for a non-existant output index. function test_deleteL2Outputs_nonExistent_reverts() external { proposeAnotherOutput(); - uint256 latestBlockNumber = oracle.latestBlockNumber(); + uint256 latestBlockNumber = l2OutputOracle.latestBlockNumber(); - vm.prank(owner); + vm.prank(l2OutputOracle.challenger()); vm.expectRevert("L2OutputOracle: cannot delete outputs after the latest output index"); - oracle.deleteL2Outputs(latestBlockNumber + 1); + l2OutputOracle.deleteL2Outputs(latestBlockNumber + 1); } /// @dev Tests that `deleteL2Outputs` reverts when trying to delete outputs @@ -370,14 +390,14 @@ contract L2OutputOracle_deleteOutputs_Test is L2OutputOracle_Initializer { proposeAnotherOutput(); // Delete the latest two outputs - uint256 latestOutputIndex = oracle.latestOutputIndex(); - vm.prank(owner); - oracle.deleteL2Outputs(latestOutputIndex - 2); + uint256 latestOutputIndex = l2OutputOracle.latestOutputIndex(); + vm.prank(l2OutputOracle.challenger()); + l2OutputOracle.deleteL2Outputs(latestOutputIndex - 2); // Now try to delete the same output again - vm.prank(owner); + vm.prank(l2OutputOracle.challenger()); vm.expectRevert("L2OutputOracle: cannot delete outputs after the latest output index"); - oracle.deleteL2Outputs(latestOutputIndex - 2); + l2OutputOracle.deleteL2Outputs(latestOutputIndex - 2); } /// @dev Tests that `deleteL2Outputs` reverts for finalized outputs. @@ -385,43 +405,48 @@ contract L2OutputOracle_deleteOutputs_Test is L2OutputOracle_Initializer { proposeAnotherOutput(); // Warp past the finalization period + 1 second - vm.warp(block.timestamp + oracle.FINALIZATION_PERIOD_SECONDS() + 1); + vm.warp(block.timestamp + l2OutputOracle.FINALIZATION_PERIOD_SECONDS() + 1); - uint256 latestOutputIndex = oracle.latestOutputIndex(); + uint256 latestOutputIndex = l2OutputOracle.latestOutputIndex(); // Try to delete a finalized output - vm.prank(owner); + vm.prank(l2OutputOracle.challenger()); vm.expectRevert("L2OutputOracle: cannot delete outputs that have already been finalized"); - oracle.deleteL2Outputs(latestOutputIndex); + l2OutputOracle.deleteL2Outputs(latestOutputIndex); } } -contract L2OutputOracleUpgradeable_Test is L2OutputOracle_Initializer { - Proxy internal proxy; - - function setUp() public override { - super.setUp(); - proxy = Proxy(payable(address(oracle))); - } - +contract L2OutputOracleUpgradeable_Test is CommonTest { /// @dev Tests that the proxy is initialized with the correct values. function test_initValuesOnProxy_succeeds() external { - assertEq(oracle.SUBMISSION_INTERVAL(), submissionInterval); - assertEq(oracle.submissionInterval(), submissionInterval); - assertEq(oracle.L2_BLOCK_TIME(), l2BlockTime); - assertEq(oracle.l2BlockTime(), l2BlockTime); - assertEq(oracle.startingBlockNumber(), startingBlockNumber); - assertEq(oracle.startingTimestamp(), startingTimestamp); - assertEq(oracle.finalizationPeriodSeconds(), finalizationPeriodSeconds); - assertEq(oracle.PROPOSER(), proposer); - assertEq(oracle.proposer(), proposer); - assertEq(oracle.CHALLENGER(), owner); - assertEq(oracle.challenger(), owner); + address proposer = cfg.l2OutputOracleProposer(); + address challenger = cfg.l2OutputOracleChallenger(); + uint256 submissionInterval = cfg.l2OutputOracleSubmissionInterval(); + uint256 startingBlockNumber = cfg.l2OutputOracleStartingBlockNumber(); + uint256 startingTimestamp = cfg.l2OutputOracleStartingTimestamp(); + uint256 l2BlockTime = cfg.l2BlockTime(); + uint256 finalizationPeriodSeconds = cfg.finalizationPeriodSeconds(); + + assertEq(l2OutputOracle.SUBMISSION_INTERVAL(), submissionInterval); + assertEq(l2OutputOracle.submissionInterval(), submissionInterval); + assertEq(l2OutputOracle.L2_BLOCK_TIME(), l2BlockTime); + assertEq(l2OutputOracle.l2BlockTime(), l2BlockTime); + assertEq(l2OutputOracle.startingBlockNumber(), startingBlockNumber); + assertEq(l2OutputOracle.startingTimestamp(), startingTimestamp); + assertEq(l2OutputOracle.finalizationPeriodSeconds(), finalizationPeriodSeconds); + assertEq(l2OutputOracle.PROPOSER(), proposer); + assertEq(l2OutputOracle.proposer(), proposer); + assertEq(l2OutputOracle.CHALLENGER(), challenger); + assertEq(l2OutputOracle.challenger(), challenger); } /// @dev Tests that the impl is created with the correct values. function test_initValuesOnImpl_succeeds() external { + L2OutputOracle oracleImpl = L2OutputOracle(mustGetAddress("L2OutputOracle")); + + uint256 submissionInterval = cfg.l2OutputOracleSubmissionInterval(); assertEq(submissionInterval, oracleImpl.SUBMISSION_INTERVAL()); + uint256 l2BlockTime = cfg.l2BlockTime(); assertEq(l2BlockTime, oracleImpl.L2_BLOCK_TIME()); // The values that are set in the initialize function should be all @@ -436,8 +461,10 @@ contract L2OutputOracleUpgradeable_Test is L2OutputOracle_Initializer { /// @dev Tests that the proxy cannot be initialized twice. function test_initializeProxy_alreadyInitialized_reverts() external { + uint256 startingBlockNumber = cfg.l2OutputOracleStartingBlockNumber(); + uint256 startingTimestamp = cfg.l2OutputOracleStartingTimestamp(); vm.expectRevert("Initializable: contract is already initialized"); - L2OutputOracle(payable(proxy)).initialize({ + l2OutputOracle.initialize({ _startingBlockNumber: startingBlockNumber, _startingTimestamp: startingTimestamp, _proposer: address(1), @@ -447,8 +474,11 @@ contract L2OutputOracleUpgradeable_Test is L2OutputOracle_Initializer { /// @dev Tests that the implementation contract cannot be initialized twice. function test_initializeImpl_alreadyInitialized_reverts() external { + L2OutputOracle oracleImpl = L2OutputOracle(mustGetAddress("L2OutputOracle")); + uint256 startingBlockNumber = cfg.l2OutputOracleStartingBlockNumber(); + uint256 startingTimestamp = cfg.l2OutputOracleStartingTimestamp(); vm.expectRevert("Initializable: contract is already initialized"); - L2OutputOracle(oracleImpl).initialize({ + oracleImpl.initialize({ _startingBlockNumber: startingBlockNumber, _startingTimestamp: startingTimestamp, _proposer: address(1), @@ -458,20 +488,21 @@ contract L2OutputOracleUpgradeable_Test is L2OutputOracle_Initializer { /// @dev Tests that the proxy can be successfully upgraded. function test_upgrading_succeeds() external { + Proxy proxy = Proxy(mustGetAddress("L2OutputOracleProxy")); // Check an unused slot before upgrading. - bytes32 slot21Before = vm.load(address(oracle), bytes32(uint256(21))); + bytes32 slot21Before = vm.load(address(l2OutputOracle), bytes32(uint256(21))); assertEq(bytes32(0), slot21Before); NextImpl nextImpl = new NextImpl(); - vm.startPrank(multisig); + vm.startPrank(EIP1967Helper.getAdmin(address(proxy))); proxy.upgradeToAndCall( address(nextImpl), abi.encodeWithSelector(NextImpl.initialize.selector, Constants.INITIALIZER + 1) ); assertEq(proxy.implementation(), address(nextImpl)); // Verify that the NextImpl contract initialized its values according as expected - bytes32 slot21After = vm.load(address(oracle), bytes32(uint256(21))); - bytes32 slot21Expected = NextImpl(address(oracle)).slot21Init(); + bytes32 slot21After = vm.load(address(l2OutputOracle), bytes32(uint256(21))); + bytes32 slot21Expected = NextImpl(address(l2OutputOracle)).slot21Init(); assertEq(slot21Expected, slot21After); } } diff --git a/packages/contracts-bedrock/test/L2StandardBridge.t.sol b/packages/contracts-bedrock/test/L2StandardBridge.t.sol index b9f31b3abcd72..567f2ea9748a8 100644 --- a/packages/contracts-bedrock/test/L2StandardBridge.t.sol +++ b/packages/contracts-bedrock/test/L2StandardBridge.t.sol @@ -3,44 +3,44 @@ pragma solidity 0.8.15; // Testing utilities // Target contract is imported by the `Bridge_Initializer` -import { Bridge_Initializer } from "./CommonTest.t.sol"; +import { Bridge_Initializer } from "test/setup/Bridge_Initializer.sol"; import { stdStorage, StdStorage } from "forge-std/Test.sol"; -import { CrossDomainMessenger } from "../src/universal/CrossDomainMessenger.sol"; -import { L2ToL1MessagePasser } from "../src/L2/L2ToL1MessagePasser.sol"; +import { CrossDomainMessenger } from "src/universal/CrossDomainMessenger.sol"; +import { L2ToL1MessagePasser } from "src/L2/L2ToL1MessagePasser.sol"; import { ERC20 } from "@openzeppelin/contracts/token/ERC20/ERC20.sol"; // Libraries -import { Hashing } from "../src/libraries/Hashing.sol"; -import { Types } from "../src/libraries/Types.sol"; +import { Hashing } from "src/libraries/Hashing.sol"; +import { Types } from "src/libraries/Types.sol"; // Target contract dependencies -import { Predeploys } from "../src/libraries/Predeploys.sol"; -import { StandardBridge } from "../src/universal/StandardBridge.sol"; -import { OptimismMintableERC20 } from "../src/universal/OptimismMintableERC20.sol"; +import { Predeploys } from "src/libraries/Predeploys.sol"; +import { StandardBridge } from "src/universal/StandardBridge.sol"; +import { OptimismMintableERC20 } from "src/universal/OptimismMintableERC20.sol"; contract L2StandardBridge_Test is Bridge_Initializer { using stdStorage for StdStorage; /// @dev Tests that the bridge is initialized correctly. function test_initialize_succeeds() external { - assertEq(address(L2Bridge.messenger()), address(L2Messenger)); - assertEq(L1Bridge.l2TokenBridge(), address(L2Bridge)); - assertEq(address(L2Bridge.OTHER_BRIDGE()), address(L1Bridge)); + assertEq(address(l2StandardBridge.messenger()), address(l2CrossDomainMessenger)); + assertEq(l1StandardBridge.l2TokenBridge(), address(l2StandardBridge)); + assertEq(address(l2StandardBridge.OTHER_BRIDGE()), address(l1StandardBridge)); } /// @dev Tests that the bridge receives ETH and successfully initiates a withdrawal. function test_receive_succeeds() external { - assertEq(address(messagePasser).balance, 0); - uint256 nonce = L2Messenger.messageNonce(); + assertEq(address(l2ToL1MessagePasser).balance, 0); + uint256 nonce = l2CrossDomainMessenger.messageNonce(); bytes memory message = abi.encodeWithSelector(StandardBridge.finalizeBridgeETH.selector, alice, alice, 100, hex""); - uint64 baseGas = L2Messenger.baseGas(message, 200_000); + uint64 baseGas = l2CrossDomainMessenger.baseGas(message, 200_000); bytes memory withdrawalData = abi.encodeWithSelector( CrossDomainMessenger.relayMessage.selector, nonce, - address(L2Bridge), - address(L1Bridge), + address(l2StandardBridge), + address(l1StandardBridge), 100, 200_000, message @@ -48,8 +48,8 @@ contract L2StandardBridge_Test is Bridge_Initializer { bytes32 withdrawalHash = Hashing.hashWithdrawal( Types.WithdrawalTransaction({ nonce: nonce, - sender: address(L2Messenger), - target: address(L1Messenger), + sender: address(l2CrossDomainMessenger), + target: address(l1CrossDomainMessenger), value: 100, gasLimit: baseGas, data: withdrawalData @@ -63,24 +63,30 @@ contract L2StandardBridge_Test is Bridge_Initializer { emit ETHBridgeInitiated(alice, alice, 100, hex""); // L2ToL1MessagePasser will emit a MessagePassed event - vm.expectEmit(true, true, true, true, address(messagePasser)); + vm.expectEmit(true, true, true, true, address(l2ToL1MessagePasser)); emit MessagePassed( - nonce, address(L2Messenger), address(L1Messenger), 100, baseGas, withdrawalData, withdrawalHash + nonce, + address(l2CrossDomainMessenger), + address(l1CrossDomainMessenger), + 100, + baseGas, + withdrawalData, + withdrawalHash ); // SentMessage event emitted by the CrossDomainMessenger - vm.expectEmit(true, true, true, true, address(L2Messenger)); - emit SentMessage(address(L1Bridge), address(L2Bridge), message, nonce, 200_000); + vm.expectEmit(true, true, true, true, address(l2CrossDomainMessenger)); + emit SentMessage(address(l1StandardBridge), address(l2StandardBridge), message, nonce, 200_000); // SentMessageExtension1 event emitted by the CrossDomainMessenger - vm.expectEmit(true, true, true, true, address(L2Messenger)); - emit SentMessageExtension1(address(L2Bridge), 100); + vm.expectEmit(true, true, true, true, address(l2CrossDomainMessenger)); + emit SentMessageExtension1(address(l2StandardBridge), 100); vm.expectCall( - address(L2Messenger), + address(l2CrossDomainMessenger), abi.encodeWithSelector( CrossDomainMessenger.sendMessage.selector, - address(L1Bridge), + address(l1StandardBridge), message, 200_000 // StandardBridge's RECEIVE_DEFAULT_GAS_LIMIT ) @@ -89,23 +95,26 @@ contract L2StandardBridge_Test is Bridge_Initializer { vm.expectCall( Predeploys.L2_TO_L1_MESSAGE_PASSER, abi.encodeWithSelector( - L2ToL1MessagePasser.initiateWithdrawal.selector, address(L1Messenger), baseGas, withdrawalData + L2ToL1MessagePasser.initiateWithdrawal.selector, + address(l1CrossDomainMessenger), + baseGas, + withdrawalData ) ); vm.prank(alice, alice); - (bool success,) = address(L2Bridge).call{ value: 100 }(hex""); + (bool success,) = address(l2StandardBridge).call{ value: 100 }(hex""); assertEq(success, true); - assertEq(address(messagePasser).balance, 100); + assertEq(address(l2ToL1MessagePasser).balance, 100); } /// @dev Tests that `withdraw` reverts if the amount is not equal to the value sent. function test_withdraw_insufficientValue_reverts() external { - assertEq(address(messagePasser).balance, 0); + assertEq(address(l2ToL1MessagePasser).balance, 0); vm.expectRevert("StandardBridge: bridging ETH must include sufficient ETH value"); vm.prank(alice, alice); - L2Bridge.withdraw(address(Predeploys.LEGACY_ERC20_ETH), 100, 1000, hex""); + l2StandardBridge.withdraw(address(Predeploys.LEGACY_ERC20_ETH), 100, 1000, hex""); } /// @dev Tests that the legacy `withdraw` interface on the L2StandardBridge @@ -114,7 +123,7 @@ contract L2StandardBridge_Test is Bridge_Initializer { assertTrue(alice.balance >= 100); assertEq(Predeploys.L2_TO_L1_MESSAGE_PASSER.balance, 0); - vm.expectEmit(true, true, true, true, address(L2Bridge)); + vm.expectEmit(true, true, true, true, address(l2StandardBridge)); emit WithdrawalInitiated({ l1Token: address(0), l2Token: Predeploys.LEGACY_ERC20_ETH, @@ -124,11 +133,11 @@ contract L2StandardBridge_Test is Bridge_Initializer { data: hex"" }); - vm.expectEmit(true, true, true, true, address(L2Bridge)); + vm.expectEmit(true, true, true, true, address(l2StandardBridge)); emit ETHBridgeInitiated({ from: alice, to: alice, amount: 100, data: hex"" }); vm.prank(alice, alice); - L2Bridge.withdraw{ value: 100 }({ + l2StandardBridge.withdraw{ value: 100 }({ _l2Token: Predeploys.LEGACY_ERC20_ETH, _amount: 100, _minGasLimit: 1000, @@ -145,19 +154,25 @@ contract PreBridgeERC20 is Bridge_Initializer { // Alice has 100 L2Token deal(_l2Token, alice, 100, true); assertEq(ERC20(_l2Token).balanceOf(alice), 100); - uint256 nonce = L2Messenger.messageNonce(); + uint256 nonce = l2CrossDomainMessenger.messageNonce(); bytes memory message = abi.encodeWithSelector( StandardBridge.finalizeBridgeERC20.selector, address(L1Token), _l2Token, alice, alice, 100, hex"" ); - uint64 baseGas = L2Messenger.baseGas(message, 1000); + uint64 baseGas = l2CrossDomainMessenger.baseGas(message, 1000); bytes memory withdrawalData = abi.encodeWithSelector( - CrossDomainMessenger.relayMessage.selector, nonce, address(L2Bridge), address(L1Bridge), 0, 1000, message + CrossDomainMessenger.relayMessage.selector, + nonce, + address(l2StandardBridge), + address(l1StandardBridge), + 0, + 1000, + message ); bytes32 withdrawalHash = Hashing.hashWithdrawal( Types.WithdrawalTransaction({ nonce: nonce, - sender: address(L2Messenger), - target: address(L1Messenger), + sender: address(l2CrossDomainMessenger), + target: address(l1CrossDomainMessenger), value: 0, gasLimit: baseGas, data: withdrawalData @@ -166,28 +181,34 @@ contract PreBridgeERC20 is Bridge_Initializer { if (_isLegacy) { vm.expectCall( - address(L2Bridge), abi.encodeWithSelector(L2Bridge.withdraw.selector, _l2Token, 100, 1000, hex"") + address(l2StandardBridge), + abi.encodeWithSelector(l2StandardBridge.withdraw.selector, _l2Token, 100, 1000, hex"") ); } else { vm.expectCall( - address(L2Bridge), - abi.encodeWithSelector(L2Bridge.bridgeERC20.selector, _l2Token, address(L1Token), 100, 1000, hex"") + address(l2StandardBridge), + abi.encodeWithSelector( + l2StandardBridge.bridgeERC20.selector, _l2Token, address(L1Token), 100, 1000, hex"" + ) ); } vm.expectCall( - address(L2Messenger), - abi.encodeWithSelector(CrossDomainMessenger.sendMessage.selector, address(L1Bridge), message, 1000) + address(l2CrossDomainMessenger), + abi.encodeWithSelector(CrossDomainMessenger.sendMessage.selector, address(l1StandardBridge), message, 1000) ); vm.expectCall( Predeploys.L2_TO_L1_MESSAGE_PASSER, abi.encodeWithSelector( - L2ToL1MessagePasser.initiateWithdrawal.selector, address(L1Messenger), baseGas, withdrawalData + L2ToL1MessagePasser.initiateWithdrawal.selector, + address(l1CrossDomainMessenger), + baseGas, + withdrawalData ) ); - // The L2Bridge should burn the tokens + // The l2StandardBridge should burn the tokens vm.expectCall(_l2Token, abi.encodeWithSelector(OptimismMintableERC20.burn.selector, alice, 100)); vm.expectEmit(true, true, true, true); @@ -198,16 +219,22 @@ contract PreBridgeERC20 is Bridge_Initializer { vm.expectEmit(true, true, true, true); emit MessagePassed( - nonce, address(L2Messenger), address(L1Messenger), 0, baseGas, withdrawalData, withdrawalHash + nonce, + address(l2CrossDomainMessenger), + address(l1CrossDomainMessenger), + 0, + baseGas, + withdrawalData, + withdrawalHash ); // SentMessage event emitted by the CrossDomainMessenger vm.expectEmit(true, true, true, true); - emit SentMessage(address(L1Bridge), address(L2Bridge), message, nonce, 1000); + emit SentMessage(address(l1StandardBridge), address(l2StandardBridge), message, nonce, 1000); // SentMessageExtension1 event emitted by the CrossDomainMessenger vm.expectEmit(true, true, true, true); - emit SentMessageExtension1(address(L2Bridge), 0); + emit SentMessageExtension1(address(l2StandardBridge), 0); vm.prank(alice, alice); } @@ -220,7 +247,7 @@ contract L2StandardBridge_BridgeERC20_Test is PreBridgeERC20 { // - calls Withdrawer.initiateWithdrawal function test_withdraw_withdrawingERC20_succeeds() external { _preBridgeERC20({ _isLegacy: true, _l2Token: address(L2Token) }); - L2Bridge.withdraw(address(L2Token), 100, 1000, hex""); + l2StandardBridge.withdraw(address(L2Token), 100, 1000, hex""); assertEq(L2Token.balanceOf(alice), 0); } @@ -231,21 +258,21 @@ contract L2StandardBridge_BridgeERC20_Test is PreBridgeERC20 { // - calls Withdrawer.initiateWithdrawal function test_bridgeERC20_succeeds() external { _preBridgeERC20({ _isLegacy: false, _l2Token: address(L2Token) }); - L2Bridge.bridgeERC20(address(L2Token), address(L1Token), 100, 1000, hex""); + l2StandardBridge.bridgeERC20(address(L2Token), address(L1Token), 100, 1000, hex""); assertEq(L2Token.balanceOf(alice), 0); } function test_withdrawLegacyERC20_succeeds() external { _preBridgeERC20({ _isLegacy: true, _l2Token: address(LegacyL2Token) }); - L2Bridge.withdraw(address(LegacyL2Token), 100, 1000, hex""); + l2StandardBridge.withdraw(address(LegacyL2Token), 100, 1000, hex""); assertEq(L2Token.balanceOf(alice), 0); } function test_bridgeLegacyERC20_succeeds() external { _preBridgeERC20({ _isLegacy: false, _l2Token: address(LegacyL2Token) }); - L2Bridge.bridgeERC20(address(LegacyL2Token), address(L1Token), 100, 1000, hex""); + l2StandardBridge.bridgeERC20(address(LegacyL2Token), address(L1Token), 100, 1000, hex""); assertEq(L2Token.balanceOf(alice), 0); } @@ -255,7 +282,7 @@ contract L2StandardBridge_BridgeERC20_Test is PreBridgeERC20 { deal(address(L2Token), address(this), 100, true); vm.expectRevert("StandardBridge: function can only be called from an EOA"); - L2Bridge.withdraw(address(L2Token), 100, 1000, hex""); + l2StandardBridge.withdraw(address(L2Token), 100, 1000, hex""); } } @@ -265,70 +292,86 @@ contract PreBridgeERC20To is Bridge_Initializer { function _preBridgeERC20To(bool _isLegacy, address _l2Token) internal { deal(_l2Token, alice, 100, true); assertEq(ERC20(L2Token).balanceOf(alice), 100); - uint256 nonce = L2Messenger.messageNonce(); + uint256 nonce = l2CrossDomainMessenger.messageNonce(); bytes memory message = abi.encodeWithSelector( StandardBridge.finalizeBridgeERC20.selector, address(L1Token), _l2Token, alice, bob, 100, hex"" ); - uint64 baseGas = L2Messenger.baseGas(message, 1000); + uint64 baseGas = l2CrossDomainMessenger.baseGas(message, 1000); bytes memory withdrawalData = abi.encodeWithSelector( - CrossDomainMessenger.relayMessage.selector, nonce, address(L2Bridge), address(L1Bridge), 0, 1000, message + CrossDomainMessenger.relayMessage.selector, + nonce, + address(l2StandardBridge), + address(l1StandardBridge), + 0, + 1000, + message ); bytes32 withdrawalHash = Hashing.hashWithdrawal( Types.WithdrawalTransaction({ nonce: nonce, - sender: address(L2Messenger), - target: address(L1Messenger), + sender: address(l2CrossDomainMessenger), + target: address(l1CrossDomainMessenger), value: 0, gasLimit: baseGas, data: withdrawalData }) ); - vm.expectEmit(true, true, true, true, address(L2Bridge)); + vm.expectEmit(true, true, true, true, address(l2StandardBridge)); emit WithdrawalInitiated(address(L1Token), _l2Token, alice, bob, 100, hex""); - vm.expectEmit(true, true, true, true, address(L2Bridge)); + vm.expectEmit(true, true, true, true, address(l2StandardBridge)); emit ERC20BridgeInitiated(_l2Token, address(L1Token), alice, bob, 100, hex""); - vm.expectEmit(true, true, true, true, address(messagePasser)); + vm.expectEmit(true, true, true, true, address(l2ToL1MessagePasser)); emit MessagePassed( - nonce, address(L2Messenger), address(L1Messenger), 0, baseGas, withdrawalData, withdrawalHash + nonce, + address(l2CrossDomainMessenger), + address(l1CrossDomainMessenger), + 0, + baseGas, + withdrawalData, + withdrawalHash ); // SentMessage event emitted by the CrossDomainMessenger - vm.expectEmit(true, true, true, true, address(L2Messenger)); - emit SentMessage(address(L1Bridge), address(L2Bridge), message, nonce, 1000); + vm.expectEmit(true, true, true, true, address(l2CrossDomainMessenger)); + emit SentMessage(address(l1StandardBridge), address(l2StandardBridge), message, nonce, 1000); // SentMessageExtension1 event emitted by the CrossDomainMessenger - vm.expectEmit(true, true, true, true, address(L2Messenger)); - emit SentMessageExtension1(address(L2Bridge), 0); + vm.expectEmit(true, true, true, true, address(l2CrossDomainMessenger)); + emit SentMessageExtension1(address(l2StandardBridge), 0); if (_isLegacy) { vm.expectCall( - address(L2Bridge), abi.encodeWithSelector(L2Bridge.withdrawTo.selector, _l2Token, bob, 100, 1000, hex"") + address(l2StandardBridge), + abi.encodeWithSelector(l2StandardBridge.withdrawTo.selector, _l2Token, bob, 100, 1000, hex"") ); } else { vm.expectCall( - address(L2Bridge), + address(l2StandardBridge), abi.encodeWithSelector( - L2Bridge.bridgeERC20To.selector, _l2Token, address(L1Token), bob, 100, 1000, hex"" + l2StandardBridge.bridgeERC20To.selector, _l2Token, address(L1Token), bob, 100, 1000, hex"" ) ); } vm.expectCall( - address(L2Messenger), - abi.encodeWithSelector(CrossDomainMessenger.sendMessage.selector, address(L1Bridge), message, 1000) + address(l2CrossDomainMessenger), + abi.encodeWithSelector(CrossDomainMessenger.sendMessage.selector, address(l1StandardBridge), message, 1000) ); vm.expectCall( Predeploys.L2_TO_L1_MESSAGE_PASSER, abi.encodeWithSelector( - L2ToL1MessagePasser.initiateWithdrawal.selector, address(L1Messenger), baseGas, withdrawalData + L2ToL1MessagePasser.initiateWithdrawal.selector, + address(l1CrossDomainMessenger), + baseGas, + withdrawalData ) ); - // The L2Bridge should burn the tokens + // The l2StandardBridge should burn the tokens vm.expectCall(address(L2Token), abi.encodeWithSelector(OptimismMintableERC20.burn.selector, alice, 100)); vm.prank(alice, alice); @@ -340,7 +383,7 @@ contract L2StandardBridge_BridgeERC20To_Test is PreBridgeERC20To { /// and initiates a withdrawal with `Withdrawer.initiateWithdrawal`. function test_withdrawTo_withdrawingERC20_succeeds() external { _preBridgeERC20To({ _isLegacy: true, _l2Token: address(L2Token) }); - L2Bridge.withdrawTo(address(L2Token), bob, 100, 1000, hex""); + l2StandardBridge.withdrawTo(address(L2Token), bob, 100, 1000, hex""); assertEq(L2Token.balanceOf(alice), 0); } @@ -349,7 +392,7 @@ contract L2StandardBridge_BridgeERC20To_Test is PreBridgeERC20To { /// and initiates a withdrawal with `Withdrawer.initiateWithdrawal`. function test_bridgeERC20To_succeeds() external { _preBridgeERC20To({ _isLegacy: false, _l2Token: address(L2Token) }); - L2Bridge.bridgeERC20To(address(L2Token), address(L1Token), bob, 100, 1000, hex""); + l2StandardBridge.bridgeERC20To(address(L2Token), address(L1Token), bob, 100, 1000, hex""); assertEq(L2Token.balanceOf(alice), 0); } } @@ -361,37 +404,37 @@ contract L2StandardBridge_Bridge_Test is Bridge_Initializer { /// - call `Withdrawer.initiateWithdrawal` if the token pair is not supported function test_finalizeDeposit_depositingERC20_succeeds() external { vm.mockCall( - address(L2Bridge.messenger()), + address(l2StandardBridge.messenger()), abi.encodeWithSelector(CrossDomainMessenger.xDomainMessageSender.selector), - abi.encode(address(L2Bridge.OTHER_BRIDGE())) + abi.encode(address(l2StandardBridge.OTHER_BRIDGE())) ); vm.expectCall(address(L2Token), abi.encodeWithSelector(OptimismMintableERC20.mint.selector, alice, 100)); // Should emit both the bedrock and legacy events - vm.expectEmit(true, true, true, true, address(L2Bridge)); + vm.expectEmit(true, true, true, true, address(l2StandardBridge)); emit DepositFinalized(address(L1Token), address(L2Token), alice, alice, 100, hex""); - vm.expectEmit(true, true, true, true, address(L2Bridge)); + vm.expectEmit(true, true, true, true, address(l2StandardBridge)); emit ERC20BridgeFinalized(address(L2Token), address(L1Token), alice, alice, 100, hex""); - vm.prank(address(L2Messenger)); - L2Bridge.finalizeDeposit(address(L1Token), address(L2Token), alice, alice, 100, hex""); + vm.prank(address(l2CrossDomainMessenger)); + l2StandardBridge.finalizeDeposit(address(L1Token), address(L2Token), alice, alice, 100, hex""); } /// @dev Tests that `finalizeDeposit` succeeds when depositing ETH. function test_finalizeDeposit_depositingETH_succeeds() external { vm.mockCall( - address(L2Bridge.messenger()), + address(l2StandardBridge.messenger()), abi.encodeWithSelector(CrossDomainMessenger.xDomainMessageSender.selector), - abi.encode(address(L2Bridge.OTHER_BRIDGE())) + abi.encode(address(l2StandardBridge.OTHER_BRIDGE())) ); // Should emit both the bedrock and legacy events - vm.expectEmit(true, true, true, true, address(L2Bridge)); + vm.expectEmit(true, true, true, true, address(l2StandardBridge)); emit DepositFinalized(address(L1Token), address(L2Token), alice, alice, 100, hex""); - vm.expectEmit(true, true, true, true, address(L2Bridge)); + vm.expectEmit(true, true, true, true, address(l2StandardBridge)); emit ERC20BridgeFinalized( address(L2Token), // localToken address(L1Token), // remoteToken @@ -401,58 +444,58 @@ contract L2StandardBridge_Bridge_Test is Bridge_Initializer { hex"" ); - vm.prank(address(L2Messenger)); - L2Bridge.finalizeDeposit(address(L1Token), address(L2Token), alice, alice, 100, hex""); + vm.prank(address(l2CrossDomainMessenger)); + l2StandardBridge.finalizeDeposit(address(L1Token), address(L2Token), alice, alice, 100, hex""); } /// @dev Tests that `finalizeDeposit` reverts if the amounts do not match. function test_finalizeBridgeETH_incorrectValue_reverts() external { vm.mockCall( - address(L2Bridge.messenger()), + address(l2StandardBridge.messenger()), abi.encodeWithSelector(CrossDomainMessenger.xDomainMessageSender.selector), - abi.encode(address(L2Bridge.OTHER_BRIDGE())) + abi.encode(address(l2StandardBridge.OTHER_BRIDGE())) ); - vm.deal(address(L2Messenger), 100); - vm.prank(address(L2Messenger)); + vm.deal(address(l2CrossDomainMessenger), 100); + vm.prank(address(l2CrossDomainMessenger)); vm.expectRevert("StandardBridge: amount sent does not match amount required"); - L2Bridge.finalizeBridgeETH{ value: 50 }(alice, alice, 100, hex""); + l2StandardBridge.finalizeBridgeETH{ value: 50 }(alice, alice, 100, hex""); } /// @dev Tests that `finalizeDeposit` reverts if the receipient is the other bridge. function test_finalizeBridgeETH_sendToSelf_reverts() external { vm.mockCall( - address(L2Bridge.messenger()), + address(l2StandardBridge.messenger()), abi.encodeWithSelector(CrossDomainMessenger.xDomainMessageSender.selector), - abi.encode(address(L2Bridge.OTHER_BRIDGE())) + abi.encode(address(l2StandardBridge.OTHER_BRIDGE())) ); - vm.deal(address(L2Messenger), 100); - vm.prank(address(L2Messenger)); + vm.deal(address(l2CrossDomainMessenger), 100); + vm.prank(address(l2CrossDomainMessenger)); vm.expectRevert("StandardBridge: cannot send to self"); - L2Bridge.finalizeBridgeETH{ value: 100 }(alice, address(L2Bridge), 100, hex""); + l2StandardBridge.finalizeBridgeETH{ value: 100 }(alice, address(l2StandardBridge), 100, hex""); } /// @dev Tests that `finalizeDeposit` reverts if the receipient is the messenger. function test_finalizeBridgeETH_sendToMessenger_reverts() external { vm.mockCall( - address(L2Bridge.messenger()), + address(l2StandardBridge.messenger()), abi.encodeWithSelector(CrossDomainMessenger.xDomainMessageSender.selector), - abi.encode(address(L2Bridge.OTHER_BRIDGE())) + abi.encode(address(l2StandardBridge.OTHER_BRIDGE())) ); - vm.deal(address(L2Messenger), 100); - vm.prank(address(L2Messenger)); + vm.deal(address(l2CrossDomainMessenger), 100); + vm.prank(address(l2CrossDomainMessenger)); vm.expectRevert("StandardBridge: cannot send to messenger"); - L2Bridge.finalizeBridgeETH{ value: 100 }(alice, address(L2Messenger), 100, hex""); + l2StandardBridge.finalizeBridgeETH{ value: 100 }(alice, address(l2CrossDomainMessenger), 100, hex""); } } contract L2StandardBridge_FinalizeBridgeETH_Test is Bridge_Initializer { /// @dev Tests that `finalizeBridgeETH` succeeds. function test_finalizeBridgeETH_succeeds() external { - address messenger = address(L2Bridge.messenger()); + address messenger = address(l2StandardBridge.messenger()); vm.mockCall( messenger, abi.encodeWithSelector(CrossDomainMessenger.xDomainMessageSender.selector), - abi.encode(address(L2Bridge.OTHER_BRIDGE())) + abi.encode(address(l2StandardBridge.OTHER_BRIDGE())) ); vm.deal(messenger, 100); vm.prank(messenger); @@ -463,6 +506,6 @@ contract L2StandardBridge_FinalizeBridgeETH_Test is Bridge_Initializer { vm.expectEmit(true, true, true, true); emit ETHBridgeFinalized(alice, alice, 100, hex""); - L2Bridge.finalizeBridgeETH{ value: 100 }(alice, alice, 100, hex""); + l2StandardBridge.finalizeBridgeETH{ value: 100 }(alice, alice, 100, hex""); } } diff --git a/packages/contracts-bedrock/test/L2ToL1MessagePasser.t.sol b/packages/contracts-bedrock/test/L2ToL1MessagePasser.t.sol index 01ebac687c1c8..0c2c6c8b869a1 100644 --- a/packages/contracts-bedrock/test/L2ToL1MessagePasser.t.sol +++ b/packages/contracts-bedrock/test/L2ToL1MessagePasser.t.sol @@ -2,36 +2,13 @@ pragma solidity 0.8.15; // Testing utilities -import { CommonTest } from "./CommonTest.t.sol"; +import { CommonTest } from "test/setup/CommonTest.sol"; // Libraries -import { Types } from "../src/libraries/Types.sol"; -import { Hashing } from "../src/libraries/Hashing.sol"; - -// Target contract -import { L2ToL1MessagePasser } from "../src/L2/L2ToL1MessagePasser.sol"; +import { Types } from "src/libraries/Types.sol"; +import { Hashing } from "src/libraries/Hashing.sol"; contract L2ToL1MessagePasserTest is CommonTest { - L2ToL1MessagePasser messagePasser; - - event MessagePassed( - uint256 indexed nonce, - address indexed sender, - address indexed target, - uint256 value, - uint256 gasLimit, - bytes data, - bytes32 withdrawalHash - ); - - event WithdrawerBalanceBurnt(uint256 indexed amount); - - /// @dev Sets up the test suite. - function setUp() public virtual override { - super.setUp(); - messagePasser = new L2ToL1MessagePasser(); - } - /// @dev Tests that `initiateWithdrawal` succeeds and correctly sets the state /// of the message passer for the withdrawal hash. function testFuzz_initiateWithdrawal_succeeds( @@ -43,7 +20,7 @@ contract L2ToL1MessagePasserTest is CommonTest { ) external { - uint256 nonce = messagePasser.messageNonce(); + uint256 nonce = l2ToL1MessagePasser.messageNonce(); bytes32 withdrawalHash = Hashing.hashWithdrawal( Types.WithdrawalTransaction({ @@ -56,70 +33,90 @@ contract L2ToL1MessagePasserTest is CommonTest { }) ); - vm.expectEmit(true, true, true, true); + vm.expectEmit(address(l2ToL1MessagePasser)); emit MessagePassed(nonce, _sender, _target, _value, _gasLimit, _data, withdrawalHash); vm.deal(_sender, _value); vm.prank(_sender); - messagePasser.initiateWithdrawal{ value: _value }(_target, _gasLimit, _data); + l2ToL1MessagePasser.initiateWithdrawal{ value: _value }(_target, _gasLimit, _data); - assertEq(messagePasser.sentMessages(withdrawalHash), true); + assertEq(l2ToL1MessagePasser.sentMessages(withdrawalHash), true); bytes32 slot = keccak256(bytes.concat(withdrawalHash, bytes32(0))); - assertEq(vm.load(address(messagePasser), slot), bytes32(uint256(1))); + assertEq(vm.load(address(l2ToL1MessagePasser), slot), bytes32(uint256(1))); } /// @dev Tests that `initiateWithdrawal` succeeds and emits the correct MessagePassed /// log when called by a contract. - function test_initiateWithdrawal_fromContract_succeeds() external { + function testFuzz_initiateWithdrawal_fromContract_succeeds( + address _target, + uint256 _gasLimit, + uint256 _value, + bytes memory _data + ) + external + { bytes32 withdrawalHash = Hashing.hashWithdrawal( - Types.WithdrawalTransaction(messagePasser.messageNonce(), address(this), address(4), 100, 64000, hex"") + Types.WithdrawalTransaction({ + nonce: l2ToL1MessagePasser.messageNonce(), + sender: address(this), + target: _target, + value: _value, + gasLimit: _gasLimit, + data: _data + }) ); - vm.expectEmit(true, true, true, true); - emit MessagePassed(messagePasser.messageNonce(), address(this), address(4), 100, 64000, hex"", withdrawalHash); + vm.expectEmit(address(l2ToL1MessagePasser)); + emit MessagePassed( + l2ToL1MessagePasser.messageNonce(), address(this), _target, _value, _gasLimit, _data, withdrawalHash + ); - vm.deal(address(this), 2 ** 64); - messagePasser.initiateWithdrawal{ value: 100 }(address(4), 64000, hex""); + vm.deal(address(this), _value); + l2ToL1MessagePasser.initiateWithdrawal{ value: _value }(_target, _gasLimit, _data); } /// @dev Tests that `initiateWithdrawal` succeeds and emits the correct MessagePassed /// log when called by an EOA. - function test_initiateWithdrawal_fromEOA_succeeds() external { - uint256 gasLimit = 64000; - address target = address(4); - uint256 value = 100; - bytes memory data = hex"ff"; - uint256 nonce = messagePasser.messageNonce(); + function testFuzz_initiateWithdrawal_fromEOA_succeeds( + uint256 _gasLimit, + address _target, + uint256 _value, + bytes memory _data + ) + external + { + uint256 nonce = l2ToL1MessagePasser.messageNonce(); // EOA emulation vm.prank(alice, alice); - vm.deal(alice, 2 ** 64); + vm.deal(alice, _value); bytes32 withdrawalHash = - Hashing.hashWithdrawal(Types.WithdrawalTransaction(nonce, alice, target, value, gasLimit, data)); + Hashing.hashWithdrawal(Types.WithdrawalTransaction(nonce, alice, _target, _value, _gasLimit, _data)); - vm.expectEmit(true, true, true, true); - emit MessagePassed(nonce, alice, target, value, gasLimit, data, withdrawalHash); + vm.expectEmit(address(l2ToL1MessagePasser)); + emit MessagePassed(nonce, alice, _target, _value, _gasLimit, _data, withdrawalHash); - messagePasser.initiateWithdrawal{ value: value }(target, gasLimit, data); + l2ToL1MessagePasser.initiateWithdrawal{ value: _value }({ _target: _target, _gasLimit: _gasLimit, _data: _data }); // the sent messages mapping is filled - assertEq(messagePasser.sentMessages(withdrawalHash), true); + assertEq(l2ToL1MessagePasser.sentMessages(withdrawalHash), true); // the nonce increments - assertEq(nonce + 1, messagePasser.messageNonce()); + assertEq(nonce + 1, l2ToL1MessagePasser.messageNonce()); } /// @dev Tests that `burn` succeeds and destroys the ETH held in the contract. - function test_burn_succeeds() external { - messagePasser.initiateWithdrawal{ value: NON_ZERO_VALUE }(NON_ZERO_ADDRESS, NON_ZERO_GASLIMIT, NON_ZERO_DATA); + function testFuzz_burn_succeeds(uint256 _value, address _target, uint256 _gasLimit, bytes memory _data) external { + vm.deal(address(this), _value); + + l2ToL1MessagePasser.initiateWithdrawal{ value: _value }({ _target: _target, _gasLimit: _gasLimit, _data: _data }); - assertEq(address(messagePasser).balance, NON_ZERO_VALUE); - vm.expectEmit(true, false, false, false); - emit WithdrawerBalanceBurnt(NON_ZERO_VALUE); - messagePasser.burn(); + assertEq(address(l2ToL1MessagePasser).balance, _value); + emit WithdrawerBalanceBurnt(_value); + l2ToL1MessagePasser.burn(); // The Withdrawer should have no balance - assertEq(address(messagePasser).balance, 0); + assertEq(address(l2ToL1MessagePasser).balance, 0); } } diff --git a/packages/contracts-bedrock/test/LegacyERC20ETH.t.sol b/packages/contracts-bedrock/test/LegacyERC20ETH.t.sol index 22c801de4ab24..62e2928f06b92 100644 --- a/packages/contracts-bedrock/test/LegacyERC20ETH.t.sol +++ b/packages/contracts-bedrock/test/LegacyERC20ETH.t.sol @@ -2,13 +2,13 @@ pragma solidity 0.8.15; // Testing utilities -import { CommonTest } from "./CommonTest.t.sol"; +import { CommonTest } from "test/setup/CommonTest.sol"; // Target contract dependencies -import { Predeploys } from "../src/libraries/Predeploys.sol"; +import { Predeploys } from "src/libraries/Predeploys.sol"; // Target contract -import { LegacyERC20ETH } from "../src/legacy/LegacyERC20ETH.sol"; +import { LegacyERC20ETH } from "src/legacy/LegacyERC20ETH.sol"; contract LegacyERC20ETH_Test is CommonTest { LegacyERC20ETH eth; diff --git a/packages/contracts-bedrock/test/LegacyMessagePasser.t.sol b/packages/contracts-bedrock/test/LegacyMessagePasser.t.sol index a5914779034d1..39eb479a3ac01 100644 --- a/packages/contracts-bedrock/test/LegacyMessagePasser.t.sol +++ b/packages/contracts-bedrock/test/LegacyMessagePasser.t.sol @@ -2,27 +2,13 @@ pragma solidity 0.8.15; // Testing utilities -import { CommonTest } from "./CommonTest.t.sol"; - -// Testing contract dependencies -import { Predeploys } from "../src/libraries/Predeploys.sol"; - -// Target contract -import { LegacyMessagePasser } from "../src/legacy/LegacyMessagePasser.sol"; +import { CommonTest } from "test/setup/CommonTest.sol"; contract LegacyMessagePasser_Test is CommonTest { - LegacyMessagePasser messagePasser; - - /// @dev Sets up the test suite. - function setUp() public virtual override { - super.setUp(); - messagePasser = new LegacyMessagePasser(); - } - /// @dev Tests that `passMessageToL1` succeeds. function test_passMessageToL1_succeeds() external { vm.prank(alice); - messagePasser.passMessageToL1(hex"ff"); - assert(messagePasser.sentMessages(keccak256(abi.encodePacked(hex"ff", alice)))); + legacyMessagePasser.passMessageToL1(hex"ff"); + assert(legacyMessagePasser.sentMessages(keccak256(abi.encodePacked(hex"ff", alice)))); } } diff --git a/packages/contracts-bedrock/test/LibClock.t.sol b/packages/contracts-bedrock/test/LibClock.t.sol index cc8fc6606902d..41b5ae1849761 100644 --- a/packages/contracts-bedrock/test/LibClock.t.sol +++ b/packages/contracts-bedrock/test/LibClock.t.sol @@ -3,7 +3,7 @@ pragma solidity ^0.8.15; import { Test } from "forge-std/Test.sol"; import { LibClock } from "../src/dispute/lib/LibClock.sol"; -import "../src/libraries/DisputeTypes.sol"; +import "src/libraries/DisputeTypes.sol"; /// @notice Tests for `LibClock` contract LibClock_Test is Test { diff --git a/packages/contracts-bedrock/test/LibPosition.t.sol b/packages/contracts-bedrock/test/LibPosition.t.sol index 4aa2dc0102676..20ff04e9fb44c 100644 --- a/packages/contracts-bedrock/test/LibPosition.t.sol +++ b/packages/contracts-bedrock/test/LibPosition.t.sol @@ -2,8 +2,8 @@ pragma solidity ^0.8.15; import { Test } from "forge-std/Test.sol"; -import { LibPosition } from "../src/dispute/lib/LibPosition.sol"; -import "../src/libraries/DisputeTypes.sol"; +import { LibPosition } from "src/dispute/lib/LibPosition.sol"; +import "src/libraries/DisputeTypes.sol"; /// @notice Tests for `LibPosition` contract LibPosition_Test is Test { diff --git a/packages/contracts-bedrock/test/LivenessGuard.t.sol b/packages/contracts-bedrock/test/LivenessGuard.t.sol new file mode 100644 index 0000000000000..2ea2159d25dcd --- /dev/null +++ b/packages/contracts-bedrock/test/LivenessGuard.t.sol @@ -0,0 +1,327 @@ +// SPDX-License-Identifier: MIT +pragma solidity 0.8.15; + +import { Test } from "forge-std/Test.sol"; +import { StdUtils } from "forge-std/StdUtils.sol"; +import { StdCheats } from "forge-std/StdCheats.sol"; +import { Safe, OwnerManager } from "safe-contracts/Safe.sol"; +import { SafeProxyFactory } from "safe-contracts/proxies/SafeProxyFactory.sol"; +import { ModuleManager } from "safe-contracts/base/ModuleManager.sol"; +import { Enum } from "safe-contracts/common/Enum.sol"; +import "test/safe-tools/SafeTestTools.sol"; +import { EnumerableSet } from "@openzeppelin/contracts/utils/structs/EnumerableSet.sol"; + +import { LivenessGuard } from "src/Safe/LivenessGuard.sol"; + +/// @dev A wrapper contract exposing the length of the ownersBefore set in the LivenessGuard. +contract WrappedGuard is LivenessGuard { + using EnumerableSet for EnumerableSet.AddressSet; + + constructor(Safe safe) LivenessGuard(safe) { } + + function ownersBeforeLength() public view returns (uint256) { + return ownersBefore.length(); + } +} + +contract LivenessGuard_TestInit is Test, SafeTestTools { + using SafeTestLib for SafeInstance; + + event OwnerRecorded(address owner); + + uint256 initTime = 10; + WrappedGuard livenessGuard; + SafeInstance safeInstance; + + /// @dev Sets up the test environment + function setUp() public { + vm.warp(initTime); + safeInstance = _setupSafe(); + livenessGuard = new WrappedGuard(safeInstance.safe); + safeInstance.setGuard(address(livenessGuard)); + } +} + +contract LivenessGuard_Constructor_Test is LivenessGuard_TestInit { + /// @dev Tests that the constructor correctly sets the current time as the lastLive time for each owner + function test_constructor_works() external { + address[] memory owners = safeInstance.owners; + livenessGuard = new WrappedGuard(safeInstance.safe); + for (uint256 i; i < owners.length; i++) { + assertEq(livenessGuard.lastLive(owners[i]), initTime); + } + } +} + +contract LivenessGuard_Getters_Test is LivenessGuard_TestInit { + /// @dev Tests that the getters return the correct values + function test_getters_works() external { + assertEq(address(livenessGuard.safe()), address(safeInstance.safe)); + assertEq(livenessGuard.lastLive(address(0)), 0); + } +} + +contract LivenessGuard_CheckTx_TestFails is LivenessGuard_TestInit { + /// @dev Tests that the checkTransaction function reverts if the caller is not the Safe + function test_checkTransaction_callerIsNotSafe_revert() external { + vm.expectRevert("LivenessGuard: only Safe can call this function"); + livenessGuard.checkTransaction({ + to: address(0), + value: 0, + data: hex"00", + operation: Enum.Operation.Call, + safeTxGas: 0, + baseGas: 0, + gasPrice: 0, + gasToken: address(0), + refundReceiver: payable(address(0)), + signatures: hex"00", + msgSender: address(0) + }); + } +} + +contract LivenessGuard_CheckTx_Test is LivenessGuard_TestInit { + using SafeTestLib for SafeInstance; + + /// @dev Tests that the checkTransaction function succeeds + function test_checkTransaction_succeeds() external { + // Create an array of the addresses who will sign the transaction. SafeTestTools + // will generate these signatures up to the threshold by iterating over the owners array. + address[] memory signers = new address[](safeInstance.threshold); + signers[0] = safeInstance.owners[0]; + signers[1] = safeInstance.owners[1]; + + // Record the timestamps before the transaction + uint256[] memory beforeTimestamps = new uint256[](safeInstance.owners.length); + + // Jump ahead + uint256 newTimestamp = block.timestamp + 100; + vm.warp(newTimestamp); + + for (uint256 i; i < signers.length; i++) { + vm.expectEmit(address(livenessGuard)); + emit OwnerRecorded(signers[i]); + } + vm.expectCall(address(safeInstance.safe), abi.encodeWithSignature("nonce()")); + vm.expectCall(address(safeInstance.safe), abi.encodeCall(OwnerManager.getThreshold, ())); + safeInstance.execTransaction({ to: address(1111), value: 0, data: hex"abba" }); + for (uint256 i; i < safeInstance.threshold; i++) { + uint256 lastLive = livenessGuard.lastLive(safeInstance.owners[i]); + assertGe(lastLive, beforeTimestamps[i]); + assertEq(lastLive, newTimestamp); + } + } +} + +contract LivenessGuard_CheckAfterExecution_TestFails is LivenessGuard_TestInit { + /// @dev Tests that the checkAfterExecution function reverts if the caller is not the Safe + function test_checkAfterExecution_callerIsNotSafe_revert() external { + vm.expectRevert("LivenessGuard: only Safe can call this function"); + livenessGuard.checkAfterExecution(bytes32(0), false); + } +} + +contract LivenessGuard_ShowLiveness_TestFail is LivenessGuard_TestInit { + /// @dev Tests that the showLiveness function reverts if the caller is not an owner + function test_showLiveness_callIsNotSafeOwner_reverts() external { + vm.expectRevert("LivenessGuard: only Safe owners may demonstrate liveness"); + livenessGuard.showLiveness(); + } +} + +contract LivenessGuard_ShowLiveness_Test is LivenessGuard_TestInit { + /// @dev Tests that the showLiveness function succeeds + function test_showLiveness_succeeds() external { + // Cache the caller + address caller = safeInstance.owners[0]; + + vm.expectEmit(address(livenessGuard)); + emit OwnerRecorded(caller); + + vm.prank(caller); + livenessGuard.showLiveness(); + + assertEq(livenessGuard.lastLive(caller), block.timestamp); + } +} + +contract LivenessGuard_OwnerManagement_Test is LivenessGuard_TestInit { + using SafeTestLib for SafeInstance; + + /// @dev Tests that the guard correctly deletes the owner from the lastLive mapping when it is removed + function test_removeOwner_succeeds() external { + address ownerToRemove = safeInstance.owners[0]; + assertGe(livenessGuard.lastLive(ownerToRemove), 0); + assertTrue(safeInstance.safe.isOwner(ownerToRemove)); + + assertEq(livenessGuard.ownersBeforeLength(), 0); + safeInstance.removeOwner({ prevOwner: address(0), owner: ownerToRemove, threshold: 1 }); + assertEq(livenessGuard.ownersBeforeLength(), 0); + + assertFalse(safeInstance.safe.isOwner(ownerToRemove)); + assertEq(livenessGuard.lastLive(ownerToRemove), 0); + } + + /// @dev Tests that the guard correctly adds an owner to the lastLive mapping when it is added + function test_addOwner_succeeds() external { + address ownerToAdd = makeAddr("new owner"); + assertEq(livenessGuard.lastLive(ownerToAdd), 0); + assertFalse(safeInstance.safe.isOwner(ownerToAdd)); + + assertEq(livenessGuard.ownersBeforeLength(), 0); + safeInstance.addOwnerWithThreshold({ owner: ownerToAdd, threshold: 1 }); + assertEq(livenessGuard.ownersBeforeLength(), 0); + + assertTrue(safeInstance.safe.isOwner(ownerToAdd)); + assertEq(livenessGuard.lastLive(ownerToAdd), block.timestamp); + } + + /// @dev Tests that the guard correctly adds an owner to the lastLive mapping when it is added + function test_swapOwner_succeeds() external { + address ownerToRemove = safeInstance.owners[0]; + assertGe(livenessGuard.lastLive(ownerToRemove), 0); + assertTrue(safeInstance.safe.isOwner(ownerToRemove)); + + address ownerToAdd = makeAddr("new owner"); + assertEq(livenessGuard.lastLive(ownerToAdd), 0); + assertFalse(safeInstance.safe.isOwner(ownerToAdd)); + + assertEq(livenessGuard.ownersBeforeLength(), 0); + safeInstance.swapOwner({ prevOwner: address(0), oldOwner: ownerToRemove, newOwner: ownerToAdd }); + assertEq(livenessGuard.ownersBeforeLength(), 0); + + assertFalse(safeInstance.safe.isOwner(ownerToRemove)); + assertEq(livenessGuard.lastLive(ownerToRemove), 0); + + assertTrue(safeInstance.safe.isOwner(ownerToAdd)); + assertEq(livenessGuard.lastLive(ownerToAdd), block.timestamp); + } +} + +contract LivenessGuard_FuzzOwnerManagement_Test is StdCheats, StdUtils, LivenessGuard_TestInit { + using SafeTestLib for SafeInstance; + + /// @dev Enumerates the possible owner management operations + enum OwnerOp { + Add, + Remove, + Swap + } + + /// @dev Describes a change to be made to the safe + struct OwnerChange { + uint8 timeDelta; // used to warp the vm + uint8 operation; // used to choose an OwnerOp + uint256 ownerIndex; // used to choose the owner to remove or swap out + uint256 newThreshold; + } + + /// @dev Maps addresses to private keys + mapping(address => uint256) privateKeys; + + /// @dev Tests that the guard correctly manages the lastLive mapping when owners are added, removed, or swapped + function testFuzz_OwnerManagement_works( + uint256 initialOwners, + uint256 threshold, + OwnerChange[] memory changes + ) + external + { + vm.assume(changes.length < 20); + // Initialize the safe with more owners than changes, to ensure we don't try to remove them all + initialOwners = bound(initialOwners, changes.length, 2 * changes.length); + + // We need at least one owner + initialOwners = initialOwners < 1 ? 1 : initialOwners; + + // Limit the threshold to the number of owners + threshold = bound(threshold, 1, initialOwners); + + // Generate the initial owners and keys and setup the safe + (address[] memory ownerAddrs, uint256[] memory ownerkeys) = + SafeTestLib.makeAddrsAndKeys("safeTest", initialOwners); + // record the private keys for later use + for (uint256 i; i < ownerAddrs.length; i++) { + privateKeys[ownerAddrs[i]] = ownerkeys[i]; + } + + // Create the new safe and register the guard. + SafeInstance memory safeInstance = _setupSafe(ownerkeys, threshold); + livenessGuard = new WrappedGuard(safeInstance.safe); + safeInstance.setGuard(address(livenessGuard)); + + for (uint256 i; i < changes.length; i++) { + vm.warp(block.timestamp + changes[i].timeDelta); + OwnerChange memory change = changes[i]; + address[] memory currentOwners = safeInstance.safe.getOwners(); + + // Create a new owner address to add and store the key + (address newOwner, uint256 newKey) = makeAddrAndKey(string.concat("new owner", vm.toString(i))); + privateKeys[newOwner] = newKey; + + OwnerOp op = OwnerOp(bound(change.operation, 0, uint256(type(OwnerOp).max))); + + assertEq(livenessGuard.ownersBeforeLength(), 0); + if (op == OwnerOp.Add) { + assertEq(livenessGuard.lastLive(newOwner), 0); + assertFalse(safeInstance.safe.isOwner(newOwner)); + change.newThreshold = bound(change.newThreshold, 1, currentOwners.length + 1); + + safeInstance.addOwnerWithThreshold(newOwner, change.newThreshold); + + assertTrue(safeInstance.safe.isOwner(newOwner)); + assertEq(livenessGuard.lastLive(newOwner), block.timestamp); + } else { + // Ensure we're removing an owner at an index within bounds + uint256 ownerIndexToRemove = bound(change.ownerIndex, 0, currentOwners.length - 1); + address ownerToRemove = currentOwners[ownerIndexToRemove]; + address prevOwner = safeInstance.getPrevOwner(ownerToRemove); + + if (op == OwnerOp.Remove) { + if (currentOwners.length == 1) continue; + assertGe(livenessGuard.lastLive(ownerToRemove), 0); + assertTrue(safeInstance.safe.isOwner(ownerToRemove)); + change.newThreshold = bound(change.newThreshold, 1, currentOwners.length - 1); + + safeInstance.removeOwner(prevOwner, ownerToRemove, change.newThreshold); + + assertFalse(safeInstance.safe.isOwner(ownerToRemove)); + assertEq(livenessGuard.lastLive(ownerToRemove), 0); + } else if (op == OwnerOp.Swap) { + assertGe(livenessGuard.lastLive(ownerToRemove), 0); + assertTrue(safeInstance.safe.isOwner(ownerToRemove)); + + safeInstance.swapOwner(prevOwner, ownerToRemove, newOwner); + + assertTrue(safeInstance.safe.isOwner(newOwner)); + assertFalse(safeInstance.safe.isOwner(ownerToRemove)); + assertEq(livenessGuard.lastLive(ownerToRemove), 0); + assertEq(livenessGuard.lastLive(newOwner), block.timestamp); + } + } + assertEq(livenessGuard.ownersBeforeLength(), 0); + _refreshOwners(safeInstance); + } + } + + /// @dev Refreshes the owners and ownerPKs arrays in the SafeInstance + function _refreshOwners(SafeInstance memory instance) internal view { + // Get the current owners + instance.owners = instance.safe.getOwners(); + + // Looks up the private key for each owner + uint256[] memory unsortedOwnerPKs = new uint256[](instance.owners.length); + for (uint256 i; i < instance.owners.length; i++) { + unsortedOwnerPKs[i] = privateKeys[instance.owners[i]]; + } + + // Sort the keys by address and store them in the SafeInstance + instance.ownerPKs = SafeTestLib.sortPKsByComputedAddress(unsortedOwnerPKs); + + // Overwrite the SafeInstances owners array with the computed addresses from the ownerPKs array + for (uint256 i; i < instance.owners.length; i++) { + instance.owners[i] = SafeTestLib.getAddr(instance.ownerPKs[i]); + } + } +} diff --git a/packages/contracts-bedrock/test/LivenessModule.t.sol b/packages/contracts-bedrock/test/LivenessModule.t.sol new file mode 100644 index 0000000000000..d51ea8fee4918 --- /dev/null +++ b/packages/contracts-bedrock/test/LivenessModule.t.sol @@ -0,0 +1,499 @@ +// SPDX-License-Identifier: MIT +pragma solidity 0.8.15; + +import { Test, StdUtils } from "forge-std/Test.sol"; +import { Safe } from "safe-contracts/Safe.sol"; +import { SafeProxyFactory } from "safe-contracts/proxies/SafeProxyFactory.sol"; +import { ModuleManager } from "safe-contracts/base/ModuleManager.sol"; +import { OwnerManager } from "safe-contracts/base/OwnerManager.sol"; +import { Enum } from "safe-contracts/common/Enum.sol"; +import "test/safe-tools/SafeTestTools.sol"; + +import { LivenessModule } from "src/Safe/LivenessModule.sol"; +import { LivenessGuard } from "src/Safe/LivenessGuard.sol"; + +contract LivenessModule_TestInit is Test, SafeTestTools { + using SafeTestLib for SafeInstance; + + event SignersRecorded(bytes32 indexed txHash, address[] signers); + + uint256 initTime = 10; + uint256 livenessInterval = 30 days; + uint256 minOwners = 6; + LivenessModule livenessModule; + LivenessGuard livenessGuard; + SafeInstance safeInstance; + address fallbackOwner; + + /// @dev Removes an owner from the safe + function _removeAnOwner(address _ownerToRemove, address[] memory _owners) internal { + address[] memory prevOwners = new address[](1); + address[] memory ownersToRemove = new address[](1); + ownersToRemove[0] = _ownerToRemove; + prevOwners[0] = SafeTestLib.getPrevOwnerFromList(_ownerToRemove, _owners); + + livenessModule.removeOwners(prevOwners, ownersToRemove); + } + + /// @dev Set the current time to after the liveness interval + function _warpPastLivenessInterval() internal { + vm.warp(initTime + livenessInterval + 1); + } + + /// @dev Sets up the test environment + function setUp() public virtual { + // Set the block timestamp to the initTime, so that signatures recorded in the first block + // are non-zero. + vm.warp(initTime); + + // Create a Safe with 10 owners + (, uint256[] memory keys) = SafeTestLib.makeAddrsAndKeys("moduleTest", 10); + safeInstance = _setupSafe(keys, 8); + + livenessGuard = new LivenessGuard(safeInstance.safe); + fallbackOwner = makeAddr("fallbackOwner"); + livenessModule = new LivenessModule({ + _safe: safeInstance.safe, + _livenessGuard: livenessGuard, + _livenessInterval: livenessInterval, + _minOwners: minOwners, + _fallbackOwner: fallbackOwner + }); + safeInstance.setGuard(address(livenessGuard)); + safeInstance.enableModule(address(livenessModule)); + } +} + +contract LivenessModule_Constructor_TestFail is LivenessModule_TestInit { + /// @dev Tests that the constructor fails if the minOwners is greater than the number of owners + function test_constructor_minOwnersGreaterThanOwners_reverts() external { + vm.expectRevert("LivenessModule: minOwners must be less than the number of owners"); + new LivenessModule({ + _safe: safeInstance.safe, + _livenessGuard: livenessGuard, + _livenessInterval: livenessInterval, + _minOwners: 11, + _fallbackOwner: address(0) + }); + } + + /// @dev Tests that the constructor fails if the minOwners is greater than the number of owners + function test_constructor_wrongThreshold_reverts() external { + uint256 wrongThreshold = livenessModule.get75PercentThreshold(safeInstance.owners.length) - 1; + vm.mockCall( + address(safeInstance.safe), abi.encodeCall(OwnerManager.getThreshold, ()), abi.encode(wrongThreshold) + ); + vm.expectRevert("LivenessModule: Safe must have a threshold of at least 75% of the number of owners"); + new LivenessModule({ + _safe: safeInstance.safe, + _livenessGuard: livenessGuard, + _livenessInterval: livenessInterval, + _minOwners: minOwners, + _fallbackOwner: address(0) + }); + } +} + +contract LivenessModule_Getters_Test is LivenessModule_TestInit { + /// @dev Tests if the getters work correctly + function test_getters_works() external { + assertEq(address(livenessModule.safe()), address(safeInstance.safe)); + assertEq(address(livenessModule.livenessGuard()), address(livenessGuard)); + assertEq(livenessModule.livenessInterval(), 30 days); + assertEq(livenessModule.minOwners(), 6); + assertEq(livenessModule.fallbackOwner(), fallbackOwner); + } +} + +contract LivenessModule_CanRemove_TestFail is LivenessModule_TestInit { + /// @dev Tests if canRemove work correctly + function test_canRemove_notSafeOwner_reverts() external { + address nonOwner = makeAddr("nonOwner"); + vm.expectRevert("LivenessModule: the owner to remove must be an owner of the Safe"); + livenessModule.canRemove(nonOwner); + } +} + +contract LivenessModule_CanRemove_Test is LivenessModule_TestInit { + /// @dev Tests if canRemove work correctly + function test_canRemove_works() external { + _warpPastLivenessInterval(); + bool canRemove = livenessModule.canRemove(safeInstance.owners[0]); + assertTrue(canRemove); + } +} + +contract LivenessModule_Get75PercentThreshold_Test is LivenessModule_TestInit { + /// @dev check the return values of the get75PercentThreshold function against manually + /// calculated values. + function test_get75PercentThreshold_Works() external { + assertEq(livenessModule.get75PercentThreshold(20), 15); + assertEq(livenessModule.get75PercentThreshold(19), 15); + assertEq(livenessModule.get75PercentThreshold(18), 14); + assertEq(livenessModule.get75PercentThreshold(17), 13); + assertEq(livenessModule.get75PercentThreshold(16), 12); + assertEq(livenessModule.get75PercentThreshold(15), 12); + assertEq(livenessModule.get75PercentThreshold(14), 11); + assertEq(livenessModule.get75PercentThreshold(13), 10); + assertEq(livenessModule.get75PercentThreshold(12), 9); + assertEq(livenessModule.get75PercentThreshold(11), 9); + assertEq(livenessModule.get75PercentThreshold(10), 8); + assertEq(livenessModule.get75PercentThreshold(9), 7); + assertEq(livenessModule.get75PercentThreshold(8), 6); + assertEq(livenessModule.get75PercentThreshold(7), 6); + assertEq(livenessModule.get75PercentThreshold(6), 5); + assertEq(livenessModule.get75PercentThreshold(5), 4); + assertEq(livenessModule.get75PercentThreshold(4), 3); + assertEq(livenessModule.get75PercentThreshold(3), 3); + assertEq(livenessModule.get75PercentThreshold(2), 2); + assertEq(livenessModule.get75PercentThreshold(1), 1); + } +} + +contract LivenessModule_RemoveOwners_TestFail is LivenessModule_TestInit { + using SafeTestLib for SafeInstance; + + /// @dev Tests with different length owner arrays + function test_removeOwners_differentArrayLengths_reverts() external { + address[] memory ownersToRemove = new address[](1); + address[] memory prevOwners = new address[](2); + vm.expectRevert("LivenessModule: arrays must be the same length"); + livenessModule.removeOwners(prevOwners, ownersToRemove); + } + + /// @dev Test removing an owner which has recently signed a transaction + function test_removeOwners_ownerHasSignedRecently_reverts() external { + /// Will sign a transaction with the first M owners in the owners list + safeInstance.execTransaction({ to: address(1111), value: 0, data: hex"abba" }); + + address[] memory owners = safeInstance.safe.getOwners(); + + vm.expectRevert("LivenessModule: the owner to remove has signed recently"); + _removeAnOwner(safeInstance.owners[0], owners); + } + + /// @dev Test removing an owner which has recently called showLiveness + function test_removeOwners_ownerHasShownLivenessRecently_reverts() external { + /// Will sign a transaction with the first M owners in the owners list + vm.prank(safeInstance.owners[0]); + livenessGuard.showLiveness(); + address[] memory owners = safeInstance.safe.getOwners(); + vm.expectRevert("LivenessModule: the owner to remove has signed recently"); + _removeAnOwner(safeInstance.owners[0], owners); + } + + /// @dev Test removing an owner with an incorrect previous owner + function test_removeOwners_wrongPreviousOwner_reverts() external { + address[] memory prevOwners = new address[](1); + address[] memory ownersToRemove = new address[](1); + ownersToRemove[0] = safeInstance.owners[0]; + prevOwners[0] = ownersToRemove[0]; // incorrect. + + _warpPastLivenessInterval(); + vm.expectRevert("LivenessModule: failed to remove owner"); + livenessModule.removeOwners(prevOwners, ownersToRemove); + } + + /// @dev Tests if removing all owners works correctly + function test_removeOwners_swapToFallbackOwner_reverts() external { + uint256 numOwners = safeInstance.owners.length; + + address[] memory ownersToRemove = new address[](numOwners); + for (uint256 i; i < numOwners; i++) { + ownersToRemove[i] = safeInstance.owners[i]; + } + address[] memory prevOwners = safeInstance.getPrevOwners(ownersToRemove); + + // Incorrectly set the final owner to address(0) + ownersToRemove[ownersToRemove.length - 1] = address(0); + + _warpPastLivenessInterval(); + vm.expectRevert("LivenessModule: failed to swap to fallback owner"); + livenessModule.removeOwners(prevOwners, ownersToRemove); + } + + /// @dev Tests if remove owners reverts if it removes too many owners without removing all of them + function test_removeOwners_belowMinButNotEmptied_reverts() external { + // Remove all but one owner + uint256 numOwners = safeInstance.owners.length - 2; + + address[] memory ownersToRemove = new address[](numOwners); + for (uint256 i; i < numOwners; i++) { + ownersToRemove[i] = safeInstance.owners[i]; + } + address[] memory prevOwners = safeInstance.getPrevOwners(ownersToRemove); + + _warpPastLivenessInterval(); + vm.expectRevert( + "LivenessModule: must remove all owners and transfer to fallback owner if numOwners < minOwners" + ); + livenessModule.removeOwners(prevOwners, ownersToRemove); + } + + /// @dev Tests if remove owners reverts if it removes too many owners transferring to the shutDown owner + function test_removeOwners_belowEmptiedButNotShutDown_reverts() external { + // Remove all but one owner + uint256 numOwners = safeInstance.owners.length - 1; + + address[] memory ownersToRemove = new address[](numOwners); + for (uint256 i; i < numOwners; i++) { + ownersToRemove[i] = safeInstance.owners[i]; + } + address[] memory prevOwners = safeInstance.getPrevOwners(ownersToRemove); + + _warpPastLivenessInterval(); + vm.expectRevert("LivenessModule: must transfer ownership to fallback owner"); + livenessModule.removeOwners(prevOwners, ownersToRemove); + } + + /// @dev Tests if remove owners reverts if the current Safe.guard does note match the expected + /// livenessGuard address. + function test_removeOwners_guardChanged_reverts() external { + address[] memory ownersToRemove = new address[](1); + ownersToRemove[0] = safeInstance.owners[0]; + address[] memory prevOwners = safeInstance.getPrevOwners(ownersToRemove); + + // Change the guard + livenessGuard = new LivenessGuard(safeInstance.safe); + safeInstance.setGuard(address(livenessGuard)); + + _warpPastLivenessInterval(); + vm.expectRevert("LivenessModule: guard has been changed"); + livenessModule.removeOwners(prevOwners, ownersToRemove); + } + + function test_removeOwners_invalidThreshold_reverts() external { + address[] memory ownersToRemove = new address[](0); + address[] memory prevOwners = new address[](0); + uint256 wrongThreshold = safeInstance.safe.getThreshold() + 1; + + vm.mockCall( + address(safeInstance.safe), abi.encodeCall(OwnerManager.getThreshold, ()), abi.encode(wrongThreshold) + ); + + _warpPastLivenessInterval(); + vm.expectRevert("LivenessModule: Safe must have a threshold of 75% of the number of owners"); + livenessModule.removeOwners(prevOwners, ownersToRemove); + } +} + +contract LivenessModule_RemoveOwners_Test is LivenessModule_TestInit { + using SafeTestLib for SafeInstance; + + /// @dev Tests if removing one owner works correctly + function test_removeOwners_oneOwner_succeeds() external { + uint256 ownersBefore = safeInstance.owners.length; + address ownerToRemove = safeInstance.owners[0]; + + _warpPastLivenessInterval(); + _removeAnOwner(ownerToRemove, safeInstance.owners); + + assertFalse(safeInstance.safe.isOwner(ownerToRemove)); + assertEq(safeInstance.safe.getOwners().length, ownersBefore - 1); + } + + /// @dev Tests if removing all owners works correctly + function test_removeOwners_allOwners_succeeds() external { + uint256 numOwners = safeInstance.owners.length; + + address[] memory ownersToRemove = new address[](numOwners); + for (uint256 i; i < numOwners; i++) { + ownersToRemove[i] = safeInstance.owners[i]; + } + address[] memory prevOwners = safeInstance.getPrevOwners(ownersToRemove); + + _warpPastLivenessInterval(); + livenessModule.removeOwners(prevOwners, ownersToRemove); + assertEq(safeInstance.safe.getOwners().length, 1); + assertEq(safeInstance.safe.getOwners()[0], fallbackOwner); + assertEq(safeInstance.safe.getThreshold(), 1); + } +} + +/// @dev A copy of LivenessModule.get75PercentThreshold as a free function to use below. +function get75PercentThreshold(uint256 _numOwners) pure returns (uint256 threshold_) { + threshold_ = (_numOwners * 75 + 99) / 100; +} + +contract LivenessModule_RemoveOwnersFuzz_Test is LivenessModule_TestInit { + using SafeTestLib for SafeInstance; + + /// @dev We put this array in storage so that we can more easily populate it using push in the tests below. + address[] ownersToRemove; + + /// @dev Options for handling the event that the number of owners remaining is less than minOwners + enum ShutDownBehavior { + Correct, // Correctly removes the owners and transfers to the shutDown owner + DoesNotTransferToFallbackOwner, // Removes all but one owner, and does not transfer to the shutDown owner + DoesNotRemoveAllOwners // Leaves more than one owner when below minOwners + } + + /// @dev This contract inherits the storage layout from the LivenessModule_TestInit contract, but we + /// override the base setUp function, to avoid instantiating an unnecessary Safe and liveness checking system. + function setUp() public override { + vm.warp(initTime); + fallbackOwner = makeAddr("fallbackOwner"); + } + + /// @dev Extracts the setup of the test environment into a separate function. + function _prepare( + uint256 _numOwners, + uint256 _minOwners, + uint256 _numLiveOwners + ) + internal + returns (uint256 numOwners_, uint256 minOwners_, uint256 numLiveOwners_) + { + // First we modify the test parameters to ensure that they describe a plausible starting point. + // + // _numOwners must be at least 4, so that _minOwners can be set to at least 3 by the following bound() call. + // Limiting the owner set to 20 helps to keep the runtime of the test reasonable. + numOwners_ = bound(_numOwners, 4, 20); + // _minOwners must be at least 3, otherwise we don't have any range below _minOwners in which to test all of the + // ShutDownBehavior options. + minOwners_ = bound(_minOwners, 3, numOwners_ - 1); + + // Ensure that _numLiveOwners is less than _numOwners so that we can remove at least one owner. + numLiveOwners_ = bound(_numLiveOwners, 0, numOwners_ - 1); + + // The above bounds are a bit tricky, so we assert that the resulting parameters enable us to test all possible + // success and revert cases in the removeOwners function. + // This is also necessary to avoid underflows or out of bounds accesses in the test. + assertTrue( + numOwners_ > minOwners_ // We need to be able to remove at least one owner + && numOwners_ >= numLiveOwners_ // We can have more live owners than there are owners + && minOwners_ >= 3 // Allows us to test all of the ShutDownBehavior options when removing an owner + ); + + // Create a Safe with _numOwners owners + (, uint256[] memory keys) = SafeTestLib.makeAddrsAndKeys("rmOwnersTest", numOwners_); + uint256 threshold = get75PercentThreshold(numOwners_); + safeInstance = _setupSafe(keys, threshold); + livenessGuard = new LivenessGuard(safeInstance.safe); + livenessModule = new LivenessModule({ + _safe: safeInstance.safe, + _livenessGuard: livenessGuard, + _livenessInterval: livenessInterval, + _minOwners: minOwners_, + _fallbackOwner: fallbackOwner + }); + safeInstance.setGuard(address(livenessGuard)); + safeInstance.enableModule(address(livenessModule)); + + // Warp ahead so that all owners non-live + _warpPastLivenessInterval(); + } + + /// @dev Tests if removing owners works correctly for various safe configurations and numbeers of live owners + function testFuzz_removeOwners( + uint256 _numOwners, + uint256 _minOwners, + uint256 _numLiveOwners, + uint256 _shutDownBehavior, + uint256 _numOwnersToRemoveinShutDown + ) + external + { + // Prepare the test env and test params + (uint256 numOwners, uint256 minOwners, uint256 numLiveOwners) = _prepare(_numOwners, _minOwners, _numLiveOwners); + + // Create an array of live owners, and call showLiveness for each of them + address[] memory liveOwners = new address[](numLiveOwners); + for (uint256 i; i < numLiveOwners; i++) { + liveOwners[i] = safeInstance.owners[i]; + vm.prank(safeInstance.owners[i]); + livenessGuard.showLiveness(); + } + + address[] memory nonLiveOwners = new address[](numOwners - numLiveOwners); + for (uint256 i; i < numOwners - numLiveOwners; i++) { + nonLiveOwners[i] = safeInstance.owners[i + numLiveOwners]; + } + + address[] memory prevOwners; + if (numLiveOwners >= minOwners) { + // The safe will remain above the minimum number of owners, so we can remove only those owners which are not + // live. + prevOwners = safeInstance.getPrevOwners(nonLiveOwners); + livenessModule.removeOwners(prevOwners, nonLiveOwners); + + // Validate the resulting state of the Safe + assertEq(safeInstance.safe.getOwners().length, numLiveOwners); + assertEq(safeInstance.safe.getThreshold(), get75PercentThreshold(numLiveOwners)); + for (uint256 i; i < numLiveOwners; i++) { + assertTrue(safeInstance.safe.isOwner(liveOwners[i])); + } + for (uint256 i; i < nonLiveOwners.length; i++) { + assertFalse(safeInstance.safe.isOwner(nonLiveOwners[i])); + } + } else { + // The number of non-live owners will push the safe below the minimum number of owners. + // We need to test all of the possible ShutDownBehavior options, so we'll create a ShutDownBehavior enum + // from the _shutDownBehavior input. + ShutDownBehavior shutDownBehavior = + ShutDownBehavior(bound(_shutDownBehavior, 0, uint256(type(ShutDownBehavior).max))); + // The safe is below the minimum number of owners. + // The ShutDownBehavior enum determines how we handle this case. + if (shutDownBehavior == ShutDownBehavior.Correct) { + // We remove all owners, and transfer ownership to the shutDown owner. + // but we need to do remove the non-live owners first, so we reverse the owners array, since + // the first owners in the array were the ones to call showLiveness. + for (uint256 i; i < numOwners; i++) { + ownersToRemove.push(safeInstance.owners[numOwners - i - 1]); + } + prevOwners = safeInstance.getPrevOwners(ownersToRemove); + livenessModule.removeOwners(prevOwners, ownersToRemove); + + // Validate the resulting state of the Safe + assertEq(safeInstance.safe.getOwners().length, 1); + assertEq(safeInstance.safe.getOwners()[0], fallbackOwner); + assertEq(safeInstance.safe.getThreshold(), 1); + } else { + // For both of the incorrect behaviors, we need to calculate the number of owners to remove to + // trigger that behavior. We initialize that value here then set it in the if statements below. + uint256 numOwnersToRemoveinShutDown; + if (shutDownBehavior == ShutDownBehavior.DoesNotRemoveAllOwners) { + // In the DoesNotRemoveAllOwners case, we should have more than 1 of the pre-existing owners + // remaining + numOwnersToRemoveinShutDown = + bound(_numOwnersToRemoveinShutDown, numOwners - minOwners + 1, numOwners - 2); + for (uint256 i; i < numOwnersToRemoveinShutDown; i++) { + // Add non-live owners to remove first + if (i < nonLiveOwners.length) { + ownersToRemove.push(nonLiveOwners[i]); + } else { + // Then add live owners to remove + ownersToRemove.push(liveOwners[i - nonLiveOwners.length]); + } + } + prevOwners = safeInstance.getPrevOwners(ownersToRemove); + vm.expectRevert( + "LivenessModule: must remove all owners and transfer to fallback owner if numOwners < minOwners" + ); + livenessModule.removeOwners(prevOwners, ownersToRemove); + } else if (shutDownBehavior == ShutDownBehavior.DoesNotTransferToFallbackOwner) { + // In the DoesNotRemoveAllOwners case, we should have exactly 1 pre-existing owners remaining + numOwnersToRemoveinShutDown = numOwners - 1; + for (uint256 i; i < numOwnersToRemoveinShutDown; i++) { + // Add non-live owners to remove first + if (i < nonLiveOwners.length) { + ownersToRemove.push(nonLiveOwners[i]); + } else { + // Then add live owners to remove + ownersToRemove.push(liveOwners[i - nonLiveOwners.length]); + } + } + prevOwners = safeInstance.getPrevOwners(ownersToRemove); + vm.expectRevert("LivenessModule: must transfer ownership to fallback owner"); + livenessModule.removeOwners(prevOwners, ownersToRemove); + } + // For both of the incorrect behaviors, verify no change to the Safe state + assertEq(safeInstance.safe.getOwners().length, numOwners); + assertEq(safeInstance.safe.getThreshold(), get75PercentThreshold(numOwners)); + for (uint256 i; i < numOwners; i++) { + assertTrue(safeInstance.safe.isOwner(safeInstance.owners[i])); + } + } + } + } +} diff --git a/packages/contracts-bedrock/test/MIPS.t.sol b/packages/contracts-bedrock/test/MIPS.t.sol index 76013d14a32c5..f34b453e9c8c7 100644 --- a/packages/contracts-bedrock/test/MIPS.t.sol +++ b/packages/contracts-bedrock/test/MIPS.t.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity 0.8.15; -import { CommonTest } from "./CommonTest.t.sol"; +import { CommonTest } from "test/setup/CommonTest.sol"; import { MIPS } from "src/cannon/MIPS.sol"; import { PreimageOracle } from "src/cannon/PreimageOracle.sol"; import "src/libraries/DisputeTypes.sol"; @@ -39,7 +39,7 @@ contract MIPS_Test is CommonTest { bytes memory proof = hex"3c10bfff3610fff0341100013c08ffff3508fffd34090003010950202d420001ae020008ae11000403e000080000000000000000000000000000000000000000ad3228b676f7d3cd4284a5443f17f1962b36e491b30a40b2405849e597ba5fb5b4c11951957c6f8f642c4af61cd6b24640fec6dc7fc607ee8206a99e92410d3021ddb9a356815c3fac1026b6dec5df3124afbadb485c9ba5a3e3398a04b7ba85e58769b32a1beaf1ea27375a44095a0d1fb664ce2dd358e7fcbfb78c26a193440eb01ebfc9ed27500cd4dfc979272d1f0913cc9f66540d7e8005811109e1cf2d887c22bd8750d34016ac3c66b5ff102dacdd73f6b014e710b51e8022af9a1968ffd70157e48063fc33c97a050f7f640233bf646cc98d9524c6b92bcf3ab56f839867cc5f7f196b93bae1e27e6320742445d290f2263827498b54fec539f756afcefad4e508c098b9a7e1d8feb19955fb02ba9675585078710969d3440f5054e0f9dc3e7fe016e050eff260334f18a5d4fe391d82092319f5964f2e2eb7c1c3a5f8b13a49e282f609c317a833fb8d976d11517c571d1221a265d25af778ecf8923490c6ceeb450aecdc82e28293031d10c7d73bf85e57bf041a97360aa2c5d99cc1df82d9c4b87413eae2ef048f94b4d3554cea73d92b0f7af96e0271c691e2bb5c67add7c6caf302256adedf7ab114da0acfe870d449a3a489f781d659e8beccda7bce9f4e8618b6bd2f4132ce798cdc7a60e7e1460a7299e3c6342a579626d22733e50f526ec2fa19a22b31e8ed50f23cd1fdf94c9154ed3a7609a2f1ff981fe1d3b5c807b281e4683cc6d6315cf95b9ade8641defcb32372f1c126e398ef7a5a2dce0a8a7f68bb74560f8f71837c2c2ebbcbf7fffb42ae1896f13f7c7479a0b46a28b6f55540f89444f63de0378e3d121be09e06cc9ded1c20e65876d36aa0c65e9645644786b620e2dd2ad648ddfcbf4a7e5b1a3a4ecfe7f64667a3f0b7e2f4418588ed35a2458cffeb39b93d26f18d2ab13bdce6aee58e7b99359ec2dfd95a9c16dc00d6ef18b7933a6f8dc65ccb55667138776f7dea101070dc8796e3774df84f40ae0c8229d0d6069e5c8f39a7c299677a09d367fc7b05e3bc380ee652cdc72595f74c7b1043d0e1ffbab734648c838dfb0527d971b602bc216c9619ef0abf5ac974a1ed57f4050aa510dd9c74f508277b39d7973bb2dfccc5eeb0618db8cd74046ff337f0a7bf2c8e03e10f642c1886798d71806ab1e888d9e5ee87d00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000"; - bytes32 postState = mips.step(encodeState(state), proof); + bytes32 postState = mips.step(encodeState(state), proof, 0); assertNotEq(postState, bytes32(0)); } @@ -59,7 +59,7 @@ contract MIPS_Test is CommonTest { expect.registers[17] = state.registers[17]; expect.registers[18] = state.registers[18]; - bytes32 postState = mips.step(encodedState, proof); + bytes32 postState = mips.step(encodedState, proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -79,7 +79,7 @@ contract MIPS_Test is CommonTest { expect.registers[17] = state.registers[17]; expect.registers[18] = state.registers[18]; - bytes32 postState = mips.step(encodedState, proof); + bytes32 postState = mips.step(encodedState, proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -99,7 +99,7 @@ contract MIPS_Test is CommonTest { expect.registers[8] = state.registers[17] + imm; expect.registers[17] = state.registers[17]; - bytes32 postState = mips.step(encodedState, proof); + bytes32 postState = mips.step(encodedState, proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -119,7 +119,7 @@ contract MIPS_Test is CommonTest { expect.registers[8] = 0; expect.registers[17] = state.registers[17]; - bytes32 postState = mips.step(encodedState, proof); + bytes32 postState = mips.step(encodedState, proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -139,7 +139,7 @@ contract MIPS_Test is CommonTest { expect.registers[8] = state.registers[17] + imm; expect.registers[17] = state.registers[17]; - bytes32 postState = mips.step(encodedState, proof); + bytes32 postState = mips.step(encodedState, proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -159,7 +159,7 @@ contract MIPS_Test is CommonTest { expect.registers[17] = state.registers[17]; expect.registers[18] = state.registers[18]; - bytes32 postState = mips.step(encodedState, proof); + bytes32 postState = mips.step(encodedState, proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -179,7 +179,7 @@ contract MIPS_Test is CommonTest { expect.registers[17] = state.registers[17]; expect.registers[18] = state.registers[18]; - bytes32 postState = mips.step(encodedState, proof); + bytes32 postState = mips.step(encodedState, proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -199,7 +199,7 @@ contract MIPS_Test is CommonTest { expect.registers[17] = state.registers[17]; expect.registers[18] = state.registers[18]; - bytes32 postState = mips.step(encodedState, proof); + bytes32 postState = mips.step(encodedState, proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -219,7 +219,7 @@ contract MIPS_Test is CommonTest { expect.registers[8] = state.registers[17] & imm; expect.registers[17] = state.registers[17]; - bytes32 postState = mips.step(encodedState, proof); + bytes32 postState = mips.step(encodedState, proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -239,7 +239,7 @@ contract MIPS_Test is CommonTest { expect.registers[17] = state.registers[17]; expect.registers[18] = state.registers[18]; - bytes32 postState = mips.step(encodedState, proof); + bytes32 postState = mips.step(encodedState, proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -259,7 +259,7 @@ contract MIPS_Test is CommonTest { expect.registers[8] = state.registers[17] | imm; expect.registers[17] = state.registers[17]; - bytes32 postState = mips.step(encodedState, proof); + bytes32 postState = mips.step(encodedState, proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -279,7 +279,7 @@ contract MIPS_Test is CommonTest { expect.registers[17] = state.registers[17]; expect.registers[18] = state.registers[18]; - bytes32 postState = mips.step(encodedState, proof); + bytes32 postState = mips.step(encodedState, proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -299,7 +299,7 @@ contract MIPS_Test is CommonTest { expect.registers[8] = state.registers[17] ^ imm; expect.registers[17] = state.registers[17]; - bytes32 postState = mips.step(encodedState, proof); + bytes32 postState = mips.step(encodedState, proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -319,7 +319,7 @@ contract MIPS_Test is CommonTest { expect.registers[17] = state.registers[17]; expect.registers[18] = state.registers[18]; - bytes32 postState = mips.step(encodedState, proof); + bytes32 postState = mips.step(encodedState, proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -338,7 +338,7 @@ contract MIPS_Test is CommonTest { expect.registers[17] = state.registers[17]; expect.registers[18] = state.registers[18]; - bytes32 postState = mips.step(encodeState(state), proof); + bytes32 postState = mips.step(encodeState(state), proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); // swap and check again @@ -348,7 +348,7 @@ contract MIPS_Test is CommonTest { expect.registers[17] = state.registers[17]; expect.registers[18] = state.registers[18]; expect.registers[8] = 0; // t0 - postState = mips.step(encodeState(state), proof); + postState = mips.step(encodeState(state), proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -368,7 +368,7 @@ contract MIPS_Test is CommonTest { expect.registers[17] = state.registers[17]; expect.registers[18] = state.registers[18]; - bytes32 postState = mips.step(encodedState, proof); + bytes32 postState = mips.step(encodedState, proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -388,7 +388,7 @@ contract MIPS_Test is CommonTest { expect.registers[8] = 0x12; // t0 expect.registers[9] = t1; - bytes32 postState = mips.step(encodedState, proof); + bytes32 postState = mips.step(encodedState, proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -410,7 +410,7 @@ contract MIPS_Test is CommonTest { expect.registers[8] = 0x12_23; // t0 expect.registers[9] = t1; - bytes32 postState = mips.step(encodedState, proof); + bytes32 postState = mips.step(encodedState, proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -432,7 +432,7 @@ contract MIPS_Test is CommonTest { expect.registers[8] = val; // t0 expect.registers[9] = t1; - bytes32 postState = mips.step(encodedState, proof); + bytes32 postState = mips.step(encodedState, proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -452,7 +452,7 @@ contract MIPS_Test is CommonTest { expect.registers[8] = 0x12; // t0 expect.registers[9] = t1; - bytes32 postState = mips.step(encodedState, proof); + bytes32 postState = mips.step(encodedState, proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -472,7 +472,7 @@ contract MIPS_Test is CommonTest { expect.registers[8] = 0x12_23; // t0 expect.registers[9] = t1; - bytes32 postState = mips.step(encodedState, proof); + bytes32 postState = mips.step(encodedState, proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -491,7 +491,7 @@ contract MIPS_Test is CommonTest { expect.registers[8] = 0x12_34_56_78; // t0 expect.registers[9] = t1; - bytes32 postState = mips.step(encodeState(state), proof); + bytes32 postState = mips.step(encodeState(state), proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); // test unaligned address @@ -499,7 +499,7 @@ contract MIPS_Test is CommonTest { (state.memRoot, proof) = ffi.getCannonMemoryProof(0, insn, t1 + 4, 0x12_34_56_78); expect.memRoot = state.memRoot; expect.registers[8] = 0x34_56_78_dd; // t0 - postState = mips.step(encodeState(state), proof); + postState = mips.step(encodeState(state), proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -518,7 +518,7 @@ contract MIPS_Test is CommonTest { expect.registers[8] = 0xaa_bb_cc_12; // t0 expect.registers[9] = t1; - bytes32 postState = mips.step(encodeState(state), proof); + bytes32 postState = mips.step(encodeState(state), proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); // test unaligned address @@ -526,7 +526,7 @@ contract MIPS_Test is CommonTest { (state.memRoot, proof) = ffi.getCannonMemoryProof(0, insn, t1 + 4, 0x12_34_56_78); expect.memRoot = state.memRoot; expect.registers[8] = 0xaa_bb_12_34; // t0 - postState = mips.step(encodeState(state), proof); + postState = mips.step(encodeState(state), proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -546,7 +546,7 @@ contract MIPS_Test is CommonTest { expect.registers[8] = state.registers[8]; expect.registers[9] = state.registers[9]; - bytes32 postState = mips.step(encodeState(state), proof); + bytes32 postState = mips.step(encodeState(state), proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -565,7 +565,7 @@ contract MIPS_Test is CommonTest { expect.registers[8] = state.registers[8]; expect.registers[9] = state.registers[9]; - bytes32 postState = mips.step(encodeState(state), proof); + bytes32 postState = mips.step(encodeState(state), proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -584,7 +584,7 @@ contract MIPS_Test is CommonTest { expect.registers[8] = state.registers[8]; expect.registers[9] = state.registers[9]; - bytes32 postState = mips.step(encodeState(state), proof); + bytes32 postState = mips.step(encodeState(state), proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -603,7 +603,7 @@ contract MIPS_Test is CommonTest { expect.registers[8] = state.registers[8]; expect.registers[9] = state.registers[9]; - bytes32 postState = mips.step(encodeState(state), proof); + bytes32 postState = mips.step(encodeState(state), proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -622,7 +622,7 @@ contract MIPS_Test is CommonTest { expect.registers[8] = state.registers[8]; expect.registers[9] = state.registers[9]; - bytes32 postState = mips.step(encodeState(state), proof); + bytes32 postState = mips.step(encodeState(state), proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -644,7 +644,7 @@ contract MIPS_Test is CommonTest { expect.registers[8] = val; // t0 expect.registers[9] = t1; - bytes32 postState = mips.step(encodedState, proof); + bytes32 postState = mips.step(encodedState, proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -663,7 +663,7 @@ contract MIPS_Test is CommonTest { expect.registers[8] = 0x1; expect.registers[9] = state.registers[9]; - bytes32 postState = mips.step(encodeState(state), proof); + bytes32 postState = mips.step(encodeState(state), proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -684,13 +684,13 @@ contract MIPS_Test is CommonTest { expect.registers[9] = state.registers[9]; expect.registers[10] = state.registers[10]; - bytes32 postState = mips.step(encodeState(state), proof); + bytes32 postState = mips.step(encodeState(state), proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); state.registers[10] = 0x0; // t2 expect.registers[10] = 0x0; // t2 expect.registers[8] = state.registers[8]; - postState = mips.step(encodeState(state), proof); + postState = mips.step(encodeState(state), proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -711,13 +711,13 @@ contract MIPS_Test is CommonTest { expect.registers[9] = state.registers[9]; expect.registers[10] = state.registers[10]; - bytes32 postState = mips.step(encodeState(state), proof); + bytes32 postState = mips.step(encodeState(state), proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); state.registers[10] = 0x1; // t2 expect.registers[10] = 0x1; // t2 expect.registers[8] = state.registers[8]; - postState = mips.step(encodeState(state), proof); + postState = mips.step(encodeState(state), proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -734,7 +734,7 @@ contract MIPS_Test is CommonTest { expect.lo = state.lo; expect.registers[8] = state.lo; - bytes32 postState = mips.step(encodeState(state), proof); + bytes32 postState = mips.step(encodeState(state), proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -751,7 +751,7 @@ contract MIPS_Test is CommonTest { expect.hi = state.hi; expect.registers[8] = state.hi; - bytes32 postState = mips.step(encodeState(state), proof); + bytes32 postState = mips.step(encodeState(state), proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -768,7 +768,7 @@ contract MIPS_Test is CommonTest { expect.hi = state.registers[8]; expect.registers[8] = state.registers[8]; - bytes32 postState = mips.step(encodeState(state), proof); + bytes32 postState = mips.step(encodeState(state), proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -785,7 +785,7 @@ contract MIPS_Test is CommonTest { expect.lo = state.registers[8]; expect.registers[8] = state.registers[8]; - bytes32 postState = mips.step(encodeState(state), proof); + bytes32 postState = mips.step(encodeState(state), proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -804,7 +804,7 @@ contract MIPS_Test is CommonTest { expect.registers[9] = 5; expect.registers[10] = 2; - bytes32 postState = mips.step(encodeState(state), proof); + bytes32 postState = mips.step(encodeState(state), proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -825,7 +825,7 @@ contract MIPS_Test is CommonTest { expect.hi = 0x6; bytes memory enc = encodeState(state); - bytes32 postState = mips.step(enc, proof); + bytes32 postState = mips.step(enc, proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -846,7 +846,7 @@ contract MIPS_Test is CommonTest { expect.hi = 0x6; bytes memory enc = encodeState(state); - bytes32 postState = mips.step(enc, proof); + bytes32 postState = mips.step(enc, proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -867,7 +867,7 @@ contract MIPS_Test is CommonTest { expect.hi = 1; bytes memory enc = encodeState(state); - bytes32 postState = mips.step(enc, proof); + bytes32 postState = mips.step(enc, proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -888,7 +888,7 @@ contract MIPS_Test is CommonTest { expect.hi = 1; bytes memory enc = encodeState(state); - bytes32 postState = mips.step(enc, proof); + bytes32 postState = mips.step(enc, proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -907,14 +907,14 @@ contract MIPS_Test is CommonTest { expect.registers[8] = 0xdeadbeef; expect.registers[9] = 0xdeadbeef; - bytes32 postState = mips.step(encodeState(state), proof); + bytes32 postState = mips.step(encodeState(state), proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); // branch not taken state.registers[8] = 0xaa; expect.registers[8] = 0xaa; expect.nextPC = state.nextPC + 4; - postState = mips.step(encodeState(state), proof); + postState = mips.step(encodeState(state), proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -933,7 +933,7 @@ contract MIPS_Test is CommonTest { expect.registers[8] = 0xdeadbeef; expect.registers[9] = 0xaa; - bytes32 postState = mips.step(encodeState(state), proof); + bytes32 postState = mips.step(encodeState(state), proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -950,7 +950,7 @@ contract MIPS_Test is CommonTest { expect.step = state.step + 1; expect.registers[8] = 0; - bytes32 postState = mips.step(encodeState(state), proof); + bytes32 postState = mips.step(encodeState(state), proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -968,7 +968,7 @@ contract MIPS_Test is CommonTest { expect.registers[8] = 1; bytes memory enc = encodeState(state); - bytes32 postState = mips.step(enc, proof); + bytes32 postState = mips.step(enc, proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -985,7 +985,7 @@ contract MIPS_Test is CommonTest { expect.step = state.step + 1; expect.registers[8] = 0xF0_00_00_00; - bytes32 postState = mips.step(encodeState(state), proof); + bytes32 postState = mips.step(encodeState(state), proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -1002,7 +1002,7 @@ contract MIPS_Test is CommonTest { expect.step = state.step + 1; expect.registers[8] = 0x00_00_00_01; - bytes32 postState = mips.step(encodeState(state), proof); + bytes32 postState = mips.step(encodeState(state), proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -1017,7 +1017,7 @@ contract MIPS_Test is CommonTest { expect.nextPC = label << 2; expect.step = state.step + 1; - bytes32 postState = mips.step(encodeState(state), proof); + bytes32 postState = mips.step(encodeState(state), proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -1034,7 +1034,7 @@ contract MIPS_Test is CommonTest { expect.step = state.step + 1; bytes memory witness = encodeState(state); - bytes32 postState = mips.step(witness, proof); + bytes32 postState = mips.step(witness, proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -1050,7 +1050,7 @@ contract MIPS_Test is CommonTest { expect.step = state.step + 1; expect.registers[31] = state.pc + 8; // ra - bytes32 postState = mips.step(encodeState(state), proof); + bytes32 postState = mips.step(encodeState(state), proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -1067,7 +1067,7 @@ contract MIPS_Test is CommonTest { expect.step = state.step + 1; expect.registers[31] = state.pc + 8; // ra - bytes32 postState = mips.step(encodeState(state), proof); + bytes32 postState = mips.step(encodeState(state), proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -1084,7 +1084,7 @@ contract MIPS_Test is CommonTest { expect.step = state.step + 1; expect.registers[8] = tgt; - bytes32 postState = mips.step(encodeState(state), proof); + bytes32 postState = mips.step(encodeState(state), proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -1102,7 +1102,7 @@ contract MIPS_Test is CommonTest { expect.registers[8] = tgt; expect.registers[9] = state.pc + 8; // t1 - bytes32 postState = mips.step(encodeState(state), proof); + bytes32 postState = mips.step(encodeState(state), proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -1121,7 +1121,7 @@ contract MIPS_Test is CommonTest { expect.registers[9] = state.registers[9]; bytes memory enc = encodeState(state); - bytes32 postState = mips.step(enc, proof); + bytes32 postState = mips.step(enc, proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -1140,7 +1140,7 @@ contract MIPS_Test is CommonTest { expect.registers[9] = state.registers[9]; bytes memory enc = encodeState(state); - bytes32 postState = mips.step(enc, proof); + bytes32 postState = mips.step(enc, proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -1159,7 +1159,7 @@ contract MIPS_Test is CommonTest { expect.registers[9] = state.registers[9]; bytes memory enc = encodeState(state); - bytes32 postState = mips.step(enc, proof); + bytes32 postState = mips.step(enc, proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -1179,7 +1179,7 @@ contract MIPS_Test is CommonTest { expect.registers[10] = state.registers[10]; bytes memory enc = encodeState(state); - bytes32 postState = mips.step(enc, proof); + bytes32 postState = mips.step(enc, proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -1199,7 +1199,7 @@ contract MIPS_Test is CommonTest { expect.registers[10] = state.registers[10]; bytes memory enc = encodeState(state); - bytes32 postState = mips.step(enc, proof); + bytes32 postState = mips.step(enc, proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -1219,7 +1219,7 @@ contract MIPS_Test is CommonTest { expect.registers[10] = state.registers[10]; bytes memory enc = encodeState(state); - bytes32 postState = mips.step(enc, proof); + bytes32 postState = mips.step(enc, proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -1235,7 +1235,7 @@ contract MIPS_Test is CommonTest { expect.step = state.step + 1; expect.registers[8] = 0x00_04_00_00; // t0 - bytes32 postState = mips.step(encodedState, proof); + bytes32 postState = mips.step(encodedState, proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -1252,7 +1252,7 @@ contract MIPS_Test is CommonTest { expect.registers[8] = 8; // t0 expect.registers[9] = state.registers[9]; - bytes32 postState = mips.step(encodeState(state), proof); + bytes32 postState = mips.step(encodeState(state), proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -1269,7 +1269,7 @@ contract MIPS_Test is CommonTest { expect.registers[8] = 16; // t0 expect.registers[9] = state.registers[9]; - bytes32 postState = mips.step(encodeState(state), proof); + bytes32 postState = mips.step(encodeState(state), proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -1306,7 +1306,7 @@ contract MIPS_Test is CommonTest { bytes32 word = bytes32(uint256(0xdeadbeef) << 224); uint8 size = 4; uint8 partOffset = 8; - oracle.loadLocalData(uint256(state.preimageKey), word, size, partOffset); + oracle.loadLocalData(uint256(state.preimageKey), 0, word, size, partOffset); MIPS.State memory expect = state; expect.preimageOffset += 4; @@ -1318,7 +1318,7 @@ contract MIPS_Test is CommonTest { // recompute merkle root of written pre-image (expect.memRoot,) = ffi.getCannonMemoryProof(pc, insn, a1, 0xdeadbeef); - bytes32 postState = mips.step(encodedState, proof); + bytes32 postState = mips.step(encodedState, proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -1360,7 +1360,7 @@ contract MIPS_Test is CommonTest { expect.registers[2] = 4; // return expect.registers[7] = 0; // errno - bytes32 postState = mips.step(encodedState, proof); + bytes32 postState = mips.step(encodedState, proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -1387,7 +1387,7 @@ contract MIPS_Test is CommonTest { expect.registers[4] = 0x0; // a0 expect.registers[5] = 4095; // a1 - bytes32 postState = mips.step(encodedState, proof); + bytes32 postState = mips.step(encodedState, proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -1406,7 +1406,7 @@ contract MIPS_Test is CommonTest { expect.registers[2] = 0x40000000; expect.registers[4] = state.registers[4]; // registers unchanged - bytes32 postState = mips.step(encodedState, proof); + bytes32 postState = mips.step(encodedState, proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -1423,7 +1423,7 @@ contract MIPS_Test is CommonTest { expect.registers[2] = 1; bytes memory enc = encodeState(state); - bytes32 postState = mips.step(enc, proof); + bytes32 postState = mips.step(enc, proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -1443,7 +1443,7 @@ contract MIPS_Test is CommonTest { expect.exited = true; expect.exitCode = uint8(state.registers[4]); - bytes32 postState = mips.step(encodeState(state), proof); + bytes32 postState = mips.step(encodeState(state), proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -1462,14 +1462,14 @@ contract MIPS_Test is CommonTest { expect.registers[2] = 0; expect.registers[5] = state.registers[5]; - bytes32 postState = mips.step(encodeState(state), proof); + bytes32 postState = mips.step(encodeState(state), proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); // assert O_WRONLY state.registers[4] = 0x1; // a0 expect.registers[4] = state.registers[4]; expect.registers[2] = 1; - postState = mips.step(encodeState(state), proof); + postState = mips.step(encodeState(state), proof, 0); assertEq(postState, outputState(expect), "unexpected post state"); } @@ -1479,7 +1479,7 @@ contract MIPS_Test is CommonTest { state.exited = true; bytes memory enc = encodeState(state); - bytes32 postState = mips.step(enc, proof); + bytes32 postState = mips.step(enc, proof, 0); assertEq(postState, outputState(state), "unexpected post state"); } @@ -1494,7 +1494,7 @@ contract MIPS_Test is CommonTest { state.memRoot = memRoot; bytes memory encodedState = encodeState(state); vm.expectRevert("invalid instruction"); - mips.step(encodedState, proof); + mips.step(encodedState, proof, 0); } function test_invalid_root_fails() external { @@ -1508,7 +1508,7 @@ contract MIPS_Test is CommonTest { proof[i] = 0x0; } vm.expectRevert(hex"000000000000000000000000000000000000000000000000000000000badf00d"); - mips.step(encodeState(state), proof); + mips.step(encodeState(state), proof, 0); } function test_jump_inDelaySlot_fails() external { @@ -1518,7 +1518,7 @@ contract MIPS_Test is CommonTest { state.nextPC = 0xa; vm.expectRevert("jump in delay slot"); - mips.step(encodeState(state), proof); + mips.step(encodeState(state), proof, 0); } function test_branch_inDelaySlot_fails() external { @@ -1530,7 +1530,7 @@ contract MIPS_Test is CommonTest { state.nextPC = 0xa; vm.expectRevert("branch in delay slot"); - mips.step(encodeState(state), proof); + mips.step(encodeState(state), proof, 0); } function encodeState(MIPS.State memory state) internal pure returns (bytes memory) { diff --git a/packages/contracts-bedrock/test/MerkleTrie.t.sol b/packages/contracts-bedrock/test/MerkleTrie.t.sol index f6c559bc46443..1727940eff7c6 100644 --- a/packages/contracts-bedrock/test/MerkleTrie.t.sol +++ b/packages/contracts-bedrock/test/MerkleTrie.t.sol @@ -1,10 +1,17 @@ // SPDX-License-Identifier: MIT pragma solidity 0.8.15; -import { CommonTest } from "./CommonTest.t.sol"; -import { MerkleTrie } from "../src/libraries/trie/MerkleTrie.sol"; +import { Test } from "forge-std/Test.sol"; +import { MerkleTrie } from "src/libraries/trie/MerkleTrie.sol"; +import { FFIInterface } from "test/setup/FFIInterface.sol"; + +contract MerkleTrie_get_Test is Test { + FFIInterface ffi; + + function setUp() public { + ffi = new FFIInterface(); + } -contract MerkleTrie_get_Test is CommonTest { function test_get_validProof1_succeeds() external { bytes32 root = 0xd582f99275e227a1cf4284899e5ff06ee56da8859be71b553397c69151bc942f; bytes memory key = hex"6b6579326262"; diff --git a/packages/contracts-bedrock/test/MintManager.t.sol b/packages/contracts-bedrock/test/MintManager.t.sol index 66578642294fd..00cc791b98c24 100644 --- a/packages/contracts-bedrock/test/MintManager.t.sol +++ b/packages/contracts-bedrock/test/MintManager.t.sol @@ -2,13 +2,13 @@ pragma solidity 0.8.15; // Testing utilities -import { CommonTest } from "./CommonTest.t.sol"; +import { CommonTest } from "test/setup/CommonTest.sol"; // Target contract dependencies -import { GovernanceToken } from "../src/governance/GovernanceToken.sol"; +import { GovernanceToken } from "src/governance/GovernanceToken.sol"; // Target contract -import { MintManager } from "../src/governance/MintManager.sol"; +import { MintManager } from "src/governance/MintManager.sol"; contract MintManager_Initializer is CommonTest { address constant owner = address(0x1234); diff --git a/packages/contracts-bedrock/test/OptimismMintableERC20.t.sol b/packages/contracts-bedrock/test/OptimismMintableERC20.t.sol index ef6c5468b703a..6bb332473ecda 100644 --- a/packages/contracts-bedrock/test/OptimismMintableERC20.t.sol +++ b/packages/contracts-bedrock/test/OptimismMintableERC20.t.sol @@ -1,8 +1,8 @@ // SPDX-License-Identifier: MIT pragma solidity 0.8.15; -import { Bridge_Initializer } from "./CommonTest.t.sol"; -import { ILegacyMintableERC20, IOptimismMintableERC20 } from "../src/universal/IOptimismMintableERC20.sol"; +import { Bridge_Initializer } from "test/setup/Bridge_Initializer.sol"; +import { ILegacyMintableERC20, IOptimismMintableERC20 } from "src/universal/IOptimismMintableERC20.sol"; import { IERC165 } from "@openzeppelin/contracts/utils/introspection/IERC165.sol"; contract OptimismMintableERC20_Test is Bridge_Initializer { @@ -14,7 +14,7 @@ contract OptimismMintableERC20_Test is Bridge_Initializer { } function test_bridge_succeeds() external { - assertEq(L2Token.bridge(), address(L2Bridge)); + assertEq(L2Token.bridge(), address(l2StandardBridge)); } function test_l1Token_succeeds() external { @@ -22,7 +22,7 @@ contract OptimismMintableERC20_Test is Bridge_Initializer { } function test_l2Bridge_succeeds() external { - assertEq(L2Token.l2Bridge(), address(L2Bridge)); + assertEq(L2Token.l2Bridge(), address(l2StandardBridge)); } function test_legacy_succeeds() external { @@ -31,16 +31,16 @@ contract OptimismMintableERC20_Test is Bridge_Initializer { assertEq(L2Token.remoteToken(), address(L1Token)); assertEq(L2Token.l1Token(), address(L1Token)); // Getters for the bridge - assertEq(L2Token.BRIDGE(), address(L2Bridge)); - assertEq(L2Token.bridge(), address(L2Bridge)); - assertEq(L2Token.l2Bridge(), address(L2Bridge)); + assertEq(L2Token.BRIDGE(), address(l2StandardBridge)); + assertEq(L2Token.bridge(), address(l2StandardBridge)); + assertEq(L2Token.l2Bridge(), address(l2StandardBridge)); } function test_mint_succeeds() external { vm.expectEmit(true, true, true, true); emit Mint(alice, 100); - vm.prank(address(L2Bridge)); + vm.prank(address(l2StandardBridge)); L2Token.mint(alice, 100); assertEq(L2Token.balanceOf(alice), 100); @@ -54,13 +54,13 @@ contract OptimismMintableERC20_Test is Bridge_Initializer { } function test_burn_succeeds() external { - vm.prank(address(L2Bridge)); + vm.prank(address(l2StandardBridge)); L2Token.mint(alice, 100); vm.expectEmit(true, true, true, true); emit Burn(alice, 100); - vm.prank(address(L2Bridge)); + vm.prank(address(l2StandardBridge)); L2Token.burn(alice, 100); assertEq(L2Token.balanceOf(alice), 0); diff --git a/packages/contracts-bedrock/test/OptimismMintableERC20Factory.t.sol b/packages/contracts-bedrock/test/OptimismMintableERC20Factory.t.sol index 64b0a7de5b980..c856e721f825c 100644 --- a/packages/contracts-bedrock/test/OptimismMintableERC20Factory.t.sol +++ b/packages/contracts-bedrock/test/OptimismMintableERC20Factory.t.sol @@ -1,19 +1,15 @@ // SPDX-License-Identifier: MIT pragma solidity 0.8.15; -import { OptimismMintableERC20 } from "../src/universal/OptimismMintableERC20.sol"; -import { Bridge_Initializer } from "./CommonTest.t.sol"; +import { OptimismMintableERC20 } from "src/universal/OptimismMintableERC20.sol"; +import { Bridge_Initializer } from "test/setup/Bridge_Initializer.sol"; contract OptimismMintableTokenFactory_Test is Bridge_Initializer { event StandardL2TokenCreated(address indexed remoteToken, address indexed localToken); event OptimismMintableERC20Created(address indexed localToken, address indexed remoteToken, address deployer); - function setUp() public override { - super.setUp(); - } - function test_bridge_succeeds() external { - assertEq(address(L2TokenFactory.BRIDGE()), address(L2Bridge)); + assertEq(address(l2OptimismMintableERC20Factory.BRIDGE()), address(l2StandardBridge)); } function test_createStandardL2Token_succeeds() external { @@ -29,7 +25,7 @@ contract OptimismMintableTokenFactory_Test is Bridge_Initializer { emit OptimismMintableERC20Created(local, remote, alice); vm.prank(alice); - address addr = L2TokenFactory.createStandardL2Token(remote, "Beep", "BOOP"); + address addr = l2OptimismMintableERC20Factory.createStandardL2Token(remote, "Beep", "BOOP"); assertTrue(addr == local); assertTrue(OptimismMintableERC20(local).decimals() == 18); } @@ -45,7 +41,7 @@ contract OptimismMintableTokenFactory_Test is Bridge_Initializer { emit OptimismMintableERC20Created(local, remote, alice); vm.prank(alice); - address addr = L2TokenFactory.createOptimismMintableERC20WithDecimals(remote, "Beep", "BOOP", 6); + address addr = l2OptimismMintableERC20Factory.createOptimismMintableERC20WithDecimals(remote, "Beep", "BOOP", 6); assertTrue(addr == local); assertTrue(OptimismMintableERC20(local).decimals() == 6); @@ -55,18 +51,18 @@ contract OptimismMintableTokenFactory_Test is Bridge_Initializer { address remote = address(4); vm.prank(alice); - L2TokenFactory.createStandardL2Token(remote, "Beep", "BOOP"); + l2OptimismMintableERC20Factory.createStandardL2Token(remote, "Beep", "BOOP"); vm.expectRevert(); vm.prank(alice); - L2TokenFactory.createStandardL2Token(remote, "Beep", "BOOP"); + l2OptimismMintableERC20Factory.createStandardL2Token(remote, "Beep", "BOOP"); } function test_createStandardL2Token_remoteIsZero_reverts() external { address remote = address(0); vm.expectRevert("OptimismMintableERC20Factory: must provide remote token address"); - L2TokenFactory.createStandardL2Token(remote, "Beep", "BOOP"); + l2OptimismMintableERC20Factory.createStandardL2Token(remote, "Beep", "BOOP"); } function calculateTokenAddress( @@ -79,10 +75,12 @@ contract OptimismMintableTokenFactory_Test is Bridge_Initializer { view returns (address) { - bytes memory constructorArgs = abi.encode(address(L2Bridge), _remote, _name, _symbol, _decimals); + bytes memory constructorArgs = abi.encode(address(l2StandardBridge), _remote, _name, _symbol, _decimals); bytes memory bytecode = abi.encodePacked(type(OptimismMintableERC20).creationCode, constructorArgs); bytes32 salt = keccak256(abi.encode(_remote, _name, _symbol, _decimals)); - bytes32 hash = keccak256(abi.encodePacked(bytes1(0xff), address(L2TokenFactory), salt, keccak256(bytecode))); + bytes32 hash = keccak256( + abi.encodePacked(bytes1(0xff), address(l2OptimismMintableERC20Factory), salt, keccak256(bytecode)) + ); return address(uint160(uint256(hash))); } } diff --git a/packages/contracts-bedrock/test/OptimismMintableERC721.t.sol b/packages/contracts-bedrock/test/OptimismMintableERC721.t.sol index d4fb8ca9b5f6a..9a9eede4b4d6a 100644 --- a/packages/contracts-bedrock/test/OptimismMintableERC721.t.sol +++ b/packages/contracts-bedrock/test/OptimismMintableERC721.t.sol @@ -5,12 +5,12 @@ import { ERC721, IERC721 } from "@openzeppelin/contracts/token/ERC721/ERC721.sol import { IERC721Enumerable } from "@openzeppelin/contracts/token/ERC721/extensions/ERC721Enumerable.sol"; import { IERC165 } from "@openzeppelin/contracts/utils/introspection/IERC165.sol"; import { Strings } from "@openzeppelin/contracts/utils/Strings.sol"; -import { ERC721Bridge_Initializer } from "./CommonTest.t.sol"; -import { OptimismMintableERC721, IOptimismMintableERC721 } from "../src/universal/OptimismMintableERC721.sol"; +import { Bridge_Initializer } from "test/setup/Bridge_Initializer.sol"; +import { OptimismMintableERC721, IOptimismMintableERC721 } from "src/universal/OptimismMintableERC721.sol"; -contract OptimismMintableERC721_Test is ERC721Bridge_Initializer { - ERC721 internal L1Token; - OptimismMintableERC721 internal L2Token; +contract OptimismMintableERC721_Test is Bridge_Initializer { + ERC721 internal L1NFT; + OptimismMintableERC721 internal L2NFT; event Transfer(address indexed from, address indexed to, uint256 indexed tokenId); @@ -22,41 +22,41 @@ contract OptimismMintableERC721_Test is ERC721Bridge_Initializer { super.setUp(); // Set up the token pair. - L1Token = new ERC721("L1Token", "L1T"); - L2Token = new OptimismMintableERC721( - address(L2Bridge), + L1NFT = new ERC721("L1NFT", "L1T"); + L2NFT = new OptimismMintableERC721( + address(l2ERC721Bridge), 1, - address(L1Token), - "L2Token", + address(L1NFT), + "L2NFT", "L2T" ); // Label the addresses for nice traces. - vm.label(address(L1Token), "L1ERC721Token"); - vm.label(address(L2Token), "L2ERC721Token"); + vm.label(address(L1NFT), "L1ERC721Token"); + vm.label(address(L2NFT), "L2ERC721Token"); } function test_constructor_succeeds() external { - assertEq(L2Token.name(), "L2Token"); - assertEq(L2Token.symbol(), "L2T"); - assertEq(L2Token.remoteToken(), address(L1Token)); - assertEq(L2Token.bridge(), address(L2Bridge)); - assertEq(L2Token.remoteChainId(), 1); - assertEq(L2Token.REMOTE_TOKEN(), address(L1Token)); - assertEq(L2Token.BRIDGE(), address(L2Bridge)); - assertEq(L2Token.REMOTE_CHAIN_ID(), 1); + assertEq(L2NFT.name(), "L2NFT"); + assertEq(L2NFT.symbol(), "L2T"); + assertEq(L2NFT.remoteToken(), address(L1NFT)); + assertEq(L2NFT.bridge(), address(l2ERC721Bridge)); + assertEq(L2NFT.remoteChainId(), 1); + assertEq(L2NFT.REMOTE_TOKEN(), address(L1NFT)); + assertEq(L2NFT.BRIDGE(), address(l2ERC721Bridge)); + assertEq(L2NFT.REMOTE_CHAIN_ID(), 1); } /// @notice Ensure that the contract supports the expected interfaces. function test_supportsInterfaces_succeeds() external { // Checks if the contract supports the IOptimismMintableERC721 interface. - assertTrue(L2Token.supportsInterface(type(IOptimismMintableERC721).interfaceId)); + assertTrue(L2NFT.supportsInterface(type(IOptimismMintableERC721).interfaceId)); // Checks if the contract supports the IERC721Enumerable interface. - assertTrue(L2Token.supportsInterface(type(IERC721Enumerable).interfaceId)); + assertTrue(L2NFT.supportsInterface(type(IERC721Enumerable).interfaceId)); // Checks if the contract supports the IERC721 interface. - assertTrue(L2Token.supportsInterface(type(IERC721).interfaceId)); + assertTrue(L2NFT.supportsInterface(type(IERC721).interfaceId)); // Checks if the contract supports the IERC165 interface. - assertTrue(L2Token.supportsInterface(type(IERC165).interfaceId)); + assertTrue(L2NFT.supportsInterface(type(IERC165).interfaceId)); } function test_safeMint_succeeds() external { @@ -69,24 +69,24 @@ contract OptimismMintableERC721_Test is ERC721Bridge_Initializer { emit Mint(alice, 1); // Mint the token. - vm.prank(address(L2Bridge)); - L2Token.safeMint(alice, 1); + vm.prank(address(l2ERC721Bridge)); + L2NFT.safeMint(alice, 1); // Token should be owned by alice. - assertEq(L2Token.ownerOf(1), alice); + assertEq(L2NFT.ownerOf(1), alice); } function test_safeMint_notBridge_reverts() external { // Try to mint the token. vm.expectRevert("OptimismMintableERC721: only bridge can call this function"); vm.prank(address(alice)); - L2Token.safeMint(alice, 1); + L2NFT.safeMint(alice, 1); } function test_burn_succeeds() external { // Mint the token first. - vm.prank(address(L2Bridge)); - L2Token.safeMint(alice, 1); + vm.prank(address(l2ERC721Bridge)); + L2NFT.safeMint(alice, 1); // Expect a transfer event. vm.expectEmit(true, true, true, true); @@ -97,37 +97,37 @@ contract OptimismMintableERC721_Test is ERC721Bridge_Initializer { emit Burn(alice, 1); // Burn the token. - vm.prank(address(L2Bridge)); - L2Token.burn(alice, 1); + vm.prank(address(l2ERC721Bridge)); + L2NFT.burn(alice, 1); // Token should be owned by address(0). vm.expectRevert("ERC721: invalid token ID"); - L2Token.ownerOf(1); + L2NFT.ownerOf(1); } function test_burn_notBridge_reverts() external { // Mint the token first. - vm.prank(address(L2Bridge)); - L2Token.safeMint(alice, 1); + vm.prank(address(l2ERC721Bridge)); + L2NFT.safeMint(alice, 1); // Try to burn the token. vm.expectRevert("OptimismMintableERC721: only bridge can call this function"); vm.prank(address(alice)); - L2Token.burn(alice, 1); + L2NFT.burn(alice, 1); } function test_tokenURI_succeeds() external { // Mint the token first. - vm.prank(address(L2Bridge)); - L2Token.safeMint(alice, 1); + vm.prank(address(l2ERC721Bridge)); + L2NFT.safeMint(alice, 1); // Token URI should be correct. assertEq( - L2Token.tokenURI(1), + L2NFT.tokenURI(1), string( abi.encodePacked( "ethereum:", - Strings.toHexString(uint160(address(L1Token)), 20), + Strings.toHexString(uint160(address(L1NFT)), 20), "@", Strings.toString(1), "/tokenURI?uint256=", diff --git a/packages/contracts-bedrock/test/OptimismMintableERC721Factory.t.sol b/packages/contracts-bedrock/test/OptimismMintableERC721Factory.t.sol index 6570a73c8c336..d337b58a5b149 100644 --- a/packages/contracts-bedrock/test/OptimismMintableERC721Factory.t.sol +++ b/packages/contracts-bedrock/test/OptimismMintableERC721Factory.t.sol @@ -2,11 +2,11 @@ pragma solidity 0.8.15; import { ERC721 } from "@openzeppelin/contracts/token/ERC721/ERC721.sol"; -import { ERC721Bridge_Initializer } from "./CommonTest.t.sol"; -import { OptimismMintableERC721 } from "../src/universal/OptimismMintableERC721.sol"; -import { OptimismMintableERC721Factory } from "../src/universal/OptimismMintableERC721Factory.sol"; +import { Bridge_Initializer } from "test/setup/Bridge_Initializer.sol"; +import { OptimismMintableERC721 } from "src/universal/OptimismMintableERC721.sol"; +import { OptimismMintableERC721Factory } from "src/universal/OptimismMintableERC721Factory.sol"; -contract OptimismMintableERC721Factory_Test is ERC721Bridge_Initializer { +contract OptimismMintableERC721Factory_Test is Bridge_Initializer { OptimismMintableERC721Factory internal factory; event OptimismMintableERC721Created(address indexed localToken, address indexed remoteToken, address deployer); @@ -15,14 +15,14 @@ contract OptimismMintableERC721Factory_Test is ERC721Bridge_Initializer { super.setUp(); // Set up the token pair. - factory = new OptimismMintableERC721Factory(address(L2Bridge), 1); + factory = new OptimismMintableERC721Factory(address(l2ERC721Bridge), 1); // Label the addresses for nice traces. vm.label(address(factory), "OptimismMintableERC721Factory"); } function test_constructor_succeeds() external { - assertEq(factory.BRIDGE(), address(L2Bridge)); + assertEq(factory.BRIDGE(), address(l2ERC721Bridge)); assertEq(factory.REMOTE_CHAIN_ID(), 1); } @@ -49,7 +49,7 @@ contract OptimismMintableERC721Factory_Test is ERC721Bridge_Initializer { assertEq(created.name(), "L2Token"); assertEq(created.symbol(), "L2T"); assertEq(created.REMOTE_TOKEN(), remote); - assertEq(created.BRIDGE(), address(L2Bridge)); + assertEq(created.BRIDGE(), address(l2ERC721Bridge)); assertEq(created.REMOTE_CHAIN_ID(), 1); } @@ -80,7 +80,7 @@ contract OptimismMintableERC721Factory_Test is ERC721Bridge_Initializer { view returns (address) { - bytes memory constructorArgs = abi.encode(address(L2Bridge), 1, _remote, _name, _symbol); + bytes memory constructorArgs = abi.encode(address(l2ERC721Bridge), 1, _remote, _name, _symbol); bytes memory bytecode = abi.encodePacked(type(OptimismMintableERC721).creationCode, constructorArgs); bytes32 salt = keccak256(abi.encode(_remote, _name, _symbol)); bytes32 hash = keccak256(abi.encodePacked(bytes1(0xff), address(factory), salt, keccak256(bytecode))); diff --git a/packages/contracts-bedrock/test/OptimismPortal.t.sol b/packages/contracts-bedrock/test/OptimismPortal.t.sol index 256e5c6359fc4..414fc65a8be37 100644 --- a/packages/contracts-bedrock/test/OptimismPortal.t.sol +++ b/packages/contracts-bedrock/test/OptimismPortal.t.sol @@ -3,7 +3,10 @@ pragma solidity 0.8.15; // Testing utilities import { stdError } from "forge-std/Test.sol"; -import { Portal_Initializer, CommonTest, NextImpl } from "./CommonTest.t.sol"; + +import { CommonTest } from "test/setup/CommonTest.sol"; +import { NextImpl } from "test/mocks/NextImpl.sol"; +import { EIP1967Helper } from "test/mocks/EIP1967Helper.sol"; // Libraries import { Types } from "src/libraries/Types.sol"; @@ -16,97 +19,111 @@ import { ResourceMetering } from "src/L1/ResourceMetering.sol"; import { AddressAliasHelper } from "src/vendor/AddressAliasHelper.sol"; import { L2OutputOracle } from "src/L1/L2OutputOracle.sol"; import { SystemConfig } from "src/L1/SystemConfig.sol"; - -// Target contract import { OptimismPortal } from "src/L1/OptimismPortal.sol"; -contract OptimismPortal_Test is Portal_Initializer { +contract OptimismPortal_Test is CommonTest { event Paused(address); event Unpaused(address); + address depositor; + + function setUp() public override { + super.setUp(); + depositor = makeAddr("depositor"); + } + /// @dev Tests that the constructor sets the correct values. function test_constructor_succeeds() external { - assertEq(address(op.L2_ORACLE()), address(oracle)); - assertEq(address(op.l2Oracle()), address(oracle)); - assertEq(op.GUARDIAN(), guardian); - assertEq(op.guardian(), guardian); - assertEq(op.l2Sender(), 0x000000000000000000000000000000000000dEaD); - assertEq(op.paused(), false); + address guardian = cfg.portalGuardian(); + assertEq(address(optimismPortal.L2_ORACLE()), address(l2OutputOracle)); + assertEq(address(optimismPortal.l2Oracle()), address(l2OutputOracle)); + assertEq(optimismPortal.GUARDIAN(), guardian); + assertEq(optimismPortal.guardian(), guardian); + assertEq(optimismPortal.l2Sender(), 0x000000000000000000000000000000000000dEaD); + assertEq(optimismPortal.paused(), false); } /// @dev Tests that `pause` successfully pauses /// when called by the GUARDIAN. function test_pause_succeeds() external { - address guardian = op.GUARDIAN(); + address guardian = optimismPortal.GUARDIAN(); - assertEq(op.paused(), false); + assertEq(optimismPortal.paused(), false); - vm.expectEmit(true, true, true, true, address(op)); + vm.expectEmit(address(optimismPortal)); emit Paused(guardian); vm.prank(guardian); - op.pause(); + optimismPortal.pause(); - assertEq(op.paused(), true); + assertEq(optimismPortal.paused(), true); } /// @dev Tests that `pause` reverts when called by a non-GUARDIAN. function test_pause_onlyGuardian_reverts() external { - assertEq(op.paused(), false); + assertEq(optimismPortal.paused(), false); - assertTrue(op.GUARDIAN() != alice); + assertTrue(optimismPortal.GUARDIAN() != alice); vm.expectRevert("OptimismPortal: only guardian can pause"); vm.prank(alice); - op.pause(); + optimismPortal.pause(); - assertEq(op.paused(), false); + assertEq(optimismPortal.paused(), false); } /// @dev Tests that `unpause` successfully unpauses /// when called by the GUARDIAN. function test_unpause_succeeds() external { - address guardian = op.GUARDIAN(); + address guardian = optimismPortal.GUARDIAN(); vm.prank(guardian); - op.pause(); - assertEq(op.paused(), true); + optimismPortal.pause(); + assertEq(optimismPortal.paused(), true); - vm.expectEmit(true, true, true, true, address(op)); + vm.expectEmit(address(optimismPortal)); emit Unpaused(guardian); vm.prank(guardian); - op.unpause(); + optimismPortal.unpause(); - assertEq(op.paused(), false); + assertEq(optimismPortal.paused(), false); } /// @dev Tests that `unpause` reverts when called by a non-GUARDIAN. function test_unpause_onlyGuardian_reverts() external { - address guardian = op.GUARDIAN(); + address guardian = optimismPortal.GUARDIAN(); vm.prank(guardian); - op.pause(); - assertEq(op.paused(), true); + optimismPortal.pause(); + assertEq(optimismPortal.paused(), true); - assertTrue(op.GUARDIAN() != alice); + assertTrue(optimismPortal.GUARDIAN() != alice); vm.expectRevert("OptimismPortal: only guardian can unpause"); vm.prank(alice); - op.unpause(); + optimismPortal.unpause(); - assertEq(op.paused(), true); + assertEq(optimismPortal.paused(), true); } /// @dev Tests that `receive` successdully deposits ETH. - function test_receive_succeeds() external { - vm.expectEmit(true, true, false, true); - emitTransactionDeposited(alice, alice, 100, 100, 100_000, false, hex""); + function testFuzz_receive_succeeds(uint256 _value) external { + vm.expectEmit(address(optimismPortal)); + emitTransactionDeposited({ + _from: alice, + _to: alice, + _value: _value, + _mint: _value, + _gasLimit: 100_000, + _isCreation: false, + _data: hex"" + }); // give alice money and send as an eoa - vm.deal(alice, 2 ** 64); + vm.deal(alice, _value); vm.prank(alice, alice); - (bool s,) = address(op).call{ value: 100 }(hex""); + (bool s,) = address(optimismPortal).call{ value: _value }(hex""); - assert(s); - assertEq(address(op).balance, 100); + assertTrue(s); + assertEq(address(optimismPortal).balance, _value); } /// @dev Tests that `depositTransaction` reverts when the destination address is non-zero @@ -114,16 +131,16 @@ contract OptimismPortal_Test is Portal_Initializer { function test_depositTransaction_contractCreation_reverts() external { // contract creation must have a target of address(0) vm.expectRevert("OptimismPortal: must send to address(0) when creating a contract"); - op.depositTransaction(address(1), 1, 0, true, hex""); + optimismPortal.depositTransaction(address(1), 1, 0, true, hex""); } /// @dev Tests that `depositTransaction` reverts when the data is too large. /// This places an upper bound on unsafe blocks sent over p2p. function test_depositTransaction_largeData_reverts() external { uint256 size = 120_001; - uint64 gasLimit = op.minimumGasLimit(uint64(size)); + uint64 gasLimit = optimismPortal.minimumGasLimit(uint64(size)); vm.expectRevert("OptimismPortal: data too large"); - op.depositTransaction({ + optimismPortal.depositTransaction({ _to: address(0), _value: 0, _gasLimit: gasLimit, @@ -135,203 +152,171 @@ contract OptimismPortal_Test is Portal_Initializer { /// @dev Tests that `depositTransaction` reverts when the gas limit is too small. function test_depositTransaction_smallGasLimit_reverts() external { vm.expectRevert("OptimismPortal: gas limit too small"); - op.depositTransaction({ _to: address(1), _value: 0, _gasLimit: 0, _isCreation: false, _data: hex"" }); + optimismPortal.depositTransaction({ _to: address(1), _value: 0, _gasLimit: 0, _isCreation: false, _data: hex"" }); } /// @dev Tests that `depositTransaction` succeeds for small, /// but sufficient, gas limits. function testFuzz_depositTransaction_smallGasLimit_succeeds(bytes memory _data, bool _shouldFail) external { - vm.assume(_data.length <= type(uint64).max); - - uint64 gasLimit = op.minimumGasLimit(uint64(_data.length)); + uint64 gasLimit = optimismPortal.minimumGasLimit(uint64(_data.length)); if (_shouldFail) { gasLimit = uint64(bound(gasLimit, 0, gasLimit - 1)); vm.expectRevert("OptimismPortal: gas limit too small"); } - op.depositTransaction({ _to: address(0x40), _value: 0, _gasLimit: gasLimit, _isCreation: false, _data: _data }); + optimismPortal.depositTransaction({ + _to: address(0x40), + _value: 0, + _gasLimit: gasLimit, + _isCreation: false, + _data: _data + }); } /// @dev Tests that `minimumGasLimit` succeeds for small calldata sizes. /// The gas limit should be 21k for 0 calldata and increase linearly /// for larger calldata sizes. function test_minimumGasLimit_succeeds() external { - assertEq(op.minimumGasLimit(0), 21_000); - assertTrue(op.minimumGasLimit(2) > op.minimumGasLimit(1)); - assertTrue(op.minimumGasLimit(3) > op.minimumGasLimit(2)); - } - - /// @dev Tests that `depositTransaction` succeeds for an EOA depositing a tx with 0 value. - function test_depositTransaction_noValueEOA_succeeds() external { - // EOA emulation - vm.prank(address(this), address(this)); - vm.expectEmit(true, true, false, true); - emitTransactionDeposited( - address(this), NON_ZERO_ADDRESS, ZERO_VALUE, ZERO_VALUE, NON_ZERO_GASLIMIT, false, NON_ZERO_DATA - ); - - op.depositTransaction(NON_ZERO_ADDRESS, ZERO_VALUE, NON_ZERO_GASLIMIT, false, NON_ZERO_DATA); - } - - /// @dev Tests that `depositTransaction` succeeds for a contract depositing a tx with 0 value. - function test_depositTransaction_noValueContract_succeeds() external { - vm.expectEmit(true, true, false, true); - emitTransactionDeposited( - AddressAliasHelper.applyL1ToL2Alias(address(this)), - NON_ZERO_ADDRESS, - ZERO_VALUE, - ZERO_VALUE, - NON_ZERO_GASLIMIT, - false, - NON_ZERO_DATA - ); - - op.depositTransaction(NON_ZERO_ADDRESS, ZERO_VALUE, NON_ZERO_GASLIMIT, false, NON_ZERO_DATA); - } - - /// @dev Tests that `depositTransaction` succeeds for an EOA - /// depositing a contract creation with 0 value. - function test_depositTransaction_createWithZeroValueForEOA_succeeds() external { - // EOA emulation - vm.prank(address(this), address(this)); - - vm.expectEmit(true, true, false, true); - emitTransactionDeposited( - address(this), ZERO_ADDRESS, ZERO_VALUE, ZERO_VALUE, NON_ZERO_GASLIMIT, true, NON_ZERO_DATA - ); - - op.depositTransaction(ZERO_ADDRESS, ZERO_VALUE, NON_ZERO_GASLIMIT, true, NON_ZERO_DATA); + assertEq(optimismPortal.minimumGasLimit(0), 21_000); + assertTrue(optimismPortal.minimumGasLimit(2) > optimismPortal.minimumGasLimit(1)); + assertTrue(optimismPortal.minimumGasLimit(3) > optimismPortal.minimumGasLimit(2)); } - /// @dev Tests that `depositTransaction` succeeds for a contract - /// depositing a contract creation with 0 value. - function test_depositTransaction_createWithZeroValueForContract_succeeds() external { - vm.expectEmit(true, true, false, true); - emitTransactionDeposited( - AddressAliasHelper.applyL1ToL2Alias(address(this)), - ZERO_ADDRESS, - ZERO_VALUE, - ZERO_VALUE, - NON_ZERO_GASLIMIT, - true, - NON_ZERO_DATA - ); - - op.depositTransaction(ZERO_ADDRESS, ZERO_VALUE, NON_ZERO_GASLIMIT, true, NON_ZERO_DATA); - } - - /// @dev Tests that `depositTransaction` succeeds for an EOA depositing a tx with ETH. - function test_depositTransaction_withEthValueFromEOA_succeeds() external { - // EOA emulation - vm.prank(address(this), address(this)); - - vm.expectEmit(true, true, false, true); - emitTransactionDeposited( - address(this), NON_ZERO_ADDRESS, NON_ZERO_VALUE, ZERO_VALUE, NON_ZERO_GASLIMIT, false, NON_ZERO_DATA - ); - - op.depositTransaction{ value: NON_ZERO_VALUE }( - NON_ZERO_ADDRESS, ZERO_VALUE, NON_ZERO_GASLIMIT, false, NON_ZERO_DATA - ); - assertEq(address(op).balance, NON_ZERO_VALUE); - } - - /// @dev Tests that `depositTransaction` succeeds for a contract depositing a tx with ETH. - function test_depositTransaction_withEthValueFromContract_succeeds() external { - vm.expectEmit(true, true, false, true); - emitTransactionDeposited( - AddressAliasHelper.applyL1ToL2Alias(address(this)), - NON_ZERO_ADDRESS, - NON_ZERO_VALUE, - ZERO_VALUE, - NON_ZERO_GASLIMIT, - false, - NON_ZERO_DATA - ); - - op.depositTransaction{ value: NON_ZERO_VALUE }( - NON_ZERO_ADDRESS, ZERO_VALUE, NON_ZERO_GASLIMIT, false, NON_ZERO_DATA + /// @dev Tests that `depositTransaction` succeeds for an EOA. + function testFuzz_depositTransaction_eoa_succeeds( + address _to, + uint64 _gasLimit, + uint256 _value, + uint256 _mint, + bool _isCreation, + bytes memory _data + ) + external + { + _gasLimit = uint64( + bound( + _gasLimit, + optimismPortal.minimumGasLimit(uint64(_data.length)), + systemConfig.resourceConfig().maxResourceLimit + ) ); - } + if (_isCreation) _to = address(0); - /// @dev Tests that `depositTransaction` succeeds for an EOA depositing a contract creation with ETH. - function test_depositTransaction_withEthValueAndEOAContractCreation_succeeds() external { // EOA emulation - vm.prank(address(this), address(this)); - - vm.expectEmit(true, true, false, true); - emitTransactionDeposited( - address(this), ZERO_ADDRESS, NON_ZERO_VALUE, ZERO_VALUE, NON_ZERO_GASLIMIT, true, hex"" - ); + vm.expectEmit(address(optimismPortal)); + emitTransactionDeposited({ + _from: depositor, + _to: _to, + _value: _value, + _mint: _mint, + _gasLimit: _gasLimit, + _isCreation: _isCreation, + _data: _data + }); - op.depositTransaction{ value: NON_ZERO_VALUE }(ZERO_ADDRESS, ZERO_VALUE, NON_ZERO_GASLIMIT, true, hex""); - assertEq(address(op).balance, NON_ZERO_VALUE); + vm.deal(depositor, _mint); + vm.prank(depositor, depositor); + optimismPortal.depositTransaction{ value: _mint }({ + _to: _to, + _value: _value, + _gasLimit: _gasLimit, + _isCreation: _isCreation, + _data: _data + }); + assertEq(address(optimismPortal).balance, _mint); } - /// @dev Tests that `depositTransaction` succeeds for a contract depositing a contract creation with ETH. - function test_depositTransaction_withEthValueAndContractContractCreation_succeeds() external { - vm.expectEmit(true, true, false, true); - emitTransactionDeposited( - AddressAliasHelper.applyL1ToL2Alias(address(this)), - ZERO_ADDRESS, - NON_ZERO_VALUE, - ZERO_VALUE, - NON_ZERO_GASLIMIT, - true, - NON_ZERO_DATA + /// @dev Tests that `depositTransaction` succeeds for a contract. + function testFuzz_depositTransaction_contract_succeeds( + address _to, + uint64 _gasLimit, + uint256 _value, + uint256 _mint, + bool _isCreation, + bytes memory _data + ) + external + { + _gasLimit = uint64( + bound( + _gasLimit, + optimismPortal.minimumGasLimit(uint64(_data.length)), + systemConfig.resourceConfig().maxResourceLimit + ) ); + if (_isCreation) _to = address(0); + + vm.expectEmit(address(optimismPortal)); + emitTransactionDeposited({ + _from: AddressAliasHelper.applyL1ToL2Alias(address(this)), + _to: _to, + _value: _value, + _mint: _mint, + _gasLimit: _gasLimit, + _isCreation: _isCreation, + _data: _data + }); - op.depositTransaction{ value: NON_ZERO_VALUE }(ZERO_ADDRESS, ZERO_VALUE, NON_ZERO_GASLIMIT, true, NON_ZERO_DATA); - assertEq(address(op).balance, NON_ZERO_VALUE); + vm.deal(address(this), _mint); + vm.prank(address(this)); + optimismPortal.depositTransaction{ value: _mint }({ + _to: _to, + _value: _value, + _gasLimit: _gasLimit, + _isCreation: _isCreation, + _data: _data + }); + assertEq(address(optimismPortal).balance, _mint); } /// @dev Tests that `isOutputFinalized` succeeds for an EOA depositing a tx with ETH and data. function test_simple_isOutputFinalized_succeeds() external { + uint256 startingBlockNumber = cfg.l2OutputOracleStartingBlockNumber(); + uint256 ts = block.timestamp; vm.mockCall( - address(op.L2_ORACLE()), + address(optimismPortal.L2_ORACLE()), abi.encodeWithSelector(L2OutputOracle.getL2Output.selector), abi.encode(Types.OutputProposal(bytes32(uint256(1)), uint128(ts), uint128(startingBlockNumber))) ); // warp to the finalization period - vm.warp(ts + oracle.FINALIZATION_PERIOD_SECONDS()); - assertEq(op.isOutputFinalized(0), false); + vm.warp(ts + l2OutputOracle.FINALIZATION_PERIOD_SECONDS()); + assertEq(optimismPortal.isOutputFinalized(0), false); // warp past the finalization period - vm.warp(ts + oracle.FINALIZATION_PERIOD_SECONDS() + 1); - assertEq(op.isOutputFinalized(0), true); + vm.warp(ts + l2OutputOracle.FINALIZATION_PERIOD_SECONDS() + 1); + assertEq(optimismPortal.isOutputFinalized(0), true); } /// @dev Tests `isOutputFinalized` for a finalized output. function test_isOutputFinalized_succeeds() external { - uint256 checkpoint = oracle.nextBlockNumber(); - uint256 nextOutputIndex = oracle.nextOutputIndex(); + uint256 checkpoint = l2OutputOracle.nextBlockNumber(); + uint256 nextOutputIndex = l2OutputOracle.nextOutputIndex(); vm.roll(checkpoint); - vm.warp(oracle.computeL2Timestamp(checkpoint) + 1); - vm.prank(oracle.PROPOSER()); - oracle.proposeL2Output(keccak256(abi.encode(2)), checkpoint, 0, 0); + vm.warp(l2OutputOracle.computeL2Timestamp(checkpoint) + 1); + vm.prank(l2OutputOracle.PROPOSER()); + l2OutputOracle.proposeL2Output(keccak256(abi.encode(2)), checkpoint, 0, 0); // warp to the final second of the finalization period - uint256 finalizationHorizon = block.timestamp + oracle.FINALIZATION_PERIOD_SECONDS(); + uint256 finalizationHorizon = block.timestamp + l2OutputOracle.FINALIZATION_PERIOD_SECONDS(); vm.warp(finalizationHorizon); // The checkpointed block should not be finalized until 1 second from now. - assertEq(op.isOutputFinalized(nextOutputIndex), false); + assertEq(optimismPortal.isOutputFinalized(nextOutputIndex), false); // Nor should a block after it vm.expectRevert(stdError.indexOOBError); - assertEq(op.isOutputFinalized(nextOutputIndex + 1), false); - + assertEq(optimismPortal.isOutputFinalized(nextOutputIndex + 1), false); // warp past the finalization period vm.warp(finalizationHorizon + 1); // It should now be finalized. - assertEq(op.isOutputFinalized(nextOutputIndex), true); + assertEq(optimismPortal.isOutputFinalized(nextOutputIndex), true); // But not the block after it. vm.expectRevert(stdError.indexOOBError); - assertEq(op.isOutputFinalized(nextOutputIndex + 1), false); + assertEq(optimismPortal.isOutputFinalized(nextOutputIndex + 1), false); } } -contract OptimismPortal_FinalizeWithdrawal_Test is Portal_Initializer { +contract OptimismPortal_FinalizeWithdrawal_Test is CommonTest { // Reusable default values for a test withdrawal Types.WithdrawalTransaction _defaultTx; @@ -366,21 +351,24 @@ contract OptimismPortal_FinalizeWithdrawal_Test is Portal_Initializer { messagePasserStorageRoot: _storageRoot, latestBlockhash: bytes32(uint256(0)) }); - _proposedBlockNumber = oracle.nextBlockNumber(); - _proposedOutputIndex = oracle.nextOutputIndex(); + _proposedBlockNumber = l2OutputOracle.nextBlockNumber(); + _proposedOutputIndex = l2OutputOracle.nextOutputIndex(); } /// @dev Setup the system for a ready-to-use state. function setUp() public override { // Configure the oracle to return the output root we've prepared. - vm.warp(oracle.computeL2Timestamp(_proposedBlockNumber) + 1); - vm.prank(oracle.PROPOSER()); - oracle.proposeL2Output(_outputRoot, _proposedBlockNumber, 0, 0); + vm.warp(l2OutputOracle.computeL2Timestamp(_proposedBlockNumber) + 1); + vm.prank(l2OutputOracle.PROPOSER()); + l2OutputOracle.proposeL2Output(_outputRoot, _proposedBlockNumber, 0, 0); // Warp beyond the finalization period for the block we've proposed. - vm.warp(oracle.getL2Output(_proposedOutputIndex).timestamp + oracle.FINALIZATION_PERIOD_SECONDS() + 1); + vm.warp( + l2OutputOracle.getL2Output(_proposedOutputIndex).timestamp + l2OutputOracle.FINALIZATION_PERIOD_SECONDS() + + 1 + ); // Fund the portal so that we can withdraw ETH. - vm.deal(address(op), 0xFFFFFFFF); + vm.deal(address(optimismPortal), 0xFFFFFFFF); } /// @dev Asserts that the reentrant call will revert. @@ -388,18 +376,18 @@ contract OptimismPortal_FinalizeWithdrawal_Test is Portal_Initializer { vm.expectRevert("OptimismPortal: can only trigger one withdrawal per transaction"); // Arguments here don't matter, as the require check is the first thing that happens. // We assume that this has already been proven. - op.finalizeWithdrawalTransaction(_defaultTx); + optimismPortal.finalizeWithdrawalTransaction(_defaultTx); // Assert that the withdrawal was not finalized. - assertFalse(op.finalizedWithdrawals(Hashing.hashWithdrawal(_defaultTx))); + assertFalse(optimismPortal.finalizedWithdrawals(Hashing.hashWithdrawal(_defaultTx))); } /// @dev Tests that `proveWithdrawalTransaction` reverts when paused. function test_proveWithdrawalTransaction_paused_reverts() external { - vm.prank(op.GUARDIAN()); - op.pause(); + vm.prank(optimismPortal.GUARDIAN()); + optimismPortal.pause(); vm.expectRevert("OptimismPortal: paused"); - op.proveWithdrawalTransaction({ + optimismPortal.proveWithdrawalTransaction({ _tx: _defaultTx, _l2OutputIndex: _proposedOutputIndex, _outputRootProof: _outputRootProof, @@ -409,9 +397,9 @@ contract OptimismPortal_FinalizeWithdrawal_Test is Portal_Initializer { /// @dev Tests that `proveWithdrawalTransaction` reverts when the target is the portal contract. function test_proveWithdrawalTransaction_onSelfCall_reverts() external { - _defaultTx.target = address(op); + _defaultTx.target = address(optimismPortal); vm.expectRevert("OptimismPortal: you cannot send messages to the portal contract"); - op.proveWithdrawalTransaction(_defaultTx, _proposedOutputIndex, _outputRootProof, _withdrawalProof); + optimismPortal.proveWithdrawalTransaction(_defaultTx, _proposedOutputIndex, _outputRootProof, _withdrawalProof); } /// @dev Tests that `proveWithdrawalTransaction` reverts when @@ -420,7 +408,7 @@ contract OptimismPortal_FinalizeWithdrawal_Test is Portal_Initializer { // Modify the version to invalidate the withdrawal proof. _outputRootProof.version = bytes32(uint256(1)); vm.expectRevert("OptimismPortal: invalid output root proof"); - op.proveWithdrawalTransaction(_defaultTx, _proposedOutputIndex, _outputRootProof, _withdrawalProof); + optimismPortal.proveWithdrawalTransaction(_defaultTx, _proposedOutputIndex, _outputRootProof, _withdrawalProof); } /// @dev Tests that `proveWithdrawalTransaction` reverts when the withdrawal is missing. @@ -428,7 +416,7 @@ contract OptimismPortal_FinalizeWithdrawal_Test is Portal_Initializer { // modify the default test values to invalidate the proof. _defaultTx.data = hex"abcd"; vm.expectRevert("MerkleTrie: path remainder must share all nibbles with key"); - op.proveWithdrawalTransaction(_defaultTx, _proposedOutputIndex, _outputRootProof, _withdrawalProof); + optimismPortal.proveWithdrawalTransaction(_defaultTx, _proposedOutputIndex, _outputRootProof, _withdrawalProof); } /// @dev Tests that `proveWithdrawalTransaction` reverts when the withdrawal has already @@ -436,10 +424,10 @@ contract OptimismPortal_FinalizeWithdrawal_Test is Portal_Initializer { function test_proveWithdrawalTransaction_replayProve_reverts() external { vm.expectEmit(true, true, true, true); emit WithdrawalProven(_withdrawalHash, alice, bob); - op.proveWithdrawalTransaction(_defaultTx, _proposedOutputIndex, _outputRootProof, _withdrawalProof); + optimismPortal.proveWithdrawalTransaction(_defaultTx, _proposedOutputIndex, _outputRootProof, _withdrawalProof); vm.expectRevert("OptimismPortal: withdrawal hash has already been proven"); - op.proveWithdrawalTransaction(_defaultTx, _proposedOutputIndex, _outputRootProof, _withdrawalProof); + optimismPortal.proveWithdrawalTransaction(_defaultTx, _proposedOutputIndex, _outputRootProof, _withdrawalProof); } /// @dev Tests that `proveWithdrawalTransaction` succeeds when the withdrawal has already @@ -447,7 +435,7 @@ contract OptimismPortal_FinalizeWithdrawal_Test is Portal_Initializer { function test_proveWithdrawalTransaction_replayProveChangedOutputRoot_succeeds() external { vm.expectEmit(true, true, true, true); emit WithdrawalProven(_withdrawalHash, alice, bob); - op.proveWithdrawalTransaction(_defaultTx, _proposedOutputIndex, _outputRootProof, _withdrawalProof); + optimismPortal.proveWithdrawalTransaction(_defaultTx, _proposedOutputIndex, _outputRootProof, _withdrawalProof); // Compute the storage slot of the outputRoot corresponding to the `withdrawalHash` // inside of the `provenWithdrawal`s mapping. @@ -460,7 +448,7 @@ contract OptimismPortal_FinalizeWithdrawal_Test is Portal_Initializer { // Store a different output root within the `provenWithdrawals` mapping without // touching the l2BlockNumber or timestamp. - vm.store(address(op), slot, bytes32(0)); + vm.store(address(optimismPortal), slot, bytes32(0)); // Warp ahead 1 second vm.warp(block.timestamp + 1); @@ -469,10 +457,10 @@ contract OptimismPortal_FinalizeWithdrawal_Test is Portal_Initializer { // our proof with a changed outputRoot vm.expectEmit(true, true, true, true); emit WithdrawalProven(_withdrawalHash, alice, bob); - op.proveWithdrawalTransaction(_defaultTx, _proposedOutputIndex, _outputRootProof, _withdrawalProof); + optimismPortal.proveWithdrawalTransaction(_defaultTx, _proposedOutputIndex, _outputRootProof, _withdrawalProof); // Ensure that the withdrawal was updated within the mapping - (, uint128 timestamp,) = op.provenWithdrawals(_withdrawalHash); + (, uint128 timestamp,) = optimismPortal.provenWithdrawals(_withdrawalHash); assertEq(timestamp, block.timestamp); } @@ -481,7 +469,7 @@ contract OptimismPortal_FinalizeWithdrawal_Test is Portal_Initializer { function test_proveWithdrawalTransaction_replayProveChangedOutputRootAndOutputIndex_succeeds() external { vm.expectEmit(true, true, true, true); emit WithdrawalProven(_withdrawalHash, alice, bob); - op.proveWithdrawalTransaction(_defaultTx, _proposedOutputIndex, _outputRootProof, _withdrawalProof); + optimismPortal.proveWithdrawalTransaction(_defaultTx, _proposedOutputIndex, _outputRootProof, _withdrawalProof); // Compute the storage slot of the outputRoot corresponding to the `withdrawalHash` // inside of the `provenWithdrawal`s mapping. @@ -494,15 +482,15 @@ contract OptimismPortal_FinalizeWithdrawal_Test is Portal_Initializer { // Store a dummy output root within the `provenWithdrawals` mapping without touching the // l2BlockNumber or timestamp. - vm.store(address(op), slot, bytes32(0)); + vm.store(address(optimismPortal), slot, bytes32(0)); // Fetch the output proposal at `_proposedOutputIndex` from the L2OutputOracle - Types.OutputProposal memory proposal = op.L2_ORACLE().getL2Output(_proposedOutputIndex); + Types.OutputProposal memory proposal = optimismPortal.L2_ORACLE().getL2Output(_proposedOutputIndex); // Propose the same output root again, creating the same output at a different index + l2BlockNumber. - vm.startPrank(op.L2_ORACLE().PROPOSER()); - op.L2_ORACLE().proposeL2Output( - proposal.outputRoot, op.L2_ORACLE().nextBlockNumber(), blockhash(block.number), block.number + vm.startPrank(optimismPortal.L2_ORACLE().PROPOSER()); + optimismPortal.L2_ORACLE().proposeL2Output( + proposal.outputRoot, optimismPortal.L2_ORACLE().nextBlockNumber(), blockhash(block.number), block.number ); vm.stopPrank(); @@ -513,10 +501,12 @@ contract OptimismPortal_FinalizeWithdrawal_Test is Portal_Initializer { // our proof with a changed outputRoot + a different output index vm.expectEmit(true, true, true, true); emit WithdrawalProven(_withdrawalHash, alice, bob); - op.proveWithdrawalTransaction(_defaultTx, _proposedOutputIndex + 1, _outputRootProof, _withdrawalProof); + optimismPortal.proveWithdrawalTransaction( + _defaultTx, _proposedOutputIndex + 1, _outputRootProof, _withdrawalProof + ); // Ensure that the withdrawal was updated within the mapping - (, uint128 timestamp,) = op.provenWithdrawals(_withdrawalHash); + (, uint128 timestamp,) = optimismPortal.provenWithdrawals(_withdrawalHash); assertEq(timestamp, block.timestamp); } @@ -524,7 +514,7 @@ contract OptimismPortal_FinalizeWithdrawal_Test is Portal_Initializer { function test_proveWithdrawalTransaction_validWithdrawalProof_succeeds() external { vm.expectEmit(true, true, true, true); emit WithdrawalProven(_withdrawalHash, alice, bob); - op.proveWithdrawalTransaction(_defaultTx, _proposedOutputIndex, _outputRootProof, _withdrawalProof); + optimismPortal.proveWithdrawalTransaction(_defaultTx, _proposedOutputIndex, _outputRootProof, _withdrawalProof); } /// @dev Tests that `finalizeWithdrawalTransaction` succeeds. @@ -533,23 +523,23 @@ contract OptimismPortal_FinalizeWithdrawal_Test is Portal_Initializer { vm.expectEmit(true, true, true, true); emit WithdrawalProven(_withdrawalHash, alice, bob); - op.proveWithdrawalTransaction(_defaultTx, _proposedOutputIndex, _outputRootProof, _withdrawalProof); + optimismPortal.proveWithdrawalTransaction(_defaultTx, _proposedOutputIndex, _outputRootProof, _withdrawalProof); - vm.warp(block.timestamp + oracle.FINALIZATION_PERIOD_SECONDS() + 1); + vm.warp(block.timestamp + l2OutputOracle.FINALIZATION_PERIOD_SECONDS() + 1); vm.expectEmit(true, true, false, true); emit WithdrawalFinalized(_withdrawalHash, true); - op.finalizeWithdrawalTransaction(_defaultTx); + optimismPortal.finalizeWithdrawalTransaction(_defaultTx); assert(address(bob).balance == bobBalanceBefore + 100); } /// @dev Tests that `finalizeWithdrawalTransaction` reverts if the contract is paused. function test_finalizeWithdrawalTransaction_paused_reverts() external { - vm.prank(op.GUARDIAN()); - op.pause(); + vm.prank(optimismPortal.GUARDIAN()); + optimismPortal.pause(); vm.expectRevert("OptimismPortal: paused"); - op.finalizeWithdrawalTransaction(_defaultTx); + optimismPortal.finalizeWithdrawalTransaction(_defaultTx); } /// @dev Tests that `finalizeWithdrawalTransaction` reverts if the withdrawal has not been @@ -557,7 +547,7 @@ contract OptimismPortal_FinalizeWithdrawal_Test is Portal_Initializer { uint256 bobBalanceBefore = address(bob).balance; vm.expectRevert("OptimismPortal: withdrawal has not been proven yet"); - op.finalizeWithdrawalTransaction(_defaultTx); + optimismPortal.finalizeWithdrawalTransaction(_defaultTx); assert(address(bob).balance == bobBalanceBefore); } @@ -569,18 +559,18 @@ contract OptimismPortal_FinalizeWithdrawal_Test is Portal_Initializer { vm.expectEmit(true, true, true, true); emit WithdrawalProven(_withdrawalHash, alice, bob); - op.proveWithdrawalTransaction(_defaultTx, _proposedOutputIndex, _outputRootProof, _withdrawalProof); + optimismPortal.proveWithdrawalTransaction(_defaultTx, _proposedOutputIndex, _outputRootProof, _withdrawalProof); // Mock a call where the resulting output root is anything but the original output root. In // this case we just use bytes32(uint256(1)). vm.mockCall( - address(op.L2_ORACLE()), + address(optimismPortal.L2_ORACLE()), abi.encodeWithSelector(L2OutputOracle.getL2Output.selector), abi.encode(bytes32(uint256(1)), _proposedBlockNumber) ); vm.expectRevert("OptimismPortal: proven withdrawal finalization period has not elapsed"); - op.finalizeWithdrawalTransaction(_defaultTx); + optimismPortal.finalizeWithdrawalTransaction(_defaultTx); assert(address(bob).balance == bobBalanceBefore); } @@ -593,19 +583,21 @@ contract OptimismPortal_FinalizeWithdrawal_Test is Portal_Initializer { // Prove our withdrawal vm.expectEmit(true, true, true, true); emit WithdrawalProven(_withdrawalHash, alice, bob); - op.proveWithdrawalTransaction(_defaultTx, _proposedOutputIndex, _outputRootProof, _withdrawalProof); + optimismPortal.proveWithdrawalTransaction(_defaultTx, _proposedOutputIndex, _outputRootProof, _withdrawalProof); // Warp to after the finalization period - vm.warp(block.timestamp + oracle.FINALIZATION_PERIOD_SECONDS() + 1); + vm.warp(block.timestamp + l2OutputOracle.FINALIZATION_PERIOD_SECONDS() + 1); // Mock a startingTimestamp change on the L2 Oracle vm.mockCall( - address(op.L2_ORACLE()), abi.encodeWithSignature("startingTimestamp()"), abi.encode(block.timestamp + 1) + address(optimismPortal.L2_ORACLE()), + abi.encodeWithSignature("startingTimestamp()"), + abi.encode(block.timestamp + 1) ); // Attempt to finalize the withdrawal vm.expectRevert("OptimismPortal: withdrawal timestamp less than L2 Oracle starting timestamp"); - op.finalizeWithdrawalTransaction(_defaultTx); + optimismPortal.finalizeWithdrawalTransaction(_defaultTx); // Ensure that bob's balance has remained the same assertEq(bobBalanceBefore, address(bob).balance); @@ -619,15 +611,15 @@ contract OptimismPortal_FinalizeWithdrawal_Test is Portal_Initializer { // Prove our withdrawal vm.expectEmit(true, true, true, true); emit WithdrawalProven(_withdrawalHash, alice, bob); - op.proveWithdrawalTransaction(_defaultTx, _proposedOutputIndex, _outputRootProof, _withdrawalProof); + optimismPortal.proveWithdrawalTransaction(_defaultTx, _proposedOutputIndex, _outputRootProof, _withdrawalProof); // Warp to after the finalization period - vm.warp(block.timestamp + oracle.FINALIZATION_PERIOD_SECONDS() + 1); + vm.warp(block.timestamp + l2OutputOracle.FINALIZATION_PERIOD_SECONDS() + 1); // Mock an outputRoot change on the output proposal before attempting // to finalize the withdrawal. vm.mockCall( - address(op.L2_ORACLE()), + address(optimismPortal.L2_ORACLE()), abi.encodeWithSelector(L2OutputOracle.getL2Output.selector), abi.encode( Types.OutputProposal(bytes32(uint256(0)), uint128(block.timestamp), uint128(_proposedBlockNumber)) @@ -636,7 +628,7 @@ contract OptimismPortal_FinalizeWithdrawal_Test is Portal_Initializer { // Attempt to finalize the withdrawal vm.expectRevert("OptimismPortal: output root proven is not the same as current output root"); - op.finalizeWithdrawalTransaction(_defaultTx); + optimismPortal.finalizeWithdrawalTransaction(_defaultTx); // Ensure that bob's balance has remained the same assertEq(bobBalanceBefore, address(bob).balance); @@ -650,22 +642,22 @@ contract OptimismPortal_FinalizeWithdrawal_Test is Portal_Initializer { // Prove our withdrawal vm.expectEmit(true, true, true, true); emit WithdrawalProven(_withdrawalHash, alice, bob); - op.proveWithdrawalTransaction(_defaultTx, _proposedOutputIndex, _outputRootProof, _withdrawalProof); + optimismPortal.proveWithdrawalTransaction(_defaultTx, _proposedOutputIndex, _outputRootProof, _withdrawalProof); // Warp to after the finalization period - vm.warp(block.timestamp + oracle.FINALIZATION_PERIOD_SECONDS() + 1); + vm.warp(block.timestamp + l2OutputOracle.FINALIZATION_PERIOD_SECONDS() + 1); // Mock a timestamp change on the output proposal that has not passed the // finalization period. vm.mockCall( - address(op.L2_ORACLE()), + address(optimismPortal.L2_ORACLE()), abi.encodeWithSelector(L2OutputOracle.getL2Output.selector), abi.encode(Types.OutputProposal(_outputRoot, uint128(block.timestamp + 1), uint128(_proposedBlockNumber))) ); // Attempt to finalize the withdrawal vm.expectRevert("OptimismPortal: output proposal finalization period has not elapsed"); - op.finalizeWithdrawalTransaction(_defaultTx); + optimismPortal.finalizeWithdrawalTransaction(_defaultTx); // Ensure that bob's balance has remained the same assertEq(bobBalanceBefore, address(bob).balance); @@ -678,12 +670,12 @@ contract OptimismPortal_FinalizeWithdrawal_Test is Portal_Initializer { vm.expectEmit(true, true, true, true); emit WithdrawalProven(_withdrawalHash, alice, bob); - op.proveWithdrawalTransaction(_defaultTx, _proposedOutputIndex, _outputRootProof, _withdrawalProof); + optimismPortal.proveWithdrawalTransaction(_defaultTx, _proposedOutputIndex, _outputRootProof, _withdrawalProof); - vm.warp(block.timestamp + oracle.FINALIZATION_PERIOD_SECONDS() + 1); + vm.warp(block.timestamp + l2OutputOracle.FINALIZATION_PERIOD_SECONDS() + 1); vm.expectEmit(true, true, true, true); emit WithdrawalFinalized(_withdrawalHash, false); - op.finalizeWithdrawalTransaction(_defaultTx); + optimismPortal.finalizeWithdrawalTransaction(_defaultTx); assert(address(bob).balance == bobBalanceBefore); } @@ -692,17 +684,17 @@ contract OptimismPortal_FinalizeWithdrawal_Test is Portal_Initializer { /// has not yet passed. function test_finalizeWithdrawalTransaction_onRecentWithdrawal_reverts() external { // Setup the Oracle to return an output with a recent timestamp - uint256 recentTimestamp = block.timestamp - 1000; + uint256 recentTimestamp = block.timestamp - 1; vm.mockCall( - address(op.L2_ORACLE()), + address(optimismPortal.L2_ORACLE()), abi.encodeWithSelector(L2OutputOracle.getL2Output.selector), abi.encode(Types.OutputProposal(_outputRoot, uint128(recentTimestamp), uint128(_proposedBlockNumber))) ); - op.proveWithdrawalTransaction(_defaultTx, _proposedOutputIndex, _outputRootProof, _withdrawalProof); + optimismPortal.proveWithdrawalTransaction(_defaultTx, _proposedOutputIndex, _outputRootProof, _withdrawalProof); vm.expectRevert("OptimismPortal: proven withdrawal finalization period has not elapsed"); - op.finalizeWithdrawalTransaction(_defaultTx); + optimismPortal.finalizeWithdrawalTransaction(_defaultTx); } /// @dev Tests that `finalizeWithdrawalTransaction` reverts if the withdrawal has already been @@ -710,15 +702,15 @@ contract OptimismPortal_FinalizeWithdrawal_Test is Portal_Initializer { function test_finalizeWithdrawalTransaction_onReplay_reverts() external { vm.expectEmit(true, true, true, true); emit WithdrawalProven(_withdrawalHash, alice, bob); - op.proveWithdrawalTransaction(_defaultTx, _proposedOutputIndex, _outputRootProof, _withdrawalProof); + optimismPortal.proveWithdrawalTransaction(_defaultTx, _proposedOutputIndex, _outputRootProof, _withdrawalProof); - vm.warp(block.timestamp + oracle.FINALIZATION_PERIOD_SECONDS() + 1); + vm.warp(block.timestamp + l2OutputOracle.FINALIZATION_PERIOD_SECONDS() + 1); vm.expectEmit(true, true, true, true); emit WithdrawalFinalized(_withdrawalHash, true); - op.finalizeWithdrawalTransaction(_defaultTx); + optimismPortal.finalizeWithdrawalTransaction(_defaultTx); vm.expectRevert("OptimismPortal: withdrawal has already been finalized"); - op.finalizeWithdrawalTransaction(_defaultTx); + optimismPortal.finalizeWithdrawalTransaction(_defaultTx); } /// @dev Tests that `finalizeWithdrawalTransaction` reverts if the withdrawal transaction @@ -746,7 +738,7 @@ contract OptimismPortal_FinalizeWithdrawal_Test is Portal_Initializer { }); vm.mockCall( - address(op.L2_ORACLE()), + address(optimismPortal.L2_ORACLE()), abi.encodeWithSelector(L2OutputOracle.getL2Output.selector), abi.encode( Types.OutputProposal( @@ -757,11 +749,13 @@ contract OptimismPortal_FinalizeWithdrawal_Test is Portal_Initializer { ) ); - op.proveWithdrawalTransaction(insufficientGasTx, _proposedOutputIndex, outputRootProof, withdrawalProof); + optimismPortal.proveWithdrawalTransaction( + insufficientGasTx, _proposedOutputIndex, outputRootProof, withdrawalProof + ); - vm.warp(block.timestamp + oracle.FINALIZATION_PERIOD_SECONDS() + 1); + vm.warp(block.timestamp + l2OutputOracle.FINALIZATION_PERIOD_SECONDS() + 1); vm.expectRevert("SafeCall: Not enough gas"); - op.finalizeWithdrawalTransaction{ gas: gasLimit }(insufficientGasTx); + optimismPortal.finalizeWithdrawalTransaction{ gas: gasLimit }(insufficientGasTx); } /// @dev Tests that `finalizeWithdrawalTransaction` reverts if a sub-call attempts to finalize @@ -791,22 +785,22 @@ contract OptimismPortal_FinalizeWithdrawal_Test is Portal_Initializer { }); // Setup the Oracle to return the outputRoot we want as well as a finalized timestamp. - uint256 finalizedTimestamp = block.timestamp - oracle.FINALIZATION_PERIOD_SECONDS() - 1; + uint256 finalizedTimestamp = block.timestamp - l2OutputOracle.FINALIZATION_PERIOD_SECONDS() - 1; vm.mockCall( - address(op.L2_ORACLE()), + address(optimismPortal.L2_ORACLE()), abi.encodeWithSelector(L2OutputOracle.getL2Output.selector), abi.encode(Types.OutputProposal(outputRoot, uint128(finalizedTimestamp), uint128(_proposedBlockNumber))) ); vm.expectEmit(true, true, true, true); emit WithdrawalProven(withdrawalHash, alice, address(this)); - op.proveWithdrawalTransaction(_testTx, _proposedBlockNumber, outputRootProof, withdrawalProof); + optimismPortal.proveWithdrawalTransaction(_testTx, _proposedBlockNumber, outputRootProof, withdrawalProof); - vm.warp(block.timestamp + oracle.FINALIZATION_PERIOD_SECONDS() + 1); + vm.warp(block.timestamp + l2OutputOracle.FINALIZATION_PERIOD_SECONDS() + 1); vm.expectCall(address(this), _testTx.data); vm.expectEmit(true, true, true, true); emit WithdrawalFinalized(withdrawalHash, true); - op.finalizeWithdrawalTransaction(_testTx); + optimismPortal.finalizeWithdrawalTransaction(_testTx); // Ensure that bob's balance was not changed by the reentrant call. assert(address(bob).balance == bobBalanceBefore); @@ -823,7 +817,7 @@ contract OptimismPortal_FinalizeWithdrawal_Test is Portal_Initializer { external { vm.assume( - _target != address(op) // Cannot call the optimism portal or a contract + _target != address(optimismPortal) // Cannot call the optimism portal or a contract && _target.code.length == 0 // No accounts with code && _target != CONSOLE // The console has no code but behaves like a contract && uint160(_target) > 9 // No precompiles (or zero address) @@ -831,10 +825,10 @@ contract OptimismPortal_FinalizeWithdrawal_Test is Portal_Initializer { // Total ETH supply is currently about 120M ETH. uint256 value = bound(_value, 0, 200_000_000 ether); - vm.deal(address(op), value); + vm.deal(address(optimismPortal), value); uint256 gasLimit = bound(_gasLimit, 0, 50_000_000); - uint256 nonce = messagePasser.messageNonce(); + uint256 nonce = l2ToL1MessagePasser.messageNonce(); // Get a withdrawal transaction and mock proof from the differential testing script. Types.WithdrawalTransaction memory _tx = Types.WithdrawalTransaction({ @@ -867,58 +861,46 @@ contract OptimismPortal_FinalizeWithdrawal_Test is Portal_Initializer { // Setup the Oracle to return the outputRoot vm.mockCall( - address(oracle), - abi.encodeWithSelector(oracle.getL2Output.selector), + address(l2OutputOracle), + abi.encodeWithSelector(l2OutputOracle.getL2Output.selector), abi.encode(outputRoot, block.timestamp, 100) ); // Prove the withdrawal transaction - op.proveWithdrawalTransaction( + optimismPortal.proveWithdrawalTransaction( _tx, 100, // l2BlockNumber proof, withdrawalProof ); - (bytes32 _root,,) = op.provenWithdrawals(withdrawalHash); + (bytes32 _root,,) = optimismPortal.provenWithdrawals(withdrawalHash); assertTrue(_root != bytes32(0)); // Warp past the finalization period - vm.warp(block.timestamp + oracle.FINALIZATION_PERIOD_SECONDS() + 1); + vm.warp(block.timestamp + l2OutputOracle.FINALIZATION_PERIOD_SECONDS() + 1); // Finalize the withdrawal transaction vm.expectCallMinGas(_tx.target, _tx.value, uint64(_tx.gasLimit), _tx.data); - op.finalizeWithdrawalTransaction(_tx); - assertTrue(op.finalizedWithdrawals(withdrawalHash)); + optimismPortal.finalizeWithdrawalTransaction(_tx); + assertTrue(optimismPortal.finalizedWithdrawals(withdrawalHash)); } } -contract OptimismPortalUpgradeable_Test is Portal_Initializer { - Proxy internal proxy; - uint64 initialBlockNum; - - /// @dev Sets up the test. - function setUp() public override { - super.setUp(); - initialBlockNum = uint64(block.number); - proxy = Proxy(payable(address(op))); - } - +contract OptimismPortalUpgradeable_Test is CommonTest { /// @dev Tests that the proxy is initialized correctly. function test_params_initValuesOnProxy_succeeds() external { - OptimismPortal p = OptimismPortal(payable(address(proxy))); - - (uint128 prevBaseFee, uint64 prevBoughtGas, uint64 prevBlockNum) = p.params(); - + (uint128 prevBaseFee, uint64 prevBoughtGas, uint64 prevBlockNum) = optimismPortal.params(); ResourceMetering.ResourceConfig memory rcfg = systemConfig.resourceConfig(); + assertEq(prevBaseFee, rcfg.minimumBaseFee); assertEq(prevBoughtGas, 0); - assertEq(prevBlockNum, initialBlockNum); + assertEq(prevBlockNum, block.number); } /// @dev Tests that the proxy cannot be initialized twice. function test_initialize_cannotInitProxy_reverts() external { vm.expectRevert("Initializable: contract is already initialized"); - OptimismPortal(payable(proxy)).initialize({ + optimismPortal.initialize({ _l2Oracle: L2OutputOracle(address(0)), _systemConfig: SystemConfig(address(0)), _guardian: address(0), @@ -928,8 +910,9 @@ contract OptimismPortalUpgradeable_Test is Portal_Initializer { /// @dev Tests that the implementation cannot be initialized twice. function test_initialize_cannotInitImpl_reverts() external { + address opImpl = mustGetAddress("OptimismPortal"); vm.expectRevert("Initializable: contract is already initialized"); - OptimismPortal(opImpl).initialize({ + OptimismPortal(payable(opImpl)).initialize({ _l2Oracle: L2OutputOracle(address(0)), _systemConfig: SystemConfig(address(0)), _guardian: address(0), @@ -940,21 +923,22 @@ contract OptimismPortalUpgradeable_Test is Portal_Initializer { /// @dev Tests that the proxy can be upgraded. function test_upgradeToAndCall_upgrading_succeeds() external { // Check an unused slot before upgrading. - bytes32 slot21Before = vm.load(address(op), bytes32(uint256(21))); + bytes32 slot21Before = vm.load(address(optimismPortal), bytes32(uint256(21))); assertEq(bytes32(0), slot21Before); NextImpl nextImpl = new NextImpl(); - vm.startPrank(multisig); + + vm.startPrank(EIP1967Helper.getAdmin(address(optimismPortal))); // The value passed to the initialize must be larger than the last value // that initialize was called with. - proxy.upgradeToAndCall( + Proxy(payable(address(optimismPortal))).upgradeToAndCall( address(nextImpl), abi.encodeWithSelector(NextImpl.initialize.selector, Constants.INITIALIZER + 1) ); - assertEq(proxy.implementation(), address(nextImpl)); + assertEq(Proxy(payable(address(optimismPortal))).implementation(), address(nextImpl)); // Verify that the NextImpl contract initialized its values according as expected - bytes32 slot21After = vm.load(address(op), bytes32(uint256(21))); - bytes32 slot21Expected = NextImpl(address(op)).slot21Init(); + bytes32 slot21After = vm.load(address(optimismPortal), bytes32(uint256(21))); + bytes32 slot21Expected = NextImpl(address(optimismPortal)).slot21Init(); assertEq(slot21Expected, slot21After); } } @@ -962,7 +946,7 @@ contract OptimismPortalUpgradeable_Test is Portal_Initializer { /// @title OptimismPortalResourceFuzz_Test /// @dev Test various values of the resource metering config to ensure that deposits cannot be /// broken by changing the config. -contract OptimismPortalResourceFuzz_Test is Portal_Initializer { +contract OptimismPortalResourceFuzz_Test is CommonTest { /// @dev The max gas limit observed throughout this test. Setting this too high can cause /// the test to take too long to run. uint256 constant MAX_GAS_LIMIT = 30_000_000; @@ -997,6 +981,8 @@ contract OptimismPortalResourceFuzz_Test is Portal_Initializer { vm.assume(((_maxResourceLimit / _elasticityMultiplier) * _elasticityMultiplier) == _maxResourceLimit); _prevBoughtGas = uint64(bound(_prevBoughtGas, 0, _maxResourceLimit - _gasLimit)); _blockDiff = uint8(bound(_blockDiff, 0, 3)); + // Pick a pseudorandom block number + vm.roll(uint256(keccak256(abi.encode(_blockDiff))) % uint256(type(uint16).max) + uint256(_blockDiff)); // Create a resource config to mock the call to the system config with ResourceMetering.ResourceConfig memory rcfg = ResourceMetering.ResourceConfig({ @@ -1014,18 +1000,18 @@ contract OptimismPortalResourceFuzz_Test is Portal_Initializer { // Set the resource params uint256 _prevBlockNum = block.number - _blockDiff; vm.store( - address(op), + address(optimismPortal), bytes32(uint256(1)), bytes32((_prevBlockNum << 192) | (uint256(_prevBoughtGas) << 128) | _prevBaseFee) ); // Ensure that the storage setting is correct - (uint128 prevBaseFee, uint64 prevBoughtGas, uint64 prevBlockNum) = op.params(); + (uint128 prevBaseFee, uint64 prevBoughtGas, uint64 prevBlockNum) = optimismPortal.params(); assertEq(prevBaseFee, _prevBaseFee); assertEq(prevBoughtGas, _prevBoughtGas); assertEq(prevBlockNum, _prevBlockNum); // Do a deposit, should not revert - op.depositTransaction{ gas: MAX_GAS_LIMIT }({ + optimismPortal.depositTransaction{ gas: MAX_GAS_LIMIT }({ _to: address(0x20), _value: 0x40, _gasLimit: _gasLimit, diff --git a/packages/contracts-bedrock/test/Optimist.t.sol b/packages/contracts-bedrock/test/Optimist.t.sol index f08656bf20da7..9502796e4e6a1 100644 --- a/packages/contracts-bedrock/test/Optimist.t.sol +++ b/packages/contracts-bedrock/test/Optimist.t.sol @@ -3,11 +3,11 @@ pragma solidity >=0.6.2 <0.9.0; // Testing utilities import { Test } from "forge-std/Test.sol"; -import { AttestationStation } from "../src/periphery/op-nft/AttestationStation.sol"; -import { Optimist } from "../src/periphery/op-nft/Optimist.sol"; -import { OptimistAllowlist } from "../src/periphery/op-nft/OptimistAllowlist.sol"; -import { OptimistInviter } from "../src/periphery/op-nft/OptimistInviter.sol"; -import { OptimistInviterHelper } from "./Helpers.sol"; +import { AttestationStation } from "src/periphery/op-nft/AttestationStation.sol"; +import { Optimist } from "src/periphery/op-nft/Optimist.sol"; +import { OptimistAllowlist } from "src/periphery/op-nft/OptimistAllowlist.sol"; +import { OptimistInviter } from "src/periphery/op-nft/OptimistInviter.sol"; +import { OptimistInviterHelper } from "test/mocks/OptimistInviterHelper.sol"; import { Strings } from "@openzeppelin/contracts/utils/Strings.sol"; import { IERC721 } from "@openzeppelin/contracts/token/ERC721/IERC721.sol"; diff --git a/packages/contracts-bedrock/test/OptimistAllowlist.t.sol b/packages/contracts-bedrock/test/OptimistAllowlist.t.sol index 4a3d59db14c5a..4855802489c35 100644 --- a/packages/contracts-bedrock/test/OptimistAllowlist.t.sol +++ b/packages/contracts-bedrock/test/OptimistAllowlist.t.sol @@ -3,11 +3,11 @@ pragma solidity 0.8.15; // Testing utilities import { Test } from "forge-std/Test.sol"; -import { AttestationStation } from "../src/periphery/op-nft/AttestationStation.sol"; -import { OptimistAllowlist } from "../src/periphery/op-nft/OptimistAllowlist.sol"; -import { OptimistInviter } from "../src/periphery/op-nft/OptimistInviter.sol"; -import { OptimistInviterHelper } from "./Helpers.sol"; -import { OptimistConstants } from "../src/periphery/op-nft/libraries/OptimistConstants.sol"; +import { AttestationStation } from "src/periphery/op-nft/AttestationStation.sol"; +import { OptimistAllowlist } from "src/periphery/op-nft/OptimistAllowlist.sol"; +import { OptimistInviter } from "src/periphery/op-nft/OptimistInviter.sol"; +import { OptimistInviterHelper } from "test/mocks/OptimistInviterHelper.sol"; +import { OptimistConstants } from "src/periphery/op-nft/libraries/OptimistConstants.sol"; contract OptimistAllowlist_Initializer is Test { event AttestationCreated(address indexed creator, address indexed about, bytes32 indexed key, bytes val); diff --git a/packages/contracts-bedrock/test/OptimistInviter.t.sol b/packages/contracts-bedrock/test/OptimistInviter.t.sol index 6c73f06889256..53d24105d122d 100644 --- a/packages/contracts-bedrock/test/OptimistInviter.t.sol +++ b/packages/contracts-bedrock/test/OptimistInviter.t.sol @@ -3,13 +3,13 @@ pragma solidity 0.8.15; // Testing utilities import { Test } from "forge-std/Test.sol"; -import { AttestationStation } from "../src/periphery/op-nft/AttestationStation.sol"; -import { OptimistInviter } from "../src/periphery/op-nft/OptimistInviter.sol"; -import { Optimist } from "../src/periphery/op-nft/Optimist.sol"; +import { AttestationStation } from "src/periphery/op-nft/AttestationStation.sol"; +import { OptimistInviter } from "src/periphery/op-nft/OptimistInviter.sol"; +import { Optimist } from "src/periphery/op-nft/Optimist.sol"; import { Strings } from "@openzeppelin/contracts/utils/Strings.sol"; -import { TestERC1271Wallet } from "./Helpers.sol"; -import { OptimistInviterHelper } from "./Helpers.sol"; -import { OptimistConstants } from "../src/periphery/op-nft/libraries/OptimistConstants.sol"; +import { TestERC1271Wallet } from "test/mocks/TestERC1271Wallet.sol"; +import { OptimistInviterHelper } from "test/mocks/OptimistInviterHelper.sol"; +import { OptimistConstants } from "src/periphery/op-nft/libraries/OptimistConstants.sol"; contract OptimistInviter_Initializer is Test { event InviteClaimed(address indexed issuer, address indexed claimer); diff --git a/packages/contracts-bedrock/test/PreimageOracle.t.sol b/packages/contracts-bedrock/test/PreimageOracle.t.sol index 9f1cd73460735..5da715a8e82a5 100644 --- a/packages/contracts-bedrock/test/PreimageOracle.t.sol +++ b/packages/contracts-bedrock/test/PreimageOracle.t.sol @@ -32,7 +32,7 @@ contract PreimageOracle_Test is Test { uint8 partOffset = 0; // Load the local data into the preimage oracle under the test contract's context. - bytes32 contextKey = oracle.loadLocalData(ident, word, size, partOffset); + bytes32 contextKey = oracle.loadLocalData(ident, 0, word, size, partOffset); // Validate that the pre-image part is set bool ok = oracle.preimagePartOk(contextKey, partOffset); @@ -47,9 +47,39 @@ contract PreimageOracle_Test is Test { assertEq(length, size); } + /// @notice Tests that multiple local key contexts can be used by the same address for the + /// same local data identifier. + function test_loadLocalData_multipleContexts_succeeds() public { + uint256 ident = 1; + uint8 size = 4; + uint8 partOffset = 0; + + // Form the words we'll be storing + bytes32[2] memory words = [bytes32(uint256(0xdeadbeef) << 224), bytes32(uint256(0xbeefbabe) << 224)]; + + for (uint256 i; i < words.length; i++) { + // Load the local data into the preimage oracle under the test contract's context + // and the given local context. + bytes32 contextKey = oracle.loadLocalData(ident, i, words[i], size, partOffset); + + // Validate that the pre-image part is set + bool ok = oracle.preimagePartOk(contextKey, partOffset); + assertTrue(ok); + + // Validate the local data part + bytes32 expectedPart = bytes32(uint256(words[i] >> 64) | uint256(size) << 192); + assertEq(oracle.preimageParts(contextKey, partOffset), expectedPart); + + // Validate the local data length + uint256 length = oracle.preimageLengths(contextKey); + assertEq(length, size); + } + } + /// @notice Tests that context-specific data [0, 32] bytes in length can be loaded correctly. function testFuzz_loadLocalData_varyingLength_succeeds( uint256 ident, + uint256 localContext, bytes32 word, uint256 size, uint256 partOffset @@ -62,7 +92,7 @@ contract PreimageOracle_Test is Test { partOffset = bound(partOffset, 0, size + 8); // Load the local data into the preimage oracle under the test contract's context. - bytes32 contextKey = oracle.loadLocalData(ident, word, uint8(size), uint8(partOffset)); + bytes32 contextKey = oracle.loadLocalData(ident, localContext, word, uint8(size), uint8(partOffset)); // Validate that the first local data part is set bool ok = oracle.preimagePartOk(contextKey, partOffset); @@ -112,7 +142,7 @@ contract PreimageOracle_Test is Test { uint256 offset = preimage.length + 9; vm.expectRevert(PartOffsetOOB.selector); - oracle.loadLocalData(1, preimage, 32, offset); + oracle.loadLocalData(1, 0, preimage, 32, offset); } /// @notice Tests that a pre-image cannot be set with an out-of-bounds offset. diff --git a/packages/contracts-bedrock/test/ProtocolVersions.t.sol b/packages/contracts-bedrock/test/ProtocolVersions.t.sol index 5c01bafb5e467..c8201495e7a94 100644 --- a/packages/contracts-bedrock/test/ProtocolVersions.t.sol +++ b/packages/contracts-bedrock/test/ProtocolVersions.t.sol @@ -2,7 +2,8 @@ pragma solidity 0.8.15; // Testing utilities -import { CommonTest } from "./CommonTest.t.sol"; +import { CommonTest } from "test/setup/CommonTest.sol"; +import { EIP1967Helper } from "test/mocks/EIP1967Helper.sol"; // Libraries import { Constants } from "src/libraries/Constants.sol"; @@ -14,44 +15,27 @@ import { Proxy } from "src/universal/Proxy.sol"; import { ProtocolVersions, ProtocolVersion } from "src/L1/ProtocolVersions.sol"; contract ProtocolVersions_Init is CommonTest { - ProtocolVersions protocolVersions; - ProtocolVersions protocolVersionsImpl; - event ConfigUpdate(uint256 indexed version, ProtocolVersions.UpdateType indexed updateType, bytes data); - // Dummy values used to test getters - ProtocolVersion constant required = ProtocolVersion.wrap(0xabcd); - ProtocolVersion constant recommended = ProtocolVersion.wrap(0x1234); + ProtocolVersion required; + ProtocolVersion recommended; function setUp() public virtual override { super.setUp(); - - Proxy proxy = new Proxy(multisig); - protocolVersionsImpl = new ProtocolVersions(); - - vm.prank(multisig); - proxy.upgradeToAndCall( - address(protocolVersionsImpl), - abi.encodeCall( - ProtocolVersions.initialize, - ( - alice, // _owner, - required, - recommended - ) - ) - ); - - protocolVersions = ProtocolVersions(address(proxy)); + required = ProtocolVersion.wrap(cfg.requiredProtocolVersion()); + recommended = ProtocolVersion.wrap(cfg.recommendedProtocolVersion()); } } contract ProtocolVersions_Initialize_Test is ProtocolVersions_Init { /// @dev Tests that initialization sets the correct values. function test_initialize_values_succeeds() external { + ProtocolVersions protocolVersionsImpl = ProtocolVersions(mustGetAddress("ProtocolVersions")); + address owner = cfg.finalSystemOwner(); + assertEq(ProtocolVersion.unwrap(protocolVersions.required()), ProtocolVersion.unwrap(required)); assertEq(ProtocolVersion.unwrap(protocolVersions.recommended()), ProtocolVersion.unwrap(recommended)); - assertEq(protocolVersions.owner(), alice); + assertEq(protocolVersions.owner(), owner); assertEq(ProtocolVersion.unwrap(protocolVersionsImpl.required()), 0); assertEq(ProtocolVersion.unwrap(protocolVersionsImpl.recommended()), 0); @@ -60,6 +44,7 @@ contract ProtocolVersions_Initialize_Test is ProtocolVersions_Init { /// @dev Ensures that the events are emitted during initialization. function test_initialize_events_succeeds() external { + ProtocolVersions protocolVersionsImpl = ProtocolVersions(mustGetAddress("ProtocolVersions")); assertEq(protocolVersionsImpl.owner(), address(0xdEad)); // Wipe out the initialized slot so the proxy can be initialized again @@ -71,7 +56,7 @@ contract ProtocolVersions_Initialize_Test is ProtocolVersions_Init { vm.expectEmit(true, true, true, true, address(protocolVersions)); emit ConfigUpdate(0, ProtocolVersions.UpdateType.RECOMMENDED_PROTOCOL_VERSION, abi.encode(recommended)); - vm.prank(multisig); + vm.prank(EIP1967Helper.getAdmin(address(protocolVersions))); Proxy(payable(address(protocolVersions))).upgradeToAndCall( address(protocolVersionsImpl), abi.encodeCall( diff --git a/packages/contracts-bedrock/test/Proxy.t.sol b/packages/contracts-bedrock/test/Proxy.t.sol index 8474f50aea772..fa794dd295b28 100644 --- a/packages/contracts-bedrock/test/Proxy.t.sol +++ b/packages/contracts-bedrock/test/Proxy.t.sol @@ -2,7 +2,7 @@ pragma solidity 0.8.15; import { Test } from "forge-std/Test.sol"; -import { Proxy } from "../src/universal/Proxy.sol"; +import { Proxy } from "src/universal/Proxy.sol"; import { Bytes32AddressLib } from "@rari-capital/solmate/src/utils/Bytes32AddressLib.sol"; contract SimpleStorage { diff --git a/packages/contracts-bedrock/test/ProxyAdmin.t.sol b/packages/contracts-bedrock/test/ProxyAdmin.t.sol index 49b290f25bb9d..083ba04c2fe58 100644 --- a/packages/contracts-bedrock/test/ProxyAdmin.t.sol +++ b/packages/contracts-bedrock/test/ProxyAdmin.t.sol @@ -2,12 +2,12 @@ pragma solidity 0.8.15; import { Test } from "forge-std/Test.sol"; -import { Proxy } from "../src/universal/Proxy.sol"; -import { ProxyAdmin } from "../src/universal/ProxyAdmin.sol"; -import { SimpleStorage } from "./Proxy.t.sol"; -import { L1ChugSplashProxy } from "../src/legacy/L1ChugSplashProxy.sol"; -import { ResolvedDelegateProxy } from "../src/legacy/ResolvedDelegateProxy.sol"; -import { AddressManager } from "../src/legacy/AddressManager.sol"; +import { Proxy } from "src/universal/Proxy.sol"; +import { ProxyAdmin } from "src/universal/ProxyAdmin.sol"; +import { SimpleStorage } from "test/Proxy.t.sol"; +import { L1ChugSplashProxy } from "src/legacy/L1ChugSplashProxy.sol"; +import { ResolvedDelegateProxy } from "src/legacy/ResolvedDelegateProxy.sol"; +import { AddressManager } from "src/legacy/AddressManager.sol"; contract ProxyAdmin_Test is Test { address alice = address(64); diff --git a/packages/contracts-bedrock/test/RLP.t.sol b/packages/contracts-bedrock/test/RLP.t.sol deleted file mode 100644 index fadd5b21bec1e..0000000000000 --- a/packages/contracts-bedrock/test/RLP.t.sol +++ /dev/null @@ -1,46 +0,0 @@ -// SPDX-License-Identifier: Unlicense -pragma solidity ^0.8.0; - -import { Bytes32AddressLib } from "@rari-capital/solmate/src/utils/Bytes32AddressLib.sol"; - -/// @title LibRLP -/// @notice Via https://github.com/Rari-Capital/solmate/issues/207. -library LibRLP { - using Bytes32AddressLib for bytes32; - - function computeAddress(address deployer, uint256 nonce) internal pure returns (address) { - // The integer zero is treated as an empty byte string, and as a result it only has a length prefix, 0x80, - // computed via 0x80 + 0. - // A one byte integer uses its own value as its length prefix, there is no additional "0x80 + length" prefix - // that comes before it. - if (nonce == 0x00) { - return keccak256(abi.encodePacked(bytes1(0xd6), bytes1(0x94), deployer, bytes1(0x80))).fromLast20Bytes(); - } - if (nonce <= 0x7f) { - return keccak256(abi.encodePacked(bytes1(0xd6), bytes1(0x94), deployer, uint8(nonce))).fromLast20Bytes(); - } - - // Nonces greater than 1 byte all follow a consistent encoding scheme, where each value is preceded by a prefix - // of 0x80 + length. - if (nonce <= type(uint8).max) { - return keccak256(abi.encodePacked(bytes1(0xd7), bytes1(0x94), deployer, bytes1(0x81), uint8(nonce))) - .fromLast20Bytes(); - } - if (nonce <= type(uint16).max) { - return keccak256(abi.encodePacked(bytes1(0xd8), bytes1(0x94), deployer, bytes1(0x82), uint16(nonce))) - .fromLast20Bytes(); - } - if (nonce <= type(uint24).max) { - return keccak256(abi.encodePacked(bytes1(0xd9), bytes1(0x94), deployer, bytes1(0x83), uint24(nonce))) - .fromLast20Bytes(); - } - - // More details about RLP encoding can be found here: https://eth.wiki/fundamentals/rlp - // 0xda = 0xc0 (short RLP prefix) + 0x16 (length of: 0x94 ++ proxy ++ 0x84 ++ nonce) - // 0x94 = 0x80 + 0x14 (0x14 = the length of an address, 20 bytes, in hex) - // 0x84 = 0x80 + 0x04 (0x04 = the bytes length of the nonce, 4 bytes, in hex) - // We assume nobody can have a nonce large enough to require more than 32 bytes. - return keccak256(abi.encodePacked(bytes1(0xda), bytes1(0x94), deployer, bytes1(0x84), uint32(nonce))) - .fromLast20Bytes(); - } -} diff --git a/packages/contracts-bedrock/test/RLPReader.t.sol b/packages/contracts-bedrock/test/RLPReader.t.sol index 2276370a69d23..7d4cf189fbe92 100644 --- a/packages/contracts-bedrock/test/RLPReader.t.sol +++ b/packages/contracts-bedrock/test/RLPReader.t.sol @@ -2,10 +2,10 @@ pragma solidity 0.8.15; import { stdError } from "forge-std/Test.sol"; -import { CommonTest } from "./CommonTest.t.sol"; -import { RLPReader } from "../src/libraries/rlp/RLPReader.sol"; +import { Test } from "forge-std/Test.sol"; +import { RLPReader } from "src/libraries/rlp/RLPReader.sol"; -contract RLPReader_readBytes_Test is CommonTest { +contract RLPReader_readBytes_Test is Test { function test_readBytes_bytestring00_succeeds() external { assertEq(RLPReader.readBytes(hex"00"), hex"00"); } @@ -44,7 +44,7 @@ contract RLPReader_readBytes_Test is CommonTest { } } -contract RLPReader_readList_Test is CommonTest { +contract RLPReader_readList_Test is Test { function test_readList_empty_succeeds() external { RLPReader.RLPItem[] memory list = RLPReader.readList(hex"c0"); assertEq(list.length, 0); diff --git a/packages/contracts-bedrock/test/RLPWriter.t.sol b/packages/contracts-bedrock/test/RLPWriter.t.sol index 6b3468c81ae94..86faffd05fc5b 100644 --- a/packages/contracts-bedrock/test/RLPWriter.t.sol +++ b/packages/contracts-bedrock/test/RLPWriter.t.sol @@ -1,10 +1,10 @@ // SPDX-License-Identifier: MIT pragma solidity 0.8.15; -import { RLPWriter } from "../src/libraries/rlp/RLPWriter.sol"; -import { CommonTest } from "./CommonTest.t.sol"; +import { RLPWriter } from "src/libraries/rlp/RLPWriter.sol"; +import { Test } from "forge-std/Test.sol"; -contract RLPWriter_writeString_Test is CommonTest { +contract RLPWriter_writeString_Test is Test { function test_writeString_empty_succeeds() external { assertEq(RLPWriter.writeString(""), hex"80"); } @@ -49,7 +49,7 @@ contract RLPWriter_writeString_Test is CommonTest { } } -contract RLPWriter_writeUint_Test is CommonTest { +contract RLPWriter_writeUint_Test is Test { function test_writeUint_zero_succeeds() external { assertEq(RLPWriter.writeUint(0x0), hex"80"); } @@ -83,7 +83,7 @@ contract RLPWriter_writeUint_Test is CommonTest { } } -contract RLPWriter_writeList_Test is CommonTest { +contract RLPWriter_writeList_Test is Test { function test_writeList_empty_succeeds() external { assertEq(RLPWriter.writeList(new bytes[](0)), hex"c0"); } diff --git a/packages/contracts-bedrock/test/ResolvedDelegateProxy.t.sol b/packages/contracts-bedrock/test/ResolvedDelegateProxy.t.sol index d740bc3859646..33a81bc2ca0e1 100644 --- a/packages/contracts-bedrock/test/ResolvedDelegateProxy.t.sol +++ b/packages/contracts-bedrock/test/ResolvedDelegateProxy.t.sol @@ -5,10 +5,10 @@ pragma solidity 0.8.15; import { Test } from "forge-std/Test.sol"; // Target contract dependencies -import { AddressManager } from "../src/legacy/AddressManager.sol"; +import { AddressManager } from "src/legacy/AddressManager.sol"; // Target contract -import { ResolvedDelegateProxy } from "../src/legacy/ResolvedDelegateProxy.sol"; +import { ResolvedDelegateProxy } from "src/legacy/ResolvedDelegateProxy.sol"; contract ResolvedDelegateProxy_Test is Test { AddressManager internal addressManager; diff --git a/packages/contracts-bedrock/test/ResourceMetering.t.sol b/packages/contracts-bedrock/test/ResourceMetering.t.sol index 2493896b8055b..01fcab1c92644 100644 --- a/packages/contracts-bedrock/test/ResourceMetering.t.sol +++ b/packages/contracts-bedrock/test/ResourceMetering.t.sol @@ -5,13 +5,13 @@ pragma solidity 0.8.15; import { Test } from "forge-std/Test.sol"; // Libraries -import { Constants } from "../src/libraries/Constants.sol"; +import { Constants } from "src/libraries/Constants.sol"; // Target contract dependencies -import { Proxy } from "../src/universal/Proxy.sol"; +import { Proxy } from "src/universal/Proxy.sol"; // Target contract -import { ResourceMetering } from "../src/L1/ResourceMetering.sol"; +import { ResourceMetering } from "src/L1/ResourceMetering.sol"; contract MeterUser is ResourceMetering { ResourceMetering.ResourceConfig public innerConfig; diff --git a/packages/contracts-bedrock/test/SafeCall.t.sol b/packages/contracts-bedrock/test/SafeCall.t.sol index 308344787414f..e3a9e05fdbb2f 100644 --- a/packages/contracts-bedrock/test/SafeCall.t.sol +++ b/packages/contracts-bedrock/test/SafeCall.t.sol @@ -2,18 +2,18 @@ pragma solidity 0.8.15; // Testing utilities -import { CommonTest } from "./CommonTest.t.sol"; +import { Test } from "forge-std/Test.sol"; // Target contract -import { SafeCall } from "../src/libraries/SafeCall.sol"; +import { SafeCall } from "src/libraries/SafeCall.sol"; -contract SafeCall_Test is CommonTest { +contract SafeCall_Test is Test { /// @dev Tests that the `send` function succeeds. function testFuzz_send_succeeds(address from, address to, uint256 gas, uint64 value) external { vm.assume(from.balance == 0); vm.assume(to.balance == 0); // no precompiles (mainnet) - assumeNoPrecompiles(to, 1); + assumeNotPrecompile(to); // don't call the vm vm.assume(to != address(vm)); vm.assume(from != address(vm)); @@ -21,8 +21,7 @@ contract SafeCall_Test is CommonTest { vm.assume(to != address(0x000000000000000000636F6e736F6c652e6c6f67)); // don't call the create2 deployer vm.assume(to != address(0x4e59b44847b379578588920cA78FbF26c0B4956C)); - // don't call the ffi interface - vm.assume(to != address(0x5615dEB798BB3E4dFa0139dFa1b3D433Cc23b72f)); + vm.assume(to != address(this)); assertEq(from.balance, 0, "from balance is 0"); vm.deal(from, value); @@ -48,7 +47,7 @@ contract SafeCall_Test is CommonTest { vm.assume(from.balance == 0); vm.assume(to.balance == 0); // no precompiles (mainnet) - assumeNoPrecompiles(to, 1); + assumeNotPrecompile(to); // don't call the vm vm.assume(to != address(vm)); vm.assume(from != address(vm)); @@ -56,8 +55,7 @@ contract SafeCall_Test is CommonTest { vm.assume(to != address(0x000000000000000000636F6e736F6c652e6c6f67)); // don't call the create2 deployer vm.assume(to != address(0x4e59b44847b379578588920cA78FbF26c0B4956C)); - // don't call the ffi interface - vm.assume(to != address(0x5615dEB798BB3E4dFa0139dFa1b3D433Cc23b72f)); + vm.assume(to != address(this)); assertEq(from.balance, 0, "from balance is 0"); vm.deal(from, value); @@ -91,7 +89,7 @@ contract SafeCall_Test is CommonTest { vm.assume(from.balance == 0); vm.assume(to.balance == 0); // no precompiles (mainnet) - assumeNoPrecompiles(to, 1); + assumeNotPrecompile(to); // don't call the vm vm.assume(to != address(vm)); vm.assume(from != address(vm)); @@ -99,8 +97,7 @@ contract SafeCall_Test is CommonTest { vm.assume(to != address(0x000000000000000000636F6e736F6c652e6c6f67)); // don't call the create2 deployer vm.assume(to != address(0x4e59b44847b379578588920cA78FbF26c0B4956C)); - // don't call the FFIInterface - vm.assume(to != address(0x5615dEB798BB3E4dFa0139dFa1b3D433Cc23b72f)); + vm.assume(to != address(this)); assertEq(from.balance, 0, "from balance is 0"); vm.deal(from, value); diff --git a/packages/contracts-bedrock/test/SafeSigners.t.sol b/packages/contracts-bedrock/test/SafeSigners.t.sol new file mode 100644 index 0000000000000..d94d91382fa3b --- /dev/null +++ b/packages/contracts-bedrock/test/SafeSigners.t.sol @@ -0,0 +1,112 @@ +// SPDX-License-Identifier: MIT +pragma solidity 0.8.15; + +import { Test } from "forge-std/Test.sol"; +import { Safe } from "safe-contracts/Safe.sol"; +import { SafeSigners } from "src/Safe/SafeSigners.sol"; +import "test/safe-tools/SafeTestTools.sol"; + +import { SignatureDecoder } from "safe-contracts/common/SignatureDecoder.sol"; + +contract SafeSigners_Test is Test, SafeTestTools { + bytes4 internal constant EIP1271_MAGIC_VALUE = 0x20c13b0b; + + enum SigTypes { + Eoa, + EthSign, + ApprovedHash, + Contract + } + + /// @dev Maps every key to one of the 4 signatures types. + /// This is used in the tests below as a pseudorandom mechanism for determining which + /// signature type to use for each key. + /// @param _key The key to map to a signature type. + function sigType(uint256 _key) internal pure returns (SigTypes sigType_) { + uint256 t = _key % 4; + sigType_ = SigTypes(t); + } + + /// @dev Test that for a given set of signatures: + /// 1. safe.checkNSignatures() succeeds + /// 2. the getSigners() method returns the expected signers + /// 3. the expected signers are all owners of the safe. + /// Demonstrating these three properties is sufficient to prove that the getSigners() method + /// returns the same signatures as those recovered by safe.checkNSignatures(). + function testDiff_getSignaturesVsCheckSignatures_succeeds(bytes memory _data, uint256 _numSigs) external { + bytes32 digest = keccak256(_data); + + // Limit the number of signatures to 25 + uint256 numSigs = bound(_numSigs, 1, 25); + + (, uint256[] memory keys) = SafeTestLib.makeAddrsAndKeys("getSigsTest", numSigs); + for (uint256 i; i < keys.length; i++) { + if (sigType(keys[i]) == SigTypes.Contract) { + keys[i] = + SafeTestLib.encodeSmartContractWalletAsPK(SafeTestLib.decodeSmartContractWalletAsAddress(keys[i])); + } + } + + // Create a new safeInstance with M=N, so that it requires a signature from each key. + SafeInstance memory safeInstance = SafeTestTools._setupSafe(keys, numSigs, 0); + + // Next we will generate signatures by iterating over the keys, and choosing the signature type + // based on the key. + uint8 v; + bytes32 r; + bytes32 s; + uint256 contractSigs; + bytes memory signatures; + uint256[] memory pks = safeInstance.ownerPKs; + for (uint256 i; i < pks.length; i++) { + if (sigType(pks[i]) == SigTypes.Eoa) { + (v, r, s) = vm.sign(pks[i], digest); + signatures = bytes.concat(signatures, abi.encodePacked(r, s, v)); + } else if (sigType(pks[i]) == SigTypes.EthSign) { + (v, r, s) = vm.sign(pks[i], keccak256(abi.encodePacked("\x19Ethereum Signed Message:\n32", digest))); + v += 4; + signatures = bytes.concat(signatures, abi.encodePacked(r, s, v)); + } else if (sigType(pks[i]) == SigTypes.ApprovedHash) { + vm.prank(SafeTestLib.getAddr(pks[i])); + safeInstance.safe.approveHash(digest); + v = 1; + // s is not checked on approved hash signatures, so we can leave it as zero. + r = bytes32(uint256(uint160(SafeTestLib.getAddr(pks[i])))); + signatures = bytes.concat(signatures, abi.encodePacked(r, s, v)); + } else if (sigType(pks[i]) == SigTypes.Contract) { + contractSigs++; + address addr = SafeTestLib.decodeSmartContractWalletAsAddress(pks[i]); + r = bytes32(uint256(uint160(addr))); + vm.mockCall( + addr, abi.encodeWithSignature("isValidSignature(bytes,bytes)"), abi.encode(EIP1271_MAGIC_VALUE) + ); + v = 0; + // s needs to point to data that comes after the signatures + s = bytes32(numSigs * 65); + signatures = bytes.concat(signatures, abi.encodePacked(r, s, v)); + } + } + + // For each contract sig, add 64 bytes to the signature data. This is necessary to satisfy + // the validation checks that the Safe contract performs on the value of s on contract + // signatures. The Safe contract checks that s correctly points to additional data appended + // after the signatures, and that the length of the data is within bounds. + for (uint256 i; i < contractSigs; i++) { + signatures = bytes.concat(signatures, abi.encode(32, 1)); + } + + // Signature checking on the Safe should succeed. + safeInstance.safe.checkNSignatures(digest, _data, signatures, numSigs); + + // Recover the signatures using the _getNSigners() method. + address[] memory gotSigners = + SafeSigners.getNSigners({ dataHash: digest, signatures: signatures, requiredSignatures: numSigs }); + + // Compare the list of recovered signers to the expected signers. + assertEq(gotSigners.length, numSigs); + assertEq(gotSigners.length, safeInstance.owners.length); + for (uint256 i; i < numSigs; i++) { + assertEq(safeInstance.owners[i], gotSigners[i]); + } + } +} diff --git a/packages/contracts-bedrock/test/Semver.t.sol b/packages/contracts-bedrock/test/Semver.t.sol deleted file mode 100644 index c15044eb3fa26..0000000000000 --- a/packages/contracts-bedrock/test/Semver.t.sol +++ /dev/null @@ -1,35 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity 0.8.15; - -import { CommonTest } from "./CommonTest.t.sol"; -import { Semver } from "../src/universal/Semver.sol"; -import { Proxy } from "../src/universal/Proxy.sol"; - -/// @notice Test the Semver contract that is used for semantic versioning -/// of various contracts. -contract Semver_Test is CommonTest { - /// @notice Global semver contract deployed in setUp. This is used in - /// the test cases. - Semver semver; - - /// @notice Deploy a Semver contract - function setUp() public virtual override { - semver = new Semver(7, 8, 0); - } - - /// @notice Test the version getter - function test_version_succeeds() external { - assertEq(semver.version(), "7.8.0"); - } - - /// @notice Since the versions are all immutable, they should - /// be able to be accessed from behind a proxy without needing - /// to initialize the contract. - function test_behindProxy_succeeds() external { - Proxy proxy = new Proxy(alice); - vm.prank(alice); - proxy.upgradeTo(address(semver)); - - assertEq(Semver(address(proxy)).version(), "7.8.0"); - } -} diff --git a/packages/contracts-bedrock/test/SequencerFeeVault.t.sol b/packages/contracts-bedrock/test/SequencerFeeVault.t.sol index 026b80e21d575..b7836de638df2 100644 --- a/packages/contracts-bedrock/test/SequencerFeeVault.t.sol +++ b/packages/contracts-bedrock/test/SequencerFeeVault.t.sol @@ -2,139 +2,156 @@ pragma solidity 0.8.15; // Testing utilities -import { FeeVault_Initializer, Reverter } from "./CommonTest.t.sol"; -import { StandardBridge } from "../src/universal/StandardBridge.sol"; +import { CommonTest } from "test/setup/CommonTest.sol"; +import { Reverter } from "test/mocks/Callers.sol"; +import { StandardBridge } from "src/universal/StandardBridge.sol"; // Libraries -import { Predeploys } from "../src/libraries/Predeploys.sol"; +import { Predeploys } from "src/libraries/Predeploys.sol"; // Target contract dependencies -import { FeeVault } from "../src/universal/FeeVault.sol"; +import { FeeVault } from "src/universal/FeeVault.sol"; // Target contract -import { SequencerFeeVault } from "../src/L2/SequencerFeeVault.sol"; +import { SequencerFeeVault } from "src/L2/SequencerFeeVault.sol"; -contract SequencerFeeVault_Test is FeeVault_Initializer { +contract SequencerFeeVault_Test is CommonTest { + address recipient; /// @dev Sets up the test suite. + function setUp() public override { super.setUp(); - vm.etch( - Predeploys.SEQUENCER_FEE_WALLET, - address(new SequencerFeeVault(recipient, NON_ZERO_VALUE, FeeVault.WithdrawalNetwork.L1)).code - ); - vm.label(Predeploys.SEQUENCER_FEE_WALLET, "SequencerFeeVault"); + recipient = cfg.sequencerFeeVaultRecipient(); } /// @dev Tests that the minimum withdrawal amount is correct. function test_minWithdrawalAmount_succeeds() external { - assertEq(vault.MIN_WITHDRAWAL_AMOUNT(), NON_ZERO_VALUE); + assertEq(sequencerFeeVault.MIN_WITHDRAWAL_AMOUNT(), cfg.sequencerFeeVaultMinimumWithdrawalAmount()); } /// @dev Tests that the l1 fee wallet is correct. function test_constructor_succeeds() external { - assertEq(vault.l1FeeWallet(), recipient); + assertEq(sequencerFeeVault.l1FeeWallet(), recipient); } /// @dev Tests that the fee vault is able to receive ETH. function test_receive_succeeds() external { - uint256 balance = address(vault).balance; + uint256 balance = address(sequencerFeeVault).balance; vm.prank(alice); - (bool success,) = address(vault).call{ value: 100 }(hex""); + (bool success,) = address(sequencerFeeVault).call{ value: 100 }(hex""); assertEq(success, true); - assertEq(address(vault).balance, balance + 100); + assertEq(address(sequencerFeeVault).balance, balance + 100); } /// @dev Tests that `withdraw` reverts if the balance is less than the minimum /// withdrawal amount. function test_withdraw_notEnough_reverts() external { - assert(address(vault).balance < vault.MIN_WITHDRAWAL_AMOUNT()); + assert(address(sequencerFeeVault).balance < sequencerFeeVault.MIN_WITHDRAWAL_AMOUNT()); vm.expectRevert("FeeVault: withdrawal amount must be greater than minimum withdrawal amount"); - vault.withdraw(); + sequencerFeeVault.withdraw(); } /// @dev Tests that `withdraw` successfully initiates a withdrawal to L1. function test_withdraw_toL1_succeeds() external { - uint256 amount = vault.MIN_WITHDRAWAL_AMOUNT() + 1; - vm.deal(address(vault), amount); + // Set the code with the withdrawal network set to L1 + vm.etch( + Predeploys.SEQUENCER_FEE_WALLET, + address( + new SequencerFeeVault(cfg.sequencerFeeVaultRecipient(), cfg.sequencerFeeVaultMinimumWithdrawalAmount(), FeeVault.WithdrawalNetwork.L1) + ).code + ); + + uint256 amount = sequencerFeeVault.MIN_WITHDRAWAL_AMOUNT() + 1; + vm.deal(address(sequencerFeeVault), amount); // No ether has been withdrawn yet - assertEq(vault.totalProcessed(), 0); + assertEq(sequencerFeeVault.totalProcessed(), 0); vm.expectEmit(true, true, true, true, address(Predeploys.SEQUENCER_FEE_WALLET)); - emit Withdrawal(address(vault).balance, vault.RECIPIENT(), address(this)); + emit Withdrawal(address(sequencerFeeVault).balance, sequencerFeeVault.RECIPIENT(), address(this)); vm.expectEmit(true, true, true, true, address(Predeploys.SEQUENCER_FEE_WALLET)); - emit Withdrawal(address(vault).balance, vault.RECIPIENT(), address(this), FeeVault.WithdrawalNetwork.L1); + emit Withdrawal( + address(sequencerFeeVault).balance, + sequencerFeeVault.RECIPIENT(), + address(this), + FeeVault.WithdrawalNetwork.L1 + ); // The entire vault's balance is withdrawn vm.expectCall( Predeploys.L2_STANDARD_BRIDGE, - address(vault).balance, - abi.encodeWithSelector(StandardBridge.bridgeETHTo.selector, vault.l1FeeWallet(), 35_000, bytes("")) + address(sequencerFeeVault).balance, + abi.encodeWithSelector( + StandardBridge.bridgeETHTo.selector, sequencerFeeVault.l1FeeWallet(), 35_000, bytes("") + ) ); - vault.withdraw(); + sequencerFeeVault.withdraw(); // The withdrawal was successful - assertEq(vault.totalProcessed(), amount); - assertEq(address(vault).balance, ZERO_VALUE); + assertEq(sequencerFeeVault.totalProcessed(), amount); + assertEq(address(sequencerFeeVault).balance, 0); assertEq(Predeploys.L2_TO_L1_MESSAGE_PASSER.balance, amount); } } -contract SequencerFeeVault_L2Withdrawal_Test is FeeVault_Initializer { +contract SequencerFeeVault_L2Withdrawal_Test is CommonTest { + address recipient; /// @dev Sets up the test suite. + function setUp() public override { super.setUp(); - vm.etch( - Predeploys.SEQUENCER_FEE_WALLET, - address(new SequencerFeeVault(recipient, NON_ZERO_VALUE, FeeVault.WithdrawalNetwork.L2)).code - ); - vm.label(Predeploys.SEQUENCER_FEE_WALLET, "SequencerFeeVault"); + recipient = cfg.sequencerFeeVaultRecipient(); } /// @dev Tests that `withdraw` successfully initiates a withdrawal to L2. function test_withdraw_toL2_succeeds() external { - uint256 amount = vault.MIN_WITHDRAWAL_AMOUNT() + 1; - vm.deal(address(vault), amount); + uint256 amount = sequencerFeeVault.MIN_WITHDRAWAL_AMOUNT() + 1; + vm.deal(address(sequencerFeeVault), amount); // No ether has been withdrawn yet - assertEq(vault.totalProcessed(), 0); + assertEq(sequencerFeeVault.totalProcessed(), 0); vm.expectEmit(true, true, true, true, address(Predeploys.SEQUENCER_FEE_WALLET)); - emit Withdrawal(address(vault).balance, vault.RECIPIENT(), address(this)); + emit Withdrawal(address(sequencerFeeVault).balance, sequencerFeeVault.RECIPIENT(), address(this)); vm.expectEmit(true, true, true, true, address(Predeploys.SEQUENCER_FEE_WALLET)); - emit Withdrawal(address(vault).balance, vault.RECIPIENT(), address(this), FeeVault.WithdrawalNetwork.L2); + emit Withdrawal( + address(sequencerFeeVault).balance, + sequencerFeeVault.RECIPIENT(), + address(this), + FeeVault.WithdrawalNetwork.L2 + ); // The entire vault's balance is withdrawn - vm.expectCall(recipient, address(vault).balance, bytes("")); + vm.expectCall(recipient, address(sequencerFeeVault).balance, bytes("")); - vault.withdraw(); + sequencerFeeVault.withdraw(); // The withdrawal was successful - assertEq(vault.totalProcessed(), amount); - assertEq(address(vault).balance, ZERO_VALUE); + assertEq(sequencerFeeVault.totalProcessed(), amount); + assertEq(address(sequencerFeeVault).balance, 0); assertEq(recipient.balance, amount); } /// @dev Tests that `withdraw` fails if the Recipient reverts. This also serves to simulate /// a situation where insufficient gas is provided to the RECIPIENT. function test_withdraw_toL2recipientReverts_fails() external { - uint256 amount = vault.MIN_WITHDRAWAL_AMOUNT(); + uint256 amount = sequencerFeeVault.MIN_WITHDRAWAL_AMOUNT(); - vm.deal(address(vault), amount); + vm.deal(address(sequencerFeeVault), amount); // No ether has been withdrawn yet - assertEq(vault.totalProcessed(), 0); + assertEq(sequencerFeeVault.totalProcessed(), 0); // Ensure the RECIPIENT reverts - vm.etch(vault.RECIPIENT(), type(Reverter).runtimeCode); + vm.etch(sequencerFeeVault.RECIPIENT(), type(Reverter).runtimeCode); // The entire vault's balance is withdrawn - vm.expectCall(recipient, address(vault).balance, bytes("")); + vm.expectCall(recipient, address(sequencerFeeVault).balance, bytes("")); vm.expectRevert("FeeVault: failed to send ETH to L2 fee recipient"); - vault.withdraw(); - assertEq(vault.totalProcessed(), 0); + sequencerFeeVault.withdraw(); + assertEq(sequencerFeeVault.totalProcessed(), 0); } } diff --git a/packages/contracts-bedrock/test/StandardBridge.t.sol b/packages/contracts-bedrock/test/StandardBridge.t.sol index fd96e09f2c675..0f437fead82ff 100644 --- a/packages/contracts-bedrock/test/StandardBridge.t.sol +++ b/packages/contracts-bedrock/test/StandardBridge.t.sol @@ -1,9 +1,9 @@ // SPDX-License-Identifier: MIT pragma solidity 0.8.15; -import { StandardBridge } from "../src/universal/StandardBridge.sol"; -import { CommonTest } from "./CommonTest.t.sol"; -import { OptimismMintableERC20, ILegacyMintableERC20 } from "../src/universal/OptimismMintableERC20.sol"; +import { StandardBridge } from "src/universal/StandardBridge.sol"; +import { CommonTest } from "test/setup/CommonTest.sol"; +import { OptimismMintableERC20, ILegacyMintableERC20 } from "src/universal/OptimismMintableERC20.sol"; import { ERC20 } from "@openzeppelin/contracts/token/ERC20/ERC20.sol"; /// @title StandardBridgeTester diff --git a/packages/contracts-bedrock/test/Storage.t.sol b/packages/contracts-bedrock/test/Storage.t.sol index 62dd2d3d8e414..902169a8c4029 100644 --- a/packages/contracts-bedrock/test/Storage.t.sol +++ b/packages/contracts-bedrock/test/Storage.t.sol @@ -13,6 +13,11 @@ import { Test } from "forge-std/Test.sol"; contract Storage_Roundtrip_Test is Test { StorageSetter setter; + /// @notice A set of storage slots to pass to `setBytes32`. + StorageSetter.Slot[] slots; + /// @notice Used to deduplicate slots passed to `setBytes32`. + mapping(bytes32 => bool) keys; + function setUp() external { setter = new StorageSetter(); } @@ -34,4 +39,21 @@ contract Storage_Roundtrip_Test is Test { assertEq(setter.getBytes32(slot), hash); assertEq(hash, vm.load(address(setter), slot)); } + + /// @dev All keys must be unique in the input so deduplication is required. + function testFuzz_setGetBytes32Multi_succeeds(StorageSetter.Slot[] calldata _slots) external { + for (uint256 i; i < _slots.length; i++) { + if (keys[_slots[i].key]) { + continue; + } + slots.push(_slots[i]); + keys[_slots[i].key] = true; + } + + setter.setBytes32(slots); + for (uint256 i; i < slots.length; i++) { + assertEq(setter.getBytes32(slots[i].key), slots[i].value); + assertEq(slots[i].value, vm.load(address(setter), slots[i].key)); + } + } } diff --git a/packages/contracts-bedrock/test/SystemConfig.t.sol b/packages/contracts-bedrock/test/SystemConfig.t.sol index bb355fc4146c6..0b09b768c6869 100644 --- a/packages/contracts-bedrock/test/SystemConfig.t.sol +++ b/packages/contracts-bedrock/test/SystemConfig.t.sol @@ -2,102 +2,73 @@ pragma solidity 0.8.15; // Testing utilities -import { CommonTest } from "./CommonTest.t.sol"; +import { CommonTest } from "test/setup/CommonTest.sol"; // Libraries -import { Constants } from "../src/libraries/Constants.sol"; +import { Constants } from "src/libraries/Constants.sol"; +import { EIP1967Helper } from "test/mocks/EIP1967Helper.sol"; // Target contract dependencies -import { ResourceMetering } from "../src/L1/ResourceMetering.sol"; -import { Proxy } from "../src/universal/Proxy.sol"; +import { ResourceMetering } from "src/L1/ResourceMetering.sol"; +import { Proxy } from "src/universal/Proxy.sol"; // Target contract -import { SystemConfig } from "../src/L1/SystemConfig.sol"; +import { SystemConfig } from "src/L1/SystemConfig.sol"; contract SystemConfig_Init is CommonTest { - SystemConfig sysConf; - SystemConfig systemConfigImpl; - event ConfigUpdate(uint256 indexed version, SystemConfig.UpdateType indexed updateType, bytes data); +} - // Dummy addresses used to test getters - address constant batchInbox = address(0x18); - address constant l1CrossDomainMessenger = address(0x20); - address constant l1ERC721Bridge = address(0x21); - address constant l1StandardBridge = address(0x22); - address constant l2OutputOracle = address(0x23); - address constant optimismPortal = address(0x24); - address constant optimismMintableERC20Factory = address(0x25); - uint256 constant overhead = 2100; - uint256 constant scalar = 1000000; - bytes32 constant batcherHash = bytes32(hex"abcd"); - uint64 constant gasLimit = 30_000_000; - address constant unsafeBlockSigner = address(1); +contract SystemConfig_Initialize_Test is SystemConfig_Init { + address batchInbox; + address owner; + uint256 overhead; + uint256 scalar; + bytes32 batcherHash; + uint64 gasLimit; + address unsafeBlockSigner; + address systemConfigImpl; + address optimismMintableERC20Factory; function setUp() public virtual override { super.setUp(); - - Proxy proxy = new Proxy(multisig); - systemConfigImpl = new SystemConfig(); - - vm.prank(multisig); - proxy.upgradeToAndCall( - address(systemConfigImpl), - abi.encodeCall( - SystemConfig.initialize, - ( - alice, // _owner, - overhead, // _overhead, - scalar, // _scalar, - batcherHash, // _batcherHash - gasLimit, // _gasLimit, - unsafeBlockSigner, // _unsafeBlockSigner, - Constants.DEFAULT_RESOURCE_CONFIG(), // _config, - 0, // _startBlock - batchInbox, // _batchInbox - SystemConfig.Addresses({ // _addresses - l1CrossDomainMessenger: l1CrossDomainMessenger, - l1ERC721Bridge: l1ERC721Bridge, - l1StandardBridge: l1StandardBridge, - l2OutputOracle: l2OutputOracle, - optimismPortal: optimismPortal, - optimismMintableERC20Factory: optimismMintableERC20Factory - }) - ) - ) - ); - - sysConf = SystemConfig(address(proxy)); + batchInbox = cfg.batchInboxAddress(); + owner = cfg.finalSystemOwner(); + overhead = cfg.gasPriceOracleOverhead(); + scalar = cfg.gasPriceOracleScalar(); + batcherHash = bytes32(uint256(uint160(cfg.batchSenderAddress()))); + gasLimit = uint64(cfg.l2GenesisBlockGasLimit()); + unsafeBlockSigner = cfg.p2pSequencerAddress(); + systemConfigImpl = mustGetAddress("SystemConfig"); + optimismMintableERC20Factory = mustGetAddress("OptimismMintableERC20FactoryProxy"); } -} -contract SystemConfig_Initialize_Test is SystemConfig_Init { /// @dev Tests that initailization sets the correct values. function test_initialize_values_succeeds() external { - assertEq(sysConf.l1CrossDomainMessenger(), l1CrossDomainMessenger); - assertEq(sysConf.l1ERC721Bridge(), l1ERC721Bridge); - assertEq(sysConf.l1StandardBridge(), l1StandardBridge); - assertEq(sysConf.l2OutputOracle(), l2OutputOracle); - assertEq(sysConf.optimismPortal(), optimismPortal); - assertEq(sysConf.optimismMintableERC20Factory(), optimismMintableERC20Factory); - assertEq(sysConf.batchInbox(), batchInbox); - assertEq(sysConf.owner(), alice); - assertEq(sysConf.overhead(), overhead); - assertEq(sysConf.scalar(), scalar); - assertEq(sysConf.batcherHash(), batcherHash); - assertEq(sysConf.gasLimit(), gasLimit); - assertEq(sysConf.unsafeBlockSigner(), unsafeBlockSigner); + assertEq(systemConfig.l1CrossDomainMessenger(), address(l1CrossDomainMessenger)); + assertEq(systemConfig.l1ERC721Bridge(), address(l1ERC721Bridge)); + assertEq(systemConfig.l1StandardBridge(), address(l1StandardBridge)); + assertEq(systemConfig.l2OutputOracle(), address(l2OutputOracle)); + assertEq(systemConfig.optimismPortal(), address(optimismPortal)); + assertEq(systemConfig.optimismMintableERC20Factory(), optimismMintableERC20Factory); + assertEq(systemConfig.batchInbox(), batchInbox); + assertEq(systemConfig.owner(), owner); + assertEq(systemConfig.overhead(), overhead); + assertEq(systemConfig.scalar(), scalar); + assertEq(systemConfig.batcherHash(), batcherHash); + assertEq(systemConfig.gasLimit(), gasLimit); + assertEq(systemConfig.unsafeBlockSigner(), unsafeBlockSigner); // Depends on start block being set to 0 in `initialize` - assertEq(sysConf.startBlock(), block.number); + assertEq(systemConfig.startBlock(), block.number); // Depends on `initialize` being called with defaults - ResourceMetering.ResourceConfig memory cfg = Constants.DEFAULT_RESOURCE_CONFIG(); - ResourceMetering.ResourceConfig memory actual = sysConf.resourceConfig(); - assertEq(actual.maxResourceLimit, cfg.maxResourceLimit); - assertEq(actual.elasticityMultiplier, cfg.elasticityMultiplier); - assertEq(actual.baseFeeMaxChangeDenominator, cfg.baseFeeMaxChangeDenominator); - assertEq(actual.minimumBaseFee, cfg.minimumBaseFee); - assertEq(actual.systemTxMaxGas, cfg.systemTxMaxGas); - assertEq(actual.maximumBaseFee, cfg.maximumBaseFee); + ResourceMetering.ResourceConfig memory rcfg = Constants.DEFAULT_RESOURCE_CONFIG(); + ResourceMetering.ResourceConfig memory actual = systemConfig.resourceConfig(); + assertEq(actual.maxResourceLimit, rcfg.maxResourceLimit); + assertEq(actual.elasticityMultiplier, rcfg.elasticityMultiplier); + assertEq(actual.baseFeeMaxChangeDenominator, rcfg.baseFeeMaxChangeDenominator); + assertEq(actual.minimumBaseFee, rcfg.minimumBaseFee); + assertEq(actual.systemTxMaxGas, rcfg.systemTxMaxGas); + assertEq(actual.maximumBaseFee, rcfg.maximumBaseFee); } /// @dev Ensures that the start block override can be used to set the start block. @@ -105,15 +76,17 @@ contract SystemConfig_Initialize_Test is SystemConfig_Init { uint256 startBlock = 100; // Wipe out the initialized slot so the proxy can be initialized again - vm.store(address(sysConf), bytes32(0), bytes32(0)); + vm.store(address(systemConfig), bytes32(0), bytes32(0)); - assertEq(sysConf.startBlock(), block.number); + assertEq(systemConfig.startBlock(), block.number); // the startBlock slot is 106, wipe it out - vm.store(address(sysConf), bytes32(uint256(106)), bytes32(0)); - assertEq(sysConf.startBlock(), 0); + vm.store(address(systemConfig), bytes32(uint256(106)), bytes32(0)); + assertEq(systemConfig.startBlock(), 0); + + address admin = address(uint160(uint256(vm.load(address(systemConfig), Constants.PROXY_OWNER_ADDRESS)))); + vm.prank(admin); - vm.prank(multisig); - Proxy(payable(address(sysConf))).upgradeToAndCall( + Proxy(payable(address(systemConfig))).upgradeToAndCall( address(systemConfigImpl), abi.encodeCall( SystemConfig.initialize, @@ -128,31 +101,31 @@ contract SystemConfig_Initialize_Test is SystemConfig_Init { startBlock, // _startBlock batchInbox, // _batchInbox SystemConfig.Addresses({ // _addresses - l1CrossDomainMessenger: l1CrossDomainMessenger, - l1ERC721Bridge: l1ERC721Bridge, - l1StandardBridge: l1StandardBridge, - l2OutputOracle: l2OutputOracle, - optimismPortal: optimismPortal, + l1CrossDomainMessenger: address(l1CrossDomainMessenger), + l1ERC721Bridge: address(l1ERC721Bridge), + l1StandardBridge: address(l1StandardBridge), + l2OutputOracle: address(l2OutputOracle), + optimismPortal: address(optimismPortal), optimismMintableERC20Factory: optimismMintableERC20Factory }) ) ) ); - assertEq(sysConf.startBlock(), startBlock); + assertEq(systemConfig.startBlock(), startBlock); } /// @dev Tests that initialization with start block already set is a noop. function test_initialize_startBlockNoop_reverts() external { // wipe out initialized slot so we can initialize again - vm.store(address(sysConf), bytes32(0), bytes32(0)); + vm.store(address(systemConfig), bytes32(0), bytes32(0)); // the startBlock slot is 106, set it to something non zero - vm.store(address(sysConf), bytes32(uint256(106)), bytes32(uint256(0xff))); + vm.store(address(systemConfig), bytes32(uint256(106)), bytes32(uint256(0xff))); // Initialize with a non zero start block, should see a revert - vm.prank(multisig); + vm.prank(EIP1967Helper.getAdmin(address(systemConfig))); // The call to initialize reverts due to: "SystemConfig: cannot override an already set start block" // but the proxy revert message bubbles up. - Proxy(payable(address(sysConf))).upgradeToAndCall( + Proxy(payable(address(systemConfig))).upgradeToAndCall( address(systemConfigImpl), abi.encodeCall( SystemConfig.initialize, @@ -167,11 +140,11 @@ contract SystemConfig_Initialize_Test is SystemConfig_Init { 1, // _startBlock batchInbox, // _batchInbox SystemConfig.Addresses({ // _addresses - l1CrossDomainMessenger: l1CrossDomainMessenger, - l1ERC721Bridge: l1ERC721Bridge, - l1StandardBridge: l1StandardBridge, - l2OutputOracle: l2OutputOracle, - optimismPortal: optimismPortal, + l1CrossDomainMessenger: address(l1CrossDomainMessenger), + l1ERC721Bridge: address(l1ERC721Bridge), + l1StandardBridge: address(l1StandardBridge), + l2OutputOracle: address(l2OutputOracle), + optimismPortal: address(optimismPortal), optimismMintableERC20Factory: optimismMintableERC20Factory }) ) @@ -180,29 +153,31 @@ contract SystemConfig_Initialize_Test is SystemConfig_Init { // It was initialized with 1 but it was already set so the override // should be ignored. - uint256 startBlock = sysConf.startBlock(); + uint256 startBlock = systemConfig.startBlock(); assertEq(startBlock, 0xff); } /// @dev Ensures that the events are emitted during initialization. function test_initialize_events_succeeds() external { // Wipe out the initialized slot so the proxy can be initialized again - vm.store(address(sysConf), bytes32(0), bytes32(0)); - vm.store(address(sysConf), bytes32(uint256(106)), bytes32(0)); - assertEq(sysConf.startBlock(), 0); + vm.store(address(systemConfig), bytes32(0), bytes32(0)); + vm.store(address(systemConfig), bytes32(uint256(106)), bytes32(0)); + assertEq(systemConfig.startBlock(), 0); // The order depends here - vm.expectEmit(true, true, true, true, address(sysConf)); + vm.expectEmit(true, true, true, true, address(systemConfig)); emit ConfigUpdate(0, SystemConfig.UpdateType.BATCHER, abi.encode(batcherHash)); - vm.expectEmit(true, true, true, true, address(sysConf)); + vm.expectEmit(true, true, true, true, address(systemConfig)); emit ConfigUpdate(0, SystemConfig.UpdateType.GAS_CONFIG, abi.encode(overhead, scalar)); - vm.expectEmit(true, true, true, true, address(sysConf)); + vm.expectEmit(true, true, true, true, address(systemConfig)); emit ConfigUpdate(0, SystemConfig.UpdateType.GAS_LIMIT, abi.encode(gasLimit)); - vm.expectEmit(true, true, true, true, address(sysConf)); + vm.expectEmit(true, true, true, true, address(systemConfig)); emit ConfigUpdate(0, SystemConfig.UpdateType.UNSAFE_BLOCK_SIGNER, abi.encode(unsafeBlockSigner)); - vm.prank(multisig); - Proxy(payable(address(sysConf))).upgradeToAndCall( + address admin = address(uint160(uint256(vm.load(address(systemConfig), Constants.PROXY_OWNER_ADDRESS)))); + vm.prank(admin); + + Proxy(payable(address(systemConfig))).upgradeToAndCall( address(systemConfigImpl), abi.encodeCall( SystemConfig.initialize, @@ -217,11 +192,11 @@ contract SystemConfig_Initialize_Test is SystemConfig_Init { 0, // _startBlock batchInbox, // _batchInbox SystemConfig.Addresses({ // _addresses - l1CrossDomainMessenger: l1CrossDomainMessenger, - l1ERC721Bridge: l1ERC721Bridge, - l1StandardBridge: l1StandardBridge, - l2OutputOracle: l2OutputOracle, - optimismPortal: optimismPortal, + l1CrossDomainMessenger: address(l1CrossDomainMessenger), + l1ERC721Bridge: address(l1ERC721Bridge), + l1StandardBridge: address(l1StandardBridge), + l2OutputOracle: address(l2OutputOracle), + optimismPortal: address(optimismPortal), optimismMintableERC20Factory: optimismMintableERC20Factory }) ) @@ -233,15 +208,19 @@ contract SystemConfig_Initialize_Test is SystemConfig_Init { contract SystemConfig_Initialize_TestFail is SystemConfig_Init { /// @dev Tests that initialization reverts if the gas limit is too low. function test_initialize_lowGasLimit_reverts() external { - uint64 minimumGasLimit = sysConf.minimumGasLimit(); + address systemConfigImpl = mustGetAddress("SystemConfig"); + uint64 minimumGasLimit = systemConfig.minimumGasLimit(); // Wipe out the initialized slot so the proxy can be initialized again - vm.store(address(sysConf), bytes32(0), bytes32(0)); - vm.prank(multisig); + vm.store(address(systemConfig), bytes32(0), bytes32(0)); + + address admin = address(uint160(uint256(vm.load(address(systemConfig), Constants.PROXY_OWNER_ADDRESS)))); + vm.prank(admin); + // The call to initialize reverts due to: "SystemConfig: gas limit too low" // but the proxy revert message bubbles up. vm.expectRevert("Proxy: delegatecall to new implementation contract failed"); - Proxy(payable(address(sysConf))).upgradeToAndCall( + Proxy(payable(address(systemConfig))).upgradeToAndCall( address(systemConfigImpl), abi.encodeCall( SystemConfig.initialize, @@ -273,32 +252,32 @@ contract SystemConfig_Setters_TestFail is SystemConfig_Init { /// @dev Tests that `setBatcherHash` reverts if the caller is not the owner. function test_setBatcherHash_notOwner_reverts() external { vm.expectRevert("Ownable: caller is not the owner"); - sysConf.setBatcherHash(bytes32(hex"")); + systemConfig.setBatcherHash(bytes32(hex"")); } /// @dev Tests that `setGasConfig` reverts if the caller is not the owner. function test_setGasConfig_notOwner_reverts() external { vm.expectRevert("Ownable: caller is not the owner"); - sysConf.setGasConfig(0, 0); + systemConfig.setGasConfig(0, 0); } /// @dev Tests that `setGasLimit` reverts if the caller is not the owner. function test_setGasLimit_notOwner_reverts() external { vm.expectRevert("Ownable: caller is not the owner"); - sysConf.setGasLimit(0); + systemConfig.setGasLimit(0); } /// @dev Tests that `setUnsafeBlockSigner` reverts if the caller is not the owner. function test_setUnsafeBlockSigner_notOwner_reverts() external { vm.expectRevert("Ownable: caller is not the owner"); - sysConf.setUnsafeBlockSigner(address(0x20)); + systemConfig.setUnsafeBlockSigner(address(0x20)); } /// @dev Tests that `setResourceConfig` reverts if the caller is not the owner. function test_setResourceConfig_notOwner_reverts() external { ResourceMetering.ResourceConfig memory config = Constants.DEFAULT_RESOURCE_CONFIG(); vm.expectRevert("Ownable: caller is not the owner"); - sysConf.setResourceConfig(config); + systemConfig.setResourceConfig(config); } /// @dev Tests that `setResourceConfig` reverts if the min base fee @@ -312,9 +291,9 @@ contract SystemConfig_Setters_TestFail is SystemConfig_Init { minimumBaseFee: 2 gwei, maximumBaseFee: 1 gwei }); - vm.prank(sysConf.owner()); + vm.prank(systemConfig.owner()); vm.expectRevert("SystemConfig: min base fee must be less than max base"); - sysConf.setResourceConfig(config); + systemConfig.setResourceConfig(config); } /// @dev Tests that `setResourceConfig` reverts if the baseFeeMaxChangeDenominator @@ -328,14 +307,14 @@ contract SystemConfig_Setters_TestFail is SystemConfig_Init { minimumBaseFee: 1 gwei, maximumBaseFee: 2 gwei }); - vm.prank(sysConf.owner()); + vm.prank(systemConfig.owner()); vm.expectRevert("SystemConfig: denominator must be larger than 1"); - sysConf.setResourceConfig(config); + systemConfig.setResourceConfig(config); } /// @dev Tests that `setResourceConfig` reverts if the gas limit is too low. function test_setResourceConfig_lowGasLimit_reverts() external { - uint64 gasLimit = sysConf.gasLimit(); + uint64 gasLimit = systemConfig.gasLimit(); ResourceMetering.ResourceConfig memory config = ResourceMetering.ResourceConfig({ maxResourceLimit: uint32(gasLimit), @@ -345,9 +324,9 @@ contract SystemConfig_Setters_TestFail is SystemConfig_Init { minimumBaseFee: 1 gwei, maximumBaseFee: 2 gwei }); - vm.prank(sysConf.owner()); + vm.prank(systemConfig.owner()); vm.expectRevert("SystemConfig: gas limit too low"); - sysConf.setResourceConfig(config); + systemConfig.setResourceConfig(config); } /// @dev Tests that `setResourceConfig` reverts if the elasticity multiplier @@ -361,9 +340,9 @@ contract SystemConfig_Setters_TestFail is SystemConfig_Init { minimumBaseFee: 1 gwei, maximumBaseFee: 2 gwei }); - vm.prank(sysConf.owner()); + vm.prank(systemConfig.owner()); vm.expectRevert("SystemConfig: precision loss with target resource limit"); - sysConf.setResourceConfig(config); + systemConfig.setResourceConfig(config); } } @@ -373,9 +352,9 @@ contract SystemConfig_Setters_Test is SystemConfig_Init { vm.expectEmit(true, true, true, true); emit ConfigUpdate(0, SystemConfig.UpdateType.BATCHER, abi.encode(newBatcherHash)); - vm.prank(sysConf.owner()); - sysConf.setBatcherHash(newBatcherHash); - assertEq(sysConf.batcherHash(), newBatcherHash); + vm.prank(systemConfig.owner()); + systemConfig.setBatcherHash(newBatcherHash); + assertEq(systemConfig.batcherHash(), newBatcherHash); } /// @dev Tests that `setGasConfig` updates the overhead and scalar successfully. @@ -383,23 +362,23 @@ contract SystemConfig_Setters_Test is SystemConfig_Init { vm.expectEmit(true, true, true, true); emit ConfigUpdate(0, SystemConfig.UpdateType.GAS_CONFIG, abi.encode(newOverhead, newScalar)); - vm.prank(sysConf.owner()); - sysConf.setGasConfig(newOverhead, newScalar); - assertEq(sysConf.overhead(), newOverhead); - assertEq(sysConf.scalar(), newScalar); + vm.prank(systemConfig.owner()); + systemConfig.setGasConfig(newOverhead, newScalar); + assertEq(systemConfig.overhead(), newOverhead); + assertEq(systemConfig.scalar(), newScalar); } /// @dev Tests that `setGasLimit` updates the gas limit successfully. function testFuzz_setGasLimit_succeeds(uint64 newGasLimit) external { - uint64 minimumGasLimit = sysConf.minimumGasLimit(); + uint64 minimumGasLimit = systemConfig.minimumGasLimit(); newGasLimit = uint64(bound(uint256(newGasLimit), uint256(minimumGasLimit), uint256(type(uint64).max))); vm.expectEmit(true, true, true, true); emit ConfigUpdate(0, SystemConfig.UpdateType.GAS_LIMIT, abi.encode(newGasLimit)); - vm.prank(sysConf.owner()); - sysConf.setGasLimit(newGasLimit); - assertEq(sysConf.gasLimit(), newGasLimit); + vm.prank(systemConfig.owner()); + systemConfig.setGasLimit(newGasLimit); + assertEq(systemConfig.gasLimit(), newGasLimit); } /// @dev Tests that `setUnsafeBlockSigner` updates the block signer successfully. @@ -407,8 +386,8 @@ contract SystemConfig_Setters_Test is SystemConfig_Init { vm.expectEmit(true, true, true, true); emit ConfigUpdate(0, SystemConfig.UpdateType.UNSAFE_BLOCK_SIGNER, abi.encode(newUnsafeSigner)); - vm.prank(sysConf.owner()); - sysConf.setUnsafeBlockSigner(newUnsafeSigner); - assertEq(sysConf.unsafeBlockSigner(), newUnsafeSigner); + vm.prank(systemConfig.owner()); + systemConfig.setUnsafeBlockSigner(newUnsafeSigner); + assertEq(systemConfig.unsafeBlockSigner(), newUnsafeSigner); } } diff --git a/packages/contracts-bedrock/test/Transactor.t.sol b/packages/contracts-bedrock/test/Transactor.t.sol index 3eefd78287cc6..af6ce0fba1ca2 100644 --- a/packages/contracts-bedrock/test/Transactor.t.sol +++ b/packages/contracts-bedrock/test/Transactor.t.sol @@ -3,9 +3,8 @@ pragma solidity 0.8.15; // Testing utilities import { Test } from "forge-std/Test.sol"; -import { CallRecorder } from "./Helpers.sol"; -import { Reverter } from "./Helpers.sol"; -import { Transactor } from "../src/periphery/Transactor.sol"; +import { CallRecorder, Reverter } from "test/mocks/Callers.sol"; +import { Transactor } from "src/periphery/Transactor.sol"; contract Transactor_Initializer is Test { address alice = address(128); diff --git a/packages/contracts-bedrock/test/TransferOnion.t.sol b/packages/contracts-bedrock/test/TransferOnion.t.sol index 88fe1dc60ab4f..27947e82c20e1 100644 --- a/packages/contracts-bedrock/test/TransferOnion.t.sol +++ b/packages/contracts-bedrock/test/TransferOnion.t.sol @@ -6,7 +6,7 @@ import { Test } from "forge-std/Test.sol"; import { ERC20 } from "@openzeppelin/contracts/token/ERC20/ERC20.sol"; // Target contract -import { TransferOnion } from "../src/periphery/TransferOnion.sol"; +import { TransferOnion } from "src/periphery/TransferOnion.sol"; /// @title TransferOnionTest /// @notice Test coverage of TransferOnion diff --git a/packages/contracts-bedrock/test/invariants/AddressAliasHelper.t.sol b/packages/contracts-bedrock/test/invariants/AddressAliasHelper.t.sol index 9c5d5f205a695..fd5bcc8c7cad5 100644 --- a/packages/contracts-bedrock/test/invariants/AddressAliasHelper.t.sol +++ b/packages/contracts-bedrock/test/invariants/AddressAliasHelper.t.sol @@ -3,7 +3,7 @@ pragma solidity 0.8.15; import { Test } from "forge-std/Test.sol"; import { StdInvariant } from "forge-std/StdInvariant.sol"; -import { AddressAliasHelper } from "../../src/vendor/AddressAliasHelper.sol"; +import { AddressAliasHelper } from "src/vendor/AddressAliasHelper.sol"; contract AddressAliasHelper_Converter { bool public failedRoundtrip; diff --git a/packages/contracts-bedrock/test/invariants/Burn.Eth.t.sol b/packages/contracts-bedrock/test/invariants/Burn.Eth.t.sol index 49f2a0249908b..0fdfcdbbb1940 100644 --- a/packages/contracts-bedrock/test/invariants/Burn.Eth.t.sol +++ b/packages/contracts-bedrock/test/invariants/Burn.Eth.t.sol @@ -6,7 +6,7 @@ import { Test } from "forge-std/Test.sol"; import { Vm } from "forge-std/Vm.sol"; import { StdInvariant } from "forge-std/StdInvariant.sol"; -import { Burn } from "../../src/libraries/Burn.sol"; +import { Burn } from "src/libraries/Burn.sol"; contract Burn_EthBurner is StdUtils { Vm internal vm; diff --git a/packages/contracts-bedrock/test/invariants/Burn.Gas.t.sol b/packages/contracts-bedrock/test/invariants/Burn.Gas.t.sol index 8e973245a4194..4e9145a08d777 100644 --- a/packages/contracts-bedrock/test/invariants/Burn.Gas.t.sol +++ b/packages/contracts-bedrock/test/invariants/Burn.Gas.t.sol @@ -6,7 +6,7 @@ import { Test } from "forge-std/Test.sol"; import { Vm } from "forge-std/Vm.sol"; import { StdInvariant } from "forge-std/StdInvariant.sol"; -import { Burn } from "../../src/libraries/Burn.sol"; +import { Burn } from "src/libraries/Burn.sol"; contract Burn_GasBurner is StdUtils { Vm internal vm; diff --git a/packages/contracts-bedrock/test/invariants/CrossDomainMessenger.t.sol b/packages/contracts-bedrock/test/invariants/CrossDomainMessenger.t.sol index 1fb358e85c03b..a2a1bf2e0d553 100644 --- a/packages/contracts-bedrock/test/invariants/CrossDomainMessenger.t.sol +++ b/packages/contracts-bedrock/test/invariants/CrossDomainMessenger.t.sol @@ -3,14 +3,15 @@ pragma solidity 0.8.15; import { StdUtils } from "forge-std/StdUtils.sol"; import { Vm } from "forge-std/Vm.sol"; -import { OptimismPortal } from "../../src/L1/OptimismPortal.sol"; -import { L1CrossDomainMessenger } from "../../src/L1/L1CrossDomainMessenger.sol"; -import { Messenger_Initializer } from "../CommonTest.t.sol"; -import { Types } from "../../src/libraries/Types.sol"; -import { Predeploys } from "../../src/libraries/Predeploys.sol"; -import { Constants } from "../../src/libraries/Constants.sol"; -import { Encoding } from "../../src/libraries/Encoding.sol"; -import { Hashing } from "../../src/libraries/Hashing.sol"; +import { OptimismPortal } from "src/L1/OptimismPortal.sol"; +import { L1CrossDomainMessenger } from "src/L1/L1CrossDomainMessenger.sol"; +import { Bridge_Initializer } from "test/setup/Bridge_Initializer.sol"; +import { Types } from "src/libraries/Types.sol"; +import { Predeploys } from "src/libraries/Predeploys.sol"; +import { Constants } from "src/libraries/Constants.sol"; +import { Encoding } from "src/libraries/Encoding.sol"; +import { Hashing } from "src/libraries/Hashing.sol"; +import { Bridge_Initializer } from "test/setup/Bridge_Initializer.sol"; contract RelayActor is StdUtils { // Storage slot of the l2Sender @@ -88,7 +89,7 @@ contract RelayActor is StdUtils { } } -contract XDM_MinGasLimits is Messenger_Initializer { +contract XDM_MinGasLimits is Bridge_Initializer { RelayActor actor; function init(bool doFail) public virtual { @@ -96,10 +97,10 @@ contract XDM_MinGasLimits is Messenger_Initializer { super.setUp(); // Deploy a relay actor - actor = new RelayActor(op, L1Messenger, vm, doFail); + actor = new RelayActor(optimismPortal, l1CrossDomainMessenger, vm, doFail); // Give the portal some ether to send to `relayMessage` - vm.deal(address(op), type(uint128).max); + vm.deal(address(optimismPortal), type(uint128).max); // Target the `RelayActor` contract targetContract(address(actor)); @@ -138,9 +139,9 @@ contract XDM_MinGasLimits_Succeeds is XDM_MinGasLimits { for (uint256 i = 0; i < length; ++i) { bytes32 hash = actor.hashes(i); // The message hash is set in the successfulMessages mapping - assertTrue(L1Messenger.successfulMessages(hash)); + assertTrue(l1CrossDomainMessenger.successfulMessages(hash)); // The message hash is not set in the failedMessages mapping - assertFalse(L1Messenger.failedMessages(hash)); + assertFalse(l1CrossDomainMessenger.failedMessages(hash)); } assertFalse(actor.reverted()); } @@ -171,9 +172,9 @@ contract XDM_MinGasLimits_Reverts is XDM_MinGasLimits { for (uint256 i = 0; i < length; ++i) { bytes32 hash = actor.hashes(i); // The message hash is not set in the successfulMessages mapping - assertFalse(L1Messenger.successfulMessages(hash)); + assertFalse(l1CrossDomainMessenger.successfulMessages(hash)); // The message hash is set in the failedMessages mapping - assertTrue(L1Messenger.failedMessages(hash)); + assertTrue(l1CrossDomainMessenger.failedMessages(hash)); } assertFalse(actor.reverted()); } diff --git a/packages/contracts-bedrock/test/invariants/Encoding.t.sol b/packages/contracts-bedrock/test/invariants/Encoding.t.sol index 405ac37815155..566c82903e018 100644 --- a/packages/contracts-bedrock/test/invariants/Encoding.t.sol +++ b/packages/contracts-bedrock/test/invariants/Encoding.t.sol @@ -3,7 +3,7 @@ pragma solidity 0.8.15; import { Test } from "forge-std/Test.sol"; import { StdInvariant } from "forge-std/StdInvariant.sol"; -import { Encoding } from "../../src/libraries/Encoding.sol"; +import { Encoding } from "src/libraries/Encoding.sol"; contract Encoding_Converter { bool public failedRoundtripAToB; diff --git a/packages/contracts-bedrock/test/invariants/Hashing.t.sol b/packages/contracts-bedrock/test/invariants/Hashing.t.sol index 729f177be30a0..c972148f12b0d 100644 --- a/packages/contracts-bedrock/test/invariants/Hashing.t.sol +++ b/packages/contracts-bedrock/test/invariants/Hashing.t.sol @@ -3,8 +3,8 @@ pragma solidity 0.8.15; import { Test } from "forge-std/Test.sol"; import { StdInvariant } from "forge-std/StdInvariant.sol"; -import { Encoding } from "../../src/libraries/Encoding.sol"; -import { Hashing } from "../../src/libraries/Hashing.sol"; +import { Encoding } from "src/libraries/Encoding.sol"; +import { Hashing } from "src/libraries/Hashing.sol"; contract Hash_CrossDomainHasher { bool public failedCrossDomainHashHighVersion; diff --git a/packages/contracts-bedrock/test/invariants/L2OutputOracle.t.sol b/packages/contracts-bedrock/test/invariants/L2OutputOracle.t.sol index 8423e5a9b5476..c688ef4196174 100644 --- a/packages/contracts-bedrock/test/invariants/L2OutputOracle.t.sol +++ b/packages/contracts-bedrock/test/invariants/L2OutputOracle.t.sol @@ -1,8 +1,8 @@ // SPDX-License-Identifier: MIT pragma solidity 0.8.15; -import { L2OutputOracle_Initializer } from "../CommonTest.t.sol"; -import { L2OutputOracle } from "../../src/L1/L2OutputOracle.sol"; +import { CommonTest } from "test/setup/CommonTest.sol"; +import { L2OutputOracle } from "src/L1/L2OutputOracle.sol"; import { Vm } from "forge-std/Vm.sol"; contract L2OutputOracle_Proposer { @@ -29,14 +29,14 @@ contract L2OutputOracle_Proposer { } } -contract L2OutputOracle_MonotonicBlockNumIncrease_Invariant is L2OutputOracle_Initializer { +contract L2OutputOracle_MonotonicBlockNumIncrease_Invariant is CommonTest { L2OutputOracle_Proposer internal actor; function setUp() public override { super.setUp(); // Create a proposer actor. - actor = new L2OutputOracle_Proposer(oracle, vm); + actor = new L2OutputOracle_Proposer(l2OutputOracle, vm); // Set the target contract to the proposer actor. targetContract(address(actor)); @@ -57,6 +57,6 @@ contract L2OutputOracle_MonotonicBlockNumIncrease_Invariant is L2OutputOracle_In /// correspond to a block number that is less than the current output. function invariant_monotonicBlockNumIncrease() external { // Assert that the block number of proposals must monotonically increase. - assertTrue(oracle.nextBlockNumber() >= oracle.latestBlockNumber()); + assertTrue(l2OutputOracle.nextBlockNumber() >= l2OutputOracle.latestBlockNumber()); } } diff --git a/packages/contracts-bedrock/test/invariants/OptimismPortal.t.sol b/packages/contracts-bedrock/test/invariants/OptimismPortal.t.sol index 145a3b9e56b2c..009a6a9daca10 100644 --- a/packages/contracts-bedrock/test/invariants/OptimismPortal.t.sol +++ b/packages/contracts-bedrock/test/invariants/OptimismPortal.t.sol @@ -4,15 +4,16 @@ pragma solidity 0.8.15; import { StdUtils } from "forge-std/Test.sol"; import { Vm } from "forge-std/Vm.sol"; -import { OptimismPortal } from "../../src/L1/OptimismPortal.sol"; -import { L2OutputOracle } from "../../src/L1/L2OutputOracle.sol"; -import { AddressAliasHelper } from "../../src/vendor/AddressAliasHelper.sol"; -import { SystemConfig } from "../../src/L1/SystemConfig.sol"; -import { ResourceMetering } from "../../src/L1/ResourceMetering.sol"; -import { Constants } from "../../src/libraries/Constants.sol"; +import { OptimismPortal } from "src/L1/OptimismPortal.sol"; +import { L2OutputOracle } from "src/L1/L2OutputOracle.sol"; +import { AddressAliasHelper } from "src/vendor/AddressAliasHelper.sol"; +import { SystemConfig } from "src/L1/SystemConfig.sol"; +import { ResourceMetering } from "src/L1/ResourceMetering.sol"; +import { Constants } from "src/libraries/Constants.sol"; -import { Portal_Initializer } from "../CommonTest.t.sol"; -import { Types } from "../../src/libraries/Types.sol"; +import { CommonTest } from "test/setup/CommonTest.sol"; +import { EIP1967Helper } from "test/mocks/EIP1967Helper.sol"; +import { Types } from "src/libraries/Types.sol"; contract OptimismPortal_Depositor is StdUtils, ResourceMetering { Vm internal vm; @@ -73,7 +74,7 @@ contract OptimismPortal_Depositor is StdUtils, ResourceMetering { } } -contract OptimismPortal_Invariant_Harness is Portal_Initializer { +contract OptimismPortal_Invariant_Harness is CommonTest { // Reusable default values for a test withdrawal Types.WithdrawalTransaction _defaultTx; @@ -108,28 +109,31 @@ contract OptimismPortal_Invariant_Harness is Portal_Initializer { messagePasserStorageRoot: _storageRoot, latestBlockhash: bytes32(uint256(0)) }); - _proposedBlockNumber = oracle.nextBlockNumber(); - _proposedOutputIndex = oracle.nextOutputIndex(); + _proposedBlockNumber = l2OutputOracle.nextBlockNumber(); + _proposedOutputIndex = l2OutputOracle.nextOutputIndex(); // Configure the oracle to return the output root we've prepared. - vm.warp(oracle.computeL2Timestamp(_proposedBlockNumber) + 1); - vm.prank(oracle.PROPOSER()); - oracle.proposeL2Output(_outputRoot, _proposedBlockNumber, 0, 0); + vm.warp(l2OutputOracle.computeL2Timestamp(_proposedBlockNumber) + 1); + vm.prank(l2OutputOracle.PROPOSER()); + l2OutputOracle.proposeL2Output(_outputRoot, _proposedBlockNumber, 0, 0); // Warp beyond the finalization period for the block we've proposed. - vm.warp(oracle.getL2Output(_proposedOutputIndex).timestamp + oracle.FINALIZATION_PERIOD_SECONDS() + 1); + vm.warp( + l2OutputOracle.getL2Output(_proposedOutputIndex).timestamp + l2OutputOracle.FINALIZATION_PERIOD_SECONDS() + + 1 + ); // Fund the portal so that we can withdraw ETH. - vm.deal(address(op), 0xFFFFFFFF); + vm.deal(address(optimismPortal), 0xFFFFFFFF); } } -contract OptimismPortal_Deposit_Invariant is Portal_Initializer { +contract OptimismPortal_Deposit_Invariant is CommonTest { OptimismPortal_Depositor internal actor; function setUp() public override { super.setUp(); // Create a deposit actor. - actor = new OptimismPortal_Depositor(vm, op); + actor = new OptimismPortal_Depositor(vm, optimismPortal); targetContract(address(actor)); @@ -154,12 +158,12 @@ contract OptimismPortal_CannotTimeTravel is OptimismPortal_Invariant_Harness { super.setUp(); // Prove the withdrawal transaction - op.proveWithdrawalTransaction(_defaultTx, _proposedOutputIndex, _outputRootProof, _withdrawalProof); + optimismPortal.proveWithdrawalTransaction(_defaultTx, _proposedOutputIndex, _outputRootProof, _withdrawalProof); // Set the target contract to the portal proxy - targetContract(address(op)); - // Exclude the proxy multisig from the senders so that the proxy cannot be upgraded - excludeSender(address(multisig)); + targetContract(address(optimismPortal)); + // Exclude the proxy admin from the senders so that the proxy cannot be upgraded + excludeSender(EIP1967Helper.getAdmin(address(optimismPortal))); } /// @custom:invariant `finalizeWithdrawalTransaction` should revert if the finalization @@ -169,7 +173,7 @@ contract OptimismPortal_CannotTimeTravel is OptimismPortal_Invariant_Harness { /// until after the finalization period has elapsed. function invariant_cannotFinalizeBeforePeriodHasPassed() external { vm.expectRevert("OptimismPortal: proven withdrawal finalization period has not elapsed"); - op.finalizeWithdrawalTransaction(_defaultTx); + optimismPortal.finalizeWithdrawalTransaction(_defaultTx); } } @@ -178,18 +182,18 @@ contract OptimismPortal_CannotFinalizeTwice is OptimismPortal_Invariant_Harness super.setUp(); // Prove the withdrawal transaction - op.proveWithdrawalTransaction(_defaultTx, _proposedOutputIndex, _outputRootProof, _withdrawalProof); + optimismPortal.proveWithdrawalTransaction(_defaultTx, _proposedOutputIndex, _outputRootProof, _withdrawalProof); // Warp past the finalization period. - vm.warp(block.timestamp + oracle.FINALIZATION_PERIOD_SECONDS() + 1); + vm.warp(block.timestamp + l2OutputOracle.FINALIZATION_PERIOD_SECONDS() + 1); // Finalize the withdrawal transaction. - op.finalizeWithdrawalTransaction(_defaultTx); + optimismPortal.finalizeWithdrawalTransaction(_defaultTx); // Set the target contract to the portal proxy - targetContract(address(op)); - // Exclude the proxy multisig from the senders so that the proxy cannot be upgraded - excludeSender(address(multisig)); + targetContract(address(optimismPortal)); + // Exclude the proxy admin from the senders so that the proxy cannot be upgraded + excludeSender(EIP1967Helper.getAdmin(address(optimismPortal))); } /// @custom:invariant `finalizeWithdrawalTransaction` should revert if the withdrawal @@ -199,7 +203,7 @@ contract OptimismPortal_CannotFinalizeTwice is OptimismPortal_Invariant_Harness /// allows a withdrawal to be finalized twice. function invariant_cannotFinalizeTwice() external { vm.expectRevert("OptimismPortal: withdrawal has already been finalized"); - op.finalizeWithdrawalTransaction(_defaultTx); + optimismPortal.finalizeWithdrawalTransaction(_defaultTx); } } @@ -208,15 +212,15 @@ contract OptimismPortal_CanAlwaysFinalizeAfterWindow is OptimismPortal_Invariant super.setUp(); // Prove the withdrawal transaction - op.proveWithdrawalTransaction(_defaultTx, _proposedOutputIndex, _outputRootProof, _withdrawalProof); + optimismPortal.proveWithdrawalTransaction(_defaultTx, _proposedOutputIndex, _outputRootProof, _withdrawalProof); // Warp past the finalization period. - vm.warp(block.timestamp + oracle.FINALIZATION_PERIOD_SECONDS() + 1); + vm.warp(block.timestamp + l2OutputOracle.FINALIZATION_PERIOD_SECONDS() + 1); // Set the target contract to the portal proxy - targetContract(address(op)); - // Exclude the proxy multisig from the senders so that the proxy cannot be upgraded - excludeSender(address(multisig)); + targetContract(address(optimismPortal)); + // Exclude the proxy admin from the senders so that the proxy cannot be upgraded + excludeSender(EIP1967Helper.getAdmin(address(optimismPortal))); } /// @custom:invariant A withdrawal should **always** be able to be finalized @@ -229,7 +233,7 @@ contract OptimismPortal_CanAlwaysFinalizeAfterWindow is OptimismPortal_Invariant function invariant_canAlwaysFinalize() external { uint256 bobBalanceBefore = address(bob).balance; - op.finalizeWithdrawalTransaction(_defaultTx); + optimismPortal.finalizeWithdrawalTransaction(_defaultTx); assertEq(address(bob).balance, bobBalanceBefore + _defaultTx.value); } diff --git a/packages/contracts-bedrock/test/invariants/ResourceMetering.t.sol b/packages/contracts-bedrock/test/invariants/ResourceMetering.t.sol index 3f2ffce7199dc..8668613312192 100644 --- a/packages/contracts-bedrock/test/invariants/ResourceMetering.t.sol +++ b/packages/contracts-bedrock/test/invariants/ResourceMetering.t.sol @@ -6,10 +6,10 @@ import { Test } from "forge-std/Test.sol"; import { StdUtils } from "forge-std/StdUtils.sol"; import { StdInvariant } from "forge-std/StdInvariant.sol"; -import { Arithmetic } from "../../src/libraries/Arithmetic.sol"; -import { ResourceMetering } from "../../src/L1/ResourceMetering.sol"; -import { Proxy } from "../../src/universal/Proxy.sol"; -import { Constants } from "../../src/libraries/Constants.sol"; +import { Arithmetic } from "src/libraries/Arithmetic.sol"; +import { ResourceMetering } from "src/L1/ResourceMetering.sol"; +import { Proxy } from "src/universal/Proxy.sol"; +import { Constants } from "src/libraries/Constants.sol"; contract ResourceMetering_User is StdUtils, ResourceMetering { bool public failedMaxGasPerBlock; diff --git a/packages/contracts-bedrock/test/invariants/SafeCall.t.sol b/packages/contracts-bedrock/test/invariants/SafeCall.t.sol index bb2bdc5702003..66fbc0be115b6 100644 --- a/packages/contracts-bedrock/test/invariants/SafeCall.t.sol +++ b/packages/contracts-bedrock/test/invariants/SafeCall.t.sol @@ -4,7 +4,7 @@ pragma solidity 0.8.15; import { Test } from "forge-std/Test.sol"; import { StdUtils } from "forge-std/StdUtils.sol"; import { Vm } from "forge-std/Vm.sol"; -import { SafeCall } from "../../src/libraries/SafeCall.sol"; +import { SafeCall } from "src/libraries/SafeCall.sol"; contract SafeCall_Succeeds_Invariants is Test { SafeCaller_Actor actor; diff --git a/packages/contracts-bedrock/test/invariants/SystemConfig.t.sol b/packages/contracts-bedrock/test/invariants/SystemConfig.t.sol index 0b297a4c3d64b..c99228a6cac0c 100644 --- a/packages/contracts-bedrock/test/invariants/SystemConfig.t.sol +++ b/packages/contracts-bedrock/test/invariants/SystemConfig.t.sol @@ -2,10 +2,10 @@ pragma solidity 0.8.15; import { Test } from "forge-std/Test.sol"; -import { SystemConfig } from "../../src/L1/SystemConfig.sol"; -import { Proxy } from "../../src/universal/Proxy.sol"; -import { ResourceMetering } from "../../src/L1/ResourceMetering.sol"; -import { Constants } from "../../src/libraries/Constants.sol"; +import { SystemConfig } from "src/L1/SystemConfig.sol"; +import { Proxy } from "src/universal/Proxy.sol"; +import { ResourceMetering } from "src/L1/ResourceMetering.sol"; +import { Constants } from "src/libraries/Constants.sol"; contract SystemConfig_GasLimitLowerBound_Invariant is Test { SystemConfig public config; @@ -54,6 +54,14 @@ contract SystemConfig_GasLimitLowerBound_Invariant is Test { selectors[0] = config.setGasLimit.selector; FuzzSelector memory selector = FuzzSelector({ addr: address(config), selectors: selectors }); targetSelector(selector); + + /// Allows the SystemConfig contract to be the target of the invariant test + /// when it is behind a proxy. Foundry calls this function under the hood to + /// know the ABI to use when calling the target contract. + string[] memory artifacts = new string[](1); + artifacts[0] = "SystemConfig"; + FuzzInterface memory target = FuzzInterface(address(config), artifacts); + targetInterface(target); } /// @custom:invariant The gas limit of the `SystemConfig` contract can never be lower diff --git a/packages/contracts-bedrock/test/mocks/AlphabetVM.sol b/packages/contracts-bedrock/test/mocks/AlphabetVM.sol new file mode 100644 index 0000000000000..b73c5924b9bb7 --- /dev/null +++ b/packages/contracts-bedrock/test/mocks/AlphabetVM.sol @@ -0,0 +1,38 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.15; + +import { IBigStepper, IPreimageOracle } from "src/dispute/interfaces/IBigStepper.sol"; +import { PreimageOracle } from "src/cannon/PreimageOracle.sol"; +import "src/libraries/DisputeTypes.sol"; + +/// @title AlphabetVM +/// @dev A mock VM for the purpose of testing the dispute game infrastructure. +contract AlphabetVM is IBigStepper { + Claim internal immutable ABSOLUTE_PRESTATE; + IPreimageOracle public oracle; + + constructor(Claim _absolutePrestate) { + ABSOLUTE_PRESTATE = _absolutePrestate; + oracle = new PreimageOracle(); + } + + /// @inheritdoc IBigStepper + function step(bytes calldata _stateData, bytes calldata, uint256) external view returns (bytes32 postState_) { + uint256 traceIndex; + uint256 claim; + if ((keccak256(_stateData) << 8) == (Claim.unwrap(ABSOLUTE_PRESTATE) << 8)) { + // If the state data is empty, then the absolute prestate is the claim. + traceIndex = 0; + (claim) = abi.decode(_stateData, (uint256)); + } else { + // Otherwise, decode the state data. + (traceIndex, claim) = abi.decode(_stateData, (uint256, uint256)); + traceIndex++; + } + // STF: n -> n + 1 + postState_ = keccak256(abi.encode(traceIndex, claim + 1)); + assembly { + postState_ := or(and(postState_, not(shl(248, 0xFF))), shl(248, 1)) + } + } +} diff --git a/packages/contracts-bedrock/test/mocks/Callers.sol b/packages/contracts-bedrock/test/mocks/Callers.sol new file mode 100644 index 0000000000000..aa7a2dc8b2289 --- /dev/null +++ b/packages/contracts-bedrock/test/mocks/Callers.sol @@ -0,0 +1,93 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.0; + +contract CallRecorder { + struct CallInfo { + address sender; + bytes data; + uint256 gas; + uint256 value; + } + + CallInfo public lastCall; + + function record() public payable { + lastCall.sender = msg.sender; + lastCall.data = msg.data; + lastCall.gas = gasleft(); + lastCall.value = msg.value; + } +} + +/// @dev Useful for testing reentrancy guards +contract CallerCaller { + event WhatHappened(bool success, bytes returndata); + + fallback() external { + (bool success, bytes memory returndata) = msg.sender.call(msg.data); + emit WhatHappened(success, returndata); + assembly { + switch success + case 0 { revert(add(returndata, 0x20), mload(returndata)) } + default { return(add(returndata, 0x20), mload(returndata)) } + } + } +} + +/// @dev Used for testing the `CrossDomainMessenger`'s per-message reentrancy guard. +contract ConfigurableCaller { + bool doRevert = true; + address target; + bytes payload; + + event WhatHappened(bool success, bytes returndata); + + /// @notice Call the configured target with the configured payload OR revert. + function call() external { + if (doRevert) { + revert("ConfigurableCaller: revert"); + } else { + (bool success, bytes memory returndata) = address(target).call(payload); + emit WhatHappened(success, returndata); + assembly { + switch success + case 0 { revert(add(returndata, 0x20), mload(returndata)) } + default { return(add(returndata, 0x20), mload(returndata)) } + } + } + } + + /// @notice Set whether or not to have `call` revert. + function setDoRevert(bool _doRevert) external { + doRevert = _doRevert; + } + + /// @notice Set the target for the call made in `call`. + function setTarget(address _target) external { + target = _target; + } + + /// @notice Set the payload for the call made in `call`. + function setPayload(bytes calldata _payload) external { + payload = _payload; + } + + /// @notice Fallback function that reverts if `doRevert` is true. + /// Otherwise, it does nothing. + fallback() external { + if (doRevert) { + revert("ConfigurableCaller: revert"); + } + } +} + +/// @dev Any call will revert +contract Reverter { + function doRevert() public pure { + revert("Reverter reverted"); + } + + fallback() external { + revert(); + } +} diff --git a/packages/contracts-bedrock/test/mocks/EIP1967Helper.sol b/packages/contracts-bedrock/test/mocks/EIP1967Helper.sol new file mode 100644 index 0000000000000..31002b65517a6 --- /dev/null +++ b/packages/contracts-bedrock/test/mocks/EIP1967Helper.sol @@ -0,0 +1,19 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.0; + +import { Vm } from "forge-std/Vm.sol"; +import { Constants } from "src/libraries/Constants.sol"; + +/// @title EIP1967Helper +/// @dev Testing library to help with reading EIP 1967 variables from state +library EIP1967Helper { + Vm internal constant vm = Vm(0x7109709ECfa91a80626fF3989D68f67F5b1DD12D); + + function getAdmin(address _proxy) internal view returns (address) { + return address(uint160(uint256(vm.load(address(_proxy), Constants.PROXY_OWNER_ADDRESS)))); + } + + function getImplementation(address _proxy) internal view returns (address) { + return address(uint160(uint256(vm.load(address(_proxy), Constants.PROXY_IMPLEMENTATION_ADDRESS)))); + } +} diff --git a/packages/contracts-bedrock/test/mocks/FaucetHelper.sol b/packages/contracts-bedrock/test/mocks/FaucetHelper.sol new file mode 100644 index 0000000000000..e9023e2d93e8e --- /dev/null +++ b/packages/contracts-bedrock/test/mocks/FaucetHelper.sol @@ -0,0 +1,59 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.0; + +import { ECDSAUpgradeable } from "@openzeppelin/contracts-upgradeable/utils/cryptography/ECDSAUpgradeable.sol"; +import { AdminFaucetAuthModule } from "src/periphery/faucet/authmodules/AdminFaucetAuthModule.sol"; + +/// @notice Simple helper contract that helps with testing the Faucet contract. +contract FaucetHelper { + /// @notice EIP712 typehash for the Proof type. + bytes32 public constant PROOF_TYPEHASH = keccak256("Proof(address recipient,bytes32 nonce,bytes32 id)"); + + /// @notice EIP712 typehash for the EIP712Domain type that is included as part of the signature. + bytes32 public constant EIP712_DOMAIN_TYPEHASH = + keccak256("EIP712Domain(string name,string version,uint256 chainId,address verifyingContract)"); + + /// @notice Keeps track of current nonce to generate new nonces for each drip. + uint256 public currentNonce; + + /// @notice Returns a bytes32 nonce that should change everytime. In practice, people should use + /// pseudorandom nonces. + /// @return Nonce that should be used as part of drip parameters. + function consumeNonce() public returns (bytes32) { + return bytes32(keccak256(abi.encode(currentNonce++))); + } + + /// @notice Returns the hash of the struct Proof. + /// @param _proof Proof struct to hash. + /// @return EIP-712 typed struct hash. + function getProofStructHash(AdminFaucetAuthModule.Proof memory _proof) public pure returns (bytes32) { + return keccak256(abi.encode(PROOF_TYPEHASH, _proof.recipient, _proof.nonce, _proof.id)); + } + + /// @notice Computes the EIP712 digest with the given domain parameters. + /// Used for testing that different domain parameters fail. + /// @param _proof Proof struct to hash. + /// @param _name Contract name to use in the EIP712 domain. + /// @param _version Contract version to use in the EIP712 domain. + /// @param _chainid Chain ID to use in the EIP712 domain. + /// @param _verifyingContract Address to use in the EIP712 domain. + /// @param _verifyingContract Address to use in the EIP712 domain. + /// @param _verifyingContract Address to use in the EIP712 domain. + /// @return EIP-712 compatible digest. + function getDigestWithEIP712Domain( + AdminFaucetAuthModule.Proof memory _proof, + bytes memory _name, + bytes memory _version, + uint256 _chainid, + address _verifyingContract + ) + public + pure + returns (bytes32) + { + bytes32 domainSeparator = keccak256( + abi.encode(EIP712_DOMAIN_TYPEHASH, keccak256(_name), keccak256(_version), _chainid, _verifyingContract) + ); + return ECDSAUpgradeable.toTypedDataHash(domainSeparator, getProofStructHash(_proof)); + } +} diff --git a/packages/contracts-bedrock/test/mocks/NextImpl.sol b/packages/contracts-bedrock/test/mocks/NextImpl.sol new file mode 100644 index 0000000000000..3d857cfdc2d0f --- /dev/null +++ b/packages/contracts-bedrock/test/mocks/NextImpl.sol @@ -0,0 +1,21 @@ +// SPDX-License-Identifier: MIT +pragma solidity 0.8.15; + +import { Initializable } from "@openzeppelin/contracts-upgradeable/proxy/utils/Initializable.sol"; + +/// @title NextImpl +/// @dev Used for testing a future upgrade beyond the current implementations. +// We include some variables so that we can sanity check accessing storage values after an upgrade. +contract NextImpl is Initializable { + // Initializable occupies the zero-th slot. + bytes32 slot1; + bytes32[19] __gap; + bytes32 slot21; + bytes32 public constant slot21Init = bytes32(hex"1337"); + + function initialize(uint8 _init) public reinitializer(_init) { + // Slot21 is unused by an of our upgradeable contracts. + // This is used to verify that we can access this value after an upgrade. + slot21 = slot21Init; + } +} diff --git a/packages/contracts-bedrock/test/mocks/OptimistInviterHelper.sol b/packages/contracts-bedrock/test/mocks/OptimistInviterHelper.sol new file mode 100644 index 0000000000000..ebc2289f9c10d --- /dev/null +++ b/packages/contracts-bedrock/test/mocks/OptimistInviterHelper.sol @@ -0,0 +1,94 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.0; + +import { OptimistInviter } from "src/periphery/op-nft/OptimistInviter.sol"; +import { ECDSA } from "@openzeppelin/contracts/utils/cryptography/ECDSA.sol"; + +/// @notice Simple helper contract that helps with testing flow and signature for +/// OptimistInviter contract. Made this a separate contract instead of including +/// in OptimistInviter.t.sol for reusability. +contract OptimistInviterHelper { + /// @notice EIP712 typehash for the ClaimableInvite type. + bytes32 public constant CLAIMABLE_INVITE_TYPEHASH = keccak256("ClaimableInvite(address issuer,bytes32 nonce)"); + + /// @notice EIP712 typehash for the EIP712Domain type that is included as part of the signature. + bytes32 public constant EIP712_DOMAIN_TYPEHASH = + keccak256("EIP712Domain(string name,string version,uint256 chainId,address verifyingContract)"); + + /// @notice Address of OptimistInviter contract we are testing. + OptimistInviter public optimistInviter; + + /// @notice OptimistInviter contract name. Used to construct the EIP-712 domain. + string public name; + + /// @notice Keeps track of current nonce to generate new nonces for each invite. + uint256 public currentNonce; + + constructor(OptimistInviter _optimistInviter, string memory _name) { + optimistInviter = _optimistInviter; + name = _name; + } + + /// @notice Returns the hash of the struct ClaimableInvite. + /// @param _claimableInvite ClaimableInvite struct to hash. + /// @return EIP-712 typed struct hash. + function getClaimableInviteStructHash(OptimistInviter.ClaimableInvite memory _claimableInvite) + public + pure + returns (bytes32) + { + return keccak256(abi.encode(CLAIMABLE_INVITE_TYPEHASH, _claimableInvite.issuer, _claimableInvite.nonce)); + } + + /// @notice Returns a bytes32 nonce that should change everytime. In practice, people should use + /// pseudorandom nonces. + /// @return Nonce that should be used as part of ClaimableInvite. + function consumeNonce() public returns (bytes32) { + return bytes32(keccak256(abi.encode(currentNonce++))); + } + + /// @notice Returns a ClaimableInvite with the issuer and current nonce. + /// @param _issuer Issuer to include in the ClaimableInvite. + /// @return ClaimableInvite that can be hashed & signed. + function getClaimableInviteWithNewNonce(address _issuer) public returns (OptimistInviter.ClaimableInvite memory) { + return OptimistInviter.ClaimableInvite(_issuer, consumeNonce()); + } + + /// @notice Computes the EIP712 digest with default correct parameters. + /// @param _claimableInvite ClaimableInvite struct to hash. + /// @return EIP-712 compatible digest. + function getDigest(OptimistInviter.ClaimableInvite calldata _claimableInvite) public view returns (bytes32) { + return getDigestWithEIP712Domain( + _claimableInvite, + bytes(name), + bytes(optimistInviter.EIP712_VERSION()), + block.chainid, + address(optimistInviter) + ); + } + + /// @notice Computes the EIP712 digest with the given domain parameters. + /// Used for testing that different domain parameters fail. + /// @param _claimableInvite ClaimableInvite struct to hash. + /// @param _name Contract name to use in the EIP712 domain. + /// @param _version Contract version to use in the EIP712 domain. + /// @param _chainid Chain ID to use in the EIP712 domain. + /// @param _verifyingContract Address to use in the EIP712 domain. + /// @return EIP-712 compatible digest. + function getDigestWithEIP712Domain( + OptimistInviter.ClaimableInvite calldata _claimableInvite, + bytes memory _name, + bytes memory _version, + uint256 _chainid, + address _verifyingContract + ) + public + pure + returns (bytes32) + { + bytes32 domainSeparator = keccak256( + abi.encode(EIP712_DOMAIN_TYPEHASH, keccak256(_name), keccak256(_version), _chainid, _verifyingContract) + ); + return ECDSA.toTypedDataHash(domainSeparator, getClaimableInviteStructHash(_claimableInvite)); + } +} diff --git a/packages/contracts-bedrock/test/mocks/SimpleStorage.sol b/packages/contracts-bedrock/test/mocks/SimpleStorage.sol new file mode 100644 index 0000000000000..218505b24c058 --- /dev/null +++ b/packages/contracts-bedrock/test/mocks/SimpleStorage.sol @@ -0,0 +1,14 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.0; + +contract SimpleStorage { + mapping(bytes32 => bytes32) public db; + + function set(bytes32 _key, bytes32 _value) public payable { + db[_key] = _value; + } + + function get(bytes32 _key) public view returns (bytes32) { + return db[_key]; + } +} diff --git a/packages/contracts-bedrock/test/mocks/TestERC1271Wallet.sol b/packages/contracts-bedrock/test/mocks/TestERC1271Wallet.sol new file mode 100644 index 0000000000000..c04ed608b7d70 --- /dev/null +++ b/packages/contracts-bedrock/test/mocks/TestERC1271Wallet.sol @@ -0,0 +1,19 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.0; + +import { Ownable } from "@openzeppelin/contracts/access/Ownable.sol"; +import { IERC1271 } from "@openzeppelin/contracts/interfaces/IERC1271.sol"; +import { ECDSA } from "@openzeppelin/contracts/utils/cryptography/ECDSA.sol"; + +/// @notice Simple ERC1271 wallet that can be used to test the ERC1271 signature checker. +/// @notice https://github.com/OpenZeppelin/openzeppelin-contracts/ +/// blob/master/contracts/mocks/ERC1271WalletMock.sol +contract TestERC1271Wallet is Ownable, IERC1271 { + constructor(address originalOwner) { + transferOwnership(originalOwner); + } + + function isValidSignature(bytes32 hash, bytes memory signature) public view override returns (bytes4 magicValue) { + return ECDSA.recover(hash, signature) == owner() ? this.isValidSignature.selector : bytes4(0); + } +} diff --git a/packages/contracts-bedrock/test/mocks/TestERC20.sol b/packages/contracts-bedrock/test/mocks/TestERC20.sol new file mode 100644 index 0000000000000..0c6603ce401f4 --- /dev/null +++ b/packages/contracts-bedrock/test/mocks/TestERC20.sol @@ -0,0 +1,12 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.0; + +import { ERC20 } from "@rari-capital/solmate/src/tokens/ERC20.sol"; + +contract TestERC20 is ERC20 { + constructor() ERC20("TEST", "TST", 18) { } + + function mint(address to, uint256 value) public { + _mint(to, value); + } +} diff --git a/packages/contracts-bedrock/test/mocks/TestERC721.sol b/packages/contracts-bedrock/test/mocks/TestERC721.sol new file mode 100644 index 0000000000000..294b4a93c7e52 --- /dev/null +++ b/packages/contracts-bedrock/test/mocks/TestERC721.sol @@ -0,0 +1,14 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.0; + +import { ERC721 } from "@rari-capital/solmate/src/tokens/ERC721.sol"; + +contract TestERC721 is ERC721 { + constructor() ERC721("TEST", "TST") { } + + function mint(address to, uint256 tokenId) public { + _mint(to, tokenId); + } + + function tokenURI(uint256) public pure virtual override returns (string memory) { } +} diff --git a/packages/contracts-bedrock/test/safe-tools/CompatibilityFallbackHandler_1_3_0.sol b/packages/contracts-bedrock/test/safe-tools/CompatibilityFallbackHandler_1_3_0.sol new file mode 100644 index 0000000000000..a0efa0e68b269 --- /dev/null +++ b/packages/contracts-bedrock/test/safe-tools/CompatibilityFallbackHandler_1_3_0.sol @@ -0,0 +1,213 @@ +// SPDX-License-Identifier: LGPL-3.0-only +pragma solidity >=0.7.0 <0.9.0; + +import "safe-contracts/interfaces/ERC1155TokenReceiver.sol"; +import "safe-contracts/interfaces/ERC721TokenReceiver.sol"; +import "safe-contracts/interfaces/ERC777TokensRecipient.sol"; +import "safe-contracts/interfaces/IERC165.sol"; +import "safe-contracts/interfaces/ISignatureValidator.sol"; +import { Safe as GnosisSafe } from "safe-contracts/Safe.sol"; + +/// author: Colin Nielsen +/// https://github.com/colinnielsen/safe-tools/blob/ce6c654a76d91b619ab7778c77d1a76b3ced6666/src/CompatibilityFallbackHandler_1_3_0.sol +contract DefaultCallbackHandler is ERC1155TokenReceiver, ERC777TokensRecipient, ERC721TokenReceiver, IERC165 { + function onERC1155Received( + address, + address, + uint256, + uint256, + bytes calldata + ) + external + pure + override + returns (bytes4) + { + return 0xf23a6e61; + } + + function onERC1155BatchReceived( + address, + address, + uint256[] calldata, + uint256[] calldata, + bytes calldata + ) + external + pure + override + returns (bytes4) + { + return 0xbc197c81; + } + + function onERC721Received(address, address, uint256, bytes calldata) external pure override returns (bytes4) { + return 0x150b7a02; + } + + function tokensReceived( + address, + address, + address, + uint256, + bytes calldata, + bytes calldata + ) + external + pure + override + { + // We implement this for completeness, doesn't really have any value + } + + function supportsInterface(bytes4 interfaceId) external view virtual override returns (bool) { + return interfaceId == type(ERC1155TokenReceiver).interfaceId + || interfaceId == type(ERC721TokenReceiver).interfaceId || interfaceId == type(IERC165).interfaceId; + } +} + +address constant SENTINEL_MODULES = address(0x1); + +/// @title Compatibility Fallback Handler - fallback handler to provider compatibility between pre 1.3.0 and 1.3.0+ Safe +/// contracts +/// @author Richard Meissner - +contract CompatibilityFallbackHandler is DefaultCallbackHandler, ISignatureValidator { + //keccak256( + // "SafeMessage(bytes message)" + //); + bytes32 private constant SAFE_MSG_TYPEHASH = 0x60b3cbf8b4a223d68d641b3b6ddf9a298e7f33710cf3d3a9d1146b5a6150fbca; + + bytes4 internal constant SIMULATE_SELECTOR = bytes4(keccak256("simulate(address,bytes)")); + + bytes4 internal constant UPDATED_MAGIC_VALUE = 0x1626ba7e; + + /** + * Implementation of ISignatureValidator (see `interfaces/ISignatureValidator.sol`) + * @dev Should return whether the signature provided is valid for the provided data. + * @param _data Arbitrary length data signed on the behalf of address(msg.sender) + * @param _signature Signature byte array associated with _data + * @return a bool upon valid or invalid signature with corresponding _data + */ + function isValidSignature(bytes memory _data, bytes memory _signature) public view override returns (bytes4) { + // Caller should be a Safe + GnosisSafe safe = GnosisSafe(payable(msg.sender)); + bytes32 messageHash = getMessageHashForSafe(safe, _data); + if (_signature.length == 0) { + require(safe.signedMessages(messageHash) != 0, "Hash not approved"); + } else { + safe.checkSignatures(messageHash, _data, _signature); + } + return EIP1271_MAGIC_VALUE; + } + + /// @dev Returns hash of a message that can be signed by owners. + /// @param message Message that should be hashed + /// @return Message hash. + function getMessageHash(bytes memory message) public view returns (bytes32) { + return getMessageHashForSafe(GnosisSafe(payable(msg.sender)), message); + } + + /// @dev Returns hash of a message that can be signed by owners. + /// @param safe Safe to which the message is targeted + /// @param message Message that should be hashed + /// @return Message hash. + function getMessageHashForSafe(GnosisSafe safe, bytes memory message) public view returns (bytes32) { + bytes32 safeMessageHash = keccak256(abi.encode(SAFE_MSG_TYPEHASH, keccak256(message))); + return keccak256(abi.encodePacked(bytes1(0x19), bytes1(0x01), safe.domainSeparator(), safeMessageHash)); + } + + /** + * Implementation of updated EIP-1271 + * @dev Should return whether the signature provided is valid for the provided data. + * The save does not implement the interface since `checkSignatures` is not a view method. + * The method will not perform any state changes (see parameters of `checkSignatures`) + * @param _dataHash Hash of the data signed on the behalf of address(msg.sender) + * @param _signature Signature byte array associated with _dataHash + * @return a bool upon valid or invalid signature with corresponding _dataHash + * @notice See + * https://github.com/gnosis/util-contracts/blob/bb5fe5fb5df6d8400998094fb1b32a178a47c3a1/contracts/StorageAccessible.sol + */ + function isValidSignature(bytes32 _dataHash, bytes calldata _signature) external view returns (bytes4) { + ISignatureValidator validator = ISignatureValidator(msg.sender); + bytes4 value = validator.isValidSignature(abi.encode(_dataHash), _signature); + return (value == EIP1271_MAGIC_VALUE) ? UPDATED_MAGIC_VALUE : bytes4(0); + } + + /// @dev Returns array of first 10 modules. + /// @return Array of modules. + function getModules() external view returns (address[] memory) { + // Caller should be a Safe + GnosisSafe safe = GnosisSafe(payable(msg.sender)); + (address[] memory array,) = safe.getModulesPaginated(SENTINEL_MODULES, 10); + return array; + } + + /** + * @dev Performs a delegetecall on a targetContract in the context of self. + * Internally reverts execution to avoid side effects (making it static). Catches revert and returns encoded result + * as bytes. + * @param targetContract Address of the contract containing the code to execute. + * @param calldataPayload Calldata that should be sent to the target contract (encoded method name and arguments). + */ + function simulate( + address targetContract, + bytes calldata calldataPayload + ) + external + returns (bytes memory response) + { + // Suppress compiler warnings about not using parameters, while allowing + // parameters to keep names for documentation purposes. This does not + // generate code. + targetContract; + calldataPayload; + + // solhint-disable-next-line no-inline-assembly + assembly { + let internalCalldata := mload(0x40) + // Store `simulateAndRevert.selector`. + // String representation is used to force right padding + mstore(internalCalldata, "\xb4\xfa\xba\x09") + // Abuse the fact that both this and the internal methods have the + // same signature, and differ only in symbol name (and therefore, + // selector) and copy calldata directly. This saves us approximately + // 250 bytes of code and 300 gas at runtime over the + // `abi.encodeWithSelector` builtin. + calldatacopy(add(internalCalldata, 0x04), 0x04, sub(calldatasize(), 0x04)) + + // `pop` is required here by the compiler, as top level expressions + // can't have return values in inline assembly. `call` typically + // returns a 0 or 1 value indicated whether or not it reverted, but + // since we know it will always revert, we can safely ignore it. + pop( + call( + gas(), + // address() has been changed to caller() to use the implementation of the Safe + caller(), + 0, + internalCalldata, + calldatasize(), + // The `simulateAndRevert` call always reverts, and + // instead encodes whether or not it was successful in the return + // data. The first 32-byte word of the return data contains the + // `success` value, so write it to memory address 0x00 (which is + // reserved Solidity scratch space and OK to use). + 0x00, + 0x20 + ) + ) + + // Allocate and copy the response bytes, making sure to increment + // the free memory pointer accordingly (in case this method is + // called as an internal function). The remaining `returndata[0x20:]` + // contains the ABI encoded response bytes, so we can just write it + // as is to memory. + let responseSize := sub(returndatasize(), 0x20) + response := mload(0x40) + mstore(0x40, add(response, responseSize)) + returndatacopy(response, 0x20, responseSize) + + if iszero(mload(0x00)) { revert(add(response, 0x20), mload(response)) } + } + } +} diff --git a/packages/contracts-bedrock/test/safe-tools/SafeTestTools.sol b/packages/contracts-bedrock/test/safe-tools/SafeTestTools.sol new file mode 100644 index 0000000000000..93b33fbab2a94 --- /dev/null +++ b/packages/contracts-bedrock/test/safe-tools/SafeTestTools.sol @@ -0,0 +1,636 @@ +// SPDX-License-Identifier: MIT +pragma solidity >=0.7.0 <0.9.0; + +import "forge-std/Test.sol"; +import "scripts/libraries/LibSort.sol"; +import { Safe as GnosisSafe, OwnerManager, ModuleManager, GuardManager } from "safe-contracts/Safe.sol"; +import { SafeProxyFactory as GnosisSafeProxyFactory } from "safe-contracts/proxies/SafeProxyFactory.sol"; +import { Enum } from "safe-contracts/common/Enum.sol"; +import { SignMessageLib } from "safe-contracts/libraries/SignMessageLib.sol"; +import "./CompatibilityFallbackHandler_1_3_0.sol"; + +// Tools to simplify testing Safe contracts +// Author: Colin Nielsen (https://github.com/colinnielsen/safe-tools) +// With expanded and improved functionality by OP Labs + +/// @dev A minimal wrapper around the OwnerManager contract. This contract is meant to be initialized with +/// the same owners as a Safe instance, and then used to simulate the resulting owners list +/// after an owner is removed. +contract OwnerSimulator is OwnerManager { + constructor(address[] memory _owners, uint256 _threshold) { + setupOwners(_owners, _threshold); + } + + /// @dev Exposes the OwnerManager's removeOwner function so that anyone may call without needing auth + function removeOwnerWrapped(address prevOwner, address owner, uint256 _threshold) public { + OwnerManager(address(this)).removeOwner(prevOwner, owner, _threshold); + } +} + +/// @dev collapsed interface that includes comapatibilityfallback handler calls +abstract contract DeployedSafe is GnosisSafe, CompatibilityFallbackHandler { } + +struct AdvancedSafeInitParams { + bool includeFallbackHandler; + uint256 saltNonce; + address setupModulesCall_to; + bytes setupModulesCall_data; + uint256 refundAmount; + address refundToken; + address payable refundReceiver; + bytes initData; +} + +struct SafeInstance { + uint256 instanceId; + uint256[] ownerPKs; + address[] owners; + uint256 threshold; + DeployedSafe safe; +} + +library Sort { + /// @dev Sorts an array of addresses in place + function sort(address[] memory arr) public pure returns (address[] memory) { + LibSort.sort(arr); + return arr; + } +} + +library SafeTestLib { + /// @dev The address of foundry's VM contract + address constant VM_ADDR = 0x7109709ECfa91a80626fF3989D68f67F5b1DD12D; + /// @dev The address of the first owner in the linked list of owners + address constant SENTINEL_OWNERS = address(0x1); + + /// @dev Get the address from a private key + function getAddr(uint256 pk) internal pure returns (address) { + return Vm(VM_ADDR).addr(pk); + } + + /// @dev Get arrays of addresses and private keys. The arrays are sorted by address, and the addresses are labelled + function makeAddrsAndKeys( + string memory prefix, + uint256 num + ) + internal + returns (address[] memory addrs, uint256[] memory keys) + { + keys = new uint256[](num); + addrs = new address[](num); + for (uint256 i; i < num; i++) { + uint256 key = uint256(keccak256(abi.encodePacked(i))); + keys[i] = key; + } + + for (uint256 i; i < num; i++) { + addrs[i] = Vm(VM_ADDR).addr(keys[i]); + Vm(VM_ADDR).label(getAddr(keys[i]), string.concat(prefix, Vm(VM_ADDR).toString(i))); + } + } + + bytes12 constant ADDR_MASK = 0xffffffffffffffffffffffff; + + /// @dev Encode a smart contract wallet as a private key + function encodeSmartContractWalletAsPK(address addr) internal pure returns (uint256 encodedPK) { + assembly { + let addr_b32 := addr + encodedPK := or(addr, ADDR_MASK) + } + } + + /// @dev Decode a smart contract wallet as an address from a private key + function decodeSmartContractWalletAsAddress(uint256 pk) internal pure returns (address decodedAddr) { + assembly { + let addr := shl(96, pk) + decodedAddr := shr(96, addr) + } + } + + /// @dev Checks if a private key is an encoded smart contract address + function isSmartContractPK(uint256 pk) internal pure returns (bool isEncoded) { + assembly { + isEncoded := eq(shr(160, pk), shr(160, ADDR_MASK)) + } + } + + /// @dev Sorts an array of private keys by the computed address + /// If the private key is a smart contract wallet, it will be decoded and sorted by the address + function sortPKsByComputedAddress(uint256[] memory _pks) internal pure returns (uint256[] memory) { + uint256[] memory sortedPKs = new uint256[](_pks.length); + + address[] memory addresses = new address[](_pks.length); + bytes32[2][] memory accounts = new bytes32[2][](_pks.length); + + for (uint256 i; i < _pks.length; i++) { + uint256 pk = _pks[i]; + address signer = SafeTestLib.getAddr(pk); + if (isSmartContractPK(pk)) { + signer = decodeSmartContractWalletAsAddress(pk); + } + addresses[i] = signer; + accounts[i][0] = bytes32(abi.encode(signer)); + accounts[i][1] = bytes32(pk); + } + + addresses = Sort.sort(addresses); + + uint256 found; + for (uint256 j; j < addresses.length; j++) { + address signer = addresses[j]; + uint256 pk; + for (uint256 k; k < accounts.length; k++) { + if (address(uint160(uint256(accounts[k][0]))) == signer) { + pk = uint256(accounts[k][1]); + found++; + } + } + + sortedPKs[j] = pk; + } + + if (found < _pks.length) { + revert("SAFETESTTOOLS: issue with private key sorting, please open a ticket on github"); + } + return sortedPKs; + } + + /// @dev Sign a transaction as a safe owner with a private key. + function signTransaction( + SafeInstance memory instance, + uint256 pk, + address to, + uint256 value, + bytes memory data, + Enum.Operation operation, + uint256 safeTxGas, + uint256 baseGas, + uint256 gasPrice, + address gasToken, + address refundReceiver + ) + internal + view + returns (uint8 v, bytes32 r, bytes32 s) + { + bytes32 txDataHash; + { + uint256 _nonce = instance.safe.nonce(); + txDataHash = instance.safe.getTransactionHash({ + to: to, + value: value, + data: data, + operation: operation, + safeTxGas: safeTxGas, + baseGas: baseGas, + gasPrice: gasPrice, + gasToken: gasToken, + refundReceiver: refundReceiver, + _nonce: _nonce + }); + } + + (v, r, s) = Vm(VM_ADDR).sign(pk, txDataHash); + } + + /// @dev Get the previous owner in the linked list of owners. + /// This version of getPrevOwner will call to the Safe contract to get the current list of owners. + /// Note that this will break vm.expectRevert() tests by making a call which does not revert.. + /// @param _owner The owner whose previous owner we want to find + function getPrevOwner(SafeInstance memory instance, address _owner) internal view returns (address prevOwner_) { + address[] memory owners = instance.safe.getOwners(); + prevOwner_ = getPrevOwnerFromList(_owner, owners); + } + + /// @dev Get the previous owner in the provided list of owners. + /// This version of getPrevOwner accepts a list of owners, and will return the previous owner. + /// It is useful when testing for a revert, as it avoids the need to call to the Safe contract. + /// @param _owner The owner whose previous owner we want to find + /// @param _ownersList The list of owners to search in + function getPrevOwnerFromList( + address _owner, + address[] memory _ownersList + ) + internal + pure + returns (address prevOwner_) + { + for (uint256 i; i < _ownersList.length; i++) { + if (_ownersList[i] != _owner) continue; + if (i == 0) { + prevOwner_ = SENTINEL_OWNERS; + break; + } + prevOwner_ = _ownersList[i - 1]; + } + } + + /// @dev Given an array of owners to remove, this function will return an array of the previous owners + /// in the order that they must be provided to the LivenessMoules's removeOwners() function. + /// Because owners are removed one at a time, and not necessarily in order, we need to simulate + /// the owners list after each removal, in order to identify the correct previous owner. + /// @param _ownersToRemove The owners to remove + /// @return prevOwners_ The previous owners in the linked list + function getPrevOwners( + SafeInstance memory instance, + address[] memory _ownersToRemove + ) + internal + returns (address[] memory prevOwners_) + { + OwnerSimulator ownerSimulator = new OwnerSimulator(instance.owners, 1); + prevOwners_ = new address[](_ownersToRemove.length); + address[] memory currentOwners; + for (uint256 i; i < _ownersToRemove.length; i++) { + currentOwners = ownerSimulator.getOwners(); + prevOwners_[i] = SafeTestLib.getPrevOwnerFromList(_ownersToRemove[i], currentOwners); + + // Don't try to remove the last owner + if (currentOwners.length == 1) break; + ownerSimulator.removeOwnerWrapped(prevOwners_[i], _ownersToRemove[i], 1); + } + } + + /// @dev Enables a module on the Safe. + function enableModule(SafeInstance memory instance, address module) internal { + execTransaction( + instance, + address(instance.safe), + 0, + abi.encodeWithSelector(ModuleManager.enableModule.selector, module), + Enum.Operation.Call, + 0, + 0, + 0, + address(0), + address(0), + "" + ); + } + + /// @dev Disables a module on the Safe. + function disableModule(SafeInstance memory instance, address module) internal { + (address[] memory modules,) = instance.safe.getModulesPaginated(SENTINEL_MODULES, 1000); + address prevModule = SENTINEL_MODULES; + bool moduleFound; + for (uint256 i; i < modules.length; i++) { + if (modules[i] == module) { + moduleFound = true; + break; + } + prevModule = modules[i]; + } + if (!moduleFound) revert("SAFETESTTOOLS: cannot disable module that is not enabled"); + + execTransaction( + instance, + address(instance.safe), + 0, + abi.encodeWithSelector(ModuleManager.disableModule.selector, prevModule, module), + Enum.Operation.Call, + 0, + 0, + 0, + address(0), + address(0), + "" + ); + } + + /// @dev Sets the guard address on the Safe. Unlike modules there can only be one guard, so + /// this method will remove the previous guard. If the guard is set to the 0 address, the + /// guard will be disabled. + function setGuard(SafeInstance memory instance, address guard) internal { + execTransaction( + instance, + address(instance.safe), + 0, + abi.encodeWithSelector(GuardManager.setGuard.selector, guard), + Enum.Operation.Call, + 0, + 0, + 0, + address(0), + address(0), + "" + ); + } + + /// @dev Signs message data using EIP1271: Standard Signature Validation Method for Contracts + function EIP1271Sign(SafeInstance memory instance, bytes memory data) internal { + address signMessageLib = address(new SignMessageLib()); + execTransaction({ + instance: instance, + to: signMessageLib, + value: 0, + data: abi.encodeWithSelector(SignMessageLib.signMessage.selector, data), + operation: Enum.Operation.DelegateCall, + safeTxGas: 0, + baseGas: 0, + gasPrice: 0, + gasToken: address(0), + refundReceiver: payable(address(0)), + signatures: "" + }); + } + + /// @dev Signs a data hash using EIP1271: Standard Signature Validation Method for Contracts + function EIP1271Sign(SafeInstance memory instance, bytes32 digest) internal { + EIP1271Sign(instance, abi.encodePacked(digest)); + } + + /// @dev Increments the nonce of the Safe by sending an empty transaction. + function incrementNonce(SafeInstance memory instance) internal returns (uint256 newNonce) { + execTransaction(instance, address(0), 0, "", Enum.Operation.Call, 0, 0, 0, address(0), address(0), ""); + return instance.safe.nonce(); + } + + /// @dev Adds a new owner to the safe + function changeThreshold(SafeInstance memory instance, uint256 threshold) internal { + execTransaction( + instance, + address(instance.safe), + 0, + abi.encodeWithSelector(OwnerManager.changeThreshold.selector, threshold) + ); + } + + /// @dev Adds a new owner to the safe + function addOwnerWithThreshold(SafeInstance memory instance, address owner, uint256 threshold) internal { + execTransaction( + instance, + address(instance.safe), + 0, + abi.encodeWithSelector(OwnerManager.addOwnerWithThreshold.selector, owner, threshold) + ); + } + + /// @dev Removes an owner from the safe. If not provided explictly, the identification of the prevOwner is handled + /// automatically. + function removeOwner(SafeInstance memory instance, address prevOwner, address owner, uint256 threshold) internal { + prevOwner = prevOwner > address(0) ? prevOwner : SafeTestLib.getPrevOwner(instance, owner); + execTransaction( + instance, + address(instance.safe), + 0, + abi.encodeWithSelector(OwnerManager.removeOwner.selector, prevOwner, owner, threshold) + ); + } + + /// @dev Replaces an old owner with a new owner. If not provided explictly, the identification of the prevOwner is + /// handled automatically. + function swapOwner(SafeInstance memory instance, address prevOwner, address oldOwner, address newOwner) internal { + prevOwner = prevOwner > address(0) ? prevOwner : SafeTestLib.getPrevOwner(instance, oldOwner); + execTransaction( + instance, + address(instance.safe), + 0, + abi.encodeWithSelector(OwnerManager.swapOwner.selector, prevOwner, oldOwner, newOwner) + ); + } + + /// @dev A wrapper for the full execTransaction method, if no signatures are provided it will + /// generate them for all owners. + function execTransaction( + SafeInstance memory instance, + address to, + uint256 value, + bytes memory data, + Enum.Operation operation, + uint256 safeTxGas, + uint256 baseGas, + uint256 gasPrice, + address gasToken, + address refundReceiver, + bytes memory signatures + ) + internal + returns (bool) + { + if (instance.owners.length == 0) { + revert("SAFETEST: Instance not initialized. Call _setupSafe() to initialize a test safe"); + } + + bytes32 safeTxHash; + { + uint256 _nonce = instance.safe.nonce(); + safeTxHash = instance.safe.getTransactionHash({ + to: to, + value: value, + data: data, + operation: operation, + safeTxGas: safeTxGas, + baseGas: baseGas, + gasPrice: gasPrice, + gasToken: gasToken, + refundReceiver: refundReceiver, + _nonce: _nonce + }); + } + + if (signatures.length == 0) { + for (uint256 i; i < instance.ownerPKs.length; ++i) { + uint256 pk = instance.ownerPKs[i]; + (uint8 v, bytes32 r, bytes32 s) = Vm(VM_ADDR).sign(pk, safeTxHash); + if (isSmartContractPK(pk)) { + v = 0; + address addr = decodeSmartContractWalletAsAddress(pk); + assembly { + r := addr + } + console.logBytes32(r); + } + signatures = bytes.concat(signatures, abi.encodePacked(r, s, v)); + } + } + + return instance.safe.execTransaction({ + to: to, + value: value, + data: data, + operation: operation, + safeTxGas: safeTxGas, + baseGas: baseGas, + gasPrice: gasPrice, + gasToken: gasToken, + refundReceiver: payable(refundReceiver), + signatures: signatures + }); + } + + /// @dev Executes either a CALL or DELEGATECALL transaction. + function execTransaction( + SafeInstance memory instance, + address to, + uint256 value, + bytes memory data, + Enum.Operation operation + ) + internal + returns (bool) + { + return execTransaction(instance, to, value, data, operation, 0, 0, 0, address(0), address(0), ""); + } + + /// @dev Executes a CALL transaction. + function execTransaction( + SafeInstance memory instance, + address to, + uint256 value, + bytes memory data + ) + internal + returns (bool) + { + return execTransaction(instance, to, value, data, Enum.Operation.Call, 0, 0, 0, address(0), address(0), ""); + } +} + +/// @dev SafeTestTools implements a set of helper functions for testing Safe contracts. +contract SafeTestTools { + using SafeTestLib for SafeInstance; + + GnosisSafe internal singleton = new GnosisSafe(); + GnosisSafeProxyFactory internal proxyFactory = new GnosisSafeProxyFactory(); + CompatibilityFallbackHandler internal handler = new CompatibilityFallbackHandler(); + + SafeInstance[] internal instances; + + /// @dev can be called to reinitialize the singleton, proxyFactory and handler. Useful for forking. + function _initializeSafeTools() internal { + singleton = new GnosisSafe(); + proxyFactory = new GnosisSafeProxyFactory(); + handler = new CompatibilityFallbackHandler(); + } + + function _setupSafe( + uint256[] memory ownerPKs, + uint256 threshold, + uint256 initialBalance, + AdvancedSafeInitParams memory advancedParams + ) + public + returns (SafeInstance memory) + { + uint256[] memory sortedPKs = SafeTestLib.sortPKsByComputedAddress(ownerPKs); + address[] memory owners = new address[](sortedPKs.length); + + for (uint256 i; i < sortedPKs.length; i++) { + if (SafeTestLib.isSmartContractPK(sortedPKs[i])) { + owners[i] = SafeTestLib.decodeSmartContractWalletAsAddress(sortedPKs[i]); + } else { + owners[i] = SafeTestLib.getAddr(sortedPKs[i]); + } + } + // store the initialization parameters + + bytes memory initData = advancedParams.initData.length > 0 + ? advancedParams.initData + : abi.encodeWithSelector( + GnosisSafe.setup.selector, + owners, + threshold, + advancedParams.setupModulesCall_to, + advancedParams.setupModulesCall_data, + advancedParams.includeFallbackHandler ? address(handler) : address(0), + advancedParams.refundToken, + advancedParams.refundAmount, + advancedParams.refundReceiver + ); + + DeployedSafe safe0 = DeployedSafe( + payable(proxyFactory.createProxyWithNonce(address(singleton), initData, advancedParams.saltNonce)) + ); + + SafeInstance memory instance0 = SafeInstance({ + instanceId: instances.length, + ownerPKs: sortedPKs, + owners: owners, + threshold: threshold, + // setup safe ecosystem, singleton, proxy factory, fallback handler, and create a new safe + safe: safe0 + }); + instances.push(instance0); + + Vm(SafeTestLib.VM_ADDR).deal(address(safe0), initialBalance); + + return instance0; + } + + function _setupSafe( + uint256[] memory ownerPKs, + uint256 threshold, + uint256 initialBalance + ) + public + returns (SafeInstance memory) + { + return _setupSafe( + ownerPKs, + threshold, + initialBalance, + AdvancedSafeInitParams({ + includeFallbackHandler: true, + initData: "", + saltNonce: 0, + setupModulesCall_to: address(0), + setupModulesCall_data: "", + refundAmount: 0, + refundToken: address(0), + refundReceiver: payable(address(0)) + }) + ); + } + + function _setupSafe(uint256[] memory ownerPKs, uint256 threshold) public returns (SafeInstance memory) { + return _setupSafe( + ownerPKs, + threshold, + 10000 ether, + AdvancedSafeInitParams({ + includeFallbackHandler: true, + initData: "", + saltNonce: 0, + setupModulesCall_to: address(0), + setupModulesCall_data: "", + refundAmount: 0, + refundToken: address(0), + refundReceiver: payable(address(0)) + }) + ); + } + + function _setupSafe() public returns (SafeInstance memory) { + (, uint256[] memory defaultPKs) = SafeTestLib.makeAddrsAndKeys("default", 3); + + return _setupSafe( + defaultPKs, + 2, + 10000 ether, + AdvancedSafeInitParams({ + includeFallbackHandler: true, + initData: "", + saltNonce: uint256(keccak256(bytes("SAFE TEST"))), + setupModulesCall_to: address(0), + setupModulesCall_data: "", + refundAmount: 0, + refundToken: address(0), + refundReceiver: payable(address(0)) + }) + ); + } + + function getSafe() public view returns (SafeInstance memory) { + if (instances.length == 0) { + revert("SAFETESTTOOLS: Test Safe has not been deployed, use _setupSafe() calling safe()"); + } + return instances[0]; + } + + function getSafe(address _safe) public view returns (SafeInstance memory) { + for (uint256 i; i < instances.length; ++i) { + if (address(instances[i].safe) == _safe) return instances[i]; + } + revert("SAFETESTTOOLS: Safe instance not found"); + } +} diff --git a/packages/contracts-bedrock/test/setup/Bridge_Initializer.sol b/packages/contracts-bedrock/test/setup/Bridge_Initializer.sol new file mode 100644 index 0000000000000..6b931712935ea --- /dev/null +++ b/packages/contracts-bedrock/test/setup/Bridge_Initializer.sol @@ -0,0 +1,69 @@ +// SPDX-License-Identifier: MIT +pragma solidity 0.8.15; + +import { CommonTest } from "test/setup/CommonTest.sol"; +import { ERC20 } from "@openzeppelin/contracts/token/ERC20/ERC20.sol"; +import { OptimismMintableERC20 } from "src/universal/OptimismMintableERC20.sol"; +import { LegacyMintableERC20 } from "src/legacy/LegacyMintableERC20.sol"; + +/// @title Bridge_Initializer +/// @dev This contract extends the CommonTest contract with token deployments +/// meant to be used with the bridge contracts. +contract Bridge_Initializer is CommonTest { + ERC20 L1Token; + ERC20 BadL1Token; + OptimismMintableERC20 L2Token; + LegacyMintableERC20 LegacyL2Token; + ERC20 NativeL2Token; + ERC20 BadL2Token; + OptimismMintableERC20 RemoteL1Token; + + function setUp() public virtual override { + super.setUp(); + + L1Token = new ERC20("Native L1 Token", "L1T"); + + LegacyL2Token = new LegacyMintableERC20({ + _l2Bridge: address(l2StandardBridge), + _l1Token: address(L1Token), + _name: string.concat("LegacyL2-", L1Token.name()), + _symbol: string.concat("LegacyL2-", L1Token.symbol()) + }); + vm.label(address(LegacyL2Token), "LegacyMintableERC20"); + + // Deploy the L2 ERC20 now + L2Token = OptimismMintableERC20( + l2OptimismMintableERC20Factory.createStandardL2Token( + address(L1Token), + string(abi.encodePacked("L2-", L1Token.name())), + string(abi.encodePacked("L2-", L1Token.symbol())) + ) + ); + + BadL2Token = OptimismMintableERC20( + l2OptimismMintableERC20Factory.createStandardL2Token( + address(1), + string(abi.encodePacked("L2-", L1Token.name())), + string(abi.encodePacked("L2-", L1Token.symbol())) + ) + ); + + NativeL2Token = new ERC20("Native L2 Token", "L2T"); + + RemoteL1Token = OptimismMintableERC20( + l1OptimismMintableERC20Factory.createStandardL2Token( + address(NativeL2Token), + string(abi.encodePacked("L1-", NativeL2Token.name())), + string(abi.encodePacked("L1-", NativeL2Token.symbol())) + ) + ); + + BadL1Token = OptimismMintableERC20( + l1OptimismMintableERC20Factory.createStandardL2Token( + address(1), + string(abi.encodePacked("L1-", NativeL2Token.name())), + string(abi.encodePacked("L1-", NativeL2Token.symbol())) + ) + ); + } +} diff --git a/packages/contracts-bedrock/test/setup/CommonTest.sol b/packages/contracts-bedrock/test/setup/CommonTest.sol new file mode 100644 index 0000000000000..74f040aa1da63 --- /dev/null +++ b/packages/contracts-bedrock/test/setup/CommonTest.sol @@ -0,0 +1,84 @@ +// SPDX-License-Identifier: MIT +pragma solidity 0.8.15; + +import { Test } from "forge-std/Test.sol"; +import { Setup } from "test/setup/Setup.sol"; +import { Events } from "test/setup/Events.sol"; +import { FFIInterface } from "test/setup/FFIInterface.sol"; + +/// @title CommonTest +/// @dev An extenstion to `Test` that sets up the optimism smart contracts. +contract CommonTest is Setup, Test, Events { + address alice = address(128); + address bob = address(256); + + bytes32 constant nonZeroHash = keccak256(abi.encode("NON_ZERO")); + + FFIInterface ffi; + + function setUp() public virtual override { + vm.deal(alice, type(uint64).max); + vm.deal(bob, type(uint64).max); + + vm.label(alice, "alice"); + vm.label(bob, "bob"); + + Setup.setUp(); + ffi = new FFIInterface(); + + // Make sure the base fee is non zero + vm.fee(1 gwei); + + // Set sane initialize block numbers + vm.warp(cfg.l2OutputOracleStartingTimestamp() + 1); + vm.roll(cfg.l2OutputOracleStartingBlockNumber() + 1); + + // Deploy L1 + Setup.L1(); + // Deploy L2 + Setup.L2({ cfg: cfg }); + } + + /// @dev Helper function that wraps `TransactionDeposited` event. + /// The magic `0` is the version. + function emitTransactionDeposited( + address _from, + address _to, + uint256 _mint, + uint256 _value, + uint64 _gasLimit, + bool _isCreation, + bytes memory _data + ) + internal + { + emit TransactionDeposited(_from, _to, 0, abi.encodePacked(_mint, _value, _gasLimit, _isCreation, _data)); + } + + // @dev Advance the evm's time to meet the L2OutputOracle's requirements for proposeL2Output + function warpToProposeTime(uint256 _nextBlockNumber) public { + vm.warp(l2OutputOracle.computeL2Timestamp(_nextBlockNumber) + 1); + } + + /// @dev Helper function to propose an output. + function proposeAnotherOutput() public { + bytes32 proposedOutput2 = keccak256(abi.encode()); + uint256 nextBlockNumber = l2OutputOracle.nextBlockNumber(); + uint256 nextOutputIndex = l2OutputOracle.nextOutputIndex(); + warpToProposeTime(nextBlockNumber); + uint256 proposedNumber = l2OutputOracle.latestBlockNumber(); + + uint256 submissionInterval = cfg.l2OutputOracleSubmissionInterval(); + // Ensure the submissionInterval is enforced + assertEq(nextBlockNumber, proposedNumber + submissionInterval); + + vm.roll(nextBlockNumber + 1); + + vm.expectEmit(true, true, true, true); + emit OutputProposed(proposedOutput2, nextOutputIndex, nextBlockNumber, block.timestamp); + + address proposer = cfg.l2OutputOracleProposer(); + vm.prank(proposer); + l2OutputOracle.proposeL2Output(proposedOutput2, nextBlockNumber, 0, 0); + } +} diff --git a/packages/contracts-bedrock/test/setup/Events.sol b/packages/contracts-bedrock/test/setup/Events.sol new file mode 100644 index 0000000000000..a9d6d62979c93 --- /dev/null +++ b/packages/contracts-bedrock/test/setup/Events.sol @@ -0,0 +1,97 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.0; + +import { FeeVault } from "src/universal/FeeVault.sol"; + +/// @title Events +/// @dev Contains various events that are tested against. This contract needs to +/// exist until we either modularize the implementations or use a newer version of +/// solc that allows for referencing events from other contracts. +contract Events { + /// @dev OpenZeppelin Ownable.sol transferOwnership event + event OwnershipTransferred(address indexed previousOwner, address indexed newOwner); + event TransactionDeposited(address indexed from, address indexed to, uint256 indexed version, bytes opaqueData); + + event WithdrawalFinalized(bytes32 indexed withdrawalHash, bool success); + event WithdrawalProven(bytes32 indexed withdrawalHash, address indexed from, address indexed to); + + event SentMessage(address indexed target, address sender, bytes message, uint256 messageNonce, uint256 gasLimit); + event SentMessageExtension1(address indexed sender, uint256 value); + event MessagePassed( + uint256 indexed nonce, + address indexed sender, + address indexed target, + uint256 value, + uint256 gasLimit, + bytes data, + bytes32 withdrawalHash + ); + event WithdrawerBalanceBurnt(uint256 indexed amount); + event RelayedMessage(bytes32 indexed msgHash); + event FailedRelayedMessage(bytes32 indexed msgHash); + event TransactionDeposited( + address indexed from, + address indexed to, + uint256 mint, + uint256 value, + uint64 gasLimit, + bool isCreation, + bytes data + ); + event WhatHappened(bool success, bytes returndata); + + event OutputProposed( + bytes32 indexed outputRoot, uint256 indexed l2OutputIndex, uint256 indexed l2BlockNumber, uint256 l1Timestamp + ); + + event OutputsDeleted(uint256 indexed prevNextOutputIndex, uint256 indexed newNextOutputIndex); + + event Withdrawal(uint256 value, address to, address from); + event Withdrawal(uint256 value, address to, address from, FeeVault.WithdrawalNetwork withdrawalNetwork); + + event ETHDepositInitiated(address indexed from, address indexed to, uint256 amount, bytes data); + + event ETHWithdrawalFinalized(address indexed from, address indexed to, uint256 amount, bytes data); + + event ERC20DepositInitiated( + address indexed l1Token, address indexed l2Token, address indexed from, address to, uint256 amount, bytes data + ); + + event ERC20WithdrawalFinalized( + address indexed l1Token, address indexed l2Token, address indexed from, address to, uint256 amount, bytes data + ); + + event WithdrawalInitiated( + address indexed l1Token, address indexed l2Token, address indexed from, address to, uint256 amount, bytes data + ); + + event DepositFinalized( + address indexed l1Token, address indexed l2Token, address indexed from, address to, uint256 amount, bytes data + ); + + event DepositFailed( + address indexed l1Token, address indexed l2Token, address indexed from, address to, uint256 amount, bytes data + ); + + event ETHBridgeInitiated(address indexed from, address indexed to, uint256 amount, bytes data); + + event ETHBridgeFinalized(address indexed from, address indexed to, uint256 amount, bytes data); + + event ERC20BridgeInitiated( + address indexed localToken, + address indexed remoteToken, + address indexed from, + address to, + uint256 amount, + bytes data + ); + + event ERC20BridgeFinalized( + address indexed localToken, + address indexed remoteToken, + address indexed from, + address to, + uint256 amount, + bytes data + ); +} diff --git a/packages/contracts-bedrock/test/setup/FFIInterface.sol b/packages/contracts-bedrock/test/setup/FFIInterface.sol new file mode 100644 index 0000000000000..93727a035d73f --- /dev/null +++ b/packages/contracts-bedrock/test/setup/FFIInterface.sol @@ -0,0 +1,243 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.0; + +import { Types } from "src/libraries/Types.sol"; +import { Vm } from "forge-std/Vm.sol"; +import { Strings } from "@openzeppelin/contracts/utils/Strings.sol"; + +/// @title FFIInterface +contract FFIInterface { + Vm internal constant vm = Vm(0x7109709ECfa91a80626fF3989D68f67F5b1DD12D); + + function getProveWithdrawalTransactionInputs(Types.WithdrawalTransaction memory _tx) + external + returns (bytes32, bytes32, bytes32, bytes32, bytes[] memory) + { + string[] memory cmds = new string[](9); + cmds[0] = "scripts/go-ffi/go-ffi"; + cmds[1] = "diff"; + cmds[2] = "getProveWithdrawalTransactionInputs"; + cmds[3] = vm.toString(_tx.nonce); + cmds[4] = vm.toString(_tx.sender); + cmds[5] = vm.toString(_tx.target); + cmds[6] = vm.toString(_tx.value); + cmds[7] = vm.toString(_tx.gasLimit); + cmds[8] = vm.toString(_tx.data); + + bytes memory result = vm.ffi(cmds); + ( + bytes32 stateRoot, + bytes32 storageRoot, + bytes32 outputRoot, + bytes32 withdrawalHash, + bytes[] memory withdrawalProof + ) = abi.decode(result, (bytes32, bytes32, bytes32, bytes32, bytes[])); + + return (stateRoot, storageRoot, outputRoot, withdrawalHash, withdrawalProof); + } + + function hashCrossDomainMessage( + uint256 _nonce, + address _sender, + address _target, + uint256 _value, + uint256 _gasLimit, + bytes memory _data + ) + external + returns (bytes32) + { + string[] memory cmds = new string[](9); + cmds[0] = "scripts/go-ffi/go-ffi"; + cmds[1] = "diff"; + cmds[2] = "hashCrossDomainMessage"; + cmds[3] = vm.toString(_nonce); + cmds[4] = vm.toString(_sender); + cmds[5] = vm.toString(_target); + cmds[6] = vm.toString(_value); + cmds[7] = vm.toString(_gasLimit); + cmds[8] = vm.toString(_data); + + bytes memory result = vm.ffi(cmds); + return abi.decode(result, (bytes32)); + } + + function hashWithdrawal( + uint256 _nonce, + address _sender, + address _target, + uint256 _value, + uint256 _gasLimit, + bytes memory _data + ) + external + returns (bytes32) + { + string[] memory cmds = new string[](9); + cmds[0] = "scripts/go-ffi/go-ffi"; + cmds[1] = "diff"; + cmds[2] = "hashWithdrawal"; + cmds[3] = vm.toString(_nonce); + cmds[4] = vm.toString(_sender); + cmds[5] = vm.toString(_target); + cmds[6] = vm.toString(_value); + cmds[7] = vm.toString(_gasLimit); + cmds[8] = vm.toString(_data); + + bytes memory result = vm.ffi(cmds); + return abi.decode(result, (bytes32)); + } + + function hashOutputRootProof( + bytes32 _version, + bytes32 _stateRoot, + bytes32 _messagePasserStorageRoot, + bytes32 _latestBlockhash + ) + external + returns (bytes32) + { + string[] memory cmds = new string[](7); + cmds[0] = "scripts/go-ffi/go-ffi"; + cmds[1] = "diff"; + cmds[2] = "hashOutputRootProof"; + cmds[3] = Strings.toHexString(uint256(_version)); + cmds[4] = Strings.toHexString(uint256(_stateRoot)); + cmds[5] = Strings.toHexString(uint256(_messagePasserStorageRoot)); + cmds[6] = Strings.toHexString(uint256(_latestBlockhash)); + + bytes memory result = vm.ffi(cmds); + return abi.decode(result, (bytes32)); + } + + function hashDepositTransaction( + address _from, + address _to, + uint256 _mint, + uint256 _value, + uint64 _gas, + bytes memory _data, + uint64 _logIndex + ) + external + returns (bytes32) + { + string[] memory cmds = new string[](11); + cmds[0] = "scripts/go-ffi/go-ffi"; + cmds[1] = "diff"; + cmds[2] = "hashDepositTransaction"; + cmds[3] = "0x0000000000000000000000000000000000000000000000000000000000000000"; + cmds[4] = vm.toString(_logIndex); + cmds[5] = vm.toString(_from); + cmds[6] = vm.toString(_to); + cmds[7] = vm.toString(_mint); + cmds[8] = vm.toString(_value); + cmds[9] = vm.toString(_gas); + cmds[10] = vm.toString(_data); + + bytes memory result = vm.ffi(cmds); + return abi.decode(result, (bytes32)); + } + + function encodeDepositTransaction(Types.UserDepositTransaction calldata txn) external returns (bytes memory) { + string[] memory cmds = new string[](12); + cmds[0] = "scripts/go-ffi/go-ffi"; + cmds[1] = "diff"; + cmds[2] = "encodeDepositTransaction"; + cmds[3] = vm.toString(txn.from); + cmds[4] = vm.toString(txn.to); + cmds[5] = vm.toString(txn.value); + cmds[6] = vm.toString(txn.mint); + cmds[7] = vm.toString(txn.gasLimit); + cmds[8] = vm.toString(txn.isCreation); + cmds[9] = vm.toString(txn.data); + cmds[10] = vm.toString(txn.l1BlockHash); + cmds[11] = vm.toString(txn.logIndex); + + bytes memory result = vm.ffi(cmds); + return abi.decode(result, (bytes)); + } + + function encodeCrossDomainMessage( + uint256 _nonce, + address _sender, + address _target, + uint256 _value, + uint256 _gasLimit, + bytes memory _data + ) + external + returns (bytes memory) + { + string[] memory cmds = new string[](9); + cmds[0] = "scripts/go-ffi/go-ffi"; + cmds[1] = "diff"; + cmds[2] = "encodeCrossDomainMessage"; + cmds[3] = vm.toString(_nonce); + cmds[4] = vm.toString(_sender); + cmds[5] = vm.toString(_target); + cmds[6] = vm.toString(_value); + cmds[7] = vm.toString(_gasLimit); + cmds[8] = vm.toString(_data); + + bytes memory result = vm.ffi(cmds); + return abi.decode(result, (bytes)); + } + + function decodeVersionedNonce(uint256 nonce) external returns (uint256, uint256) { + string[] memory cmds = new string[](4); + cmds[0] = "scripts/go-ffi/go-ffi"; + cmds[1] = "diff"; + cmds[2] = "decodeVersionedNonce"; + cmds[3] = vm.toString(nonce); + + bytes memory result = vm.ffi(cmds); + return abi.decode(result, (uint256, uint256)); + } + + function getMerkleTrieFuzzCase(string memory variant) + external + returns (bytes32, bytes memory, bytes memory, bytes[] memory) + { + string[] memory cmds = new string[](6); + cmds[0] = "./scripts/go-ffi/go-ffi"; + cmds[1] = "trie"; + cmds[2] = variant; + + return abi.decode(vm.ffi(cmds), (bytes32, bytes, bytes, bytes[])); + } + + function getCannonMemoryProof(uint32 pc, uint32 insn) external returns (bytes32, bytes memory) { + string[] memory cmds = new string[](5); + cmds[0] = "scripts/go-ffi/go-ffi"; + cmds[1] = "diff"; + cmds[2] = "cannonMemoryProof"; + cmds[3] = vm.toString(pc); + cmds[4] = vm.toString(insn); + bytes memory result = vm.ffi(cmds); + (bytes32 memRoot, bytes memory proof) = abi.decode(result, (bytes32, bytes)); + return (memRoot, proof); + } + + function getCannonMemoryProof( + uint32 pc, + uint32 insn, + uint32 memAddr, + uint32 memVal + ) + external + returns (bytes32, bytes memory) + { + string[] memory cmds = new string[](7); + cmds[0] = "scripts/go-ffi/go-ffi"; + cmds[1] = "diff"; + cmds[2] = "cannonMemoryProof"; + cmds[3] = vm.toString(pc); + cmds[4] = vm.toString(insn); + cmds[5] = vm.toString(memAddr); + cmds[6] = vm.toString(memVal); + bytes memory result = vm.ffi(cmds); + (bytes32 memRoot, bytes memory proof) = abi.decode(result, (bytes32, bytes)); + return (memRoot, proof); + } +} diff --git a/packages/contracts-bedrock/test/setup/Setup.sol b/packages/contracts-bedrock/test/setup/Setup.sol new file mode 100644 index 0000000000000..2e4dae080c639 --- /dev/null +++ b/packages/contracts-bedrock/test/setup/Setup.sol @@ -0,0 +1,189 @@ +// SPDX-License-Identifier: MIT +pragma solidity 0.8.15; + +import { Predeploys } from "src/libraries/Predeploys.sol"; +import { L2CrossDomainMessenger } from "src/L2/L2CrossDomainMessenger.sol"; +import { L2StandardBridge } from "src/L2/L2StandardBridge.sol"; +import { L2ToL1MessagePasser } from "src/L2/L2ToL1MessagePasser.sol"; +import { L2ERC721Bridge } from "src/L2/L2ERC721Bridge.sol"; +import { BaseFeeVault } from "src/L2/BaseFeeVault.sol"; +import { SequencerFeeVault } from "src/L2/SequencerFeeVault.sol"; +import { L1FeeVault } from "src/L2/L1FeeVault.sol"; +import { GasPriceOracle } from "src/L2/GasPriceOracle.sol"; +import { L1Block } from "src/L2/L1Block.sol"; +import { LegacyMessagePasser } from "src/legacy/LegacyMessagePasser.sol"; +import { GovernanceToken } from "src/governance/GovernanceToken.sol"; +import { OptimismMintableERC20Factory } from "src/universal/OptimismMintableERC20Factory.sol"; +import { LegacyERC20ETH } from "src/legacy/LegacyERC20ETH.sol"; +import { StandardBridge } from "src/universal/StandardBridge.sol"; +import { FeeVault } from "src/universal/FeeVault.sol"; +import { OptimismPortal } from "src/L1/OptimismPortal.sol"; +import { L1CrossDomainMessenger } from "src/L1/L1CrossDomainMessenger.sol"; +import { DeployConfig } from "scripts/DeployConfig.s.sol"; +import { Deploy } from "scripts/Deploy.s.sol"; +import { L2OutputOracle } from "src/L1/L2OutputOracle.sol"; +import { ProtocolVersions } from "src/L1/ProtocolVersions.sol"; +import { SystemConfig } from "src/L1/SystemConfig.sol"; +import { L1StandardBridge } from "src/L1/L1StandardBridge.sol"; +import { AddressManager } from "src/legacy/AddressManager.sol"; +import { L1ERC721Bridge } from "src/L1/L1ERC721Bridge.sol"; +import { AddressAliasHelper } from "src/vendor/AddressAliasHelper.sol"; + +/// @title Setup +/// @dev This contact is responsible for setting up the contracts in state. It currently +/// sets the L2 contracts directly at the predeploy addresses instead of setting them +/// up behind proxies. In the future we will migrate to importing the genesis JSON +/// file that is created to set up the L2 contracts instead of setting them up manually. +contract Setup is Deploy { + OptimismPortal optimismPortal; + L2OutputOracle l2OutputOracle; + SystemConfig systemConfig; + L1StandardBridge l1StandardBridge; + L1CrossDomainMessenger l1CrossDomainMessenger; + AddressManager addressManager; + L1ERC721Bridge l1ERC721Bridge; + OptimismMintableERC20Factory l1OptimismMintableERC20Factory; + ProtocolVersions protocolVersions; + + L2CrossDomainMessenger l2CrossDomainMessenger = + L2CrossDomainMessenger(payable(Predeploys.L2_CROSS_DOMAIN_MESSENGER)); + L2StandardBridge l2StandardBridge = L2StandardBridge(payable(Predeploys.L2_STANDARD_BRIDGE)); + L2ToL1MessagePasser l2ToL1MessagePasser = L2ToL1MessagePasser(payable(Predeploys.L2_TO_L1_MESSAGE_PASSER)); + OptimismMintableERC20Factory l2OptimismMintableERC20Factory = + OptimismMintableERC20Factory(Predeploys.OPTIMISM_MINTABLE_ERC20_FACTORY); + L2ERC721Bridge l2ERC721Bridge = L2ERC721Bridge(Predeploys.L2_ERC721_BRIDGE); + BaseFeeVault baseFeeVault = BaseFeeVault(payable(Predeploys.BASE_FEE_VAULT)); + SequencerFeeVault sequencerFeeVault = SequencerFeeVault(payable(Predeploys.SEQUENCER_FEE_WALLET)); + L1FeeVault l1FeeVault = L1FeeVault(payable(Predeploys.L1_FEE_VAULT)); + GasPriceOracle gasPriceOracle = GasPriceOracle(Predeploys.GAS_PRICE_ORACLE); + L1Block l1Block = L1Block(Predeploys.L1_BLOCK_ATTRIBUTES); + LegacyMessagePasser legacyMessagePasser = LegacyMessagePasser(Predeploys.LEGACY_MESSAGE_PASSER); + GovernanceToken governanceToken = GovernanceToken(Predeploys.GOVERNANCE_TOKEN); + LegacyERC20ETH legacyERC20ETH = LegacyERC20ETH(Predeploys.LEGACY_ERC20_ETH); + + function setUp() public virtual override { + Deploy.setUp(); + } + + /// @dev Sets up the L1 contracts. + function L1() public { + // Set the deterministic deployer in state to ensure that it is there + vm.etch( + 0x4e59b44847b379578588920cA78FbF26c0B4956C, + hex"7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe03601600081602082378035828234f58015156039578182fd5b8082525050506014600cf3" + ); + + Deploy.run(); + + optimismPortal = OptimismPortal(mustGetAddress("OptimismPortalProxy")); + l2OutputOracle = L2OutputOracle(mustGetAddress("L2OutputOracleProxy")); + systemConfig = SystemConfig(mustGetAddress("SystemConfigProxy")); + l1StandardBridge = L1StandardBridge(mustGetAddress("L1StandardBridgeProxy")); + l1CrossDomainMessenger = L1CrossDomainMessenger(mustGetAddress("L1CrossDomainMessengerProxy")); + addressManager = AddressManager(mustGetAddress("AddressManager")); + l1ERC721Bridge = L1ERC721Bridge(mustGetAddress("L1ERC721BridgeProxy")); + l1OptimismMintableERC20Factory = + OptimismMintableERC20Factory(mustGetAddress("OptimismMintableERC20FactoryProxy")); + protocolVersions = ProtocolVersions(mustGetAddress("ProtocolVersionsProxy")); + + vm.label(address(l2OutputOracle), "L2OutputOracle"); + vm.label(mustGetAddress("L2OutputOracleProxy"), "L2OutputOracleProxy"); + vm.label(address(optimismPortal), "OptimismPortal"); + vm.label(mustGetAddress("OptimismPortalProxy"), "OptimismPortalProxy"); + vm.label(address(systemConfig), "SystemConfig"); + vm.label(mustGetAddress("SystemConfigProxy"), "SystemConfigProxy"); + vm.label(address(l1StandardBridge), "L1StandardBridge"); + vm.label(mustGetAddress("L1StandardBridgeProxy"), "L1StandardBridgeProxy"); + vm.label(address(l1CrossDomainMessenger), "L1CrossDomainMessenger"); + vm.label(mustGetAddress("L1CrossDomainMessengerProxy"), "L1CrossDomainMessengerProxy"); + vm.label(address(addressManager), "AddressManager"); + vm.label(address(l1ERC721Bridge), "L1ERC721Bridge"); + vm.label(mustGetAddress("L1ERC721BridgeProxy"), "L1ERC721BridgeProxy"); + vm.label(address(l1OptimismMintableERC20Factory), "OptimismMintableERC20Factory"); + vm.label(mustGetAddress("OptimismMintableERC20FactoryProxy"), "OptimismMintableERC20FactoryProxy"); + vm.label(address(protocolVersions), "ProtocolVersions"); + vm.label(mustGetAddress("ProtocolVersionsProxy"), "ProtocolVersionsProxy"); + vm.label(AddressAliasHelper.applyL1ToL2Alias(address(l1CrossDomainMessenger)), "L1CrossDomainMessenger_aliased"); + } + + /// @dev Sets up the L2 contracts. Depends on `L1()` being called first. + function L2(DeployConfig cfg) public { + // Set up L2. There are currently no proxies set in the L2 initialization. + vm.etch( + address(l2CrossDomainMessenger), address(new L2CrossDomainMessenger(address(l1CrossDomainMessenger))).code + ); + l2CrossDomainMessenger.initialize(); + + vm.etch(address(l2ToL1MessagePasser), address(new L2ToL1MessagePasser()).code); + + vm.etch( + address(l2StandardBridge), address(new L2StandardBridge(StandardBridge(payable(l1StandardBridge)))).code + ); + l2StandardBridge.initialize(); + + vm.etch(address(l2OptimismMintableERC20Factory), address(new OptimismMintableERC20Factory()).code); + l2OptimismMintableERC20Factory.initialize(address(l2StandardBridge)); + + vm.etch(address(legacyERC20ETH), address(new LegacyERC20ETH()).code); + + vm.etch(address(l2ERC721Bridge), address(new L2ERC721Bridge(address(l1ERC721Bridge))).code); + l2ERC721Bridge.initialize(); + + vm.etch( + address(sequencerFeeVault), + address( + new SequencerFeeVault(cfg.sequencerFeeVaultRecipient(), cfg.sequencerFeeVaultMinimumWithdrawalAmount(), FeeVault.WithdrawalNetwork.L2) + ).code + ); + vm.etch( + address(baseFeeVault), + address( + new BaseFeeVault(cfg.baseFeeVaultRecipient(), cfg.baseFeeVaultMinimumWithdrawalAmount(), FeeVault.WithdrawalNetwork.L1) + ).code + ); + vm.etch( + address(l1FeeVault), + address( + new L1FeeVault(cfg.l1FeeVaultRecipient(), cfg.l1FeeVaultMinimumWithdrawalAmount(), FeeVault.WithdrawalNetwork.L2) + ).code + ); + + vm.etch(address(l1Block), address(new L1Block()).code); + + vm.etch(address(gasPriceOracle), address(new GasPriceOracle()).code); + + vm.etch(address(legacyMessagePasser), address(new LegacyMessagePasser()).code); + + vm.etch(address(governanceToken), address(new GovernanceToken()).code); + // Set the ERC20 token name and symbol + vm.store( + address(governanceToken), + bytes32(uint256(3)), + bytes32(0x4f7074696d69736d000000000000000000000000000000000000000000000010) + ); + vm.store( + address(governanceToken), + bytes32(uint256(4)), + bytes32(0x4f50000000000000000000000000000000000000000000000000000000000004) + ); + + // Set the governance token's owner to be the final system owner + address finalSystemOwner = cfg.finalSystemOwner(); + vm.prank(governanceToken.owner()); + governanceToken.transferOwnership(finalSystemOwner); + + vm.label(Predeploys.OPTIMISM_MINTABLE_ERC20_FACTORY, "OptimismMintableERC20Factory"); + vm.label(Predeploys.LEGACY_ERC20_ETH, "LegacyERC20ETH"); + vm.label(Predeploys.L2_STANDARD_BRIDGE, "L2StandardBridge"); + vm.label(Predeploys.L2_CROSS_DOMAIN_MESSENGER, "L2CrossDomainMessenger"); + vm.label(Predeploys.L2_TO_L1_MESSAGE_PASSER, "L2ToL1MessagePasser"); + vm.label(Predeploys.SEQUENCER_FEE_WALLET, "SequencerFeeVault"); + vm.label(Predeploys.L2_ERC721_BRIDGE, "L2ERC721Bridge"); + vm.label(Predeploys.BASE_FEE_VAULT, "BaseFeeVault"); + vm.label(Predeploys.L1_FEE_VAULT, "L1FeeVault"); + vm.label(Predeploys.L1_BLOCK_ATTRIBUTES, "L1Block"); + vm.label(Predeploys.GAS_PRICE_ORACLE, "GasPriceOracle"); + vm.label(Predeploys.LEGACY_MESSAGE_PASSER, "LegacyMessagePasser"); + vm.label(Predeploys.GOVERNANCE_TOKEN, "GovernanceToken"); + } +} diff --git a/packages/contracts-ts/CHANGELOG.md b/packages/contracts-ts/CHANGELOG.md index caaf50c21e1c4..4e99d863c3f41 100644 --- a/packages/contracts-ts/CHANGELOG.md +++ b/packages/contracts-ts/CHANGELOG.md @@ -1,5 +1,11 @@ # @eth-optimism/contracts-ts +## 0.17.0 + +### Minor Changes + +- [#7644](https://github.com/ethereum-optimism/optimism/pull/7644) [`86bdaa075`](https://github.com/ethereum-optimism/optimism/commit/86bdaa075f424974531ce98ac9e21037e43db1bb) Thanks [@roninjin10](https://github.com/roninjin10)! - Removed unused hooks and actions + ## 0.16.2 ### Patch Changes diff --git a/packages/contracts-ts/abis.json b/packages/contracts-ts/abis.json index 0834fc94ac9e9..2c4576bf815ca 100644 --- a/packages/contracts-ts/abis.json +++ b/packages/contracts-ts/abis.json @@ -4132,13 +4132,7 @@ { "stateMutability": "nonpayable", "type": "constructor", - "inputs": [ - { - "name": "_portal", - "internalType": "contract OptimismPortal", - "type": "address" - } - ] + "inputs": [] }, { "type": "event", @@ -4411,7 +4405,13 @@ { "stateMutability": "nonpayable", "type": "function", - "inputs": [], + "inputs": [ + { + "name": "_portal", + "internalType": "contract OptimismPortal", + "type": "address" + } + ], "name": "initialize", "outputs": [] }, @@ -4428,6 +4428,19 @@ } ] }, + { + "stateMutability": "view", + "type": "function", + "inputs": [], + "name": "portal", + "outputs": [ + { + "name": "", + "internalType": "address", + "type": "address" + } + ] + }, { "stateMutability": "payable", "type": "function", @@ -4535,7 +4548,7 @@ ] } ], - "L1CrossDomainMessenger_goerli": [ + "L1ERC721Bridge": [ { "stateMutability": "nonpayable", "type": "constructor", @@ -4546,106 +4559,110 @@ "anonymous": false, "inputs": [ { - "name": "msgHash", - "internalType": "bytes32", - "type": "bytes32", + "name": "localToken", + "internalType": "address", + "type": "address", "indexed": true - } - ], - "name": "FailedRelayedMessage" - }, - { - "type": "event", - "anonymous": false, - "inputs": [ + }, { - "name": "version", - "internalType": "uint8", - "type": "uint8", + "name": "remoteToken", + "internalType": "address", + "type": "address", + "indexed": true + }, + { + "name": "from", + "internalType": "address", + "type": "address", + "indexed": true + }, + { + "name": "to", + "internalType": "address", + "type": "address", + "indexed": false + }, + { + "name": "tokenId", + "internalType": "uint256", + "type": "uint256", + "indexed": false + }, + { + "name": "extraData", + "internalType": "bytes", + "type": "bytes", "indexed": false } ], - "name": "Initialized" + "name": "ERC721BridgeFinalized" }, { "type": "event", "anonymous": false, "inputs": [ { - "name": "msgHash", - "internalType": "bytes32", - "type": "bytes32", + "name": "localToken", + "internalType": "address", + "type": "address", "indexed": true - } - ], - "name": "RelayedMessage" - }, - { - "type": "event", - "anonymous": false, - "inputs": [ + }, { - "name": "target", + "name": "remoteToken", "internalType": "address", "type": "address", "indexed": true }, { - "name": "sender", + "name": "from", "internalType": "address", "type": "address", - "indexed": false + "indexed": true }, { - "name": "message", - "internalType": "bytes", - "type": "bytes", + "name": "to", + "internalType": "address", + "type": "address", "indexed": false }, { - "name": "messageNonce", + "name": "tokenId", "internalType": "uint256", "type": "uint256", "indexed": false }, { - "name": "gasLimit", - "internalType": "uint256", - "type": "uint256", + "name": "extraData", + "internalType": "bytes", + "type": "bytes", "indexed": false } ], - "name": "SentMessage" + "name": "ERC721BridgeInitiated" }, { "type": "event", "anonymous": false, "inputs": [ { - "name": "sender", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "value", - "internalType": "uint256", - "type": "uint256", + "name": "version", + "internalType": "uint8", + "type": "uint8", "indexed": false } ], - "name": "SentMessageExtension1" + "name": "Initialized" }, { "stateMutability": "view", "type": "function", "inputs": [], - "name": "MESSAGE_VERSION", + "name": "MESSENGER", "outputs": [ { "name": "", - "internalType": "uint16", - "type": "uint16" + "internalType": "contract CrossDomainMessenger", + "type": "address" } ] }, @@ -4653,169 +4670,160 @@ "stateMutability": "view", "type": "function", "inputs": [], - "name": "MIN_GAS_CALLDATA_OVERHEAD", + "name": "OTHER_BRIDGE", "outputs": [ { "name": "", - "internalType": "uint64", - "type": "uint64" + "internalType": "address", + "type": "address" } ] }, { - "stateMutability": "view", + "stateMutability": "nonpayable", "type": "function", - "inputs": [], - "name": "MIN_GAS_DYNAMIC_OVERHEAD_DENOMINATOR", - "outputs": [ + "inputs": [ { - "name": "", - "internalType": "uint64", - "type": "uint64" + "name": "_localToken", + "internalType": "address", + "type": "address" + }, + { + "name": "_remoteToken", + "internalType": "address", + "type": "address" + }, + { + "name": "_tokenId", + "internalType": "uint256", + "type": "uint256" + }, + { + "name": "_minGasLimit", + "internalType": "uint32", + "type": "uint32" + }, + { + "name": "_extraData", + "internalType": "bytes", + "type": "bytes" } - ] + ], + "name": "bridgeERC721", + "outputs": [] }, { - "stateMutability": "view", + "stateMutability": "nonpayable", "type": "function", - "inputs": [], - "name": "MIN_GAS_DYNAMIC_OVERHEAD_NUMERATOR", - "outputs": [ + "inputs": [ { - "name": "", - "internalType": "uint64", - "type": "uint64" + "name": "_localToken", + "internalType": "address", + "type": "address" + }, + { + "name": "_remoteToken", + "internalType": "address", + "type": "address" + }, + { + "name": "_to", + "internalType": "address", + "type": "address" + }, + { + "name": "_tokenId", + "internalType": "uint256", + "type": "uint256" + }, + { + "name": "_minGasLimit", + "internalType": "uint32", + "type": "uint32" + }, + { + "name": "_extraData", + "internalType": "bytes", + "type": "bytes" } - ] + ], + "name": "bridgeERC721To", + "outputs": [] }, { "stateMutability": "view", "type": "function", - "inputs": [], - "name": "OTHER_MESSENGER", - "outputs": [ + "inputs": [ { "name": "", "internalType": "address", "type": "address" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "PORTAL", - "outputs": [ + }, { "name": "", - "internalType": "contract OptimismPortal", + "internalType": "address", "type": "address" + }, + { + "name": "", + "internalType": "uint256", + "type": "uint256" } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "RELAY_CALL_OVERHEAD", + ], + "name": "deposits", "outputs": [ { "name": "", - "internalType": "uint64", - "type": "uint64" + "internalType": "bool", + "type": "bool" } ] }, { - "stateMutability": "view", + "stateMutability": "nonpayable", "type": "function", - "inputs": [], - "name": "RELAY_CONSTANT_OVERHEAD", - "outputs": [ - { - "name": "", - "internalType": "uint64", - "type": "uint64" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "RELAY_GAS_CHECK_BUFFER", - "outputs": [ + "inputs": [ { - "name": "", - "internalType": "uint64", - "type": "uint64" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "RELAY_RESERVED_GAS", - "outputs": [ + "name": "_localToken", + "internalType": "address", + "type": "address" + }, { - "name": "", - "internalType": "uint64", - "type": "uint64" - } - ] - }, - { - "stateMutability": "pure", - "type": "function", - "inputs": [ + "name": "_remoteToken", + "internalType": "address", + "type": "address" + }, { - "name": "_message", - "internalType": "bytes", - "type": "bytes" + "name": "_from", + "internalType": "address", + "type": "address" }, { - "name": "_minGasLimit", - "internalType": "uint32", - "type": "uint32" - } - ], - "name": "baseGas", - "outputs": [ + "name": "_to", + "internalType": "address", + "type": "address" + }, { - "name": "", - "internalType": "uint64", - "type": "uint64" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [ + "name": "_tokenId", + "internalType": "uint256", + "type": "uint256" + }, { - "name": "", - "internalType": "bytes32", - "type": "bytes32" + "name": "_extraData", + "internalType": "bytes", + "type": "bytes" } ], - "name": "failedMessages", - "outputs": [ - { - "name": "", - "internalType": "bool", - "type": "bool" - } - ] + "name": "finalizeBridgeERC721", + "outputs": [] }, { "stateMutability": "nonpayable", "type": "function", "inputs": [ { - "name": "_portal", - "internalType": "contract OptimismPortal", + "name": "_messenger", + "internalType": "contract CrossDomainMessenger", "type": "address" } ], @@ -4826,12 +4834,12 @@ "stateMutability": "view", "type": "function", "inputs": [], - "name": "messageNonce", + "name": "messenger", "outputs": [ { "name": "", - "internalType": "uint256", - "type": "uint256" + "internalType": "contract CrossDomainMessenger", + "type": "address" } ] }, @@ -4839,7 +4847,7 @@ "stateMutability": "view", "type": "function", "inputs": [], - "name": "portal", + "name": "otherBridge", "outputs": [ { "name": "", @@ -4849,82 +4857,79 @@ ] }, { - "stateMutability": "payable", + "stateMutability": "view", "type": "function", - "inputs": [ - { - "name": "_nonce", - "internalType": "uint256", - "type": "uint256" - }, + "inputs": [], + "name": "version", + "outputs": [ { - "name": "_sender", - "internalType": "address", - "type": "address" - }, + "name": "", + "internalType": "string", + "type": "string" + } + ] + } + ], + "L1FeeVault": [ + { + "stateMutability": "nonpayable", + "type": "constructor", + "inputs": [ { - "name": "_target", + "name": "_recipient", "internalType": "address", "type": "address" - }, - { - "name": "_value", - "internalType": "uint256", - "type": "uint256" - }, - { - "name": "_minGasLimit", - "internalType": "uint256", - "type": "uint256" - }, - { - "name": "_message", - "internalType": "bytes", - "type": "bytes" } - ], - "name": "relayMessage", - "outputs": [] + ] }, { - "stateMutability": "payable", - "type": "function", + "type": "event", + "anonymous": false, "inputs": [ { - "name": "_target", - "internalType": "address", - "type": "address" + "name": "value", + "internalType": "uint256", + "type": "uint256", + "indexed": false }, { - "name": "_message", - "internalType": "bytes", - "type": "bytes" + "name": "to", + "internalType": "address", + "type": "address", + "indexed": false }, { - "name": "_minGasLimit", - "internalType": "uint32", - "type": "uint32" + "name": "from", + "internalType": "address", + "type": "address", + "indexed": false } ], - "name": "sendMessage", - "outputs": [] + "name": "Withdrawal" }, { "stateMutability": "view", "type": "function", - "inputs": [ + "inputs": [], + "name": "MIN_WITHDRAWAL_AMOUNT", + "outputs": [ { "name": "", - "internalType": "bytes32", - "type": "bytes32" + "internalType": "uint256", + "type": "uint256" } - ], - "name": "successfulMessages", + ] + }, + { + "stateMutability": "view", + "type": "function", + "inputs": [], + "name": "RECIPIENT", "outputs": [ { "name": "", - "internalType": "bool", - "type": "bool" + "internalType": "address", + "type": "address" } ] }, @@ -4932,12 +4937,12 @@ "stateMutability": "view", "type": "function", "inputs": [], - "name": "version", + "name": "totalProcessed", "outputs": [ { "name": "", - "internalType": "string", - "type": "string" + "internalType": "uint256", + "type": "uint256" } ] }, @@ -4945,32 +4950,32 @@ "stateMutability": "view", "type": "function", "inputs": [], - "name": "xDomainMessageSender", + "name": "version", "outputs": [ { "name": "", - "internalType": "address", - "type": "address" + "internalType": "string", + "type": "string" } ] + }, + { + "stateMutability": "nonpayable", + "type": "function", + "inputs": [], + "name": "withdraw", + "outputs": [] + }, + { + "stateMutability": "payable", + "type": "receive" } ], - "L1ERC721Bridge": [ + "L1StandardBridge": [ { "stateMutability": "nonpayable", "type": "constructor", - "inputs": [ - { - "name": "_messenger", - "internalType": "address", - "type": "address" - }, - { - "name": "_otherBridge", - "internalType": "address", - "type": "address" - } - ] + "inputs": [] }, { "type": "event", @@ -5001,7 +5006,7 @@ "indexed": false }, { - "name": "tokenId", + "name": "amount", "internalType": "uint256", "type": "uint256", "indexed": false @@ -5013,7 +5018,7 @@ "indexed": false } ], - "name": "ERC721BridgeFinalized" + "name": "ERC20BridgeFinalized" }, { "type": "event", @@ -5044,7 +5049,7 @@ "indexed": false }, { - "name": "tokenId", + "name": "amount", "internalType": "uint256", "type": "uint256", "indexed": false @@ -5056,234 +5061,160 @@ "indexed": false } ], - "name": "ERC721BridgeInitiated" + "name": "ERC20BridgeInitiated" }, { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "MESSENGER", - "outputs": [ + "type": "event", + "anonymous": false, + "inputs": [ { - "name": "", - "internalType": "contract CrossDomainMessenger", - "type": "address" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "OTHER_BRIDGE", - "outputs": [ - { - "name": "", + "name": "l1Token", "internalType": "address", - "type": "address" - } - ] - }, - { - "stateMutability": "nonpayable", - "type": "function", - "inputs": [ + "type": "address", + "indexed": true + }, { - "name": "_localToken", + "name": "l2Token", "internalType": "address", - "type": "address" + "type": "address", + "indexed": true }, { - "name": "_remoteToken", + "name": "from", "internalType": "address", - "type": "address" + "type": "address", + "indexed": true }, { - "name": "_tokenId", - "internalType": "uint256", - "type": "uint256" + "name": "to", + "internalType": "address", + "type": "address", + "indexed": false }, { - "name": "_minGasLimit", - "internalType": "uint32", - "type": "uint32" + "name": "amount", + "internalType": "uint256", + "type": "uint256", + "indexed": false }, { - "name": "_extraData", + "name": "extraData", "internalType": "bytes", - "type": "bytes" + "type": "bytes", + "indexed": false } ], - "name": "bridgeERC721", - "outputs": [] + "name": "ERC20DepositInitiated" }, { - "stateMutability": "nonpayable", - "type": "function", + "type": "event", + "anonymous": false, "inputs": [ { - "name": "_localToken", + "name": "l1Token", "internalType": "address", - "type": "address" + "type": "address", + "indexed": true }, { - "name": "_remoteToken", + "name": "l2Token", "internalType": "address", - "type": "address" + "type": "address", + "indexed": true }, { - "name": "_to", + "name": "from", "internalType": "address", - "type": "address" + "type": "address", + "indexed": true }, { - "name": "_tokenId", - "internalType": "uint256", - "type": "uint256" + "name": "to", + "internalType": "address", + "type": "address", + "indexed": false }, { - "name": "_minGasLimit", - "internalType": "uint32", - "type": "uint32" + "name": "amount", + "internalType": "uint256", + "type": "uint256", + "indexed": false }, { - "name": "_extraData", + "name": "extraData", "internalType": "bytes", - "type": "bytes" + "type": "bytes", + "indexed": false } ], - "name": "bridgeERC721To", - "outputs": [] + "name": "ERC20WithdrawalFinalized" }, { - "stateMutability": "view", - "type": "function", + "type": "event", + "anonymous": false, "inputs": [ { - "name": "", + "name": "from", "internalType": "address", - "type": "address" + "type": "address", + "indexed": true }, { - "name": "", + "name": "to", "internalType": "address", - "type": "address" + "type": "address", + "indexed": true }, { - "name": "", + "name": "amount", "internalType": "uint256", - "type": "uint256" - } - ], - "name": "deposits", - "outputs": [ + "type": "uint256", + "indexed": false + }, { - "name": "", - "internalType": "bool", - "type": "bool" + "name": "extraData", + "internalType": "bytes", + "type": "bytes", + "indexed": false } - ] + ], + "name": "ETHBridgeFinalized" }, { - "stateMutability": "nonpayable", - "type": "function", + "type": "event", + "anonymous": false, "inputs": [ { - "name": "_localToken", - "internalType": "address", - "type": "address" - }, - { - "name": "_remoteToken", - "internalType": "address", - "type": "address" - }, - { - "name": "_from", + "name": "from", "internalType": "address", - "type": "address" + "type": "address", + "indexed": true }, { - "name": "_to", + "name": "to", "internalType": "address", - "type": "address" + "type": "address", + "indexed": true }, { - "name": "_tokenId", + "name": "amount", "internalType": "uint256", - "type": "uint256" + "type": "uint256", + "indexed": false }, { - "name": "_extraData", + "name": "extraData", "internalType": "bytes", - "type": "bytes" + "type": "bytes", + "indexed": false } ], - "name": "finalizeBridgeERC721", - "outputs": [] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "messenger", - "outputs": [ - { - "name": "", - "internalType": "contract CrossDomainMessenger", - "type": "address" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "otherBridge", - "outputs": [ - { - "name": "", - "internalType": "address", - "type": "address" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "version", - "outputs": [ - { - "name": "", - "internalType": "string", - "type": "string" - } - ] - } - ], - "L1ERC721Bridge_goerli": [ - { - "stateMutability": "nonpayable", - "type": "constructor", - "inputs": [] + "name": "ETHBridgeInitiated" }, { "type": "event", "anonymous": false, "inputs": [ - { - "name": "localToken", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "remoteToken", - "internalType": "address", - "type": "address", - "indexed": true - }, { "name": "from", "internalType": "address", @@ -5294,10 +5225,10 @@ "name": "to", "internalType": "address", "type": "address", - "indexed": false + "indexed": true }, { - "name": "tokenId", + "name": "amount", "internalType": "uint256", "type": "uint256", "indexed": false @@ -5309,24 +5240,12 @@ "indexed": false } ], - "name": "ERC721BridgeFinalized" + "name": "ETHDepositInitiated" }, { "type": "event", "anonymous": false, "inputs": [ - { - "name": "localToken", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "remoteToken", - "internalType": "address", - "type": "address", - "indexed": true - }, { "name": "from", "internalType": "address", @@ -5337,10 +5256,10 @@ "name": "to", "internalType": "address", "type": "address", - "indexed": false + "indexed": true }, { - "name": "tokenId", + "name": "amount", "internalType": "uint256", "type": "uint256", "indexed": false @@ -5352,7 +5271,7 @@ "indexed": false } ], - "name": "ERC721BridgeInitiated" + "name": "ETHWithdrawalFinalized" }, { "type": "event", @@ -5388,7 +5307,7 @@ "outputs": [ { "name": "", - "internalType": "address", + "internalType": "contract StandardBridge", "type": "address" } ] @@ -5408,7 +5327,7 @@ "type": "address" }, { - "name": "_tokenId", + "name": "_amount", "internalType": "uint256", "type": "uint256" }, @@ -5423,7 +5342,7 @@ "type": "bytes" } ], - "name": "bridgeERC721", + "name": "bridgeERC20", "outputs": [] }, { @@ -5446,7 +5365,7 @@ "type": "address" }, { - "name": "_tokenId", + "name": "_amount", "internalType": "uint256", "type": "uint256" }, @@ -5461,54 +5380,94 @@ "type": "bytes" } ], - "name": "bridgeERC721To", + "name": "bridgeERC20To", "outputs": [] }, { - "stateMutability": "view", + "stateMutability": "payable", "type": "function", "inputs": [ { - "name": "", - "internalType": "address", - "type": "address" + "name": "_minGasLimit", + "internalType": "uint32", + "type": "uint32" }, { - "name": "", + "name": "_extraData", + "internalType": "bytes", + "type": "bytes" + } + ], + "name": "bridgeETH", + "outputs": [] + }, + { + "stateMutability": "payable", + "type": "function", + "inputs": [ + { + "name": "_to", "internalType": "address", "type": "address" }, { - "name": "", - "internalType": "uint256", - "type": "uint256" - } - ], - "name": "deposits", - "outputs": [ + "name": "_minGasLimit", + "internalType": "uint32", + "type": "uint32" + }, { - "name": "", - "internalType": "bool", - "type": "bool" + "name": "_extraData", + "internalType": "bytes", + "type": "bytes" } - ] + ], + "name": "bridgeETHTo", + "outputs": [] }, { "stateMutability": "nonpayable", "type": "function", "inputs": [ { - "name": "_localToken", + "name": "_l1Token", "internalType": "address", "type": "address" }, { - "name": "_remoteToken", + "name": "_l2Token", "internalType": "address", "type": "address" }, { - "name": "_from", + "name": "_amount", + "internalType": "uint256", + "type": "uint256" + }, + { + "name": "_minGasLimit", + "internalType": "uint32", + "type": "uint32" + }, + { + "name": "_extraData", + "internalType": "bytes", + "type": "bytes" + } + ], + "name": "depositERC20", + "outputs": [] + }, + { + "stateMutability": "nonpayable", + "type": "function", + "inputs": [ + { + "name": "_l1Token", + "internalType": "address", + "type": "address" + }, + { + "name": "_l2Token", "internalType": "address", "type": "address" }, @@ -5518,490 +5477,574 @@ "type": "address" }, { - "name": "_tokenId", + "name": "_amount", "internalType": "uint256", "type": "uint256" }, + { + "name": "_minGasLimit", + "internalType": "uint32", + "type": "uint32" + }, { "name": "_extraData", "internalType": "bytes", "type": "bytes" } ], - "name": "finalizeBridgeERC721", + "name": "depositERC20To", "outputs": [] }, { - "stateMutability": "nonpayable", + "stateMutability": "payable", "type": "function", "inputs": [ { - "name": "_messenger", - "internalType": "contract CrossDomainMessenger", - "type": "address" + "name": "_minGasLimit", + "internalType": "uint32", + "type": "uint32" + }, + { + "name": "_extraData", + "internalType": "bytes", + "type": "bytes" } ], - "name": "initialize", + "name": "depositETH", "outputs": [] }, { - "stateMutability": "view", + "stateMutability": "payable", "type": "function", - "inputs": [], - "name": "messenger", - "outputs": [ + "inputs": [ { - "name": "", - "internalType": "contract CrossDomainMessenger", + "name": "_to", + "internalType": "address", "type": "address" + }, + { + "name": "_minGasLimit", + "internalType": "uint32", + "type": "uint32" + }, + { + "name": "_extraData", + "internalType": "bytes", + "type": "bytes" } - ] + ], + "name": "depositETHTo", + "outputs": [] }, { "stateMutability": "view", "type": "function", - "inputs": [], - "name": "otherBridge", - "outputs": [ + "inputs": [ + { + "name": "", + "internalType": "address", + "type": "address" + }, { "name": "", "internalType": "address", "type": "address" } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "version", + ], + "name": "deposits", "outputs": [ { "name": "", - "internalType": "string", - "type": "string" + "internalType": "uint256", + "type": "uint256" } ] - } - ], - "L1FeeVault": [ + }, { "stateMutability": "nonpayable", - "type": "constructor", + "type": "function", "inputs": [ { - "name": "_recipient", + "name": "_localToken", "internalType": "address", "type": "address" - } - ] - }, - { - "type": "event", - "anonymous": false, - "inputs": [ + }, { - "name": "value", - "internalType": "uint256", - "type": "uint256", - "indexed": false + "name": "_remoteToken", + "internalType": "address", + "type": "address" }, { - "name": "to", + "name": "_from", "internalType": "address", - "type": "address", - "indexed": false + "type": "address" }, { - "name": "from", + "name": "_to", "internalType": "address", - "type": "address", - "indexed": false - } - ], - "name": "Withdrawal" - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "MIN_WITHDRAWAL_AMOUNT", - "outputs": [ + "type": "address" + }, { - "name": "", + "name": "_amount", "internalType": "uint256", "type": "uint256" + }, + { + "name": "_extraData", + "internalType": "bytes", + "type": "bytes" } - ] + ], + "name": "finalizeBridgeERC20", + "outputs": [] }, { - "stateMutability": "view", + "stateMutability": "payable", "type": "function", - "inputs": [], - "name": "RECIPIENT", - "outputs": [ + "inputs": [ { - "name": "", + "name": "_from", "internalType": "address", "type": "address" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "totalProcessed", - "outputs": [ + }, { - "name": "", + "name": "_to", + "internalType": "address", + "type": "address" + }, + { + "name": "_amount", "internalType": "uint256", "type": "uint256" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "version", - "outputs": [ + }, { - "name": "", - "internalType": "string", - "type": "string" + "name": "_extraData", + "internalType": "bytes", + "type": "bytes" } - ] + ], + "name": "finalizeBridgeETH", + "outputs": [] }, { "stateMutability": "nonpayable", "type": "function", - "inputs": [], - "name": "withdraw", - "outputs": [] - }, - { - "stateMutability": "payable", - "type": "receive" - } - ], - "L1StandardBridge": [ - { - "stateMutability": "nonpayable", - "type": "constructor", - "inputs": [ - { - "name": "_messenger", - "internalType": "address payable", - "type": "address" - } - ] - }, - { - "type": "event", - "anonymous": false, "inputs": [ { - "name": "localToken", + "name": "_l1Token", "internalType": "address", - "type": "address", - "indexed": true + "type": "address" }, { - "name": "remoteToken", + "name": "_l2Token", "internalType": "address", - "type": "address", - "indexed": true + "type": "address" }, { - "name": "from", + "name": "_from", "internalType": "address", - "type": "address", - "indexed": true + "type": "address" }, { - "name": "to", + "name": "_to", "internalType": "address", - "type": "address", - "indexed": false + "type": "address" }, { - "name": "amount", + "name": "_amount", "internalType": "uint256", - "type": "uint256", - "indexed": false + "type": "uint256" }, { - "name": "extraData", + "name": "_extraData", "internalType": "bytes", - "type": "bytes", - "indexed": false + "type": "bytes" } ], - "name": "ERC20BridgeFinalized" + "name": "finalizeERC20Withdrawal", + "outputs": [] }, { - "type": "event", - "anonymous": false, + "stateMutability": "payable", + "type": "function", "inputs": [ { - "name": "localToken", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "remoteToken", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "from", + "name": "_from", "internalType": "address", - "type": "address", - "indexed": true + "type": "address" }, { - "name": "to", + "name": "_to", "internalType": "address", - "type": "address", - "indexed": false + "type": "address" }, { - "name": "amount", + "name": "_amount", "internalType": "uint256", - "type": "uint256", - "indexed": false + "type": "uint256" }, { - "name": "extraData", + "name": "_extraData", "internalType": "bytes", - "type": "bytes", - "indexed": false + "type": "bytes" } ], - "name": "ERC20BridgeInitiated" + "name": "finalizeETHWithdrawal", + "outputs": [] }, { - "type": "event", - "anonymous": false, + "stateMutability": "nonpayable", + "type": "function", "inputs": [ { - "name": "l1Token", - "internalType": "address", - "type": "address", - "indexed": true - }, + "name": "_messenger", + "internalType": "contract CrossDomainMessenger", + "type": "address" + } + ], + "name": "initialize", + "outputs": [] + }, + { + "stateMutability": "view", + "type": "function", + "inputs": [], + "name": "l2TokenBridge", + "outputs": [ { - "name": "l2Token", + "name": "", "internalType": "address", - "type": "address", - "indexed": true - }, + "type": "address" + } + ] + }, + { + "stateMutability": "view", + "type": "function", + "inputs": [], + "name": "messenger", + "outputs": [ { - "name": "from", - "internalType": "address", - "type": "address", - "indexed": true - }, + "name": "", + "internalType": "contract CrossDomainMessenger", + "type": "address" + } + ] + }, + { + "stateMutability": "view", + "type": "function", + "inputs": [], + "name": "otherBridge", + "outputs": [ { - "name": "to", + "name": "", + "internalType": "contract StandardBridge", + "type": "address" + } + ] + }, + { + "stateMutability": "view", + "type": "function", + "inputs": [], + "name": "version", + "outputs": [ + { + "name": "", + "internalType": "string", + "type": "string" + } + ] + }, + { + "stateMutability": "payable", + "type": "receive" + } + ], + "L2CrossDomainMessenger": [ + { + "stateMutability": "nonpayable", + "type": "constructor", + "inputs": [ + { + "name": "_l1CrossDomainMessenger", "internalType": "address", - "type": "address", - "indexed": false - }, + "type": "address" + } + ] + }, + { + "type": "event", + "anonymous": false, + "inputs": [ { - "name": "amount", - "internalType": "uint256", - "type": "uint256", - "indexed": false - }, + "name": "msgHash", + "internalType": "bytes32", + "type": "bytes32", + "indexed": true + } + ], + "name": "FailedRelayedMessage" + }, + { + "type": "event", + "anonymous": false, + "inputs": [ { - "name": "extraData", - "internalType": "bytes", - "type": "bytes", + "name": "version", + "internalType": "uint8", + "type": "uint8", "indexed": false } ], - "name": "ERC20DepositInitiated" + "name": "Initialized" }, { "type": "event", "anonymous": false, "inputs": [ { - "name": "l1Token", - "internalType": "address", - "type": "address", + "name": "msgHash", + "internalType": "bytes32", + "type": "bytes32", "indexed": true - }, + } + ], + "name": "RelayedMessage" + }, + { + "type": "event", + "anonymous": false, + "inputs": [ { - "name": "l2Token", + "name": "target", "internalType": "address", "type": "address", "indexed": true }, { - "name": "from", + "name": "sender", "internalType": "address", "type": "address", - "indexed": true + "indexed": false }, { - "name": "to", - "internalType": "address", - "type": "address", + "name": "message", + "internalType": "bytes", + "type": "bytes", "indexed": false }, { - "name": "amount", + "name": "messageNonce", "internalType": "uint256", "type": "uint256", "indexed": false }, { - "name": "extraData", - "internalType": "bytes", - "type": "bytes", + "name": "gasLimit", + "internalType": "uint256", + "type": "uint256", "indexed": false } ], - "name": "ERC20WithdrawalFinalized" + "name": "SentMessage" }, { "type": "event", "anonymous": false, "inputs": [ { - "name": "from", + "name": "sender", "internalType": "address", "type": "address", "indexed": true }, { - "name": "to", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "amount", + "name": "value", "internalType": "uint256", "type": "uint256", "indexed": false - }, - { - "name": "extraData", - "internalType": "bytes", - "type": "bytes", - "indexed": false } ], - "name": "ETHBridgeFinalized" + "name": "SentMessageExtension1" }, { - "type": "event", - "anonymous": false, - "inputs": [ + "stateMutability": "view", + "type": "function", + "inputs": [], + "name": "MESSAGE_VERSION", + "outputs": [ { - "name": "from", - "internalType": "address", - "type": "address", - "indexed": true - }, + "name": "", + "internalType": "uint16", + "type": "uint16" + } + ] + }, + { + "stateMutability": "view", + "type": "function", + "inputs": [], + "name": "MIN_GAS_CALLDATA_OVERHEAD", + "outputs": [ { - "name": "to", - "internalType": "address", - "type": "address", - "indexed": true - }, + "name": "", + "internalType": "uint64", + "type": "uint64" + } + ] + }, + { + "stateMutability": "view", + "type": "function", + "inputs": [], + "name": "MIN_GAS_DYNAMIC_OVERHEAD_DENOMINATOR", + "outputs": [ { - "name": "amount", - "internalType": "uint256", - "type": "uint256", - "indexed": false - }, + "name": "", + "internalType": "uint64", + "type": "uint64" + } + ] + }, + { + "stateMutability": "view", + "type": "function", + "inputs": [], + "name": "MIN_GAS_DYNAMIC_OVERHEAD_NUMERATOR", + "outputs": [ { - "name": "extraData", - "internalType": "bytes", - "type": "bytes", - "indexed": false + "name": "", + "internalType": "uint64", + "type": "uint64" } - ], - "name": "ETHBridgeInitiated" + ] }, { - "type": "event", - "anonymous": false, - "inputs": [ + "stateMutability": "view", + "type": "function", + "inputs": [], + "name": "OTHER_MESSENGER", + "outputs": [ { - "name": "from", + "name": "", "internalType": "address", - "type": "address", - "indexed": true - }, + "type": "address" + } + ] + }, + { + "stateMutability": "view", + "type": "function", + "inputs": [], + "name": "RELAY_CALL_OVERHEAD", + "outputs": [ { - "name": "to", - "internalType": "address", - "type": "address", - "indexed": true - }, + "name": "", + "internalType": "uint64", + "type": "uint64" + } + ] + }, + { + "stateMutability": "view", + "type": "function", + "inputs": [], + "name": "RELAY_CONSTANT_OVERHEAD", + "outputs": [ { - "name": "amount", - "internalType": "uint256", - "type": "uint256", - "indexed": false - }, + "name": "", + "internalType": "uint64", + "type": "uint64" + } + ] + }, + { + "stateMutability": "view", + "type": "function", + "inputs": [], + "name": "RELAY_GAS_CHECK_BUFFER", + "outputs": [ { - "name": "extraData", - "internalType": "bytes", - "type": "bytes", - "indexed": false + "name": "", + "internalType": "uint64", + "type": "uint64" } - ], - "name": "ETHDepositInitiated" + ] }, { - "type": "event", - "anonymous": false, + "stateMutability": "view", + "type": "function", + "inputs": [], + "name": "RELAY_RESERVED_GAS", + "outputs": [ + { + "name": "", + "internalType": "uint64", + "type": "uint64" + } + ] + }, + { + "stateMutability": "pure", + "type": "function", "inputs": [ { - "name": "from", - "internalType": "address", - "type": "address", - "indexed": true + "name": "_message", + "internalType": "bytes", + "type": "bytes" }, { - "name": "to", - "internalType": "address", - "type": "address", - "indexed": true - }, + "name": "_minGasLimit", + "internalType": "uint32", + "type": "uint32" + } + ], + "name": "baseGas", + "outputs": [ { - "name": "amount", - "internalType": "uint256", - "type": "uint256", - "indexed": false - }, + "name": "", + "internalType": "uint64", + "type": "uint64" + } + ] + }, + { + "stateMutability": "view", + "type": "function", + "inputs": [ { - "name": "extraData", - "internalType": "bytes", - "type": "bytes", - "indexed": false + "name": "", + "internalType": "bytes32", + "type": "bytes32" } ], - "name": "ETHWithdrawalFinalized" + "name": "failedMessages", + "outputs": [ + { + "name": "", + "internalType": "bool", + "type": "bool" + } + ] + }, + { + "stateMutability": "nonpayable", + "type": "function", + "inputs": [], + "name": "initialize", + "outputs": [] }, { "stateMutability": "view", "type": "function", "inputs": [], - "name": "MESSENGER", + "name": "l1CrossDomainMessenger", "outputs": [ { "name": "", - "internalType": "contract CrossDomainMessenger", + "internalType": "address", "type": "address" } ] @@ -6010,225 +6053,244 @@ "stateMutability": "view", "type": "function", "inputs": [], - "name": "OTHER_BRIDGE", + "name": "messageNonce", "outputs": [ { "name": "", - "internalType": "contract StandardBridge", - "type": "address" + "internalType": "uint256", + "type": "uint256" } ] }, { - "stateMutability": "nonpayable", + "stateMutability": "payable", "type": "function", "inputs": [ { - "name": "_localToken", + "name": "_nonce", + "internalType": "uint256", + "type": "uint256" + }, + { + "name": "_sender", "internalType": "address", "type": "address" }, { - "name": "_remoteToken", + "name": "_target", "internalType": "address", "type": "address" }, { - "name": "_amount", + "name": "_value", "internalType": "uint256", "type": "uint256" }, { "name": "_minGasLimit", - "internalType": "uint32", - "type": "uint32" + "internalType": "uint256", + "type": "uint256" }, { - "name": "_extraData", + "name": "_message", "internalType": "bytes", "type": "bytes" } ], - "name": "bridgeERC20", + "name": "relayMessage", "outputs": [] }, { - "stateMutability": "nonpayable", + "stateMutability": "payable", "type": "function", "inputs": [ { - "name": "_localToken", - "internalType": "address", - "type": "address" - }, - { - "name": "_remoteToken", - "internalType": "address", - "type": "address" - }, - { - "name": "_to", + "name": "_target", "internalType": "address", "type": "address" }, { - "name": "_amount", - "internalType": "uint256", - "type": "uint256" + "name": "_message", + "internalType": "bytes", + "type": "bytes" }, { "name": "_minGasLimit", "internalType": "uint32", "type": "uint32" - }, - { - "name": "_extraData", - "internalType": "bytes", - "type": "bytes" } ], - "name": "bridgeERC20To", + "name": "sendMessage", "outputs": [] }, { - "stateMutability": "payable", + "stateMutability": "view", "type": "function", "inputs": [ { - "name": "_minGasLimit", - "internalType": "uint32", - "type": "uint32" - }, - { - "name": "_extraData", - "internalType": "bytes", - "type": "bytes" + "name": "", + "internalType": "bytes32", + "type": "bytes32" } ], - "name": "bridgeETH", - "outputs": [] + "name": "successfulMessages", + "outputs": [ + { + "name": "", + "internalType": "bool", + "type": "bool" + } + ] }, { - "stateMutability": "payable", + "stateMutability": "view", "type": "function", - "inputs": [ + "inputs": [], + "name": "version", + "outputs": [ { - "name": "_to", + "name": "", + "internalType": "string", + "type": "string" + } + ] + }, + { + "stateMutability": "view", + "type": "function", + "inputs": [], + "name": "xDomainMessageSender", + "outputs": [ + { + "name": "", "internalType": "address", "type": "address" - }, + } + ] + } + ], + "L2ERC721Bridge": [ + { + "stateMutability": "nonpayable", + "type": "constructor", + "inputs": [ { - "name": "_minGasLimit", - "internalType": "uint32", - "type": "uint32" + "name": "_messenger", + "internalType": "address", + "type": "address" }, { - "name": "_extraData", - "internalType": "bytes", - "type": "bytes" + "name": "_otherBridge", + "internalType": "address", + "type": "address" } - ], - "name": "bridgeETHTo", - "outputs": [] + ] }, { - "stateMutability": "nonpayable", - "type": "function", + "type": "event", + "anonymous": false, "inputs": [ { - "name": "_l1Token", + "name": "localToken", "internalType": "address", - "type": "address" + "type": "address", + "indexed": true }, { - "name": "_l2Token", + "name": "remoteToken", "internalType": "address", - "type": "address" + "type": "address", + "indexed": true }, { - "name": "_amount", - "internalType": "uint256", - "type": "uint256" + "name": "from", + "internalType": "address", + "type": "address", + "indexed": true }, { - "name": "_minGasLimit", - "internalType": "uint32", - "type": "uint32" + "name": "to", + "internalType": "address", + "type": "address", + "indexed": false }, { - "name": "_extraData", + "name": "tokenId", + "internalType": "uint256", + "type": "uint256", + "indexed": false + }, + { + "name": "extraData", "internalType": "bytes", - "type": "bytes" + "type": "bytes", + "indexed": false } ], - "name": "depositERC20", - "outputs": [] + "name": "ERC721BridgeFinalized" }, { - "stateMutability": "nonpayable", - "type": "function", + "type": "event", + "anonymous": false, "inputs": [ { - "name": "_l1Token", + "name": "localToken", "internalType": "address", - "type": "address" + "type": "address", + "indexed": true }, { - "name": "_l2Token", + "name": "remoteToken", "internalType": "address", - "type": "address" + "type": "address", + "indexed": true }, { - "name": "_to", + "name": "from", "internalType": "address", - "type": "address" + "type": "address", + "indexed": true }, { - "name": "_amount", - "internalType": "uint256", - "type": "uint256" + "name": "to", + "internalType": "address", + "type": "address", + "indexed": false }, { - "name": "_minGasLimit", - "internalType": "uint32", - "type": "uint32" + "name": "tokenId", + "internalType": "uint256", + "type": "uint256", + "indexed": false }, { - "name": "_extraData", + "name": "extraData", "internalType": "bytes", - "type": "bytes" + "type": "bytes", + "indexed": false } ], - "name": "depositERC20To", - "outputs": [] + "name": "ERC721BridgeInitiated" }, { - "stateMutability": "payable", + "stateMutability": "nonpayable", "type": "function", "inputs": [ { - "name": "_minGasLimit", - "internalType": "uint32", - "type": "uint32" + "name": "_localToken", + "internalType": "address", + "type": "address" }, { - "name": "_extraData", - "internalType": "bytes", - "type": "bytes" - } - ], - "name": "depositETH", - "outputs": [] - }, - { - "stateMutability": "payable", - "type": "function", - "inputs": [ - { - "name": "_to", + "name": "_remoteToken", "internalType": "address", "type": "address" }, + { + "name": "_tokenId", + "internalType": "uint256", + "type": "uint256" + }, { "name": "_minGasLimit", "internalType": "uint32", @@ -6240,32 +6302,46 @@ "type": "bytes" } ], - "name": "depositETHTo", + "name": "bridgeERC721", "outputs": [] }, { - "stateMutability": "view", + "stateMutability": "nonpayable", "type": "function", "inputs": [ { - "name": "", + "name": "_localToken", "internalType": "address", "type": "address" }, { - "name": "", + "name": "_remoteToken", "internalType": "address", "type": "address" - } - ], - "name": "deposits", - "outputs": [ + }, { - "name": "", + "name": "_to", + "internalType": "address", + "type": "address" + }, + { + "name": "_tokenId", "internalType": "uint256", "type": "uint256" + }, + { + "name": "_minGasLimit", + "internalType": "uint32", + "type": "uint32" + }, + { + "name": "_extraData", + "internalType": "bytes", + "type": "bytes" } - ] + ], + "name": "bridgeERC721To", + "outputs": [] }, { "stateMutability": "nonpayable", @@ -6292,7 +6368,7 @@ "type": "address" }, { - "name": "_amount", + "name": "_tokenId", "internalType": "uint256", "type": "uint256" }, @@ -6302,112 +6378,18 @@ "type": "bytes" } ], - "name": "finalizeBridgeERC20", + "name": "finalizeBridgeERC721", "outputs": [] }, { - "stateMutability": "payable", + "stateMutability": "view", "type": "function", - "inputs": [ + "inputs": [], + "name": "messenger", + "outputs": [ { - "name": "_from", - "internalType": "address", - "type": "address" - }, - { - "name": "_to", - "internalType": "address", - "type": "address" - }, - { - "name": "_amount", - "internalType": "uint256", - "type": "uint256" - }, - { - "name": "_extraData", - "internalType": "bytes", - "type": "bytes" - } - ], - "name": "finalizeBridgeETH", - "outputs": [] - }, - { - "stateMutability": "nonpayable", - "type": "function", - "inputs": [ - { - "name": "_l1Token", - "internalType": "address", - "type": "address" - }, - { - "name": "_l2Token", - "internalType": "address", - "type": "address" - }, - { - "name": "_from", - "internalType": "address", - "type": "address" - }, - { - "name": "_to", - "internalType": "address", - "type": "address" - }, - { - "name": "_amount", - "internalType": "uint256", - "type": "uint256" - }, - { - "name": "_extraData", - "internalType": "bytes", - "type": "bytes" - } - ], - "name": "finalizeERC20Withdrawal", - "outputs": [] - }, - { - "stateMutability": "payable", - "type": "function", - "inputs": [ - { - "name": "_from", - "internalType": "address", - "type": "address" - }, - { - "name": "_to", - "internalType": "address", - "type": "address" - }, - { - "name": "_amount", - "internalType": "uint256", - "type": "uint256" - }, - { - "name": "_extraData", - "internalType": "bytes", - "type": "bytes" - } - ], - "name": "finalizeETHWithdrawal", - "outputs": [] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "l2TokenBridge", - "outputs": [ - { - "name": "", - "internalType": "address", + "name": "", + "internalType": "contract CrossDomainMessenger", "type": "address" } ] @@ -6416,11 +6398,11 @@ "stateMutability": "view", "type": "function", "inputs": [], - "name": "messenger", + "name": "otherBridge", "outputs": [ { "name": "", - "internalType": "contract CrossDomainMessenger", + "internalType": "address", "type": "address" } ] @@ -6437,17 +6419,24 @@ "type": "string" } ] - }, - { - "stateMutability": "payable", - "type": "receive" } ], - "L1StandardBridge_goerli": [ + "L2ERC721Bridge_optimism-goerli": [ { "stateMutability": "nonpayable", "type": "constructor", - "inputs": [] + "inputs": [ + { + "name": "_messenger", + "internalType": "address", + "type": "address" + }, + { + "name": "_otherBridge", + "internalType": "address", + "type": "address" + } + ] }, { "type": "event", @@ -6478,7 +6467,7 @@ "indexed": false }, { - "name": "amount", + "name": "tokenId", "internalType": "uint256", "type": "uint256", "indexed": false @@ -6490,7 +6479,7 @@ "indexed": false } ], - "name": "ERC20BridgeFinalized" + "name": "ERC721BridgeFinalized" }, { "type": "event", @@ -6521,7 +6510,7 @@ "indexed": false }, { - "name": "amount", + "name": "tokenId", "internalType": "uint256", "type": "uint256", "indexed": false @@ -6533,240 +6522,277 @@ "indexed": false } ], - "name": "ERC20BridgeInitiated" + "name": "ERC721BridgeInitiated" }, { - "type": "event", - "anonymous": false, - "inputs": [ + "stateMutability": "view", + "type": "function", + "inputs": [], + "name": "MESSENGER", + "outputs": [ { - "name": "l1Token", - "internalType": "address", - "type": "address", - "indexed": true - }, + "name": "", + "internalType": "contract CrossDomainMessenger", + "type": "address" + } + ] + }, + { + "stateMutability": "view", + "type": "function", + "inputs": [], + "name": "OTHER_BRIDGE", + "outputs": [ { - "name": "l2Token", + "name": "", "internalType": "address", - "type": "address", - "indexed": true - }, + "type": "address" + } + ] + }, + { + "stateMutability": "nonpayable", + "type": "function", + "inputs": [ { - "name": "from", + "name": "_localToken", "internalType": "address", - "type": "address", - "indexed": true + "type": "address" }, { - "name": "to", + "name": "_remoteToken", "internalType": "address", - "type": "address", - "indexed": false + "type": "address" }, { - "name": "amount", + "name": "_tokenId", "internalType": "uint256", - "type": "uint256", - "indexed": false + "type": "uint256" }, { - "name": "extraData", + "name": "_minGasLimit", + "internalType": "uint32", + "type": "uint32" + }, + { + "name": "_extraData", "internalType": "bytes", - "type": "bytes", - "indexed": false + "type": "bytes" } ], - "name": "ERC20DepositInitiated" + "name": "bridgeERC721", + "outputs": [] }, { - "type": "event", - "anonymous": false, + "stateMutability": "nonpayable", + "type": "function", "inputs": [ { - "name": "l1Token", + "name": "_localToken", "internalType": "address", - "type": "address", - "indexed": true + "type": "address" }, { - "name": "l2Token", + "name": "_remoteToken", "internalType": "address", - "type": "address", - "indexed": true + "type": "address" }, { - "name": "from", + "name": "_to", "internalType": "address", - "type": "address", - "indexed": true + "type": "address" }, { - "name": "to", - "internalType": "address", - "type": "address", - "indexed": false + "name": "_tokenId", + "internalType": "uint256", + "type": "uint256" }, { - "name": "amount", - "internalType": "uint256", - "type": "uint256", - "indexed": false + "name": "_minGasLimit", + "internalType": "uint32", + "type": "uint32" }, { - "name": "extraData", + "name": "_extraData", "internalType": "bytes", - "type": "bytes", - "indexed": false + "type": "bytes" } ], - "name": "ERC20WithdrawalFinalized" + "name": "bridgeERC721To", + "outputs": [] }, { - "type": "event", - "anonymous": false, + "stateMutability": "nonpayable", + "type": "function", "inputs": [ { - "name": "from", + "name": "_localToken", "internalType": "address", - "type": "address", - "indexed": true + "type": "address" }, { - "name": "to", + "name": "_remoteToken", "internalType": "address", - "type": "address", - "indexed": true + "type": "address" }, { - "name": "amount", - "internalType": "uint256", - "type": "uint256", - "indexed": false + "name": "_from", + "internalType": "address", + "type": "address" }, { - "name": "extraData", - "internalType": "bytes", - "type": "bytes", - "indexed": false - } - ], - "name": "ETHBridgeFinalized" - }, - { - "type": "event", - "anonymous": false, - "inputs": [ - { - "name": "from", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "to", + "name": "_to", "internalType": "address", - "type": "address", - "indexed": true + "type": "address" }, { - "name": "amount", + "name": "_tokenId", "internalType": "uint256", - "type": "uint256", - "indexed": false + "type": "uint256" }, { - "name": "extraData", + "name": "_extraData", "internalType": "bytes", - "type": "bytes", - "indexed": false + "type": "bytes" } ], - "name": "ETHBridgeInitiated" + "name": "finalizeBridgeERC721", + "outputs": [] }, { - "type": "event", - "anonymous": false, - "inputs": [ + "stateMutability": "view", + "type": "function", + "inputs": [], + "name": "messenger", + "outputs": [ { - "name": "from", - "internalType": "address", - "type": "address", - "indexed": true - }, + "name": "", + "internalType": "contract CrossDomainMessenger", + "type": "address" + } + ] + }, + { + "stateMutability": "view", + "type": "function", + "inputs": [], + "name": "otherBridge", + "outputs": [ { - "name": "to", + "name": "", "internalType": "address", - "type": "address", - "indexed": true + "type": "address" + } + ] + }, + { + "stateMutability": "view", + "type": "function", + "inputs": [], + "name": "version", + "outputs": [ + { + "name": "", + "internalType": "string", + "type": "string" + } + ] + } + ], + "L2OutputOracle": [ + { + "stateMutability": "nonpayable", + "type": "constructor", + "inputs": [ + { + "name": "_submissionInterval", + "internalType": "uint256", + "type": "uint256" }, { - "name": "amount", + "name": "_l2BlockTime", "internalType": "uint256", - "type": "uint256", - "indexed": false + "type": "uint256" }, { - "name": "extraData", - "internalType": "bytes", - "type": "bytes", + "name": "_finalizationPeriodSeconds", + "internalType": "uint256", + "type": "uint256" + } + ] + }, + { + "type": "event", + "anonymous": false, + "inputs": [ + { + "name": "version", + "internalType": "uint8", + "type": "uint8", "indexed": false } ], - "name": "ETHDepositInitiated" + "name": "Initialized" }, { "type": "event", "anonymous": false, "inputs": [ { - "name": "from", - "internalType": "address", - "type": "address", + "name": "outputRoot", + "internalType": "bytes32", + "type": "bytes32", "indexed": true }, { - "name": "to", - "internalType": "address", - "type": "address", + "name": "l2OutputIndex", + "internalType": "uint256", + "type": "uint256", "indexed": true }, { - "name": "amount", + "name": "l2BlockNumber", "internalType": "uint256", "type": "uint256", - "indexed": false + "indexed": true }, { - "name": "extraData", - "internalType": "bytes", - "type": "bytes", + "name": "l1Timestamp", + "internalType": "uint256", + "type": "uint256", "indexed": false } ], - "name": "ETHWithdrawalFinalized" + "name": "OutputProposed" }, { "type": "event", "anonymous": false, "inputs": [ { - "name": "version", - "internalType": "uint8", - "type": "uint8", - "indexed": false + "name": "prevNextOutputIndex", + "internalType": "uint256", + "type": "uint256", + "indexed": true + }, + { + "name": "newNextOutputIndex", + "internalType": "uint256", + "type": "uint256", + "indexed": true } ], - "name": "Initialized" + "name": "OutputsDeleted" }, { "stateMutability": "view", "type": "function", "inputs": [], - "name": "MESSENGER", + "name": "CHALLENGER", "outputs": [ { "name": "", - "internalType": "contract CrossDomainMessenger", + "internalType": "address", "type": "address" } ] @@ -6775,255 +6801,195 @@ "stateMutability": "view", "type": "function", "inputs": [], - "name": "OTHER_BRIDGE", + "name": "FINALIZATION_PERIOD_SECONDS", "outputs": [ { "name": "", - "internalType": "contract StandardBridge", - "type": "address" + "internalType": "uint256", + "type": "uint256" } ] }, { - "stateMutability": "nonpayable", + "stateMutability": "view", "type": "function", - "inputs": [ - { - "name": "_localToken", - "internalType": "address", - "type": "address" - }, - { - "name": "_remoteToken", - "internalType": "address", - "type": "address" - }, + "inputs": [], + "name": "L2_BLOCK_TIME", + "outputs": [ { - "name": "_amount", + "name": "", "internalType": "uint256", "type": "uint256" - }, - { - "name": "_minGasLimit", - "internalType": "uint32", - "type": "uint32" - }, - { - "name": "_extraData", - "internalType": "bytes", - "type": "bytes" } - ], - "name": "bridgeERC20", - "outputs": [] + ] }, { - "stateMutability": "nonpayable", + "stateMutability": "view", "type": "function", - "inputs": [ - { - "name": "_localToken", - "internalType": "address", - "type": "address" - }, - { - "name": "_remoteToken", - "internalType": "address", - "type": "address" - }, + "inputs": [], + "name": "PROPOSER", + "outputs": [ { - "name": "_to", + "name": "", "internalType": "address", "type": "address" - }, + } + ] + }, + { + "stateMutability": "view", + "type": "function", + "inputs": [], + "name": "SUBMISSION_INTERVAL", + "outputs": [ { - "name": "_amount", + "name": "", "internalType": "uint256", "type": "uint256" - }, - { - "name": "_minGasLimit", - "internalType": "uint32", - "type": "uint32" - }, + } + ] + }, + { + "stateMutability": "view", + "type": "function", + "inputs": [], + "name": "challenger", + "outputs": [ { - "name": "_extraData", - "internalType": "bytes", - "type": "bytes" + "name": "", + "internalType": "address", + "type": "address" } - ], - "name": "bridgeERC20To", - "outputs": [] + ] }, { - "stateMutability": "payable", + "stateMutability": "view", "type": "function", "inputs": [ { - "name": "_minGasLimit", - "internalType": "uint32", - "type": "uint32" - }, - { - "name": "_extraData", - "internalType": "bytes", - "type": "bytes" + "name": "_l2BlockNumber", + "internalType": "uint256", + "type": "uint256" } ], - "name": "bridgeETH", - "outputs": [] - }, - { - "stateMutability": "payable", - "type": "function", - "inputs": [ - { - "name": "_to", - "internalType": "address", - "type": "address" - }, - { - "name": "_minGasLimit", - "internalType": "uint32", - "type": "uint32" - }, + "name": "computeL2Timestamp", + "outputs": [ { - "name": "_extraData", - "internalType": "bytes", - "type": "bytes" + "name": "", + "internalType": "uint256", + "type": "uint256" } - ], - "name": "bridgeETHTo", - "outputs": [] + ] }, { "stateMutability": "nonpayable", "type": "function", "inputs": [ { - "name": "_l1Token", - "internalType": "address", - "type": "address" - }, - { - "name": "_l2Token", - "internalType": "address", - "type": "address" - }, - { - "name": "_amount", + "name": "_l2OutputIndex", "internalType": "uint256", "type": "uint256" - }, - { - "name": "_minGasLimit", - "internalType": "uint32", - "type": "uint32" - }, - { - "name": "_extraData", - "internalType": "bytes", - "type": "bytes" } ], - "name": "depositERC20", + "name": "deleteL2Outputs", "outputs": [] }, { - "stateMutability": "nonpayable", + "stateMutability": "view", "type": "function", - "inputs": [ - { - "name": "_l1Token", - "internalType": "address", - "type": "address" - }, - { - "name": "_l2Token", - "internalType": "address", - "type": "address" - }, - { - "name": "_to", - "internalType": "address", - "type": "address" - }, + "inputs": [], + "name": "finalizationPeriodSeconds", + "outputs": [ { - "name": "_amount", + "name": "", "internalType": "uint256", "type": "uint256" - }, - { - "name": "_minGasLimit", - "internalType": "uint32", - "type": "uint32" - }, - { - "name": "_extraData", - "internalType": "bytes", - "type": "bytes" } - ], - "name": "depositERC20To", - "outputs": [] + ] }, { - "stateMutability": "payable", + "stateMutability": "view", "type": "function", "inputs": [ { - "name": "_minGasLimit", - "internalType": "uint32", - "type": "uint32" - }, - { - "name": "_extraData", - "internalType": "bytes", - "type": "bytes" + "name": "_l2OutputIndex", + "internalType": "uint256", + "type": "uint256" } ], - "name": "depositETH", - "outputs": [] + "name": "getL2Output", + "outputs": [ + { + "name": "", + "internalType": "struct Types.OutputProposal", + "type": "tuple", + "components": [ + { + "name": "outputRoot", + "internalType": "bytes32", + "type": "bytes32" + }, + { + "name": "timestamp", + "internalType": "uint128", + "type": "uint128" + }, + { + "name": "l2BlockNumber", + "internalType": "uint128", + "type": "uint128" + } + ] + } + ] }, { - "stateMutability": "payable", + "stateMutability": "view", "type": "function", "inputs": [ { - "name": "_to", - "internalType": "address", - "type": "address" - }, - { - "name": "_minGasLimit", - "internalType": "uint32", - "type": "uint32" - }, - { - "name": "_extraData", - "internalType": "bytes", - "type": "bytes" + "name": "_l2BlockNumber", + "internalType": "uint256", + "type": "uint256" } ], - "name": "depositETHTo", - "outputs": [] + "name": "getL2OutputAfter", + "outputs": [ + { + "name": "", + "internalType": "struct Types.OutputProposal", + "type": "tuple", + "components": [ + { + "name": "outputRoot", + "internalType": "bytes32", + "type": "bytes32" + }, + { + "name": "timestamp", + "internalType": "uint128", + "type": "uint128" + }, + { + "name": "l2BlockNumber", + "internalType": "uint128", + "type": "uint128" + } + ] + } + ] }, { "stateMutability": "view", "type": "function", "inputs": [ { - "name": "", - "internalType": "address", - "type": "address" - }, - { - "name": "", - "internalType": "address", - "type": "address" + "name": "_l2BlockNumber", + "internalType": "uint256", + "type": "uint256" } ], - "name": "deposits", + "name": "getL2OutputIndexAfter", "outputs": [ { "name": "", @@ -7037,156 +7003,145 @@ "type": "function", "inputs": [ { - "name": "_localToken", - "internalType": "address", - "type": "address" + "name": "_startingBlockNumber", + "internalType": "uint256", + "type": "uint256" }, { - "name": "_remoteToken", - "internalType": "address", - "type": "address" + "name": "_startingTimestamp", + "internalType": "uint256", + "type": "uint256" }, { - "name": "_from", + "name": "_proposer", "internalType": "address", "type": "address" }, { - "name": "_to", + "name": "_challenger", "internalType": "address", "type": "address" - }, - { - "name": "_amount", - "internalType": "uint256", - "type": "uint256" - }, - { - "name": "_extraData", - "internalType": "bytes", - "type": "bytes" } ], - "name": "finalizeBridgeERC20", + "name": "initialize", "outputs": [] }, { - "stateMutability": "payable", + "stateMutability": "view", "type": "function", - "inputs": [ - { - "name": "_from", - "internalType": "address", - "type": "address" - }, - { - "name": "_to", - "internalType": "address", - "type": "address" - }, + "inputs": [], + "name": "l2BlockTime", + "outputs": [ { - "name": "_amount", + "name": "", "internalType": "uint256", "type": "uint256" - }, - { - "name": "_extraData", - "internalType": "bytes", - "type": "bytes" } - ], - "name": "finalizeBridgeETH", - "outputs": [] + ] }, { - "stateMutability": "nonpayable", + "stateMutability": "view", "type": "function", - "inputs": [ + "inputs": [], + "name": "latestBlockNumber", + "outputs": [ { - "name": "_l1Token", - "internalType": "address", - "type": "address" - }, - { - "name": "_l2Token", - "internalType": "address", - "type": "address" - }, - { - "name": "_from", - "internalType": "address", - "type": "address" - }, + "name": "", + "internalType": "uint256", + "type": "uint256" + } + ] + }, + { + "stateMutability": "view", + "type": "function", + "inputs": [], + "name": "latestOutputIndex", + "outputs": [ { - "name": "_to", - "internalType": "address", - "type": "address" - }, + "name": "", + "internalType": "uint256", + "type": "uint256" + } + ] + }, + { + "stateMutability": "view", + "type": "function", + "inputs": [], + "name": "nextBlockNumber", + "outputs": [ { - "name": "_amount", + "name": "", "internalType": "uint256", "type": "uint256" - }, + } + ] + }, + { + "stateMutability": "view", + "type": "function", + "inputs": [], + "name": "nextOutputIndex", + "outputs": [ { - "name": "_extraData", - "internalType": "bytes", - "type": "bytes" + "name": "", + "internalType": "uint256", + "type": "uint256" } - ], - "name": "finalizeERC20Withdrawal", - "outputs": [] + ] }, { "stateMutability": "payable", "type": "function", "inputs": [ { - "name": "_from", - "internalType": "address", - "type": "address" - }, - { - "name": "_to", - "internalType": "address", - "type": "address" + "name": "_outputRoot", + "internalType": "bytes32", + "type": "bytes32" }, { - "name": "_amount", + "name": "_l2BlockNumber", "internalType": "uint256", "type": "uint256" }, { - "name": "_extraData", - "internalType": "bytes", - "type": "bytes" + "name": "_l1BlockHash", + "internalType": "bytes32", + "type": "bytes32" + }, + { + "name": "_l1BlockNumber", + "internalType": "uint256", + "type": "uint256" } ], - "name": "finalizeETHWithdrawal", + "name": "proposeL2Output", "outputs": [] }, { - "stateMutability": "nonpayable", + "stateMutability": "view", "type": "function", - "inputs": [ + "inputs": [], + "name": "proposer", + "outputs": [ { - "name": "_messenger", - "internalType": "contract CrossDomainMessenger", + "name": "", + "internalType": "address", "type": "address" } - ], - "name": "initialize", - "outputs": [] + ] }, { "stateMutability": "view", "type": "function", "inputs": [], - "name": "l2TokenBridge", + "name": "startingBlockNumber", "outputs": [ { "name": "", - "internalType": "address", - "type": "address" + "internalType": "uint256", + "type": "uint256" } ] }, @@ -7194,12 +7149,12 @@ "stateMutability": "view", "type": "function", "inputs": [], - "name": "messenger", + "name": "startingTimestamp", "outputs": [ { "name": "", - "internalType": "contract CrossDomainMessenger", - "type": "address" + "internalType": "uint256", + "type": "uint256" } ] }, @@ -7207,12 +7162,12 @@ "stateMutability": "view", "type": "function", "inputs": [], - "name": "otherBridge", + "name": "submissionInterval", "outputs": [ { "name": "", - "internalType": "contract StandardBridge", - "type": "address" + "internalType": "uint256", + "type": "uint256" } ] }, @@ -7228,20 +7183,16 @@ "type": "string" } ] - }, - { - "stateMutability": "payable", - "type": "receive" } ], - "L2CrossDomainMessenger": [ + "L2StandardBridge": [ { "stateMutability": "nonpayable", "type": "constructor", "inputs": [ { - "name": "_l1CrossDomainMessenger", - "internalType": "address", + "name": "_otherBridge", + "internalType": "address payable", "type": "address" } ] @@ -7251,272 +7202,244 @@ "anonymous": false, "inputs": [ { - "name": "msgHash", - "internalType": "bytes32", - "type": "bytes32", + "name": "l1Token", + "internalType": "address", + "type": "address", "indexed": true - } - ], - "name": "FailedRelayedMessage" - }, - { - "type": "event", - "anonymous": false, - "inputs": [ + }, { - "name": "version", - "internalType": "uint8", - "type": "uint8", + "name": "l2Token", + "internalType": "address", + "type": "address", + "indexed": true + }, + { + "name": "from", + "internalType": "address", + "type": "address", + "indexed": true + }, + { + "name": "to", + "internalType": "address", + "type": "address", + "indexed": false + }, + { + "name": "amount", + "internalType": "uint256", + "type": "uint256", + "indexed": false + }, + { + "name": "extraData", + "internalType": "bytes", + "type": "bytes", "indexed": false } ], - "name": "Initialized" + "name": "DepositFinalized" }, { "type": "event", "anonymous": false, "inputs": [ { - "name": "msgHash", - "internalType": "bytes32", - "type": "bytes32", + "name": "localToken", + "internalType": "address", + "type": "address", + "indexed": true + }, + { + "name": "remoteToken", + "internalType": "address", + "type": "address", + "indexed": true + }, + { + "name": "from", + "internalType": "address", + "type": "address", "indexed": true + }, + { + "name": "to", + "internalType": "address", + "type": "address", + "indexed": false + }, + { + "name": "amount", + "internalType": "uint256", + "type": "uint256", + "indexed": false + }, + { + "name": "extraData", + "internalType": "bytes", + "type": "bytes", + "indexed": false } ], - "name": "RelayedMessage" + "name": "ERC20BridgeFinalized" }, { "type": "event", "anonymous": false, "inputs": [ { - "name": "target", + "name": "localToken", "internalType": "address", "type": "address", "indexed": true }, { - "name": "sender", + "name": "remoteToken", "internalType": "address", "type": "address", - "indexed": false + "indexed": true }, { - "name": "message", - "internalType": "bytes", - "type": "bytes", + "name": "from", + "internalType": "address", + "type": "address", + "indexed": true + }, + { + "name": "to", + "internalType": "address", + "type": "address", "indexed": false }, { - "name": "messageNonce", + "name": "amount", "internalType": "uint256", "type": "uint256", "indexed": false }, { - "name": "gasLimit", - "internalType": "uint256", - "type": "uint256", + "name": "extraData", + "internalType": "bytes", + "type": "bytes", "indexed": false } ], - "name": "SentMessage" + "name": "ERC20BridgeInitiated" }, { "type": "event", "anonymous": false, "inputs": [ { - "name": "sender", + "name": "from", "internalType": "address", "type": "address", "indexed": true }, { - "name": "value", + "name": "to", + "internalType": "address", + "type": "address", + "indexed": true + }, + { + "name": "amount", "internalType": "uint256", "type": "uint256", "indexed": false - } - ], - "name": "SentMessageExtension1" - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "MESSAGE_VERSION", - "outputs": [ - { - "name": "", - "internalType": "uint16", - "type": "uint16" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "MIN_GAS_CALLDATA_OVERHEAD", - "outputs": [ - { - "name": "", - "internalType": "uint64", - "type": "uint64" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "MIN_GAS_DYNAMIC_OVERHEAD_DENOMINATOR", - "outputs": [ + }, { - "name": "", - "internalType": "uint64", - "type": "uint64" + "name": "extraData", + "internalType": "bytes", + "type": "bytes", + "indexed": false } - ] + ], + "name": "ETHBridgeFinalized" }, { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "MIN_GAS_DYNAMIC_OVERHEAD_NUMERATOR", - "outputs": [ + "type": "event", + "anonymous": false, + "inputs": [ { - "name": "", - "internalType": "uint64", - "type": "uint64" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "OTHER_MESSENGER", - "outputs": [ + "name": "from", + "internalType": "address", + "type": "address", + "indexed": true + }, { - "name": "", + "name": "to", "internalType": "address", - "type": "address" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "RELAY_CALL_OVERHEAD", - "outputs": [ + "type": "address", + "indexed": true + }, { - "name": "", - "internalType": "uint64", - "type": "uint64" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "RELAY_CONSTANT_OVERHEAD", - "outputs": [ + "name": "amount", + "internalType": "uint256", + "type": "uint256", + "indexed": false + }, { - "name": "", - "internalType": "uint64", - "type": "uint64" + "name": "extraData", + "internalType": "bytes", + "type": "bytes", + "indexed": false } - ] + ], + "name": "ETHBridgeInitiated" }, { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "RELAY_GAS_CHECK_BUFFER", - "outputs": [ + "type": "event", + "anonymous": false, + "inputs": [ { - "name": "", - "internalType": "uint64", - "type": "uint64" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "RELAY_RESERVED_GAS", - "outputs": [ + "name": "l1Token", + "internalType": "address", + "type": "address", + "indexed": true + }, { - "name": "", - "internalType": "uint64", - "type": "uint64" - } - ] - }, - { - "stateMutability": "pure", - "type": "function", - "inputs": [ + "name": "l2Token", + "internalType": "address", + "type": "address", + "indexed": true + }, { - "name": "_message", - "internalType": "bytes", - "type": "bytes" + "name": "from", + "internalType": "address", + "type": "address", + "indexed": true }, { - "name": "_minGasLimit", - "internalType": "uint32", - "type": "uint32" - } - ], - "name": "baseGas", - "outputs": [ + "name": "to", + "internalType": "address", + "type": "address", + "indexed": false + }, { - "name": "", - "internalType": "uint64", - "type": "uint64" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [ + "name": "amount", + "internalType": "uint256", + "type": "uint256", + "indexed": false + }, { - "name": "", - "internalType": "bytes32", - "type": "bytes32" + "name": "extraData", + "internalType": "bytes", + "type": "bytes", + "indexed": false } ], - "name": "failedMessages", - "outputs": [ - { - "name": "", - "internalType": "bool", - "type": "bool" - } - ] - }, - { - "stateMutability": "nonpayable", - "type": "function", - "inputs": [], - "name": "initialize", - "outputs": [] + "name": "WithdrawalInitiated" }, { "stateMutability": "view", "type": "function", "inputs": [], - "name": "l1CrossDomainMessenger", + "name": "MESSENGER", "outputs": [ { "name": "", - "internalType": "address", + "internalType": "contract CrossDomainMessenger", "type": "address" } ] @@ -7525,224 +7448,150 @@ "stateMutability": "view", "type": "function", "inputs": [], - "name": "messageNonce", + "name": "OTHER_BRIDGE", "outputs": [ { "name": "", - "internalType": "uint256", - "type": "uint256" + "internalType": "contract StandardBridge", + "type": "address" } ] }, { - "stateMutability": "payable", + "stateMutability": "nonpayable", "type": "function", "inputs": [ { - "name": "_nonce", - "internalType": "uint256", - "type": "uint256" - }, - { - "name": "_sender", + "name": "_localToken", "internalType": "address", "type": "address" }, { - "name": "_target", + "name": "_remoteToken", "internalType": "address", "type": "address" }, { - "name": "_value", + "name": "_amount", "internalType": "uint256", "type": "uint256" }, { "name": "_minGasLimit", - "internalType": "uint256", - "type": "uint256" + "internalType": "uint32", + "type": "uint32" }, { - "name": "_message", + "name": "_extraData", "internalType": "bytes", "type": "bytes" } ], - "name": "relayMessage", + "name": "bridgeERC20", "outputs": [] }, { - "stateMutability": "payable", + "stateMutability": "nonpayable", "type": "function", "inputs": [ { - "name": "_target", + "name": "_localToken", "internalType": "address", "type": "address" }, { - "name": "_message", - "internalType": "bytes", - "type": "bytes" + "name": "_remoteToken", + "internalType": "address", + "type": "address" }, { - "name": "_minGasLimit", - "internalType": "uint32", - "type": "uint32" - } - ], - "name": "sendMessage", - "outputs": [] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [ + "name": "_to", + "internalType": "address", + "type": "address" + }, { - "name": "", - "internalType": "bytes32", - "type": "bytes32" - } - ], - "name": "successfulMessages", - "outputs": [ + "name": "_amount", + "internalType": "uint256", + "type": "uint256" + }, { - "name": "", - "internalType": "bool", - "type": "bool" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "version", - "outputs": [ + "name": "_minGasLimit", + "internalType": "uint32", + "type": "uint32" + }, { - "name": "", - "internalType": "string", - "type": "string" + "name": "_extraData", + "internalType": "bytes", + "type": "bytes" } - ] + ], + "name": "bridgeERC20To", + "outputs": [] }, { - "stateMutability": "view", + "stateMutability": "payable", "type": "function", - "inputs": [], - "name": "xDomainMessageSender", - "outputs": [ - { - "name": "", - "internalType": "address", - "type": "address" - } - ] - } - ], - "L2ERC721Bridge": [ - { - "stateMutability": "nonpayable", - "type": "constructor", "inputs": [ { - "name": "_messenger", - "internalType": "address", - "type": "address" + "name": "_minGasLimit", + "internalType": "uint32", + "type": "uint32" }, { - "name": "_otherBridge", - "internalType": "address", - "type": "address" + "name": "_extraData", + "internalType": "bytes", + "type": "bytes" } - ] + ], + "name": "bridgeETH", + "outputs": [] }, { - "type": "event", - "anonymous": false, + "stateMutability": "payable", + "type": "function", "inputs": [ { - "name": "localToken", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "remoteToken", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "from", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "to", + "name": "_to", "internalType": "address", - "type": "address", - "indexed": false + "type": "address" }, { - "name": "tokenId", - "internalType": "uint256", - "type": "uint256", - "indexed": false + "name": "_minGasLimit", + "internalType": "uint32", + "type": "uint32" }, { - "name": "extraData", + "name": "_extraData", "internalType": "bytes", - "type": "bytes", - "indexed": false + "type": "bytes" } ], - "name": "ERC721BridgeFinalized" + "name": "bridgeETHTo", + "outputs": [] }, { - "type": "event", - "anonymous": false, + "stateMutability": "view", + "type": "function", "inputs": [ { - "name": "localToken", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "remoteToken", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "from", + "name": "", "internalType": "address", - "type": "address", - "indexed": true + "type": "address" }, { - "name": "to", + "name": "", "internalType": "address", - "type": "address", - "indexed": false - }, + "type": "address" + } + ], + "name": "deposits", + "outputs": [ { - "name": "tokenId", + "name": "", "internalType": "uint256", - "type": "uint256", - "indexed": false - }, - { - "name": "extraData", - "internalType": "bytes", - "type": "bytes", - "indexed": false + "type": "uint256" } - ], - "name": "ERC721BridgeInitiated" + ] }, { "stateMutability": "nonpayable", @@ -7759,14 +7608,19 @@ "type": "address" }, { - "name": "_tokenId", - "internalType": "uint256", - "type": "uint256" + "name": "_from", + "internalType": "address", + "type": "address" }, { - "name": "_minGasLimit", - "internalType": "uint32", - "type": "uint32" + "name": "_to", + "internalType": "address", + "type": "address" + }, + { + "name": "_amount", + "internalType": "uint256", + "type": "uint256" }, { "name": "_extraData", @@ -7774,20 +7628,15 @@ "type": "bytes" } ], - "name": "bridgeERC721", + "name": "finalizeBridgeERC20", "outputs": [] }, { - "stateMutability": "nonpayable", + "stateMutability": "payable", "type": "function", "inputs": [ { - "name": "_localToken", - "internalType": "address", - "type": "address" - }, - { - "name": "_remoteToken", + "name": "_from", "internalType": "address", "type": "address" }, @@ -7797,35 +7646,30 @@ "type": "address" }, { - "name": "_tokenId", + "name": "_amount", "internalType": "uint256", "type": "uint256" }, - { - "name": "_minGasLimit", - "internalType": "uint32", - "type": "uint32" - }, { "name": "_extraData", "internalType": "bytes", "type": "bytes" } ], - "name": "bridgeERC721To", + "name": "finalizeBridgeETH", "outputs": [] }, { - "stateMutability": "nonpayable", + "stateMutability": "payable", "type": "function", "inputs": [ { - "name": "_localToken", + "name": "_l1Token", "internalType": "address", "type": "address" }, { - "name": "_remoteToken", + "name": "_l2Token", "internalType": "address", "type": "address" }, @@ -7840,7 +7684,7 @@ "type": "address" }, { - "name": "_tokenId", + "name": "_amount", "internalType": "uint256", "type": "uint256" }, @@ -7850,18 +7694,18 @@ "type": "bytes" } ], - "name": "finalizeBridgeERC721", + "name": "finalizeDeposit", "outputs": [] }, { "stateMutability": "view", "type": "function", "inputs": [], - "name": "messenger", + "name": "l1TokenBridge", "outputs": [ { "name": "", - "internalType": "contract CrossDomainMessenger", + "internalType": "address", "type": "address" } ] @@ -7870,11 +7714,11 @@ "stateMutability": "view", "type": "function", "inputs": [], - "name": "otherBridge", + "name": "messenger", "outputs": [ { "name": "", - "internalType": "address", + "internalType": "contract CrossDomainMessenger", "type": "address" } ] @@ -7891,269 +7735,213 @@ "type": "string" } ] - } - ], - "L2ERC721Bridge_optimism-goerli": [ + }, { - "stateMutability": "nonpayable", - "type": "constructor", + "stateMutability": "payable", + "type": "function", "inputs": [ { - "name": "_messenger", + "name": "_l2Token", "internalType": "address", "type": "address" }, { - "name": "_otherBridge", - "internalType": "address", - "type": "address" - } - ] - }, - { - "type": "event", - "anonymous": false, - "inputs": [ + "name": "_amount", + "internalType": "uint256", + "type": "uint256" + }, { - "name": "localToken", - "internalType": "address", - "type": "address", - "indexed": true + "name": "_minGasLimit", + "internalType": "uint32", + "type": "uint32" }, { - "name": "remoteToken", - "internalType": "address", - "type": "address", - "indexed": true - }, + "name": "_extraData", + "internalType": "bytes", + "type": "bytes" + } + ], + "name": "withdraw", + "outputs": [] + }, + { + "stateMutability": "payable", + "type": "function", + "inputs": [ { - "name": "from", + "name": "_l2Token", "internalType": "address", - "type": "address", - "indexed": true + "type": "address" }, { - "name": "to", + "name": "_to", "internalType": "address", - "type": "address", - "indexed": false + "type": "address" }, { - "name": "tokenId", + "name": "_amount", "internalType": "uint256", - "type": "uint256", - "indexed": false + "type": "uint256" }, { - "name": "extraData", + "name": "_minGasLimit", + "internalType": "uint32", + "type": "uint32" + }, + { + "name": "_extraData", "internalType": "bytes", - "type": "bytes", - "indexed": false + "type": "bytes" } ], - "name": "ERC721BridgeFinalized" + "name": "withdrawTo", + "outputs": [] + }, + { + "stateMutability": "payable", + "type": "receive" + } + ], + "L2ToL1MessagePasser": [ + { + "stateMutability": "nonpayable", + "type": "constructor", + "inputs": [] }, { "type": "event", "anonymous": false, "inputs": [ { - "name": "localToken", - "internalType": "address", - "type": "address", + "name": "nonce", + "internalType": "uint256", + "type": "uint256", "indexed": true }, { - "name": "remoteToken", + "name": "sender", "internalType": "address", "type": "address", "indexed": true }, { - "name": "from", + "name": "target", "internalType": "address", "type": "address", "indexed": true }, { - "name": "to", - "internalType": "address", - "type": "address", + "name": "value", + "internalType": "uint256", + "type": "uint256", "indexed": false }, { - "name": "tokenId", + "name": "gasLimit", "internalType": "uint256", "type": "uint256", "indexed": false }, { - "name": "extraData", + "name": "data", "internalType": "bytes", "type": "bytes", "indexed": false + }, + { + "name": "withdrawalHash", + "internalType": "bytes32", + "type": "bytes32", + "indexed": false } ], - "name": "ERC721BridgeInitiated" + "name": "MessagePassed" }, { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "MESSENGER", - "outputs": [ + "type": "event", + "anonymous": false, + "inputs": [ { - "name": "", - "internalType": "contract CrossDomainMessenger", - "type": "address" + "name": "amount", + "internalType": "uint256", + "type": "uint256", + "indexed": true } - ] + ], + "name": "WithdrawerBalanceBurnt" }, { "stateMutability": "view", "type": "function", "inputs": [], - "name": "OTHER_BRIDGE", + "name": "MESSAGE_VERSION", "outputs": [ { "name": "", - "internalType": "address", - "type": "address" + "internalType": "uint16", + "type": "uint16" } ] }, { "stateMutability": "nonpayable", "type": "function", - "inputs": [ - { - "name": "_localToken", - "internalType": "address", - "type": "address" - }, - { - "name": "_remoteToken", - "internalType": "address", - "type": "address" - }, - { - "name": "_tokenId", - "internalType": "uint256", - "type": "uint256" - }, - { - "name": "_minGasLimit", - "internalType": "uint32", - "type": "uint32" - }, - { - "name": "_extraData", - "internalType": "bytes", - "type": "bytes" - } - ], - "name": "bridgeERC721", - "outputs": [] - }, - { - "stateMutability": "nonpayable", - "type": "function", - "inputs": [ - { - "name": "_localToken", - "internalType": "address", - "type": "address" - }, - { - "name": "_remoteToken", - "internalType": "address", - "type": "address" - }, - { - "name": "_to", - "internalType": "address", - "type": "address" - }, - { - "name": "_tokenId", - "internalType": "uint256", - "type": "uint256" - }, - { - "name": "_minGasLimit", - "internalType": "uint32", - "type": "uint32" - }, - { - "name": "_extraData", - "internalType": "bytes", - "type": "bytes" - } - ], - "name": "bridgeERC721To", + "inputs": [], + "name": "burn", "outputs": [] }, { - "stateMutability": "nonpayable", + "stateMutability": "payable", "type": "function", "inputs": [ { - "name": "_localToken", - "internalType": "address", - "type": "address" - }, - { - "name": "_remoteToken", - "internalType": "address", - "type": "address" - }, - { - "name": "_from", - "internalType": "address", - "type": "address" - }, - { - "name": "_to", + "name": "_target", "internalType": "address", "type": "address" }, { - "name": "_tokenId", + "name": "_gasLimit", "internalType": "uint256", "type": "uint256" }, { - "name": "_extraData", + "name": "_data", "internalType": "bytes", "type": "bytes" } ], - "name": "finalizeBridgeERC721", + "name": "initiateWithdrawal", "outputs": [] }, { "stateMutability": "view", "type": "function", "inputs": [], - "name": "messenger", + "name": "messageNonce", "outputs": [ { "name": "", - "internalType": "contract CrossDomainMessenger", - "type": "address" + "internalType": "uint256", + "type": "uint256" } ] }, { "stateMutability": "view", "type": "function", - "inputs": [], - "name": "otherBridge", + "inputs": [ + { + "name": "", + "internalType": "bytes32", + "type": "bytes32" + } + ], + "name": "sentMessages", "outputs": [ { "name": "", - "internalType": "address", - "type": "address" + "internalType": "bool", + "type": "bool" } ] }, @@ -8169,47 +7957,26 @@ "type": "string" } ] + }, + { + "stateMutability": "payable", + "type": "receive" } ], - "L2OutputOracle": [ + "MintManager": [ { "stateMutability": "nonpayable", "type": "constructor", "inputs": [ { - "name": "_submissionInterval", - "internalType": "uint256", - "type": "uint256" - }, - { - "name": "_l2BlockTime", - "internalType": "uint256", - "type": "uint256" - }, - { - "name": "_startingBlockNumber", - "internalType": "uint256", - "type": "uint256" - }, - { - "name": "_startingTimestamp", - "internalType": "uint256", - "type": "uint256" - }, - { - "name": "_proposer", + "name": "_upgrader", "internalType": "address", "type": "address" }, { - "name": "_challenger", + "name": "_governanceToken", "internalType": "address", "type": "address" - }, - { - "name": "_finalizationPeriodSeconds", - "internalType": "uint256", - "type": "uint256" } ] }, @@ -8218,74 +7985,30 @@ "anonymous": false, "inputs": [ { - "name": "version", - "internalType": "uint8", - "type": "uint8", - "indexed": false - } - ], - "name": "Initialized" - }, - { - "type": "event", - "anonymous": false, - "inputs": [ - { - "name": "outputRoot", - "internalType": "bytes32", - "type": "bytes32", - "indexed": true - }, - { - "name": "l2OutputIndex", - "internalType": "uint256", - "type": "uint256", - "indexed": true - }, - { - "name": "l2BlockNumber", - "internalType": "uint256", - "type": "uint256", - "indexed": true - }, - { - "name": "l1Timestamp", - "internalType": "uint256", - "type": "uint256", - "indexed": false - } - ], - "name": "OutputProposed" - }, - { - "type": "event", - "anonymous": false, - "inputs": [ - { - "name": "prevNextOutputIndex", - "internalType": "uint256", - "type": "uint256", + "name": "previousOwner", + "internalType": "address", + "type": "address", "indexed": true }, { - "name": "newNextOutputIndex", - "internalType": "uint256", - "type": "uint256", + "name": "newOwner", + "internalType": "address", + "type": "address", "indexed": true } ], - "name": "OutputsDeleted" + "name": "OwnershipTransferred" }, { "stateMutability": "view", "type": "function", "inputs": [], - "name": "CHALLENGER", + "name": "DENOMINATOR", "outputs": [ { "name": "", - "internalType": "address", - "type": "address" + "internalType": "uint256", + "type": "uint256" } ] }, @@ -8293,7 +8016,7 @@ "stateMutability": "view", "type": "function", "inputs": [], - "name": "FINALIZATION_PERIOD_SECONDS", + "name": "MINT_CAP", "outputs": [ { "name": "", @@ -8306,7 +8029,7 @@ "stateMutability": "view", "type": "function", "inputs": [], - "name": "L2_BLOCK_TIME", + "name": "MINT_PERIOD", "outputs": [ { "name": "", @@ -8319,20 +8042,38 @@ "stateMutability": "view", "type": "function", "inputs": [], - "name": "PROPOSER", + "name": "governanceToken", "outputs": [ { "name": "", - "internalType": "address", + "internalType": "contract GovernanceToken", "type": "address" } ] }, + { + "stateMutability": "nonpayable", + "type": "function", + "inputs": [ + { + "name": "_account", + "internalType": "address", + "type": "address" + }, + { + "name": "_amount", + "internalType": "uint256", + "type": "uint256" + } + ], + "name": "mint", + "outputs": [] + }, { "stateMutability": "view", "type": "function", "inputs": [], - "name": "SUBMISSION_INTERVAL", + "name": "mintPermittedAfter", "outputs": [ { "name": "", @@ -8344,249 +8085,243 @@ { "stateMutability": "view", "type": "function", - "inputs": [ - { - "name": "_l2BlockNumber", - "internalType": "uint256", - "type": "uint256" - } - ], - "name": "computeL2Timestamp", + "inputs": [], + "name": "owner", "outputs": [ { "name": "", - "internalType": "uint256", - "type": "uint256" + "internalType": "address", + "type": "address" } ] }, + { + "stateMutability": "nonpayable", + "type": "function", + "inputs": [], + "name": "renounceOwnership", + "outputs": [] + }, { "stateMutability": "nonpayable", "type": "function", "inputs": [ { - "name": "_l2OutputIndex", - "internalType": "uint256", - "type": "uint256" + "name": "newOwner", + "internalType": "address", + "type": "address" } ], - "name": "deleteL2Outputs", + "name": "transferOwnership", "outputs": [] }, { - "stateMutability": "view", + "stateMutability": "nonpayable", "type": "function", "inputs": [ { - "name": "_l2OutputIndex", - "internalType": "uint256", - "type": "uint256" + "name": "_newMintManager", + "internalType": "address", + "type": "address" } ], - "name": "getL2Output", - "outputs": [ - { - "name": "", - "internalType": "struct Types.OutputProposal", - "type": "tuple", - "components": [ - { - "name": "outputRoot", - "internalType": "bytes32", - "type": "bytes32" - }, - { - "name": "timestamp", - "internalType": "uint128", - "type": "uint128" - }, - { - "name": "l2BlockNumber", - "internalType": "uint128", - "type": "uint128" - } - ] - } - ] + "name": "upgrade", + "outputs": [] + } + ], + "OptimismMintableERC20Factory": [ + { + "stateMutability": "nonpayable", + "type": "constructor", + "inputs": [] }, { - "stateMutability": "view", - "type": "function", + "type": "event", + "anonymous": false, "inputs": [ { - "name": "_l2BlockNumber", - "internalType": "uint256", - "type": "uint256" + "name": "version", + "internalType": "uint8", + "type": "uint8", + "indexed": false } ], - "name": "getL2OutputAfter", - "outputs": [ - { - "name": "", - "internalType": "struct Types.OutputProposal", - "type": "tuple", - "components": [ - { - "name": "outputRoot", - "internalType": "bytes32", - "type": "bytes32" - }, - { - "name": "timestamp", - "internalType": "uint128", - "type": "uint128" - }, - { - "name": "l2BlockNumber", - "internalType": "uint128", - "type": "uint128" - } - ] - } - ] + "name": "Initialized" }, { - "stateMutability": "view", - "type": "function", + "type": "event", + "anonymous": false, "inputs": [ { - "name": "_l2BlockNumber", - "internalType": "uint256", - "type": "uint256" - } - ], - "name": "getL2OutputIndexAfter", - "outputs": [ + "name": "localToken", + "internalType": "address", + "type": "address", + "indexed": true + }, { - "name": "", - "internalType": "uint256", - "type": "uint256" + "name": "remoteToken", + "internalType": "address", + "type": "address", + "indexed": true + }, + { + "name": "deployer", + "internalType": "address", + "type": "address", + "indexed": false } - ] + ], + "name": "OptimismMintableERC20Created" }, { - "stateMutability": "nonpayable", - "type": "function", + "type": "event", + "anonymous": false, "inputs": [ { - "name": "_startingBlockNumber", - "internalType": "uint256", - "type": "uint256" + "name": "remoteToken", + "internalType": "address", + "type": "address", + "indexed": true }, { - "name": "_startingTimestamp", - "internalType": "uint256", - "type": "uint256" + "name": "localToken", + "internalType": "address", + "type": "address", + "indexed": true } ], - "name": "initialize", - "outputs": [] + "name": "StandardL2TokenCreated" }, { "stateMutability": "view", "type": "function", "inputs": [], - "name": "latestBlockNumber", + "name": "BRIDGE", "outputs": [ { "name": "", - "internalType": "uint256", - "type": "uint256" - } + "internalType": "address", + "type": "address" + } ] }, { "stateMutability": "view", "type": "function", "inputs": [], - "name": "latestOutputIndex", + "name": "bridge", "outputs": [ { "name": "", - "internalType": "uint256", - "type": "uint256" + "internalType": "address", + "type": "address" } ] }, { - "stateMutability": "view", + "stateMutability": "nonpayable", "type": "function", - "inputs": [], - "name": "nextBlockNumber", + "inputs": [ + { + "name": "_remoteToken", + "internalType": "address", + "type": "address" + }, + { + "name": "_name", + "internalType": "string", + "type": "string" + }, + { + "name": "_symbol", + "internalType": "string", + "type": "string" + } + ], + "name": "createOptimismMintableERC20", "outputs": [ { "name": "", - "internalType": "uint256", - "type": "uint256" + "internalType": "address", + "type": "address" } ] }, { - "stateMutability": "view", + "stateMutability": "nonpayable", "type": "function", - "inputs": [], - "name": "nextOutputIndex", + "inputs": [ + { + "name": "_remoteToken", + "internalType": "address", + "type": "address" + }, + { + "name": "_name", + "internalType": "string", + "type": "string" + }, + { + "name": "_symbol", + "internalType": "string", + "type": "string" + }, + { + "name": "_decimals", + "internalType": "uint8", + "type": "uint8" + } + ], + "name": "createOptimismMintableERC20WithDecimals", "outputs": [ { "name": "", - "internalType": "uint256", - "type": "uint256" + "internalType": "address", + "type": "address" } ] }, { - "stateMutability": "payable", + "stateMutability": "nonpayable", "type": "function", "inputs": [ { - "name": "_outputRoot", - "internalType": "bytes32", - "type": "bytes32" - }, - { - "name": "_l2BlockNumber", - "internalType": "uint256", - "type": "uint256" + "name": "_remoteToken", + "internalType": "address", + "type": "address" }, { - "name": "_l1BlockHash", - "internalType": "bytes32", - "type": "bytes32" + "name": "_name", + "internalType": "string", + "type": "string" }, { - "name": "_l1BlockNumber", - "internalType": "uint256", - "type": "uint256" + "name": "_symbol", + "internalType": "string", + "type": "string" } ], - "name": "proposeL2Output", - "outputs": [] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "startingBlockNumber", + "name": "createStandardL2Token", "outputs": [ { "name": "", - "internalType": "uint256", - "type": "uint256" + "internalType": "address", + "type": "address" } ] }, { - "stateMutability": "view", + "stateMutability": "nonpayable", "type": "function", - "inputs": [], - "name": "startingTimestamp", - "outputs": [ + "inputs": [ { - "name": "", - "internalType": "uint256", - "type": "uint256" + "name": "_bridge", + "internalType": "address", + "type": "address" } - ] + ], + "name": "initialize", + "outputs": [] }, { "stateMutability": "view", @@ -8602,27 +8337,11 @@ ] } ], - "L2OutputOracle_goerli": [ + "OptimismMintableERC20Factory_goerli": [ { "stateMutability": "nonpayable", "type": "constructor", - "inputs": [ - { - "name": "_submissionInterval", - "internalType": "uint256", - "type": "uint256" - }, - { - "name": "_l2BlockTime", - "internalType": "uint256", - "type": "uint256" - }, - { - "name": "_finalizationPeriodSeconds", - "internalType": "uint256", - "type": "uint256" - } - ] + "inputs": [] }, { "type": "event", @@ -8642,56 +8361,50 @@ "anonymous": false, "inputs": [ { - "name": "outputRoot", - "internalType": "bytes32", - "type": "bytes32", - "indexed": true - }, - { - "name": "l2OutputIndex", - "internalType": "uint256", - "type": "uint256", + "name": "localToken", + "internalType": "address", + "type": "address", "indexed": true }, { - "name": "l2BlockNumber", - "internalType": "uint256", - "type": "uint256", + "name": "remoteToken", + "internalType": "address", + "type": "address", "indexed": true }, { - "name": "l1Timestamp", - "internalType": "uint256", - "type": "uint256", + "name": "deployer", + "internalType": "address", + "type": "address", "indexed": false } ], - "name": "OutputProposed" + "name": "OptimismMintableERC20Created" }, { "type": "event", "anonymous": false, "inputs": [ { - "name": "prevNextOutputIndex", - "internalType": "uint256", - "type": "uint256", + "name": "remoteToken", + "internalType": "address", + "type": "address", "indexed": true }, { - "name": "newNextOutputIndex", - "internalType": "uint256", - "type": "uint256", + "name": "localToken", + "internalType": "address", + "type": "address", "indexed": true } ], - "name": "OutputsDeleted" + "name": "StandardL2TokenCreated" }, { "stateMutability": "view", "type": "function", "inputs": [], - "name": "CHALLENGER", + "name": "BRIDGE", "outputs": [ { "name": "", @@ -8704,33 +8417,36 @@ "stateMutability": "view", "type": "function", "inputs": [], - "name": "FINALIZATION_PERIOD_SECONDS", + "name": "bridge", "outputs": [ { "name": "", - "internalType": "uint256", - "type": "uint256" + "internalType": "address", + "type": "address" } ] }, { - "stateMutability": "view", + "stateMutability": "nonpayable", "type": "function", - "inputs": [], - "name": "L2_BLOCK_TIME", - "outputs": [ + "inputs": [ { - "name": "", - "internalType": "uint256", - "type": "uint256" + "name": "_remoteToken", + "internalType": "address", + "type": "address" + }, + { + "name": "_name", + "internalType": "string", + "type": "string" + }, + { + "name": "_symbol", + "internalType": "string", + "type": "string" } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "PROPOSER", + ], + "name": "createOptimismMintableERC20", "outputs": [ { "name": "", @@ -8740,23 +8456,31 @@ ] }, { - "stateMutability": "view", + "stateMutability": "nonpayable", "type": "function", - "inputs": [], - "name": "SUBMISSION_INTERVAL", - "outputs": [ + "inputs": [ { - "name": "", - "internalType": "uint256", - "type": "uint256" + "name": "_remoteToken", + "internalType": "address", + "type": "address" + }, + { + "name": "_name", + "internalType": "string", + "type": "string" + }, + { + "name": "_symbol", + "internalType": "string", + "type": "string" + }, + { + "name": "_decimals", + "internalType": "uint8", + "type": "uint8" } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "challenger", + ], + "name": "createOptimismMintableERC20WithDecimals", "outputs": [ { "name": "", @@ -8766,21 +8490,31 @@ ] }, { - "stateMutability": "view", + "stateMutability": "nonpayable", "type": "function", "inputs": [ { - "name": "_l2BlockNumber", - "internalType": "uint256", - "type": "uint256" + "name": "_remoteToken", + "internalType": "address", + "type": "address" + }, + { + "name": "_name", + "internalType": "string", + "type": "string" + }, + { + "name": "_symbol", + "internalType": "string", + "type": "string" } ], - "name": "computeL2Timestamp", + "name": "createStandardL2Token", "outputs": [ { "name": "", - "internalType": "uint256", - "type": "uint256" + "internalType": "address", + "type": "address" } ] }, @@ -8789,115 +8523,123 @@ "type": "function", "inputs": [ { - "name": "_l2OutputIndex", - "internalType": "uint256", - "type": "uint256" + "name": "_bridge", + "internalType": "address", + "type": "address" } ], - "name": "deleteL2Outputs", + "name": "initialize", "outputs": [] }, { "stateMutability": "view", "type": "function", "inputs": [], - "name": "finalizationPeriodSeconds", + "name": "version", "outputs": [ { "name": "", - "internalType": "uint256", - "type": "uint256" + "internalType": "string", + "type": "string" } ] - }, + } + ], + "OptimismMintableERC20Factory_optimism-goerli": [ { - "stateMutability": "view", - "type": "function", + "stateMutability": "nonpayable", + "type": "constructor", "inputs": [ { - "name": "_l2OutputIndex", - "internalType": "uint256", - "type": "uint256" + "name": "_bridge", + "internalType": "address", + "type": "address" } - ], - "name": "getL2Output", - "outputs": [ + ] + }, + { + "type": "event", + "anonymous": false, + "inputs": [ { - "name": "", - "internalType": "struct Types.OutputProposal", - "type": "tuple", - "components": [ - { - "name": "outputRoot", - "internalType": "bytes32", - "type": "bytes32" - }, - { - "name": "timestamp", - "internalType": "uint128", - "type": "uint128" - }, - { - "name": "l2BlockNumber", - "internalType": "uint128", - "type": "uint128" - } - ] + "name": "localToken", + "internalType": "address", + "type": "address", + "indexed": true + }, + { + "name": "remoteToken", + "internalType": "address", + "type": "address", + "indexed": true + }, + { + "name": "deployer", + "internalType": "address", + "type": "address", + "indexed": false } - ] + ], + "name": "OptimismMintableERC20Created" }, { - "stateMutability": "view", - "type": "function", + "type": "event", + "anonymous": false, "inputs": [ { - "name": "_l2BlockNumber", - "internalType": "uint256", - "type": "uint256" + "name": "remoteToken", + "internalType": "address", + "type": "address", + "indexed": true + }, + { + "name": "localToken", + "internalType": "address", + "type": "address", + "indexed": true } ], - "name": "getL2OutputAfter", + "name": "StandardL2TokenCreated" + }, + { + "stateMutability": "view", + "type": "function", + "inputs": [], + "name": "BRIDGE", "outputs": [ { "name": "", - "internalType": "struct Types.OutputProposal", - "type": "tuple", - "components": [ - { - "name": "outputRoot", - "internalType": "bytes32", - "type": "bytes32" - }, - { - "name": "timestamp", - "internalType": "uint128", - "type": "uint128" - }, - { - "name": "l2BlockNumber", - "internalType": "uint128", - "type": "uint128" - } - ] + "internalType": "address", + "type": "address" } ] }, { - "stateMutability": "view", + "stateMutability": "nonpayable", "type": "function", "inputs": [ { - "name": "_l2BlockNumber", - "internalType": "uint256", - "type": "uint256" + "name": "_remoteToken", + "internalType": "address", + "type": "address" + }, + { + "name": "_name", + "internalType": "string", + "type": "string" + }, + { + "name": "_symbol", + "internalType": "string", + "type": "string" } ], - "name": "getL2OutputIndexAfter", + "name": "createOptimismMintableERC20", "outputs": [ { "name": "", - "internalType": "uint256", - "type": "uint256" + "internalType": "address", + "type": "address" } ] }, @@ -8906,78 +8648,144 @@ "type": "function", "inputs": [ { - "name": "_startingBlockNumber", - "internalType": "uint256", - "type": "uint256" + "name": "_remoteToken", + "internalType": "address", + "type": "address" }, { - "name": "_startingTimestamp", - "internalType": "uint256", - "type": "uint256" + "name": "_name", + "internalType": "string", + "type": "string" }, { - "name": "_proposer", - "internalType": "address", - "type": "address" - }, + "name": "_symbol", + "internalType": "string", + "type": "string" + } + ], + "name": "createStandardL2Token", + "outputs": [ { - "name": "_challenger", + "name": "", "internalType": "address", "type": "address" } - ], - "name": "initialize", - "outputs": [] + ] }, { "stateMutability": "view", "type": "function", "inputs": [], - "name": "l2BlockTime", + "name": "version", "outputs": [ { "name": "", - "internalType": "uint256", - "type": "uint256" + "internalType": "string", + "type": "string" } ] - }, + } + ], + "OptimismMintableERC721Factory": [ { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "latestBlockNumber", - "outputs": [ + "stateMutability": "nonpayable", + "type": "constructor", + "inputs": [ { - "name": "", + "name": "_bridge", + "internalType": "address", + "type": "address" + }, + { + "name": "_remoteChainId", "internalType": "uint256", "type": "uint256" } ] }, + { + "type": "event", + "anonymous": false, + "inputs": [ + { + "name": "localToken", + "internalType": "address", + "type": "address", + "indexed": true + }, + { + "name": "remoteToken", + "internalType": "address", + "type": "address", + "indexed": true + }, + { + "name": "deployer", + "internalType": "address", + "type": "address", + "indexed": false + } + ], + "name": "OptimismMintableERC721Created" + }, { "stateMutability": "view", "type": "function", "inputs": [], - "name": "latestOutputIndex", + "name": "bridge", "outputs": [ { "name": "", - "internalType": "uint256", - "type": "uint256" + "internalType": "address", + "type": "address" } ] }, { - "stateMutability": "view", + "stateMutability": "nonpayable", "type": "function", - "inputs": [], - "name": "nextBlockNumber", + "inputs": [ + { + "name": "_remoteToken", + "internalType": "address", + "type": "address" + }, + { + "name": "_name", + "internalType": "string", + "type": "string" + }, + { + "name": "_symbol", + "internalType": "string", + "type": "string" + } + ], + "name": "createOptimismMintableERC721", "outputs": [ { "name": "", - "internalType": "uint256", - "type": "uint256" + "internalType": "address", + "type": "address" + } + ] + }, + { + "stateMutability": "view", + "type": "function", + "inputs": [ + { + "name": "", + "internalType": "address", + "type": "address" + } + ], + "name": "isOptimismMintableERC721", + "outputs": [ + { + "name": "", + "internalType": "bool", + "type": "bool" } ] }, @@ -8985,7 +8793,7 @@ "stateMutability": "view", "type": "function", "inputs": [], - "name": "nextOutputIndex", + "name": "remoteChainId", "outputs": [ { "name": "", @@ -8995,38 +8803,66 @@ ] }, { - "stateMutability": "payable", + "stateMutability": "view", "type": "function", + "inputs": [], + "name": "version", + "outputs": [ + { + "name": "", + "internalType": "string", + "type": "string" + } + ] + } + ], + "OptimismMintableERC721Factory_optimism-goerli": [ + { + "stateMutability": "nonpayable", + "type": "constructor", "inputs": [ { - "name": "_outputRoot", - "internalType": "bytes32", - "type": "bytes32" + "name": "_bridge", + "internalType": "address", + "type": "address" }, { - "name": "_l2BlockNumber", + "name": "_remoteChainId", "internalType": "uint256", "type": "uint256" + } + ] + }, + { + "type": "event", + "anonymous": false, + "inputs": [ + { + "name": "localToken", + "internalType": "address", + "type": "address", + "indexed": true }, { - "name": "_l1BlockHash", - "internalType": "bytes32", - "type": "bytes32" + "name": "remoteToken", + "internalType": "address", + "type": "address", + "indexed": true }, { - "name": "_l1BlockNumber", - "internalType": "uint256", - "type": "uint256" + "name": "deployer", + "internalType": "address", + "type": "address", + "indexed": false } ], - "name": "proposeL2Output", - "outputs": [] + "name": "OptimismMintableERC721Created" }, { "stateMutability": "view", "type": "function", "inputs": [], - "name": "proposer", + "name": "BRIDGE", "outputs": [ { "name": "", @@ -9039,7 +8875,7 @@ "stateMutability": "view", "type": "function", "inputs": [], - "name": "startingBlockNumber", + "name": "REMOTE_CHAIN_ID", "outputs": [ { "name": "", @@ -9049,28 +8885,50 @@ ] }, { - "stateMutability": "view", + "stateMutability": "nonpayable", "type": "function", - "inputs": [], - "name": "startingTimestamp", + "inputs": [ + { + "name": "_remoteToken", + "internalType": "address", + "type": "address" + }, + { + "name": "_name", + "internalType": "string", + "type": "string" + }, + { + "name": "_symbol", + "internalType": "string", + "type": "string" + } + ], + "name": "createOptimismMintableERC721", "outputs": [ { "name": "", - "internalType": "uint256", - "type": "uint256" + "internalType": "address", + "type": "address" } ] }, { "stateMutability": "view", "type": "function", - "inputs": [], - "name": "submissionInterval", + "inputs": [ + { + "name": "", + "internalType": "address", + "type": "address" + } + ], + "name": "isOptimismMintableERC721", "outputs": [ { "name": "", - "internalType": "uint256", - "type": "uint256" + "internalType": "bool", + "type": "bool" } ] }, @@ -9088,34 +8946,42 @@ ] } ], - "L2StandardBridge": [ + "OptimismPortal": [ { "stateMutability": "nonpayable", "type": "constructor", + "inputs": [] + }, + { + "type": "event", + "anonymous": false, "inputs": [ { - "name": "_otherBridge", - "internalType": "address payable", - "type": "address" + "name": "version", + "internalType": "uint8", + "type": "uint8", + "indexed": false } - ] + ], + "name": "Initialized" }, { "type": "event", "anonymous": false, "inputs": [ { - "name": "l1Token", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "l2Token", + "name": "account", "internalType": "address", "type": "address", - "indexed": true - }, + "indexed": false + } + ], + "name": "Paused" + }, + { + "type": "event", + "anonymous": false, + "inputs": [ { "name": "from", "internalType": "address", @@ -9126,223 +8992,102 @@ "name": "to", "internalType": "address", "type": "address", - "indexed": false + "indexed": true }, { - "name": "amount", + "name": "version", "internalType": "uint256", "type": "uint256", - "indexed": false + "indexed": true }, { - "name": "extraData", + "name": "opaqueData", "internalType": "bytes", "type": "bytes", "indexed": false } ], - "name": "DepositFinalized" + "name": "TransactionDeposited" }, { "type": "event", "anonymous": false, "inputs": [ { - "name": "localToken", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "remoteToken", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "from", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "to", + "name": "account", "internalType": "address", "type": "address", "indexed": false - }, + } + ], + "name": "Unpaused" + }, + { + "type": "event", + "anonymous": false, + "inputs": [ { - "name": "amount", - "internalType": "uint256", - "type": "uint256", - "indexed": false + "name": "withdrawalHash", + "internalType": "bytes32", + "type": "bytes32", + "indexed": true }, { - "name": "extraData", - "internalType": "bytes", - "type": "bytes", + "name": "success", + "internalType": "bool", + "type": "bool", "indexed": false } ], - "name": "ERC20BridgeFinalized" + "name": "WithdrawalFinalized" }, { "type": "event", "anonymous": false, "inputs": [ { - "name": "localToken", - "internalType": "address", - "type": "address", + "name": "withdrawalHash", + "internalType": "bytes32", + "type": "bytes32", "indexed": true }, { - "name": "remoteToken", + "name": "from", "internalType": "address", "type": "address", "indexed": true }, { - "name": "from", + "name": "to", "internalType": "address", "type": "address", "indexed": true - }, + } + ], + "name": "WithdrawalProven" + }, + { + "stateMutability": "view", + "type": "function", + "inputs": [], + "name": "GUARDIAN", + "outputs": [ { - "name": "to", + "name": "", "internalType": "address", - "type": "address", - "indexed": false - }, - { - "name": "amount", - "internalType": "uint256", - "type": "uint256", - "indexed": false - }, - { - "name": "extraData", - "internalType": "bytes", - "type": "bytes", - "indexed": false - } - ], - "name": "ERC20BridgeInitiated" - }, - { - "type": "event", - "anonymous": false, - "inputs": [ - { - "name": "from", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "to", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "amount", - "internalType": "uint256", - "type": "uint256", - "indexed": false - }, - { - "name": "extraData", - "internalType": "bytes", - "type": "bytes", - "indexed": false - } - ], - "name": "ETHBridgeFinalized" - }, - { - "type": "event", - "anonymous": false, - "inputs": [ - { - "name": "from", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "to", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "amount", - "internalType": "uint256", - "type": "uint256", - "indexed": false - }, - { - "name": "extraData", - "internalType": "bytes", - "type": "bytes", - "indexed": false - } - ], - "name": "ETHBridgeInitiated" - }, - { - "type": "event", - "anonymous": false, - "inputs": [ - { - "name": "l1Token", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "l2Token", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "from", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "to", - "internalType": "address", - "type": "address", - "indexed": false - }, - { - "name": "amount", - "internalType": "uint256", - "type": "uint256", - "indexed": false - }, - { - "name": "extraData", - "internalType": "bytes", - "type": "bytes", - "indexed": false + "type": "address" } - ], - "name": "WithdrawalInitiated" + ] }, { "stateMutability": "view", "type": "function", "inputs": [], - "name": "MESSENGER", + "name": "L2_ORACLE", "outputs": [ { "name": "", - "internalType": "contract CrossDomainMessenger", + "internalType": "contract L2OutputOracle", "type": "address" } ] @@ -9351,2951 +9096,158 @@ "stateMutability": "view", "type": "function", "inputs": [], - "name": "OTHER_BRIDGE", + "name": "SYSTEM_CONFIG", "outputs": [ { "name": "", - "internalType": "contract StandardBridge", + "internalType": "contract SystemConfig", "type": "address" } ] }, { - "stateMutability": "nonpayable", - "type": "function", - "inputs": [ - { - "name": "_localToken", - "internalType": "address", - "type": "address" - }, - { - "name": "_remoteToken", - "internalType": "address", - "type": "address" - }, - { - "name": "_amount", - "internalType": "uint256", - "type": "uint256" - }, - { - "name": "_minGasLimit", - "internalType": "uint32", - "type": "uint32" - }, - { - "name": "_extraData", - "internalType": "bytes", - "type": "bytes" - } - ], - "name": "bridgeERC20", - "outputs": [] - }, - { - "stateMutability": "nonpayable", + "stateMutability": "payable", "type": "function", "inputs": [ - { - "name": "_localToken", - "internalType": "address", - "type": "address" - }, - { - "name": "_remoteToken", - "internalType": "address", - "type": "address" - }, { "name": "_to", "internalType": "address", "type": "address" }, { - "name": "_amount", + "name": "_value", "internalType": "uint256", "type": "uint256" }, { - "name": "_minGasLimit", - "internalType": "uint32", - "type": "uint32" + "name": "_gasLimit", + "internalType": "uint64", + "type": "uint64" }, { - "name": "_extraData", - "internalType": "bytes", - "type": "bytes" - } - ], - "name": "bridgeERC20To", - "outputs": [] - }, - { - "stateMutability": "payable", - "type": "function", - "inputs": [ - { - "name": "_minGasLimit", - "internalType": "uint32", - "type": "uint32" + "name": "_isCreation", + "internalType": "bool", + "type": "bool" }, { - "name": "_extraData", + "name": "_data", "internalType": "bytes", "type": "bytes" } ], - "name": "bridgeETH", + "name": "depositTransaction", "outputs": [] }, { "stateMutability": "payable", "type": "function", - "inputs": [ - { - "name": "_to", - "internalType": "address", - "type": "address" - }, - { - "name": "_minGasLimit", - "internalType": "uint32", - "type": "uint32" - }, - { - "name": "_extraData", - "internalType": "bytes", - "type": "bytes" - } - ], - "name": "bridgeETHTo", + "inputs": [], + "name": "donateETH", "outputs": [] }, - { - "stateMutability": "view", - "type": "function", - "inputs": [ - { - "name": "", - "internalType": "address", - "type": "address" - }, - { - "name": "", - "internalType": "address", - "type": "address" - } - ], - "name": "deposits", - "outputs": [ - { - "name": "", - "internalType": "uint256", - "type": "uint256" - } - ] - }, { "stateMutability": "nonpayable", "type": "function", "inputs": [ { - "name": "_localToken", - "internalType": "address", - "type": "address" - }, - { - "name": "_remoteToken", - "internalType": "address", - "type": "address" - }, - { - "name": "_from", - "internalType": "address", - "type": "address" - }, - { - "name": "_to", - "internalType": "address", - "type": "address" - }, - { - "name": "_amount", - "internalType": "uint256", - "type": "uint256" - }, - { - "name": "_extraData", - "internalType": "bytes", - "type": "bytes" - } - ], - "name": "finalizeBridgeERC20", - "outputs": [] - }, - { - "stateMutability": "payable", - "type": "function", - "inputs": [ - { - "name": "_from", - "internalType": "address", - "type": "address" - }, - { - "name": "_to", - "internalType": "address", - "type": "address" - }, - { - "name": "_amount", - "internalType": "uint256", - "type": "uint256" - }, - { - "name": "_extraData", - "internalType": "bytes", - "type": "bytes" - } - ], - "name": "finalizeBridgeETH", - "outputs": [] - }, - { - "stateMutability": "payable", - "type": "function", - "inputs": [ - { - "name": "_l1Token", - "internalType": "address", - "type": "address" - }, - { - "name": "_l2Token", - "internalType": "address", - "type": "address" - }, - { - "name": "_from", - "internalType": "address", - "type": "address" - }, - { - "name": "_to", - "internalType": "address", - "type": "address" - }, - { - "name": "_amount", - "internalType": "uint256", - "type": "uint256" - }, - { - "name": "_extraData", - "internalType": "bytes", - "type": "bytes" - } - ], - "name": "finalizeDeposit", - "outputs": [] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "l1TokenBridge", - "outputs": [ - { - "name": "", - "internalType": "address", - "type": "address" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "messenger", - "outputs": [ - { - "name": "", - "internalType": "contract CrossDomainMessenger", - "type": "address" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "version", - "outputs": [ - { - "name": "", - "internalType": "string", - "type": "string" - } - ] - }, - { - "stateMutability": "payable", - "type": "function", - "inputs": [ - { - "name": "_l2Token", - "internalType": "address", - "type": "address" - }, - { - "name": "_amount", - "internalType": "uint256", - "type": "uint256" - }, - { - "name": "_minGasLimit", - "internalType": "uint32", - "type": "uint32" - }, - { - "name": "_extraData", - "internalType": "bytes", - "type": "bytes" - } - ], - "name": "withdraw", - "outputs": [] - }, - { - "stateMutability": "payable", - "type": "function", - "inputs": [ - { - "name": "_l2Token", - "internalType": "address", - "type": "address" - }, - { - "name": "_to", - "internalType": "address", - "type": "address" - }, - { - "name": "_amount", - "internalType": "uint256", - "type": "uint256" - }, - { - "name": "_minGasLimit", - "internalType": "uint32", - "type": "uint32" - }, - { - "name": "_extraData", - "internalType": "bytes", - "type": "bytes" - } - ], - "name": "withdrawTo", - "outputs": [] - }, - { - "stateMutability": "payable", - "type": "receive" - } - ], - "L2ToL1MessagePasser": [ - { - "stateMutability": "nonpayable", - "type": "constructor", - "inputs": [] - }, - { - "type": "event", - "anonymous": false, - "inputs": [ - { - "name": "nonce", - "internalType": "uint256", - "type": "uint256", - "indexed": true - }, - { - "name": "sender", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "target", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "value", - "internalType": "uint256", - "type": "uint256", - "indexed": false - }, - { - "name": "gasLimit", - "internalType": "uint256", - "type": "uint256", - "indexed": false - }, - { - "name": "data", - "internalType": "bytes", - "type": "bytes", - "indexed": false - }, - { - "name": "withdrawalHash", - "internalType": "bytes32", - "type": "bytes32", - "indexed": false - } - ], - "name": "MessagePassed" - }, - { - "type": "event", - "anonymous": false, - "inputs": [ - { - "name": "amount", - "internalType": "uint256", - "type": "uint256", - "indexed": true - } - ], - "name": "WithdrawerBalanceBurnt" - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "MESSAGE_VERSION", - "outputs": [ - { - "name": "", - "internalType": "uint16", - "type": "uint16" - } - ] - }, - { - "stateMutability": "nonpayable", - "type": "function", - "inputs": [], - "name": "burn", - "outputs": [] - }, - { - "stateMutability": "payable", - "type": "function", - "inputs": [ - { - "name": "_target", - "internalType": "address", - "type": "address" - }, - { - "name": "_gasLimit", - "internalType": "uint256", - "type": "uint256" - }, - { - "name": "_data", - "internalType": "bytes", - "type": "bytes" - } - ], - "name": "initiateWithdrawal", - "outputs": [] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "messageNonce", - "outputs": [ - { - "name": "", - "internalType": "uint256", - "type": "uint256" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [ - { - "name": "", - "internalType": "bytes32", - "type": "bytes32" - } - ], - "name": "sentMessages", - "outputs": [ - { - "name": "", - "internalType": "bool", - "type": "bool" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "version", - "outputs": [ - { - "name": "", - "internalType": "string", - "type": "string" - } - ] - }, - { - "stateMutability": "payable", - "type": "receive" - } - ], - "MintManager": [ - { - "stateMutability": "nonpayable", - "type": "constructor", - "inputs": [ - { - "name": "_upgrader", - "internalType": "address", - "type": "address" - }, - { - "name": "_governanceToken", - "internalType": "address", - "type": "address" - } - ] - }, - { - "type": "event", - "anonymous": false, - "inputs": [ - { - "name": "previousOwner", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "newOwner", - "internalType": "address", - "type": "address", - "indexed": true - } - ], - "name": "OwnershipTransferred" - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "DENOMINATOR", - "outputs": [ - { - "name": "", - "internalType": "uint256", - "type": "uint256" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "MINT_CAP", - "outputs": [ - { - "name": "", - "internalType": "uint256", - "type": "uint256" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "MINT_PERIOD", - "outputs": [ - { - "name": "", - "internalType": "uint256", - "type": "uint256" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "governanceToken", - "outputs": [ - { - "name": "", - "internalType": "contract GovernanceToken", - "type": "address" - } - ] - }, - { - "stateMutability": "nonpayable", - "type": "function", - "inputs": [ - { - "name": "_account", - "internalType": "address", - "type": "address" - }, - { - "name": "_amount", - "internalType": "uint256", - "type": "uint256" - } - ], - "name": "mint", - "outputs": [] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "mintPermittedAfter", - "outputs": [ - { - "name": "", - "internalType": "uint256", - "type": "uint256" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "owner", - "outputs": [ - { - "name": "", - "internalType": "address", - "type": "address" - } - ] - }, - { - "stateMutability": "nonpayable", - "type": "function", - "inputs": [], - "name": "renounceOwnership", - "outputs": [] - }, - { - "stateMutability": "nonpayable", - "type": "function", - "inputs": [ - { - "name": "newOwner", - "internalType": "address", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [] - }, - { - "stateMutability": "nonpayable", - "type": "function", - "inputs": [ - { - "name": "_newMintManager", - "internalType": "address", - "type": "address" - } - ], - "name": "upgrade", - "outputs": [] - } - ], - "OptimismMintableERC20Factory": [ - { - "stateMutability": "nonpayable", - "type": "constructor", - "inputs": [ - { - "name": "_bridge", - "internalType": "address", - "type": "address" - } - ] - }, - { - "type": "event", - "anonymous": false, - "inputs": [ - { - "name": "localToken", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "remoteToken", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "deployer", - "internalType": "address", - "type": "address", - "indexed": false - } - ], - "name": "OptimismMintableERC20Created" - }, - { - "type": "event", - "anonymous": false, - "inputs": [ - { - "name": "remoteToken", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "localToken", - "internalType": "address", - "type": "address", - "indexed": true - } - ], - "name": "StandardL2TokenCreated" - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "BRIDGE", - "outputs": [ - { - "name": "", - "internalType": "address", - "type": "address" - } - ] - }, - { - "stateMutability": "nonpayable", - "type": "function", - "inputs": [ - { - "name": "_remoteToken", - "internalType": "address", - "type": "address" - }, - { - "name": "_name", - "internalType": "string", - "type": "string" - }, - { - "name": "_symbol", - "internalType": "string", - "type": "string" - } - ], - "name": "createOptimismMintableERC20", - "outputs": [ - { - "name": "", - "internalType": "address", - "type": "address" - } - ] - }, - { - "stateMutability": "nonpayable", - "type": "function", - "inputs": [ - { - "name": "_remoteToken", - "internalType": "address", - "type": "address" - }, - { - "name": "_name", - "internalType": "string", - "type": "string" - }, - { - "name": "_symbol", - "internalType": "string", - "type": "string" - } - ], - "name": "createStandardL2Token", - "outputs": [ - { - "name": "", - "internalType": "address", - "type": "address" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "version", - "outputs": [ - { - "name": "", - "internalType": "string", - "type": "string" - } - ] - } - ], - "OptimismMintableERC20Factory_goerli": [ - { - "stateMutability": "nonpayable", - "type": "constructor", - "inputs": [] - }, - { - "type": "event", - "anonymous": false, - "inputs": [ - { - "name": "version", - "internalType": "uint8", - "type": "uint8", - "indexed": false - } - ], - "name": "Initialized" - }, - { - "type": "event", - "anonymous": false, - "inputs": [ - { - "name": "localToken", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "remoteToken", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "deployer", - "internalType": "address", - "type": "address", - "indexed": false - } - ], - "name": "OptimismMintableERC20Created" - }, - { - "type": "event", - "anonymous": false, - "inputs": [ - { - "name": "remoteToken", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "localToken", - "internalType": "address", - "type": "address", - "indexed": true - } - ], - "name": "StandardL2TokenCreated" - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "BRIDGE", - "outputs": [ - { - "name": "", - "internalType": "address", - "type": "address" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "bridge", - "outputs": [ - { - "name": "", - "internalType": "address", - "type": "address" - } - ] - }, - { - "stateMutability": "nonpayable", - "type": "function", - "inputs": [ - { - "name": "_remoteToken", - "internalType": "address", - "type": "address" - }, - { - "name": "_name", - "internalType": "string", - "type": "string" - }, - { - "name": "_symbol", - "internalType": "string", - "type": "string" - } - ], - "name": "createOptimismMintableERC20", - "outputs": [ - { - "name": "", - "internalType": "address", - "type": "address" - } - ] - }, - { - "stateMutability": "nonpayable", - "type": "function", - "inputs": [ - { - "name": "_remoteToken", - "internalType": "address", - "type": "address" - }, - { - "name": "_name", - "internalType": "string", - "type": "string" - }, - { - "name": "_symbol", - "internalType": "string", - "type": "string" - }, - { - "name": "_decimals", - "internalType": "uint8", - "type": "uint8" - } - ], - "name": "createOptimismMintableERC20WithDecimals", - "outputs": [ - { - "name": "", - "internalType": "address", - "type": "address" - } - ] - }, - { - "stateMutability": "nonpayable", - "type": "function", - "inputs": [ - { - "name": "_remoteToken", - "internalType": "address", - "type": "address" - }, - { - "name": "_name", - "internalType": "string", - "type": "string" - }, - { - "name": "_symbol", - "internalType": "string", - "type": "string" - } - ], - "name": "createStandardL2Token", - "outputs": [ - { - "name": "", - "internalType": "address", - "type": "address" - } - ] - }, - { - "stateMutability": "nonpayable", - "type": "function", - "inputs": [ - { - "name": "_bridge", - "internalType": "address", - "type": "address" - } - ], - "name": "initialize", - "outputs": [] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "version", - "outputs": [ - { - "name": "", - "internalType": "string", - "type": "string" - } - ] - } - ], - "OptimismMintableERC20Factory_optimism-goerli": [ - { - "stateMutability": "nonpayable", - "type": "constructor", - "inputs": [ - { - "name": "_bridge", - "internalType": "address", - "type": "address" - } - ] - }, - { - "type": "event", - "anonymous": false, - "inputs": [ - { - "name": "localToken", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "remoteToken", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "deployer", - "internalType": "address", - "type": "address", - "indexed": false - } - ], - "name": "OptimismMintableERC20Created" - }, - { - "type": "event", - "anonymous": false, - "inputs": [ - { - "name": "remoteToken", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "localToken", - "internalType": "address", - "type": "address", - "indexed": true - } - ], - "name": "StandardL2TokenCreated" - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "BRIDGE", - "outputs": [ - { - "name": "", - "internalType": "address", - "type": "address" - } - ] - }, - { - "stateMutability": "nonpayable", - "type": "function", - "inputs": [ - { - "name": "_remoteToken", - "internalType": "address", - "type": "address" - }, - { - "name": "_name", - "internalType": "string", - "type": "string" - }, - { - "name": "_symbol", - "internalType": "string", - "type": "string" - } - ], - "name": "createOptimismMintableERC20", - "outputs": [ - { - "name": "", - "internalType": "address", - "type": "address" - } - ] - }, - { - "stateMutability": "nonpayable", - "type": "function", - "inputs": [ - { - "name": "_remoteToken", - "internalType": "address", - "type": "address" - }, - { - "name": "_name", - "internalType": "string", - "type": "string" - }, - { - "name": "_symbol", - "internalType": "string", - "type": "string" - } - ], - "name": "createStandardL2Token", - "outputs": [ - { - "name": "", - "internalType": "address", - "type": "address" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "version", - "outputs": [ - { - "name": "", - "internalType": "string", - "type": "string" - } - ] - } - ], - "OptimismMintableERC721Factory": [ - { - "stateMutability": "nonpayable", - "type": "constructor", - "inputs": [ - { - "name": "_bridge", - "internalType": "address", - "type": "address" - }, - { - "name": "_remoteChainId", - "internalType": "uint256", - "type": "uint256" - } - ] - }, - { - "type": "event", - "anonymous": false, - "inputs": [ - { - "name": "localToken", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "remoteToken", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "deployer", - "internalType": "address", - "type": "address", - "indexed": false - } - ], - "name": "OptimismMintableERC721Created" - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "bridge", - "outputs": [ - { - "name": "", - "internalType": "address", - "type": "address" - } - ] - }, - { - "stateMutability": "nonpayable", - "type": "function", - "inputs": [ - { - "name": "_remoteToken", - "internalType": "address", - "type": "address" - }, - { - "name": "_name", - "internalType": "string", - "type": "string" - }, - { - "name": "_symbol", - "internalType": "string", - "type": "string" - } - ], - "name": "createOptimismMintableERC721", - "outputs": [ - { - "name": "", - "internalType": "address", - "type": "address" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [ - { - "name": "", - "internalType": "address", - "type": "address" - } - ], - "name": "isOptimismMintableERC721", - "outputs": [ - { - "name": "", - "internalType": "bool", - "type": "bool" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "remoteChainId", - "outputs": [ - { - "name": "", - "internalType": "uint256", - "type": "uint256" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "version", - "outputs": [ - { - "name": "", - "internalType": "string", - "type": "string" - } - ] - } - ], - "OptimismMintableERC721Factory_optimism-goerli": [ - { - "stateMutability": "nonpayable", - "type": "constructor", - "inputs": [ - { - "name": "_bridge", - "internalType": "address", - "type": "address" - }, - { - "name": "_remoteChainId", - "internalType": "uint256", - "type": "uint256" - } - ] - }, - { - "type": "event", - "anonymous": false, - "inputs": [ - { - "name": "localToken", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "remoteToken", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "deployer", - "internalType": "address", - "type": "address", - "indexed": false - } - ], - "name": "OptimismMintableERC721Created" - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "BRIDGE", - "outputs": [ - { - "name": "", - "internalType": "address", - "type": "address" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "REMOTE_CHAIN_ID", - "outputs": [ - { - "name": "", - "internalType": "uint256", - "type": "uint256" - } - ] - }, - { - "stateMutability": "nonpayable", - "type": "function", - "inputs": [ - { - "name": "_remoteToken", - "internalType": "address", - "type": "address" - }, - { - "name": "_name", - "internalType": "string", - "type": "string" - }, - { - "name": "_symbol", - "internalType": "string", - "type": "string" - } - ], - "name": "createOptimismMintableERC721", - "outputs": [ - { - "name": "", - "internalType": "address", - "type": "address" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [ - { - "name": "", - "internalType": "address", - "type": "address" - } - ], - "name": "isOptimismMintableERC721", - "outputs": [ - { - "name": "", - "internalType": "bool", - "type": "bool" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "version", - "outputs": [ - { - "name": "", - "internalType": "string", - "type": "string" - } - ] - } - ], - "OptimismPortal": [ - { - "stateMutability": "nonpayable", - "type": "constructor", - "inputs": [ - { - "name": "_l2Oracle", - "internalType": "contract L2OutputOracle", - "type": "address" - }, - { - "name": "_guardian", - "internalType": "address", - "type": "address" - }, - { - "name": "_paused", - "internalType": "bool", - "type": "bool" - }, - { - "name": "_config", - "internalType": "contract SystemConfig", - "type": "address" - } - ] - }, - { - "type": "event", - "anonymous": false, - "inputs": [ - { - "name": "version", - "internalType": "uint8", - "type": "uint8", - "indexed": false - } - ], - "name": "Initialized" - }, - { - "type": "event", - "anonymous": false, - "inputs": [ - { - "name": "account", - "internalType": "address", - "type": "address", - "indexed": false - } - ], - "name": "Paused" - }, - { - "type": "event", - "anonymous": false, - "inputs": [ - { - "name": "from", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "to", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "version", - "internalType": "uint256", - "type": "uint256", - "indexed": true - }, - { - "name": "opaqueData", - "internalType": "bytes", - "type": "bytes", - "indexed": false - } - ], - "name": "TransactionDeposited" - }, - { - "type": "event", - "anonymous": false, - "inputs": [ - { - "name": "account", - "internalType": "address", - "type": "address", - "indexed": false - } - ], - "name": "Unpaused" - }, - { - "type": "event", - "anonymous": false, - "inputs": [ - { - "name": "withdrawalHash", - "internalType": "bytes32", - "type": "bytes32", - "indexed": true - }, - { - "name": "success", - "internalType": "bool", - "type": "bool", - "indexed": false - } - ], - "name": "WithdrawalFinalized" - }, - { - "type": "event", - "anonymous": false, - "inputs": [ - { - "name": "withdrawalHash", - "internalType": "bytes32", - "type": "bytes32", - "indexed": true - }, - { - "name": "from", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "to", - "internalType": "address", - "type": "address", - "indexed": true - } - ], - "name": "WithdrawalProven" - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "GUARDIAN", - "outputs": [ - { - "name": "", - "internalType": "address", - "type": "address" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "L2_ORACLE", - "outputs": [ - { - "name": "", - "internalType": "contract L2OutputOracle", - "type": "address" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "SYSTEM_CONFIG", - "outputs": [ - { - "name": "", - "internalType": "contract SystemConfig", - "type": "address" - } - ] - }, - { - "stateMutability": "payable", - "type": "function", - "inputs": [ - { - "name": "_to", - "internalType": "address", - "type": "address" - }, - { - "name": "_value", - "internalType": "uint256", - "type": "uint256" - }, - { - "name": "_gasLimit", - "internalType": "uint64", - "type": "uint64" - }, - { - "name": "_isCreation", - "internalType": "bool", - "type": "bool" - }, - { - "name": "_data", - "internalType": "bytes", - "type": "bytes" - } - ], - "name": "depositTransaction", - "outputs": [] - }, - { - "stateMutability": "payable", - "type": "function", - "inputs": [], - "name": "donateETH", - "outputs": [] - }, - { - "stateMutability": "nonpayable", - "type": "function", - "inputs": [ - { - "name": "_tx", - "internalType": "struct Types.WithdrawalTransaction", - "type": "tuple", - "components": [ - { - "name": "nonce", - "internalType": "uint256", - "type": "uint256" - }, - { - "name": "sender", - "internalType": "address", - "type": "address" - }, - { - "name": "target", - "internalType": "address", - "type": "address" - }, - { - "name": "value", - "internalType": "uint256", - "type": "uint256" - }, - { - "name": "gasLimit", - "internalType": "uint256", - "type": "uint256" - }, - { - "name": "data", - "internalType": "bytes", - "type": "bytes" - } - ] - } - ], - "name": "finalizeWithdrawalTransaction", - "outputs": [] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [ - { - "name": "", - "internalType": "bytes32", - "type": "bytes32" - } - ], - "name": "finalizedWithdrawals", - "outputs": [ - { - "name": "", - "internalType": "bool", - "type": "bool" - } - ] - }, - { - "stateMutability": "nonpayable", - "type": "function", - "inputs": [ - { - "name": "_paused", - "internalType": "bool", - "type": "bool" - } - ], - "name": "initialize", - "outputs": [] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [ - { - "name": "_l2OutputIndex", - "internalType": "uint256", - "type": "uint256" - } - ], - "name": "isOutputFinalized", - "outputs": [ - { - "name": "", - "internalType": "bool", - "type": "bool" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "l2Sender", - "outputs": [ - { - "name": "", - "internalType": "address", - "type": "address" - } - ] - }, - { - "stateMutability": "pure", - "type": "function", - "inputs": [ - { - "name": "_byteCount", - "internalType": "uint64", - "type": "uint64" - } - ], - "name": "minimumGasLimit", - "outputs": [ - { - "name": "", - "internalType": "uint64", - "type": "uint64" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "params", - "outputs": [ - { - "name": "prevBaseFee", - "internalType": "uint128", - "type": "uint128" - }, - { - "name": "prevBoughtGas", - "internalType": "uint64", - "type": "uint64" - }, - { - "name": "prevBlockNum", - "internalType": "uint64", - "type": "uint64" - } - ] - }, - { - "stateMutability": "nonpayable", - "type": "function", - "inputs": [], - "name": "pause", - "outputs": [] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "paused", - "outputs": [ - { - "name": "", - "internalType": "bool", - "type": "bool" - } - ] - }, - { - "stateMutability": "nonpayable", - "type": "function", - "inputs": [ - { - "name": "_tx", - "internalType": "struct Types.WithdrawalTransaction", - "type": "tuple", - "components": [ - { - "name": "nonce", - "internalType": "uint256", - "type": "uint256" - }, - { - "name": "sender", - "internalType": "address", - "type": "address" - }, - { - "name": "target", - "internalType": "address", - "type": "address" - }, - { - "name": "value", - "internalType": "uint256", - "type": "uint256" - }, - { - "name": "gasLimit", - "internalType": "uint256", - "type": "uint256" - }, - { - "name": "data", - "internalType": "bytes", - "type": "bytes" - } - ] - }, - { - "name": "_l2OutputIndex", - "internalType": "uint256", - "type": "uint256" - }, - { - "name": "_outputRootProof", - "internalType": "struct Types.OutputRootProof", - "type": "tuple", - "components": [ - { - "name": "version", - "internalType": "bytes32", - "type": "bytes32" - }, - { - "name": "stateRoot", - "internalType": "bytes32", - "type": "bytes32" - }, - { - "name": "messagePasserStorageRoot", - "internalType": "bytes32", - "type": "bytes32" - }, - { - "name": "latestBlockhash", - "internalType": "bytes32", - "type": "bytes32" - } - ] - }, - { - "name": "_withdrawalProof", - "internalType": "bytes[]", - "type": "bytes[]" - } - ], - "name": "proveWithdrawalTransaction", - "outputs": [] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [ - { - "name": "", - "internalType": "bytes32", - "type": "bytes32" - } - ], - "name": "provenWithdrawals", - "outputs": [ - { - "name": "outputRoot", - "internalType": "bytes32", - "type": "bytes32" - }, - { - "name": "timestamp", - "internalType": "uint128", - "type": "uint128" - }, - { - "name": "l2OutputIndex", - "internalType": "uint128", - "type": "uint128" - } - ] - }, - { - "stateMutability": "nonpayable", - "type": "function", - "inputs": [], - "name": "unpause", - "outputs": [] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "version", - "outputs": [ - { - "name": "", - "internalType": "string", - "type": "string" - } - ] - }, - { - "stateMutability": "payable", - "type": "receive" - } - ], - "OptimismPortal_goerli": [ - { - "stateMutability": "nonpayable", - "type": "constructor", - "inputs": [] - }, - { - "type": "event", - "anonymous": false, - "inputs": [ - { - "name": "version", - "internalType": "uint8", - "type": "uint8", - "indexed": false - } - ], - "name": "Initialized" - }, - { - "type": "event", - "anonymous": false, - "inputs": [ - { - "name": "account", - "internalType": "address", - "type": "address", - "indexed": false - } - ], - "name": "Paused" - }, - { - "type": "event", - "anonymous": false, - "inputs": [ - { - "name": "from", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "to", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "version", - "internalType": "uint256", - "type": "uint256", - "indexed": true - }, - { - "name": "opaqueData", - "internalType": "bytes", - "type": "bytes", - "indexed": false - } - ], - "name": "TransactionDeposited" - }, - { - "type": "event", - "anonymous": false, - "inputs": [ - { - "name": "account", - "internalType": "address", - "type": "address", - "indexed": false - } - ], - "name": "Unpaused" - }, - { - "type": "event", - "anonymous": false, - "inputs": [ - { - "name": "withdrawalHash", - "internalType": "bytes32", - "type": "bytes32", - "indexed": true - }, - { - "name": "success", - "internalType": "bool", - "type": "bool", - "indexed": false - } - ], - "name": "WithdrawalFinalized" - }, - { - "type": "event", - "anonymous": false, - "inputs": [ - { - "name": "withdrawalHash", - "internalType": "bytes32", - "type": "bytes32", - "indexed": true - }, - { - "name": "from", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "to", - "internalType": "address", - "type": "address", - "indexed": true - } - ], - "name": "WithdrawalProven" - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "GUARDIAN", - "outputs": [ - { - "name": "", - "internalType": "address", - "type": "address" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "L2_ORACLE", - "outputs": [ - { - "name": "", - "internalType": "contract L2OutputOracle", - "type": "address" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "SYSTEM_CONFIG", - "outputs": [ - { - "name": "", - "internalType": "contract SystemConfig", - "type": "address" - } - ] - }, - { - "stateMutability": "payable", - "type": "function", - "inputs": [ - { - "name": "_to", - "internalType": "address", - "type": "address" - }, - { - "name": "_value", - "internalType": "uint256", - "type": "uint256" - }, - { - "name": "_gasLimit", - "internalType": "uint64", - "type": "uint64" - }, - { - "name": "_isCreation", - "internalType": "bool", - "type": "bool" - }, - { - "name": "_data", - "internalType": "bytes", - "type": "bytes" - } - ], - "name": "depositTransaction", - "outputs": [] - }, - { - "stateMutability": "payable", - "type": "function", - "inputs": [], - "name": "donateETH", - "outputs": [] - }, - { - "stateMutability": "nonpayable", - "type": "function", - "inputs": [ - { - "name": "_tx", - "internalType": "struct Types.WithdrawalTransaction", - "type": "tuple", - "components": [ - { - "name": "nonce", - "internalType": "uint256", - "type": "uint256" - }, - { - "name": "sender", - "internalType": "address", - "type": "address" - }, - { - "name": "target", - "internalType": "address", - "type": "address" - }, - { - "name": "value", - "internalType": "uint256", - "type": "uint256" - }, - { - "name": "gasLimit", - "internalType": "uint256", - "type": "uint256" - }, - { - "name": "data", - "internalType": "bytes", - "type": "bytes" - } - ] - } - ], - "name": "finalizeWithdrawalTransaction", - "outputs": [] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [ - { - "name": "", - "internalType": "bytes32", - "type": "bytes32" - } - ], - "name": "finalizedWithdrawals", - "outputs": [ - { - "name": "", - "internalType": "bool", - "type": "bool" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "guardian", - "outputs": [ - { - "name": "", - "internalType": "address", - "type": "address" - } - ] - }, - { - "stateMutability": "nonpayable", - "type": "function", - "inputs": [ - { - "name": "_l2Oracle", - "internalType": "contract L2OutputOracle", - "type": "address" - }, - { - "name": "_guardian", - "internalType": "address", - "type": "address" - }, - { - "name": "_systemConfig", - "internalType": "contract SystemConfig", - "type": "address" - }, - { - "name": "_paused", - "internalType": "bool", - "type": "bool" - } - ], - "name": "initialize", - "outputs": [] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [ - { - "name": "_l2OutputIndex", - "internalType": "uint256", - "type": "uint256" - } - ], - "name": "isOutputFinalized", - "outputs": [ - { - "name": "", - "internalType": "bool", - "type": "bool" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "l2Oracle", - "outputs": [ - { - "name": "", - "internalType": "contract L2OutputOracle", - "type": "address" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "l2Sender", - "outputs": [ - { - "name": "", - "internalType": "address", - "type": "address" - } - ] - }, - { - "stateMutability": "pure", - "type": "function", - "inputs": [ - { - "name": "_byteCount", - "internalType": "uint64", - "type": "uint64" - } - ], - "name": "minimumGasLimit", - "outputs": [ - { - "name": "", - "internalType": "uint64", - "type": "uint64" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "params", - "outputs": [ - { - "name": "prevBaseFee", - "internalType": "uint128", - "type": "uint128" - }, - { - "name": "prevBoughtGas", - "internalType": "uint64", - "type": "uint64" - }, - { - "name": "prevBlockNum", - "internalType": "uint64", - "type": "uint64" - } - ] - }, - { - "stateMutability": "nonpayable", - "type": "function", - "inputs": [], - "name": "pause", - "outputs": [] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "paused", - "outputs": [ - { - "name": "", - "internalType": "bool", - "type": "bool" - } - ] - }, - { - "stateMutability": "nonpayable", - "type": "function", - "inputs": [ - { - "name": "_tx", - "internalType": "struct Types.WithdrawalTransaction", - "type": "tuple", - "components": [ - { - "name": "nonce", - "internalType": "uint256", - "type": "uint256" - }, - { - "name": "sender", - "internalType": "address", - "type": "address" - }, - { - "name": "target", - "internalType": "address", - "type": "address" - }, - { - "name": "value", - "internalType": "uint256", - "type": "uint256" - }, - { - "name": "gasLimit", - "internalType": "uint256", - "type": "uint256" - }, - { - "name": "data", - "internalType": "bytes", - "type": "bytes" - } - ] - }, - { - "name": "_l2OutputIndex", - "internalType": "uint256", - "type": "uint256" - }, - { - "name": "_outputRootProof", - "internalType": "struct Types.OutputRootProof", - "type": "tuple", - "components": [ - { - "name": "version", - "internalType": "bytes32", - "type": "bytes32" - }, - { - "name": "stateRoot", - "internalType": "bytes32", - "type": "bytes32" - }, - { - "name": "messagePasserStorageRoot", - "internalType": "bytes32", - "type": "bytes32" - }, - { - "name": "latestBlockhash", - "internalType": "bytes32", - "type": "bytes32" - } - ] - }, - { - "name": "_withdrawalProof", - "internalType": "bytes[]", - "type": "bytes[]" - } - ], - "name": "proveWithdrawalTransaction", - "outputs": [] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [ - { - "name": "", - "internalType": "bytes32", - "type": "bytes32" - } - ], - "name": "provenWithdrawals", - "outputs": [ - { - "name": "outputRoot", - "internalType": "bytes32", - "type": "bytes32" - }, - { - "name": "timestamp", - "internalType": "uint128", - "type": "uint128" - }, - { - "name": "l2OutputIndex", - "internalType": "uint128", - "type": "uint128" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "systemConfig", - "outputs": [ - { - "name": "", - "internalType": "contract SystemConfig", - "type": "address" - } - ] - }, - { - "stateMutability": "nonpayable", - "type": "function", - "inputs": [], - "name": "unpause", - "outputs": [] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "version", - "outputs": [ - { - "name": "", - "internalType": "string", - "type": "string" - } - ] - }, - { - "stateMutability": "payable", - "type": "receive" - } - ], - "Optimist": [ - { - "stateMutability": "nonpayable", - "type": "constructor", - "inputs": [ - { - "name": "_name", - "internalType": "string", - "type": "string" - }, - { - "name": "_symbol", - "internalType": "string", - "type": "string" - }, - { - "name": "_baseURIAttestor", - "internalType": "address", - "type": "address" - }, - { - "name": "_attestationStation", - "internalType": "contract AttestationStation", - "type": "address" - }, - { - "name": "_optimistAllowlist", - "internalType": "contract OptimistAllowlist", - "type": "address" - } - ] - }, - { - "type": "event", - "anonymous": false, - "inputs": [ - { - "name": "owner", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "approved", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "tokenId", - "internalType": "uint256", - "type": "uint256", - "indexed": true - } - ], - "name": "Approval" - }, - { - "type": "event", - "anonymous": false, - "inputs": [ - { - "name": "owner", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "operator", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "approved", - "internalType": "bool", - "type": "bool", - "indexed": false - } - ], - "name": "ApprovalForAll" - }, - { - "type": "event", - "anonymous": false, - "inputs": [ - { - "name": "version", - "internalType": "uint8", - "type": "uint8", - "indexed": false - } - ], - "name": "Initialized" - }, - { - "type": "event", - "anonymous": false, - "inputs": [ - { - "name": "from", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "to", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "tokenId", - "internalType": "uint256", - "type": "uint256", - "indexed": true - } - ], - "name": "Transfer" - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "ATTESTATION_STATION", - "outputs": [ - { - "name": "", - "internalType": "contract AttestationStation", - "type": "address" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "BASE_URI_ATTESTATION_KEY", - "outputs": [ - { - "name": "", - "internalType": "bytes32", - "type": "bytes32" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "BASE_URI_ATTESTOR", - "outputs": [ - { - "name": "", - "internalType": "address", - "type": "address" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "OPTIMIST_ALLOWLIST", - "outputs": [ - { - "name": "", - "internalType": "contract OptimistAllowlist", - "type": "address" - } - ] - }, - { - "stateMutability": "pure", - "type": "function", - "inputs": [ - { - "name": "", - "internalType": "address", - "type": "address" - }, - { - "name": "", - "internalType": "uint256", - "type": "uint256" - } - ], - "name": "approve", - "outputs": [] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [ - { - "name": "owner", - "internalType": "address", - "type": "address" - } - ], - "name": "balanceOf", - "outputs": [ - { - "name": "", - "internalType": "uint256", - "type": "uint256" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "baseURI", - "outputs": [ - { - "name": "", - "internalType": "string", - "type": "string" - } - ] - }, - { - "stateMutability": "nonpayable", - "type": "function", - "inputs": [ - { - "name": "tokenId", - "internalType": "uint256", - "type": "uint256" - } - ], - "name": "burn", - "outputs": [] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [ - { - "name": "tokenId", - "internalType": "uint256", - "type": "uint256" - } - ], - "name": "getApproved", - "outputs": [ - { - "name": "", - "internalType": "address", - "type": "address" - } - ] - }, - { - "stateMutability": "nonpayable", - "type": "function", - "inputs": [ - { - "name": "_name", - "internalType": "string", - "type": "string" - }, - { - "name": "_symbol", - "internalType": "string", - "type": "string" - } - ], - "name": "initialize", - "outputs": [] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [ - { - "name": "owner", - "internalType": "address", - "type": "address" - }, - { - "name": "operator", - "internalType": "address", - "type": "address" - } - ], - "name": "isApprovedForAll", - "outputs": [ - { - "name": "", - "internalType": "bool", - "type": "bool" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [ - { - "name": "_recipient", - "internalType": "address", - "type": "address" - } - ], - "name": "isOnAllowList", - "outputs": [ - { - "name": "", - "internalType": "bool", - "type": "bool" - } - ] - }, - { - "stateMutability": "nonpayable", - "type": "function", - "inputs": [ - { - "name": "_recipient", - "internalType": "address", - "type": "address" - } - ], - "name": "mint", - "outputs": [] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "name", - "outputs": [ - { - "name": "", - "internalType": "string", - "type": "string" + "name": "_tx", + "internalType": "struct Types.WithdrawalTransaction", + "type": "tuple", + "components": [ + { + "name": "nonce", + "internalType": "uint256", + "type": "uint256" + }, + { + "name": "sender", + "internalType": "address", + "type": "address" + }, + { + "name": "target", + "internalType": "address", + "type": "address" + }, + { + "name": "value", + "internalType": "uint256", + "type": "uint256" + }, + { + "name": "gasLimit", + "internalType": "uint256", + "type": "uint256" + }, + { + "name": "data", + "internalType": "bytes", + "type": "bytes" + } + ] } - ] + ], + "name": "finalizeWithdrawalTransaction", + "outputs": [] }, { "stateMutability": "view", "type": "function", "inputs": [ { - "name": "tokenId", - "internalType": "uint256", - "type": "uint256" + "name": "", + "internalType": "bytes32", + "type": "bytes32" } ], - "name": "ownerOf", + "name": "finalizedWithdrawals", "outputs": [ { "name": "", - "internalType": "address", - "type": "address" + "internalType": "bool", + "type": "bool" } ] }, { - "stateMutability": "nonpayable", + "stateMutability": "view", "type": "function", - "inputs": [ - { - "name": "from", - "internalType": "address", - "type": "address" - }, + "inputs": [], + "name": "guardian", + "outputs": [ { - "name": "to", + "name": "", "internalType": "address", "type": "address" - }, - { - "name": "tokenId", - "internalType": "uint256", - "type": "uint256" } - ], - "name": "safeTransferFrom", - "outputs": [] + ] }, { "stateMutability": "nonpayable", "type": "function", "inputs": [ { - "name": "from", - "internalType": "address", + "name": "_l2Oracle", + "internalType": "contract L2OutputOracle", "type": "address" }, { - "name": "to", + "name": "_guardian", "internalType": "address", "type": "address" }, { - "name": "tokenId", - "internalType": "uint256", - "type": "uint256" - }, - { - "name": "data", - "internalType": "bytes", - "type": "bytes" - } - ], - "name": "safeTransferFrom", - "outputs": [] - }, - { - "stateMutability": "nonpayable", - "type": "function", - "inputs": [ - { - "name": "", - "internalType": "address", + "name": "_systemConfig", + "internalType": "contract SystemConfig", "type": "address" }, { - "name": "", + "name": "_paused", "internalType": "bool", "type": "bool" } ], - "name": "setApprovalForAll", + "name": "initialize", "outputs": [] }, { @@ -12303,12 +9255,12 @@ "type": "function", "inputs": [ { - "name": "interfaceId", - "internalType": "bytes4", - "type": "bytes4" + "name": "_l2OutputIndex", + "internalType": "uint256", + "type": "uint256" } ], - "name": "supportsInterface", + "name": "isOutputFinalized", "outputs": [ { "name": "", @@ -12321,179 +9273,198 @@ "stateMutability": "view", "type": "function", "inputs": [], - "name": "symbol", + "name": "l2Oracle", "outputs": [ { "name": "", - "internalType": "string", - "type": "string" + "internalType": "contract L2OutputOracle", + "type": "address" } ] }, { - "stateMutability": "pure", + "stateMutability": "view", "type": "function", - "inputs": [ - { - "name": "_owner", - "internalType": "address", - "type": "address" - } - ], - "name": "tokenIdOfAddress", + "inputs": [], + "name": "l2Sender", "outputs": [ { "name": "", - "internalType": "uint256", - "type": "uint256" + "internalType": "address", + "type": "address" } ] }, { - "stateMutability": "view", + "stateMutability": "pure", "type": "function", "inputs": [ { - "name": "_tokenId", - "internalType": "uint256", - "type": "uint256" + "name": "_byteCount", + "internalType": "uint64", + "type": "uint64" } ], - "name": "tokenURI", + "name": "minimumGasLimit", "outputs": [ { "name": "", - "internalType": "string", - "type": "string" + "internalType": "uint64", + "type": "uint64" } ] }, - { - "stateMutability": "nonpayable", - "type": "function", - "inputs": [ - { - "name": "from", - "internalType": "address", - "type": "address" - }, - { - "name": "to", - "internalType": "address", - "type": "address" - }, - { - "name": "tokenId", - "internalType": "uint256", - "type": "uint256" - } - ], - "name": "transferFrom", - "outputs": [] - }, { "stateMutability": "view", "type": "function", "inputs": [], - "name": "version", + "name": "params", "outputs": [ { - "name": "", - "internalType": "string", - "type": "string" - } - ] - } - ], - "OptimistAllowlist": [ - { - "stateMutability": "nonpayable", - "type": "constructor", - "inputs": [ - { - "name": "_attestationStation", - "internalType": "contract AttestationStation", - "type": "address" - }, - { - "name": "_allowlistAttestor", - "internalType": "address", - "type": "address" + "name": "prevBaseFee", + "internalType": "uint128", + "type": "uint128" }, { - "name": "_coinbaseQuestAttestor", - "internalType": "address", - "type": "address" + "name": "prevBoughtGas", + "internalType": "uint64", + "type": "uint64" }, { - "name": "_optimistInviter", - "internalType": "address", - "type": "address" + "name": "prevBlockNum", + "internalType": "uint64", + "type": "uint64" } ] }, { - "stateMutability": "view", + "stateMutability": "nonpayable", "type": "function", "inputs": [], - "name": "ALLOWLIST_ATTESTOR", - "outputs": [ - { - "name": "", - "internalType": "address", - "type": "address" - } - ] + "name": "pause", + "outputs": [] }, { "stateMutability": "view", "type": "function", "inputs": [], - "name": "ATTESTATION_STATION", + "name": "paused", "outputs": [ { "name": "", - "internalType": "contract AttestationStation", - "type": "address" + "internalType": "bool", + "type": "bool" } ] }, { - "stateMutability": "view", + "stateMutability": "nonpayable", "type": "function", - "inputs": [], - "name": "COINBASE_QUEST_ATTESTOR", - "outputs": [ + "inputs": [ + { + "name": "_tx", + "internalType": "struct Types.WithdrawalTransaction", + "type": "tuple", + "components": [ + { + "name": "nonce", + "internalType": "uint256", + "type": "uint256" + }, + { + "name": "sender", + "internalType": "address", + "type": "address" + }, + { + "name": "target", + "internalType": "address", + "type": "address" + }, + { + "name": "value", + "internalType": "uint256", + "type": "uint256" + }, + { + "name": "gasLimit", + "internalType": "uint256", + "type": "uint256" + }, + { + "name": "data", + "internalType": "bytes", + "type": "bytes" + } + ] + }, + { + "name": "_l2OutputIndex", + "internalType": "uint256", + "type": "uint256" + }, + { + "name": "_outputRootProof", + "internalType": "struct Types.OutputRootProof", + "type": "tuple", + "components": [ + { + "name": "version", + "internalType": "bytes32", + "type": "bytes32" + }, + { + "name": "stateRoot", + "internalType": "bytes32", + "type": "bytes32" + }, + { + "name": "messagePasserStorageRoot", + "internalType": "bytes32", + "type": "bytes32" + }, + { + "name": "latestBlockhash", + "internalType": "bytes32", + "type": "bytes32" + } + ] + }, { - "name": "", - "internalType": "address", - "type": "address" + "name": "_withdrawalProof", + "internalType": "bytes[]", + "type": "bytes[]" } - ] + ], + "name": "proveWithdrawalTransaction", + "outputs": [] }, { "stateMutability": "view", "type": "function", - "inputs": [], - "name": "COINBASE_QUEST_ELIGIBLE_ATTESTATION_KEY", - "outputs": [ + "inputs": [ { "name": "", "internalType": "bytes32", "type": "bytes32" } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "OPTIMIST_CAN_MINT_ATTESTATION_KEY", + ], + "name": "provenWithdrawals", "outputs": [ { - "name": "", + "name": "outputRoot", "internalType": "bytes32", "type": "bytes32" + }, + { + "name": "timestamp", + "internalType": "uint128", + "type": "uint128" + }, + { + "name": "l2OutputIndex", + "internalType": "uint128", + "type": "uint128" } ] }, @@ -12501,33 +9472,21 @@ "stateMutability": "view", "type": "function", "inputs": [], - "name": "OPTIMIST_INVITER", + "name": "systemConfig", "outputs": [ { "name": "", - "internalType": "address", + "internalType": "contract SystemConfig", "type": "address" } ] }, { - "stateMutability": "view", + "stateMutability": "nonpayable", "type": "function", - "inputs": [ - { - "name": "_claimer", - "internalType": "address", - "type": "address" - } - ], - "name": "isAllowedToMint", - "outputs": [ - { - "name": "", - "internalType": "bool", - "type": "bool" - } - ] + "inputs": [], + "name": "unpause", + "outputs": [] }, { "stateMutability": "view", @@ -12541,15 +9500,29 @@ "type": "string" } ] + }, + { + "stateMutability": "payable", + "type": "receive" } ], - "OptimistInviter": [ + "Optimist": [ { "stateMutability": "nonpayable", "type": "constructor", "inputs": [ { - "name": "_inviteGranter", + "name": "_name", + "internalType": "string", + "type": "string" + }, + { + "name": "_symbol", + "internalType": "string", + "type": "string" + }, + { + "name": "_baseURIAttestor", "internalType": "address", "type": "address" }, @@ -12557,9 +9530,64 @@ "name": "_attestationStation", "internalType": "contract AttestationStation", "type": "address" + }, + { + "name": "_optimistAllowlist", + "internalType": "contract OptimistAllowlist", + "type": "address" } ] }, + { + "type": "event", + "anonymous": false, + "inputs": [ + { + "name": "owner", + "internalType": "address", + "type": "address", + "indexed": true + }, + { + "name": "approved", + "internalType": "address", + "type": "address", + "indexed": true + }, + { + "name": "tokenId", + "internalType": "uint256", + "type": "uint256", + "indexed": true + } + ], + "name": "Approval" + }, + { + "type": "event", + "anonymous": false, + "inputs": [ + { + "name": "owner", + "internalType": "address", + "type": "address", + "indexed": true + }, + { + "name": "operator", + "internalType": "address", + "type": "address", + "indexed": true + }, + { + "name": "approved", + "internalType": "bool", + "type": "bool", + "indexed": false + } + ], + "name": "ApprovalForAll" + }, { "type": "event", "anonymous": false, @@ -12578,19 +9606,25 @@ "anonymous": false, "inputs": [ { - "name": "issuer", + "name": "from", "internalType": "address", "type": "address", "indexed": true }, { - "name": "claimer", + "name": "to", "internalType": "address", "type": "address", "indexed": true + }, + { + "name": "tokenId", + "internalType": "uint256", + "type": "uint256", + "indexed": true } ], - "name": "InviteClaimed" + "name": "Transfer" }, { "stateMutability": "view", @@ -12609,7 +9643,7 @@ "stateMutability": "view", "type": "function", "inputs": [], - "name": "CAN_INVITE_ATTESTATION_KEY", + "name": "BASE_URI_ATTESTATION_KEY", "outputs": [ { "name": "", @@ -12622,12 +9656,12 @@ "stateMutability": "view", "type": "function", "inputs": [], - "name": "CLAIMABLE_INVITE_TYPEHASH", + "name": "BASE_URI_ATTESTOR", "outputs": [ { "name": "", - "internalType": "bytes32", - "type": "bytes32" + "internalType": "address", + "type": "address" } ] }, @@ -12635,105 +9669,62 @@ "stateMutability": "view", "type": "function", "inputs": [], - "name": "EIP712_VERSION", + "name": "OPTIMIST_ALLOWLIST", "outputs": [ { "name": "", - "internalType": "string", - "type": "string" + "internalType": "contract OptimistAllowlist", + "type": "address" } ] }, { - "stateMutability": "view", + "stateMutability": "pure", "type": "function", - "inputs": [], - "name": "INVITE_GRANTER", - "outputs": [ + "inputs": [ { "name": "", "internalType": "address", "type": "address" - } - ] - }, - { - "stateMutability": "view", - "type": "function", - "inputs": [], - "name": "MIN_COMMITMENT_PERIOD", - "outputs": [ + }, { "name": "", "internalType": "uint256", "type": "uint256" } - ] + ], + "name": "approve", + "outputs": [] }, { - "stateMutability": "nonpayable", + "stateMutability": "view", "type": "function", "inputs": [ { - "name": "_claimer", + "name": "owner", "internalType": "address", "type": "address" - }, - { - "name": "_claimableInvite", - "internalType": "struct OptimistInviter.ClaimableInvite", - "type": "tuple", - "components": [ - { - "name": "issuer", - "internalType": "address", - "type": "address" - }, - { - "name": "nonce", - "internalType": "bytes32", - "type": "bytes32" - } - ] - }, - { - "name": "_signature", - "internalType": "bytes", - "type": "bytes" } ], - "name": "claimInvite", - "outputs": [] - }, - { - "stateMutability": "nonpayable", - "type": "function", - "inputs": [ + "name": "balanceOf", + "outputs": [ { - "name": "_commitment", - "internalType": "bytes32", - "type": "bytes32" + "name": "", + "internalType": "uint256", + "type": "uint256" } - ], - "name": "commitInvite", - "outputs": [] + ] }, { "stateMutability": "view", "type": "function", - "inputs": [ - { - "name": "", - "internalType": "bytes32", - "type": "bytes32" - } - ], - "name": "commitmentTimestamps", + "inputs": [], + "name": "baseURI", "outputs": [ { "name": "", - "internalType": "uint256", - "type": "uint256" + "internalType": "string", + "type": "string" } ] }, @@ -12742,12 +9733,12 @@ "type": "function", "inputs": [ { - "name": "_name", - "internalType": "string", - "type": "string" + "name": "tokenId", + "internalType": "uint256", + "type": "uint256" } ], - "name": "initialize", + "name": "burn", "outputs": [] }, { @@ -12755,17 +9746,17 @@ "type": "function", "inputs": [ { - "name": "", - "internalType": "address", - "type": "address" + "name": "tokenId", + "internalType": "uint256", + "type": "uint256" } ], - "name": "inviteCounts", + "name": "getApproved", "outputs": [ { "name": "", - "internalType": "uint256", - "type": "uint256" + "internalType": "address", + "type": "address" } ] }, @@ -12774,17 +9765,17 @@ "type": "function", "inputs": [ { - "name": "_accounts", - "internalType": "address[]", - "type": "address[]" + "name": "_name", + "internalType": "string", + "type": "string" }, { - "name": "_inviteCount", - "internalType": "uint256", - "type": "uint256" + "name": "_symbol", + "internalType": "string", + "type": "string" } ], - "name": "setInviteCounts", + "name": "initialize", "outputs": [] }, { @@ -12792,17 +9783,17 @@ "type": "function", "inputs": [ { - "name": "", + "name": "owner", "internalType": "address", "type": "address" }, { - "name": "", - "internalType": "bytes32", - "type": "bytes32" + "name": "operator", + "internalType": "address", + "type": "address" } ], - "name": "usedNonces", + "name": "isApprovedForAll", "outputs": [ { "name": "", @@ -12814,38 +9805,63 @@ { "stateMutability": "view", "type": "function", - "inputs": [], - "name": "version", + "inputs": [ + { + "name": "_recipient", + "internalType": "address", + "type": "address" + } + ], + "name": "isOnAllowList", "outputs": [ { "name": "", - "internalType": "string", - "type": "string" + "internalType": "bool", + "type": "bool" } ] - } - ], - "PortalSender": [ + }, { "stateMutability": "nonpayable", - "type": "constructor", + "type": "function", "inputs": [ { - "name": "_portal", - "internalType": "contract OptimismPortal", + "name": "_recipient", + "internalType": "address", "type": "address" } - ] + ], + "name": "mint", + "outputs": [] }, { "stateMutability": "view", "type": "function", "inputs": [], - "name": "PORTAL", + "name": "name", "outputs": [ { "name": "", - "internalType": "contract OptimismPortal", + "internalType": "string", + "type": "string" + } + ] + }, + { + "stateMutability": "view", + "type": "function", + "inputs": [ + { + "name": "tokenId", + "internalType": "uint256", + "type": "uint256" + } + ], + "name": "ownerOf", + "outputs": [ + { + "name": "", + "internalType": "address", "type": "address" } ] @@ -12853,141 +9869,211 @@ { "stateMutability": "nonpayable", "type": "function", - "inputs": [], - "name": "donate", + "inputs": [ + { + "name": "from", + "internalType": "address", + "type": "address" + }, + { + "name": "to", + "internalType": "address", + "type": "address" + }, + { + "name": "tokenId", + "internalType": "uint256", + "type": "uint256" + } + ], + "name": "safeTransferFrom", "outputs": [] - } - ], - "ProtocolVersions": [ - { - "stateMutability": "nonpayable", - "type": "constructor", - "inputs": [] }, { - "type": "event", - "anonymous": false, + "stateMutability": "nonpayable", + "type": "function", "inputs": [ { - "name": "version", - "internalType": "uint256", - "type": "uint256", - "indexed": true + "name": "from", + "internalType": "address", + "type": "address" }, { - "name": "updateType", - "internalType": "enum ProtocolVersions.UpdateType", - "type": "uint8", - "indexed": true + "name": "to", + "internalType": "address", + "type": "address" + }, + { + "name": "tokenId", + "internalType": "uint256", + "type": "uint256" }, { "name": "data", "internalType": "bytes", - "type": "bytes", - "indexed": false + "type": "bytes" } ], - "name": "ConfigUpdate" + "name": "safeTransferFrom", + "outputs": [] }, { - "type": "event", - "anonymous": false, + "stateMutability": "nonpayable", + "type": "function", "inputs": [ { - "name": "version", - "internalType": "uint8", - "type": "uint8", - "indexed": false + "name": "", + "internalType": "address", + "type": "address" + }, + { + "name": "", + "internalType": "bool", + "type": "bool" } ], - "name": "Initialized" + "name": "setApprovalForAll", + "outputs": [] }, { - "type": "event", - "anonymous": false, + "stateMutability": "view", + "type": "function", "inputs": [ { - "name": "previousOwner", - "internalType": "address", - "type": "address", - "indexed": true - }, - { - "name": "newOwner", - "internalType": "address", - "type": "address", - "indexed": true + "name": "interfaceId", + "internalType": "bytes4", + "type": "bytes4" } ], - "name": "OwnershipTransferred" + "name": "supportsInterface", + "outputs": [ + { + "name": "", + "internalType": "bool", + "type": "bool" + } + ] }, { "stateMutability": "view", "type": "function", "inputs": [], - "name": "RECOMMENDED_SLOT", + "name": "symbol", "outputs": [ { "name": "", - "internalType": "bytes32", - "type": "bytes32" + "internalType": "string", + "type": "string" + } + ] + }, + { + "stateMutability": "pure", + "type": "function", + "inputs": [ + { + "name": "_owner", + "internalType": "address", + "type": "address" + } + ], + "name": "tokenIdOfAddress", + "outputs": [ + { + "name": "", + "internalType": "uint256", + "type": "uint256" } ] }, { "stateMutability": "view", "type": "function", - "inputs": [], - "name": "REQUIRED_SLOT", + "inputs": [ + { + "name": "_tokenId", + "internalType": "uint256", + "type": "uint256" + } + ], + "name": "tokenURI", "outputs": [ { "name": "", - "internalType": "bytes32", - "type": "bytes32" + "internalType": "string", + "type": "string" + } + ] + }, + { + "stateMutability": "nonpayable", + "type": "function", + "inputs": [ + { + "name": "from", + "internalType": "address", + "type": "address" + }, + { + "name": "to", + "internalType": "address", + "type": "address" + }, + { + "name": "tokenId", + "internalType": "uint256", + "type": "uint256" } - ] + ], + "name": "transferFrom", + "outputs": [] }, { "stateMutability": "view", "type": "function", "inputs": [], - "name": "VERSION", + "name": "version", "outputs": [ { "name": "", - "internalType": "uint256", - "type": "uint256" + "internalType": "string", + "type": "string" } ] - }, + } + ], + "OptimistAllowlist": [ { "stateMutability": "nonpayable", - "type": "function", + "type": "constructor", "inputs": [ { - "name": "_owner", + "name": "_attestationStation", + "internalType": "contract AttestationStation", + "type": "address" + }, + { + "name": "_allowlistAttestor", "internalType": "address", "type": "address" }, { - "name": "_required", - "internalType": "ProtocolVersion", - "type": "uint256" + "name": "_coinbaseQuestAttestor", + "internalType": "address", + "type": "address" }, { - "name": "_recommended", - "internalType": "ProtocolVersion", - "type": "uint256" + "name": "_optimistInviter", + "internalType": "address", + "type": "address" } - ], - "name": "initialize", - "outputs": [] + ] }, { "stateMutability": "view", "type": "function", "inputs": [], - "name": "owner", + "name": "ALLOWLIST_ATTESTOR", "outputs": [ { "name": "", @@ -13000,73 +10086,85 @@ "stateMutability": "view", "type": "function", "inputs": [], - "name": "recommended", + "name": "ATTESTATION_STATION", "outputs": [ { - "name": "out_", - "internalType": "ProtocolVersion", - "type": "uint256" + "name": "", + "internalType": "contract AttestationStation", + "type": "address" } ] }, { - "stateMutability": "nonpayable", + "stateMutability": "view", "type": "function", "inputs": [], - "name": "renounceOwnership", - "outputs": [] + "name": "COINBASE_QUEST_ATTESTOR", + "outputs": [ + { + "name": "", + "internalType": "address", + "type": "address" + } + ] }, { "stateMutability": "view", "type": "function", "inputs": [], - "name": "required", + "name": "COINBASE_QUEST_ELIGIBLE_ATTESTATION_KEY", "outputs": [ { - "name": "out_", - "internalType": "ProtocolVersion", - "type": "uint256" + "name": "", + "internalType": "bytes32", + "type": "bytes32" } ] }, { - "stateMutability": "nonpayable", + "stateMutability": "view", "type": "function", - "inputs": [ + "inputs": [], + "name": "OPTIMIST_CAN_MINT_ATTESTATION_KEY", + "outputs": [ { - "name": "_recommended", - "internalType": "ProtocolVersion", - "type": "uint256" + "name": "", + "internalType": "bytes32", + "type": "bytes32" } - ], - "name": "setRecommended", - "outputs": [] + ] }, { - "stateMutability": "nonpayable", + "stateMutability": "view", "type": "function", - "inputs": [ + "inputs": [], + "name": "OPTIMIST_INVITER", + "outputs": [ { - "name": "_required", - "internalType": "ProtocolVersion", - "type": "uint256" + "name": "", + "internalType": "address", + "type": "address" } - ], - "name": "setRequired", - "outputs": [] + ] }, { - "stateMutability": "nonpayable", + "stateMutability": "view", "type": "function", "inputs": [ { - "name": "newOwner", + "name": "_claimer", "internalType": "address", "type": "address" } ], - "name": "transferOwnership", - "outputs": [] + "name": "isAllowedToMint", + "outputs": [ + { + "name": "", + "internalType": "bool", + "type": "bool" + } + ] }, { "stateMutability": "view", @@ -13082,15 +10180,20 @@ ] } ], - "ProxyAdmin": [ + "OptimistInviter": [ { "stateMutability": "nonpayable", "type": "constructor", "inputs": [ { - "name": "_owner", + "name": "_inviteGranter", "internalType": "address", "type": "address" + }, + { + "name": "_attestationStation", + "internalType": "contract AttestationStation", + "type": "address" } ] }, @@ -13099,100 +10202,77 @@ "anonymous": false, "inputs": [ { - "name": "previousOwner", + "name": "version", + "internalType": "uint8", + "type": "uint8", + "indexed": false + } + ], + "name": "Initialized" + }, + { + "type": "event", + "anonymous": false, + "inputs": [ + { + "name": "issuer", "internalType": "address", "type": "address", "indexed": true }, { - "name": "newOwner", + "name": "claimer", "internalType": "address", "type": "address", "indexed": true } ], - "name": "OwnershipTransferred" + "name": "InviteClaimed" }, { "stateMutability": "view", "type": "function", "inputs": [], - "name": "addressManager", + "name": "ATTESTATION_STATION", "outputs": [ { "name": "", - "internalType": "contract AddressManager", + "internalType": "contract AttestationStation", "type": "address" } ] }, - { - "stateMutability": "nonpayable", - "type": "function", - "inputs": [ - { - "name": "_proxy", - "internalType": "address payable", - "type": "address" - }, - { - "name": "_newAdmin", - "internalType": "address", - "type": "address" - } - ], - "name": "changeProxyAdmin", - "outputs": [] - }, { "stateMutability": "view", "type": "function", - "inputs": [ - { - "name": "_proxy", - "internalType": "address payable", - "type": "address" - } - ], - "name": "getProxyAdmin", + "inputs": [], + "name": "CAN_INVITE_ATTESTATION_KEY", "outputs": [ { "name": "", - "internalType": "address", - "type": "address" + "internalType": "bytes32", + "type": "bytes32" } ] }, { "stateMutability": "view", "type": "function", - "inputs": [ - { - "name": "_proxy", - "internalType": "address", - "type": "address" - } - ], - "name": "getProxyImplementation", + "inputs": [], + "name": "CLAIMABLE_INVITE_TYPEHASH", "outputs": [ { "name": "", - "internalType": "address", - "type": "address" + "internalType": "bytes32", + "type": "bytes32" } ] }, { "stateMutability": "view", "type": "function", - "inputs": [ - { - "name": "", - "internalType": "address", - "type": "address" - } - ], - "name": "implementationName", + "inputs": [], + "name": "EIP712_VERSION", "outputs": [ { "name": "", @@ -13205,12 +10285,12 @@ "stateMutability": "view", "type": "function", "inputs": [], - "name": "isUpgrading", + "name": "INVITE_GRANTER", "outputs": [ { "name": "", - "internalType": "bool", - "type": "bool" + "internalType": "address", + "type": "address" } ] }, @@ -13218,14 +10298,62 @@ "stateMutability": "view", "type": "function", "inputs": [], - "name": "owner", + "name": "MIN_COMMITMENT_PERIOD", "outputs": [ { "name": "", + "internalType": "uint256", + "type": "uint256" + } + ] + }, + { + "stateMutability": "nonpayable", + "type": "function", + "inputs": [ + { + "name": "_claimer", "internalType": "address", "type": "address" + }, + { + "name": "_claimableInvite", + "internalType": "struct OptimistInviter.ClaimableInvite", + "type": "tuple", + "components": [ + { + "name": "issuer", + "internalType": "address", + "type": "address" + }, + { + "name": "nonce", + "internalType": "bytes32", + "type": "bytes32" + } + ] + }, + { + "name": "_signature", + "internalType": "bytes", + "type": "bytes" + } + ], + "name": "claimInvite", + "outputs": [] + }, + { + "stateMutability": "nonpayable", + "type": "function", + "inputs": [ + { + "name": "_commitment", + "internalType": "bytes32", + "type": "bytes32" } - ] + ], + "name": "commitInvite", + "outputs": [] }, { "stateMutability": "view", @@ -13233,26 +10361,19 @@ "inputs": [ { "name": "", - "internalType": "address", - "type": "address" + "internalType": "bytes32", + "type": "bytes32" } ], - "name": "proxyType", + "name": "commitmentTimestamps", "outputs": [ { "name": "", - "internalType": "enum ProxyAdmin.ProxyType", - "type": "uint8" + "internalType": "uint256", + "type": "uint256" } ] }, - { - "stateMutability": "nonpayable", - "type": "function", - "inputs": [], - "name": "renounceOwnership", - "outputs": [] - }, { "stateMutability": "nonpayable", "type": "function", @@ -13261,225 +10382,200 @@ "name": "_name", "internalType": "string", "type": "string" - }, - { - "name": "_address", - "internalType": "address", - "type": "address" } ], - "name": "setAddress", + "name": "initialize", "outputs": [] }, { - "stateMutability": "nonpayable", + "stateMutability": "view", "type": "function", "inputs": [ { - "name": "_address", - "internalType": "contract AddressManager", + "name": "", + "internalType": "address", "type": "address" } ], - "name": "setAddressManager", - "outputs": [] + "name": "inviteCounts", + "outputs": [ + { + "name": "", + "internalType": "uint256", + "type": "uint256" + } + ] }, { "stateMutability": "nonpayable", "type": "function", "inputs": [ { - "name": "_address", - "internalType": "address", - "type": "address" + "name": "_accounts", + "internalType": "address[]", + "type": "address[]" }, { - "name": "_name", - "internalType": "string", - "type": "string" + "name": "_inviteCount", + "internalType": "uint256", + "type": "uint256" } ], - "name": "setImplementationName", + "name": "setInviteCounts", "outputs": [] }, { - "stateMutability": "nonpayable", + "stateMutability": "view", "type": "function", "inputs": [ { - "name": "_address", + "name": "", "internalType": "address", "type": "address" }, { - "name": "_type", - "internalType": "enum ProxyAdmin.ProxyType", - "type": "uint8" + "name": "", + "internalType": "bytes32", + "type": "bytes32" } ], - "name": "setProxyType", - "outputs": [] - }, - { - "stateMutability": "nonpayable", - "type": "function", - "inputs": [ + "name": "usedNonces", + "outputs": [ { - "name": "_upgrading", + "name": "", "internalType": "bool", "type": "bool" } - ], - "name": "setUpgrading", - "outputs": [] + ] }, { - "stateMutability": "nonpayable", + "stateMutability": "view", "type": "function", - "inputs": [ + "inputs": [], + "name": "version", + "outputs": [ { - "name": "newOwner", - "internalType": "address", - "type": "address" + "name": "", + "internalType": "string", + "type": "string" } - ], - "name": "transferOwnership", - "outputs": [] - }, + ] + } + ], + "PortalSender": [ { "stateMutability": "nonpayable", - "type": "function", + "type": "constructor", "inputs": [ { - "name": "_proxy", - "internalType": "address payable", - "type": "address" - }, - { - "name": "_implementation", - "internalType": "address", + "name": "_portal", + "internalType": "contract OptimismPortal", "type": "address" } - ], - "name": "upgrade", - "outputs": [] + ] }, { - "stateMutability": "payable", + "stateMutability": "view", "type": "function", - "inputs": [ - { - "name": "_proxy", - "internalType": "address payable", - "type": "address" - }, + "inputs": [], + "name": "PORTAL", + "outputs": [ { - "name": "_implementation", - "internalType": "address", + "name": "", + "internalType": "contract OptimismPortal", "type": "address" - }, - { - "name": "_data", - "internalType": "bytes", - "type": "bytes" } - ], - "name": "upgradeAndCall", + ] + }, + { + "stateMutability": "nonpayable", + "type": "function", + "inputs": [], + "name": "donate", "outputs": [] } ], - "SchemaRegistry": [ + "ProtocolVersions": [ { "stateMutability": "nonpayable", "type": "constructor", "inputs": [] }, - { - "type": "error", - "inputs": [], - "name": "AlreadyExists" - }, { "type": "event", "anonymous": false, "inputs": [ { - "name": "uid", - "internalType": "bytes32", - "type": "bytes32", + "name": "version", + "internalType": "uint256", + "type": "uint256", "indexed": true }, { - "name": "registerer", - "internalType": "address", - "type": "address", + "name": "updateType", + "internalType": "enum ProtocolVersions.UpdateType", + "type": "uint8", + "indexed": true + }, + { + "name": "data", + "internalType": "bytes", + "type": "bytes", "indexed": false } ], - "name": "Registered" + "name": "ConfigUpdate" }, { - "stateMutability": "view", - "type": "function", + "type": "event", + "anonymous": false, "inputs": [ { - "name": "uid", - "internalType": "bytes32", - "type": "bytes32" + "name": "version", + "internalType": "uint8", + "type": "uint8", + "indexed": false } ], - "name": "getSchema", - "outputs": [ - { - "name": "", - "internalType": "struct SchemaRecord", - "type": "tuple", - "components": [ - { - "name": "uid", - "internalType": "bytes32", - "type": "bytes32" - }, - { - "name": "resolver", - "internalType": "contract ISchemaResolver", - "type": "address" - }, - { - "name": "revocable", - "internalType": "bool", - "type": "bool" - }, - { - "name": "schema", - "internalType": "string", - "type": "string" - } - ] - } - ] + "name": "Initialized" }, { - "stateMutability": "nonpayable", - "type": "function", + "type": "event", + "anonymous": false, "inputs": [ { - "name": "schema", - "internalType": "string", - "type": "string" - }, - { - "name": "resolver", - "internalType": "contract ISchemaResolver", - "type": "address" + "name": "previousOwner", + "internalType": "address", + "type": "address", + "indexed": true }, { - "name": "revocable", - "internalType": "bool", - "type": "bool" + "name": "newOwner", + "internalType": "address", + "type": "address", + "indexed": true } ], - "name": "register", + "name": "OwnershipTransferred" + }, + { + "stateMutability": "view", + "type": "function", + "inputs": [], + "name": "RECOMMENDED_SLOT", + "outputs": [ + { + "name": "", + "internalType": "bytes32", + "type": "bytes32" + } + ] + }, + { + "stateMutability": "view", + "type": "function", + "inputs": [], + "name": "REQUIRED_SLOT", "outputs": [ { "name": "", @@ -13492,63 +10588,48 @@ "stateMutability": "view", "type": "function", "inputs": [], - "name": "version", + "name": "VERSION", "outputs": [ { "name": "", - "internalType": "string", - "type": "string" + "internalType": "uint256", + "type": "uint256" } ] - } - ], - "SequencerFeeVault": [ + }, { "stateMutability": "nonpayable", - "type": "constructor", + "type": "function", "inputs": [ { - "name": "_recipient", + "name": "_owner", "internalType": "address", "type": "address" - } - ] - }, - { - "type": "event", - "anonymous": false, - "inputs": [ - { - "name": "value", - "internalType": "uint256", - "type": "uint256", - "indexed": false }, { - "name": "to", - "internalType": "address", - "type": "address", - "indexed": false + "name": "_required", + "internalType": "ProtocolVersion", + "type": "uint256" }, { - "name": "from", - "internalType": "address", - "type": "address", - "indexed": false + "name": "_recommended", + "internalType": "ProtocolVersion", + "type": "uint256" } ], - "name": "Withdrawal" + "name": "initialize", + "outputs": [] }, { "stateMutability": "view", "type": "function", "inputs": [], - "name": "MIN_WITHDRAWAL_AMOUNT", + "name": "owner", "outputs": [ { "name": "", - "internalType": "uint256", - "type": "uint256" + "internalType": "address", + "type": "address" } ] }, @@ -13556,40 +10637,73 @@ "stateMutability": "view", "type": "function", "inputs": [], - "name": "RECIPIENT", + "name": "recommended", "outputs": [ { - "name": "", - "internalType": "address", - "type": "address" + "name": "out_", + "internalType": "ProtocolVersion", + "type": "uint256" } ] }, + { + "stateMutability": "nonpayable", + "type": "function", + "inputs": [], + "name": "renounceOwnership", + "outputs": [] + }, { "stateMutability": "view", "type": "function", "inputs": [], - "name": "l1FeeWallet", + "name": "required", "outputs": [ { - "name": "", - "internalType": "address", - "type": "address" + "name": "out_", + "internalType": "ProtocolVersion", + "type": "uint256" } ] }, { - "stateMutability": "view", + "stateMutability": "nonpayable", "type": "function", - "inputs": [], - "name": "totalProcessed", - "outputs": [ + "inputs": [ { - "name": "", - "internalType": "uint256", + "name": "_recommended", + "internalType": "ProtocolVersion", "type": "uint256" } - ] + ], + "name": "setRecommended", + "outputs": [] + }, + { + "stateMutability": "nonpayable", + "type": "function", + "inputs": [ + { + "name": "_required", + "internalType": "ProtocolVersion", + "type": "uint256" + } + ], + "name": "setRequired", + "outputs": [] + }, + { + "stateMutability": "nonpayable", + "type": "function", + "inputs": [ + { + "name": "newOwner", + "internalType": "address", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [] }, { "stateMutability": "view", @@ -13603,20 +10717,9 @@ "type": "string" } ] - }, - { - "stateMutability": "nonpayable", - "type": "function", - "inputs": [], - "name": "withdraw", - "outputs": [] - }, - { - "stateMutability": "payable", - "type": "receive" } ], - "SystemConfig": [ + "ProxyAdmin": [ { "stateMutability": "nonpayable", "type": "constructor", @@ -13625,68 +10728,6 @@ "name": "_owner", "internalType": "address", "type": "address" - }, - { - "name": "_overhead", - "internalType": "uint256", - "type": "uint256" - }, - { - "name": "_scalar", - "internalType": "uint256", - "type": "uint256" - }, - { - "name": "_batcherHash", - "internalType": "bytes32", - "type": "bytes32" - }, - { - "name": "_gasLimit", - "internalType": "uint64", - "type": "uint64" - }, - { - "name": "_unsafeBlockSigner", - "internalType": "address", - "type": "address" - }, - { - "name": "_config", - "internalType": "struct ResourceMetering.ResourceConfig", - "type": "tuple", - "components": [ - { - "name": "maxResourceLimit", - "internalType": "uint32", - "type": "uint32" - }, - { - "name": "elasticityMultiplier", - "internalType": "uint8", - "type": "uint8" - }, - { - "name": "baseFeeMaxChangeDenominator", - "internalType": "uint8", - "type": "uint8" - }, - { - "name": "minimumBaseFee", - "internalType": "uint32", - "type": "uint32" - }, - { - "name": "systemTxMaxGas", - "internalType": "uint32", - "type": "uint32" - }, - { - "name": "maximumBaseFee", - "internalType": "uint128", - "type": "uint128" - } - ] } ] }, @@ -13695,68 +10736,105 @@ "anonymous": false, "inputs": [ { - "name": "version", - "internalType": "uint256", - "type": "uint256", + "name": "previousOwner", + "internalType": "address", + "type": "address", "indexed": true }, { - "name": "updateType", - "internalType": "enum SystemConfig.UpdateType", - "type": "uint8", + "name": "newOwner", + "internalType": "address", + "type": "address", "indexed": true + } + ], + "name": "OwnershipTransferred" + }, + { + "stateMutability": "view", + "type": "function", + "inputs": [], + "name": "addressManager", + "outputs": [ + { + "name": "", + "internalType": "contract AddressManager", + "type": "address" + } + ] + }, + { + "stateMutability": "nonpayable", + "type": "function", + "inputs": [ + { + "name": "_proxy", + "internalType": "address payable", + "type": "address" }, { - "name": "data", - "internalType": "bytes", - "type": "bytes", - "indexed": false + "name": "_newAdmin", + "internalType": "address", + "type": "address" } ], - "name": "ConfigUpdate" + "name": "changeProxyAdmin", + "outputs": [] }, { - "type": "event", - "anonymous": false, + "stateMutability": "view", + "type": "function", "inputs": [ { - "name": "version", - "internalType": "uint8", - "type": "uint8", - "indexed": false + "name": "_proxy", + "internalType": "address payable", + "type": "address" + } + ], + "name": "getProxyAdmin", + "outputs": [ + { + "name": "", + "internalType": "address", + "type": "address" } - ], - "name": "Initialized" + ] }, { - "type": "event", - "anonymous": false, + "stateMutability": "view", + "type": "function", "inputs": [ { - "name": "previousOwner", + "name": "_proxy", "internalType": "address", - "type": "address", - "indexed": true - }, + "type": "address" + } + ], + "name": "getProxyImplementation", + "outputs": [ { - "name": "newOwner", + "name": "", "internalType": "address", - "type": "address", - "indexed": true + "type": "address" } - ], - "name": "OwnershipTransferred" + ] }, { "stateMutability": "view", "type": "function", - "inputs": [], - "name": "UNSAFE_BLOCK_SIGNER_SLOT", + "inputs": [ + { + "name": "", + "internalType": "address", + "type": "address" + } + ], + "name": "implementationName", "outputs": [ { "name": "", - "internalType": "bytes32", - "type": "bytes32" + "internalType": "string", + "type": "string" } ] }, @@ -13764,12 +10842,12 @@ "stateMutability": "view", "type": "function", "inputs": [], - "name": "VERSION", + "name": "isUpgrading", "outputs": [ { "name": "", - "internalType": "uint256", - "type": "uint256" + "internalType": "bool", + "type": "bool" } ] }, @@ -13777,332 +10855,376 @@ "stateMutability": "view", "type": "function", "inputs": [], - "name": "batcherHash", + "name": "owner", "outputs": [ { "name": "", - "internalType": "bytes32", - "type": "bytes32" + "internalType": "address", + "type": "address" } ] }, { "stateMutability": "view", "type": "function", - "inputs": [], - "name": "gasLimit", + "inputs": [ + { + "name": "", + "internalType": "address", + "type": "address" + } + ], + "name": "proxyType", "outputs": [ { "name": "", - "internalType": "uint64", - "type": "uint64" + "internalType": "enum ProxyAdmin.ProxyType", + "type": "uint8" } ] }, + { + "stateMutability": "nonpayable", + "type": "function", + "inputs": [], + "name": "renounceOwnership", + "outputs": [] + }, { "stateMutability": "nonpayable", "type": "function", "inputs": [ { - "name": "_owner", - "internalType": "address", - "type": "address" + "name": "_name", + "internalType": "string", + "type": "string" }, { - "name": "_overhead", - "internalType": "uint256", - "type": "uint256" - }, + "name": "_address", + "internalType": "address", + "type": "address" + } + ], + "name": "setAddress", + "outputs": [] + }, + { + "stateMutability": "nonpayable", + "type": "function", + "inputs": [ { - "name": "_scalar", - "internalType": "uint256", - "type": "uint256" - }, + "name": "_address", + "internalType": "contract AddressManager", + "type": "address" + } + ], + "name": "setAddressManager", + "outputs": [] + }, + { + "stateMutability": "nonpayable", + "type": "function", + "inputs": [ { - "name": "_batcherHash", - "internalType": "bytes32", - "type": "bytes32" + "name": "_address", + "internalType": "address", + "type": "address" }, { - "name": "_gasLimit", - "internalType": "uint64", - "type": "uint64" - }, + "name": "_name", + "internalType": "string", + "type": "string" + } + ], + "name": "setImplementationName", + "outputs": [] + }, + { + "stateMutability": "nonpayable", + "type": "function", + "inputs": [ { - "name": "_unsafeBlockSigner", + "name": "_address", "internalType": "address", "type": "address" }, { - "name": "_config", - "internalType": "struct ResourceMetering.ResourceConfig", - "type": "tuple", - "components": [ - { - "name": "maxResourceLimit", - "internalType": "uint32", - "type": "uint32" - }, - { - "name": "elasticityMultiplier", - "internalType": "uint8", - "type": "uint8" - }, - { - "name": "baseFeeMaxChangeDenominator", - "internalType": "uint8", - "type": "uint8" - }, - { - "name": "minimumBaseFee", - "internalType": "uint32", - "type": "uint32" - }, - { - "name": "systemTxMaxGas", - "internalType": "uint32", - "type": "uint32" - }, - { - "name": "maximumBaseFee", - "internalType": "uint128", - "type": "uint128" - } - ] + "name": "_type", + "internalType": "enum ProxyAdmin.ProxyType", + "type": "uint8" } ], - "name": "initialize", + "name": "setProxyType", "outputs": [] }, { - "stateMutability": "view", + "stateMutability": "nonpayable", "type": "function", - "inputs": [], - "name": "minimumGasLimit", - "outputs": [ + "inputs": [ { - "name": "", - "internalType": "uint64", - "type": "uint64" + "name": "_upgrading", + "internalType": "bool", + "type": "bool" } - ] + ], + "name": "setUpgrading", + "outputs": [] }, { - "stateMutability": "view", + "stateMutability": "nonpayable", "type": "function", - "inputs": [], - "name": "overhead", - "outputs": [ + "inputs": [ { - "name": "", - "internalType": "uint256", - "type": "uint256" + "name": "newOwner", + "internalType": "address", + "type": "address" } - ] + ], + "name": "transferOwnership", + "outputs": [] + }, + { + "stateMutability": "nonpayable", + "type": "function", + "inputs": [ + { + "name": "_proxy", + "internalType": "address payable", + "type": "address" + }, + { + "name": "_implementation", + "internalType": "address", + "type": "address" + } + ], + "name": "upgrade", + "outputs": [] + }, + { + "stateMutability": "payable", + "type": "function", + "inputs": [ + { + "name": "_proxy", + "internalType": "address payable", + "type": "address" + }, + { + "name": "_implementation", + "internalType": "address", + "type": "address" + }, + { + "name": "_data", + "internalType": "bytes", + "type": "bytes" + } + ], + "name": "upgradeAndCall", + "outputs": [] + } + ], + "SchemaRegistry": [ + { + "stateMutability": "nonpayable", + "type": "constructor", + "inputs": [] }, { - "stateMutability": "view", - "type": "function", + "type": "error", "inputs": [], - "name": "owner", - "outputs": [ + "name": "AlreadyExists" + }, + { + "type": "event", + "anonymous": false, + "inputs": [ { - "name": "", + "name": "uid", + "internalType": "bytes32", + "type": "bytes32", + "indexed": true + }, + { + "name": "registerer", "internalType": "address", - "type": "address" + "type": "address", + "indexed": false } - ] - }, - { - "stateMutability": "nonpayable", - "type": "function", - "inputs": [], - "name": "renounceOwnership", - "outputs": [] + ], + "name": "Registered" }, { "stateMutability": "view", "type": "function", - "inputs": [], - "name": "resourceConfig", + "inputs": [ + { + "name": "uid", + "internalType": "bytes32", + "type": "bytes32" + } + ], + "name": "getSchema", "outputs": [ { "name": "", - "internalType": "struct ResourceMetering.ResourceConfig", + "internalType": "struct SchemaRecord", "type": "tuple", "components": [ { - "name": "maxResourceLimit", - "internalType": "uint32", - "type": "uint32" - }, - { - "name": "elasticityMultiplier", - "internalType": "uint8", - "type": "uint8" - }, - { - "name": "baseFeeMaxChangeDenominator", - "internalType": "uint8", - "type": "uint8" + "name": "uid", + "internalType": "bytes32", + "type": "bytes32" }, { - "name": "minimumBaseFee", - "internalType": "uint32", - "type": "uint32" + "name": "resolver", + "internalType": "contract ISchemaResolver", + "type": "address" }, { - "name": "systemTxMaxGas", - "internalType": "uint32", - "type": "uint32" + "name": "revocable", + "internalType": "bool", + "type": "bool" }, { - "name": "maximumBaseFee", - "internalType": "uint128", - "type": "uint128" + "name": "schema", + "internalType": "string", + "type": "string" } ] } ] }, + { + "stateMutability": "nonpayable", + "type": "function", + "inputs": [ + { + "name": "schema", + "internalType": "string", + "type": "string" + }, + { + "name": "resolver", + "internalType": "contract ISchemaResolver", + "type": "address" + }, + { + "name": "revocable", + "internalType": "bool", + "type": "bool" + } + ], + "name": "register", + "outputs": [ + { + "name": "", + "internalType": "bytes32", + "type": "bytes32" + } + ] + }, { "stateMutability": "view", "type": "function", "inputs": [], - "name": "scalar", + "name": "version", "outputs": [ { "name": "", - "internalType": "uint256", - "type": "uint256" + "internalType": "string", + "type": "string" } ] - }, + } + ], + "SequencerFeeVault": [ { "stateMutability": "nonpayable", - "type": "function", + "type": "constructor", "inputs": [ { - "name": "_batcherHash", - "internalType": "bytes32", - "type": "bytes32" + "name": "_recipient", + "internalType": "address", + "type": "address" } - ], - "name": "setBatcherHash", - "outputs": [] + ] }, { - "stateMutability": "nonpayable", - "type": "function", + "type": "event", + "anonymous": false, "inputs": [ { - "name": "_overhead", + "name": "value", "internalType": "uint256", - "type": "uint256" + "type": "uint256", + "indexed": false }, { - "name": "_scalar", - "internalType": "uint256", - "type": "uint256" - } - ], - "name": "setGasConfig", - "outputs": [] - }, - { - "stateMutability": "nonpayable", - "type": "function", - "inputs": [ + "name": "to", + "internalType": "address", + "type": "address", + "indexed": false + }, { - "name": "_gasLimit", - "internalType": "uint64", - "type": "uint64" + "name": "from", + "internalType": "address", + "type": "address", + "indexed": false } ], - "name": "setGasLimit", - "outputs": [] + "name": "Withdrawal" }, { - "stateMutability": "nonpayable", + "stateMutability": "view", "type": "function", - "inputs": [ + "inputs": [], + "name": "MIN_WITHDRAWAL_AMOUNT", + "outputs": [ { - "name": "_config", - "internalType": "struct ResourceMetering.ResourceConfig", - "type": "tuple", - "components": [ - { - "name": "maxResourceLimit", - "internalType": "uint32", - "type": "uint32" - }, - { - "name": "elasticityMultiplier", - "internalType": "uint8", - "type": "uint8" - }, - { - "name": "baseFeeMaxChangeDenominator", - "internalType": "uint8", - "type": "uint8" - }, - { - "name": "minimumBaseFee", - "internalType": "uint32", - "type": "uint32" - }, - { - "name": "systemTxMaxGas", - "internalType": "uint32", - "type": "uint32" - }, - { - "name": "maximumBaseFee", - "internalType": "uint128", - "type": "uint128" - } - ] + "name": "", + "internalType": "uint256", + "type": "uint256" } - ], - "name": "setResourceConfig", - "outputs": [] + ] }, { - "stateMutability": "nonpayable", + "stateMutability": "view", "type": "function", - "inputs": [ + "inputs": [], + "name": "RECIPIENT", + "outputs": [ { - "name": "_unsafeBlockSigner", + "name": "", "internalType": "address", "type": "address" } - ], - "name": "setUnsafeBlockSigner", - "outputs": [] + ] }, { - "stateMutability": "nonpayable", + "stateMutability": "view", "type": "function", - "inputs": [ + "inputs": [], + "name": "l1FeeWallet", + "outputs": [ { - "name": "newOwner", + "name": "", "internalType": "address", "type": "address" } - ], - "name": "transferOwnership", - "outputs": [] + ] }, { "stateMutability": "view", "type": "function", "inputs": [], - "name": "unsafeBlockSigner", + "name": "totalProcessed", "outputs": [ { "name": "", - "internalType": "address", - "type": "address" + "internalType": "uint256", + "type": "uint256" } ] }, @@ -14118,9 +11240,20 @@ "type": "string" } ] + }, + { + "stateMutability": "nonpayable", + "type": "function", + "inputs": [], + "name": "withdraw", + "outputs": [] + }, + { + "stateMutability": "payable", + "type": "receive" } ], - "SystemConfig_goerli": [ + "SystemConfig": [ { "stateMutability": "nonpayable", "type": "constructor", diff --git a/packages/contracts-ts/addresses.json b/packages/contracts-ts/addresses.json index 04782ba532773..a236783794abc 100644 --- a/packages/contracts-ts/addresses.json +++ b/packages/contracts-ts/addresses.json @@ -54,24 +54,18 @@ "420": "0x4200000000000000000000000000000000000015" }, "L1CrossDomainMessenger": { - "1": "0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1" - }, - "L1CrossDomainMessenger_goerli": { + "1": "0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1", "5": "0x5086d1eEF304eb5284A0f6720f79403b4e9bE294" }, "L1ERC721Bridge": { - "1": "0x5a7749f83b81B301cAb5f48EB8516B986DAef23D" - }, - "L1ERC721Bridge_goerli": { + "1": "0x5a7749f83b81B301cAb5f48EB8516B986DAef23D", "5": "0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9" }, "L1FeeVault": { "420": "0x420000000000000000000000000000000000001a" }, "L1StandardBridge": { - "1": "0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1" - }, - "L1StandardBridge_goerli": { + "1": "0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1", "5": "0x636Af16bf2f682dD3109e60102b8E1A089FedAa8" }, "L2CrossDomainMessenger": { @@ -84,9 +78,7 @@ "420": "0x4200000000000000000000000000000000000014" }, "L2OutputOracle": { - "1": "0xdfe97868233d1aa22e815a266982f2cf17685a27" - }, - "L2OutputOracle_goerli": { + "1": "0xdfe97868233d1aa22e815a266982f2cf17685a27", "5": "0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0" }, "L2StandardBridge": { @@ -115,9 +107,7 @@ "420": "0x4200000000000000000000000000000000000017" }, "OptimismPortal": { - "1": "0xbEb5Fc579115071764c7423A4f12eDde41f106Ed" - }, - "OptimismPortal_goerli": { + "1": "0xbEb5Fc579115071764c7423A4f12eDde41f106Ed", "5": "0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383" }, "Optimist": { @@ -151,9 +141,7 @@ "420": "0x4200000000000000000000000000000000000011" }, "SystemConfig": { - "1": "0x229047fed2591dbec1eF1118d64F7aF3dB9EB290" - }, - "SystemConfig_goerli": { + "1": "0x229047fed2591dbec1eF1118d64F7aF3dB9EB290", "5": "0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60" }, "SystemDictator": { diff --git a/packages/contracts-ts/package.json b/packages/contracts-ts/package.json index d160cf6da644e..a77d272274428 100644 --- a/packages/contracts-ts/package.json +++ b/packages/contracts-ts/package.json @@ -1,6 +1,6 @@ { "name": "@eth-optimism/contracts-ts", - "version": "0.16.2", + "version": "0.17.0", "description": "TypeScript interface for Contracts Bedrock", "license": "MIT", "repository": { @@ -48,20 +48,20 @@ }, "devDependencies": { "@eth-optimism/contracts-bedrock": "workspace:*", - "@testing-library/jest-dom": "^6.0.1", + "@testing-library/jest-dom": "^6.1.4", "@testing-library/react-hooks": "^8.0.1", "@types/glob": "^8.1.0", "@vitest/coverage-istanbul": "^0.34.6", "@wagmi/cli": "^1.5.2", - "@wagmi/core": "^1.4.3", - "abitype": "^0.10.1", + "@wagmi/core": "^1.4.5", + "abitype": "^0.10.2", "glob": "^10.3.10", "isomorphic-fetch": "^3.0.0", "jest-dom": "link:@types/@testing-library/jest-dom", "jsdom": "^22.1.0", "tsup": "^7.2.0", "typescript": "^5.2.2", - "vite": "^4.4.10", + "vite": "^4.5.0", "vitest": "^0.34.2" }, "peerDependencies": { @@ -82,6 +82,6 @@ "change-case": "4.1.2", "react": "^18.2.0", "react-dom": "^18.2.0", - "viem": "^1.16.5" + "viem": "^1.18.6" } } diff --git a/packages/contracts-ts/src/actions.ts b/packages/contracts-ts/src/actions.ts index 8d22383060967..b277991d6c3e6 100644 --- a/packages/contracts-ts/src/actions.ts +++ b/packages/contracts-ts/src/actions.ts @@ -1,19 +1,4 @@ -import { - getContract, - GetContractArgs, - readContract, - ReadContractConfig, - writeContract, - WriteContractMode, - WriteContractArgs, - WriteContractPreparedArgs, - WriteContractUnpreparedArgs, - prepareWriteContract, - PrepareWriteContractConfig, - watchContractEvent, - WatchContractEventConfig, - WatchContractEventCallback, -} from 'wagmi/actions' +import { getContract, GetContractArgs } from 'wagmi/actions' /* eslint-disable */ @@ -2791,20 +2776,11 @@ export const l1BlockConfig = { ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) */ export const l1CrossDomainMessengerABI = [ - { - stateMutability: 'nonpayable', - type: 'constructor', - inputs: [ - { - name: '_portal', - internalType: 'contract OptimismPortal', - type: 'address', - }, - ], - }, + { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, { type: 'event', anonymous: false, @@ -2925,15 +2901,6 @@ export const l1CrossDomainMessengerABI = [ name: 'OTHER_MESSENGER', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'PORTAL', - outputs: [ - { name: '', internalType: 'contract OptimismPortal', type: 'address' }, - ], - }, { stateMutability: 'view', type: 'function', @@ -2982,7 +2949,13 @@ export const l1CrossDomainMessengerABI = [ { stateMutability: 'nonpayable', type: 'function', - inputs: [], + inputs: [ + { + name: '_portal', + internalType: 'contract OptimismPortal', + type: 'address', + }, + ], name: 'initialize', outputs: [], }, @@ -2993,6 +2966,13 @@ export const l1CrossDomainMessengerABI = [ name: 'messageNonce', outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'portal', + outputs: [{ name: '', internalType: 'address', type: 'address' }], + }, { stateMutability: 'payable', type: 'function', @@ -3042,14 +3022,17 @@ export const l1CrossDomainMessengerABI = [ ] as const /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) */ export const l1CrossDomainMessengerAddress = { 1: '0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1', + 5: '0x5086d1eEF304eb5284A0f6720f79403b4e9bE294', } as const /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) */ export const l1CrossDomainMessengerConfig = { address: l1CrossDomainMessengerAddress, @@ -3057,186 +3040,148 @@ export const l1CrossDomainMessengerConfig = { } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// L1CrossDomainMessenger_goerli +// L1ERC721Bridge ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5a7749f83b81B301cAb5f48EB8516B986DAef23D) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9) */ -export const l1CrossDomainMessengerGoerliABI = [ +export const l1Erc721BridgeABI = [ { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, { type: 'event', anonymous: false, inputs: [ { - name: 'msgHash', - internalType: 'bytes32', - type: 'bytes32', - indexed: true, - }, - ], - name: 'FailedRelayedMessage', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, - ], - name: 'Initialized', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'msgHash', - internalType: 'bytes32', - type: 'bytes32', - indexed: true, - }, - ], - name: 'RelayedMessage', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'target', + name: 'localToken', internalType: 'address', type: 'address', indexed: true, }, { - name: 'sender', + name: 'remoteToken', internalType: 'address', type: 'address', - indexed: false, + indexed: true, }, - { name: 'message', internalType: 'bytes', type: 'bytes', indexed: false }, + { name: 'from', internalType: 'address', type: 'address', indexed: true }, + { name: 'to', internalType: 'address', type: 'address', indexed: false }, { - name: 'messageNonce', + name: 'tokenId', internalType: 'uint256', type: 'uint256', indexed: false, }, { - name: 'gasLimit', - internalType: 'uint256', - type: 'uint256', + name: 'extraData', + internalType: 'bytes', + type: 'bytes', indexed: false, }, ], - name: 'SentMessage', + name: 'ERC721BridgeFinalized', }, { type: 'event', anonymous: false, inputs: [ { - name: 'sender', + name: 'localToken', internalType: 'address', type: 'address', indexed: true, }, { - name: 'value', + name: 'remoteToken', + internalType: 'address', + type: 'address', + indexed: true, + }, + { name: 'from', internalType: 'address', type: 'address', indexed: true }, + { name: 'to', internalType: 'address', type: 'address', indexed: false }, + { + name: 'tokenId', internalType: 'uint256', type: 'uint256', indexed: false, }, + { + name: 'extraData', + internalType: 'bytes', + type: 'bytes', + indexed: false, + }, ], - name: 'SentMessageExtension1', - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'MESSAGE_VERSION', - outputs: [{ name: '', internalType: 'uint16', type: 'uint16' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'MIN_GAS_CALLDATA_OVERHEAD', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'MIN_GAS_DYNAMIC_OVERHEAD_DENOMINATOR', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'MIN_GAS_DYNAMIC_OVERHEAD_NUMERATOR', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'OTHER_MESSENGER', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'ERC721BridgeInitiated', }, { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'RELAY_CALL_OVERHEAD', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + type: 'event', + anonymous: false, + inputs: [ + { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, + ], + name: 'Initialized', }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'RELAY_CONSTANT_OVERHEAD', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + inputs: [ + { name: '_localToken', internalType: 'address', type: 'address' }, + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'bridgeERC721', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'RELAY_GAS_CHECK_BUFFER', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + inputs: [ + { name: '_localToken', internalType: 'address', type: 'address' }, + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'bridgeERC721To', + outputs: [], }, { stateMutability: 'view', type: 'function', - inputs: [], - name: 'RELAY_RESERVED_GAS', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], - }, - { - stateMutability: 'pure', - type: 'function', inputs: [ - { name: '_message', internalType: 'bytes', type: 'bytes' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '', internalType: 'address', type: 'address' }, + { name: '', internalType: 'address', type: 'address' }, + { name: '', internalType: 'uint256', type: 'uint256' }, ], - name: 'baseGas', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + name: 'deposits', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - name: 'failedMessages', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + inputs: [ + { name: '_localToken', internalType: 'address', type: 'address' }, + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_from', internalType: 'address', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'finalizeBridgeERC721', + outputs: [], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ { - name: '_portal', - internalType: 'contract OptimismPortal', + name: '_messenger', + internalType: 'contract CrossDomainMessenger', type: 'address', }, ], @@ -3247,47 +3192,102 @@ export const l1CrossDomainMessengerGoerliABI = [ stateMutability: 'view', type: 'function', inputs: [], - name: 'messageNonce', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'messenger', + outputs: [ + { + name: '', + internalType: 'contract CrossDomainMessenger', + type: 'address', + }, + ], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'portal', + name: 'otherBridge', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'payable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_nonce', internalType: 'uint256', type: 'uint256' }, - { name: '_sender', internalType: 'address', type: 'address' }, - { name: '_target', internalType: 'address', type: 'address' }, - { name: '_value', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint256', type: 'uint256' }, - { name: '_message', internalType: 'bytes', type: 'bytes' }, - ], - name: 'relayMessage', - outputs: [], + inputs: [], + name: 'version', + outputs: [{ name: '', internalType: 'string', type: 'string' }], }, - { - stateMutability: 'payable', - type: 'function', - inputs: [ - { name: '_target', internalType: 'address', type: 'address' }, - { name: '_message', internalType: 'bytes', type: 'bytes' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, +] as const + +/** + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5a7749f83b81B301cAb5f48EB8516B986DAef23D) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9) + */ +export const l1Erc721BridgeAddress = { + 1: '0x5a7749f83b81B301cAb5f48EB8516B986DAef23D', + 5: '0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9', +} as const + +/** + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5a7749f83b81B301cAb5f48EB8516B986DAef23D) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9) + */ +export const l1Erc721BridgeConfig = { + address: l1Erc721BridgeAddress, + abi: l1Erc721BridgeABI, +} as const + +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// L1FeeVault +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/** + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000001a) + */ +export const l1FeeVaultABI = [ + { + stateMutability: 'nonpayable', + type: 'constructor', + inputs: [{ name: '_recipient', internalType: 'address', type: 'address' }], + }, + { + type: 'event', + anonymous: false, + inputs: [ + { + name: 'value', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + { name: 'to', internalType: 'address', type: 'address', indexed: false }, + { + name: 'from', + internalType: 'address', + type: 'address', + indexed: false, + }, ], - name: 'sendMessage', - outputs: [], + name: 'Withdrawal', }, { stateMutability: 'view', type: 'function', - inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - name: 'successfulMessages', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + inputs: [], + name: 'MIN_WITHDRAWAL_AMOUNT', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'RECIPIENT', + outputs: [{ name: '', internalType: 'address', type: 'address' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'totalProcessed', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', @@ -3297,45 +3297,40 @@ export const l1CrossDomainMessengerGoerliABI = [ outputs: [{ name: '', internalType: 'string', type: 'string' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', inputs: [], - name: 'xDomainMessageSender', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'withdraw', + outputs: [], }, + { stateMutability: 'payable', type: 'receive' }, ] as const /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000001a) */ -export const l1CrossDomainMessengerGoerliAddress = { - 5: '0x5086d1eEF304eb5284A0f6720f79403b4e9bE294', +export const l1FeeVaultAddress = { + 420: '0x420000000000000000000000000000000000001A', } as const /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000001a) */ -export const l1CrossDomainMessengerGoerliConfig = { - address: l1CrossDomainMessengerGoerliAddress, - abi: l1CrossDomainMessengerGoerliABI, +export const l1FeeVaultConfig = { + address: l1FeeVaultAddress, + abi: l1FeeVaultABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// L1ERC721Bridge +// L1StandardBridge ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5a7749f83b81B301cAb5f48EB8516B986DAef23D) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) */ -export const l1Erc721BridgeABI = [ - { - stateMutability: 'nonpayable', - type: 'constructor', - inputs: [ - { name: '_messenger', internalType: 'address', type: 'address' }, - { name: '_otherBridge', internalType: 'address', type: 'address' }, - ], - }, +export const l1StandardBridgeABI = [ + { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, { type: 'event', anonymous: false, @@ -3355,7 +3350,7 @@ export const l1Erc721BridgeABI = [ { name: 'from', internalType: 'address', type: 'address', indexed: true }, { name: 'to', internalType: 'address', type: 'address', indexed: false }, { - name: 'tokenId', + name: 'amount', internalType: 'uint256', type: 'uint256', indexed: false, @@ -3367,7 +3362,7 @@ export const l1Erc721BridgeABI = [ indexed: false, }, ], - name: 'ERC721BridgeFinalized', + name: 'ERC20BridgeFinalized', }, { type: 'event', @@ -3388,7 +3383,7 @@ export const l1Erc721BridgeABI = [ { name: 'from', internalType: 'address', type: 'address', indexed: true }, { name: 'to', internalType: 'address', type: 'address', indexed: false }, { - name: 'tokenId', + name: 'amount', internalType: 'uint256', type: 'uint256', indexed: false, @@ -3400,125 +3395,20 @@ export const l1Erc721BridgeABI = [ indexed: false, }, ], - name: 'ERC721BridgeInitiated', - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'bridgeERC721', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'bridgeERC721To', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [ - { name: '', internalType: 'address', type: 'address' }, - { name: '', internalType: 'address', type: 'address' }, - { name: '', internalType: 'uint256', type: 'uint256' }, - ], - name: 'deposits', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_from', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'finalizeBridgeERC721', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'messenger', - outputs: [ - { - name: '', - internalType: 'contract CrossDomainMessenger', - type: 'address', - }, - ], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'otherBridge', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + name: 'ERC20BridgeInitiated', }, -] as const - -/** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5a7749f83b81B301cAb5f48EB8516B986DAef23D) - */ -export const l1Erc721BridgeAddress = { - 1: '0x5a7749f83b81B301cAb5f48EB8516B986DAef23D', -} as const - -/** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5a7749f83b81B301cAb5f48EB8516B986DAef23D) - */ -export const l1Erc721BridgeConfig = { - address: l1Erc721BridgeAddress, - abi: l1Erc721BridgeABI, -} as const - -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// L1ERC721Bridge_goerli -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9) - */ -export const l1Erc721BridgeGoerliABI = [ - { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, { type: 'event', anonymous: false, inputs: [ { - name: 'localToken', + name: 'l1Token', internalType: 'address', type: 'address', indexed: true, }, { - name: 'remoteToken', + name: 'l2Token', internalType: 'address', type: 'address', indexed: true, @@ -3526,7 +3416,7 @@ export const l1Erc721BridgeGoerliABI = [ { name: 'from', internalType: 'address', type: 'address', indexed: true }, { name: 'to', internalType: 'address', type: 'address', indexed: false }, { - name: 'tokenId', + name: 'amount', internalType: 'uint256', type: 'uint256', indexed: false, @@ -3538,20 +3428,20 @@ export const l1Erc721BridgeGoerliABI = [ indexed: false, }, ], - name: 'ERC721BridgeFinalized', + name: 'ERC20DepositInitiated', }, { type: 'event', anonymous: false, inputs: [ { - name: 'localToken', + name: 'l1Token', internalType: 'address', type: 'address', indexed: true, }, { - name: 'remoteToken', + name: 'l2Token', internalType: 'address', type: 'address', indexed: true, @@ -3559,7 +3449,7 @@ export const l1Erc721BridgeGoerliABI = [ { name: 'from', internalType: 'address', type: 'address', indexed: true }, { name: 'to', internalType: 'address', type: 'address', indexed: false }, { - name: 'tokenId', + name: 'amount', internalType: 'uint256', type: 'uint256', indexed: false, @@ -3571,41 +3461,194 @@ export const l1Erc721BridgeGoerliABI = [ indexed: false, }, ], - name: 'ERC721BridgeInitiated', + name: 'ERC20WithdrawalFinalized', }, { type: 'event', anonymous: false, inputs: [ - { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, - ], - name: 'Initialized', - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { name: 'from', internalType: 'address', type: 'address', indexed: true }, + { name: 'to', internalType: 'address', type: 'address', indexed: true }, + { + name: 'amount', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + { + name: 'extraData', + internalType: 'bytes', + type: 'bytes', + indexed: false, + }, ], - name: 'bridgeERC721', - outputs: [], + name: 'ETHBridgeFinalized', }, { - stateMutability: 'nonpayable', - type: 'function', + type: 'event', + anonymous: false, inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, + { name: 'from', internalType: 'address', type: 'address', indexed: true }, + { name: 'to', internalType: 'address', type: 'address', indexed: true }, + { + name: 'amount', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + { + name: 'extraData', + internalType: 'bytes', + type: 'bytes', + indexed: false, + }, + ], + name: 'ETHBridgeInitiated', + }, + { + type: 'event', + anonymous: false, + inputs: [ + { name: 'from', internalType: 'address', type: 'address', indexed: true }, + { name: 'to', internalType: 'address', type: 'address', indexed: true }, + { + name: 'amount', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + { + name: 'extraData', + internalType: 'bytes', + type: 'bytes', + indexed: false, + }, + ], + name: 'ETHDepositInitiated', + }, + { + type: 'event', + anonymous: false, + inputs: [ + { name: 'from', internalType: 'address', type: 'address', indexed: true }, + { name: 'to', internalType: 'address', type: 'address', indexed: true }, + { + name: 'amount', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + { + name: 'extraData', + internalType: 'bytes', + type: 'bytes', + indexed: false, + }, + ], + name: 'ETHWithdrawalFinalized', + }, + { + type: 'event', + anonymous: false, + inputs: [ + { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, + ], + name: 'Initialized', + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { name: '_localToken', internalType: 'address', type: 'address' }, + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'bridgeERC20', + outputs: [], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { name: '_localToken', internalType: 'address', type: 'address' }, { name: '_remoteToken', internalType: 'address', type: 'address' }, { name: '_to', internalType: 'address', type: 'address' }, - { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, { name: '_extraData', internalType: 'bytes', type: 'bytes' }, ], - name: 'bridgeERC721To', + name: 'bridgeERC20To', + outputs: [], + }, + { + stateMutability: 'payable', + type: 'function', + inputs: [ + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'bridgeETH', + outputs: [], + }, + { + stateMutability: 'payable', + type: 'function', + inputs: [ + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'bridgeETHTo', + outputs: [], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { name: '_l1Token', internalType: 'address', type: 'address' }, + { name: '_l2Token', internalType: 'address', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'depositERC20', + outputs: [], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { name: '_l1Token', internalType: 'address', type: 'address' }, + { name: '_l2Token', internalType: 'address', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'depositERC20To', + outputs: [], + }, + { + stateMutability: 'payable', + type: 'function', + inputs: [ + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'depositETH', + outputs: [], + }, + { + stateMutability: 'payable', + type: 'function', + inputs: [ + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'depositETHTo', outputs: [], }, { @@ -3614,10 +3657,9 @@ export const l1Erc721BridgeGoerliABI = [ inputs: [ { name: '', internalType: 'address', type: 'address' }, { name: '', internalType: 'address', type: 'address' }, - { name: '', internalType: 'uint256', type: 'uint256' }, ], name: 'deposits', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'nonpayable', @@ -3627,10 +3669,48 @@ export const l1Erc721BridgeGoerliABI = [ { name: '_remoteToken', internalType: 'address', type: 'address' }, { name: '_from', internalType: 'address', type: 'address' }, { name: '_to', internalType: 'address', type: 'address' }, - { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, { name: '_extraData', internalType: 'bytes', type: 'bytes' }, ], - name: 'finalizeBridgeERC721', + name: 'finalizeBridgeERC20', + outputs: [], + }, + { + stateMutability: 'payable', + type: 'function', + inputs: [ + { name: '_from', internalType: 'address', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'finalizeBridgeETH', + outputs: [], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { name: '_l1Token', internalType: 'address', type: 'address' }, + { name: '_l2Token', internalType: 'address', type: 'address' }, + { name: '_from', internalType: 'address', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'finalizeERC20Withdrawal', + outputs: [], + }, + { + stateMutability: 'payable', + type: 'function', + inputs: [ + { name: '_from', internalType: 'address', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'finalizeETHWithdrawal', outputs: [], }, { @@ -3646,6 +3726,13 @@ export const l1Erc721BridgeGoerliABI = [ name: 'initialize', outputs: [], }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'l2TokenBridge', + outputs: [{ name: '', internalType: 'address', type: 'address' }], + }, { stateMutability: 'view', type: 'function', @@ -3664,7 +3751,9 @@ export const l1Erc721BridgeGoerliABI = [ type: 'function', inputs: [], name: 'otherBridge', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + outputs: [ + { name: '', internalType: 'contract StandardBridge', type: 'address' }, + ], }, { stateMutability: 'view', @@ -3673,77 +3762,264 @@ export const l1Erc721BridgeGoerliABI = [ name: 'version', outputs: [{ name: '', internalType: 'string', type: 'string' }], }, + { stateMutability: 'payable', type: 'receive' }, ] as const /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) */ -export const l1Erc721BridgeGoerliAddress = { - 5: '0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9', +export const l1StandardBridgeAddress = { + 1: '0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1', + 5: '0x636Af16bf2f682dD3109e60102b8E1A089FedAa8', } as const /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) */ -export const l1Erc721BridgeGoerliConfig = { - address: l1Erc721BridgeGoerliAddress, - abi: l1Erc721BridgeGoerliABI, +export const l1StandardBridgeConfig = { + address: l1StandardBridgeAddress, + abi: l1StandardBridgeABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// L1FeeVault +// L2CrossDomainMessenger ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000001a) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) */ -export const l1FeeVaultABI = [ +export const l2CrossDomainMessengerABI = [ { stateMutability: 'nonpayable', type: 'constructor', - inputs: [{ name: '_recipient', internalType: 'address', type: 'address' }], + inputs: [ + { + name: '_l1CrossDomainMessenger', + internalType: 'address', + type: 'address', + }, + ], }, { type: 'event', anonymous: false, inputs: [ { - name: 'value', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - { name: 'to', internalType: 'address', type: 'address', indexed: false }, - { - name: 'from', - internalType: 'address', - type: 'address', - indexed: false, + name: 'msgHash', + internalType: 'bytes32', + type: 'bytes32', + indexed: true, }, ], - name: 'Withdrawal', + name: 'FailedRelayedMessage', }, { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'MIN_WITHDRAWAL_AMOUNT', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + type: 'event', + anonymous: false, + inputs: [ + { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, + ], + name: 'Initialized', + }, + { + type: 'event', + anonymous: false, + inputs: [ + { + name: 'msgHash', + internalType: 'bytes32', + type: 'bytes32', + indexed: true, + }, + ], + name: 'RelayedMessage', + }, + { + type: 'event', + anonymous: false, + inputs: [ + { + name: 'target', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'sender', + internalType: 'address', + type: 'address', + indexed: false, + }, + { name: 'message', internalType: 'bytes', type: 'bytes', indexed: false }, + { + name: 'messageNonce', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + { + name: 'gasLimit', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + ], + name: 'SentMessage', + }, + { + type: 'event', + anonymous: false, + inputs: [ + { + name: 'sender', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'value', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + ], + name: 'SentMessageExtension1', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'RECIPIENT', + name: 'MESSAGE_VERSION', + outputs: [{ name: '', internalType: 'uint16', type: 'uint16' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'MIN_GAS_CALLDATA_OVERHEAD', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'MIN_GAS_DYNAMIC_OVERHEAD_DENOMINATOR', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'MIN_GAS_DYNAMIC_OVERHEAD_NUMERATOR', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'OTHER_MESSENGER', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'totalProcessed', + name: 'RELAY_CALL_OVERHEAD', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'RELAY_CONSTANT_OVERHEAD', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'RELAY_GAS_CHECK_BUFFER', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'RELAY_RESERVED_GAS', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + }, + { + stateMutability: 'pure', + type: 'function', + inputs: [ + { name: '_message', internalType: 'bytes', type: 'bytes' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + ], + name: 'baseGas', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'failedMessages', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [], + name: 'initialize', + outputs: [], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'l1CrossDomainMessenger', + outputs: [{ name: '', internalType: 'address', type: 'address' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'messageNonce', outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, + { + stateMutability: 'payable', + type: 'function', + inputs: [ + { name: '_nonce', internalType: 'uint256', type: 'uint256' }, + { name: '_sender', internalType: 'address', type: 'address' }, + { name: '_target', internalType: 'address', type: 'address' }, + { name: '_value', internalType: 'uint256', type: 'uint256' }, + { name: '_minGasLimit', internalType: 'uint256', type: 'uint256' }, + { name: '_message', internalType: 'bytes', type: 'bytes' }, + ], + name: 'relayMessage', + outputs: [], + }, + { + stateMutability: 'payable', + type: 'function', + inputs: [ + { name: '_target', internalType: 'address', type: 'address' }, + { name: '_message', internalType: 'bytes', type: 'bytes' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + ], + name: 'sendMessage', + outputs: [], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'successfulMessages', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + }, { stateMutability: 'view', type: 'function', @@ -3752,43 +4028,44 @@ export const l1FeeVaultABI = [ outputs: [{ name: '', internalType: 'string', type: 'string' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', inputs: [], - name: 'withdraw', - outputs: [], + name: 'xDomainMessageSender', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, - { stateMutability: 'payable', type: 'receive' }, ] as const /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000001a) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) */ -export const l1FeeVaultAddress = { - 420: '0x420000000000000000000000000000000000001A', +export const l2CrossDomainMessengerAddress = { + 420: '0x4200000000000000000000000000000000000007', } as const /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000001a) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) */ -export const l1FeeVaultConfig = { - address: l1FeeVaultAddress, - abi: l1FeeVaultABI, +export const l2CrossDomainMessengerConfig = { + address: l2CrossDomainMessengerAddress, + abi: l2CrossDomainMessengerABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// L1StandardBridge +// L2ERC721Bridge ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000014) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000014) */ -export const l1StandardBridgeABI = [ +export const l2Erc721BridgeABI = [ { stateMutability: 'nonpayable', type: 'constructor', inputs: [ - { name: '_messenger', internalType: 'address payable', type: 'address' }, + { name: '_messenger', internalType: 'address', type: 'address' }, + { name: '_otherBridge', internalType: 'address', type: 'address' }, ], }, { @@ -3810,7 +4087,7 @@ export const l1StandardBridgeABI = [ { name: 'from', internalType: 'address', type: 'address', indexed: true }, { name: 'to', internalType: 'address', type: 'address', indexed: false }, { - name: 'amount', + name: 'tokenId', internalType: 'uint256', type: 'uint256', indexed: false, @@ -3822,7 +4099,7 @@ export const l1StandardBridgeABI = [ indexed: false, }, ], - name: 'ERC20BridgeFinalized', + name: 'ERC721BridgeFinalized', }, { type: 'event', @@ -3843,7 +4120,7 @@ export const l1StandardBridgeABI = [ { name: 'from', internalType: 'address', type: 'address', indexed: true }, { name: 'to', internalType: 'address', type: 'address', indexed: false }, { - name: 'amount', + name: 'tokenId', internalType: 'uint256', type: 'uint256', indexed: false, @@ -3855,344 +4132,347 @@ export const l1StandardBridgeABI = [ indexed: false, }, ], - name: 'ERC20BridgeInitiated', + name: 'ERC721BridgeInitiated', }, { - type: 'event', - anonymous: false, + stateMutability: 'nonpayable', + type: 'function', inputs: [ - { - name: 'l1Token', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'l2Token', - internalType: 'address', - type: 'address', - indexed: true, - }, - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: false }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, - }, + { name: '_localToken', internalType: 'address', type: 'address' }, + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, ], - name: 'ERC20DepositInitiated', + name: 'bridgeERC721', + outputs: [], }, { - type: 'event', - anonymous: false, + stateMutability: 'nonpayable', + type: 'function', inputs: [ + { name: '_localToken', internalType: 'address', type: 'address' }, + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'bridgeERC721To', + outputs: [], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { name: '_localToken', internalType: 'address', type: 'address' }, + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_from', internalType: 'address', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'finalizeBridgeERC721', + outputs: [], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'messenger', + outputs: [ { - name: 'l1Token', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'l2Token', - internalType: 'address', + name: '', + internalType: 'contract CrossDomainMessenger', type: 'address', - indexed: true, - }, - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: false }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, }, ], - name: 'ERC20WithdrawalFinalized', }, { - type: 'event', - anonymous: false, + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'otherBridge', + outputs: [{ name: '', internalType: 'address', type: 'address' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'version', + outputs: [{ name: '', internalType: 'string', type: 'string' }], + }, +] as const + +/** + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000014) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000014) + */ +export const l2Erc721BridgeAddress = { + 10: '0x4200000000000000000000000000000000000014', + 420: '0x4200000000000000000000000000000000000014', +} as const + +/** + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000014) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000014) + */ +export const l2Erc721BridgeConfig = { + address: l2Erc721BridgeAddress, + abi: l2Erc721BridgeABI, +} as const + +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// L2OutputOracle +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/** + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) + */ +export const l2OutputOracleABI = [ + { + stateMutability: 'nonpayable', + type: 'constructor', inputs: [ - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, + { name: '_submissionInterval', internalType: 'uint256', type: 'uint256' }, + { name: '_l2BlockTime', internalType: 'uint256', type: 'uint256' }, { - name: 'amount', + name: '_finalizationPeriodSeconds', internalType: 'uint256', type: 'uint256', - indexed: false, - }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, }, ], - name: 'ETHBridgeFinalized', }, { type: 'event', anonymous: false, inputs: [ - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, - }, + { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, ], - name: 'ETHBridgeInitiated', + name: 'Initialized', }, { type: 'event', anonymous: false, inputs: [ - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, { - name: 'amount', + name: 'outputRoot', + internalType: 'bytes32', + type: 'bytes32', + indexed: true, + }, + { + name: 'l2OutputIndex', internalType: 'uint256', type: 'uint256', - indexed: false, + indexed: true, }, { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', + name: 'l2BlockNumber', + internalType: 'uint256', + type: 'uint256', + indexed: true, + }, + { + name: 'l1Timestamp', + internalType: 'uint256', + type: 'uint256', indexed: false, }, ], - name: 'ETHDepositInitiated', + name: 'OutputProposed', }, { type: 'event', anonymous: false, inputs: [ - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, { - name: 'amount', + name: 'prevNextOutputIndex', internalType: 'uint256', type: 'uint256', - indexed: false, + indexed: true, }, { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, + name: 'newNextOutputIndex', + internalType: 'uint256', + type: 'uint256', + indexed: true, }, ], - name: 'ETHWithdrawalFinalized', + name: 'OutputsDeleted', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'OTHER_BRIDGE', - outputs: [ - { name: '', internalType: 'contract StandardBridge', type: 'address' }, - ], + name: 'challenger', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, ], - name: 'bridgeERC20', - outputs: [], + name: 'computeL2Timestamp', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, ], - name: 'bridgeERC20To', + name: 'deleteL2Outputs', outputs: [], }, { - stateMutability: 'payable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'bridgeETH', - outputs: [], + inputs: [], + name: 'finalizationPeriodSeconds', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { - stateMutability: 'payable', + stateMutability: 'view', type: 'function', inputs: [ - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, + ], + name: 'getL2Output', + outputs: [ + { + name: '', + internalType: 'struct Types.OutputProposal', + type: 'tuple', + components: [ + { name: 'outputRoot', internalType: 'bytes32', type: 'bytes32' }, + { name: 'timestamp', internalType: 'uint128', type: 'uint128' }, + { name: 'l2BlockNumber', internalType: 'uint128', type: 'uint128' }, + ], + }, ], - name: 'bridgeETHTo', - outputs: [], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', inputs: [ - { name: '_l1Token', internalType: 'address', type: 'address' }, - { name: '_l2Token', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, + ], + name: 'getL2OutputAfter', + outputs: [ + { + name: '', + internalType: 'struct Types.OutputProposal', + type: 'tuple', + components: [ + { name: 'outputRoot', internalType: 'bytes32', type: 'bytes32' }, + { name: 'timestamp', internalType: 'uint128', type: 'uint128' }, + { name: 'l2BlockNumber', internalType: 'uint128', type: 'uint128' }, + ], + }, ], - name: 'depositERC20', - outputs: [], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', inputs: [ - { name: '_l1Token', internalType: 'address', type: 'address' }, - { name: '_l2Token', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, ], - name: 'depositERC20To', - outputs: [], + name: 'getL2OutputIndexAfter', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { - stateMutability: 'payable', + stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { + name: '_startingBlockNumber', + internalType: 'uint256', + type: 'uint256', + }, + { name: '_startingTimestamp', internalType: 'uint256', type: 'uint256' }, + { name: '_proposer', internalType: 'address', type: 'address' }, + { name: '_challenger', internalType: 'address', type: 'address' }, ], - name: 'depositETH', + name: 'initialize', outputs: [], }, { - stateMutability: 'payable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'depositETHTo', - outputs: [], + inputs: [], + name: 'l2BlockTime', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', - inputs: [ - { name: '', internalType: 'address', type: 'address' }, - { name: '', internalType: 'address', type: 'address' }, - ], - name: 'deposits', + inputs: [], + name: 'latestBlockNumber', outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_from', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'finalizeBridgeERC20', - outputs: [], + inputs: [], + name: 'latestOutputIndex', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { - stateMutability: 'payable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_from', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'finalizeBridgeETH', - outputs: [], + inputs: [], + name: 'nextBlockNumber', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_l1Token', internalType: 'address', type: 'address' }, - { name: '_l2Token', internalType: 'address', type: 'address' }, - { name: '_from', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'finalizeERC20Withdrawal', - outputs: [], + inputs: [], + name: 'nextOutputIndex', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'payable', type: 'function', inputs: [ - { name: '_from', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { name: '_outputRoot', internalType: 'bytes32', type: 'bytes32' }, + { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, + { name: '_l1BlockHash', internalType: 'bytes32', type: 'bytes32' }, + { name: '_l1BlockNumber', internalType: 'uint256', type: 'uint256' }, ], - name: 'finalizeETHWithdrawal', + name: 'proposeL2Output', outputs: [], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'l2TokenBridge', + name: 'proposer', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'messenger', - outputs: [ - { - name: '', - internalType: 'contract CrossDomainMessenger', - type: 'address', - }, - ], + name: 'startingBlockNumber', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'startingTimestamp', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'submissionInterval', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', @@ -4201,78 +4481,57 @@ export const l1StandardBridgeABI = [ name: 'version', outputs: [{ name: '', internalType: 'string', type: 'string' }], }, - { stateMutability: 'payable', type: 'receive' }, ] as const /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) */ -export const l1StandardBridgeAddress = { - 1: '0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1', +export const l2OutputOracleAddress = { + 1: '0xdfe97868233d1aa22e815a266982f2cf17685a27', + 5: '0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0', } as const /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) */ -export const l1StandardBridgeConfig = { - address: l1StandardBridgeAddress, - abi: l1StandardBridgeABI, +export const l2OutputOracleConfig = { + address: l2OutputOracleAddress, + abi: l2OutputOracleABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// L1StandardBridge_goerli +// L2StandardBridge ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) */ -export const l1StandardBridgeGoerliABI = [ - { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, +export const l2StandardBridgeABI = [ { - type: 'event', - anonymous: false, + stateMutability: 'nonpayable', + type: 'constructor', inputs: [ { - name: 'localToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'remoteToken', - internalType: 'address', + name: '_otherBridge', + internalType: 'address payable', type: 'address', - indexed: true, - }, - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: false }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, }, ], - name: 'ERC20BridgeFinalized', }, { type: 'event', anonymous: false, inputs: [ { - name: 'localToken', + name: 'l1Token', internalType: 'address', type: 'address', indexed: true, }, { - name: 'remoteToken', + name: 'l2Token', internalType: 'address', type: 'address', indexed: true, @@ -4292,20 +4551,20 @@ export const l1StandardBridgeGoerliABI = [ indexed: false, }, ], - name: 'ERC20BridgeInitiated', + name: 'DepositFinalized', }, { type: 'event', anonymous: false, inputs: [ { - name: 'l1Token', + name: 'localToken', internalType: 'address', type: 'address', indexed: true, }, { - name: 'l2Token', + name: 'remoteToken', internalType: 'address', type: 'address', indexed: true, @@ -4325,20 +4584,20 @@ export const l1StandardBridgeGoerliABI = [ indexed: false, }, ], - name: 'ERC20DepositInitiated', + name: 'ERC20BridgeFinalized', }, { type: 'event', anonymous: false, inputs: [ { - name: 'l1Token', + name: 'localToken', internalType: 'address', type: 'address', indexed: true, }, { - name: 'l2Token', + name: 'remoteToken', internalType: 'address', type: 'address', indexed: true, @@ -4358,7 +4617,7 @@ export const l1StandardBridgeGoerliABI = [ indexed: false, }, ], - name: 'ERC20WithdrawalFinalized', + name: 'ERC20BridgeInitiated', }, { type: 'event', @@ -4406,29 +4665,20 @@ export const l1StandardBridgeGoerliABI = [ type: 'event', anonymous: false, inputs: [ - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, + name: 'l1Token', + internalType: 'address', + type: 'address', + indexed: true, }, { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, + name: 'l2Token', + internalType: 'address', + type: 'address', + indexed: true, }, - ], - name: 'ETHDepositInitiated', - }, - { - type: 'event', - anonymous: false, - inputs: [ { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, + { name: 'to', internalType: 'address', type: 'address', indexed: false }, { name: 'amount', internalType: 'uint256', @@ -4442,15 +4692,16 @@ export const l1StandardBridgeGoerliABI = [ indexed: false, }, ], - name: 'ETHWithdrawalFinalized', + name: 'WithdrawalInitiated', }, { - type: 'event', - anonymous: false, - inputs: [ - { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'OTHER_BRIDGE', + outputs: [ + { name: '', internalType: 'contract StandardBridge', type: 'address' }, ], - name: 'Initialized', }, { stateMutability: 'nonpayable', @@ -4501,59 +4752,11 @@ export const l1StandardBridgeGoerliABI = [ outputs: [], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', inputs: [ - { name: '_l1Token', internalType: 'address', type: 'address' }, - { name: '_l2Token', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'depositERC20', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_l1Token', internalType: 'address', type: 'address' }, - { name: '_l2Token', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'depositERC20To', - outputs: [], - }, - { - stateMutability: 'payable', - type: 'function', - inputs: [ - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'depositETH', - outputs: [], - }, - { - stateMutability: 'payable', - type: 'function', - inputs: [ - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'depositETHTo', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [ - { name: '', internalType: 'address', type: 'address' }, - { name: '', internalType: 'address', type: 'address' }, + { name: '', internalType: 'address', type: 'address' }, + { name: '', internalType: 'address', type: 'address' }, ], name: 'deposits', outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], @@ -4585,7 +4788,7 @@ export const l1StandardBridgeGoerliABI = [ outputs: [], }, { - stateMutability: 'nonpayable', + stateMutability: 'payable', type: 'function', inputs: [ { name: '_l1Token', internalType: 'address', type: 'address' }, @@ -4595,39 +4798,14 @@ export const l1StandardBridgeGoerliABI = [ { name: '_amount', internalType: 'uint256', type: 'uint256' }, { name: '_extraData', internalType: 'bytes', type: 'bytes' }, ], - name: 'finalizeERC20Withdrawal', - outputs: [], - }, - { - stateMutability: 'payable', - type: 'function', - inputs: [ - { name: '_from', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'finalizeETHWithdrawal', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { - name: '_messenger', - internalType: 'contract CrossDomainMessenger', - type: 'address', - }, - ], - name: 'initialize', + name: 'finalizeDeposit', outputs: [], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'l2TokenBridge', + name: 'l1TokenBridge', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { @@ -4647,108 +4825,85 @@ export const l1StandardBridgeGoerliABI = [ stateMutability: 'view', type: 'function', inputs: [], - name: 'otherBridge', - outputs: [ - { name: '', internalType: 'contract StandardBridge', type: 'address' }, + name: 'version', + outputs: [{ name: '', internalType: 'string', type: 'string' }], + }, + { + stateMutability: 'payable', + type: 'function', + inputs: [ + { name: '_l2Token', internalType: 'address', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, ], + name: 'withdraw', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'payable', type: 'function', - inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + inputs: [ + { name: '_l2Token', internalType: 'address', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'withdrawTo', + outputs: [], }, { stateMutability: 'payable', type: 'receive' }, ] as const /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) */ -export const l1StandardBridgeGoerliAddress = { - 5: '0x636Af16bf2f682dD3109e60102b8E1A089FedAa8', +export const l2StandardBridgeAddress = { + 420: '0x4200000000000000000000000000000000000010', } as const /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) */ -export const l1StandardBridgeGoerliConfig = { - address: l1StandardBridgeGoerliAddress, - abi: l1StandardBridgeGoerliABI, +export const l2StandardBridgeConfig = { + address: l2StandardBridgeAddress, + abi: l2StandardBridgeABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// L2CrossDomainMessenger +// L2ToL1MessagePasser ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000016) */ -export const l2CrossDomainMessengerABI = [ - { - stateMutability: 'nonpayable', - type: 'constructor', - inputs: [ - { - name: '_l1CrossDomainMessenger', - internalType: 'address', - type: 'address', - }, - ], - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'msgHash', - internalType: 'bytes32', - type: 'bytes32', - indexed: true, - }, - ], - name: 'FailedRelayedMessage', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, - ], - name: 'Initialized', - }, +export const l2ToL1MessagePasserABI = [ + { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, { type: 'event', anonymous: false, inputs: [ { - name: 'msgHash', - internalType: 'bytes32', - type: 'bytes32', + name: 'nonce', + internalType: 'uint256', + type: 'uint256', indexed: true, }, - ], - name: 'RelayedMessage', - }, - { - type: 'event', - anonymous: false, - inputs: [ { - name: 'target', + name: 'sender', internalType: 'address', type: 'address', indexed: true, }, { - name: 'sender', + name: 'target', internalType: 'address', type: 'address', - indexed: false, + indexed: true, }, - { name: 'message', internalType: 'bytes', type: 'bytes', indexed: false }, { - name: 'messageNonce', + name: 'value', internalType: 'uint256', type: 'uint256', indexed: false, @@ -4759,27 +4914,28 @@ export const l2CrossDomainMessengerABI = [ type: 'uint256', indexed: false, }, + { name: 'data', internalType: 'bytes', type: 'bytes', indexed: false }, + { + name: 'withdrawalHash', + internalType: 'bytes32', + type: 'bytes32', + indexed: false, + }, ], - name: 'SentMessage', + name: 'MessagePassed', }, { type: 'event', anonymous: false, inputs: [ { - name: 'sender', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'value', + name: 'amount', internalType: 'uint256', type: 'uint256', - indexed: false, + indexed: true, }, ], - name: 'SentMessageExtension1', + name: 'WithdrawerBalanceBurnt', }, { stateMutability: 'view', @@ -4789,178 +4945,211 @@ export const l2CrossDomainMessengerABI = [ outputs: [{ name: '', internalType: 'uint16', type: 'uint16' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', inputs: [], - name: 'MIN_GAS_CALLDATA_OVERHEAD', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + name: 'burn', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'payable', type: 'function', - inputs: [], - name: 'MIN_GAS_DYNAMIC_OVERHEAD_DENOMINATOR', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + inputs: [ + { name: '_target', internalType: 'address', type: 'address' }, + { name: '_gasLimit', internalType: 'uint256', type: 'uint256' }, + { name: '_data', internalType: 'bytes', type: 'bytes' }, + ], + name: 'initiateWithdrawal', + outputs: [], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'MIN_GAS_DYNAMIC_OVERHEAD_NUMERATOR', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + name: 'messageNonce', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', - inputs: [], - name: 'OTHER_MESSENGER', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'sentMessages', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'RELAY_CALL_OVERHEAD', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + name: 'version', + outputs: [{ name: '', internalType: 'string', type: 'string' }], }, + { stateMutability: 'payable', type: 'receive' }, +] as const + +/** + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000016) + */ +export const l2ToL1MessagePasserAddress = { + 420: '0x4200000000000000000000000000000000000016', +} as const + +/** + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000016) + */ +export const l2ToL1MessagePasserConfig = { + address: l2ToL1MessagePasserAddress, + abi: l2ToL1MessagePasserABI, +} as const + +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// MintManager +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/** + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x5C4e7Ba1E219E47948e6e3F55019A647bA501005) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76) + */ +export const mintManagerABI = [ { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'RELAY_CONSTANT_OVERHEAD', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'RELAY_GAS_CHECK_BUFFER', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'RELAY_RESERVED_GAS', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + stateMutability: 'nonpayable', + type: 'constructor', + inputs: [ + { name: '_upgrader', internalType: 'address', type: 'address' }, + { name: '_governanceToken', internalType: 'address', type: 'address' }, + ], }, { - stateMutability: 'pure', - type: 'function', + type: 'event', + anonymous: false, inputs: [ - { name: '_message', internalType: 'bytes', type: 'bytes' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { + name: 'previousOwner', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'newOwner', + internalType: 'address', + type: 'address', + indexed: true, + }, ], - name: 'baseGas', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + name: 'OwnershipTransferred', }, { stateMutability: 'view', type: 'function', - inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - name: 'failedMessages', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', inputs: [], - name: 'initialize', - outputs: [], + name: 'DENOMINATOR', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'l1CrossDomainMessenger', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'MINT_CAP', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'messageNonce', + name: 'MINT_PERIOD', outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { - stateMutability: 'payable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_nonce', internalType: 'uint256', type: 'uint256' }, - { name: '_sender', internalType: 'address', type: 'address' }, - { name: '_target', internalType: 'address', type: 'address' }, - { name: '_value', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint256', type: 'uint256' }, - { name: '_message', internalType: 'bytes', type: 'bytes' }, + inputs: [], + name: 'governanceToken', + outputs: [ + { name: '', internalType: 'contract GovernanceToken', type: 'address' }, ], - name: 'relayMessage', - outputs: [], }, { - stateMutability: 'payable', + stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_target', internalType: 'address', type: 'address' }, - { name: '_message', internalType: 'bytes', type: 'bytes' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_account', internalType: 'address', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, ], - name: 'sendMessage', + name: 'mint', outputs: [], }, { stateMutability: 'view', type: 'function', - inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - name: 'successfulMessages', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + inputs: [], + name: 'mintPermittedAfter', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + name: 'owner', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', inputs: [], - name: 'xDomainMessageSender', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'renounceOwnership', + outputs: [], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], + name: 'transferOwnership', + outputs: [], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { name: '_newMintManager', internalType: 'address', type: 'address' }, + ], + name: 'upgrade', + outputs: [], }, ] as const /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x5C4e7Ba1E219E47948e6e3F55019A647bA501005) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76) */ -export const l2CrossDomainMessengerAddress = { - 420: '0x4200000000000000000000000000000000000007', +export const mintManagerAddress = { + 10: '0x5C4e7Ba1E219E47948e6e3F55019A647bA501005', + 420: '0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76', } as const /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x5C4e7Ba1E219E47948e6e3F55019A647bA501005) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76) */ -export const l2CrossDomainMessengerConfig = { - address: l2CrossDomainMessengerAddress, - abi: l2CrossDomainMessengerABI, +export const mintManagerConfig = { + address: mintManagerAddress, + abi: mintManagerABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// L2ERC721Bridge +// OptimismMintableERC20Factory ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000014) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000014) + * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000012) */ -export const l2Erc721BridgeABI = [ +export const optimismMintableErc20FactoryABI = [ + { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, { - stateMutability: 'nonpayable', - type: 'constructor', + type: 'event', + anonymous: false, inputs: [ - { name: '_messenger', internalType: 'address', type: 'address' }, - { name: '_otherBridge', internalType: 'address', type: 'address' }, + { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, ], + name: 'Initialized', }, { type: 'event', @@ -4978,116 +5167,81 @@ export const l2Erc721BridgeABI = [ type: 'address', indexed: true, }, - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: false }, - { - name: 'tokenId', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', + name: 'deployer', + internalType: 'address', + type: 'address', indexed: false, }, ], - name: 'ERC721BridgeFinalized', + name: 'OptimismMintableERC20Created', }, { type: 'event', anonymous: false, inputs: [ { - name: 'localToken', + name: 'remoteToken', internalType: 'address', type: 'address', indexed: true, }, { - name: 'remoteToken', + name: 'localToken', internalType: 'address', type: 'address', indexed: true, }, - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: false }, - { - name: 'tokenId', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, - }, ], - name: 'ERC721BridgeInitiated', + name: 'StandardL2TokenCreated', }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'bridgeERC721', - outputs: [], + inputs: [], + name: 'bridge', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, ], - name: 'bridgeERC721To', - outputs: [], + name: 'createOptimismMintableERC20', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_from', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, + { name: '_decimals', internalType: 'uint8', type: 'uint8' }, ], - name: 'finalizeBridgeERC721', - outputs: [], + name: 'createOptimismMintableERC20WithDecimals', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'messenger', - outputs: [ - { - name: '', - internalType: 'contract CrossDomainMessenger', - type: 'address', - }, + inputs: [ + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, ], + name: 'createStandardL2Token', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'otherBridge', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + inputs: [{ name: '_bridge', internalType: 'address', type: 'address' }], + name: 'initialize', + outputs: [], }, { stateMutability: 'view', @@ -5099,52 +5253,29 @@ export const l2Erc721BridgeABI = [ ] as const /** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000014) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000014) + * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000012) */ -export const l2Erc721BridgeAddress = { - 10: '0x4200000000000000000000000000000000000014', - 420: '0x4200000000000000000000000000000000000014', +export const optimismMintableErc20FactoryAddress = { + 1: '0x4200000000000000000000000000000000000012', } as const /** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000014) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000014) + * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000012) */ -export const l2Erc721BridgeConfig = { - address: l2Erc721BridgeAddress, - abi: l2Erc721BridgeABI, +export const optimismMintableErc20FactoryConfig = { + address: optimismMintableErc20FactoryAddress, + abi: optimismMintableErc20FactoryABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// L2OutputOracle +// OptimismMintableERC20Factory_goerli ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) + * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000012) */ -export const l2OutputOracleABI = [ - { - stateMutability: 'nonpayable', - type: 'constructor', - inputs: [ - { name: '_submissionInterval', internalType: 'uint256', type: 'uint256' }, - { name: '_l2BlockTime', internalType: 'uint256', type: 'uint256' }, - { - name: '_startingBlockNumber', - internalType: 'uint256', - type: 'uint256', - }, - { name: '_startingTimestamp', internalType: 'uint256', type: 'uint256' }, - { name: '_proposer', internalType: 'address', type: 'address' }, - { name: '_challenger', internalType: 'address', type: 'address' }, - { - name: '_finalizationPeriodSeconds', - internalType: 'uint256', - type: 'uint256', - }, - ], - }, +export const optimismMintableErc20FactoryGoerliABI = [ + { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, { type: 'event', anonymous: false, @@ -5158,219 +5289,298 @@ export const l2OutputOracleABI = [ anonymous: false, inputs: [ { - name: 'outputRoot', - internalType: 'bytes32', - type: 'bytes32', - indexed: true, - }, - { - name: 'l2OutputIndex', - internalType: 'uint256', - type: 'uint256', + name: 'localToken', + internalType: 'address', + type: 'address', indexed: true, }, { - name: 'l2BlockNumber', - internalType: 'uint256', - type: 'uint256', + name: 'remoteToken', + internalType: 'address', + type: 'address', indexed: true, }, { - name: 'l1Timestamp', - internalType: 'uint256', - type: 'uint256', + name: 'deployer', + internalType: 'address', + type: 'address', indexed: false, }, ], - name: 'OutputProposed', + name: 'OptimismMintableERC20Created', }, { type: 'event', anonymous: false, inputs: [ { - name: 'prevNextOutputIndex', - internalType: 'uint256', - type: 'uint256', + name: 'remoteToken', + internalType: 'address', + type: 'address', indexed: true, }, { - name: 'newNextOutputIndex', - internalType: 'uint256', - type: 'uint256', + name: 'localToken', + internalType: 'address', + type: 'address', indexed: true, }, ], - name: 'OutputsDeleted', + name: 'StandardL2TokenCreated', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'CHALLENGER', + name: 'bridge', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'FINALIZATION_PERIOD_SECONDS', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + inputs: [ + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, + ], + name: 'createOptimismMintableERC20', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'L2_BLOCK_TIME', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + inputs: [ + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, + { name: '_decimals', internalType: 'uint8', type: 'uint8' }, + ], + name: 'createOptimismMintableERC20WithDecimals', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'PROPOSER', + inputs: [ + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, + ], + name: 'createStandardL2Token', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'SUBMISSION_INTERVAL', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + inputs: [{ name: '_bridge', internalType: 'address', type: 'address' }], + name: 'initialize', + outputs: [], }, { stateMutability: 'view', type: 'function', - inputs: [ - { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, - ], - name: 'computeL2Timestamp', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + inputs: [], + name: 'version', + outputs: [{ name: '', internalType: 'string', type: 'string' }], }, +] as const + +/** + * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000012) + */ +export const optimismMintableErc20FactoryGoerliAddress = { + 5: '0x4200000000000000000000000000000000000012', +} as const + +/** + * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000012) + */ +export const optimismMintableErc20FactoryGoerliConfig = { + address: optimismMintableErc20FactoryGoerliAddress, + abi: optimismMintableErc20FactoryGoerliABI, +} as const + +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// OptimismMintableERC20Factory_optimism-goerli +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/** + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000012) + */ +export const optimismMintableErc20FactoryOptimismGoerliABI = [ { stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, - ], - name: 'deleteL2Outputs', - outputs: [], + type: 'constructor', + inputs: [{ name: '_bridge', internalType: 'address', type: 'address' }], }, { - stateMutability: 'view', - type: 'function', + type: 'event', + anonymous: false, inputs: [ - { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, - ], - name: 'getL2Output', - outputs: [ { - name: '', - internalType: 'struct Types.OutputProposal', - type: 'tuple', - components: [ - { name: 'outputRoot', internalType: 'bytes32', type: 'bytes32' }, - { name: 'timestamp', internalType: 'uint128', type: 'uint128' }, - { name: 'l2BlockNumber', internalType: 'uint128', type: 'uint128' }, - ], + name: 'localToken', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'remoteToken', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'deployer', + internalType: 'address', + type: 'address', + indexed: false, }, ], + name: 'OptimismMintableERC20Created', }, { - stateMutability: 'view', - type: 'function', + type: 'event', + anonymous: false, inputs: [ - { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, - ], - name: 'getL2OutputAfter', - outputs: [ { - name: '', - internalType: 'struct Types.OutputProposal', - type: 'tuple', - components: [ - { name: 'outputRoot', internalType: 'bytes32', type: 'bytes32' }, - { name: 'timestamp', internalType: 'uint128', type: 'uint128' }, - { name: 'l2BlockNumber', internalType: 'uint128', type: 'uint128' }, - ], + name: 'remoteToken', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'localToken', + internalType: 'address', + type: 'address', + indexed: true, }, ], + name: 'StandardL2TokenCreated', }, { stateMutability: 'view', type: 'function', - inputs: [ - { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, - ], - name: 'getL2OutputIndexAfter', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + inputs: [], + name: 'BRIDGE', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { - name: '_startingBlockNumber', - internalType: 'uint256', - type: 'uint256', - }, - { name: '_startingTimestamp', internalType: 'uint256', type: 'uint256' }, + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, ], - name: 'initialize', - outputs: [], + name: 'createOptimismMintableERC20', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'latestBlockNumber', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + inputs: [ + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, + ], + name: 'createStandardL2Token', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'latestOutputIndex', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'version', + outputs: [{ name: '', internalType: 'string', type: 'string' }], }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'nextBlockNumber', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], +] as const + +/** + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000012) + */ +export const optimismMintableErc20FactoryOptimismGoerliAddress = { + 420: '0x4200000000000000000000000000000000000012', +} as const + +/** + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000012) + */ +export const optimismMintableErc20FactoryOptimismGoerliConfig = { + address: optimismMintableErc20FactoryOptimismGoerliAddress, + abi: optimismMintableErc20FactoryOptimismGoerliABI, +} as const + +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// OptimismMintableERC721Factory +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/** + * [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000017) + */ +export const optimismMintableErc721FactoryABI = [ + { + stateMutability: 'nonpayable', + type: 'constructor', + inputs: [ + { name: '_bridge', internalType: 'address', type: 'address' }, + { name: '_remoteChainId', internalType: 'uint256', type: 'uint256' }, + ], + }, + { + type: 'event', + anonymous: false, + inputs: [ + { + name: 'localToken', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'remoteToken', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'deployer', + internalType: 'address', + type: 'address', + indexed: false, + }, + ], + name: 'OptimismMintableERC721Created', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'nextOutputIndex', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'bridge', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'payable', + stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_outputRoot', internalType: 'bytes32', type: 'bytes32' }, - { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, - { name: '_l1BlockHash', internalType: 'bytes32', type: 'bytes32' }, - { name: '_l1BlockNumber', internalType: 'uint256', type: 'uint256' }, + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, ], - name: 'proposeL2Output', - outputs: [], + name: 'createOptimismMintableERC721', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', - inputs: [], - name: 'startingBlockNumber', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + inputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'isOptimismMintableERC721', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'startingTimestamp', + name: 'remoteChainId', outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { @@ -5383,270 +5593,407 @@ export const l2OutputOracleABI = [ ] as const /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) + * [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000017) */ -export const l2OutputOracleAddress = { - 1: '0xdfe97868233d1aa22e815a266982f2cf17685a27', +export const optimismMintableErc721FactoryAddress = { + 10: '0x4200000000000000000000000000000000000017', } as const /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) + * [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000017) */ -export const l2OutputOracleConfig = { - address: l2OutputOracleAddress, - abi: l2OutputOracleABI, +export const optimismMintableErc721FactoryConfig = { + address: optimismMintableErc721FactoryAddress, + abi: optimismMintableErc721FactoryABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// L2OutputOracle_goerli +// OptimismMintableERC721Factory_optimism-goerli ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000017) */ -export const l2OutputOracleGoerliABI = [ +export const optimismMintableErc721FactoryOptimismGoerliABI = [ { stateMutability: 'nonpayable', type: 'constructor', inputs: [ - { name: '_submissionInterval', internalType: 'uint256', type: 'uint256' }, - { name: '_l2BlockTime', internalType: 'uint256', type: 'uint256' }, - { - name: '_finalizationPeriodSeconds', - internalType: 'uint256', - type: 'uint256', - }, - ], - }, - { - type: 'event', - anonymous: false, - inputs: [ - { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, + { name: '_bridge', internalType: 'address', type: 'address' }, + { name: '_remoteChainId', internalType: 'uint256', type: 'uint256' }, ], - name: 'Initialized', }, { type: 'event', anonymous: false, inputs: [ { - name: 'outputRoot', - internalType: 'bytes32', - type: 'bytes32', - indexed: true, - }, - { - name: 'l2OutputIndex', - internalType: 'uint256', - type: 'uint256', + name: 'localToken', + internalType: 'address', + type: 'address', indexed: true, }, { - name: 'l2BlockNumber', - internalType: 'uint256', - type: 'uint256', + name: 'remoteToken', + internalType: 'address', + type: 'address', indexed: true, }, { - name: 'l1Timestamp', - internalType: 'uint256', - type: 'uint256', + name: 'deployer', + internalType: 'address', + type: 'address', indexed: false, }, ], - name: 'OutputProposed', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'prevNextOutputIndex', - internalType: 'uint256', - type: 'uint256', - indexed: true, - }, - { - name: 'newNextOutputIndex', - internalType: 'uint256', - type: 'uint256', - indexed: true, - }, - ], - name: 'OutputsDeleted', + name: 'OptimismMintableERC721Created', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'challenger', + name: 'BRIDGE', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', - inputs: [ - { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, - ], - name: 'computeL2Timestamp', + inputs: [], + name: 'REMOTE_CHAIN_ID', outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, ], - name: 'deleteL2Outputs', - outputs: [], + name: 'createOptimismMintableERC721', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', - inputs: [], - name: 'finalizationPeriodSeconds', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + inputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'isOptimismMintableERC721', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { stateMutability: 'view', type: 'function', + inputs: [], + name: 'version', + outputs: [{ name: '', internalType: 'string', type: 'string' }], + }, +] as const + +/** + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000017) + */ +export const optimismMintableErc721FactoryOptimismGoerliAddress = { + 420: '0x4200000000000000000000000000000000000017', +} as const + +/** + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000017) + */ +export const optimismMintableErc721FactoryOptimismGoerliConfig = { + address: optimismMintableErc721FactoryOptimismGoerliAddress, + abi: optimismMintableErc721FactoryOptimismGoerliABI, +} as const + +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// OptimismPortal +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/** + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) + */ +export const optimismPortalABI = [ + { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, + { + type: 'event', + anonymous: false, inputs: [ - { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, - ], - name: 'getL2Output', - outputs: [ - { - name: '', - internalType: 'struct Types.OutputProposal', - type: 'tuple', - components: [ - { name: 'outputRoot', internalType: 'bytes32', type: 'bytes32' }, - { name: 'timestamp', internalType: 'uint128', type: 'uint128' }, - { name: 'l2BlockNumber', internalType: 'uint128', type: 'uint128' }, - ], - }, + { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, ], + name: 'Initialized', }, { - stateMutability: 'view', - type: 'function', + type: 'event', + anonymous: false, inputs: [ - { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, - ], - name: 'getL2OutputAfter', - outputs: [ { - name: '', - internalType: 'struct Types.OutputProposal', - type: 'tuple', - components: [ - { name: 'outputRoot', internalType: 'bytes32', type: 'bytes32' }, - { name: 'timestamp', internalType: 'uint128', type: 'uint128' }, - { name: 'l2BlockNumber', internalType: 'uint128', type: 'uint128' }, - ], + name: 'account', + internalType: 'address', + type: 'address', + indexed: false, }, ], + name: 'Paused', }, { - stateMutability: 'view', - type: 'function', + type: 'event', + anonymous: false, inputs: [ - { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, + { name: 'from', internalType: 'address', type: 'address', indexed: true }, + { name: 'to', internalType: 'address', type: 'address', indexed: true }, + { + name: 'version', + internalType: 'uint256', + type: 'uint256', + indexed: true, + }, + { + name: 'opaqueData', + internalType: 'bytes', + type: 'bytes', + indexed: false, + }, ], - name: 'getL2OutputIndexAfter', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'TransactionDeposited', + }, + { + type: 'event', + anonymous: false, + inputs: [ + { + name: 'account', + internalType: 'address', + type: 'address', + indexed: false, + }, + ], + name: 'Unpaused', + }, + { + type: 'event', + anonymous: false, + inputs: [ + { + name: 'withdrawalHash', + internalType: 'bytes32', + type: 'bytes32', + indexed: true, + }, + { name: 'success', internalType: 'bool', type: 'bool', indexed: false }, + ], + name: 'WithdrawalFinalized', + }, + { + type: 'event', + anonymous: false, + inputs: [ + { + name: 'withdrawalHash', + internalType: 'bytes32', + type: 'bytes32', + indexed: true, + }, + { name: 'from', internalType: 'address', type: 'address', indexed: true }, + { name: 'to', internalType: 'address', type: 'address', indexed: true }, + ], + name: 'WithdrawalProven', + }, + { + stateMutability: 'payable', + type: 'function', + inputs: [ + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_value', internalType: 'uint256', type: 'uint256' }, + { name: '_gasLimit', internalType: 'uint64', type: 'uint64' }, + { name: '_isCreation', internalType: 'bool', type: 'bool' }, + { name: '_data', internalType: 'bytes', type: 'bytes' }, + ], + name: 'depositTransaction', + outputs: [], + }, + { + stateMutability: 'payable', + type: 'function', + inputs: [], + name: 'donateETH', + outputs: [], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ { - name: '_startingBlockNumber', - internalType: 'uint256', - type: 'uint256', + name: '_tx', + internalType: 'struct Types.WithdrawalTransaction', + type: 'tuple', + components: [ + { name: 'nonce', internalType: 'uint256', type: 'uint256' }, + { name: 'sender', internalType: 'address', type: 'address' }, + { name: 'target', internalType: 'address', type: 'address' }, + { name: 'value', internalType: 'uint256', type: 'uint256' }, + { name: 'gasLimit', internalType: 'uint256', type: 'uint256' }, + { name: 'data', internalType: 'bytes', type: 'bytes' }, + ], }, - { name: '_startingTimestamp', internalType: 'uint256', type: 'uint256' }, - { name: '_proposer', internalType: 'address', type: 'address' }, - { name: '_challenger', internalType: 'address', type: 'address' }, ], - name: 'initialize', + name: 'finalizeWithdrawalTransaction', outputs: [], }, { stateMutability: 'view', type: 'function', - inputs: [], - name: 'l2BlockTime', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'finalizedWithdrawals', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'latestBlockNumber', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'guardian', + outputs: [{ name: '', internalType: 'address', type: 'address' }], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { + name: '_l2Oracle', + internalType: 'contract L2OutputOracle', + type: 'address', + }, + { name: '_guardian', internalType: 'address', type: 'address' }, + { + name: '_systemConfig', + internalType: 'contract SystemConfig', + type: 'address', + }, + { name: '_paused', internalType: 'bool', type: 'bool' }, + ], + name: 'initialize', + outputs: [], }, { stateMutability: 'view', type: 'function', - inputs: [], - name: 'latestOutputIndex', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + inputs: [ + { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, + ], + name: 'isOutputFinalized', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'nextBlockNumber', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'l2Oracle', + outputs: [ + { name: '', internalType: 'contract L2OutputOracle', type: 'address' }, + ], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'nextOutputIndex', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'l2Sender', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'payable', + stateMutability: 'pure', type: 'function', - inputs: [ - { name: '_outputRoot', internalType: 'bytes32', type: 'bytes32' }, - { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, - { name: '_l1BlockHash', internalType: 'bytes32', type: 'bytes32' }, - { name: '_l1BlockNumber', internalType: 'uint256', type: 'uint256' }, + inputs: [{ name: '_byteCount', internalType: 'uint64', type: 'uint64' }], + name: 'minimumGasLimit', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'params', + outputs: [ + { name: 'prevBaseFee', internalType: 'uint128', type: 'uint128' }, + { name: 'prevBoughtGas', internalType: 'uint64', type: 'uint64' }, + { name: 'prevBlockNum', internalType: 'uint64', type: 'uint64' }, ], - name: 'proposeL2Output', + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [], + name: 'pause', outputs: [], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'proposer', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'paused', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { + name: '_tx', + internalType: 'struct Types.WithdrawalTransaction', + type: 'tuple', + components: [ + { name: 'nonce', internalType: 'uint256', type: 'uint256' }, + { name: 'sender', internalType: 'address', type: 'address' }, + { name: 'target', internalType: 'address', type: 'address' }, + { name: 'value', internalType: 'uint256', type: 'uint256' }, + { name: 'gasLimit', internalType: 'uint256', type: 'uint256' }, + { name: 'data', internalType: 'bytes', type: 'bytes' }, + ], + }, + { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, + { + name: '_outputRootProof', + internalType: 'struct Types.OutputRootProof', + type: 'tuple', + components: [ + { name: 'version', internalType: 'bytes32', type: 'bytes32' }, + { name: 'stateRoot', internalType: 'bytes32', type: 'bytes32' }, + { + name: 'messagePasserStorageRoot', + internalType: 'bytes32', + type: 'bytes32', + }, + { name: 'latestBlockhash', internalType: 'bytes32', type: 'bytes32' }, + ], + }, + { name: '_withdrawalProof', internalType: 'bytes[]', type: 'bytes[]' }, + ], + name: 'proveWithdrawalTransaction', + outputs: [], }, { stateMutability: 'view', type: 'function', - inputs: [], - name: 'startingBlockNumber', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'provenWithdrawals', + outputs: [ + { name: 'outputRoot', internalType: 'bytes32', type: 'bytes32' }, + { name: 'timestamp', internalType: 'uint128', type: 'uint128' }, + { name: 'l2OutputIndex', internalType: 'uint128', type: 'uint128' }, + ], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'startingTimestamp', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'systemConfig', + outputs: [ + { name: '', internalType: 'contract SystemConfig', type: 'address' }, + ], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', inputs: [], - name: 'submissionInterval', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'unpause', + outputs: [], }, { stateMutability: 'view', @@ -5655,161 +6002,107 @@ export const l2OutputOracleGoerliABI = [ name: 'version', outputs: [{ name: '', internalType: 'string', type: 'string' }], }, + { stateMutability: 'payable', type: 'receive' }, ] as const /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) */ -export const l2OutputOracleGoerliAddress = { - 5: '0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0', +export const optimismPortalAddress = { + 1: '0xbEb5Fc579115071764c7423A4f12eDde41f106Ed', + 5: '0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383', } as const /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) */ -export const l2OutputOracleGoerliConfig = { - address: l2OutputOracleGoerliAddress, - abi: l2OutputOracleGoerliABI, +export const optimismPortalConfig = { + address: optimismPortalAddress, + abi: optimismPortalABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// L2StandardBridge +// Optimist ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) */ -export const l2StandardBridgeABI = [ +export const optimistABI = [ { stateMutability: 'nonpayable', type: 'constructor', inputs: [ + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, + { name: '_baseURIAttestor', internalType: 'address', type: 'address' }, { - name: '_otherBridge', - internalType: 'address payable', - type: 'address', - }, - ], - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'l1Token', - internalType: 'address', + name: '_attestationStation', + internalType: 'contract AttestationStation', type: 'address', - indexed: true, }, { - name: 'l2Token', - internalType: 'address', + name: '_optimistAllowlist', + internalType: 'contract OptimistAllowlist', type: 'address', - indexed: true, - }, - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: false }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, }, ], - name: 'DepositFinalized', }, { type: 'event', anonymous: false, inputs: [ { - name: 'localToken', + name: 'owner', internalType: 'address', type: 'address', indexed: true, }, { - name: 'remoteToken', + name: 'approved', internalType: 'address', type: 'address', indexed: true, }, - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: false }, { - name: 'amount', + name: 'tokenId', internalType: 'uint256', type: 'uint256', - indexed: false, - }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, + indexed: true, }, ], - name: 'ERC20BridgeFinalized', + name: 'Approval', }, { type: 'event', anonymous: false, inputs: [ { - name: 'localToken', + name: 'owner', internalType: 'address', type: 'address', indexed: true, }, { - name: 'remoteToken', + name: 'operator', internalType: 'address', type: 'address', indexed: true, }, - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: false }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, - }, + { name: 'approved', internalType: 'bool', type: 'bool', indexed: false }, ], - name: 'ERC20BridgeInitiated', + name: 'ApprovalForAll', }, { type: 'event', anonymous: false, inputs: [ - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, - }, + { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, ], - name: 'ETHBridgeFinalized', + name: 'Initialized', }, { type: 'event', @@ -5818,334 +6111,207 @@ export const l2StandardBridgeABI = [ { name: 'from', internalType: 'address', type: 'address', indexed: true }, { name: 'to', internalType: 'address', type: 'address', indexed: true }, { - name: 'amount', + name: 'tokenId', internalType: 'uint256', type: 'uint256', - indexed: false, - }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, + indexed: true, }, ], - name: 'ETHBridgeInitiated', + name: 'Transfer', }, { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'l1Token', - internalType: 'address', - type: 'address', - indexed: true, - }, + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'ATTESTATION_STATION', + outputs: [ { - name: 'l2Token', - internalType: 'address', + name: '', + internalType: 'contract AttestationStation', type: 'address', - indexed: true, - }, - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: false }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, }, ], - name: 'WithdrawalInitiated', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'OTHER_BRIDGE', - outputs: [ - { name: '', internalType: 'contract StandardBridge', type: 'address' }, - ], + name: 'BASE_URI_ATTESTATION_KEY', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'bridgeERC20', - outputs: [], + inputs: [], + name: 'BASE_URI_ATTESTOR', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + inputs: [], + name: 'OPTIMIST_ALLOWLIST', + outputs: [ + { name: '', internalType: 'contract OptimistAllowlist', type: 'address' }, ], - name: 'bridgeERC20To', - outputs: [], }, { - stateMutability: 'payable', + stateMutability: 'pure', type: 'function', inputs: [ - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { name: '', internalType: 'address', type: 'address' }, + { name: '', internalType: 'uint256', type: 'uint256' }, ], - name: 'bridgeETH', + name: 'approve', outputs: [], }, { - stateMutability: 'payable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'bridgeETHTo', - outputs: [], + inputs: [{ name: 'owner', internalType: 'address', type: 'address' }], + name: 'balanceOf', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', - inputs: [ - { name: '', internalType: 'address', type: 'address' }, - { name: '', internalType: 'address', type: 'address' }, - ], - name: 'deposits', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + inputs: [], + name: 'baseURI', + outputs: [{ name: '', internalType: 'string', type: 'string' }], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_from', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'finalizeBridgeERC20', + inputs: [{ name: 'tokenId', internalType: 'uint256', type: 'uint256' }], + name: 'burn', outputs: [], }, { - stateMutability: 'payable', + stateMutability: 'view', + type: 'function', + inputs: [{ name: 'tokenId', internalType: 'uint256', type: 'uint256' }], + name: 'getApproved', + outputs: [{ name: '', internalType: 'address', type: 'address' }], + }, + { + stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_from', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, ], - name: 'finalizeBridgeETH', + name: 'initialize', outputs: [], }, { - stateMutability: 'payable', + stateMutability: 'view', type: 'function', inputs: [ - { name: '_l1Token', internalType: 'address', type: 'address' }, - { name: '_l2Token', internalType: 'address', type: 'address' }, - { name: '_from', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { name: 'owner', internalType: 'address', type: 'address' }, + { name: 'operator', internalType: 'address', type: 'address' }, ], - name: 'finalizeDeposit', - outputs: [], + name: 'isApprovedForAll', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { stateMutability: 'view', type: 'function', - inputs: [], - name: 'l1TokenBridge', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + inputs: [{ name: '_recipient', internalType: 'address', type: 'address' }], + name: 'isOnAllowList', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'messenger', - outputs: [ - { - name: '', - internalType: 'contract CrossDomainMessenger', - type: 'address', - }, - ], + inputs: [{ name: '_recipient', internalType: 'address', type: 'address' }], + name: 'mint', + outputs: [], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'version', + name: 'name', outputs: [{ name: '', internalType: 'string', type: 'string' }], }, { - stateMutability: 'payable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_l2Token', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'withdraw', - outputs: [], + inputs: [{ name: 'tokenId', internalType: 'uint256', type: 'uint256' }], + name: 'ownerOf', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'payable', + stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_l2Token', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { name: 'from', internalType: 'address', type: 'address' }, + { name: 'to', internalType: 'address', type: 'address' }, + { name: 'tokenId', internalType: 'uint256', type: 'uint256' }, ], - name: 'withdrawTo', + name: 'safeTransferFrom', outputs: [], }, - { stateMutability: 'payable', type: 'receive' }, -] as const - -/** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) - */ -export const l2StandardBridgeAddress = { - 420: '0x4200000000000000000000000000000000000010', -} as const - -/** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) - */ -export const l2StandardBridgeConfig = { - address: l2StandardBridgeAddress, - abi: l2StandardBridgeABI, -} as const - -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// L2ToL1MessagePasser -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000016) - */ -export const l2ToL1MessagePasserABI = [ - { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, { - type: 'event', - anonymous: false, + stateMutability: 'nonpayable', + type: 'function', inputs: [ - { - name: 'nonce', - internalType: 'uint256', - type: 'uint256', - indexed: true, - }, - { - name: 'sender', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'target', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'value', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - { - name: 'gasLimit', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - { name: 'data', internalType: 'bytes', type: 'bytes', indexed: false }, - { - name: 'withdrawalHash', - internalType: 'bytes32', - type: 'bytes32', - indexed: false, - }, + { name: 'from', internalType: 'address', type: 'address' }, + { name: 'to', internalType: 'address', type: 'address' }, + { name: 'tokenId', internalType: 'uint256', type: 'uint256' }, + { name: 'data', internalType: 'bytes', type: 'bytes' }, ], - name: 'MessagePassed', + name: 'safeTransferFrom', + outputs: [], }, { - type: 'event', - anonymous: false, + stateMutability: 'nonpayable', + type: 'function', inputs: [ - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: true, - }, + { name: '', internalType: 'address', type: 'address' }, + { name: '', internalType: 'bool', type: 'bool' }, ], - name: 'WithdrawerBalanceBurnt', + name: 'setApprovalForAll', + outputs: [], }, { stateMutability: 'view', type: 'function', - inputs: [], - name: 'MESSAGE_VERSION', - outputs: [{ name: '', internalType: 'uint16', type: 'uint16' }], + inputs: [{ name: 'interfaceId', internalType: 'bytes4', type: 'bytes4' }], + name: 'supportsInterface', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', inputs: [], - name: 'burn', - outputs: [], + name: 'symbol', + outputs: [{ name: '', internalType: 'string', type: 'string' }], }, { - stateMutability: 'payable', + stateMutability: 'pure', type: 'function', - inputs: [ - { name: '_target', internalType: 'address', type: 'address' }, - { name: '_gasLimit', internalType: 'uint256', type: 'uint256' }, - { name: '_data', internalType: 'bytes', type: 'bytes' }, - ], - name: 'initiateWithdrawal', - outputs: [], + inputs: [{ name: '_owner', internalType: 'address', type: 'address' }], + name: 'tokenIdOfAddress', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', - inputs: [], - name: 'messageNonce', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + inputs: [{ name: '_tokenId', internalType: 'uint256', type: 'uint256' }], + name: 'tokenURI', + outputs: [{ name: '', internalType: 'string', type: 'string' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - name: 'sentMessages', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + inputs: [ + { name: 'from', internalType: 'address', type: 'address' }, + { name: 'to', internalType: 'address', type: 'address' }, + { name: 'tokenId', internalType: 'uint256', type: 'uint256' }, + ], + name: 'transferFrom', + outputs: [], }, { stateMutability: 'view', @@ -6154,242 +6320,297 @@ export const l2ToL1MessagePasserABI = [ name: 'version', outputs: [{ name: '', internalType: 'string', type: 'string' }], }, - { stateMutability: 'payable', type: 'receive' }, ] as const /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000016) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) */ -export const l2ToL1MessagePasserAddress = { - 420: '0x4200000000000000000000000000000000000016', +export const optimistAddress = { + 10: '0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5', + 420: '0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5', } as const /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000016) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) */ -export const l2ToL1MessagePasserConfig = { - address: l2ToL1MessagePasserAddress, - abi: l2ToL1MessagePasserABI, +export const optimistConfig = { + address: optimistAddress, + abi: optimistABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// MintManager +// OptimistAllowlist ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x5C4e7Ba1E219E47948e6e3F55019A647bA501005) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) */ -export const mintManagerABI = [ +export const optimistAllowlistABI = [ { stateMutability: 'nonpayable', type: 'constructor', - inputs: [ - { name: '_upgrader', internalType: 'address', type: 'address' }, - { name: '_governanceToken', internalType: 'address', type: 'address' }, - ], - }, - { - type: 'event', - anonymous: false, inputs: [ { - name: 'previousOwner', - internalType: 'address', + name: '_attestationStation', + internalType: 'contract AttestationStation', type: 'address', - indexed: true, }, + { name: '_allowlistAttestor', internalType: 'address', type: 'address' }, { - name: 'newOwner', + name: '_coinbaseQuestAttestor', internalType: 'address', type: 'address', - indexed: true, }, + { name: '_optimistInviter', internalType: 'address', type: 'address' }, ], - name: 'OwnershipTransferred', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'DENOMINATOR', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'ALLOWLIST_ATTESTOR', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'MINT_CAP', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'ATTESTATION_STATION', + outputs: [ + { + name: '', + internalType: 'contract AttestationStation', + type: 'address', + }, + ], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'MINT_PERIOD', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'COINBASE_QUEST_ATTESTOR', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'governanceToken', - outputs: [ - { name: '', internalType: 'contract GovernanceToken', type: 'address' }, - ], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_account', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - ], - name: 'mint', - outputs: [], + name: 'COINBASE_QUEST_ELIGIBLE_ATTESTATION_KEY', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'mintPermittedAfter', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'OPTIMIST_CAN_MINT_ATTESTATION_KEY', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'owner', + name: 'OPTIMIST_INVITER', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [], - name: 'renounceOwnership', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], - name: 'transferOwnership', - outputs: [], + inputs: [{ name: '_claimer', internalType: 'address', type: 'address' }], + name: 'isAllowedToMint', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_newMintManager', internalType: 'address', type: 'address' }, - ], - name: 'upgrade', - outputs: [], + inputs: [], + name: 'version', + outputs: [{ name: '', internalType: 'string', type: 'string' }], }, ] as const /** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x5C4e7Ba1E219E47948e6e3F55019A647bA501005) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) */ -export const mintManagerAddress = { - 10: '0x5C4e7Ba1E219E47948e6e3F55019A647bA501005', - 420: '0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76', +export const optimistAllowlistAddress = { + 10: '0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180', + 420: '0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180', } as const /** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x5C4e7Ba1E219E47948e6e3F55019A647bA501005) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) */ -export const mintManagerConfig = { - address: mintManagerAddress, - abi: mintManagerABI, +export const optimistAllowlistConfig = { + address: optimistAllowlistAddress, + abi: optimistAllowlistABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// OptimismMintableERC20Factory +// OptimistInviter ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000012) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) */ -export const optimismMintableErc20FactoryABI = [ +export const optimistInviterABI = [ { stateMutability: 'nonpayable', type: 'constructor', - inputs: [{ name: '_bridge', internalType: 'address', type: 'address' }], + inputs: [ + { name: '_inviteGranter', internalType: 'address', type: 'address' }, + { + name: '_attestationStation', + internalType: 'contract AttestationStation', + type: 'address', + }, + ], }, { type: 'event', anonymous: false, inputs: [ - { - name: 'localToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'remoteToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'deployer', - internalType: 'address', - type: 'address', - indexed: false, - }, + { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, ], - name: 'OptimismMintableERC20Created', + name: 'Initialized', }, { type: 'event', anonymous: false, inputs: [ { - name: 'remoteToken', + name: 'issuer', internalType: 'address', type: 'address', indexed: true, }, { - name: 'localToken', + name: 'claimer', internalType: 'address', type: 'address', indexed: true, }, ], - name: 'StandardL2TokenCreated', + name: 'InviteClaimed', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'BRIDGE', + name: 'ATTESTATION_STATION', + outputs: [ + { + name: '', + internalType: 'contract AttestationStation', + type: 'address', + }, + ], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'CAN_INVITE_ATTESTATION_KEY', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'CLAIMABLE_INVITE_TYPEHASH', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'EIP712_VERSION', + outputs: [{ name: '', internalType: 'string', type: 'string' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'INVITE_GRANTER', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'MIN_COMMITMENT_PERIOD', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_symbol', internalType: 'string', type: 'string' }, + { name: '_claimer', internalType: 'address', type: 'address' }, + { + name: '_claimableInvite', + internalType: 'struct OptimistInviter.ClaimableInvite', + type: 'tuple', + components: [ + { name: 'issuer', internalType: 'address', type: 'address' }, + { name: 'nonce', internalType: 'bytes32', type: 'bytes32' }, + ], + }, + { name: '_signature', internalType: 'bytes', type: 'bytes' }, ], - name: 'createOptimismMintableERC20', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'claimInvite', + outputs: [], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [{ name: '_commitment', internalType: 'bytes32', type: 'bytes32' }], + name: 'commitInvite', + outputs: [], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'commitmentTimestamps', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [{ name: '_name', internalType: 'string', type: 'string' }], + name: 'initialize', + outputs: [], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'inviteCounts', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_symbol', internalType: 'string', type: 'string' }, + { name: '_accounts', internalType: 'address[]', type: 'address[]' }, + { name: '_inviteCount', internalType: 'uint256', type: 'uint256' }, ], - name: 'createStandardL2Token', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'setInviteCounts', + outputs: [], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [ + { name: '', internalType: 'address', type: 'address' }, + { name: '', internalType: 'bytes32', type: 'bytes32' }, + ], + name: 'usedNonces', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { stateMutability: 'view', @@ -6401,238 +6622,224 @@ export const optimismMintableErc20FactoryABI = [ ] as const /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000012) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) */ -export const optimismMintableErc20FactoryAddress = { - 1: '0x4200000000000000000000000000000000000012', +export const optimistInviterAddress = { + 10: '0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929', + 420: '0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929', } as const /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000012) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) */ -export const optimismMintableErc20FactoryConfig = { - address: optimismMintableErc20FactoryAddress, - abi: optimismMintableErc20FactoryABI, +export const optimistInviterConfig = { + address: optimistInviterAddress, + abi: optimistInviterABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// OptimismMintableERC20Factory_goerli +// PortalSender ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000012) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x0A893d9576b9cFD9EF78595963dc973238E78210) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xe7FACd39531ee3C313330E93B4d7a8B8A3c84Aa4) */ -export const optimismMintableErc20FactoryGoerliABI = [ - { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, - { - type: 'event', - anonymous: false, - inputs: [ - { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, - ], - name: 'Initialized', - }, +export const portalSenderABI = [ { - type: 'event', - anonymous: false, + stateMutability: 'nonpayable', + type: 'constructor', inputs: [ { - name: 'localToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'remoteToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'deployer', - internalType: 'address', + name: '_portal', + internalType: 'contract OptimismPortal', type: 'address', - indexed: false, }, ], - name: 'OptimismMintableERC20Created', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'remoteToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'localToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - ], - name: 'StandardL2TokenCreated', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'bridge', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_symbol', internalType: 'string', type: 'string' }, - ], - name: 'createOptimismMintableERC20', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_symbol', internalType: 'string', type: 'string' }, - { name: '_decimals', internalType: 'uint8', type: 'uint8' }, - ], - name: 'createOptimismMintableERC20WithDecimals', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_symbol', internalType: 'string', type: 'string' }, + name: 'PORTAL', + outputs: [ + { name: '', internalType: 'contract OptimismPortal', type: 'address' }, ], - name: 'createStandardL2Token', - outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [{ name: '_bridge', internalType: 'address', type: 'address' }], - name: 'initialize', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + name: 'donate', + outputs: [], }, ] as const /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000012) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x0A893d9576b9cFD9EF78595963dc973238E78210) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xe7FACd39531ee3C313330E93B4d7a8B8A3c84Aa4) */ -export const optimismMintableErc20FactoryGoerliAddress = { - 5: '0x4200000000000000000000000000000000000012', +export const portalSenderAddress = { + 1: '0x0A893d9576b9cFD9EF78595963dc973238E78210', + 5: '0xe7FACd39531ee3C313330E93B4d7a8B8A3c84Aa4', } as const /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000012) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x0A893d9576b9cFD9EF78595963dc973238E78210) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xe7FACd39531ee3C313330E93B4d7a8B8A3c84Aa4) */ -export const optimismMintableErc20FactoryGoerliConfig = { - address: optimismMintableErc20FactoryGoerliAddress, - abi: optimismMintableErc20FactoryGoerliABI, +export const portalSenderConfig = { + address: portalSenderAddress, + abi: portalSenderABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// OptimismMintableERC20Factory_optimism-goerli +// ProtocolVersions ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000012) + * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) */ -export const optimismMintableErc20FactoryOptimismGoerliABI = [ - { - stateMutability: 'nonpayable', - type: 'constructor', - inputs: [{ name: '_bridge', internalType: 'address', type: 'address' }], - }, +export const protocolVersionsABI = [ + { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, { type: 'event', anonymous: false, inputs: [ { - name: 'localToken', - internalType: 'address', - type: 'address', + name: 'version', + internalType: 'uint256', + type: 'uint256', indexed: true, }, { - name: 'remoteToken', - internalType: 'address', - type: 'address', + name: 'updateType', + internalType: 'enum ProtocolVersions.UpdateType', + type: 'uint8', indexed: true, }, - { - name: 'deployer', - internalType: 'address', - type: 'address', - indexed: false, - }, + { name: 'data', internalType: 'bytes', type: 'bytes', indexed: false }, ], - name: 'OptimismMintableERC20Created', + name: 'ConfigUpdate', + }, + { + type: 'event', + anonymous: false, + inputs: [ + { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, + ], + name: 'Initialized', }, { type: 'event', anonymous: false, inputs: [ { - name: 'remoteToken', + name: 'previousOwner', internalType: 'address', type: 'address', indexed: true, }, { - name: 'localToken', + name: 'newOwner', internalType: 'address', type: 'address', indexed: true, }, ], - name: 'StandardL2TokenCreated', + name: 'OwnershipTransferred', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'BRIDGE', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'RECOMMENDED_SLOT', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'REQUIRED_SLOT', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_symbol', internalType: 'string', type: 'string' }, + { name: '_owner', internalType: 'address', type: 'address' }, + { name: '_required', internalType: 'ProtocolVersion', type: 'uint256' }, + { + name: '_recommended', + internalType: 'ProtocolVersion', + type: 'uint256', + }, ], - name: 'createOptimismMintableERC20', + name: 'initialize', + outputs: [], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'owner', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'recommended', + outputs: [ + { name: 'out_', internalType: 'ProtocolVersion', type: 'uint256' }, + ], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [], + name: 'renounceOwnership', + outputs: [], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'required', + outputs: [ + { name: 'out_', internalType: 'ProtocolVersion', type: 'uint256' }, + ], + }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_symbol', internalType: 'string', type: 'string' }, + { + name: '_recommended', + internalType: 'ProtocolVersion', + type: 'uint256', + }, ], - name: 'createStandardL2Token', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'setRecommended', + outputs: [], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { name: '_required', internalType: 'ProtocolVersion', type: 'uint256' }, + ], + name: 'setRequired', + outputs: [], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], + name: 'transferOwnership', + outputs: [], }, { stateMutability: 'view', @@ -6644,823 +6851,797 @@ export const optimismMintableErc20FactoryOptimismGoerliABI = [ ] as const /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000012) + * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) */ -export const optimismMintableErc20FactoryOptimismGoerliAddress = { - 420: '0x4200000000000000000000000000000000000012', +export const protocolVersionsAddress = { + 5: '0x0C24F5098774aA366827D667494e9F889f7cFc08', } as const /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000012) + * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) */ -export const optimismMintableErc20FactoryOptimismGoerliConfig = { - address: optimismMintableErc20FactoryOptimismGoerliAddress, - abi: optimismMintableErc20FactoryOptimismGoerliABI, +export const protocolVersionsConfig = { + address: protocolVersionsAddress, + abi: protocolVersionsABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// OptimismMintableERC721Factory +// ProxyAdmin ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000017) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) */ -export const optimismMintableErc721FactoryABI = [ +export const proxyAdminABI = [ { stateMutability: 'nonpayable', type: 'constructor', - inputs: [ - { name: '_bridge', internalType: 'address', type: 'address' }, - { name: '_remoteChainId', internalType: 'uint256', type: 'uint256' }, - ], + inputs: [{ name: '_owner', internalType: 'address', type: 'address' }], }, { type: 'event', anonymous: false, inputs: [ { - name: 'localToken', + name: 'previousOwner', internalType: 'address', type: 'address', indexed: true, }, { - name: 'remoteToken', + name: 'newOwner', internalType: 'address', type: 'address', indexed: true, }, - { - name: 'deployer', - internalType: 'address', - type: 'address', - indexed: false, - }, ], - name: 'OptimismMintableERC721Created', + name: 'OwnershipTransferred', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'bridge', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'addressManager', + outputs: [ + { name: '', internalType: 'contract AddressManager', type: 'address' }, + ], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_symbol', internalType: 'string', type: 'string' }, - ], - name: 'createOptimismMintableERC721', + { name: '_proxy', internalType: 'address payable', type: 'address' }, + { name: '_newAdmin', internalType: 'address', type: 'address' }, + ], + name: 'changeProxyAdmin', + outputs: [], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [ + { name: '_proxy', internalType: 'address payable', type: 'address' }, + ], + name: 'getProxyAdmin', + outputs: [{ name: '', internalType: 'address', type: 'address' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [{ name: '_proxy', internalType: 'address', type: 'address' }], + name: 'getProxyImplementation', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', inputs: [{ name: '', internalType: 'address', type: 'address' }], - name: 'isOptimismMintableERC721', + name: 'implementationName', + outputs: [{ name: '', internalType: 'string', type: 'string' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'isUpgrading', outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'remoteChainId', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'owner', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', + inputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'proxyType', + outputs: [ + { name: '', internalType: 'enum ProxyAdmin.ProxyType', type: 'uint8' }, + ], + }, + { + stateMutability: 'nonpayable', + type: 'function', inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + name: 'renounceOwnership', + outputs: [], }, -] as const - -/** - * [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000017) - */ -export const optimismMintableErc721FactoryAddress = { - 10: '0x4200000000000000000000000000000000000017', -} as const - -/** - * [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000017) - */ -export const optimismMintableErc721FactoryConfig = { - address: optimismMintableErc721FactoryAddress, - abi: optimismMintableErc721FactoryABI, -} as const - -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// OptimismMintableERC721Factory_optimism-goerli -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000017) - */ -export const optimismMintableErc721FactoryOptimismGoerliABI = [ { stateMutability: 'nonpayable', - type: 'constructor', + type: 'function', inputs: [ - { name: '_bridge', internalType: 'address', type: 'address' }, - { name: '_remoteChainId', internalType: 'uint256', type: 'uint256' }, + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_address', internalType: 'address', type: 'address' }, ], + name: 'setAddress', + outputs: [], }, { - type: 'event', - anonymous: false, + stateMutability: 'nonpayable', + type: 'function', inputs: [ { - name: 'localToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'remoteToken', - internalType: 'address', + name: '_address', + internalType: 'contract AddressManager', type: 'address', - indexed: true, }, + ], + name: 'setAddressManager', + outputs: [], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { name: '_address', internalType: 'address', type: 'address' }, + { name: '_name', internalType: 'string', type: 'string' }, + ], + name: 'setImplementationName', + outputs: [], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { name: '_address', internalType: 'address', type: 'address' }, { - name: 'deployer', - internalType: 'address', - type: 'address', - indexed: false, + name: '_type', + internalType: 'enum ProxyAdmin.ProxyType', + type: 'uint8', }, ], - name: 'OptimismMintableERC721Created', + name: 'setProxyType', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'BRIDGE', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + inputs: [{ name: '_upgrading', internalType: 'bool', type: 'bool' }], + name: 'setUpgrading', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'REMOTE_CHAIN_ID', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], + name: 'transferOwnership', + outputs: [], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_symbol', internalType: 'string', type: 'string' }, + { name: '_proxy', internalType: 'address payable', type: 'address' }, + { name: '_implementation', internalType: 'address', type: 'address' }, ], - name: 'createOptimismMintableERC721', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [{ name: '', internalType: 'address', type: 'address' }], - name: 'isOptimismMintableERC721', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + name: 'upgrade', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'payable', type: 'function', - inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + inputs: [ + { name: '_proxy', internalType: 'address payable', type: 'address' }, + { name: '_implementation', internalType: 'address', type: 'address' }, + { name: '_data', internalType: 'bytes', type: 'bytes' }, + ], + name: 'upgradeAndCall', + outputs: [], }, ] as const /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000017) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) */ -export const optimismMintableErc721FactoryOptimismGoerliAddress = { - 420: '0x4200000000000000000000000000000000000017', +export const proxyAdminAddress = { + 1: '0x4200000000000000000000000000000000000018', + 5: '0x4200000000000000000000000000000000000018', } as const /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000017) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) */ -export const optimismMintableErc721FactoryOptimismGoerliConfig = { - address: optimismMintableErc721FactoryOptimismGoerliAddress, - abi: optimismMintableErc721FactoryOptimismGoerliABI, +export const proxyAdminConfig = { + address: proxyAdminAddress, + abi: proxyAdminABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// OptimismPortal +// SchemaRegistry ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x6232208d66bAc2305b46b4Cb6BCB3857B298DF13) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2545fa928d5d278cA75Fd47306e4a89096ff6403) */ -export const optimismPortalABI = [ +export const schemaRegistryABI = [ + { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, + { type: 'error', inputs: [], name: 'AlreadyExists' }, { - stateMutability: 'nonpayable', - type: 'constructor', + type: 'event', + anonymous: false, inputs: [ + { name: 'uid', internalType: 'bytes32', type: 'bytes32', indexed: true }, { - name: '_l2Oracle', - internalType: 'contract L2OutputOracle', - type: 'address', - }, - { name: '_guardian', internalType: 'address', type: 'address' }, - { name: '_paused', internalType: 'bool', type: 'bool' }, - { - name: '_config', - internalType: 'contract SystemConfig', + name: 'registerer', + internalType: 'address', type: 'address', + indexed: false, }, ], + name: 'Registered', }, { - type: 'event', - anonymous: false, - inputs: [ - { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, + stateMutability: 'view', + type: 'function', + inputs: [{ name: 'uid', internalType: 'bytes32', type: 'bytes32' }], + name: 'getSchema', + outputs: [ + { + name: '', + internalType: 'struct SchemaRecord', + type: 'tuple', + components: [ + { name: 'uid', internalType: 'bytes32', type: 'bytes32' }, + { + name: 'resolver', + internalType: 'contract ISchemaResolver', + type: 'address', + }, + { name: 'revocable', internalType: 'bool', type: 'bool' }, + { name: 'schema', internalType: 'string', type: 'string' }, + ], + }, ], - name: 'Initialized', }, { - type: 'event', - anonymous: false, + stateMutability: 'nonpayable', + type: 'function', inputs: [ + { name: 'schema', internalType: 'string', type: 'string' }, { - name: 'account', - internalType: 'address', + name: 'resolver', + internalType: 'contract ISchemaResolver', type: 'address', - indexed: false, }, + { name: 'revocable', internalType: 'bool', type: 'bool' }, ], - name: 'Paused', + name: 'register', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { - type: 'event', - anonymous: false, - inputs: [ - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, - { - name: 'version', - internalType: 'uint256', - type: 'uint256', - indexed: true, - }, - { - name: 'opaqueData', - internalType: 'bytes', - type: 'bytes', - indexed: false, - }, - ], - name: 'TransactionDeposited', + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'version', + outputs: [{ name: '', internalType: 'string', type: 'string' }], + }, +] as const + +/** + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x6232208d66bAc2305b46b4Cb6BCB3857B298DF13) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2545fa928d5d278cA75Fd47306e4a89096ff6403) + */ +export const schemaRegistryAddress = { + 10: '0x6232208d66bAc2305b46b4Cb6BCB3857B298DF13', + 420: '0x2545fa928d5d278cA75Fd47306e4a89096ff6403', +} as const + +/** + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x6232208d66bAc2305b46b4Cb6BCB3857B298DF13) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2545fa928d5d278cA75Fd47306e4a89096ff6403) + */ +export const schemaRegistryConfig = { + address: schemaRegistryAddress, + abi: schemaRegistryABI, +} as const + +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// SequencerFeeVault +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/** + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000011) + */ +export const sequencerFeeVaultABI = [ + { + stateMutability: 'nonpayable', + type: 'constructor', + inputs: [{ name: '_recipient', internalType: 'address', type: 'address' }], }, { type: 'event', anonymous: false, inputs: [ { - name: 'account', + name: 'value', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + { name: 'to', internalType: 'address', type: 'address', indexed: false }, + { + name: 'from', internalType: 'address', type: 'address', indexed: false, }, ], - name: 'Unpaused', + name: 'Withdrawal', }, { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'withdrawalHash', - internalType: 'bytes32', - type: 'bytes32', - indexed: true, - }, - { name: 'success', internalType: 'bool', type: 'bool', indexed: false }, - ], - name: 'WithdrawalFinalized', + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'MIN_WITHDRAWAL_AMOUNT', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'withdrawalHash', - internalType: 'bytes32', - type: 'bytes32', - indexed: true, - }, - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, - ], - name: 'WithdrawalProven', + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'RECIPIENT', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'GUARDIAN', + name: 'l1FeeWallet', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'L2_ORACLE', - outputs: [ - { name: '', internalType: 'contract L2OutputOracle', type: 'address' }, - ], + name: 'totalProcessed', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'SYSTEM_CONFIG', - outputs: [ - { name: '', internalType: 'contract SystemConfig', type: 'address' }, - ], + name: 'version', + outputs: [{ name: '', internalType: 'string', type: 'string' }], }, { - stateMutability: 'payable', + stateMutability: 'nonpayable', type: 'function', + inputs: [], + name: 'withdraw', + outputs: [], + }, + { stateMutability: 'payable', type: 'receive' }, +] as const + +/** + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000011) + */ +export const sequencerFeeVaultAddress = { + 420: '0x4200000000000000000000000000000000000011', +} as const + +/** + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000011) + */ +export const sequencerFeeVaultConfig = { + address: sequencerFeeVaultAddress, + abi: sequencerFeeVaultABI, +} as const + +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// SystemConfig +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/** + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) + */ +export const systemConfigABI = [ + { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, + { + type: 'event', + anonymous: false, inputs: [ - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_value', internalType: 'uint256', type: 'uint256' }, - { name: '_gasLimit', internalType: 'uint64', type: 'uint64' }, - { name: '_isCreation', internalType: 'bool', type: 'bool' }, - { name: '_data', internalType: 'bytes', type: 'bytes' }, + { + name: 'version', + internalType: 'uint256', + type: 'uint256', + indexed: true, + }, + { + name: 'updateType', + internalType: 'enum SystemConfig.UpdateType', + type: 'uint8', + indexed: true, + }, + { name: 'data', internalType: 'bytes', type: 'bytes', indexed: false }, ], - name: 'depositTransaction', - outputs: [], + name: 'ConfigUpdate', }, { - stateMutability: 'payable', - type: 'function', - inputs: [], - name: 'donateETH', - outputs: [], + type: 'event', + anonymous: false, + inputs: [ + { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, + ], + name: 'Initialized', }, { - stateMutability: 'nonpayable', - type: 'function', + type: 'event', + anonymous: false, inputs: [ { - name: '_tx', - internalType: 'struct Types.WithdrawalTransaction', - type: 'tuple', - components: [ - { name: 'nonce', internalType: 'uint256', type: 'uint256' }, - { name: 'sender', internalType: 'address', type: 'address' }, - { name: 'target', internalType: 'address', type: 'address' }, - { name: 'value', internalType: 'uint256', type: 'uint256' }, - { name: 'gasLimit', internalType: 'uint256', type: 'uint256' }, - { name: 'data', internalType: 'bytes', type: 'bytes' }, - ], + name: 'previousOwner', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'newOwner', + internalType: 'address', + type: 'address', + indexed: true, }, ], - name: 'finalizeWithdrawalTransaction', - outputs: [], + name: 'OwnershipTransferred', }, { stateMutability: 'view', type: 'function', - inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - name: 'finalizedWithdrawals', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + inputs: [], + name: 'BATCH_INBOX_SLOT', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [{ name: '_paused', internalType: 'bool', type: 'bool' }], - name: 'initialize', - outputs: [], + inputs: [], + name: 'L1_CROSS_DOMAIN_MESSENGER_SLOT', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { stateMutability: 'view', type: 'function', - inputs: [ - { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, - ], - name: 'isOutputFinalized', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + inputs: [], + name: 'L1_ERC_721_BRIDGE_SLOT', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'l2Sender', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'L1_STANDARD_BRIDGE_SLOT', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { - stateMutability: 'pure', + stateMutability: 'view', type: 'function', - inputs: [{ name: '_byteCount', internalType: 'uint64', type: 'uint64' }], - name: 'minimumGasLimit', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + inputs: [], + name: 'L2_OUTPUT_ORACLE_SLOT', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'params', - outputs: [ - { name: 'prevBaseFee', internalType: 'uint128', type: 'uint128' }, - { name: 'prevBoughtGas', internalType: 'uint64', type: 'uint64' }, - { name: 'prevBlockNum', internalType: 'uint64', type: 'uint64' }, - ], + name: 'OPTIMISM_MINTABLE_ERC20_FACTORY_SLOT', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', inputs: [], - name: 'pause', - outputs: [], + name: 'OPTIMISM_PORTAL_SLOT', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'paused', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + name: 'UNSAFE_BLOCK_SIGNER_SLOT', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'batchInbox', + outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'batcherHash', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'gasLimit', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + }, + { + stateMutability: 'nonpayable', type: 'function', inputs: [ + { name: '_owner', internalType: 'address', type: 'address' }, + { name: '_overhead', internalType: 'uint256', type: 'uint256' }, + { name: '_scalar', internalType: 'uint256', type: 'uint256' }, + { name: '_batcherHash', internalType: 'bytes32', type: 'bytes32' }, + { name: '_gasLimit', internalType: 'uint64', type: 'uint64' }, + { name: '_unsafeBlockSigner', internalType: 'address', type: 'address' }, { - name: '_tx', - internalType: 'struct Types.WithdrawalTransaction', + name: '_config', + internalType: 'struct ResourceMetering.ResourceConfig', type: 'tuple', components: [ - { name: 'nonce', internalType: 'uint256', type: 'uint256' }, - { name: 'sender', internalType: 'address', type: 'address' }, - { name: 'target', internalType: 'address', type: 'address' }, - { name: 'value', internalType: 'uint256', type: 'uint256' }, - { name: 'gasLimit', internalType: 'uint256', type: 'uint256' }, - { name: 'data', internalType: 'bytes', type: 'bytes' }, + { name: 'maxResourceLimit', internalType: 'uint32', type: 'uint32' }, + { + name: 'elasticityMultiplier', + internalType: 'uint8', + type: 'uint8', + }, + { + name: 'baseFeeMaxChangeDenominator', + internalType: 'uint8', + type: 'uint8', + }, + { name: 'minimumBaseFee', internalType: 'uint32', type: 'uint32' }, + { name: 'systemTxMaxGas', internalType: 'uint32', type: 'uint32' }, + { name: 'maximumBaseFee', internalType: 'uint128', type: 'uint128' }, ], }, - { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, + { name: '_startBlock', internalType: 'uint256', type: 'uint256' }, + { name: '_batchInbox', internalType: 'address', type: 'address' }, { - name: '_outputRootProof', - internalType: 'struct Types.OutputRootProof', + name: '_addresses', + internalType: 'struct SystemConfig.Addresses', type: 'tuple', components: [ - { name: 'version', internalType: 'bytes32', type: 'bytes32' }, - { name: 'stateRoot', internalType: 'bytes32', type: 'bytes32' }, { - name: 'messagePasserStorageRoot', - internalType: 'bytes32', - type: 'bytes32', + name: 'l1CrossDomainMessenger', + internalType: 'address', + type: 'address', + }, + { name: 'l1ERC721Bridge', internalType: 'address', type: 'address' }, + { + name: 'l1StandardBridge', + internalType: 'address', + type: 'address', + }, + { name: 'l2OutputOracle', internalType: 'address', type: 'address' }, + { name: 'optimismPortal', internalType: 'address', type: 'address' }, + { + name: 'optimismMintableERC20Factory', + internalType: 'address', + type: 'address', }, - { name: 'latestBlockhash', internalType: 'bytes32', type: 'bytes32' }, ], }, - { name: '_withdrawalProof', internalType: 'bytes[]', type: 'bytes[]' }, ], - name: 'proveWithdrawalTransaction', + name: 'initialize', outputs: [], }, { stateMutability: 'view', type: 'function', - inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - name: 'provenWithdrawals', - outputs: [ - { name: 'outputRoot', internalType: 'bytes32', type: 'bytes32' }, - { name: 'timestamp', internalType: 'uint128', type: 'uint128' }, - { name: 'l2OutputIndex', internalType: 'uint128', type: 'uint128' }, - ], + inputs: [], + name: 'l1CrossDomainMessenger', + outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', inputs: [], - name: 'unpause', - outputs: [], + name: 'l1ERC721Bridge', + outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], - }, - { stateMutability: 'payable', type: 'receive' }, -] as const - -/** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) - */ -export const optimismPortalAddress = { - 1: '0xbEb5Fc579115071764c7423A4f12eDde41f106Ed', -} as const - -/** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) - */ -export const optimismPortalConfig = { - address: optimismPortalAddress, - abi: optimismPortalABI, -} as const - -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// OptimismPortal_goerli -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) - */ -export const optimismPortalGoerliABI = [ - { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, - { - type: 'event', - anonymous: false, - inputs: [ - { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, - ], - name: 'Initialized', + name: 'l1StandardBridge', + outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], }, { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'account', - internalType: 'address', - type: 'address', - indexed: false, - }, - ], - name: 'Paused', + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'l2OutputOracle', + outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], }, { - type: 'event', - anonymous: false, - inputs: [ - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, - { - name: 'version', - internalType: 'uint256', - type: 'uint256', - indexed: true, - }, - { - name: 'opaqueData', - internalType: 'bytes', - type: 'bytes', - indexed: false, - }, - ], - name: 'TransactionDeposited', + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'minimumGasLimit', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], }, { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'account', - internalType: 'address', - type: 'address', - indexed: false, - }, - ], - name: 'Unpaused', + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'optimismMintableERC20Factory', + outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], }, { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'withdrawalHash', - internalType: 'bytes32', - type: 'bytes32', - indexed: true, - }, - { name: 'success', internalType: 'bool', type: 'bool', indexed: false }, - ], - name: 'WithdrawalFinalized', + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'optimismPortal', + outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], }, { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'withdrawalHash', - internalType: 'bytes32', - type: 'bytes32', - indexed: true, - }, - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, - ], - name: 'WithdrawalProven', + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'overhead', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { - stateMutability: 'payable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_value', internalType: 'uint256', type: 'uint256' }, - { name: '_gasLimit', internalType: 'uint64', type: 'uint64' }, - { name: '_isCreation', internalType: 'bool', type: 'bool' }, - { name: '_data', internalType: 'bytes', type: 'bytes' }, - ], - name: 'depositTransaction', - outputs: [], + inputs: [], + name: 'owner', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'payable', + stateMutability: 'nonpayable', type: 'function', inputs: [], - name: 'donateETH', + name: 'renounceOwnership', outputs: [], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [ + inputs: [], + name: 'resourceConfig', + outputs: [ { - name: '_tx', - internalType: 'struct Types.WithdrawalTransaction', + name: '', + internalType: 'struct ResourceMetering.ResourceConfig', type: 'tuple', components: [ - { name: 'nonce', internalType: 'uint256', type: 'uint256' }, - { name: 'sender', internalType: 'address', type: 'address' }, - { name: 'target', internalType: 'address', type: 'address' }, - { name: 'value', internalType: 'uint256', type: 'uint256' }, - { name: 'gasLimit', internalType: 'uint256', type: 'uint256' }, - { name: 'data', internalType: 'bytes', type: 'bytes' }, + { name: 'maxResourceLimit', internalType: 'uint32', type: 'uint32' }, + { + name: 'elasticityMultiplier', + internalType: 'uint8', + type: 'uint8', + }, + { + name: 'baseFeeMaxChangeDenominator', + internalType: 'uint8', + type: 'uint8', + }, + { name: 'minimumBaseFee', internalType: 'uint32', type: 'uint32' }, + { name: 'systemTxMaxGas', internalType: 'uint32', type: 'uint32' }, + { name: 'maximumBaseFee', internalType: 'uint128', type: 'uint128' }, ], }, ], - name: 'finalizeWithdrawalTransaction', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - name: 'finalizedWithdrawals', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'guardian', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'scalar', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { - name: '_l2Oracle', - internalType: 'contract L2OutputOracle', - type: 'address', - }, - { name: '_guardian', internalType: 'address', type: 'address' }, - { - name: '_systemConfig', - internalType: 'contract SystemConfig', - type: 'address', - }, - { name: '_paused', internalType: 'bool', type: 'bool' }, + { name: '_batcherHash', internalType: 'bytes32', type: 'bytes32' }, ], - name: 'initialize', + name: 'setBatcherHash', outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, - ], - name: 'isOutputFinalized', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'l2Oracle', - outputs: [ - { name: '', internalType: 'contract L2OutputOracle', type: 'address' }, - ], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'l2Sender', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'pure', - type: 'function', - inputs: [{ name: '_byteCount', internalType: 'uint64', type: 'uint64' }], - name: 'minimumGasLimit', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'params', - outputs: [ - { name: 'prevBaseFee', internalType: 'uint128', type: 'uint128' }, - { name: 'prevBoughtGas', internalType: 'uint64', type: 'uint64' }, - { name: 'prevBlockNum', internalType: 'uint64', type: 'uint64' }, + { name: '_overhead', internalType: 'uint256', type: 'uint256' }, + { name: '_scalar', internalType: 'uint256', type: 'uint256' }, ], + name: 'setGasConfig', + outputs: [], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'pause', + inputs: [{ name: '_gasLimit', internalType: 'uint64', type: 'uint64' }], + name: 'setGasLimit', outputs: [], }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'paused', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], - }, { stateMutability: 'nonpayable', type: 'function', inputs: [ { - name: '_tx', - internalType: 'struct Types.WithdrawalTransaction', - type: 'tuple', - components: [ - { name: 'nonce', internalType: 'uint256', type: 'uint256' }, - { name: 'sender', internalType: 'address', type: 'address' }, - { name: 'target', internalType: 'address', type: 'address' }, - { name: 'value', internalType: 'uint256', type: 'uint256' }, - { name: 'gasLimit', internalType: 'uint256', type: 'uint256' }, - { name: 'data', internalType: 'bytes', type: 'bytes' }, - ], - }, - { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, - { - name: '_outputRootProof', - internalType: 'struct Types.OutputRootProof', + name: '_config', + internalType: 'struct ResourceMetering.ResourceConfig', type: 'tuple', components: [ - { name: 'version', internalType: 'bytes32', type: 'bytes32' }, - { name: 'stateRoot', internalType: 'bytes32', type: 'bytes32' }, + { name: 'maxResourceLimit', internalType: 'uint32', type: 'uint32' }, { - name: 'messagePasserStorageRoot', - internalType: 'bytes32', - type: 'bytes32', + name: 'elasticityMultiplier', + internalType: 'uint8', + type: 'uint8', }, - { name: 'latestBlockhash', internalType: 'bytes32', type: 'bytes32' }, + { + name: 'baseFeeMaxChangeDenominator', + internalType: 'uint8', + type: 'uint8', + }, + { name: 'minimumBaseFee', internalType: 'uint32', type: 'uint32' }, + { name: 'systemTxMaxGas', internalType: 'uint32', type: 'uint32' }, + { name: 'maximumBaseFee', internalType: 'uint128', type: 'uint128' }, ], }, - { name: '_withdrawalProof', internalType: 'bytes[]', type: 'bytes[]' }, ], - name: 'proveWithdrawalTransaction', + name: 'setResourceConfig', outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - name: 'provenWithdrawals', - outputs: [ - { name: 'outputRoot', internalType: 'bytes32', type: 'bytes32' }, - { name: 'timestamp', internalType: 'uint128', type: 'uint128' }, - { name: 'l2OutputIndex', internalType: 'uint128', type: 'uint128' }, + inputs: [ + { name: '_unsafeBlockSigner', internalType: 'address', type: 'address' }, ], + name: 'setUnsafeBlockSigner', + outputs: [], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'systemConfig', - outputs: [ - { name: '', internalType: 'contract SystemConfig', type: 'address' }, - ], + name: 'startBlock', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'unpause', + inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], + name: 'transferOwnership', outputs: [], }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'unsafeBlockSigner', + outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], + }, { stateMutability: 'view', type: 'function', @@ -7468,471 +7649,622 @@ export const optimismPortalGoerliABI = [ name: 'version', outputs: [{ name: '', internalType: 'string', type: 'string' }], }, - { stateMutability: 'payable', type: 'receive' }, ] as const /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) */ -export const optimismPortalGoerliAddress = { - 5: '0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383', +export const systemConfigAddress = { + 1: '0x229047fed2591dbec1eF1118d64F7aF3dB9EB290', + 5: '0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60', } as const /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) */ -export const optimismPortalGoerliConfig = { - address: optimismPortalGoerliAddress, - abi: optimismPortalGoerliABI, +export const systemConfigConfig = { + address: systemConfigAddress, + abi: systemConfigABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// Optimist +// SystemDictator ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) + * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) */ -export const optimistABI = [ - { - stateMutability: 'nonpayable', - type: 'constructor', - inputs: [ - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_symbol', internalType: 'string', type: 'string' }, - { name: '_baseURIAttestor', internalType: 'address', type: 'address' }, - { - name: '_attestationStation', - internalType: 'contract AttestationStation', - type: 'address', - }, - { - name: '_optimistAllowlist', - internalType: 'contract OptimistAllowlist', - type: 'address', - }, - ], - }, +export const systemDictatorABI = [ + { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, { type: 'event', anonymous: false, inputs: [ - { - name: 'owner', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'approved', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'tokenId', - internalType: 'uint256', - type: 'uint256', - indexed: true, - }, + { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, ], - name: 'Approval', + name: 'Initialized', }, { type: 'event', anonymous: false, inputs: [ { - name: 'owner', + name: 'previousOwner', internalType: 'address', type: 'address', indexed: true, }, { - name: 'operator', + name: 'newOwner', internalType: 'address', type: 'address', indexed: true, }, - { name: 'approved', internalType: 'bool', type: 'bool', indexed: false }, - ], - name: 'ApprovalForAll', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, ], - name: 'Initialized', + name: 'OwnershipTransferred', }, { - type: 'event', - anonymous: false, - inputs: [ - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, - { - name: 'tokenId', - internalType: 'uint256', - type: 'uint256', - indexed: true, - }, - ], - name: 'Transfer', + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'EXIT_1_NO_RETURN_STEP', + outputs: [{ name: '', internalType: 'uint8', type: 'uint8' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'ATTESTATION_STATION', - outputs: [ - { - name: '', - internalType: 'contract AttestationStation', - type: 'address', - }, - ], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'BASE_URI_ATTESTATION_KEY', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'BASE_URI_ATTESTOR', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'PROXY_TRANSFER_STEP', + outputs: [{ name: '', internalType: 'uint8', type: 'uint8' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'OPTIMIST_ALLOWLIST', + name: 'config', outputs: [ - { name: '', internalType: 'contract OptimistAllowlist', type: 'address' }, - ], - }, - { - stateMutability: 'pure', - type: 'function', - inputs: [ - { name: '', internalType: 'address', type: 'address' }, - { name: '', internalType: 'uint256', type: 'uint256' }, + { + name: 'globalConfig', + internalType: 'struct SystemDictator.GlobalConfig', + type: 'tuple', + components: [ + { + name: 'addressManager', + internalType: 'contract AddressManager', + type: 'address', + }, + { + name: 'proxyAdmin', + internalType: 'contract ProxyAdmin', + type: 'address', + }, + { name: 'controller', internalType: 'address', type: 'address' }, + { name: 'finalOwner', internalType: 'address', type: 'address' }, + ], + }, + { + name: 'proxyAddressConfig', + internalType: 'struct SystemDictator.ProxyAddressConfig', + type: 'tuple', + components: [ + { + name: 'l2OutputOracleProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'optimismPortalProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'l1CrossDomainMessengerProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'l1StandardBridgeProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'optimismMintableERC20FactoryProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'l1ERC721BridgeProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'systemConfigProxy', + internalType: 'address', + type: 'address', + }, + ], + }, + { + name: 'implementationAddressConfig', + internalType: 'struct SystemDictator.ImplementationAddressConfig', + type: 'tuple', + components: [ + { + name: 'l2OutputOracleImpl', + internalType: 'contract L2OutputOracle', + type: 'address', + }, + { + name: 'optimismPortalImpl', + internalType: 'contract OptimismPortal', + type: 'address', + }, + { + name: 'l1CrossDomainMessengerImpl', + internalType: 'contract L1CrossDomainMessenger', + type: 'address', + }, + { + name: 'l1StandardBridgeImpl', + internalType: 'contract L1StandardBridge', + type: 'address', + }, + { + name: 'optimismMintableERC20FactoryImpl', + internalType: 'contract OptimismMintableERC20Factory', + type: 'address', + }, + { + name: 'l1ERC721BridgeImpl', + internalType: 'contract L1ERC721Bridge', + type: 'address', + }, + { + name: 'portalSenderImpl', + internalType: 'contract PortalSender', + type: 'address', + }, + { + name: 'systemConfigImpl', + internalType: 'contract SystemConfig', + type: 'address', + }, + ], + }, + { + name: 'systemConfigConfig', + internalType: 'struct SystemDictator.SystemConfigConfig', + type: 'tuple', + components: [ + { name: 'owner', internalType: 'address', type: 'address' }, + { name: 'overhead', internalType: 'uint256', type: 'uint256' }, + { name: 'scalar', internalType: 'uint256', type: 'uint256' }, + { name: 'batcherHash', internalType: 'bytes32', type: 'bytes32' }, + { name: 'gasLimit', internalType: 'uint64', type: 'uint64' }, + { + name: 'unsafeBlockSigner', + internalType: 'address', + type: 'address', + }, + { + name: 'resourceConfig', + internalType: 'struct ResourceMetering.ResourceConfig', + type: 'tuple', + components: [ + { + name: 'maxResourceLimit', + internalType: 'uint32', + type: 'uint32', + }, + { + name: 'elasticityMultiplier', + internalType: 'uint8', + type: 'uint8', + }, + { + name: 'baseFeeMaxChangeDenominator', + internalType: 'uint8', + type: 'uint8', + }, + { + name: 'minimumBaseFee', + internalType: 'uint32', + type: 'uint32', + }, + { + name: 'systemTxMaxGas', + internalType: 'uint32', + type: 'uint32', + }, + { + name: 'maximumBaseFee', + internalType: 'uint128', + type: 'uint128', + }, + ], + }, + ], + }, ], - name: 'approve', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [{ name: 'owner', internalType: 'address', type: 'address' }], - name: 'balanceOf', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'baseURI', - outputs: [{ name: '', internalType: 'string', type: 'string' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: 'tokenId', internalType: 'uint256', type: 'uint256' }], - name: 'burn', - outputs: [], + name: 'currentStep', + outputs: [{ name: '', internalType: 'uint8', type: 'uint8' }], }, { stateMutability: 'view', type: 'function', - inputs: [{ name: 'tokenId', internalType: 'uint256', type: 'uint256' }], - name: 'getApproved', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + inputs: [], + name: 'dynamicConfigSet', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [ - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_symbol', internalType: 'string', type: 'string' }, - ], - name: 'initialize', + inputs: [], + name: 'exit1', outputs: [], }, { stateMutability: 'view', type: 'function', - inputs: [ - { name: 'owner', internalType: 'address', type: 'address' }, - { name: 'operator', internalType: 'address', type: 'address' }, - ], - name: 'isApprovedForAll', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [{ name: '_recipient', internalType: 'address', type: 'address' }], - name: 'isOnAllowList', + inputs: [], + name: 'exited', outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [{ name: '_recipient', internalType: 'address', type: 'address' }], - name: 'mint', + inputs: [], + name: 'finalize', outputs: [], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'name', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + name: 'finalized', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { - stateMutability: 'view', - type: 'function', - inputs: [{ name: 'tokenId', internalType: 'uint256', type: 'uint256' }], - name: 'ownerOf', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'nonpayable', + stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: 'from', internalType: 'address', type: 'address' }, - { name: 'to', internalType: 'address', type: 'address' }, - { name: 'tokenId', internalType: 'uint256', type: 'uint256' }, + { + name: '_config', + internalType: 'struct SystemDictator.DeployConfig', + type: 'tuple', + components: [ + { + name: 'globalConfig', + internalType: 'struct SystemDictator.GlobalConfig', + type: 'tuple', + components: [ + { + name: 'addressManager', + internalType: 'contract AddressManager', + type: 'address', + }, + { + name: 'proxyAdmin', + internalType: 'contract ProxyAdmin', + type: 'address', + }, + { name: 'controller', internalType: 'address', type: 'address' }, + { name: 'finalOwner', internalType: 'address', type: 'address' }, + ], + }, + { + name: 'proxyAddressConfig', + internalType: 'struct SystemDictator.ProxyAddressConfig', + type: 'tuple', + components: [ + { + name: 'l2OutputOracleProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'optimismPortalProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'l1CrossDomainMessengerProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'l1StandardBridgeProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'optimismMintableERC20FactoryProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'l1ERC721BridgeProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'systemConfigProxy', + internalType: 'address', + type: 'address', + }, + ], + }, + { + name: 'implementationAddressConfig', + internalType: 'struct SystemDictator.ImplementationAddressConfig', + type: 'tuple', + components: [ + { + name: 'l2OutputOracleImpl', + internalType: 'contract L2OutputOracle', + type: 'address', + }, + { + name: 'optimismPortalImpl', + internalType: 'contract OptimismPortal', + type: 'address', + }, + { + name: 'l1CrossDomainMessengerImpl', + internalType: 'contract L1CrossDomainMessenger', + type: 'address', + }, + { + name: 'l1StandardBridgeImpl', + internalType: 'contract L1StandardBridge', + type: 'address', + }, + { + name: 'optimismMintableERC20FactoryImpl', + internalType: 'contract OptimismMintableERC20Factory', + type: 'address', + }, + { + name: 'l1ERC721BridgeImpl', + internalType: 'contract L1ERC721Bridge', + type: 'address', + }, + { + name: 'portalSenderImpl', + internalType: 'contract PortalSender', + type: 'address', + }, + { + name: 'systemConfigImpl', + internalType: 'contract SystemConfig', + type: 'address', + }, + ], + }, + { + name: 'systemConfigConfig', + internalType: 'struct SystemDictator.SystemConfigConfig', + type: 'tuple', + components: [ + { name: 'owner', internalType: 'address', type: 'address' }, + { name: 'overhead', internalType: 'uint256', type: 'uint256' }, + { name: 'scalar', internalType: 'uint256', type: 'uint256' }, + { name: 'batcherHash', internalType: 'bytes32', type: 'bytes32' }, + { name: 'gasLimit', internalType: 'uint64', type: 'uint64' }, + { + name: 'unsafeBlockSigner', + internalType: 'address', + type: 'address', + }, + { + name: 'resourceConfig', + internalType: 'struct ResourceMetering.ResourceConfig', + type: 'tuple', + components: [ + { + name: 'maxResourceLimit', + internalType: 'uint32', + type: 'uint32', + }, + { + name: 'elasticityMultiplier', + internalType: 'uint8', + type: 'uint8', + }, + { + name: 'baseFeeMaxChangeDenominator', + internalType: 'uint8', + type: 'uint8', + }, + { + name: 'minimumBaseFee', + internalType: 'uint32', + type: 'uint32', + }, + { + name: 'systemTxMaxGas', + internalType: 'uint32', + type: 'uint32', + }, + { + name: 'maximumBaseFee', + internalType: 'uint128', + type: 'uint128', + }, + ], + }, + ], + }, + ], + }, ], - name: 'safeTransferFrom', + name: 'initialize', outputs: [], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: 'from', internalType: 'address', type: 'address' }, - { name: 'to', internalType: 'address', type: 'address' }, - { name: 'tokenId', internalType: 'uint256', type: 'uint256' }, - { name: 'data', internalType: 'bytes', type: 'bytes' }, + inputs: [], + name: 'l2OutputOracleDynamicConfig', + outputs: [ + { + name: 'l2OutputOracleStartingBlockNumber', + internalType: 'uint256', + type: 'uint256', + }, + { + name: 'l2OutputOracleStartingTimestamp', + internalType: 'uint256', + type: 'uint256', + }, ], - name: 'safeTransferFrom', - outputs: [], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '', internalType: 'address', type: 'address' }, - { name: '', internalType: 'bool', type: 'bool' }, - ], - name: 'setApprovalForAll', - outputs: [], + inputs: [], + name: 'oldL1CrossDomainMessenger', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', - inputs: [{ name: 'interfaceId', internalType: 'bytes4', type: 'bytes4' }], - name: 'supportsInterface', + inputs: [], + name: 'optimismPortalDynamicConfig', outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'symbol', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + name: 'owner', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'pure', + stateMutability: 'nonpayable', type: 'function', - inputs: [{ name: '_owner', internalType: 'address', type: 'address' }], - name: 'tokenIdOfAddress', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + inputs: [], + name: 'phase1', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [{ name: '_tokenId', internalType: 'uint256', type: 'uint256' }], - name: 'tokenURI', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + inputs: [], + name: 'phase2', + outputs: [], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [ - { name: 'from', internalType: 'address', type: 'address' }, - { name: 'to', internalType: 'address', type: 'address' }, - { name: 'tokenId', internalType: 'uint256', type: 'uint256' }, - ], - name: 'transferFrom', + inputs: [], + name: 'renounceOwnership', outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + name: 'step1', + outputs: [], }, -] as const - -/** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - */ -export const optimistAddress = { - 10: '0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5', - 420: '0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5', -} as const - -/** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - */ -export const optimistConfig = { - address: optimistAddress, - abi: optimistABI, -} as const - -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// OptimistAllowlist -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) - */ -export const optimistAllowlistABI = [ { stateMutability: 'nonpayable', - type: 'constructor', - inputs: [ - { - name: '_attestationStation', - internalType: 'contract AttestationStation', - type: 'address', - }, - { name: '_allowlistAttestor', internalType: 'address', type: 'address' }, - { - name: '_coinbaseQuestAttestor', - internalType: 'address', - type: 'address', - }, - { name: '_optimistInviter', internalType: 'address', type: 'address' }, - ], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'ALLOWLIST_ATTESTOR', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'ATTESTATION_STATION', - outputs: [ - { - name: '', - internalType: 'contract AttestationStation', - type: 'address', - }, - ], - }, - { - stateMutability: 'view', type: 'function', inputs: [], - name: 'COINBASE_QUEST_ATTESTOR', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'step2', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', inputs: [], - name: 'COINBASE_QUEST_ELIGIBLE_ATTESTATION_KEY', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'step3', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', inputs: [], - name: 'OPTIMIST_CAN_MINT_ATTESTATION_KEY', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'step4', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', inputs: [], - name: 'OPTIMIST_INVITER', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'step5', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [{ name: '_claimer', internalType: 'address', type: 'address' }], - name: 'isAllowedToMint', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], + name: 'transferOwnership', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + inputs: [ + { + name: '_l2OutputOracleDynamicConfig', + internalType: 'struct SystemDictator.L2OutputOracleDynamicConfig', + type: 'tuple', + components: [ + { + name: 'l2OutputOracleStartingBlockNumber', + internalType: 'uint256', + type: 'uint256', + }, + { + name: 'l2OutputOracleStartingTimestamp', + internalType: 'uint256', + type: 'uint256', + }, + ], + }, + { + name: '_optimismPortalDynamicConfig', + internalType: 'bool', + type: 'bool', + }, + ], + name: 'updateDynamicConfig', + outputs: [], }, ] as const /** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) + * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) */ -export const optimistAllowlistAddress = { - 10: '0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180', - 420: '0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180', +export const systemDictatorAddress = { + 1: '0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB', } as const /** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) + * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) */ -export const optimistAllowlistConfig = { - address: optimistAllowlistAddress, - abi: optimistAllowlistABI, +export const systemDictatorConfig = { + address: systemDictatorAddress, + abi: systemDictatorABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// OptimistInviter +// SystemDictator_goerli ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) + * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) */ -export const optimistInviterABI = [ - { - stateMutability: 'nonpayable', - type: 'constructor', - inputs: [ - { name: '_inviteGranter', internalType: 'address', type: 'address' }, - { - name: '_attestationStation', - internalType: 'contract AttestationStation', - type: 'address', - }, - ], - }, +export const systemDictatorGoerliABI = [ { type: 'event', anonymous: false, @@ -7946,355 +8278,421 @@ export const optimistInviterABI = [ anonymous: false, inputs: [ { - name: 'issuer', + name: 'previousOwner', internalType: 'address', type: 'address', indexed: true, }, { - name: 'claimer', + name: 'newOwner', internalType: 'address', type: 'address', indexed: true, }, ], - name: 'InviteClaimed', - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'ATTESTATION_STATION', - outputs: [ - { - name: '', - internalType: 'contract AttestationStation', - type: 'address', - }, - ], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'CAN_INVITE_ATTESTATION_KEY', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'CLAIMABLE_INVITE_TYPEHASH', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'OwnershipTransferred', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'EIP712_VERSION', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + name: 'EXIT_1_NO_RETURN_STEP', + outputs: [{ name: '', internalType: 'uint8', type: 'uint8' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'INVITE_GRANTER', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'PROXY_TRANSFER_STEP', + outputs: [{ name: '', internalType: 'uint8', type: 'uint8' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'MIN_COMMITMENT_PERIOD', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_claimer', internalType: 'address', type: 'address' }, + name: 'config', + outputs: [ { - name: '_claimableInvite', - internalType: 'struct OptimistInviter.ClaimableInvite', + name: 'globalConfig', + internalType: 'struct SystemDictator.GlobalConfig', type: 'tuple', components: [ - { name: 'issuer', internalType: 'address', type: 'address' }, - { name: 'nonce', internalType: 'bytes32', type: 'bytes32' }, + { + name: 'addressManager', + internalType: 'contract AddressManager', + type: 'address', + }, + { + name: 'proxyAdmin', + internalType: 'contract ProxyAdmin', + type: 'address', + }, + { name: 'controller', internalType: 'address', type: 'address' }, + { name: 'finalOwner', internalType: 'address', type: 'address' }, + ], + }, + { + name: 'proxyAddressConfig', + internalType: 'struct SystemDictator.ProxyAddressConfig', + type: 'tuple', + components: [ + { + name: 'l2OutputOracleProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'optimismPortalProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'l1CrossDomainMessengerProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'l1StandardBridgeProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'optimismMintableERC20FactoryProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'l1ERC721BridgeProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'systemConfigProxy', + internalType: 'address', + type: 'address', + }, + ], + }, + { + name: 'implementationAddressConfig', + internalType: 'struct SystemDictator.ImplementationAddressConfig', + type: 'tuple', + components: [ + { + name: 'l2OutputOracleImpl', + internalType: 'contract L2OutputOracle', + type: 'address', + }, + { + name: 'optimismPortalImpl', + internalType: 'contract OptimismPortal', + type: 'address', + }, + { + name: 'l1CrossDomainMessengerImpl', + internalType: 'contract L1CrossDomainMessenger', + type: 'address', + }, + { + name: 'l1StandardBridgeImpl', + internalType: 'contract L1StandardBridge', + type: 'address', + }, + { + name: 'optimismMintableERC20FactoryImpl', + internalType: 'contract OptimismMintableERC20Factory', + type: 'address', + }, + { + name: 'l1ERC721BridgeImpl', + internalType: 'contract L1ERC721Bridge', + type: 'address', + }, + { + name: 'portalSenderImpl', + internalType: 'contract PortalSender', + type: 'address', + }, + { + name: 'systemConfigImpl', + internalType: 'contract SystemConfig', + type: 'address', + }, + ], + }, + { + name: 'systemConfigConfig', + internalType: 'struct SystemDictator.SystemConfigConfig', + type: 'tuple', + components: [ + { name: 'owner', internalType: 'address', type: 'address' }, + { name: 'overhead', internalType: 'uint256', type: 'uint256' }, + { name: 'scalar', internalType: 'uint256', type: 'uint256' }, + { name: 'batcherHash', internalType: 'bytes32', type: 'bytes32' }, + { name: 'gasLimit', internalType: 'uint64', type: 'uint64' }, + { + name: 'unsafeBlockSigner', + internalType: 'address', + type: 'address', + }, ], }, - { name: '_signature', internalType: 'bytes', type: 'bytes' }, - ], - name: 'claimInvite', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: '_commitment', internalType: 'bytes32', type: 'bytes32' }], - name: 'commitInvite', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - name: 'commitmentTimestamps', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: '_name', internalType: 'string', type: 'string' }], - name: 'initialize', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [{ name: '', internalType: 'address', type: 'address' }], - name: 'inviteCounts', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_accounts', internalType: 'address[]', type: 'address[]' }, - { name: '_inviteCount', internalType: 'uint256', type: 'uint256' }, ], - name: 'setInviteCounts', - outputs: [], }, { stateMutability: 'view', type: 'function', - inputs: [ - { name: '', internalType: 'address', type: 'address' }, - { name: '', internalType: 'bytes32', type: 'bytes32' }, - ], - name: 'usedNonces', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + inputs: [], + name: 'currentStep', + outputs: [{ name: '', internalType: 'uint8', type: 'uint8' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + name: 'dynamicConfigSet', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, -] as const - -/** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - */ -export const optimistInviterAddress = { - 10: '0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929', - 420: '0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929', -} as const - -/** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - */ -export const optimistInviterConfig = { - address: optimistInviterAddress, - abi: optimistInviterABI, -} as const - -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// PortalSender -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/** - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x0A893d9576b9cFD9EF78595963dc973238E78210) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xe7FACd39531ee3C313330E93B4d7a8B8A3c84Aa4) - */ -export const portalSenderABI = [ { stateMutability: 'nonpayable', - type: 'constructor', - inputs: [ - { - name: '_portal', - internalType: 'contract OptimismPortal', - type: 'address', - }, - ], - }, - { - stateMutability: 'view', type: 'function', inputs: [], - name: 'PORTAL', - outputs: [ - { name: '', internalType: 'contract OptimismPortal', type: 'address' }, - ], + name: 'exit1', + outputs: [], }, { stateMutability: 'nonpayable', type: 'function', inputs: [], - name: 'donate', + name: 'finalize', outputs: [], }, -] as const - -/** - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x0A893d9576b9cFD9EF78595963dc973238E78210) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xe7FACd39531ee3C313330E93B4d7a8B8A3c84Aa4) - */ -export const portalSenderAddress = { - 1: '0x0A893d9576b9cFD9EF78595963dc973238E78210', - 5: '0xe7FACd39531ee3C313330E93B4d7a8B8A3c84Aa4', -} as const - -/** - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x0A893d9576b9cFD9EF78595963dc973238E78210) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xe7FACd39531ee3C313330E93B4d7a8B8A3c84Aa4) - */ -export const portalSenderConfig = { - address: portalSenderAddress, - abi: portalSenderABI, -} as const - -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// ProtocolVersions -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) - */ -export const protocolVersionsABI = [ - { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'version', - internalType: 'uint256', - type: 'uint256', - indexed: true, - }, - { - name: 'updateType', - internalType: 'enum ProtocolVersions.UpdateType', - type: 'uint8', - indexed: true, - }, - { name: 'data', internalType: 'bytes', type: 'bytes', indexed: false }, - ], - name: 'ConfigUpdate', - }, { - type: 'event', - anonymous: false, - inputs: [ - { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, - ], - name: 'Initialized', + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'finalized', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { - type: 'event', - anonymous: false, + stateMutability: 'nonpayable', + type: 'function', inputs: [ { - name: 'previousOwner', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'newOwner', - internalType: 'address', - type: 'address', - indexed: true, - }, - ], - name: 'OwnershipTransferred', - }, + name: '_config', + internalType: 'struct SystemDictator.DeployConfig', + type: 'tuple', + components: [ + { + name: 'globalConfig', + internalType: 'struct SystemDictator.GlobalConfig', + type: 'tuple', + components: [ + { + name: 'addressManager', + internalType: 'contract AddressManager', + type: 'address', + }, + { + name: 'proxyAdmin', + internalType: 'contract ProxyAdmin', + type: 'address', + }, + { name: 'controller', internalType: 'address', type: 'address' }, + { name: 'finalOwner', internalType: 'address', type: 'address' }, + ], + }, + { + name: 'proxyAddressConfig', + internalType: 'struct SystemDictator.ProxyAddressConfig', + type: 'tuple', + components: [ + { + name: 'l2OutputOracleProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'optimismPortalProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'l1CrossDomainMessengerProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'l1StandardBridgeProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'optimismMintableERC20FactoryProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'l1ERC721BridgeProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'systemConfigProxy', + internalType: 'address', + type: 'address', + }, + ], + }, + { + name: 'implementationAddressConfig', + internalType: 'struct SystemDictator.ImplementationAddressConfig', + type: 'tuple', + components: [ + { + name: 'l2OutputOracleImpl', + internalType: 'contract L2OutputOracle', + type: 'address', + }, + { + name: 'optimismPortalImpl', + internalType: 'contract OptimismPortal', + type: 'address', + }, + { + name: 'l1CrossDomainMessengerImpl', + internalType: 'contract L1CrossDomainMessenger', + type: 'address', + }, + { + name: 'l1StandardBridgeImpl', + internalType: 'contract L1StandardBridge', + type: 'address', + }, + { + name: 'optimismMintableERC20FactoryImpl', + internalType: 'contract OptimismMintableERC20Factory', + type: 'address', + }, + { + name: 'l1ERC721BridgeImpl', + internalType: 'contract L1ERC721Bridge', + type: 'address', + }, + { + name: 'portalSenderImpl', + internalType: 'contract PortalSender', + type: 'address', + }, + { + name: 'systemConfigImpl', + internalType: 'contract SystemConfig', + type: 'address', + }, + ], + }, + { + name: 'systemConfigConfig', + internalType: 'struct SystemDictator.SystemConfigConfig', + type: 'tuple', + components: [ + { name: 'owner', internalType: 'address', type: 'address' }, + { name: 'overhead', internalType: 'uint256', type: 'uint256' }, + { name: 'scalar', internalType: 'uint256', type: 'uint256' }, + { name: 'batcherHash', internalType: 'bytes32', type: 'bytes32' }, + { name: 'gasLimit', internalType: 'uint64', type: 'uint64' }, + { + name: 'unsafeBlockSigner', + internalType: 'address', + type: 'address', + }, + ], + }, + ], + }, + ], + name: 'initialize', + outputs: [], + }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'RECOMMENDED_SLOT', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'l2OutputOracleDynamicConfig', + outputs: [ + { + name: 'l2OutputOracleStartingBlockNumber', + internalType: 'uint256', + type: 'uint256', + }, + { + name: 'l2OutputOracleStartingTimestamp', + internalType: 'uint256', + type: 'uint256', + }, + ], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'REQUIRED_SLOT', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'oldL1CrossDomainMessenger', + outputs: [{ name: '', internalType: 'address', type: 'address' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'owner', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [ - { name: '_owner', internalType: 'address', type: 'address' }, - { name: '_required', internalType: 'ProtocolVersion', type: 'uint256' }, - { - name: '_recommended', - internalType: 'ProtocolVersion', - type: 'uint256', - }, - ], - name: 'initialize', + inputs: [], + name: 'renounceOwnership', outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', inputs: [], - name: 'owner', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'step1', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', inputs: [], - name: 'recommended', - outputs: [ - { name: 'out_', internalType: 'ProtocolVersion', type: 'uint256' }, - ], + name: 'step2', + outputs: [], }, { stateMutability: 'nonpayable', type: 'function', inputs: [], - name: 'renounceOwnership', + name: 'step3', outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', inputs: [], - name: 'required', - outputs: [ - { name: 'out_', internalType: 'ProtocolVersion', type: 'uint256' }, - ], + name: 'step4', + outputs: [], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [ - { - name: '_recommended', - internalType: 'ProtocolVersion', - type: 'uint256', - }, - ], - name: 'setRecommended', + inputs: [], + name: 'step5', outputs: [], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [ - { name: '_required', internalType: 'ProtocolVersion', type: 'uint256' }, - ], - name: 'setRequired', + inputs: [], + name: 'step6', outputs: [], }, { @@ -8305,38 +8703,55 @@ export const protocolVersionsABI = [ outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + inputs: [ + { + name: '_l2OutputOracleDynamicConfig', + internalType: 'struct SystemDictator.L2OutputOracleDynamicConfig', + type: 'tuple', + components: [ + { + name: 'l2OutputOracleStartingBlockNumber', + internalType: 'uint256', + type: 'uint256', + }, + { + name: 'l2OutputOracleStartingTimestamp', + internalType: 'uint256', + type: 'uint256', + }, + ], + }, + ], + name: 'updateL2OutputOracleDynamicConfig', + outputs: [], }, ] as const /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) + * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) */ -export const protocolVersionsAddress = { - 5: '0x0C24F5098774aA366827D667494e9F889f7cFc08', +export const systemDictatorGoerliAddress = { + 5: '0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971', } as const /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) + * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) */ -export const protocolVersionsConfig = { - address: protocolVersionsAddress, - abi: protocolVersionsABI, +export const systemDictatorGoerliConfig = { + address: systemDictatorGoerliAddress, + abi: systemDictatorGoerliABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// ProxyAdmin +// TeleportrWithdrawer ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) + * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) */ -export const proxyAdminABI = [ +export const teleportrWithdrawerABI = [ { stateMutability: 'nonpayable', type: 'constructor', @@ -8346,69 +8761,147 @@ export const proxyAdminABI = [ type: 'event', anonymous: false, inputs: [ + { name: 'user', internalType: 'address', type: 'address', indexed: true }, { - name: 'previousOwner', + name: 'newOwner', internalType: 'address', type: 'address', indexed: true, }, + ], + name: 'OwnerUpdated', + }, + { + type: 'event', + anonymous: false, + inputs: [ + { name: 'from', internalType: 'address', type: 'address', indexed: true }, { - name: 'newOwner', + name: 'amount', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + ], + name: 'ReceivedETH', + }, + { + type: 'event', + anonymous: false, + inputs: [ + { + name: 'withdrawer', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'recipient', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'asset', internalType: 'address', type: 'address', indexed: true, }, + { + name: 'amount', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, ], - name: 'OwnershipTransferred', + name: 'WithdrewERC20', }, { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'addressManager', - outputs: [ - { name: '', internalType: 'contract AddressManager', type: 'address' }, + type: 'event', + anonymous: false, + inputs: [ + { + name: 'withdrawer', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'recipient', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'asset', + internalType: 'address', + type: 'address', + indexed: true, + }, + { name: 'id', internalType: 'uint256', type: 'uint256', indexed: false }, ], + name: 'WithdrewERC721', }, { - stateMutability: 'nonpayable', - type: 'function', + type: 'event', + anonymous: false, inputs: [ - { name: '_proxy', internalType: 'address payable', type: 'address' }, - { name: '_newAdmin', internalType: 'address', type: 'address' }, + { + name: 'withdrawer', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'recipient', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'amount', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, ], - name: 'changeProxyAdmin', - outputs: [], + name: 'WithdrewETH', }, { - stateMutability: 'view', + stateMutability: 'payable', type: 'function', inputs: [ - { name: '_proxy', internalType: 'address payable', type: 'address' }, + { name: '_target', internalType: 'address', type: 'address' }, + { name: '_data', internalType: 'bytes', type: 'bytes' }, + { name: '_gas', internalType: 'uint256', type: 'uint256' }, + { name: '_value', internalType: 'uint256', type: 'uint256' }, + ], + name: 'CALL', + outputs: [ + { name: '', internalType: 'bool', type: 'bool' }, + { name: '', internalType: 'bytes', type: 'bytes' }, ], - name: 'getProxyAdmin', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [{ name: '_proxy', internalType: 'address', type: 'address' }], - name: 'getProxyImplementation', - outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'view', + stateMutability: 'payable', type: 'function', - inputs: [{ name: '', internalType: 'address', type: 'address' }], - name: 'implementationName', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + inputs: [ + { name: '_target', internalType: 'address', type: 'address' }, + { name: '_data', internalType: 'bytes', type: 'bytes' }, + { name: '_gas', internalType: 'uint256', type: 'uint256' }, + ], + name: 'DELEGATECALL', + outputs: [ + { name: '', internalType: 'bool', type: 'bool' }, + { name: '', internalType: 'bytes', type: 'bytes' }, + ], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'isUpgrading', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + name: 'data', + outputs: [{ name: '', internalType: 'bytes', type: 'bytes' }], }, { stateMutability: 'view', @@ -8420,7975 +8913,906 @@ export const proxyAdminABI = [ { stateMutability: 'view', type: 'function', - inputs: [{ name: '', internalType: 'address', type: 'address' }], - name: 'proxyType', - outputs: [ - { name: '', internalType: 'enum ProxyAdmin.ProxyType', type: 'uint8' }, - ], + inputs: [], + name: 'recipient', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'renounceOwnership', + inputs: [{ name: '_data', internalType: 'bytes', type: 'bytes' }], + name: 'setData', outputs: [], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [ - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_address', internalType: 'address', type: 'address' }, - ], - name: 'setAddress', + inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], + name: 'setOwner', outputs: [], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [ - { - name: '_address', - internalType: 'contract AddressManager', - type: 'address', - }, - ], - name: 'setAddressManager', + inputs: [{ name: '_recipient', internalType: 'address', type: 'address' }], + name: 'setRecipient', outputs: [], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [ - { name: '_address', internalType: 'address', type: 'address' }, - { name: '_name', internalType: 'string', type: 'string' }, - ], - name: 'setImplementationName', + inputs: [{ name: '_teleportr', internalType: 'address', type: 'address' }], + name: 'setTeleportr', outputs: [], }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'teleportr', + outputs: [{ name: '', internalType: 'address', type: 'address' }], + }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_address', internalType: 'address', type: 'address' }, - { - name: '_type', - internalType: 'enum ProxyAdmin.ProxyType', - type: 'uint8', - }, + { name: '_asset', internalType: 'contract ERC20', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, ], - name: 'setProxyType', + name: 'withdrawERC20', outputs: [], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [{ name: '_upgrading', internalType: 'bool', type: 'bool' }], - name: 'setUpgrading', + inputs: [ + { name: '_asset', internalType: 'contract ERC20', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + ], + name: 'withdrawERC20', outputs: [], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], - name: 'transferOwnership', + inputs: [ + { name: '_asset', internalType: 'contract ERC721', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_id', internalType: 'uint256', type: 'uint256' }, + ], + name: 'withdrawERC721', outputs: [], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_proxy', internalType: 'address payable', type: 'address' }, - { name: '_implementation', internalType: 'address', type: 'address' }, + { name: '_to', internalType: 'address payable', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, ], - name: 'upgrade', + name: 'withdrawETH', outputs: [], }, { - stateMutability: 'payable', + stateMutability: 'nonpayable', type: 'function', - inputs: [ - { name: '_proxy', internalType: 'address payable', type: 'address' }, - { name: '_implementation', internalType: 'address', type: 'address' }, - { name: '_data', internalType: 'bytes', type: 'bytes' }, - ], - name: 'upgradeAndCall', + inputs: [{ name: '_to', internalType: 'address payable', type: 'address' }], + name: 'withdrawETH', outputs: [], }, -] as const - -/** - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) - */ -export const proxyAdminAddress = { - 1: '0x4200000000000000000000000000000000000018', - 5: '0x4200000000000000000000000000000000000018', -} as const - -/** - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) - */ -export const proxyAdminConfig = { - address: proxyAdminAddress, - abi: proxyAdminABI, -} as const - -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// SchemaRegistry -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x6232208d66bAc2305b46b4Cb6BCB3857B298DF13) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2545fa928d5d278cA75Fd47306e4a89096ff6403) - */ -export const schemaRegistryABI = [ - { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, - { type: 'error', inputs: [], name: 'AlreadyExists' }, - { - type: 'event', - anonymous: false, - inputs: [ - { name: 'uid', internalType: 'bytes32', type: 'bytes32', indexed: true }, - { - name: 'registerer', - internalType: 'address', - type: 'address', - indexed: false, - }, - ], - name: 'Registered', - }, - { - stateMutability: 'view', - type: 'function', - inputs: [{ name: 'uid', internalType: 'bytes32', type: 'bytes32' }], - name: 'getSchema', - outputs: [ - { - name: '', - internalType: 'struct SchemaRecord', - type: 'tuple', - components: [ - { name: 'uid', internalType: 'bytes32', type: 'bytes32' }, - { - name: 'resolver', - internalType: 'contract ISchemaResolver', - type: 'address', - }, - { name: 'revocable', internalType: 'bool', type: 'bool' }, - { name: 'schema', internalType: 'string', type: 'string' }, - ], - }, - ], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: 'schema', internalType: 'string', type: 'string' }, - { - name: 'resolver', - internalType: 'contract ISchemaResolver', - type: 'address', - }, - { name: 'revocable', internalType: 'bool', type: 'bool' }, - ], - name: 'register', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], - }, -] as const - -/** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x6232208d66bAc2305b46b4Cb6BCB3857B298DF13) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2545fa928d5d278cA75Fd47306e4a89096ff6403) - */ -export const schemaRegistryAddress = { - 10: '0x6232208d66bAc2305b46b4Cb6BCB3857B298DF13', - 420: '0x2545fa928d5d278cA75Fd47306e4a89096ff6403', -} as const - -/** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x6232208d66bAc2305b46b4Cb6BCB3857B298DF13) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2545fa928d5d278cA75Fd47306e4a89096ff6403) - */ -export const schemaRegistryConfig = { - address: schemaRegistryAddress, - abi: schemaRegistryABI, -} as const - -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// SequencerFeeVault -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000011) - */ -export const sequencerFeeVaultABI = [ - { - stateMutability: 'nonpayable', - type: 'constructor', - inputs: [{ name: '_recipient', internalType: 'address', type: 'address' }], - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'value', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - { name: 'to', internalType: 'address', type: 'address', indexed: false }, - { - name: 'from', - internalType: 'address', - type: 'address', - indexed: false, - }, - ], - name: 'Withdrawal', - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'MIN_WITHDRAWAL_AMOUNT', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'RECIPIENT', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'l1FeeWallet', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'totalProcessed', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], - }, { stateMutability: 'nonpayable', type: 'function', inputs: [], - name: 'withdraw', - outputs: [], - }, - { stateMutability: 'payable', type: 'receive' }, -] as const - -/** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000011) - */ -export const sequencerFeeVaultAddress = { - 420: '0x4200000000000000000000000000000000000011', -} as const - -/** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000011) - */ -export const sequencerFeeVaultConfig = { - address: sequencerFeeVaultAddress, - abi: sequencerFeeVaultABI, -} as const - -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// SystemConfig -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) - */ -export const systemConfigABI = [ - { - stateMutability: 'nonpayable', - type: 'constructor', - inputs: [ - { name: '_owner', internalType: 'address', type: 'address' }, - { name: '_overhead', internalType: 'uint256', type: 'uint256' }, - { name: '_scalar', internalType: 'uint256', type: 'uint256' }, - { name: '_batcherHash', internalType: 'bytes32', type: 'bytes32' }, - { name: '_gasLimit', internalType: 'uint64', type: 'uint64' }, - { name: '_unsafeBlockSigner', internalType: 'address', type: 'address' }, - { - name: '_config', - internalType: 'struct ResourceMetering.ResourceConfig', - type: 'tuple', - components: [ - { name: 'maxResourceLimit', internalType: 'uint32', type: 'uint32' }, - { - name: 'elasticityMultiplier', - internalType: 'uint8', - type: 'uint8', - }, - { - name: 'baseFeeMaxChangeDenominator', - internalType: 'uint8', - type: 'uint8', - }, - { name: 'minimumBaseFee', internalType: 'uint32', type: 'uint32' }, - { name: 'systemTxMaxGas', internalType: 'uint32', type: 'uint32' }, - { name: 'maximumBaseFee', internalType: 'uint128', type: 'uint128' }, - ], - }, - ], - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'version', - internalType: 'uint256', - type: 'uint256', - indexed: true, - }, - { - name: 'updateType', - internalType: 'enum SystemConfig.UpdateType', - type: 'uint8', - indexed: true, - }, - { name: 'data', internalType: 'bytes', type: 'bytes', indexed: false }, - ], - name: 'ConfigUpdate', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, - ], - name: 'Initialized', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'previousOwner', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'newOwner', - internalType: 'address', - type: 'address', - indexed: true, - }, - ], - name: 'OwnershipTransferred', - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'UNSAFE_BLOCK_SIGNER_SLOT', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'batcherHash', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'gasLimit', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_owner', internalType: 'address', type: 'address' }, - { name: '_overhead', internalType: 'uint256', type: 'uint256' }, - { name: '_scalar', internalType: 'uint256', type: 'uint256' }, - { name: '_batcherHash', internalType: 'bytes32', type: 'bytes32' }, - { name: '_gasLimit', internalType: 'uint64', type: 'uint64' }, - { name: '_unsafeBlockSigner', internalType: 'address', type: 'address' }, - { - name: '_config', - internalType: 'struct ResourceMetering.ResourceConfig', - type: 'tuple', - components: [ - { name: 'maxResourceLimit', internalType: 'uint32', type: 'uint32' }, - { - name: 'elasticityMultiplier', - internalType: 'uint8', - type: 'uint8', - }, - { - name: 'baseFeeMaxChangeDenominator', - internalType: 'uint8', - type: 'uint8', - }, - { name: 'minimumBaseFee', internalType: 'uint32', type: 'uint32' }, - { name: 'systemTxMaxGas', internalType: 'uint32', type: 'uint32' }, - { name: 'maximumBaseFee', internalType: 'uint128', type: 'uint128' }, - ], - }, - ], - name: 'initialize', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'minimumGasLimit', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'overhead', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'owner', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'renounceOwnership', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'resourceConfig', - outputs: [ - { - name: '', - internalType: 'struct ResourceMetering.ResourceConfig', - type: 'tuple', - components: [ - { name: 'maxResourceLimit', internalType: 'uint32', type: 'uint32' }, - { - name: 'elasticityMultiplier', - internalType: 'uint8', - type: 'uint8', - }, - { - name: 'baseFeeMaxChangeDenominator', - internalType: 'uint8', - type: 'uint8', - }, - { name: 'minimumBaseFee', internalType: 'uint32', type: 'uint32' }, - { name: 'systemTxMaxGas', internalType: 'uint32', type: 'uint32' }, - { name: 'maximumBaseFee', internalType: 'uint128', type: 'uint128' }, - ], - }, - ], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'scalar', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_batcherHash', internalType: 'bytes32', type: 'bytes32' }, - ], - name: 'setBatcherHash', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_overhead', internalType: 'uint256', type: 'uint256' }, - { name: '_scalar', internalType: 'uint256', type: 'uint256' }, - ], - name: 'setGasConfig', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: '_gasLimit', internalType: 'uint64', type: 'uint64' }], - name: 'setGasLimit', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { - name: '_config', - internalType: 'struct ResourceMetering.ResourceConfig', - type: 'tuple', - components: [ - { name: 'maxResourceLimit', internalType: 'uint32', type: 'uint32' }, - { - name: 'elasticityMultiplier', - internalType: 'uint8', - type: 'uint8', - }, - { - name: 'baseFeeMaxChangeDenominator', - internalType: 'uint8', - type: 'uint8', - }, - { name: 'minimumBaseFee', internalType: 'uint32', type: 'uint32' }, - { name: 'systemTxMaxGas', internalType: 'uint32', type: 'uint32' }, - { name: 'maximumBaseFee', internalType: 'uint128', type: 'uint128' }, - ], - }, - ], - name: 'setResourceConfig', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_unsafeBlockSigner', internalType: 'address', type: 'address' }, - ], - name: 'setUnsafeBlockSigner', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], - name: 'transferOwnership', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'unsafeBlockSigner', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], - }, -] as const - -/** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) - */ -export const systemConfigAddress = { - 1: '0x229047fed2591dbec1eF1118d64F7aF3dB9EB290', -} as const - -/** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) - */ -export const systemConfigConfig = { - address: systemConfigAddress, - abi: systemConfigABI, -} as const - -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// SystemConfig_goerli -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export const systemConfigGoerliABI = [ - { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'version', - internalType: 'uint256', - type: 'uint256', - indexed: true, - }, - { - name: 'updateType', - internalType: 'enum SystemConfig.UpdateType', - type: 'uint8', - indexed: true, - }, - { name: 'data', internalType: 'bytes', type: 'bytes', indexed: false }, - ], - name: 'ConfigUpdate', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, - ], - name: 'Initialized', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'previousOwner', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'newOwner', - internalType: 'address', - type: 'address', - indexed: true, - }, - ], - name: 'OwnershipTransferred', - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'BATCH_INBOX_SLOT', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'L1_CROSS_DOMAIN_MESSENGER_SLOT', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'L1_ERC_721_BRIDGE_SLOT', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'L1_STANDARD_BRIDGE_SLOT', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'L2_OUTPUT_ORACLE_SLOT', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'OPTIMISM_MINTABLE_ERC20_FACTORY_SLOT', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'OPTIMISM_PORTAL_SLOT', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'UNSAFE_BLOCK_SIGNER_SLOT', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'batchInbox', - outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'batcherHash', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'gasLimit', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_owner', internalType: 'address', type: 'address' }, - { name: '_overhead', internalType: 'uint256', type: 'uint256' }, - { name: '_scalar', internalType: 'uint256', type: 'uint256' }, - { name: '_batcherHash', internalType: 'bytes32', type: 'bytes32' }, - { name: '_gasLimit', internalType: 'uint64', type: 'uint64' }, - { name: '_unsafeBlockSigner', internalType: 'address', type: 'address' }, - { - name: '_config', - internalType: 'struct ResourceMetering.ResourceConfig', - type: 'tuple', - components: [ - { name: 'maxResourceLimit', internalType: 'uint32', type: 'uint32' }, - { - name: 'elasticityMultiplier', - internalType: 'uint8', - type: 'uint8', - }, - { - name: 'baseFeeMaxChangeDenominator', - internalType: 'uint8', - type: 'uint8', - }, - { name: 'minimumBaseFee', internalType: 'uint32', type: 'uint32' }, - { name: 'systemTxMaxGas', internalType: 'uint32', type: 'uint32' }, - { name: 'maximumBaseFee', internalType: 'uint128', type: 'uint128' }, - ], - }, - { name: '_startBlock', internalType: 'uint256', type: 'uint256' }, - { name: '_batchInbox', internalType: 'address', type: 'address' }, - { - name: '_addresses', - internalType: 'struct SystemConfig.Addresses', - type: 'tuple', - components: [ - { - name: 'l1CrossDomainMessenger', - internalType: 'address', - type: 'address', - }, - { name: 'l1ERC721Bridge', internalType: 'address', type: 'address' }, - { - name: 'l1StandardBridge', - internalType: 'address', - type: 'address', - }, - { name: 'l2OutputOracle', internalType: 'address', type: 'address' }, - { name: 'optimismPortal', internalType: 'address', type: 'address' }, - { - name: 'optimismMintableERC20Factory', - internalType: 'address', - type: 'address', - }, - ], - }, - ], - name: 'initialize', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'l1CrossDomainMessenger', - outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'l1ERC721Bridge', - outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'l1StandardBridge', - outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'l2OutputOracle', - outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'minimumGasLimit', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'optimismMintableERC20Factory', - outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'optimismPortal', - outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'overhead', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'owner', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'renounceOwnership', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'resourceConfig', - outputs: [ - { - name: '', - internalType: 'struct ResourceMetering.ResourceConfig', - type: 'tuple', - components: [ - { name: 'maxResourceLimit', internalType: 'uint32', type: 'uint32' }, - { - name: 'elasticityMultiplier', - internalType: 'uint8', - type: 'uint8', - }, - { - name: 'baseFeeMaxChangeDenominator', - internalType: 'uint8', - type: 'uint8', - }, - { name: 'minimumBaseFee', internalType: 'uint32', type: 'uint32' }, - { name: 'systemTxMaxGas', internalType: 'uint32', type: 'uint32' }, - { name: 'maximumBaseFee', internalType: 'uint128', type: 'uint128' }, - ], - }, - ], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'scalar', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_batcherHash', internalType: 'bytes32', type: 'bytes32' }, - ], - name: 'setBatcherHash', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_overhead', internalType: 'uint256', type: 'uint256' }, - { name: '_scalar', internalType: 'uint256', type: 'uint256' }, - ], - name: 'setGasConfig', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: '_gasLimit', internalType: 'uint64', type: 'uint64' }], - name: 'setGasLimit', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { - name: '_config', - internalType: 'struct ResourceMetering.ResourceConfig', - type: 'tuple', - components: [ - { name: 'maxResourceLimit', internalType: 'uint32', type: 'uint32' }, - { - name: 'elasticityMultiplier', - internalType: 'uint8', - type: 'uint8', - }, - { - name: 'baseFeeMaxChangeDenominator', - internalType: 'uint8', - type: 'uint8', - }, - { name: 'minimumBaseFee', internalType: 'uint32', type: 'uint32' }, - { name: 'systemTxMaxGas', internalType: 'uint32', type: 'uint32' }, - { name: 'maximumBaseFee', internalType: 'uint128', type: 'uint128' }, - ], - }, - ], - name: 'setResourceConfig', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_unsafeBlockSigner', internalType: 'address', type: 'address' }, - ], - name: 'setUnsafeBlockSigner', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'startBlock', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], - name: 'transferOwnership', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'unsafeBlockSigner', - outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], - }, -] as const - -/** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export const systemConfigGoerliAddress = { - 5: '0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60', -} as const - -/** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export const systemConfigGoerliConfig = { - address: systemConfigGoerliAddress, - abi: systemConfigGoerliABI, -} as const - -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// SystemDictator -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) - */ -export const systemDictatorABI = [ - { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, - { - type: 'event', - anonymous: false, - inputs: [ - { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, - ], - name: 'Initialized', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'previousOwner', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'newOwner', - internalType: 'address', - type: 'address', - indexed: true, - }, - ], - name: 'OwnershipTransferred', - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'EXIT_1_NO_RETURN_STEP', - outputs: [{ name: '', internalType: 'uint8', type: 'uint8' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'PROXY_TRANSFER_STEP', - outputs: [{ name: '', internalType: 'uint8', type: 'uint8' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'config', - outputs: [ - { - name: 'globalConfig', - internalType: 'struct SystemDictator.GlobalConfig', - type: 'tuple', - components: [ - { - name: 'addressManager', - internalType: 'contract AddressManager', - type: 'address', - }, - { - name: 'proxyAdmin', - internalType: 'contract ProxyAdmin', - type: 'address', - }, - { name: 'controller', internalType: 'address', type: 'address' }, - { name: 'finalOwner', internalType: 'address', type: 'address' }, - ], - }, - { - name: 'proxyAddressConfig', - internalType: 'struct SystemDictator.ProxyAddressConfig', - type: 'tuple', - components: [ - { - name: 'l2OutputOracleProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'optimismPortalProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'l1CrossDomainMessengerProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'l1StandardBridgeProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'optimismMintableERC20FactoryProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'l1ERC721BridgeProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'systemConfigProxy', - internalType: 'address', - type: 'address', - }, - ], - }, - { - name: 'implementationAddressConfig', - internalType: 'struct SystemDictator.ImplementationAddressConfig', - type: 'tuple', - components: [ - { - name: 'l2OutputOracleImpl', - internalType: 'contract L2OutputOracle', - type: 'address', - }, - { - name: 'optimismPortalImpl', - internalType: 'contract OptimismPortal', - type: 'address', - }, - { - name: 'l1CrossDomainMessengerImpl', - internalType: 'contract L1CrossDomainMessenger', - type: 'address', - }, - { - name: 'l1StandardBridgeImpl', - internalType: 'contract L1StandardBridge', - type: 'address', - }, - { - name: 'optimismMintableERC20FactoryImpl', - internalType: 'contract OptimismMintableERC20Factory', - type: 'address', - }, - { - name: 'l1ERC721BridgeImpl', - internalType: 'contract L1ERC721Bridge', - type: 'address', - }, - { - name: 'portalSenderImpl', - internalType: 'contract PortalSender', - type: 'address', - }, - { - name: 'systemConfigImpl', - internalType: 'contract SystemConfig', - type: 'address', - }, - ], - }, - { - name: 'systemConfigConfig', - internalType: 'struct SystemDictator.SystemConfigConfig', - type: 'tuple', - components: [ - { name: 'owner', internalType: 'address', type: 'address' }, - { name: 'overhead', internalType: 'uint256', type: 'uint256' }, - { name: 'scalar', internalType: 'uint256', type: 'uint256' }, - { name: 'batcherHash', internalType: 'bytes32', type: 'bytes32' }, - { name: 'gasLimit', internalType: 'uint64', type: 'uint64' }, - { - name: 'unsafeBlockSigner', - internalType: 'address', - type: 'address', - }, - { - name: 'resourceConfig', - internalType: 'struct ResourceMetering.ResourceConfig', - type: 'tuple', - components: [ - { - name: 'maxResourceLimit', - internalType: 'uint32', - type: 'uint32', - }, - { - name: 'elasticityMultiplier', - internalType: 'uint8', - type: 'uint8', - }, - { - name: 'baseFeeMaxChangeDenominator', - internalType: 'uint8', - type: 'uint8', - }, - { - name: 'minimumBaseFee', - internalType: 'uint32', - type: 'uint32', - }, - { - name: 'systemTxMaxGas', - internalType: 'uint32', - type: 'uint32', - }, - { - name: 'maximumBaseFee', - internalType: 'uint128', - type: 'uint128', - }, - ], - }, - ], - }, - ], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'currentStep', - outputs: [{ name: '', internalType: 'uint8', type: 'uint8' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'dynamicConfigSet', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'exit1', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'exited', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'finalize', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'finalized', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { - name: '_config', - internalType: 'struct SystemDictator.DeployConfig', - type: 'tuple', - components: [ - { - name: 'globalConfig', - internalType: 'struct SystemDictator.GlobalConfig', - type: 'tuple', - components: [ - { - name: 'addressManager', - internalType: 'contract AddressManager', - type: 'address', - }, - { - name: 'proxyAdmin', - internalType: 'contract ProxyAdmin', - type: 'address', - }, - { name: 'controller', internalType: 'address', type: 'address' }, - { name: 'finalOwner', internalType: 'address', type: 'address' }, - ], - }, - { - name: 'proxyAddressConfig', - internalType: 'struct SystemDictator.ProxyAddressConfig', - type: 'tuple', - components: [ - { - name: 'l2OutputOracleProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'optimismPortalProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'l1CrossDomainMessengerProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'l1StandardBridgeProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'optimismMintableERC20FactoryProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'l1ERC721BridgeProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'systemConfigProxy', - internalType: 'address', - type: 'address', - }, - ], - }, - { - name: 'implementationAddressConfig', - internalType: 'struct SystemDictator.ImplementationAddressConfig', - type: 'tuple', - components: [ - { - name: 'l2OutputOracleImpl', - internalType: 'contract L2OutputOracle', - type: 'address', - }, - { - name: 'optimismPortalImpl', - internalType: 'contract OptimismPortal', - type: 'address', - }, - { - name: 'l1CrossDomainMessengerImpl', - internalType: 'contract L1CrossDomainMessenger', - type: 'address', - }, - { - name: 'l1StandardBridgeImpl', - internalType: 'contract L1StandardBridge', - type: 'address', - }, - { - name: 'optimismMintableERC20FactoryImpl', - internalType: 'contract OptimismMintableERC20Factory', - type: 'address', - }, - { - name: 'l1ERC721BridgeImpl', - internalType: 'contract L1ERC721Bridge', - type: 'address', - }, - { - name: 'portalSenderImpl', - internalType: 'contract PortalSender', - type: 'address', - }, - { - name: 'systemConfigImpl', - internalType: 'contract SystemConfig', - type: 'address', - }, - ], - }, - { - name: 'systemConfigConfig', - internalType: 'struct SystemDictator.SystemConfigConfig', - type: 'tuple', - components: [ - { name: 'owner', internalType: 'address', type: 'address' }, - { name: 'overhead', internalType: 'uint256', type: 'uint256' }, - { name: 'scalar', internalType: 'uint256', type: 'uint256' }, - { name: 'batcherHash', internalType: 'bytes32', type: 'bytes32' }, - { name: 'gasLimit', internalType: 'uint64', type: 'uint64' }, - { - name: 'unsafeBlockSigner', - internalType: 'address', - type: 'address', - }, - { - name: 'resourceConfig', - internalType: 'struct ResourceMetering.ResourceConfig', - type: 'tuple', - components: [ - { - name: 'maxResourceLimit', - internalType: 'uint32', - type: 'uint32', - }, - { - name: 'elasticityMultiplier', - internalType: 'uint8', - type: 'uint8', - }, - { - name: 'baseFeeMaxChangeDenominator', - internalType: 'uint8', - type: 'uint8', - }, - { - name: 'minimumBaseFee', - internalType: 'uint32', - type: 'uint32', - }, - { - name: 'systemTxMaxGas', - internalType: 'uint32', - type: 'uint32', - }, - { - name: 'maximumBaseFee', - internalType: 'uint128', - type: 'uint128', - }, - ], - }, - ], - }, - ], - }, - ], - name: 'initialize', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'l2OutputOracleDynamicConfig', - outputs: [ - { - name: 'l2OutputOracleStartingBlockNumber', - internalType: 'uint256', - type: 'uint256', - }, - { - name: 'l2OutputOracleStartingTimestamp', - internalType: 'uint256', - type: 'uint256', - }, - ], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'oldL1CrossDomainMessenger', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'optimismPortalDynamicConfig', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'owner', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'phase1', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'phase2', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'renounceOwnership', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'step1', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'step2', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'step3', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'step4', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'step5', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], - name: 'transferOwnership', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { - name: '_l2OutputOracleDynamicConfig', - internalType: 'struct SystemDictator.L2OutputOracleDynamicConfig', - type: 'tuple', - components: [ - { - name: 'l2OutputOracleStartingBlockNumber', - internalType: 'uint256', - type: 'uint256', - }, - { - name: 'l2OutputOracleStartingTimestamp', - internalType: 'uint256', - type: 'uint256', - }, - ], - }, - { - name: '_optimismPortalDynamicConfig', - internalType: 'bool', - type: 'bool', - }, - ], - name: 'updateDynamicConfig', - outputs: [], - }, -] as const - -/** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) - */ -export const systemDictatorAddress = { - 1: '0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB', -} as const - -/** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) - */ -export const systemDictatorConfig = { - address: systemDictatorAddress, - abi: systemDictatorABI, -} as const - -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// SystemDictator_goerli -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) - */ -export const systemDictatorGoerliABI = [ - { - type: 'event', - anonymous: false, - inputs: [ - { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, - ], - name: 'Initialized', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'previousOwner', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'newOwner', - internalType: 'address', - type: 'address', - indexed: true, - }, - ], - name: 'OwnershipTransferred', - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'EXIT_1_NO_RETURN_STEP', - outputs: [{ name: '', internalType: 'uint8', type: 'uint8' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'PROXY_TRANSFER_STEP', - outputs: [{ name: '', internalType: 'uint8', type: 'uint8' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'config', - outputs: [ - { - name: 'globalConfig', - internalType: 'struct SystemDictator.GlobalConfig', - type: 'tuple', - components: [ - { - name: 'addressManager', - internalType: 'contract AddressManager', - type: 'address', - }, - { - name: 'proxyAdmin', - internalType: 'contract ProxyAdmin', - type: 'address', - }, - { name: 'controller', internalType: 'address', type: 'address' }, - { name: 'finalOwner', internalType: 'address', type: 'address' }, - ], - }, - { - name: 'proxyAddressConfig', - internalType: 'struct SystemDictator.ProxyAddressConfig', - type: 'tuple', - components: [ - { - name: 'l2OutputOracleProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'optimismPortalProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'l1CrossDomainMessengerProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'l1StandardBridgeProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'optimismMintableERC20FactoryProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'l1ERC721BridgeProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'systemConfigProxy', - internalType: 'address', - type: 'address', - }, - ], - }, - { - name: 'implementationAddressConfig', - internalType: 'struct SystemDictator.ImplementationAddressConfig', - type: 'tuple', - components: [ - { - name: 'l2OutputOracleImpl', - internalType: 'contract L2OutputOracle', - type: 'address', - }, - { - name: 'optimismPortalImpl', - internalType: 'contract OptimismPortal', - type: 'address', - }, - { - name: 'l1CrossDomainMessengerImpl', - internalType: 'contract L1CrossDomainMessenger', - type: 'address', - }, - { - name: 'l1StandardBridgeImpl', - internalType: 'contract L1StandardBridge', - type: 'address', - }, - { - name: 'optimismMintableERC20FactoryImpl', - internalType: 'contract OptimismMintableERC20Factory', - type: 'address', - }, - { - name: 'l1ERC721BridgeImpl', - internalType: 'contract L1ERC721Bridge', - type: 'address', - }, - { - name: 'portalSenderImpl', - internalType: 'contract PortalSender', - type: 'address', - }, - { - name: 'systemConfigImpl', - internalType: 'contract SystemConfig', - type: 'address', - }, - ], - }, - { - name: 'systemConfigConfig', - internalType: 'struct SystemDictator.SystemConfigConfig', - type: 'tuple', - components: [ - { name: 'owner', internalType: 'address', type: 'address' }, - { name: 'overhead', internalType: 'uint256', type: 'uint256' }, - { name: 'scalar', internalType: 'uint256', type: 'uint256' }, - { name: 'batcherHash', internalType: 'bytes32', type: 'bytes32' }, - { name: 'gasLimit', internalType: 'uint64', type: 'uint64' }, - { - name: 'unsafeBlockSigner', - internalType: 'address', - type: 'address', - }, - ], - }, - ], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'currentStep', - outputs: [{ name: '', internalType: 'uint8', type: 'uint8' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'dynamicConfigSet', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'exit1', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'finalize', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'finalized', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { - name: '_config', - internalType: 'struct SystemDictator.DeployConfig', - type: 'tuple', - components: [ - { - name: 'globalConfig', - internalType: 'struct SystemDictator.GlobalConfig', - type: 'tuple', - components: [ - { - name: 'addressManager', - internalType: 'contract AddressManager', - type: 'address', - }, - { - name: 'proxyAdmin', - internalType: 'contract ProxyAdmin', - type: 'address', - }, - { name: 'controller', internalType: 'address', type: 'address' }, - { name: 'finalOwner', internalType: 'address', type: 'address' }, - ], - }, - { - name: 'proxyAddressConfig', - internalType: 'struct SystemDictator.ProxyAddressConfig', - type: 'tuple', - components: [ - { - name: 'l2OutputOracleProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'optimismPortalProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'l1CrossDomainMessengerProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'l1StandardBridgeProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'optimismMintableERC20FactoryProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'l1ERC721BridgeProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'systemConfigProxy', - internalType: 'address', - type: 'address', - }, - ], - }, - { - name: 'implementationAddressConfig', - internalType: 'struct SystemDictator.ImplementationAddressConfig', - type: 'tuple', - components: [ - { - name: 'l2OutputOracleImpl', - internalType: 'contract L2OutputOracle', - type: 'address', - }, - { - name: 'optimismPortalImpl', - internalType: 'contract OptimismPortal', - type: 'address', - }, - { - name: 'l1CrossDomainMessengerImpl', - internalType: 'contract L1CrossDomainMessenger', - type: 'address', - }, - { - name: 'l1StandardBridgeImpl', - internalType: 'contract L1StandardBridge', - type: 'address', - }, - { - name: 'optimismMintableERC20FactoryImpl', - internalType: 'contract OptimismMintableERC20Factory', - type: 'address', - }, - { - name: 'l1ERC721BridgeImpl', - internalType: 'contract L1ERC721Bridge', - type: 'address', - }, - { - name: 'portalSenderImpl', - internalType: 'contract PortalSender', - type: 'address', - }, - { - name: 'systemConfigImpl', - internalType: 'contract SystemConfig', - type: 'address', - }, - ], - }, - { - name: 'systemConfigConfig', - internalType: 'struct SystemDictator.SystemConfigConfig', - type: 'tuple', - components: [ - { name: 'owner', internalType: 'address', type: 'address' }, - { name: 'overhead', internalType: 'uint256', type: 'uint256' }, - { name: 'scalar', internalType: 'uint256', type: 'uint256' }, - { name: 'batcherHash', internalType: 'bytes32', type: 'bytes32' }, - { name: 'gasLimit', internalType: 'uint64', type: 'uint64' }, - { - name: 'unsafeBlockSigner', - internalType: 'address', - type: 'address', - }, - ], - }, - ], - }, - ], - name: 'initialize', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'l2OutputOracleDynamicConfig', - outputs: [ - { - name: 'l2OutputOracleStartingBlockNumber', - internalType: 'uint256', - type: 'uint256', - }, - { - name: 'l2OutputOracleStartingTimestamp', - internalType: 'uint256', - type: 'uint256', - }, - ], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'oldL1CrossDomainMessenger', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'owner', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'renounceOwnership', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'step1', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'step2', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'step3', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'step4', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'step5', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'step6', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], - name: 'transferOwnership', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { - name: '_l2OutputOracleDynamicConfig', - internalType: 'struct SystemDictator.L2OutputOracleDynamicConfig', - type: 'tuple', - components: [ - { - name: 'l2OutputOracleStartingBlockNumber', - internalType: 'uint256', - type: 'uint256', - }, - { - name: 'l2OutputOracleStartingTimestamp', - internalType: 'uint256', - type: 'uint256', - }, - ], - }, - ], - name: 'updateL2OutputOracleDynamicConfig', - outputs: [], - }, -] as const - -/** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) - */ -export const systemDictatorGoerliAddress = { - 5: '0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971', -} as const - -/** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) - */ -export const systemDictatorGoerliConfig = { - address: systemDictatorGoerliAddress, - abi: systemDictatorGoerliABI, -} as const - -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// TeleportrWithdrawer -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) - */ -export const teleportrWithdrawerABI = [ - { - stateMutability: 'nonpayable', - type: 'constructor', - inputs: [{ name: '_owner', internalType: 'address', type: 'address' }], - }, - { - type: 'event', - anonymous: false, - inputs: [ - { name: 'user', internalType: 'address', type: 'address', indexed: true }, - { - name: 'newOwner', - internalType: 'address', - type: 'address', - indexed: true, - }, - ], - name: 'OwnerUpdated', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - ], - name: 'ReceivedETH', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'withdrawer', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'recipient', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'asset', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - ], - name: 'WithdrewERC20', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'withdrawer', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'recipient', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'asset', - internalType: 'address', - type: 'address', - indexed: true, - }, - { name: 'id', internalType: 'uint256', type: 'uint256', indexed: false }, - ], - name: 'WithdrewERC721', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'withdrawer', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'recipient', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - ], - name: 'WithdrewETH', - }, - { - stateMutability: 'payable', - type: 'function', - inputs: [ - { name: '_target', internalType: 'address', type: 'address' }, - { name: '_data', internalType: 'bytes', type: 'bytes' }, - { name: '_gas', internalType: 'uint256', type: 'uint256' }, - { name: '_value', internalType: 'uint256', type: 'uint256' }, - ], - name: 'CALL', - outputs: [ - { name: '', internalType: 'bool', type: 'bool' }, - { name: '', internalType: 'bytes', type: 'bytes' }, - ], - }, - { - stateMutability: 'payable', - type: 'function', - inputs: [ - { name: '_target', internalType: 'address', type: 'address' }, - { name: '_data', internalType: 'bytes', type: 'bytes' }, - { name: '_gas', internalType: 'uint256', type: 'uint256' }, - ], - name: 'DELEGATECALL', - outputs: [ - { name: '', internalType: 'bool', type: 'bool' }, - { name: '', internalType: 'bytes', type: 'bytes' }, - ], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'data', - outputs: [{ name: '', internalType: 'bytes', type: 'bytes' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'owner', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'recipient', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: '_data', internalType: 'bytes', type: 'bytes' }], - name: 'setData', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], - name: 'setOwner', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: '_recipient', internalType: 'address', type: 'address' }], - name: 'setRecipient', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: '_teleportr', internalType: 'address', type: 'address' }], - name: 'setTeleportr', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'teleportr', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_asset', internalType: 'contract ERC20', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - ], - name: 'withdrawERC20', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_asset', internalType: 'contract ERC20', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - ], - name: 'withdrawERC20', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_asset', internalType: 'contract ERC721', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_id', internalType: 'uint256', type: 'uint256' }, - ], - name: 'withdrawERC721', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_to', internalType: 'address payable', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - ], - name: 'withdrawETH', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: '_to', internalType: 'address payable', type: 'address' }], - name: 'withdrawETH', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'withdrawFromTeleportr', - outputs: [], - }, - { stateMutability: 'payable', type: 'receive' }, -] as const - -/** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) - */ -export const teleportrWithdrawerAddress = { - 1: '0x78A25524D90E3D0596558fb43789bD800a5c3007', -} as const - -/** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) - */ -export const teleportrWithdrawerConfig = { - address: teleportrWithdrawerAddress, - abi: teleportrWithdrawerABI, -} as const - -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// eslintIgnore -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// Core -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/** - * Wraps __{@link getContract}__ with `abi` set to __{@link addressManagerABI}__. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdE1FCfB0851916CA5101820A69b13a4E276bd81F) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xa6f73589243a6A7a9023b1Fa0651b1d89c177111) - */ -export function getAddressManager( - config: Omit & { - chainId?: keyof typeof addressManagerAddress - } -) { - return getContract({ - abi: addressManagerABI, - address: - addressManagerAddress[ - config.chainId as keyof typeof addressManagerAddress - ], - ...config, - }) -} - -/** - * Wraps __{@link readContract}__ with `abi` set to __{@link addressManagerABI}__. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdE1FCfB0851916CA5101820A69b13a4E276bd81F) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xa6f73589243a6A7a9023b1Fa0651b1d89c177111) - */ -export function readAddressManager< - TAbi extends readonly unknown[] = typeof addressManagerABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof addressManagerAddress - } -) { - return readContract({ - abi: addressManagerABI, - address: - addressManagerAddress[ - config.chainId as keyof typeof addressManagerAddress - ], - ...config, - } as unknown as ReadContractConfig) -} - -/** - * Wraps __{@link writeContract}__ with `abi` set to __{@link addressManagerABI}__. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdE1FCfB0851916CA5101820A69b13a4E276bd81F) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xa6f73589243a6A7a9023b1Fa0651b1d89c177111) - */ -export function writeAddressManager< - TFunctionName extends string, - TMode extends WriteContractMode, - TChainId extends number = keyof typeof addressManagerAddress ->( - config: - | (Omit< - WriteContractPreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof addressManagerAddress - }) - | (Omit< - WriteContractUnpreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof addressManagerAddress - }) -) { - return writeContract({ - abi: addressManagerABI, - address: - addressManagerAddress[ - config.chainId as keyof typeof addressManagerAddress - ], - ...config, - } as unknown as WriteContractArgs) -} - -/** - * Wraps __{@link prepareWriteContract}__ with `abi` set to __{@link addressManagerABI}__. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdE1FCfB0851916CA5101820A69b13a4E276bd81F) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xa6f73589243a6A7a9023b1Fa0651b1d89c177111) - */ -export function prepareWriteAddressManager< - TAbi extends readonly unknown[] = typeof addressManagerABI, - TFunctionName extends string = string ->( - config: Omit< - PrepareWriteContractConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof addressManagerAddress } -) { - return prepareWriteContract({ - abi: addressManagerABI, - address: - addressManagerAddress[ - config.chainId as keyof typeof addressManagerAddress - ], - ...config, - } as unknown as PrepareWriteContractConfig) -} - -/** - * Wraps __{@link watchContractEvent}__ with `abi` set to __{@link addressManagerABI}__. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdE1FCfB0851916CA5101820A69b13a4E276bd81F) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xa6f73589243a6A7a9023b1Fa0651b1d89c177111) - */ -export function watchAddressManagerEvent< - TAbi extends readonly unknown[] = typeof addressManagerABI, - TEventName extends string = string ->( - config: Omit< - WatchContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof addressManagerAddress }, - callback: WatchContractEventCallback -) { - return watchContractEvent( - { - abi: addressManagerABI, - address: - addressManagerAddress[ - config.chainId as keyof typeof addressManagerAddress - ], - ...config, - } as WatchContractEventConfig, - callback - ) -} - -/** - * Wraps __{@link getContract}__ with `abi` set to __{@link assetReceiverABI}__. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - */ -export function getAssetReceiver( - config: Omit & { - chainId?: keyof typeof assetReceiverAddress - } -) { - return getContract({ - abi: assetReceiverABI, - address: - assetReceiverAddress[config.chainId as keyof typeof assetReceiverAddress], - ...config, - }) -} - -/** - * Wraps __{@link readContract}__ with `abi` set to __{@link assetReceiverABI}__. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - */ -export function readAssetReceiver< - TAbi extends readonly unknown[] = typeof assetReceiverABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof assetReceiverAddress - } -) { - return readContract({ - abi: assetReceiverABI, - address: - assetReceiverAddress[config.chainId as keyof typeof assetReceiverAddress], - ...config, - } as unknown as ReadContractConfig) -} - -/** - * Wraps __{@link writeContract}__ with `abi` set to __{@link assetReceiverABI}__. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - */ -export function writeAssetReceiver< - TFunctionName extends string, - TMode extends WriteContractMode, - TChainId extends number = keyof typeof assetReceiverAddress ->( - config: - | (Omit< - WriteContractPreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof assetReceiverAddress - }) - | (Omit< - WriteContractUnpreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof assetReceiverAddress - }) -) { - return writeContract({ - abi: assetReceiverABI, - address: - assetReceiverAddress[config.chainId as keyof typeof assetReceiverAddress], - ...config, - } as unknown as WriteContractArgs) -} - -/** - * Wraps __{@link prepareWriteContract}__ with `abi` set to __{@link assetReceiverABI}__. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - */ -export function prepareWriteAssetReceiver< - TAbi extends readonly unknown[] = typeof assetReceiverABI, - TFunctionName extends string = string ->( - config: Omit< - PrepareWriteContractConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof assetReceiverAddress } -) { - return prepareWriteContract({ - abi: assetReceiverABI, - address: - assetReceiverAddress[config.chainId as keyof typeof assetReceiverAddress], - ...config, - } as unknown as PrepareWriteContractConfig) -} - -/** - * Wraps __{@link watchContractEvent}__ with `abi` set to __{@link assetReceiverABI}__. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - */ -export function watchAssetReceiverEvent< - TAbi extends readonly unknown[] = typeof assetReceiverABI, - TEventName extends string = string ->( - config: Omit< - WatchContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof assetReceiverAddress }, - callback: WatchContractEventCallback -) { - return watchContractEvent( - { - abi: assetReceiverABI, - address: - assetReceiverAddress[ - config.chainId as keyof typeof assetReceiverAddress - ], - ...config, - } as WatchContractEventConfig, - callback - ) -} - -/** - * Wraps __{@link getContract}__ with `abi` set to __{@link attestationStationABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0xEE36eaaD94d1Cc1d0eccaDb55C38bFfB6Be06C77) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0xEE36eaaD94d1Cc1d0eccaDb55C38bFfB6Be06C77) - */ -export function getAttestationStation( - config: Omit & { - chainId?: keyof typeof attestationStationAddress - } -) { - return getContract({ - abi: attestationStationABI, - address: - attestationStationAddress[ - config.chainId as keyof typeof attestationStationAddress - ], - ...config, - }) -} - -/** - * Wraps __{@link readContract}__ with `abi` set to __{@link attestationStationABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0xEE36eaaD94d1Cc1d0eccaDb55C38bFfB6Be06C77) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0xEE36eaaD94d1Cc1d0eccaDb55C38bFfB6Be06C77) - */ -export function readAttestationStation< - TAbi extends readonly unknown[] = typeof attestationStationABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof attestationStationAddress - } -) { - return readContract({ - abi: attestationStationABI, - address: - attestationStationAddress[ - config.chainId as keyof typeof attestationStationAddress - ], - ...config, - } as unknown as ReadContractConfig) -} - -/** - * Wraps __{@link writeContract}__ with `abi` set to __{@link attestationStationABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0xEE36eaaD94d1Cc1d0eccaDb55C38bFfB6Be06C77) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0xEE36eaaD94d1Cc1d0eccaDb55C38bFfB6Be06C77) - */ -export function writeAttestationStation< - TFunctionName extends string, - TMode extends WriteContractMode, - TChainId extends number = keyof typeof attestationStationAddress ->( - config: - | (Omit< - WriteContractPreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof attestationStationAddress - }) - | (Omit< - WriteContractUnpreparedArgs< - typeof attestationStationABI, - TFunctionName - >, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof attestationStationAddress - }) -) { - return writeContract({ - abi: attestationStationABI, - address: - attestationStationAddress[ - config.chainId as keyof typeof attestationStationAddress - ], - ...config, - } as unknown as WriteContractArgs) -} - -/** - * Wraps __{@link prepareWriteContract}__ with `abi` set to __{@link attestationStationABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0xEE36eaaD94d1Cc1d0eccaDb55C38bFfB6Be06C77) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0xEE36eaaD94d1Cc1d0eccaDb55C38bFfB6Be06C77) - */ -export function prepareWriteAttestationStation< - TAbi extends readonly unknown[] = typeof attestationStationABI, - TFunctionName extends string = string ->( - config: Omit< - PrepareWriteContractConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof attestationStationAddress } -) { - return prepareWriteContract({ - abi: attestationStationABI, - address: - attestationStationAddress[ - config.chainId as keyof typeof attestationStationAddress - ], - ...config, - } as unknown as PrepareWriteContractConfig) -} - -/** - * Wraps __{@link watchContractEvent}__ with `abi` set to __{@link attestationStationABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0xEE36eaaD94d1Cc1d0eccaDb55C38bFfB6Be06C77) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0xEE36eaaD94d1Cc1d0eccaDb55C38bFfB6Be06C77) - */ -export function watchAttestationStationEvent< - TAbi extends readonly unknown[] = typeof attestationStationABI, - TEventName extends string = string ->( - config: Omit< - WatchContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof attestationStationAddress }, - callback: WatchContractEventCallback -) { - return watchContractEvent( - { - abi: attestationStationABI, - address: - attestationStationAddress[ - config.chainId as keyof typeof attestationStationAddress - ], - ...config, - } as WatchContractEventConfig, - callback - ) -} - -/** - * Wraps __{@link getContract}__ with `abi` set to __{@link baseFeeVaultABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000019) - */ -export function getBaseFeeVault( - config: Omit & { - chainId?: keyof typeof baseFeeVaultAddress - } -) { - return getContract({ - abi: baseFeeVaultABI, - address: baseFeeVaultAddress[420], - ...config, - }) -} - -/** - * Wraps __{@link readContract}__ with `abi` set to __{@link baseFeeVaultABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000019) - */ -export function readBaseFeeVault< - TAbi extends readonly unknown[] = typeof baseFeeVaultABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof baseFeeVaultAddress - } -) { - return readContract({ - abi: baseFeeVaultABI, - address: baseFeeVaultAddress[420], - ...config, - } as unknown as ReadContractConfig) -} - -/** - * Wraps __{@link writeContract}__ with `abi` set to __{@link baseFeeVaultABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000019) - */ -export function writeBaseFeeVault< - TFunctionName extends string, - TMode extends WriteContractMode, - TChainId extends number = keyof typeof baseFeeVaultAddress ->( - config: - | (Omit< - WriteContractPreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof baseFeeVaultAddress - }) - | (Omit< - WriteContractUnpreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof baseFeeVaultAddress - }) -) { - return writeContract({ - abi: baseFeeVaultABI, - address: baseFeeVaultAddress[420], - ...config, - } as unknown as WriteContractArgs) -} - -/** - * Wraps __{@link prepareWriteContract}__ with `abi` set to __{@link baseFeeVaultABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000019) - */ -export function prepareWriteBaseFeeVault< - TAbi extends readonly unknown[] = typeof baseFeeVaultABI, - TFunctionName extends string = string ->( - config: Omit< - PrepareWriteContractConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof baseFeeVaultAddress } -) { - return prepareWriteContract({ - abi: baseFeeVaultABI, - address: baseFeeVaultAddress[420], - ...config, - } as unknown as PrepareWriteContractConfig) -} - -/** - * Wraps __{@link watchContractEvent}__ with `abi` set to __{@link baseFeeVaultABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000019) - */ -export function watchBaseFeeVaultEvent< - TAbi extends readonly unknown[] = typeof baseFeeVaultABI, - TEventName extends string = string ->( - config: Omit< - WatchContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof baseFeeVaultAddress }, - callback: WatchContractEventCallback -) { - return watchContractEvent( - { - abi: baseFeeVaultABI, - address: baseFeeVaultAddress[420], - ...config, - } as WatchContractEventConfig, - callback - ) -} - -/** - * Wraps __{@link getContract}__ with `abi` set to __{@link checkBalanceHighABI}__. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x7eC64a8a591bFf829ff6C8be76074D540ACb813F) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x7eC64a8a591bFf829ff6C8be76074D540ACb813F) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5d7103853f12109A7d27F118e54BbC654ad847E9) - */ -export function getCheckBalanceHigh( - config: Omit & { - chainId?: keyof typeof checkBalanceHighAddress - } -) { - return getContract({ - abi: checkBalanceHighABI, - address: - checkBalanceHighAddress[ - config.chainId as keyof typeof checkBalanceHighAddress - ], - ...config, - }) -} - -/** - * Wraps __{@link readContract}__ with `abi` set to __{@link checkBalanceHighABI}__. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x7eC64a8a591bFf829ff6C8be76074D540ACb813F) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x7eC64a8a591bFf829ff6C8be76074D540ACb813F) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5d7103853f12109A7d27F118e54BbC654ad847E9) - */ -export function readCheckBalanceHigh< - TAbi extends readonly unknown[] = typeof checkBalanceHighABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof checkBalanceHighAddress - } -) { - return readContract({ - abi: checkBalanceHighABI, - address: - checkBalanceHighAddress[ - config.chainId as keyof typeof checkBalanceHighAddress - ], - ...config, - } as unknown as ReadContractConfig) -} - -/** - * Wraps __{@link watchContractEvent}__ with `abi` set to __{@link checkBalanceHighABI}__. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x7eC64a8a591bFf829ff6C8be76074D540ACb813F) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x7eC64a8a591bFf829ff6C8be76074D540ACb813F) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5d7103853f12109A7d27F118e54BbC654ad847E9) - */ -export function watchCheckBalanceHighEvent< - TAbi extends readonly unknown[] = typeof checkBalanceHighABI, - TEventName extends string = string ->( - config: Omit< - WatchContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof checkBalanceHighAddress }, - callback: WatchContractEventCallback -) { - return watchContractEvent( - { - abi: checkBalanceHighABI, - address: - checkBalanceHighAddress[ - config.chainId as keyof typeof checkBalanceHighAddress - ], - ...config, - } as WatchContractEventConfig, - callback - ) -} - -/** - * Wraps __{@link getContract}__ with `abi` set to __{@link checkBalanceLowABI}__. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x381a4eFC2A2C914eA1889722bB4B44Fa6BD5b640) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x381a4eFC2A2C914eA1889722bB4B44Fa6BD5b640) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x7Ce13D154FAEE5C8B3E6b19d4Add16f21d884474) - */ -export function getCheckBalanceLow( - config: Omit & { - chainId?: keyof typeof checkBalanceLowAddress - } -) { - return getContract({ - abi: checkBalanceLowABI, - address: - checkBalanceLowAddress[ - config.chainId as keyof typeof checkBalanceLowAddress - ], - ...config, - }) -} - -/** - * Wraps __{@link readContract}__ with `abi` set to __{@link checkBalanceLowABI}__. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x381a4eFC2A2C914eA1889722bB4B44Fa6BD5b640) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x381a4eFC2A2C914eA1889722bB4B44Fa6BD5b640) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x7Ce13D154FAEE5C8B3E6b19d4Add16f21d884474) - */ -export function readCheckBalanceLow< - TAbi extends readonly unknown[] = typeof checkBalanceLowABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof checkBalanceLowAddress - } -) { - return readContract({ - abi: checkBalanceLowABI, - address: - checkBalanceLowAddress[ - config.chainId as keyof typeof checkBalanceLowAddress - ], - ...config, - } as unknown as ReadContractConfig) -} - -/** - * Wraps __{@link watchContractEvent}__ with `abi` set to __{@link checkBalanceLowABI}__. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x381a4eFC2A2C914eA1889722bB4B44Fa6BD5b640) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x381a4eFC2A2C914eA1889722bB4B44Fa6BD5b640) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x7Ce13D154FAEE5C8B3E6b19d4Add16f21d884474) - */ -export function watchCheckBalanceLowEvent< - TAbi extends readonly unknown[] = typeof checkBalanceLowABI, - TEventName extends string = string ->( - config: Omit< - WatchContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof checkBalanceLowAddress }, - callback: WatchContractEventCallback -) { - return watchContractEvent( - { - abi: checkBalanceLowABI, - address: - checkBalanceLowAddress[ - config.chainId as keyof typeof checkBalanceLowAddress - ], - ...config, - } as WatchContractEventConfig, - callback - ) -} - -/** - * Wraps __{@link getContract}__ with `abi` set to __{@link checkGelatoLowABI}__. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4f7CFc43f6D262a085F3b946cAC69E7a8E39BBAa) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4f7CFc43f6D262a085F3b946cAC69E7a8E39BBAa) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0xF9c8a4Cb4021f57F9f6d69799cA9BefF64524862) - */ -export function getCheckGelatoLow( - config: Omit & { - chainId?: keyof typeof checkGelatoLowAddress - } -) { - return getContract({ - abi: checkGelatoLowABI, - address: - checkGelatoLowAddress[ - config.chainId as keyof typeof checkGelatoLowAddress - ], - ...config, - }) -} - -/** - * Wraps __{@link readContract}__ with `abi` set to __{@link checkGelatoLowABI}__. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4f7CFc43f6D262a085F3b946cAC69E7a8E39BBAa) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4f7CFc43f6D262a085F3b946cAC69E7a8E39BBAa) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0xF9c8a4Cb4021f57F9f6d69799cA9BefF64524862) - */ -export function readCheckGelatoLow< - TAbi extends readonly unknown[] = typeof checkGelatoLowABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof checkGelatoLowAddress - } -) { - return readContract({ - abi: checkGelatoLowABI, - address: - checkGelatoLowAddress[ - config.chainId as keyof typeof checkGelatoLowAddress - ], - ...config, - } as unknown as ReadContractConfig) -} - -/** - * Wraps __{@link watchContractEvent}__ with `abi` set to __{@link checkGelatoLowABI}__. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4f7CFc43f6D262a085F3b946cAC69E7a8E39BBAa) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4f7CFc43f6D262a085F3b946cAC69E7a8E39BBAa) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0xF9c8a4Cb4021f57F9f6d69799cA9BefF64524862) - */ -export function watchCheckGelatoLowEvent< - TAbi extends readonly unknown[] = typeof checkGelatoLowABI, - TEventName extends string = string ->( - config: Omit< - WatchContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof checkGelatoLowAddress }, - callback: WatchContractEventCallback -) { - return watchContractEvent( - { - abi: checkGelatoLowABI, - address: - checkGelatoLowAddress[ - config.chainId as keyof typeof checkGelatoLowAddress - ], - ...config, - } as WatchContractEventConfig, - callback - ) -} - -/** - * Wraps __{@link getContract}__ with `abi` set to __{@link checkTrueABI}__. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5c741a38cb11424711231777D71689C458eE835D) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5c741a38cb11424711231777D71689C458eE835D) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x47443D0C184e022F19BD1578F5bca6B8a9F58E32) - */ -export function getCheckTrue( - config: Omit & { - chainId?: keyof typeof checkTrueAddress - } -) { - return getContract({ - abi: checkTrueABI, - address: checkTrueAddress[config.chainId as keyof typeof checkTrueAddress], - ...config, - }) -} - -/** - * Wraps __{@link readContract}__ with `abi` set to __{@link checkTrueABI}__. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5c741a38cb11424711231777D71689C458eE835D) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5c741a38cb11424711231777D71689C458eE835D) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x47443D0C184e022F19BD1578F5bca6B8a9F58E32) - */ -export function readCheckTrue< - TAbi extends readonly unknown[] = typeof checkTrueABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof checkTrueAddress - } -) { - return readContract({ - abi: checkTrueABI, - address: checkTrueAddress[config.chainId as keyof typeof checkTrueAddress], - ...config, - } as unknown as ReadContractConfig) -} - -/** - * Wraps __{@link getContract}__ with `abi` set to __{@link drippieABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function getDrippie( - config: Omit & { - chainId?: keyof typeof drippieAddress - } -) { - return getContract({ abi: drippieABI, address: drippieAddress[1], ...config }) -} - -/** - * Wraps __{@link readContract}__ with `abi` set to __{@link drippieABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function readDrippie< - TAbi extends readonly unknown[] = typeof drippieABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof drippieAddress - } -) { - return readContract({ - abi: drippieABI, - address: drippieAddress[1], - ...config, - } as unknown as ReadContractConfig) -} - -/** - * Wraps __{@link writeContract}__ with `abi` set to __{@link drippieABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function writeDrippie< - TFunctionName extends string, - TMode extends WriteContractMode, - TChainId extends number = keyof typeof drippieAddress ->( - config: - | (Omit< - WriteContractPreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof drippieAddress - }) - | (Omit< - WriteContractUnpreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof drippieAddress - }) -) { - return writeContract({ - abi: drippieABI, - address: drippieAddress[1], - ...config, - } as unknown as WriteContractArgs) -} - -/** - * Wraps __{@link prepareWriteContract}__ with `abi` set to __{@link drippieABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function prepareWriteDrippie< - TAbi extends readonly unknown[] = typeof drippieABI, - TFunctionName extends string = string ->( - config: Omit< - PrepareWriteContractConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof drippieAddress } -) { - return prepareWriteContract({ - abi: drippieABI, - address: drippieAddress[1], - ...config, - } as unknown as PrepareWriteContractConfig) -} - -/** - * Wraps __{@link watchContractEvent}__ with `abi` set to __{@link drippieABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function watchDrippieEvent< - TAbi extends readonly unknown[] = typeof drippieABI, - TEventName extends string = string ->( - config: Omit< - WatchContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof drippieAddress }, - callback: WatchContractEventCallback -) { - return watchContractEvent( - { - abi: drippieABI, - address: drippieAddress[1], - ...config, - } as WatchContractEventConfig, - callback - ) -} - -/** - * Wraps __{@link getContract}__ with `abi` set to __{@link drippieGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function getDrippieGoerli( - config: Omit & { - chainId?: keyof typeof drippieGoerliAddress - } -) { - return getContract({ - abi: drippieGoerliABI, - address: drippieGoerliAddress[5], - ...config, - }) -} - -/** - * Wraps __{@link readContract}__ with `abi` set to __{@link drippieGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function readDrippieGoerli< - TAbi extends readonly unknown[] = typeof drippieGoerliABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof drippieGoerliAddress - } -) { - return readContract({ - abi: drippieGoerliABI, - address: drippieGoerliAddress[5], - ...config, - } as unknown as ReadContractConfig) -} - -/** - * Wraps __{@link writeContract}__ with `abi` set to __{@link drippieGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function writeDrippieGoerli< - TFunctionName extends string, - TMode extends WriteContractMode, - TChainId extends number = keyof typeof drippieGoerliAddress ->( - config: - | (Omit< - WriteContractPreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof drippieGoerliAddress - }) - | (Omit< - WriteContractUnpreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof drippieGoerliAddress - }) -) { - return writeContract({ - abi: drippieGoerliABI, - address: drippieGoerliAddress[5], - ...config, - } as unknown as WriteContractArgs) -} - -/** - * Wraps __{@link prepareWriteContract}__ with `abi` set to __{@link drippieGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function prepareWriteDrippieGoerli< - TAbi extends readonly unknown[] = typeof drippieGoerliABI, - TFunctionName extends string = string ->( - config: Omit< - PrepareWriteContractConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof drippieGoerliAddress } -) { - return prepareWriteContract({ - abi: drippieGoerliABI, - address: drippieGoerliAddress[5], - ...config, - } as unknown as PrepareWriteContractConfig) -} - -/** - * Wraps __{@link watchContractEvent}__ with `abi` set to __{@link drippieGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function watchDrippieGoerliEvent< - TAbi extends readonly unknown[] = typeof drippieGoerliABI, - TEventName extends string = string ->( - config: Omit< - WatchContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof drippieGoerliAddress }, - callback: WatchContractEventCallback -) { - return watchContractEvent( - { - abi: drippieGoerliABI, - address: drippieGoerliAddress[5], - ...config, - } as WatchContractEventConfig, - callback - ) -} - -/** - * Wraps __{@link getContract}__ with `abi` set to __{@link drippieOptimismGoerliABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x8D8d533C16D23847EB04EEB0925be8900Dd3af86) - */ -export function getDrippieOptimismGoerli( - config: Omit & { - chainId?: keyof typeof drippieOptimismGoerliAddress - } -) { - return getContract({ - abi: drippieOptimismGoerliABI, - address: drippieOptimismGoerliAddress[420], - ...config, - }) -} - -/** - * Wraps __{@link readContract}__ with `abi` set to __{@link drippieOptimismGoerliABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x8D8d533C16D23847EB04EEB0925be8900Dd3af86) - */ -export function readDrippieOptimismGoerli< - TAbi extends readonly unknown[] = typeof drippieOptimismGoerliABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof drippieOptimismGoerliAddress - } -) { - return readContract({ - abi: drippieOptimismGoerliABI, - address: drippieOptimismGoerliAddress[420], - ...config, - } as unknown as ReadContractConfig) -} - -/** - * Wraps __{@link writeContract}__ with `abi` set to __{@link drippieOptimismGoerliABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x8D8d533C16D23847EB04EEB0925be8900Dd3af86) - */ -export function writeDrippieOptimismGoerli< - TFunctionName extends string, - TMode extends WriteContractMode, - TChainId extends number = keyof typeof drippieOptimismGoerliAddress ->( - config: - | (Omit< - WriteContractPreparedArgs< - typeof drippieOptimismGoerliABI, - TFunctionName - >, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof drippieOptimismGoerliAddress - }) - | (Omit< - WriteContractUnpreparedArgs< - typeof drippieOptimismGoerliABI, - TFunctionName - >, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof drippieOptimismGoerliAddress - }) -) { - return writeContract({ - abi: drippieOptimismGoerliABI, - address: drippieOptimismGoerliAddress[420], - ...config, - } as unknown as WriteContractArgs) -} - -/** - * Wraps __{@link prepareWriteContract}__ with `abi` set to __{@link drippieOptimismGoerliABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x8D8d533C16D23847EB04EEB0925be8900Dd3af86) - */ -export function prepareWriteDrippieOptimismGoerli< - TAbi extends readonly unknown[] = typeof drippieOptimismGoerliABI, - TFunctionName extends string = string ->( - config: Omit< - PrepareWriteContractConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof drippieOptimismGoerliAddress } -) { - return prepareWriteContract({ - abi: drippieOptimismGoerliABI, - address: drippieOptimismGoerliAddress[420], - ...config, - } as unknown as PrepareWriteContractConfig) -} - -/** - * Wraps __{@link watchContractEvent}__ with `abi` set to __{@link drippieOptimismGoerliABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x8D8d533C16D23847EB04EEB0925be8900Dd3af86) - */ -export function watchDrippieOptimismGoerliEvent< - TAbi extends readonly unknown[] = typeof drippieOptimismGoerliABI, - TEventName extends string = string ->( - config: Omit< - WatchContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof drippieOptimismGoerliAddress }, - callback: WatchContractEventCallback -) { - return watchContractEvent( - { - abi: drippieOptimismGoerliABI, - address: drippieOptimismGoerliAddress[420], - ...config, - } as WatchContractEventConfig, - callback - ) -} - -/** - * Wraps __{@link getContract}__ with `abi` set to __{@link easABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function getEas( - config: Omit & { - chainId?: keyof typeof easAddress - } -) { - return getContract({ - abi: easABI, - address: easAddress[config.chainId as keyof typeof easAddress], - ...config, - }) -} - -/** - * Wraps __{@link readContract}__ with `abi` set to __{@link easABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function readEas< - TAbi extends readonly unknown[] = typeof easABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof easAddress - } -) { - return readContract({ - abi: easABI, - address: easAddress[config.chainId as keyof typeof easAddress], - ...config, - } as unknown as ReadContractConfig) -} - -/** - * Wraps __{@link writeContract}__ with `abi` set to __{@link easABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function writeEas< - TFunctionName extends string, - TMode extends WriteContractMode, - TChainId extends number = keyof typeof easAddress ->( - config: - | (Omit< - WriteContractPreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' ? TChainId : keyof typeof easAddress - }) - | (Omit< - WriteContractUnpreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' ? TChainId : keyof typeof easAddress - }) -) { - return writeContract({ - abi: easABI, - address: easAddress[config.chainId as keyof typeof easAddress], - ...config, - } as unknown as WriteContractArgs) -} - -/** - * Wraps __{@link prepareWriteContract}__ with `abi` set to __{@link easABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function prepareWriteEas< - TAbi extends readonly unknown[] = typeof easABI, - TFunctionName extends string = string ->( - config: Omit< - PrepareWriteContractConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof easAddress } -) { - return prepareWriteContract({ - abi: easABI, - address: easAddress[config.chainId as keyof typeof easAddress], - ...config, - } as unknown as PrepareWriteContractConfig) -} - -/** - * Wraps __{@link watchContractEvent}__ with `abi` set to __{@link easABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function watchEasEvent< - TAbi extends readonly unknown[] = typeof easABI, - TEventName extends string = string ->( - config: Omit< - WatchContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof easAddress }, - callback: WatchContractEventCallback -) { - return watchContractEvent( - { - abi: easABI, - address: easAddress[config.chainId as keyof typeof easAddress], - ...config, - } as WatchContractEventConfig, - callback - ) -} - -/** - * Wraps __{@link getContract}__ with `abi` set to __{@link gasPriceOracleABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000000F) - */ -export function getGasPriceOracle( - config: Omit & { - chainId?: keyof typeof gasPriceOracleAddress - } -) { - return getContract({ - abi: gasPriceOracleABI, - address: gasPriceOracleAddress[420], - ...config, - }) -} - -/** - * Wraps __{@link readContract}__ with `abi` set to __{@link gasPriceOracleABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000000F) - */ -export function readGasPriceOracle< - TAbi extends readonly unknown[] = typeof gasPriceOracleABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof gasPriceOracleAddress - } -) { - return readContract({ - abi: gasPriceOracleABI, - address: gasPriceOracleAddress[420], - ...config, - } as unknown as ReadContractConfig) -} - -/** - * Wraps __{@link getContract}__ with `abi` set to __{@link l1BlockABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000015) - */ -export function getL1Block( - config: Omit & { - chainId?: keyof typeof l1BlockAddress - } -) { - return getContract({ - abi: l1BlockABI, - address: l1BlockAddress[420], - ...config, - }) -} - -/** - * Wraps __{@link readContract}__ with `abi` set to __{@link l1BlockABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000015) - */ -export function readL1Block< - TAbi extends readonly unknown[] = typeof l1BlockABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof l1BlockAddress - } -) { - return readContract({ - abi: l1BlockABI, - address: l1BlockAddress[420], - ...config, - } as unknown as ReadContractConfig) -} - -/** - * Wraps __{@link writeContract}__ with `abi` set to __{@link l1BlockABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000015) - */ -export function writeL1Block< - TFunctionName extends string, - TMode extends WriteContractMode, - TChainId extends number = keyof typeof l1BlockAddress ->( - config: - | (Omit< - WriteContractPreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof l1BlockAddress - }) - | (Omit< - WriteContractUnpreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof l1BlockAddress - }) -) { - return writeContract({ - abi: l1BlockABI, - address: l1BlockAddress[420], - ...config, - } as unknown as WriteContractArgs) -} - -/** - * Wraps __{@link prepareWriteContract}__ with `abi` set to __{@link l1BlockABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000015) - */ -export function prepareWriteL1Block< - TAbi extends readonly unknown[] = typeof l1BlockABI, - TFunctionName extends string = string ->( - config: Omit< - PrepareWriteContractConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l1BlockAddress } -) { - return prepareWriteContract({ - abi: l1BlockABI, - address: l1BlockAddress[420], - ...config, - } as unknown as PrepareWriteContractConfig) -} - -/** - * Wraps __{@link getContract}__ with `abi` set to __{@link l1CrossDomainMessengerABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) - */ -export function getL1CrossDomainMessenger( - config: Omit & { - chainId?: keyof typeof l1CrossDomainMessengerAddress - } -) { - return getContract({ - abi: l1CrossDomainMessengerABI, - address: l1CrossDomainMessengerAddress[1], - ...config, - }) -} - -/** - * Wraps __{@link readContract}__ with `abi` set to __{@link l1CrossDomainMessengerABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) - */ -export function readL1CrossDomainMessenger< - TAbi extends readonly unknown[] = typeof l1CrossDomainMessengerABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof l1CrossDomainMessengerAddress - } -) { - return readContract({ - abi: l1CrossDomainMessengerABI, - address: l1CrossDomainMessengerAddress[1], - ...config, - } as unknown as ReadContractConfig) -} - -/** - * Wraps __{@link writeContract}__ with `abi` set to __{@link l1CrossDomainMessengerABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) - */ -export function writeL1CrossDomainMessenger< - TFunctionName extends string, - TMode extends WriteContractMode, - TChainId extends number = keyof typeof l1CrossDomainMessengerAddress ->( - config: - | (Omit< - WriteContractPreparedArgs< - typeof l1CrossDomainMessengerABI, - TFunctionName - >, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof l1CrossDomainMessengerAddress - }) - | (Omit< - WriteContractUnpreparedArgs< - typeof l1CrossDomainMessengerABI, - TFunctionName - >, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof l1CrossDomainMessengerAddress - }) -) { - return writeContract({ - abi: l1CrossDomainMessengerABI, - address: l1CrossDomainMessengerAddress[1], - ...config, - } as unknown as WriteContractArgs) -} - -/** - * Wraps __{@link prepareWriteContract}__ with `abi` set to __{@link l1CrossDomainMessengerABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) - */ -export function prepareWriteL1CrossDomainMessenger< - TAbi extends readonly unknown[] = typeof l1CrossDomainMessengerABI, - TFunctionName extends string = string ->( - config: Omit< - PrepareWriteContractConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l1CrossDomainMessengerAddress } -) { - return prepareWriteContract({ - abi: l1CrossDomainMessengerABI, - address: l1CrossDomainMessengerAddress[1], - ...config, - } as unknown as PrepareWriteContractConfig) -} - -/** - * Wraps __{@link watchContractEvent}__ with `abi` set to __{@link l1CrossDomainMessengerABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) - */ -export function watchL1CrossDomainMessengerEvent< - TAbi extends readonly unknown[] = typeof l1CrossDomainMessengerABI, - TEventName extends string = string ->( - config: Omit< - WatchContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l1CrossDomainMessengerAddress }, - callback: WatchContractEventCallback -) { - return watchContractEvent( - { - abi: l1CrossDomainMessengerABI, - address: l1CrossDomainMessengerAddress[1], - ...config, - } as WatchContractEventConfig, - callback - ) -} - -/** - * Wraps __{@link getContract}__ with `abi` set to __{@link l1CrossDomainMessengerGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) - */ -export function getL1CrossDomainMessengerGoerli( - config: Omit & { - chainId?: keyof typeof l1CrossDomainMessengerGoerliAddress - } -) { - return getContract({ - abi: l1CrossDomainMessengerGoerliABI, - address: l1CrossDomainMessengerGoerliAddress[5], - ...config, - }) -} - -/** - * Wraps __{@link readContract}__ with `abi` set to __{@link l1CrossDomainMessengerGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) - */ -export function readL1CrossDomainMessengerGoerli< - TAbi extends readonly unknown[] = typeof l1CrossDomainMessengerGoerliABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof l1CrossDomainMessengerGoerliAddress - } -) { - return readContract({ - abi: l1CrossDomainMessengerGoerliABI, - address: l1CrossDomainMessengerGoerliAddress[5], - ...config, - } as unknown as ReadContractConfig) -} - -/** - * Wraps __{@link writeContract}__ with `abi` set to __{@link l1CrossDomainMessengerGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) - */ -export function writeL1CrossDomainMessengerGoerli< - TFunctionName extends string, - TMode extends WriteContractMode, - TChainId extends number = keyof typeof l1CrossDomainMessengerGoerliAddress ->( - config: - | (Omit< - WriteContractPreparedArgs< - typeof l1CrossDomainMessengerGoerliABI, - TFunctionName - >, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof l1CrossDomainMessengerGoerliAddress - }) - | (Omit< - WriteContractUnpreparedArgs< - typeof l1CrossDomainMessengerGoerliABI, - TFunctionName - >, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof l1CrossDomainMessengerGoerliAddress - }) -) { - return writeContract({ - abi: l1CrossDomainMessengerGoerliABI, - address: l1CrossDomainMessengerGoerliAddress[5], - ...config, - } as unknown as WriteContractArgs) -} - -/** - * Wraps __{@link prepareWriteContract}__ with `abi` set to __{@link l1CrossDomainMessengerGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) - */ -export function prepareWriteL1CrossDomainMessengerGoerli< - TAbi extends readonly unknown[] = typeof l1CrossDomainMessengerGoerliABI, - TFunctionName extends string = string ->( - config: Omit< - PrepareWriteContractConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l1CrossDomainMessengerGoerliAddress } -) { - return prepareWriteContract({ - abi: l1CrossDomainMessengerGoerliABI, - address: l1CrossDomainMessengerGoerliAddress[5], - ...config, - } as unknown as PrepareWriteContractConfig) -} - -/** - * Wraps __{@link watchContractEvent}__ with `abi` set to __{@link l1CrossDomainMessengerGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) - */ -export function watchL1CrossDomainMessengerGoerliEvent< - TAbi extends readonly unknown[] = typeof l1CrossDomainMessengerGoerliABI, - TEventName extends string = string ->( - config: Omit< - WatchContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l1CrossDomainMessengerGoerliAddress }, - callback: WatchContractEventCallback -) { - return watchContractEvent( - { - abi: l1CrossDomainMessengerGoerliABI, - address: l1CrossDomainMessengerGoerliAddress[5], - ...config, - } as WatchContractEventConfig, - callback - ) -} - -/** - * Wraps __{@link getContract}__ with `abi` set to __{@link l1Erc721BridgeABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5a7749f83b81B301cAb5f48EB8516B986DAef23D) - */ -export function getL1Erc721Bridge( - config: Omit & { - chainId?: keyof typeof l1Erc721BridgeAddress - } -) { - return getContract({ - abi: l1Erc721BridgeABI, - address: l1Erc721BridgeAddress[1], - ...config, - }) -} - -/** - * Wraps __{@link readContract}__ with `abi` set to __{@link l1Erc721BridgeABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5a7749f83b81B301cAb5f48EB8516B986DAef23D) - */ -export function readL1Erc721Bridge< - TAbi extends readonly unknown[] = typeof l1Erc721BridgeABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof l1Erc721BridgeAddress - } -) { - return readContract({ - abi: l1Erc721BridgeABI, - address: l1Erc721BridgeAddress[1], - ...config, - } as unknown as ReadContractConfig) -} - -/** - * Wraps __{@link writeContract}__ with `abi` set to __{@link l1Erc721BridgeABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5a7749f83b81B301cAb5f48EB8516B986DAef23D) - */ -export function writeL1Erc721Bridge< - TFunctionName extends string, - TMode extends WriteContractMode, - TChainId extends number = keyof typeof l1Erc721BridgeAddress ->( - config: - | (Omit< - WriteContractPreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof l1Erc721BridgeAddress - }) - | (Omit< - WriteContractUnpreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof l1Erc721BridgeAddress - }) -) { - return writeContract({ - abi: l1Erc721BridgeABI, - address: l1Erc721BridgeAddress[1], - ...config, - } as unknown as WriteContractArgs) -} - -/** - * Wraps __{@link prepareWriteContract}__ with `abi` set to __{@link l1Erc721BridgeABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5a7749f83b81B301cAb5f48EB8516B986DAef23D) - */ -export function prepareWriteL1Erc721Bridge< - TAbi extends readonly unknown[] = typeof l1Erc721BridgeABI, - TFunctionName extends string = string ->( - config: Omit< - PrepareWriteContractConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l1Erc721BridgeAddress } -) { - return prepareWriteContract({ - abi: l1Erc721BridgeABI, - address: l1Erc721BridgeAddress[1], - ...config, - } as unknown as PrepareWriteContractConfig) -} - -/** - * Wraps __{@link watchContractEvent}__ with `abi` set to __{@link l1Erc721BridgeABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5a7749f83b81B301cAb5f48EB8516B986DAef23D) - */ -export function watchL1Erc721BridgeEvent< - TAbi extends readonly unknown[] = typeof l1Erc721BridgeABI, - TEventName extends string = string ->( - config: Omit< - WatchContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l1Erc721BridgeAddress }, - callback: WatchContractEventCallback -) { - return watchContractEvent( - { - abi: l1Erc721BridgeABI, - address: l1Erc721BridgeAddress[1], - ...config, - } as WatchContractEventConfig, - callback - ) -} - -/** - * Wraps __{@link getContract}__ with `abi` set to __{@link l1Erc721BridgeGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9) - */ -export function getL1Erc721BridgeGoerli( - config: Omit & { - chainId?: keyof typeof l1Erc721BridgeGoerliAddress - } -) { - return getContract({ - abi: l1Erc721BridgeGoerliABI, - address: l1Erc721BridgeGoerliAddress[5], - ...config, - }) -} - -/** - * Wraps __{@link readContract}__ with `abi` set to __{@link l1Erc721BridgeGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9) - */ -export function readL1Erc721BridgeGoerli< - TAbi extends readonly unknown[] = typeof l1Erc721BridgeGoerliABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof l1Erc721BridgeGoerliAddress - } -) { - return readContract({ - abi: l1Erc721BridgeGoerliABI, - address: l1Erc721BridgeGoerliAddress[5], - ...config, - } as unknown as ReadContractConfig) -} - -/** - * Wraps __{@link writeContract}__ with `abi` set to __{@link l1Erc721BridgeGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9) - */ -export function writeL1Erc721BridgeGoerli< - TFunctionName extends string, - TMode extends WriteContractMode, - TChainId extends number = keyof typeof l1Erc721BridgeGoerliAddress ->( - config: - | (Omit< - WriteContractPreparedArgs< - typeof l1Erc721BridgeGoerliABI, - TFunctionName - >, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof l1Erc721BridgeGoerliAddress - }) - | (Omit< - WriteContractUnpreparedArgs< - typeof l1Erc721BridgeGoerliABI, - TFunctionName - >, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof l1Erc721BridgeGoerliAddress - }) -) { - return writeContract({ - abi: l1Erc721BridgeGoerliABI, - address: l1Erc721BridgeGoerliAddress[5], - ...config, - } as unknown as WriteContractArgs) -} - -/** - * Wraps __{@link prepareWriteContract}__ with `abi` set to __{@link l1Erc721BridgeGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9) - */ -export function prepareWriteL1Erc721BridgeGoerli< - TAbi extends readonly unknown[] = typeof l1Erc721BridgeGoerliABI, - TFunctionName extends string = string ->( - config: Omit< - PrepareWriteContractConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l1Erc721BridgeGoerliAddress } -) { - return prepareWriteContract({ - abi: l1Erc721BridgeGoerliABI, - address: l1Erc721BridgeGoerliAddress[5], - ...config, - } as unknown as PrepareWriteContractConfig) -} - -/** - * Wraps __{@link watchContractEvent}__ with `abi` set to __{@link l1Erc721BridgeGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9) - */ -export function watchL1Erc721BridgeGoerliEvent< - TAbi extends readonly unknown[] = typeof l1Erc721BridgeGoerliABI, - TEventName extends string = string ->( - config: Omit< - WatchContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l1Erc721BridgeGoerliAddress }, - callback: WatchContractEventCallback -) { - return watchContractEvent( - { - abi: l1Erc721BridgeGoerliABI, - address: l1Erc721BridgeGoerliAddress[5], - ...config, - } as WatchContractEventConfig, - callback - ) -} - -/** - * Wraps __{@link getContract}__ with `abi` set to __{@link l1FeeVaultABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000001a) - */ -export function getL1FeeVault( - config: Omit & { - chainId?: keyof typeof l1FeeVaultAddress - } -) { - return getContract({ - abi: l1FeeVaultABI, - address: l1FeeVaultAddress[420], - ...config, - }) -} - -/** - * Wraps __{@link readContract}__ with `abi` set to __{@link l1FeeVaultABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000001a) - */ -export function readL1FeeVault< - TAbi extends readonly unknown[] = typeof l1FeeVaultABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof l1FeeVaultAddress - } -) { - return readContract({ - abi: l1FeeVaultABI, - address: l1FeeVaultAddress[420], - ...config, - } as unknown as ReadContractConfig) -} - -/** - * Wraps __{@link writeContract}__ with `abi` set to __{@link l1FeeVaultABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000001a) - */ -export function writeL1FeeVault< - TFunctionName extends string, - TMode extends WriteContractMode, - TChainId extends number = keyof typeof l1FeeVaultAddress ->( - config: - | (Omit< - WriteContractPreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof l1FeeVaultAddress - }) - | (Omit< - WriteContractUnpreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof l1FeeVaultAddress - }) -) { - return writeContract({ - abi: l1FeeVaultABI, - address: l1FeeVaultAddress[420], - ...config, - } as unknown as WriteContractArgs) -} - -/** - * Wraps __{@link prepareWriteContract}__ with `abi` set to __{@link l1FeeVaultABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000001a) - */ -export function prepareWriteL1FeeVault< - TAbi extends readonly unknown[] = typeof l1FeeVaultABI, - TFunctionName extends string = string ->( - config: Omit< - PrepareWriteContractConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l1FeeVaultAddress } -) { - return prepareWriteContract({ - abi: l1FeeVaultABI, - address: l1FeeVaultAddress[420], - ...config, - } as unknown as PrepareWriteContractConfig) -} - -/** - * Wraps __{@link watchContractEvent}__ with `abi` set to __{@link l1FeeVaultABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000001a) - */ -export function watchL1FeeVaultEvent< - TAbi extends readonly unknown[] = typeof l1FeeVaultABI, - TEventName extends string = string ->( - config: Omit< - WatchContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l1FeeVaultAddress }, - callback: WatchContractEventCallback -) { - return watchContractEvent( - { - abi: l1FeeVaultABI, - address: l1FeeVaultAddress[420], - ...config, - } as WatchContractEventConfig, - callback - ) -} - -/** - * Wraps __{@link getContract}__ with `abi` set to __{@link l1StandardBridgeABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) - */ -export function getL1StandardBridge( - config: Omit & { - chainId?: keyof typeof l1StandardBridgeAddress - } -) { - return getContract({ - abi: l1StandardBridgeABI, - address: l1StandardBridgeAddress[1], - ...config, - }) -} - -/** - * Wraps __{@link readContract}__ with `abi` set to __{@link l1StandardBridgeABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) - */ -export function readL1StandardBridge< - TAbi extends readonly unknown[] = typeof l1StandardBridgeABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof l1StandardBridgeAddress - } -) { - return readContract({ - abi: l1StandardBridgeABI, - address: l1StandardBridgeAddress[1], - ...config, - } as unknown as ReadContractConfig) -} - -/** - * Wraps __{@link writeContract}__ with `abi` set to __{@link l1StandardBridgeABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) - */ -export function writeL1StandardBridge< - TFunctionName extends string, - TMode extends WriteContractMode, - TChainId extends number = keyof typeof l1StandardBridgeAddress ->( - config: - | (Omit< - WriteContractPreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof l1StandardBridgeAddress - }) - | (Omit< - WriteContractUnpreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof l1StandardBridgeAddress - }) -) { - return writeContract({ - abi: l1StandardBridgeABI, - address: l1StandardBridgeAddress[1], - ...config, - } as unknown as WriteContractArgs) -} - -/** - * Wraps __{@link prepareWriteContract}__ with `abi` set to __{@link l1StandardBridgeABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) - */ -export function prepareWriteL1StandardBridge< - TAbi extends readonly unknown[] = typeof l1StandardBridgeABI, - TFunctionName extends string = string ->( - config: Omit< - PrepareWriteContractConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l1StandardBridgeAddress } -) { - return prepareWriteContract({ - abi: l1StandardBridgeABI, - address: l1StandardBridgeAddress[1], - ...config, - } as unknown as PrepareWriteContractConfig) -} - -/** - * Wraps __{@link watchContractEvent}__ with `abi` set to __{@link l1StandardBridgeABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) - */ -export function watchL1StandardBridgeEvent< - TAbi extends readonly unknown[] = typeof l1StandardBridgeABI, - TEventName extends string = string ->( - config: Omit< - WatchContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l1StandardBridgeAddress }, - callback: WatchContractEventCallback -) { - return watchContractEvent( - { - abi: l1StandardBridgeABI, - address: l1StandardBridgeAddress[1], - ...config, - } as WatchContractEventConfig, - callback - ) -} - -/** - * Wraps __{@link getContract}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function getL1StandardBridgeGoerli( - config: Omit & { - chainId?: keyof typeof l1StandardBridgeGoerliAddress - } -) { - return getContract({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - ...config, - }) -} - -/** - * Wraps __{@link readContract}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function readL1StandardBridgeGoerli< - TAbi extends readonly unknown[] = typeof l1StandardBridgeGoerliABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof l1StandardBridgeGoerliAddress - } -) { - return readContract({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - ...config, - } as unknown as ReadContractConfig) -} - -/** - * Wraps __{@link writeContract}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function writeL1StandardBridgeGoerli< - TFunctionName extends string, - TMode extends WriteContractMode, - TChainId extends number = keyof typeof l1StandardBridgeGoerliAddress ->( - config: - | (Omit< - WriteContractPreparedArgs< - typeof l1StandardBridgeGoerliABI, - TFunctionName - >, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof l1StandardBridgeGoerliAddress - }) - | (Omit< - WriteContractUnpreparedArgs< - typeof l1StandardBridgeGoerliABI, - TFunctionName - >, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof l1StandardBridgeGoerliAddress - }) -) { - return writeContract({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - ...config, - } as unknown as WriteContractArgs) -} - -/** - * Wraps __{@link prepareWriteContract}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function prepareWriteL1StandardBridgeGoerli< - TAbi extends readonly unknown[] = typeof l1StandardBridgeGoerliABI, - TFunctionName extends string = string ->( - config: Omit< - PrepareWriteContractConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l1StandardBridgeGoerliAddress } -) { - return prepareWriteContract({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - ...config, - } as unknown as PrepareWriteContractConfig) -} - -/** - * Wraps __{@link watchContractEvent}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function watchL1StandardBridgeGoerliEvent< - TAbi extends readonly unknown[] = typeof l1StandardBridgeGoerliABI, - TEventName extends string = string ->( - config: Omit< - WatchContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l1StandardBridgeGoerliAddress }, - callback: WatchContractEventCallback -) { - return watchContractEvent( - { - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - ...config, - } as WatchContractEventConfig, - callback - ) -} - -/** - * Wraps __{@link getContract}__ with `abi` set to __{@link l2CrossDomainMessengerABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) - */ -export function getL2CrossDomainMessenger( - config: Omit & { - chainId?: keyof typeof l2CrossDomainMessengerAddress - } -) { - return getContract({ - abi: l2CrossDomainMessengerABI, - address: l2CrossDomainMessengerAddress[420], - ...config, - }) -} - -/** - * Wraps __{@link readContract}__ with `abi` set to __{@link l2CrossDomainMessengerABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) - */ -export function readL2CrossDomainMessenger< - TAbi extends readonly unknown[] = typeof l2CrossDomainMessengerABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof l2CrossDomainMessengerAddress - } -) { - return readContract({ - abi: l2CrossDomainMessengerABI, - address: l2CrossDomainMessengerAddress[420], - ...config, - } as unknown as ReadContractConfig) -} - -/** - * Wraps __{@link writeContract}__ with `abi` set to __{@link l2CrossDomainMessengerABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) - */ -export function writeL2CrossDomainMessenger< - TFunctionName extends string, - TMode extends WriteContractMode, - TChainId extends number = keyof typeof l2CrossDomainMessengerAddress ->( - config: - | (Omit< - WriteContractPreparedArgs< - typeof l2CrossDomainMessengerABI, - TFunctionName - >, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof l2CrossDomainMessengerAddress - }) - | (Omit< - WriteContractUnpreparedArgs< - typeof l2CrossDomainMessengerABI, - TFunctionName - >, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof l2CrossDomainMessengerAddress - }) -) { - return writeContract({ - abi: l2CrossDomainMessengerABI, - address: l2CrossDomainMessengerAddress[420], - ...config, - } as unknown as WriteContractArgs) -} - -/** - * Wraps __{@link prepareWriteContract}__ with `abi` set to __{@link l2CrossDomainMessengerABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) - */ -export function prepareWriteL2CrossDomainMessenger< - TAbi extends readonly unknown[] = typeof l2CrossDomainMessengerABI, - TFunctionName extends string = string ->( - config: Omit< - PrepareWriteContractConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l2CrossDomainMessengerAddress } -) { - return prepareWriteContract({ - abi: l2CrossDomainMessengerABI, - address: l2CrossDomainMessengerAddress[420], - ...config, - } as unknown as PrepareWriteContractConfig) -} - -/** - * Wraps __{@link watchContractEvent}__ with `abi` set to __{@link l2CrossDomainMessengerABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) - */ -export function watchL2CrossDomainMessengerEvent< - TAbi extends readonly unknown[] = typeof l2CrossDomainMessengerABI, - TEventName extends string = string ->( - config: Omit< - WatchContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l2CrossDomainMessengerAddress }, - callback: WatchContractEventCallback -) { - return watchContractEvent( - { - abi: l2CrossDomainMessengerABI, - address: l2CrossDomainMessengerAddress[420], - ...config, - } as WatchContractEventConfig, - callback - ) -} - -/** - * Wraps __{@link getContract}__ with `abi` set to __{@link l2Erc721BridgeABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000014) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000014) - */ -export function getL2Erc721Bridge( - config: Omit & { - chainId?: keyof typeof l2Erc721BridgeAddress - } -) { - return getContract({ - abi: l2Erc721BridgeABI, - address: - l2Erc721BridgeAddress[ - config.chainId as keyof typeof l2Erc721BridgeAddress - ], - ...config, - }) -} - -/** - * Wraps __{@link readContract}__ with `abi` set to __{@link l2Erc721BridgeABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000014) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000014) - */ -export function readL2Erc721Bridge< - TAbi extends readonly unknown[] = typeof l2Erc721BridgeABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof l2Erc721BridgeAddress - } -) { - return readContract({ - abi: l2Erc721BridgeABI, - address: - l2Erc721BridgeAddress[ - config.chainId as keyof typeof l2Erc721BridgeAddress - ], - ...config, - } as unknown as ReadContractConfig) -} - -/** - * Wraps __{@link writeContract}__ with `abi` set to __{@link l2Erc721BridgeABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000014) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000014) - */ -export function writeL2Erc721Bridge< - TFunctionName extends string, - TMode extends WriteContractMode, - TChainId extends number = keyof typeof l2Erc721BridgeAddress ->( - config: - | (Omit< - WriteContractPreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof l2Erc721BridgeAddress - }) - | (Omit< - WriteContractUnpreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof l2Erc721BridgeAddress - }) -) { - return writeContract({ - abi: l2Erc721BridgeABI, - address: - l2Erc721BridgeAddress[ - config.chainId as keyof typeof l2Erc721BridgeAddress - ], - ...config, - } as unknown as WriteContractArgs) -} - -/** - * Wraps __{@link prepareWriteContract}__ with `abi` set to __{@link l2Erc721BridgeABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000014) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000014) - */ -export function prepareWriteL2Erc721Bridge< - TAbi extends readonly unknown[] = typeof l2Erc721BridgeABI, - TFunctionName extends string = string ->( - config: Omit< - PrepareWriteContractConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l2Erc721BridgeAddress } -) { - return prepareWriteContract({ - abi: l2Erc721BridgeABI, - address: - l2Erc721BridgeAddress[ - config.chainId as keyof typeof l2Erc721BridgeAddress - ], - ...config, - } as unknown as PrepareWriteContractConfig) -} - -/** - * Wraps __{@link watchContractEvent}__ with `abi` set to __{@link l2Erc721BridgeABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000014) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000014) - */ -export function watchL2Erc721BridgeEvent< - TAbi extends readonly unknown[] = typeof l2Erc721BridgeABI, - TEventName extends string = string ->( - config: Omit< - WatchContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l2Erc721BridgeAddress }, - callback: WatchContractEventCallback -) { - return watchContractEvent( - { - abi: l2Erc721BridgeABI, - address: - l2Erc721BridgeAddress[ - config.chainId as keyof typeof l2Erc721BridgeAddress - ], - ...config, - } as WatchContractEventConfig, - callback - ) -} - -/** - * Wraps __{@link getContract}__ with `abi` set to __{@link l2OutputOracleABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) - */ -export function getL2OutputOracle( - config: Omit & { - chainId?: keyof typeof l2OutputOracleAddress - } -) { - return getContract({ - abi: l2OutputOracleABI, - address: l2OutputOracleAddress[1], - ...config, - }) -} - -/** - * Wraps __{@link readContract}__ with `abi` set to __{@link l2OutputOracleABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) - */ -export function readL2OutputOracle< - TAbi extends readonly unknown[] = typeof l2OutputOracleABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof l2OutputOracleAddress - } -) { - return readContract({ - abi: l2OutputOracleABI, - address: l2OutputOracleAddress[1], - ...config, - } as unknown as ReadContractConfig) -} - -/** - * Wraps __{@link writeContract}__ with `abi` set to __{@link l2OutputOracleABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) - */ -export function writeL2OutputOracle< - TFunctionName extends string, - TMode extends WriteContractMode, - TChainId extends number = keyof typeof l2OutputOracleAddress ->( - config: - | (Omit< - WriteContractPreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof l2OutputOracleAddress - }) - | (Omit< - WriteContractUnpreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof l2OutputOracleAddress - }) -) { - return writeContract({ - abi: l2OutputOracleABI, - address: l2OutputOracleAddress[1], - ...config, - } as unknown as WriteContractArgs) -} - -/** - * Wraps __{@link prepareWriteContract}__ with `abi` set to __{@link l2OutputOracleABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) - */ -export function prepareWriteL2OutputOracle< - TAbi extends readonly unknown[] = typeof l2OutputOracleABI, - TFunctionName extends string = string ->( - config: Omit< - PrepareWriteContractConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l2OutputOracleAddress } -) { - return prepareWriteContract({ - abi: l2OutputOracleABI, - address: l2OutputOracleAddress[1], - ...config, - } as unknown as PrepareWriteContractConfig) -} - -/** - * Wraps __{@link watchContractEvent}__ with `abi` set to __{@link l2OutputOracleABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) - */ -export function watchL2OutputOracleEvent< - TAbi extends readonly unknown[] = typeof l2OutputOracleABI, - TEventName extends string = string ->( - config: Omit< - WatchContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l2OutputOracleAddress }, - callback: WatchContractEventCallback -) { - return watchContractEvent( - { - abi: l2OutputOracleABI, - address: l2OutputOracleAddress[1], - ...config, - } as WatchContractEventConfig, - callback - ) -} - -/** - * Wraps __{@link getContract}__ with `abi` set to __{@link l2OutputOracleGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) - */ -export function getL2OutputOracleGoerli( - config: Omit & { - chainId?: keyof typeof l2OutputOracleGoerliAddress - } -) { - return getContract({ - abi: l2OutputOracleGoerliABI, - address: l2OutputOracleGoerliAddress[5], - ...config, - }) -} - -/** - * Wraps __{@link readContract}__ with `abi` set to __{@link l2OutputOracleGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) - */ -export function readL2OutputOracleGoerli< - TAbi extends readonly unknown[] = typeof l2OutputOracleGoerliABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof l2OutputOracleGoerliAddress - } -) { - return readContract({ - abi: l2OutputOracleGoerliABI, - address: l2OutputOracleGoerliAddress[5], - ...config, - } as unknown as ReadContractConfig) -} - -/** - * Wraps __{@link writeContract}__ with `abi` set to __{@link l2OutputOracleGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) - */ -export function writeL2OutputOracleGoerli< - TFunctionName extends string, - TMode extends WriteContractMode, - TChainId extends number = keyof typeof l2OutputOracleGoerliAddress ->( - config: - | (Omit< - WriteContractPreparedArgs< - typeof l2OutputOracleGoerliABI, - TFunctionName - >, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof l2OutputOracleGoerliAddress - }) - | (Omit< - WriteContractUnpreparedArgs< - typeof l2OutputOracleGoerliABI, - TFunctionName - >, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof l2OutputOracleGoerliAddress - }) -) { - return writeContract({ - abi: l2OutputOracleGoerliABI, - address: l2OutputOracleGoerliAddress[5], - ...config, - } as unknown as WriteContractArgs) -} - -/** - * Wraps __{@link prepareWriteContract}__ with `abi` set to __{@link l2OutputOracleGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) - */ -export function prepareWriteL2OutputOracleGoerli< - TAbi extends readonly unknown[] = typeof l2OutputOracleGoerliABI, - TFunctionName extends string = string ->( - config: Omit< - PrepareWriteContractConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l2OutputOracleGoerliAddress } -) { - return prepareWriteContract({ - abi: l2OutputOracleGoerliABI, - address: l2OutputOracleGoerliAddress[5], - ...config, - } as unknown as PrepareWriteContractConfig) -} - -/** - * Wraps __{@link watchContractEvent}__ with `abi` set to __{@link l2OutputOracleGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) - */ -export function watchL2OutputOracleGoerliEvent< - TAbi extends readonly unknown[] = typeof l2OutputOracleGoerliABI, - TEventName extends string = string ->( - config: Omit< - WatchContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l2OutputOracleGoerliAddress }, - callback: WatchContractEventCallback -) { - return watchContractEvent( - { - abi: l2OutputOracleGoerliABI, - address: l2OutputOracleGoerliAddress[5], - ...config, - } as WatchContractEventConfig, - callback - ) -} - -/** - * Wraps __{@link getContract}__ with `abi` set to __{@link l2StandardBridgeABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) - */ -export function getL2StandardBridge( - config: Omit & { - chainId?: keyof typeof l2StandardBridgeAddress - } -) { - return getContract({ - abi: l2StandardBridgeABI, - address: l2StandardBridgeAddress[420], - ...config, - }) -} - -/** - * Wraps __{@link readContract}__ with `abi` set to __{@link l2StandardBridgeABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) - */ -export function readL2StandardBridge< - TAbi extends readonly unknown[] = typeof l2StandardBridgeABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof l2StandardBridgeAddress - } -) { - return readContract({ - abi: l2StandardBridgeABI, - address: l2StandardBridgeAddress[420], - ...config, - } as unknown as ReadContractConfig) -} - -/** - * Wraps __{@link writeContract}__ with `abi` set to __{@link l2StandardBridgeABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) - */ -export function writeL2StandardBridge< - TFunctionName extends string, - TMode extends WriteContractMode, - TChainId extends number = keyof typeof l2StandardBridgeAddress ->( - config: - | (Omit< - WriteContractPreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof l2StandardBridgeAddress - }) - | (Omit< - WriteContractUnpreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof l2StandardBridgeAddress - }) -) { - return writeContract({ - abi: l2StandardBridgeABI, - address: l2StandardBridgeAddress[420], - ...config, - } as unknown as WriteContractArgs) -} - -/** - * Wraps __{@link prepareWriteContract}__ with `abi` set to __{@link l2StandardBridgeABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) - */ -export function prepareWriteL2StandardBridge< - TAbi extends readonly unknown[] = typeof l2StandardBridgeABI, - TFunctionName extends string = string ->( - config: Omit< - PrepareWriteContractConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l2StandardBridgeAddress } -) { - return prepareWriteContract({ - abi: l2StandardBridgeABI, - address: l2StandardBridgeAddress[420], - ...config, - } as unknown as PrepareWriteContractConfig) -} - -/** - * Wraps __{@link watchContractEvent}__ with `abi` set to __{@link l2StandardBridgeABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) - */ -export function watchL2StandardBridgeEvent< - TAbi extends readonly unknown[] = typeof l2StandardBridgeABI, - TEventName extends string = string ->( - config: Omit< - WatchContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l2StandardBridgeAddress }, - callback: WatchContractEventCallback -) { - return watchContractEvent( - { - abi: l2StandardBridgeABI, - address: l2StandardBridgeAddress[420], - ...config, - } as WatchContractEventConfig, - callback - ) -} - -/** - * Wraps __{@link getContract}__ with `abi` set to __{@link l2ToL1MessagePasserABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000016) - */ -export function getL2ToL1MessagePasser( - config: Omit & { - chainId?: keyof typeof l2ToL1MessagePasserAddress - } -) { - return getContract({ - abi: l2ToL1MessagePasserABI, - address: l2ToL1MessagePasserAddress[420], - ...config, - }) -} - -/** - * Wraps __{@link readContract}__ with `abi` set to __{@link l2ToL1MessagePasserABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000016) - */ -export function readL2ToL1MessagePasser< - TAbi extends readonly unknown[] = typeof l2ToL1MessagePasserABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof l2ToL1MessagePasserAddress - } -) { - return readContract({ - abi: l2ToL1MessagePasserABI, - address: l2ToL1MessagePasserAddress[420], - ...config, - } as unknown as ReadContractConfig) -} - -/** - * Wraps __{@link writeContract}__ with `abi` set to __{@link l2ToL1MessagePasserABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000016) - */ -export function writeL2ToL1MessagePasser< - TFunctionName extends string, - TMode extends WriteContractMode, - TChainId extends number = keyof typeof l2ToL1MessagePasserAddress ->( - config: - | (Omit< - WriteContractPreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof l2ToL1MessagePasserAddress - }) - | (Omit< - WriteContractUnpreparedArgs< - typeof l2ToL1MessagePasserABI, - TFunctionName - >, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof l2ToL1MessagePasserAddress - }) -) { - return writeContract({ - abi: l2ToL1MessagePasserABI, - address: l2ToL1MessagePasserAddress[420], - ...config, - } as unknown as WriteContractArgs) -} - -/** - * Wraps __{@link prepareWriteContract}__ with `abi` set to __{@link l2ToL1MessagePasserABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000016) - */ -export function prepareWriteL2ToL1MessagePasser< - TAbi extends readonly unknown[] = typeof l2ToL1MessagePasserABI, - TFunctionName extends string = string ->( - config: Omit< - PrepareWriteContractConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l2ToL1MessagePasserAddress } -) { - return prepareWriteContract({ - abi: l2ToL1MessagePasserABI, - address: l2ToL1MessagePasserAddress[420], - ...config, - } as unknown as PrepareWriteContractConfig) -} - -/** - * Wraps __{@link watchContractEvent}__ with `abi` set to __{@link l2ToL1MessagePasserABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000016) - */ -export function watchL2ToL1MessagePasserEvent< - TAbi extends readonly unknown[] = typeof l2ToL1MessagePasserABI, - TEventName extends string = string ->( - config: Omit< - WatchContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l2ToL1MessagePasserAddress }, - callback: WatchContractEventCallback -) { - return watchContractEvent( - { - abi: l2ToL1MessagePasserABI, - address: l2ToL1MessagePasserAddress[420], - ...config, - } as WatchContractEventConfig, - callback - ) -} - -/** - * Wraps __{@link getContract}__ with `abi` set to __{@link mintManagerABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x5C4e7Ba1E219E47948e6e3F55019A647bA501005) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76) - */ -export function getMintManager( - config: Omit & { - chainId?: keyof typeof mintManagerAddress - } -) { - return getContract({ - abi: mintManagerABI, - address: - mintManagerAddress[config.chainId as keyof typeof mintManagerAddress], - ...config, - }) -} - -/** - * Wraps __{@link readContract}__ with `abi` set to __{@link mintManagerABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x5C4e7Ba1E219E47948e6e3F55019A647bA501005) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76) - */ -export function readMintManager< - TAbi extends readonly unknown[] = typeof mintManagerABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof mintManagerAddress - } -) { - return readContract({ - abi: mintManagerABI, - address: - mintManagerAddress[config.chainId as keyof typeof mintManagerAddress], - ...config, - } as unknown as ReadContractConfig) -} - -/** - * Wraps __{@link writeContract}__ with `abi` set to __{@link mintManagerABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x5C4e7Ba1E219E47948e6e3F55019A647bA501005) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76) - */ -export function writeMintManager< - TFunctionName extends string, - TMode extends WriteContractMode, - TChainId extends number = keyof typeof mintManagerAddress ->( - config: - | (Omit< - WriteContractPreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof mintManagerAddress - }) - | (Omit< - WriteContractUnpreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof mintManagerAddress - }) -) { - return writeContract({ - abi: mintManagerABI, - address: - mintManagerAddress[config.chainId as keyof typeof mintManagerAddress], - ...config, - } as unknown as WriteContractArgs) -} - -/** - * Wraps __{@link prepareWriteContract}__ with `abi` set to __{@link mintManagerABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x5C4e7Ba1E219E47948e6e3F55019A647bA501005) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76) - */ -export function prepareWriteMintManager< - TAbi extends readonly unknown[] = typeof mintManagerABI, - TFunctionName extends string = string ->( - config: Omit< - PrepareWriteContractConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof mintManagerAddress } -) { - return prepareWriteContract({ - abi: mintManagerABI, - address: - mintManagerAddress[config.chainId as keyof typeof mintManagerAddress], - ...config, - } as unknown as PrepareWriteContractConfig) -} - -/** - * Wraps __{@link watchContractEvent}__ with `abi` set to __{@link mintManagerABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x5C4e7Ba1E219E47948e6e3F55019A647bA501005) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76) - */ -export function watchMintManagerEvent< - TAbi extends readonly unknown[] = typeof mintManagerABI, - TEventName extends string = string ->( - config: Omit< - WatchContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof mintManagerAddress }, - callback: WatchContractEventCallback -) { - return watchContractEvent( - { - abi: mintManagerABI, - address: - mintManagerAddress[config.chainId as keyof typeof mintManagerAddress], - ...config, - } as WatchContractEventConfig, - callback - ) -} - -/** - * Wraps __{@link getContract}__ with `abi` set to __{@link optimismMintableErc20FactoryABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function getOptimismMintableErc20Factory( - config: Omit & { - chainId?: keyof typeof optimismMintableErc20FactoryAddress - } -) { - return getContract({ - abi: optimismMintableErc20FactoryABI, - address: optimismMintableErc20FactoryAddress[1], - ...config, - }) -} - -/** - * Wraps __{@link readContract}__ with `abi` set to __{@link optimismMintableErc20FactoryABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function readOptimismMintableErc20Factory< - TAbi extends readonly unknown[] = typeof optimismMintableErc20FactoryABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof optimismMintableErc20FactoryAddress - } -) { - return readContract({ - abi: optimismMintableErc20FactoryABI, - address: optimismMintableErc20FactoryAddress[1], - ...config, - } as unknown as ReadContractConfig) -} - -/** - * Wraps __{@link writeContract}__ with `abi` set to __{@link optimismMintableErc20FactoryABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function writeOptimismMintableErc20Factory< - TFunctionName extends string, - TMode extends WriteContractMode, - TChainId extends number = keyof typeof optimismMintableErc20FactoryAddress ->( - config: - | (Omit< - WriteContractPreparedArgs< - typeof optimismMintableErc20FactoryABI, - TFunctionName - >, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof optimismMintableErc20FactoryAddress - }) - | (Omit< - WriteContractUnpreparedArgs< - typeof optimismMintableErc20FactoryABI, - TFunctionName - >, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof optimismMintableErc20FactoryAddress - }) -) { - return writeContract({ - abi: optimismMintableErc20FactoryABI, - address: optimismMintableErc20FactoryAddress[1], - ...config, - } as unknown as WriteContractArgs) -} - -/** - * Wraps __{@link prepareWriteContract}__ with `abi` set to __{@link optimismMintableErc20FactoryABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function prepareWriteOptimismMintableErc20Factory< - TAbi extends readonly unknown[] = typeof optimismMintableErc20FactoryABI, - TFunctionName extends string = string ->( - config: Omit< - PrepareWriteContractConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof optimismMintableErc20FactoryAddress } -) { - return prepareWriteContract({ - abi: optimismMintableErc20FactoryABI, - address: optimismMintableErc20FactoryAddress[1], - ...config, - } as unknown as PrepareWriteContractConfig) -} - -/** - * Wraps __{@link watchContractEvent}__ with `abi` set to __{@link optimismMintableErc20FactoryABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function watchOptimismMintableErc20FactoryEvent< - TAbi extends readonly unknown[] = typeof optimismMintableErc20FactoryABI, - TEventName extends string = string ->( - config: Omit< - WatchContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof optimismMintableErc20FactoryAddress }, - callback: WatchContractEventCallback -) { - return watchContractEvent( - { - abi: optimismMintableErc20FactoryABI, - address: optimismMintableErc20FactoryAddress[1], - ...config, - } as WatchContractEventConfig, - callback - ) -} - -/** - * Wraps __{@link getContract}__ with `abi` set to __{@link optimismMintableErc20FactoryGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function getOptimismMintableErc20FactoryGoerli( - config: Omit & { - chainId?: keyof typeof optimismMintableErc20FactoryGoerliAddress - } -) { - return getContract({ - abi: optimismMintableErc20FactoryGoerliABI, - address: optimismMintableErc20FactoryGoerliAddress[5], - ...config, - }) -} - -/** - * Wraps __{@link readContract}__ with `abi` set to __{@link optimismMintableErc20FactoryGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function readOptimismMintableErc20FactoryGoerli< - TAbi extends readonly unknown[] = typeof optimismMintableErc20FactoryGoerliABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof optimismMintableErc20FactoryGoerliAddress - } -) { - return readContract({ - abi: optimismMintableErc20FactoryGoerliABI, - address: optimismMintableErc20FactoryGoerliAddress[5], - ...config, - } as unknown as ReadContractConfig) -} - -/** - * Wraps __{@link writeContract}__ with `abi` set to __{@link optimismMintableErc20FactoryGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function writeOptimismMintableErc20FactoryGoerli< - TFunctionName extends string, - TMode extends WriteContractMode, - TChainId extends number = keyof typeof optimismMintableErc20FactoryGoerliAddress ->( - config: - | (Omit< - WriteContractPreparedArgs< - typeof optimismMintableErc20FactoryGoerliABI, - TFunctionName - >, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof optimismMintableErc20FactoryGoerliAddress - }) - | (Omit< - WriteContractUnpreparedArgs< - typeof optimismMintableErc20FactoryGoerliABI, - TFunctionName - >, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof optimismMintableErc20FactoryGoerliAddress - }) -) { - return writeContract({ - abi: optimismMintableErc20FactoryGoerliABI, - address: optimismMintableErc20FactoryGoerliAddress[5], - ...config, - } as unknown as WriteContractArgs) -} - -/** - * Wraps __{@link prepareWriteContract}__ with `abi` set to __{@link optimismMintableErc20FactoryGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function prepareWriteOptimismMintableErc20FactoryGoerli< - TAbi extends readonly unknown[] = typeof optimismMintableErc20FactoryGoerliABI, - TFunctionName extends string = string ->( - config: Omit< - PrepareWriteContractConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof optimismMintableErc20FactoryGoerliAddress } -) { - return prepareWriteContract({ - abi: optimismMintableErc20FactoryGoerliABI, - address: optimismMintableErc20FactoryGoerliAddress[5], - ...config, - } as unknown as PrepareWriteContractConfig) -} - -/** - * Wraps __{@link watchContractEvent}__ with `abi` set to __{@link optimismMintableErc20FactoryGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function watchOptimismMintableErc20FactoryGoerliEvent< - TAbi extends readonly unknown[] = typeof optimismMintableErc20FactoryGoerliABI, - TEventName extends string = string ->( - config: Omit< - WatchContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof optimismMintableErc20FactoryGoerliAddress }, - callback: WatchContractEventCallback -) { - return watchContractEvent( - { - abi: optimismMintableErc20FactoryGoerliABI, - address: optimismMintableErc20FactoryGoerliAddress[5], - ...config, - } as WatchContractEventConfig, - callback - ) -} - -/** - * Wraps __{@link getContract}__ with `abi` set to __{@link optimismMintableErc20FactoryOptimismGoerliABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function getOptimismMintableErc20FactoryOptimismGoerli( - config: Omit & { - chainId?: keyof typeof optimismMintableErc20FactoryOptimismGoerliAddress - } -) { - return getContract({ - abi: optimismMintableErc20FactoryOptimismGoerliABI, - address: optimismMintableErc20FactoryOptimismGoerliAddress[420], - ...config, - }) -} - -/** - * Wraps __{@link readContract}__ with `abi` set to __{@link optimismMintableErc20FactoryOptimismGoerliABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function readOptimismMintableErc20FactoryOptimismGoerli< - TAbi extends readonly unknown[] = typeof optimismMintableErc20FactoryOptimismGoerliABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof optimismMintableErc20FactoryOptimismGoerliAddress - } -) { - return readContract({ - abi: optimismMintableErc20FactoryOptimismGoerliABI, - address: optimismMintableErc20FactoryOptimismGoerliAddress[420], - ...config, - } as unknown as ReadContractConfig) -} - -/** - * Wraps __{@link writeContract}__ with `abi` set to __{@link optimismMintableErc20FactoryOptimismGoerliABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function writeOptimismMintableErc20FactoryOptimismGoerli< - TFunctionName extends string, - TMode extends WriteContractMode, - TChainId extends number = keyof typeof optimismMintableErc20FactoryOptimismGoerliAddress ->( - config: - | (Omit< - WriteContractPreparedArgs< - typeof optimismMintableErc20FactoryOptimismGoerliABI, - TFunctionName - >, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof optimismMintableErc20FactoryOptimismGoerliAddress - }) - | (Omit< - WriteContractUnpreparedArgs< - typeof optimismMintableErc20FactoryOptimismGoerliABI, - TFunctionName - >, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof optimismMintableErc20FactoryOptimismGoerliAddress - }) -) { - return writeContract({ - abi: optimismMintableErc20FactoryOptimismGoerliABI, - address: optimismMintableErc20FactoryOptimismGoerliAddress[420], - ...config, - } as unknown as WriteContractArgs) -} - -/** - * Wraps __{@link prepareWriteContract}__ with `abi` set to __{@link optimismMintableErc20FactoryOptimismGoerliABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function prepareWriteOptimismMintableErc20FactoryOptimismGoerli< - TAbi extends readonly unknown[] = typeof optimismMintableErc20FactoryOptimismGoerliABI, - TFunctionName extends string = string ->( - config: Omit< - PrepareWriteContractConfig, - 'abi' | 'address' - > & { - chainId?: keyof typeof optimismMintableErc20FactoryOptimismGoerliAddress - } -) { - return prepareWriteContract({ - abi: optimismMintableErc20FactoryOptimismGoerliABI, - address: optimismMintableErc20FactoryOptimismGoerliAddress[420], - ...config, - } as unknown as PrepareWriteContractConfig) -} - -/** - * Wraps __{@link watchContractEvent}__ with `abi` set to __{@link optimismMintableErc20FactoryOptimismGoerliABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function watchOptimismMintableErc20FactoryOptimismGoerliEvent< - TAbi extends readonly unknown[] = typeof optimismMintableErc20FactoryOptimismGoerliABI, - TEventName extends string = string ->( - config: Omit< - WatchContractEventConfig, - 'abi' | 'address' - > & { - chainId?: keyof typeof optimismMintableErc20FactoryOptimismGoerliAddress - }, - callback: WatchContractEventCallback -) { - return watchContractEvent( - { - abi: optimismMintableErc20FactoryOptimismGoerliABI, - address: optimismMintableErc20FactoryOptimismGoerliAddress[420], - ...config, - } as WatchContractEventConfig, - callback - ) -} - -/** - * Wraps __{@link getContract}__ with `abi` set to __{@link optimismMintableErc721FactoryABI}__. - * - * [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000017) - */ -export function getOptimismMintableErc721Factory( - config: Omit & { - chainId?: keyof typeof optimismMintableErc721FactoryAddress - } -) { - return getContract({ - abi: optimismMintableErc721FactoryABI, - address: optimismMintableErc721FactoryAddress[10], - ...config, - }) -} - -/** - * Wraps __{@link readContract}__ with `abi` set to __{@link optimismMintableErc721FactoryABI}__. - * - * [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000017) - */ -export function readOptimismMintableErc721Factory< - TAbi extends readonly unknown[] = typeof optimismMintableErc721FactoryABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof optimismMintableErc721FactoryAddress - } -) { - return readContract({ - abi: optimismMintableErc721FactoryABI, - address: optimismMintableErc721FactoryAddress[10], - ...config, - } as unknown as ReadContractConfig) -} - -/** - * Wraps __{@link writeContract}__ with `abi` set to __{@link optimismMintableErc721FactoryABI}__. - * - * [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000017) - */ -export function writeOptimismMintableErc721Factory< - TFunctionName extends string, - TMode extends WriteContractMode, - TChainId extends number = keyof typeof optimismMintableErc721FactoryAddress ->( - config: - | (Omit< - WriteContractPreparedArgs< - typeof optimismMintableErc721FactoryABI, - TFunctionName - >, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof optimismMintableErc721FactoryAddress - }) - | (Omit< - WriteContractUnpreparedArgs< - typeof optimismMintableErc721FactoryABI, - TFunctionName - >, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof optimismMintableErc721FactoryAddress - }) -) { - return writeContract({ - abi: optimismMintableErc721FactoryABI, - address: optimismMintableErc721FactoryAddress[10], - ...config, - } as unknown as WriteContractArgs) -} - -/** - * Wraps __{@link prepareWriteContract}__ with `abi` set to __{@link optimismMintableErc721FactoryABI}__. - * - * [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000017) - */ -export function prepareWriteOptimismMintableErc721Factory< - TAbi extends readonly unknown[] = typeof optimismMintableErc721FactoryABI, - TFunctionName extends string = string ->( - config: Omit< - PrepareWriteContractConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof optimismMintableErc721FactoryAddress } -) { - return prepareWriteContract({ - abi: optimismMintableErc721FactoryABI, - address: optimismMintableErc721FactoryAddress[10], - ...config, - } as unknown as PrepareWriteContractConfig) -} - -/** - * Wraps __{@link watchContractEvent}__ with `abi` set to __{@link optimismMintableErc721FactoryABI}__. - * - * [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000017) - */ -export function watchOptimismMintableErc721FactoryEvent< - TAbi extends readonly unknown[] = typeof optimismMintableErc721FactoryABI, - TEventName extends string = string ->( - config: Omit< - WatchContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof optimismMintableErc721FactoryAddress }, - callback: WatchContractEventCallback -) { - return watchContractEvent( - { - abi: optimismMintableErc721FactoryABI, - address: optimismMintableErc721FactoryAddress[10], - ...config, - } as WatchContractEventConfig, - callback - ) -} - -/** - * Wraps __{@link getContract}__ with `abi` set to __{@link optimismMintableErc721FactoryOptimismGoerliABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000017) - */ -export function getOptimismMintableErc721FactoryOptimismGoerli( - config: Omit & { - chainId?: keyof typeof optimismMintableErc721FactoryOptimismGoerliAddress - } -) { - return getContract({ - abi: optimismMintableErc721FactoryOptimismGoerliABI, - address: optimismMintableErc721FactoryOptimismGoerliAddress[420], - ...config, - }) -} - -/** - * Wraps __{@link readContract}__ with `abi` set to __{@link optimismMintableErc721FactoryOptimismGoerliABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000017) - */ -export function readOptimismMintableErc721FactoryOptimismGoerli< - TAbi extends readonly unknown[] = typeof optimismMintableErc721FactoryOptimismGoerliABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof optimismMintableErc721FactoryOptimismGoerliAddress - } -) { - return readContract({ - abi: optimismMintableErc721FactoryOptimismGoerliABI, - address: optimismMintableErc721FactoryOptimismGoerliAddress[420], - ...config, - } as unknown as ReadContractConfig) -} - -/** - * Wraps __{@link writeContract}__ with `abi` set to __{@link optimismMintableErc721FactoryOptimismGoerliABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000017) - */ -export function writeOptimismMintableErc721FactoryOptimismGoerli< - TFunctionName extends string, - TMode extends WriteContractMode, - TChainId extends number = keyof typeof optimismMintableErc721FactoryOptimismGoerliAddress ->( - config: - | (Omit< - WriteContractPreparedArgs< - typeof optimismMintableErc721FactoryOptimismGoerliABI, - TFunctionName - >, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof optimismMintableErc721FactoryOptimismGoerliAddress - }) - | (Omit< - WriteContractUnpreparedArgs< - typeof optimismMintableErc721FactoryOptimismGoerliABI, - TFunctionName - >, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof optimismMintableErc721FactoryOptimismGoerliAddress - }) -) { - return writeContract({ - abi: optimismMintableErc721FactoryOptimismGoerliABI, - address: optimismMintableErc721FactoryOptimismGoerliAddress[420], - ...config, - } as unknown as WriteContractArgs) -} - -/** - * Wraps __{@link prepareWriteContract}__ with `abi` set to __{@link optimismMintableErc721FactoryOptimismGoerliABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000017) - */ -export function prepareWriteOptimismMintableErc721FactoryOptimismGoerli< - TAbi extends readonly unknown[] = typeof optimismMintableErc721FactoryOptimismGoerliABI, - TFunctionName extends string = string ->( - config: Omit< - PrepareWriteContractConfig, - 'abi' | 'address' - > & { - chainId?: keyof typeof optimismMintableErc721FactoryOptimismGoerliAddress - } -) { - return prepareWriteContract({ - abi: optimismMintableErc721FactoryOptimismGoerliABI, - address: optimismMintableErc721FactoryOptimismGoerliAddress[420], - ...config, - } as unknown as PrepareWriteContractConfig) -} - -/** - * Wraps __{@link watchContractEvent}__ with `abi` set to __{@link optimismMintableErc721FactoryOptimismGoerliABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000017) - */ -export function watchOptimismMintableErc721FactoryOptimismGoerliEvent< - TAbi extends readonly unknown[] = typeof optimismMintableErc721FactoryOptimismGoerliABI, - TEventName extends string = string ->( - config: Omit< - WatchContractEventConfig, - 'abi' | 'address' - > & { - chainId?: keyof typeof optimismMintableErc721FactoryOptimismGoerliAddress - }, - callback: WatchContractEventCallback -) { - return watchContractEvent( - { - abi: optimismMintableErc721FactoryOptimismGoerliABI, - address: optimismMintableErc721FactoryOptimismGoerliAddress[420], - ...config, - } as WatchContractEventConfig, - callback - ) -} - -/** - * Wraps __{@link getContract}__ with `abi` set to __{@link optimismPortalABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) - */ -export function getOptimismPortal( - config: Omit & { - chainId?: keyof typeof optimismPortalAddress - } -) { - return getContract({ - abi: optimismPortalABI, - address: optimismPortalAddress[1], - ...config, - }) -} - -/** - * Wraps __{@link readContract}__ with `abi` set to __{@link optimismPortalABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) - */ -export function readOptimismPortal< - TAbi extends readonly unknown[] = typeof optimismPortalABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof optimismPortalAddress - } -) { - return readContract({ - abi: optimismPortalABI, - address: optimismPortalAddress[1], - ...config, - } as unknown as ReadContractConfig) -} - -/** - * Wraps __{@link writeContract}__ with `abi` set to __{@link optimismPortalABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) - */ -export function writeOptimismPortal< - TFunctionName extends string, - TMode extends WriteContractMode, - TChainId extends number = keyof typeof optimismPortalAddress ->( - config: - | (Omit< - WriteContractPreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof optimismPortalAddress - }) - | (Omit< - WriteContractUnpreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof optimismPortalAddress - }) -) { - return writeContract({ - abi: optimismPortalABI, - address: optimismPortalAddress[1], - ...config, - } as unknown as WriteContractArgs) -} - -/** - * Wraps __{@link prepareWriteContract}__ with `abi` set to __{@link optimismPortalABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) - */ -export function prepareWriteOptimismPortal< - TAbi extends readonly unknown[] = typeof optimismPortalABI, - TFunctionName extends string = string ->( - config: Omit< - PrepareWriteContractConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof optimismPortalAddress } -) { - return prepareWriteContract({ - abi: optimismPortalABI, - address: optimismPortalAddress[1], - ...config, - } as unknown as PrepareWriteContractConfig) -} - -/** - * Wraps __{@link watchContractEvent}__ with `abi` set to __{@link optimismPortalABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) - */ -export function watchOptimismPortalEvent< - TAbi extends readonly unknown[] = typeof optimismPortalABI, - TEventName extends string = string ->( - config: Omit< - WatchContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof optimismPortalAddress }, - callback: WatchContractEventCallback -) { - return watchContractEvent( - { - abi: optimismPortalABI, - address: optimismPortalAddress[1], - ...config, - } as WatchContractEventConfig, - callback - ) -} - -/** - * Wraps __{@link getContract}__ with `abi` set to __{@link optimismPortalGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) - */ -export function getOptimismPortalGoerli( - config: Omit & { - chainId?: keyof typeof optimismPortalGoerliAddress - } -) { - return getContract({ - abi: optimismPortalGoerliABI, - address: optimismPortalGoerliAddress[5], - ...config, - }) -} - -/** - * Wraps __{@link readContract}__ with `abi` set to __{@link optimismPortalGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) - */ -export function readOptimismPortalGoerli< - TAbi extends readonly unknown[] = typeof optimismPortalGoerliABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof optimismPortalGoerliAddress - } -) { - return readContract({ - abi: optimismPortalGoerliABI, - address: optimismPortalGoerliAddress[5], - ...config, - } as unknown as ReadContractConfig) -} - -/** - * Wraps __{@link writeContract}__ with `abi` set to __{@link optimismPortalGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) - */ -export function writeOptimismPortalGoerli< - TFunctionName extends string, - TMode extends WriteContractMode, - TChainId extends number = keyof typeof optimismPortalGoerliAddress ->( - config: - | (Omit< - WriteContractPreparedArgs< - typeof optimismPortalGoerliABI, - TFunctionName - >, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof optimismPortalGoerliAddress - }) - | (Omit< - WriteContractUnpreparedArgs< - typeof optimismPortalGoerliABI, - TFunctionName - >, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof optimismPortalGoerliAddress - }) -) { - return writeContract({ - abi: optimismPortalGoerliABI, - address: optimismPortalGoerliAddress[5], - ...config, - } as unknown as WriteContractArgs) -} - -/** - * Wraps __{@link prepareWriteContract}__ with `abi` set to __{@link optimismPortalGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) - */ -export function prepareWriteOptimismPortalGoerli< - TAbi extends readonly unknown[] = typeof optimismPortalGoerliABI, - TFunctionName extends string = string ->( - config: Omit< - PrepareWriteContractConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof optimismPortalGoerliAddress } -) { - return prepareWriteContract({ - abi: optimismPortalGoerliABI, - address: optimismPortalGoerliAddress[5], - ...config, - } as unknown as PrepareWriteContractConfig) -} - -/** - * Wraps __{@link watchContractEvent}__ with `abi` set to __{@link optimismPortalGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) - */ -export function watchOptimismPortalGoerliEvent< - TAbi extends readonly unknown[] = typeof optimismPortalGoerliABI, - TEventName extends string = string ->( - config: Omit< - WatchContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof optimismPortalGoerliAddress }, - callback: WatchContractEventCallback -) { - return watchContractEvent( - { - abi: optimismPortalGoerliABI, - address: optimismPortalGoerliAddress[5], - ...config, - } as WatchContractEventConfig, - callback - ) -} - -/** - * Wraps __{@link getContract}__ with `abi` set to __{@link optimistABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - */ -export function getOptimist( - config: Omit & { - chainId?: keyof typeof optimistAddress - } -) { - return getContract({ - abi: optimistABI, - address: optimistAddress[config.chainId as keyof typeof optimistAddress], - ...config, - }) -} - -/** - * Wraps __{@link readContract}__ with `abi` set to __{@link optimistABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - */ -export function readOptimist< - TAbi extends readonly unknown[] = typeof optimistABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof optimistAddress - } -) { - return readContract({ - abi: optimistABI, - address: optimistAddress[config.chainId as keyof typeof optimistAddress], - ...config, - } as unknown as ReadContractConfig) -} + name: 'withdrawFromTeleportr', + outputs: [], + }, + { stateMutability: 'payable', type: 'receive' }, +] as const /** - * Wraps __{@link writeContract}__ with `abi` set to __{@link optimistABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) + * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) */ -export function writeOptimist< - TFunctionName extends string, - TMode extends WriteContractMode, - TChainId extends number = keyof typeof optimistAddress ->( - config: - | (Omit< - WriteContractPreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof optimistAddress - }) - | (Omit< - WriteContractUnpreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof optimistAddress - }) -) { - return writeContract({ - abi: optimistABI, - address: optimistAddress[config.chainId as keyof typeof optimistAddress], - ...config, - } as unknown as WriteContractArgs) -} +export const teleportrWithdrawerAddress = { + 1: '0x78A25524D90E3D0596558fb43789bD800a5c3007', +} as const /** - * Wraps __{@link prepareWriteContract}__ with `abi` set to __{@link optimistABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) + * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) */ -export function prepareWriteOptimist< - TAbi extends readonly unknown[] = typeof optimistABI, - TFunctionName extends string = string ->( - config: Omit< - PrepareWriteContractConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof optimistAddress } -) { - return prepareWriteContract({ - abi: optimistABI, - address: optimistAddress[config.chainId as keyof typeof optimistAddress], - ...config, - } as unknown as PrepareWriteContractConfig) -} +export const teleportrWithdrawerConfig = { + address: teleportrWithdrawerAddress, + abi: teleportrWithdrawerABI, +} as const -/** - * Wraps __{@link watchContractEvent}__ with `abi` set to __{@link optimistABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - */ -export function watchOptimistEvent< - TAbi extends readonly unknown[] = typeof optimistABI, - TEventName extends string = string ->( - config: Omit< - WatchContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof optimistAddress }, - callback: WatchContractEventCallback -) { - return watchContractEvent( - { - abi: optimistABI, - address: optimistAddress[config.chainId as keyof typeof optimistAddress], - ...config, - } as WatchContractEventConfig, - callback - ) -} +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// eslintIgnore +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// Core +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * Wraps __{@link getContract}__ with `abi` set to __{@link optimistAllowlistABI}__. + * Wraps __{@link getContract}__ with `abi` set to __{@link addressManagerABI}__. * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdE1FCfB0851916CA5101820A69b13a4E276bd81F) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xa6f73589243a6A7a9023b1Fa0651b1d89c177111) */ -export function getOptimistAllowlist( +export function getAddressManager( config: Omit & { - chainId?: keyof typeof optimistAllowlistAddress + chainId?: keyof typeof addressManagerAddress } ) { return getContract({ - abi: optimistAllowlistABI, + abi: addressManagerABI, address: - optimistAllowlistAddress[ - config.chainId as keyof typeof optimistAllowlistAddress + addressManagerAddress[ + config.chainId as keyof typeof addressManagerAddress ], ...config, }) } /** - * Wraps __{@link readContract}__ with `abi` set to __{@link optimistAllowlistABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) - */ -export function readOptimistAllowlist< - TAbi extends readonly unknown[] = typeof optimistAllowlistABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof optimistAllowlistAddress - } -) { - return readContract({ - abi: optimistAllowlistABI, - address: - optimistAllowlistAddress[ - config.chainId as keyof typeof optimistAllowlistAddress - ], - ...config, - } as unknown as ReadContractConfig) -} - -/** - * Wraps __{@link getContract}__ with `abi` set to __{@link optimistInviterABI}__. + * Wraps __{@link getContract}__ with `abi` set to __{@link assetReceiverABI}__. * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) */ -export function getOptimistInviter( +export function getAssetReceiver( config: Omit & { - chainId?: keyof typeof optimistInviterAddress + chainId?: keyof typeof assetReceiverAddress } ) { return getContract({ - abi: optimistInviterABI, + abi: assetReceiverABI, address: - optimistInviterAddress[ - config.chainId as keyof typeof optimistInviterAddress - ], + assetReceiverAddress[config.chainId as keyof typeof assetReceiverAddress], ...config, }) } /** - * Wraps __{@link readContract}__ with `abi` set to __{@link optimistInviterABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - */ -export function readOptimistInviter< - TAbi extends readonly unknown[] = typeof optimistInviterABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof optimistInviterAddress - } -) { - return readContract({ - abi: optimistInviterABI, - address: - optimistInviterAddress[ - config.chainId as keyof typeof optimistInviterAddress - ], - ...config, - } as unknown as ReadContractConfig) -} - -/** - * Wraps __{@link writeContract}__ with `abi` set to __{@link optimistInviterABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - */ -export function writeOptimistInviter< - TFunctionName extends string, - TMode extends WriteContractMode, - TChainId extends number = keyof typeof optimistInviterAddress ->( - config: - | (Omit< - WriteContractPreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof optimistInviterAddress - }) - | (Omit< - WriteContractUnpreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof optimistInviterAddress - }) -) { - return writeContract({ - abi: optimistInviterABI, - address: - optimistInviterAddress[ - config.chainId as keyof typeof optimistInviterAddress - ], - ...config, - } as unknown as WriteContractArgs) -} - -/** - * Wraps __{@link prepareWriteContract}__ with `abi` set to __{@link optimistInviterABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - */ -export function prepareWriteOptimistInviter< - TAbi extends readonly unknown[] = typeof optimistInviterABI, - TFunctionName extends string = string ->( - config: Omit< - PrepareWriteContractConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof optimistInviterAddress } -) { - return prepareWriteContract({ - abi: optimistInviterABI, - address: - optimistInviterAddress[ - config.chainId as keyof typeof optimistInviterAddress - ], - ...config, - } as unknown as PrepareWriteContractConfig) -} - -/** - * Wraps __{@link watchContractEvent}__ with `abi` set to __{@link optimistInviterABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - */ -export function watchOptimistInviterEvent< - TAbi extends readonly unknown[] = typeof optimistInviterABI, - TEventName extends string = string ->( - config: Omit< - WatchContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof optimistInviterAddress }, - callback: WatchContractEventCallback -) { - return watchContractEvent( - { - abi: optimistInviterABI, - address: - optimistInviterAddress[ - config.chainId as keyof typeof optimistInviterAddress - ], - ...config, - } as WatchContractEventConfig, - callback - ) -} - -/** - * Wraps __{@link getContract}__ with `abi` set to __{@link portalSenderABI}__. + * Wraps __{@link getContract}__ with `abi` set to __{@link attestationStationABI}__. * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x0A893d9576b9cFD9EF78595963dc973238E78210) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xe7FACd39531ee3C313330E93B4d7a8B8A3c84Aa4) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0xEE36eaaD94d1Cc1d0eccaDb55C38bFfB6Be06C77) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0xEE36eaaD94d1Cc1d0eccaDb55C38bFfB6Be06C77) */ -export function getPortalSender( +export function getAttestationStation( config: Omit & { - chainId?: keyof typeof portalSenderAddress + chainId?: keyof typeof attestationStationAddress } ) { return getContract({ - abi: portalSenderABI, + abi: attestationStationABI, address: - portalSenderAddress[config.chainId as keyof typeof portalSenderAddress], + attestationStationAddress[ + config.chainId as keyof typeof attestationStationAddress + ], ...config, }) } /** - * Wraps __{@link readContract}__ with `abi` set to __{@link portalSenderABI}__. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x0A893d9576b9cFD9EF78595963dc973238E78210) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xe7FACd39531ee3C313330E93B4d7a8B8A3c84Aa4) - */ -export function readPortalSender< - TAbi extends readonly unknown[] = typeof portalSenderABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof portalSenderAddress - } -) { - return readContract({ - abi: portalSenderABI, - address: - portalSenderAddress[config.chainId as keyof typeof portalSenderAddress], - ...config, - } as unknown as ReadContractConfig) -} - -/** - * Wraps __{@link writeContract}__ with `abi` set to __{@link portalSenderABI}__. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x0A893d9576b9cFD9EF78595963dc973238E78210) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xe7FACd39531ee3C313330E93B4d7a8B8A3c84Aa4) - */ -export function writePortalSender< - TFunctionName extends string, - TMode extends WriteContractMode, - TChainId extends number = keyof typeof portalSenderAddress ->( - config: - | (Omit< - WriteContractPreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof portalSenderAddress - }) - | (Omit< - WriteContractUnpreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof portalSenderAddress - }) -) { - return writeContract({ - abi: portalSenderABI, - address: - portalSenderAddress[config.chainId as keyof typeof portalSenderAddress], - ...config, - } as unknown as WriteContractArgs) -} - -/** - * Wraps __{@link prepareWriteContract}__ with `abi` set to __{@link portalSenderABI}__. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x0A893d9576b9cFD9EF78595963dc973238E78210) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xe7FACd39531ee3C313330E93B4d7a8B8A3c84Aa4) - */ -export function prepareWritePortalSender< - TAbi extends readonly unknown[] = typeof portalSenderABI, - TFunctionName extends string = string ->( - config: Omit< - PrepareWriteContractConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof portalSenderAddress } -) { - return prepareWriteContract({ - abi: portalSenderABI, - address: - portalSenderAddress[config.chainId as keyof typeof portalSenderAddress], - ...config, - } as unknown as PrepareWriteContractConfig) -} - -/** - * Wraps __{@link getContract}__ with `abi` set to __{@link protocolVersionsABI}__. + * Wraps __{@link getContract}__ with `abi` set to __{@link baseFeeVaultABI}__. * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000019) */ -export function getProtocolVersions( +export function getBaseFeeVault( config: Omit & { - chainId?: keyof typeof protocolVersionsAddress + chainId?: keyof typeof baseFeeVaultAddress } ) { return getContract({ - abi: protocolVersionsABI, - address: protocolVersionsAddress[5], + abi: baseFeeVaultABI, + address: baseFeeVaultAddress[420], ...config, }) } /** - * Wraps __{@link readContract}__ with `abi` set to __{@link protocolVersionsABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) - */ -export function readProtocolVersions< - TAbi extends readonly unknown[] = typeof protocolVersionsABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof protocolVersionsAddress - } -) { - return readContract({ - abi: protocolVersionsABI, - address: protocolVersionsAddress[5], - ...config, - } as unknown as ReadContractConfig) -} - -/** - * Wraps __{@link writeContract}__ with `abi` set to __{@link protocolVersionsABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) - */ -export function writeProtocolVersions< - TFunctionName extends string, - TMode extends WriteContractMode, - TChainId extends number = keyof typeof protocolVersionsAddress ->( - config: - | (Omit< - WriteContractPreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof protocolVersionsAddress - }) - | (Omit< - WriteContractUnpreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof protocolVersionsAddress - }) -) { - return writeContract({ - abi: protocolVersionsABI, - address: protocolVersionsAddress[5], - ...config, - } as unknown as WriteContractArgs) -} - -/** - * Wraps __{@link prepareWriteContract}__ with `abi` set to __{@link protocolVersionsABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) - */ -export function prepareWriteProtocolVersions< - TAbi extends readonly unknown[] = typeof protocolVersionsABI, - TFunctionName extends string = string ->( - config: Omit< - PrepareWriteContractConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof protocolVersionsAddress } -) { - return prepareWriteContract({ - abi: protocolVersionsABI, - address: protocolVersionsAddress[5], - ...config, - } as unknown as PrepareWriteContractConfig) -} - -/** - * Wraps __{@link watchContractEvent}__ with `abi` set to __{@link protocolVersionsABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) - */ -export function watchProtocolVersionsEvent< - TAbi extends readonly unknown[] = typeof protocolVersionsABI, - TEventName extends string = string ->( - config: Omit< - WatchContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof protocolVersionsAddress }, - callback: WatchContractEventCallback -) { - return watchContractEvent( - { - abi: protocolVersionsABI, - address: protocolVersionsAddress[5], - ...config, - } as WatchContractEventConfig, - callback - ) -} - -/** - * Wraps __{@link getContract}__ with `abi` set to __{@link proxyAdminABI}__. + * Wraps __{@link getContract}__ with `abi` set to __{@link checkBalanceHighABI}__. * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x7eC64a8a591bFf829ff6C8be76074D540ACb813F) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x7eC64a8a591bFf829ff6C8be76074D540ACb813F) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5d7103853f12109A7d27F118e54BbC654ad847E9) */ -export function getProxyAdmin( +export function getCheckBalanceHigh( config: Omit & { - chainId?: keyof typeof proxyAdminAddress + chainId?: keyof typeof checkBalanceHighAddress } ) { return getContract({ - abi: proxyAdminABI, + abi: checkBalanceHighABI, address: - proxyAdminAddress[config.chainId as keyof typeof proxyAdminAddress], + checkBalanceHighAddress[ + config.chainId as keyof typeof checkBalanceHighAddress + ], ...config, }) } /** - * Wraps __{@link readContract}__ with `abi` set to __{@link proxyAdminABI}__. + * Wraps __{@link getContract}__ with `abi` set to __{@link checkBalanceLowABI}__. * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x381a4eFC2A2C914eA1889722bB4B44Fa6BD5b640) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x381a4eFC2A2C914eA1889722bB4B44Fa6BD5b640) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x7Ce13D154FAEE5C8B3E6b19d4Add16f21d884474) */ -export function readProxyAdmin< - TAbi extends readonly unknown[] = typeof proxyAdminABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof proxyAdminAddress +export function getCheckBalanceLow( + config: Omit & { + chainId?: keyof typeof checkBalanceLowAddress } ) { - return readContract({ - abi: proxyAdminABI, + return getContract({ + abi: checkBalanceLowABI, address: - proxyAdminAddress[config.chainId as keyof typeof proxyAdminAddress], + checkBalanceLowAddress[ + config.chainId as keyof typeof checkBalanceLowAddress + ], ...config, - } as unknown as ReadContractConfig) + }) } /** - * Wraps __{@link writeContract}__ with `abi` set to __{@link proxyAdminABI}__. + * Wraps __{@link getContract}__ with `abi` set to __{@link checkGelatoLowABI}__. * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4f7CFc43f6D262a085F3b946cAC69E7a8E39BBAa) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4f7CFc43f6D262a085F3b946cAC69E7a8E39BBAa) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0xF9c8a4Cb4021f57F9f6d69799cA9BefF64524862) */ -export function writeProxyAdmin< - TFunctionName extends string, - TMode extends WriteContractMode, - TChainId extends number = keyof typeof proxyAdminAddress ->( - config: - | (Omit< - WriteContractPreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof proxyAdminAddress - }) - | (Omit< - WriteContractUnpreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof proxyAdminAddress - }) +export function getCheckGelatoLow( + config: Omit & { + chainId?: keyof typeof checkGelatoLowAddress + } ) { - return writeContract({ - abi: proxyAdminABI, + return getContract({ + abi: checkGelatoLowABI, address: - proxyAdminAddress[config.chainId as keyof typeof proxyAdminAddress], + checkGelatoLowAddress[ + config.chainId as keyof typeof checkGelatoLowAddress + ], ...config, - } as unknown as WriteContractArgs) + }) } /** - * Wraps __{@link prepareWriteContract}__ with `abi` set to __{@link proxyAdminABI}__. + * Wraps __{@link getContract}__ with `abi` set to __{@link checkTrueABI}__. * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5c741a38cb11424711231777D71689C458eE835D) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5c741a38cb11424711231777D71689C458eE835D) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x47443D0C184e022F19BD1578F5bca6B8a9F58E32) */ -export function prepareWriteProxyAdmin< - TAbi extends readonly unknown[] = typeof proxyAdminABI, - TFunctionName extends string = string ->( - config: Omit< - PrepareWriteContractConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof proxyAdminAddress } +export function getCheckTrue( + config: Omit & { + chainId?: keyof typeof checkTrueAddress + } ) { - return prepareWriteContract({ - abi: proxyAdminABI, - address: - proxyAdminAddress[config.chainId as keyof typeof proxyAdminAddress], + return getContract({ + abi: checkTrueABI, + address: checkTrueAddress[config.chainId as keyof typeof checkTrueAddress], ...config, - } as unknown as PrepareWriteContractConfig) + }) } /** - * Wraps __{@link watchContractEvent}__ with `abi` set to __{@link proxyAdminABI}__. + * Wraps __{@link getContract}__ with `abi` set to __{@link drippieABI}__. * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) + * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) */ -export function watchProxyAdminEvent< - TAbi extends readonly unknown[] = typeof proxyAdminABI, - TEventName extends string = string ->( - config: Omit< - WatchContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof proxyAdminAddress }, - callback: WatchContractEventCallback +export function getDrippie( + config: Omit & { + chainId?: keyof typeof drippieAddress + } ) { - return watchContractEvent( - { - abi: proxyAdminABI, - address: - proxyAdminAddress[config.chainId as keyof typeof proxyAdminAddress], - ...config, - } as WatchContractEventConfig, - callback - ) + return getContract({ abi: drippieABI, address: drippieAddress[1], ...config }) } /** - * Wraps __{@link getContract}__ with `abi` set to __{@link schemaRegistryABI}__. + * Wraps __{@link getContract}__ with `abi` set to __{@link drippieGoerliABI}__. * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x6232208d66bAc2305b46b4Cb6BCB3857B298DF13) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2545fa928d5d278cA75Fd47306e4a89096ff6403) + * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) */ -export function getSchemaRegistry( +export function getDrippieGoerli( config: Omit & { - chainId?: keyof typeof schemaRegistryAddress + chainId?: keyof typeof drippieGoerliAddress } ) { return getContract({ - abi: schemaRegistryABI, - address: - schemaRegistryAddress[ - config.chainId as keyof typeof schemaRegistryAddress - ], + abi: drippieGoerliABI, + address: drippieGoerliAddress[5], ...config, }) } /** - * Wraps __{@link readContract}__ with `abi` set to __{@link schemaRegistryABI}__. + * Wraps __{@link getContract}__ with `abi` set to __{@link drippieOptimismGoerliABI}__. * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x6232208d66bAc2305b46b4Cb6BCB3857B298DF13) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2545fa928d5d278cA75Fd47306e4a89096ff6403) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x8D8d533C16D23847EB04EEB0925be8900Dd3af86) */ -export function readSchemaRegistry< - TAbi extends readonly unknown[] = typeof schemaRegistryABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof schemaRegistryAddress +export function getDrippieOptimismGoerli( + config: Omit & { + chainId?: keyof typeof drippieOptimismGoerliAddress } ) { - return readContract({ - abi: schemaRegistryABI, - address: - schemaRegistryAddress[ - config.chainId as keyof typeof schemaRegistryAddress - ], + return getContract({ + abi: drippieOptimismGoerliABI, + address: drippieOptimismGoerliAddress[420], ...config, - } as unknown as ReadContractConfig) + }) } /** - * Wraps __{@link writeContract}__ with `abi` set to __{@link schemaRegistryABI}__. + * Wraps __{@link getContract}__ with `abi` set to __{@link easABI}__. * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x6232208d66bAc2305b46b4Cb6BCB3857B298DF13) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2545fa928d5d278cA75Fd47306e4a89096ff6403) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) */ -export function writeSchemaRegistry< - TFunctionName extends string, - TMode extends WriteContractMode, - TChainId extends number = keyof typeof schemaRegistryAddress ->( - config: - | (Omit< - WriteContractPreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof schemaRegistryAddress - }) - | (Omit< - WriteContractUnpreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof schemaRegistryAddress - }) +export function getEas( + config: Omit & { + chainId?: keyof typeof easAddress + } ) { - return writeContract({ - abi: schemaRegistryABI, - address: - schemaRegistryAddress[ - config.chainId as keyof typeof schemaRegistryAddress - ], + return getContract({ + abi: easABI, + address: easAddress[config.chainId as keyof typeof easAddress], ...config, - } as unknown as WriteContractArgs) + }) } /** - * Wraps __{@link prepareWriteContract}__ with `abi` set to __{@link schemaRegistryABI}__. + * Wraps __{@link getContract}__ with `abi` set to __{@link gasPriceOracleABI}__. * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x6232208d66bAc2305b46b4Cb6BCB3857B298DF13) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2545fa928d5d278cA75Fd47306e4a89096ff6403) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000000F) */ -export function prepareWriteSchemaRegistry< - TAbi extends readonly unknown[] = typeof schemaRegistryABI, - TFunctionName extends string = string ->( - config: Omit< - PrepareWriteContractConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof schemaRegistryAddress } +export function getGasPriceOracle( + config: Omit & { + chainId?: keyof typeof gasPriceOracleAddress + } ) { - return prepareWriteContract({ - abi: schemaRegistryABI, - address: - schemaRegistryAddress[ - config.chainId as keyof typeof schemaRegistryAddress - ], + return getContract({ + abi: gasPriceOracleABI, + address: gasPriceOracleAddress[420], ...config, - } as unknown as PrepareWriteContractConfig) -} - -/** - * Wraps __{@link watchContractEvent}__ with `abi` set to __{@link schemaRegistryABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x6232208d66bAc2305b46b4Cb6BCB3857B298DF13) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2545fa928d5d278cA75Fd47306e4a89096ff6403) - */ -export function watchSchemaRegistryEvent< - TAbi extends readonly unknown[] = typeof schemaRegistryABI, - TEventName extends string = string ->( - config: Omit< - WatchContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof schemaRegistryAddress }, - callback: WatchContractEventCallback -) { - return watchContractEvent( - { - abi: schemaRegistryABI, - address: - schemaRegistryAddress[ - config.chainId as keyof typeof schemaRegistryAddress - ], - ...config, - } as WatchContractEventConfig, - callback - ) + }) } /** - * Wraps __{@link getContract}__ with `abi` set to __{@link sequencerFeeVaultABI}__. + * Wraps __{@link getContract}__ with `abi` set to __{@link l1BlockABI}__. * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000011) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000015) */ -export function getSequencerFeeVault( +export function getL1Block( config: Omit & { - chainId?: keyof typeof sequencerFeeVaultAddress + chainId?: keyof typeof l1BlockAddress } ) { return getContract({ - abi: sequencerFeeVaultABI, - address: sequencerFeeVaultAddress[420], + abi: l1BlockABI, + address: l1BlockAddress[420], ...config, }) } /** - * Wraps __{@link readContract}__ with `abi` set to __{@link sequencerFeeVaultABI}__. + * Wraps __{@link getContract}__ with `abi` set to __{@link l1CrossDomainMessengerABI}__. * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000011) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) */ -export function readSequencerFeeVault< - TAbi extends readonly unknown[] = typeof sequencerFeeVaultABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof sequencerFeeVaultAddress +export function getL1CrossDomainMessenger( + config: Omit & { + chainId?: keyof typeof l1CrossDomainMessengerAddress } ) { - return readContract({ - abi: sequencerFeeVaultABI, - address: sequencerFeeVaultAddress[420], + return getContract({ + abi: l1CrossDomainMessengerABI, + address: + l1CrossDomainMessengerAddress[ + config.chainId as keyof typeof l1CrossDomainMessengerAddress + ], ...config, - } as unknown as ReadContractConfig) + }) } /** - * Wraps __{@link writeContract}__ with `abi` set to __{@link sequencerFeeVaultABI}__. + * Wraps __{@link getContract}__ with `abi` set to __{@link l1Erc721BridgeABI}__. * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000011) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5a7749f83b81B301cAb5f48EB8516B986DAef23D) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9) */ -export function writeSequencerFeeVault< - TFunctionName extends string, - TMode extends WriteContractMode, - TChainId extends number = keyof typeof sequencerFeeVaultAddress ->( - config: - | (Omit< - WriteContractPreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof sequencerFeeVaultAddress - }) - | (Omit< - WriteContractUnpreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof sequencerFeeVaultAddress - }) +export function getL1Erc721Bridge( + config: Omit & { + chainId?: keyof typeof l1Erc721BridgeAddress + } ) { - return writeContract({ - abi: sequencerFeeVaultABI, - address: sequencerFeeVaultAddress[420], + return getContract({ + abi: l1Erc721BridgeABI, + address: + l1Erc721BridgeAddress[ + config.chainId as keyof typeof l1Erc721BridgeAddress + ], ...config, - } as unknown as WriteContractArgs) + }) } /** - * Wraps __{@link prepareWriteContract}__ with `abi` set to __{@link sequencerFeeVaultABI}__. + * Wraps __{@link getContract}__ with `abi` set to __{@link l1FeeVaultABI}__. * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000011) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000001a) */ -export function prepareWriteSequencerFeeVault< - TAbi extends readonly unknown[] = typeof sequencerFeeVaultABI, - TFunctionName extends string = string ->( - config: Omit< - PrepareWriteContractConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof sequencerFeeVaultAddress } +export function getL1FeeVault( + config: Omit & { + chainId?: keyof typeof l1FeeVaultAddress + } ) { - return prepareWriteContract({ - abi: sequencerFeeVaultABI, - address: sequencerFeeVaultAddress[420], + return getContract({ + abi: l1FeeVaultABI, + address: l1FeeVaultAddress[420], ...config, - } as unknown as PrepareWriteContractConfig) + }) } /** - * Wraps __{@link watchContractEvent}__ with `abi` set to __{@link sequencerFeeVaultABI}__. + * Wraps __{@link getContract}__ with `abi` set to __{@link l1StandardBridgeABI}__. * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000011) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) */ -export function watchSequencerFeeVaultEvent< - TAbi extends readonly unknown[] = typeof sequencerFeeVaultABI, - TEventName extends string = string ->( - config: Omit< - WatchContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof sequencerFeeVaultAddress }, - callback: WatchContractEventCallback +export function getL1StandardBridge( + config: Omit & { + chainId?: keyof typeof l1StandardBridgeAddress + } ) { - return watchContractEvent( - { - abi: sequencerFeeVaultABI, - address: sequencerFeeVaultAddress[420], - ...config, - } as WatchContractEventConfig, - callback - ) + return getContract({ + abi: l1StandardBridgeABI, + address: + l1StandardBridgeAddress[ + config.chainId as keyof typeof l1StandardBridgeAddress + ], + ...config, + }) } /** - * Wraps __{@link getContract}__ with `abi` set to __{@link systemConfigABI}__. + * Wraps __{@link getContract}__ with `abi` set to __{@link l2CrossDomainMessengerABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) */ -export function getSystemConfig( +export function getL2CrossDomainMessenger( config: Omit & { - chainId?: keyof typeof systemConfigAddress + chainId?: keyof typeof l2CrossDomainMessengerAddress } ) { return getContract({ - abi: systemConfigABI, - address: systemConfigAddress[1], + abi: l2CrossDomainMessengerABI, + address: l2CrossDomainMessengerAddress[420], ...config, }) } /** - * Wraps __{@link readContract}__ with `abi` set to __{@link systemConfigABI}__. + * Wraps __{@link getContract}__ with `abi` set to __{@link l2Erc721BridgeABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000014) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000014) */ -export function readSystemConfig< - TAbi extends readonly unknown[] = typeof systemConfigABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof systemConfigAddress +export function getL2Erc721Bridge( + config: Omit & { + chainId?: keyof typeof l2Erc721BridgeAddress } ) { - return readContract({ - abi: systemConfigABI, - address: systemConfigAddress[1], + return getContract({ + abi: l2Erc721BridgeABI, + address: + l2Erc721BridgeAddress[ + config.chainId as keyof typeof l2Erc721BridgeAddress + ], ...config, - } as unknown as ReadContractConfig) + }) } /** - * Wraps __{@link writeContract}__ with `abi` set to __{@link systemConfigABI}__. + * Wraps __{@link getContract}__ with `abi` set to __{@link l2OutputOracleABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) */ -export function writeSystemConfig< - TFunctionName extends string, - TMode extends WriteContractMode, - TChainId extends number = keyof typeof systemConfigAddress ->( - config: - | (Omit< - WriteContractPreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof systemConfigAddress - }) - | (Omit< - WriteContractUnpreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof systemConfigAddress - }) +export function getL2OutputOracle( + config: Omit & { + chainId?: keyof typeof l2OutputOracleAddress + } ) { - return writeContract({ - abi: systemConfigABI, - address: systemConfigAddress[1], + return getContract({ + abi: l2OutputOracleABI, + address: + l2OutputOracleAddress[ + config.chainId as keyof typeof l2OutputOracleAddress + ], ...config, - } as unknown as WriteContractArgs) + }) } /** - * Wraps __{@link prepareWriteContract}__ with `abi` set to __{@link systemConfigABI}__. + * Wraps __{@link getContract}__ with `abi` set to __{@link l2StandardBridgeABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) */ -export function prepareWriteSystemConfig< - TAbi extends readonly unknown[] = typeof systemConfigABI, - TFunctionName extends string = string ->( - config: Omit< - PrepareWriteContractConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof systemConfigAddress } +export function getL2StandardBridge( + config: Omit & { + chainId?: keyof typeof l2StandardBridgeAddress + } ) { - return prepareWriteContract({ - abi: systemConfigABI, - address: systemConfigAddress[1], + return getContract({ + abi: l2StandardBridgeABI, + address: l2StandardBridgeAddress[420], ...config, - } as unknown as PrepareWriteContractConfig) + }) } /** - * Wraps __{@link watchContractEvent}__ with `abi` set to __{@link systemConfigABI}__. + * Wraps __{@link getContract}__ with `abi` set to __{@link l2ToL1MessagePasserABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000016) */ -export function watchSystemConfigEvent< - TAbi extends readonly unknown[] = typeof systemConfigABI, - TEventName extends string = string ->( - config: Omit< - WatchContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof systemConfigAddress }, - callback: WatchContractEventCallback +export function getL2ToL1MessagePasser( + config: Omit & { + chainId?: keyof typeof l2ToL1MessagePasserAddress + } ) { - return watchContractEvent( - { - abi: systemConfigABI, - address: systemConfigAddress[1], - ...config, - } as WatchContractEventConfig, - callback - ) + return getContract({ + abi: l2ToL1MessagePasserABI, + address: l2ToL1MessagePasserAddress[420], + ...config, + }) } /** - * Wraps __{@link getContract}__ with `abi` set to __{@link systemConfigGoerliABI}__. + * Wraps __{@link getContract}__ with `abi` set to __{@link mintManagerABI}__. * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x5C4e7Ba1E219E47948e6e3F55019A647bA501005) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76) */ -export function getSystemConfigGoerli( +export function getMintManager( config: Omit & { - chainId?: keyof typeof systemConfigGoerliAddress + chainId?: keyof typeof mintManagerAddress } ) { return getContract({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], + abi: mintManagerABI, + address: + mintManagerAddress[config.chainId as keyof typeof mintManagerAddress], ...config, }) } /** - * Wraps __{@link readContract}__ with `abi` set to __{@link systemConfigGoerliABI}__. + * Wraps __{@link getContract}__ with `abi` set to __{@link optimismMintableErc20FactoryABI}__. * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) + * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000012) */ -export function readSystemConfigGoerli< - TAbi extends readonly unknown[] = typeof systemConfigGoerliABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof systemConfigGoerliAddress +export function getOptimismMintableErc20Factory( + config: Omit & { + chainId?: keyof typeof optimismMintableErc20FactoryAddress } ) { - return readContract({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], + return getContract({ + abi: optimismMintableErc20FactoryABI, + address: optimismMintableErc20FactoryAddress[1], ...config, - } as unknown as ReadContractConfig) + }) } /** - * Wraps __{@link writeContract}__ with `abi` set to __{@link systemConfigGoerliABI}__. + * Wraps __{@link getContract}__ with `abi` set to __{@link optimismMintableErc20FactoryGoerliABI}__. * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) + * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000012) */ -export function writeSystemConfigGoerli< - TFunctionName extends string, - TMode extends WriteContractMode, - TChainId extends number = keyof typeof systemConfigGoerliAddress ->( - config: - | (Omit< - WriteContractPreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof systemConfigGoerliAddress - }) - | (Omit< - WriteContractUnpreparedArgs< - typeof systemConfigGoerliABI, - TFunctionName - >, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof systemConfigGoerliAddress - }) +export function getOptimismMintableErc20FactoryGoerli( + config: Omit & { + chainId?: keyof typeof optimismMintableErc20FactoryGoerliAddress + } ) { - return writeContract({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], + return getContract({ + abi: optimismMintableErc20FactoryGoerliABI, + address: optimismMintableErc20FactoryGoerliAddress[5], ...config, - } as unknown as WriteContractArgs) + }) } /** - * Wraps __{@link prepareWriteContract}__ with `abi` set to __{@link systemConfigGoerliABI}__. + * Wraps __{@link getContract}__ with `abi` set to __{@link optimismMintableErc20FactoryOptimismGoerliABI}__. * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000012) */ -export function prepareWriteSystemConfigGoerli< - TAbi extends readonly unknown[] = typeof systemConfigGoerliABI, - TFunctionName extends string = string ->( - config: Omit< - PrepareWriteContractConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof systemConfigGoerliAddress } +export function getOptimismMintableErc20FactoryOptimismGoerli( + config: Omit & { + chainId?: keyof typeof optimismMintableErc20FactoryOptimismGoerliAddress + } ) { - return prepareWriteContract({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], + return getContract({ + abi: optimismMintableErc20FactoryOptimismGoerliABI, + address: optimismMintableErc20FactoryOptimismGoerliAddress[420], ...config, - } as unknown as PrepareWriteContractConfig) + }) } /** - * Wraps __{@link watchContractEvent}__ with `abi` set to __{@link systemConfigGoerliABI}__. + * Wraps __{@link getContract}__ with `abi` set to __{@link optimismMintableErc721FactoryABI}__. * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) + * [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000017) */ -export function watchSystemConfigGoerliEvent< - TAbi extends readonly unknown[] = typeof systemConfigGoerliABI, - TEventName extends string = string ->( - config: Omit< - WatchContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof systemConfigGoerliAddress }, - callback: WatchContractEventCallback +export function getOptimismMintableErc721Factory( + config: Omit & { + chainId?: keyof typeof optimismMintableErc721FactoryAddress + } ) { - return watchContractEvent( - { - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - ...config, - } as WatchContractEventConfig, - callback - ) + return getContract({ + abi: optimismMintableErc721FactoryABI, + address: optimismMintableErc721FactoryAddress[10], + ...config, + }) } /** - * Wraps __{@link getContract}__ with `abi` set to __{@link systemDictatorABI}__. + * Wraps __{@link getContract}__ with `abi` set to __{@link optimismMintableErc721FactoryOptimismGoerliABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000017) */ -export function getSystemDictator( +export function getOptimismMintableErc721FactoryOptimismGoerli( config: Omit & { - chainId?: keyof typeof systemDictatorAddress + chainId?: keyof typeof optimismMintableErc721FactoryOptimismGoerliAddress } ) { return getContract({ - abi: systemDictatorABI, - address: systemDictatorAddress[1], + abi: optimismMintableErc721FactoryOptimismGoerliABI, + address: optimismMintableErc721FactoryOptimismGoerliAddress[420], ...config, }) } /** - * Wraps __{@link readContract}__ with `abi` set to __{@link systemDictatorABI}__. + * Wraps __{@link getContract}__ with `abi` set to __{@link optimismPortalABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) */ -export function readSystemDictator< - TAbi extends readonly unknown[] = typeof systemDictatorABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof systemDictatorAddress +export function getOptimismPortal( + config: Omit & { + chainId?: keyof typeof optimismPortalAddress } ) { - return readContract({ - abi: systemDictatorABI, - address: systemDictatorAddress[1], + return getContract({ + abi: optimismPortalABI, + address: + optimismPortalAddress[ + config.chainId as keyof typeof optimismPortalAddress + ], ...config, - } as unknown as ReadContractConfig) + }) } /** - * Wraps __{@link writeContract}__ with `abi` set to __{@link systemDictatorABI}__. + * Wraps __{@link getContract}__ with `abi` set to __{@link optimistABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) */ -export function writeSystemDictator< - TFunctionName extends string, - TMode extends WriteContractMode, - TChainId extends number = keyof typeof systemDictatorAddress ->( - config: - | (Omit< - WriteContractPreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof systemDictatorAddress - }) - | (Omit< - WriteContractUnpreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof systemDictatorAddress - }) +export function getOptimist( + config: Omit & { + chainId?: keyof typeof optimistAddress + } ) { - return writeContract({ - abi: systemDictatorABI, - address: systemDictatorAddress[1], + return getContract({ + abi: optimistABI, + address: optimistAddress[config.chainId as keyof typeof optimistAddress], ...config, - } as unknown as WriteContractArgs) + }) } /** - * Wraps __{@link prepareWriteContract}__ with `abi` set to __{@link systemDictatorABI}__. + * Wraps __{@link getContract}__ with `abi` set to __{@link optimistAllowlistABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) */ -export function prepareWriteSystemDictator< - TAbi extends readonly unknown[] = typeof systemDictatorABI, - TFunctionName extends string = string ->( - config: Omit< - PrepareWriteContractConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof systemDictatorAddress } +export function getOptimistAllowlist( + config: Omit & { + chainId?: keyof typeof optimistAllowlistAddress + } ) { - return prepareWriteContract({ - abi: systemDictatorABI, - address: systemDictatorAddress[1], + return getContract({ + abi: optimistAllowlistABI, + address: + optimistAllowlistAddress[ + config.chainId as keyof typeof optimistAllowlistAddress + ], ...config, - } as unknown as PrepareWriteContractConfig) + }) } /** - * Wraps __{@link watchContractEvent}__ with `abi` set to __{@link systemDictatorABI}__. + * Wraps __{@link getContract}__ with `abi` set to __{@link optimistInviterABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) */ -export function watchSystemDictatorEvent< - TAbi extends readonly unknown[] = typeof systemDictatorABI, - TEventName extends string = string ->( - config: Omit< - WatchContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof systemDictatorAddress }, - callback: WatchContractEventCallback +export function getOptimistInviter( + config: Omit & { + chainId?: keyof typeof optimistInviterAddress + } ) { - return watchContractEvent( - { - abi: systemDictatorABI, - address: systemDictatorAddress[1], - ...config, - } as WatchContractEventConfig, - callback - ) + return getContract({ + abi: optimistInviterABI, + address: + optimistInviterAddress[ + config.chainId as keyof typeof optimistInviterAddress + ], + ...config, + }) } /** - * Wraps __{@link getContract}__ with `abi` set to __{@link systemDictatorGoerliABI}__. + * Wraps __{@link getContract}__ with `abi` set to __{@link portalSenderABI}__. * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x0A893d9576b9cFD9EF78595963dc973238E78210) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xe7FACd39531ee3C313330E93B4d7a8B8A3c84Aa4) */ -export function getSystemDictatorGoerli( +export function getPortalSender( config: Omit & { - chainId?: keyof typeof systemDictatorGoerliAddress + chainId?: keyof typeof portalSenderAddress } ) { return getContract({ - abi: systemDictatorGoerliABI, - address: systemDictatorGoerliAddress[5], + abi: portalSenderABI, + address: + portalSenderAddress[config.chainId as keyof typeof portalSenderAddress], ...config, }) } /** - * Wraps __{@link readContract}__ with `abi` set to __{@link systemDictatorGoerliABI}__. + * Wraps __{@link getContract}__ with `abi` set to __{@link protocolVersionsABI}__. * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) + * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) */ -export function readSystemDictatorGoerli< - TAbi extends readonly unknown[] = typeof systemDictatorGoerliABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof systemDictatorGoerliAddress +export function getProtocolVersions( + config: Omit & { + chainId?: keyof typeof protocolVersionsAddress } ) { - return readContract({ - abi: systemDictatorGoerliABI, - address: systemDictatorGoerliAddress[5], + return getContract({ + abi: protocolVersionsABI, + address: protocolVersionsAddress[5], ...config, - } as unknown as ReadContractConfig) + }) } /** - * Wraps __{@link writeContract}__ with `abi` set to __{@link systemDictatorGoerliABI}__. + * Wraps __{@link getContract}__ with `abi` set to __{@link proxyAdminABI}__. * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) */ -export function writeSystemDictatorGoerli< - TFunctionName extends string, - TMode extends WriteContractMode, - TChainId extends number = keyof typeof systemDictatorGoerliAddress ->( - config: - | (Omit< - WriteContractPreparedArgs< - typeof systemDictatorGoerliABI, - TFunctionName - >, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof systemDictatorGoerliAddress - }) - | (Omit< - WriteContractUnpreparedArgs< - typeof systemDictatorGoerliABI, - TFunctionName - >, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof systemDictatorGoerliAddress - }) +export function getProxyAdmin( + config: Omit & { + chainId?: keyof typeof proxyAdminAddress + } ) { - return writeContract({ - abi: systemDictatorGoerliABI, - address: systemDictatorGoerliAddress[5], + return getContract({ + abi: proxyAdminABI, + address: + proxyAdminAddress[config.chainId as keyof typeof proxyAdminAddress], ...config, - } as unknown as WriteContractArgs) + }) } /** - * Wraps __{@link prepareWriteContract}__ with `abi` set to __{@link systemDictatorGoerliABI}__. + * Wraps __{@link getContract}__ with `abi` set to __{@link schemaRegistryABI}__. * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x6232208d66bAc2305b46b4Cb6BCB3857B298DF13) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2545fa928d5d278cA75Fd47306e4a89096ff6403) */ -export function prepareWriteSystemDictatorGoerli< - TAbi extends readonly unknown[] = typeof systemDictatorGoerliABI, - TFunctionName extends string = string ->( - config: Omit< - PrepareWriteContractConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof systemDictatorGoerliAddress } +export function getSchemaRegistry( + config: Omit & { + chainId?: keyof typeof schemaRegistryAddress + } ) { - return prepareWriteContract({ - abi: systemDictatorGoerliABI, - address: systemDictatorGoerliAddress[5], + return getContract({ + abi: schemaRegistryABI, + address: + schemaRegistryAddress[ + config.chainId as keyof typeof schemaRegistryAddress + ], ...config, - } as unknown as PrepareWriteContractConfig) + }) } /** - * Wraps __{@link watchContractEvent}__ with `abi` set to __{@link systemDictatorGoerliABI}__. + * Wraps __{@link getContract}__ with `abi` set to __{@link sequencerFeeVaultABI}__. * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000011) */ -export function watchSystemDictatorGoerliEvent< - TAbi extends readonly unknown[] = typeof systemDictatorGoerliABI, - TEventName extends string = string ->( - config: Omit< - WatchContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof systemDictatorGoerliAddress }, - callback: WatchContractEventCallback +export function getSequencerFeeVault( + config: Omit & { + chainId?: keyof typeof sequencerFeeVaultAddress + } ) { - return watchContractEvent( - { - abi: systemDictatorGoerliABI, - address: systemDictatorGoerliAddress[5], - ...config, - } as WatchContractEventConfig, - callback - ) + return getContract({ + abi: sequencerFeeVaultABI, + address: sequencerFeeVaultAddress[420], + ...config, + }) } /** - * Wraps __{@link getContract}__ with `abi` set to __{@link teleportrWithdrawerABI}__. + * Wraps __{@link getContract}__ with `abi` set to __{@link systemConfigABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) */ -export function getTeleportrWithdrawer( +export function getSystemConfig( config: Omit & { - chainId?: keyof typeof teleportrWithdrawerAddress + chainId?: keyof typeof systemConfigAddress } ) { return getContract({ - abi: teleportrWithdrawerABI, - address: teleportrWithdrawerAddress[1], + abi: systemConfigABI, + address: + systemConfigAddress[config.chainId as keyof typeof systemConfigAddress], ...config, }) } /** - * Wraps __{@link readContract}__ with `abi` set to __{@link teleportrWithdrawerABI}__. + * Wraps __{@link getContract}__ with `abi` set to __{@link systemDictatorABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) + * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) */ -export function readTeleportrWithdrawer< - TAbi extends readonly unknown[] = typeof teleportrWithdrawerABI, - TFunctionName extends string = string ->( - config: Omit, 'abi' | 'address'> & { - chainId?: keyof typeof teleportrWithdrawerAddress +export function getSystemDictator( + config: Omit & { + chainId?: keyof typeof systemDictatorAddress } ) { - return readContract({ - abi: teleportrWithdrawerABI, - address: teleportrWithdrawerAddress[1], + return getContract({ + abi: systemDictatorABI, + address: systemDictatorAddress[1], ...config, - } as unknown as ReadContractConfig) + }) } /** - * Wraps __{@link writeContract}__ with `abi` set to __{@link teleportrWithdrawerABI}__. + * Wraps __{@link getContract}__ with `abi` set to __{@link systemDictatorGoerliABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) + * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) */ -export function writeTeleportrWithdrawer< - TFunctionName extends string, - TMode extends WriteContractMode, - TChainId extends number = keyof typeof teleportrWithdrawerAddress ->( - config: - | (Omit< - WriteContractPreparedArgs, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof teleportrWithdrawerAddress - }) - | (Omit< - WriteContractUnpreparedArgs< - typeof teleportrWithdrawerABI, - TFunctionName - >, - 'abi' | 'address' - > & { - mode: TMode - chainId?: TMode extends 'prepared' - ? TChainId - : keyof typeof teleportrWithdrawerAddress - }) +export function getSystemDictatorGoerli( + config: Omit & { + chainId?: keyof typeof systemDictatorGoerliAddress + } ) { - return writeContract({ - abi: teleportrWithdrawerABI, - address: teleportrWithdrawerAddress[1], + return getContract({ + abi: systemDictatorGoerliABI, + address: systemDictatorGoerliAddress[5], ...config, - } as unknown as WriteContractArgs) + }) } /** - * Wraps __{@link prepareWriteContract}__ with `abi` set to __{@link teleportrWithdrawerABI}__. + * Wraps __{@link getContract}__ with `abi` set to __{@link teleportrWithdrawerABI}__. * * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) */ -export function prepareWriteTeleportrWithdrawer< - TAbi extends readonly unknown[] = typeof teleportrWithdrawerABI, - TFunctionName extends string = string ->( - config: Omit< - PrepareWriteContractConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof teleportrWithdrawerAddress } +export function getTeleportrWithdrawer( + config: Omit & { + chainId?: keyof typeof teleportrWithdrawerAddress + } ) { - return prepareWriteContract({ + return getContract({ abi: teleportrWithdrawerABI, address: teleportrWithdrawerAddress[1], ...config, - } as unknown as PrepareWriteContractConfig) -} - -/** - * Wraps __{@link watchContractEvent}__ with `abi` set to __{@link teleportrWithdrawerABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) - */ -export function watchTeleportrWithdrawerEvent< - TAbi extends readonly unknown[] = typeof teleportrWithdrawerABI, - TEventName extends string = string ->( - config: Omit< - WatchContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof teleportrWithdrawerAddress }, - callback: WatchContractEventCallback -) { - return watchContractEvent( - { - abi: teleportrWithdrawerABI, - address: teleportrWithdrawerAddress[1], - ...config, - } as WatchContractEventConfig, - callback - ) + }) } diff --git a/packages/contracts-ts/src/constants.ts b/packages/contracts-ts/src/constants.ts index 0ab3d39ab18f4..42c9cf74f63a9 100644 --- a/packages/contracts-ts/src/constants.ts +++ b/packages/contracts-ts/src/constants.ts @@ -2781,20 +2781,11 @@ export const l1BlockConfig = { ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) */ export const l1CrossDomainMessengerABI = [ - { - stateMutability: 'nonpayable', - type: 'constructor', - inputs: [ - { - name: '_portal', - internalType: 'contract OptimismPortal', - type: 'address', - }, - ], - }, + { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, { type: 'event', anonymous: false, @@ -2972,7 +2963,13 @@ export const l1CrossDomainMessengerABI = [ { stateMutability: 'nonpayable', type: 'function', - inputs: [], + inputs: [ + { + name: '_portal', + internalType: 'contract OptimismPortal', + type: 'address', + }, + ], name: 'initialize', outputs: [], }, @@ -2983,6 +2980,13 @@ export const l1CrossDomainMessengerABI = [ name: 'messageNonce', outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'portal', + outputs: [{ name: '', internalType: 'address', type: 'address' }], + }, { stateMutability: 'payable', type: 'function', @@ -3032,14 +3036,17 @@ export const l1CrossDomainMessengerABI = [ ] as const /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) */ export const l1CrossDomainMessengerAddress = { 1: '0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1', + 5: '0x5086d1eEF304eb5284A0f6720f79403b4e9bE294', } as const /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) */ export const l1CrossDomainMessengerConfig = { address: l1CrossDomainMessengerAddress, @@ -3047,195 +3054,168 @@ export const l1CrossDomainMessengerConfig = { } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// L1CrossDomainMessenger_goerli +// L1ERC721Bridge ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5a7749f83b81B301cAb5f48EB8516B986DAef23D) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9) */ -export const l1CrossDomainMessengerGoerliABI = [ +export const l1Erc721BridgeABI = [ { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, { type: 'event', anonymous: false, inputs: [ { - name: 'msgHash', - internalType: 'bytes32', - type: 'bytes32', - indexed: true, - }, - ], - name: 'FailedRelayedMessage', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, - ], - name: 'Initialized', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'msgHash', - internalType: 'bytes32', - type: 'bytes32', - indexed: true, - }, - ], - name: 'RelayedMessage', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'target', + name: 'localToken', internalType: 'address', type: 'address', indexed: true, }, { - name: 'sender', + name: 'remoteToken', internalType: 'address', type: 'address', - indexed: false, + indexed: true, }, - { name: 'message', internalType: 'bytes', type: 'bytes', indexed: false }, + { name: 'from', internalType: 'address', type: 'address', indexed: true }, + { name: 'to', internalType: 'address', type: 'address', indexed: false }, { - name: 'messageNonce', + name: 'tokenId', internalType: 'uint256', type: 'uint256', indexed: false, }, { - name: 'gasLimit', - internalType: 'uint256', - type: 'uint256', + name: 'extraData', + internalType: 'bytes', + type: 'bytes', indexed: false, }, ], - name: 'SentMessage', + name: 'ERC721BridgeFinalized', }, { type: 'event', anonymous: false, inputs: [ { - name: 'sender', + name: 'localToken', internalType: 'address', type: 'address', indexed: true, }, { - name: 'value', + name: 'remoteToken', + internalType: 'address', + type: 'address', + indexed: true, + }, + { name: 'from', internalType: 'address', type: 'address', indexed: true }, + { name: 'to', internalType: 'address', type: 'address', indexed: false }, + { + name: 'tokenId', internalType: 'uint256', type: 'uint256', indexed: false, }, + { + name: 'extraData', + internalType: 'bytes', + type: 'bytes', + indexed: false, + }, ], - name: 'SentMessageExtension1', - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'MESSAGE_VERSION', - outputs: [{ name: '', internalType: 'uint16', type: 'uint16' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'MIN_GAS_CALLDATA_OVERHEAD', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'MIN_GAS_DYNAMIC_OVERHEAD_DENOMINATOR', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'MIN_GAS_DYNAMIC_OVERHEAD_NUMERATOR', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + name: 'ERC721BridgeInitiated', }, { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'OTHER_MESSENGER', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + type: 'event', + anonymous: false, + inputs: [ + { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, + ], + name: 'Initialized', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'PORTAL', + name: 'MESSENGER', outputs: [ - { name: '', internalType: 'contract OptimismPortal', type: 'address' }, + { + name: '', + internalType: 'contract CrossDomainMessenger', + type: 'address', + }, ], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'RELAY_CALL_OVERHEAD', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + name: 'OTHER_BRIDGE', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'RELAY_CONSTANT_OVERHEAD', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + inputs: [ + { name: '_localToken', internalType: 'address', type: 'address' }, + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'bridgeERC721', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'RELAY_GAS_CHECK_BUFFER', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + inputs: [ + { name: '_localToken', internalType: 'address', type: 'address' }, + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'bridgeERC721To', + outputs: [], }, { stateMutability: 'view', type: 'function', - inputs: [], - name: 'RELAY_RESERVED_GAS', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], - }, - { - stateMutability: 'pure', - type: 'function', inputs: [ - { name: '_message', internalType: 'bytes', type: 'bytes' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '', internalType: 'address', type: 'address' }, + { name: '', internalType: 'address', type: 'address' }, + { name: '', internalType: 'uint256', type: 'uint256' }, ], - name: 'baseGas', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + name: 'deposits', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - name: 'failedMessages', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + inputs: [ + { name: '_localToken', internalType: 'address', type: 'address' }, + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_from', internalType: 'address', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'finalizeBridgeERC721', + outputs: [], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ { - name: '_portal', - internalType: 'contract OptimismPortal', + name: '_messenger', + internalType: 'contract CrossDomainMessenger', type: 'address', }, ], @@ -3246,48 +3226,22 @@ export const l1CrossDomainMessengerGoerliABI = [ stateMutability: 'view', type: 'function', inputs: [], - name: 'messageNonce', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'messenger', + outputs: [ + { + name: '', + internalType: 'contract CrossDomainMessenger', + type: 'address', + }, + ], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'portal', + name: 'otherBridge', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, - { - stateMutability: 'payable', - type: 'function', - inputs: [ - { name: '_nonce', internalType: 'uint256', type: 'uint256' }, - { name: '_sender', internalType: 'address', type: 'address' }, - { name: '_target', internalType: 'address', type: 'address' }, - { name: '_value', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint256', type: 'uint256' }, - { name: '_message', internalType: 'bytes', type: 'bytes' }, - ], - name: 'relayMessage', - outputs: [], - }, - { - stateMutability: 'payable', - type: 'function', - inputs: [ - { name: '_target', internalType: 'address', type: 'address' }, - { name: '_message', internalType: 'bytes', type: 'bytes' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - ], - name: 'sendMessage', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - name: 'successfulMessages', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], - }, { stateMutability: 'view', type: 'function', @@ -3295,236 +3249,121 @@ export const l1CrossDomainMessengerGoerliABI = [ name: 'version', outputs: [{ name: '', internalType: 'string', type: 'string' }], }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'xDomainMessageSender', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, ] as const /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5a7749f83b81B301cAb5f48EB8516B986DAef23D) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9) */ -export const l1CrossDomainMessengerGoerliAddress = { - 5: '0x5086d1eEF304eb5284A0f6720f79403b4e9bE294', +export const l1Erc721BridgeAddress = { + 1: '0x5a7749f83b81B301cAb5f48EB8516B986DAef23D', + 5: '0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9', } as const /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5a7749f83b81B301cAb5f48EB8516B986DAef23D) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9) */ -export const l1CrossDomainMessengerGoerliConfig = { - address: l1CrossDomainMessengerGoerliAddress, - abi: l1CrossDomainMessengerGoerliABI, +export const l1Erc721BridgeConfig = { + address: l1Erc721BridgeAddress, + abi: l1Erc721BridgeABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// L1ERC721Bridge +// L1FeeVault ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5a7749f83b81B301cAb5f48EB8516B986DAef23D) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000001a) */ -export const l1Erc721BridgeABI = [ +export const l1FeeVaultABI = [ { stateMutability: 'nonpayable', type: 'constructor', - inputs: [ - { name: '_messenger', internalType: 'address', type: 'address' }, - { name: '_otherBridge', internalType: 'address', type: 'address' }, - ], + inputs: [{ name: '_recipient', internalType: 'address', type: 'address' }], }, { type: 'event', anonymous: false, inputs: [ { - name: 'localToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'remoteToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: false }, - { - name: 'tokenId', + name: 'value', internalType: 'uint256', type: 'uint256', indexed: false, }, + { name: 'to', internalType: 'address', type: 'address', indexed: false }, { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, - }, - ], - name: 'ERC721BridgeFinalized', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'localToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'remoteToken', + name: 'from', internalType: 'address', type: 'address', - indexed: true, - }, - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: false }, - { - name: 'tokenId', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', indexed: false, }, ], - name: 'ERC721BridgeInitiated', + name: 'Withdrawal', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'MESSENGER', - outputs: [ - { - name: '', - internalType: 'contract CrossDomainMessenger', - type: 'address', - }, - ], + name: 'MIN_WITHDRAWAL_AMOUNT', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'OTHER_BRIDGE', + name: 'RECIPIENT', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'bridgeERC721', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'bridgeERC721To', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [ - { name: '', internalType: 'address', type: 'address' }, - { name: '', internalType: 'address', type: 'address' }, - { name: '', internalType: 'uint256', type: 'uint256' }, - ], - name: 'deposits', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_from', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'finalizeBridgeERC721', - outputs: [], - }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'messenger', - outputs: [ - { - name: '', - internalType: 'contract CrossDomainMessenger', - type: 'address', - }, - ], + name: 'totalProcessed', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'otherBridge', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'version', + outputs: [{ name: '', internalType: 'string', type: 'string' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + name: 'withdraw', + outputs: [], }, + { stateMutability: 'payable', type: 'receive' }, ] as const /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5a7749f83b81B301cAb5f48EB8516B986DAef23D) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000001a) */ -export const l1Erc721BridgeAddress = { - 1: '0x5a7749f83b81B301cAb5f48EB8516B986DAef23D', +export const l1FeeVaultAddress = { + 420: '0x420000000000000000000000000000000000001A', } as const /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5a7749f83b81B301cAb5f48EB8516B986DAef23D) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000001a) */ -export const l1Erc721BridgeConfig = { - address: l1Erc721BridgeAddress, - abi: l1Erc721BridgeABI, +export const l1FeeVaultConfig = { + address: l1FeeVaultAddress, + abi: l1FeeVaultABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// L1ERC721Bridge_goerli +// L1StandardBridge ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) */ -export const l1Erc721BridgeGoerliABI = [ +export const l1StandardBridgeABI = [ { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, { type: 'event', @@ -3545,7 +3384,7 @@ export const l1Erc721BridgeGoerliABI = [ { name: 'from', internalType: 'address', type: 'address', indexed: true }, { name: 'to', internalType: 'address', type: 'address', indexed: false }, { - name: 'tokenId', + name: 'amount', internalType: 'uint256', type: 'uint256', indexed: false, @@ -3557,7 +3396,7 @@ export const l1Erc721BridgeGoerliABI = [ indexed: false, }, ], - name: 'ERC721BridgeFinalized', + name: 'ERC20BridgeFinalized', }, { type: 'event', @@ -3578,7 +3417,7 @@ export const l1Erc721BridgeGoerliABI = [ { name: 'from', internalType: 'address', type: 'address', indexed: true }, { name: 'to', internalType: 'address', type: 'address', indexed: false }, { - name: 'tokenId', + name: 'amount', internalType: 'uint256', type: 'uint256', indexed: false, @@ -3590,35 +3429,187 @@ export const l1Erc721BridgeGoerliABI = [ indexed: false, }, ], - name: 'ERC721BridgeInitiated', + name: 'ERC20BridgeInitiated', }, { type: 'event', anonymous: false, inputs: [ - { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, + { + name: 'l1Token', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'l2Token', + internalType: 'address', + type: 'address', + indexed: true, + }, + { name: 'from', internalType: 'address', type: 'address', indexed: true }, + { name: 'to', internalType: 'address', type: 'address', indexed: false }, + { + name: 'amount', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + { + name: 'extraData', + internalType: 'bytes', + type: 'bytes', + indexed: false, + }, ], - name: 'Initialized', + name: 'ERC20DepositInitiated', }, { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'MESSENGER', - outputs: [ + type: 'event', + anonymous: false, + inputs: [ { - name: '', - internalType: 'contract CrossDomainMessenger', + name: 'l1Token', + internalType: 'address', type: 'address', + indexed: true, + }, + { + name: 'l2Token', + internalType: 'address', + type: 'address', + indexed: true, + }, + { name: 'from', internalType: 'address', type: 'address', indexed: true }, + { name: 'to', internalType: 'address', type: 'address', indexed: false }, + { + name: 'amount', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + { + name: 'extraData', + internalType: 'bytes', + type: 'bytes', + indexed: false, }, ], + name: 'ERC20WithdrawalFinalized', }, { - stateMutability: 'view', - type: 'function', + type: 'event', + anonymous: false, + inputs: [ + { name: 'from', internalType: 'address', type: 'address', indexed: true }, + { name: 'to', internalType: 'address', type: 'address', indexed: true }, + { + name: 'amount', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + { + name: 'extraData', + internalType: 'bytes', + type: 'bytes', + indexed: false, + }, + ], + name: 'ETHBridgeFinalized', + }, + { + type: 'event', + anonymous: false, + inputs: [ + { name: 'from', internalType: 'address', type: 'address', indexed: true }, + { name: 'to', internalType: 'address', type: 'address', indexed: true }, + { + name: 'amount', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + { + name: 'extraData', + internalType: 'bytes', + type: 'bytes', + indexed: false, + }, + ], + name: 'ETHBridgeInitiated', + }, + { + type: 'event', + anonymous: false, + inputs: [ + { name: 'from', internalType: 'address', type: 'address', indexed: true }, + { name: 'to', internalType: 'address', type: 'address', indexed: true }, + { + name: 'amount', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + { + name: 'extraData', + internalType: 'bytes', + type: 'bytes', + indexed: false, + }, + ], + name: 'ETHDepositInitiated', + }, + { + type: 'event', + anonymous: false, + inputs: [ + { name: 'from', internalType: 'address', type: 'address', indexed: true }, + { name: 'to', internalType: 'address', type: 'address', indexed: true }, + { + name: 'amount', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + { + name: 'extraData', + internalType: 'bytes', + type: 'bytes', + indexed: false, + }, + ], + name: 'ETHWithdrawalFinalized', + }, + { + type: 'event', + anonymous: false, + inputs: [ + { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, + ], + name: 'Initialized', + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'MESSENGER', + outputs: [ + { + name: '', + internalType: 'contract CrossDomainMessenger', + type: 'address', + }, + ], + }, + { + stateMutability: 'view', + type: 'function', inputs: [], name: 'OTHER_BRIDGE', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + outputs: [ + { name: '', internalType: 'contract StandardBridge', type: 'address' }, + ], }, { stateMutability: 'nonpayable', @@ -3626,11 +3617,11 @@ export const l1Erc721BridgeGoerliABI = [ inputs: [ { name: '_localToken', internalType: 'address', type: 'address' }, { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, { name: '_extraData', internalType: 'bytes', type: 'bytes' }, ], - name: 'bridgeERC721', + name: 'bridgeERC20', outputs: [], }, { @@ -3640,11 +3631,80 @@ export const l1Erc721BridgeGoerliABI = [ { name: '_localToken', internalType: 'address', type: 'address' }, { name: '_remoteToken', internalType: 'address', type: 'address' }, { name: '_to', internalType: 'address', type: 'address' }, - { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, { name: '_extraData', internalType: 'bytes', type: 'bytes' }, ], - name: 'bridgeERC721To', + name: 'bridgeERC20To', + outputs: [], + }, + { + stateMutability: 'payable', + type: 'function', + inputs: [ + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'bridgeETH', + outputs: [], + }, + { + stateMutability: 'payable', + type: 'function', + inputs: [ + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'bridgeETHTo', + outputs: [], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { name: '_l1Token', internalType: 'address', type: 'address' }, + { name: '_l2Token', internalType: 'address', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'depositERC20', + outputs: [], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { name: '_l1Token', internalType: 'address', type: 'address' }, + { name: '_l2Token', internalType: 'address', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'depositERC20To', + outputs: [], + }, + { + stateMutability: 'payable', + type: 'function', + inputs: [ + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'depositETH', + outputs: [], + }, + { + stateMutability: 'payable', + type: 'function', + inputs: [ + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'depositETHTo', outputs: [], }, { @@ -3653,10 +3713,9 @@ export const l1Erc721BridgeGoerliABI = [ inputs: [ { name: '', internalType: 'address', type: 'address' }, { name: '', internalType: 'address', type: 'address' }, - { name: '', internalType: 'uint256', type: 'uint256' }, ], name: 'deposits', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'nonpayable', @@ -3666,10 +3725,48 @@ export const l1Erc721BridgeGoerliABI = [ { name: '_remoteToken', internalType: 'address', type: 'address' }, { name: '_from', internalType: 'address', type: 'address' }, { name: '_to', internalType: 'address', type: 'address' }, - { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, { name: '_extraData', internalType: 'bytes', type: 'bytes' }, ], - name: 'finalizeBridgeERC721', + name: 'finalizeBridgeERC20', + outputs: [], + }, + { + stateMutability: 'payable', + type: 'function', + inputs: [ + { name: '_from', internalType: 'address', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'finalizeBridgeETH', + outputs: [], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { name: '_l1Token', internalType: 'address', type: 'address' }, + { name: '_l2Token', internalType: 'address', type: 'address' }, + { name: '_from', internalType: 'address', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'finalizeERC20Withdrawal', + outputs: [], + }, + { + stateMutability: 'payable', + type: 'function', + inputs: [ + { name: '_from', internalType: 'address', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'finalizeETHWithdrawal', outputs: [], }, { @@ -3685,6 +3782,13 @@ export const l1Erc721BridgeGoerliABI = [ name: 'initialize', outputs: [], }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'l2TokenBridge', + outputs: [{ name: '', internalType: 'address', type: 'address' }], + }, { stateMutability: 'view', type: 'function', @@ -3703,7 +3807,9 @@ export const l1Erc721BridgeGoerliABI = [ type: 'function', inputs: [], name: 'otherBridge', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + outputs: [ + { name: '', internalType: 'contract StandardBridge', type: 'address' }, + ], }, { stateMutability: 'view', @@ -3712,77 +3818,264 @@ export const l1Erc721BridgeGoerliABI = [ name: 'version', outputs: [{ name: '', internalType: 'string', type: 'string' }], }, + { stateMutability: 'payable', type: 'receive' }, ] as const /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) */ -export const l1Erc721BridgeGoerliAddress = { - 5: '0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9', +export const l1StandardBridgeAddress = { + 1: '0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1', + 5: '0x636Af16bf2f682dD3109e60102b8E1A089FedAa8', } as const /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) */ -export const l1Erc721BridgeGoerliConfig = { - address: l1Erc721BridgeGoerliAddress, - abi: l1Erc721BridgeGoerliABI, +export const l1StandardBridgeConfig = { + address: l1StandardBridgeAddress, + abi: l1StandardBridgeABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// L1FeeVault +// L2CrossDomainMessenger ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000001a) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) */ -export const l1FeeVaultABI = [ +export const l2CrossDomainMessengerABI = [ { stateMutability: 'nonpayable', type: 'constructor', - inputs: [{ name: '_recipient', internalType: 'address', type: 'address' }], + inputs: [ + { + name: '_l1CrossDomainMessenger', + internalType: 'address', + type: 'address', + }, + ], }, { type: 'event', anonymous: false, inputs: [ { - name: 'value', + name: 'msgHash', + internalType: 'bytes32', + type: 'bytes32', + indexed: true, + }, + ], + name: 'FailedRelayedMessage', + }, + { + type: 'event', + anonymous: false, + inputs: [ + { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, + ], + name: 'Initialized', + }, + { + type: 'event', + anonymous: false, + inputs: [ + { + name: 'msgHash', + internalType: 'bytes32', + type: 'bytes32', + indexed: true, + }, + ], + name: 'RelayedMessage', + }, + { + type: 'event', + anonymous: false, + inputs: [ + { + name: 'target', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'sender', + internalType: 'address', + type: 'address', + indexed: false, + }, + { name: 'message', internalType: 'bytes', type: 'bytes', indexed: false }, + { + name: 'messageNonce', internalType: 'uint256', type: 'uint256', indexed: false, }, - { name: 'to', internalType: 'address', type: 'address', indexed: false }, { - name: 'from', + name: 'gasLimit', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + ], + name: 'SentMessage', + }, + { + type: 'event', + anonymous: false, + inputs: [ + { + name: 'sender', internalType: 'address', type: 'address', + indexed: true, + }, + { + name: 'value', + internalType: 'uint256', + type: 'uint256', indexed: false, }, ], - name: 'Withdrawal', + name: 'SentMessageExtension1', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'MIN_WITHDRAWAL_AMOUNT', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'MESSAGE_VERSION', + outputs: [{ name: '', internalType: 'uint16', type: 'uint16' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'RECIPIENT', + name: 'MIN_GAS_CALLDATA_OVERHEAD', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'MIN_GAS_DYNAMIC_OVERHEAD_DENOMINATOR', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'MIN_GAS_DYNAMIC_OVERHEAD_NUMERATOR', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'OTHER_MESSENGER', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'totalProcessed', + name: 'RELAY_CALL_OVERHEAD', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'RELAY_CONSTANT_OVERHEAD', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'RELAY_GAS_CHECK_BUFFER', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'RELAY_RESERVED_GAS', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + }, + { + stateMutability: 'pure', + type: 'function', + inputs: [ + { name: '_message', internalType: 'bytes', type: 'bytes' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + ], + name: 'baseGas', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'failedMessages', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [], + name: 'initialize', + outputs: [], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'l1CrossDomainMessenger', + outputs: [{ name: '', internalType: 'address', type: 'address' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'messageNonce', outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, + { + stateMutability: 'payable', + type: 'function', + inputs: [ + { name: '_nonce', internalType: 'uint256', type: 'uint256' }, + { name: '_sender', internalType: 'address', type: 'address' }, + { name: '_target', internalType: 'address', type: 'address' }, + { name: '_value', internalType: 'uint256', type: 'uint256' }, + { name: '_minGasLimit', internalType: 'uint256', type: 'uint256' }, + { name: '_message', internalType: 'bytes', type: 'bytes' }, + ], + name: 'relayMessage', + outputs: [], + }, + { + stateMutability: 'payable', + type: 'function', + inputs: [ + { name: '_target', internalType: 'address', type: 'address' }, + { name: '_message', internalType: 'bytes', type: 'bytes' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + ], + name: 'sendMessage', + outputs: [], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'successfulMessages', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + }, { stateMutability: 'view', type: 'function', @@ -3791,43 +4084,43 @@ export const l1FeeVaultABI = [ outputs: [{ name: '', internalType: 'string', type: 'string' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', inputs: [], - name: 'withdraw', - outputs: [], + name: 'xDomainMessageSender', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, - { stateMutability: 'payable', type: 'receive' }, ] as const /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000001a) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) */ -export const l1FeeVaultAddress = { - 420: '0x420000000000000000000000000000000000001A', +export const l2CrossDomainMessengerAddress = { + 420: '0x4200000000000000000000000000000000000007', } as const /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000001a) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) */ -export const l1FeeVaultConfig = { - address: l1FeeVaultAddress, - abi: l1FeeVaultABI, +export const l2CrossDomainMessengerConfig = { + address: l2CrossDomainMessengerAddress, + abi: l2CrossDomainMessengerABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// L1StandardBridge +// L2ERC721Bridge ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) + * [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000014) */ -export const l1StandardBridgeABI = [ +export const l2Erc721BridgeABI = [ { stateMutability: 'nonpayable', type: 'constructor', inputs: [ - { name: '_messenger', internalType: 'address payable', type: 'address' }, + { name: '_messenger', internalType: 'address', type: 'address' }, + { name: '_otherBridge', internalType: 'address', type: 'address' }, ], }, { @@ -3849,7 +4142,7 @@ export const l1StandardBridgeABI = [ { name: 'from', internalType: 'address', type: 'address', indexed: true }, { name: 'to', internalType: 'address', type: 'address', indexed: false }, { - name: 'amount', + name: 'tokenId', internalType: 'uint256', type: 'uint256', indexed: false, @@ -3861,7 +4154,7 @@ export const l1StandardBridgeABI = [ indexed: false, }, ], - name: 'ERC20BridgeFinalized', + name: 'ERC721BridgeFinalized', }, { type: 'event', @@ -3882,7 +4175,7 @@ export const l1StandardBridgeABI = [ { name: 'from', internalType: 'address', type: 'address', indexed: true }, { name: 'to', internalType: 'address', type: 'address', indexed: false }, { - name: 'amount', + name: 'tokenId', internalType: 'uint256', type: 'uint256', indexed: false, @@ -3894,53 +4187,121 @@ export const l1StandardBridgeABI = [ indexed: false, }, ], - name: 'ERC20BridgeInitiated', + name: 'ERC721BridgeInitiated', }, { - type: 'event', - anonymous: false, + stateMutability: 'nonpayable', + type: 'function', inputs: [ + { name: '_localToken', internalType: 'address', type: 'address' }, + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'bridgeERC721', + outputs: [], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { name: '_localToken', internalType: 'address', type: 'address' }, + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'bridgeERC721To', + outputs: [], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { name: '_localToken', internalType: 'address', type: 'address' }, + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_from', internalType: 'address', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'finalizeBridgeERC721', + outputs: [], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'messenger', + outputs: [ { - name: 'l1Token', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'l2Token', - internalType: 'address', - type: 'address', - indexed: true, - }, - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: false }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, + name: '', + internalType: 'contract CrossDomainMessenger', + type: 'address', }, ], - name: 'ERC20DepositInitiated', + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'otherBridge', + outputs: [{ name: '', internalType: 'address', type: 'address' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'version', + outputs: [{ name: '', internalType: 'string', type: 'string' }], + }, +] as const + +/** + * [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000014) + */ +export const l2Erc721BridgeAddress = { + 10: '0x4200000000000000000000000000000000000014', +} as const + +/** + * [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000014) + */ +export const l2Erc721BridgeConfig = { + address: l2Erc721BridgeAddress, + abi: l2Erc721BridgeABI, +} as const + +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// L2ERC721Bridge_optimism-goerli +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/** + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000014) + */ +export const l2Erc721BridgeOptimismGoerliABI = [ + { + stateMutability: 'nonpayable', + type: 'constructor', + inputs: [ + { name: '_messenger', internalType: 'address', type: 'address' }, + { name: '_otherBridge', internalType: 'address', type: 'address' }, + ], }, { type: 'event', anonymous: false, inputs: [ { - name: 'l1Token', + name: 'localToken', internalType: 'address', type: 'address', indexed: true, }, { - name: 'l2Token', + name: 'remoteToken', internalType: 'address', type: 'address', indexed: true, @@ -3948,49 +4309,7 @@ export const l1StandardBridgeABI = [ { name: 'from', internalType: 'address', type: 'address', indexed: true }, { name: 'to', internalType: 'address', type: 'address', indexed: false }, { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, - }, - ], - name: 'ERC20WithdrawalFinalized', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, - }, - ], - name: 'ETHBridgeFinalized', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, - { - name: 'amount', + name: 'tokenId', internalType: 'uint256', type: 'uint256', indexed: false, @@ -4002,37 +4321,28 @@ export const l1StandardBridgeABI = [ indexed: false, }, ], - name: 'ETHBridgeInitiated', + name: 'ERC721BridgeFinalized', }, { type: 'event', anonymous: false, inputs: [ - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, + name: 'localToken', + internalType: 'address', + type: 'address', + indexed: true, }, { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, + name: 'remoteToken', + internalType: 'address', + type: 'address', + indexed: true, }, - ], - name: 'ETHDepositInitiated', - }, - { - type: 'event', - anonymous: false, - inputs: [ { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, + { name: 'to', internalType: 'address', type: 'address', indexed: false }, { - name: 'amount', + name: 'tokenId', internalType: 'uint256', type: 'uint256', indexed: false, @@ -4044,7 +4354,7 @@ export const l1StandardBridgeABI = [ indexed: false, }, ], - name: 'ETHWithdrawalFinalized', + name: 'ERC721BridgeInitiated', }, { stateMutability: 'view', @@ -4064,9 +4374,7 @@ export const l1StandardBridgeABI = [ type: 'function', inputs: [], name: 'OTHER_BRIDGE', - outputs: [ - { name: '', internalType: 'contract StandardBridge', type: 'address' }, - ], + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'nonpayable', @@ -4074,11 +4382,11 @@ export const l1StandardBridgeABI = [ inputs: [ { name: '_localToken', internalType: 'address', type: 'address' }, { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, + { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, { name: '_extraData', internalType: 'bytes', type: 'bytes' }, ], - name: 'bridgeERC20', + name: 'bridgeERC721', outputs: [], }, { @@ -4088,643 +4396,357 @@ export const l1StandardBridgeABI = [ { name: '_localToken', internalType: 'address', type: 'address' }, { name: '_remoteToken', internalType: 'address', type: 'address' }, { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'bridgeERC20To', - outputs: [], - }, - { - stateMutability: 'payable', - type: 'function', - inputs: [ + { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, { name: '_extraData', internalType: 'bytes', type: 'bytes' }, ], - name: 'bridgeETH', + name: 'bridgeERC721To', outputs: [], }, { - stateMutability: 'payable', + stateMutability: 'nonpayable', type: 'function', inputs: [ + { name: '_localToken', internalType: 'address', type: 'address' }, + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_from', internalType: 'address', type: 'address' }, { name: '_to', internalType: 'address', type: 'address' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, { name: '_extraData', internalType: 'bytes', type: 'bytes' }, ], - name: 'bridgeETHTo', + name: 'finalizeBridgeERC721', outputs: [], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_l1Token', internalType: 'address', type: 'address' }, - { name: '_l2Token', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + inputs: [], + name: 'messenger', + outputs: [ + { + name: '', + internalType: 'contract CrossDomainMessenger', + type: 'address', + }, ], - name: 'depositERC20', - outputs: [], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_l1Token', internalType: 'address', type: 'address' }, - { name: '_l2Token', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'depositERC20To', - outputs: [], + inputs: [], + name: 'otherBridge', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'payable', - type: 'function', - inputs: [ - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'depositETH', - outputs: [], - }, - { - stateMutability: 'payable', - type: 'function', - inputs: [ - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'depositETHTo', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [ - { name: '', internalType: 'address', type: 'address' }, - { name: '', internalType: 'address', type: 'address' }, - ], - name: 'deposits', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_from', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'finalizeBridgeERC20', - outputs: [], - }, - { - stateMutability: 'payable', - type: 'function', - inputs: [ - { name: '_from', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'finalizeBridgeETH', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_l1Token', internalType: 'address', type: 'address' }, - { name: '_l2Token', internalType: 'address', type: 'address' }, - { name: '_from', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'finalizeERC20Withdrawal', - outputs: [], - }, - { - stateMutability: 'payable', - type: 'function', - inputs: [ - { name: '_from', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'finalizeETHWithdrawal', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'l2TokenBridge', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'messenger', - outputs: [ - { - name: '', - internalType: 'contract CrossDomainMessenger', - type: 'address', - }, - ], - }, - { - stateMutability: 'view', + stateMutability: 'view', type: 'function', inputs: [], name: 'version', outputs: [{ name: '', internalType: 'string', type: 'string' }], }, - { stateMutability: 'payable', type: 'receive' }, ] as const /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000014) */ -export const l1StandardBridgeAddress = { - 1: '0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1', +export const l2Erc721BridgeOptimismGoerliAddress = { + 420: '0x4200000000000000000000000000000000000014', } as const /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000014) */ -export const l1StandardBridgeConfig = { - address: l1StandardBridgeAddress, - abi: l1StandardBridgeABI, +export const l2Erc721BridgeOptimismGoerliConfig = { + address: l2Erc721BridgeOptimismGoerliAddress, + abi: l2Erc721BridgeOptimismGoerliABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// L1StandardBridge_goerli +// L2OutputOracle ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) */ -export const l1StandardBridgeGoerliABI = [ - { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, +export const l2OutputOracleABI = [ { - type: 'event', - anonymous: false, + stateMutability: 'nonpayable', + type: 'constructor', inputs: [ + { name: '_submissionInterval', internalType: 'uint256', type: 'uint256' }, + { name: '_l2BlockTime', internalType: 'uint256', type: 'uint256' }, { - name: 'localToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'remoteToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: false }, - { - name: 'amount', + name: '_finalizationPeriodSeconds', internalType: 'uint256', type: 'uint256', - indexed: false, - }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, }, ], - name: 'ERC20BridgeFinalized', }, { type: 'event', anonymous: false, inputs: [ - { - name: 'localToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'remoteToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: false }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, - }, + { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, ], - name: 'ERC20BridgeInitiated', + name: 'Initialized', }, { type: 'event', anonymous: false, inputs: [ { - name: 'l1Token', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'l2Token', - internalType: 'address', - type: 'address', + name: 'outputRoot', + internalType: 'bytes32', + type: 'bytes32', indexed: true, }, - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: false }, { - name: 'amount', + name: 'l2OutputIndex', internalType: 'uint256', type: 'uint256', - indexed: false, - }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, - }, - ], - name: 'ERC20DepositInitiated', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'l1Token', - internalType: 'address', - type: 'address', indexed: true, }, { - name: 'l2Token', - internalType: 'address', - type: 'address', + name: 'l2BlockNumber', + internalType: 'uint256', + type: 'uint256', indexed: true, }, - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: false }, { - name: 'amount', + name: 'l1Timestamp', internalType: 'uint256', type: 'uint256', indexed: false, }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, - }, ], - name: 'ERC20WithdrawalFinalized', + name: 'OutputProposed', }, { type: 'event', anonymous: false, inputs: [ - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, { - name: 'amount', + name: 'prevNextOutputIndex', internalType: 'uint256', type: 'uint256', - indexed: false, + indexed: true, }, { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, + name: 'newNextOutputIndex', + internalType: 'uint256', + type: 'uint256', + indexed: true, }, ], - name: 'ETHBridgeFinalized', + name: 'OutputsDeleted', }, { - type: 'event', - anonymous: false, - inputs: [ - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, - }, - ], - name: 'ETHBridgeInitiated', + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'CHALLENGER', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - type: 'event', - anonymous: false, - inputs: [ - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, - }, - ], - name: 'ETHDepositInitiated', + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'FINALIZATION_PERIOD_SECONDS', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { - type: 'event', - anonymous: false, - inputs: [ - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, - }, - ], - name: 'ETHWithdrawalFinalized', + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'L2_BLOCK_TIME', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { - type: 'event', - anonymous: false, - inputs: [ - { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, - ], - name: 'Initialized', + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'PROPOSER', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'MESSENGER', - outputs: [ - { - name: '', - internalType: 'contract CrossDomainMessenger', - type: 'address', - }, - ], + name: 'SUBMISSION_INTERVAL', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'OTHER_BRIDGE', - outputs: [ - { name: '', internalType: 'contract StandardBridge', type: 'address' }, - ], + name: 'challenger', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, ], - name: 'bridgeERC20', - outputs: [], + name: 'computeL2Timestamp', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, ], - name: 'bridgeERC20To', + name: 'deleteL2Outputs', outputs: [], }, { - stateMutability: 'payable', + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'finalizationPeriodSeconds', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + }, + { + stateMutability: 'view', type: 'function', inputs: [ - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, + ], + name: 'getL2Output', + outputs: [ + { + name: '', + internalType: 'struct Types.OutputProposal', + type: 'tuple', + components: [ + { name: 'outputRoot', internalType: 'bytes32', type: 'bytes32' }, + { name: 'timestamp', internalType: 'uint128', type: 'uint128' }, + { name: 'l2BlockNumber', internalType: 'uint128', type: 'uint128' }, + ], + }, ], - name: 'bridgeETH', - outputs: [], }, { - stateMutability: 'payable', + stateMutability: 'view', type: 'function', inputs: [ - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, + ], + name: 'getL2OutputAfter', + outputs: [ + { + name: '', + internalType: 'struct Types.OutputProposal', + type: 'tuple', + components: [ + { name: 'outputRoot', internalType: 'bytes32', type: 'bytes32' }, + { name: 'timestamp', internalType: 'uint128', type: 'uint128' }, + { name: 'l2BlockNumber', internalType: 'uint128', type: 'uint128' }, + ], + }, ], - name: 'bridgeETHTo', - outputs: [], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', inputs: [ - { name: '_l1Token', internalType: 'address', type: 'address' }, - { name: '_l2Token', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, ], - name: 'depositERC20', - outputs: [], + name: 'getL2OutputIndexAfter', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_l1Token', internalType: 'address', type: 'address' }, - { name: '_l2Token', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { + name: '_startingBlockNumber', + internalType: 'uint256', + type: 'uint256', + }, + { name: '_startingTimestamp', internalType: 'uint256', type: 'uint256' }, + { name: '_proposer', internalType: 'address', type: 'address' }, + { name: '_challenger', internalType: 'address', type: 'address' }, ], - name: 'depositERC20To', + name: 'initialize', outputs: [], }, { - stateMutability: 'payable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'depositETH', - outputs: [], + inputs: [], + name: 'l2BlockTime', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { - stateMutability: 'payable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'depositETHTo', - outputs: [], + inputs: [], + name: 'latestBlockNumber', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', - inputs: [ - { name: '', internalType: 'address', type: 'address' }, - { name: '', internalType: 'address', type: 'address' }, - ], - name: 'deposits', + inputs: [], + name: 'latestOutputIndex', outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_from', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'finalizeBridgeERC20', - outputs: [], + inputs: [], + name: 'nextBlockNumber', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { - stateMutability: 'payable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_from', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'finalizeBridgeETH', - outputs: [], + inputs: [], + name: 'nextOutputIndex', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'payable', type: 'function', inputs: [ - { name: '_l1Token', internalType: 'address', type: 'address' }, - { name: '_l2Token', internalType: 'address', type: 'address' }, - { name: '_from', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { name: '_outputRoot', internalType: 'bytes32', type: 'bytes32' }, + { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, + { name: '_l1BlockHash', internalType: 'bytes32', type: 'bytes32' }, + { name: '_l1BlockNumber', internalType: 'uint256', type: 'uint256' }, ], - name: 'finalizeERC20Withdrawal', + name: 'proposeL2Output', outputs: [], }, { - stateMutability: 'payable', - type: 'function', - inputs: [ - { name: '_from', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'finalizeETHWithdrawal', - outputs: [], - }, - { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [ - { - name: '_messenger', - internalType: 'contract CrossDomainMessenger', - type: 'address', - }, - ], - name: 'initialize', - outputs: [], + inputs: [], + name: 'proposer', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'l2TokenBridge', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'startingBlockNumber', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'messenger', - outputs: [ - { - name: '', - internalType: 'contract CrossDomainMessenger', - type: 'address', - }, - ], + name: 'startingTimestamp', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'otherBridge', - outputs: [ - { name: '', internalType: 'contract StandardBridge', type: 'address' }, - ], + name: 'submissionInterval', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', @@ -4733,39 +4755,41 @@ export const l1StandardBridgeGoerliABI = [ name: 'version', outputs: [{ name: '', internalType: 'string', type: 'string' }], }, - { stateMutability: 'payable', type: 'receive' }, ] as const /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) */ -export const l1StandardBridgeGoerliAddress = { - 5: '0x636Af16bf2f682dD3109e60102b8E1A089FedAa8', +export const l2OutputOracleAddress = { + 1: '0xdfe97868233d1aa22e815a266982f2cf17685a27', + 5: '0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0', } as const /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) */ -export const l1StandardBridgeGoerliConfig = { - address: l1StandardBridgeGoerliAddress, - abi: l1StandardBridgeGoerliABI, +export const l2OutputOracleConfig = { + address: l2OutputOracleAddress, + abi: l2OutputOracleABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// L2CrossDomainMessenger +// L2StandardBridge ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) */ -export const l2CrossDomainMessengerABI = [ +export const l2StandardBridgeABI = [ { stateMutability: 'nonpayable', type: 'constructor', inputs: [ { - name: '_l1CrossDomainMessenger', - internalType: 'address', + name: '_otherBridge', + internalType: 'address payable', type: 'address', }, ], @@ -4775,392 +4799,469 @@ export const l2CrossDomainMessengerABI = [ anonymous: false, inputs: [ { - name: 'msgHash', - internalType: 'bytes32', - type: 'bytes32', + name: 'l1Token', + internalType: 'address', + type: 'address', indexed: true, }, + { + name: 'l2Token', + internalType: 'address', + type: 'address', + indexed: true, + }, + { name: 'from', internalType: 'address', type: 'address', indexed: true }, + { name: 'to', internalType: 'address', type: 'address', indexed: false }, + { + name: 'amount', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + { + name: 'extraData', + internalType: 'bytes', + type: 'bytes', + indexed: false, + }, ], - name: 'FailedRelayedMessage', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, - ], - name: 'Initialized', + name: 'DepositFinalized', }, { type: 'event', anonymous: false, inputs: [ { - name: 'msgHash', - internalType: 'bytes32', - type: 'bytes32', + name: 'localToken', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'remoteToken', + internalType: 'address', + type: 'address', indexed: true, }, + { name: 'from', internalType: 'address', type: 'address', indexed: true }, + { name: 'to', internalType: 'address', type: 'address', indexed: false }, + { + name: 'amount', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + { + name: 'extraData', + internalType: 'bytes', + type: 'bytes', + indexed: false, + }, ], - name: 'RelayedMessage', + name: 'ERC20BridgeFinalized', }, { type: 'event', anonymous: false, inputs: [ { - name: 'target', + name: 'localToken', internalType: 'address', type: 'address', indexed: true, }, { - name: 'sender', + name: 'remoteToken', internalType: 'address', type: 'address', + indexed: true, + }, + { name: 'from', internalType: 'address', type: 'address', indexed: true }, + { name: 'to', internalType: 'address', type: 'address', indexed: false }, + { + name: 'amount', + internalType: 'uint256', + type: 'uint256', indexed: false, }, - { name: 'message', internalType: 'bytes', type: 'bytes', indexed: false }, { - name: 'messageNonce', + name: 'extraData', + internalType: 'bytes', + type: 'bytes', + indexed: false, + }, + ], + name: 'ERC20BridgeInitiated', + }, + { + type: 'event', + anonymous: false, + inputs: [ + { name: 'from', internalType: 'address', type: 'address', indexed: true }, + { name: 'to', internalType: 'address', type: 'address', indexed: true }, + { + name: 'amount', internalType: 'uint256', type: 'uint256', indexed: false, }, { - name: 'gasLimit', + name: 'extraData', + internalType: 'bytes', + type: 'bytes', + indexed: false, + }, + ], + name: 'ETHBridgeFinalized', + }, + { + type: 'event', + anonymous: false, + inputs: [ + { name: 'from', internalType: 'address', type: 'address', indexed: true }, + { name: 'to', internalType: 'address', type: 'address', indexed: true }, + { + name: 'amount', internalType: 'uint256', type: 'uint256', indexed: false, }, + { + name: 'extraData', + internalType: 'bytes', + type: 'bytes', + indexed: false, + }, ], - name: 'SentMessage', + name: 'ETHBridgeInitiated', }, { type: 'event', anonymous: false, inputs: [ { - name: 'sender', + name: 'l1Token', internalType: 'address', type: 'address', indexed: true, }, { - name: 'value', + name: 'l2Token', + internalType: 'address', + type: 'address', + indexed: true, + }, + { name: 'from', internalType: 'address', type: 'address', indexed: true }, + { name: 'to', internalType: 'address', type: 'address', indexed: false }, + { + name: 'amount', internalType: 'uint256', type: 'uint256', indexed: false, }, + { + name: 'extraData', + internalType: 'bytes', + type: 'bytes', + indexed: false, + }, ], - name: 'SentMessageExtension1', - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'MESSAGE_VERSION', - outputs: [{ name: '', internalType: 'uint16', type: 'uint16' }], + name: 'WithdrawalInitiated', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'MIN_GAS_CALLDATA_OVERHEAD', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + name: 'MESSENGER', + outputs: [ + { + name: '', + internalType: 'contract CrossDomainMessenger', + type: 'address', + }, + ], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'MIN_GAS_DYNAMIC_OVERHEAD_DENOMINATOR', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + name: 'OTHER_BRIDGE', + outputs: [ + { name: '', internalType: 'contract StandardBridge', type: 'address' }, + ], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'MIN_GAS_DYNAMIC_OVERHEAD_NUMERATOR', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + inputs: [ + { name: '_localToken', internalType: 'address', type: 'address' }, + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'bridgeERC20', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'OTHER_MESSENGER', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + inputs: [ + { name: '_localToken', internalType: 'address', type: 'address' }, + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'bridgeERC20To', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'payable', type: 'function', - inputs: [], - name: 'RELAY_CALL_OVERHEAD', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + inputs: [ + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'bridgeETH', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'payable', type: 'function', - inputs: [], - name: 'RELAY_CONSTANT_OVERHEAD', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + inputs: [ + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'bridgeETHTo', + outputs: [], }, { stateMutability: 'view', type: 'function', - inputs: [], - name: 'RELAY_GAS_CHECK_BUFFER', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + inputs: [ + { name: '', internalType: 'address', type: 'address' }, + { name: '', internalType: 'address', type: 'address' }, + ], + name: 'deposits', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'RELAY_RESERVED_GAS', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + inputs: [ + { name: '_localToken', internalType: 'address', type: 'address' }, + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_from', internalType: 'address', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'finalizeBridgeERC20', + outputs: [], }, { - stateMutability: 'pure', + stateMutability: 'payable', type: 'function', inputs: [ - { name: '_message', internalType: 'bytes', type: 'bytes' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_from', internalType: 'address', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, ], - name: 'baseGas', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + name: 'finalizeBridgeETH', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'payable', type: 'function', - inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - name: 'failedMessages', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + inputs: [ + { name: '_l1Token', internalType: 'address', type: 'address' }, + { name: '_l2Token', internalType: 'address', type: 'address' }, + { name: '_from', internalType: 'address', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'finalizeDeposit', + outputs: [], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', inputs: [], - name: 'initialize', - outputs: [], + name: 'l1TokenBridge', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'l1CrossDomainMessenger', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'messenger', + outputs: [ + { + name: '', + internalType: 'contract CrossDomainMessenger', + type: 'address', + }, + ], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'messageNonce', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'version', + outputs: [{ name: '', internalType: 'string', type: 'string' }], }, { stateMutability: 'payable', type: 'function', inputs: [ - { name: '_nonce', internalType: 'uint256', type: 'uint256' }, - { name: '_sender', internalType: 'address', type: 'address' }, - { name: '_target', internalType: 'address', type: 'address' }, - { name: '_value', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint256', type: 'uint256' }, - { name: '_message', internalType: 'bytes', type: 'bytes' }, + { name: '_l2Token', internalType: 'address', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, ], - name: 'relayMessage', + name: 'withdraw', outputs: [], }, { stateMutability: 'payable', type: 'function', inputs: [ - { name: '_target', internalType: 'address', type: 'address' }, - { name: '_message', internalType: 'bytes', type: 'bytes' }, + { name: '_l2Token', internalType: 'address', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, ], - name: 'sendMessage', + name: 'withdrawTo', outputs: [], }, - { - stateMutability: 'view', - type: 'function', - inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - name: 'successfulMessages', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'xDomainMessageSender', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, + { stateMutability: 'payable', type: 'receive' }, ] as const /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) */ -export const l2CrossDomainMessengerAddress = { - 420: '0x4200000000000000000000000000000000000007', +export const l2StandardBridgeAddress = { + 420: '0x4200000000000000000000000000000000000010', } as const /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) */ -export const l2CrossDomainMessengerConfig = { - address: l2CrossDomainMessengerAddress, - abi: l2CrossDomainMessengerABI, +export const l2StandardBridgeConfig = { + address: l2StandardBridgeAddress, + abi: l2StandardBridgeABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// L2ERC721Bridge +// L2ToL1MessagePasser ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000014) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000016) */ -export const l2Erc721BridgeABI = [ - { - stateMutability: 'nonpayable', - type: 'constructor', - inputs: [ - { name: '_messenger', internalType: 'address', type: 'address' }, - { name: '_otherBridge', internalType: 'address', type: 'address' }, - ], - }, +export const l2ToL1MessagePasserABI = [ + { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, { type: 'event', anonymous: false, inputs: [ { - name: 'localToken', + name: 'nonce', + internalType: 'uint256', + type: 'uint256', + indexed: true, + }, + { + name: 'sender', internalType: 'address', type: 'address', indexed: true, }, { - name: 'remoteToken', + name: 'target', internalType: 'address', type: 'address', indexed: true, }, - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: false }, { - name: 'tokenId', + name: 'value', internalType: 'uint256', type: 'uint256', indexed: false, }, { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', + name: 'gasLimit', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + { name: 'data', internalType: 'bytes', type: 'bytes', indexed: false }, + { + name: 'withdrawalHash', + internalType: 'bytes32', + type: 'bytes32', indexed: false, }, ], - name: 'ERC721BridgeFinalized', + name: 'MessagePassed', }, { type: 'event', anonymous: false, inputs: [ { - name: 'localToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'remoteToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: false }, - { - name: 'tokenId', + name: 'amount', internalType: 'uint256', type: 'uint256', - indexed: false, - }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, + indexed: true, }, ], - name: 'ERC721BridgeInitiated', + name: 'WithdrawerBalanceBurnt', }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'bridgeERC721', - outputs: [], + inputs: [], + name: 'MESSAGE_VERSION', + outputs: [{ name: '', internalType: 'uint16', type: 'uint16' }], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'bridgeERC721To', + inputs: [], + name: 'burn', outputs: [], }, { - stateMutability: 'nonpayable', + stateMutability: 'payable', type: 'function', inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_from', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { name: '_target', internalType: 'address', type: 'address' }, + { name: '_gasLimit', internalType: 'uint256', type: 'uint256' }, + { name: '_data', internalType: 'bytes', type: 'bytes' }, ], - name: 'finalizeBridgeERC721', + name: 'initiateWithdrawal', outputs: [], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'messenger', - outputs: [ - { - name: '', - internalType: 'contract CrossDomainMessenger', - type: 'address', - }, - ], + name: 'messageNonce', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', - inputs: [], - name: 'otherBridge', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'sentMessages', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { stateMutability: 'view', @@ -5169,239 +5270,166 @@ export const l2Erc721BridgeABI = [ name: 'version', outputs: [{ name: '', internalType: 'string', type: 'string' }], }, + { stateMutability: 'payable', type: 'receive' }, ] as const /** - * [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000014) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000016) */ -export const l2Erc721BridgeAddress = { - 10: '0x4200000000000000000000000000000000000014', +export const l2ToL1MessagePasserAddress = { + 420: '0x4200000000000000000000000000000000000016', } as const /** - * [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000014) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000016) */ -export const l2Erc721BridgeConfig = { - address: l2Erc721BridgeAddress, - abi: l2Erc721BridgeABI, +export const l2ToL1MessagePasserConfig = { + address: l2ToL1MessagePasserAddress, + abi: l2ToL1MessagePasserABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// L2ERC721Bridge_optimism-goerli +// MintManager ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000014) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x5C4e7Ba1E219E47948e6e3F55019A647bA501005) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76) */ -export const l2Erc721BridgeOptimismGoerliABI = [ +export const mintManagerABI = [ { stateMutability: 'nonpayable', type: 'constructor', inputs: [ - { name: '_messenger', internalType: 'address', type: 'address' }, - { name: '_otherBridge', internalType: 'address', type: 'address' }, - ], - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'localToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'remoteToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: false }, - { - name: 'tokenId', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, - }, + { name: '_upgrader', internalType: 'address', type: 'address' }, + { name: '_governanceToken', internalType: 'address', type: 'address' }, ], - name: 'ERC721BridgeFinalized', }, { type: 'event', anonymous: false, inputs: [ { - name: 'localToken', + name: 'previousOwner', internalType: 'address', type: 'address', indexed: true, }, { - name: 'remoteToken', + name: 'newOwner', internalType: 'address', type: 'address', indexed: true, }, - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: false }, - { - name: 'tokenId', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, - }, ], - name: 'ERC721BridgeInitiated', + name: 'OwnershipTransferred', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'MESSENGER', - outputs: [ - { - name: '', - internalType: 'contract CrossDomainMessenger', - type: 'address', - }, - ], + name: 'DENOMINATOR', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'OTHER_BRIDGE', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'MINT_CAP', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'bridgeERC721', - outputs: [], + inputs: [], + name: 'MINT_PERIOD', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + inputs: [], + name: 'governanceToken', + outputs: [ + { name: '', internalType: 'contract GovernanceToken', type: 'address' }, ], - name: 'bridgeERC721To', - outputs: [], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_from', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { name: '_account', internalType: 'address', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, ], - name: 'finalizeBridgeERC721', + name: 'mint', outputs: [], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'messenger', - outputs: [ - { - name: '', - internalType: 'contract CrossDomainMessenger', - type: 'address', - }, - ], + name: 'mintPermittedAfter', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'otherBridge', + name: 'owner', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + name: 'renounceOwnership', + outputs: [], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], + name: 'transferOwnership', + outputs: [], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { name: '_newMintManager', internalType: 'address', type: 'address' }, + ], + name: 'upgrade', + outputs: [], }, ] as const /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000014) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x5C4e7Ba1E219E47948e6e3F55019A647bA501005) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76) */ -export const l2Erc721BridgeOptimismGoerliAddress = { - 420: '0x4200000000000000000000000000000000000014', +export const mintManagerAddress = { + 10: '0x5C4e7Ba1E219E47948e6e3F55019A647bA501005', + 420: '0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76', } as const /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000014) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x5C4e7Ba1E219E47948e6e3F55019A647bA501005) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76) */ -export const l2Erc721BridgeOptimismGoerliConfig = { - address: l2Erc721BridgeOptimismGoerliAddress, - abi: l2Erc721BridgeOptimismGoerliABI, +export const mintManagerConfig = { + address: mintManagerAddress, + abi: mintManagerABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// L2OutputOracle +// OptimismMintableERC20Factory ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) + * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000012) */ -export const l2OutputOracleABI = [ - { - stateMutability: 'nonpayable', - type: 'constructor', - inputs: [ - { name: '_submissionInterval', internalType: 'uint256', type: 'uint256' }, - { name: '_l2BlockTime', internalType: 'uint256', type: 'uint256' }, - { - name: '_startingBlockNumber', - internalType: 'uint256', - type: 'uint256', - }, - { name: '_startingTimestamp', internalType: 'uint256', type: 'uint256' }, - { name: '_proposer', internalType: 'address', type: 'address' }, - { name: '_challenger', internalType: 'address', type: 'address' }, - { - name: '_finalizationPeriodSeconds', - internalType: 'uint256', - type: 'uint256', - }, - ], - }, +export const optimismMintableErc20FactoryABI = [ + { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, { type: 'event', anonymous: false, @@ -5415,221 +5443,100 @@ export const l2OutputOracleABI = [ anonymous: false, inputs: [ { - name: 'outputRoot', - internalType: 'bytes32', - type: 'bytes32', - indexed: true, - }, - { - name: 'l2OutputIndex', - internalType: 'uint256', - type: 'uint256', + name: 'localToken', + internalType: 'address', + type: 'address', indexed: true, }, { - name: 'l2BlockNumber', - internalType: 'uint256', - type: 'uint256', + name: 'remoteToken', + internalType: 'address', + type: 'address', indexed: true, }, { - name: 'l1Timestamp', - internalType: 'uint256', - type: 'uint256', + name: 'deployer', + internalType: 'address', + type: 'address', indexed: false, }, ], - name: 'OutputProposed', + name: 'OptimismMintableERC20Created', }, { type: 'event', anonymous: false, inputs: [ { - name: 'prevNextOutputIndex', - internalType: 'uint256', - type: 'uint256', - indexed: true, + name: 'remoteToken', + internalType: 'address', + type: 'address', + indexed: true, }, { - name: 'newNextOutputIndex', - internalType: 'uint256', - type: 'uint256', + name: 'localToken', + internalType: 'address', + type: 'address', indexed: true, }, ], - name: 'OutputsDeleted', + name: 'StandardL2TokenCreated', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'CHALLENGER', + name: 'BRIDGE', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'FINALIZATION_PERIOD_SECONDS', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'L2_BLOCK_TIME', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'PROPOSER', + name: 'bridge', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'SUBMISSION_INTERVAL', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [ - { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, - ], - name: 'computeL2Timestamp', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, - ], - name: 'deleteL2Outputs', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [ - { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, - ], - name: 'getL2Output', - outputs: [ - { - name: '', - internalType: 'struct Types.OutputProposal', - type: 'tuple', - components: [ - { name: 'outputRoot', internalType: 'bytes32', type: 'bytes32' }, - { name: 'timestamp', internalType: 'uint128', type: 'uint128' }, - { name: 'l2BlockNumber', internalType: 'uint128', type: 'uint128' }, - ], - }, + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, ], + name: 'createOptimismMintableERC20', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, - ], - name: 'getL2OutputAfter', - outputs: [ - { - name: '', - internalType: 'struct Types.OutputProposal', - type: 'tuple', - components: [ - { name: 'outputRoot', internalType: 'bytes32', type: 'bytes32' }, - { name: 'timestamp', internalType: 'uint128', type: 'uint128' }, - { name: 'l2BlockNumber', internalType: 'uint128', type: 'uint128' }, - ], - }, + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, + { name: '_decimals', internalType: 'uint8', type: 'uint8' }, ], + name: 'createOptimismMintableERC20WithDecimals', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, ], - name: 'getL2OutputIndexAfter', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'createStandardL2Token', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [ - { - name: '_startingBlockNumber', - internalType: 'uint256', - type: 'uint256', - }, - { name: '_startingTimestamp', internalType: 'uint256', type: 'uint256' }, - ], + inputs: [{ name: '_bridge', internalType: 'address', type: 'address' }], name: 'initialize', outputs: [], }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'latestBlockNumber', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'latestOutputIndex', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'nextBlockNumber', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'nextOutputIndex', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'payable', - type: 'function', - inputs: [ - { name: '_outputRoot', internalType: 'bytes32', type: 'bytes32' }, - { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, - { name: '_l1BlockHash', internalType: 'bytes32', type: 'bytes32' }, - { name: '_l1BlockNumber', internalType: 'uint256', type: 'uint256' }, - ], - name: 'proposeL2Output', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'startingBlockNumber', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'startingTimestamp', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, { stateMutability: 'view', type: 'function', @@ -5640,41 +5547,29 @@ export const l2OutputOracleABI = [ ] as const /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) + * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000012) */ -export const l2OutputOracleAddress = { - 1: '0xdfe97868233d1aa22e815a266982f2cf17685a27', +export const optimismMintableErc20FactoryAddress = { + 1: '0x4200000000000000000000000000000000000012', } as const /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) + * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000012) */ -export const l2OutputOracleConfig = { - address: l2OutputOracleAddress, - abi: l2OutputOracleABI, +export const optimismMintableErc20FactoryConfig = { + address: optimismMintableErc20FactoryAddress, + abi: optimismMintableErc20FactoryABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// L2OutputOracle_goerli +// OptimismMintableERC20Factory_goerli ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) + * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000012) */ -export const l2OutputOracleGoerliABI = [ - { - stateMutability: 'nonpayable', - type: 'constructor', - inputs: [ - { name: '_submissionInterval', internalType: 'uint256', type: 'uint256' }, - { name: '_l2BlockTime', internalType: 'uint256', type: 'uint256' }, - { - name: '_finalizationPeriodSeconds', - internalType: 'uint256', - type: 'uint256', - }, - ], - }, +export const optimismMintableErc20FactoryGoerliABI = [ + { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, { type: 'event', anonymous: false, @@ -5688,257 +5583,209 @@ export const l2OutputOracleGoerliABI = [ anonymous: false, inputs: [ { - name: 'outputRoot', - internalType: 'bytes32', - type: 'bytes32', - indexed: true, - }, - { - name: 'l2OutputIndex', - internalType: 'uint256', - type: 'uint256', + name: 'localToken', + internalType: 'address', + type: 'address', indexed: true, }, { - name: 'l2BlockNumber', - internalType: 'uint256', - type: 'uint256', + name: 'remoteToken', + internalType: 'address', + type: 'address', indexed: true, }, { - name: 'l1Timestamp', - internalType: 'uint256', - type: 'uint256', + name: 'deployer', + internalType: 'address', + type: 'address', indexed: false, }, ], - name: 'OutputProposed', + name: 'OptimismMintableERC20Created', }, { type: 'event', anonymous: false, inputs: [ { - name: 'prevNextOutputIndex', - internalType: 'uint256', - type: 'uint256', + name: 'remoteToken', + internalType: 'address', + type: 'address', indexed: true, }, { - name: 'newNextOutputIndex', - internalType: 'uint256', - type: 'uint256', + name: 'localToken', + internalType: 'address', + type: 'address', indexed: true, }, ], - name: 'OutputsDeleted', + name: 'StandardL2TokenCreated', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'CHALLENGER', + name: 'BRIDGE', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'FINALIZATION_PERIOD_SECONDS', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'bridge', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'L2_BLOCK_TIME', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + inputs: [ + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, + ], + name: 'createOptimismMintableERC20', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'PROPOSER', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'SUBMISSION_INTERVAL', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'challenger', + inputs: [ + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, + { name: '_decimals', internalType: 'uint8', type: 'uint8' }, + ], + name: 'createOptimismMintableERC20WithDecimals', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, ], - name: 'computeL2Timestamp', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'createStandardL2Token', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [ - { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, - ], - name: 'deleteL2Outputs', + inputs: [{ name: '_bridge', internalType: 'address', type: 'address' }], + name: 'initialize', outputs: [], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'finalizationPeriodSeconds', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'version', + outputs: [{ name: '', internalType: 'string', type: 'string' }], + }, +] as const + +/** + * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000012) + */ +export const optimismMintableErc20FactoryGoerliAddress = { + 5: '0x4200000000000000000000000000000000000012', +} as const + +/** + * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000012) + */ +export const optimismMintableErc20FactoryGoerliConfig = { + address: optimismMintableErc20FactoryGoerliAddress, + abi: optimismMintableErc20FactoryGoerliABI, +} as const + +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// OptimismMintableERC20Factory_optimism-goerli +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/** + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000012) + */ +export const optimismMintableErc20FactoryOptimismGoerliABI = [ + { + stateMutability: 'nonpayable', + type: 'constructor', + inputs: [{ name: '_bridge', internalType: 'address', type: 'address' }], }, { - stateMutability: 'view', - type: 'function', + type: 'event', + anonymous: false, inputs: [ - { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, - ], - name: 'getL2Output', - outputs: [ { - name: '', - internalType: 'struct Types.OutputProposal', - type: 'tuple', - components: [ - { name: 'outputRoot', internalType: 'bytes32', type: 'bytes32' }, - { name: 'timestamp', internalType: 'uint128', type: 'uint128' }, - { name: 'l2BlockNumber', internalType: 'uint128', type: 'uint128' }, - ], + name: 'localToken', + internalType: 'address', + type: 'address', + indexed: true, }, - ], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [ - { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, - ], - name: 'getL2OutputAfter', - outputs: [ { - name: '', - internalType: 'struct Types.OutputProposal', - type: 'tuple', - components: [ - { name: 'outputRoot', internalType: 'bytes32', type: 'bytes32' }, - { name: 'timestamp', internalType: 'uint128', type: 'uint128' }, - { name: 'l2BlockNumber', internalType: 'uint128', type: 'uint128' }, - ], + name: 'remoteToken', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'deployer', + internalType: 'address', + type: 'address', + indexed: false, }, ], + name: 'OptimismMintableERC20Created', }, { - stateMutability: 'view', - type: 'function', - inputs: [ - { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, - ], - name: 'getL2OutputIndexAfter', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', + type: 'event', + anonymous: false, inputs: [ { - name: '_startingBlockNumber', - internalType: 'uint256', - type: 'uint256', + name: 'remoteToken', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'localToken', + internalType: 'address', + type: 'address', + indexed: true, }, - { name: '_startingTimestamp', internalType: 'uint256', type: 'uint256' }, - { name: '_proposer', internalType: 'address', type: 'address' }, - { name: '_challenger', internalType: 'address', type: 'address' }, ], - name: 'initialize', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'l2BlockTime', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'latestBlockNumber', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'latestOutputIndex', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'nextBlockNumber', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'StandardL2TokenCreated', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'nextOutputIndex', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'BRIDGE', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'payable', + stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_outputRoot', internalType: 'bytes32', type: 'bytes32' }, - { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, - { name: '_l1BlockHash', internalType: 'bytes32', type: 'bytes32' }, - { name: '_l1BlockNumber', internalType: 'uint256', type: 'uint256' }, + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, ], - name: 'proposeL2Output', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'proposer', + name: 'createOptimismMintableERC20', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'startingBlockNumber', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'startingTimestamp', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'submissionInterval', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + inputs: [ + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, + ], + name: 'createStandardL2Token', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', @@ -5950,37 +5797,34 @@ export const l2OutputOracleGoerliABI = [ ] as const /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000012) */ -export const l2OutputOracleGoerliAddress = { - 5: '0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0', +export const optimismMintableErc20FactoryOptimismGoerliAddress = { + 420: '0x4200000000000000000000000000000000000012', } as const /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000012) */ -export const l2OutputOracleGoerliConfig = { - address: l2OutputOracleGoerliAddress, - abi: l2OutputOracleGoerliABI, +export const optimismMintableErc20FactoryOptimismGoerliConfig = { + address: optimismMintableErc20FactoryOptimismGoerliAddress, + abi: optimismMintableErc20FactoryOptimismGoerliABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// L2StandardBridge +// OptimismMintableERC721Factory ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) + * [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000017) */ -export const l2StandardBridgeABI = [ +export const optimismMintableErc721FactoryABI = [ { stateMutability: 'nonpayable', type: 'constructor', inputs: [ - { - name: '_otherBridge', - internalType: 'address payable', - type: 'address', - }, + { name: '_bridge', internalType: 'address', type: 'address' }, + { name: '_remoteChainId', internalType: 'uint256', type: 'uint256' }, ], }, { @@ -5988,33 +5832,97 @@ export const l2StandardBridgeABI = [ anonymous: false, inputs: [ { - name: 'l1Token', + name: 'localToken', internalType: 'address', type: 'address', indexed: true, }, { - name: 'l2Token', + name: 'remoteToken', internalType: 'address', type: 'address', indexed: true, }, - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: false }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', + name: 'deployer', + internalType: 'address', + type: 'address', indexed: false, }, ], - name: 'DepositFinalized', + name: 'OptimismMintableERC721Created', + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'bridge', + outputs: [{ name: '', internalType: 'address', type: 'address' }], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, + ], + name: 'createOptimismMintableERC721', + outputs: [{ name: '', internalType: 'address', type: 'address' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'isOptimismMintableERC721', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'remoteChainId', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'version', + outputs: [{ name: '', internalType: 'string', type: 'string' }], + }, +] as const + +/** + * [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000017) + */ +export const optimismMintableErc721FactoryAddress = { + 10: '0x4200000000000000000000000000000000000017', +} as const + +/** + * [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000017) + */ +export const optimismMintableErc721FactoryConfig = { + address: optimismMintableErc721FactoryAddress, + abi: optimismMintableErc721FactoryABI, +} as const + +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// OptimismMintableERC721Factory_optimism-goerli +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/** + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000017) + */ +export const optimismMintableErc721FactoryOptimismGoerliABI = [ + { + stateMutability: 'nonpayable', + type: 'constructor', + inputs: [ + { name: '_bridge', internalType: 'address', type: 'address' }, + { name: '_remoteChainId', internalType: 'uint256', type: 'uint256' }, + ], }, { type: 'event', @@ -6032,55 +5940,101 @@ export const l2StandardBridgeABI = [ type: 'address', indexed: true, }, - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: false }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', + name: 'deployer', + internalType: 'address', + type: 'address', indexed: false, }, ], - name: 'ERC20BridgeFinalized', + name: 'OptimismMintableERC721Created', + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'BRIDGE', + outputs: [{ name: '', internalType: 'address', type: 'address' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'REMOTE_CHAIN_ID', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, + ], + name: 'createOptimismMintableERC721', + outputs: [{ name: '', internalType: 'address', type: 'address' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'isOptimismMintableERC721', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'version', + outputs: [{ name: '', internalType: 'string', type: 'string' }], + }, +] as const + +/** + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000017) + */ +export const optimismMintableErc721FactoryOptimismGoerliAddress = { + 420: '0x4200000000000000000000000000000000000017', +} as const + +/** + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000017) + */ +export const optimismMintableErc721FactoryOptimismGoerliConfig = { + address: optimismMintableErc721FactoryOptimismGoerliAddress, + abi: optimismMintableErc721FactoryOptimismGoerliABI, +} as const + +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// OptimismPortal +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/** + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) + */ +export const optimismPortalABI = [ + { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, + { + type: 'event', + anonymous: false, + inputs: [ + { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, + ], + name: 'Initialized', }, { type: 'event', anonymous: false, inputs: [ { - name: 'localToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'remoteToken', + name: 'account', internalType: 'address', type: 'address', - indexed: true, - }, - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: false }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', indexed: false, }, ], - name: 'ERC20BridgeInitiated', + name: 'Paused', }, { type: 'event', @@ -6089,467 +6043,513 @@ export const l2StandardBridgeABI = [ { name: 'from', internalType: 'address', type: 'address', indexed: true }, { name: 'to', internalType: 'address', type: 'address', indexed: true }, { - name: 'amount', + name: 'version', internalType: 'uint256', type: 'uint256', - indexed: false, + indexed: true, }, { - name: 'extraData', + name: 'opaqueData', internalType: 'bytes', type: 'bytes', indexed: false, }, ], - name: 'ETHBridgeFinalized', + name: 'TransactionDeposited', }, { type: 'event', anonymous: false, inputs: [ - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', + name: 'account', + internalType: 'address', + type: 'address', indexed: false, }, ], - name: 'ETHBridgeInitiated', + name: 'Unpaused', }, { type: 'event', anonymous: false, inputs: [ { - name: 'l1Token', - internalType: 'address', - type: 'address', + name: 'withdrawalHash', + internalType: 'bytes32', + type: 'bytes32', indexed: true, }, + { name: 'success', internalType: 'bool', type: 'bool', indexed: false }, + ], + name: 'WithdrawalFinalized', + }, + { + type: 'event', + anonymous: false, + inputs: [ { - name: 'l2Token', - internalType: 'address', - type: 'address', + name: 'withdrawalHash', + internalType: 'bytes32', + type: 'bytes32', indexed: true, }, { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: false }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, - }, + { name: 'to', internalType: 'address', type: 'address', indexed: true }, ], - name: 'WithdrawalInitiated', + name: 'WithdrawalProven', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'MESSENGER', - outputs: [ - { - name: '', - internalType: 'contract CrossDomainMessenger', - type: 'address', - }, - ], + name: 'GUARDIAN', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'OTHER_BRIDGE', + name: 'L2_ORACLE', outputs: [ - { name: '', internalType: 'contract StandardBridge', type: 'address' }, + { name: '', internalType: 'contract L2OutputOracle', type: 'address' }, ], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + inputs: [], + name: 'SYSTEM_CONFIG', + outputs: [ + { name: '', internalType: 'contract SystemConfig', type: 'address' }, ], - name: 'bridgeERC20', - outputs: [], }, { - stateMutability: 'nonpayable', + stateMutability: 'payable', type: 'function', inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { name: '_value', internalType: 'uint256', type: 'uint256' }, + { name: '_gasLimit', internalType: 'uint64', type: 'uint64' }, + { name: '_isCreation', internalType: 'bool', type: 'bool' }, + { name: '_data', internalType: 'bytes', type: 'bytes' }, ], - name: 'bridgeERC20To', + name: 'depositTransaction', outputs: [], }, { stateMutability: 'payable', type: 'function', - inputs: [ - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'bridgeETH', + inputs: [], + name: 'donateETH', outputs: [], }, { - stateMutability: 'payable', + stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { + name: '_tx', + internalType: 'struct Types.WithdrawalTransaction', + type: 'tuple', + components: [ + { name: 'nonce', internalType: 'uint256', type: 'uint256' }, + { name: 'sender', internalType: 'address', type: 'address' }, + { name: 'target', internalType: 'address', type: 'address' }, + { name: 'value', internalType: 'uint256', type: 'uint256' }, + { name: 'gasLimit', internalType: 'uint256', type: 'uint256' }, + { name: 'data', internalType: 'bytes', type: 'bytes' }, + ], + }, ], - name: 'bridgeETHTo', + name: 'finalizeWithdrawalTransaction', outputs: [], }, { stateMutability: 'view', type: 'function', - inputs: [ - { name: '', internalType: 'address', type: 'address' }, - { name: '', internalType: 'address', type: 'address' }, - ], - name: 'deposits', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'finalizedWithdrawals', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'guardian', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_from', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { + name: '_l2Oracle', + internalType: 'contract L2OutputOracle', + type: 'address', + }, + { name: '_guardian', internalType: 'address', type: 'address' }, + { + name: '_systemConfig', + internalType: 'contract SystemConfig', + type: 'address', + }, + { name: '_paused', internalType: 'bool', type: 'bool' }, ], - name: 'finalizeBridgeERC20', + name: 'initialize', outputs: [], }, { - stateMutability: 'payable', + stateMutability: 'view', type: 'function', inputs: [ - { name: '_from', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, ], - name: 'finalizeBridgeETH', - outputs: [], + name: 'isOutputFinalized', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { - stateMutability: 'payable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_l1Token', internalType: 'address', type: 'address' }, - { name: '_l2Token', internalType: 'address', type: 'address' }, - { name: '_from', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + inputs: [], + name: 'l2Oracle', + outputs: [ + { name: '', internalType: 'contract L2OutputOracle', type: 'address' }, ], - name: 'finalizeDeposit', - outputs: [], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'l1TokenBridge', + name: 'l2Sender', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, + { + stateMutability: 'pure', + type: 'function', + inputs: [{ name: '_byteCount', internalType: 'uint64', type: 'uint64' }], + name: 'minimumGasLimit', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'messenger', + name: 'params', outputs: [ - { - name: '', - internalType: 'contract CrossDomainMessenger', - type: 'address', - }, + { name: 'prevBaseFee', internalType: 'uint128', type: 'uint128' }, + { name: 'prevBoughtGas', internalType: 'uint64', type: 'uint64' }, + { name: 'prevBlockNum', internalType: 'uint64', type: 'uint64' }, ], }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [], + name: 'pause', + outputs: [], + }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + name: 'paused', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { - stateMutability: 'payable', + stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_l2Token', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { + name: '_tx', + internalType: 'struct Types.WithdrawalTransaction', + type: 'tuple', + components: [ + { name: 'nonce', internalType: 'uint256', type: 'uint256' }, + { name: 'sender', internalType: 'address', type: 'address' }, + { name: 'target', internalType: 'address', type: 'address' }, + { name: 'value', internalType: 'uint256', type: 'uint256' }, + { name: 'gasLimit', internalType: 'uint256', type: 'uint256' }, + { name: 'data', internalType: 'bytes', type: 'bytes' }, + ], + }, + { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, + { + name: '_outputRootProof', + internalType: 'struct Types.OutputRootProof', + type: 'tuple', + components: [ + { name: 'version', internalType: 'bytes32', type: 'bytes32' }, + { name: 'stateRoot', internalType: 'bytes32', type: 'bytes32' }, + { + name: 'messagePasserStorageRoot', + internalType: 'bytes32', + type: 'bytes32', + }, + { name: 'latestBlockhash', internalType: 'bytes32', type: 'bytes32' }, + ], + }, + { name: '_withdrawalProof', internalType: 'bytes[]', type: 'bytes[]' }, ], - name: 'withdraw', + name: 'proveWithdrawalTransaction', outputs: [], }, { - stateMutability: 'payable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_l2Token', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'provenWithdrawals', + outputs: [ + { name: 'outputRoot', internalType: 'bytes32', type: 'bytes32' }, + { name: 'timestamp', internalType: 'uint128', type: 'uint128' }, + { name: 'l2OutputIndex', internalType: 'uint128', type: 'uint128' }, ], - name: 'withdrawTo', + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'systemConfig', + outputs: [ + { name: '', internalType: 'contract SystemConfig', type: 'address' }, + ], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [], + name: 'unpause', outputs: [], }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'version', + outputs: [{ name: '', internalType: 'string', type: 'string' }], + }, { stateMutability: 'payable', type: 'receive' }, ] as const /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) */ -export const l2StandardBridgeAddress = { - 420: '0x4200000000000000000000000000000000000010', +export const optimismPortalAddress = { + 1: '0xbEb5Fc579115071764c7423A4f12eDde41f106Ed', + 5: '0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383', } as const /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) */ -export const l2StandardBridgeConfig = { - address: l2StandardBridgeAddress, - abi: l2StandardBridgeABI, +export const optimismPortalConfig = { + address: optimismPortalAddress, + abi: optimismPortalABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// L2ToL1MessagePasser +// Optimist ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000016) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) */ -export const l2ToL1MessagePasserABI = [ - { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, +export const optimistABI = [ { - type: 'event', - anonymous: false, + stateMutability: 'nonpayable', + type: 'constructor', inputs: [ + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, + { name: '_baseURIAttestor', internalType: 'address', type: 'address' }, { - name: 'nonce', - internalType: 'uint256', - type: 'uint256', - indexed: true, + name: '_attestationStation', + internalType: 'contract AttestationStation', + type: 'address', }, { - name: 'sender', + name: '_optimistAllowlist', + internalType: 'contract OptimistAllowlist', + type: 'address', + }, + ], + }, + { + type: 'event', + anonymous: false, + inputs: [ + { + name: 'owner', internalType: 'address', type: 'address', indexed: true, }, { - name: 'target', + name: 'approved', internalType: 'address', type: 'address', indexed: true, }, { - name: 'value', + name: 'tokenId', internalType: 'uint256', type: 'uint256', - indexed: false, + indexed: true, }, + ], + name: 'Approval', + }, + { + type: 'event', + anonymous: false, + inputs: [ { - name: 'gasLimit', - internalType: 'uint256', - type: 'uint256', - indexed: false, + name: 'owner', + internalType: 'address', + type: 'address', + indexed: true, }, - { name: 'data', internalType: 'bytes', type: 'bytes', indexed: false }, { - name: 'withdrawalHash', - internalType: 'bytes32', - type: 'bytes32', - indexed: false, + name: 'operator', + internalType: 'address', + type: 'address', + indexed: true, }, + { name: 'approved', internalType: 'bool', type: 'bool', indexed: false }, ], - name: 'MessagePassed', + name: 'ApprovalForAll', + }, + { + type: 'event', + anonymous: false, + inputs: [ + { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, + ], + name: 'Initialized', }, { type: 'event', anonymous: false, inputs: [ + { name: 'from', internalType: 'address', type: 'address', indexed: true }, + { name: 'to', internalType: 'address', type: 'address', indexed: true }, { - name: 'amount', + name: 'tokenId', internalType: 'uint256', type: 'uint256', indexed: true, }, ], - name: 'WithdrawerBalanceBurnt', + name: 'Transfer', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'MESSAGE_VERSION', - outputs: [{ name: '', internalType: 'uint16', type: 'uint16' }], + name: 'ATTESTATION_STATION', + outputs: [ + { + name: '', + internalType: 'contract AttestationStation', + type: 'address', + }, + ], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', inputs: [], - name: 'burn', - outputs: [], + name: 'BASE_URI_ATTESTATION_KEY', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { - stateMutability: 'payable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_target', internalType: 'address', type: 'address' }, - { name: '_gasLimit', internalType: 'uint256', type: 'uint256' }, - { name: '_data', internalType: 'bytes', type: 'bytes' }, - ], - name: 'initiateWithdrawal', - outputs: [], + inputs: [], + name: 'BASE_URI_ATTESTOR', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'messageNonce', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'OPTIMIST_ALLOWLIST', + outputs: [ + { name: '', internalType: 'contract OptimistAllowlist', type: 'address' }, + ], + }, + { + stateMutability: 'pure', + type: 'function', + inputs: [ + { name: '', internalType: 'address', type: 'address' }, + { name: '', internalType: 'uint256', type: 'uint256' }, + ], + name: 'approve', + outputs: [], }, { stateMutability: 'view', type: 'function', - inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - name: 'sentMessages', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + inputs: [{ name: 'owner', internalType: 'address', type: 'address' }], + name: 'balanceOf', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'version', + name: 'baseURI', outputs: [{ name: '', internalType: 'string', type: 'string' }], }, - { stateMutability: 'payable', type: 'receive' }, -] as const - -/** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000016) - */ -export const l2ToL1MessagePasserAddress = { - 420: '0x4200000000000000000000000000000000000016', -} as const - -/** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000016) - */ -export const l2ToL1MessagePasserConfig = { - address: l2ToL1MessagePasserAddress, - abi: l2ToL1MessagePasserABI, -} as const - -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// MintManager -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x5C4e7Ba1E219E47948e6e3F55019A647bA501005) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76) - */ -export const mintManagerABI = [ { stateMutability: 'nonpayable', - type: 'constructor', - inputs: [ - { name: '_upgrader', internalType: 'address', type: 'address' }, - { name: '_governanceToken', internalType: 'address', type: 'address' }, - ], - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'previousOwner', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'newOwner', - internalType: 'address', - type: 'address', - indexed: true, - }, - ], - name: 'OwnershipTransferred', + type: 'function', + inputs: [{ name: 'tokenId', internalType: 'uint256', type: 'uint256' }], + name: 'burn', + outputs: [], }, { stateMutability: 'view', type: 'function', - inputs: [], - name: 'DENOMINATOR', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + inputs: [{ name: 'tokenId', internalType: 'uint256', type: 'uint256' }], + name: 'getApproved', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'MINT_CAP', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + inputs: [ + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, + ], + name: 'initialize', + outputs: [], }, { stateMutability: 'view', type: 'function', - inputs: [], - name: 'MINT_PERIOD', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + inputs: [ + { name: 'owner', internalType: 'address', type: 'address' }, + { name: 'operator', internalType: 'address', type: 'address' }, + ], + name: 'isApprovedForAll', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { stateMutability: 'view', type: 'function', - inputs: [], - name: 'governanceToken', - outputs: [ - { name: '', internalType: 'contract GovernanceToken', type: 'address' }, - ], + inputs: [{ name: '_recipient', internalType: 'address', type: 'address' }], + name: 'isOnAllowList', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [ - { name: '_account', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - ], + inputs: [{ name: '_recipient', internalType: 'address', type: 'address' }], name: 'mint', outputs: [], }, @@ -6557,145 +6557,197 @@ export const mintManagerABI = [ stateMutability: 'view', type: 'function', inputs: [], - name: 'mintPermittedAfter', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'name', + outputs: [{ name: '', internalType: 'string', type: 'string' }], }, { stateMutability: 'view', type: 'function', - inputs: [], - name: 'owner', + inputs: [{ name: 'tokenId', internalType: 'uint256', type: 'uint256' }], + name: 'ownerOf', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'renounceOwnership', + inputs: [ + { name: 'from', internalType: 'address', type: 'address' }, + { name: 'to', internalType: 'address', type: 'address' }, + { name: 'tokenId', internalType: 'uint256', type: 'uint256' }, + ], + name: 'safeTransferFrom', outputs: [], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], - name: 'transferOwnership', + inputs: [ + { name: 'from', internalType: 'address', type: 'address' }, + { name: 'to', internalType: 'address', type: 'address' }, + { name: 'tokenId', internalType: 'uint256', type: 'uint256' }, + { name: 'data', internalType: 'bytes', type: 'bytes' }, + ], + name: 'safeTransferFrom', outputs: [], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_newMintManager', internalType: 'address', type: 'address' }, + { name: '', internalType: 'address', type: 'address' }, + { name: '', internalType: 'bool', type: 'bool' }, ], - name: 'upgrade', + name: 'setApprovalForAll', outputs: [], }, -] as const + { + stateMutability: 'view', + type: 'function', + inputs: [{ name: 'interfaceId', internalType: 'bytes4', type: 'bytes4' }], + name: 'supportsInterface', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'symbol', + outputs: [{ name: '', internalType: 'string', type: 'string' }], + }, + { + stateMutability: 'pure', + type: 'function', + inputs: [{ name: '_owner', internalType: 'address', type: 'address' }], + name: 'tokenIdOfAddress', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [{ name: '_tokenId', internalType: 'uint256', type: 'uint256' }], + name: 'tokenURI', + outputs: [{ name: '', internalType: 'string', type: 'string' }], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { name: 'from', internalType: 'address', type: 'address' }, + { name: 'to', internalType: 'address', type: 'address' }, + { name: 'tokenId', internalType: 'uint256', type: 'uint256' }, + ], + name: 'transferFrom', + outputs: [], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'version', + outputs: [{ name: '', internalType: 'string', type: 'string' }], + }, +] as const /** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x5C4e7Ba1E219E47948e6e3F55019A647bA501005) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) */ -export const mintManagerAddress = { - 10: '0x5C4e7Ba1E219E47948e6e3F55019A647bA501005', - 420: '0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76', +export const optimistAddress = { + 10: '0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5', + 420: '0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5', } as const /** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x5C4e7Ba1E219E47948e6e3F55019A647bA501005) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) */ -export const mintManagerConfig = { - address: mintManagerAddress, - abi: mintManagerABI, +export const optimistConfig = { + address: optimistAddress, + abi: optimistABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// OptimismMintableERC20Factory +// OptimistAllowlist ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000012) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) */ -export const optimismMintableErc20FactoryABI = [ +export const optimistAllowlistABI = [ { stateMutability: 'nonpayable', type: 'constructor', - inputs: [{ name: '_bridge', internalType: 'address', type: 'address' }], - }, - { - type: 'event', - anonymous: false, inputs: [ { - name: 'localToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'remoteToken', - internalType: 'address', + name: '_attestationStation', + internalType: 'contract AttestationStation', type: 'address', - indexed: true, }, + { name: '_allowlistAttestor', internalType: 'address', type: 'address' }, { - name: 'deployer', + name: '_coinbaseQuestAttestor', internalType: 'address', type: 'address', - indexed: false, }, + { name: '_optimistInviter', internalType: 'address', type: 'address' }, ], - name: 'OptimismMintableERC20Created', }, { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'remoteToken', - internalType: 'address', - type: 'address', - indexed: true, - }, + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'ALLOWLIST_ATTESTOR', + outputs: [{ name: '', internalType: 'address', type: 'address' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'ATTESTATION_STATION', + outputs: [ { - name: 'localToken', - internalType: 'address', + name: '', + internalType: 'contract AttestationStation', type: 'address', - indexed: true, }, ], - name: 'StandardL2TokenCreated', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'BRIDGE', + name: 'COINBASE_QUEST_ATTESTOR', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_symbol', internalType: 'string', type: 'string' }, - ], - name: 'createOptimismMintableERC20', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + inputs: [], + name: 'COINBASE_QUEST_ELIGIBLE_ATTESTATION_KEY', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_symbol', internalType: 'string', type: 'string' }, - ], - name: 'createStandardL2Token', + inputs: [], + name: 'OPTIMIST_CAN_MINT_ATTESTATION_KEY', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'OPTIMIST_INVITER', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, + { + stateMutability: 'view', + type: 'function', + inputs: [{ name: '_claimer', internalType: 'address', type: 'address' }], + name: 'isAllowedToMint', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + }, { stateMutability: 'view', type: 'function', @@ -6706,29 +6758,44 @@ export const optimismMintableErc20FactoryABI = [ ] as const /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000012) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) */ -export const optimismMintableErc20FactoryAddress = { - 1: '0x4200000000000000000000000000000000000012', +export const optimistAllowlistAddress = { + 10: '0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180', + 420: '0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180', } as const /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000012) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) */ -export const optimismMintableErc20FactoryConfig = { - address: optimismMintableErc20FactoryAddress, - abi: optimismMintableErc20FactoryABI, +export const optimistAllowlistConfig = { + address: optimistAllowlistAddress, + abi: optimistAllowlistABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// OptimismMintableERC20Factory_goerli +// OptimistInviter ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000012) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) */ -export const optimismMintableErc20FactoryGoerliABI = [ - { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, +export const optimistInviterABI = [ + { + stateMutability: 'nonpayable', + type: 'constructor', + inputs: [ + { name: '_inviteGranter', internalType: 'address', type: 'address' }, + { + name: '_attestationStation', + internalType: 'contract AttestationStation', + type: 'address', + }, + ], + }, { type: 'event', anonymous: false, @@ -6742,100 +6809,135 @@ export const optimismMintableErc20FactoryGoerliABI = [ anonymous: false, inputs: [ { - name: 'localToken', + name: 'issuer', internalType: 'address', type: 'address', indexed: true, }, { - name: 'remoteToken', + name: 'claimer', internalType: 'address', type: 'address', indexed: true, }, - { - name: 'deployer', - internalType: 'address', - type: 'address', - indexed: false, - }, ], - name: 'OptimismMintableERC20Created', + name: 'InviteClaimed', }, { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'remoteToken', - internalType: 'address', - type: 'address', - indexed: true, - }, + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'ATTESTATION_STATION', + outputs: [ { - name: 'localToken', - internalType: 'address', + name: '', + internalType: 'contract AttestationStation', type: 'address', - indexed: true, }, ], - name: 'StandardL2TokenCreated', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'BRIDGE', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'CAN_INVITE_ATTESTATION_KEY', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'bridge', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'CLAIMABLE_INVITE_TYPEHASH', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_symbol', internalType: 'string', type: 'string' }, - ], - name: 'createOptimismMintableERC20', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + inputs: [], + name: 'EIP712_VERSION', + outputs: [{ name: '', internalType: 'string', type: 'string' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_symbol', internalType: 'string', type: 'string' }, - { name: '_decimals', internalType: 'uint8', type: 'uint8' }, - ], - name: 'createOptimismMintableERC20WithDecimals', + inputs: [], + name: 'INVITE_GRANTER', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'MIN_COMMITMENT_PERIOD', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_symbol', internalType: 'string', type: 'string' }, + { name: '_claimer', internalType: 'address', type: 'address' }, + { + name: '_claimableInvite', + internalType: 'struct OptimistInviter.ClaimableInvite', + type: 'tuple', + components: [ + { name: 'issuer', internalType: 'address', type: 'address' }, + { name: 'nonce', internalType: 'bytes32', type: 'bytes32' }, + ], + }, + { name: '_signature', internalType: 'bytes', type: 'bytes' }, ], - name: 'createStandardL2Token', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'claimInvite', + outputs: [], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [{ name: '_bridge', internalType: 'address', type: 'address' }], + inputs: [{ name: '_commitment', internalType: 'bytes32', type: 'bytes32' }], + name: 'commitInvite', + outputs: [], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'commitmentTimestamps', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [{ name: '_name', internalType: 'string', type: 'string' }], name: 'initialize', outputs: [], }, + { + stateMutability: 'view', + type: 'function', + inputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'inviteCounts', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { name: '_accounts', internalType: 'address[]', type: 'address[]' }, + { name: '_inviteCount', internalType: 'uint256', type: 'uint256' }, + ], + name: 'setInviteCounts', + outputs: [], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [ + { name: '', internalType: 'address', type: 'address' }, + { name: '', internalType: 'bytes32', type: 'bytes32' }, + ], + name: 'usedNonces', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + }, { stateMutability: 'view', type: 'function', @@ -6846,299 +6948,231 @@ export const optimismMintableErc20FactoryGoerliABI = [ ] as const /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000012) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) */ -export const optimismMintableErc20FactoryGoerliAddress = { - 5: '0x4200000000000000000000000000000000000012', +export const optimistInviterAddress = { + 10: '0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929', + 420: '0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929', } as const /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000012) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) */ -export const optimismMintableErc20FactoryGoerliConfig = { - address: optimismMintableErc20FactoryGoerliAddress, - abi: optimismMintableErc20FactoryGoerliABI, +export const optimistInviterConfig = { + address: optimistInviterAddress, + abi: optimistInviterABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// OptimismMintableERC20Factory_optimism-goerli +// PortalSender ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000012) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x0A893d9576b9cFD9EF78595963dc973238E78210) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xe7FACd39531ee3C313330E93B4d7a8B8A3c84Aa4) */ -export const optimismMintableErc20FactoryOptimismGoerliABI = [ +export const portalSenderABI = [ { stateMutability: 'nonpayable', type: 'constructor', - inputs: [{ name: '_bridge', internalType: 'address', type: 'address' }], - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'localToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'remoteToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'deployer', - internalType: 'address', - type: 'address', - indexed: false, - }, - ], - name: 'OptimismMintableERC20Created', - }, - { - type: 'event', - anonymous: false, inputs: [ { - name: 'remoteToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'localToken', - internalType: 'address', + name: '_portal', + internalType: 'contract OptimismPortal', type: 'address', - indexed: true, }, ], - name: 'StandardL2TokenCreated', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'BRIDGE', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_symbol', internalType: 'string', type: 'string' }, + name: 'PORTAL', + outputs: [ + { name: '', internalType: 'contract OptimismPortal', type: 'address' }, ], - name: 'createOptimismMintableERC20', - outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [ - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_symbol', internalType: 'string', type: 'string' }, - ], - name: 'createStandardL2Token', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + name: 'donate', + outputs: [], }, ] as const /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000012) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x0A893d9576b9cFD9EF78595963dc973238E78210) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xe7FACd39531ee3C313330E93B4d7a8B8A3c84Aa4) */ -export const optimismMintableErc20FactoryOptimismGoerliAddress = { - 420: '0x4200000000000000000000000000000000000012', +export const portalSenderAddress = { + 1: '0x0A893d9576b9cFD9EF78595963dc973238E78210', + 5: '0xe7FACd39531ee3C313330E93B4d7a8B8A3c84Aa4', } as const /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000012) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x0A893d9576b9cFD9EF78595963dc973238E78210) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xe7FACd39531ee3C313330E93B4d7a8B8A3c84Aa4) */ -export const optimismMintableErc20FactoryOptimismGoerliConfig = { - address: optimismMintableErc20FactoryOptimismGoerliAddress, - abi: optimismMintableErc20FactoryOptimismGoerliABI, +export const portalSenderConfig = { + address: portalSenderAddress, + abi: portalSenderABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// OptimismMintableERC721Factory +// ProtocolVersions ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000017) + * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) */ -export const optimismMintableErc721FactoryABI = [ +export const protocolVersionsABI = [ + { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, { - stateMutability: 'nonpayable', - type: 'constructor', + type: 'event', + anonymous: false, inputs: [ - { name: '_bridge', internalType: 'address', type: 'address' }, - { name: '_remoteChainId', internalType: 'uint256', type: 'uint256' }, + { + name: 'version', + internalType: 'uint256', + type: 'uint256', + indexed: true, + }, + { + name: 'updateType', + internalType: 'enum ProtocolVersions.UpdateType', + type: 'uint8', + indexed: true, + }, + { name: 'data', internalType: 'bytes', type: 'bytes', indexed: false }, + ], + name: 'ConfigUpdate', + }, + { + type: 'event', + anonymous: false, + inputs: [ + { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, ], + name: 'Initialized', }, { type: 'event', anonymous: false, inputs: [ { - name: 'localToken', + name: 'previousOwner', internalType: 'address', type: 'address', indexed: true, }, { - name: 'remoteToken', + name: 'newOwner', internalType: 'address', type: 'address', indexed: true, }, - { - name: 'deployer', - internalType: 'address', - type: 'address', - indexed: false, - }, ], - name: 'OptimismMintableERC721Created', + name: 'OwnershipTransferred', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'bridge', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_symbol', internalType: 'string', type: 'string' }, - ], - name: 'createOptimismMintableERC721', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'RECOMMENDED_SLOT', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { stateMutability: 'view', type: 'function', - inputs: [{ name: '', internalType: 'address', type: 'address' }], - name: 'isOptimismMintableERC721', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + inputs: [], + name: 'REQUIRED_SLOT', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'remoteChainId', + name: 'VERSION', outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], - }, -] as const - -/** - * [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000017) - */ -export const optimismMintableErc721FactoryAddress = { - 10: '0x4200000000000000000000000000000000000017', -} as const - -/** - * [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000017) - */ -export const optimismMintableErc721FactoryConfig = { - address: optimismMintableErc721FactoryAddress, - abi: optimismMintableErc721FactoryABI, -} as const - -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// OptimismMintableERC721Factory_optimism-goerli -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000017) - */ -export const optimismMintableErc721FactoryOptimismGoerliABI = [ { stateMutability: 'nonpayable', - type: 'constructor', - inputs: [ - { name: '_bridge', internalType: 'address', type: 'address' }, - { name: '_remoteChainId', internalType: 'uint256', type: 'uint256' }, - ], - }, - { - type: 'event', - anonymous: false, + type: 'function', inputs: [ + { name: '_owner', internalType: 'address', type: 'address' }, + { name: '_required', internalType: 'ProtocolVersion', type: 'uint256' }, { - name: 'localToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'remoteToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'deployer', - internalType: 'address', - type: 'address', - indexed: false, + name: '_recommended', + internalType: 'ProtocolVersion', + type: 'uint256', }, ], - name: 'OptimismMintableERC721Created', + name: 'initialize', + outputs: [], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'BRIDGE', + name: 'owner', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'REMOTE_CHAIN_ID', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'recommended', + outputs: [ + { name: 'out_', internalType: 'ProtocolVersion', type: 'uint256' }, + ], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [], + name: 'renounceOwnership', + outputs: [], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'required', + outputs: [ + { name: 'out_', internalType: 'ProtocolVersion', type: 'uint256' }, + ], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_symbol', internalType: 'string', type: 'string' }, + { + name: '_recommended', + internalType: 'ProtocolVersion', + type: 'uint256', + }, ], - name: 'createOptimismMintableERC721', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'setRecommended', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [{ name: '', internalType: 'address', type: 'address' }], - name: 'isOptimismMintableERC721', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + inputs: [ + { name: '_required', internalType: 'ProtocolVersion', type: 'uint256' }, + ], + name: 'setRequired', + outputs: [], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], + name: 'transferOwnership', + outputs: [], }, { stateMutability: 'view', @@ -7150,968 +7184,803 @@ export const optimismMintableErc721FactoryOptimismGoerliABI = [ ] as const /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000017) + * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) */ -export const optimismMintableErc721FactoryOptimismGoerliAddress = { - 420: '0x4200000000000000000000000000000000000017', +export const protocolVersionsAddress = { + 5: '0x0C24F5098774aA366827D667494e9F889f7cFc08', } as const /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000017) + * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) */ -export const optimismMintableErc721FactoryOptimismGoerliConfig = { - address: optimismMintableErc721FactoryOptimismGoerliAddress, - abi: optimismMintableErc721FactoryOptimismGoerliABI, +export const protocolVersionsConfig = { + address: protocolVersionsAddress, + abi: protocolVersionsABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// OptimismPortal +// ProxyAdmin ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) */ -export const optimismPortalABI = [ +export const proxyAdminABI = [ { stateMutability: 'nonpayable', type: 'constructor', - inputs: [ - { - name: '_l2Oracle', - internalType: 'contract L2OutputOracle', - type: 'address', - }, - { name: '_guardian', internalType: 'address', type: 'address' }, - { name: '_paused', internalType: 'bool', type: 'bool' }, - { - name: '_config', - internalType: 'contract SystemConfig', - type: 'address', - }, - ], - }, - { - type: 'event', - anonymous: false, - inputs: [ - { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, - ], - name: 'Initialized', + inputs: [{ name: '_owner', internalType: 'address', type: 'address' }], }, { type: 'event', anonymous: false, inputs: [ { - name: 'account', + name: 'previousOwner', internalType: 'address', type: 'address', - indexed: false, - }, - ], - name: 'Paused', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, - { - name: 'version', - internalType: 'uint256', - type: 'uint256', indexed: true, }, { - name: 'opaqueData', - internalType: 'bytes', - type: 'bytes', - indexed: false, + name: 'newOwner', + internalType: 'address', + type: 'address', + indexed: true, }, ], - name: 'TransactionDeposited', + name: 'OwnershipTransferred', }, { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'account', - internalType: 'address', - type: 'address', - indexed: false, - }, + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'addressManager', + outputs: [ + { name: '', internalType: 'contract AddressManager', type: 'address' }, ], - name: 'Unpaused', }, { - type: 'event', - anonymous: false, + stateMutability: 'nonpayable', + type: 'function', inputs: [ - { - name: 'withdrawalHash', - internalType: 'bytes32', - type: 'bytes32', - indexed: true, - }, - { name: 'success', internalType: 'bool', type: 'bool', indexed: false }, + { name: '_proxy', internalType: 'address payable', type: 'address' }, + { name: '_newAdmin', internalType: 'address', type: 'address' }, ], - name: 'WithdrawalFinalized', + name: 'changeProxyAdmin', + outputs: [], }, { - type: 'event', - anonymous: false, + stateMutability: 'view', + type: 'function', inputs: [ - { - name: 'withdrawalHash', - internalType: 'bytes32', - type: 'bytes32', - indexed: true, - }, - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, + { name: '_proxy', internalType: 'address payable', type: 'address' }, ], - name: 'WithdrawalProven', + name: 'getProxyAdmin', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', - inputs: [], - name: 'GUARDIAN', + inputs: [{ name: '_proxy', internalType: 'address', type: 'address' }], + name: 'getProxyImplementation', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', - inputs: [], - name: 'L2_ORACLE', - outputs: [ - { name: '', internalType: 'contract L2OutputOracle', type: 'address' }, - ], + inputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'implementationName', + outputs: [{ name: '', internalType: 'string', type: 'string' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'SYSTEM_CONFIG', - outputs: [ - { name: '', internalType: 'contract SystemConfig', type: 'address' }, - ], + name: 'isUpgrading', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { - stateMutability: 'payable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_value', internalType: 'uint256', type: 'uint256' }, - { name: '_gasLimit', internalType: 'uint64', type: 'uint64' }, - { name: '_isCreation', internalType: 'bool', type: 'bool' }, - { name: '_data', internalType: 'bytes', type: 'bytes' }, + inputs: [], + name: 'owner', + outputs: [{ name: '', internalType: 'address', type: 'address' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'proxyType', + outputs: [ + { name: '', internalType: 'enum ProxyAdmin.ProxyType', type: 'uint8' }, ], - name: 'depositTransaction', - outputs: [], }, { - stateMutability: 'payable', + stateMutability: 'nonpayable', type: 'function', inputs: [], - name: 'donateETH', + name: 'renounceOwnership', outputs: [], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { - name: '_tx', - internalType: 'struct Types.WithdrawalTransaction', - type: 'tuple', - components: [ - { name: 'nonce', internalType: 'uint256', type: 'uint256' }, - { name: 'sender', internalType: 'address', type: 'address' }, - { name: 'target', internalType: 'address', type: 'address' }, - { name: 'value', internalType: 'uint256', type: 'uint256' }, - { name: 'gasLimit', internalType: 'uint256', type: 'uint256' }, - { name: 'data', internalType: 'bytes', type: 'bytes' }, - ], - }, + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_address', internalType: 'address', type: 'address' }, ], - name: 'finalizeWithdrawalTransaction', + name: 'setAddress', outputs: [], }, - { - stateMutability: 'view', - type: 'function', - inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - name: 'finalizedWithdrawals', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], - }, { stateMutability: 'nonpayable', type: 'function', - inputs: [{ name: '_paused', internalType: 'bool', type: 'bool' }], - name: 'initialize', + inputs: [ + { + name: '_address', + internalType: 'contract AddressManager', + type: 'address', + }, + ], + name: 'setAddressManager', outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, + { name: '_address', internalType: 'address', type: 'address' }, + { name: '_name', internalType: 'string', type: 'string' }, ], - name: 'isOutputFinalized', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'l2Sender', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'pure', - type: 'function', - inputs: [{ name: '_byteCount', internalType: 'uint64', type: 'uint64' }], - name: 'minimumGasLimit', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + name: 'setImplementationName', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'params', - outputs: [ - { name: 'prevBaseFee', internalType: 'uint128', type: 'uint128' }, - { name: 'prevBoughtGas', internalType: 'uint64', type: 'uint64' }, - { name: 'prevBlockNum', internalType: 'uint64', type: 'uint64' }, + inputs: [ + { name: '_address', internalType: 'address', type: 'address' }, + { + name: '_type', + internalType: 'enum ProxyAdmin.ProxyType', + type: 'uint8', + }, ], + name: 'setProxyType', + outputs: [], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'pause', + inputs: [{ name: '_upgrading', internalType: 'bool', type: 'bool' }], + name: 'setUpgrading', outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'paused', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], + name: 'transferOwnership', + outputs: [], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { - name: '_tx', - internalType: 'struct Types.WithdrawalTransaction', - type: 'tuple', - components: [ - { name: 'nonce', internalType: 'uint256', type: 'uint256' }, - { name: 'sender', internalType: 'address', type: 'address' }, - { name: 'target', internalType: 'address', type: 'address' }, - { name: 'value', internalType: 'uint256', type: 'uint256' }, - { name: 'gasLimit', internalType: 'uint256', type: 'uint256' }, - { name: 'data', internalType: 'bytes', type: 'bytes' }, - ], - }, - { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, - { - name: '_outputRootProof', - internalType: 'struct Types.OutputRootProof', - type: 'tuple', - components: [ - { name: 'version', internalType: 'bytes32', type: 'bytes32' }, - { name: 'stateRoot', internalType: 'bytes32', type: 'bytes32' }, - { - name: 'messagePasserStorageRoot', - internalType: 'bytes32', - type: 'bytes32', - }, - { name: 'latestBlockhash', internalType: 'bytes32', type: 'bytes32' }, - ], - }, - { name: '_withdrawalProof', internalType: 'bytes[]', type: 'bytes[]' }, + { name: '_proxy', internalType: 'address payable', type: 'address' }, + { name: '_implementation', internalType: 'address', type: 'address' }, ], - name: 'proveWithdrawalTransaction', + name: 'upgrade', outputs: [], }, { - stateMutability: 'view', + stateMutability: 'payable', type: 'function', - inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - name: 'provenWithdrawals', - outputs: [ - { name: 'outputRoot', internalType: 'bytes32', type: 'bytes32' }, - { name: 'timestamp', internalType: 'uint128', type: 'uint128' }, - { name: 'l2OutputIndex', internalType: 'uint128', type: 'uint128' }, + inputs: [ + { name: '_proxy', internalType: 'address payable', type: 'address' }, + { name: '_implementation', internalType: 'address', type: 'address' }, + { name: '_data', internalType: 'bytes', type: 'bytes' }, ], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'unpause', + name: 'upgradeAndCall', outputs: [], }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], - }, - { stateMutability: 'payable', type: 'receive' }, ] as const /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) */ -export const optimismPortalAddress = { - 1: '0xbEb5Fc579115071764c7423A4f12eDde41f106Ed', +export const proxyAdminAddress = { + 1: '0x4200000000000000000000000000000000000018', + 5: '0x4200000000000000000000000000000000000018', } as const /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) */ -export const optimismPortalConfig = { - address: optimismPortalAddress, - abi: optimismPortalABI, +export const proxyAdminConfig = { + address: proxyAdminAddress, + abi: proxyAdminABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// OptimismPortal_goerli +// SchemaRegistry ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x6232208d66bAc2305b46b4Cb6BCB3857B298DF13) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2545fa928d5d278cA75Fd47306e4a89096ff6403) */ -export const optimismPortalGoerliABI = [ +export const schemaRegistryABI = [ { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, + { type: 'error', inputs: [], name: 'AlreadyExists' }, { type: 'event', anonymous: false, inputs: [ - { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, - ], - name: 'Initialized', - }, - { - type: 'event', - anonymous: false, - inputs: [ + { name: 'uid', internalType: 'bytes32', type: 'bytes32', indexed: true }, { - name: 'account', + name: 'registerer', internalType: 'address', type: 'address', indexed: false, }, ], - name: 'Paused', + name: 'Registered', }, { - type: 'event', - anonymous: false, - inputs: [ - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, - { - name: 'version', - internalType: 'uint256', - type: 'uint256', - indexed: true, - }, + stateMutability: 'view', + type: 'function', + inputs: [{ name: 'uid', internalType: 'bytes32', type: 'bytes32' }], + name: 'getSchema', + outputs: [ { - name: 'opaqueData', - internalType: 'bytes', - type: 'bytes', - indexed: false, + name: '', + internalType: 'struct SchemaRecord', + type: 'tuple', + components: [ + { name: 'uid', internalType: 'bytes32', type: 'bytes32' }, + { + name: 'resolver', + internalType: 'contract ISchemaResolver', + type: 'address', + }, + { name: 'revocable', internalType: 'bool', type: 'bool' }, + { name: 'schema', internalType: 'string', type: 'string' }, + ], }, ], - name: 'TransactionDeposited', }, { - type: 'event', - anonymous: false, + stateMutability: 'nonpayable', + type: 'function', inputs: [ + { name: 'schema', internalType: 'string', type: 'string' }, { - name: 'account', - internalType: 'address', + name: 'resolver', + internalType: 'contract ISchemaResolver', type: 'address', - indexed: false, }, + { name: 'revocable', internalType: 'bool', type: 'bool' }, ], - name: 'Unpaused', + name: 'register', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'withdrawalHash', - internalType: 'bytes32', - type: 'bytes32', - indexed: true, - }, - { name: 'success', internalType: 'bool', type: 'bool', indexed: false }, - ], - name: 'WithdrawalFinalized', + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'version', + outputs: [{ name: '', internalType: 'string', type: 'string' }], + }, +] as const + +/** + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x6232208d66bAc2305b46b4Cb6BCB3857B298DF13) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2545fa928d5d278cA75Fd47306e4a89096ff6403) + */ +export const schemaRegistryAddress = { + 10: '0x6232208d66bAc2305b46b4Cb6BCB3857B298DF13', + 420: '0x2545fa928d5d278cA75Fd47306e4a89096ff6403', +} as const + +/** + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x6232208d66bAc2305b46b4Cb6BCB3857B298DF13) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2545fa928d5d278cA75Fd47306e4a89096ff6403) + */ +export const schemaRegistryConfig = { + address: schemaRegistryAddress, + abi: schemaRegistryABI, +} as const + +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// SequencerFeeVault +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/** + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000011) + */ +export const sequencerFeeVaultABI = [ + { + stateMutability: 'nonpayable', + type: 'constructor', + inputs: [{ name: '_recipient', internalType: 'address', type: 'address' }], }, { type: 'event', anonymous: false, inputs: [ { - name: 'withdrawalHash', - internalType: 'bytes32', - type: 'bytes32', - indexed: true, + name: 'value', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + { name: 'to', internalType: 'address', type: 'address', indexed: false }, + { + name: 'from', + internalType: 'address', + type: 'address', + indexed: false, }, - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, ], - name: 'WithdrawalProven', + name: 'Withdrawal', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'GUARDIAN', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'MIN_WITHDRAWAL_AMOUNT', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'L2_ORACLE', - outputs: [ - { name: '', internalType: 'contract L2OutputOracle', type: 'address' }, - ], + name: 'RECIPIENT', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'SYSTEM_CONFIG', - outputs: [ - { name: '', internalType: 'contract SystemConfig', type: 'address' }, - ], + name: 'l1FeeWallet', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'payable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_value', internalType: 'uint256', type: 'uint256' }, - { name: '_gasLimit', internalType: 'uint64', type: 'uint64' }, - { name: '_isCreation', internalType: 'bool', type: 'bool' }, - { name: '_data', internalType: 'bytes', type: 'bytes' }, - ], - name: 'depositTransaction', - outputs: [], + inputs: [], + name: 'totalProcessed', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { - stateMutability: 'payable', + stateMutability: 'view', type: 'function', inputs: [], - name: 'donateETH', - outputs: [], + name: 'version', + outputs: [{ name: '', internalType: 'string', type: 'string' }], }, { stateMutability: 'nonpayable', type: 'function', + inputs: [], + name: 'withdraw', + outputs: [], + }, + { stateMutability: 'payable', type: 'receive' }, +] as const + +/** + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000011) + */ +export const sequencerFeeVaultAddress = { + 420: '0x4200000000000000000000000000000000000011', +} as const + +/** + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000011) + */ +export const sequencerFeeVaultConfig = { + address: sequencerFeeVaultAddress, + abi: sequencerFeeVaultABI, +} as const + +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// SystemConfig +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/** + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) + */ +export const systemConfigABI = [ + { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, + { + type: 'event', + anonymous: false, inputs: [ { - name: '_tx', - internalType: 'struct Types.WithdrawalTransaction', - type: 'tuple', - components: [ - { name: 'nonce', internalType: 'uint256', type: 'uint256' }, - { name: 'sender', internalType: 'address', type: 'address' }, - { name: 'target', internalType: 'address', type: 'address' }, - { name: 'value', internalType: 'uint256', type: 'uint256' }, - { name: 'gasLimit', internalType: 'uint256', type: 'uint256' }, - { name: 'data', internalType: 'bytes', type: 'bytes' }, - ], + name: 'version', + internalType: 'uint256', + type: 'uint256', + indexed: true, + }, + { + name: 'updateType', + internalType: 'enum SystemConfig.UpdateType', + type: 'uint8', + indexed: true, }, + { name: 'data', internalType: 'bytes', type: 'bytes', indexed: false }, ], - name: 'finalizeWithdrawalTransaction', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - name: 'finalizedWithdrawals', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + name: 'ConfigUpdate', }, { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'guardian', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + type: 'event', + anonymous: false, + inputs: [ + { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, + ], + name: 'Initialized', }, { - stateMutability: 'nonpayable', - type: 'function', + type: 'event', + anonymous: false, inputs: [ { - name: '_l2Oracle', - internalType: 'contract L2OutputOracle', + name: 'previousOwner', + internalType: 'address', type: 'address', + indexed: true, }, - { name: '_guardian', internalType: 'address', type: 'address' }, { - name: '_systemConfig', - internalType: 'contract SystemConfig', + name: 'newOwner', + internalType: 'address', type: 'address', + indexed: true, }, - { name: '_paused', internalType: 'bool', type: 'bool' }, ], - name: 'initialize', - outputs: [], + name: 'OwnershipTransferred', }, { stateMutability: 'view', type: 'function', - inputs: [ - { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, - ], - name: 'isOutputFinalized', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + inputs: [], + name: 'BATCH_INBOX_SLOT', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'l2Oracle', - outputs: [ - { name: '', internalType: 'contract L2OutputOracle', type: 'address' }, - ], + name: 'L1_CROSS_DOMAIN_MESSENGER_SLOT', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'l2Sender', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'L1_ERC_721_BRIDGE_SLOT', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { - stateMutability: 'pure', + stateMutability: 'view', type: 'function', - inputs: [{ name: '_byteCount', internalType: 'uint64', type: 'uint64' }], - name: 'minimumGasLimit', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + inputs: [], + name: 'L1_STANDARD_BRIDGE_SLOT', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'params', - outputs: [ - { name: 'prevBaseFee', internalType: 'uint128', type: 'uint128' }, - { name: 'prevBoughtGas', internalType: 'uint64', type: 'uint64' }, - { name: 'prevBlockNum', internalType: 'uint64', type: 'uint64' }, - ], + name: 'L2_OUTPUT_ORACLE_SLOT', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', inputs: [], - name: 'pause', - outputs: [], + name: 'OPTIMISM_MINTABLE_ERC20_FACTORY_SLOT', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'paused', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + name: 'OPTIMISM_PORTAL_SLOT', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [ - { - name: '_tx', - internalType: 'struct Types.WithdrawalTransaction', - type: 'tuple', - components: [ - { name: 'nonce', internalType: 'uint256', type: 'uint256' }, - { name: 'sender', internalType: 'address', type: 'address' }, - { name: 'target', internalType: 'address', type: 'address' }, - { name: 'value', internalType: 'uint256', type: 'uint256' }, - { name: 'gasLimit', internalType: 'uint256', type: 'uint256' }, - { name: 'data', internalType: 'bytes', type: 'bytes' }, - ], - }, - { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, - { - name: '_outputRootProof', - internalType: 'struct Types.OutputRootProof', - type: 'tuple', - components: [ - { name: 'version', internalType: 'bytes32', type: 'bytes32' }, - { name: 'stateRoot', internalType: 'bytes32', type: 'bytes32' }, - { - name: 'messagePasserStorageRoot', - internalType: 'bytes32', - type: 'bytes32', - }, - { name: 'latestBlockhash', internalType: 'bytes32', type: 'bytes32' }, - ], - }, - { name: '_withdrawalProof', internalType: 'bytes[]', type: 'bytes[]' }, - ], - name: 'proveWithdrawalTransaction', - outputs: [], + inputs: [], + name: 'UNSAFE_BLOCK_SIGNER_SLOT', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { stateMutability: 'view', type: 'function', - inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - name: 'provenWithdrawals', - outputs: [ - { name: 'outputRoot', internalType: 'bytes32', type: 'bytes32' }, - { name: 'timestamp', internalType: 'uint128', type: 'uint128' }, - { name: 'l2OutputIndex', internalType: 'uint128', type: 'uint128' }, - ], + inputs: [], + name: 'VERSION', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'systemConfig', - outputs: [ - { name: '', internalType: 'contract SystemConfig', type: 'address' }, - ], + name: 'batchInbox', + outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', inputs: [], - name: 'unpause', - outputs: [], + name: 'batcherHash', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + name: 'gasLimit', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], }, - { stateMutability: 'payable', type: 'receive' }, -] as const - -/** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) - */ -export const optimismPortalGoerliAddress = { - 5: '0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383', -} as const - -/** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) - */ -export const optimismPortalGoerliConfig = { - address: optimismPortalGoerliAddress, - abi: optimismPortalGoerliABI, -} as const - -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// Optimist -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - */ -export const optimistABI = [ { stateMutability: 'nonpayable', - type: 'constructor', - inputs: [ - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_symbol', internalType: 'string', type: 'string' }, - { name: '_baseURIAttestor', internalType: 'address', type: 'address' }, - { - name: '_attestationStation', - internalType: 'contract AttestationStation', - type: 'address', - }, - { - name: '_optimistAllowlist', - internalType: 'contract OptimistAllowlist', - type: 'address', - }, - ], - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'owner', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'approved', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'tokenId', - internalType: 'uint256', - type: 'uint256', - indexed: true, - }, - ], - name: 'Approval', - }, - { - type: 'event', - anonymous: false, + type: 'function', inputs: [ + { name: '_owner', internalType: 'address', type: 'address' }, + { name: '_overhead', internalType: 'uint256', type: 'uint256' }, + { name: '_scalar', internalType: 'uint256', type: 'uint256' }, + { name: '_batcherHash', internalType: 'bytes32', type: 'bytes32' }, + { name: '_gasLimit', internalType: 'uint64', type: 'uint64' }, + { name: '_unsafeBlockSigner', internalType: 'address', type: 'address' }, { - name: 'owner', - internalType: 'address', - type: 'address', - indexed: true, + name: '_config', + internalType: 'struct ResourceMetering.ResourceConfig', + type: 'tuple', + components: [ + { name: 'maxResourceLimit', internalType: 'uint32', type: 'uint32' }, + { + name: 'elasticityMultiplier', + internalType: 'uint8', + type: 'uint8', + }, + { + name: 'baseFeeMaxChangeDenominator', + internalType: 'uint8', + type: 'uint8', + }, + { name: 'minimumBaseFee', internalType: 'uint32', type: 'uint32' }, + { name: 'systemTxMaxGas', internalType: 'uint32', type: 'uint32' }, + { name: 'maximumBaseFee', internalType: 'uint128', type: 'uint128' }, + ], }, + { name: '_startBlock', internalType: 'uint256', type: 'uint256' }, + { name: '_batchInbox', internalType: 'address', type: 'address' }, { - name: 'operator', - internalType: 'address', - type: 'address', - indexed: true, + name: '_addresses', + internalType: 'struct SystemConfig.Addresses', + type: 'tuple', + components: [ + { + name: 'l1CrossDomainMessenger', + internalType: 'address', + type: 'address', + }, + { name: 'l1ERC721Bridge', internalType: 'address', type: 'address' }, + { + name: 'l1StandardBridge', + internalType: 'address', + type: 'address', + }, + { name: 'l2OutputOracle', internalType: 'address', type: 'address' }, + { name: 'optimismPortal', internalType: 'address', type: 'address' }, + { + name: 'optimismMintableERC20Factory', + internalType: 'address', + type: 'address', + }, + ], }, - { name: 'approved', internalType: 'bool', type: 'bool', indexed: false }, ], - name: 'ApprovalForAll', + name: 'initialize', + outputs: [], }, { - type: 'event', - anonymous: false, - inputs: [ - { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, - ], - name: 'Initialized', + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'l1CrossDomainMessenger', + outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], }, { - type: 'event', - anonymous: false, - inputs: [ - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, - { - name: 'tokenId', - internalType: 'uint256', - type: 'uint256', - indexed: true, - }, - ], - name: 'Transfer', + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'l1ERC721Bridge', + outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'ATTESTATION_STATION', - outputs: [ - { - name: '', - internalType: 'contract AttestationStation', - type: 'address', - }, - ], + name: 'l1StandardBridge', + outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'BASE_URI_ATTESTATION_KEY', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'l2OutputOracle', + outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'BASE_URI_ATTESTOR', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'minimumGasLimit', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'OPTIMIST_ALLOWLIST', - outputs: [ - { name: '', internalType: 'contract OptimistAllowlist', type: 'address' }, - ], + name: 'optimismMintableERC20Factory', + outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], }, { - stateMutability: 'pure', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '', internalType: 'address', type: 'address' }, - { name: '', internalType: 'uint256', type: 'uint256' }, - ], - name: 'approve', - outputs: [], + inputs: [], + name: 'optimismPortal', + outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', - inputs: [{ name: 'owner', internalType: 'address', type: 'address' }], - name: 'balanceOf', + inputs: [], + name: 'overhead', outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'baseURI', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + name: 'owner', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [{ name: 'tokenId', internalType: 'uint256', type: 'uint256' }], - name: 'burn', + inputs: [], + name: 'renounceOwnership', outputs: [], }, { stateMutability: 'view', type: 'function', - inputs: [{ name: 'tokenId', internalType: 'uint256', type: 'uint256' }], - name: 'getApproved', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_symbol', internalType: 'string', type: 'string' }, - ], - name: 'initialize', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [ - { name: 'owner', internalType: 'address', type: 'address' }, - { name: 'operator', internalType: 'address', type: 'address' }, + inputs: [], + name: 'resourceConfig', + outputs: [ + { + name: '', + internalType: 'struct ResourceMetering.ResourceConfig', + type: 'tuple', + components: [ + { name: 'maxResourceLimit', internalType: 'uint32', type: 'uint32' }, + { + name: 'elasticityMultiplier', + internalType: 'uint8', + type: 'uint8', + }, + { + name: 'baseFeeMaxChangeDenominator', + internalType: 'uint8', + type: 'uint8', + }, + { name: 'minimumBaseFee', internalType: 'uint32', type: 'uint32' }, + { name: 'systemTxMaxGas', internalType: 'uint32', type: 'uint32' }, + { name: 'maximumBaseFee', internalType: 'uint128', type: 'uint128' }, + ], + }, ], - name: 'isApprovedForAll', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { stateMutability: 'view', type: 'function', - inputs: [{ name: '_recipient', internalType: 'address', type: 'address' }], - name: 'isOnAllowList', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + inputs: [], + name: 'scalar', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [{ name: '_recipient', internalType: 'address', type: 'address' }], - name: 'mint', + inputs: [ + { name: '_batcherHash', internalType: 'bytes32', type: 'bytes32' }, + ], + name: 'setBatcherHash', outputs: [], }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'name', - outputs: [{ name: '', internalType: 'string', type: 'string' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [{ name: 'tokenId', internalType: 'uint256', type: 'uint256' }], - name: 'ownerOf', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: 'from', internalType: 'address', type: 'address' }, - { name: 'to', internalType: 'address', type: 'address' }, - { name: 'tokenId', internalType: 'uint256', type: 'uint256' }, + { name: '_overhead', internalType: 'uint256', type: 'uint256' }, + { name: '_scalar', internalType: 'uint256', type: 'uint256' }, ], - name: 'safeTransferFrom', + name: 'setGasConfig', outputs: [], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [ - { name: 'from', internalType: 'address', type: 'address' }, - { name: 'to', internalType: 'address', type: 'address' }, - { name: 'tokenId', internalType: 'uint256', type: 'uint256' }, - { name: 'data', internalType: 'bytes', type: 'bytes' }, - ], - name: 'safeTransferFrom', + inputs: [{ name: '_gasLimit', internalType: 'uint64', type: 'uint64' }], + name: 'setGasLimit', outputs: [], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '', internalType: 'address', type: 'address' }, - { name: '', internalType: 'bool', type: 'bool' }, + { + name: '_config', + internalType: 'struct ResourceMetering.ResourceConfig', + type: 'tuple', + components: [ + { name: 'maxResourceLimit', internalType: 'uint32', type: 'uint32' }, + { + name: 'elasticityMultiplier', + internalType: 'uint8', + type: 'uint8', + }, + { + name: 'baseFeeMaxChangeDenominator', + internalType: 'uint8', + type: 'uint8', + }, + { name: 'minimumBaseFee', internalType: 'uint32', type: 'uint32' }, + { name: 'systemTxMaxGas', internalType: 'uint32', type: 'uint32' }, + { name: 'maximumBaseFee', internalType: 'uint128', type: 'uint128' }, + ], + }, ], - name: 'setApprovalForAll', + name: 'setResourceConfig', outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [{ name: 'interfaceId', internalType: 'bytes4', type: 'bytes4' }], - name: 'supportsInterface', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + inputs: [ + { name: '_unsafeBlockSigner', internalType: 'address', type: 'address' }, + ], + name: 'setUnsafeBlockSigner', + outputs: [], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'symbol', - outputs: [{ name: '', internalType: 'string', type: 'string' }], - }, - { - stateMutability: 'pure', - type: 'function', - inputs: [{ name: '_owner', internalType: 'address', type: 'address' }], - name: 'tokenIdOfAddress', + name: 'startBlock', outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [{ name: '_tokenId', internalType: 'uint256', type: 'uint256' }], - name: 'tokenURI', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], + name: 'transferOwnership', + outputs: [], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: 'from', internalType: 'address', type: 'address' }, - { name: 'to', internalType: 'address', type: 'address' }, - { name: 'tokenId', internalType: 'uint256', type: 'uint256' }, - ], - name: 'transferFrom', - outputs: [], + inputs: [], + name: 'unsafeBlockSigner', + outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', @@ -8123,407 +7992,619 @@ export const optimistABI = [ ] as const /** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) */ -export const optimistAddress = { - 10: '0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5', - 420: '0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5', +export const systemConfigAddress = { + 1: '0x229047fed2591dbec1eF1118d64F7aF3dB9EB290', + 5: '0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60', } as const /** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) */ -export const optimistConfig = { - address: optimistAddress, - abi: optimistABI, +export const systemConfigConfig = { + address: systemConfigAddress, + abi: systemConfigABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// OptimistAllowlist +// SystemDictator ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) + * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) */ -export const optimistAllowlistABI = [ +export const systemDictatorABI = [ + { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, { - stateMutability: 'nonpayable', - type: 'constructor', + type: 'event', + anonymous: false, + inputs: [ + { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, + ], + name: 'Initialized', + }, + { + type: 'event', + anonymous: false, inputs: [ { - name: '_attestationStation', - internalType: 'contract AttestationStation', - type: 'address', - }, - { name: '_allowlistAttestor', internalType: 'address', type: 'address' }, - { - name: '_coinbaseQuestAttestor', + name: 'previousOwner', internalType: 'address', type: 'address', + indexed: true, }, - { name: '_optimistInviter', internalType: 'address', type: 'address' }, - ], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'ALLOWLIST_ATTESTOR', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'ATTESTATION_STATION', - outputs: [ { - name: '', - internalType: 'contract AttestationStation', + name: 'newOwner', + internalType: 'address', type: 'address', + indexed: true, }, ], + name: 'OwnershipTransferred', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'COINBASE_QUEST_ATTESTOR', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'COINBASE_QUEST_ELIGIBLE_ATTESTATION_KEY', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'OPTIMIST_CAN_MINT_ATTESTATION_KEY', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'EXIT_1_NO_RETURN_STEP', + outputs: [{ name: '', internalType: 'uint8', type: 'uint8' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'OPTIMIST_INVITER', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [{ name: '_claimer', internalType: 'address', type: 'address' }], - name: 'isAllowedToMint', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + name: 'PROXY_TRANSFER_STEP', + outputs: [{ name: '', internalType: 'uint8', type: 'uint8' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], - }, -] as const - -/** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) - */ -export const optimistAllowlistAddress = { - 10: '0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180', - 420: '0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180', -} as const - -/** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) - */ -export const optimistAllowlistConfig = { - address: optimistAllowlistAddress, - abi: optimistAllowlistABI, -} as const - -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// OptimistInviter -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - */ -export const optimistInviterABI = [ - { - stateMutability: 'nonpayable', - type: 'constructor', - inputs: [ - { name: '_inviteGranter', internalType: 'address', type: 'address' }, + name: 'config', + outputs: [ { - name: '_attestationStation', - internalType: 'contract AttestationStation', - type: 'address', + name: 'globalConfig', + internalType: 'struct SystemDictator.GlobalConfig', + type: 'tuple', + components: [ + { + name: 'addressManager', + internalType: 'contract AddressManager', + type: 'address', + }, + { + name: 'proxyAdmin', + internalType: 'contract ProxyAdmin', + type: 'address', + }, + { name: 'controller', internalType: 'address', type: 'address' }, + { name: 'finalOwner', internalType: 'address', type: 'address' }, + ], }, - ], - }, - { - type: 'event', - anonymous: false, - inputs: [ - { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, - ], - name: 'Initialized', - }, - { - type: 'event', - anonymous: false, - inputs: [ { - name: 'issuer', - internalType: 'address', - type: 'address', - indexed: true, + name: 'proxyAddressConfig', + internalType: 'struct SystemDictator.ProxyAddressConfig', + type: 'tuple', + components: [ + { + name: 'l2OutputOracleProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'optimismPortalProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'l1CrossDomainMessengerProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'l1StandardBridgeProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'optimismMintableERC20FactoryProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'l1ERC721BridgeProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'systemConfigProxy', + internalType: 'address', + type: 'address', + }, + ], }, { - name: 'claimer', - internalType: 'address', - type: 'address', - indexed: true, + name: 'implementationAddressConfig', + internalType: 'struct SystemDictator.ImplementationAddressConfig', + type: 'tuple', + components: [ + { + name: 'l2OutputOracleImpl', + internalType: 'contract L2OutputOracle', + type: 'address', + }, + { + name: 'optimismPortalImpl', + internalType: 'contract OptimismPortal', + type: 'address', + }, + { + name: 'l1CrossDomainMessengerImpl', + internalType: 'contract L1CrossDomainMessenger', + type: 'address', + }, + { + name: 'l1StandardBridgeImpl', + internalType: 'contract L1StandardBridge', + type: 'address', + }, + { + name: 'optimismMintableERC20FactoryImpl', + internalType: 'contract OptimismMintableERC20Factory', + type: 'address', + }, + { + name: 'l1ERC721BridgeImpl', + internalType: 'contract L1ERC721Bridge', + type: 'address', + }, + { + name: 'portalSenderImpl', + internalType: 'contract PortalSender', + type: 'address', + }, + { + name: 'systemConfigImpl', + internalType: 'contract SystemConfig', + type: 'address', + }, + ], + }, + { + name: 'systemConfigConfig', + internalType: 'struct SystemDictator.SystemConfigConfig', + type: 'tuple', + components: [ + { name: 'owner', internalType: 'address', type: 'address' }, + { name: 'overhead', internalType: 'uint256', type: 'uint256' }, + { name: 'scalar', internalType: 'uint256', type: 'uint256' }, + { name: 'batcherHash', internalType: 'bytes32', type: 'bytes32' }, + { name: 'gasLimit', internalType: 'uint64', type: 'uint64' }, + { + name: 'unsafeBlockSigner', + internalType: 'address', + type: 'address', + }, + { + name: 'resourceConfig', + internalType: 'struct ResourceMetering.ResourceConfig', + type: 'tuple', + components: [ + { + name: 'maxResourceLimit', + internalType: 'uint32', + type: 'uint32', + }, + { + name: 'elasticityMultiplier', + internalType: 'uint8', + type: 'uint8', + }, + { + name: 'baseFeeMaxChangeDenominator', + internalType: 'uint8', + type: 'uint8', + }, + { + name: 'minimumBaseFee', + internalType: 'uint32', + type: 'uint32', + }, + { + name: 'systemTxMaxGas', + internalType: 'uint32', + type: 'uint32', + }, + { + name: 'maximumBaseFee', + internalType: 'uint128', + type: 'uint128', + }, + ], + }, + ], }, ], - name: 'InviteClaimed', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'ATTESTATION_STATION', - outputs: [ - { - name: '', - internalType: 'contract AttestationStation', - type: 'address', - }, - ], + name: 'currentStep', + outputs: [{ name: '', internalType: 'uint8', type: 'uint8' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'CAN_INVITE_ATTESTATION_KEY', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'dynamicConfigSet', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', inputs: [], - name: 'CLAIMABLE_INVITE_TYPEHASH', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'exit1', + outputs: [], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'EIP712_VERSION', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + name: 'exited', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', inputs: [], - name: 'INVITE_GRANTER', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'finalize', + outputs: [], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'MIN_COMMITMENT_PERIOD', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'finalized', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_claimer', internalType: 'address', type: 'address' }, { - name: '_claimableInvite', - internalType: 'struct OptimistInviter.ClaimableInvite', + name: '_config', + internalType: 'struct SystemDictator.DeployConfig', type: 'tuple', components: [ - { name: 'issuer', internalType: 'address', type: 'address' }, - { name: 'nonce', internalType: 'bytes32', type: 'bytes32' }, - ], - }, - { name: '_signature', internalType: 'bytes', type: 'bytes' }, - ], - name: 'claimInvite', + { + name: 'globalConfig', + internalType: 'struct SystemDictator.GlobalConfig', + type: 'tuple', + components: [ + { + name: 'addressManager', + internalType: 'contract AddressManager', + type: 'address', + }, + { + name: 'proxyAdmin', + internalType: 'contract ProxyAdmin', + type: 'address', + }, + { name: 'controller', internalType: 'address', type: 'address' }, + { name: 'finalOwner', internalType: 'address', type: 'address' }, + ], + }, + { + name: 'proxyAddressConfig', + internalType: 'struct SystemDictator.ProxyAddressConfig', + type: 'tuple', + components: [ + { + name: 'l2OutputOracleProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'optimismPortalProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'l1CrossDomainMessengerProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'l1StandardBridgeProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'optimismMintableERC20FactoryProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'l1ERC721BridgeProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'systemConfigProxy', + internalType: 'address', + type: 'address', + }, + ], + }, + { + name: 'implementationAddressConfig', + internalType: 'struct SystemDictator.ImplementationAddressConfig', + type: 'tuple', + components: [ + { + name: 'l2OutputOracleImpl', + internalType: 'contract L2OutputOracle', + type: 'address', + }, + { + name: 'optimismPortalImpl', + internalType: 'contract OptimismPortal', + type: 'address', + }, + { + name: 'l1CrossDomainMessengerImpl', + internalType: 'contract L1CrossDomainMessenger', + type: 'address', + }, + { + name: 'l1StandardBridgeImpl', + internalType: 'contract L1StandardBridge', + type: 'address', + }, + { + name: 'optimismMintableERC20FactoryImpl', + internalType: 'contract OptimismMintableERC20Factory', + type: 'address', + }, + { + name: 'l1ERC721BridgeImpl', + internalType: 'contract L1ERC721Bridge', + type: 'address', + }, + { + name: 'portalSenderImpl', + internalType: 'contract PortalSender', + type: 'address', + }, + { + name: 'systemConfigImpl', + internalType: 'contract SystemConfig', + type: 'address', + }, + ], + }, + { + name: 'systemConfigConfig', + internalType: 'struct SystemDictator.SystemConfigConfig', + type: 'tuple', + components: [ + { name: 'owner', internalType: 'address', type: 'address' }, + { name: 'overhead', internalType: 'uint256', type: 'uint256' }, + { name: 'scalar', internalType: 'uint256', type: 'uint256' }, + { name: 'batcherHash', internalType: 'bytes32', type: 'bytes32' }, + { name: 'gasLimit', internalType: 'uint64', type: 'uint64' }, + { + name: 'unsafeBlockSigner', + internalType: 'address', + type: 'address', + }, + { + name: 'resourceConfig', + internalType: 'struct ResourceMetering.ResourceConfig', + type: 'tuple', + components: [ + { + name: 'maxResourceLimit', + internalType: 'uint32', + type: 'uint32', + }, + { + name: 'elasticityMultiplier', + internalType: 'uint8', + type: 'uint8', + }, + { + name: 'baseFeeMaxChangeDenominator', + internalType: 'uint8', + type: 'uint8', + }, + { + name: 'minimumBaseFee', + internalType: 'uint32', + type: 'uint32', + }, + { + name: 'systemTxMaxGas', + internalType: 'uint32', + type: 'uint32', + }, + { + name: 'maximumBaseFee', + internalType: 'uint128', + type: 'uint128', + }, + ], + }, + ], + }, + ], + }, + ], + name: 'initialize', outputs: [], }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'l2OutputOracleDynamicConfig', + outputs: [ + { + name: 'l2OutputOracleStartingBlockNumber', + internalType: 'uint256', + type: 'uint256', + }, + { + name: 'l2OutputOracleStartingTimestamp', + internalType: 'uint256', + type: 'uint256', + }, + ], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'oldL1CrossDomainMessenger', + outputs: [{ name: '', internalType: 'address', type: 'address' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'optimismPortalDynamicConfig', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'owner', + outputs: [{ name: '', internalType: 'address', type: 'address' }], + }, { stateMutability: 'nonpayable', type: 'function', - inputs: [{ name: '_commitment', internalType: 'bytes32', type: 'bytes32' }], - name: 'commitInvite', + inputs: [], + name: 'phase1', outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - name: 'commitmentTimestamps', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + inputs: [], + name: 'phase2', + outputs: [], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [{ name: '_name', internalType: 'string', type: 'string' }], - name: 'initialize', + inputs: [], + name: 'renounceOwnership', outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [{ name: '', internalType: 'address', type: 'address' }], - name: 'inviteCounts', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + inputs: [], + name: 'step1', + outputs: [], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [ - { name: '_accounts', internalType: 'address[]', type: 'address[]' }, - { name: '_inviteCount', internalType: 'uint256', type: 'uint256' }, - ], - name: 'setInviteCounts', + inputs: [], + name: 'step2', outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [ - { name: '', internalType: 'address', type: 'address' }, - { name: '', internalType: 'bytes32', type: 'bytes32' }, - ], - name: 'usedNonces', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + inputs: [], + name: 'step3', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + name: 'step4', + outputs: [], }, -] as const - -/** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - */ -export const optimistInviterAddress = { - 10: '0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929', - 420: '0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929', -} as const - -/** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - */ -export const optimistInviterConfig = { - address: optimistInviterAddress, - abi: optimistInviterABI, -} as const - -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// PortalSender -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/** - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x0A893d9576b9cFD9EF78595963dc973238E78210) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xe7FACd39531ee3C313330E93B4d7a8B8A3c84Aa4) - */ -export const portalSenderABI = [ { stateMutability: 'nonpayable', - type: 'constructor', - inputs: [ - { - name: '_portal', - internalType: 'contract OptimismPortal', - type: 'address', - }, - ], + type: 'function', + inputs: [], + name: 'step5', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'PORTAL', - outputs: [ - { name: '', internalType: 'contract OptimismPortal', type: 'address' }, - ], + inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], + name: 'transferOwnership', + outputs: [], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'donate', + inputs: [ + { + name: '_l2OutputOracleDynamicConfig', + internalType: 'struct SystemDictator.L2OutputOracleDynamicConfig', + type: 'tuple', + components: [ + { + name: 'l2OutputOracleStartingBlockNumber', + internalType: 'uint256', + type: 'uint256', + }, + { + name: 'l2OutputOracleStartingTimestamp', + internalType: 'uint256', + type: 'uint256', + }, + ], + }, + { + name: '_optimismPortalDynamicConfig', + internalType: 'bool', + type: 'bool', + }, + ], + name: 'updateDynamicConfig', outputs: [], }, ] as const /** - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x0A893d9576b9cFD9EF78595963dc973238E78210) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xe7FACd39531ee3C313330E93B4d7a8B8A3c84Aa4) + * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) */ -export const portalSenderAddress = { - 1: '0x0A893d9576b9cFD9EF78595963dc973238E78210', - 5: '0xe7FACd39531ee3C313330E93B4d7a8B8A3c84Aa4', +export const systemDictatorAddress = { + 1: '0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB', } as const /** - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x0A893d9576b9cFD9EF78595963dc973238E78210) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xe7FACd39531ee3C313330E93B4d7a8B8A3c84Aa4) + * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) */ -export const portalSenderConfig = { - address: portalSenderAddress, - abi: portalSenderABI, +export const systemDictatorConfig = { + address: systemDictatorAddress, + abi: systemDictatorABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// ProtocolVersions +// SystemDictator_goerli ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) + * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) */ -export const protocolVersionsABI = [ - { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'version', - internalType: 'uint256', - type: 'uint256', - indexed: true, - }, - { - name: 'updateType', - internalType: 'enum ProtocolVersions.UpdateType', - type: 'uint8', - indexed: true, - }, - { name: 'data', internalType: 'bytes', type: 'bytes', indexed: false }, - ], - name: 'ConfigUpdate', - }, +export const systemDictatorGoerliABI = [ { type: 'event', anonymous: false, @@ -8555,6586 +8636,2102 @@ export const protocolVersionsABI = [ stateMutability: 'view', type: 'function', inputs: [], - name: 'RECOMMENDED_SLOT', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'EXIT_1_NO_RETURN_STEP', + outputs: [{ name: '', internalType: 'uint8', type: 'uint8' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'REQUIRED_SLOT', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'PROXY_TRANSFER_STEP', + outputs: [{ name: '', internalType: 'uint8', type: 'uint8' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'VERSION', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_owner', internalType: 'address', type: 'address' }, - { name: '_required', internalType: 'ProtocolVersion', type: 'uint256' }, + name: 'config', + outputs: [ { - name: '_recommended', - internalType: 'ProtocolVersion', - type: 'uint256', + name: 'globalConfig', + internalType: 'struct SystemDictator.GlobalConfig', + type: 'tuple', + components: [ + { + name: 'addressManager', + internalType: 'contract AddressManager', + type: 'address', + }, + { + name: 'proxyAdmin', + internalType: 'contract ProxyAdmin', + type: 'address', + }, + { name: 'controller', internalType: 'address', type: 'address' }, + { name: 'finalOwner', internalType: 'address', type: 'address' }, + ], }, - ], - name: 'initialize', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'owner', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'recommended', - outputs: [ - { name: 'out_', internalType: 'ProtocolVersion', type: 'uint256' }, - ], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'renounceOwnership', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'required', - outputs: [ - { name: 'out_', internalType: 'ProtocolVersion', type: 'uint256' }, - ], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ { - name: '_recommended', - internalType: 'ProtocolVersion', - type: 'uint256', + name: 'proxyAddressConfig', + internalType: 'struct SystemDictator.ProxyAddressConfig', + type: 'tuple', + components: [ + { + name: 'l2OutputOracleProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'optimismPortalProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'l1CrossDomainMessengerProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'l1StandardBridgeProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'optimismMintableERC20FactoryProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'l1ERC721BridgeProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'systemConfigProxy', + internalType: 'address', + type: 'address', + }, + ], }, - ], - name: 'setRecommended', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_required', internalType: 'ProtocolVersion', type: 'uint256' }, - ], - name: 'setRequired', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], - name: 'transferOwnership', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], - }, -] as const - -/** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) - */ -export const protocolVersionsAddress = { - 5: '0x0C24F5098774aA366827D667494e9F889f7cFc08', -} as const - -/** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) - */ -export const protocolVersionsConfig = { - address: protocolVersionsAddress, - abi: protocolVersionsABI, -} as const - -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// ProxyAdmin -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/** - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) - */ -export const proxyAdminABI = [ - { - stateMutability: 'nonpayable', - type: 'constructor', - inputs: [{ name: '_owner', internalType: 'address', type: 'address' }], - }, - { - type: 'event', - anonymous: false, - inputs: [ { - name: 'previousOwner', - internalType: 'address', - type: 'address', - indexed: true, + name: 'implementationAddressConfig', + internalType: 'struct SystemDictator.ImplementationAddressConfig', + type: 'tuple', + components: [ + { + name: 'l2OutputOracleImpl', + internalType: 'contract L2OutputOracle', + type: 'address', + }, + { + name: 'optimismPortalImpl', + internalType: 'contract OptimismPortal', + type: 'address', + }, + { + name: 'l1CrossDomainMessengerImpl', + internalType: 'contract L1CrossDomainMessenger', + type: 'address', + }, + { + name: 'l1StandardBridgeImpl', + internalType: 'contract L1StandardBridge', + type: 'address', + }, + { + name: 'optimismMintableERC20FactoryImpl', + internalType: 'contract OptimismMintableERC20Factory', + type: 'address', + }, + { + name: 'l1ERC721BridgeImpl', + internalType: 'contract L1ERC721Bridge', + type: 'address', + }, + { + name: 'portalSenderImpl', + internalType: 'contract PortalSender', + type: 'address', + }, + { + name: 'systemConfigImpl', + internalType: 'contract SystemConfig', + type: 'address', + }, + ], }, { - name: 'newOwner', - internalType: 'address', - type: 'address', - indexed: true, + name: 'systemConfigConfig', + internalType: 'struct SystemDictator.SystemConfigConfig', + type: 'tuple', + components: [ + { name: 'owner', internalType: 'address', type: 'address' }, + { name: 'overhead', internalType: 'uint256', type: 'uint256' }, + { name: 'scalar', internalType: 'uint256', type: 'uint256' }, + { name: 'batcherHash', internalType: 'bytes32', type: 'bytes32' }, + { name: 'gasLimit', internalType: 'uint64', type: 'uint64' }, + { + name: 'unsafeBlockSigner', + internalType: 'address', + type: 'address', + }, + ], }, ], - name: 'OwnershipTransferred', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'addressManager', - outputs: [ - { name: '', internalType: 'contract AddressManager', type: 'address' }, - ], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_proxy', internalType: 'address payable', type: 'address' }, - { name: '_newAdmin', internalType: 'address', type: 'address' }, - ], - name: 'changeProxyAdmin', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [ - { name: '_proxy', internalType: 'address payable', type: 'address' }, - ], - name: 'getProxyAdmin', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [{ name: '_proxy', internalType: 'address', type: 'address' }], - name: 'getProxyImplementation', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [{ name: '', internalType: 'address', type: 'address' }], - name: 'implementationName', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + name: 'currentStep', + outputs: [{ name: '', internalType: 'uint8', type: 'uint8' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'isUpgrading', + name: 'dynamicConfigSet', outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'owner', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [{ name: '', internalType: 'address', type: 'address' }], - name: 'proxyType', - outputs: [ - { name: '', internalType: 'enum ProxyAdmin.ProxyType', type: 'uint8' }, - ], - }, { stateMutability: 'nonpayable', type: 'function', inputs: [], - name: 'renounceOwnership', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_address', internalType: 'address', type: 'address' }, - ], - name: 'setAddress', + name: 'exit1', outputs: [], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [ - { - name: '_address', - internalType: 'contract AddressManager', - type: 'address', - }, - ], - name: 'setAddressManager', + inputs: [], + name: 'finalize', outputs: [], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_address', internalType: 'address', type: 'address' }, - { name: '_name', internalType: 'string', type: 'string' }, - ], - name: 'setImplementationName', - outputs: [], + inputs: [], + name: 'finalized', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_address', internalType: 'address', type: 'address' }, { - name: '_type', - internalType: 'enum ProxyAdmin.ProxyType', - type: 'uint8', - }, - ], - name: 'setProxyType', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: '_upgrading', internalType: 'bool', type: 'bool' }], - name: 'setUpgrading', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], - name: 'transferOwnership', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_proxy', internalType: 'address payable', type: 'address' }, - { name: '_implementation', internalType: 'address', type: 'address' }, - ], - name: 'upgrade', - outputs: [], - }, - { - stateMutability: 'payable', - type: 'function', - inputs: [ - { name: '_proxy', internalType: 'address payable', type: 'address' }, - { name: '_implementation', internalType: 'address', type: 'address' }, - { name: '_data', internalType: 'bytes', type: 'bytes' }, - ], - name: 'upgradeAndCall', - outputs: [], - }, -] as const - -/** - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) - */ -export const proxyAdminAddress = { - 1: '0x4200000000000000000000000000000000000018', - 5: '0x4200000000000000000000000000000000000018', -} as const - -/** - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) - */ -export const proxyAdminConfig = { - address: proxyAdminAddress, - abi: proxyAdminABI, -} as const - -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// SchemaRegistry -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x6232208d66bAc2305b46b4Cb6BCB3857B298DF13) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2545fa928d5d278cA75Fd47306e4a89096ff6403) - */ -export const schemaRegistryABI = [ - { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, - { type: 'error', inputs: [], name: 'AlreadyExists' }, - { - type: 'event', - anonymous: false, - inputs: [ - { name: 'uid', internalType: 'bytes32', type: 'bytes32', indexed: true }, - { - name: 'registerer', - internalType: 'address', - type: 'address', - indexed: false, - }, - ], - name: 'Registered', - }, - { - stateMutability: 'view', - type: 'function', - inputs: [{ name: 'uid', internalType: 'bytes32', type: 'bytes32' }], - name: 'getSchema', - outputs: [ - { - name: '', - internalType: 'struct SchemaRecord', + name: '_config', + internalType: 'struct SystemDictator.DeployConfig', type: 'tuple', components: [ - { name: 'uid', internalType: 'bytes32', type: 'bytes32' }, { - name: 'resolver', - internalType: 'contract ISchemaResolver', - type: 'address', + name: 'globalConfig', + internalType: 'struct SystemDictator.GlobalConfig', + type: 'tuple', + components: [ + { + name: 'addressManager', + internalType: 'contract AddressManager', + type: 'address', + }, + { + name: 'proxyAdmin', + internalType: 'contract ProxyAdmin', + type: 'address', + }, + { name: 'controller', internalType: 'address', type: 'address' }, + { name: 'finalOwner', internalType: 'address', type: 'address' }, + ], + }, + { + name: 'proxyAddressConfig', + internalType: 'struct SystemDictator.ProxyAddressConfig', + type: 'tuple', + components: [ + { + name: 'l2OutputOracleProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'optimismPortalProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'l1CrossDomainMessengerProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'l1StandardBridgeProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'optimismMintableERC20FactoryProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'l1ERC721BridgeProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'systemConfigProxy', + internalType: 'address', + type: 'address', + }, + ], + }, + { + name: 'implementationAddressConfig', + internalType: 'struct SystemDictator.ImplementationAddressConfig', + type: 'tuple', + components: [ + { + name: 'l2OutputOracleImpl', + internalType: 'contract L2OutputOracle', + type: 'address', + }, + { + name: 'optimismPortalImpl', + internalType: 'contract OptimismPortal', + type: 'address', + }, + { + name: 'l1CrossDomainMessengerImpl', + internalType: 'contract L1CrossDomainMessenger', + type: 'address', + }, + { + name: 'l1StandardBridgeImpl', + internalType: 'contract L1StandardBridge', + type: 'address', + }, + { + name: 'optimismMintableERC20FactoryImpl', + internalType: 'contract OptimismMintableERC20Factory', + type: 'address', + }, + { + name: 'l1ERC721BridgeImpl', + internalType: 'contract L1ERC721Bridge', + type: 'address', + }, + { + name: 'portalSenderImpl', + internalType: 'contract PortalSender', + type: 'address', + }, + { + name: 'systemConfigImpl', + internalType: 'contract SystemConfig', + type: 'address', + }, + ], + }, + { + name: 'systemConfigConfig', + internalType: 'struct SystemDictator.SystemConfigConfig', + type: 'tuple', + components: [ + { name: 'owner', internalType: 'address', type: 'address' }, + { name: 'overhead', internalType: 'uint256', type: 'uint256' }, + { name: 'scalar', internalType: 'uint256', type: 'uint256' }, + { name: 'batcherHash', internalType: 'bytes32', type: 'bytes32' }, + { name: 'gasLimit', internalType: 'uint64', type: 'uint64' }, + { + name: 'unsafeBlockSigner', + internalType: 'address', + type: 'address', + }, + ], }, - { name: 'revocable', internalType: 'bool', type: 'bool' }, - { name: 'schema', internalType: 'string', type: 'string' }, ], }, ], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: 'schema', internalType: 'string', type: 'string' }, - { - name: 'resolver', - internalType: 'contract ISchemaResolver', - type: 'address', - }, - { name: 'revocable', internalType: 'bool', type: 'bool' }, - ], - name: 'register', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'initialize', + outputs: [], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], - }, -] as const - -/** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x6232208d66bAc2305b46b4Cb6BCB3857B298DF13) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2545fa928d5d278cA75Fd47306e4a89096ff6403) - */ -export const schemaRegistryAddress = { - 10: '0x6232208d66bAc2305b46b4Cb6BCB3857B298DF13', - 420: '0x2545fa928d5d278cA75Fd47306e4a89096ff6403', -} as const - -/** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x6232208d66bAc2305b46b4Cb6BCB3857B298DF13) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2545fa928d5d278cA75Fd47306e4a89096ff6403) - */ -export const schemaRegistryConfig = { - address: schemaRegistryAddress, - abi: schemaRegistryABI, -} as const - -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// SequencerFeeVault -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000011) - */ -export const sequencerFeeVaultABI = [ - { - stateMutability: 'nonpayable', - type: 'constructor', - inputs: [{ name: '_recipient', internalType: 'address', type: 'address' }], - }, - { - type: 'event', - anonymous: false, - inputs: [ + name: 'l2OutputOracleDynamicConfig', + outputs: [ { - name: 'value', + name: 'l2OutputOracleStartingBlockNumber', internalType: 'uint256', type: 'uint256', - indexed: false, }, - { name: 'to', internalType: 'address', type: 'address', indexed: false }, { - name: 'from', - internalType: 'address', - type: 'address', - indexed: false, + name: 'l2OutputOracleStartingTimestamp', + internalType: 'uint256', + type: 'uint256', }, ], - name: 'Withdrawal', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'MIN_WITHDRAWAL_AMOUNT', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'oldL1CrossDomainMessenger', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'RECIPIENT', + name: 'owner', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', inputs: [], - name: 'l1FeeWallet', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'renounceOwnership', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', inputs: [], - name: 'totalProcessed', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'step1', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + name: 'step2', + outputs: [], }, { stateMutability: 'nonpayable', type: 'function', inputs: [], - name: 'withdraw', + name: 'step3', + outputs: [], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [], + name: 'step4', + outputs: [], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [], + name: 'step5', + outputs: [], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [], + name: 'step6', + outputs: [], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], + name: 'transferOwnership', + outputs: [], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { + name: '_l2OutputOracleDynamicConfig', + internalType: 'struct SystemDictator.L2OutputOracleDynamicConfig', + type: 'tuple', + components: [ + { + name: 'l2OutputOracleStartingBlockNumber', + internalType: 'uint256', + type: 'uint256', + }, + { + name: 'l2OutputOracleStartingTimestamp', + internalType: 'uint256', + type: 'uint256', + }, + ], + }, + ], + name: 'updateL2OutputOracleDynamicConfig', outputs: [], }, - { stateMutability: 'payable', type: 'receive' }, ] as const /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000011) + * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) */ -export const sequencerFeeVaultAddress = { - 420: '0x4200000000000000000000000000000000000011', +export const systemDictatorGoerliAddress = { + 5: '0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971', } as const /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000011) + * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) */ -export const sequencerFeeVaultConfig = { - address: sequencerFeeVaultAddress, - abi: sequencerFeeVaultABI, +export const systemDictatorGoerliConfig = { + address: systemDictatorGoerliAddress, + abi: systemDictatorGoerliABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// SystemConfig +// TeleportrWithdrawer ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) + * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) */ -export const systemConfigABI = [ +export const teleportrWithdrawerABI = [ { stateMutability: 'nonpayable', type: 'constructor', + inputs: [{ name: '_owner', internalType: 'address', type: 'address' }], + }, + { + type: 'event', + anonymous: false, inputs: [ - { name: '_owner', internalType: 'address', type: 'address' }, - { name: '_overhead', internalType: 'uint256', type: 'uint256' }, - { name: '_scalar', internalType: 'uint256', type: 'uint256' }, - { name: '_batcherHash', internalType: 'bytes32', type: 'bytes32' }, - { name: '_gasLimit', internalType: 'uint64', type: 'uint64' }, - { name: '_unsafeBlockSigner', internalType: 'address', type: 'address' }, + { name: 'user', internalType: 'address', type: 'address', indexed: true }, { - name: '_config', - internalType: 'struct ResourceMetering.ResourceConfig', - type: 'tuple', - components: [ - { name: 'maxResourceLimit', internalType: 'uint32', type: 'uint32' }, - { - name: 'elasticityMultiplier', - internalType: 'uint8', - type: 'uint8', - }, - { - name: 'baseFeeMaxChangeDenominator', - internalType: 'uint8', - type: 'uint8', - }, - { name: 'minimumBaseFee', internalType: 'uint32', type: 'uint32' }, - { name: 'systemTxMaxGas', internalType: 'uint32', type: 'uint32' }, - { name: 'maximumBaseFee', internalType: 'uint128', type: 'uint128' }, - ], + name: 'newOwner', + internalType: 'address', + type: 'address', + indexed: true, }, ], + name: 'OwnerUpdated', }, { type: 'event', anonymous: false, inputs: [ + { name: 'from', internalType: 'address', type: 'address', indexed: true }, { - name: 'version', + name: 'amount', internalType: 'uint256', type: 'uint256', + indexed: false, + }, + ], + name: 'ReceivedETH', + }, + { + type: 'event', + anonymous: false, + inputs: [ + { + name: 'withdrawer', + internalType: 'address', + type: 'address', indexed: true, }, { - name: 'updateType', - internalType: 'enum SystemConfig.UpdateType', - type: 'uint8', + name: 'recipient', + internalType: 'address', + type: 'address', indexed: true, }, - { name: 'data', internalType: 'bytes', type: 'bytes', indexed: false }, + { + name: 'asset', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'amount', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, ], - name: 'ConfigUpdate', + name: 'WithdrewERC20', }, { type: 'event', anonymous: false, inputs: [ - { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, + { + name: 'withdrawer', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'recipient', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'asset', + internalType: 'address', + type: 'address', + indexed: true, + }, + { name: 'id', internalType: 'uint256', type: 'uint256', indexed: false }, ], - name: 'Initialized', + name: 'WithdrewERC721', }, { type: 'event', anonymous: false, inputs: [ { - name: 'previousOwner', + name: 'withdrawer', internalType: 'address', type: 'address', indexed: true, }, { - name: 'newOwner', + name: 'recipient', internalType: 'address', type: 'address', indexed: true, }, + { + name: 'amount', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, ], - name: 'OwnershipTransferred', + name: 'WithdrewETH', }, { - stateMutability: 'view', + stateMutability: 'payable', type: 'function', - inputs: [], - name: 'UNSAFE_BLOCK_SIGNER_SLOT', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + inputs: [ + { name: '_target', internalType: 'address', type: 'address' }, + { name: '_data', internalType: 'bytes', type: 'bytes' }, + { name: '_gas', internalType: 'uint256', type: 'uint256' }, + { name: '_value', internalType: 'uint256', type: 'uint256' }, + ], + name: 'CALL', + outputs: [ + { name: '', internalType: 'bool', type: 'bool' }, + { name: '', internalType: 'bytes', type: 'bytes' }, + ], + }, + { + stateMutability: 'payable', + type: 'function', + inputs: [ + { name: '_target', internalType: 'address', type: 'address' }, + { name: '_data', internalType: 'bytes', type: 'bytes' }, + { name: '_gas', internalType: 'uint256', type: 'uint256' }, + ], + name: 'DELEGATECALL', + outputs: [ + { name: '', internalType: 'bool', type: 'bool' }, + { name: '', internalType: 'bytes', type: 'bytes' }, + ], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'VERSION', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'data', + outputs: [{ name: '', internalType: 'bytes', type: 'bytes' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'batcherHash', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'owner', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'gasLimit', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + name: 'recipient', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [ - { name: '_owner', internalType: 'address', type: 'address' }, - { name: '_overhead', internalType: 'uint256', type: 'uint256' }, - { name: '_scalar', internalType: 'uint256', type: 'uint256' }, - { name: '_batcherHash', internalType: 'bytes32', type: 'bytes32' }, - { name: '_gasLimit', internalType: 'uint64', type: 'uint64' }, - { name: '_unsafeBlockSigner', internalType: 'address', type: 'address' }, - { - name: '_config', - internalType: 'struct ResourceMetering.ResourceConfig', - type: 'tuple', - components: [ - { name: 'maxResourceLimit', internalType: 'uint32', type: 'uint32' }, - { - name: 'elasticityMultiplier', - internalType: 'uint8', - type: 'uint8', - }, - { - name: 'baseFeeMaxChangeDenominator', - internalType: 'uint8', - type: 'uint8', - }, - { name: 'minimumBaseFee', internalType: 'uint32', type: 'uint32' }, - { name: 'systemTxMaxGas', internalType: 'uint32', type: 'uint32' }, - { name: 'maximumBaseFee', internalType: 'uint128', type: 'uint128' }, - ], - }, - ], - name: 'initialize', + inputs: [{ name: '_data', internalType: 'bytes', type: 'bytes' }], + name: 'setData', outputs: [], }, { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'minimumGasLimit', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'overhead', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'owner', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], + name: 'setOwner', + outputs: [], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'renounceOwnership', + inputs: [{ name: '_recipient', internalType: 'address', type: 'address' }], + name: 'setRecipient', outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'resourceConfig', - outputs: [ - { - name: '', - internalType: 'struct ResourceMetering.ResourceConfig', - type: 'tuple', - components: [ - { name: 'maxResourceLimit', internalType: 'uint32', type: 'uint32' }, - { - name: 'elasticityMultiplier', - internalType: 'uint8', - type: 'uint8', - }, - { - name: 'baseFeeMaxChangeDenominator', - internalType: 'uint8', - type: 'uint8', - }, - { name: 'minimumBaseFee', internalType: 'uint32', type: 'uint32' }, - { name: 'systemTxMaxGas', internalType: 'uint32', type: 'uint32' }, - { name: 'maximumBaseFee', internalType: 'uint128', type: 'uint128' }, - ], - }, - ], + inputs: [{ name: '_teleportr', internalType: 'address', type: 'address' }], + name: 'setTeleportr', + outputs: [], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'scalar', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'teleportr', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_batcherHash', internalType: 'bytes32', type: 'bytes32' }, + { name: '_asset', internalType: 'contract ERC20', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, ], - name: 'setBatcherHash', + name: 'withdrawERC20', outputs: [], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_overhead', internalType: 'uint256', type: 'uint256' }, - { name: '_scalar', internalType: 'uint256', type: 'uint256' }, + { name: '_asset', internalType: 'contract ERC20', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, ], - name: 'setGasConfig', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: '_gasLimit', internalType: 'uint64', type: 'uint64' }], - name: 'setGasLimit', + name: 'withdrawERC20', outputs: [], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { - name: '_config', - internalType: 'struct ResourceMetering.ResourceConfig', - type: 'tuple', - components: [ - { name: 'maxResourceLimit', internalType: 'uint32', type: 'uint32' }, - { - name: 'elasticityMultiplier', - internalType: 'uint8', - type: 'uint8', - }, - { - name: 'baseFeeMaxChangeDenominator', - internalType: 'uint8', - type: 'uint8', - }, - { name: 'minimumBaseFee', internalType: 'uint32', type: 'uint32' }, - { name: 'systemTxMaxGas', internalType: 'uint32', type: 'uint32' }, - { name: 'maximumBaseFee', internalType: 'uint128', type: 'uint128' }, - ], - }, + { name: '_asset', internalType: 'contract ERC721', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_id', internalType: 'uint256', type: 'uint256' }, ], - name: 'setResourceConfig', + name: 'withdrawERC721', outputs: [], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_unsafeBlockSigner', internalType: 'address', type: 'address' }, + { name: '_to', internalType: 'address payable', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, ], - name: 'setUnsafeBlockSigner', + name: 'withdrawETH', outputs: [], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], - name: 'transferOwnership', + inputs: [{ name: '_to', internalType: 'address payable', type: 'address' }], + name: 'withdrawETH', outputs: [], }, { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'unsafeBlockSigner', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + name: 'withdrawFromTeleportr', + outputs: [], }, + { stateMutability: 'payable', type: 'receive' }, ] as const /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) + * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) */ -export const systemConfigAddress = { - 1: '0x229047fed2591dbec1eF1118d64F7aF3dB9EB290', +export const teleportrWithdrawerAddress = { + 1: '0x78A25524D90E3D0596558fb43789bD800a5c3007', } as const /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) + * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) */ -export const systemConfigConfig = { - address: systemConfigAddress, - abi: systemConfigABI, +export const teleportrWithdrawerConfig = { + address: teleportrWithdrawerAddress, + abi: teleportrWithdrawerABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// SystemConfig_goerli +// eslintIgnore ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -/** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export const systemConfigGoerliABI = [ - { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'version', - internalType: 'uint256', - type: 'uint256', - indexed: true, - }, - { - name: 'updateType', - internalType: 'enum SystemConfig.UpdateType', - type: 'uint8', - indexed: true, - }, - { name: 'data', internalType: 'bytes', type: 'bytes', indexed: false }, - ], - name: 'ConfigUpdate', +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// addressesByContractByNetwork +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +export const addresses = { + AddressManager: { + '1': '0xdE1FCfB0851916CA5101820A69b13a4E276bd81F', + '5': '0xa6f73589243a6A7a9023b1Fa0651b1d89c177111', }, - { - type: 'event', - anonymous: false, - inputs: [ - { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, - ], - name: 'Initialized', + AssetReceiver: { + '1': '0x15DdA60616Ffca20371ED1659dBB78E888f65556', + '10': '0x15DdA60616Ffca20371ED1659dBB78E888f65556', }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'previousOwner', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'newOwner', - internalType: 'address', - type: 'address', - indexed: true, - }, - ], - name: 'OwnershipTransferred', + AttestationStation: { + '10': '0xEE36eaaD94d1Cc1d0eccaDb55C38bFfB6Be06C77', + '420': '0xEE36eaaD94d1Cc1d0eccaDb55C38bFfB6Be06C77', }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'BATCH_INBOX_SLOT', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + BaseFeeVault: { '420': '0x4200000000000000000000000000000000000019' }, + CheckBalanceHigh: { + '1': '0x7eC64a8a591bFf829ff6C8be76074D540ACb813F', + '5': '0x7eC64a8a591bFf829ff6C8be76074D540ACb813F', + '420': '0x5d7103853f12109A7d27F118e54BbC654ad847E9', }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'L1_CROSS_DOMAIN_MESSENGER_SLOT', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + CheckBalanceLow: { + '1': '0x381a4eFC2A2C914eA1889722bB4B44Fa6BD5b640', + '5': '0x381a4eFC2A2C914eA1889722bB4B44Fa6BD5b640', + '420': '0x7Ce13D154FAEE5C8B3E6b19d4Add16f21d884474', }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'L1_ERC_721_BRIDGE_SLOT', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + CheckGelatoLow: { + '1': '0x4f7CFc43f6D262a085F3b946cAC69E7a8E39BBAa', + '5': '0x4f7CFc43f6D262a085F3b946cAC69E7a8E39BBAa', + '420': '0xF9c8a4Cb4021f57F9f6d69799cA9BefF64524862', }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'L1_STANDARD_BRIDGE_SLOT', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + CheckTrue: { + '1': '0x5c741a38cb11424711231777D71689C458eE835D', + '5': '0x5c741a38cb11424711231777D71689C458eE835D', + '420': '0x47443D0C184e022F19BD1578F5bca6B8a9F58E32', }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'L2_OUTPUT_ORACLE_SLOT', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + Drippie: { '1': '0x44b3A2a040057eBafC601A78647e805fd58B1f50' }, + Drippie_goerli: { '5': '0x44b3A2a040057eBafC601A78647e805fd58B1f50' }, + 'Drippie_optimism-goerli': { + '420': '0x8D8d533C16D23847EB04EEB0925be8900Dd3af86', }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'OPTIMISM_MINTABLE_ERC20_FACTORY_SLOT', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + EAS: { + '10': '0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088', + '420': '0x5A633F1cc84B03F7588486CF2F386c102061E6e1', }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'OPTIMISM_PORTAL_SLOT', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + GasPriceOracle: { '420': '0x420000000000000000000000000000000000000F' }, + L1Block: { '420': '0x4200000000000000000000000000000000000015' }, + L1CrossDomainMessenger: { + '1': '0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1', + '5': '0x5086d1eEF304eb5284A0f6720f79403b4e9bE294', }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'UNSAFE_BLOCK_SIGNER_SLOT', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + L1ERC721Bridge: { + '1': '0x5a7749f83b81B301cAb5f48EB8516B986DAef23D', + '5': '0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9', }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'VERSION', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + L1FeeVault: { '420': '0x420000000000000000000000000000000000001a' }, + L1StandardBridge: { + '1': '0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1', + '5': '0x636Af16bf2f682dD3109e60102b8E1A089FedAa8', }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'batchInbox', - outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], + L2CrossDomainMessenger: { + '420': '0x4200000000000000000000000000000000000007', }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'batcherHash', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + L2ERC721Bridge: { '10': '0x4200000000000000000000000000000000000014' }, + 'L2ERC721Bridge_optimism-goerli': { + '420': '0x4200000000000000000000000000000000000014', }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'gasLimit', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + L2OutputOracle: { + '1': '0xdfe97868233d1aa22e815a266982f2cf17685a27', + '5': '0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0', }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_owner', internalType: 'address', type: 'address' }, - { name: '_overhead', internalType: 'uint256', type: 'uint256' }, - { name: '_scalar', internalType: 'uint256', type: 'uint256' }, - { name: '_batcherHash', internalType: 'bytes32', type: 'bytes32' }, - { name: '_gasLimit', internalType: 'uint64', type: 'uint64' }, - { name: '_unsafeBlockSigner', internalType: 'address', type: 'address' }, - { - name: '_config', - internalType: 'struct ResourceMetering.ResourceConfig', - type: 'tuple', - components: [ - { name: 'maxResourceLimit', internalType: 'uint32', type: 'uint32' }, - { - name: 'elasticityMultiplier', - internalType: 'uint8', - type: 'uint8', - }, - { - name: 'baseFeeMaxChangeDenominator', - internalType: 'uint8', - type: 'uint8', - }, - { name: 'minimumBaseFee', internalType: 'uint32', type: 'uint32' }, - { name: 'systemTxMaxGas', internalType: 'uint32', type: 'uint32' }, - { name: 'maximumBaseFee', internalType: 'uint128', type: 'uint128' }, - ], - }, - { name: '_startBlock', internalType: 'uint256', type: 'uint256' }, - { name: '_batchInbox', internalType: 'address', type: 'address' }, - { - name: '_addresses', - internalType: 'struct SystemConfig.Addresses', - type: 'tuple', - components: [ - { - name: 'l1CrossDomainMessenger', - internalType: 'address', - type: 'address', - }, - { name: 'l1ERC721Bridge', internalType: 'address', type: 'address' }, - { - name: 'l1StandardBridge', - internalType: 'address', - type: 'address', - }, - { name: 'l2OutputOracle', internalType: 'address', type: 'address' }, - { name: 'optimismPortal', internalType: 'address', type: 'address' }, - { - name: 'optimismMintableERC20Factory', - internalType: 'address', - type: 'address', - }, - ], - }, - ], - name: 'initialize', - outputs: [], + L2StandardBridge: { '420': '0x4200000000000000000000000000000000000010' }, + L2ToL1MessagePasser: { '420': '0x4200000000000000000000000000000000000016' }, + MintManager: { + '10': '0x5C4e7Ba1E219E47948e6e3F55019A647bA501005', + '420': '0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76', }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'l1CrossDomainMessenger', - outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], + OptimismMintableERC20Factory: { + '1': '0x4200000000000000000000000000000000000012', }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'l1ERC721Bridge', - outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], + OptimismMintableERC20Factory_goerli: { + '5': '0x4200000000000000000000000000000000000012', }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'l1StandardBridge', - outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], + 'OptimismMintableERC20Factory_optimism-goerli': { + '420': '0x4200000000000000000000000000000000000012', }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'l2OutputOracle', - outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], + OptimismMintableERC721Factory: { + '10': '0x4200000000000000000000000000000000000017', }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'minimumGasLimit', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + 'OptimismMintableERC721Factory_optimism-goerli': { + '420': '0x4200000000000000000000000000000000000017', }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'optimismMintableERC20Factory', - outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], + OptimismPortal: { + '1': '0xbEb5Fc579115071764c7423A4f12eDde41f106Ed', + '5': '0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383', }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'optimismPortal', - outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], + Optimist: { + '10': '0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5', + '420': '0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5', }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'overhead', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + OptimistAllowlist: { + '10': '0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180', + '420': '0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180', }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'owner', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + OptimistInviter: { + '10': '0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929', + '420': '0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929', }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'renounceOwnership', - outputs: [], + PortalSender: { + '1': '0x0A893d9576b9cFD9EF78595963dc973238E78210', + '5': '0xe7FACd39531ee3C313330E93B4d7a8B8A3c84Aa4', }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'resourceConfig', - outputs: [ - { - name: '', - internalType: 'struct ResourceMetering.ResourceConfig', - type: 'tuple', - components: [ - { name: 'maxResourceLimit', internalType: 'uint32', type: 'uint32' }, - { - name: 'elasticityMultiplier', - internalType: 'uint8', - type: 'uint8', - }, - { - name: 'baseFeeMaxChangeDenominator', - internalType: 'uint8', - type: 'uint8', - }, - { name: 'minimumBaseFee', internalType: 'uint32', type: 'uint32' }, - { name: 'systemTxMaxGas', internalType: 'uint32', type: 'uint32' }, - { name: 'maximumBaseFee', internalType: 'uint128', type: 'uint128' }, - ], - }, - ], + ProtocolVersions: { '5': '0x0C24F5098774aA366827D667494e9F889f7cFc08' }, + ProxyAdmin: { + '1': '0x4200000000000000000000000000000000000018', + '5': '0x4200000000000000000000000000000000000018', }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'scalar', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + SchemaRegistry: { + '10': '0x6232208d66bAc2305b46b4Cb6BCB3857B298DF13', + '420': '0x2545fa928d5d278cA75Fd47306e4a89096ff6403', }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_batcherHash', internalType: 'bytes32', type: 'bytes32' }, - ], - name: 'setBatcherHash', - outputs: [], + SequencerFeeVault: { '420': '0x4200000000000000000000000000000000000011' }, + SystemConfig: { + '1': '0x229047fed2591dbec1eF1118d64F7aF3dB9EB290', + '5': '0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60', }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_overhead', internalType: 'uint256', type: 'uint256' }, - { name: '_scalar', internalType: 'uint256', type: 'uint256' }, - ], - name: 'setGasConfig', - outputs: [], + SystemDictator: { '1': '0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB' }, + SystemDictator_goerli: { '5': '0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971' }, + TeleportrWithdrawer: { '1': '0x78A25524D90E3D0596558fb43789bD800a5c3007' }, +} as const +export const predeploys = { + LegacyMessagePasser: { + address: '0x4200000000000000000000000000000000000000', + introduced: 'Legacy', + deprecated: true, + proxied: true, }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: '_gasLimit', internalType: 'uint64', type: 'uint64' }], - name: 'setGasLimit', - outputs: [], + DeployerWhitelist: { + address: '0x4200000000000000000000000000000000000002', + introduced: 'Legacy', + deprecated: true, + proxied: true, }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { - name: '_config', - internalType: 'struct ResourceMetering.ResourceConfig', - type: 'tuple', - components: [ - { name: 'maxResourceLimit', internalType: 'uint32', type: 'uint32' }, - { - name: 'elasticityMultiplier', - internalType: 'uint8', - type: 'uint8', - }, - { - name: 'baseFeeMaxChangeDenominator', - internalType: 'uint8', - type: 'uint8', - }, - { name: 'minimumBaseFee', internalType: 'uint32', type: 'uint32' }, - { name: 'systemTxMaxGas', internalType: 'uint32', type: 'uint32' }, - { name: 'maximumBaseFee', internalType: 'uint128', type: 'uint128' }, - ], - }, - ], - name: 'setResourceConfig', - outputs: [], + LegacyERC20ETH: { + address: '0xDeadDeAddeAddEAddeadDEaDDEAdDeaDDeAD0000', + introduced: 'Legacy', + deprecated: true, + proxied: false, }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_unsafeBlockSigner', internalType: 'address', type: 'address' }, - ], - name: 'setUnsafeBlockSigner', - outputs: [], + WETH9: { + address: '0x4200000000000000000000000000000000000006', + introduced: 'Legacy', + deprecated: false, + proxied: false, }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'startBlock', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + L2CrossDomainMessenger: { + address: '0x4200000000000000000000000000000000000007', + introduced: 'Legacy', + deprecated: false, + proxied: true, }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], - name: 'transferOwnership', - outputs: [], + L2StandardBridge: { + address: '0x4200000000000000000000000000000000000010', + introduced: 'Legacy', + deprecated: false, + proxied: true, }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'unsafeBlockSigner', - outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], + SequencerFeeVault: { + address: '0x4200000000000000000000000000000000000011', + introduced: 'Legacy', + deprecated: false, + proxied: true, }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + OptimismMintableERC20Factory: { + address: '0x4200000000000000000000000000000000000012', + introduced: 'Legacy', + deprecated: false, + proxied: true, }, -] as const - -/** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export const systemConfigGoerliAddress = { - 5: '0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60', -} as const - -/** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export const systemConfigGoerliConfig = { - address: systemConfigGoerliAddress, - abi: systemConfigGoerliABI, -} as const - -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// SystemDictator -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) - */ -export const systemDictatorABI = [ - { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, - { - type: 'event', - anonymous: false, - inputs: [ - { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, - ], - name: 'Initialized', + L1BlockNumber: { + address: '0x4200000000000000000000000000000000000013', + introduced: 'Legacy', + deprecated: true, + proxied: true, }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'previousOwner', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'newOwner', - internalType: 'address', - type: 'address', - indexed: true, - }, - ], - name: 'OwnershipTransferred', + GasPriceOracle: { + address: '0x420000000000000000000000000000000000000F', + introduced: 'Legacy', + deprecated: false, + proxied: true, }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'EXIT_1_NO_RETURN_STEP', - outputs: [{ name: '', internalType: 'uint8', type: 'uint8' }], + GovernanceToken: { + address: '0x4200000000000000000000000000000000000042', + introduced: 'Legacy', + deprecated: false, + proxied: false, }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'PROXY_TRANSFER_STEP', - outputs: [{ name: '', internalType: 'uint8', type: 'uint8' }], + L1Block: { + address: '0x4200000000000000000000000000000000000015', + introduced: 'Bedrock', + deprecated: false, + proxied: true, }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'config', - outputs: [ - { - name: 'globalConfig', - internalType: 'struct SystemDictator.GlobalConfig', - type: 'tuple', - components: [ - { - name: 'addressManager', - internalType: 'contract AddressManager', - type: 'address', - }, - { - name: 'proxyAdmin', - internalType: 'contract ProxyAdmin', - type: 'address', - }, - { name: 'controller', internalType: 'address', type: 'address' }, - { name: 'finalOwner', internalType: 'address', type: 'address' }, - ], - }, - { - name: 'proxyAddressConfig', - internalType: 'struct SystemDictator.ProxyAddressConfig', - type: 'tuple', - components: [ - { - name: 'l2OutputOracleProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'optimismPortalProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'l1CrossDomainMessengerProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'l1StandardBridgeProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'optimismMintableERC20FactoryProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'l1ERC721BridgeProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'systemConfigProxy', - internalType: 'address', - type: 'address', - }, - ], - }, - { - name: 'implementationAddressConfig', - internalType: 'struct SystemDictator.ImplementationAddressConfig', - type: 'tuple', - components: [ - { - name: 'l2OutputOracleImpl', - internalType: 'contract L2OutputOracle', - type: 'address', - }, - { - name: 'optimismPortalImpl', - internalType: 'contract OptimismPortal', - type: 'address', - }, - { - name: 'l1CrossDomainMessengerImpl', - internalType: 'contract L1CrossDomainMessenger', - type: 'address', - }, - { - name: 'l1StandardBridgeImpl', - internalType: 'contract L1StandardBridge', - type: 'address', - }, - { - name: 'optimismMintableERC20FactoryImpl', - internalType: 'contract OptimismMintableERC20Factory', - type: 'address', - }, - { - name: 'l1ERC721BridgeImpl', - internalType: 'contract L1ERC721Bridge', - type: 'address', - }, - { - name: 'portalSenderImpl', - internalType: 'contract PortalSender', - type: 'address', - }, - { - name: 'systemConfigImpl', - internalType: 'contract SystemConfig', - type: 'address', - }, - ], - }, - { - name: 'systemConfigConfig', - internalType: 'struct SystemDictator.SystemConfigConfig', - type: 'tuple', - components: [ - { name: 'owner', internalType: 'address', type: 'address' }, - { name: 'overhead', internalType: 'uint256', type: 'uint256' }, - { name: 'scalar', internalType: 'uint256', type: 'uint256' }, - { name: 'batcherHash', internalType: 'bytes32', type: 'bytes32' }, - { name: 'gasLimit', internalType: 'uint64', type: 'uint64' }, - { - name: 'unsafeBlockSigner', - internalType: 'address', - type: 'address', - }, - { - name: 'resourceConfig', - internalType: 'struct ResourceMetering.ResourceConfig', - type: 'tuple', - components: [ - { - name: 'maxResourceLimit', - internalType: 'uint32', - type: 'uint32', - }, - { - name: 'elasticityMultiplier', - internalType: 'uint8', - type: 'uint8', - }, - { - name: 'baseFeeMaxChangeDenominator', - internalType: 'uint8', - type: 'uint8', - }, - { - name: 'minimumBaseFee', - internalType: 'uint32', - type: 'uint32', - }, - { - name: 'systemTxMaxGas', - internalType: 'uint32', - type: 'uint32', - }, - { - name: 'maximumBaseFee', - internalType: 'uint128', - type: 'uint128', - }, - ], - }, - ], - }, - ], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'currentStep', - outputs: [{ name: '', internalType: 'uint8', type: 'uint8' }], + L2ToL1MessagePasser: { + address: '0x4200000000000000000000000000000000000016', + introduced: 'Bedrock', + deprecated: false, + proxied: true, }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'dynamicConfigSet', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + L2ERC721Bridge: { + address: '0x4200000000000000000000000000000000000014', + introduced: 'Legacy', + deprecated: false, + proxied: true, }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'exit1', - outputs: [], + OptimismMintableERC721Factory: { + address: '0x4200000000000000000000000000000000000017', + introduced: 'Bedrock', + deprecated: false, + proxied: true, }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'exited', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + ProxyAdmin: { + address: '0x4200000000000000000000000000000000000018', + introduced: 'Bedrock', + deprecated: false, + proxied: true, }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'finalize', - outputs: [], + BaseFeeVault: { + address: '0x4200000000000000000000000000000000000019', + introduced: 'Bedrock', + deprecated: false, + proxied: true, }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'finalized', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + L1FeeVault: { + address: '0x420000000000000000000000000000000000001a', + introduced: 'Bedrock', + deprecated: false, + proxied: true, }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { - name: '_config', - internalType: 'struct SystemDictator.DeployConfig', - type: 'tuple', - components: [ - { - name: 'globalConfig', - internalType: 'struct SystemDictator.GlobalConfig', - type: 'tuple', - components: [ - { - name: 'addressManager', - internalType: 'contract AddressManager', - type: 'address', - }, - { - name: 'proxyAdmin', - internalType: 'contract ProxyAdmin', - type: 'address', - }, - { name: 'controller', internalType: 'address', type: 'address' }, - { name: 'finalOwner', internalType: 'address', type: 'address' }, - ], - }, - { - name: 'proxyAddressConfig', - internalType: 'struct SystemDictator.ProxyAddressConfig', - type: 'tuple', - components: [ - { - name: 'l2OutputOracleProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'optimismPortalProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'l1CrossDomainMessengerProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'l1StandardBridgeProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'optimismMintableERC20FactoryProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'l1ERC721BridgeProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'systemConfigProxy', - internalType: 'address', - type: 'address', - }, - ], - }, - { - name: 'implementationAddressConfig', - internalType: 'struct SystemDictator.ImplementationAddressConfig', - type: 'tuple', - components: [ - { - name: 'l2OutputOracleImpl', - internalType: 'contract L2OutputOracle', - type: 'address', - }, - { - name: 'optimismPortalImpl', - internalType: 'contract OptimismPortal', - type: 'address', - }, - { - name: 'l1CrossDomainMessengerImpl', - internalType: 'contract L1CrossDomainMessenger', - type: 'address', - }, - { - name: 'l1StandardBridgeImpl', - internalType: 'contract L1StandardBridge', - type: 'address', - }, - { - name: 'optimismMintableERC20FactoryImpl', - internalType: 'contract OptimismMintableERC20Factory', - type: 'address', - }, - { - name: 'l1ERC721BridgeImpl', - internalType: 'contract L1ERC721Bridge', - type: 'address', - }, - { - name: 'portalSenderImpl', - internalType: 'contract PortalSender', - type: 'address', - }, - { - name: 'systemConfigImpl', - internalType: 'contract SystemConfig', - type: 'address', - }, - ], - }, - { - name: 'systemConfigConfig', - internalType: 'struct SystemDictator.SystemConfigConfig', - type: 'tuple', - components: [ - { name: 'owner', internalType: 'address', type: 'address' }, - { name: 'overhead', internalType: 'uint256', type: 'uint256' }, - { name: 'scalar', internalType: 'uint256', type: 'uint256' }, - { name: 'batcherHash', internalType: 'bytes32', type: 'bytes32' }, - { name: 'gasLimit', internalType: 'uint64', type: 'uint64' }, - { - name: 'unsafeBlockSigner', - internalType: 'address', - type: 'address', - }, - { - name: 'resourceConfig', - internalType: 'struct ResourceMetering.ResourceConfig', - type: 'tuple', - components: [ - { - name: 'maxResourceLimit', - internalType: 'uint32', - type: 'uint32', - }, - { - name: 'elasticityMultiplier', - internalType: 'uint8', - type: 'uint8', - }, - { - name: 'baseFeeMaxChangeDenominator', - internalType: 'uint8', - type: 'uint8', - }, - { - name: 'minimumBaseFee', - internalType: 'uint32', - type: 'uint32', - }, - { - name: 'systemTxMaxGas', - internalType: 'uint32', - type: 'uint32', - }, - { - name: 'maximumBaseFee', - internalType: 'uint128', - type: 'uint128', - }, - ], - }, - ], - }, - ], - }, - ], - name: 'initialize', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'l2OutputOracleDynamicConfig', - outputs: [ - { - name: 'l2OutputOracleStartingBlockNumber', - internalType: 'uint256', - type: 'uint256', - }, - { - name: 'l2OutputOracleStartingTimestamp', - internalType: 'uint256', - type: 'uint256', - }, - ], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'oldL1CrossDomainMessenger', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'optimismPortalDynamicConfig', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'owner', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'phase1', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'phase2', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'renounceOwnership', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'step1', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'step2', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'step3', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'step4', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'step5', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], - name: 'transferOwnership', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { - name: '_l2OutputOracleDynamicConfig', - internalType: 'struct SystemDictator.L2OutputOracleDynamicConfig', - type: 'tuple', - components: [ - { - name: 'l2OutputOracleStartingBlockNumber', - internalType: 'uint256', - type: 'uint256', - }, - { - name: 'l2OutputOracleStartingTimestamp', - internalType: 'uint256', - type: 'uint256', - }, - ], - }, - { - name: '_optimismPortalDynamicConfig', - internalType: 'bool', - type: 'bool', - }, - ], - name: 'updateDynamicConfig', - outputs: [], - }, -] as const - -/** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) - */ -export const systemDictatorAddress = { - 1: '0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB', -} as const - -/** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) - */ -export const systemDictatorConfig = { - address: systemDictatorAddress, - abi: systemDictatorABI, -} as const - -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// SystemDictator_goerli -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) - */ -export const systemDictatorGoerliABI = [ - { - type: 'event', - anonymous: false, - inputs: [ - { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, - ], - name: 'Initialized', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'previousOwner', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'newOwner', - internalType: 'address', - type: 'address', - indexed: true, - }, - ], - name: 'OwnershipTransferred', - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'EXIT_1_NO_RETURN_STEP', - outputs: [{ name: '', internalType: 'uint8', type: 'uint8' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'PROXY_TRANSFER_STEP', - outputs: [{ name: '', internalType: 'uint8', type: 'uint8' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'config', - outputs: [ - { - name: 'globalConfig', - internalType: 'struct SystemDictator.GlobalConfig', - type: 'tuple', - components: [ - { - name: 'addressManager', - internalType: 'contract AddressManager', - type: 'address', - }, - { - name: 'proxyAdmin', - internalType: 'contract ProxyAdmin', - type: 'address', - }, - { name: 'controller', internalType: 'address', type: 'address' }, - { name: 'finalOwner', internalType: 'address', type: 'address' }, - ], - }, - { - name: 'proxyAddressConfig', - internalType: 'struct SystemDictator.ProxyAddressConfig', - type: 'tuple', - components: [ - { - name: 'l2OutputOracleProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'optimismPortalProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'l1CrossDomainMessengerProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'l1StandardBridgeProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'optimismMintableERC20FactoryProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'l1ERC721BridgeProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'systemConfigProxy', - internalType: 'address', - type: 'address', - }, - ], - }, - { - name: 'implementationAddressConfig', - internalType: 'struct SystemDictator.ImplementationAddressConfig', - type: 'tuple', - components: [ - { - name: 'l2OutputOracleImpl', - internalType: 'contract L2OutputOracle', - type: 'address', - }, - { - name: 'optimismPortalImpl', - internalType: 'contract OptimismPortal', - type: 'address', - }, - { - name: 'l1CrossDomainMessengerImpl', - internalType: 'contract L1CrossDomainMessenger', - type: 'address', - }, - { - name: 'l1StandardBridgeImpl', - internalType: 'contract L1StandardBridge', - type: 'address', - }, - { - name: 'optimismMintableERC20FactoryImpl', - internalType: 'contract OptimismMintableERC20Factory', - type: 'address', - }, - { - name: 'l1ERC721BridgeImpl', - internalType: 'contract L1ERC721Bridge', - type: 'address', - }, - { - name: 'portalSenderImpl', - internalType: 'contract PortalSender', - type: 'address', - }, - { - name: 'systemConfigImpl', - internalType: 'contract SystemConfig', - type: 'address', - }, - ], - }, - { - name: 'systemConfigConfig', - internalType: 'struct SystemDictator.SystemConfigConfig', - type: 'tuple', - components: [ - { name: 'owner', internalType: 'address', type: 'address' }, - { name: 'overhead', internalType: 'uint256', type: 'uint256' }, - { name: 'scalar', internalType: 'uint256', type: 'uint256' }, - { name: 'batcherHash', internalType: 'bytes32', type: 'bytes32' }, - { name: 'gasLimit', internalType: 'uint64', type: 'uint64' }, - { - name: 'unsafeBlockSigner', - internalType: 'address', - type: 'address', - }, - ], - }, - ], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'currentStep', - outputs: [{ name: '', internalType: 'uint8', type: 'uint8' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'dynamicConfigSet', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'exit1', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'finalize', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'finalized', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { - name: '_config', - internalType: 'struct SystemDictator.DeployConfig', - type: 'tuple', - components: [ - { - name: 'globalConfig', - internalType: 'struct SystemDictator.GlobalConfig', - type: 'tuple', - components: [ - { - name: 'addressManager', - internalType: 'contract AddressManager', - type: 'address', - }, - { - name: 'proxyAdmin', - internalType: 'contract ProxyAdmin', - type: 'address', - }, - { name: 'controller', internalType: 'address', type: 'address' }, - { name: 'finalOwner', internalType: 'address', type: 'address' }, - ], - }, - { - name: 'proxyAddressConfig', - internalType: 'struct SystemDictator.ProxyAddressConfig', - type: 'tuple', - components: [ - { - name: 'l2OutputOracleProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'optimismPortalProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'l1CrossDomainMessengerProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'l1StandardBridgeProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'optimismMintableERC20FactoryProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'l1ERC721BridgeProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'systemConfigProxy', - internalType: 'address', - type: 'address', - }, - ], - }, - { - name: 'implementationAddressConfig', - internalType: 'struct SystemDictator.ImplementationAddressConfig', - type: 'tuple', - components: [ - { - name: 'l2OutputOracleImpl', - internalType: 'contract L2OutputOracle', - type: 'address', - }, - { - name: 'optimismPortalImpl', - internalType: 'contract OptimismPortal', - type: 'address', - }, - { - name: 'l1CrossDomainMessengerImpl', - internalType: 'contract L1CrossDomainMessenger', - type: 'address', - }, - { - name: 'l1StandardBridgeImpl', - internalType: 'contract L1StandardBridge', - type: 'address', - }, - { - name: 'optimismMintableERC20FactoryImpl', - internalType: 'contract OptimismMintableERC20Factory', - type: 'address', - }, - { - name: 'l1ERC721BridgeImpl', - internalType: 'contract L1ERC721Bridge', - type: 'address', - }, - { - name: 'portalSenderImpl', - internalType: 'contract PortalSender', - type: 'address', - }, - { - name: 'systemConfigImpl', - internalType: 'contract SystemConfig', - type: 'address', - }, - ], - }, - { - name: 'systemConfigConfig', - internalType: 'struct SystemDictator.SystemConfigConfig', - type: 'tuple', - components: [ - { name: 'owner', internalType: 'address', type: 'address' }, - { name: 'overhead', internalType: 'uint256', type: 'uint256' }, - { name: 'scalar', internalType: 'uint256', type: 'uint256' }, - { name: 'batcherHash', internalType: 'bytes32', type: 'bytes32' }, - { name: 'gasLimit', internalType: 'uint64', type: 'uint64' }, - { - name: 'unsafeBlockSigner', - internalType: 'address', - type: 'address', - }, - ], - }, - ], - }, - ], - name: 'initialize', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'l2OutputOracleDynamicConfig', - outputs: [ - { - name: 'l2OutputOracleStartingBlockNumber', - internalType: 'uint256', - type: 'uint256', - }, - { - name: 'l2OutputOracleStartingTimestamp', - internalType: 'uint256', - type: 'uint256', - }, - ], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'oldL1CrossDomainMessenger', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'owner', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'renounceOwnership', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'step1', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'step2', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'step3', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'step4', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'step5', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'step6', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], - name: 'transferOwnership', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { - name: '_l2OutputOracleDynamicConfig', - internalType: 'struct SystemDictator.L2OutputOracleDynamicConfig', - type: 'tuple', - components: [ - { - name: 'l2OutputOracleStartingBlockNumber', - internalType: 'uint256', - type: 'uint256', - }, - { - name: 'l2OutputOracleStartingTimestamp', - internalType: 'uint256', - type: 'uint256', - }, - ], - }, - ], - name: 'updateL2OutputOracleDynamicConfig', - outputs: [], - }, -] as const - -/** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) - */ -export const systemDictatorGoerliAddress = { - 5: '0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971', -} as const - -/** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) - */ -export const systemDictatorGoerliConfig = { - address: systemDictatorGoerliAddress, - abi: systemDictatorGoerliABI, -} as const - -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// TeleportrWithdrawer -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) - */ -export const teleportrWithdrawerABI = [ - { - stateMutability: 'nonpayable', - type: 'constructor', - inputs: [{ name: '_owner', internalType: 'address', type: 'address' }], - }, - { - type: 'event', - anonymous: false, - inputs: [ - { name: 'user', internalType: 'address', type: 'address', indexed: true }, - { - name: 'newOwner', - internalType: 'address', - type: 'address', - indexed: true, - }, - ], - name: 'OwnerUpdated', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - ], - name: 'ReceivedETH', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'withdrawer', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'recipient', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'asset', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - ], - name: 'WithdrewERC20', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'withdrawer', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'recipient', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'asset', - internalType: 'address', - type: 'address', - indexed: true, - }, - { name: 'id', internalType: 'uint256', type: 'uint256', indexed: false }, - ], - name: 'WithdrewERC721', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'withdrawer', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'recipient', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - ], - name: 'WithdrewETH', - }, - { - stateMutability: 'payable', - type: 'function', - inputs: [ - { name: '_target', internalType: 'address', type: 'address' }, - { name: '_data', internalType: 'bytes', type: 'bytes' }, - { name: '_gas', internalType: 'uint256', type: 'uint256' }, - { name: '_value', internalType: 'uint256', type: 'uint256' }, - ], - name: 'CALL', - outputs: [ - { name: '', internalType: 'bool', type: 'bool' }, - { name: '', internalType: 'bytes', type: 'bytes' }, - ], - }, - { - stateMutability: 'payable', - type: 'function', - inputs: [ - { name: '_target', internalType: 'address', type: 'address' }, - { name: '_data', internalType: 'bytes', type: 'bytes' }, - { name: '_gas', internalType: 'uint256', type: 'uint256' }, - ], - name: 'DELEGATECALL', - outputs: [ - { name: '', internalType: 'bool', type: 'bool' }, - { name: '', internalType: 'bytes', type: 'bytes' }, - ], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'data', - outputs: [{ name: '', internalType: 'bytes', type: 'bytes' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'owner', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'recipient', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: '_data', internalType: 'bytes', type: 'bytes' }], - name: 'setData', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], - name: 'setOwner', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: '_recipient', internalType: 'address', type: 'address' }], - name: 'setRecipient', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: '_teleportr', internalType: 'address', type: 'address' }], - name: 'setTeleportr', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'teleportr', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_asset', internalType: 'contract ERC20', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - ], - name: 'withdrawERC20', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_asset', internalType: 'contract ERC20', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - ], - name: 'withdrawERC20', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_asset', internalType: 'contract ERC721', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_id', internalType: 'uint256', type: 'uint256' }, - ], - name: 'withdrawERC721', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_to', internalType: 'address payable', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - ], - name: 'withdrawETH', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: '_to', internalType: 'address payable', type: 'address' }], - name: 'withdrawETH', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'withdrawFromTeleportr', - outputs: [], - }, - { stateMutability: 'payable', type: 'receive' }, -] as const - -/** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) - */ -export const teleportrWithdrawerAddress = { - 1: '0x78A25524D90E3D0596558fb43789bD800a5c3007', -} as const - -/** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) - */ -export const teleportrWithdrawerConfig = { - address: teleportrWithdrawerAddress, - abi: teleportrWithdrawerABI, -} as const - -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// eslintIgnore -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// addressesByContractByNetwork -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -export const addresses = { - AddressManager: { - '1': '0xdE1FCfB0851916CA5101820A69b13a4E276bd81F', - '5': '0xa6f73589243a6A7a9023b1Fa0651b1d89c177111', - }, - AssetReceiver: { - '1': '0x15DdA60616Ffca20371ED1659dBB78E888f65556', - '10': '0x15DdA60616Ffca20371ED1659dBB78E888f65556', - }, - AttestationStation: { - '10': '0xEE36eaaD94d1Cc1d0eccaDb55C38bFfB6Be06C77', - '420': '0xEE36eaaD94d1Cc1d0eccaDb55C38bFfB6Be06C77', - }, - BaseFeeVault: { '420': '0x4200000000000000000000000000000000000019' }, - CheckBalanceHigh: { - '1': '0x7eC64a8a591bFf829ff6C8be76074D540ACb813F', - '5': '0x7eC64a8a591bFf829ff6C8be76074D540ACb813F', - '420': '0x5d7103853f12109A7d27F118e54BbC654ad847E9', - }, - CheckBalanceLow: { - '1': '0x381a4eFC2A2C914eA1889722bB4B44Fa6BD5b640', - '5': '0x381a4eFC2A2C914eA1889722bB4B44Fa6BD5b640', - '420': '0x7Ce13D154FAEE5C8B3E6b19d4Add16f21d884474', - }, - CheckGelatoLow: { - '1': '0x4f7CFc43f6D262a085F3b946cAC69E7a8E39BBAa', - '5': '0x4f7CFc43f6D262a085F3b946cAC69E7a8E39BBAa', - '420': '0xF9c8a4Cb4021f57F9f6d69799cA9BefF64524862', - }, - CheckTrue: { - '1': '0x5c741a38cb11424711231777D71689C458eE835D', - '5': '0x5c741a38cb11424711231777D71689C458eE835D', - '420': '0x47443D0C184e022F19BD1578F5bca6B8a9F58E32', - }, - Drippie: { '1': '0x44b3A2a040057eBafC601A78647e805fd58B1f50' }, - Drippie_goerli: { '5': '0x44b3A2a040057eBafC601A78647e805fd58B1f50' }, - 'Drippie_optimism-goerli': { - '420': '0x8D8d533C16D23847EB04EEB0925be8900Dd3af86', - }, - EAS: { - '10': '0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088', - '420': '0x5A633F1cc84B03F7588486CF2F386c102061E6e1', - }, - GasPriceOracle: { '420': '0x420000000000000000000000000000000000000F' }, - L1Block: { '420': '0x4200000000000000000000000000000000000015' }, - L1CrossDomainMessenger: { '1': '0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1' }, - L1CrossDomainMessenger_goerli: { - '5': '0x5086d1eEF304eb5284A0f6720f79403b4e9bE294', - }, - L1ERC721Bridge: { '1': '0x5a7749f83b81B301cAb5f48EB8516B986DAef23D' }, - L1ERC721Bridge_goerli: { '5': '0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9' }, - L1FeeVault: { '420': '0x420000000000000000000000000000000000001a' }, - L1StandardBridge: { '1': '0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1' }, - L1StandardBridge_goerli: { - '5': '0x636Af16bf2f682dD3109e60102b8E1A089FedAa8', - }, - L2CrossDomainMessenger: { - '420': '0x4200000000000000000000000000000000000007', - }, - L2ERC721Bridge: { '10': '0x4200000000000000000000000000000000000014' }, - 'L2ERC721Bridge_optimism-goerli': { - '420': '0x4200000000000000000000000000000000000014', - }, - L2OutputOracle: { '1': '0xdfe97868233d1aa22e815a266982f2cf17685a27' }, - L2OutputOracle_goerli: { '5': '0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0' }, - L2StandardBridge: { '420': '0x4200000000000000000000000000000000000010' }, - L2ToL1MessagePasser: { '420': '0x4200000000000000000000000000000000000016' }, - MintManager: { - '10': '0x5C4e7Ba1E219E47948e6e3F55019A647bA501005', - '420': '0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76', - }, - OptimismMintableERC20Factory: { - '1': '0x4200000000000000000000000000000000000012', - }, - OptimismMintableERC20Factory_goerli: { - '5': '0x4200000000000000000000000000000000000012', - }, - 'OptimismMintableERC20Factory_optimism-goerli': { - '420': '0x4200000000000000000000000000000000000012', - }, - OptimismMintableERC721Factory: { - '10': '0x4200000000000000000000000000000000000017', - }, - 'OptimismMintableERC721Factory_optimism-goerli': { - '420': '0x4200000000000000000000000000000000000017', - }, - OptimismPortal: { '1': '0xbEb5Fc579115071764c7423A4f12eDde41f106Ed' }, - OptimismPortal_goerli: { '5': '0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383' }, - Optimist: { - '10': '0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5', - '420': '0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5', - }, - OptimistAllowlist: { - '10': '0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180', - '420': '0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180', - }, - OptimistInviter: { - '10': '0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929', - '420': '0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929', - }, - PortalSender: { - '1': '0x0A893d9576b9cFD9EF78595963dc973238E78210', - '5': '0xe7FACd39531ee3C313330E93B4d7a8B8A3c84Aa4', - }, - ProtocolVersions: { '5': '0x0C24F5098774aA366827D667494e9F889f7cFc08' }, - ProxyAdmin: { - '1': '0x4200000000000000000000000000000000000018', - '5': '0x4200000000000000000000000000000000000018', - }, - SchemaRegistry: { - '10': '0x6232208d66bAc2305b46b4Cb6BCB3857B298DF13', - '420': '0x2545fa928d5d278cA75Fd47306e4a89096ff6403', - }, - SequencerFeeVault: { '420': '0x4200000000000000000000000000000000000011' }, - SystemConfig: { '1': '0x229047fed2591dbec1eF1118d64F7aF3dB9EB290' }, - SystemConfig_goerli: { '5': '0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60' }, - SystemDictator: { '1': '0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB' }, - SystemDictator_goerli: { '5': '0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971' }, - TeleportrWithdrawer: { '1': '0x78A25524D90E3D0596558fb43789bD800a5c3007' }, -} as const -export const predeploys = { - LegacyMessagePasser: { - address: '0x4200000000000000000000000000000000000000', - introduced: 'Legacy', - deprecated: true, - proxied: true, - }, - DeployerWhitelist: { - address: '0x4200000000000000000000000000000000000002', - introduced: 'Legacy', - deprecated: true, - proxied: true, - }, - LegacyERC20ETH: { - address: '0xDeadDeAddeAddEAddeadDEaDDEAdDeaDDeAD0000', - introduced: 'Legacy', - deprecated: true, - proxied: false, - }, - WETH9: { - address: '0x4200000000000000000000000000000000000006', - introduced: 'Legacy', - deprecated: false, - proxied: false, - }, - L2CrossDomainMessenger: { - address: '0x4200000000000000000000000000000000000007', - introduced: 'Legacy', - deprecated: false, - proxied: true, - }, - L2StandardBridge: { - address: '0x4200000000000000000000000000000000000010', - introduced: 'Legacy', - deprecated: false, - proxied: true, - }, - SequencerFeeVault: { - address: '0x4200000000000000000000000000000000000011', - introduced: 'Legacy', - deprecated: false, - proxied: true, - }, - OptimismMintableERC20Factory: { - address: '0x4200000000000000000000000000000000000012', - introduced: 'Legacy', - deprecated: false, - proxied: true, - }, - L1BlockNumber: { - address: '0x4200000000000000000000000000000000000013', - introduced: 'Legacy', - deprecated: true, - proxied: true, - }, - GasPriceOracle: { - address: '0x420000000000000000000000000000000000000F', - introduced: 'Legacy', - deprecated: false, - proxied: true, - }, - GovernanceToken: { - address: '0x4200000000000000000000000000000000000042', - introduced: 'Legacy', - deprecated: false, - proxied: false, - }, - L1Block: { - address: '0x4200000000000000000000000000000000000015', - introduced: 'Bedrock', - deprecated: false, - proxied: true, - }, - L2ToL1MessagePasser: { - address: '0x4200000000000000000000000000000000000016', - introduced: 'Bedrock', - deprecated: false, - proxied: true, - }, - L2ERC721Bridge: { - address: '0x4200000000000000000000000000000000000014', - introduced: 'Legacy', - deprecated: false, - proxied: true, - }, - OptimismMintableERC721Factory: { - address: '0x4200000000000000000000000000000000000017', - introduced: 'Bedrock', - deprecated: false, - proxied: true, - }, - ProxyAdmin: { - address: '0x4200000000000000000000000000000000000018', - introduced: 'Bedrock', - deprecated: false, - proxied: true, - }, - BaseFeeVault: { - address: '0x4200000000000000000000000000000000000019', - introduced: 'Bedrock', - deprecated: false, - proxied: true, - }, - L1FeeVault: { - address: '0x420000000000000000000000000000000000001a', - introduced: 'Bedrock', - deprecated: false, - proxied: true, - }, -} - -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// abisByContractByNetwork -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -export const abis = { - AddressManager: [ - { - type: 'event', - anonymous: false, - inputs: [ - { - name: '_name', - internalType: 'string', - type: 'string', - indexed: true, - }, - { - name: '_newAddress', - internalType: 'address', - type: 'address', - indexed: false, - }, - { - name: '_oldAddress', - internalType: 'address', - type: 'address', - indexed: false, - }, - ], - name: 'AddressSet', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'previousOwner', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'newOwner', - internalType: 'address', - type: 'address', - indexed: true, - }, - ], - name: 'OwnershipTransferred', - }, - { - stateMutability: 'view', - type: 'function', - inputs: [{ name: '_name', internalType: 'string', type: 'string' }], - name: 'getAddress', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'owner', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'renounceOwnership', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_address', internalType: 'address', type: 'address' }, - ], - name: 'setAddress', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], - name: 'transferOwnership', - outputs: [], - }, - ], - AssetReceiver: [ - { - stateMutability: 'nonpayable', - type: 'constructor', - inputs: [{ name: '_owner', internalType: 'address', type: 'address' }], - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'user', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'newOwner', - internalType: 'address', - type: 'address', - indexed: true, - }, - ], - name: 'OwnerUpdated', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'from', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - ], - name: 'ReceivedETH', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'withdrawer', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'recipient', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'asset', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - ], - name: 'WithdrewERC20', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'withdrawer', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'recipient', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'asset', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'id', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - ], - name: 'WithdrewERC721', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'withdrawer', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'recipient', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - ], - name: 'WithdrewETH', - }, - { - stateMutability: 'payable', - type: 'function', - inputs: [ - { name: '_target', internalType: 'address', type: 'address' }, - { name: '_data', internalType: 'bytes', type: 'bytes' }, - { name: '_gas', internalType: 'uint256', type: 'uint256' }, - { name: '_value', internalType: 'uint256', type: 'uint256' }, - ], - name: 'CALL', - outputs: [ - { name: '', internalType: 'bool', type: 'bool' }, - { name: '', internalType: 'bytes', type: 'bytes' }, - ], - }, - { - stateMutability: 'payable', - type: 'function', - inputs: [ - { name: '_target', internalType: 'address', type: 'address' }, - { name: '_data', internalType: 'bytes', type: 'bytes' }, - { name: '_gas', internalType: 'uint256', type: 'uint256' }, - ], - name: 'DELEGATECALL', - outputs: [ - { name: '', internalType: 'bool', type: 'bool' }, - { name: '', internalType: 'bytes', type: 'bytes' }, - ], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'owner', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], - name: 'setOwner', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_asset', internalType: 'contract ERC20', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - ], - name: 'withdrawERC20', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_asset', internalType: 'contract ERC20', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - ], - name: 'withdrawERC20', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_asset', internalType: 'contract ERC721', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_id', internalType: 'uint256', type: 'uint256' }, - ], - name: 'withdrawERC721', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_to', internalType: 'address payable', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - ], - name: 'withdrawETH', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_to', internalType: 'address payable', type: 'address' }, - ], - name: 'withdrawETH', - outputs: [], - }, - { stateMutability: 'payable', type: 'receive' }, - ], - AttestationStation: [ - { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'creator', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'about', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'key', - internalType: 'bytes32', - type: 'bytes32', - indexed: true, - }, - { name: 'val', internalType: 'bytes', type: 'bytes', indexed: false }, - ], - name: 'AttestationCreated', - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { - name: '_attestations', - internalType: 'struct AttestationStation.AttestationData[]', - type: 'tuple[]', - components: [ - { name: 'about', internalType: 'address', type: 'address' }, - { name: 'key', internalType: 'bytes32', type: 'bytes32' }, - { name: 'val', internalType: 'bytes', type: 'bytes' }, - ], - }, - ], - name: 'attest', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_about', internalType: 'address', type: 'address' }, - { name: '_key', internalType: 'bytes32', type: 'bytes32' }, - { name: '_val', internalType: 'bytes', type: 'bytes' }, - ], - name: 'attest', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [ - { name: '', internalType: 'address', type: 'address' }, - { name: '', internalType: 'address', type: 'address' }, - { name: '', internalType: 'bytes32', type: 'bytes32' }, - ], - name: 'attestations', - outputs: [{ name: '', internalType: 'bytes', type: 'bytes' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], - }, - ], - BaseFeeVault: [ - { - stateMutability: 'nonpayable', - type: 'constructor', - inputs: [ - { name: '_recipient', internalType: 'address', type: 'address' }, - ], - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'value', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - { - name: 'to', - internalType: 'address', - type: 'address', - indexed: false, - }, - { - name: 'from', - internalType: 'address', - type: 'address', - indexed: false, - }, - ], - name: 'Withdrawal', - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'MIN_WITHDRAWAL_AMOUNT', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'RECIPIENT', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'totalProcessed', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'withdraw', - outputs: [], - }, - { stateMutability: 'payable', type: 'receive' }, - ], - CheckBalanceHigh: [ - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'params', - internalType: 'struct CheckBalanceHigh.Params', - type: 'tuple', - components: [ - { name: 'target', internalType: 'address', type: 'address' }, - { name: 'threshold', internalType: 'uint256', type: 'uint256' }, - ], - indexed: false, - }, - ], - name: '_EventToExposeStructInABI__Params', - }, - { - stateMutability: 'view', - type: 'function', - inputs: [{ name: '_params', internalType: 'bytes', type: 'bytes' }], - name: 'check', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], - }, - ], - CheckBalanceLow: [ - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'params', - internalType: 'struct CheckBalanceLow.Params', - type: 'tuple', - components: [ - { name: 'target', internalType: 'address', type: 'address' }, - { name: 'threshold', internalType: 'uint256', type: 'uint256' }, - ], - indexed: false, - }, - ], - name: '_EventToExposeStructInABI__Params', - }, - { - stateMutability: 'view', - type: 'function', - inputs: [{ name: '_params', internalType: 'bytes', type: 'bytes' }], - name: 'check', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], - }, - ], - CheckGelatoLow: [ - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'params', - internalType: 'struct CheckGelatoLow.Params', - type: 'tuple', - components: [ - { name: 'treasury', internalType: 'address', type: 'address' }, - { name: 'threshold', internalType: 'uint256', type: 'uint256' }, - { name: 'recipient', internalType: 'address', type: 'address' }, - ], - indexed: false, - }, - ], - name: '_EventToExposeStructInABI__Params', - }, - { - stateMutability: 'view', - type: 'function', - inputs: [{ name: '_params', internalType: 'bytes', type: 'bytes' }], - name: 'check', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], - }, - ], - CheckTrue: [ - { - stateMutability: 'pure', - type: 'function', - inputs: [{ name: '', internalType: 'bytes', type: 'bytes' }], - name: 'check', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], - }, - ], - Drippie: [ - { - stateMutability: 'nonpayable', - type: 'constructor', - inputs: [{ name: '_owner', internalType: 'address', type: 'address' }], - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'nameref', - internalType: 'string', - type: 'string', - indexed: true, - }, - { - name: 'name', - internalType: 'string', - type: 'string', - indexed: false, - }, - { - name: 'config', - internalType: 'struct Drippie.DripConfig', - type: 'tuple', - components: [ - { name: 'reentrant', internalType: 'bool', type: 'bool' }, - { name: 'interval', internalType: 'uint256', type: 'uint256' }, - { - name: 'dripcheck', - internalType: 'contract IDripCheck', - type: 'address', - }, - { name: 'checkparams', internalType: 'bytes', type: 'bytes' }, - { - name: 'actions', - internalType: 'struct Drippie.DripAction[]', - type: 'tuple[]', - components: [ - { - name: 'target', - internalType: 'address payable', - type: 'address', - }, - { name: 'data', internalType: 'bytes', type: 'bytes' }, - { name: 'value', internalType: 'uint256', type: 'uint256' }, - ], - }, - ], - indexed: false, - }, - ], - name: 'DripCreated', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'nameref', - internalType: 'string', - type: 'string', - indexed: true, - }, - { - name: 'name', - internalType: 'string', - type: 'string', - indexed: false, - }, - { - name: 'executor', - internalType: 'address', - type: 'address', - indexed: false, - }, - { - name: 'timestamp', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - ], - name: 'DripExecuted', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'nameref', - internalType: 'string', - type: 'string', - indexed: true, - }, - { - name: 'name', - internalType: 'string', - type: 'string', - indexed: false, - }, - { - name: 'status', - internalType: 'enum Drippie.DripStatus', - type: 'uint8', - indexed: false, - }, - ], - name: 'DripStatusUpdated', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'user', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'newOwner', - internalType: 'address', - type: 'address', - indexed: true, - }, - ], - name: 'OwnerUpdated', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'from', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - ], - name: 'ReceivedETH', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'withdrawer', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'recipient', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'asset', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - ], - name: 'WithdrewERC20', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'withdrawer', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'recipient', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'asset', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'id', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - ], - name: 'WithdrewERC721', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'withdrawer', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'recipient', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - ], - name: 'WithdrewETH', - }, - { - stateMutability: 'payable', - type: 'function', - inputs: [ - { name: '_target', internalType: 'address', type: 'address' }, - { name: '_data', internalType: 'bytes', type: 'bytes' }, - { name: '_value', internalType: 'uint256', type: 'uint256' }, - ], - name: 'CALL', - outputs: [ - { name: '', internalType: 'bool', type: 'bool' }, - { name: '', internalType: 'bytes', type: 'bytes' }, - ], - }, - { - stateMutability: 'payable', - type: 'function', - inputs: [ - { name: '_target', internalType: 'address', type: 'address' }, - { name: '_data', internalType: 'bytes', type: 'bytes' }, - ], - name: 'DELEGATECALL', - outputs: [ - { name: '', internalType: 'bool', type: 'bool' }, - { name: '', internalType: 'bytes', type: 'bytes' }, - ], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_name', internalType: 'string', type: 'string' }, - { - name: '_config', - internalType: 'struct Drippie.DripConfig', - type: 'tuple', - components: [ - { name: 'reentrant', internalType: 'bool', type: 'bool' }, - { name: 'interval', internalType: 'uint256', type: 'uint256' }, - { - name: 'dripcheck', - internalType: 'contract IDripCheck', - type: 'address', - }, - { name: 'checkparams', internalType: 'bytes', type: 'bytes' }, - { - name: 'actions', - internalType: 'struct Drippie.DripAction[]', - type: 'tuple[]', - components: [ - { - name: 'target', - internalType: 'address payable', - type: 'address', - }, - { name: 'data', internalType: 'bytes', type: 'bytes' }, - { name: 'value', internalType: 'uint256', type: 'uint256' }, - ], - }, - ], - }, - ], - name: 'create', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: '_name', internalType: 'string', type: 'string' }], - name: 'drip', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [{ name: '', internalType: 'string', type: 'string' }], - name: 'drips', - outputs: [ - { - name: 'status', - internalType: 'enum Drippie.DripStatus', - type: 'uint8', - }, - { - name: 'config', - internalType: 'struct Drippie.DripConfig', - type: 'tuple', - components: [ - { name: 'reentrant', internalType: 'bool', type: 'bool' }, - { name: 'interval', internalType: 'uint256', type: 'uint256' }, - { - name: 'dripcheck', - internalType: 'contract IDripCheck', - type: 'address', - }, - { name: 'checkparams', internalType: 'bytes', type: 'bytes' }, - { - name: 'actions', - internalType: 'struct Drippie.DripAction[]', - type: 'tuple[]', - components: [ - { - name: 'target', - internalType: 'address payable', - type: 'address', - }, - { name: 'data', internalType: 'bytes', type: 'bytes' }, - { name: 'value', internalType: 'uint256', type: 'uint256' }, - ], - }, - ], - }, - { name: 'last', internalType: 'uint256', type: 'uint256' }, - { name: 'count', internalType: 'uint256', type: 'uint256' }, - ], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [{ name: '_name', internalType: 'string', type: 'string' }], - name: 'executable', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'owner', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], - name: 'setOwner', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_name', internalType: 'string', type: 'string' }, - { - name: '_status', - internalType: 'enum Drippie.DripStatus', - type: 'uint8', - }, - ], - name: 'status', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_asset', internalType: 'contract ERC20', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - ], - name: 'withdrawERC20', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_asset', internalType: 'contract ERC20', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - ], - name: 'withdrawERC20', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_asset', internalType: 'contract ERC721', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_id', internalType: 'uint256', type: 'uint256' }, - ], - name: 'withdrawERC721', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_to', internalType: 'address payable', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - ], - name: 'withdrawETH', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_to', internalType: 'address payable', type: 'address' }, - ], - name: 'withdrawETH', - outputs: [], - }, - { stateMutability: 'payable', type: 'receive' }, - ], - Drippie_goerli: [ - { - stateMutability: 'nonpayable', - type: 'constructor', - inputs: [{ name: '_owner', internalType: 'address', type: 'address' }], - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'nameref', - internalType: 'string', - type: 'string', - indexed: true, - }, - { - name: 'name', - internalType: 'string', - type: 'string', - indexed: false, - }, - { - name: 'config', - internalType: 'struct Drippie.DripConfig', - type: 'tuple', - components: [ - { name: 'reentrant', internalType: 'bool', type: 'bool' }, - { name: 'interval', internalType: 'uint256', type: 'uint256' }, - { - name: 'dripcheck', - internalType: 'contract IDripCheck', - type: 'address', - }, - { name: 'checkparams', internalType: 'bytes', type: 'bytes' }, - { - name: 'actions', - internalType: 'struct Drippie.DripAction[]', - type: 'tuple[]', - components: [ - { - name: 'target', - internalType: 'address payable', - type: 'address', - }, - { name: 'data', internalType: 'bytes', type: 'bytes' }, - { name: 'value', internalType: 'uint256', type: 'uint256' }, - ], - }, - ], - indexed: false, - }, - ], - name: 'DripCreated', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'nameref', - internalType: 'string', - type: 'string', - indexed: true, - }, - { - name: 'name', - internalType: 'string', - type: 'string', - indexed: false, - }, - { - name: 'executor', - internalType: 'address', - type: 'address', - indexed: false, - }, - { - name: 'timestamp', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - ], - name: 'DripExecuted', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'nameref', - internalType: 'string', - type: 'string', - indexed: true, - }, - { - name: 'name', - internalType: 'string', - type: 'string', - indexed: false, - }, - { - name: 'status', - internalType: 'enum Drippie.DripStatus', - type: 'uint8', - indexed: false, - }, - ], - name: 'DripStatusUpdated', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'user', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'newOwner', - internalType: 'address', - type: 'address', - indexed: true, - }, - ], - name: 'OwnerUpdated', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'from', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - ], - name: 'ReceivedETH', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'withdrawer', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'recipient', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'asset', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - ], - name: 'WithdrewERC20', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'withdrawer', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'recipient', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'asset', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'id', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - ], - name: 'WithdrewERC721', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'withdrawer', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'recipient', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - ], - name: 'WithdrewETH', - }, - { - stateMutability: 'payable', - type: 'function', - inputs: [ - { name: '_target', internalType: 'address', type: 'address' }, - { name: '_data', internalType: 'bytes', type: 'bytes' }, - { name: '_value', internalType: 'uint256', type: 'uint256' }, - ], - name: 'CALL', - outputs: [ - { name: '', internalType: 'bool', type: 'bool' }, - { name: '', internalType: 'bytes', type: 'bytes' }, - ], - }, - { - stateMutability: 'payable', - type: 'function', - inputs: [ - { name: '_target', internalType: 'address', type: 'address' }, - { name: '_data', internalType: 'bytes', type: 'bytes' }, - ], - name: 'DELEGATECALL', - outputs: [ - { name: '', internalType: 'bool', type: 'bool' }, - { name: '', internalType: 'bytes', type: 'bytes' }, - ], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_name', internalType: 'string', type: 'string' }, - { - name: '_config', - internalType: 'struct Drippie.DripConfig', - type: 'tuple', - components: [ - { name: 'reentrant', internalType: 'bool', type: 'bool' }, - { name: 'interval', internalType: 'uint256', type: 'uint256' }, - { - name: 'dripcheck', - internalType: 'contract IDripCheck', - type: 'address', - }, - { name: 'checkparams', internalType: 'bytes', type: 'bytes' }, - { - name: 'actions', - internalType: 'struct Drippie.DripAction[]', - type: 'tuple[]', - components: [ - { - name: 'target', - internalType: 'address payable', - type: 'address', - }, - { name: 'data', internalType: 'bytes', type: 'bytes' }, - { name: 'value', internalType: 'uint256', type: 'uint256' }, - ], - }, - ], - }, - ], - name: 'create', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: '_name', internalType: 'string', type: 'string' }], - name: 'drip', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [{ name: '', internalType: 'string', type: 'string' }], - name: 'drips', - outputs: [ - { - name: 'status', - internalType: 'enum Drippie.DripStatus', - type: 'uint8', - }, - { - name: 'config', - internalType: 'struct Drippie.DripConfig', - type: 'tuple', - components: [ - { name: 'reentrant', internalType: 'bool', type: 'bool' }, - { name: 'interval', internalType: 'uint256', type: 'uint256' }, - { - name: 'dripcheck', - internalType: 'contract IDripCheck', - type: 'address', - }, - { name: 'checkparams', internalType: 'bytes', type: 'bytes' }, - { - name: 'actions', - internalType: 'struct Drippie.DripAction[]', - type: 'tuple[]', - components: [ - { - name: 'target', - internalType: 'address payable', - type: 'address', - }, - { name: 'data', internalType: 'bytes', type: 'bytes' }, - { name: 'value', internalType: 'uint256', type: 'uint256' }, - ], - }, - ], - }, - { name: 'last', internalType: 'uint256', type: 'uint256' }, - { name: 'count', internalType: 'uint256', type: 'uint256' }, - ], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [{ name: '_name', internalType: 'string', type: 'string' }], - name: 'executable', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'owner', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], - name: 'setOwner', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_name', internalType: 'string', type: 'string' }, - { - name: '_status', - internalType: 'enum Drippie.DripStatus', - type: 'uint8', - }, - ], - name: 'status', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_asset', internalType: 'contract ERC20', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - ], - name: 'withdrawERC20', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_asset', internalType: 'contract ERC20', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - ], - name: 'withdrawERC20', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_asset', internalType: 'contract ERC721', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_id', internalType: 'uint256', type: 'uint256' }, - ], - name: 'withdrawERC721', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_to', internalType: 'address payable', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - ], - name: 'withdrawETH', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_to', internalType: 'address payable', type: 'address' }, - ], - name: 'withdrawETH', - outputs: [], - }, - { stateMutability: 'payable', type: 'receive' }, - ], - 'Drippie_optimism-goerli': [ - { - stateMutability: 'nonpayable', - type: 'constructor', - inputs: [{ name: '_owner', internalType: 'address', type: 'address' }], - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'nameref', - internalType: 'string', - type: 'string', - indexed: true, - }, - { - name: 'name', - internalType: 'string', - type: 'string', - indexed: false, - }, - { - name: 'config', - internalType: 'struct Drippie.DripConfig', - type: 'tuple', - components: [ - { name: 'interval', internalType: 'uint256', type: 'uint256' }, - { - name: 'dripcheck', - internalType: 'contract IDripCheck', - type: 'address', - }, - { name: 'checkparams', internalType: 'bytes', type: 'bytes' }, - { - name: 'actions', - internalType: 'struct Drippie.DripAction[]', - type: 'tuple[]', - components: [ - { - name: 'target', - internalType: 'address payable', - type: 'address', - }, - { name: 'data', internalType: 'bytes', type: 'bytes' }, - { name: 'value', internalType: 'uint256', type: 'uint256' }, - ], - }, - ], - indexed: false, - }, - ], - name: 'DripCreated', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'nameref', - internalType: 'string', - type: 'string', - indexed: true, - }, - { - name: 'name', - internalType: 'string', - type: 'string', - indexed: false, - }, - { - name: 'executor', - internalType: 'address', - type: 'address', - indexed: false, - }, - { - name: 'timestamp', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - ], - name: 'DripExecuted', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'nameref', - internalType: 'string', - type: 'string', - indexed: true, - }, - { - name: 'name', - internalType: 'string', - type: 'string', - indexed: false, - }, - { - name: 'status', - internalType: 'enum Drippie.DripStatus', - type: 'uint8', - indexed: false, - }, - ], - name: 'DripStatusUpdated', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'user', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'newOwner', - internalType: 'address', - type: 'address', - indexed: true, - }, - ], - name: 'OwnerUpdated', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'from', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - ], - name: 'ReceivedETH', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'withdrawer', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'recipient', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'asset', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - ], - name: 'WithdrewERC20', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'withdrawer', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'recipient', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'asset', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'id', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - ], - name: 'WithdrewERC721', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'withdrawer', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'recipient', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - ], - name: 'WithdrewETH', - }, - { - stateMutability: 'payable', - type: 'function', - inputs: [ - { name: '_target', internalType: 'address', type: 'address' }, - { name: '_data', internalType: 'bytes', type: 'bytes' }, - { name: '_gas', internalType: 'uint256', type: 'uint256' }, - { name: '_value', internalType: 'uint256', type: 'uint256' }, - ], - name: 'CALL', - outputs: [ - { name: '', internalType: 'bool', type: 'bool' }, - { name: '', internalType: 'bytes', type: 'bytes' }, - ], - }, - { - stateMutability: 'payable', - type: 'function', - inputs: [ - { name: '_target', internalType: 'address', type: 'address' }, - { name: '_data', internalType: 'bytes', type: 'bytes' }, - { name: '_gas', internalType: 'uint256', type: 'uint256' }, - ], - name: 'DELEGATECALL', - outputs: [ - { name: '', internalType: 'bool', type: 'bool' }, - { name: '', internalType: 'bytes', type: 'bytes' }, - ], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_name', internalType: 'string', type: 'string' }, - { - name: '_config', - internalType: 'struct Drippie.DripConfig', - type: 'tuple', - components: [ - { name: 'interval', internalType: 'uint256', type: 'uint256' }, - { - name: 'dripcheck', - internalType: 'contract IDripCheck', - type: 'address', - }, - { name: 'checkparams', internalType: 'bytes', type: 'bytes' }, - { - name: 'actions', - internalType: 'struct Drippie.DripAction[]', - type: 'tuple[]', - components: [ - { - name: 'target', - internalType: 'address payable', - type: 'address', - }, - { name: 'data', internalType: 'bytes', type: 'bytes' }, - { name: 'value', internalType: 'uint256', type: 'uint256' }, - ], - }, - ], - }, - ], - name: 'create', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: '_name', internalType: 'string', type: 'string' }], - name: 'drip', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [{ name: '', internalType: 'string', type: 'string' }], - name: 'drips', - outputs: [ - { - name: 'status', - internalType: 'enum Drippie.DripStatus', - type: 'uint8', - }, - { - name: 'config', - internalType: 'struct Drippie.DripConfig', - type: 'tuple', - components: [ - { name: 'interval', internalType: 'uint256', type: 'uint256' }, - { - name: 'dripcheck', - internalType: 'contract IDripCheck', - type: 'address', - }, - { name: 'checkparams', internalType: 'bytes', type: 'bytes' }, - { - name: 'actions', - internalType: 'struct Drippie.DripAction[]', - type: 'tuple[]', - components: [ - { - name: 'target', - internalType: 'address payable', - type: 'address', - }, - { name: 'data', internalType: 'bytes', type: 'bytes' }, - { name: 'value', internalType: 'uint256', type: 'uint256' }, - ], - }, - ], - }, - { name: 'last', internalType: 'uint256', type: 'uint256' }, - { name: 'count', internalType: 'uint256', type: 'uint256' }, - ], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [{ name: '_name', internalType: 'string', type: 'string' }], - name: 'executable', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'owner', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], - name: 'setOwner', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_name', internalType: 'string', type: 'string' }, - { - name: '_status', - internalType: 'enum Drippie.DripStatus', - type: 'uint8', - }, - ], - name: 'status', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_asset', internalType: 'contract ERC20', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - ], - name: 'withdrawERC20', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_asset', internalType: 'contract ERC20', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - ], - name: 'withdrawERC20', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_asset', internalType: 'contract ERC721', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_id', internalType: 'uint256', type: 'uint256' }, - ], - name: 'withdrawERC721', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_to', internalType: 'address payable', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - ], - name: 'withdrawETH', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_to', internalType: 'address payable', type: 'address' }, - ], - name: 'withdrawETH', - outputs: [], - }, - { stateMutability: 'payable', type: 'receive' }, - ], - EAS: [ - { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, - { type: 'error', inputs: [], name: 'AccessDenied' }, - { type: 'error', inputs: [], name: 'AlreadyRevoked' }, - { type: 'error', inputs: [], name: 'AlreadyRevokedOffchain' }, - { type: 'error', inputs: [], name: 'AlreadyTimestamped' }, - { type: 'error', inputs: [], name: 'InsufficientValue' }, - { type: 'error', inputs: [], name: 'InvalidAttestation' }, - { type: 'error', inputs: [], name: 'InvalidAttestations' }, - { type: 'error', inputs: [], name: 'InvalidExpirationTime' }, - { type: 'error', inputs: [], name: 'InvalidLength' }, - { type: 'error', inputs: [], name: 'InvalidOffset' }, - { type: 'error', inputs: [], name: 'InvalidRegistry' }, - { type: 'error', inputs: [], name: 'InvalidRevocation' }, - { type: 'error', inputs: [], name: 'InvalidRevocations' }, - { type: 'error', inputs: [], name: 'InvalidSchema' }, - { type: 'error', inputs: [], name: 'InvalidSignature' }, - { type: 'error', inputs: [], name: 'InvalidVerifier' }, - { type: 'error', inputs: [], name: 'Irrevocable' }, - { type: 'error', inputs: [], name: 'NotFound' }, - { type: 'error', inputs: [], name: 'NotPayable' }, - { type: 'error', inputs: [], name: 'WrongSchema' }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'recipient', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'attester', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'uid', - internalType: 'bytes32', - type: 'bytes32', - indexed: false, - }, - { - name: 'schema', - internalType: 'bytes32', - type: 'bytes32', - indexed: true, - }, - ], - name: 'Attested', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'recipient', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'attester', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'uid', - internalType: 'bytes32', - type: 'bytes32', - indexed: false, - }, - { - name: 'schema', - internalType: 'bytes32', - type: 'bytes32', - indexed: true, - }, - ], - name: 'Revoked', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'revoker', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'data', - internalType: 'bytes32', - type: 'bytes32', - indexed: true, - }, - { - name: 'timestamp', - internalType: 'uint64', - type: 'uint64', - indexed: true, - }, - ], - name: 'RevokedOffchain', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'data', - internalType: 'bytes32', - type: 'bytes32', - indexed: true, - }, - { - name: 'timestamp', - internalType: 'uint64', - type: 'uint64', - indexed: true, - }, - ], - name: 'Timestamped', - }, - { - stateMutability: 'payable', - type: 'function', - inputs: [ - { - name: 'request', - internalType: 'struct AttestationRequest', - type: 'tuple', - components: [ - { name: 'schema', internalType: 'bytes32', type: 'bytes32' }, - { - name: 'data', - internalType: 'struct AttestationRequestData', - type: 'tuple', - components: [ - { name: 'recipient', internalType: 'address', type: 'address' }, - { - name: 'expirationTime', - internalType: 'uint64', - type: 'uint64', - }, - { name: 'revocable', internalType: 'bool', type: 'bool' }, - { name: 'refUID', internalType: 'bytes32', type: 'bytes32' }, - { name: 'data', internalType: 'bytes', type: 'bytes' }, - { name: 'value', internalType: 'uint256', type: 'uint256' }, - ], - }, - ], - }, - ], - name: 'attest', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - }, - { - stateMutability: 'payable', - type: 'function', - inputs: [ - { - name: 'delegatedRequest', - internalType: 'struct DelegatedAttestationRequest', - type: 'tuple', - components: [ - { name: 'schema', internalType: 'bytes32', type: 'bytes32' }, - { - name: 'data', - internalType: 'struct AttestationRequestData', - type: 'tuple', - components: [ - { name: 'recipient', internalType: 'address', type: 'address' }, - { - name: 'expirationTime', - internalType: 'uint64', - type: 'uint64', - }, - { name: 'revocable', internalType: 'bool', type: 'bool' }, - { name: 'refUID', internalType: 'bytes32', type: 'bytes32' }, - { name: 'data', internalType: 'bytes', type: 'bytes' }, - { name: 'value', internalType: 'uint256', type: 'uint256' }, - ], - }, - { - name: 'signature', - internalType: 'struct EIP712Signature', - type: 'tuple', - components: [ - { name: 'v', internalType: 'uint8', type: 'uint8' }, - { name: 'r', internalType: 'bytes32', type: 'bytes32' }, - { name: 's', internalType: 'bytes32', type: 'bytes32' }, - ], - }, - { name: 'attester', internalType: 'address', type: 'address' }, - ], - }, - ], - name: 'attestByDelegation', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - }, - { - stateMutability: 'pure', - type: 'function', - inputs: [], - name: 'getAttestTypeHash', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [{ name: 'uid', internalType: 'bytes32', type: 'bytes32' }], - name: 'getAttestation', - outputs: [ - { - name: '', - internalType: 'struct Attestation', - type: 'tuple', - components: [ - { name: 'uid', internalType: 'bytes32', type: 'bytes32' }, - { name: 'schema', internalType: 'bytes32', type: 'bytes32' }, - { name: 'time', internalType: 'uint64', type: 'uint64' }, - { name: 'expirationTime', internalType: 'uint64', type: 'uint64' }, - { name: 'revocationTime', internalType: 'uint64', type: 'uint64' }, - { name: 'refUID', internalType: 'bytes32', type: 'bytes32' }, - { name: 'recipient', internalType: 'address', type: 'address' }, - { name: 'attester', internalType: 'address', type: 'address' }, - { name: 'revocable', internalType: 'bool', type: 'bool' }, - { name: 'data', internalType: 'bytes', type: 'bytes' }, - ], - }, - ], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'getDomainSeparator', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'getName', - outputs: [{ name: '', internalType: 'string', type: 'string' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [{ name: 'account', internalType: 'address', type: 'address' }], - name: 'getNonce', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [ - { name: 'revoker', internalType: 'address', type: 'address' }, - { name: 'data', internalType: 'bytes32', type: 'bytes32' }, - ], - name: 'getRevokeOffchain', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], - }, - { - stateMutability: 'pure', - type: 'function', - inputs: [], - name: 'getRevokeTypeHash', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - }, - { - stateMutability: 'pure', - type: 'function', - inputs: [], - name: 'getSchemaRegistry', - outputs: [ - { name: '', internalType: 'contract ISchemaRegistry', type: 'address' }, - ], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [{ name: 'data', internalType: 'bytes32', type: 'bytes32' }], - name: 'getTimestamp', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [{ name: 'uid', internalType: 'bytes32', type: 'bytes32' }], - name: 'isAttestationValid', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], - }, - { - stateMutability: 'payable', - type: 'function', - inputs: [ - { - name: 'multiRequests', - internalType: 'struct MultiAttestationRequest[]', - type: 'tuple[]', - components: [ - { name: 'schema', internalType: 'bytes32', type: 'bytes32' }, - { - name: 'data', - internalType: 'struct AttestationRequestData[]', - type: 'tuple[]', - components: [ - { name: 'recipient', internalType: 'address', type: 'address' }, - { - name: 'expirationTime', - internalType: 'uint64', - type: 'uint64', - }, - { name: 'revocable', internalType: 'bool', type: 'bool' }, - { name: 'refUID', internalType: 'bytes32', type: 'bytes32' }, - { name: 'data', internalType: 'bytes', type: 'bytes' }, - { name: 'value', internalType: 'uint256', type: 'uint256' }, - ], - }, - ], - }, - ], - name: 'multiAttest', - outputs: [{ name: '', internalType: 'bytes32[]', type: 'bytes32[]' }], - }, - { - stateMutability: 'payable', - type: 'function', - inputs: [ - { - name: 'multiDelegatedRequests', - internalType: 'struct MultiDelegatedAttestationRequest[]', - type: 'tuple[]', - components: [ - { name: 'schema', internalType: 'bytes32', type: 'bytes32' }, - { - name: 'data', - internalType: 'struct AttestationRequestData[]', - type: 'tuple[]', - components: [ - { name: 'recipient', internalType: 'address', type: 'address' }, - { - name: 'expirationTime', - internalType: 'uint64', - type: 'uint64', - }, - { name: 'revocable', internalType: 'bool', type: 'bool' }, - { name: 'refUID', internalType: 'bytes32', type: 'bytes32' }, - { name: 'data', internalType: 'bytes', type: 'bytes' }, - { name: 'value', internalType: 'uint256', type: 'uint256' }, - ], - }, - { - name: 'signatures', - internalType: 'struct EIP712Signature[]', - type: 'tuple[]', - components: [ - { name: 'v', internalType: 'uint8', type: 'uint8' }, - { name: 'r', internalType: 'bytes32', type: 'bytes32' }, - { name: 's', internalType: 'bytes32', type: 'bytes32' }, - ], - }, - { name: 'attester', internalType: 'address', type: 'address' }, - ], - }, - ], - name: 'multiAttestByDelegation', - outputs: [{ name: '', internalType: 'bytes32[]', type: 'bytes32[]' }], - }, +} + +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// abisByContractByNetwork +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +export const abis = { + AddressManager: [ { - stateMutability: 'payable', - type: 'function', + type: 'event', + anonymous: false, inputs: [ { - name: 'multiRequests', - internalType: 'struct MultiRevocationRequest[]', - type: 'tuple[]', - components: [ - { name: 'schema', internalType: 'bytes32', type: 'bytes32' }, - { - name: 'data', - internalType: 'struct RevocationRequestData[]', - type: 'tuple[]', - components: [ - { name: 'uid', internalType: 'bytes32', type: 'bytes32' }, - { name: 'value', internalType: 'uint256', type: 'uint256' }, - ], - }, - ], + name: '_name', + internalType: 'string', + type: 'string', + indexed: true, }, - ], - name: 'multiRevoke', - outputs: [], - }, - { - stateMutability: 'payable', - type: 'function', - inputs: [ { - name: 'multiDelegatedRequests', - internalType: 'struct MultiDelegatedRevocationRequest[]', - type: 'tuple[]', - components: [ - { name: 'schema', internalType: 'bytes32', type: 'bytes32' }, - { - name: 'data', - internalType: 'struct RevocationRequestData[]', - type: 'tuple[]', - components: [ - { name: 'uid', internalType: 'bytes32', type: 'bytes32' }, - { name: 'value', internalType: 'uint256', type: 'uint256' }, - ], - }, - { - name: 'signatures', - internalType: 'struct EIP712Signature[]', - type: 'tuple[]', - components: [ - { name: 'v', internalType: 'uint8', type: 'uint8' }, - { name: 'r', internalType: 'bytes32', type: 'bytes32' }, - { name: 's', internalType: 'bytes32', type: 'bytes32' }, - ], - }, - { name: 'revoker', internalType: 'address', type: 'address' }, - ], - }, - ], - name: 'multiRevokeByDelegation', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: 'data', internalType: 'bytes32[]', type: 'bytes32[]' }], - name: 'multiRevokeOffchain', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: 'data', internalType: 'bytes32[]', type: 'bytes32[]' }], - name: 'multiTimestamp', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], - }, - { - stateMutability: 'payable', - type: 'function', - inputs: [ + name: '_newAddress', + internalType: 'address', + type: 'address', + indexed: false, + }, { - name: 'request', - internalType: 'struct RevocationRequest', - type: 'tuple', - components: [ - { name: 'schema', internalType: 'bytes32', type: 'bytes32' }, - { - name: 'data', - internalType: 'struct RevocationRequestData', - type: 'tuple', - components: [ - { name: 'uid', internalType: 'bytes32', type: 'bytes32' }, - { name: 'value', internalType: 'uint256', type: 'uint256' }, - ], - }, - ], + name: '_oldAddress', + internalType: 'address', + type: 'address', + indexed: false, }, ], - name: 'revoke', - outputs: [], + name: 'AddressSet', }, { - stateMutability: 'payable', - type: 'function', + type: 'event', + anonymous: false, inputs: [ { - name: 'delegatedRequest', - internalType: 'struct DelegatedRevocationRequest', - type: 'tuple', - components: [ - { name: 'schema', internalType: 'bytes32', type: 'bytes32' }, - { - name: 'data', - internalType: 'struct RevocationRequestData', - type: 'tuple', - components: [ - { name: 'uid', internalType: 'bytes32', type: 'bytes32' }, - { name: 'value', internalType: 'uint256', type: 'uint256' }, - ], - }, - { - name: 'signature', - internalType: 'struct EIP712Signature', - type: 'tuple', - components: [ - { name: 'v', internalType: 'uint8', type: 'uint8' }, - { name: 'r', internalType: 'bytes32', type: 'bytes32' }, - { name: 's', internalType: 'bytes32', type: 'bytes32' }, - ], - }, - { name: 'revoker', internalType: 'address', type: 'address' }, - ], + name: 'previousOwner', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'newOwner', + internalType: 'address', + type: 'address', + indexed: true, }, ], - name: 'revokeByDelegation', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: 'data', internalType: 'bytes32', type: 'bytes32' }], - name: 'revokeOffchain', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: 'data', internalType: 'bytes32', type: 'bytes32' }], - name: 'timestamp', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], - }, - ], - GasPriceOracle: [ - { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'DECIMALS', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'baseFee', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'pure', - type: 'function', - inputs: [], - name: 'decimals', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'gasPrice', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [{ name: '_data', internalType: 'bytes', type: 'bytes' }], - name: 'getL1Fee', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [{ name: '_data', internalType: 'bytes', type: 'bytes' }], - name: 'getL1GasUsed', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'l1BaseFee', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'overhead', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'scalar', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + name: 'OwnershipTransferred', }, - ], - L1Block: [ - { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, { stateMutability: 'view', type: 'function', - inputs: [], - name: 'DEPOSITOR_ACCOUNT', + inputs: [{ name: '_name', internalType: 'string', type: 'string' }], + name: 'getAddress', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'basefee', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'batcherHash', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'hash', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'l1FeeOverhead', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'l1FeeScalar', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'number', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + name: 'owner', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', inputs: [], - name: 'sequenceNumber', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + name: 'renounceOwnership', + outputs: [], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_number', internalType: 'uint64', type: 'uint64' }, - { name: '_timestamp', internalType: 'uint64', type: 'uint64' }, - { name: '_basefee', internalType: 'uint256', type: 'uint256' }, - { name: '_hash', internalType: 'bytes32', type: 'bytes32' }, - { name: '_sequenceNumber', internalType: 'uint64', type: 'uint64' }, - { name: '_batcherHash', internalType: 'bytes32', type: 'bytes32' }, - { name: '_l1FeeOverhead', internalType: 'uint256', type: 'uint256' }, - { name: '_l1FeeScalar', internalType: 'uint256', type: 'uint256' }, + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_address', internalType: 'address', type: 'address' }, ], - name: 'setL1BlockValues', + name: 'setAddress', outputs: [], }, { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'timestamp', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], - }, - { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], + name: 'transferOwnership', + outputs: [], }, ], - L1CrossDomainMessenger: [ + AssetReceiver: [ { stateMutability: 'nonpayable', type: 'constructor', + inputs: [{ name: '_owner', internalType: 'address', type: 'address' }], + }, + { + type: 'event', + anonymous: false, inputs: [ { - name: '_portal', - internalType: 'contract OptimismPortal', + name: 'user', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'newOwner', + internalType: 'address', type: 'address', + indexed: true, }, ], + name: 'OwnerUpdated', }, { type: 'event', anonymous: false, inputs: [ { - name: 'msgHash', - internalType: 'bytes32', - type: 'bytes32', + name: 'from', + internalType: 'address', + type: 'address', indexed: true, }, - ], - name: 'FailedRelayedMessage', - }, - { - type: 'event', - anonymous: false, - inputs: [ { - name: 'version', - internalType: 'uint8', - type: 'uint8', + name: 'amount', + internalType: 'uint256', + type: 'uint256', indexed: false, }, ], - name: 'Initialized', + name: 'ReceivedETH', }, { type: 'event', anonymous: false, inputs: [ { - name: 'msgHash', - internalType: 'bytes32', - type: 'bytes32', + name: 'withdrawer', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'recipient', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'asset', + internalType: 'address', + type: 'address', indexed: true, }, + { + name: 'amount', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, ], - name: 'RelayedMessage', + name: 'WithdrewERC20', }, { type: 'event', anonymous: false, inputs: [ { - name: 'target', + name: 'withdrawer', internalType: 'address', type: 'address', indexed: true, }, { - name: 'sender', + name: 'recipient', internalType: 'address', type: 'address', - indexed: false, - }, - { - name: 'message', - internalType: 'bytes', - type: 'bytes', - indexed: false, + indexed: true, }, { - name: 'messageNonce', - internalType: 'uint256', - type: 'uint256', - indexed: false, + name: 'asset', + internalType: 'address', + type: 'address', + indexed: true, }, { - name: 'gasLimit', + name: 'id', internalType: 'uint256', type: 'uint256', indexed: false, }, ], - name: 'SentMessage', + name: 'WithdrewERC721', }, { type: 'event', anonymous: false, inputs: [ { - name: 'sender', + name: 'withdrawer', internalType: 'address', type: 'address', indexed: true, }, { - name: 'value', + name: 'recipient', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'amount', internalType: 'uint256', type: 'uint256', indexed: false, }, ], - name: 'SentMessageExtension1', - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'MESSAGE_VERSION', - outputs: [{ name: '', internalType: 'uint16', type: 'uint16' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'MIN_GAS_CALLDATA_OVERHEAD', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'MIN_GAS_DYNAMIC_OVERHEAD_DENOMINATOR', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'MIN_GAS_DYNAMIC_OVERHEAD_NUMERATOR', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'OTHER_MESSENGER', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'WithdrewETH', }, { - stateMutability: 'view', + stateMutability: 'payable', type: 'function', - inputs: [], - name: 'PORTAL', + inputs: [ + { name: '_target', internalType: 'address', type: 'address' }, + { name: '_data', internalType: 'bytes', type: 'bytes' }, + { name: '_gas', internalType: 'uint256', type: 'uint256' }, + { name: '_value', internalType: 'uint256', type: 'uint256' }, + ], + name: 'CALL', outputs: [ - { name: '', internalType: 'contract OptimismPortal', type: 'address' }, + { name: '', internalType: 'bool', type: 'bool' }, + { name: '', internalType: 'bytes', type: 'bytes' }, ], }, { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'RELAY_CALL_OVERHEAD', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'RELAY_CONSTANT_OVERHEAD', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'RELAY_GAS_CHECK_BUFFER', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'RELAY_RESERVED_GAS', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], - }, - { - stateMutability: 'pure', + stateMutability: 'payable', type: 'function', inputs: [ - { name: '_message', internalType: 'bytes', type: 'bytes' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_target', internalType: 'address', type: 'address' }, + { name: '_data', internalType: 'bytes', type: 'bytes' }, + { name: '_gas', internalType: 'uint256', type: 'uint256' }, + ], + name: 'DELEGATECALL', + outputs: [ + { name: '', internalType: 'bool', type: 'bool' }, + { name: '', internalType: 'bytes', type: 'bytes' }, ], - name: 'baseGas', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], }, { stateMutability: 'view', type: 'function', - inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - name: 'failedMessages', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + inputs: [], + name: 'owner', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'initialize', + inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], + name: 'setOwner', outputs: [], }, { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'messageNonce', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'payable', + stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_nonce', internalType: 'uint256', type: 'uint256' }, - { name: '_sender', internalType: 'address', type: 'address' }, - { name: '_target', internalType: 'address', type: 'address' }, - { name: '_value', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint256', type: 'uint256' }, - { name: '_message', internalType: 'bytes', type: 'bytes' }, + { name: '_asset', internalType: 'contract ERC20', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, ], - name: 'relayMessage', + name: 'withdrawERC20', outputs: [], }, { - stateMutability: 'payable', + stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_target', internalType: 'address', type: 'address' }, - { name: '_message', internalType: 'bytes', type: 'bytes' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_asset', internalType: 'contract ERC20', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, ], - name: 'sendMessage', + name: 'withdrawERC20', outputs: [], }, { - stateMutability: 'view', - type: 'function', - inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - name: 'successfulMessages', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], - }, - { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'xDomainMessageSender', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - ], - L1CrossDomainMessenger_goerli: [ - { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, - { - type: 'event', - anonymous: false, inputs: [ - { - name: 'msgHash', - internalType: 'bytes32', - type: 'bytes32', - indexed: true, - }, + { name: '_asset', internalType: 'contract ERC721', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_id', internalType: 'uint256', type: 'uint256' }, ], - name: 'FailedRelayedMessage', + name: 'withdrawERC721', + outputs: [], }, { - type: 'event', - anonymous: false, + stateMutability: 'nonpayable', + type: 'function', inputs: [ - { - name: 'version', - internalType: 'uint8', - type: 'uint8', - indexed: false, - }, + { name: '_to', internalType: 'address payable', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, ], - name: 'Initialized', + name: 'withdrawETH', + outputs: [], }, { - type: 'event', - anonymous: false, + stateMutability: 'nonpayable', + type: 'function', inputs: [ - { - name: 'msgHash', - internalType: 'bytes32', - type: 'bytes32', - indexed: true, - }, + { name: '_to', internalType: 'address payable', type: 'address' }, ], - name: 'RelayedMessage', + name: 'withdrawETH', + outputs: [], }, + { stateMutability: 'payable', type: 'receive' }, + ], + AttestationStation: [ + { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, { type: 'event', anonymous: false, inputs: [ { - name: 'target', + name: 'creator', internalType: 'address', type: 'address', indexed: true, }, { - name: 'sender', + name: 'about', internalType: 'address', type: 'address', - indexed: false, - }, - { - name: 'message', - internalType: 'bytes', - type: 'bytes', - indexed: false, - }, - { - name: 'messageNonce', - internalType: 'uint256', - type: 'uint256', - indexed: false, + indexed: true, }, { - name: 'gasLimit', - internalType: 'uint256', - type: 'uint256', - indexed: false, + name: 'key', + internalType: 'bytes32', + type: 'bytes32', + indexed: true, }, + { name: 'val', internalType: 'bytes', type: 'bytes', indexed: false }, ], - name: 'SentMessage', + name: 'AttestationCreated', }, { - type: 'event', - anonymous: false, + stateMutability: 'nonpayable', + type: 'function', inputs: [ { - name: 'sender', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'value', - internalType: 'uint256', - type: 'uint256', - indexed: false, + name: '_attestations', + internalType: 'struct AttestationStation.AttestationData[]', + type: 'tuple[]', + components: [ + { name: 'about', internalType: 'address', type: 'address' }, + { name: 'key', internalType: 'bytes32', type: 'bytes32' }, + { name: 'val', internalType: 'bytes', type: 'bytes' }, + ], }, ], - name: 'SentMessageExtension1', - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'MESSAGE_VERSION', - outputs: [{ name: '', internalType: 'uint16', type: 'uint16' }], + name: 'attest', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'MIN_GAS_CALLDATA_OVERHEAD', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + inputs: [ + { name: '_about', internalType: 'address', type: 'address' }, + { name: '_key', internalType: 'bytes32', type: 'bytes32' }, + { name: '_val', internalType: 'bytes', type: 'bytes' }, + ], + name: 'attest', + outputs: [], }, { stateMutability: 'view', type: 'function', - inputs: [], - name: 'MIN_GAS_DYNAMIC_OVERHEAD_DENOMINATOR', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + inputs: [ + { name: '', internalType: 'address', type: 'address' }, + { name: '', internalType: 'address', type: 'address' }, + { name: '', internalType: 'bytes32', type: 'bytes32' }, + ], + name: 'attestations', + outputs: [{ name: '', internalType: 'bytes', type: 'bytes' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'MIN_GAS_DYNAMIC_OVERHEAD_NUMERATOR', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + name: 'version', + outputs: [{ name: '', internalType: 'string', type: 'string' }], }, + ], + BaseFeeVault: [ { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'OTHER_MESSENGER', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + stateMutability: 'nonpayable', + type: 'constructor', + inputs: [ + { name: '_recipient', internalType: 'address', type: 'address' }, + ], }, { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'PORTAL', - outputs: [ - { name: '', internalType: 'contract OptimismPortal', type: 'address' }, + type: 'event', + anonymous: false, + inputs: [ + { + name: 'value', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + { + name: 'to', + internalType: 'address', + type: 'address', + indexed: false, + }, + { + name: 'from', + internalType: 'address', + type: 'address', + indexed: false, + }, ], + name: 'Withdrawal', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'RELAY_CALL_OVERHEAD', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + name: 'MIN_WITHDRAWAL_AMOUNT', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'RELAY_CONSTANT_OVERHEAD', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + name: 'RECIPIENT', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'RELAY_GAS_CHECK_BUFFER', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + name: 'totalProcessed', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'RELAY_RESERVED_GAS', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], - }, - { - stateMutability: 'pure', - type: 'function', - inputs: [ - { name: '_message', internalType: 'bytes', type: 'bytes' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - ], - name: 'baseGas', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + name: 'version', + outputs: [{ name: '', internalType: 'string', type: 'string' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - name: 'failedMessages', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + inputs: [], + name: 'withdraw', + outputs: [], }, + { stateMutability: 'payable', type: 'receive' }, + ], + CheckBalanceHigh: [ { - stateMutability: 'nonpayable', - type: 'function', + type: 'event', + anonymous: false, inputs: [ { - name: '_portal', - internalType: 'contract OptimismPortal', - type: 'address', + name: 'params', + internalType: 'struct CheckBalanceHigh.Params', + type: 'tuple', + components: [ + { name: 'target', internalType: 'address', type: 'address' }, + { name: 'threshold', internalType: 'uint256', type: 'uint256' }, + ], + indexed: false, }, ], - name: 'initialize', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'messageNonce', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: '_EventToExposeStructInABI__Params', }, { stateMutability: 'view', type: 'function', - inputs: [], - name: 'portal', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'payable', - type: 'function', - inputs: [ - { name: '_nonce', internalType: 'uint256', type: 'uint256' }, - { name: '_sender', internalType: 'address', type: 'address' }, - { name: '_target', internalType: 'address', type: 'address' }, - { name: '_value', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint256', type: 'uint256' }, - { name: '_message', internalType: 'bytes', type: 'bytes' }, - ], - name: 'relayMessage', - outputs: [], + inputs: [{ name: '_params', internalType: 'bytes', type: 'bytes' }], + name: 'check', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, + ], + CheckBalanceLow: [ { - stateMutability: 'payable', - type: 'function', + type: 'event', + anonymous: false, inputs: [ - { name: '_target', internalType: 'address', type: 'address' }, - { name: '_message', internalType: 'bytes', type: 'bytes' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { + name: 'params', + internalType: 'struct CheckBalanceLow.Params', + type: 'tuple', + components: [ + { name: 'target', internalType: 'address', type: 'address' }, + { name: 'threshold', internalType: 'uint256', type: 'uint256' }, + ], + indexed: false, + }, ], - name: 'sendMessage', - outputs: [], + name: '_EventToExposeStructInABI__Params', }, { stateMutability: 'view', type: 'function', - inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - name: 'successfulMessages', + inputs: [{ name: '_params', internalType: 'bytes', type: 'bytes' }], + name: 'check', outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, + ], + CheckGelatoLow: [ + { + type: 'event', + anonymous: false, + inputs: [ + { + name: 'params', + internalType: 'struct CheckGelatoLow.Params', + type: 'tuple', + components: [ + { name: 'treasury', internalType: 'address', type: 'address' }, + { name: 'threshold', internalType: 'uint256', type: 'uint256' }, + { name: 'recipient', internalType: 'address', type: 'address' }, + ], + indexed: false, + }, + ], + name: '_EventToExposeStructInABI__Params', + }, { stateMutability: 'view', type: 'function', - inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + inputs: [{ name: '_params', internalType: 'bytes', type: 'bytes' }], + name: 'check', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, + ], + CheckTrue: [ { - stateMutability: 'view', + stateMutability: 'pure', type: 'function', - inputs: [], - name: 'xDomainMessageSender', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + inputs: [{ name: '', internalType: 'bytes', type: 'bytes' }], + name: 'check', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, ], - L1ERC721Bridge: [ + Drippie: [ { stateMutability: 'nonpayable', type: 'constructor', - inputs: [ - { name: '_messenger', internalType: 'address', type: 'address' }, - { name: '_otherBridge', internalType: 'address', type: 'address' }, - ], + inputs: [{ name: '_owner', internalType: 'address', type: 'address' }], }, { type: 'event', anonymous: false, inputs: [ { - name: 'localToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'remoteToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'from', - internalType: 'address', - type: 'address', + name: 'nameref', + internalType: 'string', + type: 'string', indexed: true, }, { - name: 'to', - internalType: 'address', - type: 'address', - indexed: false, - }, - { - name: 'tokenId', - internalType: 'uint256', - type: 'uint256', + name: 'name', + internalType: 'string', + type: 'string', indexed: false, }, { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', + name: 'config', + internalType: 'struct Drippie.DripConfig', + type: 'tuple', + components: [ + { name: 'reentrant', internalType: 'bool', type: 'bool' }, + { name: 'interval', internalType: 'uint256', type: 'uint256' }, + { + name: 'dripcheck', + internalType: 'contract IDripCheck', + type: 'address', + }, + { name: 'checkparams', internalType: 'bytes', type: 'bytes' }, + { + name: 'actions', + internalType: 'struct Drippie.DripAction[]', + type: 'tuple[]', + components: [ + { + name: 'target', + internalType: 'address payable', + type: 'address', + }, + { name: 'data', internalType: 'bytes', type: 'bytes' }, + { name: 'value', internalType: 'uint256', type: 'uint256' }, + ], + }, + ], indexed: false, }, ], - name: 'ERC721BridgeFinalized', + name: 'DripCreated', }, { type: 'event', anonymous: false, inputs: [ { - name: 'localToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'remoteToken', - internalType: 'address', - type: 'address', + name: 'nameref', + internalType: 'string', + type: 'string', indexed: true, }, { - name: 'from', - internalType: 'address', - type: 'address', - indexed: true, + name: 'name', + internalType: 'string', + type: 'string', + indexed: false, }, { - name: 'to', + name: 'executor', internalType: 'address', type: 'address', indexed: false, }, { - name: 'tokenId', + name: 'timestamp', internalType: 'uint256', type: 'uint256', indexed: false, }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, - }, ], - name: 'ERC721BridgeInitiated', + name: 'DripExecuted', }, { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'MESSENGER', - outputs: [ + type: 'event', + anonymous: false, + inputs: [ { - name: '', - internalType: 'contract CrossDomainMessenger', - type: 'address', + name: 'nameref', + internalType: 'string', + type: 'string', + indexed: true, }, - ], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'OTHER_BRIDGE', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'bridgeERC721', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'bridgeERC721To', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [ - { name: '', internalType: 'address', type: 'address' }, - { name: '', internalType: 'address', type: 'address' }, - { name: '', internalType: 'uint256', type: 'uint256' }, - ], - name: 'deposits', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_from', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'finalizeBridgeERC721', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'messenger', - outputs: [ { - name: '', - internalType: 'contract CrossDomainMessenger', - type: 'address', + name: 'name', + internalType: 'string', + type: 'string', + indexed: false, + }, + { + name: 'status', + internalType: 'enum Drippie.DripStatus', + type: 'uint8', + indexed: false, }, ], + name: 'DripStatusUpdated', }, { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'otherBridge', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + type: 'event', + anonymous: false, + inputs: [ + { + name: 'user', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'newOwner', + internalType: 'address', + type: 'address', + indexed: true, + }, + ], + name: 'OwnerUpdated', }, - ], - L1ERC721Bridge_goerli: [ - { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, { type: 'event', anonymous: false, inputs: [ { - name: 'localToken', + name: 'from', internalType: 'address', type: 'address', indexed: true, }, { - name: 'remoteToken', + name: 'amount', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + ], + name: 'ReceivedETH', + }, + { + type: 'event', + anonymous: false, + inputs: [ + { + name: 'withdrawer', internalType: 'address', type: 'address', indexed: true, }, { - name: 'from', + name: 'recipient', internalType: 'address', type: 'address', indexed: true, }, { - name: 'to', + name: 'asset', internalType: 'address', type: 'address', - indexed: false, + indexed: true, }, { - name: 'tokenId', + name: 'amount', internalType: 'uint256', type: 'uint256', indexed: false, }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, - }, ], - name: 'ERC721BridgeFinalized', + name: 'WithdrewERC20', }, { type: 'event', anonymous: false, inputs: [ { - name: 'localToken', + name: 'withdrawer', internalType: 'address', type: 'address', indexed: true, }, { - name: 'remoteToken', + name: 'recipient', internalType: 'address', type: 'address', indexed: true, }, { - name: 'from', + name: 'asset', internalType: 'address', type: 'address', indexed: true, }, { - name: 'to', - internalType: 'address', - type: 'address', - indexed: false, - }, - { - name: 'tokenId', + name: 'id', internalType: 'uint256', type: 'uint256', indexed: false, }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, - }, ], - name: 'ERC721BridgeInitiated', + name: 'WithdrewERC721', }, { type: 'event', anonymous: false, inputs: [ { - name: 'version', - internalType: 'uint8', - type: 'uint8', - indexed: false, + name: 'withdrawer', + internalType: 'address', + type: 'address', + indexed: true, }, - ], - name: 'Initialized', - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'MESSENGER', - outputs: [ { - name: '', - internalType: 'contract CrossDomainMessenger', + name: 'recipient', + internalType: 'address', type: 'address', + indexed: true, + }, + { + name: 'amount', + internalType: 'uint256', + type: 'uint256', + indexed: false, }, ], + name: 'WithdrewETH', }, { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'OTHER_BRIDGE', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'nonpayable', + stateMutability: 'payable', type: 'function', inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { name: '_target', internalType: 'address', type: 'address' }, + { name: '_data', internalType: 'bytes', type: 'bytes' }, + { name: '_value', internalType: 'uint256', type: 'uint256' }, ], - name: 'bridgeERC721', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + name: 'CALL', + outputs: [ + { name: '', internalType: 'bool', type: 'bool' }, + { name: '', internalType: 'bytes', type: 'bytes' }, ], - name: 'bridgeERC721To', - outputs: [], }, { - stateMutability: 'view', + stateMutability: 'payable', type: 'function', inputs: [ - { name: '', internalType: 'address', type: 'address' }, - { name: '', internalType: 'address', type: 'address' }, - { name: '', internalType: 'uint256', type: 'uint256' }, + { name: '_target', internalType: 'address', type: 'address' }, + { name: '_data', internalType: 'bytes', type: 'bytes' }, + ], + name: 'DELEGATECALL', + outputs: [ + { name: '', internalType: 'bool', type: 'bool' }, + { name: '', internalType: 'bytes', type: 'bytes' }, ], - name: 'deposits', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_from', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { name: '_name', internalType: 'string', type: 'string' }, + { + name: '_config', + internalType: 'struct Drippie.DripConfig', + type: 'tuple', + components: [ + { name: 'reentrant', internalType: 'bool', type: 'bool' }, + { name: 'interval', internalType: 'uint256', type: 'uint256' }, + { + name: 'dripcheck', + internalType: 'contract IDripCheck', + type: 'address', + }, + { name: 'checkparams', internalType: 'bytes', type: 'bytes' }, + { + name: 'actions', + internalType: 'struct Drippie.DripAction[]', + type: 'tuple[]', + components: [ + { + name: 'target', + internalType: 'address payable', + type: 'address', + }, + { name: 'data', internalType: 'bytes', type: 'bytes' }, + { name: 'value', internalType: 'uint256', type: 'uint256' }, + ], + }, + ], + }, ], - name: 'finalizeBridgeERC721', + name: 'create', outputs: [], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [ - { - name: '_messenger', - internalType: 'contract CrossDomainMessenger', - type: 'address', - }, - ], - name: 'initialize', + inputs: [{ name: '_name', internalType: 'string', type: 'string' }], + name: 'drip', outputs: [], }, { stateMutability: 'view', type: 'function', - inputs: [], - name: 'messenger', + inputs: [{ name: '', internalType: 'string', type: 'string' }], + name: 'drips', outputs: [ { - name: '', - internalType: 'contract CrossDomainMessenger', - type: 'address', + name: 'status', + internalType: 'enum Drippie.DripStatus', + type: 'uint8', + }, + { + name: 'config', + internalType: 'struct Drippie.DripConfig', + type: 'tuple', + components: [ + { name: 'reentrant', internalType: 'bool', type: 'bool' }, + { name: 'interval', internalType: 'uint256', type: 'uint256' }, + { + name: 'dripcheck', + internalType: 'contract IDripCheck', + type: 'address', + }, + { name: 'checkparams', internalType: 'bytes', type: 'bytes' }, + { + name: 'actions', + internalType: 'struct Drippie.DripAction[]', + type: 'tuple[]', + components: [ + { + name: 'target', + internalType: 'address payable', + type: 'address', + }, + { name: 'data', internalType: 'bytes', type: 'bytes' }, + { name: 'value', internalType: 'uint256', type: 'uint256' }, + ], + }, + ], }, + { name: 'last', internalType: 'uint256', type: 'uint256' }, + { name: 'count', internalType: 'uint256', type: 'uint256' }, ], }, { stateMutability: 'view', type: 'function', - inputs: [], - name: 'otherBridge', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + inputs: [{ name: '_name', internalType: 'string', type: 'string' }], + name: 'executable', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + name: 'owner', + outputs: [{ name: '', internalType: 'address', type: 'address' }], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], + name: 'setOwner', + outputs: [], }, - ], - L1FeeVault: [ { stateMutability: 'nonpayable', - type: 'constructor', - inputs: [ - { name: '_recipient', internalType: 'address', type: 'address' }, - ], - }, - { - type: 'event', - anonymous: false, + type: 'function', inputs: [ + { name: '_name', internalType: 'string', type: 'string' }, { - name: 'value', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - { - name: 'to', - internalType: 'address', - type: 'address', - indexed: false, - }, - { - name: 'from', - internalType: 'address', - type: 'address', - indexed: false, + name: '_status', + internalType: 'enum Drippie.DripStatus', + type: 'uint8', }, ], - name: 'Withdrawal', + name: 'status', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'MIN_WITHDRAWAL_AMOUNT', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + inputs: [ + { name: '_asset', internalType: 'contract ERC20', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, + ], + name: 'withdrawERC20', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'RECIPIENT', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + inputs: [ + { name: '_asset', internalType: 'contract ERC20', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + ], + name: 'withdrawERC20', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'totalProcessed', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + inputs: [ + { name: '_asset', internalType: 'contract ERC721', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_id', internalType: 'uint256', type: 'uint256' }, + ], + name: 'withdrawERC721', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + inputs: [ + { name: '_to', internalType: 'address payable', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, + ], + name: 'withdrawETH', + outputs: [], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'withdraw', + inputs: [ + { name: '_to', internalType: 'address payable', type: 'address' }, + ], + name: 'withdrawETH', outputs: [], }, { stateMutability: 'payable', type: 'receive' }, ], - L1StandardBridge: [ + Drippie_goerli: [ { stateMutability: 'nonpayable', type: 'constructor', - inputs: [ - { - name: '_messenger', - internalType: 'address payable', - type: 'address', - }, - ], + inputs: [{ name: '_owner', internalType: 'address', type: 'address' }], }, { type: 'event', anonymous: false, inputs: [ { - name: 'localToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'remoteToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'from', - internalType: 'address', - type: 'address', + name: 'nameref', + internalType: 'string', + type: 'string', indexed: true, }, { - name: 'to', - internalType: 'address', - type: 'address', - indexed: false, - }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', + name: 'name', + internalType: 'string', + type: 'string', indexed: false, }, { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', + name: 'config', + internalType: 'struct Drippie.DripConfig', + type: 'tuple', + components: [ + { name: 'reentrant', internalType: 'bool', type: 'bool' }, + { name: 'interval', internalType: 'uint256', type: 'uint256' }, + { + name: 'dripcheck', + internalType: 'contract IDripCheck', + type: 'address', + }, + { name: 'checkparams', internalType: 'bytes', type: 'bytes' }, + { + name: 'actions', + internalType: 'struct Drippie.DripAction[]', + type: 'tuple[]', + components: [ + { + name: 'target', + internalType: 'address payable', + type: 'address', + }, + { name: 'data', internalType: 'bytes', type: 'bytes' }, + { name: 'value', internalType: 'uint256', type: 'uint256' }, + ], + }, + ], indexed: false, }, ], - name: 'ERC20BridgeFinalized', + name: 'DripCreated', }, { type: 'event', anonymous: false, inputs: [ { - name: 'localToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'remoteToken', - internalType: 'address', - type: 'address', + name: 'nameref', + internalType: 'string', + type: 'string', indexed: true, }, { - name: 'from', - internalType: 'address', - type: 'address', - indexed: true, + name: 'name', + internalType: 'string', + type: 'string', + indexed: false, }, { - name: 'to', + name: 'executor', internalType: 'address', type: 'address', indexed: false, }, { - name: 'amount', + name: 'timestamp', internalType: 'uint256', type: 'uint256', indexed: false, }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, - }, ], - name: 'ERC20BridgeInitiated', + name: 'DripExecuted', }, { type: 'event', anonymous: false, inputs: [ { - name: 'l1Token', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'l2Token', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'from', - internalType: 'address', - type: 'address', + name: 'nameref', + internalType: 'string', + type: 'string', indexed: true, }, { - name: 'to', - internalType: 'address', - type: 'address', - indexed: false, - }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', + name: 'name', + internalType: 'string', + type: 'string', indexed: false, }, { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', + name: 'status', + internalType: 'enum Drippie.DripStatus', + type: 'uint8', indexed: false, }, ], - name: 'ERC20DepositInitiated', + name: 'DripStatusUpdated', }, { type: 'event', anonymous: false, inputs: [ { - name: 'l1Token', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'l2Token', + name: 'user', internalType: 'address', type: 'address', indexed: true, }, { - name: 'from', + name: 'newOwner', internalType: 'address', type: 'address', indexed: true, }, - { - name: 'to', - internalType: 'address', - type: 'address', - indexed: false, - }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, - }, ], - name: 'ERC20WithdrawalFinalized', + name: 'OwnerUpdated', }, { type: 'event', @@ -15146,1070 +10743,1269 @@ export const abis = { type: 'address', indexed: true, }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, { name: 'amount', internalType: 'uint256', type: 'uint256', indexed: false, }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, - }, ], - name: 'ETHBridgeFinalized', + name: 'ReceivedETH', }, { type: 'event', anonymous: false, inputs: [ { - name: 'from', + name: 'withdrawer', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'recipient', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'asset', internalType: 'address', type: 'address', indexed: true, }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, { name: 'amount', internalType: 'uint256', type: 'uint256', indexed: false, }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, - }, ], - name: 'ETHBridgeInitiated', + name: 'WithdrewERC20', }, { type: 'event', anonymous: false, inputs: [ { - name: 'from', + name: 'withdrawer', internalType: 'address', type: 'address', indexed: true, }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, + name: 'recipient', + internalType: 'address', + type: 'address', + indexed: true, }, { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', + name: 'asset', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'id', + internalType: 'uint256', + type: 'uint256', indexed: false, }, ], - name: 'ETHDepositInitiated', + name: 'WithdrewERC721', }, { type: 'event', anonymous: false, inputs: [ { - name: 'from', + name: 'withdrawer', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'recipient', internalType: 'address', type: 'address', indexed: true, }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, { name: 'amount', internalType: 'uint256', type: 'uint256', indexed: false, }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, - }, - ], - name: 'ETHWithdrawalFinalized', - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'MESSENGER', - outputs: [ - { - name: '', - internalType: 'contract CrossDomainMessenger', - type: 'address', - }, - ], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'OTHER_BRIDGE', - outputs: [ - { name: '', internalType: 'contract StandardBridge', type: 'address' }, ], + name: 'WithdrewETH', }, { - stateMutability: 'nonpayable', + stateMutability: 'payable', type: 'function', inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { name: '_target', internalType: 'address', type: 'address' }, + { name: '_data', internalType: 'bytes', type: 'bytes' }, + { name: '_value', internalType: 'uint256', type: 'uint256' }, ], - name: 'bridgeERC20', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + name: 'CALL', + outputs: [ + { name: '', internalType: 'bool', type: 'bool' }, + { name: '', internalType: 'bytes', type: 'bytes' }, ], - name: 'bridgeERC20To', - outputs: [], }, { stateMutability: 'payable', type: 'function', inputs: [ - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { name: '_target', internalType: 'address', type: 'address' }, + { name: '_data', internalType: 'bytes', type: 'bytes' }, + ], + name: 'DELEGATECALL', + outputs: [ + { name: '', internalType: 'bool', type: 'bool' }, + { name: '', internalType: 'bytes', type: 'bytes' }, ], - name: 'bridgeETH', - outputs: [], }, { - stateMutability: 'payable', + stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { name: '_name', internalType: 'string', type: 'string' }, + { + name: '_config', + internalType: 'struct Drippie.DripConfig', + type: 'tuple', + components: [ + { name: 'reentrant', internalType: 'bool', type: 'bool' }, + { name: 'interval', internalType: 'uint256', type: 'uint256' }, + { + name: 'dripcheck', + internalType: 'contract IDripCheck', + type: 'address', + }, + { name: 'checkparams', internalType: 'bytes', type: 'bytes' }, + { + name: 'actions', + internalType: 'struct Drippie.DripAction[]', + type: 'tuple[]', + components: [ + { + name: 'target', + internalType: 'address payable', + type: 'address', + }, + { name: 'data', internalType: 'bytes', type: 'bytes' }, + { name: 'value', internalType: 'uint256', type: 'uint256' }, + ], + }, + ], + }, ], - name: 'bridgeETHTo', + name: 'create', outputs: [], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [ - { name: '_l1Token', internalType: 'address', type: 'address' }, - { name: '_l2Token', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'depositERC20', + inputs: [{ name: '_name', internalType: 'string', type: 'string' }], + name: 'drip', outputs: [], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_l1Token', internalType: 'address', type: 'address' }, - { name: '_l2Token', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + inputs: [{ name: '', internalType: 'string', type: 'string' }], + name: 'drips', + outputs: [ + { + name: 'status', + internalType: 'enum Drippie.DripStatus', + type: 'uint8', + }, + { + name: 'config', + internalType: 'struct Drippie.DripConfig', + type: 'tuple', + components: [ + { name: 'reentrant', internalType: 'bool', type: 'bool' }, + { name: 'interval', internalType: 'uint256', type: 'uint256' }, + { + name: 'dripcheck', + internalType: 'contract IDripCheck', + type: 'address', + }, + { name: 'checkparams', internalType: 'bytes', type: 'bytes' }, + { + name: 'actions', + internalType: 'struct Drippie.DripAction[]', + type: 'tuple[]', + components: [ + { + name: 'target', + internalType: 'address payable', + type: 'address', + }, + { name: 'data', internalType: 'bytes', type: 'bytes' }, + { name: 'value', internalType: 'uint256', type: 'uint256' }, + ], + }, + ], + }, + { name: 'last', internalType: 'uint256', type: 'uint256' }, + { name: 'count', internalType: 'uint256', type: 'uint256' }, ], - name: 'depositERC20To', - outputs: [], }, { - stateMutability: 'payable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'depositETH', - outputs: [], + inputs: [{ name: '_name', internalType: 'string', type: 'string' }], + name: 'executable', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { - stateMutability: 'payable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'depositETHTo', + inputs: [], + name: 'owner', + outputs: [{ name: '', internalType: 'address', type: 'address' }], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], + name: 'setOwner', outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '', internalType: 'address', type: 'address' }, - { name: '', internalType: 'address', type: 'address' }, + { name: '_name', internalType: 'string', type: 'string' }, + { + name: '_status', + internalType: 'enum Drippie.DripStatus', + type: 'uint8', + }, ], - name: 'deposits', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'status', + outputs: [], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_from', internalType: 'address', type: 'address' }, + { name: '_asset', internalType: 'contract ERC20', type: 'address' }, { name: '_to', internalType: 'address', type: 'address' }, { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, ], - name: 'finalizeBridgeERC20', + name: 'withdrawERC20', outputs: [], }, { - stateMutability: 'payable', + stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_from', internalType: 'address', type: 'address' }, + { name: '_asset', internalType: 'contract ERC20', type: 'address' }, { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, ], - name: 'finalizeBridgeETH', + name: 'withdrawERC20', outputs: [], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_l1Token', internalType: 'address', type: 'address' }, - { name: '_l2Token', internalType: 'address', type: 'address' }, - { name: '_from', internalType: 'address', type: 'address' }, + { name: '_asset', internalType: 'contract ERC721', type: 'address' }, { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { name: '_id', internalType: 'uint256', type: 'uint256' }, ], - name: 'finalizeERC20Withdrawal', + name: 'withdrawERC721', outputs: [], }, { - stateMutability: 'payable', + stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_from', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, + { name: '_to', internalType: 'address payable', type: 'address' }, { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, ], - name: 'finalizeETHWithdrawal', + name: 'withdrawETH', outputs: [], }, { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'l2TokenBridge', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'messenger', - outputs: [ - { - name: '', - internalType: 'contract CrossDomainMessenger', - type: 'address', - }, + inputs: [ + { name: '_to', internalType: 'address payable', type: 'address' }, ], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + name: 'withdrawETH', + outputs: [], }, { stateMutability: 'payable', type: 'receive' }, ], - L1StandardBridge_goerli: [ - { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, + 'Drippie_optimism-goerli': [ + { + stateMutability: 'nonpayable', + type: 'constructor', + inputs: [{ name: '_owner', internalType: 'address', type: 'address' }], + }, { type: 'event', anonymous: false, inputs: [ { - name: 'localToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'remoteToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'from', - internalType: 'address', - type: 'address', + name: 'nameref', + internalType: 'string', + type: 'string', indexed: true, }, { - name: 'to', - internalType: 'address', - type: 'address', - indexed: false, - }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', + name: 'name', + internalType: 'string', + type: 'string', indexed: false, }, { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', + name: 'config', + internalType: 'struct Drippie.DripConfig', + type: 'tuple', + components: [ + { name: 'interval', internalType: 'uint256', type: 'uint256' }, + { + name: 'dripcheck', + internalType: 'contract IDripCheck', + type: 'address', + }, + { name: 'checkparams', internalType: 'bytes', type: 'bytes' }, + { + name: 'actions', + internalType: 'struct Drippie.DripAction[]', + type: 'tuple[]', + components: [ + { + name: 'target', + internalType: 'address payable', + type: 'address', + }, + { name: 'data', internalType: 'bytes', type: 'bytes' }, + { name: 'value', internalType: 'uint256', type: 'uint256' }, + ], + }, + ], indexed: false, }, ], - name: 'ERC20BridgeFinalized', + name: 'DripCreated', }, { type: 'event', anonymous: false, inputs: [ { - name: 'localToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'remoteToken', - internalType: 'address', - type: 'address', + name: 'nameref', + internalType: 'string', + type: 'string', indexed: true, }, { - name: 'from', - internalType: 'address', - type: 'address', - indexed: true, + name: 'name', + internalType: 'string', + type: 'string', + indexed: false, }, { - name: 'to', + name: 'executor', internalType: 'address', type: 'address', indexed: false, }, { - name: 'amount', + name: 'timestamp', internalType: 'uint256', type: 'uint256', indexed: false, }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, - }, ], - name: 'ERC20BridgeInitiated', + name: 'DripExecuted', }, { type: 'event', anonymous: false, inputs: [ { - name: 'l1Token', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'l2Token', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'from', - internalType: 'address', - type: 'address', + name: 'nameref', + internalType: 'string', + type: 'string', indexed: true, }, { - name: 'to', - internalType: 'address', - type: 'address', - indexed: false, - }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', + name: 'name', + internalType: 'string', + type: 'string', indexed: false, }, { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', + name: 'status', + internalType: 'enum Drippie.DripStatus', + type: 'uint8', indexed: false, }, ], - name: 'ERC20DepositInitiated', + name: 'DripStatusUpdated', }, { type: 'event', anonymous: false, inputs: [ { - name: 'l1Token', + name: 'user', internalType: 'address', type: 'address', indexed: true, }, { - name: 'l2Token', + name: 'newOwner', internalType: 'address', type: 'address', indexed: true, }, + ], + name: 'OwnerUpdated', + }, + { + type: 'event', + anonymous: false, + inputs: [ { name: 'from', internalType: 'address', type: 'address', indexed: true, }, - { - name: 'to', - internalType: 'address', - type: 'address', - indexed: false, - }, { name: 'amount', internalType: 'uint256', type: 'uint256', indexed: false, }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, - }, ], - name: 'ERC20WithdrawalFinalized', + name: 'ReceivedETH', }, { type: 'event', anonymous: false, inputs: [ { - name: 'from', + name: 'withdrawer', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'recipient', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'asset', internalType: 'address', type: 'address', indexed: true, }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, { name: 'amount', internalType: 'uint256', type: 'uint256', indexed: false, }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, - }, ], - name: 'ETHBridgeFinalized', + name: 'WithdrewERC20', }, { type: 'event', anonymous: false, inputs: [ { - name: 'from', + name: 'withdrawer', internalType: 'address', type: 'address', indexed: true, }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, + name: 'recipient', + internalType: 'address', + type: 'address', + indexed: true, }, - ], - name: 'ETHBridgeInitiated', - }, - { - type: 'event', - anonymous: false, - inputs: [ { - name: 'from', + name: 'asset', internalType: 'address', type: 'address', indexed: true, }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, { - name: 'amount', + name: 'id', internalType: 'uint256', type: 'uint256', indexed: false, }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, - }, ], - name: 'ETHDepositInitiated', + name: 'WithdrewERC721', }, { type: 'event', anonymous: false, inputs: [ { - name: 'from', + name: 'withdrawer', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'recipient', internalType: 'address', type: 'address', indexed: true, }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, { name: 'amount', internalType: 'uint256', type: 'uint256', indexed: false, }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, - }, ], - name: 'ETHWithdrawalFinalized', + name: 'WithdrewETH', }, { - type: 'event', - anonymous: false, + stateMutability: 'payable', + type: 'function', inputs: [ - { - name: 'version', - internalType: 'uint8', - type: 'uint8', - indexed: false, - }, + { name: '_target', internalType: 'address', type: 'address' }, + { name: '_data', internalType: 'bytes', type: 'bytes' }, + { name: '_gas', internalType: 'uint256', type: 'uint256' }, + { name: '_value', internalType: 'uint256', type: 'uint256' }, ], - name: 'Initialized', - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'MESSENGER', + name: 'CALL', outputs: [ - { - name: '', - internalType: 'contract CrossDomainMessenger', - type: 'address', - }, + { name: '', internalType: 'bool', type: 'bool' }, + { name: '', internalType: 'bytes', type: 'bytes' }, ], }, { - stateMutability: 'view', + stateMutability: 'payable', type: 'function', - inputs: [], - name: 'OTHER_BRIDGE', + inputs: [ + { name: '_target', internalType: 'address', type: 'address' }, + { name: '_data', internalType: 'bytes', type: 'bytes' }, + { name: '_gas', internalType: 'uint256', type: 'uint256' }, + ], + name: 'DELEGATECALL', outputs: [ - { name: '', internalType: 'contract StandardBridge', type: 'address' }, + { name: '', internalType: 'bool', type: 'bool' }, + { name: '', internalType: 'bytes', type: 'bytes' }, ], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { name: '_name', internalType: 'string', type: 'string' }, + { + name: '_config', + internalType: 'struct Drippie.DripConfig', + type: 'tuple', + components: [ + { name: 'interval', internalType: 'uint256', type: 'uint256' }, + { + name: 'dripcheck', + internalType: 'contract IDripCheck', + type: 'address', + }, + { name: 'checkparams', internalType: 'bytes', type: 'bytes' }, + { + name: 'actions', + internalType: 'struct Drippie.DripAction[]', + type: 'tuple[]', + components: [ + { + name: 'target', + internalType: 'address payable', + type: 'address', + }, + { name: 'data', internalType: 'bytes', type: 'bytes' }, + { name: 'value', internalType: 'uint256', type: 'uint256' }, + ], + }, + ], + }, ], - name: 'bridgeERC20', + name: 'create', outputs: [], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'bridgeERC20To', + inputs: [{ name: '_name', internalType: 'string', type: 'string' }], + name: 'drip', outputs: [], }, { - stateMutability: 'payable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + inputs: [{ name: '', internalType: 'string', type: 'string' }], + name: 'drips', + outputs: [ + { + name: 'status', + internalType: 'enum Drippie.DripStatus', + type: 'uint8', + }, + { + name: 'config', + internalType: 'struct Drippie.DripConfig', + type: 'tuple', + components: [ + { name: 'interval', internalType: 'uint256', type: 'uint256' }, + { + name: 'dripcheck', + internalType: 'contract IDripCheck', + type: 'address', + }, + { name: 'checkparams', internalType: 'bytes', type: 'bytes' }, + { + name: 'actions', + internalType: 'struct Drippie.DripAction[]', + type: 'tuple[]', + components: [ + { + name: 'target', + internalType: 'address payable', + type: 'address', + }, + { name: 'data', internalType: 'bytes', type: 'bytes' }, + { name: 'value', internalType: 'uint256', type: 'uint256' }, + ], + }, + ], + }, + { name: 'last', internalType: 'uint256', type: 'uint256' }, + { name: 'count', internalType: 'uint256', type: 'uint256' }, ], - name: 'bridgeETH', - outputs: [], }, { - stateMutability: 'payable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'bridgeETHTo', - outputs: [], + inputs: [{ name: '_name', internalType: 'string', type: 'string' }], + name: 'executable', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_l1Token', internalType: 'address', type: 'address' }, - { name: '_l2Token', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'depositERC20', - outputs: [], + inputs: [], + name: 'owner', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [ - { name: '_l1Token', internalType: 'address', type: 'address' }, - { name: '_l2Token', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'depositERC20To', - outputs: [], - }, - { - stateMutability: 'payable', - type: 'function', - inputs: [ - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'depositETH', - outputs: [], - }, - { - stateMutability: 'payable', - type: 'function', - inputs: [ - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'depositETHTo', + inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], + name: 'setOwner', outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '', internalType: 'address', type: 'address' }, - { name: '', internalType: 'address', type: 'address' }, + { name: '_name', internalType: 'string', type: 'string' }, + { + name: '_status', + internalType: 'enum Drippie.DripStatus', + type: 'uint8', + }, ], - name: 'deposits', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'status', + outputs: [], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_from', internalType: 'address', type: 'address' }, + { name: '_asset', internalType: 'contract ERC20', type: 'address' }, { name: '_to', internalType: 'address', type: 'address' }, { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, ], - name: 'finalizeBridgeERC20', + name: 'withdrawERC20', outputs: [], }, { - stateMutability: 'payable', + stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_from', internalType: 'address', type: 'address' }, + { name: '_asset', internalType: 'contract ERC20', type: 'address' }, { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, ], - name: 'finalizeBridgeETH', + name: 'withdrawERC20', outputs: [], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_l1Token', internalType: 'address', type: 'address' }, - { name: '_l2Token', internalType: 'address', type: 'address' }, - { name: '_from', internalType: 'address', type: 'address' }, + { name: '_asset', internalType: 'contract ERC721', type: 'address' }, { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { name: '_id', internalType: 'uint256', type: 'uint256' }, ], - name: 'finalizeERC20Withdrawal', + name: 'withdrawERC721', outputs: [], }, { - stateMutability: 'payable', + stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_from', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, + { name: '_to', internalType: 'address payable', type: 'address' }, { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, ], - name: 'finalizeETHWithdrawal', + name: 'withdrawETH', outputs: [], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { - name: '_messenger', - internalType: 'contract CrossDomainMessenger', - type: 'address', - }, + { name: '_to', internalType: 'address payable', type: 'address' }, ], - name: 'initialize', + name: 'withdrawETH', outputs: [], }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'l2TokenBridge', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'messenger', - outputs: [ - { - name: '', - internalType: 'contract CrossDomainMessenger', - type: 'address', - }, - ], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'otherBridge', - outputs: [ - { name: '', internalType: 'contract StandardBridge', type: 'address' }, - ], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], - }, { stateMutability: 'payable', type: 'receive' }, ], - L2CrossDomainMessenger: [ + EAS: [ + { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, + { type: 'error', inputs: [], name: 'AccessDenied' }, + { type: 'error', inputs: [], name: 'AlreadyRevoked' }, + { type: 'error', inputs: [], name: 'AlreadyRevokedOffchain' }, + { type: 'error', inputs: [], name: 'AlreadyTimestamped' }, + { type: 'error', inputs: [], name: 'InsufficientValue' }, + { type: 'error', inputs: [], name: 'InvalidAttestation' }, + { type: 'error', inputs: [], name: 'InvalidAttestations' }, + { type: 'error', inputs: [], name: 'InvalidExpirationTime' }, + { type: 'error', inputs: [], name: 'InvalidLength' }, + { type: 'error', inputs: [], name: 'InvalidOffset' }, + { type: 'error', inputs: [], name: 'InvalidRegistry' }, + { type: 'error', inputs: [], name: 'InvalidRevocation' }, + { type: 'error', inputs: [], name: 'InvalidRevocations' }, + { type: 'error', inputs: [], name: 'InvalidSchema' }, + { type: 'error', inputs: [], name: 'InvalidSignature' }, + { type: 'error', inputs: [], name: 'InvalidVerifier' }, + { type: 'error', inputs: [], name: 'Irrevocable' }, + { type: 'error', inputs: [], name: 'NotFound' }, + { type: 'error', inputs: [], name: 'NotPayable' }, + { type: 'error', inputs: [], name: 'WrongSchema' }, { - stateMutability: 'nonpayable', - type: 'constructor', + type: 'event', + anonymous: false, inputs: [ { - name: '_l1CrossDomainMessenger', + name: 'recipient', internalType: 'address', type: 'address', + indexed: true, }, - ], - }, - { - type: 'event', - anonymous: false, - inputs: [ { - name: 'msgHash', + name: 'attester', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'uid', + internalType: 'bytes32', + type: 'bytes32', + indexed: false, + }, + { + name: 'schema', internalType: 'bytes32', type: 'bytes32', indexed: true, }, ], - name: 'FailedRelayedMessage', + name: 'Attested', }, { type: 'event', anonymous: false, inputs: [ { - name: 'version', - internalType: 'uint8', - type: 'uint8', + name: 'recipient', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'attester', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'uid', + internalType: 'bytes32', + type: 'bytes32', indexed: false, }, + { + name: 'schema', + internalType: 'bytes32', + type: 'bytes32', + indexed: true, + }, ], - name: 'Initialized', + name: 'Revoked', }, { type: 'event', anonymous: false, inputs: [ { - name: 'msgHash', + name: 'revoker', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'data', internalType: 'bytes32', type: 'bytes32', indexed: true, }, + { + name: 'timestamp', + internalType: 'uint64', + type: 'uint64', + indexed: true, + }, ], - name: 'RelayedMessage', + name: 'RevokedOffchain', }, { type: 'event', anonymous: false, inputs: [ { - name: 'target', - internalType: 'address', - type: 'address', + name: 'data', + internalType: 'bytes32', + type: 'bytes32', indexed: true, }, { - name: 'sender', - internalType: 'address', - type: 'address', - indexed: false, - }, - { - name: 'message', - internalType: 'bytes', - type: 'bytes', - indexed: false, + name: 'timestamp', + internalType: 'uint64', + type: 'uint64', + indexed: true, }, + ], + name: 'Timestamped', + }, + { + stateMutability: 'payable', + type: 'function', + inputs: [ { - name: 'messageNonce', - internalType: 'uint256', - type: 'uint256', - indexed: false, + name: 'request', + internalType: 'struct AttestationRequest', + type: 'tuple', + components: [ + { name: 'schema', internalType: 'bytes32', type: 'bytes32' }, + { + name: 'data', + internalType: 'struct AttestationRequestData', + type: 'tuple', + components: [ + { name: 'recipient', internalType: 'address', type: 'address' }, + { + name: 'expirationTime', + internalType: 'uint64', + type: 'uint64', + }, + { name: 'revocable', internalType: 'bool', type: 'bool' }, + { name: 'refUID', internalType: 'bytes32', type: 'bytes32' }, + { name: 'data', internalType: 'bytes', type: 'bytes' }, + { name: 'value', internalType: 'uint256', type: 'uint256' }, + ], + }, + ], }, + ], + name: 'attest', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + }, + { + stateMutability: 'payable', + type: 'function', + inputs: [ { - name: 'gasLimit', - internalType: 'uint256', - type: 'uint256', - indexed: false, + name: 'delegatedRequest', + internalType: 'struct DelegatedAttestationRequest', + type: 'tuple', + components: [ + { name: 'schema', internalType: 'bytes32', type: 'bytes32' }, + { + name: 'data', + internalType: 'struct AttestationRequestData', + type: 'tuple', + components: [ + { name: 'recipient', internalType: 'address', type: 'address' }, + { + name: 'expirationTime', + internalType: 'uint64', + type: 'uint64', + }, + { name: 'revocable', internalType: 'bool', type: 'bool' }, + { name: 'refUID', internalType: 'bytes32', type: 'bytes32' }, + { name: 'data', internalType: 'bytes', type: 'bytes' }, + { name: 'value', internalType: 'uint256', type: 'uint256' }, + ], + }, + { + name: 'signature', + internalType: 'struct EIP712Signature', + type: 'tuple', + components: [ + { name: 'v', internalType: 'uint8', type: 'uint8' }, + { name: 'r', internalType: 'bytes32', type: 'bytes32' }, + { name: 's', internalType: 'bytes32', type: 'bytes32' }, + ], + }, + { name: 'attester', internalType: 'address', type: 'address' }, + ], }, ], - name: 'SentMessage', + name: 'attestByDelegation', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'sender', - internalType: 'address', - type: 'address', - indexed: true, - }, + stateMutability: 'pure', + type: 'function', + inputs: [], + name: 'getAttestTypeHash', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [{ name: 'uid', internalType: 'bytes32', type: 'bytes32' }], + name: 'getAttestation', + outputs: [ { - name: 'value', - internalType: 'uint256', - type: 'uint256', - indexed: false, + name: '', + internalType: 'struct Attestation', + type: 'tuple', + components: [ + { name: 'uid', internalType: 'bytes32', type: 'bytes32' }, + { name: 'schema', internalType: 'bytes32', type: 'bytes32' }, + { name: 'time', internalType: 'uint64', type: 'uint64' }, + { name: 'expirationTime', internalType: 'uint64', type: 'uint64' }, + { name: 'revocationTime', internalType: 'uint64', type: 'uint64' }, + { name: 'refUID', internalType: 'bytes32', type: 'bytes32' }, + { name: 'recipient', internalType: 'address', type: 'address' }, + { name: 'attester', internalType: 'address', type: 'address' }, + { name: 'revocable', internalType: 'bool', type: 'bool' }, + { name: 'data', internalType: 'bytes', type: 'bytes' }, + ], }, ], - name: 'SentMessageExtension1', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'MESSAGE_VERSION', - outputs: [{ name: '', internalType: 'uint16', type: 'uint16' }], + name: 'getDomainSeparator', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'MIN_GAS_CALLDATA_OVERHEAD', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + name: 'getName', + outputs: [{ name: '', internalType: 'string', type: 'string' }], }, { stateMutability: 'view', type: 'function', - inputs: [], - name: 'MIN_GAS_DYNAMIC_OVERHEAD_DENOMINATOR', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + inputs: [{ name: 'account', internalType: 'address', type: 'address' }], + name: 'getNonce', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', - inputs: [], - name: 'MIN_GAS_DYNAMIC_OVERHEAD_NUMERATOR', + inputs: [ + { name: 'revoker', internalType: 'address', type: 'address' }, + { name: 'data', internalType: 'bytes32', type: 'bytes32' }, + ], + name: 'getRevokeOffchain', outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], }, { - stateMutability: 'view', + stateMutability: 'pure', type: 'function', inputs: [], - name: 'OTHER_MESSENGER', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'getRevokeTypeHash', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { - stateMutability: 'view', + stateMutability: 'pure', type: 'function', inputs: [], - name: 'RELAY_CALL_OVERHEAD', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + name: 'getSchemaRegistry', + outputs: [ + { name: '', internalType: 'contract ISchemaRegistry', type: 'address' }, + ], }, { stateMutability: 'view', type: 'function', - inputs: [], - name: 'RELAY_CONSTANT_OVERHEAD', + inputs: [{ name: 'data', internalType: 'bytes32', type: 'bytes32' }], + name: 'getTimestamp', outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], }, { - stateMutability: 'view', + stateMutability: 'view', + type: 'function', + inputs: [{ name: 'uid', internalType: 'bytes32', type: 'bytes32' }], + name: 'isAttestationValid', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + }, + { + stateMutability: 'payable', + type: 'function', + inputs: [ + { + name: 'multiRequests', + internalType: 'struct MultiAttestationRequest[]', + type: 'tuple[]', + components: [ + { name: 'schema', internalType: 'bytes32', type: 'bytes32' }, + { + name: 'data', + internalType: 'struct AttestationRequestData[]', + type: 'tuple[]', + components: [ + { name: 'recipient', internalType: 'address', type: 'address' }, + { + name: 'expirationTime', + internalType: 'uint64', + type: 'uint64', + }, + { name: 'revocable', internalType: 'bool', type: 'bool' }, + { name: 'refUID', internalType: 'bytes32', type: 'bytes32' }, + { name: 'data', internalType: 'bytes', type: 'bytes' }, + { name: 'value', internalType: 'uint256', type: 'uint256' }, + ], + }, + ], + }, + ], + name: 'multiAttest', + outputs: [{ name: '', internalType: 'bytes32[]', type: 'bytes32[]' }], + }, + { + stateMutability: 'payable', + type: 'function', + inputs: [ + { + name: 'multiDelegatedRequests', + internalType: 'struct MultiDelegatedAttestationRequest[]', + type: 'tuple[]', + components: [ + { name: 'schema', internalType: 'bytes32', type: 'bytes32' }, + { + name: 'data', + internalType: 'struct AttestationRequestData[]', + type: 'tuple[]', + components: [ + { name: 'recipient', internalType: 'address', type: 'address' }, + { + name: 'expirationTime', + internalType: 'uint64', + type: 'uint64', + }, + { name: 'revocable', internalType: 'bool', type: 'bool' }, + { name: 'refUID', internalType: 'bytes32', type: 'bytes32' }, + { name: 'data', internalType: 'bytes', type: 'bytes' }, + { name: 'value', internalType: 'uint256', type: 'uint256' }, + ], + }, + { + name: 'signatures', + internalType: 'struct EIP712Signature[]', + type: 'tuple[]', + components: [ + { name: 'v', internalType: 'uint8', type: 'uint8' }, + { name: 'r', internalType: 'bytes32', type: 'bytes32' }, + { name: 's', internalType: 'bytes32', type: 'bytes32' }, + ], + }, + { name: 'attester', internalType: 'address', type: 'address' }, + ], + }, + ], + name: 'multiAttestByDelegation', + outputs: [{ name: '', internalType: 'bytes32[]', type: 'bytes32[]' }], + }, + { + stateMutability: 'payable', + type: 'function', + inputs: [ + { + name: 'multiRequests', + internalType: 'struct MultiRevocationRequest[]', + type: 'tuple[]', + components: [ + { name: 'schema', internalType: 'bytes32', type: 'bytes32' }, + { + name: 'data', + internalType: 'struct RevocationRequestData[]', + type: 'tuple[]', + components: [ + { name: 'uid', internalType: 'bytes32', type: 'bytes32' }, + { name: 'value', internalType: 'uint256', type: 'uint256' }, + ], + }, + ], + }, + ], + name: 'multiRevoke', + outputs: [], + }, + { + stateMutability: 'payable', + type: 'function', + inputs: [ + { + name: 'multiDelegatedRequests', + internalType: 'struct MultiDelegatedRevocationRequest[]', + type: 'tuple[]', + components: [ + { name: 'schema', internalType: 'bytes32', type: 'bytes32' }, + { + name: 'data', + internalType: 'struct RevocationRequestData[]', + type: 'tuple[]', + components: [ + { name: 'uid', internalType: 'bytes32', type: 'bytes32' }, + { name: 'value', internalType: 'uint256', type: 'uint256' }, + ], + }, + { + name: 'signatures', + internalType: 'struct EIP712Signature[]', + type: 'tuple[]', + components: [ + { name: 'v', internalType: 'uint8', type: 'uint8' }, + { name: 'r', internalType: 'bytes32', type: 'bytes32' }, + { name: 's', internalType: 'bytes32', type: 'bytes32' }, + ], + }, + { name: 'revoker', internalType: 'address', type: 'address' }, + ], + }, + ], + name: 'multiRevokeByDelegation', + outputs: [], + }, + { + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'RELAY_GAS_CHECK_BUFFER', + inputs: [{ name: 'data', internalType: 'bytes32[]', type: 'bytes32[]' }], + name: 'multiRevokeOffchain', outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'RELAY_RESERVED_GAS', + inputs: [{ name: 'data', internalType: 'bytes32[]', type: 'bytes32[]' }], + name: 'multiTimestamp', outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], }, { - stateMutability: 'pure', + stateMutability: 'payable', type: 'function', inputs: [ - { name: '_message', internalType: 'bytes', type: 'bytes' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { + name: 'request', + internalType: 'struct RevocationRequest', + type: 'tuple', + components: [ + { name: 'schema', internalType: 'bytes32', type: 'bytes32' }, + { + name: 'data', + internalType: 'struct RevocationRequestData', + type: 'tuple', + components: [ + { name: 'uid', internalType: 'bytes32', type: 'bytes32' }, + { name: 'value', internalType: 'uint256', type: 'uint256' }, + ], + }, + ], + }, ], - name: 'baseGas', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - name: 'failedMessages', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'initialize', + name: 'revoke', outputs: [], }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'l1CrossDomainMessenger', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'messageNonce', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, { stateMutability: 'payable', type: 'function', inputs: [ - { name: '_nonce', internalType: 'uint256', type: 'uint256' }, - { name: '_sender', internalType: 'address', type: 'address' }, - { name: '_target', internalType: 'address', type: 'address' }, - { name: '_value', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint256', type: 'uint256' }, - { name: '_message', internalType: 'bytes', type: 'bytes' }, + { + name: 'delegatedRequest', + internalType: 'struct DelegatedRevocationRequest', + type: 'tuple', + components: [ + { name: 'schema', internalType: 'bytes32', type: 'bytes32' }, + { + name: 'data', + internalType: 'struct RevocationRequestData', + type: 'tuple', + components: [ + { name: 'uid', internalType: 'bytes32', type: 'bytes32' }, + { name: 'value', internalType: 'uint256', type: 'uint256' }, + ], + }, + { + name: 'signature', + internalType: 'struct EIP712Signature', + type: 'tuple', + components: [ + { name: 'v', internalType: 'uint8', type: 'uint8' }, + { name: 'r', internalType: 'bytes32', type: 'bytes32' }, + { name: 's', internalType: 'bytes32', type: 'bytes32' }, + ], + }, + { name: 'revoker', internalType: 'address', type: 'address' }, + ], + }, ], - name: 'relayMessage', + name: 'revokeByDelegation', outputs: [], }, { - stateMutability: 'payable', + stateMutability: 'nonpayable', type: 'function', - inputs: [ - { name: '_target', internalType: 'address', type: 'address' }, - { name: '_message', internalType: 'bytes', type: 'bytes' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - ], - name: 'sendMessage', - outputs: [], + inputs: [{ name: 'data', internalType: 'bytes32', type: 'bytes32' }], + name: 'revokeOffchain', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - name: 'successfulMessages', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + inputs: [{ name: 'data', internalType: 'bytes32', type: 'bytes32' }], + name: 'timestamp', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], }, { stateMutability: 'view', @@ -16218,169 +12014,71 @@ export const abis = { name: 'version', outputs: [{ name: '', internalType: 'string', type: 'string' }], }, + ], + GasPriceOracle: [ + { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'xDomainMessageSender', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - ], - L2ERC721Bridge: [ - { - stateMutability: 'nonpayable', - type: 'constructor', - inputs: [ - { name: '_messenger', internalType: 'address', type: 'address' }, - { name: '_otherBridge', internalType: 'address', type: 'address' }, - ], + name: 'DECIMALS', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'localToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'remoteToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'from', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'to', - internalType: 'address', - type: 'address', - indexed: false, - }, - { - name: 'tokenId', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, - }, - ], - name: 'ERC721BridgeFinalized', + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'baseFee', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'localToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'remoteToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'from', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'to', - internalType: 'address', - type: 'address', - indexed: false, - }, - { - name: 'tokenId', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, - }, - ], - name: 'ERC721BridgeInitiated', + stateMutability: 'pure', + type: 'function', + inputs: [], + name: 'decimals', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'bridgeERC721', - outputs: [], + inputs: [], + name: 'gasPrice', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'bridgeERC721To', - outputs: [], + inputs: [{ name: '_data', internalType: 'bytes', type: 'bytes' }], + name: 'getL1Fee', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_from', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'finalizeBridgeERC721', - outputs: [], + inputs: [{ name: '_data', internalType: 'bytes', type: 'bytes' }], + name: 'getL1GasUsed', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'messenger', - outputs: [ - { - name: '', - internalType: 'contract CrossDomainMessenger', - type: 'address', - }, - ], + name: 'l1BaseFee', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'otherBridge', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'overhead', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'scalar', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', @@ -16390,181 +12088,86 @@ export const abis = { outputs: [{ name: '', internalType: 'string', type: 'string' }], }, ], - 'L2ERC721Bridge_optimism-goerli': [ - { - stateMutability: 'nonpayable', - type: 'constructor', - inputs: [ - { name: '_messenger', internalType: 'address', type: 'address' }, - { name: '_otherBridge', internalType: 'address', type: 'address' }, - ], - }, + L1Block: [ + { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'localToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'remoteToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'from', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'to', - internalType: 'address', - type: 'address', - indexed: false, - }, - { - name: 'tokenId', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, - }, - ], - name: 'ERC721BridgeFinalized', + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'DEPOSITOR_ACCOUNT', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'localToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'remoteToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'from', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'to', - internalType: 'address', - type: 'address', - indexed: false, - }, - { - name: 'tokenId', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, - }, - ], - name: 'ERC721BridgeInitiated', + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'basefee', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'MESSENGER', - outputs: [ - { - name: '', - internalType: 'contract CrossDomainMessenger', - type: 'address', - }, - ], + name: 'batcherHash', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'OTHER_BRIDGE', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'hash', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'bridgeERC721', - outputs: [], + inputs: [], + name: 'l1FeeOverhead', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'bridgeERC721To', - outputs: [], + inputs: [], + name: 'l1FeeScalar', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_from', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'finalizeBridgeERC721', - outputs: [], + inputs: [], + name: 'number', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'messenger', - outputs: [ - { - name: '', - internalType: 'contract CrossDomainMessenger', - type: 'address', - }, + name: 'sequenceNumber', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { name: '_number', internalType: 'uint64', type: 'uint64' }, + { name: '_timestamp', internalType: 'uint64', type: 'uint64' }, + { name: '_basefee', internalType: 'uint256', type: 'uint256' }, + { name: '_hash', internalType: 'bytes32', type: 'bytes32' }, + { name: '_sequenceNumber', internalType: 'uint64', type: 'uint64' }, + { name: '_batcherHash', internalType: 'bytes32', type: 'bytes32' }, + { name: '_l1FeeOverhead', internalType: 'uint256', type: 'uint256' }, + { name: '_l1FeeScalar', internalType: 'uint256', type: 'uint256' }, ], + name: 'setL1BlockValues', + outputs: [], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'otherBridge', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'timestamp', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], }, { stateMutability: 'view', @@ -16574,35 +12177,20 @@ export const abis = { outputs: [{ name: '', internalType: 'string', type: 'string' }], }, ], - L2OutputOracle: [ + L1CrossDomainMessenger: [ + { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, { - stateMutability: 'nonpayable', - type: 'constructor', + type: 'event', + anonymous: false, inputs: [ { - name: '_submissionInterval', - internalType: 'uint256', - type: 'uint256', - }, - { name: '_l2BlockTime', internalType: 'uint256', type: 'uint256' }, - { - name: '_startingBlockNumber', - internalType: 'uint256', - type: 'uint256', - }, - { - name: '_startingTimestamp', - internalType: 'uint256', - type: 'uint256', - }, - { name: '_proposer', internalType: 'address', type: 'address' }, - { name: '_challenger', internalType: 'address', type: 'address' }, - { - name: '_finalizationPeriodSeconds', - internalType: 'uint256', - type: 'uint256', + name: 'msgHash', + internalType: 'bytes32', + type: 'bytes32', + indexed: true, }, ], + name: 'FailedRelayedMessage', }, { type: 'event', @@ -16622,166 +12210,167 @@ export const abis = { anonymous: false, inputs: [ { - name: 'outputRoot', + name: 'msgHash', internalType: 'bytes32', type: 'bytes32', indexed: true, }, + ], + name: 'RelayedMessage', + }, + { + type: 'event', + anonymous: false, + inputs: [ { - name: 'l2OutputIndex', - internalType: 'uint256', - type: 'uint256', + name: 'target', + internalType: 'address', + type: 'address', indexed: true, }, { - name: 'l2BlockNumber', + name: 'sender', + internalType: 'address', + type: 'address', + indexed: false, + }, + { + name: 'message', + internalType: 'bytes', + type: 'bytes', + indexed: false, + }, + { + name: 'messageNonce', internalType: 'uint256', type: 'uint256', - indexed: true, + indexed: false, }, { - name: 'l1Timestamp', + name: 'gasLimit', internalType: 'uint256', type: 'uint256', indexed: false, }, ], - name: 'OutputProposed', + name: 'SentMessage', }, { type: 'event', anonymous: false, inputs: [ { - name: 'prevNextOutputIndex', - internalType: 'uint256', - type: 'uint256', + name: 'sender', + internalType: 'address', + type: 'address', indexed: true, }, { - name: 'newNextOutputIndex', + name: 'value', internalType: 'uint256', type: 'uint256', - indexed: true, + indexed: false, }, ], - name: 'OutputsDeleted', + name: 'SentMessageExtension1', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'CHALLENGER', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'MESSAGE_VERSION', + outputs: [{ name: '', internalType: 'uint16', type: 'uint16' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'FINALIZATION_PERIOD_SECONDS', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'MIN_GAS_CALLDATA_OVERHEAD', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'L2_BLOCK_TIME', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'MIN_GAS_DYNAMIC_OVERHEAD_DENOMINATOR', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'PROPOSER', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'MIN_GAS_DYNAMIC_OVERHEAD_NUMERATOR', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'SUBMISSION_INTERVAL', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'OTHER_MESSENGER', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', - inputs: [ - { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, + inputs: [], + name: 'PORTAL', + outputs: [ + { name: '', internalType: 'contract OptimismPortal', type: 'address' }, ], - name: 'computeL2Timestamp', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, - ], - name: 'deleteL2Outputs', - outputs: [], + inputs: [], + name: 'RELAY_CALL_OVERHEAD', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], }, { stateMutability: 'view', type: 'function', - inputs: [ - { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, - ], - name: 'getL2Output', - outputs: [ - { - name: '', - internalType: 'struct Types.OutputProposal', - type: 'tuple', - components: [ - { name: 'outputRoot', internalType: 'bytes32', type: 'bytes32' }, - { name: 'timestamp', internalType: 'uint128', type: 'uint128' }, - { name: 'l2BlockNumber', internalType: 'uint128', type: 'uint128' }, - ], - }, - ], + inputs: [], + name: 'RELAY_CONSTANT_OVERHEAD', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], }, { stateMutability: 'view', type: 'function', - inputs: [ - { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, - ], - name: 'getL2OutputAfter', - outputs: [ - { - name: '', - internalType: 'struct Types.OutputProposal', - type: 'tuple', - components: [ - { name: 'outputRoot', internalType: 'bytes32', type: 'bytes32' }, - { name: 'timestamp', internalType: 'uint128', type: 'uint128' }, - { name: 'l2BlockNumber', internalType: 'uint128', type: 'uint128' }, - ], - }, - ], + inputs: [], + name: 'RELAY_GAS_CHECK_BUFFER', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], }, { stateMutability: 'view', type: 'function', + inputs: [], + name: 'RELAY_RESERVED_GAS', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + }, + { + stateMutability: 'pure', + type: 'function', inputs: [ - { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, + { name: '_message', internalType: 'bytes', type: 'bytes' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, ], - name: 'getL2OutputIndexAfter', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'baseGas', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'failedMessages', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ { - name: '_startingBlockNumber', - internalType: 'uint256', - type: 'uint256', - }, - { - name: '_startingTimestamp', - internalType: 'uint256', - type: 'uint256', + name: '_portal', + internalType: 'contract OptimismPortal', + type: 'address', }, ], name: 'initialize', @@ -16791,277 +12380,245 @@ export const abis = { stateMutability: 'view', type: 'function', inputs: [], - name: 'latestBlockNumber', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'latestOutputIndex', + name: 'messageNonce', outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'nextBlockNumber', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'portal', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'view', + stateMutability: 'payable', type: 'function', - inputs: [], - name: 'nextOutputIndex', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + inputs: [ + { name: '_nonce', internalType: 'uint256', type: 'uint256' }, + { name: '_sender', internalType: 'address', type: 'address' }, + { name: '_target', internalType: 'address', type: 'address' }, + { name: '_value', internalType: 'uint256', type: 'uint256' }, + { name: '_minGasLimit', internalType: 'uint256', type: 'uint256' }, + { name: '_message', internalType: 'bytes', type: 'bytes' }, + ], + name: 'relayMessage', + outputs: [], }, { stateMutability: 'payable', type: 'function', inputs: [ - { name: '_outputRoot', internalType: 'bytes32', type: 'bytes32' }, - { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, - { name: '_l1BlockHash', internalType: 'bytes32', type: 'bytes32' }, - { name: '_l1BlockNumber', internalType: 'uint256', type: 'uint256' }, + { name: '_target', internalType: 'address', type: 'address' }, + { name: '_message', internalType: 'bytes', type: 'bytes' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, ], - name: 'proposeL2Output', + name: 'sendMessage', outputs: [], }, { stateMutability: 'view', type: 'function', - inputs: [], - name: 'startingBlockNumber', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'successfulMessages', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'startingTimestamp', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'version', + outputs: [{ name: '', internalType: 'string', type: 'string' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + name: 'xDomainMessageSender', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, ], - L2OutputOracle_goerli: [ + L1ERC721Bridge: [ + { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, { - stateMutability: 'nonpayable', - type: 'constructor', + type: 'event', + anonymous: false, inputs: [ { - name: '_submissionInterval', - internalType: 'uint256', - type: 'uint256', + name: 'localToken', + internalType: 'address', + type: 'address', + indexed: true, }, - { name: '_l2BlockTime', internalType: 'uint256', type: 'uint256' }, { - name: '_finalizationPeriodSeconds', - internalType: 'uint256', - type: 'uint256', + name: 'remoteToken', + internalType: 'address', + type: 'address', + indexed: true, }, - ], - }, - { - type: 'event', - anonymous: false, - inputs: [ { - name: 'version', - internalType: 'uint8', - type: 'uint8', + name: 'from', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'to', + internalType: 'address', + type: 'address', + indexed: false, + }, + { + name: 'tokenId', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + { + name: 'extraData', + internalType: 'bytes', + type: 'bytes', indexed: false, }, ], - name: 'Initialized', + name: 'ERC721BridgeFinalized', }, { type: 'event', anonymous: false, inputs: [ { - name: 'outputRoot', - internalType: 'bytes32', - type: 'bytes32', + name: 'localToken', + internalType: 'address', + type: 'address', indexed: true, }, { - name: 'l2OutputIndex', - internalType: 'uint256', - type: 'uint256', + name: 'remoteToken', + internalType: 'address', + type: 'address', indexed: true, }, { - name: 'l2BlockNumber', - internalType: 'uint256', - type: 'uint256', + name: 'from', + internalType: 'address', + type: 'address', indexed: true, }, { - name: 'l1Timestamp', + name: 'to', + internalType: 'address', + type: 'address', + indexed: false, + }, + { + name: 'tokenId', internalType: 'uint256', type: 'uint256', indexed: false, }, + { + name: 'extraData', + internalType: 'bytes', + type: 'bytes', + indexed: false, + }, ], - name: 'OutputProposed', + name: 'ERC721BridgeInitiated', }, { type: 'event', anonymous: false, inputs: [ { - name: 'prevNextOutputIndex', - internalType: 'uint256', - type: 'uint256', - indexed: true, - }, - { - name: 'newNextOutputIndex', - internalType: 'uint256', - type: 'uint256', - indexed: true, + name: 'version', + internalType: 'uint8', + type: 'uint8', + indexed: false, }, ], - name: 'OutputsDeleted', - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'CHALLENGER', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'FINALIZATION_PERIOD_SECONDS', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'L2_BLOCK_TIME', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'PROPOSER', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'Initialized', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'SUBMISSION_INTERVAL', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'MESSENGER', + outputs: [ + { + name: '', + internalType: 'contract CrossDomainMessenger', + type: 'address', + }, + ], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'challenger', + name: 'OTHER_BRIDGE', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, - { - stateMutability: 'view', - type: 'function', - inputs: [ - { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, - ], - name: 'computeL2Timestamp', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, + { name: '_localToken', internalType: 'address', type: 'address' }, + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, ], - name: 'deleteL2Outputs', + name: 'bridgeERC721', outputs: [], }, { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'finalizationPeriodSeconds', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, - ], - name: 'getL2Output', - outputs: [ - { - name: '', - internalType: 'struct Types.OutputProposal', - type: 'tuple', - components: [ - { name: 'outputRoot', internalType: 'bytes32', type: 'bytes32' }, - { name: 'timestamp', internalType: 'uint128', type: 'uint128' }, - { name: 'l2BlockNumber', internalType: 'uint128', type: 'uint128' }, - ], - }, + { name: '_localToken', internalType: 'address', type: 'address' }, + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, ], + name: 'bridgeERC721To', + outputs: [], }, { stateMutability: 'view', type: 'function', inputs: [ - { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, - ], - name: 'getL2OutputAfter', - outputs: [ - { - name: '', - internalType: 'struct Types.OutputProposal', - type: 'tuple', - components: [ - { name: 'outputRoot', internalType: 'bytes32', type: 'bytes32' }, - { name: 'timestamp', internalType: 'uint128', type: 'uint128' }, - { name: 'l2BlockNumber', internalType: 'uint128', type: 'uint128' }, - ], - }, + { name: '', internalType: 'address', type: 'address' }, + { name: '', internalType: 'address', type: 'address' }, + { name: '', internalType: 'uint256', type: 'uint256' }, ], + name: 'deposits', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, + { name: '_localToken', internalType: 'address', type: 'address' }, + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_from', internalType: 'address', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, ], - name: 'getL2OutputIndexAfter', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'finalizeBridgeERC721', + outputs: [], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ { - name: '_startingBlockNumber', - internalType: 'uint256', - type: 'uint256', - }, - { - name: '_startingTimestamp', - internalType: 'uint256', - type: 'uint256', + name: '_messenger', + internalType: 'contract CrossDomainMessenger', + type: 'address', }, - { name: '_proposer', internalType: 'address', type: 'address' }, - { name: '_challenger', internalType: 'address', type: 'address' }, ], name: 'initialize', outputs: [], @@ -17070,109 +12627,157 @@ export const abis = { stateMutability: 'view', type: 'function', inputs: [], - name: 'l2BlockTime', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'latestBlockNumber', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'messenger', + outputs: [ + { + name: '', + internalType: 'contract CrossDomainMessenger', + type: 'address', + }, + ], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'latestOutputIndex', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'otherBridge', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'nextBlockNumber', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'version', + outputs: [{ name: '', internalType: 'string', type: 'string' }], }, + ], + L1FeeVault: [ { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'nextOutputIndex', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + stateMutability: 'nonpayable', + type: 'constructor', + inputs: [ + { name: '_recipient', internalType: 'address', type: 'address' }, + ], }, { - stateMutability: 'payable', - type: 'function', + type: 'event', + anonymous: false, inputs: [ - { name: '_outputRoot', internalType: 'bytes32', type: 'bytes32' }, - { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, - { name: '_l1BlockHash', internalType: 'bytes32', type: 'bytes32' }, - { name: '_l1BlockNumber', internalType: 'uint256', type: 'uint256' }, - ], - name: 'proposeL2Output', - outputs: [], + { + name: 'value', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + { + name: 'to', + internalType: 'address', + type: 'address', + indexed: false, + }, + { + name: 'from', + internalType: 'address', + type: 'address', + indexed: false, + }, + ], + name: 'Withdrawal', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'proposer', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'MIN_WITHDRAWAL_AMOUNT', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'startingBlockNumber', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'RECIPIENT', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'startingTimestamp', + name: 'totalProcessed', outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'submissionInterval', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'version', + outputs: [{ name: '', internalType: 'string', type: 'string' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + name: 'withdraw', + outputs: [], }, + { stateMutability: 'payable', type: 'receive' }, ], - L2StandardBridge: [ + L1StandardBridge: [ + { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, { - stateMutability: 'nonpayable', - type: 'constructor', + type: 'event', + anonymous: false, inputs: [ { - name: '_otherBridge', - internalType: 'address payable', + name: 'localToken', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'remoteToken', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'from', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'to', + internalType: 'address', type: 'address', + indexed: false, + }, + { + name: 'amount', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + { + name: 'extraData', + internalType: 'bytes', + type: 'bytes', + indexed: false, }, ], + name: 'ERC20BridgeFinalized', }, { type: 'event', anonymous: false, inputs: [ { - name: 'l1Token', + name: 'localToken', internalType: 'address', type: 'address', indexed: true, }, { - name: 'l2Token', + name: 'remoteToken', internalType: 'address', type: 'address', indexed: true, @@ -17202,20 +12807,20 @@ export const abis = { indexed: false, }, ], - name: 'DepositFinalized', + name: 'ERC20BridgeInitiated', }, { type: 'event', anonymous: false, inputs: [ { - name: 'localToken', + name: 'l1Token', internalType: 'address', type: 'address', indexed: true, }, { - name: 'remoteToken', + name: 'l2Token', internalType: 'address', type: 'address', indexed: true, @@ -17245,20 +12850,20 @@ export const abis = { indexed: false, }, ], - name: 'ERC20BridgeFinalized', + name: 'ERC20DepositInitiated', }, { type: 'event', anonymous: false, inputs: [ { - name: 'localToken', + name: 'l1Token', internalType: 'address', type: 'address', indexed: true, }, { - name: 'remoteToken', + name: 'l2Token', internalType: 'address', type: 'address', indexed: true, @@ -17288,7 +12893,7 @@ export const abis = { indexed: false, }, ], - name: 'ERC20BridgeInitiated', + name: 'ERC20WithdrawalFinalized', }, { type: 'event', @@ -17347,29 +12952,38 @@ export const abis = { anonymous: false, inputs: [ { - name: 'l1Token', + name: 'from', internalType: 'address', type: 'address', indexed: true, }, + { name: 'to', internalType: 'address', type: 'address', indexed: true }, { - name: 'l2Token', - internalType: 'address', - type: 'address', - indexed: true, + name: 'amount', + internalType: 'uint256', + type: 'uint256', + indexed: false, }, { - name: 'from', - internalType: 'address', - type: 'address', - indexed: true, + name: 'extraData', + internalType: 'bytes', + type: 'bytes', + indexed: false, }, + ], + name: 'ETHDepositInitiated', + }, + { + type: 'event', + anonymous: false, + inputs: [ { - name: 'to', + name: 'from', internalType: 'address', type: 'address', - indexed: false, + indexed: true, }, + { name: 'to', internalType: 'address', type: 'address', indexed: true }, { name: 'amount', internalType: 'uint256', @@ -17383,7 +12997,20 @@ export const abis = { indexed: false, }, ], - name: 'WithdrawalInitiated', + name: 'ETHWithdrawalFinalized', + }, + { + type: 'event', + anonymous: false, + inputs: [ + { + name: 'version', + internalType: 'uint8', + type: 'uint8', + indexed: false, + }, + ], + name: 'Initialized', }, { stateMutability: 'view', @@ -17455,6 +13082,54 @@ export const abis = { name: 'bridgeETHTo', outputs: [], }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { name: '_l1Token', internalType: 'address', type: 'address' }, + { name: '_l2Token', internalType: 'address', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'depositERC20', + outputs: [], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { name: '_l1Token', internalType: 'address', type: 'address' }, + { name: '_l2Token', internalType: 'address', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'depositERC20To', + outputs: [], + }, + { + stateMutability: 'payable', + type: 'function', + inputs: [ + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'depositETH', + outputs: [], + }, + { + stateMutability: 'payable', + type: 'function', + inputs: [ + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'depositETHTo', + outputs: [], + }, { stateMutability: 'view', type: 'function', @@ -17492,7 +13167,7 @@ export const abis = { outputs: [], }, { - stateMutability: 'payable', + stateMutability: 'nonpayable', type: 'function', inputs: [ { name: '_l1Token', internalType: 'address', type: 'address' }, @@ -17502,14 +13177,39 @@ export const abis = { { name: '_amount', internalType: 'uint256', type: 'uint256' }, { name: '_extraData', internalType: 'bytes', type: 'bytes' }, ], - name: 'finalizeDeposit', + name: 'finalizeERC20Withdrawal', + outputs: [], + }, + { + stateMutability: 'payable', + type: 'function', + inputs: [ + { name: '_from', internalType: 'address', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'finalizeETHWithdrawal', + outputs: [], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { + name: '_messenger', + internalType: 'contract CrossDomainMessenger', + type: 'address', + }, + ], + name: 'initialize', outputs: [], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'l1TokenBridge', + name: 'l2TokenBridge', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { @@ -17525,6 +13225,15 @@ export const abis = { }, ], }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'otherBridge', + outputs: [ + { name: '', internalType: 'contract StandardBridge', type: 'address' }, + ], + }, { stateMutability: 'view', type: 'function', @@ -17532,59 +13241,83 @@ export const abis = { name: 'version', outputs: [{ name: '', internalType: 'string', type: 'string' }], }, + { stateMutability: 'payable', type: 'receive' }, + ], + L2CrossDomainMessenger: [ { - stateMutability: 'payable', - type: 'function', + stateMutability: 'nonpayable', + type: 'constructor', inputs: [ - { name: '_l2Token', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { + name: '_l1CrossDomainMessenger', + internalType: 'address', + type: 'address', + }, + ], + }, + { + type: 'event', + anonymous: false, + inputs: [ + { + name: 'msgHash', + internalType: 'bytes32', + type: 'bytes32', + indexed: true, + }, + ], + name: 'FailedRelayedMessage', + }, + { + type: 'event', + anonymous: false, + inputs: [ + { + name: 'version', + internalType: 'uint8', + type: 'uint8', + indexed: false, + }, ], - name: 'withdraw', - outputs: [], + name: 'Initialized', }, { - stateMutability: 'payable', - type: 'function', + type: 'event', + anonymous: false, inputs: [ - { name: '_l2Token', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { + name: 'msgHash', + internalType: 'bytes32', + type: 'bytes32', + indexed: true, + }, ], - name: 'withdrawTo', - outputs: [], + name: 'RelayedMessage', }, - { stateMutability: 'payable', type: 'receive' }, - ], - L2ToL1MessagePasser: [ - { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, { type: 'event', anonymous: false, inputs: [ { - name: 'nonce', - internalType: 'uint256', - type: 'uint256', + name: 'target', + internalType: 'address', + type: 'address', indexed: true, }, { name: 'sender', internalType: 'address', type: 'address', - indexed: true, + indexed: false, }, { - name: 'target', - internalType: 'address', - type: 'address', - indexed: true, + name: 'message', + internalType: 'bytes', + type: 'bytes', + indexed: false, }, { - name: 'value', + name: 'messageNonce', internalType: 'uint256', type: 'uint256', indexed: false, @@ -17595,28 +13328,27 @@ export const abis = { type: 'uint256', indexed: false, }, - { name: 'data', internalType: 'bytes', type: 'bytes', indexed: false }, - { - name: 'withdrawalHash', - internalType: 'bytes32', - type: 'bytes32', - indexed: false, - }, ], - name: 'MessagePassed', + name: 'SentMessage', }, { type: 'event', anonymous: false, inputs: [ { - name: 'amount', + name: 'sender', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'value', internalType: 'uint256', type: 'uint256', - indexed: true, + indexed: false, }, ], - name: 'WithdrawerBalanceBurnt', + name: 'SentMessageExtension1', }, { stateMutability: 'view', @@ -17626,157 +13358,197 @@ export const abis = { outputs: [{ name: '', internalType: 'uint16', type: 'uint16' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', inputs: [], - name: 'burn', - outputs: [], + name: 'MIN_GAS_CALLDATA_OVERHEAD', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], }, { - stateMutability: 'payable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_target', internalType: 'address', type: 'address' }, - { name: '_gasLimit', internalType: 'uint256', type: 'uint256' }, - { name: '_data', internalType: 'bytes', type: 'bytes' }, - ], - name: 'initiateWithdrawal', - outputs: [], + inputs: [], + name: 'MIN_GAS_DYNAMIC_OVERHEAD_DENOMINATOR', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'messageNonce', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'MIN_GAS_DYNAMIC_OVERHEAD_NUMERATOR', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], }, { stateMutability: 'view', type: 'function', - inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - name: 'sentMessages', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + inputs: [], + name: 'OTHER_MESSENGER', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + name: 'RELAY_CALL_OVERHEAD', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], }, - { stateMutability: 'payable', type: 'receive' }, - ], - MintManager: [ { - stateMutability: 'nonpayable', - type: 'constructor', - inputs: [ - { name: '_upgrader', internalType: 'address', type: 'address' }, - { name: '_governanceToken', internalType: 'address', type: 'address' }, - ], + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'RELAY_CONSTANT_OVERHEAD', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], }, { - type: 'event', - anonymous: false, + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'RELAY_GAS_CHECK_BUFFER', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'RELAY_RESERVED_GAS', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + }, + { + stateMutability: 'pure', + type: 'function', inputs: [ - { - name: 'previousOwner', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'newOwner', - internalType: 'address', - type: 'address', - indexed: true, - }, + { name: '_message', internalType: 'bytes', type: 'bytes' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, ], - name: 'OwnershipTransferred', + name: 'baseGas', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], }, { stateMutability: 'view', type: 'function', + inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'failedMessages', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + }, + { + stateMutability: 'nonpayable', + type: 'function', inputs: [], - name: 'DENOMINATOR', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'initialize', + outputs: [], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'MINT_CAP', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'l1CrossDomainMessenger', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'MINT_PERIOD', + name: 'messageNonce', outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { - stateMutability: 'view', + stateMutability: 'payable', type: 'function', - inputs: [], - name: 'governanceToken', - outputs: [ - { name: '', internalType: 'contract GovernanceToken', type: 'address' }, + inputs: [ + { name: '_nonce', internalType: 'uint256', type: 'uint256' }, + { name: '_sender', internalType: 'address', type: 'address' }, + { name: '_target', internalType: 'address', type: 'address' }, + { name: '_value', internalType: 'uint256', type: 'uint256' }, + { name: '_minGasLimit', internalType: 'uint256', type: 'uint256' }, + { name: '_message', internalType: 'bytes', type: 'bytes' }, ], + name: 'relayMessage', + outputs: [], }, { - stateMutability: 'nonpayable', + stateMutability: 'payable', type: 'function', inputs: [ - { name: '_account', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, + { name: '_target', internalType: 'address', type: 'address' }, + { name: '_message', internalType: 'bytes', type: 'bytes' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, ], - name: 'mint', + name: 'sendMessage', outputs: [], }, { stateMutability: 'view', type: 'function', - inputs: [], - name: 'mintPermittedAfter', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'successfulMessages', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'owner', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'version', + outputs: [{ name: '', internalType: 'string', type: 'string' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', inputs: [], - name: 'renounceOwnership', - outputs: [], + name: 'xDomainMessageSender', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, + ], + L2ERC721Bridge: [ { stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], - name: 'transferOwnership', - outputs: [], + type: 'constructor', + inputs: [ + { name: '_messenger', internalType: 'address', type: 'address' }, + { name: '_otherBridge', internalType: 'address', type: 'address' }, + ], }, { - stateMutability: 'nonpayable', - type: 'function', + type: 'event', + anonymous: false, inputs: [ - { name: '_newMintManager', internalType: 'address', type: 'address' }, + { + name: 'localToken', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'remoteToken', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'from', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'to', + internalType: 'address', + type: 'address', + indexed: false, + }, + { + name: 'tokenId', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + { + name: 'extraData', + internalType: 'bytes', + type: 'bytes', + indexed: false, + }, ], - name: 'upgrade', - outputs: [], - }, - ], - OptimismMintableERC20Factory: [ - { - stateMutability: 'nonpayable', - type: 'constructor', - inputs: [{ name: '_bridge', internalType: 'address', type: 'address' }], + name: 'ERC721BridgeFinalized', }, { type: 'event', @@ -17795,60 +13567,91 @@ export const abis = { indexed: true, }, { - name: 'deployer', + name: 'from', internalType: 'address', type: 'address', - indexed: false, + indexed: true, }, - ], - name: 'OptimismMintableERC20Created', - }, - { - type: 'event', - anonymous: false, - inputs: [ { - name: 'remoteToken', + name: 'to', internalType: 'address', type: 'address', - indexed: true, + indexed: false, }, { - name: 'localToken', - internalType: 'address', - type: 'address', - indexed: true, + name: 'tokenId', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + { + name: 'extraData', + internalType: 'bytes', + type: 'bytes', + indexed: false, }, ], - name: 'StandardL2TokenCreated', + name: 'ERC721BridgeInitiated', }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'BRIDGE', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + inputs: [ + { name: '_localToken', internalType: 'address', type: 'address' }, + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'bridgeERC721', + outputs: [], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ + { name: '_localToken', internalType: 'address', type: 'address' }, { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_symbol', internalType: 'string', type: 'string' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, ], - name: 'createOptimismMintableERC20', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'bridgeERC721To', + outputs: [], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ + { name: '_localToken', internalType: 'address', type: 'address' }, { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_symbol', internalType: 'string', type: 'string' }, + { name: '_from', internalType: 'address', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, ], - name: 'createStandardL2Token', + name: 'finalizeBridgeERC721', + outputs: [], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'messenger', + outputs: [ + { + name: '', + internalType: 'contract CrossDomainMessenger', + type: 'address', + }, + ], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'otherBridge', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { @@ -17859,20 +13662,14 @@ export const abis = { outputs: [{ name: '', internalType: 'string', type: 'string' }], }, ], - OptimismMintableERC20Factory_goerli: [ - { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, + 'L2ERC721Bridge_optimism-goerli': [ { - type: 'event', - anonymous: false, + stateMutability: 'nonpayable', + type: 'constructor', inputs: [ - { - name: 'version', - internalType: 'uint8', - type: 'uint8', - indexed: false, - }, + { name: '_messenger', internalType: 'address', type: 'address' }, + { name: '_otherBridge', internalType: 'address', type: 'address' }, ], - name: 'Initialized', }, { type: 'event', @@ -17891,18 +13688,42 @@ export const abis = { indexed: true, }, { - name: 'deployer', + name: 'from', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'to', internalType: 'address', type: 'address', indexed: false, }, + { + name: 'tokenId', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + { + name: 'extraData', + internalType: 'bytes', + type: 'bytes', + indexed: false, + }, ], - name: 'OptimismMintableERC20Created', + name: 'ERC721BridgeFinalized', }, { type: 'event', anonymous: false, inputs: [ + { + name: 'localToken', + internalType: 'address', + type: 'address', + indexed: true, + }, { name: 'remoteToken', internalType: 'address', @@ -17910,68 +13731,112 @@ export const abis = { indexed: true, }, { - name: 'localToken', + name: 'from', internalType: 'address', type: 'address', indexed: true, }, + { + name: 'to', + internalType: 'address', + type: 'address', + indexed: false, + }, + { + name: 'tokenId', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + { + name: 'extraData', + internalType: 'bytes', + type: 'bytes', + indexed: false, + }, ], - name: 'StandardL2TokenCreated', + name: 'ERC721BridgeInitiated', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'BRIDGE', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'MESSENGER', + outputs: [ + { + name: '', + internalType: 'contract CrossDomainMessenger', + type: 'address', + }, + ], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'bridge', + name: 'OTHER_BRIDGE', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ + { name: '_localToken', internalType: 'address', type: 'address' }, { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_symbol', internalType: 'string', type: 'string' }, + { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, ], - name: 'createOptimismMintableERC20', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'bridgeERC721', + outputs: [], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ + { name: '_localToken', internalType: 'address', type: 'address' }, { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_symbol', internalType: 'string', type: 'string' }, - { name: '_decimals', internalType: 'uint8', type: 'uint8' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, ], - name: 'createOptimismMintableERC20WithDecimals', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'bridgeERC721To', + outputs: [], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ + { name: '_localToken', internalType: 'address', type: 'address' }, { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_symbol', internalType: 'string', type: 'string' }, + { name: '_from', internalType: 'address', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, ], - name: 'createStandardL2Token', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'finalizeBridgeERC721', + outputs: [], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [{ name: '_bridge', internalType: 'address', type: 'address' }], - name: 'initialize', - outputs: [], + inputs: [], + name: 'messenger', + outputs: [ + { + name: '', + internalType: 'contract CrossDomainMessenger', + type: 'address', + }, + ], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'otherBridge', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', @@ -17981,232 +13846,297 @@ export const abis = { outputs: [{ name: '', internalType: 'string', type: 'string' }], }, ], - 'OptimismMintableERC20Factory_optimism-goerli': [ + L2OutputOracle: [ { stateMutability: 'nonpayable', type: 'constructor', - inputs: [{ name: '_bridge', internalType: 'address', type: 'address' }], + inputs: [ + { + name: '_submissionInterval', + internalType: 'uint256', + type: 'uint256', + }, + { name: '_l2BlockTime', internalType: 'uint256', type: 'uint256' }, + { + name: '_finalizationPeriodSeconds', + internalType: 'uint256', + type: 'uint256', + }, + ], + }, + { + type: 'event', + anonymous: false, + inputs: [ + { + name: 'version', + internalType: 'uint8', + type: 'uint8', + indexed: false, + }, + ], + name: 'Initialized', }, { type: 'event', anonymous: false, inputs: [ { - name: 'localToken', - internalType: 'address', - type: 'address', + name: 'outputRoot', + internalType: 'bytes32', + type: 'bytes32', indexed: true, }, { - name: 'remoteToken', - internalType: 'address', - type: 'address', + name: 'l2OutputIndex', + internalType: 'uint256', + type: 'uint256', indexed: true, }, { - name: 'deployer', - internalType: 'address', - type: 'address', + name: 'l2BlockNumber', + internalType: 'uint256', + type: 'uint256', + indexed: true, + }, + { + name: 'l1Timestamp', + internalType: 'uint256', + type: 'uint256', indexed: false, }, ], - name: 'OptimismMintableERC20Created', + name: 'OutputProposed', }, { type: 'event', anonymous: false, inputs: [ { - name: 'remoteToken', - internalType: 'address', - type: 'address', + name: 'prevNextOutputIndex', + internalType: 'uint256', + type: 'uint256', indexed: true, }, { - name: 'localToken', - internalType: 'address', - type: 'address', + name: 'newNextOutputIndex', + internalType: 'uint256', + type: 'uint256', indexed: true, }, ], - name: 'StandardL2TokenCreated', + name: 'OutputsDeleted', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'BRIDGE', + name: 'CHALLENGER', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'FINALIZATION_PERIOD_SECONDS', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'L2_BLOCK_TIME', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'PROPOSER', + outputs: [{ name: '', internalType: 'address', type: 'address' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'SUBMISSION_INTERVAL', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'challenger', + outputs: [{ name: '', internalType: 'address', type: 'address' }], + }, + { + stateMutability: 'view', type: 'function', inputs: [ - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_symbol', internalType: 'string', type: 'string' }, + { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, ], - name: 'createOptimismMintableERC20', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'computeL2Timestamp', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_symbol', internalType: 'string', type: 'string' }, + { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, ], - name: 'createStandardL2Token', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'deleteL2Outputs', + outputs: [], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + name: 'finalizationPeriodSeconds', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, - ], - OptimismMintableERC721Factory: [ { - stateMutability: 'nonpayable', - type: 'constructor', + stateMutability: 'view', + type: 'function', inputs: [ - { name: '_bridge', internalType: 'address', type: 'address' }, - { name: '_remoteChainId', internalType: 'uint256', type: 'uint256' }, + { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, + ], + name: 'getL2Output', + outputs: [ + { + name: '', + internalType: 'struct Types.OutputProposal', + type: 'tuple', + components: [ + { name: 'outputRoot', internalType: 'bytes32', type: 'bytes32' }, + { name: 'timestamp', internalType: 'uint128', type: 'uint128' }, + { name: 'l2BlockNumber', internalType: 'uint128', type: 'uint128' }, + ], + }, ], }, { - type: 'event', - anonymous: false, + stateMutability: 'view', + type: 'function', inputs: [ + { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, + ], + name: 'getL2OutputAfter', + outputs: [ { - name: 'localToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'remoteToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'deployer', - internalType: 'address', - type: 'address', - indexed: false, + name: '', + internalType: 'struct Types.OutputProposal', + type: 'tuple', + components: [ + { name: 'outputRoot', internalType: 'bytes32', type: 'bytes32' }, + { name: 'timestamp', internalType: 'uint128', type: 'uint128' }, + { name: 'l2BlockNumber', internalType: 'uint128', type: 'uint128' }, + ], }, ], - name: 'OptimismMintableERC721Created', }, { stateMutability: 'view', type: 'function', - inputs: [], - name: 'bridge', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + inputs: [ + { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, + ], + name: 'getL2OutputIndexAfter', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_symbol', internalType: 'string', type: 'string' }, + { + name: '_startingBlockNumber', + internalType: 'uint256', + type: 'uint256', + }, + { + name: '_startingTimestamp', + internalType: 'uint256', + type: 'uint256', + }, + { name: '_proposer', internalType: 'address', type: 'address' }, + { name: '_challenger', internalType: 'address', type: 'address' }, ], - name: 'createOptimismMintableERC721', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'initialize', + outputs: [], }, { stateMutability: 'view', type: 'function', - inputs: [{ name: '', internalType: 'address', type: 'address' }], - name: 'isOptimismMintableERC721', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + inputs: [], + name: 'l2BlockTime', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'remoteChainId', + name: 'latestBlockNumber', outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + name: 'latestOutputIndex', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, - ], - 'OptimismMintableERC721Factory_optimism-goerli': [ { - stateMutability: 'nonpayable', - type: 'constructor', - inputs: [ - { name: '_bridge', internalType: 'address', type: 'address' }, - { name: '_remoteChainId', internalType: 'uint256', type: 'uint256' }, - ], + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'nextBlockNumber', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { - type: 'event', - anonymous: false, + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'nextOutputIndex', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + }, + { + stateMutability: 'payable', + type: 'function', inputs: [ - { - name: 'localToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'remoteToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'deployer', - internalType: 'address', - type: 'address', - indexed: false, - }, + { name: '_outputRoot', internalType: 'bytes32', type: 'bytes32' }, + { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, + { name: '_l1BlockHash', internalType: 'bytes32', type: 'bytes32' }, + { name: '_l1BlockNumber', internalType: 'uint256', type: 'uint256' }, ], - name: 'OptimismMintableERC721Created', + name: 'proposeL2Output', + outputs: [], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'BRIDGE', + name: 'proposer', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'REMOTE_CHAIN_ID', + name: 'startingBlockNumber', outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_symbol', internalType: 'string', type: 'string' }, - ], - name: 'createOptimismMintableERC721', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + inputs: [], + name: 'startingTimestamp', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', - inputs: [{ name: '', internalType: 'address', type: 'address' }], - name: 'isOptimismMintableERC721', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + inputs: [], + name: 'submissionInterval', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', @@ -18216,21 +14146,14 @@ export const abis = { outputs: [{ name: '', internalType: 'string', type: 'string' }], }, ], - OptimismPortal: [ + L2StandardBridge: [ { stateMutability: 'nonpayable', type: 'constructor', inputs: [ { - name: '_l2Oracle', - internalType: 'contract L2OutputOracle', - type: 'address', - }, - { name: '_guardian', internalType: 'address', type: 'address' }, - { name: '_paused', internalType: 'bool', type: 'bool' }, - { - name: '_config', - internalType: 'contract SystemConfig', + name: '_otherBridge', + internalType: 'address payable', type: 'address', }, ], @@ -18240,88 +14163,196 @@ export const abis = { anonymous: false, inputs: [ { - name: 'version', - internalType: 'uint8', - type: 'uint8', + name: 'l1Token', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'l2Token', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'from', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'to', + internalType: 'address', + type: 'address', + indexed: false, + }, + { + name: 'amount', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + { + name: 'extraData', + internalType: 'bytes', + type: 'bytes', indexed: false, }, ], - name: 'Initialized', + name: 'DepositFinalized', }, { type: 'event', anonymous: false, inputs: [ { - name: 'account', + name: 'localToken', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'remoteToken', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'from', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'to', internalType: 'address', type: 'address', indexed: false, }, + { + name: 'amount', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + { + name: 'extraData', + internalType: 'bytes', + type: 'bytes', + indexed: false, + }, ], - name: 'Paused', + name: 'ERC20BridgeFinalized', }, { type: 'event', anonymous: false, inputs: [ + { + name: 'localToken', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'remoteToken', + internalType: 'address', + type: 'address', + indexed: true, + }, { name: 'from', internalType: 'address', type: 'address', indexed: true, }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, { - name: 'version', + name: 'to', + internalType: 'address', + type: 'address', + indexed: false, + }, + { + name: 'amount', internalType: 'uint256', type: 'uint256', - indexed: true, + indexed: false, }, { - name: 'opaqueData', + name: 'extraData', internalType: 'bytes', type: 'bytes', indexed: false, }, ], - name: 'TransactionDeposited', + name: 'ERC20BridgeInitiated', }, { type: 'event', anonymous: false, inputs: [ { - name: 'account', + name: 'from', internalType: 'address', type: 'address', + indexed: true, + }, + { name: 'to', internalType: 'address', type: 'address', indexed: true }, + { + name: 'amount', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + { + name: 'extraData', + internalType: 'bytes', + type: 'bytes', indexed: false, }, ], - name: 'Unpaused', + name: 'ETHBridgeFinalized', }, { type: 'event', anonymous: false, inputs: [ { - name: 'withdrawalHash', - internalType: 'bytes32', - type: 'bytes32', + name: 'from', + internalType: 'address', + type: 'address', indexed: true, }, - { name: 'success', internalType: 'bool', type: 'bool', indexed: false }, + { name: 'to', internalType: 'address', type: 'address', indexed: true }, + { + name: 'amount', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + { + name: 'extraData', + internalType: 'bytes', + type: 'bytes', + indexed: false, + }, ], - name: 'WithdrawalFinalized', + name: 'ETHBridgeInitiated', }, { type: 'event', anonymous: false, inputs: [ { - name: 'withdrawalHash', - internalType: 'bytes32', - type: 'bytes32', + name: 'l1Token', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'l2Token', + internalType: 'address', + type: 'address', indexed: true, }, { @@ -18330,532 +14361,526 @@ export const abis = { type: 'address', indexed: true, }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, + { + name: 'to', + internalType: 'address', + type: 'address', + indexed: false, + }, + { + name: 'amount', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + { + name: 'extraData', + internalType: 'bytes', + type: 'bytes', + indexed: false, + }, ], - name: 'WithdrawalProven', + name: 'WithdrawalInitiated', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'GUARDIAN', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'MESSENGER', + outputs: [ + { + name: '', + internalType: 'contract CrossDomainMessenger', + type: 'address', + }, + ], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'L2_ORACLE', + name: 'OTHER_BRIDGE', outputs: [ - { name: '', internalType: 'contract L2OutputOracle', type: 'address' }, + { name: '', internalType: 'contract StandardBridge', type: 'address' }, ], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'SYSTEM_CONFIG', - outputs: [ - { name: '', internalType: 'contract SystemConfig', type: 'address' }, + inputs: [ + { name: '_localToken', internalType: 'address', type: 'address' }, + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, ], + name: 'bridgeERC20', + outputs: [], }, { - stateMutability: 'payable', + stateMutability: 'nonpayable', type: 'function', inputs: [ + { name: '_localToken', internalType: 'address', type: 'address' }, + { name: '_remoteToken', internalType: 'address', type: 'address' }, { name: '_to', internalType: 'address', type: 'address' }, - { name: '_value', internalType: 'uint256', type: 'uint256' }, - { name: '_gasLimit', internalType: 'uint64', type: 'uint64' }, - { name: '_isCreation', internalType: 'bool', type: 'bool' }, - { name: '_data', internalType: 'bytes', type: 'bytes' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, ], - name: 'depositTransaction', + name: 'bridgeERC20To', outputs: [], }, { stateMutability: 'payable', type: 'function', - inputs: [], - name: 'donateETH', + inputs: [ + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'bridgeETH', outputs: [], }, { - stateMutability: 'nonpayable', + stateMutability: 'payable', type: 'function', inputs: [ - { - name: '_tx', - internalType: 'struct Types.WithdrawalTransaction', - type: 'tuple', - components: [ - { name: 'nonce', internalType: 'uint256', type: 'uint256' }, - { name: 'sender', internalType: 'address', type: 'address' }, - { name: 'target', internalType: 'address', type: 'address' }, - { name: 'value', internalType: 'uint256', type: 'uint256' }, - { name: 'gasLimit', internalType: 'uint256', type: 'uint256' }, - { name: 'data', internalType: 'bytes', type: 'bytes' }, - ], - }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, ], - name: 'finalizeWithdrawalTransaction', + name: 'bridgeETHTo', outputs: [], }, { stateMutability: 'view', type: 'function', - inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - name: 'finalizedWithdrawals', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + inputs: [ + { name: '', internalType: 'address', type: 'address' }, + { name: '', internalType: 'address', type: 'address' }, + ], + name: 'deposits', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [{ name: '_paused', internalType: 'bool', type: 'bool' }], - name: 'initialize', + inputs: [ + { name: '_localToken', internalType: 'address', type: 'address' }, + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_from', internalType: 'address', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'finalizeBridgeERC20', outputs: [], }, { - stateMutability: 'view', + stateMutability: 'payable', type: 'function', inputs: [ - { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, + { name: '_from', internalType: 'address', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, ], - name: 'isOutputFinalized', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + name: 'finalizeBridgeETH', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'payable', type: 'function', - inputs: [], - name: 'l2Sender', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + inputs: [ + { name: '_l1Token', internalType: 'address', type: 'address' }, + { name: '_l2Token', internalType: 'address', type: 'address' }, + { name: '_from', internalType: 'address', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'finalizeDeposit', + outputs: [], }, { - stateMutability: 'pure', + stateMutability: 'view', type: 'function', - inputs: [{ name: '_byteCount', internalType: 'uint64', type: 'uint64' }], - name: 'minimumGasLimit', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + inputs: [], + name: 'l1TokenBridge', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'params', + name: 'messenger', outputs: [ - { name: 'prevBaseFee', internalType: 'uint128', type: 'uint128' }, - { name: 'prevBoughtGas', internalType: 'uint64', type: 'uint64' }, - { name: 'prevBlockNum', internalType: 'uint64', type: 'uint64' }, + { + name: '', + internalType: 'contract CrossDomainMessenger', + type: 'address', + }, ], }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'pause', - outputs: [], - }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'paused', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + name: 'version', + outputs: [{ name: '', internalType: 'string', type: 'string' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'payable', type: 'function', inputs: [ - { - name: '_tx', - internalType: 'struct Types.WithdrawalTransaction', - type: 'tuple', - components: [ - { name: 'nonce', internalType: 'uint256', type: 'uint256' }, - { name: 'sender', internalType: 'address', type: 'address' }, - { name: 'target', internalType: 'address', type: 'address' }, - { name: 'value', internalType: 'uint256', type: 'uint256' }, - { name: 'gasLimit', internalType: 'uint256', type: 'uint256' }, - { name: 'data', internalType: 'bytes', type: 'bytes' }, - ], - }, - { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, - { - name: '_outputRootProof', - internalType: 'struct Types.OutputRootProof', - type: 'tuple', - components: [ - { name: 'version', internalType: 'bytes32', type: 'bytes32' }, - { name: 'stateRoot', internalType: 'bytes32', type: 'bytes32' }, - { - name: 'messagePasserStorageRoot', - internalType: 'bytes32', - type: 'bytes32', - }, - { - name: 'latestBlockhash', - internalType: 'bytes32', - type: 'bytes32', - }, - ], - }, - { name: '_withdrawalProof', internalType: 'bytes[]', type: 'bytes[]' }, + { name: '_l2Token', internalType: 'address', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, ], - name: 'proveWithdrawalTransaction', + name: 'withdraw', outputs: [], }, { - stateMutability: 'view', + stateMutability: 'payable', type: 'function', - inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - name: 'provenWithdrawals', - outputs: [ - { name: 'outputRoot', internalType: 'bytes32', type: 'bytes32' }, - { name: 'timestamp', internalType: 'uint128', type: 'uint128' }, - { name: 'l2OutputIndex', internalType: 'uint128', type: 'uint128' }, + inputs: [ + { name: '_l2Token', internalType: 'address', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, ], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'unpause', + name: 'withdrawTo', outputs: [], }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], - }, { stateMutability: 'payable', type: 'receive' }, ], - OptimismPortal_goerli: [ + L2ToL1MessagePasser: [ { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, { type: 'event', anonymous: false, inputs: [ { - name: 'version', - internalType: 'uint8', - type: 'uint8', - indexed: false, + name: 'nonce', + internalType: 'uint256', + type: 'uint256', + indexed: true, }, - ], - name: 'Initialized', - }, - { - type: 'event', - anonymous: false, - inputs: [ { - name: 'account', + name: 'sender', internalType: 'address', type: 'address', - indexed: false, + indexed: true, }, - ], - name: 'Paused', - }, - { - type: 'event', - anonymous: false, - inputs: [ { - name: 'from', + name: 'target', internalType: 'address', type: 'address', indexed: true, }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, { - name: 'version', + name: 'value', internalType: 'uint256', type: 'uint256', - indexed: true, + indexed: false, }, { - name: 'opaqueData', - internalType: 'bytes', - type: 'bytes', + name: 'gasLimit', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + { name: 'data', internalType: 'bytes', type: 'bytes', indexed: false }, + { + name: 'withdrawalHash', + internalType: 'bytes32', + type: 'bytes32', indexed: false, }, ], - name: 'TransactionDeposited', + name: 'MessagePassed', }, { type: 'event', anonymous: false, inputs: [ { - name: 'account', - internalType: 'address', - type: 'address', - indexed: false, + name: 'amount', + internalType: 'uint256', + type: 'uint256', + indexed: true, }, ], - name: 'Unpaused', + name: 'WithdrawerBalanceBurnt', + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'MESSAGE_VERSION', + outputs: [{ name: '', internalType: 'uint16', type: 'uint16' }], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [], + name: 'burn', + outputs: [], + }, + { + stateMutability: 'payable', + type: 'function', + inputs: [ + { name: '_target', internalType: 'address', type: 'address' }, + { name: '_gasLimit', internalType: 'uint256', type: 'uint256' }, + { name: '_data', internalType: 'bytes', type: 'bytes' }, + ], + name: 'initiateWithdrawal', + outputs: [], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'messageNonce', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { - type: 'event', - anonymous: false, + stateMutability: 'view', + type: 'function', + inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'sentMessages', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'version', + outputs: [{ name: '', internalType: 'string', type: 'string' }], + }, + { stateMutability: 'payable', type: 'receive' }, + ], + MintManager: [ + { + stateMutability: 'nonpayable', + type: 'constructor', inputs: [ - { - name: 'withdrawalHash', - internalType: 'bytes32', - type: 'bytes32', - indexed: true, - }, - { name: 'success', internalType: 'bool', type: 'bool', indexed: false }, + { name: '_upgrader', internalType: 'address', type: 'address' }, + { name: '_governanceToken', internalType: 'address', type: 'address' }, ], - name: 'WithdrawalFinalized', }, { type: 'event', anonymous: false, inputs: [ { - name: 'withdrawalHash', - internalType: 'bytes32', - type: 'bytes32', + name: 'previousOwner', + internalType: 'address', + type: 'address', indexed: true, }, { - name: 'from', + name: 'newOwner', internalType: 'address', type: 'address', indexed: true, }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, ], - name: 'WithdrawalProven', + name: 'OwnershipTransferred', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'GUARDIAN', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'DENOMINATOR', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'L2_ORACLE', - outputs: [ - { name: '', internalType: 'contract L2OutputOracle', type: 'address' }, - ], + name: 'MINT_CAP', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'SYSTEM_CONFIG', - outputs: [ - { name: '', internalType: 'contract SystemConfig', type: 'address' }, - ], - }, - { - stateMutability: 'payable', - type: 'function', - inputs: [ - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_value', internalType: 'uint256', type: 'uint256' }, - { name: '_gasLimit', internalType: 'uint64', type: 'uint64' }, - { name: '_isCreation', internalType: 'bool', type: 'bool' }, - { name: '_data', internalType: 'bytes', type: 'bytes' }, - ], - name: 'depositTransaction', - outputs: [], + name: 'MINT_PERIOD', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { - stateMutability: 'payable', + stateMutability: 'view', type: 'function', inputs: [], - name: 'donateETH', - outputs: [], + name: 'governanceToken', + outputs: [ + { name: '', internalType: 'contract GovernanceToken', type: 'address' }, + ], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { - name: '_tx', - internalType: 'struct Types.WithdrawalTransaction', - type: 'tuple', - components: [ - { name: 'nonce', internalType: 'uint256', type: 'uint256' }, - { name: 'sender', internalType: 'address', type: 'address' }, - { name: 'target', internalType: 'address', type: 'address' }, - { name: 'value', internalType: 'uint256', type: 'uint256' }, - { name: 'gasLimit', internalType: 'uint256', type: 'uint256' }, - { name: 'data', internalType: 'bytes', type: 'bytes' }, - ], - }, + { name: '_account', internalType: 'address', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, ], - name: 'finalizeWithdrawalTransaction', + name: 'mint', outputs: [], }, { stateMutability: 'view', type: 'function', - inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - name: 'finalizedWithdrawals', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + inputs: [], + name: 'mintPermittedAfter', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'guardian', + name: 'owner', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [ - { - name: '_l2Oracle', - internalType: 'contract L2OutputOracle', - type: 'address', - }, - { name: '_guardian', internalType: 'address', type: 'address' }, - { - name: '_systemConfig', - internalType: 'contract SystemConfig', - type: 'address', - }, - { name: '_paused', internalType: 'bool', type: 'bool' }, - ], - name: 'initialize', + inputs: [], + name: 'renounceOwnership', outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [ - { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, - ], - name: 'isOutputFinalized', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], + name: 'transferOwnership', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'l2Oracle', - outputs: [ - { name: '', internalType: 'contract L2OutputOracle', type: 'address' }, + inputs: [ + { name: '_newMintManager', internalType: 'address', type: 'address' }, ], + name: 'upgrade', + outputs: [], }, + ], + OptimismMintableERC20Factory: [ + { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'l2Sender', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + type: 'event', + anonymous: false, + inputs: [ + { + name: 'version', + internalType: 'uint8', + type: 'uint8', + indexed: false, + }, + ], + name: 'Initialized', }, { - stateMutability: 'pure', - type: 'function', - inputs: [{ name: '_byteCount', internalType: 'uint64', type: 'uint64' }], - name: 'minimumGasLimit', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + type: 'event', + anonymous: false, + inputs: [ + { + name: 'localToken', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'remoteToken', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'deployer', + internalType: 'address', + type: 'address', + indexed: false, + }, + ], + name: 'OptimismMintableERC20Created', }, { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'params', - outputs: [ - { name: 'prevBaseFee', internalType: 'uint128', type: 'uint128' }, - { name: 'prevBoughtGas', internalType: 'uint64', type: 'uint64' }, - { name: 'prevBlockNum', internalType: 'uint64', type: 'uint64' }, + type: 'event', + anonymous: false, + inputs: [ + { + name: 'remoteToken', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'localToken', + internalType: 'address', + type: 'address', + indexed: true, + }, ], + name: 'StandardL2TokenCreated', }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', inputs: [], - name: 'pause', - outputs: [], + name: 'BRIDGE', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'paused', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + name: 'bridge', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { - name: '_tx', - internalType: 'struct Types.WithdrawalTransaction', - type: 'tuple', - components: [ - { name: 'nonce', internalType: 'uint256', type: 'uint256' }, - { name: 'sender', internalType: 'address', type: 'address' }, - { name: 'target', internalType: 'address', type: 'address' }, - { name: 'value', internalType: 'uint256', type: 'uint256' }, - { name: 'gasLimit', internalType: 'uint256', type: 'uint256' }, - { name: 'data', internalType: 'bytes', type: 'bytes' }, - ], - }, - { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, - { - name: '_outputRootProof', - internalType: 'struct Types.OutputRootProof', - type: 'tuple', - components: [ - { name: 'version', internalType: 'bytes32', type: 'bytes32' }, - { name: 'stateRoot', internalType: 'bytes32', type: 'bytes32' }, - { - name: 'messagePasserStorageRoot', - internalType: 'bytes32', - type: 'bytes32', - }, - { - name: 'latestBlockhash', - internalType: 'bytes32', - type: 'bytes32', - }, - ], - }, - { name: '_withdrawalProof', internalType: 'bytes[]', type: 'bytes[]' }, + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, ], - name: 'proveWithdrawalTransaction', - outputs: [], + name: 'createOptimismMintableERC20', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'view', - type: 'function', - inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - name: 'provenWithdrawals', - outputs: [ - { name: 'outputRoot', internalType: 'bytes32', type: 'bytes32' }, - { name: 'timestamp', internalType: 'uint128', type: 'uint128' }, - { name: 'l2OutputIndex', internalType: 'uint128', type: 'uint128' }, + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, + { name: '_decimals', internalType: 'uint8', type: 'uint8' }, ], + name: 'createOptimismMintableERC20WithDecimals', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'systemConfig', - outputs: [ - { name: '', internalType: 'contract SystemConfig', type: 'address' }, + inputs: [ + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, ], + name: 'createStandardL2Token', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'unpause', + inputs: [{ name: '_bridge', internalType: 'address', type: 'address' }], + name: 'initialize', outputs: [], }, { @@ -18865,312 +14890,355 @@ export const abis = { name: 'version', outputs: [{ name: '', internalType: 'string', type: 'string' }], }, - { stateMutability: 'payable', type: 'receive' }, ], - Optimist: [ + OptimismMintableERC20Factory_goerli: [ + { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, { - stateMutability: 'nonpayable', - type: 'constructor', + type: 'event', + anonymous: false, inputs: [ - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_symbol', internalType: 'string', type: 'string' }, - { name: '_baseURIAttestor', internalType: 'address', type: 'address' }, - { - name: '_attestationStation', - internalType: 'contract AttestationStation', - type: 'address', - }, { - name: '_optimistAllowlist', - internalType: 'contract OptimistAllowlist', - type: 'address', + name: 'version', + internalType: 'uint8', + type: 'uint8', + indexed: false, }, ], + name: 'Initialized', }, { type: 'event', anonymous: false, inputs: [ { - name: 'owner', + name: 'localToken', internalType: 'address', type: 'address', indexed: true, }, { - name: 'approved', + name: 'remoteToken', internalType: 'address', type: 'address', indexed: true, }, { - name: 'tokenId', - internalType: 'uint256', - type: 'uint256', - indexed: true, + name: 'deployer', + internalType: 'address', + type: 'address', + indexed: false, }, ], - name: 'Approval', + name: 'OptimismMintableERC20Created', }, { type: 'event', anonymous: false, inputs: [ { - name: 'owner', + name: 'remoteToken', internalType: 'address', type: 'address', indexed: true, }, { - name: 'operator', + name: 'localToken', internalType: 'address', type: 'address', indexed: true, }, - { - name: 'approved', - internalType: 'bool', - type: 'bool', - indexed: false, - }, ], - name: 'ApprovalForAll', + name: 'StandardL2TokenCreated', }, { - type: 'event', - anonymous: false, + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'BRIDGE', + outputs: [{ name: '', internalType: 'address', type: 'address' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'bridge', + outputs: [{ name: '', internalType: 'address', type: 'address' }], + }, + { + stateMutability: 'nonpayable', + type: 'function', inputs: [ - { - name: 'version', - internalType: 'uint8', - type: 'uint8', - indexed: false, - }, + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, ], - name: 'Initialized', + name: 'createOptimismMintableERC20', + outputs: [{ name: '', internalType: 'address', type: 'address' }], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, + { name: '_decimals', internalType: 'uint8', type: 'uint8' }, + ], + name: 'createOptimismMintableERC20WithDecimals', + outputs: [{ name: '', internalType: 'address', type: 'address' }], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, + ], + name: 'createStandardL2Token', + outputs: [{ name: '', internalType: 'address', type: 'address' }], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [{ name: '_bridge', internalType: 'address', type: 'address' }], + name: 'initialize', + outputs: [], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'version', + outputs: [{ name: '', internalType: 'string', type: 'string' }], + }, + ], + 'OptimismMintableERC20Factory_optimism-goerli': [ + { + stateMutability: 'nonpayable', + type: 'constructor', + inputs: [{ name: '_bridge', internalType: 'address', type: 'address' }], }, { type: 'event', anonymous: false, inputs: [ { - name: 'from', + name: 'localToken', internalType: 'address', type: 'address', indexed: true, }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, { - name: 'tokenId', - internalType: 'uint256', - type: 'uint256', + name: 'remoteToken', + internalType: 'address', + type: 'address', indexed: true, }, + { + name: 'deployer', + internalType: 'address', + type: 'address', + indexed: false, + }, ], - name: 'Transfer', + name: 'OptimismMintableERC20Created', }, { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'ATTESTATION_STATION', - outputs: [ + type: 'event', + anonymous: false, + inputs: [ { - name: '', - internalType: 'contract AttestationStation', + name: 'remoteToken', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'localToken', + internalType: 'address', type: 'address', + indexed: true, }, ], + name: 'StandardL2TokenCreated', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'BASE_URI_ATTESTATION_KEY', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'BASE_URI_ATTESTOR', + name: 'BRIDGE', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'OPTIMIST_ALLOWLIST', - outputs: [ - { - name: '', - internalType: 'contract OptimistAllowlist', - type: 'address', - }, + inputs: [ + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, ], + name: 'createOptimismMintableERC20', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'pure', + stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '', internalType: 'address', type: 'address' }, - { name: '', internalType: 'uint256', type: 'uint256' }, + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, ], - name: 'approve', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [{ name: 'owner', internalType: 'address', type: 'address' }], - name: 'balanceOf', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'createStandardL2Token', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'baseURI', + name: 'version', outputs: [{ name: '', internalType: 'string', type: 'string' }], }, + ], + OptimismMintableERC721Factory: [ { stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: 'tokenId', internalType: 'uint256', type: 'uint256' }], - name: 'burn', - outputs: [], + type: 'constructor', + inputs: [ + { name: '_bridge', internalType: 'address', type: 'address' }, + { name: '_remoteChainId', internalType: 'uint256', type: 'uint256' }, + ], + }, + { + type: 'event', + anonymous: false, + inputs: [ + { + name: 'localToken', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'remoteToken', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'deployer', + internalType: 'address', + type: 'address', + indexed: false, + }, + ], + name: 'OptimismMintableERC721Created', }, { stateMutability: 'view', type: 'function', - inputs: [{ name: 'tokenId', internalType: 'uint256', type: 'uint256' }], - name: 'getApproved', + inputs: [], + name: 'bridge', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ + { name: '_remoteToken', internalType: 'address', type: 'address' }, { name: '_name', internalType: 'string', type: 'string' }, { name: '_symbol', internalType: 'string', type: 'string' }, ], - name: 'initialize', - outputs: [], + name: 'createOptimismMintableERC721', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', - inputs: [ - { name: 'owner', internalType: 'address', type: 'address' }, - { name: 'operator', internalType: 'address', type: 'address' }, - ], - name: 'isApprovedForAll', + inputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'isOptimismMintableERC721', outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { stateMutability: 'view', type: 'function', - inputs: [ - { name: '_recipient', internalType: 'address', type: 'address' }, - ], - name: 'isOnAllowList', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_recipient', internalType: 'address', type: 'address' }, - ], - name: 'mint', - outputs: [], + inputs: [], + name: 'remoteChainId', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'name', + name: 'version', outputs: [{ name: '', internalType: 'string', type: 'string' }], }, - { - stateMutability: 'view', - type: 'function', - inputs: [{ name: 'tokenId', internalType: 'uint256', type: 'uint256' }], - name: 'ownerOf', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: 'from', internalType: 'address', type: 'address' }, - { name: 'to', internalType: 'address', type: 'address' }, - { name: 'tokenId', internalType: 'uint256', type: 'uint256' }, - ], - name: 'safeTransferFrom', - outputs: [], - }, + ], + 'OptimismMintableERC721Factory_optimism-goerli': [ { stateMutability: 'nonpayable', - type: 'function', + type: 'constructor', inputs: [ - { name: 'from', internalType: 'address', type: 'address' }, - { name: 'to', internalType: 'address', type: 'address' }, - { name: 'tokenId', internalType: 'uint256', type: 'uint256' }, - { name: 'data', internalType: 'bytes', type: 'bytes' }, + { name: '_bridge', internalType: 'address', type: 'address' }, + { name: '_remoteChainId', internalType: 'uint256', type: 'uint256' }, ], - name: 'safeTransferFrom', - outputs: [], }, { - stateMutability: 'nonpayable', - type: 'function', + type: 'event', + anonymous: false, inputs: [ - { name: '', internalType: 'address', type: 'address' }, - { name: '', internalType: 'bool', type: 'bool' }, + { + name: 'localToken', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'remoteToken', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'deployer', + internalType: 'address', + type: 'address', + indexed: false, + }, ], - name: 'setApprovalForAll', - outputs: [], + name: 'OptimismMintableERC721Created', }, { stateMutability: 'view', type: 'function', - inputs: [{ name: 'interfaceId', internalType: 'bytes4', type: 'bytes4' }], - name: 'supportsInterface', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + inputs: [], + name: 'BRIDGE', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'symbol', - outputs: [{ name: '', internalType: 'string', type: 'string' }], - }, - { - stateMutability: 'pure', - type: 'function', - inputs: [{ name: '_owner', internalType: 'address', type: 'address' }], - name: 'tokenIdOfAddress', + name: 'REMOTE_CHAIN_ID', outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, - { - stateMutability: 'view', - type: 'function', - inputs: [{ name: '_tokenId', internalType: 'uint256', type: 'uint256' }], - name: 'tokenURI', - outputs: [{ name: '', internalType: 'string', type: 'string' }], - }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: 'from', internalType: 'address', type: 'address' }, - { name: 'to', internalType: 'address', type: 'address' }, - { name: 'tokenId', internalType: 'uint256', type: 'uint256' }, + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, ], - name: 'transferFrom', - outputs: [], + name: 'createOptimismMintableERC721', + outputs: [{ name: '', internalType: 'address', type: 'address' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'isOptimismMintableERC721', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { stateMutability: 'view', @@ -19180,254 +15248,333 @@ export const abis = { outputs: [{ name: '', internalType: 'string', type: 'string' }], }, ], - OptimistAllowlist: [ + OptimismPortal: [ + { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, { - stateMutability: 'nonpayable', - type: 'constructor', + type: 'event', + anonymous: false, inputs: [ { - name: '_attestationStation', - internalType: 'contract AttestationStation', + name: 'version', + internalType: 'uint8', + type: 'uint8', + indexed: false, + }, + ], + name: 'Initialized', + }, + { + type: 'event', + anonymous: false, + inputs: [ + { + name: 'account', + internalType: 'address', type: 'address', + indexed: false, }, + ], + name: 'Paused', + }, + { + type: 'event', + anonymous: false, + inputs: [ { - name: '_allowlistAttestor', + name: 'from', internalType: 'address', type: 'address', + indexed: true, }, + { name: 'to', internalType: 'address', type: 'address', indexed: true }, { - name: '_coinbaseQuestAttestor', + name: 'version', + internalType: 'uint256', + type: 'uint256', + indexed: true, + }, + { + name: 'opaqueData', + internalType: 'bytes', + type: 'bytes', + indexed: false, + }, + ], + name: 'TransactionDeposited', + }, + { + type: 'event', + anonymous: false, + inputs: [ + { + name: 'account', internalType: 'address', type: 'address', + indexed: false, }, - { name: '_optimistInviter', internalType: 'address', type: 'address' }, ], + name: 'Unpaused', + }, + { + type: 'event', + anonymous: false, + inputs: [ + { + name: 'withdrawalHash', + internalType: 'bytes32', + type: 'bytes32', + indexed: true, + }, + { name: 'success', internalType: 'bool', type: 'bool', indexed: false }, + ], + name: 'WithdrawalFinalized', + }, + { + type: 'event', + anonymous: false, + inputs: [ + { + name: 'withdrawalHash', + internalType: 'bytes32', + type: 'bytes32', + indexed: true, + }, + { + name: 'from', + internalType: 'address', + type: 'address', + indexed: true, + }, + { name: 'to', internalType: 'address', type: 'address', indexed: true }, + ], + name: 'WithdrawalProven', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'ALLOWLIST_ATTESTOR', + name: 'GUARDIAN', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'ATTESTATION_STATION', + name: 'L2_ORACLE', outputs: [ - { - name: '', - internalType: 'contract AttestationStation', - type: 'address', - }, + { name: '', internalType: 'contract L2OutputOracle', type: 'address' }, ], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'COINBASE_QUEST_ATTESTOR', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'SYSTEM_CONFIG', + outputs: [ + { name: '', internalType: 'contract SystemConfig', type: 'address' }, + ], }, { - stateMutability: 'view', + stateMutability: 'payable', type: 'function', - inputs: [], - name: 'COINBASE_QUEST_ELIGIBLE_ATTESTATION_KEY', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + inputs: [ + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_value', internalType: 'uint256', type: 'uint256' }, + { name: '_gasLimit', internalType: 'uint64', type: 'uint64' }, + { name: '_isCreation', internalType: 'bool', type: 'bool' }, + { name: '_data', internalType: 'bytes', type: 'bytes' }, + ], + name: 'depositTransaction', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'payable', type: 'function', inputs: [], - name: 'OPTIMIST_CAN_MINT_ATTESTATION_KEY', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'donateETH', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'OPTIMIST_INVITER', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + inputs: [ + { + name: '_tx', + internalType: 'struct Types.WithdrawalTransaction', + type: 'tuple', + components: [ + { name: 'nonce', internalType: 'uint256', type: 'uint256' }, + { name: 'sender', internalType: 'address', type: 'address' }, + { name: 'target', internalType: 'address', type: 'address' }, + { name: 'value', internalType: 'uint256', type: 'uint256' }, + { name: 'gasLimit', internalType: 'uint256', type: 'uint256' }, + { name: 'data', internalType: 'bytes', type: 'bytes' }, + ], + }, + ], + name: 'finalizeWithdrawalTransaction', + outputs: [], }, { stateMutability: 'view', type: 'function', - inputs: [{ name: '_claimer', internalType: 'address', type: 'address' }], - name: 'isAllowedToMint', + inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'finalizedWithdrawals', outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + name: 'guardian', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, - ], - OptimistInviter: [ { stateMutability: 'nonpayable', - type: 'constructor', + type: 'function', inputs: [ - { name: '_inviteGranter', internalType: 'address', type: 'address' }, { - name: '_attestationStation', - internalType: 'contract AttestationStation', + name: '_l2Oracle', + internalType: 'contract L2OutputOracle', type: 'address', }, - ], - }, - { - type: 'event', - anonymous: false, - inputs: [ + { name: '_guardian', internalType: 'address', type: 'address' }, { - name: 'version', - internalType: 'uint8', - type: 'uint8', - indexed: false, + name: '_systemConfig', + internalType: 'contract SystemConfig', + type: 'address', }, + { name: '_paused', internalType: 'bool', type: 'bool' }, ], - name: 'Initialized', + name: 'initialize', + outputs: [], }, { - type: 'event', - anonymous: false, + stateMutability: 'view', + type: 'function', inputs: [ - { - name: 'issuer', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'claimer', - internalType: 'address', - type: 'address', - indexed: true, - }, + { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, ], - name: 'InviteClaimed', + name: 'isOutputFinalized', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'ATTESTATION_STATION', + name: 'l2Oracle', outputs: [ - { - name: '', - internalType: 'contract AttestationStation', - type: 'address', - }, + { name: '', internalType: 'contract L2OutputOracle', type: 'address' }, ], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'CAN_INVITE_ATTESTATION_KEY', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'l2Sender', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'view', + stateMutability: 'pure', type: 'function', - inputs: [], - name: 'CLAIMABLE_INVITE_TYPEHASH', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + inputs: [{ name: '_byteCount', internalType: 'uint64', type: 'uint64' }], + name: 'minimumGasLimit', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'EIP712_VERSION', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + name: 'params', + outputs: [ + { name: 'prevBaseFee', internalType: 'uint128', type: 'uint128' }, + { name: 'prevBoughtGas', internalType: 'uint64', type: 'uint64' }, + { name: 'prevBlockNum', internalType: 'uint64', type: 'uint64' }, + ], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', inputs: [], - name: 'INVITE_GRANTER', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'pause', + outputs: [], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'MIN_COMMITMENT_PERIOD', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'paused', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_claimer', internalType: 'address', type: 'address' }, { - name: '_claimableInvite', - internalType: 'struct OptimistInviter.ClaimableInvite', + name: '_tx', + internalType: 'struct Types.WithdrawalTransaction', type: 'tuple', components: [ - { name: 'issuer', internalType: 'address', type: 'address' }, - { name: 'nonce', internalType: 'bytes32', type: 'bytes32' }, + { name: 'nonce', internalType: 'uint256', type: 'uint256' }, + { name: 'sender', internalType: 'address', type: 'address' }, + { name: 'target', internalType: 'address', type: 'address' }, + { name: 'value', internalType: 'uint256', type: 'uint256' }, + { name: 'gasLimit', internalType: 'uint256', type: 'uint256' }, + { name: 'data', internalType: 'bytes', type: 'bytes' }, ], }, - { name: '_signature', internalType: 'bytes', type: 'bytes' }, - ], - name: 'claimInvite', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_commitment', internalType: 'bytes32', type: 'bytes32' }, + { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, + { + name: '_outputRootProof', + internalType: 'struct Types.OutputRootProof', + type: 'tuple', + components: [ + { name: 'version', internalType: 'bytes32', type: 'bytes32' }, + { name: 'stateRoot', internalType: 'bytes32', type: 'bytes32' }, + { + name: 'messagePasserStorageRoot', + internalType: 'bytes32', + type: 'bytes32', + }, + { + name: 'latestBlockhash', + internalType: 'bytes32', + type: 'bytes32', + }, + ], + }, + { name: '_withdrawalProof', internalType: 'bytes[]', type: 'bytes[]' }, ], - name: 'commitInvite', + name: 'proveWithdrawalTransaction', outputs: [], }, { stateMutability: 'view', type: 'function', inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - name: 'commitmentTimestamps', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: '_name', internalType: 'string', type: 'string' }], - name: 'initialize', - outputs: [], + name: 'provenWithdrawals', + outputs: [ + { name: 'outputRoot', internalType: 'bytes32', type: 'bytes32' }, + { name: 'timestamp', internalType: 'uint128', type: 'uint128' }, + { name: 'l2OutputIndex', internalType: 'uint128', type: 'uint128' }, + ], }, { stateMutability: 'view', type: 'function', - inputs: [{ name: '', internalType: 'address', type: 'address' }], - name: 'inviteCounts', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + inputs: [], + name: 'systemConfig', + outputs: [ + { name: '', internalType: 'contract SystemConfig', type: 'address' }, + ], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [ - { name: '_accounts', internalType: 'address[]', type: 'address[]' }, - { name: '_inviteCount', internalType: 'uint256', type: 'uint256' }, - ], - name: 'setInviteCounts', + inputs: [], + name: 'unpause', outputs: [], }, - { - stateMutability: 'view', - type: 'function', - inputs: [ - { name: '', internalType: 'address', type: 'address' }, - { name: '', internalType: 'bytes32', type: 'bytes32' }, - ], - name: 'usedNonces', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], - }, { stateMutability: 'view', type: 'function', @@ -19435,57 +15582,77 @@ export const abis = { name: 'version', outputs: [{ name: '', internalType: 'string', type: 'string' }], }, + { stateMutability: 'payable', type: 'receive' }, ], - PortalSender: [ + Optimist: [ { stateMutability: 'nonpayable', type: 'constructor', inputs: [ + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, + { name: '_baseURIAttestor', internalType: 'address', type: 'address' }, { - name: '_portal', - internalType: 'contract OptimismPortal', + name: '_attestationStation', + internalType: 'contract AttestationStation', + type: 'address', + }, + { + name: '_optimistAllowlist', + internalType: 'contract OptimistAllowlist', type: 'address', }, ], }, { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'PORTAL', - outputs: [ - { name: '', internalType: 'contract OptimismPortal', type: 'address' }, + type: 'event', + anonymous: false, + inputs: [ + { + name: 'owner', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'approved', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'tokenId', + internalType: 'uint256', + type: 'uint256', + indexed: true, + }, ], + name: 'Approval', }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'donate', - outputs: [], - }, - ], - ProtocolVersions: [ - { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, { type: 'event', anonymous: false, inputs: [ { - name: 'version', - internalType: 'uint256', - type: 'uint256', + name: 'owner', + internalType: 'address', + type: 'address', indexed: true, }, { - name: 'updateType', - internalType: 'enum ProtocolVersions.UpdateType', - type: 'uint8', + name: 'operator', + internalType: 'address', + type: 'address', indexed: true, }, - { name: 'data', internalType: 'bytes', type: 'bytes', indexed: false }, + { + name: 'approved', + internalType: 'bool', + type: 'bool', + indexed: false, + }, ], - name: 'ConfigUpdate', + name: 'ApprovalForAll', }, { type: 'event', @@ -19505,115 +15672,221 @@ export const abis = { anonymous: false, inputs: [ { - name: 'previousOwner', + name: 'from', internalType: 'address', type: 'address', indexed: true, }, + { name: 'to', internalType: 'address', type: 'address', indexed: true }, { - name: 'newOwner', - internalType: 'address', - type: 'address', + name: 'tokenId', + internalType: 'uint256', + type: 'uint256', indexed: true, }, ], - name: 'OwnershipTransferred', + name: 'Transfer', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'RECOMMENDED_SLOT', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'ATTESTATION_STATION', + outputs: [ + { + name: '', + internalType: 'contract AttestationStation', + type: 'address', + }, + ], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'REQUIRED_SLOT', + name: 'BASE_URI_ATTESTATION_KEY', outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'VERSION', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'BASE_URI_ATTESTOR', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_owner', internalType: 'address', type: 'address' }, - { name: '_required', internalType: 'ProtocolVersion', type: 'uint256' }, + inputs: [], + name: 'OPTIMIST_ALLOWLIST', + outputs: [ { - name: '_recommended', - internalType: 'ProtocolVersion', - type: 'uint256', + name: '', + internalType: 'contract OptimistAllowlist', + type: 'address', }, ], - name: 'initialize', + }, + { + stateMutability: 'pure', + type: 'function', + inputs: [ + { name: '', internalType: 'address', type: 'address' }, + { name: '', internalType: 'uint256', type: 'uint256' }, + ], + name: 'approve', outputs: [], }, + { + stateMutability: 'view', + type: 'function', + inputs: [{ name: 'owner', internalType: 'address', type: 'address' }], + name: 'balanceOf', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'owner', + name: 'baseURI', + outputs: [{ name: '', internalType: 'string', type: 'string' }], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [{ name: 'tokenId', internalType: 'uint256', type: 'uint256' }], + name: 'burn', + outputs: [], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [{ name: 'tokenId', internalType: 'uint256', type: 'uint256' }], + name: 'getApproved', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, + ], + name: 'initialize', + outputs: [], + }, { stateMutability: 'view', type: 'function', - inputs: [], - name: 'recommended', - outputs: [ - { name: 'out_', internalType: 'ProtocolVersion', type: 'uint256' }, + inputs: [ + { name: 'owner', internalType: 'address', type: 'address' }, + { name: 'operator', internalType: 'address', type: 'address' }, + ], + name: 'isApprovedForAll', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [ + { name: '_recipient', internalType: 'address', type: 'address' }, ], + name: 'isOnAllowList', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'renounceOwnership', + inputs: [ + { name: '_recipient', internalType: 'address', type: 'address' }, + ], + name: 'mint', outputs: [], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'required', - outputs: [ - { name: 'out_', internalType: 'ProtocolVersion', type: 'uint256' }, + name: 'name', + outputs: [{ name: '', internalType: 'string', type: 'string' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [{ name: 'tokenId', internalType: 'uint256', type: 'uint256' }], + name: 'ownerOf', + outputs: [{ name: '', internalType: 'address', type: 'address' }], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { name: 'from', internalType: 'address', type: 'address' }, + { name: 'to', internalType: 'address', type: 'address' }, + { name: 'tokenId', internalType: 'uint256', type: 'uint256' }, ], + name: 'safeTransferFrom', + outputs: [], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { - name: '_recommended', - internalType: 'ProtocolVersion', - type: 'uint256', - }, + { name: 'from', internalType: 'address', type: 'address' }, + { name: 'to', internalType: 'address', type: 'address' }, + { name: 'tokenId', internalType: 'uint256', type: 'uint256' }, + { name: 'data', internalType: 'bytes', type: 'bytes' }, ], - name: 'setRecommended', + name: 'safeTransferFrom', outputs: [], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_required', internalType: 'ProtocolVersion', type: 'uint256' }, + { name: '', internalType: 'address', type: 'address' }, + { name: '', internalType: 'bool', type: 'bool' }, ], - name: 'setRequired', + name: 'setApprovalForAll', outputs: [], }, + { + stateMutability: 'view', + type: 'function', + inputs: [{ name: 'interfaceId', internalType: 'bytes4', type: 'bytes4' }], + name: 'supportsInterface', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'symbol', + outputs: [{ name: '', internalType: 'string', type: 'string' }], + }, + { + stateMutability: 'pure', + type: 'function', + inputs: [{ name: '_owner', internalType: 'address', type: 'address' }], + name: 'tokenIdOfAddress', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [{ name: '_tokenId', internalType: 'uint256', type: 'uint256' }], + name: 'tokenURI', + outputs: [{ name: '', internalType: 'string', type: 'string' }], + }, { stateMutability: 'nonpayable', type: 'function', - inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], - name: 'transferOwnership', + inputs: [ + { name: 'from', internalType: 'address', type: 'address' }, + { name: 'to', internalType: 'address', type: 'address' }, + { name: 'tokenId', internalType: 'uint256', type: 'uint256' }, + ], + name: 'transferFrom', outputs: [], }, { @@ -19624,314 +15897,253 @@ export const abis = { outputs: [{ name: '', internalType: 'string', type: 'string' }], }, ], - ProxyAdmin: [ + OptimistAllowlist: [ { stateMutability: 'nonpayable', type: 'constructor', - inputs: [{ name: '_owner', internalType: 'address', type: 'address' }], - }, - { - type: 'event', - anonymous: false, inputs: [ { - name: 'previousOwner', + name: '_attestationStation', + internalType: 'contract AttestationStation', + type: 'address', + }, + { + name: '_allowlistAttestor', internalType: 'address', type: 'address', - indexed: true, }, { - name: 'newOwner', + name: '_coinbaseQuestAttestor', internalType: 'address', type: 'address', - indexed: true, }, + { name: '_optimistInviter', internalType: 'address', type: 'address' }, ], - name: 'OwnershipTransferred', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'addressManager', - outputs: [ - { name: '', internalType: 'contract AddressManager', type: 'address' }, - ], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_proxy', internalType: 'address payable', type: 'address' }, - { name: '_newAdmin', internalType: 'address', type: 'address' }, - ], - name: 'changeProxyAdmin', - outputs: [], + name: 'ALLOWLIST_ATTESTOR', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', - inputs: [ - { name: '_proxy', internalType: 'address payable', type: 'address' }, + inputs: [], + name: 'ATTESTATION_STATION', + outputs: [ + { + name: '', + internalType: 'contract AttestationStation', + type: 'address', + }, ], - name: 'getProxyAdmin', - outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', - inputs: [{ name: '_proxy', internalType: 'address', type: 'address' }], - name: 'getProxyImplementation', + inputs: [], + name: 'COINBASE_QUEST_ATTESTOR', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', - inputs: [{ name: '', internalType: 'address', type: 'address' }], - name: 'implementationName', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + inputs: [], + name: 'COINBASE_QUEST_ELIGIBLE_ATTESTATION_KEY', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'isUpgrading', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + name: 'OPTIMIST_CAN_MINT_ATTESTATION_KEY', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'owner', + name: 'OPTIMIST_INVITER', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', - inputs: [{ name: '', internalType: 'address', type: 'address' }], - name: 'proxyType', - outputs: [ - { name: '', internalType: 'enum ProxyAdmin.ProxyType', type: 'uint8' }, - ], + inputs: [{ name: '_claimer', internalType: 'address', type: 'address' }], + name: 'isAllowedToMint', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', inputs: [], - name: 'renounceOwnership', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_address', internalType: 'address', type: 'address' }, - ], - name: 'setAddress', - outputs: [], + name: 'version', + outputs: [{ name: '', internalType: 'string', type: 'string' }], }, + ], + OptimistInviter: [ { stateMutability: 'nonpayable', - type: 'function', + type: 'constructor', inputs: [ + { name: '_inviteGranter', internalType: 'address', type: 'address' }, { - name: '_address', - internalType: 'contract AddressManager', + name: '_attestationStation', + internalType: 'contract AttestationStation', type: 'address', }, ], - name: 'setAddressManager', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_address', internalType: 'address', type: 'address' }, - { name: '_name', internalType: 'string', type: 'string' }, - ], - name: 'setImplementationName', - outputs: [], }, { - stateMutability: 'nonpayable', - type: 'function', + type: 'event', + anonymous: false, inputs: [ - { name: '_address', internalType: 'address', type: 'address' }, { - name: '_type', - internalType: 'enum ProxyAdmin.ProxyType', + name: 'version', + internalType: 'uint8', type: 'uint8', + indexed: false, }, ], - name: 'setProxyType', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: '_upgrading', internalType: 'bool', type: 'bool' }], - name: 'setUpgrading', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], - name: 'transferOwnership', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_proxy', internalType: 'address payable', type: 'address' }, - { name: '_implementation', internalType: 'address', type: 'address' }, - ], - name: 'upgrade', - outputs: [], - }, - { - stateMutability: 'payable', - type: 'function', - inputs: [ - { name: '_proxy', internalType: 'address payable', type: 'address' }, - { name: '_implementation', internalType: 'address', type: 'address' }, - { name: '_data', internalType: 'bytes', type: 'bytes' }, - ], - name: 'upgradeAndCall', - outputs: [], + name: 'Initialized', }, - ], - SchemaRegistry: [ - { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, - { type: 'error', inputs: [], name: 'AlreadyExists' }, { type: 'event', anonymous: false, inputs: [ { - name: 'uid', - internalType: 'bytes32', - type: 'bytes32', + name: 'issuer', + internalType: 'address', + type: 'address', indexed: true, }, { - name: 'registerer', + name: 'claimer', internalType: 'address', type: 'address', - indexed: false, + indexed: true, }, ], - name: 'Registered', + name: 'InviteClaimed', }, { stateMutability: 'view', type: 'function', - inputs: [{ name: 'uid', internalType: 'bytes32', type: 'bytes32' }], - name: 'getSchema', + inputs: [], + name: 'ATTESTATION_STATION', outputs: [ { name: '', - internalType: 'struct SchemaRecord', - type: 'tuple', - components: [ - { name: 'uid', internalType: 'bytes32', type: 'bytes32' }, - { - name: 'resolver', - internalType: 'contract ISchemaResolver', - type: 'address', - }, - { name: 'revocable', internalType: 'bool', type: 'bool' }, - { name: 'schema', internalType: 'string', type: 'string' }, - ], + internalType: 'contract AttestationStation', + type: 'address', }, ], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: 'schema', internalType: 'string', type: 'string' }, - { - name: 'resolver', - internalType: 'contract ISchemaResolver', - type: 'address', - }, - { name: 'revocable', internalType: 'bool', type: 'bool' }, - ], - name: 'register', + inputs: [], + name: 'CAN_INVITE_ATTESTATION_KEY', outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'version', + name: 'CLAIMABLE_INVITE_TYPEHASH', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'EIP712_VERSION', outputs: [{ name: '', internalType: 'string', type: 'string' }], }, - ], - SequencerFeeVault: [ + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'INVITE_GRANTER', + outputs: [{ name: '', internalType: 'address', type: 'address' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'MIN_COMMITMENT_PERIOD', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + }, { stateMutability: 'nonpayable', - type: 'constructor', + type: 'function', inputs: [ - { name: '_recipient', internalType: 'address', type: 'address' }, + { name: '_claimer', internalType: 'address', type: 'address' }, + { + name: '_claimableInvite', + internalType: 'struct OptimistInviter.ClaimableInvite', + type: 'tuple', + components: [ + { name: 'issuer', internalType: 'address', type: 'address' }, + { name: 'nonce', internalType: 'bytes32', type: 'bytes32' }, + ], + }, + { name: '_signature', internalType: 'bytes', type: 'bytes' }, ], + name: 'claimInvite', + outputs: [], }, { - type: 'event', - anonymous: false, + stateMutability: 'nonpayable', + type: 'function', inputs: [ - { - name: 'value', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - { - name: 'to', - internalType: 'address', - type: 'address', - indexed: false, - }, - { - name: 'from', - internalType: 'address', - type: 'address', - indexed: false, - }, + { name: '_commitment', internalType: 'bytes32', type: 'bytes32' }, ], - name: 'Withdrawal', + name: 'commitInvite', + outputs: [], }, { stateMutability: 'view', type: 'function', - inputs: [], - name: 'MIN_WITHDRAWAL_AMOUNT', + inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'commitmentTimestamps', outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'RECIPIENT', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + inputs: [{ name: '_name', internalType: 'string', type: 'string' }], + name: 'initialize', + outputs: [], }, { stateMutability: 'view', type: 'function', - inputs: [], - name: 'l1FeeWallet', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + inputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'inviteCounts', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { name: '_accounts', internalType: 'address[]', type: 'address[]' }, + { name: '_inviteCount', internalType: 'uint256', type: 'uint256' }, + ], + name: 'setInviteCounts', + outputs: [], }, { stateMutability: 'view', type: 'function', - inputs: [], - name: 'totalProcessed', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + inputs: [ + { name: '', internalType: 'address', type: 'address' }, + { name: '', internalType: 'bytes32', type: 'bytes32' }, + ], + name: 'usedNonces', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { stateMutability: 'view', @@ -19940,61 +16152,38 @@ export const abis = { name: 'version', outputs: [{ name: '', internalType: 'string', type: 'string' }], }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'withdraw', - outputs: [], - }, - { stateMutability: 'payable', type: 'receive' }, ], - SystemConfig: [ + PortalSender: [ { stateMutability: 'nonpayable', type: 'constructor', inputs: [ - { name: '_owner', internalType: 'address', type: 'address' }, - { name: '_overhead', internalType: 'uint256', type: 'uint256' }, - { name: '_scalar', internalType: 'uint256', type: 'uint256' }, - { name: '_batcherHash', internalType: 'bytes32', type: 'bytes32' }, - { name: '_gasLimit', internalType: 'uint64', type: 'uint64' }, { - name: '_unsafeBlockSigner', - internalType: 'address', + name: '_portal', + internalType: 'contract OptimismPortal', type: 'address', }, - { - name: '_config', - internalType: 'struct ResourceMetering.ResourceConfig', - type: 'tuple', - components: [ - { - name: 'maxResourceLimit', - internalType: 'uint32', - type: 'uint32', - }, - { - name: 'elasticityMultiplier', - internalType: 'uint8', - type: 'uint8', - }, - { - name: 'baseFeeMaxChangeDenominator', - internalType: 'uint8', - type: 'uint8', - }, - { name: 'minimumBaseFee', internalType: 'uint32', type: 'uint32' }, - { name: 'systemTxMaxGas', internalType: 'uint32', type: 'uint32' }, - { - name: 'maximumBaseFee', - internalType: 'uint128', - type: 'uint128', - }, - ], - }, ], }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'PORTAL', + outputs: [ + { name: '', internalType: 'contract OptimismPortal', type: 'address' }, + ], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [], + name: 'donate', + outputs: [], + }, + ], + ProtocolVersions: [ + { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, { type: 'event', anonymous: false, @@ -20007,7 +16196,7 @@ export const abis = { }, { name: 'updateType', - internalType: 'enum SystemConfig.UpdateType', + internalType: 'enum ProtocolVersions.UpdateType', type: 'uint8', indexed: true, }, @@ -20051,7 +16240,14 @@ export const abis = { stateMutability: 'view', type: 'function', inputs: [], - name: 'UNSAFE_BLOCK_SIGNER_SLOT', + name: 'RECOMMENDED_SLOT', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'REQUIRED_SLOT', outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { @@ -20061,87 +16257,179 @@ export const abis = { name: 'VERSION', outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { name: '_owner', internalType: 'address', type: 'address' }, + { name: '_required', internalType: 'ProtocolVersion', type: 'uint256' }, + { + name: '_recommended', + internalType: 'ProtocolVersion', + type: 'uint256', + }, + ], + name: 'initialize', + outputs: [], + }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'batcherHash', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'owner', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'gasLimit', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + name: 'recommended', + outputs: [ + { name: 'out_', internalType: 'ProtocolVersion', type: 'uint256' }, + ], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [], + name: 'renounceOwnership', + outputs: [], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'required', + outputs: [ + { name: 'out_', internalType: 'ProtocolVersion', type: 'uint256' }, + ], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_owner', internalType: 'address', type: 'address' }, - { name: '_overhead', internalType: 'uint256', type: 'uint256' }, - { name: '_scalar', internalType: 'uint256', type: 'uint256' }, - { name: '_batcherHash', internalType: 'bytes32', type: 'bytes32' }, - { name: '_gasLimit', internalType: 'uint64', type: 'uint64' }, { - name: '_unsafeBlockSigner', + name: '_recommended', + internalType: 'ProtocolVersion', + type: 'uint256', + }, + ], + name: 'setRecommended', + outputs: [], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { name: '_required', internalType: 'ProtocolVersion', type: 'uint256' }, + ], + name: 'setRequired', + outputs: [], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], + name: 'transferOwnership', + outputs: [], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'version', + outputs: [{ name: '', internalType: 'string', type: 'string' }], + }, + ], + ProxyAdmin: [ + { + stateMutability: 'nonpayable', + type: 'constructor', + inputs: [{ name: '_owner', internalType: 'address', type: 'address' }], + }, + { + type: 'event', + anonymous: false, + inputs: [ + { + name: 'previousOwner', internalType: 'address', type: 'address', + indexed: true, }, { - name: '_config', - internalType: 'struct ResourceMetering.ResourceConfig', - type: 'tuple', - components: [ - { - name: 'maxResourceLimit', - internalType: 'uint32', - type: 'uint32', - }, - { - name: 'elasticityMultiplier', - internalType: 'uint8', - type: 'uint8', - }, - { - name: 'baseFeeMaxChangeDenominator', - internalType: 'uint8', - type: 'uint8', - }, - { name: 'minimumBaseFee', internalType: 'uint32', type: 'uint32' }, - { name: 'systemTxMaxGas', internalType: 'uint32', type: 'uint32' }, - { - name: 'maximumBaseFee', - internalType: 'uint128', - type: 'uint128', - }, - ], + name: 'newOwner', + internalType: 'address', + type: 'address', + indexed: true, }, ], - name: 'initialize', + name: 'OwnershipTransferred', + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'addressManager', + outputs: [ + { name: '', internalType: 'contract AddressManager', type: 'address' }, + ], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { name: '_proxy', internalType: 'address payable', type: 'address' }, + { name: '_newAdmin', internalType: 'address', type: 'address' }, + ], + name: 'changeProxyAdmin', outputs: [], }, + { + stateMutability: 'view', + type: 'function', + inputs: [ + { name: '_proxy', internalType: 'address payable', type: 'address' }, + ], + name: 'getProxyAdmin', + outputs: [{ name: '', internalType: 'address', type: 'address' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [{ name: '_proxy', internalType: 'address', type: 'address' }], + name: 'getProxyImplementation', + outputs: [{ name: '', internalType: 'address', type: 'address' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'implementationName', + outputs: [{ name: '', internalType: 'string', type: 'string' }], + }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'minimumGasLimit', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + name: 'isUpgrading', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'overhead', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'owner', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', - inputs: [], - name: 'owner', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + inputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'proxyType', + outputs: [ + { name: '', internalType: 'enum ProxyAdmin.ProxyType', type: 'uint8' }, + ], }, { stateMutability: 'nonpayable', @@ -20151,139 +16439,217 @@ export const abis = { outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'resourceConfig', - outputs: [ - { - name: '', - internalType: 'struct ResourceMetering.ResourceConfig', - type: 'tuple', - components: [ - { - name: 'maxResourceLimit', - internalType: 'uint32', - type: 'uint32', - }, - { - name: 'elasticityMultiplier', - internalType: 'uint8', - type: 'uint8', - }, - { - name: 'baseFeeMaxChangeDenominator', - internalType: 'uint8', - type: 'uint8', - }, - { name: 'minimumBaseFee', internalType: 'uint32', type: 'uint32' }, - { name: 'systemTxMaxGas', internalType: 'uint32', type: 'uint32' }, - { - name: 'maximumBaseFee', - internalType: 'uint128', - type: 'uint128', - }, - ], - }, + inputs: [ + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_address', internalType: 'address', type: 'address' }, ], + name: 'setAddress', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'scalar', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + inputs: [ + { + name: '_address', + internalType: 'contract AddressManager', + type: 'address', + }, + ], + name: 'setAddressManager', + outputs: [], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_batcherHash', internalType: 'bytes32', type: 'bytes32' }, + { name: '_address', internalType: 'address', type: 'address' }, + { name: '_name', internalType: 'string', type: 'string' }, ], - name: 'setBatcherHash', + name: 'setImplementationName', outputs: [], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_overhead', internalType: 'uint256', type: 'uint256' }, - { name: '_scalar', internalType: 'uint256', type: 'uint256' }, + { name: '_address', internalType: 'address', type: 'address' }, + { + name: '_type', + internalType: 'enum ProxyAdmin.ProxyType', + type: 'uint8', + }, ], - name: 'setGasConfig', + name: 'setProxyType', outputs: [], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [{ name: '_gasLimit', internalType: 'uint64', type: 'uint64' }], - name: 'setGasLimit', + inputs: [{ name: '_upgrading', internalType: 'bool', type: 'bool' }], + name: 'setUpgrading', + outputs: [], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], + name: 'transferOwnership', outputs: [], }, { stateMutability: 'nonpayable', type: 'function', + inputs: [ + { name: '_proxy', internalType: 'address payable', type: 'address' }, + { name: '_implementation', internalType: 'address', type: 'address' }, + ], + name: 'upgrade', + outputs: [], + }, + { + stateMutability: 'payable', + type: 'function', + inputs: [ + { name: '_proxy', internalType: 'address payable', type: 'address' }, + { name: '_implementation', internalType: 'address', type: 'address' }, + { name: '_data', internalType: 'bytes', type: 'bytes' }, + ], + name: 'upgradeAndCall', + outputs: [], + }, + ], + SchemaRegistry: [ + { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, + { type: 'error', inputs: [], name: 'AlreadyExists' }, + { + type: 'event', + anonymous: false, inputs: [ { - name: '_config', - internalType: 'struct ResourceMetering.ResourceConfig', + name: 'uid', + internalType: 'bytes32', + type: 'bytes32', + indexed: true, + }, + { + name: 'registerer', + internalType: 'address', + type: 'address', + indexed: false, + }, + ], + name: 'Registered', + }, + { + stateMutability: 'view', + type: 'function', + inputs: [{ name: 'uid', internalType: 'bytes32', type: 'bytes32' }], + name: 'getSchema', + outputs: [ + { + name: '', + internalType: 'struct SchemaRecord', type: 'tuple', components: [ + { name: 'uid', internalType: 'bytes32', type: 'bytes32' }, { - name: 'maxResourceLimit', - internalType: 'uint32', - type: 'uint32', - }, - { - name: 'elasticityMultiplier', - internalType: 'uint8', - type: 'uint8', - }, - { - name: 'baseFeeMaxChangeDenominator', - internalType: 'uint8', - type: 'uint8', - }, - { name: 'minimumBaseFee', internalType: 'uint32', type: 'uint32' }, - { name: 'systemTxMaxGas', internalType: 'uint32', type: 'uint32' }, - { - name: 'maximumBaseFee', - internalType: 'uint128', - type: 'uint128', + name: 'resolver', + internalType: 'contract ISchemaResolver', + type: 'address', }, + { name: 'revocable', internalType: 'bool', type: 'bool' }, + { name: 'schema', internalType: 'string', type: 'string' }, ], }, ], - name: 'setResourceConfig', - outputs: [], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ + { name: 'schema', internalType: 'string', type: 'string' }, { - name: '_unsafeBlockSigner', - internalType: 'address', + name: 'resolver', + internalType: 'contract ISchemaResolver', type: 'address', }, + { name: 'revocable', internalType: 'bool', type: 'bool' }, ], - name: 'setUnsafeBlockSigner', - outputs: [], + name: 'register', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'version', + outputs: [{ name: '', internalType: 'string', type: 'string' }], + }, + ], + SequencerFeeVault: [ { stateMutability: 'nonpayable', + type: 'constructor', + inputs: [ + { name: '_recipient', internalType: 'address', type: 'address' }, + ], + }, + { + type: 'event', + anonymous: false, + inputs: [ + { + name: 'value', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + { + name: 'to', + internalType: 'address', + type: 'address', + indexed: false, + }, + { + name: 'from', + internalType: 'address', + type: 'address', + indexed: false, + }, + ], + name: 'Withdrawal', + }, + { + stateMutability: 'view', type: 'function', - inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], - name: 'transferOwnership', - outputs: [], + inputs: [], + name: 'MIN_WITHDRAWAL_AMOUNT', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'unsafeBlockSigner', + name: 'RECIPIENT', + outputs: [{ name: '', internalType: 'address', type: 'address' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'l1FeeWallet', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'totalProcessed', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + }, { stateMutability: 'view', type: 'function', @@ -20291,8 +16657,16 @@ export const abis = { name: 'version', outputs: [{ name: '', internalType: 'string', type: 'string' }], }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [], + name: 'withdraw', + outputs: [], + }, + { stateMutability: 'payable', type: 'receive' }, ], - SystemConfig_goerli: [ + SystemConfig: [ { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, { type: 'event', diff --git a/packages/contracts-ts/src/react.spec.tsx b/packages/contracts-ts/src/react.spec.tsx deleted file mode 100644 index 30799d860a0f1..0000000000000 --- a/packages/contracts-ts/src/react.spec.tsx +++ /dev/null @@ -1,87 +0,0 @@ -import matchers from '@testing-library/jest-dom/matchers' -import { cleanup, waitFor } from '@testing-library/react' -import { renderHook } from '@testing-library/react-hooks' -import { afterEach, expect, test } from 'vitest' -import { useMintManagerOwner } from './react' -import { configureChains, createConfig, WagmiConfig } from 'wagmi' -import * as React from 'react' -import { optimism } from 'viem/chains' -import { jsonRpcProvider } from 'wagmi/providers/jsonRpc' - -expect.extend(matchers) - -afterEach(() => { - cleanup() -}) - -const { publicClient } = configureChains( - [optimism], - [ - jsonRpcProvider({ - rpc: () => ({ - http: - import.meta.env.VITE_RPC_URL_L2_MAINNET ?? - 'https://mainnet.optimism.io', - }), - }), - ] -) - -const config = createConfig({ - publicClient: ({ chainId }) => publicClient({ chainId }), -}) - -const blockNumber = BigInt(106806163) - -test('react hooks should work', async () => { - const hook = renderHook( - () => useMintManagerOwner({ chainId: 10, blockNumber }), - { - wrapper: ({ children }) => ( - {children} - ), - } - ) - await waitFor(() => { - hook.rerender() - if (hook.result.current.error) throw hook.result.current.error - expect(hook.result.current?.data).toBeDefined() - }) - const normalizedResult = { - ...hook.result.current, - internal: { - ...hook.result.current.internal, - dataUpdatedAt: 'SNAPSHOT_TEST_REMOVED!!!', - }, - } - expect(normalizedResult).toMatchInlineSnapshot(` - { - "data": "0x2A82Ae142b2e62Cb7D10b55E323ACB1Cab663a26", - "error": null, - "fetchStatus": "idle", - "internal": { - "dataUpdatedAt": "SNAPSHOT_TEST_REMOVED!!!", - "errorUpdatedAt": 0, - "failureCount": 0, - "isFetchedAfterMount": true, - "isLoadingError": false, - "isPaused": false, - "isPlaceholderData": false, - "isPreviousData": false, - "isRefetchError": false, - "isStale": true, - "remove": [Function], - }, - "isError": false, - "isFetched": true, - "isFetchedAfterMount": true, - "isFetching": false, - "isIdle": false, - "isLoading": false, - "isRefetching": false, - "isSuccess": true, - "refetch": [Function], - "status": "success", - } - `) -}) diff --git a/packages/contracts-ts/src/react.ts b/packages/contracts-ts/src/react.ts index 2204652009c72..268a9006bbc31 100644 --- a/packages/contracts-ts/src/react.ts +++ b/packages/contracts-ts/src/react.ts @@ -6,8 +6,6 @@ import { useContractWrite, Address, UseContractWriteConfig, - usePrepareContractWrite, - UsePrepareContractWriteConfig, useContractEvent, UseContractEventConfig, } from 'wagmi' @@ -2793,20 +2791,11 @@ export const l1BlockConfig = { ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) */ export const l1CrossDomainMessengerABI = [ - { - stateMutability: 'nonpayable', - type: 'constructor', - inputs: [ - { - name: '_portal', - internalType: 'contract OptimismPortal', - type: 'address', - }, - ], - }, + { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, { type: 'event', anonymous: false, @@ -2927,15 +2916,6 @@ export const l1CrossDomainMessengerABI = [ name: 'OTHER_MESSENGER', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'PORTAL', - outputs: [ - { name: '', internalType: 'contract OptimismPortal', type: 'address' }, - ], - }, { stateMutability: 'view', type: 'function', @@ -2984,7 +2964,13 @@ export const l1CrossDomainMessengerABI = [ { stateMutability: 'nonpayable', type: 'function', - inputs: [], + inputs: [ + { + name: '_portal', + internalType: 'contract OptimismPortal', + type: 'address', + }, + ], name: 'initialize', outputs: [], }, @@ -2995,6 +2981,13 @@ export const l1CrossDomainMessengerABI = [ name: 'messageNonce', outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'portal', + outputs: [{ name: '', internalType: 'address', type: 'address' }], + }, { stateMutability: 'payable', type: 'function', @@ -3044,14 +3037,17 @@ export const l1CrossDomainMessengerABI = [ ] as const /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) */ export const l1CrossDomainMessengerAddress = { 1: '0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1', + 5: '0x5086d1eEF304eb5284A0f6720f79403b4e9bE294', } as const /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) */ export const l1CrossDomainMessengerConfig = { address: l1CrossDomainMessengerAddress, @@ -3059,186 +3055,148 @@ export const l1CrossDomainMessengerConfig = { } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// L1CrossDomainMessenger_goerli +// L1ERC721Bridge ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5a7749f83b81B301cAb5f48EB8516B986DAef23D) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9) */ -export const l1CrossDomainMessengerGoerliABI = [ +export const l1Erc721BridgeABI = [ { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, { type: 'event', anonymous: false, inputs: [ { - name: 'msgHash', - internalType: 'bytes32', - type: 'bytes32', - indexed: true, - }, - ], - name: 'FailedRelayedMessage', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, - ], - name: 'Initialized', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'msgHash', - internalType: 'bytes32', - type: 'bytes32', - indexed: true, - }, - ], - name: 'RelayedMessage', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'target', + name: 'localToken', internalType: 'address', type: 'address', indexed: true, }, { - name: 'sender', + name: 'remoteToken', internalType: 'address', type: 'address', - indexed: false, + indexed: true, }, - { name: 'message', internalType: 'bytes', type: 'bytes', indexed: false }, + { name: 'from', internalType: 'address', type: 'address', indexed: true }, + { name: 'to', internalType: 'address', type: 'address', indexed: false }, { - name: 'messageNonce', + name: 'tokenId', internalType: 'uint256', type: 'uint256', indexed: false, }, { - name: 'gasLimit', - internalType: 'uint256', - type: 'uint256', + name: 'extraData', + internalType: 'bytes', + type: 'bytes', indexed: false, }, ], - name: 'SentMessage', + name: 'ERC721BridgeFinalized', }, { type: 'event', anonymous: false, inputs: [ { - name: 'sender', + name: 'localToken', internalType: 'address', type: 'address', indexed: true, }, { - name: 'value', + name: 'remoteToken', + internalType: 'address', + type: 'address', + indexed: true, + }, + { name: 'from', internalType: 'address', type: 'address', indexed: true }, + { name: 'to', internalType: 'address', type: 'address', indexed: false }, + { + name: 'tokenId', internalType: 'uint256', type: 'uint256', indexed: false, }, + { + name: 'extraData', + internalType: 'bytes', + type: 'bytes', + indexed: false, + }, ], - name: 'SentMessageExtension1', - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'MESSAGE_VERSION', - outputs: [{ name: '', internalType: 'uint16', type: 'uint16' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'MIN_GAS_CALLDATA_OVERHEAD', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'MIN_GAS_DYNAMIC_OVERHEAD_DENOMINATOR', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'MIN_GAS_DYNAMIC_OVERHEAD_NUMERATOR', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'OTHER_MESSENGER', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'ERC721BridgeInitiated', }, { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'RELAY_CALL_OVERHEAD', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + type: 'event', + anonymous: false, + inputs: [ + { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, + ], + name: 'Initialized', }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'RELAY_CONSTANT_OVERHEAD', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + inputs: [ + { name: '_localToken', internalType: 'address', type: 'address' }, + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'bridgeERC721', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'RELAY_GAS_CHECK_BUFFER', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + inputs: [ + { name: '_localToken', internalType: 'address', type: 'address' }, + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'bridgeERC721To', + outputs: [], }, { stateMutability: 'view', type: 'function', - inputs: [], - name: 'RELAY_RESERVED_GAS', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], - }, - { - stateMutability: 'pure', - type: 'function', inputs: [ - { name: '_message', internalType: 'bytes', type: 'bytes' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '', internalType: 'address', type: 'address' }, + { name: '', internalType: 'address', type: 'address' }, + { name: '', internalType: 'uint256', type: 'uint256' }, ], - name: 'baseGas', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + name: 'deposits', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - name: 'failedMessages', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + inputs: [ + { name: '_localToken', internalType: 'address', type: 'address' }, + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_from', internalType: 'address', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'finalizeBridgeERC721', + outputs: [], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ { - name: '_portal', - internalType: 'contract OptimismPortal', + name: '_messenger', + internalType: 'contract CrossDomainMessenger', type: 'address', }, ], @@ -3249,47 +3207,102 @@ export const l1CrossDomainMessengerGoerliABI = [ stateMutability: 'view', type: 'function', inputs: [], - name: 'messageNonce', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'messenger', + outputs: [ + { + name: '', + internalType: 'contract CrossDomainMessenger', + type: 'address', + }, + ], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'portal', + name: 'otherBridge', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'payable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_nonce', internalType: 'uint256', type: 'uint256' }, - { name: '_sender', internalType: 'address', type: 'address' }, - { name: '_target', internalType: 'address', type: 'address' }, - { name: '_value', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint256', type: 'uint256' }, - { name: '_message', internalType: 'bytes', type: 'bytes' }, - ], - name: 'relayMessage', - outputs: [], + inputs: [], + name: 'version', + outputs: [{ name: '', internalType: 'string', type: 'string' }], }, - { - stateMutability: 'payable', - type: 'function', - inputs: [ - { name: '_target', internalType: 'address', type: 'address' }, - { name: '_message', internalType: 'bytes', type: 'bytes' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, +] as const + +/** + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5a7749f83b81B301cAb5f48EB8516B986DAef23D) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9) + */ +export const l1Erc721BridgeAddress = { + 1: '0x5a7749f83b81B301cAb5f48EB8516B986DAef23D', + 5: '0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9', +} as const + +/** + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5a7749f83b81B301cAb5f48EB8516B986DAef23D) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9) + */ +export const l1Erc721BridgeConfig = { + address: l1Erc721BridgeAddress, + abi: l1Erc721BridgeABI, +} as const + +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// L1FeeVault +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/** + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000001a) + */ +export const l1FeeVaultABI = [ + { + stateMutability: 'nonpayable', + type: 'constructor', + inputs: [{ name: '_recipient', internalType: 'address', type: 'address' }], + }, + { + type: 'event', + anonymous: false, + inputs: [ + { + name: 'value', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + { name: 'to', internalType: 'address', type: 'address', indexed: false }, + { + name: 'from', + internalType: 'address', + type: 'address', + indexed: false, + }, ], - name: 'sendMessage', - outputs: [], + name: 'Withdrawal', }, { stateMutability: 'view', type: 'function', - inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - name: 'successfulMessages', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + inputs: [], + name: 'MIN_WITHDRAWAL_AMOUNT', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'RECIPIENT', + outputs: [{ name: '', internalType: 'address', type: 'address' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'totalProcessed', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', @@ -3299,45 +3312,40 @@ export const l1CrossDomainMessengerGoerliABI = [ outputs: [{ name: '', internalType: 'string', type: 'string' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', inputs: [], - name: 'xDomainMessageSender', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'withdraw', + outputs: [], }, + { stateMutability: 'payable', type: 'receive' }, ] as const /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000001a) */ -export const l1CrossDomainMessengerGoerliAddress = { - 5: '0x5086d1eEF304eb5284A0f6720f79403b4e9bE294', +export const l1FeeVaultAddress = { + 420: '0x420000000000000000000000000000000000001A', } as const /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000001a) */ -export const l1CrossDomainMessengerGoerliConfig = { - address: l1CrossDomainMessengerGoerliAddress, - abi: l1CrossDomainMessengerGoerliABI, +export const l1FeeVaultConfig = { + address: l1FeeVaultAddress, + abi: l1FeeVaultABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// L1ERC721Bridge +// L1StandardBridge ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5a7749f83b81B301cAb5f48EB8516B986DAef23D) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) */ -export const l1Erc721BridgeABI = [ - { - stateMutability: 'nonpayable', - type: 'constructor', - inputs: [ - { name: '_messenger', internalType: 'address', type: 'address' }, - { name: '_otherBridge', internalType: 'address', type: 'address' }, - ], - }, +export const l1StandardBridgeABI = [ + { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, { type: 'event', anonymous: false, @@ -3357,7 +3365,7 @@ export const l1Erc721BridgeABI = [ { name: 'from', internalType: 'address', type: 'address', indexed: true }, { name: 'to', internalType: 'address', type: 'address', indexed: false }, { - name: 'tokenId', + name: 'amount', internalType: 'uint256', type: 'uint256', indexed: false, @@ -3369,7 +3377,7 @@ export const l1Erc721BridgeABI = [ indexed: false, }, ], - name: 'ERC721BridgeFinalized', + name: 'ERC20BridgeFinalized', }, { type: 'event', @@ -3390,7 +3398,7 @@ export const l1Erc721BridgeABI = [ { name: 'from', internalType: 'address', type: 'address', indexed: true }, { name: 'to', internalType: 'address', type: 'address', indexed: false }, { - name: 'tokenId', + name: 'amount', internalType: 'uint256', type: 'uint256', indexed: false, @@ -3402,125 +3410,20 @@ export const l1Erc721BridgeABI = [ indexed: false, }, ], - name: 'ERC721BridgeInitiated', - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'bridgeERC721', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'bridgeERC721To', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [ - { name: '', internalType: 'address', type: 'address' }, - { name: '', internalType: 'address', type: 'address' }, - { name: '', internalType: 'uint256', type: 'uint256' }, - ], - name: 'deposits', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_from', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'finalizeBridgeERC721', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'messenger', - outputs: [ - { - name: '', - internalType: 'contract CrossDomainMessenger', - type: 'address', - }, - ], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'otherBridge', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + name: 'ERC20BridgeInitiated', }, -] as const - -/** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5a7749f83b81B301cAb5f48EB8516B986DAef23D) - */ -export const l1Erc721BridgeAddress = { - 1: '0x5a7749f83b81B301cAb5f48EB8516B986DAef23D', -} as const - -/** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5a7749f83b81B301cAb5f48EB8516B986DAef23D) - */ -export const l1Erc721BridgeConfig = { - address: l1Erc721BridgeAddress, - abi: l1Erc721BridgeABI, -} as const - -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// L1ERC721Bridge_goerli -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9) - */ -export const l1Erc721BridgeGoerliABI = [ - { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, { type: 'event', anonymous: false, inputs: [ { - name: 'localToken', + name: 'l1Token', internalType: 'address', type: 'address', indexed: true, }, { - name: 'remoteToken', + name: 'l2Token', internalType: 'address', type: 'address', indexed: true, @@ -3528,7 +3431,7 @@ export const l1Erc721BridgeGoerliABI = [ { name: 'from', internalType: 'address', type: 'address', indexed: true }, { name: 'to', internalType: 'address', type: 'address', indexed: false }, { - name: 'tokenId', + name: 'amount', internalType: 'uint256', type: 'uint256', indexed: false, @@ -3540,20 +3443,20 @@ export const l1Erc721BridgeGoerliABI = [ indexed: false, }, ], - name: 'ERC721BridgeFinalized', + name: 'ERC20DepositInitiated', }, { type: 'event', anonymous: false, inputs: [ { - name: 'localToken', + name: 'l1Token', internalType: 'address', type: 'address', indexed: true, }, { - name: 'remoteToken', + name: 'l2Token', internalType: 'address', type: 'address', indexed: true, @@ -3561,7 +3464,7 @@ export const l1Erc721BridgeGoerliABI = [ { name: 'from', internalType: 'address', type: 'address', indexed: true }, { name: 'to', internalType: 'address', type: 'address', indexed: false }, { - name: 'tokenId', + name: 'amount', internalType: 'uint256', type: 'uint256', indexed: false, @@ -3573,41 +3476,194 @@ export const l1Erc721BridgeGoerliABI = [ indexed: false, }, ], - name: 'ERC721BridgeInitiated', + name: 'ERC20WithdrawalFinalized', }, { type: 'event', anonymous: false, inputs: [ - { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, - ], - name: 'Initialized', - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { name: 'from', internalType: 'address', type: 'address', indexed: true }, + { name: 'to', internalType: 'address', type: 'address', indexed: true }, + { + name: 'amount', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + { + name: 'extraData', + internalType: 'bytes', + type: 'bytes', + indexed: false, + }, ], - name: 'bridgeERC721', - outputs: [], + name: 'ETHBridgeFinalized', }, { - stateMutability: 'nonpayable', - type: 'function', + type: 'event', + anonymous: false, inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, + { name: 'from', internalType: 'address', type: 'address', indexed: true }, + { name: 'to', internalType: 'address', type: 'address', indexed: true }, + { + name: 'amount', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + { + name: 'extraData', + internalType: 'bytes', + type: 'bytes', + indexed: false, + }, + ], + name: 'ETHBridgeInitiated', + }, + { + type: 'event', + anonymous: false, + inputs: [ + { name: 'from', internalType: 'address', type: 'address', indexed: true }, + { name: 'to', internalType: 'address', type: 'address', indexed: true }, + { + name: 'amount', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + { + name: 'extraData', + internalType: 'bytes', + type: 'bytes', + indexed: false, + }, + ], + name: 'ETHDepositInitiated', + }, + { + type: 'event', + anonymous: false, + inputs: [ + { name: 'from', internalType: 'address', type: 'address', indexed: true }, + { name: 'to', internalType: 'address', type: 'address', indexed: true }, + { + name: 'amount', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + { + name: 'extraData', + internalType: 'bytes', + type: 'bytes', + indexed: false, + }, + ], + name: 'ETHWithdrawalFinalized', + }, + { + type: 'event', + anonymous: false, + inputs: [ + { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, + ], + name: 'Initialized', + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { name: '_localToken', internalType: 'address', type: 'address' }, + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'bridgeERC20', + outputs: [], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { name: '_localToken', internalType: 'address', type: 'address' }, { name: '_remoteToken', internalType: 'address', type: 'address' }, { name: '_to', internalType: 'address', type: 'address' }, - { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, { name: '_extraData', internalType: 'bytes', type: 'bytes' }, ], - name: 'bridgeERC721To', + name: 'bridgeERC20To', + outputs: [], + }, + { + stateMutability: 'payable', + type: 'function', + inputs: [ + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'bridgeETH', + outputs: [], + }, + { + stateMutability: 'payable', + type: 'function', + inputs: [ + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'bridgeETHTo', + outputs: [], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { name: '_l1Token', internalType: 'address', type: 'address' }, + { name: '_l2Token', internalType: 'address', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'depositERC20', + outputs: [], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { name: '_l1Token', internalType: 'address', type: 'address' }, + { name: '_l2Token', internalType: 'address', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'depositERC20To', + outputs: [], + }, + { + stateMutability: 'payable', + type: 'function', + inputs: [ + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'depositETH', + outputs: [], + }, + { + stateMutability: 'payable', + type: 'function', + inputs: [ + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'depositETHTo', outputs: [], }, { @@ -3616,10 +3672,9 @@ export const l1Erc721BridgeGoerliABI = [ inputs: [ { name: '', internalType: 'address', type: 'address' }, { name: '', internalType: 'address', type: 'address' }, - { name: '', internalType: 'uint256', type: 'uint256' }, ], name: 'deposits', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'nonpayable', @@ -3629,10 +3684,48 @@ export const l1Erc721BridgeGoerliABI = [ { name: '_remoteToken', internalType: 'address', type: 'address' }, { name: '_from', internalType: 'address', type: 'address' }, { name: '_to', internalType: 'address', type: 'address' }, - { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, { name: '_extraData', internalType: 'bytes', type: 'bytes' }, ], - name: 'finalizeBridgeERC721', + name: 'finalizeBridgeERC20', + outputs: [], + }, + { + stateMutability: 'payable', + type: 'function', + inputs: [ + { name: '_from', internalType: 'address', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'finalizeBridgeETH', + outputs: [], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { name: '_l1Token', internalType: 'address', type: 'address' }, + { name: '_l2Token', internalType: 'address', type: 'address' }, + { name: '_from', internalType: 'address', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'finalizeERC20Withdrawal', + outputs: [], + }, + { + stateMutability: 'payable', + type: 'function', + inputs: [ + { name: '_from', internalType: 'address', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'finalizeETHWithdrawal', outputs: [], }, { @@ -3648,6 +3741,13 @@ export const l1Erc721BridgeGoerliABI = [ name: 'initialize', outputs: [], }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'l2TokenBridge', + outputs: [{ name: '', internalType: 'address', type: 'address' }], + }, { stateMutability: 'view', type: 'function', @@ -3666,7 +3766,9 @@ export const l1Erc721BridgeGoerliABI = [ type: 'function', inputs: [], name: 'otherBridge', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + outputs: [ + { name: '', internalType: 'contract StandardBridge', type: 'address' }, + ], }, { stateMutability: 'view', @@ -3675,77 +3777,264 @@ export const l1Erc721BridgeGoerliABI = [ name: 'version', outputs: [{ name: '', internalType: 'string', type: 'string' }], }, + { stateMutability: 'payable', type: 'receive' }, ] as const /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) */ -export const l1Erc721BridgeGoerliAddress = { - 5: '0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9', +export const l1StandardBridgeAddress = { + 1: '0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1', + 5: '0x636Af16bf2f682dD3109e60102b8E1A089FedAa8', } as const /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) */ -export const l1Erc721BridgeGoerliConfig = { - address: l1Erc721BridgeGoerliAddress, - abi: l1Erc721BridgeGoerliABI, +export const l1StandardBridgeConfig = { + address: l1StandardBridgeAddress, + abi: l1StandardBridgeABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// L1FeeVault +// L2CrossDomainMessenger ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000001a) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) */ -export const l1FeeVaultABI = [ +export const l2CrossDomainMessengerABI = [ { stateMutability: 'nonpayable', type: 'constructor', - inputs: [{ name: '_recipient', internalType: 'address', type: 'address' }], + inputs: [ + { + name: '_l1CrossDomainMessenger', + internalType: 'address', + type: 'address', + }, + ], }, { type: 'event', anonymous: false, inputs: [ { - name: 'value', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - { name: 'to', internalType: 'address', type: 'address', indexed: false }, - { - name: 'from', - internalType: 'address', - type: 'address', - indexed: false, + name: 'msgHash', + internalType: 'bytes32', + type: 'bytes32', + indexed: true, }, ], - name: 'Withdrawal', + name: 'FailedRelayedMessage', }, { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'MIN_WITHDRAWAL_AMOUNT', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + type: 'event', + anonymous: false, + inputs: [ + { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, + ], + name: 'Initialized', + }, + { + type: 'event', + anonymous: false, + inputs: [ + { + name: 'msgHash', + internalType: 'bytes32', + type: 'bytes32', + indexed: true, + }, + ], + name: 'RelayedMessage', + }, + { + type: 'event', + anonymous: false, + inputs: [ + { + name: 'target', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'sender', + internalType: 'address', + type: 'address', + indexed: false, + }, + { name: 'message', internalType: 'bytes', type: 'bytes', indexed: false }, + { + name: 'messageNonce', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + { + name: 'gasLimit', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + ], + name: 'SentMessage', + }, + { + type: 'event', + anonymous: false, + inputs: [ + { + name: 'sender', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'value', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + ], + name: 'SentMessageExtension1', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'RECIPIENT', + name: 'MESSAGE_VERSION', + outputs: [{ name: '', internalType: 'uint16', type: 'uint16' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'MIN_GAS_CALLDATA_OVERHEAD', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'MIN_GAS_DYNAMIC_OVERHEAD_DENOMINATOR', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'MIN_GAS_DYNAMIC_OVERHEAD_NUMERATOR', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'OTHER_MESSENGER', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'totalProcessed', + name: 'RELAY_CALL_OVERHEAD', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'RELAY_CONSTANT_OVERHEAD', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'RELAY_GAS_CHECK_BUFFER', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'RELAY_RESERVED_GAS', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + }, + { + stateMutability: 'pure', + type: 'function', + inputs: [ + { name: '_message', internalType: 'bytes', type: 'bytes' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + ], + name: 'baseGas', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'failedMessages', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [], + name: 'initialize', + outputs: [], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'l1CrossDomainMessenger', + outputs: [{ name: '', internalType: 'address', type: 'address' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'messageNonce', outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, + { + stateMutability: 'payable', + type: 'function', + inputs: [ + { name: '_nonce', internalType: 'uint256', type: 'uint256' }, + { name: '_sender', internalType: 'address', type: 'address' }, + { name: '_target', internalType: 'address', type: 'address' }, + { name: '_value', internalType: 'uint256', type: 'uint256' }, + { name: '_minGasLimit', internalType: 'uint256', type: 'uint256' }, + { name: '_message', internalType: 'bytes', type: 'bytes' }, + ], + name: 'relayMessage', + outputs: [], + }, + { + stateMutability: 'payable', + type: 'function', + inputs: [ + { name: '_target', internalType: 'address', type: 'address' }, + { name: '_message', internalType: 'bytes', type: 'bytes' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + ], + name: 'sendMessage', + outputs: [], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'successfulMessages', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + }, { stateMutability: 'view', type: 'function', @@ -3754,43 +4043,44 @@ export const l1FeeVaultABI = [ outputs: [{ name: '', internalType: 'string', type: 'string' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', inputs: [], - name: 'withdraw', - outputs: [], + name: 'xDomainMessageSender', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, - { stateMutability: 'payable', type: 'receive' }, ] as const /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000001a) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) */ -export const l1FeeVaultAddress = { - 420: '0x420000000000000000000000000000000000001A', +export const l2CrossDomainMessengerAddress = { + 420: '0x4200000000000000000000000000000000000007', } as const /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000001a) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) */ -export const l1FeeVaultConfig = { - address: l1FeeVaultAddress, - abi: l1FeeVaultABI, +export const l2CrossDomainMessengerConfig = { + address: l2CrossDomainMessengerAddress, + abi: l2CrossDomainMessengerABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// L1StandardBridge +// L2ERC721Bridge ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000014) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000014) */ -export const l1StandardBridgeABI = [ +export const l2Erc721BridgeABI = [ { stateMutability: 'nonpayable', type: 'constructor', inputs: [ - { name: '_messenger', internalType: 'address payable', type: 'address' }, + { name: '_messenger', internalType: 'address', type: 'address' }, + { name: '_otherBridge', internalType: 'address', type: 'address' }, ], }, { @@ -3812,7 +4102,7 @@ export const l1StandardBridgeABI = [ { name: 'from', internalType: 'address', type: 'address', indexed: true }, { name: 'to', internalType: 'address', type: 'address', indexed: false }, { - name: 'amount', + name: 'tokenId', internalType: 'uint256', type: 'uint256', indexed: false, @@ -3824,7 +4114,7 @@ export const l1StandardBridgeABI = [ indexed: false, }, ], - name: 'ERC20BridgeFinalized', + name: 'ERC721BridgeFinalized', }, { type: 'event', @@ -3845,7 +4135,7 @@ export const l1StandardBridgeABI = [ { name: 'from', internalType: 'address', type: 'address', indexed: true }, { name: 'to', internalType: 'address', type: 'address', indexed: false }, { - name: 'amount', + name: 'tokenId', internalType: 'uint256', type: 'uint256', indexed: false, @@ -3857,344 +4147,347 @@ export const l1StandardBridgeABI = [ indexed: false, }, ], - name: 'ERC20BridgeInitiated', + name: 'ERC721BridgeInitiated', }, { - type: 'event', - anonymous: false, + stateMutability: 'nonpayable', + type: 'function', inputs: [ - { - name: 'l1Token', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'l2Token', - internalType: 'address', - type: 'address', - indexed: true, - }, - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: false }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, - }, + { name: '_localToken', internalType: 'address', type: 'address' }, + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, ], - name: 'ERC20DepositInitiated', + name: 'bridgeERC721', + outputs: [], }, { - type: 'event', - anonymous: false, + stateMutability: 'nonpayable', + type: 'function', inputs: [ + { name: '_localToken', internalType: 'address', type: 'address' }, + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'bridgeERC721To', + outputs: [], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { name: '_localToken', internalType: 'address', type: 'address' }, + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_from', internalType: 'address', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'finalizeBridgeERC721', + outputs: [], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'messenger', + outputs: [ { - name: 'l1Token', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'l2Token', - internalType: 'address', + name: '', + internalType: 'contract CrossDomainMessenger', type: 'address', - indexed: true, - }, - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: false }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, }, ], - name: 'ERC20WithdrawalFinalized', }, { - type: 'event', - anonymous: false, + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'otherBridge', + outputs: [{ name: '', internalType: 'address', type: 'address' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'version', + outputs: [{ name: '', internalType: 'string', type: 'string' }], + }, +] as const + +/** + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000014) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000014) + */ +export const l2Erc721BridgeAddress = { + 10: '0x4200000000000000000000000000000000000014', + 420: '0x4200000000000000000000000000000000000014', +} as const + +/** + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000014) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000014) + */ +export const l2Erc721BridgeConfig = { + address: l2Erc721BridgeAddress, + abi: l2Erc721BridgeABI, +} as const + +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// L2OutputOracle +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/** + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) + */ +export const l2OutputOracleABI = [ + { + stateMutability: 'nonpayable', + type: 'constructor', inputs: [ - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, + { name: '_submissionInterval', internalType: 'uint256', type: 'uint256' }, + { name: '_l2BlockTime', internalType: 'uint256', type: 'uint256' }, { - name: 'amount', + name: '_finalizationPeriodSeconds', internalType: 'uint256', type: 'uint256', - indexed: false, - }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, }, ], - name: 'ETHBridgeFinalized', }, { type: 'event', anonymous: false, inputs: [ - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, - }, + { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, ], - name: 'ETHBridgeInitiated', + name: 'Initialized', }, { type: 'event', anonymous: false, inputs: [ - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, { - name: 'amount', + name: 'outputRoot', + internalType: 'bytes32', + type: 'bytes32', + indexed: true, + }, + { + name: 'l2OutputIndex', internalType: 'uint256', type: 'uint256', - indexed: false, + indexed: true, }, { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', + name: 'l2BlockNumber', + internalType: 'uint256', + type: 'uint256', + indexed: true, + }, + { + name: 'l1Timestamp', + internalType: 'uint256', + type: 'uint256', indexed: false, }, ], - name: 'ETHDepositInitiated', + name: 'OutputProposed', }, { type: 'event', anonymous: false, inputs: [ - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, { - name: 'amount', + name: 'prevNextOutputIndex', internalType: 'uint256', type: 'uint256', - indexed: false, + indexed: true, }, { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, + name: 'newNextOutputIndex', + internalType: 'uint256', + type: 'uint256', + indexed: true, }, ], - name: 'ETHWithdrawalFinalized', + name: 'OutputsDeleted', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'OTHER_BRIDGE', - outputs: [ - { name: '', internalType: 'contract StandardBridge', type: 'address' }, - ], + name: 'challenger', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, ], - name: 'bridgeERC20', - outputs: [], + name: 'computeL2Timestamp', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, ], - name: 'bridgeERC20To', + name: 'deleteL2Outputs', outputs: [], }, { - stateMutability: 'payable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'bridgeETH', - outputs: [], + inputs: [], + name: 'finalizationPeriodSeconds', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { - stateMutability: 'payable', + stateMutability: 'view', type: 'function', inputs: [ - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, + ], + name: 'getL2Output', + outputs: [ + { + name: '', + internalType: 'struct Types.OutputProposal', + type: 'tuple', + components: [ + { name: 'outputRoot', internalType: 'bytes32', type: 'bytes32' }, + { name: 'timestamp', internalType: 'uint128', type: 'uint128' }, + { name: 'l2BlockNumber', internalType: 'uint128', type: 'uint128' }, + ], + }, ], - name: 'bridgeETHTo', - outputs: [], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', inputs: [ - { name: '_l1Token', internalType: 'address', type: 'address' }, - { name: '_l2Token', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, + ], + name: 'getL2OutputAfter', + outputs: [ + { + name: '', + internalType: 'struct Types.OutputProposal', + type: 'tuple', + components: [ + { name: 'outputRoot', internalType: 'bytes32', type: 'bytes32' }, + { name: 'timestamp', internalType: 'uint128', type: 'uint128' }, + { name: 'l2BlockNumber', internalType: 'uint128', type: 'uint128' }, + ], + }, ], - name: 'depositERC20', - outputs: [], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', inputs: [ - { name: '_l1Token', internalType: 'address', type: 'address' }, - { name: '_l2Token', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, ], - name: 'depositERC20To', - outputs: [], + name: 'getL2OutputIndexAfter', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { - stateMutability: 'payable', + stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { + name: '_startingBlockNumber', + internalType: 'uint256', + type: 'uint256', + }, + { name: '_startingTimestamp', internalType: 'uint256', type: 'uint256' }, + { name: '_proposer', internalType: 'address', type: 'address' }, + { name: '_challenger', internalType: 'address', type: 'address' }, ], - name: 'depositETH', + name: 'initialize', outputs: [], }, { - stateMutability: 'payable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'depositETHTo', - outputs: [], + inputs: [], + name: 'l2BlockTime', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', - inputs: [ - { name: '', internalType: 'address', type: 'address' }, - { name: '', internalType: 'address', type: 'address' }, - ], - name: 'deposits', + inputs: [], + name: 'latestBlockNumber', outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_from', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'finalizeBridgeERC20', - outputs: [], + inputs: [], + name: 'latestOutputIndex', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { - stateMutability: 'payable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_from', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'finalizeBridgeETH', - outputs: [], + inputs: [], + name: 'nextBlockNumber', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_l1Token', internalType: 'address', type: 'address' }, - { name: '_l2Token', internalType: 'address', type: 'address' }, - { name: '_from', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'finalizeERC20Withdrawal', - outputs: [], + inputs: [], + name: 'nextOutputIndex', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'payable', type: 'function', inputs: [ - { name: '_from', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { name: '_outputRoot', internalType: 'bytes32', type: 'bytes32' }, + { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, + { name: '_l1BlockHash', internalType: 'bytes32', type: 'bytes32' }, + { name: '_l1BlockNumber', internalType: 'uint256', type: 'uint256' }, ], - name: 'finalizeETHWithdrawal', + name: 'proposeL2Output', outputs: [], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'l2TokenBridge', + name: 'proposer', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'messenger', - outputs: [ - { - name: '', - internalType: 'contract CrossDomainMessenger', - type: 'address', - }, - ], + name: 'startingBlockNumber', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'startingTimestamp', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'submissionInterval', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', @@ -4203,78 +4496,57 @@ export const l1StandardBridgeABI = [ name: 'version', outputs: [{ name: '', internalType: 'string', type: 'string' }], }, - { stateMutability: 'payable', type: 'receive' }, ] as const /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) */ -export const l1StandardBridgeAddress = { - 1: '0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1', +export const l2OutputOracleAddress = { + 1: '0xdfe97868233d1aa22e815a266982f2cf17685a27', + 5: '0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0', } as const /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) */ -export const l1StandardBridgeConfig = { - address: l1StandardBridgeAddress, - abi: l1StandardBridgeABI, +export const l2OutputOracleConfig = { + address: l2OutputOracleAddress, + abi: l2OutputOracleABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// L1StandardBridge_goerli +// L2StandardBridge ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) */ -export const l1StandardBridgeGoerliABI = [ - { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, +export const l2StandardBridgeABI = [ { - type: 'event', - anonymous: false, + stateMutability: 'nonpayable', + type: 'constructor', inputs: [ { - name: 'localToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'remoteToken', - internalType: 'address', + name: '_otherBridge', + internalType: 'address payable', type: 'address', - indexed: true, - }, - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: false }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, }, ], - name: 'ERC20BridgeFinalized', }, { type: 'event', anonymous: false, inputs: [ { - name: 'localToken', + name: 'l1Token', internalType: 'address', type: 'address', indexed: true, }, { - name: 'remoteToken', + name: 'l2Token', internalType: 'address', type: 'address', indexed: true, @@ -4294,20 +4566,20 @@ export const l1StandardBridgeGoerliABI = [ indexed: false, }, ], - name: 'ERC20BridgeInitiated', + name: 'DepositFinalized', }, { type: 'event', anonymous: false, inputs: [ { - name: 'l1Token', + name: 'localToken', internalType: 'address', type: 'address', indexed: true, }, { - name: 'l2Token', + name: 'remoteToken', internalType: 'address', type: 'address', indexed: true, @@ -4327,20 +4599,20 @@ export const l1StandardBridgeGoerliABI = [ indexed: false, }, ], - name: 'ERC20DepositInitiated', + name: 'ERC20BridgeFinalized', }, { type: 'event', anonymous: false, inputs: [ { - name: 'l1Token', + name: 'localToken', internalType: 'address', type: 'address', indexed: true, }, { - name: 'l2Token', + name: 'remoteToken', internalType: 'address', type: 'address', indexed: true, @@ -4360,7 +4632,7 @@ export const l1StandardBridgeGoerliABI = [ indexed: false, }, ], - name: 'ERC20WithdrawalFinalized', + name: 'ERC20BridgeInitiated', }, { type: 'event', @@ -4408,29 +4680,20 @@ export const l1StandardBridgeGoerliABI = [ type: 'event', anonymous: false, inputs: [ - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, + name: 'l1Token', + internalType: 'address', + type: 'address', + indexed: true, }, { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, + name: 'l2Token', + internalType: 'address', + type: 'address', + indexed: true, }, - ], - name: 'ETHDepositInitiated', - }, - { - type: 'event', - anonymous: false, - inputs: [ { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, + { name: 'to', internalType: 'address', type: 'address', indexed: false }, { name: 'amount', internalType: 'uint256', @@ -4444,15 +4707,16 @@ export const l1StandardBridgeGoerliABI = [ indexed: false, }, ], - name: 'ETHWithdrawalFinalized', + name: 'WithdrawalInitiated', }, { - type: 'event', - anonymous: false, - inputs: [ - { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'OTHER_BRIDGE', + outputs: [ + { name: '', internalType: 'contract StandardBridge', type: 'address' }, ], - name: 'Initialized', }, { stateMutability: 'nonpayable', @@ -4503,59 +4767,11 @@ export const l1StandardBridgeGoerliABI = [ outputs: [], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', inputs: [ - { name: '_l1Token', internalType: 'address', type: 'address' }, - { name: '_l2Token', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'depositERC20', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_l1Token', internalType: 'address', type: 'address' }, - { name: '_l2Token', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'depositERC20To', - outputs: [], - }, - { - stateMutability: 'payable', - type: 'function', - inputs: [ - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'depositETH', - outputs: [], - }, - { - stateMutability: 'payable', - type: 'function', - inputs: [ - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'depositETHTo', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [ - { name: '', internalType: 'address', type: 'address' }, - { name: '', internalType: 'address', type: 'address' }, + { name: '', internalType: 'address', type: 'address' }, + { name: '', internalType: 'address', type: 'address' }, ], name: 'deposits', outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], @@ -4587,7 +4803,7 @@ export const l1StandardBridgeGoerliABI = [ outputs: [], }, { - stateMutability: 'nonpayable', + stateMutability: 'payable', type: 'function', inputs: [ { name: '_l1Token', internalType: 'address', type: 'address' }, @@ -4597,39 +4813,14 @@ export const l1StandardBridgeGoerliABI = [ { name: '_amount', internalType: 'uint256', type: 'uint256' }, { name: '_extraData', internalType: 'bytes', type: 'bytes' }, ], - name: 'finalizeERC20Withdrawal', - outputs: [], - }, - { - stateMutability: 'payable', - type: 'function', - inputs: [ - { name: '_from', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'finalizeETHWithdrawal', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { - name: '_messenger', - internalType: 'contract CrossDomainMessenger', - type: 'address', - }, - ], - name: 'initialize', + name: 'finalizeDeposit', outputs: [], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'l2TokenBridge', + name: 'l1TokenBridge', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { @@ -4649,108 +4840,85 @@ export const l1StandardBridgeGoerliABI = [ stateMutability: 'view', type: 'function', inputs: [], - name: 'otherBridge', - outputs: [ - { name: '', internalType: 'contract StandardBridge', type: 'address' }, + name: 'version', + outputs: [{ name: '', internalType: 'string', type: 'string' }], + }, + { + stateMutability: 'payable', + type: 'function', + inputs: [ + { name: '_l2Token', internalType: 'address', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, ], + name: 'withdraw', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'payable', type: 'function', - inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + inputs: [ + { name: '_l2Token', internalType: 'address', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, + { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + ], + name: 'withdrawTo', + outputs: [], }, { stateMutability: 'payable', type: 'receive' }, ] as const /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) */ -export const l1StandardBridgeGoerliAddress = { - 5: '0x636Af16bf2f682dD3109e60102b8E1A089FedAa8', +export const l2StandardBridgeAddress = { + 420: '0x4200000000000000000000000000000000000010', } as const /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) */ -export const l1StandardBridgeGoerliConfig = { - address: l1StandardBridgeGoerliAddress, - abi: l1StandardBridgeGoerliABI, +export const l2StandardBridgeConfig = { + address: l2StandardBridgeAddress, + abi: l2StandardBridgeABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// L2CrossDomainMessenger +// L2ToL1MessagePasser ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000016) */ -export const l2CrossDomainMessengerABI = [ - { - stateMutability: 'nonpayable', - type: 'constructor', - inputs: [ - { - name: '_l1CrossDomainMessenger', - internalType: 'address', - type: 'address', - }, - ], - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'msgHash', - internalType: 'bytes32', - type: 'bytes32', - indexed: true, - }, - ], - name: 'FailedRelayedMessage', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, - ], - name: 'Initialized', - }, +export const l2ToL1MessagePasserABI = [ + { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, { type: 'event', anonymous: false, inputs: [ { - name: 'msgHash', - internalType: 'bytes32', - type: 'bytes32', + name: 'nonce', + internalType: 'uint256', + type: 'uint256', indexed: true, }, - ], - name: 'RelayedMessage', - }, - { - type: 'event', - anonymous: false, - inputs: [ { - name: 'target', + name: 'sender', internalType: 'address', type: 'address', indexed: true, }, { - name: 'sender', + name: 'target', internalType: 'address', type: 'address', - indexed: false, + indexed: true, }, - { name: 'message', internalType: 'bytes', type: 'bytes', indexed: false }, { - name: 'messageNonce', + name: 'value', internalType: 'uint256', type: 'uint256', indexed: false, @@ -4761,27 +4929,28 @@ export const l2CrossDomainMessengerABI = [ type: 'uint256', indexed: false, }, + { name: 'data', internalType: 'bytes', type: 'bytes', indexed: false }, + { + name: 'withdrawalHash', + internalType: 'bytes32', + type: 'bytes32', + indexed: false, + }, ], - name: 'SentMessage', + name: 'MessagePassed', }, { type: 'event', anonymous: false, inputs: [ { - name: 'sender', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'value', + name: 'amount', internalType: 'uint256', type: 'uint256', - indexed: false, + indexed: true, }, ], - name: 'SentMessageExtension1', + name: 'WithdrawerBalanceBurnt', }, { stateMutability: 'view', @@ -4791,178 +4960,211 @@ export const l2CrossDomainMessengerABI = [ outputs: [{ name: '', internalType: 'uint16', type: 'uint16' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', inputs: [], - name: 'MIN_GAS_CALLDATA_OVERHEAD', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + name: 'burn', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'payable', type: 'function', - inputs: [], - name: 'MIN_GAS_DYNAMIC_OVERHEAD_DENOMINATOR', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + inputs: [ + { name: '_target', internalType: 'address', type: 'address' }, + { name: '_gasLimit', internalType: 'uint256', type: 'uint256' }, + { name: '_data', internalType: 'bytes', type: 'bytes' }, + ], + name: 'initiateWithdrawal', + outputs: [], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'MIN_GAS_DYNAMIC_OVERHEAD_NUMERATOR', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + name: 'messageNonce', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', - inputs: [], - name: 'OTHER_MESSENGER', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'sentMessages', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'RELAY_CALL_OVERHEAD', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + name: 'version', + outputs: [{ name: '', internalType: 'string', type: 'string' }], }, + { stateMutability: 'payable', type: 'receive' }, +] as const + +/** + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000016) + */ +export const l2ToL1MessagePasserAddress = { + 420: '0x4200000000000000000000000000000000000016', +} as const + +/** + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000016) + */ +export const l2ToL1MessagePasserConfig = { + address: l2ToL1MessagePasserAddress, + abi: l2ToL1MessagePasserABI, +} as const + +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// MintManager +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/** + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x5C4e7Ba1E219E47948e6e3F55019A647bA501005) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76) + */ +export const mintManagerABI = [ { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'RELAY_CONSTANT_OVERHEAD', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'RELAY_GAS_CHECK_BUFFER', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'RELAY_RESERVED_GAS', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + stateMutability: 'nonpayable', + type: 'constructor', + inputs: [ + { name: '_upgrader', internalType: 'address', type: 'address' }, + { name: '_governanceToken', internalType: 'address', type: 'address' }, + ], }, { - stateMutability: 'pure', - type: 'function', + type: 'event', + anonymous: false, inputs: [ - { name: '_message', internalType: 'bytes', type: 'bytes' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { + name: 'previousOwner', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'newOwner', + internalType: 'address', + type: 'address', + indexed: true, + }, ], - name: 'baseGas', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + name: 'OwnershipTransferred', }, { stateMutability: 'view', type: 'function', - inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - name: 'failedMessages', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', inputs: [], - name: 'initialize', - outputs: [], + name: 'DENOMINATOR', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'l1CrossDomainMessenger', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'MINT_CAP', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'messageNonce', + name: 'MINT_PERIOD', outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { - stateMutability: 'payable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_nonce', internalType: 'uint256', type: 'uint256' }, - { name: '_sender', internalType: 'address', type: 'address' }, - { name: '_target', internalType: 'address', type: 'address' }, - { name: '_value', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint256', type: 'uint256' }, - { name: '_message', internalType: 'bytes', type: 'bytes' }, + inputs: [], + name: 'governanceToken', + outputs: [ + { name: '', internalType: 'contract GovernanceToken', type: 'address' }, ], - name: 'relayMessage', - outputs: [], }, { - stateMutability: 'payable', + stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_target', internalType: 'address', type: 'address' }, - { name: '_message', internalType: 'bytes', type: 'bytes' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, + { name: '_account', internalType: 'address', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, ], - name: 'sendMessage', + name: 'mint', outputs: [], }, { stateMutability: 'view', type: 'function', - inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - name: 'successfulMessages', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + inputs: [], + name: 'mintPermittedAfter', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + name: 'owner', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', inputs: [], - name: 'xDomainMessageSender', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'renounceOwnership', + outputs: [], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], + name: 'transferOwnership', + outputs: [], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { name: '_newMintManager', internalType: 'address', type: 'address' }, + ], + name: 'upgrade', + outputs: [], }, ] as const /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x5C4e7Ba1E219E47948e6e3F55019A647bA501005) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76) */ -export const l2CrossDomainMessengerAddress = { - 420: '0x4200000000000000000000000000000000000007', +export const mintManagerAddress = { + 10: '0x5C4e7Ba1E219E47948e6e3F55019A647bA501005', + 420: '0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76', } as const /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x5C4e7Ba1E219E47948e6e3F55019A647bA501005) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76) */ -export const l2CrossDomainMessengerConfig = { - address: l2CrossDomainMessengerAddress, - abi: l2CrossDomainMessengerABI, +export const mintManagerConfig = { + address: mintManagerAddress, + abi: mintManagerABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// L2ERC721Bridge +// OptimismMintableERC20Factory ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000014) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000014) + * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000012) */ -export const l2Erc721BridgeABI = [ +export const optimismMintableErc20FactoryABI = [ + { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, { - stateMutability: 'nonpayable', - type: 'constructor', + type: 'event', + anonymous: false, inputs: [ - { name: '_messenger', internalType: 'address', type: 'address' }, - { name: '_otherBridge', internalType: 'address', type: 'address' }, + { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, ], + name: 'Initialized', }, { type: 'event', @@ -4980,116 +5182,81 @@ export const l2Erc721BridgeABI = [ type: 'address', indexed: true, }, - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: false }, - { - name: 'tokenId', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', + name: 'deployer', + internalType: 'address', + type: 'address', indexed: false, }, ], - name: 'ERC721BridgeFinalized', + name: 'OptimismMintableERC20Created', }, { type: 'event', anonymous: false, inputs: [ { - name: 'localToken', + name: 'remoteToken', internalType: 'address', type: 'address', indexed: true, }, { - name: 'remoteToken', + name: 'localToken', internalType: 'address', type: 'address', indexed: true, }, - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: false }, - { - name: 'tokenId', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, - }, ], - name: 'ERC721BridgeInitiated', + name: 'StandardL2TokenCreated', }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'bridgeERC721', - outputs: [], + inputs: [], + name: 'bridge', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, ], - name: 'bridgeERC721To', - outputs: [], + name: 'createOptimismMintableERC20', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_from', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_tokenId', internalType: 'uint256', type: 'uint256' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, + { name: '_decimals', internalType: 'uint8', type: 'uint8' }, ], - name: 'finalizeBridgeERC721', - outputs: [], + name: 'createOptimismMintableERC20WithDecimals', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'messenger', - outputs: [ - { - name: '', - internalType: 'contract CrossDomainMessenger', - type: 'address', - }, + inputs: [ + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, ], + name: 'createStandardL2Token', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'otherBridge', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + inputs: [{ name: '_bridge', internalType: 'address', type: 'address' }], + name: 'initialize', + outputs: [], }, { stateMutability: 'view', @@ -5101,52 +5268,29 @@ export const l2Erc721BridgeABI = [ ] as const /** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000014) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000014) + * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000012) */ -export const l2Erc721BridgeAddress = { - 10: '0x4200000000000000000000000000000000000014', - 420: '0x4200000000000000000000000000000000000014', +export const optimismMintableErc20FactoryAddress = { + 1: '0x4200000000000000000000000000000000000012', } as const /** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000014) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000014) + * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000012) */ -export const l2Erc721BridgeConfig = { - address: l2Erc721BridgeAddress, - abi: l2Erc721BridgeABI, +export const optimismMintableErc20FactoryConfig = { + address: optimismMintableErc20FactoryAddress, + abi: optimismMintableErc20FactoryABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// L2OutputOracle +// OptimismMintableERC20Factory_goerli ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) + * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000012) */ -export const l2OutputOracleABI = [ - { - stateMutability: 'nonpayable', - type: 'constructor', - inputs: [ - { name: '_submissionInterval', internalType: 'uint256', type: 'uint256' }, - { name: '_l2BlockTime', internalType: 'uint256', type: 'uint256' }, - { - name: '_startingBlockNumber', - internalType: 'uint256', - type: 'uint256', - }, - { name: '_startingTimestamp', internalType: 'uint256', type: 'uint256' }, - { name: '_proposer', internalType: 'address', type: 'address' }, - { name: '_challenger', internalType: 'address', type: 'address' }, - { - name: '_finalizationPeriodSeconds', - internalType: 'uint256', - type: 'uint256', - }, - ], - }, +export const optimismMintableErc20FactoryGoerliABI = [ + { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, { type: 'event', anonymous: false, @@ -5160,219 +5304,298 @@ export const l2OutputOracleABI = [ anonymous: false, inputs: [ { - name: 'outputRoot', - internalType: 'bytes32', - type: 'bytes32', - indexed: true, - }, - { - name: 'l2OutputIndex', - internalType: 'uint256', - type: 'uint256', + name: 'localToken', + internalType: 'address', + type: 'address', indexed: true, }, { - name: 'l2BlockNumber', - internalType: 'uint256', - type: 'uint256', + name: 'remoteToken', + internalType: 'address', + type: 'address', indexed: true, }, { - name: 'l1Timestamp', - internalType: 'uint256', - type: 'uint256', + name: 'deployer', + internalType: 'address', + type: 'address', indexed: false, }, ], - name: 'OutputProposed', + name: 'OptimismMintableERC20Created', }, { type: 'event', anonymous: false, inputs: [ { - name: 'prevNextOutputIndex', - internalType: 'uint256', - type: 'uint256', + name: 'remoteToken', + internalType: 'address', + type: 'address', indexed: true, }, { - name: 'newNextOutputIndex', - internalType: 'uint256', - type: 'uint256', + name: 'localToken', + internalType: 'address', + type: 'address', indexed: true, }, ], - name: 'OutputsDeleted', + name: 'StandardL2TokenCreated', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'CHALLENGER', + name: 'bridge', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'FINALIZATION_PERIOD_SECONDS', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + inputs: [ + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, + ], + name: 'createOptimismMintableERC20', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'L2_BLOCK_TIME', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + inputs: [ + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, + { name: '_decimals', internalType: 'uint8', type: 'uint8' }, + ], + name: 'createOptimismMintableERC20WithDecimals', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'PROPOSER', + inputs: [ + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, + ], + name: 'createStandardL2Token', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'SUBMISSION_INTERVAL', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + inputs: [{ name: '_bridge', internalType: 'address', type: 'address' }], + name: 'initialize', + outputs: [], }, { stateMutability: 'view', type: 'function', - inputs: [ - { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, - ], - name: 'computeL2Timestamp', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + inputs: [], + name: 'version', + outputs: [{ name: '', internalType: 'string', type: 'string' }], }, +] as const + +/** + * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000012) + */ +export const optimismMintableErc20FactoryGoerliAddress = { + 5: '0x4200000000000000000000000000000000000012', +} as const + +/** + * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000012) + */ +export const optimismMintableErc20FactoryGoerliConfig = { + address: optimismMintableErc20FactoryGoerliAddress, + abi: optimismMintableErc20FactoryGoerliABI, +} as const + +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// OptimismMintableERC20Factory_optimism-goerli +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/** + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000012) + */ +export const optimismMintableErc20FactoryOptimismGoerliABI = [ { stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, - ], - name: 'deleteL2Outputs', - outputs: [], + type: 'constructor', + inputs: [{ name: '_bridge', internalType: 'address', type: 'address' }], }, { - stateMutability: 'view', - type: 'function', + type: 'event', + anonymous: false, inputs: [ - { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, - ], - name: 'getL2Output', - outputs: [ { - name: '', - internalType: 'struct Types.OutputProposal', - type: 'tuple', - components: [ - { name: 'outputRoot', internalType: 'bytes32', type: 'bytes32' }, - { name: 'timestamp', internalType: 'uint128', type: 'uint128' }, - { name: 'l2BlockNumber', internalType: 'uint128', type: 'uint128' }, - ], + name: 'localToken', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'remoteToken', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'deployer', + internalType: 'address', + type: 'address', + indexed: false, }, ], + name: 'OptimismMintableERC20Created', }, { - stateMutability: 'view', - type: 'function', + type: 'event', + anonymous: false, inputs: [ - { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, - ], - name: 'getL2OutputAfter', - outputs: [ { - name: '', - internalType: 'struct Types.OutputProposal', - type: 'tuple', - components: [ - { name: 'outputRoot', internalType: 'bytes32', type: 'bytes32' }, - { name: 'timestamp', internalType: 'uint128', type: 'uint128' }, - { name: 'l2BlockNumber', internalType: 'uint128', type: 'uint128' }, - ], + name: 'remoteToken', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'localToken', + internalType: 'address', + type: 'address', + indexed: true, }, ], + name: 'StandardL2TokenCreated', }, { stateMutability: 'view', type: 'function', - inputs: [ - { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, - ], - name: 'getL2OutputIndexAfter', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + inputs: [], + name: 'BRIDGE', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { - name: '_startingBlockNumber', - internalType: 'uint256', - type: 'uint256', - }, - { name: '_startingTimestamp', internalType: 'uint256', type: 'uint256' }, + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, ], - name: 'initialize', - outputs: [], + name: 'createOptimismMintableERC20', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'latestBlockNumber', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + inputs: [ + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, + ], + name: 'createStandardL2Token', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'latestOutputIndex', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'version', + outputs: [{ name: '', internalType: 'string', type: 'string' }], }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'nextBlockNumber', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], +] as const + +/** + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000012) + */ +export const optimismMintableErc20FactoryOptimismGoerliAddress = { + 420: '0x4200000000000000000000000000000000000012', +} as const + +/** + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000012) + */ +export const optimismMintableErc20FactoryOptimismGoerliConfig = { + address: optimismMintableErc20FactoryOptimismGoerliAddress, + abi: optimismMintableErc20FactoryOptimismGoerliABI, +} as const + +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// OptimismMintableERC721Factory +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/** + * [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000017) + */ +export const optimismMintableErc721FactoryABI = [ + { + stateMutability: 'nonpayable', + type: 'constructor', + inputs: [ + { name: '_bridge', internalType: 'address', type: 'address' }, + { name: '_remoteChainId', internalType: 'uint256', type: 'uint256' }, + ], + }, + { + type: 'event', + anonymous: false, + inputs: [ + { + name: 'localToken', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'remoteToken', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'deployer', + internalType: 'address', + type: 'address', + indexed: false, + }, + ], + name: 'OptimismMintableERC721Created', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'nextOutputIndex', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'bridge', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'payable', + stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_outputRoot', internalType: 'bytes32', type: 'bytes32' }, - { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, - { name: '_l1BlockHash', internalType: 'bytes32', type: 'bytes32' }, - { name: '_l1BlockNumber', internalType: 'uint256', type: 'uint256' }, + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, ], - name: 'proposeL2Output', - outputs: [], + name: 'createOptimismMintableERC721', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', - inputs: [], - name: 'startingBlockNumber', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + inputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'isOptimismMintableERC721', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'startingTimestamp', + name: 'remoteChainId', outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { @@ -5385,270 +5608,407 @@ export const l2OutputOracleABI = [ ] as const /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) + * [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000017) */ -export const l2OutputOracleAddress = { - 1: '0xdfe97868233d1aa22e815a266982f2cf17685a27', +export const optimismMintableErc721FactoryAddress = { + 10: '0x4200000000000000000000000000000000000017', } as const /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) + * [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000017) */ -export const l2OutputOracleConfig = { - address: l2OutputOracleAddress, - abi: l2OutputOracleABI, +export const optimismMintableErc721FactoryConfig = { + address: optimismMintableErc721FactoryAddress, + abi: optimismMintableErc721FactoryABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// L2OutputOracle_goerli +// OptimismMintableERC721Factory_optimism-goerli ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000017) */ -export const l2OutputOracleGoerliABI = [ +export const optimismMintableErc721FactoryOptimismGoerliABI = [ { stateMutability: 'nonpayable', type: 'constructor', inputs: [ - { name: '_submissionInterval', internalType: 'uint256', type: 'uint256' }, - { name: '_l2BlockTime', internalType: 'uint256', type: 'uint256' }, - { - name: '_finalizationPeriodSeconds', - internalType: 'uint256', - type: 'uint256', - }, - ], - }, - { - type: 'event', - anonymous: false, - inputs: [ - { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, + { name: '_bridge', internalType: 'address', type: 'address' }, + { name: '_remoteChainId', internalType: 'uint256', type: 'uint256' }, ], - name: 'Initialized', }, { type: 'event', anonymous: false, inputs: [ { - name: 'outputRoot', - internalType: 'bytes32', - type: 'bytes32', - indexed: true, - }, - { - name: 'l2OutputIndex', - internalType: 'uint256', - type: 'uint256', + name: 'localToken', + internalType: 'address', + type: 'address', indexed: true, }, { - name: 'l2BlockNumber', - internalType: 'uint256', - type: 'uint256', + name: 'remoteToken', + internalType: 'address', + type: 'address', indexed: true, }, { - name: 'l1Timestamp', - internalType: 'uint256', - type: 'uint256', + name: 'deployer', + internalType: 'address', + type: 'address', indexed: false, }, ], - name: 'OutputProposed', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'prevNextOutputIndex', - internalType: 'uint256', - type: 'uint256', - indexed: true, - }, - { - name: 'newNextOutputIndex', - internalType: 'uint256', - type: 'uint256', - indexed: true, - }, - ], - name: 'OutputsDeleted', + name: 'OptimismMintableERC721Created', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'challenger', + name: 'BRIDGE', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', - inputs: [ - { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, - ], - name: 'computeL2Timestamp', + inputs: [], + name: 'REMOTE_CHAIN_ID', outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, + { name: '_remoteToken', internalType: 'address', type: 'address' }, + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, ], - name: 'deleteL2Outputs', - outputs: [], + name: 'createOptimismMintableERC721', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', - inputs: [], - name: 'finalizationPeriodSeconds', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + inputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'isOptimismMintableERC721', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { stateMutability: 'view', type: 'function', + inputs: [], + name: 'version', + outputs: [{ name: '', internalType: 'string', type: 'string' }], + }, +] as const + +/** + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000017) + */ +export const optimismMintableErc721FactoryOptimismGoerliAddress = { + 420: '0x4200000000000000000000000000000000000017', +} as const + +/** + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000017) + */ +export const optimismMintableErc721FactoryOptimismGoerliConfig = { + address: optimismMintableErc721FactoryOptimismGoerliAddress, + abi: optimismMintableErc721FactoryOptimismGoerliABI, +} as const + +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// OptimismPortal +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/** + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) + */ +export const optimismPortalABI = [ + { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, + { + type: 'event', + anonymous: false, inputs: [ - { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, - ], - name: 'getL2Output', - outputs: [ - { - name: '', - internalType: 'struct Types.OutputProposal', - type: 'tuple', - components: [ - { name: 'outputRoot', internalType: 'bytes32', type: 'bytes32' }, - { name: 'timestamp', internalType: 'uint128', type: 'uint128' }, - { name: 'l2BlockNumber', internalType: 'uint128', type: 'uint128' }, - ], - }, + { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, ], + name: 'Initialized', }, { - stateMutability: 'view', - type: 'function', + type: 'event', + anonymous: false, inputs: [ - { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, - ], - name: 'getL2OutputAfter', - outputs: [ { - name: '', - internalType: 'struct Types.OutputProposal', - type: 'tuple', - components: [ - { name: 'outputRoot', internalType: 'bytes32', type: 'bytes32' }, - { name: 'timestamp', internalType: 'uint128', type: 'uint128' }, - { name: 'l2BlockNumber', internalType: 'uint128', type: 'uint128' }, - ], + name: 'account', + internalType: 'address', + type: 'address', + indexed: false, }, ], + name: 'Paused', }, { - stateMutability: 'view', - type: 'function', + type: 'event', + anonymous: false, inputs: [ - { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, + { name: 'from', internalType: 'address', type: 'address', indexed: true }, + { name: 'to', internalType: 'address', type: 'address', indexed: true }, + { + name: 'version', + internalType: 'uint256', + type: 'uint256', + indexed: true, + }, + { + name: 'opaqueData', + internalType: 'bytes', + type: 'bytes', + indexed: false, + }, ], - name: 'getL2OutputIndexAfter', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'TransactionDeposited', + }, + { + type: 'event', + anonymous: false, + inputs: [ + { + name: 'account', + internalType: 'address', + type: 'address', + indexed: false, + }, + ], + name: 'Unpaused', + }, + { + type: 'event', + anonymous: false, + inputs: [ + { + name: 'withdrawalHash', + internalType: 'bytes32', + type: 'bytes32', + indexed: true, + }, + { name: 'success', internalType: 'bool', type: 'bool', indexed: false }, + ], + name: 'WithdrawalFinalized', + }, + { + type: 'event', + anonymous: false, + inputs: [ + { + name: 'withdrawalHash', + internalType: 'bytes32', + type: 'bytes32', + indexed: true, + }, + { name: 'from', internalType: 'address', type: 'address', indexed: true }, + { name: 'to', internalType: 'address', type: 'address', indexed: true }, + ], + name: 'WithdrawalProven', + }, + { + stateMutability: 'payable', + type: 'function', + inputs: [ + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_value', internalType: 'uint256', type: 'uint256' }, + { name: '_gasLimit', internalType: 'uint64', type: 'uint64' }, + { name: '_isCreation', internalType: 'bool', type: 'bool' }, + { name: '_data', internalType: 'bytes', type: 'bytes' }, + ], + name: 'depositTransaction', + outputs: [], + }, + { + stateMutability: 'payable', + type: 'function', + inputs: [], + name: 'donateETH', + outputs: [], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ { - name: '_startingBlockNumber', - internalType: 'uint256', - type: 'uint256', + name: '_tx', + internalType: 'struct Types.WithdrawalTransaction', + type: 'tuple', + components: [ + { name: 'nonce', internalType: 'uint256', type: 'uint256' }, + { name: 'sender', internalType: 'address', type: 'address' }, + { name: 'target', internalType: 'address', type: 'address' }, + { name: 'value', internalType: 'uint256', type: 'uint256' }, + { name: 'gasLimit', internalType: 'uint256', type: 'uint256' }, + { name: 'data', internalType: 'bytes', type: 'bytes' }, + ], }, - { name: '_startingTimestamp', internalType: 'uint256', type: 'uint256' }, - { name: '_proposer', internalType: 'address', type: 'address' }, - { name: '_challenger', internalType: 'address', type: 'address' }, ], - name: 'initialize', + name: 'finalizeWithdrawalTransaction', outputs: [], }, { stateMutability: 'view', type: 'function', - inputs: [], - name: 'l2BlockTime', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'finalizedWithdrawals', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'latestBlockNumber', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'guardian', + outputs: [{ name: '', internalType: 'address', type: 'address' }], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { + name: '_l2Oracle', + internalType: 'contract L2OutputOracle', + type: 'address', + }, + { name: '_guardian', internalType: 'address', type: 'address' }, + { + name: '_systemConfig', + internalType: 'contract SystemConfig', + type: 'address', + }, + { name: '_paused', internalType: 'bool', type: 'bool' }, + ], + name: 'initialize', + outputs: [], }, { stateMutability: 'view', type: 'function', - inputs: [], - name: 'latestOutputIndex', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + inputs: [ + { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, + ], + name: 'isOutputFinalized', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'nextBlockNumber', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'l2Oracle', + outputs: [ + { name: '', internalType: 'contract L2OutputOracle', type: 'address' }, + ], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'nextOutputIndex', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'l2Sender', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'payable', + stateMutability: 'pure', type: 'function', - inputs: [ - { name: '_outputRoot', internalType: 'bytes32', type: 'bytes32' }, - { name: '_l2BlockNumber', internalType: 'uint256', type: 'uint256' }, - { name: '_l1BlockHash', internalType: 'bytes32', type: 'bytes32' }, - { name: '_l1BlockNumber', internalType: 'uint256', type: 'uint256' }, + inputs: [{ name: '_byteCount', internalType: 'uint64', type: 'uint64' }], + name: 'minimumGasLimit', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'params', + outputs: [ + { name: 'prevBaseFee', internalType: 'uint128', type: 'uint128' }, + { name: 'prevBoughtGas', internalType: 'uint64', type: 'uint64' }, + { name: 'prevBlockNum', internalType: 'uint64', type: 'uint64' }, ], - name: 'proposeL2Output', + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [], + name: 'pause', outputs: [], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'proposer', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'paused', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { + name: '_tx', + internalType: 'struct Types.WithdrawalTransaction', + type: 'tuple', + components: [ + { name: 'nonce', internalType: 'uint256', type: 'uint256' }, + { name: 'sender', internalType: 'address', type: 'address' }, + { name: 'target', internalType: 'address', type: 'address' }, + { name: 'value', internalType: 'uint256', type: 'uint256' }, + { name: 'gasLimit', internalType: 'uint256', type: 'uint256' }, + { name: 'data', internalType: 'bytes', type: 'bytes' }, + ], + }, + { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, + { + name: '_outputRootProof', + internalType: 'struct Types.OutputRootProof', + type: 'tuple', + components: [ + { name: 'version', internalType: 'bytes32', type: 'bytes32' }, + { name: 'stateRoot', internalType: 'bytes32', type: 'bytes32' }, + { + name: 'messagePasserStorageRoot', + internalType: 'bytes32', + type: 'bytes32', + }, + { name: 'latestBlockhash', internalType: 'bytes32', type: 'bytes32' }, + ], + }, + { name: '_withdrawalProof', internalType: 'bytes[]', type: 'bytes[]' }, + ], + name: 'proveWithdrawalTransaction', + outputs: [], }, { stateMutability: 'view', type: 'function', - inputs: [], - name: 'startingBlockNumber', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'provenWithdrawals', + outputs: [ + { name: 'outputRoot', internalType: 'bytes32', type: 'bytes32' }, + { name: 'timestamp', internalType: 'uint128', type: 'uint128' }, + { name: 'l2OutputIndex', internalType: 'uint128', type: 'uint128' }, + ], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'startingTimestamp', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'systemConfig', + outputs: [ + { name: '', internalType: 'contract SystemConfig', type: 'address' }, + ], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', inputs: [], - name: 'submissionInterval', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'unpause', + outputs: [], }, { stateMutability: 'view', @@ -5657,161 +6017,107 @@ export const l2OutputOracleGoerliABI = [ name: 'version', outputs: [{ name: '', internalType: 'string', type: 'string' }], }, + { stateMutability: 'payable', type: 'receive' }, ] as const /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) */ -export const l2OutputOracleGoerliAddress = { - 5: '0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0', +export const optimismPortalAddress = { + 1: '0xbEb5Fc579115071764c7423A4f12eDde41f106Ed', + 5: '0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383', } as const /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) */ -export const l2OutputOracleGoerliConfig = { - address: l2OutputOracleGoerliAddress, - abi: l2OutputOracleGoerliABI, +export const optimismPortalConfig = { + address: optimismPortalAddress, + abi: optimismPortalABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// L2StandardBridge +// Optimist ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) */ -export const l2StandardBridgeABI = [ +export const optimistABI = [ { stateMutability: 'nonpayable', type: 'constructor', inputs: [ + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, + { name: '_baseURIAttestor', internalType: 'address', type: 'address' }, { - name: '_otherBridge', - internalType: 'address payable', - type: 'address', - }, - ], - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'l1Token', - internalType: 'address', + name: '_attestationStation', + internalType: 'contract AttestationStation', type: 'address', - indexed: true, }, { - name: 'l2Token', - internalType: 'address', + name: '_optimistAllowlist', + internalType: 'contract OptimistAllowlist', type: 'address', - indexed: true, - }, - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: false }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, }, ], - name: 'DepositFinalized', }, { type: 'event', anonymous: false, inputs: [ { - name: 'localToken', + name: 'owner', internalType: 'address', type: 'address', indexed: true, }, { - name: 'remoteToken', + name: 'approved', internalType: 'address', type: 'address', indexed: true, }, - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: false }, { - name: 'amount', + name: 'tokenId', internalType: 'uint256', type: 'uint256', - indexed: false, - }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, + indexed: true, }, ], - name: 'ERC20BridgeFinalized', + name: 'Approval', }, { type: 'event', anonymous: false, inputs: [ { - name: 'localToken', + name: 'owner', internalType: 'address', type: 'address', indexed: true, }, { - name: 'remoteToken', + name: 'operator', internalType: 'address', type: 'address', indexed: true, }, - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: false }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, - }, + { name: 'approved', internalType: 'bool', type: 'bool', indexed: false }, ], - name: 'ERC20BridgeInitiated', + name: 'ApprovalForAll', }, { type: 'event', anonymous: false, inputs: [ - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, - }, + { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, ], - name: 'ETHBridgeFinalized', + name: 'Initialized', }, { type: 'event', @@ -5820,334 +6126,207 @@ export const l2StandardBridgeABI = [ { name: 'from', internalType: 'address', type: 'address', indexed: true }, { name: 'to', internalType: 'address', type: 'address', indexed: true }, { - name: 'amount', + name: 'tokenId', internalType: 'uint256', type: 'uint256', - indexed: false, - }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, + indexed: true, }, ], - name: 'ETHBridgeInitiated', + name: 'Transfer', }, { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'l1Token', - internalType: 'address', - type: 'address', - indexed: true, - }, + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'ATTESTATION_STATION', + outputs: [ { - name: 'l2Token', - internalType: 'address', + name: '', + internalType: 'contract AttestationStation', type: 'address', - indexed: true, - }, - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: false }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - { - name: 'extraData', - internalType: 'bytes', - type: 'bytes', - indexed: false, }, ], - name: 'WithdrawalInitiated', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'OTHER_BRIDGE', - outputs: [ - { name: '', internalType: 'contract StandardBridge', type: 'address' }, - ], + name: 'BASE_URI_ATTESTATION_KEY', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'bridgeERC20', - outputs: [], + inputs: [], + name: 'BASE_URI_ATTESTOR', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + inputs: [], + name: 'OPTIMIST_ALLOWLIST', + outputs: [ + { name: '', internalType: 'contract OptimistAllowlist', type: 'address' }, ], - name: 'bridgeERC20To', - outputs: [], }, { - stateMutability: 'payable', + stateMutability: 'pure', type: 'function', inputs: [ - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { name: '', internalType: 'address', type: 'address' }, + { name: '', internalType: 'uint256', type: 'uint256' }, ], - name: 'bridgeETH', + name: 'approve', outputs: [], }, { - stateMutability: 'payable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'bridgeETHTo', - outputs: [], + inputs: [{ name: 'owner', internalType: 'address', type: 'address' }], + name: 'balanceOf', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', - inputs: [ - { name: '', internalType: 'address', type: 'address' }, - { name: '', internalType: 'address', type: 'address' }, - ], - name: 'deposits', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + inputs: [], + name: 'baseURI', + outputs: [{ name: '', internalType: 'string', type: 'string' }], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [ - { name: '_localToken', internalType: 'address', type: 'address' }, - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_from', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'finalizeBridgeERC20', + inputs: [{ name: 'tokenId', internalType: 'uint256', type: 'uint256' }], + name: 'burn', outputs: [], }, { - stateMutability: 'payable', + stateMutability: 'view', + type: 'function', + inputs: [{ name: 'tokenId', internalType: 'uint256', type: 'uint256' }], + name: 'getApproved', + outputs: [{ name: '', internalType: 'address', type: 'address' }], + }, + { + stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_from', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_symbol', internalType: 'string', type: 'string' }, ], - name: 'finalizeBridgeETH', + name: 'initialize', outputs: [], }, { - stateMutability: 'payable', + stateMutability: 'view', type: 'function', inputs: [ - { name: '_l1Token', internalType: 'address', type: 'address' }, - { name: '_l2Token', internalType: 'address', type: 'address' }, - { name: '_from', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { name: 'owner', internalType: 'address', type: 'address' }, + { name: 'operator', internalType: 'address', type: 'address' }, ], - name: 'finalizeDeposit', - outputs: [], + name: 'isApprovedForAll', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { stateMutability: 'view', type: 'function', - inputs: [], - name: 'l1TokenBridge', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + inputs: [{ name: '_recipient', internalType: 'address', type: 'address' }], + name: 'isOnAllowList', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'messenger', - outputs: [ - { - name: '', - internalType: 'contract CrossDomainMessenger', - type: 'address', - }, - ], + inputs: [{ name: '_recipient', internalType: 'address', type: 'address' }], + name: 'mint', + outputs: [], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'version', + name: 'name', outputs: [{ name: '', internalType: 'string', type: 'string' }], }, { - stateMutability: 'payable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_l2Token', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, - ], - name: 'withdraw', - outputs: [], + inputs: [{ name: 'tokenId', internalType: 'uint256', type: 'uint256' }], + name: 'ownerOf', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'payable', + stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_l2Token', internalType: 'address', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - { name: '_minGasLimit', internalType: 'uint32', type: 'uint32' }, - { name: '_extraData', internalType: 'bytes', type: 'bytes' }, + { name: 'from', internalType: 'address', type: 'address' }, + { name: 'to', internalType: 'address', type: 'address' }, + { name: 'tokenId', internalType: 'uint256', type: 'uint256' }, ], - name: 'withdrawTo', + name: 'safeTransferFrom', outputs: [], }, - { stateMutability: 'payable', type: 'receive' }, -] as const - -/** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) - */ -export const l2StandardBridgeAddress = { - 420: '0x4200000000000000000000000000000000000010', -} as const - -/** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) - */ -export const l2StandardBridgeConfig = { - address: l2StandardBridgeAddress, - abi: l2StandardBridgeABI, -} as const - -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// L2ToL1MessagePasser -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000016) - */ -export const l2ToL1MessagePasserABI = [ - { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, { - type: 'event', - anonymous: false, + stateMutability: 'nonpayable', + type: 'function', inputs: [ - { - name: 'nonce', - internalType: 'uint256', - type: 'uint256', - indexed: true, - }, - { - name: 'sender', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'target', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'value', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - { - name: 'gasLimit', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - { name: 'data', internalType: 'bytes', type: 'bytes', indexed: false }, - { - name: 'withdrawalHash', - internalType: 'bytes32', - type: 'bytes32', - indexed: false, - }, + { name: 'from', internalType: 'address', type: 'address' }, + { name: 'to', internalType: 'address', type: 'address' }, + { name: 'tokenId', internalType: 'uint256', type: 'uint256' }, + { name: 'data', internalType: 'bytes', type: 'bytes' }, ], - name: 'MessagePassed', + name: 'safeTransferFrom', + outputs: [], }, { - type: 'event', - anonymous: false, + stateMutability: 'nonpayable', + type: 'function', inputs: [ - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: true, - }, + { name: '', internalType: 'address', type: 'address' }, + { name: '', internalType: 'bool', type: 'bool' }, ], - name: 'WithdrawerBalanceBurnt', + name: 'setApprovalForAll', + outputs: [], }, { stateMutability: 'view', type: 'function', - inputs: [], - name: 'MESSAGE_VERSION', - outputs: [{ name: '', internalType: 'uint16', type: 'uint16' }], + inputs: [{ name: 'interfaceId', internalType: 'bytes4', type: 'bytes4' }], + name: 'supportsInterface', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', inputs: [], - name: 'burn', - outputs: [], + name: 'symbol', + outputs: [{ name: '', internalType: 'string', type: 'string' }], }, { - stateMutability: 'payable', + stateMutability: 'pure', type: 'function', - inputs: [ - { name: '_target', internalType: 'address', type: 'address' }, - { name: '_gasLimit', internalType: 'uint256', type: 'uint256' }, - { name: '_data', internalType: 'bytes', type: 'bytes' }, - ], - name: 'initiateWithdrawal', - outputs: [], + inputs: [{ name: '_owner', internalType: 'address', type: 'address' }], + name: 'tokenIdOfAddress', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', - inputs: [], - name: 'messageNonce', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + inputs: [{ name: '_tokenId', internalType: 'uint256', type: 'uint256' }], + name: 'tokenURI', + outputs: [{ name: '', internalType: 'string', type: 'string' }], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - name: 'sentMessages', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + inputs: [ + { name: 'from', internalType: 'address', type: 'address' }, + { name: 'to', internalType: 'address', type: 'address' }, + { name: 'tokenId', internalType: 'uint256', type: 'uint256' }, + ], + name: 'transferFrom', + outputs: [], }, { stateMutability: 'view', @@ -6156,242 +6335,297 @@ export const l2ToL1MessagePasserABI = [ name: 'version', outputs: [{ name: '', internalType: 'string', type: 'string' }], }, - { stateMutability: 'payable', type: 'receive' }, ] as const /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000016) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) */ -export const l2ToL1MessagePasserAddress = { - 420: '0x4200000000000000000000000000000000000016', +export const optimistAddress = { + 10: '0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5', + 420: '0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5', } as const /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000016) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) */ -export const l2ToL1MessagePasserConfig = { - address: l2ToL1MessagePasserAddress, - abi: l2ToL1MessagePasserABI, +export const optimistConfig = { + address: optimistAddress, + abi: optimistABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// MintManager +// OptimistAllowlist ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x5C4e7Ba1E219E47948e6e3F55019A647bA501005) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) */ -export const mintManagerABI = [ +export const optimistAllowlistABI = [ { stateMutability: 'nonpayable', type: 'constructor', - inputs: [ - { name: '_upgrader', internalType: 'address', type: 'address' }, - { name: '_governanceToken', internalType: 'address', type: 'address' }, - ], - }, - { - type: 'event', - anonymous: false, inputs: [ { - name: 'previousOwner', - internalType: 'address', + name: '_attestationStation', + internalType: 'contract AttestationStation', type: 'address', - indexed: true, }, + { name: '_allowlistAttestor', internalType: 'address', type: 'address' }, { - name: 'newOwner', + name: '_coinbaseQuestAttestor', internalType: 'address', type: 'address', - indexed: true, }, + { name: '_optimistInviter', internalType: 'address', type: 'address' }, ], - name: 'OwnershipTransferred', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'DENOMINATOR', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'ALLOWLIST_ATTESTOR', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'MINT_CAP', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'ATTESTATION_STATION', + outputs: [ + { + name: '', + internalType: 'contract AttestationStation', + type: 'address', + }, + ], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'MINT_PERIOD', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'COINBASE_QUEST_ATTESTOR', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'governanceToken', - outputs: [ - { name: '', internalType: 'contract GovernanceToken', type: 'address' }, - ], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_account', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - ], - name: 'mint', - outputs: [], + name: 'COINBASE_QUEST_ELIGIBLE_ATTESTATION_KEY', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'mintPermittedAfter', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'OPTIMIST_CAN_MINT_ATTESTATION_KEY', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'owner', + name: 'OPTIMIST_INVITER', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [], - name: 'renounceOwnership', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], - name: 'transferOwnership', - outputs: [], + inputs: [{ name: '_claimer', internalType: 'address', type: 'address' }], + name: 'isAllowedToMint', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_newMintManager', internalType: 'address', type: 'address' }, - ], - name: 'upgrade', - outputs: [], + inputs: [], + name: 'version', + outputs: [{ name: '', internalType: 'string', type: 'string' }], }, ] as const /** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x5C4e7Ba1E219E47948e6e3F55019A647bA501005) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) */ -export const mintManagerAddress = { - 10: '0x5C4e7Ba1E219E47948e6e3F55019A647bA501005', - 420: '0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76', +export const optimistAllowlistAddress = { + 10: '0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180', + 420: '0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180', } as const /** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x5C4e7Ba1E219E47948e6e3F55019A647bA501005) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) */ -export const mintManagerConfig = { - address: mintManagerAddress, - abi: mintManagerABI, +export const optimistAllowlistConfig = { + address: optimistAllowlistAddress, + abi: optimistAllowlistABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// OptimismMintableERC20Factory +// OptimistInviter ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000012) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) */ -export const optimismMintableErc20FactoryABI = [ +export const optimistInviterABI = [ { stateMutability: 'nonpayable', type: 'constructor', - inputs: [{ name: '_bridge', internalType: 'address', type: 'address' }], + inputs: [ + { name: '_inviteGranter', internalType: 'address', type: 'address' }, + { + name: '_attestationStation', + internalType: 'contract AttestationStation', + type: 'address', + }, + ], }, { type: 'event', anonymous: false, inputs: [ - { - name: 'localToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'remoteToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'deployer', - internalType: 'address', - type: 'address', - indexed: false, - }, + { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, ], - name: 'OptimismMintableERC20Created', + name: 'Initialized', }, { type: 'event', anonymous: false, inputs: [ { - name: 'remoteToken', + name: 'issuer', internalType: 'address', type: 'address', indexed: true, }, { - name: 'localToken', + name: 'claimer', internalType: 'address', type: 'address', indexed: true, }, ], - name: 'StandardL2TokenCreated', + name: 'InviteClaimed', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'BRIDGE', + name: 'ATTESTATION_STATION', + outputs: [ + { + name: '', + internalType: 'contract AttestationStation', + type: 'address', + }, + ], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'CAN_INVITE_ATTESTATION_KEY', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'CLAIMABLE_INVITE_TYPEHASH', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'EIP712_VERSION', + outputs: [{ name: '', internalType: 'string', type: 'string' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'INVITE_GRANTER', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'MIN_COMMITMENT_PERIOD', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_symbol', internalType: 'string', type: 'string' }, + { name: '_claimer', internalType: 'address', type: 'address' }, + { + name: '_claimableInvite', + internalType: 'struct OptimistInviter.ClaimableInvite', + type: 'tuple', + components: [ + { name: 'issuer', internalType: 'address', type: 'address' }, + { name: 'nonce', internalType: 'bytes32', type: 'bytes32' }, + ], + }, + { name: '_signature', internalType: 'bytes', type: 'bytes' }, ], - name: 'createOptimismMintableERC20', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'claimInvite', + outputs: [], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [{ name: '_commitment', internalType: 'bytes32', type: 'bytes32' }], + name: 'commitInvite', + outputs: [], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'commitmentTimestamps', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [{ name: '_name', internalType: 'string', type: 'string' }], + name: 'initialize', + outputs: [], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'inviteCounts', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_symbol', internalType: 'string', type: 'string' }, + { name: '_accounts', internalType: 'address[]', type: 'address[]' }, + { name: '_inviteCount', internalType: 'uint256', type: 'uint256' }, ], - name: 'createStandardL2Token', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'setInviteCounts', + outputs: [], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [ + { name: '', internalType: 'address', type: 'address' }, + { name: '', internalType: 'bytes32', type: 'bytes32' }, + ], + name: 'usedNonces', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { stateMutability: 'view', @@ -6403,238 +6637,224 @@ export const optimismMintableErc20FactoryABI = [ ] as const /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000012) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) */ -export const optimismMintableErc20FactoryAddress = { - 1: '0x4200000000000000000000000000000000000012', +export const optimistInviterAddress = { + 10: '0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929', + 420: '0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929', } as const /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000012) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) */ -export const optimismMintableErc20FactoryConfig = { - address: optimismMintableErc20FactoryAddress, - abi: optimismMintableErc20FactoryABI, +export const optimistInviterConfig = { + address: optimistInviterAddress, + abi: optimistInviterABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// OptimismMintableERC20Factory_goerli +// PortalSender ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000012) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x0A893d9576b9cFD9EF78595963dc973238E78210) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xe7FACd39531ee3C313330E93B4d7a8B8A3c84Aa4) */ -export const optimismMintableErc20FactoryGoerliABI = [ - { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, - { - type: 'event', - anonymous: false, - inputs: [ - { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, - ], - name: 'Initialized', - }, +export const portalSenderABI = [ { - type: 'event', - anonymous: false, + stateMutability: 'nonpayable', + type: 'constructor', inputs: [ { - name: 'localToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'remoteToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'deployer', - internalType: 'address', + name: '_portal', + internalType: 'contract OptimismPortal', type: 'address', - indexed: false, }, ], - name: 'OptimismMintableERC20Created', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'remoteToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'localToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - ], - name: 'StandardL2TokenCreated', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'bridge', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_symbol', internalType: 'string', type: 'string' }, - ], - name: 'createOptimismMintableERC20', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_symbol', internalType: 'string', type: 'string' }, - { name: '_decimals', internalType: 'uint8', type: 'uint8' }, - ], - name: 'createOptimismMintableERC20WithDecimals', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_symbol', internalType: 'string', type: 'string' }, + name: 'PORTAL', + outputs: [ + { name: '', internalType: 'contract OptimismPortal', type: 'address' }, ], - name: 'createStandardL2Token', - outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [{ name: '_bridge', internalType: 'address', type: 'address' }], - name: 'initialize', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + name: 'donate', + outputs: [], }, ] as const /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000012) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x0A893d9576b9cFD9EF78595963dc973238E78210) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xe7FACd39531ee3C313330E93B4d7a8B8A3c84Aa4) */ -export const optimismMintableErc20FactoryGoerliAddress = { - 5: '0x4200000000000000000000000000000000000012', +export const portalSenderAddress = { + 1: '0x0A893d9576b9cFD9EF78595963dc973238E78210', + 5: '0xe7FACd39531ee3C313330E93B4d7a8B8A3c84Aa4', } as const /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000012) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x0A893d9576b9cFD9EF78595963dc973238E78210) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xe7FACd39531ee3C313330E93B4d7a8B8A3c84Aa4) */ -export const optimismMintableErc20FactoryGoerliConfig = { - address: optimismMintableErc20FactoryGoerliAddress, - abi: optimismMintableErc20FactoryGoerliABI, +export const portalSenderConfig = { + address: portalSenderAddress, + abi: portalSenderABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// OptimismMintableERC20Factory_optimism-goerli +// ProtocolVersions ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000012) + * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) */ -export const optimismMintableErc20FactoryOptimismGoerliABI = [ - { - stateMutability: 'nonpayable', - type: 'constructor', - inputs: [{ name: '_bridge', internalType: 'address', type: 'address' }], - }, +export const protocolVersionsABI = [ + { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, { type: 'event', anonymous: false, inputs: [ { - name: 'localToken', - internalType: 'address', - type: 'address', + name: 'version', + internalType: 'uint256', + type: 'uint256', indexed: true, }, { - name: 'remoteToken', - internalType: 'address', - type: 'address', + name: 'updateType', + internalType: 'enum ProtocolVersions.UpdateType', + type: 'uint8', indexed: true, }, - { - name: 'deployer', - internalType: 'address', - type: 'address', - indexed: false, - }, + { name: 'data', internalType: 'bytes', type: 'bytes', indexed: false }, ], - name: 'OptimismMintableERC20Created', + name: 'ConfigUpdate', + }, + { + type: 'event', + anonymous: false, + inputs: [ + { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, + ], + name: 'Initialized', }, { type: 'event', anonymous: false, inputs: [ { - name: 'remoteToken', + name: 'previousOwner', internalType: 'address', type: 'address', indexed: true, }, { - name: 'localToken', + name: 'newOwner', internalType: 'address', type: 'address', indexed: true, }, ], - name: 'StandardL2TokenCreated', + name: 'OwnershipTransferred', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'BRIDGE', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'RECOMMENDED_SLOT', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'REQUIRED_SLOT', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_symbol', internalType: 'string', type: 'string' }, + { name: '_owner', internalType: 'address', type: 'address' }, + { name: '_required', internalType: 'ProtocolVersion', type: 'uint256' }, + { + name: '_recommended', + internalType: 'ProtocolVersion', + type: 'uint256', + }, ], - name: 'createOptimismMintableERC20', + name: 'initialize', + outputs: [], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'owner', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'recommended', + outputs: [ + { name: 'out_', internalType: 'ProtocolVersion', type: 'uint256' }, + ], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [], + name: 'renounceOwnership', + outputs: [], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'required', + outputs: [ + { name: 'out_', internalType: 'ProtocolVersion', type: 'uint256' }, + ], + }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_symbol', internalType: 'string', type: 'string' }, + { + name: '_recommended', + internalType: 'ProtocolVersion', + type: 'uint256', + }, ], - name: 'createStandardL2Token', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'setRecommended', + outputs: [], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { name: '_required', internalType: 'ProtocolVersion', type: 'uint256' }, + ], + name: 'setRequired', + outputs: [], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], + name: 'transferOwnership', + outputs: [], }, { stateMutability: 'view', @@ -6646,823 +6866,797 @@ export const optimismMintableErc20FactoryOptimismGoerliABI = [ ] as const /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000012) + * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) */ -export const optimismMintableErc20FactoryOptimismGoerliAddress = { - 420: '0x4200000000000000000000000000000000000012', +export const protocolVersionsAddress = { + 5: '0x0C24F5098774aA366827D667494e9F889f7cFc08', } as const /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000012) + * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) */ -export const optimismMintableErc20FactoryOptimismGoerliConfig = { - address: optimismMintableErc20FactoryOptimismGoerliAddress, - abi: optimismMintableErc20FactoryOptimismGoerliABI, +export const protocolVersionsConfig = { + address: protocolVersionsAddress, + abi: protocolVersionsABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// OptimismMintableERC721Factory +// ProxyAdmin ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000017) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) */ -export const optimismMintableErc721FactoryABI = [ +export const proxyAdminABI = [ { stateMutability: 'nonpayable', type: 'constructor', - inputs: [ - { name: '_bridge', internalType: 'address', type: 'address' }, - { name: '_remoteChainId', internalType: 'uint256', type: 'uint256' }, - ], + inputs: [{ name: '_owner', internalType: 'address', type: 'address' }], }, { type: 'event', anonymous: false, inputs: [ { - name: 'localToken', + name: 'previousOwner', internalType: 'address', type: 'address', indexed: true, }, { - name: 'remoteToken', + name: 'newOwner', internalType: 'address', type: 'address', indexed: true, }, - { - name: 'deployer', - internalType: 'address', - type: 'address', - indexed: false, - }, ], - name: 'OptimismMintableERC721Created', + name: 'OwnershipTransferred', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'bridge', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'addressManager', + outputs: [ + { name: '', internalType: 'contract AddressManager', type: 'address' }, + ], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_symbol', internalType: 'string', type: 'string' }, - ], - name: 'createOptimismMintableERC721', + { name: '_proxy', internalType: 'address payable', type: 'address' }, + { name: '_newAdmin', internalType: 'address', type: 'address' }, + ], + name: 'changeProxyAdmin', + outputs: [], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [ + { name: '_proxy', internalType: 'address payable', type: 'address' }, + ], + name: 'getProxyAdmin', + outputs: [{ name: '', internalType: 'address', type: 'address' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [{ name: '_proxy', internalType: 'address', type: 'address' }], + name: 'getProxyImplementation', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', inputs: [{ name: '', internalType: 'address', type: 'address' }], - name: 'isOptimismMintableERC721', + name: 'implementationName', + outputs: [{ name: '', internalType: 'string', type: 'string' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'isUpgrading', outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'remoteChainId', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + name: 'owner', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', + inputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'proxyType', + outputs: [ + { name: '', internalType: 'enum ProxyAdmin.ProxyType', type: 'uint8' }, + ], + }, + { + stateMutability: 'nonpayable', + type: 'function', inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + name: 'renounceOwnership', + outputs: [], }, -] as const - -/** - * [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000017) - */ -export const optimismMintableErc721FactoryAddress = { - 10: '0x4200000000000000000000000000000000000017', -} as const - -/** - * [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000017) - */ -export const optimismMintableErc721FactoryConfig = { - address: optimismMintableErc721FactoryAddress, - abi: optimismMintableErc721FactoryABI, -} as const - -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// OptimismMintableERC721Factory_optimism-goerli -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000017) - */ -export const optimismMintableErc721FactoryOptimismGoerliABI = [ { stateMutability: 'nonpayable', - type: 'constructor', + type: 'function', inputs: [ - { name: '_bridge', internalType: 'address', type: 'address' }, - { name: '_remoteChainId', internalType: 'uint256', type: 'uint256' }, + { name: '_name', internalType: 'string', type: 'string' }, + { name: '_address', internalType: 'address', type: 'address' }, ], + name: 'setAddress', + outputs: [], }, { - type: 'event', - anonymous: false, + stateMutability: 'nonpayable', + type: 'function', inputs: [ { - name: 'localToken', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'remoteToken', - internalType: 'address', + name: '_address', + internalType: 'contract AddressManager', type: 'address', - indexed: true, }, + ], + name: 'setAddressManager', + outputs: [], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { name: '_address', internalType: 'address', type: 'address' }, + { name: '_name', internalType: 'string', type: 'string' }, + ], + name: 'setImplementationName', + outputs: [], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [ + { name: '_address', internalType: 'address', type: 'address' }, { - name: 'deployer', - internalType: 'address', - type: 'address', - indexed: false, + name: '_type', + internalType: 'enum ProxyAdmin.ProxyType', + type: 'uint8', }, ], - name: 'OptimismMintableERC721Created', + name: 'setProxyType', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'BRIDGE', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + inputs: [{ name: '_upgrading', internalType: 'bool', type: 'bool' }], + name: 'setUpgrading', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'REMOTE_CHAIN_ID', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], + name: 'transferOwnership', + outputs: [], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_remoteToken', internalType: 'address', type: 'address' }, - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_symbol', internalType: 'string', type: 'string' }, + { name: '_proxy', internalType: 'address payable', type: 'address' }, + { name: '_implementation', internalType: 'address', type: 'address' }, ], - name: 'createOptimismMintableERC721', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [{ name: '', internalType: 'address', type: 'address' }], - name: 'isOptimismMintableERC721', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + name: 'upgrade', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'payable', type: 'function', - inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + inputs: [ + { name: '_proxy', internalType: 'address payable', type: 'address' }, + { name: '_implementation', internalType: 'address', type: 'address' }, + { name: '_data', internalType: 'bytes', type: 'bytes' }, + ], + name: 'upgradeAndCall', + outputs: [], }, ] as const /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000017) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) */ -export const optimismMintableErc721FactoryOptimismGoerliAddress = { - 420: '0x4200000000000000000000000000000000000017', +export const proxyAdminAddress = { + 1: '0x4200000000000000000000000000000000000018', + 5: '0x4200000000000000000000000000000000000018', } as const /** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000017) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) */ -export const optimismMintableErc721FactoryOptimismGoerliConfig = { - address: optimismMintableErc721FactoryOptimismGoerliAddress, - abi: optimismMintableErc721FactoryOptimismGoerliABI, +export const proxyAdminConfig = { + address: proxyAdminAddress, + abi: proxyAdminABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// OptimismPortal +// SchemaRegistry ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x6232208d66bAc2305b46b4Cb6BCB3857B298DF13) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2545fa928d5d278cA75Fd47306e4a89096ff6403) */ -export const optimismPortalABI = [ +export const schemaRegistryABI = [ + { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, + { type: 'error', inputs: [], name: 'AlreadyExists' }, { - stateMutability: 'nonpayable', - type: 'constructor', + type: 'event', + anonymous: false, inputs: [ + { name: 'uid', internalType: 'bytes32', type: 'bytes32', indexed: true }, { - name: '_l2Oracle', - internalType: 'contract L2OutputOracle', - type: 'address', - }, - { name: '_guardian', internalType: 'address', type: 'address' }, - { name: '_paused', internalType: 'bool', type: 'bool' }, - { - name: '_config', - internalType: 'contract SystemConfig', + name: 'registerer', + internalType: 'address', type: 'address', + indexed: false, }, ], + name: 'Registered', }, { - type: 'event', - anonymous: false, - inputs: [ - { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, + stateMutability: 'view', + type: 'function', + inputs: [{ name: 'uid', internalType: 'bytes32', type: 'bytes32' }], + name: 'getSchema', + outputs: [ + { + name: '', + internalType: 'struct SchemaRecord', + type: 'tuple', + components: [ + { name: 'uid', internalType: 'bytes32', type: 'bytes32' }, + { + name: 'resolver', + internalType: 'contract ISchemaResolver', + type: 'address', + }, + { name: 'revocable', internalType: 'bool', type: 'bool' }, + { name: 'schema', internalType: 'string', type: 'string' }, + ], + }, ], - name: 'Initialized', }, { - type: 'event', - anonymous: false, + stateMutability: 'nonpayable', + type: 'function', inputs: [ + { name: 'schema', internalType: 'string', type: 'string' }, { - name: 'account', - internalType: 'address', + name: 'resolver', + internalType: 'contract ISchemaResolver', type: 'address', - indexed: false, }, + { name: 'revocable', internalType: 'bool', type: 'bool' }, ], - name: 'Paused', + name: 'register', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { - type: 'event', - anonymous: false, - inputs: [ - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, - { - name: 'version', - internalType: 'uint256', - type: 'uint256', - indexed: true, - }, - { - name: 'opaqueData', - internalType: 'bytes', - type: 'bytes', - indexed: false, - }, - ], - name: 'TransactionDeposited', + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'version', + outputs: [{ name: '', internalType: 'string', type: 'string' }], + }, +] as const + +/** + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x6232208d66bAc2305b46b4Cb6BCB3857B298DF13) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2545fa928d5d278cA75Fd47306e4a89096ff6403) + */ +export const schemaRegistryAddress = { + 10: '0x6232208d66bAc2305b46b4Cb6BCB3857B298DF13', + 420: '0x2545fa928d5d278cA75Fd47306e4a89096ff6403', +} as const + +/** + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x6232208d66bAc2305b46b4Cb6BCB3857B298DF13) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2545fa928d5d278cA75Fd47306e4a89096ff6403) + */ +export const schemaRegistryConfig = { + address: schemaRegistryAddress, + abi: schemaRegistryABI, +} as const + +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// SequencerFeeVault +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/** + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000011) + */ +export const sequencerFeeVaultABI = [ + { + stateMutability: 'nonpayable', + type: 'constructor', + inputs: [{ name: '_recipient', internalType: 'address', type: 'address' }], }, { type: 'event', anonymous: false, inputs: [ { - name: 'account', + name: 'value', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + { name: 'to', internalType: 'address', type: 'address', indexed: false }, + { + name: 'from', internalType: 'address', type: 'address', indexed: false, }, ], - name: 'Unpaused', + name: 'Withdrawal', }, { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'withdrawalHash', - internalType: 'bytes32', - type: 'bytes32', - indexed: true, - }, - { name: 'success', internalType: 'bool', type: 'bool', indexed: false }, - ], - name: 'WithdrawalFinalized', + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'MIN_WITHDRAWAL_AMOUNT', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'withdrawalHash', - internalType: 'bytes32', - type: 'bytes32', - indexed: true, - }, - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, - ], - name: 'WithdrawalProven', + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'RECIPIENT', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'GUARDIAN', + name: 'l1FeeWallet', outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'L2_ORACLE', - outputs: [ - { name: '', internalType: 'contract L2OutputOracle', type: 'address' }, - ], + name: 'totalProcessed', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'SYSTEM_CONFIG', - outputs: [ - { name: '', internalType: 'contract SystemConfig', type: 'address' }, - ], + name: 'version', + outputs: [{ name: '', internalType: 'string', type: 'string' }], }, { - stateMutability: 'payable', + stateMutability: 'nonpayable', type: 'function', + inputs: [], + name: 'withdraw', + outputs: [], + }, + { stateMutability: 'payable', type: 'receive' }, +] as const + +/** + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000011) + */ +export const sequencerFeeVaultAddress = { + 420: '0x4200000000000000000000000000000000000011', +} as const + +/** + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000011) + */ +export const sequencerFeeVaultConfig = { + address: sequencerFeeVaultAddress, + abi: sequencerFeeVaultABI, +} as const + +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// SystemConfig +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +/** + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) + */ +export const systemConfigABI = [ + { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, + { + type: 'event', + anonymous: false, inputs: [ - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_value', internalType: 'uint256', type: 'uint256' }, - { name: '_gasLimit', internalType: 'uint64', type: 'uint64' }, - { name: '_isCreation', internalType: 'bool', type: 'bool' }, - { name: '_data', internalType: 'bytes', type: 'bytes' }, + { + name: 'version', + internalType: 'uint256', + type: 'uint256', + indexed: true, + }, + { + name: 'updateType', + internalType: 'enum SystemConfig.UpdateType', + type: 'uint8', + indexed: true, + }, + { name: 'data', internalType: 'bytes', type: 'bytes', indexed: false }, ], - name: 'depositTransaction', - outputs: [], + name: 'ConfigUpdate', }, { - stateMutability: 'payable', - type: 'function', - inputs: [], - name: 'donateETH', - outputs: [], + type: 'event', + anonymous: false, + inputs: [ + { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, + ], + name: 'Initialized', }, { - stateMutability: 'nonpayable', - type: 'function', + type: 'event', + anonymous: false, inputs: [ { - name: '_tx', - internalType: 'struct Types.WithdrawalTransaction', - type: 'tuple', - components: [ - { name: 'nonce', internalType: 'uint256', type: 'uint256' }, - { name: 'sender', internalType: 'address', type: 'address' }, - { name: 'target', internalType: 'address', type: 'address' }, - { name: 'value', internalType: 'uint256', type: 'uint256' }, - { name: 'gasLimit', internalType: 'uint256', type: 'uint256' }, - { name: 'data', internalType: 'bytes', type: 'bytes' }, - ], + name: 'previousOwner', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'newOwner', + internalType: 'address', + type: 'address', + indexed: true, }, ], - name: 'finalizeWithdrawalTransaction', - outputs: [], + name: 'OwnershipTransferred', }, { stateMutability: 'view', type: 'function', - inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - name: 'finalizedWithdrawals', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + inputs: [], + name: 'BATCH_INBOX_SLOT', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [{ name: '_paused', internalType: 'bool', type: 'bool' }], - name: 'initialize', - outputs: [], + inputs: [], + name: 'L1_CROSS_DOMAIN_MESSENGER_SLOT', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { stateMutability: 'view', type: 'function', - inputs: [ - { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, - ], - name: 'isOutputFinalized', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + inputs: [], + name: 'L1_ERC_721_BRIDGE_SLOT', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'l2Sender', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'L1_STANDARD_BRIDGE_SLOT', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { - stateMutability: 'pure', + stateMutability: 'view', type: 'function', - inputs: [{ name: '_byteCount', internalType: 'uint64', type: 'uint64' }], - name: 'minimumGasLimit', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + inputs: [], + name: 'L2_OUTPUT_ORACLE_SLOT', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'params', - outputs: [ - { name: 'prevBaseFee', internalType: 'uint128', type: 'uint128' }, - { name: 'prevBoughtGas', internalType: 'uint64', type: 'uint64' }, - { name: 'prevBlockNum', internalType: 'uint64', type: 'uint64' }, - ], + name: 'OPTIMISM_MINTABLE_ERC20_FACTORY_SLOT', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', inputs: [], - name: 'pause', - outputs: [], + name: 'OPTIMISM_PORTAL_SLOT', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'paused', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + name: 'UNSAFE_BLOCK_SIGNER_SLOT', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'batchInbox', + outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'batcherHash', + outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'gasLimit', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], + }, + { + stateMutability: 'nonpayable', type: 'function', inputs: [ + { name: '_owner', internalType: 'address', type: 'address' }, + { name: '_overhead', internalType: 'uint256', type: 'uint256' }, + { name: '_scalar', internalType: 'uint256', type: 'uint256' }, + { name: '_batcherHash', internalType: 'bytes32', type: 'bytes32' }, + { name: '_gasLimit', internalType: 'uint64', type: 'uint64' }, + { name: '_unsafeBlockSigner', internalType: 'address', type: 'address' }, { - name: '_tx', - internalType: 'struct Types.WithdrawalTransaction', + name: '_config', + internalType: 'struct ResourceMetering.ResourceConfig', type: 'tuple', components: [ - { name: 'nonce', internalType: 'uint256', type: 'uint256' }, - { name: 'sender', internalType: 'address', type: 'address' }, - { name: 'target', internalType: 'address', type: 'address' }, - { name: 'value', internalType: 'uint256', type: 'uint256' }, - { name: 'gasLimit', internalType: 'uint256', type: 'uint256' }, - { name: 'data', internalType: 'bytes', type: 'bytes' }, + { name: 'maxResourceLimit', internalType: 'uint32', type: 'uint32' }, + { + name: 'elasticityMultiplier', + internalType: 'uint8', + type: 'uint8', + }, + { + name: 'baseFeeMaxChangeDenominator', + internalType: 'uint8', + type: 'uint8', + }, + { name: 'minimumBaseFee', internalType: 'uint32', type: 'uint32' }, + { name: 'systemTxMaxGas', internalType: 'uint32', type: 'uint32' }, + { name: 'maximumBaseFee', internalType: 'uint128', type: 'uint128' }, ], }, - { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, + { name: '_startBlock', internalType: 'uint256', type: 'uint256' }, + { name: '_batchInbox', internalType: 'address', type: 'address' }, { - name: '_outputRootProof', - internalType: 'struct Types.OutputRootProof', + name: '_addresses', + internalType: 'struct SystemConfig.Addresses', type: 'tuple', components: [ - { name: 'version', internalType: 'bytes32', type: 'bytes32' }, - { name: 'stateRoot', internalType: 'bytes32', type: 'bytes32' }, { - name: 'messagePasserStorageRoot', - internalType: 'bytes32', - type: 'bytes32', + name: 'l1CrossDomainMessenger', + internalType: 'address', + type: 'address', + }, + { name: 'l1ERC721Bridge', internalType: 'address', type: 'address' }, + { + name: 'l1StandardBridge', + internalType: 'address', + type: 'address', + }, + { name: 'l2OutputOracle', internalType: 'address', type: 'address' }, + { name: 'optimismPortal', internalType: 'address', type: 'address' }, + { + name: 'optimismMintableERC20Factory', + internalType: 'address', + type: 'address', }, - { name: 'latestBlockhash', internalType: 'bytes32', type: 'bytes32' }, ], }, - { name: '_withdrawalProof', internalType: 'bytes[]', type: 'bytes[]' }, ], - name: 'proveWithdrawalTransaction', + name: 'initialize', outputs: [], }, { stateMutability: 'view', type: 'function', - inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - name: 'provenWithdrawals', - outputs: [ - { name: 'outputRoot', internalType: 'bytes32', type: 'bytes32' }, - { name: 'timestamp', internalType: 'uint128', type: 'uint128' }, - { name: 'l2OutputIndex', internalType: 'uint128', type: 'uint128' }, - ], + inputs: [], + name: 'l1CrossDomainMessenger', + outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', inputs: [], - name: 'unpause', - outputs: [], + name: 'l1ERC721Bridge', + outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], - }, - { stateMutability: 'payable', type: 'receive' }, -] as const - -/** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) - */ -export const optimismPortalAddress = { - 1: '0xbEb5Fc579115071764c7423A4f12eDde41f106Ed', -} as const - -/** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) - */ -export const optimismPortalConfig = { - address: optimismPortalAddress, - abi: optimismPortalABI, -} as const - -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// OptimismPortal_goerli -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) - */ -export const optimismPortalGoerliABI = [ - { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, - { - type: 'event', - anonymous: false, - inputs: [ - { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, - ], - name: 'Initialized', + name: 'l1StandardBridge', + outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], }, { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'account', - internalType: 'address', - type: 'address', - indexed: false, - }, - ], - name: 'Paused', + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'l2OutputOracle', + outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], }, { - type: 'event', - anonymous: false, - inputs: [ - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, - { - name: 'version', - internalType: 'uint256', - type: 'uint256', - indexed: true, - }, - { - name: 'opaqueData', - internalType: 'bytes', - type: 'bytes', - indexed: false, - }, - ], - name: 'TransactionDeposited', + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'minimumGasLimit', + outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], }, { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'account', - internalType: 'address', - type: 'address', - indexed: false, - }, - ], - name: 'Unpaused', + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'optimismMintableERC20Factory', + outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], }, { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'withdrawalHash', - internalType: 'bytes32', - type: 'bytes32', - indexed: true, - }, - { name: 'success', internalType: 'bool', type: 'bool', indexed: false }, - ], - name: 'WithdrawalFinalized', + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'optimismPortal', + outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], }, { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'withdrawalHash', - internalType: 'bytes32', - type: 'bytes32', - indexed: true, - }, - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, - ], - name: 'WithdrawalProven', + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'overhead', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { - stateMutability: 'payable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_value', internalType: 'uint256', type: 'uint256' }, - { name: '_gasLimit', internalType: 'uint64', type: 'uint64' }, - { name: '_isCreation', internalType: 'bool', type: 'bool' }, - { name: '_data', internalType: 'bytes', type: 'bytes' }, - ], - name: 'depositTransaction', - outputs: [], + inputs: [], + name: 'owner', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'payable', + stateMutability: 'nonpayable', type: 'function', inputs: [], - name: 'donateETH', + name: 'renounceOwnership', outputs: [], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [ + inputs: [], + name: 'resourceConfig', + outputs: [ { - name: '_tx', - internalType: 'struct Types.WithdrawalTransaction', + name: '', + internalType: 'struct ResourceMetering.ResourceConfig', type: 'tuple', components: [ - { name: 'nonce', internalType: 'uint256', type: 'uint256' }, - { name: 'sender', internalType: 'address', type: 'address' }, - { name: 'target', internalType: 'address', type: 'address' }, - { name: 'value', internalType: 'uint256', type: 'uint256' }, - { name: 'gasLimit', internalType: 'uint256', type: 'uint256' }, - { name: 'data', internalType: 'bytes', type: 'bytes' }, + { name: 'maxResourceLimit', internalType: 'uint32', type: 'uint32' }, + { + name: 'elasticityMultiplier', + internalType: 'uint8', + type: 'uint8', + }, + { + name: 'baseFeeMaxChangeDenominator', + internalType: 'uint8', + type: 'uint8', + }, + { name: 'minimumBaseFee', internalType: 'uint32', type: 'uint32' }, + { name: 'systemTxMaxGas', internalType: 'uint32', type: 'uint32' }, + { name: 'maximumBaseFee', internalType: 'uint128', type: 'uint128' }, ], }, ], - name: 'finalizeWithdrawalTransaction', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - name: 'finalizedWithdrawals', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'guardian', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'scalar', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { - name: '_l2Oracle', - internalType: 'contract L2OutputOracle', - type: 'address', - }, - { name: '_guardian', internalType: 'address', type: 'address' }, - { - name: '_systemConfig', - internalType: 'contract SystemConfig', - type: 'address', - }, - { name: '_paused', internalType: 'bool', type: 'bool' }, + { name: '_batcherHash', internalType: 'bytes32', type: 'bytes32' }, ], - name: 'initialize', + name: 'setBatcherHash', outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, - ], - name: 'isOutputFinalized', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'l2Oracle', - outputs: [ - { name: '', internalType: 'contract L2OutputOracle', type: 'address' }, - ], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'l2Sender', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'pure', - type: 'function', - inputs: [{ name: '_byteCount', internalType: 'uint64', type: 'uint64' }], - name: 'minimumGasLimit', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'params', - outputs: [ - { name: 'prevBaseFee', internalType: 'uint128', type: 'uint128' }, - { name: 'prevBoughtGas', internalType: 'uint64', type: 'uint64' }, - { name: 'prevBlockNum', internalType: 'uint64', type: 'uint64' }, + { name: '_overhead', internalType: 'uint256', type: 'uint256' }, + { name: '_scalar', internalType: 'uint256', type: 'uint256' }, ], + name: 'setGasConfig', + outputs: [], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'pause', + inputs: [{ name: '_gasLimit', internalType: 'uint64', type: 'uint64' }], + name: 'setGasLimit', outputs: [], }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'paused', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], - }, { stateMutability: 'nonpayable', type: 'function', inputs: [ { - name: '_tx', - internalType: 'struct Types.WithdrawalTransaction', - type: 'tuple', - components: [ - { name: 'nonce', internalType: 'uint256', type: 'uint256' }, - { name: 'sender', internalType: 'address', type: 'address' }, - { name: 'target', internalType: 'address', type: 'address' }, - { name: 'value', internalType: 'uint256', type: 'uint256' }, - { name: 'gasLimit', internalType: 'uint256', type: 'uint256' }, - { name: 'data', internalType: 'bytes', type: 'bytes' }, - ], - }, - { name: '_l2OutputIndex', internalType: 'uint256', type: 'uint256' }, - { - name: '_outputRootProof', - internalType: 'struct Types.OutputRootProof', + name: '_config', + internalType: 'struct ResourceMetering.ResourceConfig', type: 'tuple', components: [ - { name: 'version', internalType: 'bytes32', type: 'bytes32' }, - { name: 'stateRoot', internalType: 'bytes32', type: 'bytes32' }, + { name: 'maxResourceLimit', internalType: 'uint32', type: 'uint32' }, { - name: 'messagePasserStorageRoot', - internalType: 'bytes32', - type: 'bytes32', + name: 'elasticityMultiplier', + internalType: 'uint8', + type: 'uint8', }, - { name: 'latestBlockhash', internalType: 'bytes32', type: 'bytes32' }, + { + name: 'baseFeeMaxChangeDenominator', + internalType: 'uint8', + type: 'uint8', + }, + { name: 'minimumBaseFee', internalType: 'uint32', type: 'uint32' }, + { name: 'systemTxMaxGas', internalType: 'uint32', type: 'uint32' }, + { name: 'maximumBaseFee', internalType: 'uint128', type: 'uint128' }, ], }, - { name: '_withdrawalProof', internalType: 'bytes[]', type: 'bytes[]' }, ], - name: 'proveWithdrawalTransaction', + name: 'setResourceConfig', outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - name: 'provenWithdrawals', - outputs: [ - { name: 'outputRoot', internalType: 'bytes32', type: 'bytes32' }, - { name: 'timestamp', internalType: 'uint128', type: 'uint128' }, - { name: 'l2OutputIndex', internalType: 'uint128', type: 'uint128' }, + inputs: [ + { name: '_unsafeBlockSigner', internalType: 'address', type: 'address' }, ], + name: 'setUnsafeBlockSigner', + outputs: [], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'systemConfig', - outputs: [ - { name: '', internalType: 'contract SystemConfig', type: 'address' }, - ], + name: 'startBlock', + outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'unpause', + inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], + name: 'transferOwnership', outputs: [], }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'unsafeBlockSigner', + outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], + }, { stateMutability: 'view', type: 'function', @@ -7470,471 +7664,622 @@ export const optimismPortalGoerliABI = [ name: 'version', outputs: [{ name: '', internalType: 'string', type: 'string' }], }, - { stateMutability: 'payable', type: 'receive' }, ] as const /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) */ -export const optimismPortalGoerliAddress = { - 5: '0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383', +export const systemConfigAddress = { + 1: '0x229047fed2591dbec1eF1118d64F7aF3dB9EB290', + 5: '0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60', } as const /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) */ -export const optimismPortalGoerliConfig = { - address: optimismPortalGoerliAddress, - abi: optimismPortalGoerliABI, +export const systemConfigConfig = { + address: systemConfigAddress, + abi: systemConfigABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// Optimist +// SystemDictator ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) + * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) */ -export const optimistABI = [ - { - stateMutability: 'nonpayable', - type: 'constructor', - inputs: [ - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_symbol', internalType: 'string', type: 'string' }, - { name: '_baseURIAttestor', internalType: 'address', type: 'address' }, - { - name: '_attestationStation', - internalType: 'contract AttestationStation', - type: 'address', - }, - { - name: '_optimistAllowlist', - internalType: 'contract OptimistAllowlist', - type: 'address', - }, - ], - }, +export const systemDictatorABI = [ + { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, { type: 'event', anonymous: false, inputs: [ - { - name: 'owner', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'approved', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'tokenId', - internalType: 'uint256', - type: 'uint256', - indexed: true, - }, + { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, ], - name: 'Approval', + name: 'Initialized', }, { type: 'event', anonymous: false, inputs: [ { - name: 'owner', + name: 'previousOwner', internalType: 'address', type: 'address', indexed: true, }, { - name: 'operator', + name: 'newOwner', internalType: 'address', type: 'address', indexed: true, }, - { name: 'approved', internalType: 'bool', type: 'bool', indexed: false }, - ], - name: 'ApprovalForAll', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, ], - name: 'Initialized', + name: 'OwnershipTransferred', }, { - type: 'event', - anonymous: false, - inputs: [ - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { name: 'to', internalType: 'address', type: 'address', indexed: true }, - { - name: 'tokenId', - internalType: 'uint256', - type: 'uint256', - indexed: true, - }, - ], - name: 'Transfer', + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'EXIT_1_NO_RETURN_STEP', + outputs: [{ name: '', internalType: 'uint8', type: 'uint8' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'ATTESTATION_STATION', - outputs: [ - { - name: '', - internalType: 'contract AttestationStation', - type: 'address', - }, - ], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'BASE_URI_ATTESTATION_KEY', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'BASE_URI_ATTESTOR', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'PROXY_TRANSFER_STEP', + outputs: [{ name: '', internalType: 'uint8', type: 'uint8' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'OPTIMIST_ALLOWLIST', + name: 'config', outputs: [ - { name: '', internalType: 'contract OptimistAllowlist', type: 'address' }, - ], - }, - { - stateMutability: 'pure', - type: 'function', - inputs: [ - { name: '', internalType: 'address', type: 'address' }, - { name: '', internalType: 'uint256', type: 'uint256' }, + { + name: 'globalConfig', + internalType: 'struct SystemDictator.GlobalConfig', + type: 'tuple', + components: [ + { + name: 'addressManager', + internalType: 'contract AddressManager', + type: 'address', + }, + { + name: 'proxyAdmin', + internalType: 'contract ProxyAdmin', + type: 'address', + }, + { name: 'controller', internalType: 'address', type: 'address' }, + { name: 'finalOwner', internalType: 'address', type: 'address' }, + ], + }, + { + name: 'proxyAddressConfig', + internalType: 'struct SystemDictator.ProxyAddressConfig', + type: 'tuple', + components: [ + { + name: 'l2OutputOracleProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'optimismPortalProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'l1CrossDomainMessengerProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'l1StandardBridgeProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'optimismMintableERC20FactoryProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'l1ERC721BridgeProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'systemConfigProxy', + internalType: 'address', + type: 'address', + }, + ], + }, + { + name: 'implementationAddressConfig', + internalType: 'struct SystemDictator.ImplementationAddressConfig', + type: 'tuple', + components: [ + { + name: 'l2OutputOracleImpl', + internalType: 'contract L2OutputOracle', + type: 'address', + }, + { + name: 'optimismPortalImpl', + internalType: 'contract OptimismPortal', + type: 'address', + }, + { + name: 'l1CrossDomainMessengerImpl', + internalType: 'contract L1CrossDomainMessenger', + type: 'address', + }, + { + name: 'l1StandardBridgeImpl', + internalType: 'contract L1StandardBridge', + type: 'address', + }, + { + name: 'optimismMintableERC20FactoryImpl', + internalType: 'contract OptimismMintableERC20Factory', + type: 'address', + }, + { + name: 'l1ERC721BridgeImpl', + internalType: 'contract L1ERC721Bridge', + type: 'address', + }, + { + name: 'portalSenderImpl', + internalType: 'contract PortalSender', + type: 'address', + }, + { + name: 'systemConfigImpl', + internalType: 'contract SystemConfig', + type: 'address', + }, + ], + }, + { + name: 'systemConfigConfig', + internalType: 'struct SystemDictator.SystemConfigConfig', + type: 'tuple', + components: [ + { name: 'owner', internalType: 'address', type: 'address' }, + { name: 'overhead', internalType: 'uint256', type: 'uint256' }, + { name: 'scalar', internalType: 'uint256', type: 'uint256' }, + { name: 'batcherHash', internalType: 'bytes32', type: 'bytes32' }, + { name: 'gasLimit', internalType: 'uint64', type: 'uint64' }, + { + name: 'unsafeBlockSigner', + internalType: 'address', + type: 'address', + }, + { + name: 'resourceConfig', + internalType: 'struct ResourceMetering.ResourceConfig', + type: 'tuple', + components: [ + { + name: 'maxResourceLimit', + internalType: 'uint32', + type: 'uint32', + }, + { + name: 'elasticityMultiplier', + internalType: 'uint8', + type: 'uint8', + }, + { + name: 'baseFeeMaxChangeDenominator', + internalType: 'uint8', + type: 'uint8', + }, + { + name: 'minimumBaseFee', + internalType: 'uint32', + type: 'uint32', + }, + { + name: 'systemTxMaxGas', + internalType: 'uint32', + type: 'uint32', + }, + { + name: 'maximumBaseFee', + internalType: 'uint128', + type: 'uint128', + }, + ], + }, + ], + }, ], - name: 'approve', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [{ name: 'owner', internalType: 'address', type: 'address' }], - name: 'balanceOf', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'baseURI', - outputs: [{ name: '', internalType: 'string', type: 'string' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: 'tokenId', internalType: 'uint256', type: 'uint256' }], - name: 'burn', - outputs: [], + name: 'currentStep', + outputs: [{ name: '', internalType: 'uint8', type: 'uint8' }], }, { stateMutability: 'view', type: 'function', - inputs: [{ name: 'tokenId', internalType: 'uint256', type: 'uint256' }], - name: 'getApproved', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + inputs: [], + name: 'dynamicConfigSet', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [ - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_symbol', internalType: 'string', type: 'string' }, - ], - name: 'initialize', + inputs: [], + name: 'exit1', outputs: [], }, { stateMutability: 'view', type: 'function', - inputs: [ - { name: 'owner', internalType: 'address', type: 'address' }, - { name: 'operator', internalType: 'address', type: 'address' }, - ], - name: 'isApprovedForAll', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [{ name: '_recipient', internalType: 'address', type: 'address' }], - name: 'isOnAllowList', + inputs: [], + name: 'exited', outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [{ name: '_recipient', internalType: 'address', type: 'address' }], - name: 'mint', + inputs: [], + name: 'finalize', outputs: [], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'name', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + name: 'finalized', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { - stateMutability: 'view', - type: 'function', - inputs: [{ name: 'tokenId', internalType: 'uint256', type: 'uint256' }], - name: 'ownerOf', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'nonpayable', + stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: 'from', internalType: 'address', type: 'address' }, - { name: 'to', internalType: 'address', type: 'address' }, - { name: 'tokenId', internalType: 'uint256', type: 'uint256' }, + { + name: '_config', + internalType: 'struct SystemDictator.DeployConfig', + type: 'tuple', + components: [ + { + name: 'globalConfig', + internalType: 'struct SystemDictator.GlobalConfig', + type: 'tuple', + components: [ + { + name: 'addressManager', + internalType: 'contract AddressManager', + type: 'address', + }, + { + name: 'proxyAdmin', + internalType: 'contract ProxyAdmin', + type: 'address', + }, + { name: 'controller', internalType: 'address', type: 'address' }, + { name: 'finalOwner', internalType: 'address', type: 'address' }, + ], + }, + { + name: 'proxyAddressConfig', + internalType: 'struct SystemDictator.ProxyAddressConfig', + type: 'tuple', + components: [ + { + name: 'l2OutputOracleProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'optimismPortalProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'l1CrossDomainMessengerProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'l1StandardBridgeProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'optimismMintableERC20FactoryProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'l1ERC721BridgeProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'systemConfigProxy', + internalType: 'address', + type: 'address', + }, + ], + }, + { + name: 'implementationAddressConfig', + internalType: 'struct SystemDictator.ImplementationAddressConfig', + type: 'tuple', + components: [ + { + name: 'l2OutputOracleImpl', + internalType: 'contract L2OutputOracle', + type: 'address', + }, + { + name: 'optimismPortalImpl', + internalType: 'contract OptimismPortal', + type: 'address', + }, + { + name: 'l1CrossDomainMessengerImpl', + internalType: 'contract L1CrossDomainMessenger', + type: 'address', + }, + { + name: 'l1StandardBridgeImpl', + internalType: 'contract L1StandardBridge', + type: 'address', + }, + { + name: 'optimismMintableERC20FactoryImpl', + internalType: 'contract OptimismMintableERC20Factory', + type: 'address', + }, + { + name: 'l1ERC721BridgeImpl', + internalType: 'contract L1ERC721Bridge', + type: 'address', + }, + { + name: 'portalSenderImpl', + internalType: 'contract PortalSender', + type: 'address', + }, + { + name: 'systemConfigImpl', + internalType: 'contract SystemConfig', + type: 'address', + }, + ], + }, + { + name: 'systemConfigConfig', + internalType: 'struct SystemDictator.SystemConfigConfig', + type: 'tuple', + components: [ + { name: 'owner', internalType: 'address', type: 'address' }, + { name: 'overhead', internalType: 'uint256', type: 'uint256' }, + { name: 'scalar', internalType: 'uint256', type: 'uint256' }, + { name: 'batcherHash', internalType: 'bytes32', type: 'bytes32' }, + { name: 'gasLimit', internalType: 'uint64', type: 'uint64' }, + { + name: 'unsafeBlockSigner', + internalType: 'address', + type: 'address', + }, + { + name: 'resourceConfig', + internalType: 'struct ResourceMetering.ResourceConfig', + type: 'tuple', + components: [ + { + name: 'maxResourceLimit', + internalType: 'uint32', + type: 'uint32', + }, + { + name: 'elasticityMultiplier', + internalType: 'uint8', + type: 'uint8', + }, + { + name: 'baseFeeMaxChangeDenominator', + internalType: 'uint8', + type: 'uint8', + }, + { + name: 'minimumBaseFee', + internalType: 'uint32', + type: 'uint32', + }, + { + name: 'systemTxMaxGas', + internalType: 'uint32', + type: 'uint32', + }, + { + name: 'maximumBaseFee', + internalType: 'uint128', + type: 'uint128', + }, + ], + }, + ], + }, + ], + }, ], - name: 'safeTransferFrom', + name: 'initialize', outputs: [], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: 'from', internalType: 'address', type: 'address' }, - { name: 'to', internalType: 'address', type: 'address' }, - { name: 'tokenId', internalType: 'uint256', type: 'uint256' }, - { name: 'data', internalType: 'bytes', type: 'bytes' }, + inputs: [], + name: 'l2OutputOracleDynamicConfig', + outputs: [ + { + name: 'l2OutputOracleStartingBlockNumber', + internalType: 'uint256', + type: 'uint256', + }, + { + name: 'l2OutputOracleStartingTimestamp', + internalType: 'uint256', + type: 'uint256', + }, ], - name: 'safeTransferFrom', - outputs: [], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '', internalType: 'address', type: 'address' }, - { name: '', internalType: 'bool', type: 'bool' }, - ], - name: 'setApprovalForAll', - outputs: [], + inputs: [], + name: 'oldL1CrossDomainMessenger', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'view', type: 'function', - inputs: [{ name: 'interfaceId', internalType: 'bytes4', type: 'bytes4' }], - name: 'supportsInterface', + inputs: [], + name: 'optimismPortalDynamicConfig', outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'symbol', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + name: 'owner', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'pure', + stateMutability: 'nonpayable', type: 'function', - inputs: [{ name: '_owner', internalType: 'address', type: 'address' }], - name: 'tokenIdOfAddress', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], + inputs: [], + name: 'phase1', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [{ name: '_tokenId', internalType: 'uint256', type: 'uint256' }], - name: 'tokenURI', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + inputs: [], + name: 'phase2', + outputs: [], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [ - { name: 'from', internalType: 'address', type: 'address' }, - { name: 'to', internalType: 'address', type: 'address' }, - { name: 'tokenId', internalType: 'uint256', type: 'uint256' }, - ], - name: 'transferFrom', + inputs: [], + name: 'renounceOwnership', outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + name: 'step1', + outputs: [], }, -] as const - -/** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - */ -export const optimistAddress = { - 10: '0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5', - 420: '0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5', -} as const - -/** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - */ -export const optimistConfig = { - address: optimistAddress, - abi: optimistABI, -} as const - -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// OptimistAllowlist -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) - */ -export const optimistAllowlistABI = [ { stateMutability: 'nonpayable', - type: 'constructor', - inputs: [ - { - name: '_attestationStation', - internalType: 'contract AttestationStation', - type: 'address', - }, - { name: '_allowlistAttestor', internalType: 'address', type: 'address' }, - { - name: '_coinbaseQuestAttestor', - internalType: 'address', - type: 'address', - }, - { name: '_optimistInviter', internalType: 'address', type: 'address' }, - ], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'ALLOWLIST_ATTESTOR', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'ATTESTATION_STATION', - outputs: [ - { - name: '', - internalType: 'contract AttestationStation', - type: 'address', - }, - ], - }, - { - stateMutability: 'view', type: 'function', inputs: [], - name: 'COINBASE_QUEST_ATTESTOR', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'step2', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', inputs: [], - name: 'COINBASE_QUEST_ELIGIBLE_ATTESTATION_KEY', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'step3', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', inputs: [], - name: 'OPTIMIST_CAN_MINT_ATTESTATION_KEY', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'step4', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', inputs: [], - name: 'OPTIMIST_INVITER', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'step5', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [{ name: '_claimer', internalType: 'address', type: 'address' }], - name: 'isAllowedToMint', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], + name: 'transferOwnership', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + inputs: [ + { + name: '_l2OutputOracleDynamicConfig', + internalType: 'struct SystemDictator.L2OutputOracleDynamicConfig', + type: 'tuple', + components: [ + { + name: 'l2OutputOracleStartingBlockNumber', + internalType: 'uint256', + type: 'uint256', + }, + { + name: 'l2OutputOracleStartingTimestamp', + internalType: 'uint256', + type: 'uint256', + }, + ], + }, + { + name: '_optimismPortalDynamicConfig', + internalType: 'bool', + type: 'bool', + }, + ], + name: 'updateDynamicConfig', + outputs: [], }, ] as const /** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) + * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) */ -export const optimistAllowlistAddress = { - 10: '0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180', - 420: '0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180', +export const systemDictatorAddress = { + 1: '0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB', } as const /** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) + * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) */ -export const optimistAllowlistConfig = { - address: optimistAllowlistAddress, - abi: optimistAllowlistABI, +export const systemDictatorConfig = { + address: systemDictatorAddress, + abi: systemDictatorABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// OptimistInviter +// SystemDictator_goerli ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) + * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) */ -export const optimistInviterABI = [ - { - stateMutability: 'nonpayable', - type: 'constructor', - inputs: [ - { name: '_inviteGranter', internalType: 'address', type: 'address' }, - { - name: '_attestationStation', - internalType: 'contract AttestationStation', - type: 'address', - }, - ], - }, +export const systemDictatorGoerliABI = [ { type: 'event', anonymous: false, @@ -7948,355 +8293,421 @@ export const optimistInviterABI = [ anonymous: false, inputs: [ { - name: 'issuer', + name: 'previousOwner', internalType: 'address', type: 'address', indexed: true, }, { - name: 'claimer', + name: 'newOwner', internalType: 'address', type: 'address', indexed: true, }, ], - name: 'InviteClaimed', - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'ATTESTATION_STATION', - outputs: [ - { - name: '', - internalType: 'contract AttestationStation', - type: 'address', - }, - ], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'CAN_INVITE_ATTESTATION_KEY', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'CLAIMABLE_INVITE_TYPEHASH', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'OwnershipTransferred', }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'EIP712_VERSION', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + name: 'EXIT_1_NO_RETURN_STEP', + outputs: [{ name: '', internalType: 'uint8', type: 'uint8' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'INVITE_GRANTER', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'PROXY_TRANSFER_STEP', + outputs: [{ name: '', internalType: 'uint8', type: 'uint8' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'MIN_COMMITMENT_PERIOD', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_claimer', internalType: 'address', type: 'address' }, + name: 'config', + outputs: [ { - name: '_claimableInvite', - internalType: 'struct OptimistInviter.ClaimableInvite', + name: 'globalConfig', + internalType: 'struct SystemDictator.GlobalConfig', type: 'tuple', components: [ - { name: 'issuer', internalType: 'address', type: 'address' }, - { name: 'nonce', internalType: 'bytes32', type: 'bytes32' }, + { + name: 'addressManager', + internalType: 'contract AddressManager', + type: 'address', + }, + { + name: 'proxyAdmin', + internalType: 'contract ProxyAdmin', + type: 'address', + }, + { name: 'controller', internalType: 'address', type: 'address' }, + { name: 'finalOwner', internalType: 'address', type: 'address' }, + ], + }, + { + name: 'proxyAddressConfig', + internalType: 'struct SystemDictator.ProxyAddressConfig', + type: 'tuple', + components: [ + { + name: 'l2OutputOracleProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'optimismPortalProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'l1CrossDomainMessengerProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'l1StandardBridgeProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'optimismMintableERC20FactoryProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'l1ERC721BridgeProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'systemConfigProxy', + internalType: 'address', + type: 'address', + }, + ], + }, + { + name: 'implementationAddressConfig', + internalType: 'struct SystemDictator.ImplementationAddressConfig', + type: 'tuple', + components: [ + { + name: 'l2OutputOracleImpl', + internalType: 'contract L2OutputOracle', + type: 'address', + }, + { + name: 'optimismPortalImpl', + internalType: 'contract OptimismPortal', + type: 'address', + }, + { + name: 'l1CrossDomainMessengerImpl', + internalType: 'contract L1CrossDomainMessenger', + type: 'address', + }, + { + name: 'l1StandardBridgeImpl', + internalType: 'contract L1StandardBridge', + type: 'address', + }, + { + name: 'optimismMintableERC20FactoryImpl', + internalType: 'contract OptimismMintableERC20Factory', + type: 'address', + }, + { + name: 'l1ERC721BridgeImpl', + internalType: 'contract L1ERC721Bridge', + type: 'address', + }, + { + name: 'portalSenderImpl', + internalType: 'contract PortalSender', + type: 'address', + }, + { + name: 'systemConfigImpl', + internalType: 'contract SystemConfig', + type: 'address', + }, + ], + }, + { + name: 'systemConfigConfig', + internalType: 'struct SystemDictator.SystemConfigConfig', + type: 'tuple', + components: [ + { name: 'owner', internalType: 'address', type: 'address' }, + { name: 'overhead', internalType: 'uint256', type: 'uint256' }, + { name: 'scalar', internalType: 'uint256', type: 'uint256' }, + { name: 'batcherHash', internalType: 'bytes32', type: 'bytes32' }, + { name: 'gasLimit', internalType: 'uint64', type: 'uint64' }, + { + name: 'unsafeBlockSigner', + internalType: 'address', + type: 'address', + }, ], }, - { name: '_signature', internalType: 'bytes', type: 'bytes' }, - ], - name: 'claimInvite', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: '_commitment', internalType: 'bytes32', type: 'bytes32' }], - name: 'commitInvite', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - name: 'commitmentTimestamps', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: '_name', internalType: 'string', type: 'string' }], - name: 'initialize', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [{ name: '', internalType: 'address', type: 'address' }], - name: 'inviteCounts', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_accounts', internalType: 'address[]', type: 'address[]' }, - { name: '_inviteCount', internalType: 'uint256', type: 'uint256' }, ], - name: 'setInviteCounts', - outputs: [], }, { stateMutability: 'view', type: 'function', - inputs: [ - { name: '', internalType: 'address', type: 'address' }, - { name: '', internalType: 'bytes32', type: 'bytes32' }, - ], - name: 'usedNonces', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + inputs: [], + name: 'currentStep', + outputs: [{ name: '', internalType: 'uint8', type: 'uint8' }], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + name: 'dynamicConfigSet', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, -] as const - -/** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - */ -export const optimistInviterAddress = { - 10: '0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929', - 420: '0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929', -} as const - -/** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - */ -export const optimistInviterConfig = { - address: optimistInviterAddress, - abi: optimistInviterABI, -} as const - -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// PortalSender -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/** - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x0A893d9576b9cFD9EF78595963dc973238E78210) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xe7FACd39531ee3C313330E93B4d7a8B8A3c84Aa4) - */ -export const portalSenderABI = [ { stateMutability: 'nonpayable', - type: 'constructor', - inputs: [ - { - name: '_portal', - internalType: 'contract OptimismPortal', - type: 'address', - }, - ], - }, - { - stateMutability: 'view', type: 'function', inputs: [], - name: 'PORTAL', - outputs: [ - { name: '', internalType: 'contract OptimismPortal', type: 'address' }, - ], + name: 'exit1', + outputs: [], }, { stateMutability: 'nonpayable', type: 'function', inputs: [], - name: 'donate', + name: 'finalize', outputs: [], }, -] as const - -/** - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x0A893d9576b9cFD9EF78595963dc973238E78210) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xe7FACd39531ee3C313330E93B4d7a8B8A3c84Aa4) - */ -export const portalSenderAddress = { - 1: '0x0A893d9576b9cFD9EF78595963dc973238E78210', - 5: '0xe7FACd39531ee3C313330E93B4d7a8B8A3c84Aa4', -} as const - -/** - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x0A893d9576b9cFD9EF78595963dc973238E78210) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xe7FACd39531ee3C313330E93B4d7a8B8A3c84Aa4) - */ -export const portalSenderConfig = { - address: portalSenderAddress, - abi: portalSenderABI, -} as const - -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// ProtocolVersions -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) - */ -export const protocolVersionsABI = [ - { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'version', - internalType: 'uint256', - type: 'uint256', - indexed: true, - }, - { - name: 'updateType', - internalType: 'enum ProtocolVersions.UpdateType', - type: 'uint8', - indexed: true, - }, - { name: 'data', internalType: 'bytes', type: 'bytes', indexed: false }, - ], - name: 'ConfigUpdate', - }, { - type: 'event', - anonymous: false, - inputs: [ - { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, - ], - name: 'Initialized', + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'finalized', + outputs: [{ name: '', internalType: 'bool', type: 'bool' }], }, { - type: 'event', - anonymous: false, + stateMutability: 'nonpayable', + type: 'function', inputs: [ { - name: 'previousOwner', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'newOwner', - internalType: 'address', - type: 'address', - indexed: true, - }, - ], - name: 'OwnershipTransferred', - }, + name: '_config', + internalType: 'struct SystemDictator.DeployConfig', + type: 'tuple', + components: [ + { + name: 'globalConfig', + internalType: 'struct SystemDictator.GlobalConfig', + type: 'tuple', + components: [ + { + name: 'addressManager', + internalType: 'contract AddressManager', + type: 'address', + }, + { + name: 'proxyAdmin', + internalType: 'contract ProxyAdmin', + type: 'address', + }, + { name: 'controller', internalType: 'address', type: 'address' }, + { name: 'finalOwner', internalType: 'address', type: 'address' }, + ], + }, + { + name: 'proxyAddressConfig', + internalType: 'struct SystemDictator.ProxyAddressConfig', + type: 'tuple', + components: [ + { + name: 'l2OutputOracleProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'optimismPortalProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'l1CrossDomainMessengerProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'l1StandardBridgeProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'optimismMintableERC20FactoryProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'l1ERC721BridgeProxy', + internalType: 'address', + type: 'address', + }, + { + name: 'systemConfigProxy', + internalType: 'address', + type: 'address', + }, + ], + }, + { + name: 'implementationAddressConfig', + internalType: 'struct SystemDictator.ImplementationAddressConfig', + type: 'tuple', + components: [ + { + name: 'l2OutputOracleImpl', + internalType: 'contract L2OutputOracle', + type: 'address', + }, + { + name: 'optimismPortalImpl', + internalType: 'contract OptimismPortal', + type: 'address', + }, + { + name: 'l1CrossDomainMessengerImpl', + internalType: 'contract L1CrossDomainMessenger', + type: 'address', + }, + { + name: 'l1StandardBridgeImpl', + internalType: 'contract L1StandardBridge', + type: 'address', + }, + { + name: 'optimismMintableERC20FactoryImpl', + internalType: 'contract OptimismMintableERC20Factory', + type: 'address', + }, + { + name: 'l1ERC721BridgeImpl', + internalType: 'contract L1ERC721Bridge', + type: 'address', + }, + { + name: 'portalSenderImpl', + internalType: 'contract PortalSender', + type: 'address', + }, + { + name: 'systemConfigImpl', + internalType: 'contract SystemConfig', + type: 'address', + }, + ], + }, + { + name: 'systemConfigConfig', + internalType: 'struct SystemDictator.SystemConfigConfig', + type: 'tuple', + components: [ + { name: 'owner', internalType: 'address', type: 'address' }, + { name: 'overhead', internalType: 'uint256', type: 'uint256' }, + { name: 'scalar', internalType: 'uint256', type: 'uint256' }, + { name: 'batcherHash', internalType: 'bytes32', type: 'bytes32' }, + { name: 'gasLimit', internalType: 'uint64', type: 'uint64' }, + { + name: 'unsafeBlockSigner', + internalType: 'address', + type: 'address', + }, + ], + }, + ], + }, + ], + name: 'initialize', + outputs: [], + }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'RECOMMENDED_SLOT', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'l2OutputOracleDynamicConfig', + outputs: [ + { + name: 'l2OutputOracleStartingBlockNumber', + internalType: 'uint256', + type: 'uint256', + }, + { + name: 'l2OutputOracleStartingTimestamp', + internalType: 'uint256', + type: 'uint256', + }, + ], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'REQUIRED_SLOT', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], + name: 'oldL1CrossDomainMessenger', + outputs: [{ name: '', internalType: 'address', type: 'address' }], + }, + { + stateMutability: 'view', + type: 'function', + inputs: [], + name: 'owner', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [ - { name: '_owner', internalType: 'address', type: 'address' }, - { name: '_required', internalType: 'ProtocolVersion', type: 'uint256' }, - { - name: '_recommended', - internalType: 'ProtocolVersion', - type: 'uint256', - }, - ], - name: 'initialize', + inputs: [], + name: 'renounceOwnership', outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', inputs: [], - name: 'owner', - outputs: [{ name: '', internalType: 'address', type: 'address' }], + name: 'step1', + outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', inputs: [], - name: 'recommended', - outputs: [ - { name: 'out_', internalType: 'ProtocolVersion', type: 'uint256' }, - ], + name: 'step2', + outputs: [], }, { stateMutability: 'nonpayable', type: 'function', inputs: [], - name: 'renounceOwnership', + name: 'step3', outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', inputs: [], - name: 'required', - outputs: [ - { name: 'out_', internalType: 'ProtocolVersion', type: 'uint256' }, - ], + name: 'step4', + outputs: [], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [ - { - name: '_recommended', - internalType: 'ProtocolVersion', - type: 'uint256', - }, - ], - name: 'setRecommended', + inputs: [], + name: 'step5', outputs: [], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [ - { name: '_required', internalType: 'ProtocolVersion', type: 'uint256' }, - ], - name: 'setRequired', + inputs: [], + name: 'step6', outputs: [], }, { @@ -8307,38 +8718,55 @@ export const protocolVersionsABI = [ outputs: [], }, { - stateMutability: 'view', + stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + inputs: [ + { + name: '_l2OutputOracleDynamicConfig', + internalType: 'struct SystemDictator.L2OutputOracleDynamicConfig', + type: 'tuple', + components: [ + { + name: 'l2OutputOracleStartingBlockNumber', + internalType: 'uint256', + type: 'uint256', + }, + { + name: 'l2OutputOracleStartingTimestamp', + internalType: 'uint256', + type: 'uint256', + }, + ], + }, + ], + name: 'updateL2OutputOracleDynamicConfig', + outputs: [], }, ] as const /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) + * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) */ -export const protocolVersionsAddress = { - 5: '0x0C24F5098774aA366827D667494e9F889f7cFc08', +export const systemDictatorGoerliAddress = { + 5: '0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971', } as const /** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) + * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) */ -export const protocolVersionsConfig = { - address: protocolVersionsAddress, - abi: protocolVersionsABI, +export const systemDictatorGoerliConfig = { + address: systemDictatorGoerliAddress, + abi: systemDictatorGoerliABI, } as const ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// ProxyAdmin +// TeleportrWithdrawer ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) + * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) */ -export const proxyAdminABI = [ +export const teleportrWithdrawerABI = [ { stateMutability: 'nonpayable', type: 'constructor', @@ -8348,69 +8776,147 @@ export const proxyAdminABI = [ type: 'event', anonymous: false, inputs: [ + { name: 'user', internalType: 'address', type: 'address', indexed: true }, { - name: 'previousOwner', + name: 'newOwner', internalType: 'address', type: 'address', indexed: true, }, + ], + name: 'OwnerUpdated', + }, + { + type: 'event', + anonymous: false, + inputs: [ + { name: 'from', internalType: 'address', type: 'address', indexed: true }, { - name: 'newOwner', + name: 'amount', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, + ], + name: 'ReceivedETH', + }, + { + type: 'event', + anonymous: false, + inputs: [ + { + name: 'withdrawer', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'recipient', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'asset', internalType: 'address', type: 'address', indexed: true, }, + { + name: 'amount', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, ], - name: 'OwnershipTransferred', + name: 'WithdrewERC20', }, { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'addressManager', - outputs: [ - { name: '', internalType: 'contract AddressManager', type: 'address' }, + type: 'event', + anonymous: false, + inputs: [ + { + name: 'withdrawer', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'recipient', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'asset', + internalType: 'address', + type: 'address', + indexed: true, + }, + { name: 'id', internalType: 'uint256', type: 'uint256', indexed: false }, ], + name: 'WithdrewERC721', }, { - stateMutability: 'nonpayable', - type: 'function', + type: 'event', + anonymous: false, inputs: [ - { name: '_proxy', internalType: 'address payable', type: 'address' }, - { name: '_newAdmin', internalType: 'address', type: 'address' }, + { + name: 'withdrawer', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'recipient', + internalType: 'address', + type: 'address', + indexed: true, + }, + { + name: 'amount', + internalType: 'uint256', + type: 'uint256', + indexed: false, + }, ], - name: 'changeProxyAdmin', - outputs: [], + name: 'WithdrewETH', }, { - stateMutability: 'view', + stateMutability: 'payable', type: 'function', inputs: [ - { name: '_proxy', internalType: 'address payable', type: 'address' }, + { name: '_target', internalType: 'address', type: 'address' }, + { name: '_data', internalType: 'bytes', type: 'bytes' }, + { name: '_gas', internalType: 'uint256', type: 'uint256' }, + { name: '_value', internalType: 'uint256', type: 'uint256' }, + ], + name: 'CALL', + outputs: [ + { name: '', internalType: 'bool', type: 'bool' }, + { name: '', internalType: 'bytes', type: 'bytes' }, ], - name: 'getProxyAdmin', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [{ name: '_proxy', internalType: 'address', type: 'address' }], - name: 'getProxyImplementation', - outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { - stateMutability: 'view', + stateMutability: 'payable', type: 'function', - inputs: [{ name: '', internalType: 'address', type: 'address' }], - name: 'implementationName', - outputs: [{ name: '', internalType: 'string', type: 'string' }], + inputs: [ + { name: '_target', internalType: 'address', type: 'address' }, + { name: '_data', internalType: 'bytes', type: 'bytes' }, + { name: '_gas', internalType: 'uint256', type: 'uint256' }, + ], + name: 'DELEGATECALL', + outputs: [ + { name: '', internalType: 'bool', type: 'bool' }, + { name: '', internalType: 'bytes', type: 'bytes' }, + ], }, { stateMutability: 'view', type: 'function', inputs: [], - name: 'isUpgrading', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], + name: 'data', + outputs: [{ name: '', internalType: 'bytes', type: 'bytes' }], }, { stateMutability: 'view', @@ -8422,30243 +8928,1692 @@ export const proxyAdminABI = [ { stateMutability: 'view', type: 'function', - inputs: [{ name: '', internalType: 'address', type: 'address' }], - name: 'proxyType', - outputs: [ - { name: '', internalType: 'enum ProxyAdmin.ProxyType', type: 'uint8' }, - ], + inputs: [], + name: 'recipient', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [], - name: 'renounceOwnership', + inputs: [{ name: '_data', internalType: 'bytes', type: 'bytes' }], + name: 'setData', outputs: [], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [ - { name: '_name', internalType: 'string', type: 'string' }, - { name: '_address', internalType: 'address', type: 'address' }, - ], - name: 'setAddress', + inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], + name: 'setOwner', outputs: [], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [ - { - name: '_address', - internalType: 'contract AddressManager', - type: 'address', - }, - ], - name: 'setAddressManager', + inputs: [{ name: '_recipient', internalType: 'address', type: 'address' }], + name: 'setRecipient', outputs: [], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [ - { name: '_address', internalType: 'address', type: 'address' }, - { name: '_name', internalType: 'string', type: 'string' }, - ], - name: 'setImplementationName', + inputs: [{ name: '_teleportr', internalType: 'address', type: 'address' }], + name: 'setTeleportr', outputs: [], }, { - stateMutability: 'nonpayable', + stateMutability: 'view', type: 'function', - inputs: [ - { name: '_address', internalType: 'address', type: 'address' }, - { - name: '_type', - internalType: 'enum ProxyAdmin.ProxyType', - type: 'uint8', - }, - ], - name: 'setProxyType', - outputs: [], + inputs: [], + name: 'teleportr', + outputs: [{ name: '', internalType: 'address', type: 'address' }], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [{ name: '_upgrading', internalType: 'bool', type: 'bool' }], - name: 'setUpgrading', + inputs: [ + { name: '_asset', internalType: 'contract ERC20', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, + ], + name: 'withdrawERC20', outputs: [], }, { stateMutability: 'nonpayable', type: 'function', - inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], - name: 'transferOwnership', + inputs: [ + { name: '_asset', internalType: 'contract ERC20', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + ], + name: 'withdrawERC20', outputs: [], }, { stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_proxy', internalType: 'address payable', type: 'address' }, - { name: '_implementation', internalType: 'address', type: 'address' }, + { name: '_asset', internalType: 'contract ERC721', type: 'address' }, + { name: '_to', internalType: 'address', type: 'address' }, + { name: '_id', internalType: 'uint256', type: 'uint256' }, ], - name: 'upgrade', + name: 'withdrawERC721', outputs: [], }, { - stateMutability: 'payable', + stateMutability: 'nonpayable', type: 'function', inputs: [ - { name: '_proxy', internalType: 'address payable', type: 'address' }, - { name: '_implementation', internalType: 'address', type: 'address' }, - { name: '_data', internalType: 'bytes', type: 'bytes' }, - ], - name: 'upgradeAndCall', - outputs: [], - }, -] as const - -/** - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) - */ -export const proxyAdminAddress = { - 1: '0x4200000000000000000000000000000000000018', - 5: '0x4200000000000000000000000000000000000018', -} as const - -/** - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) - */ -export const proxyAdminConfig = { - address: proxyAdminAddress, - abi: proxyAdminABI, -} as const - -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// SchemaRegistry -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x6232208d66bAc2305b46b4Cb6BCB3857B298DF13) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2545fa928d5d278cA75Fd47306e4a89096ff6403) - */ -export const schemaRegistryABI = [ - { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, - { type: 'error', inputs: [], name: 'AlreadyExists' }, - { - type: 'event', - anonymous: false, - inputs: [ - { name: 'uid', internalType: 'bytes32', type: 'bytes32', indexed: true }, - { - name: 'registerer', - internalType: 'address', - type: 'address', - indexed: false, - }, - ], - name: 'Registered', - }, - { - stateMutability: 'view', - type: 'function', - inputs: [{ name: 'uid', internalType: 'bytes32', type: 'bytes32' }], - name: 'getSchema', - outputs: [ - { - name: '', - internalType: 'struct SchemaRecord', - type: 'tuple', - components: [ - { name: 'uid', internalType: 'bytes32', type: 'bytes32' }, - { - name: 'resolver', - internalType: 'contract ISchemaResolver', - type: 'address', - }, - { name: 'revocable', internalType: 'bool', type: 'bool' }, - { name: 'schema', internalType: 'string', type: 'string' }, - ], - }, - ], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: 'schema', internalType: 'string', type: 'string' }, - { - name: 'resolver', - internalType: 'contract ISchemaResolver', - type: 'address', - }, - { name: 'revocable', internalType: 'bool', type: 'bool' }, - ], - name: 'register', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], - }, -] as const - -/** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x6232208d66bAc2305b46b4Cb6BCB3857B298DF13) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2545fa928d5d278cA75Fd47306e4a89096ff6403) - */ -export const schemaRegistryAddress = { - 10: '0x6232208d66bAc2305b46b4Cb6BCB3857B298DF13', - 420: '0x2545fa928d5d278cA75Fd47306e4a89096ff6403', -} as const - -/** - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x6232208d66bAc2305b46b4Cb6BCB3857B298DF13) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2545fa928d5d278cA75Fd47306e4a89096ff6403) - */ -export const schemaRegistryConfig = { - address: schemaRegistryAddress, - abi: schemaRegistryABI, -} as const - -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// SequencerFeeVault -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000011) - */ -export const sequencerFeeVaultABI = [ - { - stateMutability: 'nonpayable', - type: 'constructor', - inputs: [{ name: '_recipient', internalType: 'address', type: 'address' }], - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'value', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - { name: 'to', internalType: 'address', type: 'address', indexed: false }, - { - name: 'from', - internalType: 'address', - type: 'address', - indexed: false, - }, - ], - name: 'Withdrawal', - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'MIN_WITHDRAWAL_AMOUNT', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'RECIPIENT', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'l1FeeWallet', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'totalProcessed', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'withdraw', - outputs: [], - }, - { stateMutability: 'payable', type: 'receive' }, -] as const - -/** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000011) - */ -export const sequencerFeeVaultAddress = { - 420: '0x4200000000000000000000000000000000000011', -} as const - -/** - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000011) - */ -export const sequencerFeeVaultConfig = { - address: sequencerFeeVaultAddress, - abi: sequencerFeeVaultABI, -} as const - -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// SystemConfig -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) - */ -export const systemConfigABI = [ - { - stateMutability: 'nonpayable', - type: 'constructor', - inputs: [ - { name: '_owner', internalType: 'address', type: 'address' }, - { name: '_overhead', internalType: 'uint256', type: 'uint256' }, - { name: '_scalar', internalType: 'uint256', type: 'uint256' }, - { name: '_batcherHash', internalType: 'bytes32', type: 'bytes32' }, - { name: '_gasLimit', internalType: 'uint64', type: 'uint64' }, - { name: '_unsafeBlockSigner', internalType: 'address', type: 'address' }, - { - name: '_config', - internalType: 'struct ResourceMetering.ResourceConfig', - type: 'tuple', - components: [ - { name: 'maxResourceLimit', internalType: 'uint32', type: 'uint32' }, - { - name: 'elasticityMultiplier', - internalType: 'uint8', - type: 'uint8', - }, - { - name: 'baseFeeMaxChangeDenominator', - internalType: 'uint8', - type: 'uint8', - }, - { name: 'minimumBaseFee', internalType: 'uint32', type: 'uint32' }, - { name: 'systemTxMaxGas', internalType: 'uint32', type: 'uint32' }, - { name: 'maximumBaseFee', internalType: 'uint128', type: 'uint128' }, - ], - }, - ], - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'version', - internalType: 'uint256', - type: 'uint256', - indexed: true, - }, - { - name: 'updateType', - internalType: 'enum SystemConfig.UpdateType', - type: 'uint8', - indexed: true, - }, - { name: 'data', internalType: 'bytes', type: 'bytes', indexed: false }, - ], - name: 'ConfigUpdate', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, - ], - name: 'Initialized', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'previousOwner', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'newOwner', - internalType: 'address', - type: 'address', - indexed: true, - }, - ], - name: 'OwnershipTransferred', - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'UNSAFE_BLOCK_SIGNER_SLOT', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'batcherHash', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'gasLimit', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_owner', internalType: 'address', type: 'address' }, - { name: '_overhead', internalType: 'uint256', type: 'uint256' }, - { name: '_scalar', internalType: 'uint256', type: 'uint256' }, - { name: '_batcherHash', internalType: 'bytes32', type: 'bytes32' }, - { name: '_gasLimit', internalType: 'uint64', type: 'uint64' }, - { name: '_unsafeBlockSigner', internalType: 'address', type: 'address' }, - { - name: '_config', - internalType: 'struct ResourceMetering.ResourceConfig', - type: 'tuple', - components: [ - { name: 'maxResourceLimit', internalType: 'uint32', type: 'uint32' }, - { - name: 'elasticityMultiplier', - internalType: 'uint8', - type: 'uint8', - }, - { - name: 'baseFeeMaxChangeDenominator', - internalType: 'uint8', - type: 'uint8', - }, - { name: 'minimumBaseFee', internalType: 'uint32', type: 'uint32' }, - { name: 'systemTxMaxGas', internalType: 'uint32', type: 'uint32' }, - { name: 'maximumBaseFee', internalType: 'uint128', type: 'uint128' }, - ], - }, - ], - name: 'initialize', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'minimumGasLimit', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'overhead', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'owner', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'renounceOwnership', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'resourceConfig', - outputs: [ - { - name: '', - internalType: 'struct ResourceMetering.ResourceConfig', - type: 'tuple', - components: [ - { name: 'maxResourceLimit', internalType: 'uint32', type: 'uint32' }, - { - name: 'elasticityMultiplier', - internalType: 'uint8', - type: 'uint8', - }, - { - name: 'baseFeeMaxChangeDenominator', - internalType: 'uint8', - type: 'uint8', - }, - { name: 'minimumBaseFee', internalType: 'uint32', type: 'uint32' }, - { name: 'systemTxMaxGas', internalType: 'uint32', type: 'uint32' }, - { name: 'maximumBaseFee', internalType: 'uint128', type: 'uint128' }, - ], - }, - ], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'scalar', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_batcherHash', internalType: 'bytes32', type: 'bytes32' }, - ], - name: 'setBatcherHash', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_overhead', internalType: 'uint256', type: 'uint256' }, - { name: '_scalar', internalType: 'uint256', type: 'uint256' }, - ], - name: 'setGasConfig', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: '_gasLimit', internalType: 'uint64', type: 'uint64' }], - name: 'setGasLimit', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { - name: '_config', - internalType: 'struct ResourceMetering.ResourceConfig', - type: 'tuple', - components: [ - { name: 'maxResourceLimit', internalType: 'uint32', type: 'uint32' }, - { - name: 'elasticityMultiplier', - internalType: 'uint8', - type: 'uint8', - }, - { - name: 'baseFeeMaxChangeDenominator', - internalType: 'uint8', - type: 'uint8', - }, - { name: 'minimumBaseFee', internalType: 'uint32', type: 'uint32' }, - { name: 'systemTxMaxGas', internalType: 'uint32', type: 'uint32' }, - { name: 'maximumBaseFee', internalType: 'uint128', type: 'uint128' }, - ], - }, - ], - name: 'setResourceConfig', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_unsafeBlockSigner', internalType: 'address', type: 'address' }, - ], - name: 'setUnsafeBlockSigner', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], - name: 'transferOwnership', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'unsafeBlockSigner', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], - }, -] as const - -/** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) - */ -export const systemConfigAddress = { - 1: '0x229047fed2591dbec1eF1118d64F7aF3dB9EB290', -} as const - -/** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) - */ -export const systemConfigConfig = { - address: systemConfigAddress, - abi: systemConfigABI, -} as const - -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// SystemConfig_goerli -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export const systemConfigGoerliABI = [ - { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'version', - internalType: 'uint256', - type: 'uint256', - indexed: true, - }, - { - name: 'updateType', - internalType: 'enum SystemConfig.UpdateType', - type: 'uint8', - indexed: true, - }, - { name: 'data', internalType: 'bytes', type: 'bytes', indexed: false }, - ], - name: 'ConfigUpdate', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, - ], - name: 'Initialized', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'previousOwner', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'newOwner', - internalType: 'address', - type: 'address', - indexed: true, - }, - ], - name: 'OwnershipTransferred', - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'BATCH_INBOX_SLOT', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'L1_CROSS_DOMAIN_MESSENGER_SLOT', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'L1_ERC_721_BRIDGE_SLOT', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'L1_STANDARD_BRIDGE_SLOT', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'L2_OUTPUT_ORACLE_SLOT', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'OPTIMISM_MINTABLE_ERC20_FACTORY_SLOT', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'OPTIMISM_PORTAL_SLOT', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'UNSAFE_BLOCK_SIGNER_SLOT', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'batchInbox', - outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'batcherHash', - outputs: [{ name: '', internalType: 'bytes32', type: 'bytes32' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'gasLimit', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_owner', internalType: 'address', type: 'address' }, - { name: '_overhead', internalType: 'uint256', type: 'uint256' }, - { name: '_scalar', internalType: 'uint256', type: 'uint256' }, - { name: '_batcherHash', internalType: 'bytes32', type: 'bytes32' }, - { name: '_gasLimit', internalType: 'uint64', type: 'uint64' }, - { name: '_unsafeBlockSigner', internalType: 'address', type: 'address' }, - { - name: '_config', - internalType: 'struct ResourceMetering.ResourceConfig', - type: 'tuple', - components: [ - { name: 'maxResourceLimit', internalType: 'uint32', type: 'uint32' }, - { - name: 'elasticityMultiplier', - internalType: 'uint8', - type: 'uint8', - }, - { - name: 'baseFeeMaxChangeDenominator', - internalType: 'uint8', - type: 'uint8', - }, - { name: 'minimumBaseFee', internalType: 'uint32', type: 'uint32' }, - { name: 'systemTxMaxGas', internalType: 'uint32', type: 'uint32' }, - { name: 'maximumBaseFee', internalType: 'uint128', type: 'uint128' }, - ], - }, - { name: '_startBlock', internalType: 'uint256', type: 'uint256' }, - { name: '_batchInbox', internalType: 'address', type: 'address' }, - { - name: '_addresses', - internalType: 'struct SystemConfig.Addresses', - type: 'tuple', - components: [ - { - name: 'l1CrossDomainMessenger', - internalType: 'address', - type: 'address', - }, - { name: 'l1ERC721Bridge', internalType: 'address', type: 'address' }, - { - name: 'l1StandardBridge', - internalType: 'address', - type: 'address', - }, - { name: 'l2OutputOracle', internalType: 'address', type: 'address' }, - { name: 'optimismPortal', internalType: 'address', type: 'address' }, - { - name: 'optimismMintableERC20Factory', - internalType: 'address', - type: 'address', - }, - ], - }, - ], - name: 'initialize', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'l1CrossDomainMessenger', - outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'l1ERC721Bridge', - outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'l1StandardBridge', - outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'l2OutputOracle', - outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'minimumGasLimit', - outputs: [{ name: '', internalType: 'uint64', type: 'uint64' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'optimismMintableERC20Factory', - outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'optimismPortal', - outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'overhead', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'owner', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'renounceOwnership', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'resourceConfig', - outputs: [ - { - name: '', - internalType: 'struct ResourceMetering.ResourceConfig', - type: 'tuple', - components: [ - { name: 'maxResourceLimit', internalType: 'uint32', type: 'uint32' }, - { - name: 'elasticityMultiplier', - internalType: 'uint8', - type: 'uint8', - }, - { - name: 'baseFeeMaxChangeDenominator', - internalType: 'uint8', - type: 'uint8', - }, - { name: 'minimumBaseFee', internalType: 'uint32', type: 'uint32' }, - { name: 'systemTxMaxGas', internalType: 'uint32', type: 'uint32' }, - { name: 'maximumBaseFee', internalType: 'uint128', type: 'uint128' }, - ], - }, - ], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'scalar', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_batcherHash', internalType: 'bytes32', type: 'bytes32' }, - ], - name: 'setBatcherHash', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_overhead', internalType: 'uint256', type: 'uint256' }, - { name: '_scalar', internalType: 'uint256', type: 'uint256' }, - ], - name: 'setGasConfig', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: '_gasLimit', internalType: 'uint64', type: 'uint64' }], - name: 'setGasLimit', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { - name: '_config', - internalType: 'struct ResourceMetering.ResourceConfig', - type: 'tuple', - components: [ - { name: 'maxResourceLimit', internalType: 'uint32', type: 'uint32' }, - { - name: 'elasticityMultiplier', - internalType: 'uint8', - type: 'uint8', - }, - { - name: 'baseFeeMaxChangeDenominator', - internalType: 'uint8', - type: 'uint8', - }, - { name: 'minimumBaseFee', internalType: 'uint32', type: 'uint32' }, - { name: 'systemTxMaxGas', internalType: 'uint32', type: 'uint32' }, - { name: 'maximumBaseFee', internalType: 'uint128', type: 'uint128' }, - ], - }, - ], - name: 'setResourceConfig', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_unsafeBlockSigner', internalType: 'address', type: 'address' }, - ], - name: 'setUnsafeBlockSigner', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'startBlock', - outputs: [{ name: '', internalType: 'uint256', type: 'uint256' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], - name: 'transferOwnership', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'unsafeBlockSigner', - outputs: [{ name: 'addr_', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'version', - outputs: [{ name: '', internalType: 'string', type: 'string' }], - }, -] as const - -/** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export const systemConfigGoerliAddress = { - 5: '0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60', -} as const - -/** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export const systemConfigGoerliConfig = { - address: systemConfigGoerliAddress, - abi: systemConfigGoerliABI, -} as const - -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// SystemDictator -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) - */ -export const systemDictatorABI = [ - { stateMutability: 'nonpayable', type: 'constructor', inputs: [] }, - { - type: 'event', - anonymous: false, - inputs: [ - { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, - ], - name: 'Initialized', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'previousOwner', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'newOwner', - internalType: 'address', - type: 'address', - indexed: true, - }, - ], - name: 'OwnershipTransferred', - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'EXIT_1_NO_RETURN_STEP', - outputs: [{ name: '', internalType: 'uint8', type: 'uint8' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'PROXY_TRANSFER_STEP', - outputs: [{ name: '', internalType: 'uint8', type: 'uint8' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'config', - outputs: [ - { - name: 'globalConfig', - internalType: 'struct SystemDictator.GlobalConfig', - type: 'tuple', - components: [ - { - name: 'addressManager', - internalType: 'contract AddressManager', - type: 'address', - }, - { - name: 'proxyAdmin', - internalType: 'contract ProxyAdmin', - type: 'address', - }, - { name: 'controller', internalType: 'address', type: 'address' }, - { name: 'finalOwner', internalType: 'address', type: 'address' }, - ], - }, - { - name: 'proxyAddressConfig', - internalType: 'struct SystemDictator.ProxyAddressConfig', - type: 'tuple', - components: [ - { - name: 'l2OutputOracleProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'optimismPortalProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'l1CrossDomainMessengerProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'l1StandardBridgeProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'optimismMintableERC20FactoryProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'l1ERC721BridgeProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'systemConfigProxy', - internalType: 'address', - type: 'address', - }, - ], - }, - { - name: 'implementationAddressConfig', - internalType: 'struct SystemDictator.ImplementationAddressConfig', - type: 'tuple', - components: [ - { - name: 'l2OutputOracleImpl', - internalType: 'contract L2OutputOracle', - type: 'address', - }, - { - name: 'optimismPortalImpl', - internalType: 'contract OptimismPortal', - type: 'address', - }, - { - name: 'l1CrossDomainMessengerImpl', - internalType: 'contract L1CrossDomainMessenger', - type: 'address', - }, - { - name: 'l1StandardBridgeImpl', - internalType: 'contract L1StandardBridge', - type: 'address', - }, - { - name: 'optimismMintableERC20FactoryImpl', - internalType: 'contract OptimismMintableERC20Factory', - type: 'address', - }, - { - name: 'l1ERC721BridgeImpl', - internalType: 'contract L1ERC721Bridge', - type: 'address', - }, - { - name: 'portalSenderImpl', - internalType: 'contract PortalSender', - type: 'address', - }, - { - name: 'systemConfigImpl', - internalType: 'contract SystemConfig', - type: 'address', - }, - ], - }, - { - name: 'systemConfigConfig', - internalType: 'struct SystemDictator.SystemConfigConfig', - type: 'tuple', - components: [ - { name: 'owner', internalType: 'address', type: 'address' }, - { name: 'overhead', internalType: 'uint256', type: 'uint256' }, - { name: 'scalar', internalType: 'uint256', type: 'uint256' }, - { name: 'batcherHash', internalType: 'bytes32', type: 'bytes32' }, - { name: 'gasLimit', internalType: 'uint64', type: 'uint64' }, - { - name: 'unsafeBlockSigner', - internalType: 'address', - type: 'address', - }, - { - name: 'resourceConfig', - internalType: 'struct ResourceMetering.ResourceConfig', - type: 'tuple', - components: [ - { - name: 'maxResourceLimit', - internalType: 'uint32', - type: 'uint32', - }, - { - name: 'elasticityMultiplier', - internalType: 'uint8', - type: 'uint8', - }, - { - name: 'baseFeeMaxChangeDenominator', - internalType: 'uint8', - type: 'uint8', - }, - { - name: 'minimumBaseFee', - internalType: 'uint32', - type: 'uint32', - }, - { - name: 'systemTxMaxGas', - internalType: 'uint32', - type: 'uint32', - }, - { - name: 'maximumBaseFee', - internalType: 'uint128', - type: 'uint128', - }, - ], - }, - ], - }, - ], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'currentStep', - outputs: [{ name: '', internalType: 'uint8', type: 'uint8' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'dynamicConfigSet', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'exit1', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'exited', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'finalize', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'finalized', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { - name: '_config', - internalType: 'struct SystemDictator.DeployConfig', - type: 'tuple', - components: [ - { - name: 'globalConfig', - internalType: 'struct SystemDictator.GlobalConfig', - type: 'tuple', - components: [ - { - name: 'addressManager', - internalType: 'contract AddressManager', - type: 'address', - }, - { - name: 'proxyAdmin', - internalType: 'contract ProxyAdmin', - type: 'address', - }, - { name: 'controller', internalType: 'address', type: 'address' }, - { name: 'finalOwner', internalType: 'address', type: 'address' }, - ], - }, - { - name: 'proxyAddressConfig', - internalType: 'struct SystemDictator.ProxyAddressConfig', - type: 'tuple', - components: [ - { - name: 'l2OutputOracleProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'optimismPortalProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'l1CrossDomainMessengerProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'l1StandardBridgeProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'optimismMintableERC20FactoryProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'l1ERC721BridgeProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'systemConfigProxy', - internalType: 'address', - type: 'address', - }, - ], - }, - { - name: 'implementationAddressConfig', - internalType: 'struct SystemDictator.ImplementationAddressConfig', - type: 'tuple', - components: [ - { - name: 'l2OutputOracleImpl', - internalType: 'contract L2OutputOracle', - type: 'address', - }, - { - name: 'optimismPortalImpl', - internalType: 'contract OptimismPortal', - type: 'address', - }, - { - name: 'l1CrossDomainMessengerImpl', - internalType: 'contract L1CrossDomainMessenger', - type: 'address', - }, - { - name: 'l1StandardBridgeImpl', - internalType: 'contract L1StandardBridge', - type: 'address', - }, - { - name: 'optimismMintableERC20FactoryImpl', - internalType: 'contract OptimismMintableERC20Factory', - type: 'address', - }, - { - name: 'l1ERC721BridgeImpl', - internalType: 'contract L1ERC721Bridge', - type: 'address', - }, - { - name: 'portalSenderImpl', - internalType: 'contract PortalSender', - type: 'address', - }, - { - name: 'systemConfigImpl', - internalType: 'contract SystemConfig', - type: 'address', - }, - ], - }, - { - name: 'systemConfigConfig', - internalType: 'struct SystemDictator.SystemConfigConfig', - type: 'tuple', - components: [ - { name: 'owner', internalType: 'address', type: 'address' }, - { name: 'overhead', internalType: 'uint256', type: 'uint256' }, - { name: 'scalar', internalType: 'uint256', type: 'uint256' }, - { name: 'batcherHash', internalType: 'bytes32', type: 'bytes32' }, - { name: 'gasLimit', internalType: 'uint64', type: 'uint64' }, - { - name: 'unsafeBlockSigner', - internalType: 'address', - type: 'address', - }, - { - name: 'resourceConfig', - internalType: 'struct ResourceMetering.ResourceConfig', - type: 'tuple', - components: [ - { - name: 'maxResourceLimit', - internalType: 'uint32', - type: 'uint32', - }, - { - name: 'elasticityMultiplier', - internalType: 'uint8', - type: 'uint8', - }, - { - name: 'baseFeeMaxChangeDenominator', - internalType: 'uint8', - type: 'uint8', - }, - { - name: 'minimumBaseFee', - internalType: 'uint32', - type: 'uint32', - }, - { - name: 'systemTxMaxGas', - internalType: 'uint32', - type: 'uint32', - }, - { - name: 'maximumBaseFee', - internalType: 'uint128', - type: 'uint128', - }, - ], - }, - ], - }, - ], - }, - ], - name: 'initialize', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'l2OutputOracleDynamicConfig', - outputs: [ - { - name: 'l2OutputOracleStartingBlockNumber', - internalType: 'uint256', - type: 'uint256', - }, - { - name: 'l2OutputOracleStartingTimestamp', - internalType: 'uint256', - type: 'uint256', - }, - ], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'oldL1CrossDomainMessenger', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'optimismPortalDynamicConfig', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'owner', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'phase1', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'phase2', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'renounceOwnership', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'step1', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'step2', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'step3', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'step4', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'step5', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], - name: 'transferOwnership', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { - name: '_l2OutputOracleDynamicConfig', - internalType: 'struct SystemDictator.L2OutputOracleDynamicConfig', - type: 'tuple', - components: [ - { - name: 'l2OutputOracleStartingBlockNumber', - internalType: 'uint256', - type: 'uint256', - }, - { - name: 'l2OutputOracleStartingTimestamp', - internalType: 'uint256', - type: 'uint256', - }, - ], - }, - { - name: '_optimismPortalDynamicConfig', - internalType: 'bool', - type: 'bool', - }, - ], - name: 'updateDynamicConfig', - outputs: [], - }, -] as const - -/** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) - */ -export const systemDictatorAddress = { - 1: '0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB', -} as const - -/** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) - */ -export const systemDictatorConfig = { - address: systemDictatorAddress, - abi: systemDictatorABI, -} as const - -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// SystemDictator_goerli -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) - */ -export const systemDictatorGoerliABI = [ - { - type: 'event', - anonymous: false, - inputs: [ - { name: 'version', internalType: 'uint8', type: 'uint8', indexed: false }, - ], - name: 'Initialized', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'previousOwner', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'newOwner', - internalType: 'address', - type: 'address', - indexed: true, - }, - ], - name: 'OwnershipTransferred', - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'EXIT_1_NO_RETURN_STEP', - outputs: [{ name: '', internalType: 'uint8', type: 'uint8' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'PROXY_TRANSFER_STEP', - outputs: [{ name: '', internalType: 'uint8', type: 'uint8' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'config', - outputs: [ - { - name: 'globalConfig', - internalType: 'struct SystemDictator.GlobalConfig', - type: 'tuple', - components: [ - { - name: 'addressManager', - internalType: 'contract AddressManager', - type: 'address', - }, - { - name: 'proxyAdmin', - internalType: 'contract ProxyAdmin', - type: 'address', - }, - { name: 'controller', internalType: 'address', type: 'address' }, - { name: 'finalOwner', internalType: 'address', type: 'address' }, - ], - }, - { - name: 'proxyAddressConfig', - internalType: 'struct SystemDictator.ProxyAddressConfig', - type: 'tuple', - components: [ - { - name: 'l2OutputOracleProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'optimismPortalProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'l1CrossDomainMessengerProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'l1StandardBridgeProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'optimismMintableERC20FactoryProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'l1ERC721BridgeProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'systemConfigProxy', - internalType: 'address', - type: 'address', - }, - ], - }, - { - name: 'implementationAddressConfig', - internalType: 'struct SystemDictator.ImplementationAddressConfig', - type: 'tuple', - components: [ - { - name: 'l2OutputOracleImpl', - internalType: 'contract L2OutputOracle', - type: 'address', - }, - { - name: 'optimismPortalImpl', - internalType: 'contract OptimismPortal', - type: 'address', - }, - { - name: 'l1CrossDomainMessengerImpl', - internalType: 'contract L1CrossDomainMessenger', - type: 'address', - }, - { - name: 'l1StandardBridgeImpl', - internalType: 'contract L1StandardBridge', - type: 'address', - }, - { - name: 'optimismMintableERC20FactoryImpl', - internalType: 'contract OptimismMintableERC20Factory', - type: 'address', - }, - { - name: 'l1ERC721BridgeImpl', - internalType: 'contract L1ERC721Bridge', - type: 'address', - }, - { - name: 'portalSenderImpl', - internalType: 'contract PortalSender', - type: 'address', - }, - { - name: 'systemConfigImpl', - internalType: 'contract SystemConfig', - type: 'address', - }, - ], - }, - { - name: 'systemConfigConfig', - internalType: 'struct SystemDictator.SystemConfigConfig', - type: 'tuple', - components: [ - { name: 'owner', internalType: 'address', type: 'address' }, - { name: 'overhead', internalType: 'uint256', type: 'uint256' }, - { name: 'scalar', internalType: 'uint256', type: 'uint256' }, - { name: 'batcherHash', internalType: 'bytes32', type: 'bytes32' }, - { name: 'gasLimit', internalType: 'uint64', type: 'uint64' }, - { - name: 'unsafeBlockSigner', - internalType: 'address', - type: 'address', - }, - ], - }, - ], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'currentStep', - outputs: [{ name: '', internalType: 'uint8', type: 'uint8' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'dynamicConfigSet', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'exit1', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'finalize', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'finalized', - outputs: [{ name: '', internalType: 'bool', type: 'bool' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { - name: '_config', - internalType: 'struct SystemDictator.DeployConfig', - type: 'tuple', - components: [ - { - name: 'globalConfig', - internalType: 'struct SystemDictator.GlobalConfig', - type: 'tuple', - components: [ - { - name: 'addressManager', - internalType: 'contract AddressManager', - type: 'address', - }, - { - name: 'proxyAdmin', - internalType: 'contract ProxyAdmin', - type: 'address', - }, - { name: 'controller', internalType: 'address', type: 'address' }, - { name: 'finalOwner', internalType: 'address', type: 'address' }, - ], - }, - { - name: 'proxyAddressConfig', - internalType: 'struct SystemDictator.ProxyAddressConfig', - type: 'tuple', - components: [ - { - name: 'l2OutputOracleProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'optimismPortalProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'l1CrossDomainMessengerProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'l1StandardBridgeProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'optimismMintableERC20FactoryProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'l1ERC721BridgeProxy', - internalType: 'address', - type: 'address', - }, - { - name: 'systemConfigProxy', - internalType: 'address', - type: 'address', - }, - ], - }, - { - name: 'implementationAddressConfig', - internalType: 'struct SystemDictator.ImplementationAddressConfig', - type: 'tuple', - components: [ - { - name: 'l2OutputOracleImpl', - internalType: 'contract L2OutputOracle', - type: 'address', - }, - { - name: 'optimismPortalImpl', - internalType: 'contract OptimismPortal', - type: 'address', - }, - { - name: 'l1CrossDomainMessengerImpl', - internalType: 'contract L1CrossDomainMessenger', - type: 'address', - }, - { - name: 'l1StandardBridgeImpl', - internalType: 'contract L1StandardBridge', - type: 'address', - }, - { - name: 'optimismMintableERC20FactoryImpl', - internalType: 'contract OptimismMintableERC20Factory', - type: 'address', - }, - { - name: 'l1ERC721BridgeImpl', - internalType: 'contract L1ERC721Bridge', - type: 'address', - }, - { - name: 'portalSenderImpl', - internalType: 'contract PortalSender', - type: 'address', - }, - { - name: 'systemConfigImpl', - internalType: 'contract SystemConfig', - type: 'address', - }, - ], - }, - { - name: 'systemConfigConfig', - internalType: 'struct SystemDictator.SystemConfigConfig', - type: 'tuple', - components: [ - { name: 'owner', internalType: 'address', type: 'address' }, - { name: 'overhead', internalType: 'uint256', type: 'uint256' }, - { name: 'scalar', internalType: 'uint256', type: 'uint256' }, - { name: 'batcherHash', internalType: 'bytes32', type: 'bytes32' }, - { name: 'gasLimit', internalType: 'uint64', type: 'uint64' }, - { - name: 'unsafeBlockSigner', - internalType: 'address', - type: 'address', - }, - ], - }, - ], - }, - ], - name: 'initialize', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'l2OutputOracleDynamicConfig', - outputs: [ - { - name: 'l2OutputOracleStartingBlockNumber', - internalType: 'uint256', - type: 'uint256', - }, - { - name: 'l2OutputOracleStartingTimestamp', - internalType: 'uint256', - type: 'uint256', - }, - ], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'oldL1CrossDomainMessenger', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'owner', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'renounceOwnership', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'step1', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'step2', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'step3', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'step4', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'step5', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'step6', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], - name: 'transferOwnership', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { - name: '_l2OutputOracleDynamicConfig', - internalType: 'struct SystemDictator.L2OutputOracleDynamicConfig', - type: 'tuple', - components: [ - { - name: 'l2OutputOracleStartingBlockNumber', - internalType: 'uint256', - type: 'uint256', - }, - { - name: 'l2OutputOracleStartingTimestamp', - internalType: 'uint256', - type: 'uint256', - }, - ], - }, - ], - name: 'updateL2OutputOracleDynamicConfig', - outputs: [], - }, -] as const - -/** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) - */ -export const systemDictatorGoerliAddress = { - 5: '0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971', -} as const - -/** - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) - */ -export const systemDictatorGoerliConfig = { - address: systemDictatorGoerliAddress, - abi: systemDictatorGoerliABI, -} as const - -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// TeleportrWithdrawer -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) - */ -export const teleportrWithdrawerABI = [ - { - stateMutability: 'nonpayable', - type: 'constructor', - inputs: [{ name: '_owner', internalType: 'address', type: 'address' }], - }, - { - type: 'event', - anonymous: false, - inputs: [ - { name: 'user', internalType: 'address', type: 'address', indexed: true }, - { - name: 'newOwner', - internalType: 'address', - type: 'address', - indexed: true, - }, - ], - name: 'OwnerUpdated', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { name: 'from', internalType: 'address', type: 'address', indexed: true }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - ], - name: 'ReceivedETH', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'withdrawer', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'recipient', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'asset', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - ], - name: 'WithdrewERC20', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'withdrawer', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'recipient', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'asset', - internalType: 'address', - type: 'address', - indexed: true, - }, - { name: 'id', internalType: 'uint256', type: 'uint256', indexed: false }, - ], - name: 'WithdrewERC721', - }, - { - type: 'event', - anonymous: false, - inputs: [ - { - name: 'withdrawer', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'recipient', - internalType: 'address', - type: 'address', - indexed: true, - }, - { - name: 'amount', - internalType: 'uint256', - type: 'uint256', - indexed: false, - }, - ], - name: 'WithdrewETH', - }, - { - stateMutability: 'payable', - type: 'function', - inputs: [ - { name: '_target', internalType: 'address', type: 'address' }, - { name: '_data', internalType: 'bytes', type: 'bytes' }, - { name: '_gas', internalType: 'uint256', type: 'uint256' }, - { name: '_value', internalType: 'uint256', type: 'uint256' }, - ], - name: 'CALL', - outputs: [ - { name: '', internalType: 'bool', type: 'bool' }, - { name: '', internalType: 'bytes', type: 'bytes' }, - ], - }, - { - stateMutability: 'payable', - type: 'function', - inputs: [ - { name: '_target', internalType: 'address', type: 'address' }, - { name: '_data', internalType: 'bytes', type: 'bytes' }, - { name: '_gas', internalType: 'uint256', type: 'uint256' }, - ], - name: 'DELEGATECALL', - outputs: [ - { name: '', internalType: 'bool', type: 'bool' }, - { name: '', internalType: 'bytes', type: 'bytes' }, - ], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'data', - outputs: [{ name: '', internalType: 'bytes', type: 'bytes' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'owner', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'recipient', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: '_data', internalType: 'bytes', type: 'bytes' }], - name: 'setData', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: 'newOwner', internalType: 'address', type: 'address' }], - name: 'setOwner', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: '_recipient', internalType: 'address', type: 'address' }], - name: 'setRecipient', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: '_teleportr', internalType: 'address', type: 'address' }], - name: 'setTeleportr', - outputs: [], - }, - { - stateMutability: 'view', - type: 'function', - inputs: [], - name: 'teleportr', - outputs: [{ name: '', internalType: 'address', type: 'address' }], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_asset', internalType: 'contract ERC20', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - ], - name: 'withdrawERC20', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_asset', internalType: 'contract ERC20', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - ], - name: 'withdrawERC20', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_asset', internalType: 'contract ERC721', type: 'address' }, - { name: '_to', internalType: 'address', type: 'address' }, - { name: '_id', internalType: 'uint256', type: 'uint256' }, - ], - name: 'withdrawERC721', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [ - { name: '_to', internalType: 'address payable', type: 'address' }, - { name: '_amount', internalType: 'uint256', type: 'uint256' }, - ], - name: 'withdrawETH', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [{ name: '_to', internalType: 'address payable', type: 'address' }], - name: 'withdrawETH', - outputs: [], - }, - { - stateMutability: 'nonpayable', - type: 'function', - inputs: [], - name: 'withdrawFromTeleportr', - outputs: [], - }, - { stateMutability: 'payable', type: 'receive' }, -] as const - -/** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) - */ -export const teleportrWithdrawerAddress = { - 1: '0x78A25524D90E3D0596558fb43789bD800a5c3007', -} as const - -/** - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) - */ -export const teleportrWithdrawerConfig = { - address: teleportrWithdrawerAddress, - abi: teleportrWithdrawerABI, -} as const - -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// eslintIgnore -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -// React -////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link addressManagerABI}__. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdE1FCfB0851916CA5101820A69b13a4E276bd81F) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xa6f73589243a6A7a9023b1Fa0651b1d89c177111) - */ -export function useAddressManagerRead< - TFunctionName extends string, - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof addressManagerAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: addressManagerABI, - address: - addressManagerAddress[chainId as keyof typeof addressManagerAddress], - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link addressManagerABI}__ and `functionName` set to `"getAddress"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdE1FCfB0851916CA5101820A69b13a4E276bd81F) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xa6f73589243a6A7a9023b1Fa0651b1d89c177111) - */ -export function useAddressManagerGetAddress< - TFunctionName extends 'getAddress', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof addressManagerAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: addressManagerABI, - address: - addressManagerAddress[chainId as keyof typeof addressManagerAddress], - functionName: 'getAddress', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link addressManagerABI}__ and `functionName` set to `"owner"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdE1FCfB0851916CA5101820A69b13a4E276bd81F) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xa6f73589243a6A7a9023b1Fa0651b1d89c177111) - */ -export function useAddressManagerOwner< - TFunctionName extends 'owner', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof addressManagerAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: addressManagerABI, - address: - addressManagerAddress[chainId as keyof typeof addressManagerAddress], - functionName: 'owner', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link addressManagerABI}__. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdE1FCfB0851916CA5101820A69b13a4E276bd81F) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xa6f73589243a6A7a9023b1Fa0651b1d89c177111) - */ -export function useAddressManagerWrite< - TFunctionName extends string, - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof addressManagerAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof addressManagerABI, - string - >['request']['abi'], - TFunctionName, - TMode - > & { address?: Address; chainId?: TChainId } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: addressManagerABI, - address: - addressManagerAddress[chainId as keyof typeof addressManagerAddress], - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link addressManagerABI}__ and `functionName` set to `"renounceOwnership"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdE1FCfB0851916CA5101820A69b13a4E276bd81F) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xa6f73589243a6A7a9023b1Fa0651b1d89c177111) - */ -export function useAddressManagerRenounceOwnership< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof addressManagerAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof addressManagerABI, - 'renounceOwnership' - >['request']['abi'], - 'renounceOwnership', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'renounceOwnership' - } - : UseContractWriteConfig< - typeof addressManagerABI, - 'renounceOwnership', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'renounceOwnership' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite( - { - abi: addressManagerABI, - address: - addressManagerAddress[chainId as keyof typeof addressManagerAddress], - functionName: 'renounceOwnership', - ...config, - } as any - ) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link addressManagerABI}__ and `functionName` set to `"setAddress"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdE1FCfB0851916CA5101820A69b13a4E276bd81F) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xa6f73589243a6A7a9023b1Fa0651b1d89c177111) - */ -export function useAddressManagerSetAddress< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof addressManagerAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof addressManagerABI, - 'setAddress' - >['request']['abi'], - 'setAddress', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'setAddress' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'setAddress' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: addressManagerABI, - address: - addressManagerAddress[chainId as keyof typeof addressManagerAddress], - functionName: 'setAddress', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link addressManagerABI}__ and `functionName` set to `"transferOwnership"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdE1FCfB0851916CA5101820A69b13a4E276bd81F) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xa6f73589243a6A7a9023b1Fa0651b1d89c177111) - */ -export function useAddressManagerTransferOwnership< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof addressManagerAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof addressManagerABI, - 'transferOwnership' - >['request']['abi'], - 'transferOwnership', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'transferOwnership' - } - : UseContractWriteConfig< - typeof addressManagerABI, - 'transferOwnership', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'transferOwnership' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite( - { - abi: addressManagerABI, - address: - addressManagerAddress[chainId as keyof typeof addressManagerAddress], - functionName: 'transferOwnership', - ...config, - } as any - ) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link addressManagerABI}__. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdE1FCfB0851916CA5101820A69b13a4E276bd81F) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xa6f73589243a6A7a9023b1Fa0651b1d89c177111) - */ -export function usePrepareAddressManagerWrite( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof addressManagerAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: addressManagerABI, - address: - addressManagerAddress[chainId as keyof typeof addressManagerAddress], - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link addressManagerABI}__ and `functionName` set to `"renounceOwnership"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdE1FCfB0851916CA5101820A69b13a4E276bd81F) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xa6f73589243a6A7a9023b1Fa0651b1d89c177111) - */ -export function usePrepareAddressManagerRenounceOwnership( - config: Omit< - UsePrepareContractWriteConfig< - typeof addressManagerABI, - 'renounceOwnership' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof addressManagerAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: addressManagerABI, - address: - addressManagerAddress[chainId as keyof typeof addressManagerAddress], - functionName: 'renounceOwnership', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link addressManagerABI}__ and `functionName` set to `"setAddress"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdE1FCfB0851916CA5101820A69b13a4E276bd81F) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xa6f73589243a6A7a9023b1Fa0651b1d89c177111) - */ -export function usePrepareAddressManagerSetAddress( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof addressManagerAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: addressManagerABI, - address: - addressManagerAddress[chainId as keyof typeof addressManagerAddress], - functionName: 'setAddress', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link addressManagerABI}__ and `functionName` set to `"transferOwnership"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdE1FCfB0851916CA5101820A69b13a4E276bd81F) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xa6f73589243a6A7a9023b1Fa0651b1d89c177111) - */ -export function usePrepareAddressManagerTransferOwnership( - config: Omit< - UsePrepareContractWriteConfig< - typeof addressManagerABI, - 'transferOwnership' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof addressManagerAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: addressManagerABI, - address: - addressManagerAddress[chainId as keyof typeof addressManagerAddress], - functionName: 'transferOwnership', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link addressManagerABI}__. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdE1FCfB0851916CA5101820A69b13a4E276bd81F) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xa6f73589243a6A7a9023b1Fa0651b1d89c177111) - */ -export function useAddressManagerEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof addressManagerAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractEvent({ - abi: addressManagerABI, - address: - addressManagerAddress[chainId as keyof typeof addressManagerAddress], - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link addressManagerABI}__ and `eventName` set to `"AddressSet"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdE1FCfB0851916CA5101820A69b13a4E276bd81F) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xa6f73589243a6A7a9023b1Fa0651b1d89c177111) - */ -export function useAddressManagerAddressSetEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof addressManagerAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractEvent({ - abi: addressManagerABI, - address: - addressManagerAddress[chainId as keyof typeof addressManagerAddress], - eventName: 'AddressSet', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link addressManagerABI}__ and `eventName` set to `"OwnershipTransferred"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdE1FCfB0851916CA5101820A69b13a4E276bd81F) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xa6f73589243a6A7a9023b1Fa0651b1d89c177111) - */ -export function useAddressManagerOwnershipTransferredEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof addressManagerAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractEvent({ - abi: addressManagerABI, - address: - addressManagerAddress[chainId as keyof typeof addressManagerAddress], - eventName: 'OwnershipTransferred', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link assetReceiverABI}__. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - */ -export function useAssetReceiverRead< - TFunctionName extends string, - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof assetReceiverAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: assetReceiverABI, - address: assetReceiverAddress[chainId as keyof typeof assetReceiverAddress], - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link assetReceiverABI}__ and `functionName` set to `"owner"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - */ -export function useAssetReceiverOwner< - TFunctionName extends 'owner', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof assetReceiverAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: assetReceiverABI, - address: assetReceiverAddress[chainId as keyof typeof assetReceiverAddress], - functionName: 'owner', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link assetReceiverABI}__. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - */ -export function useAssetReceiverWrite< - TFunctionName extends string, - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof assetReceiverAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof assetReceiverABI, - string - >['request']['abi'], - TFunctionName, - TMode - > & { address?: Address; chainId?: TChainId } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: assetReceiverABI, - address: assetReceiverAddress[chainId as keyof typeof assetReceiverAddress], - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link assetReceiverABI}__ and `functionName` set to `"CALL"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - */ -export function useAssetReceiverCall< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof assetReceiverAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof assetReceiverABI, - 'CALL' - >['request']['abi'], - 'CALL', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'CALL' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'CALL' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: assetReceiverABI, - address: assetReceiverAddress[chainId as keyof typeof assetReceiverAddress], - functionName: 'CALL', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link assetReceiverABI}__ and `functionName` set to `"DELEGATECALL"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - */ -export function useAssetReceiverDelegatecall< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof assetReceiverAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof assetReceiverABI, - 'DELEGATECALL' - >['request']['abi'], - 'DELEGATECALL', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'DELEGATECALL' - } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'DELEGATECALL' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: assetReceiverABI, - address: assetReceiverAddress[chainId as keyof typeof assetReceiverAddress], - functionName: 'DELEGATECALL', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link assetReceiverABI}__ and `functionName` set to `"setOwner"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - */ -export function useAssetReceiverSetOwner< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof assetReceiverAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof assetReceiverABI, - 'setOwner' - >['request']['abi'], - 'setOwner', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'setOwner' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'setOwner' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: assetReceiverABI, - address: assetReceiverAddress[chainId as keyof typeof assetReceiverAddress], - functionName: 'setOwner', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link assetReceiverABI}__ and `functionName` set to `"withdrawERC20"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - */ -export function useAssetReceiverWithdrawErc20< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof assetReceiverAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof assetReceiverABI, - 'withdrawERC20' - >['request']['abi'], - 'withdrawERC20', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'withdrawERC20' - } - : UseContractWriteConfig< - typeof assetReceiverABI, - 'withdrawERC20', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'withdrawERC20' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: assetReceiverABI, - address: assetReceiverAddress[chainId as keyof typeof assetReceiverAddress], - functionName: 'withdrawERC20', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link assetReceiverABI}__ and `functionName` set to `"withdrawERC721"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - */ -export function useAssetReceiverWithdrawErc721< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof assetReceiverAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof assetReceiverABI, - 'withdrawERC721' - >['request']['abi'], - 'withdrawERC721', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'withdrawERC721' - } - : UseContractWriteConfig< - typeof assetReceiverABI, - 'withdrawERC721', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'withdrawERC721' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: assetReceiverABI, - address: assetReceiverAddress[chainId as keyof typeof assetReceiverAddress], - functionName: 'withdrawERC721', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link assetReceiverABI}__ and `functionName` set to `"withdrawETH"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - */ -export function useAssetReceiverWithdrawEth< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof assetReceiverAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof assetReceiverABI, - 'withdrawETH' - >['request']['abi'], - 'withdrawETH', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'withdrawETH' - } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'withdrawETH' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: assetReceiverABI, - address: assetReceiverAddress[chainId as keyof typeof assetReceiverAddress], - functionName: 'withdrawETH', - ...config, - } as any) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link assetReceiverABI}__. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - */ -export function usePrepareAssetReceiverWrite( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof assetReceiverAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: assetReceiverABI, - address: assetReceiverAddress[chainId as keyof typeof assetReceiverAddress], - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link assetReceiverABI}__ and `functionName` set to `"CALL"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - */ -export function usePrepareAssetReceiverCall( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof assetReceiverAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: assetReceiverABI, - address: assetReceiverAddress[chainId as keyof typeof assetReceiverAddress], - functionName: 'CALL', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link assetReceiverABI}__ and `functionName` set to `"DELEGATECALL"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - */ -export function usePrepareAssetReceiverDelegatecall( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof assetReceiverAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: assetReceiverABI, - address: assetReceiverAddress[chainId as keyof typeof assetReceiverAddress], - functionName: 'DELEGATECALL', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link assetReceiverABI}__ and `functionName` set to `"setOwner"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - */ -export function usePrepareAssetReceiverSetOwner( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof assetReceiverAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: assetReceiverABI, - address: assetReceiverAddress[chainId as keyof typeof assetReceiverAddress], - functionName: 'setOwner', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link assetReceiverABI}__ and `functionName` set to `"withdrawERC20"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - */ -export function usePrepareAssetReceiverWithdrawErc20( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof assetReceiverAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: assetReceiverABI, - address: assetReceiverAddress[chainId as keyof typeof assetReceiverAddress], - functionName: 'withdrawERC20', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link assetReceiverABI}__ and `functionName` set to `"withdrawERC721"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - */ -export function usePrepareAssetReceiverWithdrawErc721( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof assetReceiverAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: assetReceiverABI, - address: assetReceiverAddress[chainId as keyof typeof assetReceiverAddress], - functionName: 'withdrawERC721', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link assetReceiverABI}__ and `functionName` set to `"withdrawETH"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - */ -export function usePrepareAssetReceiverWithdrawEth( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof assetReceiverAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: assetReceiverABI, - address: assetReceiverAddress[chainId as keyof typeof assetReceiverAddress], - functionName: 'withdrawETH', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link assetReceiverABI}__. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - */ -export function useAssetReceiverEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof assetReceiverAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractEvent({ - abi: assetReceiverABI, - address: assetReceiverAddress[chainId as keyof typeof assetReceiverAddress], - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link assetReceiverABI}__ and `eventName` set to `"OwnerUpdated"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - */ -export function useAssetReceiverOwnerUpdatedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof assetReceiverAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractEvent({ - abi: assetReceiverABI, - address: assetReceiverAddress[chainId as keyof typeof assetReceiverAddress], - eventName: 'OwnerUpdated', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link assetReceiverABI}__ and `eventName` set to `"ReceivedETH"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - */ -export function useAssetReceiverReceivedEthEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof assetReceiverAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractEvent({ - abi: assetReceiverABI, - address: assetReceiverAddress[chainId as keyof typeof assetReceiverAddress], - eventName: 'ReceivedETH', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link assetReceiverABI}__ and `eventName` set to `"WithdrewERC20"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - */ -export function useAssetReceiverWithdrewErc20Event( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof assetReceiverAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractEvent({ - abi: assetReceiverABI, - address: assetReceiverAddress[chainId as keyof typeof assetReceiverAddress], - eventName: 'WithdrewERC20', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link assetReceiverABI}__ and `eventName` set to `"WithdrewERC721"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - */ -export function useAssetReceiverWithdrewErc721Event( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof assetReceiverAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractEvent({ - abi: assetReceiverABI, - address: assetReceiverAddress[chainId as keyof typeof assetReceiverAddress], - eventName: 'WithdrewERC721', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link assetReceiverABI}__ and `eventName` set to `"WithdrewETH"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) - */ -export function useAssetReceiverWithdrewEthEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof assetReceiverAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractEvent({ - abi: assetReceiverABI, - address: assetReceiverAddress[chainId as keyof typeof assetReceiverAddress], - eventName: 'WithdrewETH', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link attestationStationABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0xEE36eaaD94d1Cc1d0eccaDb55C38bFfB6Be06C77) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0xEE36eaaD94d1Cc1d0eccaDb55C38bFfB6Be06C77) - */ -export function useAttestationStationRead< - TFunctionName extends string, - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof attestationStationABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' - > & { chainId?: keyof typeof attestationStationAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: attestationStationABI, - address: - attestationStationAddress[ - chainId as keyof typeof attestationStationAddress - ], - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link attestationStationABI}__ and `functionName` set to `"attestations"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0xEE36eaaD94d1Cc1d0eccaDb55C38bFfB6Be06C77) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0xEE36eaaD94d1Cc1d0eccaDb55C38bFfB6Be06C77) - */ -export function useAttestationStationAttestations< - TFunctionName extends 'attestations', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof attestationStationABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof attestationStationAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: attestationStationABI, - address: - attestationStationAddress[ - chainId as keyof typeof attestationStationAddress - ], - functionName: 'attestations', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link attestationStationABI}__ and `functionName` set to `"version"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0xEE36eaaD94d1Cc1d0eccaDb55C38bFfB6Be06C77) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0xEE36eaaD94d1Cc1d0eccaDb55C38bFfB6Be06C77) - */ -export function useAttestationStationVersion< - TFunctionName extends 'version', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof attestationStationABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof attestationStationAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: attestationStationABI, - address: - attestationStationAddress[ - chainId as keyof typeof attestationStationAddress - ], - functionName: 'version', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link attestationStationABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0xEE36eaaD94d1Cc1d0eccaDb55C38bFfB6Be06C77) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0xEE36eaaD94d1Cc1d0eccaDb55C38bFfB6Be06C77) - */ -export function useAttestationStationWrite< - TFunctionName extends string, - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof attestationStationAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof attestationStationABI, - string - >['request']['abi'], - TFunctionName, - TMode - > & { address?: Address; chainId?: TChainId } - : UseContractWriteConfig< - typeof attestationStationABI, - TFunctionName, - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: attestationStationABI, - address: - attestationStationAddress[ - chainId as keyof typeof attestationStationAddress - ], - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link attestationStationABI}__ and `functionName` set to `"attest"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0xEE36eaaD94d1Cc1d0eccaDb55C38bFfB6Be06C77) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0xEE36eaaD94d1Cc1d0eccaDb55C38bFfB6Be06C77) - */ -export function useAttestationStationAttest< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof attestationStationAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof attestationStationABI, - 'attest' - >['request']['abi'], - 'attest', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'attest' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'attest' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: attestationStationABI, - address: - attestationStationAddress[ - chainId as keyof typeof attestationStationAddress - ], - functionName: 'attest', - ...config, - } as any) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link attestationStationABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0xEE36eaaD94d1Cc1d0eccaDb55C38bFfB6Be06C77) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0xEE36eaaD94d1Cc1d0eccaDb55C38bFfB6Be06C77) - */ -export function usePrepareAttestationStationWrite( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof attestationStationAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: attestationStationABI, - address: - attestationStationAddress[ - chainId as keyof typeof attestationStationAddress - ], - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link attestationStationABI}__ and `functionName` set to `"attest"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0xEE36eaaD94d1Cc1d0eccaDb55C38bFfB6Be06C77) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0xEE36eaaD94d1Cc1d0eccaDb55C38bFfB6Be06C77) - */ -export function usePrepareAttestationStationAttest( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof attestationStationAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: attestationStationABI, - address: - attestationStationAddress[ - chainId as keyof typeof attestationStationAddress - ], - functionName: 'attest', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link attestationStationABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0xEE36eaaD94d1Cc1d0eccaDb55C38bFfB6Be06C77) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0xEE36eaaD94d1Cc1d0eccaDb55C38bFfB6Be06C77) - */ -export function useAttestationStationEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof attestationStationAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractEvent({ - abi: attestationStationABI, - address: - attestationStationAddress[ - chainId as keyof typeof attestationStationAddress - ], - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link attestationStationABI}__ and `eventName` set to `"AttestationCreated"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0xEE36eaaD94d1Cc1d0eccaDb55C38bFfB6Be06C77) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0xEE36eaaD94d1Cc1d0eccaDb55C38bFfB6Be06C77) - */ -export function useAttestationStationAttestationCreatedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof attestationStationAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractEvent({ - abi: attestationStationABI, - address: - attestationStationAddress[ - chainId as keyof typeof attestationStationAddress - ], - eventName: 'AttestationCreated', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link baseFeeVaultABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000019) - */ -export function useBaseFeeVaultRead< - TFunctionName extends string, - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof baseFeeVaultAddress } = {} as any -) { - return useContractRead({ - abi: baseFeeVaultABI, - address: baseFeeVaultAddress[420], - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link baseFeeVaultABI}__ and `functionName` set to `"MIN_WITHDRAWAL_AMOUNT"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000019) - */ -export function useBaseFeeVaultMinWithdrawalAmount< - TFunctionName extends 'MIN_WITHDRAWAL_AMOUNT', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof baseFeeVaultAddress } = {} as any -) { - return useContractRead({ - abi: baseFeeVaultABI, - address: baseFeeVaultAddress[420], - functionName: 'MIN_WITHDRAWAL_AMOUNT', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link baseFeeVaultABI}__ and `functionName` set to `"RECIPIENT"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000019) - */ -export function useBaseFeeVaultRecipient< - TFunctionName extends 'RECIPIENT', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof baseFeeVaultAddress } = {} as any -) { - return useContractRead({ - abi: baseFeeVaultABI, - address: baseFeeVaultAddress[420], - functionName: 'RECIPIENT', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link baseFeeVaultABI}__ and `functionName` set to `"totalProcessed"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000019) - */ -export function useBaseFeeVaultTotalProcessed< - TFunctionName extends 'totalProcessed', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof baseFeeVaultAddress } = {} as any -) { - return useContractRead({ - abi: baseFeeVaultABI, - address: baseFeeVaultAddress[420], - functionName: 'totalProcessed', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link baseFeeVaultABI}__ and `functionName` set to `"version"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000019) - */ -export function useBaseFeeVaultVersion< - TFunctionName extends 'version', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof baseFeeVaultAddress } = {} as any -) { - return useContractRead({ - abi: baseFeeVaultABI, - address: baseFeeVaultAddress[420], - functionName: 'version', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link baseFeeVaultABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000019) - */ -export function useBaseFeeVaultWrite< - TFunctionName extends string, - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof baseFeeVaultAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof baseFeeVaultABI, - string - >['request']['abi'], - TFunctionName, - TMode - > & { address?: Address; chainId?: TChainId } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - } = {} as any -) { - return useContractWrite({ - abi: baseFeeVaultABI, - address: baseFeeVaultAddress[420], - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link baseFeeVaultABI}__ and `functionName` set to `"withdraw"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000019) - */ -export function useBaseFeeVaultWithdraw< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof baseFeeVaultAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof baseFeeVaultABI, - 'withdraw' - >['request']['abi'], - 'withdraw', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'withdraw' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'withdraw' - } = {} as any -) { - return useContractWrite({ - abi: baseFeeVaultABI, - address: baseFeeVaultAddress[420], - functionName: 'withdraw', - ...config, - } as any) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link baseFeeVaultABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000019) - */ -export function usePrepareBaseFeeVaultWrite( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof baseFeeVaultAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: baseFeeVaultABI, - address: baseFeeVaultAddress[420], - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link baseFeeVaultABI}__ and `functionName` set to `"withdraw"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000019) - */ -export function usePrepareBaseFeeVaultWithdraw( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof baseFeeVaultAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: baseFeeVaultABI, - address: baseFeeVaultAddress[420], - functionName: 'withdraw', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link baseFeeVaultABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000019) - */ -export function useBaseFeeVaultEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof baseFeeVaultAddress } = {} as any -) { - return useContractEvent({ - abi: baseFeeVaultABI, - address: baseFeeVaultAddress[420], - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link baseFeeVaultABI}__ and `eventName` set to `"Withdrawal"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000019) - */ -export function useBaseFeeVaultWithdrawalEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof baseFeeVaultAddress } = {} as any -) { - return useContractEvent({ - abi: baseFeeVaultABI, - address: baseFeeVaultAddress[420], - eventName: 'Withdrawal', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link checkBalanceHighABI}__. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x7eC64a8a591bFf829ff6C8be76074D540ACb813F) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x7eC64a8a591bFf829ff6C8be76074D540ACb813F) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5d7103853f12109A7d27F118e54BbC654ad847E9) - */ -export function useCheckBalanceHighRead< - TFunctionName extends string, - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof checkBalanceHighABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' - > & { chainId?: keyof typeof checkBalanceHighAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: checkBalanceHighABI, - address: - checkBalanceHighAddress[chainId as keyof typeof checkBalanceHighAddress], - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link checkBalanceHighABI}__ and `functionName` set to `"check"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x7eC64a8a591bFf829ff6C8be76074D540ACb813F) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x7eC64a8a591bFf829ff6C8be76074D540ACb813F) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5d7103853f12109A7d27F118e54BbC654ad847E9) - */ -export function useCheckBalanceHighCheck< - TFunctionName extends 'check', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof checkBalanceHighABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof checkBalanceHighAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: checkBalanceHighABI, - address: - checkBalanceHighAddress[chainId as keyof typeof checkBalanceHighAddress], - functionName: 'check', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link checkBalanceHighABI}__. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x7eC64a8a591bFf829ff6C8be76074D540ACb813F) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x7eC64a8a591bFf829ff6C8be76074D540ACb813F) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5d7103853f12109A7d27F118e54BbC654ad847E9) - */ -export function useCheckBalanceHighEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof checkBalanceHighAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractEvent({ - abi: checkBalanceHighABI, - address: - checkBalanceHighAddress[chainId as keyof typeof checkBalanceHighAddress], - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link checkBalanceHighABI}__ and `eventName` set to `"_EventToExposeStructInABI__Params"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x7eC64a8a591bFf829ff6C8be76074D540ACb813F) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x7eC64a8a591bFf829ff6C8be76074D540ACb813F) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5d7103853f12109A7d27F118e54BbC654ad847E9) - */ -export function useCheckBalanceHighEventToExposeStructInAbiParamsEvent( - config: Omit< - UseContractEventConfig< - typeof checkBalanceHighABI, - '_EventToExposeStructInABI__Params' - >, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof checkBalanceHighAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractEvent({ - abi: checkBalanceHighABI, - address: - checkBalanceHighAddress[chainId as keyof typeof checkBalanceHighAddress], - eventName: '_EventToExposeStructInABI__Params', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link checkBalanceLowABI}__. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x381a4eFC2A2C914eA1889722bB4B44Fa6BD5b640) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x381a4eFC2A2C914eA1889722bB4B44Fa6BD5b640) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x7Ce13D154FAEE5C8B3E6b19d4Add16f21d884474) - */ -export function useCheckBalanceLowRead< - TFunctionName extends string, - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof checkBalanceLowABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' - > & { chainId?: keyof typeof checkBalanceLowAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: checkBalanceLowABI, - address: - checkBalanceLowAddress[chainId as keyof typeof checkBalanceLowAddress], - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link checkBalanceLowABI}__ and `functionName` set to `"check"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x381a4eFC2A2C914eA1889722bB4B44Fa6BD5b640) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x381a4eFC2A2C914eA1889722bB4B44Fa6BD5b640) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x7Ce13D154FAEE5C8B3E6b19d4Add16f21d884474) - */ -export function useCheckBalanceLowCheck< - TFunctionName extends 'check', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof checkBalanceLowABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof checkBalanceLowAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: checkBalanceLowABI, - address: - checkBalanceLowAddress[chainId as keyof typeof checkBalanceLowAddress], - functionName: 'check', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link checkBalanceLowABI}__. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x381a4eFC2A2C914eA1889722bB4B44Fa6BD5b640) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x381a4eFC2A2C914eA1889722bB4B44Fa6BD5b640) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x7Ce13D154FAEE5C8B3E6b19d4Add16f21d884474) - */ -export function useCheckBalanceLowEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof checkBalanceLowAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractEvent({ - abi: checkBalanceLowABI, - address: - checkBalanceLowAddress[chainId as keyof typeof checkBalanceLowAddress], - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link checkBalanceLowABI}__ and `eventName` set to `"_EventToExposeStructInABI__Params"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x381a4eFC2A2C914eA1889722bB4B44Fa6BD5b640) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x381a4eFC2A2C914eA1889722bB4B44Fa6BD5b640) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x7Ce13D154FAEE5C8B3E6b19d4Add16f21d884474) - */ -export function useCheckBalanceLowEventToExposeStructInAbiParamsEvent( - config: Omit< - UseContractEventConfig< - typeof checkBalanceLowABI, - '_EventToExposeStructInABI__Params' - >, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof checkBalanceLowAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractEvent({ - abi: checkBalanceLowABI, - address: - checkBalanceLowAddress[chainId as keyof typeof checkBalanceLowAddress], - eventName: '_EventToExposeStructInABI__Params', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link checkGelatoLowABI}__. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4f7CFc43f6D262a085F3b946cAC69E7a8E39BBAa) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4f7CFc43f6D262a085F3b946cAC69E7a8E39BBAa) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0xF9c8a4Cb4021f57F9f6d69799cA9BefF64524862) - */ -export function useCheckGelatoLowRead< - TFunctionName extends string, - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof checkGelatoLowAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: checkGelatoLowABI, - address: - checkGelatoLowAddress[chainId as keyof typeof checkGelatoLowAddress], - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link checkGelatoLowABI}__ and `functionName` set to `"check"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4f7CFc43f6D262a085F3b946cAC69E7a8E39BBAa) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4f7CFc43f6D262a085F3b946cAC69E7a8E39BBAa) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0xF9c8a4Cb4021f57F9f6d69799cA9BefF64524862) - */ -export function useCheckGelatoLowCheck< - TFunctionName extends 'check', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof checkGelatoLowAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: checkGelatoLowABI, - address: - checkGelatoLowAddress[chainId as keyof typeof checkGelatoLowAddress], - functionName: 'check', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link checkGelatoLowABI}__. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4f7CFc43f6D262a085F3b946cAC69E7a8E39BBAa) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4f7CFc43f6D262a085F3b946cAC69E7a8E39BBAa) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0xF9c8a4Cb4021f57F9f6d69799cA9BefF64524862) - */ -export function useCheckGelatoLowEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof checkGelatoLowAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractEvent({ - abi: checkGelatoLowABI, - address: - checkGelatoLowAddress[chainId as keyof typeof checkGelatoLowAddress], - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link checkGelatoLowABI}__ and `eventName` set to `"_EventToExposeStructInABI__Params"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4f7CFc43f6D262a085F3b946cAC69E7a8E39BBAa) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4f7CFc43f6D262a085F3b946cAC69E7a8E39BBAa) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0xF9c8a4Cb4021f57F9f6d69799cA9BefF64524862) - */ -export function useCheckGelatoLowEventToExposeStructInAbiParamsEvent( - config: Omit< - UseContractEventConfig< - typeof checkGelatoLowABI, - '_EventToExposeStructInABI__Params' - >, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof checkGelatoLowAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractEvent({ - abi: checkGelatoLowABI, - address: - checkGelatoLowAddress[chainId as keyof typeof checkGelatoLowAddress], - eventName: '_EventToExposeStructInABI__Params', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link checkTrueABI}__. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5c741a38cb11424711231777D71689C458eE835D) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5c741a38cb11424711231777D71689C458eE835D) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x47443D0C184e022F19BD1578F5bca6B8a9F58E32) - */ -export function useCheckTrueRead< - TFunctionName extends string, - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof checkTrueAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: checkTrueABI, - address: checkTrueAddress[chainId as keyof typeof checkTrueAddress], - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link checkTrueABI}__ and `functionName` set to `"check"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5c741a38cb11424711231777D71689C458eE835D) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5c741a38cb11424711231777D71689C458eE835D) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x47443D0C184e022F19BD1578F5bca6B8a9F58E32) - */ -export function useCheckTrueCheck< - TFunctionName extends 'check', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof checkTrueAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: checkTrueABI, - address: checkTrueAddress[chainId as keyof typeof checkTrueAddress], - functionName: 'check', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link drippieABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function useDrippieRead< - TFunctionName extends string, - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof drippieAddress } = {} as any -) { - return useContractRead({ - abi: drippieABI, - address: drippieAddress[1], - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link drippieABI}__ and `functionName` set to `"drips"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function useDrippieDrips< - TFunctionName extends 'drips', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof drippieAddress } = {} as any -) { - return useContractRead({ - abi: drippieABI, - address: drippieAddress[1], - functionName: 'drips', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link drippieABI}__ and `functionName` set to `"executable"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function useDrippieExecutable< - TFunctionName extends 'executable', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof drippieAddress } = {} as any -) { - return useContractRead({ - abi: drippieABI, - address: drippieAddress[1], - functionName: 'executable', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link drippieABI}__ and `functionName` set to `"owner"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function useDrippieOwner< - TFunctionName extends 'owner', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof drippieAddress } = {} as any -) { - return useContractRead({ - abi: drippieABI, - address: drippieAddress[1], - functionName: 'owner', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link drippieABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function useDrippieWrite< - TFunctionName extends string, - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof drippieAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult['request']['abi'], - TFunctionName, - TMode - > & { address?: Address; chainId?: TChainId } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - } = {} as any -) { - return useContractWrite({ - abi: drippieABI, - address: drippieAddress[1], - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link drippieABI}__ and `functionName` set to `"CALL"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function useDrippieCall< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof drippieAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult['request']['abi'], - 'CALL', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'CALL' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'CALL' - } = {} as any -) { - return useContractWrite({ - abi: drippieABI, - address: drippieAddress[1], - functionName: 'CALL', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link drippieABI}__ and `functionName` set to `"DELEGATECALL"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function useDrippieDelegatecall< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof drippieAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof drippieABI, - 'DELEGATECALL' - >['request']['abi'], - 'DELEGATECALL', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'DELEGATECALL' - } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'DELEGATECALL' - } = {} as any -) { - return useContractWrite({ - abi: drippieABI, - address: drippieAddress[1], - functionName: 'DELEGATECALL', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link drippieABI}__ and `functionName` set to `"create"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function useDrippieCreate< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof drippieAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof drippieABI, - 'create' - >['request']['abi'], - 'create', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'create' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'create' - } = {} as any -) { - return useContractWrite({ - abi: drippieABI, - address: drippieAddress[1], - functionName: 'create', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link drippieABI}__ and `functionName` set to `"drip"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function useDrippieDrip< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof drippieAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult['request']['abi'], - 'drip', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'drip' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'drip' - } = {} as any -) { - return useContractWrite({ - abi: drippieABI, - address: drippieAddress[1], - functionName: 'drip', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link drippieABI}__ and `functionName` set to `"setOwner"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function useDrippieSetOwner< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof drippieAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof drippieABI, - 'setOwner' - >['request']['abi'], - 'setOwner', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'setOwner' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'setOwner' - } = {} as any -) { - return useContractWrite({ - abi: drippieABI, - address: drippieAddress[1], - functionName: 'setOwner', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link drippieABI}__ and `functionName` set to `"status"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function useDrippieStatus< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof drippieAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof drippieABI, - 'status' - >['request']['abi'], - 'status', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'status' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'status' - } = {} as any -) { - return useContractWrite({ - abi: drippieABI, - address: drippieAddress[1], - functionName: 'status', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link drippieABI}__ and `functionName` set to `"withdrawERC20"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function useDrippieWithdrawErc20< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof drippieAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof drippieABI, - 'withdrawERC20' - >['request']['abi'], - 'withdrawERC20', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'withdrawERC20' - } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'withdrawERC20' - } = {} as any -) { - return useContractWrite({ - abi: drippieABI, - address: drippieAddress[1], - functionName: 'withdrawERC20', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link drippieABI}__ and `functionName` set to `"withdrawERC721"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function useDrippieWithdrawErc721< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof drippieAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof drippieABI, - 'withdrawERC721' - >['request']['abi'], - 'withdrawERC721', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'withdrawERC721' - } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'withdrawERC721' - } = {} as any -) { - return useContractWrite({ - abi: drippieABI, - address: drippieAddress[1], - functionName: 'withdrawERC721', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link drippieABI}__ and `functionName` set to `"withdrawETH"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function useDrippieWithdrawEth< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof drippieAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof drippieABI, - 'withdrawETH' - >['request']['abi'], - 'withdrawETH', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'withdrawETH' - } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'withdrawETH' - } = {} as any -) { - return useContractWrite({ - abi: drippieABI, - address: drippieAddress[1], - functionName: 'withdrawETH', - ...config, - } as any) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link drippieABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function usePrepareDrippieWrite( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof drippieAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: drippieABI, - address: drippieAddress[1], - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link drippieABI}__ and `functionName` set to `"CALL"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function usePrepareDrippieCall( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof drippieAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: drippieABI, - address: drippieAddress[1], - functionName: 'CALL', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link drippieABI}__ and `functionName` set to `"DELEGATECALL"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function usePrepareDrippieDelegatecall( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof drippieAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: drippieABI, - address: drippieAddress[1], - functionName: 'DELEGATECALL', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link drippieABI}__ and `functionName` set to `"create"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function usePrepareDrippieCreate( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof drippieAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: drippieABI, - address: drippieAddress[1], - functionName: 'create', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link drippieABI}__ and `functionName` set to `"drip"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function usePrepareDrippieDrip( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof drippieAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: drippieABI, - address: drippieAddress[1], - functionName: 'drip', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link drippieABI}__ and `functionName` set to `"setOwner"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function usePrepareDrippieSetOwner( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof drippieAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: drippieABI, - address: drippieAddress[1], - functionName: 'setOwner', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link drippieABI}__ and `functionName` set to `"status"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function usePrepareDrippieStatus( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof drippieAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: drippieABI, - address: drippieAddress[1], - functionName: 'status', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link drippieABI}__ and `functionName` set to `"withdrawERC20"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function usePrepareDrippieWithdrawErc20( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof drippieAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: drippieABI, - address: drippieAddress[1], - functionName: 'withdrawERC20', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link drippieABI}__ and `functionName` set to `"withdrawERC721"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function usePrepareDrippieWithdrawErc721( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof drippieAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: drippieABI, - address: drippieAddress[1], - functionName: 'withdrawERC721', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link drippieABI}__ and `functionName` set to `"withdrawETH"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function usePrepareDrippieWithdrawEth( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof drippieAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: drippieABI, - address: drippieAddress[1], - functionName: 'withdrawETH', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link drippieABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function useDrippieEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof drippieAddress } = {} as any -) { - return useContractEvent({ - abi: drippieABI, - address: drippieAddress[1], - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link drippieABI}__ and `eventName` set to `"DripCreated"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function useDrippieDripCreatedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof drippieAddress } = {} as any -) { - return useContractEvent({ - abi: drippieABI, - address: drippieAddress[1], - eventName: 'DripCreated', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link drippieABI}__ and `eventName` set to `"DripExecuted"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function useDrippieDripExecutedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof drippieAddress } = {} as any -) { - return useContractEvent({ - abi: drippieABI, - address: drippieAddress[1], - eventName: 'DripExecuted', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link drippieABI}__ and `eventName` set to `"DripStatusUpdated"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function useDrippieDripStatusUpdatedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof drippieAddress } = {} as any -) { - return useContractEvent({ - abi: drippieABI, - address: drippieAddress[1], - eventName: 'DripStatusUpdated', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link drippieABI}__ and `eventName` set to `"OwnerUpdated"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function useDrippieOwnerUpdatedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof drippieAddress } = {} as any -) { - return useContractEvent({ - abi: drippieABI, - address: drippieAddress[1], - eventName: 'OwnerUpdated', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link drippieABI}__ and `eventName` set to `"ReceivedETH"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function useDrippieReceivedEthEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof drippieAddress } = {} as any -) { - return useContractEvent({ - abi: drippieABI, - address: drippieAddress[1], - eventName: 'ReceivedETH', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link drippieABI}__ and `eventName` set to `"WithdrewERC20"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function useDrippieWithdrewErc20Event( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof drippieAddress } = {} as any -) { - return useContractEvent({ - abi: drippieABI, - address: drippieAddress[1], - eventName: 'WithdrewERC20', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link drippieABI}__ and `eventName` set to `"WithdrewERC721"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function useDrippieWithdrewErc721Event( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof drippieAddress } = {} as any -) { - return useContractEvent({ - abi: drippieABI, - address: drippieAddress[1], - eventName: 'WithdrewERC721', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link drippieABI}__ and `eventName` set to `"WithdrewETH"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function useDrippieWithdrewEthEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof drippieAddress } = {} as any -) { - return useContractEvent({ - abi: drippieABI, - address: drippieAddress[1], - eventName: 'WithdrewETH', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link drippieGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function useDrippieGoerliRead< - TFunctionName extends string, - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof drippieGoerliAddress } = {} as any -) { - return useContractRead({ - abi: drippieGoerliABI, - address: drippieGoerliAddress[5], - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link drippieGoerliABI}__ and `functionName` set to `"drips"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function useDrippieGoerliDrips< - TFunctionName extends 'drips', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof drippieGoerliAddress } = {} as any -) { - return useContractRead({ - abi: drippieGoerliABI, - address: drippieGoerliAddress[5], - functionName: 'drips', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link drippieGoerliABI}__ and `functionName` set to `"executable"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function useDrippieGoerliExecutable< - TFunctionName extends 'executable', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof drippieGoerliAddress } = {} as any -) { - return useContractRead({ - abi: drippieGoerliABI, - address: drippieGoerliAddress[5], - functionName: 'executable', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link drippieGoerliABI}__ and `functionName` set to `"owner"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function useDrippieGoerliOwner< - TFunctionName extends 'owner', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof drippieGoerliAddress } = {} as any -) { - return useContractRead({ - abi: drippieGoerliABI, - address: drippieGoerliAddress[5], - functionName: 'owner', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link drippieGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function useDrippieGoerliWrite< - TFunctionName extends string, - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof drippieGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof drippieGoerliABI, - string - >['request']['abi'], - TFunctionName, - TMode - > & { address?: Address; chainId?: TChainId } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - } = {} as any -) { - return useContractWrite({ - abi: drippieGoerliABI, - address: drippieGoerliAddress[5], - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link drippieGoerliABI}__ and `functionName` set to `"CALL"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function useDrippieGoerliCall< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof drippieGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof drippieGoerliABI, - 'CALL' - >['request']['abi'], - 'CALL', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'CALL' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'CALL' - } = {} as any -) { - return useContractWrite({ - abi: drippieGoerliABI, - address: drippieGoerliAddress[5], - functionName: 'CALL', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link drippieGoerliABI}__ and `functionName` set to `"DELEGATECALL"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function useDrippieGoerliDelegatecall< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof drippieGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof drippieGoerliABI, - 'DELEGATECALL' - >['request']['abi'], - 'DELEGATECALL', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'DELEGATECALL' - } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'DELEGATECALL' - } = {} as any -) { - return useContractWrite({ - abi: drippieGoerliABI, - address: drippieGoerliAddress[5], - functionName: 'DELEGATECALL', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link drippieGoerliABI}__ and `functionName` set to `"create"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function useDrippieGoerliCreate< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof drippieGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof drippieGoerliABI, - 'create' - >['request']['abi'], - 'create', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'create' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'create' - } = {} as any -) { - return useContractWrite({ - abi: drippieGoerliABI, - address: drippieGoerliAddress[5], - functionName: 'create', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link drippieGoerliABI}__ and `functionName` set to `"drip"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function useDrippieGoerliDrip< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof drippieGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof drippieGoerliABI, - 'drip' - >['request']['abi'], - 'drip', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'drip' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'drip' - } = {} as any -) { - return useContractWrite({ - abi: drippieGoerliABI, - address: drippieGoerliAddress[5], - functionName: 'drip', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link drippieGoerliABI}__ and `functionName` set to `"setOwner"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function useDrippieGoerliSetOwner< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof drippieGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof drippieGoerliABI, - 'setOwner' - >['request']['abi'], - 'setOwner', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'setOwner' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'setOwner' - } = {} as any -) { - return useContractWrite({ - abi: drippieGoerliABI, - address: drippieGoerliAddress[5], - functionName: 'setOwner', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link drippieGoerliABI}__ and `functionName` set to `"status"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function useDrippieGoerliStatus< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof drippieGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof drippieGoerliABI, - 'status' - >['request']['abi'], - 'status', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'status' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'status' - } = {} as any -) { - return useContractWrite({ - abi: drippieGoerliABI, - address: drippieGoerliAddress[5], - functionName: 'status', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link drippieGoerliABI}__ and `functionName` set to `"withdrawERC20"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function useDrippieGoerliWithdrawErc20< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof drippieGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof drippieGoerliABI, - 'withdrawERC20' - >['request']['abi'], - 'withdrawERC20', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'withdrawERC20' - } - : UseContractWriteConfig< - typeof drippieGoerliABI, - 'withdrawERC20', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'withdrawERC20' - } = {} as any -) { - return useContractWrite({ - abi: drippieGoerliABI, - address: drippieGoerliAddress[5], - functionName: 'withdrawERC20', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link drippieGoerliABI}__ and `functionName` set to `"withdrawERC721"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function useDrippieGoerliWithdrawErc721< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof drippieGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof drippieGoerliABI, - 'withdrawERC721' - >['request']['abi'], - 'withdrawERC721', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'withdrawERC721' - } - : UseContractWriteConfig< - typeof drippieGoerliABI, - 'withdrawERC721', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'withdrawERC721' - } = {} as any -) { - return useContractWrite({ - abi: drippieGoerliABI, - address: drippieGoerliAddress[5], - functionName: 'withdrawERC721', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link drippieGoerliABI}__ and `functionName` set to `"withdrawETH"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function useDrippieGoerliWithdrawEth< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof drippieGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof drippieGoerliABI, - 'withdrawETH' - >['request']['abi'], - 'withdrawETH', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'withdrawETH' - } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'withdrawETH' - } = {} as any -) { - return useContractWrite({ - abi: drippieGoerliABI, - address: drippieGoerliAddress[5], - functionName: 'withdrawETH', - ...config, - } as any) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link drippieGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function usePrepareDrippieGoerliWrite( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof drippieGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: drippieGoerliABI, - address: drippieGoerliAddress[5], - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link drippieGoerliABI}__ and `functionName` set to `"CALL"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function usePrepareDrippieGoerliCall( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof drippieGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: drippieGoerliABI, - address: drippieGoerliAddress[5], - functionName: 'CALL', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link drippieGoerliABI}__ and `functionName` set to `"DELEGATECALL"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function usePrepareDrippieGoerliDelegatecall( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof drippieGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: drippieGoerliABI, - address: drippieGoerliAddress[5], - functionName: 'DELEGATECALL', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link drippieGoerliABI}__ and `functionName` set to `"create"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function usePrepareDrippieGoerliCreate( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof drippieGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: drippieGoerliABI, - address: drippieGoerliAddress[5], - functionName: 'create', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link drippieGoerliABI}__ and `functionName` set to `"drip"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function usePrepareDrippieGoerliDrip( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof drippieGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: drippieGoerliABI, - address: drippieGoerliAddress[5], - functionName: 'drip', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link drippieGoerliABI}__ and `functionName` set to `"setOwner"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function usePrepareDrippieGoerliSetOwner( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof drippieGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: drippieGoerliABI, - address: drippieGoerliAddress[5], - functionName: 'setOwner', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link drippieGoerliABI}__ and `functionName` set to `"status"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function usePrepareDrippieGoerliStatus( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof drippieGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: drippieGoerliABI, - address: drippieGoerliAddress[5], - functionName: 'status', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link drippieGoerliABI}__ and `functionName` set to `"withdrawERC20"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function usePrepareDrippieGoerliWithdrawErc20( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof drippieGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: drippieGoerliABI, - address: drippieGoerliAddress[5], - functionName: 'withdrawERC20', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link drippieGoerliABI}__ and `functionName` set to `"withdrawERC721"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function usePrepareDrippieGoerliWithdrawErc721( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof drippieGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: drippieGoerliABI, - address: drippieGoerliAddress[5], - functionName: 'withdrawERC721', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link drippieGoerliABI}__ and `functionName` set to `"withdrawETH"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function usePrepareDrippieGoerliWithdrawEth( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof drippieGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: drippieGoerliABI, - address: drippieGoerliAddress[5], - functionName: 'withdrawETH', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link drippieGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function useDrippieGoerliEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof drippieGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: drippieGoerliABI, - address: drippieGoerliAddress[5], - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link drippieGoerliABI}__ and `eventName` set to `"DripCreated"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function useDrippieGoerliDripCreatedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof drippieGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: drippieGoerliABI, - address: drippieGoerliAddress[5], - eventName: 'DripCreated', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link drippieGoerliABI}__ and `eventName` set to `"DripExecuted"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function useDrippieGoerliDripExecutedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof drippieGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: drippieGoerliABI, - address: drippieGoerliAddress[5], - eventName: 'DripExecuted', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link drippieGoerliABI}__ and `eventName` set to `"DripStatusUpdated"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function useDrippieGoerliDripStatusUpdatedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof drippieGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: drippieGoerliABI, - address: drippieGoerliAddress[5], - eventName: 'DripStatusUpdated', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link drippieGoerliABI}__ and `eventName` set to `"OwnerUpdated"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function useDrippieGoerliOwnerUpdatedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof drippieGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: drippieGoerliABI, - address: drippieGoerliAddress[5], - eventName: 'OwnerUpdated', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link drippieGoerliABI}__ and `eventName` set to `"ReceivedETH"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function useDrippieGoerliReceivedEthEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof drippieGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: drippieGoerliABI, - address: drippieGoerliAddress[5], - eventName: 'ReceivedETH', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link drippieGoerliABI}__ and `eventName` set to `"WithdrewERC20"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function useDrippieGoerliWithdrewErc20Event( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof drippieGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: drippieGoerliABI, - address: drippieGoerliAddress[5], - eventName: 'WithdrewERC20', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link drippieGoerliABI}__ and `eventName` set to `"WithdrewERC721"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function useDrippieGoerliWithdrewErc721Event( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof drippieGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: drippieGoerliABI, - address: drippieGoerliAddress[5], - eventName: 'WithdrewERC721', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link drippieGoerliABI}__ and `eventName` set to `"WithdrewETH"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) - */ -export function useDrippieGoerliWithdrewEthEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof drippieGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: drippieGoerliABI, - address: drippieGoerliAddress[5], - eventName: 'WithdrewETH', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link drippieOptimismGoerliABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x8D8d533C16D23847EB04EEB0925be8900Dd3af86) - */ -export function useDrippieOptimismGoerliRead< - TFunctionName extends string, - TSelectData = ReadContractResult< - typeof drippieOptimismGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof drippieOptimismGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' - > & { chainId?: keyof typeof drippieOptimismGoerliAddress } = {} as any -) { - return useContractRead({ - abi: drippieOptimismGoerliABI, - address: drippieOptimismGoerliAddress[420], - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link drippieOptimismGoerliABI}__ and `functionName` set to `"drips"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x8D8d533C16D23847EB04EEB0925be8900Dd3af86) - */ -export function useDrippieOptimismGoerliDrips< - TFunctionName extends 'drips', - TSelectData = ReadContractResult< - typeof drippieOptimismGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof drippieOptimismGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof drippieOptimismGoerliAddress } = {} as any -) { - return useContractRead({ - abi: drippieOptimismGoerliABI, - address: drippieOptimismGoerliAddress[420], - functionName: 'drips', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link drippieOptimismGoerliABI}__ and `functionName` set to `"executable"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x8D8d533C16D23847EB04EEB0925be8900Dd3af86) - */ -export function useDrippieOptimismGoerliExecutable< - TFunctionName extends 'executable', - TSelectData = ReadContractResult< - typeof drippieOptimismGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof drippieOptimismGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof drippieOptimismGoerliAddress } = {} as any -) { - return useContractRead({ - abi: drippieOptimismGoerliABI, - address: drippieOptimismGoerliAddress[420], - functionName: 'executable', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link drippieOptimismGoerliABI}__ and `functionName` set to `"owner"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x8D8d533C16D23847EB04EEB0925be8900Dd3af86) - */ -export function useDrippieOptimismGoerliOwner< - TFunctionName extends 'owner', - TSelectData = ReadContractResult< - typeof drippieOptimismGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof drippieOptimismGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof drippieOptimismGoerliAddress } = {} as any -) { - return useContractRead({ - abi: drippieOptimismGoerliABI, - address: drippieOptimismGoerliAddress[420], - functionName: 'owner', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link drippieOptimismGoerliABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x8D8d533C16D23847EB04EEB0925be8900Dd3af86) - */ -export function useDrippieOptimismGoerliWrite< - TFunctionName extends string, - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof drippieOptimismGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof drippieOptimismGoerliABI, - string - >['request']['abi'], - TFunctionName, - TMode - > & { address?: Address; chainId?: TChainId } - : UseContractWriteConfig< - typeof drippieOptimismGoerliABI, - TFunctionName, - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - } = {} as any -) { - return useContractWrite< - typeof drippieOptimismGoerliABI, - TFunctionName, - TMode - >({ - abi: drippieOptimismGoerliABI, - address: drippieOptimismGoerliAddress[420], - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link drippieOptimismGoerliABI}__ and `functionName` set to `"CALL"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x8D8d533C16D23847EB04EEB0925be8900Dd3af86) - */ -export function useDrippieOptimismGoerliCall< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof drippieOptimismGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof drippieOptimismGoerliABI, - 'CALL' - >['request']['abi'], - 'CALL', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'CALL' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'CALL' - } = {} as any -) { - return useContractWrite({ - abi: drippieOptimismGoerliABI, - address: drippieOptimismGoerliAddress[420], - functionName: 'CALL', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link drippieOptimismGoerliABI}__ and `functionName` set to `"DELEGATECALL"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x8D8d533C16D23847EB04EEB0925be8900Dd3af86) - */ -export function useDrippieOptimismGoerliDelegatecall< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof drippieOptimismGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof drippieOptimismGoerliABI, - 'DELEGATECALL' - >['request']['abi'], - 'DELEGATECALL', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'DELEGATECALL' - } - : UseContractWriteConfig< - typeof drippieOptimismGoerliABI, - 'DELEGATECALL', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'DELEGATECALL' - } = {} as any -) { - return useContractWrite< - typeof drippieOptimismGoerliABI, - 'DELEGATECALL', - TMode - >({ - abi: drippieOptimismGoerliABI, - address: drippieOptimismGoerliAddress[420], - functionName: 'DELEGATECALL', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link drippieOptimismGoerliABI}__ and `functionName` set to `"create"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x8D8d533C16D23847EB04EEB0925be8900Dd3af86) - */ -export function useDrippieOptimismGoerliCreate< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof drippieOptimismGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof drippieOptimismGoerliABI, - 'create' - >['request']['abi'], - 'create', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'create' } - : UseContractWriteConfig< - typeof drippieOptimismGoerliABI, - 'create', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'create' - } = {} as any -) { - return useContractWrite({ - abi: drippieOptimismGoerliABI, - address: drippieOptimismGoerliAddress[420], - functionName: 'create', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link drippieOptimismGoerliABI}__ and `functionName` set to `"drip"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x8D8d533C16D23847EB04EEB0925be8900Dd3af86) - */ -export function useDrippieOptimismGoerliDrip< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof drippieOptimismGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof drippieOptimismGoerliABI, - 'drip' - >['request']['abi'], - 'drip', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'drip' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'drip' - } = {} as any -) { - return useContractWrite({ - abi: drippieOptimismGoerliABI, - address: drippieOptimismGoerliAddress[420], - functionName: 'drip', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link drippieOptimismGoerliABI}__ and `functionName` set to `"setOwner"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x8D8d533C16D23847EB04EEB0925be8900Dd3af86) - */ -export function useDrippieOptimismGoerliSetOwner< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof drippieOptimismGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof drippieOptimismGoerliABI, - 'setOwner' - >['request']['abi'], - 'setOwner', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'setOwner' } - : UseContractWriteConfig< - typeof drippieOptimismGoerliABI, - 'setOwner', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'setOwner' - } = {} as any -) { - return useContractWrite({ - abi: drippieOptimismGoerliABI, - address: drippieOptimismGoerliAddress[420], - functionName: 'setOwner', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link drippieOptimismGoerliABI}__ and `functionName` set to `"status"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x8D8d533C16D23847EB04EEB0925be8900Dd3af86) - */ -export function useDrippieOptimismGoerliStatus< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof drippieOptimismGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof drippieOptimismGoerliABI, - 'status' - >['request']['abi'], - 'status', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'status' } - : UseContractWriteConfig< - typeof drippieOptimismGoerliABI, - 'status', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'status' - } = {} as any -) { - return useContractWrite({ - abi: drippieOptimismGoerliABI, - address: drippieOptimismGoerliAddress[420], - functionName: 'status', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link drippieOptimismGoerliABI}__ and `functionName` set to `"withdrawERC20"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x8D8d533C16D23847EB04EEB0925be8900Dd3af86) - */ -export function useDrippieOptimismGoerliWithdrawErc20< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof drippieOptimismGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof drippieOptimismGoerliABI, - 'withdrawERC20' - >['request']['abi'], - 'withdrawERC20', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'withdrawERC20' - } - : UseContractWriteConfig< - typeof drippieOptimismGoerliABI, - 'withdrawERC20', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'withdrawERC20' - } = {} as any -) { - return useContractWrite< - typeof drippieOptimismGoerliABI, - 'withdrawERC20', - TMode - >({ - abi: drippieOptimismGoerliABI, - address: drippieOptimismGoerliAddress[420], - functionName: 'withdrawERC20', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link drippieOptimismGoerliABI}__ and `functionName` set to `"withdrawERC721"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x8D8d533C16D23847EB04EEB0925be8900Dd3af86) - */ -export function useDrippieOptimismGoerliWithdrawErc721< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof drippieOptimismGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof drippieOptimismGoerliABI, - 'withdrawERC721' - >['request']['abi'], - 'withdrawERC721', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'withdrawERC721' - } - : UseContractWriteConfig< - typeof drippieOptimismGoerliABI, - 'withdrawERC721', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'withdrawERC721' - } = {} as any -) { - return useContractWrite< - typeof drippieOptimismGoerliABI, - 'withdrawERC721', - TMode - >({ - abi: drippieOptimismGoerliABI, - address: drippieOptimismGoerliAddress[420], - functionName: 'withdrawERC721', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link drippieOptimismGoerliABI}__ and `functionName` set to `"withdrawETH"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x8D8d533C16D23847EB04EEB0925be8900Dd3af86) - */ -export function useDrippieOptimismGoerliWithdrawEth< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof drippieOptimismGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof drippieOptimismGoerliABI, - 'withdrawETH' - >['request']['abi'], - 'withdrawETH', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'withdrawETH' - } - : UseContractWriteConfig< - typeof drippieOptimismGoerliABI, - 'withdrawETH', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'withdrawETH' - } = {} as any -) { - return useContractWrite< - typeof drippieOptimismGoerliABI, - 'withdrawETH', - TMode - >({ - abi: drippieOptimismGoerliABI, - address: drippieOptimismGoerliAddress[420], - functionName: 'withdrawETH', - ...config, - } as any) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link drippieOptimismGoerliABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x8D8d533C16D23847EB04EEB0925be8900Dd3af86) - */ -export function usePrepareDrippieOptimismGoerliWrite< - TFunctionName extends string ->( - config: Omit< - UsePrepareContractWriteConfig< - typeof drippieOptimismGoerliABI, - TFunctionName - >, - 'abi' | 'address' - > & { chainId?: keyof typeof drippieOptimismGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: drippieOptimismGoerliABI, - address: drippieOptimismGoerliAddress[420], - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link drippieOptimismGoerliABI}__ and `functionName` set to `"CALL"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x8D8d533C16D23847EB04EEB0925be8900Dd3af86) - */ -export function usePrepareDrippieOptimismGoerliCall( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof drippieOptimismGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: drippieOptimismGoerliABI, - address: drippieOptimismGoerliAddress[420], - functionName: 'CALL', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link drippieOptimismGoerliABI}__ and `functionName` set to `"DELEGATECALL"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x8D8d533C16D23847EB04EEB0925be8900Dd3af86) - */ -export function usePrepareDrippieOptimismGoerliDelegatecall( - config: Omit< - UsePrepareContractWriteConfig< - typeof drippieOptimismGoerliABI, - 'DELEGATECALL' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof drippieOptimismGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: drippieOptimismGoerliABI, - address: drippieOptimismGoerliAddress[420], - functionName: 'DELEGATECALL', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link drippieOptimismGoerliABI}__ and `functionName` set to `"create"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x8D8d533C16D23847EB04EEB0925be8900Dd3af86) - */ -export function usePrepareDrippieOptimismGoerliCreate( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof drippieOptimismGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: drippieOptimismGoerliABI, - address: drippieOptimismGoerliAddress[420], - functionName: 'create', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link drippieOptimismGoerliABI}__ and `functionName` set to `"drip"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x8D8d533C16D23847EB04EEB0925be8900Dd3af86) - */ -export function usePrepareDrippieOptimismGoerliDrip( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof drippieOptimismGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: drippieOptimismGoerliABI, - address: drippieOptimismGoerliAddress[420], - functionName: 'drip', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link drippieOptimismGoerliABI}__ and `functionName` set to `"setOwner"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x8D8d533C16D23847EB04EEB0925be8900Dd3af86) - */ -export function usePrepareDrippieOptimismGoerliSetOwner( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof drippieOptimismGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: drippieOptimismGoerliABI, - address: drippieOptimismGoerliAddress[420], - functionName: 'setOwner', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link drippieOptimismGoerliABI}__ and `functionName` set to `"status"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x8D8d533C16D23847EB04EEB0925be8900Dd3af86) - */ -export function usePrepareDrippieOptimismGoerliStatus( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof drippieOptimismGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: drippieOptimismGoerliABI, - address: drippieOptimismGoerliAddress[420], - functionName: 'status', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link drippieOptimismGoerliABI}__ and `functionName` set to `"withdrawERC20"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x8D8d533C16D23847EB04EEB0925be8900Dd3af86) - */ -export function usePrepareDrippieOptimismGoerliWithdrawErc20( - config: Omit< - UsePrepareContractWriteConfig< - typeof drippieOptimismGoerliABI, - 'withdrawERC20' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof drippieOptimismGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: drippieOptimismGoerliABI, - address: drippieOptimismGoerliAddress[420], - functionName: 'withdrawERC20', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link drippieOptimismGoerliABI}__ and `functionName` set to `"withdrawERC721"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x8D8d533C16D23847EB04EEB0925be8900Dd3af86) - */ -export function usePrepareDrippieOptimismGoerliWithdrawErc721( - config: Omit< - UsePrepareContractWriteConfig< - typeof drippieOptimismGoerliABI, - 'withdrawERC721' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof drippieOptimismGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: drippieOptimismGoerliABI, - address: drippieOptimismGoerliAddress[420], - functionName: 'withdrawERC721', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link drippieOptimismGoerliABI}__ and `functionName` set to `"withdrawETH"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x8D8d533C16D23847EB04EEB0925be8900Dd3af86) - */ -export function usePrepareDrippieOptimismGoerliWithdrawEth( - config: Omit< - UsePrepareContractWriteConfig< - typeof drippieOptimismGoerliABI, - 'withdrawETH' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof drippieOptimismGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: drippieOptimismGoerliABI, - address: drippieOptimismGoerliAddress[420], - functionName: 'withdrawETH', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link drippieOptimismGoerliABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x8D8d533C16D23847EB04EEB0925be8900Dd3af86) - */ -export function useDrippieOptimismGoerliEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof drippieOptimismGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: drippieOptimismGoerliABI, - address: drippieOptimismGoerliAddress[420], - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link drippieOptimismGoerliABI}__ and `eventName` set to `"DripCreated"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x8D8d533C16D23847EB04EEB0925be8900Dd3af86) - */ -export function useDrippieOptimismGoerliDripCreatedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof drippieOptimismGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: drippieOptimismGoerliABI, - address: drippieOptimismGoerliAddress[420], - eventName: 'DripCreated', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link drippieOptimismGoerliABI}__ and `eventName` set to `"DripExecuted"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x8D8d533C16D23847EB04EEB0925be8900Dd3af86) - */ -export function useDrippieOptimismGoerliDripExecutedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof drippieOptimismGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: drippieOptimismGoerliABI, - address: drippieOptimismGoerliAddress[420], - eventName: 'DripExecuted', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link drippieOptimismGoerliABI}__ and `eventName` set to `"DripStatusUpdated"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x8D8d533C16D23847EB04EEB0925be8900Dd3af86) - */ -export function useDrippieOptimismGoerliDripStatusUpdatedEvent( - config: Omit< - UseContractEventConfig< - typeof drippieOptimismGoerliABI, - 'DripStatusUpdated' - >, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof drippieOptimismGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: drippieOptimismGoerliABI, - address: drippieOptimismGoerliAddress[420], - eventName: 'DripStatusUpdated', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link drippieOptimismGoerliABI}__ and `eventName` set to `"OwnerUpdated"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x8D8d533C16D23847EB04EEB0925be8900Dd3af86) - */ -export function useDrippieOptimismGoerliOwnerUpdatedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof drippieOptimismGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: drippieOptimismGoerliABI, - address: drippieOptimismGoerliAddress[420], - eventName: 'OwnerUpdated', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link drippieOptimismGoerliABI}__ and `eventName` set to `"ReceivedETH"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x8D8d533C16D23847EB04EEB0925be8900Dd3af86) - */ -export function useDrippieOptimismGoerliReceivedEthEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof drippieOptimismGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: drippieOptimismGoerliABI, - address: drippieOptimismGoerliAddress[420], - eventName: 'ReceivedETH', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link drippieOptimismGoerliABI}__ and `eventName` set to `"WithdrewERC20"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x8D8d533C16D23847EB04EEB0925be8900Dd3af86) - */ -export function useDrippieOptimismGoerliWithdrewErc20Event( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof drippieOptimismGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: drippieOptimismGoerliABI, - address: drippieOptimismGoerliAddress[420], - eventName: 'WithdrewERC20', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link drippieOptimismGoerliABI}__ and `eventName` set to `"WithdrewERC721"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x8D8d533C16D23847EB04EEB0925be8900Dd3af86) - */ -export function useDrippieOptimismGoerliWithdrewErc721Event( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof drippieOptimismGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: drippieOptimismGoerliABI, - address: drippieOptimismGoerliAddress[420], - eventName: 'WithdrewERC721', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link drippieOptimismGoerliABI}__ and `eventName` set to `"WithdrewETH"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x8D8d533C16D23847EB04EEB0925be8900Dd3af86) - */ -export function useDrippieOptimismGoerliWithdrewEthEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof drippieOptimismGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: drippieOptimismGoerliABI, - address: drippieOptimismGoerliAddress[420], - eventName: 'WithdrewETH', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link easABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function useEasRead< - TFunctionName extends string, - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof easAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: easABI, - address: easAddress[chainId as keyof typeof easAddress], - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link easABI}__ and `functionName` set to `"getAttestTypeHash"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function useEasGetAttestTypeHash< - TFunctionName extends 'getAttestTypeHash', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof easAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: easABI, - address: easAddress[chainId as keyof typeof easAddress], - functionName: 'getAttestTypeHash', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link easABI}__ and `functionName` set to `"getAttestation"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function useEasGetAttestation< - TFunctionName extends 'getAttestation', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof easAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: easABI, - address: easAddress[chainId as keyof typeof easAddress], - functionName: 'getAttestation', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link easABI}__ and `functionName` set to `"getDomainSeparator"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function useEasGetDomainSeparator< - TFunctionName extends 'getDomainSeparator', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof easAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: easABI, - address: easAddress[chainId as keyof typeof easAddress], - functionName: 'getDomainSeparator', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link easABI}__ and `functionName` set to `"getName"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function useEasGetName< - TFunctionName extends 'getName', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof easAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: easABI, - address: easAddress[chainId as keyof typeof easAddress], - functionName: 'getName', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link easABI}__ and `functionName` set to `"getNonce"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function useEasGetNonce< - TFunctionName extends 'getNonce', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof easAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: easABI, - address: easAddress[chainId as keyof typeof easAddress], - functionName: 'getNonce', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link easABI}__ and `functionName` set to `"getRevokeOffchain"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function useEasGetRevokeOffchain< - TFunctionName extends 'getRevokeOffchain', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof easAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: easABI, - address: easAddress[chainId as keyof typeof easAddress], - functionName: 'getRevokeOffchain', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link easABI}__ and `functionName` set to `"getRevokeTypeHash"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function useEasGetRevokeTypeHash< - TFunctionName extends 'getRevokeTypeHash', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof easAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: easABI, - address: easAddress[chainId as keyof typeof easAddress], - functionName: 'getRevokeTypeHash', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link easABI}__ and `functionName` set to `"getSchemaRegistry"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function useEasGetSchemaRegistry< - TFunctionName extends 'getSchemaRegistry', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof easAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: easABI, - address: easAddress[chainId as keyof typeof easAddress], - functionName: 'getSchemaRegistry', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link easABI}__ and `functionName` set to `"getTimestamp"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function useEasGetTimestamp< - TFunctionName extends 'getTimestamp', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof easAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: easABI, - address: easAddress[chainId as keyof typeof easAddress], - functionName: 'getTimestamp', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link easABI}__ and `functionName` set to `"isAttestationValid"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function useEasIsAttestationValid< - TFunctionName extends 'isAttestationValid', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof easAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: easABI, - address: easAddress[chainId as keyof typeof easAddress], - functionName: 'isAttestationValid', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link easABI}__ and `functionName` set to `"version"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function useEasVersion< - TFunctionName extends 'version', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof easAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: easABI, - address: easAddress[chainId as keyof typeof easAddress], - functionName: 'version', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link easABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function useEasWrite< - TFunctionName extends string, - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof easAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult['request']['abi'], - TFunctionName, - TMode - > & { address?: Address; chainId?: TChainId } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: easABI, - address: easAddress[chainId as keyof typeof easAddress], - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link easABI}__ and `functionName` set to `"attest"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function useEasAttest< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof easAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult['request']['abi'], - 'attest', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'attest' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'attest' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: easABI, - address: easAddress[chainId as keyof typeof easAddress], - functionName: 'attest', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link easABI}__ and `functionName` set to `"attestByDelegation"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function useEasAttestByDelegation< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof easAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof easABI, - 'attestByDelegation' - >['request']['abi'], - 'attestByDelegation', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'attestByDelegation' - } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'attestByDelegation' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: easABI, - address: easAddress[chainId as keyof typeof easAddress], - functionName: 'attestByDelegation', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link easABI}__ and `functionName` set to `"multiAttest"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function useEasMultiAttest< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof easAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof easABI, - 'multiAttest' - >['request']['abi'], - 'multiAttest', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'multiAttest' - } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'multiAttest' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: easABI, - address: easAddress[chainId as keyof typeof easAddress], - functionName: 'multiAttest', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link easABI}__ and `functionName` set to `"multiAttestByDelegation"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function useEasMultiAttestByDelegation< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof easAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof easABI, - 'multiAttestByDelegation' - >['request']['abi'], - 'multiAttestByDelegation', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'multiAttestByDelegation' - } - : UseContractWriteConfig< - typeof easABI, - 'multiAttestByDelegation', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'multiAttestByDelegation' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: easABI, - address: easAddress[chainId as keyof typeof easAddress], - functionName: 'multiAttestByDelegation', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link easABI}__ and `functionName` set to `"multiRevoke"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function useEasMultiRevoke< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof easAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof easABI, - 'multiRevoke' - >['request']['abi'], - 'multiRevoke', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'multiRevoke' - } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'multiRevoke' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: easABI, - address: easAddress[chainId as keyof typeof easAddress], - functionName: 'multiRevoke', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link easABI}__ and `functionName` set to `"multiRevokeByDelegation"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function useEasMultiRevokeByDelegation< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof easAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof easABI, - 'multiRevokeByDelegation' - >['request']['abi'], - 'multiRevokeByDelegation', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'multiRevokeByDelegation' - } - : UseContractWriteConfig< - typeof easABI, - 'multiRevokeByDelegation', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'multiRevokeByDelegation' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: easABI, - address: easAddress[chainId as keyof typeof easAddress], - functionName: 'multiRevokeByDelegation', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link easABI}__ and `functionName` set to `"multiRevokeOffchain"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function useEasMultiRevokeOffchain< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof easAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof easABI, - 'multiRevokeOffchain' - >['request']['abi'], - 'multiRevokeOffchain', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'multiRevokeOffchain' - } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'multiRevokeOffchain' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: easABI, - address: easAddress[chainId as keyof typeof easAddress], - functionName: 'multiRevokeOffchain', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link easABI}__ and `functionName` set to `"multiTimestamp"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function useEasMultiTimestamp< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof easAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof easABI, - 'multiTimestamp' - >['request']['abi'], - 'multiTimestamp', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'multiTimestamp' - } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'multiTimestamp' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: easABI, - address: easAddress[chainId as keyof typeof easAddress], - functionName: 'multiTimestamp', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link easABI}__ and `functionName` set to `"revoke"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function useEasRevoke< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof easAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult['request']['abi'], - 'revoke', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'revoke' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'revoke' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: easABI, - address: easAddress[chainId as keyof typeof easAddress], - functionName: 'revoke', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link easABI}__ and `functionName` set to `"revokeByDelegation"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function useEasRevokeByDelegation< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof easAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof easABI, - 'revokeByDelegation' - >['request']['abi'], - 'revokeByDelegation', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'revokeByDelegation' - } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'revokeByDelegation' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: easABI, - address: easAddress[chainId as keyof typeof easAddress], - functionName: 'revokeByDelegation', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link easABI}__ and `functionName` set to `"revokeOffchain"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function useEasRevokeOffchain< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof easAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof easABI, - 'revokeOffchain' - >['request']['abi'], - 'revokeOffchain', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'revokeOffchain' - } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'revokeOffchain' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: easABI, - address: easAddress[chainId as keyof typeof easAddress], - functionName: 'revokeOffchain', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link easABI}__ and `functionName` set to `"timestamp"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function useEasTimestamp< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof easAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof easABI, - 'timestamp' - >['request']['abi'], - 'timestamp', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'timestamp' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'timestamp' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: easABI, - address: easAddress[chainId as keyof typeof easAddress], - functionName: 'timestamp', - ...config, - } as any) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link easABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function usePrepareEasWrite( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof easAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: easABI, - address: easAddress[chainId as keyof typeof easAddress], - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link easABI}__ and `functionName` set to `"attest"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function usePrepareEasAttest( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof easAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: easABI, - address: easAddress[chainId as keyof typeof easAddress], - functionName: 'attest', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link easABI}__ and `functionName` set to `"attestByDelegation"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function usePrepareEasAttestByDelegation( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof easAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: easABI, - address: easAddress[chainId as keyof typeof easAddress], - functionName: 'attestByDelegation', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link easABI}__ and `functionName` set to `"multiAttest"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function usePrepareEasMultiAttest( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof easAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: easABI, - address: easAddress[chainId as keyof typeof easAddress], - functionName: 'multiAttest', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link easABI}__ and `functionName` set to `"multiAttestByDelegation"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function usePrepareEasMultiAttestByDelegation( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof easAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: easABI, - address: easAddress[chainId as keyof typeof easAddress], - functionName: 'multiAttestByDelegation', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link easABI}__ and `functionName` set to `"multiRevoke"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function usePrepareEasMultiRevoke( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof easAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: easABI, - address: easAddress[chainId as keyof typeof easAddress], - functionName: 'multiRevoke', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link easABI}__ and `functionName` set to `"multiRevokeByDelegation"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function usePrepareEasMultiRevokeByDelegation( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof easAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: easABI, - address: easAddress[chainId as keyof typeof easAddress], - functionName: 'multiRevokeByDelegation', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link easABI}__ and `functionName` set to `"multiRevokeOffchain"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function usePrepareEasMultiRevokeOffchain( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof easAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: easABI, - address: easAddress[chainId as keyof typeof easAddress], - functionName: 'multiRevokeOffchain', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link easABI}__ and `functionName` set to `"multiTimestamp"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function usePrepareEasMultiTimestamp( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof easAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: easABI, - address: easAddress[chainId as keyof typeof easAddress], - functionName: 'multiTimestamp', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link easABI}__ and `functionName` set to `"revoke"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function usePrepareEasRevoke( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof easAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: easABI, - address: easAddress[chainId as keyof typeof easAddress], - functionName: 'revoke', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link easABI}__ and `functionName` set to `"revokeByDelegation"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function usePrepareEasRevokeByDelegation( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof easAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: easABI, - address: easAddress[chainId as keyof typeof easAddress], - functionName: 'revokeByDelegation', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link easABI}__ and `functionName` set to `"revokeOffchain"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function usePrepareEasRevokeOffchain( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof easAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: easABI, - address: easAddress[chainId as keyof typeof easAddress], - functionName: 'revokeOffchain', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link easABI}__ and `functionName` set to `"timestamp"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function usePrepareEasTimestamp( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof easAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: easABI, - address: easAddress[chainId as keyof typeof easAddress], - functionName: 'timestamp', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link easABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function useEasEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof easAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractEvent({ - abi: easABI, - address: easAddress[chainId as keyof typeof easAddress], - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link easABI}__ and `eventName` set to `"Attested"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function useEasAttestedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof easAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractEvent({ - abi: easABI, - address: easAddress[chainId as keyof typeof easAddress], - eventName: 'Attested', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link easABI}__ and `eventName` set to `"Revoked"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function useEasRevokedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof easAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractEvent({ - abi: easABI, - address: easAddress[chainId as keyof typeof easAddress], - eventName: 'Revoked', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link easABI}__ and `eventName` set to `"RevokedOffchain"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function useEasRevokedOffchainEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof easAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractEvent({ - abi: easABI, - address: easAddress[chainId as keyof typeof easAddress], - eventName: 'RevokedOffchain', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link easABI}__ and `eventName` set to `"Timestamped"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) - */ -export function useEasTimestampedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof easAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractEvent({ - abi: easABI, - address: easAddress[chainId as keyof typeof easAddress], - eventName: 'Timestamped', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link gasPriceOracleABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000000F) - */ -export function useGasPriceOracleRead< - TFunctionName extends string, - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof gasPriceOracleAddress } = {} as any -) { - return useContractRead({ - abi: gasPriceOracleABI, - address: gasPriceOracleAddress[420], - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link gasPriceOracleABI}__ and `functionName` set to `"baseFee"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000000F) - */ -export function useGasPriceOracleBaseFee< - TFunctionName extends 'baseFee', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof gasPriceOracleAddress } = {} as any -) { - return useContractRead({ - abi: gasPriceOracleABI, - address: gasPriceOracleAddress[420], - functionName: 'baseFee', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link gasPriceOracleABI}__ and `functionName` set to `"decimals"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000000F) - */ -export function useGasPriceOracleDecimals< - TFunctionName extends 'decimals', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof gasPriceOracleAddress } = {} as any -) { - return useContractRead({ - abi: gasPriceOracleABI, - address: gasPriceOracleAddress[420], - functionName: 'decimals', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link gasPriceOracleABI}__ and `functionName` set to `"gasPrice"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000000F) - */ -export function useGasPriceOracleGasPrice< - TFunctionName extends 'gasPrice', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof gasPriceOracleAddress } = {} as any -) { - return useContractRead({ - abi: gasPriceOracleABI, - address: gasPriceOracleAddress[420], - functionName: 'gasPrice', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link gasPriceOracleABI}__ and `functionName` set to `"getL1Fee"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000000F) - */ -export function useGasPriceOracleGetL1Fee< - TFunctionName extends 'getL1Fee', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof gasPriceOracleAddress } = {} as any -) { - return useContractRead({ - abi: gasPriceOracleABI, - address: gasPriceOracleAddress[420], - functionName: 'getL1Fee', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link gasPriceOracleABI}__ and `functionName` set to `"getL1GasUsed"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000000F) - */ -export function useGasPriceOracleGetL1GasUsed< - TFunctionName extends 'getL1GasUsed', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof gasPriceOracleAddress } = {} as any -) { - return useContractRead({ - abi: gasPriceOracleABI, - address: gasPriceOracleAddress[420], - functionName: 'getL1GasUsed', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link gasPriceOracleABI}__ and `functionName` set to `"l1BaseFee"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000000F) - */ -export function useGasPriceOracleL1BaseFee< - TFunctionName extends 'l1BaseFee', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof gasPriceOracleAddress } = {} as any -) { - return useContractRead({ - abi: gasPriceOracleABI, - address: gasPriceOracleAddress[420], - functionName: 'l1BaseFee', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link gasPriceOracleABI}__ and `functionName` set to `"overhead"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000000F) - */ -export function useGasPriceOracleOverhead< - TFunctionName extends 'overhead', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof gasPriceOracleAddress } = {} as any -) { - return useContractRead({ - abi: gasPriceOracleABI, - address: gasPriceOracleAddress[420], - functionName: 'overhead', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link gasPriceOracleABI}__ and `functionName` set to `"scalar"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000000F) - */ -export function useGasPriceOracleScalar< - TFunctionName extends 'scalar', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof gasPriceOracleAddress } = {} as any -) { - return useContractRead({ - abi: gasPriceOracleABI, - address: gasPriceOracleAddress[420], - functionName: 'scalar', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link gasPriceOracleABI}__ and `functionName` set to `"version"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000000F) - */ -export function useGasPriceOracleVersion< - TFunctionName extends 'version', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof gasPriceOracleAddress } = {} as any -) { - return useContractRead({ - abi: gasPriceOracleABI, - address: gasPriceOracleAddress[420], - functionName: 'version', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1BlockABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000015) - */ -export function useL1BlockRead< - TFunctionName extends string, - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l1BlockAddress } = {} as any -) { - return useContractRead({ - abi: l1BlockABI, - address: l1BlockAddress[420], - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1BlockABI}__ and `functionName` set to `"DEPOSITOR_ACCOUNT"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000015) - */ -export function useL1BlockDepositorAccount< - TFunctionName extends 'DEPOSITOR_ACCOUNT', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1BlockAddress } = {} as any -) { - return useContractRead({ - abi: l1BlockABI, - address: l1BlockAddress[420], - functionName: 'DEPOSITOR_ACCOUNT', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1BlockABI}__ and `functionName` set to `"basefee"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000015) - */ -export function useL1BlockBasefee< - TFunctionName extends 'basefee', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1BlockAddress } = {} as any -) { - return useContractRead({ - abi: l1BlockABI, - address: l1BlockAddress[420], - functionName: 'basefee', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1BlockABI}__ and `functionName` set to `"batcherHash"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000015) - */ -export function useL1BlockBatcherHash< - TFunctionName extends 'batcherHash', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1BlockAddress } = {} as any -) { - return useContractRead({ - abi: l1BlockABI, - address: l1BlockAddress[420], - functionName: 'batcherHash', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1BlockABI}__ and `functionName` set to `"hash"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000015) - */ -export function useL1BlockHash< - TFunctionName extends 'hash', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1BlockAddress } = {} as any -) { - return useContractRead({ - abi: l1BlockABI, - address: l1BlockAddress[420], - functionName: 'hash', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1BlockABI}__ and `functionName` set to `"l1FeeOverhead"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000015) - */ -export function useL1BlockL1FeeOverhead< - TFunctionName extends 'l1FeeOverhead', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1BlockAddress } = {} as any -) { - return useContractRead({ - abi: l1BlockABI, - address: l1BlockAddress[420], - functionName: 'l1FeeOverhead', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1BlockABI}__ and `functionName` set to `"l1FeeScalar"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000015) - */ -export function useL1BlockL1FeeScalar< - TFunctionName extends 'l1FeeScalar', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1BlockAddress } = {} as any -) { - return useContractRead({ - abi: l1BlockABI, - address: l1BlockAddress[420], - functionName: 'l1FeeScalar', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1BlockABI}__ and `functionName` set to `"number"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000015) - */ -export function useL1BlockNumber< - TFunctionName extends 'number', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1BlockAddress } = {} as any -) { - return useContractRead({ - abi: l1BlockABI, - address: l1BlockAddress[420], - functionName: 'number', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1BlockABI}__ and `functionName` set to `"sequenceNumber"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000015) - */ -export function useL1BlockSequenceNumber< - TFunctionName extends 'sequenceNumber', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1BlockAddress } = {} as any -) { - return useContractRead({ - abi: l1BlockABI, - address: l1BlockAddress[420], - functionName: 'sequenceNumber', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1BlockABI}__ and `functionName` set to `"timestamp"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000015) - */ -export function useL1BlockTimestamp< - TFunctionName extends 'timestamp', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1BlockAddress } = {} as any -) { - return useContractRead({ - abi: l1BlockABI, - address: l1BlockAddress[420], - functionName: 'timestamp', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1BlockABI}__ and `functionName` set to `"version"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000015) - */ -export function useL1BlockVersion< - TFunctionName extends 'version', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1BlockAddress } = {} as any -) { - return useContractRead({ - abi: l1BlockABI, - address: l1BlockAddress[420], - functionName: 'version', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1BlockABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000015) - */ -export function useL1BlockWrite< - TFunctionName extends string, - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1BlockAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult['request']['abi'], - TFunctionName, - TMode - > & { address?: Address; chainId?: TChainId } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - } = {} as any -) { - return useContractWrite({ - abi: l1BlockABI, - address: l1BlockAddress[420], - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1BlockABI}__ and `functionName` set to `"setL1BlockValues"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000015) - */ -export function useL1BlockSetL1BlockValues< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1BlockAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1BlockABI, - 'setL1BlockValues' - >['request']['abi'], - 'setL1BlockValues', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'setL1BlockValues' - } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'setL1BlockValues' - } = {} as any -) { - return useContractWrite({ - abi: l1BlockABI, - address: l1BlockAddress[420], - functionName: 'setL1BlockValues', - ...config, - } as any) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1BlockABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000015) - */ -export function usePrepareL1BlockWrite( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l1BlockAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1BlockABI, - address: l1BlockAddress[420], - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1BlockABI}__ and `functionName` set to `"setL1BlockValues"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000015) - */ -export function usePrepareL1BlockSetL1BlockValues( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1BlockAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1BlockABI, - address: l1BlockAddress[420], - functionName: 'setL1BlockValues', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1CrossDomainMessengerABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) - */ -export function useL1CrossDomainMessengerRead< - TFunctionName extends string, - TSelectData = ReadContractResult< - typeof l1CrossDomainMessengerABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l1CrossDomainMessengerABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' - > & { chainId?: keyof typeof l1CrossDomainMessengerAddress } = {} as any -) { - return useContractRead({ - abi: l1CrossDomainMessengerABI, - address: l1CrossDomainMessengerAddress[1], - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1CrossDomainMessengerABI}__ and `functionName` set to `"MESSAGE_VERSION"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) - */ -export function useL1CrossDomainMessengerMessageVersion< - TFunctionName extends 'MESSAGE_VERSION', - TSelectData = ReadContractResult< - typeof l1CrossDomainMessengerABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l1CrossDomainMessengerABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1CrossDomainMessengerAddress } = {} as any -) { - return useContractRead({ - abi: l1CrossDomainMessengerABI, - address: l1CrossDomainMessengerAddress[1], - functionName: 'MESSAGE_VERSION', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1CrossDomainMessengerABI}__ and `functionName` set to `"MIN_GAS_CALLDATA_OVERHEAD"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) - */ -export function useL1CrossDomainMessengerMinGasCalldataOverhead< - TFunctionName extends 'MIN_GAS_CALLDATA_OVERHEAD', - TSelectData = ReadContractResult< - typeof l1CrossDomainMessengerABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l1CrossDomainMessengerABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1CrossDomainMessengerAddress } = {} as any -) { - return useContractRead({ - abi: l1CrossDomainMessengerABI, - address: l1CrossDomainMessengerAddress[1], - functionName: 'MIN_GAS_CALLDATA_OVERHEAD', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1CrossDomainMessengerABI}__ and `functionName` set to `"MIN_GAS_DYNAMIC_OVERHEAD_DENOMINATOR"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) - */ -export function useL1CrossDomainMessengerMinGasDynamicOverheadDenominator< - TFunctionName extends 'MIN_GAS_DYNAMIC_OVERHEAD_DENOMINATOR', - TSelectData = ReadContractResult< - typeof l1CrossDomainMessengerABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l1CrossDomainMessengerABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1CrossDomainMessengerAddress } = {} as any -) { - return useContractRead({ - abi: l1CrossDomainMessengerABI, - address: l1CrossDomainMessengerAddress[1], - functionName: 'MIN_GAS_DYNAMIC_OVERHEAD_DENOMINATOR', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1CrossDomainMessengerABI}__ and `functionName` set to `"MIN_GAS_DYNAMIC_OVERHEAD_NUMERATOR"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) - */ -export function useL1CrossDomainMessengerMinGasDynamicOverheadNumerator< - TFunctionName extends 'MIN_GAS_DYNAMIC_OVERHEAD_NUMERATOR', - TSelectData = ReadContractResult< - typeof l1CrossDomainMessengerABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l1CrossDomainMessengerABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1CrossDomainMessengerAddress } = {} as any -) { - return useContractRead({ - abi: l1CrossDomainMessengerABI, - address: l1CrossDomainMessengerAddress[1], - functionName: 'MIN_GAS_DYNAMIC_OVERHEAD_NUMERATOR', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1CrossDomainMessengerABI}__ and `functionName` set to `"OTHER_MESSENGER"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) - */ -export function useL1CrossDomainMessengerOtherMessenger< - TFunctionName extends 'OTHER_MESSENGER', - TSelectData = ReadContractResult< - typeof l1CrossDomainMessengerABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l1CrossDomainMessengerABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1CrossDomainMessengerAddress } = {} as any -) { - return useContractRead({ - abi: l1CrossDomainMessengerABI, - address: l1CrossDomainMessengerAddress[1], - functionName: 'OTHER_MESSENGER', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1CrossDomainMessengerABI}__ and `functionName` set to `"PORTAL"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) - */ -export function useL1CrossDomainMessengerPortal< - TFunctionName extends 'PORTAL', - TSelectData = ReadContractResult< - typeof l1CrossDomainMessengerABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l1CrossDomainMessengerABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1CrossDomainMessengerAddress } = {} as any -) { - return useContractRead({ - abi: l1CrossDomainMessengerABI, - address: l1CrossDomainMessengerAddress[1], - functionName: 'PORTAL', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1CrossDomainMessengerABI}__ and `functionName` set to `"RELAY_CALL_OVERHEAD"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) - */ -export function useL1CrossDomainMessengerRelayCallOverhead< - TFunctionName extends 'RELAY_CALL_OVERHEAD', - TSelectData = ReadContractResult< - typeof l1CrossDomainMessengerABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l1CrossDomainMessengerABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1CrossDomainMessengerAddress } = {} as any -) { - return useContractRead({ - abi: l1CrossDomainMessengerABI, - address: l1CrossDomainMessengerAddress[1], - functionName: 'RELAY_CALL_OVERHEAD', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1CrossDomainMessengerABI}__ and `functionName` set to `"RELAY_CONSTANT_OVERHEAD"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) - */ -export function useL1CrossDomainMessengerRelayConstantOverhead< - TFunctionName extends 'RELAY_CONSTANT_OVERHEAD', - TSelectData = ReadContractResult< - typeof l1CrossDomainMessengerABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l1CrossDomainMessengerABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1CrossDomainMessengerAddress } = {} as any -) { - return useContractRead({ - abi: l1CrossDomainMessengerABI, - address: l1CrossDomainMessengerAddress[1], - functionName: 'RELAY_CONSTANT_OVERHEAD', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1CrossDomainMessengerABI}__ and `functionName` set to `"RELAY_GAS_CHECK_BUFFER"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) - */ -export function useL1CrossDomainMessengerRelayGasCheckBuffer< - TFunctionName extends 'RELAY_GAS_CHECK_BUFFER', - TSelectData = ReadContractResult< - typeof l1CrossDomainMessengerABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l1CrossDomainMessengerABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1CrossDomainMessengerAddress } = {} as any -) { - return useContractRead({ - abi: l1CrossDomainMessengerABI, - address: l1CrossDomainMessengerAddress[1], - functionName: 'RELAY_GAS_CHECK_BUFFER', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1CrossDomainMessengerABI}__ and `functionName` set to `"RELAY_RESERVED_GAS"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) - */ -export function useL1CrossDomainMessengerRelayReservedGas< - TFunctionName extends 'RELAY_RESERVED_GAS', - TSelectData = ReadContractResult< - typeof l1CrossDomainMessengerABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l1CrossDomainMessengerABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1CrossDomainMessengerAddress } = {} as any -) { - return useContractRead({ - abi: l1CrossDomainMessengerABI, - address: l1CrossDomainMessengerAddress[1], - functionName: 'RELAY_RESERVED_GAS', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1CrossDomainMessengerABI}__ and `functionName` set to `"baseGas"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) - */ -export function useL1CrossDomainMessengerBaseGas< - TFunctionName extends 'baseGas', - TSelectData = ReadContractResult< - typeof l1CrossDomainMessengerABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l1CrossDomainMessengerABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1CrossDomainMessengerAddress } = {} as any -) { - return useContractRead({ - abi: l1CrossDomainMessengerABI, - address: l1CrossDomainMessengerAddress[1], - functionName: 'baseGas', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1CrossDomainMessengerABI}__ and `functionName` set to `"failedMessages"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) - */ -export function useL1CrossDomainMessengerFailedMessages< - TFunctionName extends 'failedMessages', - TSelectData = ReadContractResult< - typeof l1CrossDomainMessengerABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l1CrossDomainMessengerABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1CrossDomainMessengerAddress } = {} as any -) { - return useContractRead({ - abi: l1CrossDomainMessengerABI, - address: l1CrossDomainMessengerAddress[1], - functionName: 'failedMessages', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1CrossDomainMessengerABI}__ and `functionName` set to `"messageNonce"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) - */ -export function useL1CrossDomainMessengerMessageNonce< - TFunctionName extends 'messageNonce', - TSelectData = ReadContractResult< - typeof l1CrossDomainMessengerABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l1CrossDomainMessengerABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1CrossDomainMessengerAddress } = {} as any -) { - return useContractRead({ - abi: l1CrossDomainMessengerABI, - address: l1CrossDomainMessengerAddress[1], - functionName: 'messageNonce', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1CrossDomainMessengerABI}__ and `functionName` set to `"successfulMessages"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) - */ -export function useL1CrossDomainMessengerSuccessfulMessages< - TFunctionName extends 'successfulMessages', - TSelectData = ReadContractResult< - typeof l1CrossDomainMessengerABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l1CrossDomainMessengerABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1CrossDomainMessengerAddress } = {} as any -) { - return useContractRead({ - abi: l1CrossDomainMessengerABI, - address: l1CrossDomainMessengerAddress[1], - functionName: 'successfulMessages', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1CrossDomainMessengerABI}__ and `functionName` set to `"version"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) - */ -export function useL1CrossDomainMessengerVersion< - TFunctionName extends 'version', - TSelectData = ReadContractResult< - typeof l1CrossDomainMessengerABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l1CrossDomainMessengerABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1CrossDomainMessengerAddress } = {} as any -) { - return useContractRead({ - abi: l1CrossDomainMessengerABI, - address: l1CrossDomainMessengerAddress[1], - functionName: 'version', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1CrossDomainMessengerABI}__ and `functionName` set to `"xDomainMessageSender"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) - */ -export function useL1CrossDomainMessengerXDomainMessageSender< - TFunctionName extends 'xDomainMessageSender', - TSelectData = ReadContractResult< - typeof l1CrossDomainMessengerABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l1CrossDomainMessengerABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1CrossDomainMessengerAddress } = {} as any -) { - return useContractRead({ - abi: l1CrossDomainMessengerABI, - address: l1CrossDomainMessengerAddress[1], - functionName: 'xDomainMessageSender', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1CrossDomainMessengerABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) - */ -export function useL1CrossDomainMessengerWrite< - TFunctionName extends string, - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1CrossDomainMessengerAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1CrossDomainMessengerABI, - string - >['request']['abi'], - TFunctionName, - TMode - > & { address?: Address; chainId?: TChainId } - : UseContractWriteConfig< - typeof l1CrossDomainMessengerABI, - TFunctionName, - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - } = {} as any -) { - return useContractWrite< - typeof l1CrossDomainMessengerABI, - TFunctionName, - TMode - >({ - abi: l1CrossDomainMessengerABI, - address: l1CrossDomainMessengerAddress[1], - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1CrossDomainMessengerABI}__ and `functionName` set to `"initialize"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) - */ -export function useL1CrossDomainMessengerInitialize< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1CrossDomainMessengerAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1CrossDomainMessengerABI, - 'initialize' - >['request']['abi'], - 'initialize', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'initialize' } - : UseContractWriteConfig< - typeof l1CrossDomainMessengerABI, - 'initialize', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'initialize' - } = {} as any -) { - return useContractWrite< - typeof l1CrossDomainMessengerABI, - 'initialize', - TMode - >({ - abi: l1CrossDomainMessengerABI, - address: l1CrossDomainMessengerAddress[1], - functionName: 'initialize', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1CrossDomainMessengerABI}__ and `functionName` set to `"relayMessage"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) - */ -export function useL1CrossDomainMessengerRelayMessage< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1CrossDomainMessengerAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1CrossDomainMessengerABI, - 'relayMessage' - >['request']['abi'], - 'relayMessage', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'relayMessage' - } - : UseContractWriteConfig< - typeof l1CrossDomainMessengerABI, - 'relayMessage', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'relayMessage' - } = {} as any -) { - return useContractWrite< - typeof l1CrossDomainMessengerABI, - 'relayMessage', - TMode - >({ - abi: l1CrossDomainMessengerABI, - address: l1CrossDomainMessengerAddress[1], - functionName: 'relayMessage', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1CrossDomainMessengerABI}__ and `functionName` set to `"sendMessage"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) - */ -export function useL1CrossDomainMessengerSendMessage< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1CrossDomainMessengerAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1CrossDomainMessengerABI, - 'sendMessage' - >['request']['abi'], - 'sendMessage', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'sendMessage' - } - : UseContractWriteConfig< - typeof l1CrossDomainMessengerABI, - 'sendMessage', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'sendMessage' - } = {} as any -) { - return useContractWrite< - typeof l1CrossDomainMessengerABI, - 'sendMessage', - TMode - >({ - abi: l1CrossDomainMessengerABI, - address: l1CrossDomainMessengerAddress[1], - functionName: 'sendMessage', - ...config, - } as any) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1CrossDomainMessengerABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) - */ -export function usePrepareL1CrossDomainMessengerWrite< - TFunctionName extends string ->( - config: Omit< - UsePrepareContractWriteConfig< - typeof l1CrossDomainMessengerABI, - TFunctionName - >, - 'abi' | 'address' - > & { chainId?: keyof typeof l1CrossDomainMessengerAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1CrossDomainMessengerABI, - address: l1CrossDomainMessengerAddress[1], - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1CrossDomainMessengerABI}__ and `functionName` set to `"initialize"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) - */ -export function usePrepareL1CrossDomainMessengerInitialize( - config: Omit< - UsePrepareContractWriteConfig< - typeof l1CrossDomainMessengerABI, - 'initialize' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1CrossDomainMessengerAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1CrossDomainMessengerABI, - address: l1CrossDomainMessengerAddress[1], - functionName: 'initialize', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1CrossDomainMessengerABI}__ and `functionName` set to `"relayMessage"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) - */ -export function usePrepareL1CrossDomainMessengerRelayMessage( - config: Omit< - UsePrepareContractWriteConfig< - typeof l1CrossDomainMessengerABI, - 'relayMessage' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1CrossDomainMessengerAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1CrossDomainMessengerABI, - address: l1CrossDomainMessengerAddress[1], - functionName: 'relayMessage', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1CrossDomainMessengerABI}__ and `functionName` set to `"sendMessage"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) - */ -export function usePrepareL1CrossDomainMessengerSendMessage( - config: Omit< - UsePrepareContractWriteConfig< - typeof l1CrossDomainMessengerABI, - 'sendMessage' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1CrossDomainMessengerAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1CrossDomainMessengerABI, - address: l1CrossDomainMessengerAddress[1], - functionName: 'sendMessage', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l1CrossDomainMessengerABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) - */ -export function useL1CrossDomainMessengerEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l1CrossDomainMessengerAddress } = {} as any -) { - return useContractEvent({ - abi: l1CrossDomainMessengerABI, - address: l1CrossDomainMessengerAddress[1], - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l1CrossDomainMessengerABI}__ and `eventName` set to `"FailedRelayedMessage"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) - */ -export function useL1CrossDomainMessengerFailedRelayedMessageEvent( - config: Omit< - UseContractEventConfig< - typeof l1CrossDomainMessengerABI, - 'FailedRelayedMessage' - >, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l1CrossDomainMessengerAddress } = {} as any -) { - return useContractEvent({ - abi: l1CrossDomainMessengerABI, - address: l1CrossDomainMessengerAddress[1], - eventName: 'FailedRelayedMessage', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l1CrossDomainMessengerABI}__ and `eventName` set to `"Initialized"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) - */ -export function useL1CrossDomainMessengerInitializedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l1CrossDomainMessengerAddress } = {} as any -) { - return useContractEvent({ - abi: l1CrossDomainMessengerABI, - address: l1CrossDomainMessengerAddress[1], - eventName: 'Initialized', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l1CrossDomainMessengerABI}__ and `eventName` set to `"RelayedMessage"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) - */ -export function useL1CrossDomainMessengerRelayedMessageEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l1CrossDomainMessengerAddress } = {} as any -) { - return useContractEvent({ - abi: l1CrossDomainMessengerABI, - address: l1CrossDomainMessengerAddress[1], - eventName: 'RelayedMessage', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l1CrossDomainMessengerABI}__ and `eventName` set to `"SentMessage"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) - */ -export function useL1CrossDomainMessengerSentMessageEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l1CrossDomainMessengerAddress } = {} as any -) { - return useContractEvent({ - abi: l1CrossDomainMessengerABI, - address: l1CrossDomainMessengerAddress[1], - eventName: 'SentMessage', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l1CrossDomainMessengerABI}__ and `eventName` set to `"SentMessageExtension1"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) - */ -export function useL1CrossDomainMessengerSentMessageExtension1Event( - config: Omit< - UseContractEventConfig< - typeof l1CrossDomainMessengerABI, - 'SentMessageExtension1' - >, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l1CrossDomainMessengerAddress } = {} as any -) { - return useContractEvent({ - abi: l1CrossDomainMessengerABI, - address: l1CrossDomainMessengerAddress[1], - eventName: 'SentMessageExtension1', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1CrossDomainMessengerGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) - */ -export function useL1CrossDomainMessengerGoerliRead< - TFunctionName extends string, - TSelectData = ReadContractResult< - typeof l1CrossDomainMessengerGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l1CrossDomainMessengerGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' - > & { chainId?: keyof typeof l1CrossDomainMessengerGoerliAddress } = {} as any -) { - return useContractRead({ - abi: l1CrossDomainMessengerGoerliABI, - address: l1CrossDomainMessengerGoerliAddress[5], - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1CrossDomainMessengerGoerliABI}__ and `functionName` set to `"MESSAGE_VERSION"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) - */ -export function useL1CrossDomainMessengerGoerliMessageVersion< - TFunctionName extends 'MESSAGE_VERSION', - TSelectData = ReadContractResult< - typeof l1CrossDomainMessengerGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l1CrossDomainMessengerGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1CrossDomainMessengerGoerliAddress } = {} as any -) { - return useContractRead({ - abi: l1CrossDomainMessengerGoerliABI, - address: l1CrossDomainMessengerGoerliAddress[5], - functionName: 'MESSAGE_VERSION', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1CrossDomainMessengerGoerliABI}__ and `functionName` set to `"MIN_GAS_CALLDATA_OVERHEAD"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) - */ -export function useL1CrossDomainMessengerGoerliMinGasCalldataOverhead< - TFunctionName extends 'MIN_GAS_CALLDATA_OVERHEAD', - TSelectData = ReadContractResult< - typeof l1CrossDomainMessengerGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l1CrossDomainMessengerGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1CrossDomainMessengerGoerliAddress } = {} as any -) { - return useContractRead({ - abi: l1CrossDomainMessengerGoerliABI, - address: l1CrossDomainMessengerGoerliAddress[5], - functionName: 'MIN_GAS_CALLDATA_OVERHEAD', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1CrossDomainMessengerGoerliABI}__ and `functionName` set to `"MIN_GAS_DYNAMIC_OVERHEAD_DENOMINATOR"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) - */ -export function useL1CrossDomainMessengerGoerliMinGasDynamicOverheadDenominator< - TFunctionName extends 'MIN_GAS_DYNAMIC_OVERHEAD_DENOMINATOR', - TSelectData = ReadContractResult< - typeof l1CrossDomainMessengerGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l1CrossDomainMessengerGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1CrossDomainMessengerGoerliAddress } = {} as any -) { - return useContractRead({ - abi: l1CrossDomainMessengerGoerliABI, - address: l1CrossDomainMessengerGoerliAddress[5], - functionName: 'MIN_GAS_DYNAMIC_OVERHEAD_DENOMINATOR', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1CrossDomainMessengerGoerliABI}__ and `functionName` set to `"MIN_GAS_DYNAMIC_OVERHEAD_NUMERATOR"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) - */ -export function useL1CrossDomainMessengerGoerliMinGasDynamicOverheadNumerator< - TFunctionName extends 'MIN_GAS_DYNAMIC_OVERHEAD_NUMERATOR', - TSelectData = ReadContractResult< - typeof l1CrossDomainMessengerGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l1CrossDomainMessengerGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1CrossDomainMessengerGoerliAddress } = {} as any -) { - return useContractRead({ - abi: l1CrossDomainMessengerGoerliABI, - address: l1CrossDomainMessengerGoerliAddress[5], - functionName: 'MIN_GAS_DYNAMIC_OVERHEAD_NUMERATOR', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1CrossDomainMessengerGoerliABI}__ and `functionName` set to `"OTHER_MESSENGER"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) - */ -export function useL1CrossDomainMessengerGoerliOtherMessenger< - TFunctionName extends 'OTHER_MESSENGER', - TSelectData = ReadContractResult< - typeof l1CrossDomainMessengerGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l1CrossDomainMessengerGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1CrossDomainMessengerGoerliAddress } = {} as any -) { - return useContractRead({ - abi: l1CrossDomainMessengerGoerliABI, - address: l1CrossDomainMessengerGoerliAddress[5], - functionName: 'OTHER_MESSENGER', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1CrossDomainMessengerGoerliABI}__ and `functionName` set to `"RELAY_CALL_OVERHEAD"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) - */ -export function useL1CrossDomainMessengerGoerliRelayCallOverhead< - TFunctionName extends 'RELAY_CALL_OVERHEAD', - TSelectData = ReadContractResult< - typeof l1CrossDomainMessengerGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l1CrossDomainMessengerGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1CrossDomainMessengerGoerliAddress } = {} as any -) { - return useContractRead({ - abi: l1CrossDomainMessengerGoerliABI, - address: l1CrossDomainMessengerGoerliAddress[5], - functionName: 'RELAY_CALL_OVERHEAD', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1CrossDomainMessengerGoerliABI}__ and `functionName` set to `"RELAY_CONSTANT_OVERHEAD"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) - */ -export function useL1CrossDomainMessengerGoerliRelayConstantOverhead< - TFunctionName extends 'RELAY_CONSTANT_OVERHEAD', - TSelectData = ReadContractResult< - typeof l1CrossDomainMessengerGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l1CrossDomainMessengerGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1CrossDomainMessengerGoerliAddress } = {} as any -) { - return useContractRead({ - abi: l1CrossDomainMessengerGoerliABI, - address: l1CrossDomainMessengerGoerliAddress[5], - functionName: 'RELAY_CONSTANT_OVERHEAD', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1CrossDomainMessengerGoerliABI}__ and `functionName` set to `"RELAY_GAS_CHECK_BUFFER"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) - */ -export function useL1CrossDomainMessengerGoerliRelayGasCheckBuffer< - TFunctionName extends 'RELAY_GAS_CHECK_BUFFER', - TSelectData = ReadContractResult< - typeof l1CrossDomainMessengerGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l1CrossDomainMessengerGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1CrossDomainMessengerGoerliAddress } = {} as any -) { - return useContractRead({ - abi: l1CrossDomainMessengerGoerliABI, - address: l1CrossDomainMessengerGoerliAddress[5], - functionName: 'RELAY_GAS_CHECK_BUFFER', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1CrossDomainMessengerGoerliABI}__ and `functionName` set to `"RELAY_RESERVED_GAS"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) - */ -export function useL1CrossDomainMessengerGoerliRelayReservedGas< - TFunctionName extends 'RELAY_RESERVED_GAS', - TSelectData = ReadContractResult< - typeof l1CrossDomainMessengerGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l1CrossDomainMessengerGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1CrossDomainMessengerGoerliAddress } = {} as any -) { - return useContractRead({ - abi: l1CrossDomainMessengerGoerliABI, - address: l1CrossDomainMessengerGoerliAddress[5], - functionName: 'RELAY_RESERVED_GAS', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1CrossDomainMessengerGoerliABI}__ and `functionName` set to `"baseGas"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) - */ -export function useL1CrossDomainMessengerGoerliBaseGas< - TFunctionName extends 'baseGas', - TSelectData = ReadContractResult< - typeof l1CrossDomainMessengerGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l1CrossDomainMessengerGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1CrossDomainMessengerGoerliAddress } = {} as any -) { - return useContractRead({ - abi: l1CrossDomainMessengerGoerliABI, - address: l1CrossDomainMessengerGoerliAddress[5], - functionName: 'baseGas', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1CrossDomainMessengerGoerliABI}__ and `functionName` set to `"failedMessages"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) - */ -export function useL1CrossDomainMessengerGoerliFailedMessages< - TFunctionName extends 'failedMessages', - TSelectData = ReadContractResult< - typeof l1CrossDomainMessengerGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l1CrossDomainMessengerGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1CrossDomainMessengerGoerliAddress } = {} as any -) { - return useContractRead({ - abi: l1CrossDomainMessengerGoerliABI, - address: l1CrossDomainMessengerGoerliAddress[5], - functionName: 'failedMessages', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1CrossDomainMessengerGoerliABI}__ and `functionName` set to `"messageNonce"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) - */ -export function useL1CrossDomainMessengerGoerliMessageNonce< - TFunctionName extends 'messageNonce', - TSelectData = ReadContractResult< - typeof l1CrossDomainMessengerGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l1CrossDomainMessengerGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1CrossDomainMessengerGoerliAddress } = {} as any -) { - return useContractRead({ - abi: l1CrossDomainMessengerGoerliABI, - address: l1CrossDomainMessengerGoerliAddress[5], - functionName: 'messageNonce', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1CrossDomainMessengerGoerliABI}__ and `functionName` set to `"portal"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) - */ -export function useL1CrossDomainMessengerGoerliPortal< - TFunctionName extends 'portal', - TSelectData = ReadContractResult< - typeof l1CrossDomainMessengerGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l1CrossDomainMessengerGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1CrossDomainMessengerGoerliAddress } = {} as any -) { - return useContractRead({ - abi: l1CrossDomainMessengerGoerliABI, - address: l1CrossDomainMessengerGoerliAddress[5], - functionName: 'portal', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1CrossDomainMessengerGoerliABI}__ and `functionName` set to `"successfulMessages"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) - */ -export function useL1CrossDomainMessengerGoerliSuccessfulMessages< - TFunctionName extends 'successfulMessages', - TSelectData = ReadContractResult< - typeof l1CrossDomainMessengerGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l1CrossDomainMessengerGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1CrossDomainMessengerGoerliAddress } = {} as any -) { - return useContractRead({ - abi: l1CrossDomainMessengerGoerliABI, - address: l1CrossDomainMessengerGoerliAddress[5], - functionName: 'successfulMessages', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1CrossDomainMessengerGoerliABI}__ and `functionName` set to `"version"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) - */ -export function useL1CrossDomainMessengerGoerliVersion< - TFunctionName extends 'version', - TSelectData = ReadContractResult< - typeof l1CrossDomainMessengerGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l1CrossDomainMessengerGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1CrossDomainMessengerGoerliAddress } = {} as any -) { - return useContractRead({ - abi: l1CrossDomainMessengerGoerliABI, - address: l1CrossDomainMessengerGoerliAddress[5], - functionName: 'version', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1CrossDomainMessengerGoerliABI}__ and `functionName` set to `"xDomainMessageSender"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) - */ -export function useL1CrossDomainMessengerGoerliXDomainMessageSender< - TFunctionName extends 'xDomainMessageSender', - TSelectData = ReadContractResult< - typeof l1CrossDomainMessengerGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l1CrossDomainMessengerGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1CrossDomainMessengerGoerliAddress } = {} as any -) { - return useContractRead({ - abi: l1CrossDomainMessengerGoerliABI, - address: l1CrossDomainMessengerGoerliAddress[5], - functionName: 'xDomainMessageSender', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1CrossDomainMessengerGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) - */ -export function useL1CrossDomainMessengerGoerliWrite< - TFunctionName extends string, - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1CrossDomainMessengerGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1CrossDomainMessengerGoerliABI, - string - >['request']['abi'], - TFunctionName, - TMode - > & { address?: Address; chainId?: TChainId } - : UseContractWriteConfig< - typeof l1CrossDomainMessengerGoerliABI, - TFunctionName, - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - } = {} as any -) { - return useContractWrite< - typeof l1CrossDomainMessengerGoerliABI, - TFunctionName, - TMode - >({ - abi: l1CrossDomainMessengerGoerliABI, - address: l1CrossDomainMessengerGoerliAddress[5], - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1CrossDomainMessengerGoerliABI}__ and `functionName` set to `"initialize"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) - */ -export function useL1CrossDomainMessengerGoerliInitialize< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1CrossDomainMessengerGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1CrossDomainMessengerGoerliABI, - 'initialize' - >['request']['abi'], - 'initialize', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'initialize' } - : UseContractWriteConfig< - typeof l1CrossDomainMessengerGoerliABI, - 'initialize', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'initialize' - } = {} as any -) { - return useContractWrite< - typeof l1CrossDomainMessengerGoerliABI, - 'initialize', - TMode - >({ - abi: l1CrossDomainMessengerGoerliABI, - address: l1CrossDomainMessengerGoerliAddress[5], - functionName: 'initialize', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1CrossDomainMessengerGoerliABI}__ and `functionName` set to `"relayMessage"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) - */ -export function useL1CrossDomainMessengerGoerliRelayMessage< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1CrossDomainMessengerGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1CrossDomainMessengerGoerliABI, - 'relayMessage' - >['request']['abi'], - 'relayMessage', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'relayMessage' - } - : UseContractWriteConfig< - typeof l1CrossDomainMessengerGoerliABI, - 'relayMessage', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'relayMessage' - } = {} as any -) { - return useContractWrite< - typeof l1CrossDomainMessengerGoerliABI, - 'relayMessage', - TMode - >({ - abi: l1CrossDomainMessengerGoerliABI, - address: l1CrossDomainMessengerGoerliAddress[5], - functionName: 'relayMessage', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1CrossDomainMessengerGoerliABI}__ and `functionName` set to `"sendMessage"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) - */ -export function useL1CrossDomainMessengerGoerliSendMessage< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1CrossDomainMessengerGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1CrossDomainMessengerGoerliABI, - 'sendMessage' - >['request']['abi'], - 'sendMessage', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'sendMessage' - } - : UseContractWriteConfig< - typeof l1CrossDomainMessengerGoerliABI, - 'sendMessage', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'sendMessage' - } = {} as any -) { - return useContractWrite< - typeof l1CrossDomainMessengerGoerliABI, - 'sendMessage', - TMode - >({ - abi: l1CrossDomainMessengerGoerliABI, - address: l1CrossDomainMessengerGoerliAddress[5], - functionName: 'sendMessage', - ...config, - } as any) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1CrossDomainMessengerGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) - */ -export function usePrepareL1CrossDomainMessengerGoerliWrite< - TFunctionName extends string ->( - config: Omit< - UsePrepareContractWriteConfig< - typeof l1CrossDomainMessengerGoerliABI, - TFunctionName - >, - 'abi' | 'address' - > & { chainId?: keyof typeof l1CrossDomainMessengerGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1CrossDomainMessengerGoerliABI, - address: l1CrossDomainMessengerGoerliAddress[5], - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1CrossDomainMessengerGoerliABI}__ and `functionName` set to `"initialize"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) - */ -export function usePrepareL1CrossDomainMessengerGoerliInitialize( - config: Omit< - UsePrepareContractWriteConfig< - typeof l1CrossDomainMessengerGoerliABI, - 'initialize' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1CrossDomainMessengerGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1CrossDomainMessengerGoerliABI, - address: l1CrossDomainMessengerGoerliAddress[5], - functionName: 'initialize', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1CrossDomainMessengerGoerliABI}__ and `functionName` set to `"relayMessage"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) - */ -export function usePrepareL1CrossDomainMessengerGoerliRelayMessage( - config: Omit< - UsePrepareContractWriteConfig< - typeof l1CrossDomainMessengerGoerliABI, - 'relayMessage' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1CrossDomainMessengerGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1CrossDomainMessengerGoerliABI, - address: l1CrossDomainMessengerGoerliAddress[5], - functionName: 'relayMessage', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1CrossDomainMessengerGoerliABI}__ and `functionName` set to `"sendMessage"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) - */ -export function usePrepareL1CrossDomainMessengerGoerliSendMessage( - config: Omit< - UsePrepareContractWriteConfig< - typeof l1CrossDomainMessengerGoerliABI, - 'sendMessage' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1CrossDomainMessengerGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1CrossDomainMessengerGoerliABI, - address: l1CrossDomainMessengerGoerliAddress[5], - functionName: 'sendMessage', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l1CrossDomainMessengerGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) - */ -export function useL1CrossDomainMessengerGoerliEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l1CrossDomainMessengerGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: l1CrossDomainMessengerGoerliABI, - address: l1CrossDomainMessengerGoerliAddress[5], - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l1CrossDomainMessengerGoerliABI}__ and `eventName` set to `"FailedRelayedMessage"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) - */ -export function useL1CrossDomainMessengerGoerliFailedRelayedMessageEvent( - config: Omit< - UseContractEventConfig< - typeof l1CrossDomainMessengerGoerliABI, - 'FailedRelayedMessage' - >, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l1CrossDomainMessengerGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: l1CrossDomainMessengerGoerliABI, - address: l1CrossDomainMessengerGoerliAddress[5], - eventName: 'FailedRelayedMessage', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l1CrossDomainMessengerGoerliABI}__ and `eventName` set to `"Initialized"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) - */ -export function useL1CrossDomainMessengerGoerliInitializedEvent( - config: Omit< - UseContractEventConfig< - typeof l1CrossDomainMessengerGoerliABI, - 'Initialized' - >, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l1CrossDomainMessengerGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: l1CrossDomainMessengerGoerliABI, - address: l1CrossDomainMessengerGoerliAddress[5], - eventName: 'Initialized', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l1CrossDomainMessengerGoerliABI}__ and `eventName` set to `"RelayedMessage"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) - */ -export function useL1CrossDomainMessengerGoerliRelayedMessageEvent( - config: Omit< - UseContractEventConfig< - typeof l1CrossDomainMessengerGoerliABI, - 'RelayedMessage' - >, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l1CrossDomainMessengerGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: l1CrossDomainMessengerGoerliABI, - address: l1CrossDomainMessengerGoerliAddress[5], - eventName: 'RelayedMessage', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l1CrossDomainMessengerGoerliABI}__ and `eventName` set to `"SentMessage"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) - */ -export function useL1CrossDomainMessengerGoerliSentMessageEvent( - config: Omit< - UseContractEventConfig< - typeof l1CrossDomainMessengerGoerliABI, - 'SentMessage' - >, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l1CrossDomainMessengerGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: l1CrossDomainMessengerGoerliABI, - address: l1CrossDomainMessengerGoerliAddress[5], - eventName: 'SentMessage', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l1CrossDomainMessengerGoerliABI}__ and `eventName` set to `"SentMessageExtension1"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) - */ -export function useL1CrossDomainMessengerGoerliSentMessageExtension1Event( - config: Omit< - UseContractEventConfig< - typeof l1CrossDomainMessengerGoerliABI, - 'SentMessageExtension1' - >, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l1CrossDomainMessengerGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: l1CrossDomainMessengerGoerliABI, - address: l1CrossDomainMessengerGoerliAddress[5], - eventName: 'SentMessageExtension1', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1Erc721BridgeABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5a7749f83b81B301cAb5f48EB8516B986DAef23D) - */ -export function useL1Erc721BridgeRead< - TFunctionName extends string, - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l1Erc721BridgeAddress } = {} as any -) { - return useContractRead({ - abi: l1Erc721BridgeABI, - address: l1Erc721BridgeAddress[1], - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1Erc721BridgeABI}__ and `functionName` set to `"deposits"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5a7749f83b81B301cAb5f48EB8516B986DAef23D) - */ -export function useL1Erc721BridgeDeposits< - TFunctionName extends 'deposits', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1Erc721BridgeAddress } = {} as any -) { - return useContractRead({ - abi: l1Erc721BridgeABI, - address: l1Erc721BridgeAddress[1], - functionName: 'deposits', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1Erc721BridgeABI}__ and `functionName` set to `"messenger"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5a7749f83b81B301cAb5f48EB8516B986DAef23D) - */ -export function useL1Erc721BridgeMessenger< - TFunctionName extends 'messenger', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1Erc721BridgeAddress } = {} as any -) { - return useContractRead({ - abi: l1Erc721BridgeABI, - address: l1Erc721BridgeAddress[1], - functionName: 'messenger', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1Erc721BridgeABI}__ and `functionName` set to `"otherBridge"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5a7749f83b81B301cAb5f48EB8516B986DAef23D) - */ -export function useL1Erc721BridgeOtherBridge< - TFunctionName extends 'otherBridge', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1Erc721BridgeAddress } = {} as any -) { - return useContractRead({ - abi: l1Erc721BridgeABI, - address: l1Erc721BridgeAddress[1], - functionName: 'otherBridge', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1Erc721BridgeABI}__ and `functionName` set to `"version"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5a7749f83b81B301cAb5f48EB8516B986DAef23D) - */ -export function useL1Erc721BridgeVersion< - TFunctionName extends 'version', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1Erc721BridgeAddress } = {} as any -) { - return useContractRead({ - abi: l1Erc721BridgeABI, - address: l1Erc721BridgeAddress[1], - functionName: 'version', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1Erc721BridgeABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5a7749f83b81B301cAb5f48EB8516B986DAef23D) - */ -export function useL1Erc721BridgeWrite< - TFunctionName extends string, - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1Erc721BridgeAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1Erc721BridgeABI, - string - >['request']['abi'], - TFunctionName, - TMode - > & { address?: Address; chainId?: TChainId } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - } = {} as any -) { - return useContractWrite({ - abi: l1Erc721BridgeABI, - address: l1Erc721BridgeAddress[1], - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1Erc721BridgeABI}__ and `functionName` set to `"bridgeERC721"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5a7749f83b81B301cAb5f48EB8516B986DAef23D) - */ -export function useL1Erc721BridgeBridgeErc721< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1Erc721BridgeAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1Erc721BridgeABI, - 'bridgeERC721' - >['request']['abi'], - 'bridgeERC721', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'bridgeERC721' - } - : UseContractWriteConfig< - typeof l1Erc721BridgeABI, - 'bridgeERC721', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'bridgeERC721' - } = {} as any -) { - return useContractWrite({ - abi: l1Erc721BridgeABI, - address: l1Erc721BridgeAddress[1], - functionName: 'bridgeERC721', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1Erc721BridgeABI}__ and `functionName` set to `"bridgeERC721To"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5a7749f83b81B301cAb5f48EB8516B986DAef23D) - */ -export function useL1Erc721BridgeBridgeErc721To< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1Erc721BridgeAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1Erc721BridgeABI, - 'bridgeERC721To' - >['request']['abi'], - 'bridgeERC721To', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'bridgeERC721To' - } - : UseContractWriteConfig< - typeof l1Erc721BridgeABI, - 'bridgeERC721To', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'bridgeERC721To' - } = {} as any -) { - return useContractWrite({ - abi: l1Erc721BridgeABI, - address: l1Erc721BridgeAddress[1], - functionName: 'bridgeERC721To', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1Erc721BridgeABI}__ and `functionName` set to `"finalizeBridgeERC721"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5a7749f83b81B301cAb5f48EB8516B986DAef23D) - */ -export function useL1Erc721BridgeFinalizeBridgeErc721< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1Erc721BridgeAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1Erc721BridgeABI, - 'finalizeBridgeERC721' - >['request']['abi'], - 'finalizeBridgeERC721', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'finalizeBridgeERC721' - } - : UseContractWriteConfig< - typeof l1Erc721BridgeABI, - 'finalizeBridgeERC721', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'finalizeBridgeERC721' - } = {} as any -) { - return useContractWrite< - typeof l1Erc721BridgeABI, - 'finalizeBridgeERC721', - TMode - >({ - abi: l1Erc721BridgeABI, - address: l1Erc721BridgeAddress[1], - functionName: 'finalizeBridgeERC721', - ...config, - } as any) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1Erc721BridgeABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5a7749f83b81B301cAb5f48EB8516B986DAef23D) - */ -export function usePrepareL1Erc721BridgeWrite( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l1Erc721BridgeAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1Erc721BridgeABI, - address: l1Erc721BridgeAddress[1], - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1Erc721BridgeABI}__ and `functionName` set to `"bridgeERC721"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5a7749f83b81B301cAb5f48EB8516B986DAef23D) - */ -export function usePrepareL1Erc721BridgeBridgeErc721( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1Erc721BridgeAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1Erc721BridgeABI, - address: l1Erc721BridgeAddress[1], - functionName: 'bridgeERC721', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1Erc721BridgeABI}__ and `functionName` set to `"bridgeERC721To"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5a7749f83b81B301cAb5f48EB8516B986DAef23D) - */ -export function usePrepareL1Erc721BridgeBridgeErc721To( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1Erc721BridgeAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1Erc721BridgeABI, - address: l1Erc721BridgeAddress[1], - functionName: 'bridgeERC721To', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1Erc721BridgeABI}__ and `functionName` set to `"finalizeBridgeERC721"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5a7749f83b81B301cAb5f48EB8516B986DAef23D) - */ -export function usePrepareL1Erc721BridgeFinalizeBridgeErc721( - config: Omit< - UsePrepareContractWriteConfig< - typeof l1Erc721BridgeABI, - 'finalizeBridgeERC721' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1Erc721BridgeAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1Erc721BridgeABI, - address: l1Erc721BridgeAddress[1], - functionName: 'finalizeBridgeERC721', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l1Erc721BridgeABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5a7749f83b81B301cAb5f48EB8516B986DAef23D) - */ -export function useL1Erc721BridgeEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l1Erc721BridgeAddress } = {} as any -) { - return useContractEvent({ - abi: l1Erc721BridgeABI, - address: l1Erc721BridgeAddress[1], - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l1Erc721BridgeABI}__ and `eventName` set to `"ERC721BridgeFinalized"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5a7749f83b81B301cAb5f48EB8516B986DAef23D) - */ -export function useL1Erc721BridgeErc721BridgeFinalizedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l1Erc721BridgeAddress } = {} as any -) { - return useContractEvent({ - abi: l1Erc721BridgeABI, - address: l1Erc721BridgeAddress[1], - eventName: 'ERC721BridgeFinalized', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l1Erc721BridgeABI}__ and `eventName` set to `"ERC721BridgeInitiated"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5a7749f83b81B301cAb5f48EB8516B986DAef23D) - */ -export function useL1Erc721BridgeErc721BridgeInitiatedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l1Erc721BridgeAddress } = {} as any -) { - return useContractEvent({ - abi: l1Erc721BridgeABI, - address: l1Erc721BridgeAddress[1], - eventName: 'ERC721BridgeInitiated', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1Erc721BridgeGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9) - */ -export function useL1Erc721BridgeGoerliRead< - TFunctionName extends string, - TSelectData = ReadContractResult< - typeof l1Erc721BridgeGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l1Erc721BridgeGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' - > & { chainId?: keyof typeof l1Erc721BridgeGoerliAddress } = {} as any -) { - return useContractRead({ - abi: l1Erc721BridgeGoerliABI, - address: l1Erc721BridgeGoerliAddress[5], - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1Erc721BridgeGoerliABI}__ and `functionName` set to `"deposits"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9) - */ -export function useL1Erc721BridgeGoerliDeposits< - TFunctionName extends 'deposits', - TSelectData = ReadContractResult< - typeof l1Erc721BridgeGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l1Erc721BridgeGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1Erc721BridgeGoerliAddress } = {} as any -) { - return useContractRead({ - abi: l1Erc721BridgeGoerliABI, - address: l1Erc721BridgeGoerliAddress[5], - functionName: 'deposits', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1Erc721BridgeGoerliABI}__ and `functionName` set to `"messenger"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9) - */ -export function useL1Erc721BridgeGoerliMessenger< - TFunctionName extends 'messenger', - TSelectData = ReadContractResult< - typeof l1Erc721BridgeGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l1Erc721BridgeGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1Erc721BridgeGoerliAddress } = {} as any -) { - return useContractRead({ - abi: l1Erc721BridgeGoerliABI, - address: l1Erc721BridgeGoerliAddress[5], - functionName: 'messenger', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1Erc721BridgeGoerliABI}__ and `functionName` set to `"otherBridge"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9) - */ -export function useL1Erc721BridgeGoerliOtherBridge< - TFunctionName extends 'otherBridge', - TSelectData = ReadContractResult< - typeof l1Erc721BridgeGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l1Erc721BridgeGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1Erc721BridgeGoerliAddress } = {} as any -) { - return useContractRead({ - abi: l1Erc721BridgeGoerliABI, - address: l1Erc721BridgeGoerliAddress[5], - functionName: 'otherBridge', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1Erc721BridgeGoerliABI}__ and `functionName` set to `"version"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9) - */ -export function useL1Erc721BridgeGoerliVersion< - TFunctionName extends 'version', - TSelectData = ReadContractResult< - typeof l1Erc721BridgeGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l1Erc721BridgeGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1Erc721BridgeGoerliAddress } = {} as any -) { - return useContractRead({ - abi: l1Erc721BridgeGoerliABI, - address: l1Erc721BridgeGoerliAddress[5], - functionName: 'version', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1Erc721BridgeGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9) - */ -export function useL1Erc721BridgeGoerliWrite< - TFunctionName extends string, - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1Erc721BridgeGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1Erc721BridgeGoerliABI, - string - >['request']['abi'], - TFunctionName, - TMode - > & { address?: Address; chainId?: TChainId } - : UseContractWriteConfig< - typeof l1Erc721BridgeGoerliABI, - TFunctionName, - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - } = {} as any -) { - return useContractWrite( - { - abi: l1Erc721BridgeGoerliABI, - address: l1Erc721BridgeGoerliAddress[5], - ...config, - } as any - ) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1Erc721BridgeGoerliABI}__ and `functionName` set to `"bridgeERC721"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9) - */ -export function useL1Erc721BridgeGoerliBridgeErc721< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1Erc721BridgeGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1Erc721BridgeGoerliABI, - 'bridgeERC721' - >['request']['abi'], - 'bridgeERC721', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'bridgeERC721' - } - : UseContractWriteConfig< - typeof l1Erc721BridgeGoerliABI, - 'bridgeERC721', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'bridgeERC721' - } = {} as any -) { - return useContractWrite< - typeof l1Erc721BridgeGoerliABI, - 'bridgeERC721', - TMode - >({ - abi: l1Erc721BridgeGoerliABI, - address: l1Erc721BridgeGoerliAddress[5], - functionName: 'bridgeERC721', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1Erc721BridgeGoerliABI}__ and `functionName` set to `"bridgeERC721To"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9) - */ -export function useL1Erc721BridgeGoerliBridgeErc721To< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1Erc721BridgeGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1Erc721BridgeGoerliABI, - 'bridgeERC721To' - >['request']['abi'], - 'bridgeERC721To', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'bridgeERC721To' - } - : UseContractWriteConfig< - typeof l1Erc721BridgeGoerliABI, - 'bridgeERC721To', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'bridgeERC721To' - } = {} as any -) { - return useContractWrite< - typeof l1Erc721BridgeGoerliABI, - 'bridgeERC721To', - TMode - >({ - abi: l1Erc721BridgeGoerliABI, - address: l1Erc721BridgeGoerliAddress[5], - functionName: 'bridgeERC721To', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1Erc721BridgeGoerliABI}__ and `functionName` set to `"finalizeBridgeERC721"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9) - */ -export function useL1Erc721BridgeGoerliFinalizeBridgeErc721< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1Erc721BridgeGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1Erc721BridgeGoerliABI, - 'finalizeBridgeERC721' - >['request']['abi'], - 'finalizeBridgeERC721', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'finalizeBridgeERC721' - } - : UseContractWriteConfig< - typeof l1Erc721BridgeGoerliABI, - 'finalizeBridgeERC721', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'finalizeBridgeERC721' - } = {} as any -) { - return useContractWrite< - typeof l1Erc721BridgeGoerliABI, - 'finalizeBridgeERC721', - TMode - >({ - abi: l1Erc721BridgeGoerliABI, - address: l1Erc721BridgeGoerliAddress[5], - functionName: 'finalizeBridgeERC721', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1Erc721BridgeGoerliABI}__ and `functionName` set to `"initialize"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9) - */ -export function useL1Erc721BridgeGoerliInitialize< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1Erc721BridgeGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1Erc721BridgeGoerliABI, - 'initialize' - >['request']['abi'], - 'initialize', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'initialize' } - : UseContractWriteConfig< - typeof l1Erc721BridgeGoerliABI, - 'initialize', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'initialize' - } = {} as any -) { - return useContractWrite({ - abi: l1Erc721BridgeGoerliABI, - address: l1Erc721BridgeGoerliAddress[5], - functionName: 'initialize', - ...config, - } as any) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1Erc721BridgeGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9) - */ -export function usePrepareL1Erc721BridgeGoerliWrite< - TFunctionName extends string ->( - config: Omit< - UsePrepareContractWriteConfig< - typeof l1Erc721BridgeGoerliABI, - TFunctionName - >, - 'abi' | 'address' - > & { chainId?: keyof typeof l1Erc721BridgeGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1Erc721BridgeGoerliABI, - address: l1Erc721BridgeGoerliAddress[5], - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1Erc721BridgeGoerliABI}__ and `functionName` set to `"bridgeERC721"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9) - */ -export function usePrepareL1Erc721BridgeGoerliBridgeErc721( - config: Omit< - UsePrepareContractWriteConfig< - typeof l1Erc721BridgeGoerliABI, - 'bridgeERC721' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1Erc721BridgeGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1Erc721BridgeGoerliABI, - address: l1Erc721BridgeGoerliAddress[5], - functionName: 'bridgeERC721', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1Erc721BridgeGoerliABI}__ and `functionName` set to `"bridgeERC721To"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9) - */ -export function usePrepareL1Erc721BridgeGoerliBridgeErc721To( - config: Omit< - UsePrepareContractWriteConfig< - typeof l1Erc721BridgeGoerliABI, - 'bridgeERC721To' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1Erc721BridgeGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1Erc721BridgeGoerliABI, - address: l1Erc721BridgeGoerliAddress[5], - functionName: 'bridgeERC721To', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1Erc721BridgeGoerliABI}__ and `functionName` set to `"finalizeBridgeERC721"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9) - */ -export function usePrepareL1Erc721BridgeGoerliFinalizeBridgeErc721( - config: Omit< - UsePrepareContractWriteConfig< - typeof l1Erc721BridgeGoerliABI, - 'finalizeBridgeERC721' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1Erc721BridgeGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1Erc721BridgeGoerliABI, - address: l1Erc721BridgeGoerliAddress[5], - functionName: 'finalizeBridgeERC721', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1Erc721BridgeGoerliABI}__ and `functionName` set to `"initialize"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9) - */ -export function usePrepareL1Erc721BridgeGoerliInitialize( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1Erc721BridgeGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1Erc721BridgeGoerliABI, - address: l1Erc721BridgeGoerliAddress[5], - functionName: 'initialize', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l1Erc721BridgeGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9) - */ -export function useL1Erc721BridgeGoerliEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l1Erc721BridgeGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: l1Erc721BridgeGoerliABI, - address: l1Erc721BridgeGoerliAddress[5], - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l1Erc721BridgeGoerliABI}__ and `eventName` set to `"ERC721BridgeFinalized"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9) - */ -export function useL1Erc721BridgeGoerliErc721BridgeFinalizedEvent( - config: Omit< - UseContractEventConfig< - typeof l1Erc721BridgeGoerliABI, - 'ERC721BridgeFinalized' - >, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l1Erc721BridgeGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: l1Erc721BridgeGoerliABI, - address: l1Erc721BridgeGoerliAddress[5], - eventName: 'ERC721BridgeFinalized', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l1Erc721BridgeGoerliABI}__ and `eventName` set to `"ERC721BridgeInitiated"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9) - */ -export function useL1Erc721BridgeGoerliErc721BridgeInitiatedEvent( - config: Omit< - UseContractEventConfig< - typeof l1Erc721BridgeGoerliABI, - 'ERC721BridgeInitiated' - >, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l1Erc721BridgeGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: l1Erc721BridgeGoerliABI, - address: l1Erc721BridgeGoerliAddress[5], - eventName: 'ERC721BridgeInitiated', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l1Erc721BridgeGoerliABI}__ and `eventName` set to `"Initialized"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9) - */ -export function useL1Erc721BridgeGoerliInitializedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l1Erc721BridgeGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: l1Erc721BridgeGoerliABI, - address: l1Erc721BridgeGoerliAddress[5], - eventName: 'Initialized', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1FeeVaultABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000001a) - */ -export function useL1FeeVaultRead< - TFunctionName extends string, - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l1FeeVaultAddress } = {} as any -) { - return useContractRead({ - abi: l1FeeVaultABI, - address: l1FeeVaultAddress[420], - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1FeeVaultABI}__ and `functionName` set to `"MIN_WITHDRAWAL_AMOUNT"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000001a) - */ -export function useL1FeeVaultMinWithdrawalAmount< - TFunctionName extends 'MIN_WITHDRAWAL_AMOUNT', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1FeeVaultAddress } = {} as any -) { - return useContractRead({ - abi: l1FeeVaultABI, - address: l1FeeVaultAddress[420], - functionName: 'MIN_WITHDRAWAL_AMOUNT', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1FeeVaultABI}__ and `functionName` set to `"RECIPIENT"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000001a) - */ -export function useL1FeeVaultRecipient< - TFunctionName extends 'RECIPIENT', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1FeeVaultAddress } = {} as any -) { - return useContractRead({ - abi: l1FeeVaultABI, - address: l1FeeVaultAddress[420], - functionName: 'RECIPIENT', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1FeeVaultABI}__ and `functionName` set to `"totalProcessed"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000001a) - */ -export function useL1FeeVaultTotalProcessed< - TFunctionName extends 'totalProcessed', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1FeeVaultAddress } = {} as any -) { - return useContractRead({ - abi: l1FeeVaultABI, - address: l1FeeVaultAddress[420], - functionName: 'totalProcessed', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1FeeVaultABI}__ and `functionName` set to `"version"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000001a) - */ -export function useL1FeeVaultVersion< - TFunctionName extends 'version', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1FeeVaultAddress } = {} as any -) { - return useContractRead({ - abi: l1FeeVaultABI, - address: l1FeeVaultAddress[420], - functionName: 'version', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1FeeVaultABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000001a) - */ -export function useL1FeeVaultWrite< - TFunctionName extends string, - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1FeeVaultAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1FeeVaultABI, - string - >['request']['abi'], - TFunctionName, - TMode - > & { address?: Address; chainId?: TChainId } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - } = {} as any -) { - return useContractWrite({ - abi: l1FeeVaultABI, - address: l1FeeVaultAddress[420], - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1FeeVaultABI}__ and `functionName` set to `"withdraw"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000001a) - */ -export function useL1FeeVaultWithdraw< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1FeeVaultAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1FeeVaultABI, - 'withdraw' - >['request']['abi'], - 'withdraw', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'withdraw' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'withdraw' - } = {} as any -) { - return useContractWrite({ - abi: l1FeeVaultABI, - address: l1FeeVaultAddress[420], - functionName: 'withdraw', - ...config, - } as any) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1FeeVaultABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000001a) - */ -export function usePrepareL1FeeVaultWrite( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l1FeeVaultAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1FeeVaultABI, - address: l1FeeVaultAddress[420], - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1FeeVaultABI}__ and `functionName` set to `"withdraw"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000001a) - */ -export function usePrepareL1FeeVaultWithdraw( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1FeeVaultAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1FeeVaultABI, - address: l1FeeVaultAddress[420], - functionName: 'withdraw', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l1FeeVaultABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000001a) - */ -export function useL1FeeVaultEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l1FeeVaultAddress } = {} as any -) { - return useContractEvent({ - abi: l1FeeVaultABI, - address: l1FeeVaultAddress[420], - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l1FeeVaultABI}__ and `eventName` set to `"Withdrawal"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000001a) - */ -export function useL1FeeVaultWithdrawalEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l1FeeVaultAddress } = {} as any -) { - return useContractEvent({ - abi: l1FeeVaultABI, - address: l1FeeVaultAddress[420], - eventName: 'Withdrawal', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1StandardBridgeABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) - */ -export function useL1StandardBridgeRead< - TFunctionName extends string, - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof l1StandardBridgeABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' - > & { chainId?: keyof typeof l1StandardBridgeAddress } = {} as any -) { - return useContractRead({ - abi: l1StandardBridgeABI, - address: l1StandardBridgeAddress[1], - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1StandardBridgeABI}__ and `functionName` set to `"OTHER_BRIDGE"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) - */ -export function useL1StandardBridgeOtherBridge< - TFunctionName extends 'OTHER_BRIDGE', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof l1StandardBridgeABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1StandardBridgeAddress } = {} as any -) { - return useContractRead({ - abi: l1StandardBridgeABI, - address: l1StandardBridgeAddress[1], - functionName: 'OTHER_BRIDGE', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1StandardBridgeABI}__ and `functionName` set to `"deposits"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) - */ -export function useL1StandardBridgeDeposits< - TFunctionName extends 'deposits', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof l1StandardBridgeABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1StandardBridgeAddress } = {} as any -) { - return useContractRead({ - abi: l1StandardBridgeABI, - address: l1StandardBridgeAddress[1], - functionName: 'deposits', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1StandardBridgeABI}__ and `functionName` set to `"l2TokenBridge"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) - */ -export function useL1StandardBridgeL2TokenBridge< - TFunctionName extends 'l2TokenBridge', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof l1StandardBridgeABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1StandardBridgeAddress } = {} as any -) { - return useContractRead({ - abi: l1StandardBridgeABI, - address: l1StandardBridgeAddress[1], - functionName: 'l2TokenBridge', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1StandardBridgeABI}__ and `functionName` set to `"messenger"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) - */ -export function useL1StandardBridgeMessenger< - TFunctionName extends 'messenger', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof l1StandardBridgeABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1StandardBridgeAddress } = {} as any -) { - return useContractRead({ - abi: l1StandardBridgeABI, - address: l1StandardBridgeAddress[1], - functionName: 'messenger', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1StandardBridgeABI}__ and `functionName` set to `"version"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) - */ -export function useL1StandardBridgeVersion< - TFunctionName extends 'version', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof l1StandardBridgeABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1StandardBridgeAddress } = {} as any -) { - return useContractRead({ - abi: l1StandardBridgeABI, - address: l1StandardBridgeAddress[1], - functionName: 'version', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1StandardBridgeABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) - */ -export function useL1StandardBridgeWrite< - TFunctionName extends string, - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1StandardBridgeAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1StandardBridgeABI, - string - >['request']['abi'], - TFunctionName, - TMode - > & { address?: Address; chainId?: TChainId } - : UseContractWriteConfig< - typeof l1StandardBridgeABI, - TFunctionName, - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - } = {} as any -) { - return useContractWrite({ - abi: l1StandardBridgeABI, - address: l1StandardBridgeAddress[1], - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1StandardBridgeABI}__ and `functionName` set to `"bridgeERC20"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) - */ -export function useL1StandardBridgeBridgeErc20< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1StandardBridgeAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1StandardBridgeABI, - 'bridgeERC20' - >['request']['abi'], - 'bridgeERC20', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'bridgeERC20' - } - : UseContractWriteConfig< - typeof l1StandardBridgeABI, - 'bridgeERC20', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'bridgeERC20' - } = {} as any -) { - return useContractWrite({ - abi: l1StandardBridgeABI, - address: l1StandardBridgeAddress[1], - functionName: 'bridgeERC20', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1StandardBridgeABI}__ and `functionName` set to `"bridgeERC20To"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) - */ -export function useL1StandardBridgeBridgeErc20To< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1StandardBridgeAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1StandardBridgeABI, - 'bridgeERC20To' - >['request']['abi'], - 'bridgeERC20To', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'bridgeERC20To' - } - : UseContractWriteConfig< - typeof l1StandardBridgeABI, - 'bridgeERC20To', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'bridgeERC20To' - } = {} as any -) { - return useContractWrite({ - abi: l1StandardBridgeABI, - address: l1StandardBridgeAddress[1], - functionName: 'bridgeERC20To', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1StandardBridgeABI}__ and `functionName` set to `"bridgeETH"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) - */ -export function useL1StandardBridgeBridgeEth< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1StandardBridgeAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1StandardBridgeABI, - 'bridgeETH' - >['request']['abi'], - 'bridgeETH', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'bridgeETH' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'bridgeETH' - } = {} as any -) { - return useContractWrite({ - abi: l1StandardBridgeABI, - address: l1StandardBridgeAddress[1], - functionName: 'bridgeETH', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1StandardBridgeABI}__ and `functionName` set to `"bridgeETHTo"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) - */ -export function useL1StandardBridgeBridgeEthTo< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1StandardBridgeAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1StandardBridgeABI, - 'bridgeETHTo' - >['request']['abi'], - 'bridgeETHTo', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'bridgeETHTo' - } - : UseContractWriteConfig< - typeof l1StandardBridgeABI, - 'bridgeETHTo', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'bridgeETHTo' - } = {} as any -) { - return useContractWrite({ - abi: l1StandardBridgeABI, - address: l1StandardBridgeAddress[1], - functionName: 'bridgeETHTo', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1StandardBridgeABI}__ and `functionName` set to `"depositERC20"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) - */ -export function useL1StandardBridgeDepositErc20< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1StandardBridgeAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1StandardBridgeABI, - 'depositERC20' - >['request']['abi'], - 'depositERC20', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'depositERC20' - } - : UseContractWriteConfig< - typeof l1StandardBridgeABI, - 'depositERC20', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'depositERC20' - } = {} as any -) { - return useContractWrite({ - abi: l1StandardBridgeABI, - address: l1StandardBridgeAddress[1], - functionName: 'depositERC20', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1StandardBridgeABI}__ and `functionName` set to `"depositERC20To"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) - */ -export function useL1StandardBridgeDepositErc20To< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1StandardBridgeAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1StandardBridgeABI, - 'depositERC20To' - >['request']['abi'], - 'depositERC20To', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'depositERC20To' - } - : UseContractWriteConfig< - typeof l1StandardBridgeABI, - 'depositERC20To', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'depositERC20To' - } = {} as any -) { - return useContractWrite({ - abi: l1StandardBridgeABI, - address: l1StandardBridgeAddress[1], - functionName: 'depositERC20To', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1StandardBridgeABI}__ and `functionName` set to `"depositETH"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) - */ -export function useL1StandardBridgeDepositEth< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1StandardBridgeAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1StandardBridgeABI, - 'depositETH' - >['request']['abi'], - 'depositETH', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'depositETH' } - : UseContractWriteConfig< - typeof l1StandardBridgeABI, - 'depositETH', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'depositETH' - } = {} as any -) { - return useContractWrite({ - abi: l1StandardBridgeABI, - address: l1StandardBridgeAddress[1], - functionName: 'depositETH', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1StandardBridgeABI}__ and `functionName` set to `"depositETHTo"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) - */ -export function useL1StandardBridgeDepositEthTo< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1StandardBridgeAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1StandardBridgeABI, - 'depositETHTo' - >['request']['abi'], - 'depositETHTo', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'depositETHTo' - } - : UseContractWriteConfig< - typeof l1StandardBridgeABI, - 'depositETHTo', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'depositETHTo' - } = {} as any -) { - return useContractWrite({ - abi: l1StandardBridgeABI, - address: l1StandardBridgeAddress[1], - functionName: 'depositETHTo', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1StandardBridgeABI}__ and `functionName` set to `"finalizeBridgeERC20"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) - */ -export function useL1StandardBridgeFinalizeBridgeErc20< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1StandardBridgeAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1StandardBridgeABI, - 'finalizeBridgeERC20' - >['request']['abi'], - 'finalizeBridgeERC20', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'finalizeBridgeERC20' - } - : UseContractWriteConfig< - typeof l1StandardBridgeABI, - 'finalizeBridgeERC20', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'finalizeBridgeERC20' - } = {} as any -) { - return useContractWrite< - typeof l1StandardBridgeABI, - 'finalizeBridgeERC20', - TMode - >({ - abi: l1StandardBridgeABI, - address: l1StandardBridgeAddress[1], - functionName: 'finalizeBridgeERC20', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1StandardBridgeABI}__ and `functionName` set to `"finalizeBridgeETH"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) - */ -export function useL1StandardBridgeFinalizeBridgeEth< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1StandardBridgeAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1StandardBridgeABI, - 'finalizeBridgeETH' - >['request']['abi'], - 'finalizeBridgeETH', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'finalizeBridgeETH' - } - : UseContractWriteConfig< - typeof l1StandardBridgeABI, - 'finalizeBridgeETH', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'finalizeBridgeETH' - } = {} as any -) { - return useContractWrite< - typeof l1StandardBridgeABI, - 'finalizeBridgeETH', - TMode - >({ - abi: l1StandardBridgeABI, - address: l1StandardBridgeAddress[1], - functionName: 'finalizeBridgeETH', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1StandardBridgeABI}__ and `functionName` set to `"finalizeERC20Withdrawal"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) - */ -export function useL1StandardBridgeFinalizeErc20Withdrawal< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1StandardBridgeAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1StandardBridgeABI, - 'finalizeERC20Withdrawal' - >['request']['abi'], - 'finalizeERC20Withdrawal', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'finalizeERC20Withdrawal' - } - : UseContractWriteConfig< - typeof l1StandardBridgeABI, - 'finalizeERC20Withdrawal', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'finalizeERC20Withdrawal' - } = {} as any -) { - return useContractWrite< - typeof l1StandardBridgeABI, - 'finalizeERC20Withdrawal', - TMode - >({ - abi: l1StandardBridgeABI, - address: l1StandardBridgeAddress[1], - functionName: 'finalizeERC20Withdrawal', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1StandardBridgeABI}__ and `functionName` set to `"finalizeETHWithdrawal"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) - */ -export function useL1StandardBridgeFinalizeEthWithdrawal< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1StandardBridgeAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1StandardBridgeABI, - 'finalizeETHWithdrawal' - >['request']['abi'], - 'finalizeETHWithdrawal', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'finalizeETHWithdrawal' - } - : UseContractWriteConfig< - typeof l1StandardBridgeABI, - 'finalizeETHWithdrawal', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'finalizeETHWithdrawal' - } = {} as any -) { - return useContractWrite< - typeof l1StandardBridgeABI, - 'finalizeETHWithdrawal', - TMode - >({ - abi: l1StandardBridgeABI, - address: l1StandardBridgeAddress[1], - functionName: 'finalizeETHWithdrawal', - ...config, - } as any) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1StandardBridgeABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) - */ -export function usePrepareL1StandardBridgeWrite( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l1StandardBridgeAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1StandardBridgeABI, - address: l1StandardBridgeAddress[1], - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1StandardBridgeABI}__ and `functionName` set to `"bridgeERC20"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) - */ -export function usePrepareL1StandardBridgeBridgeErc20( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1StandardBridgeAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1StandardBridgeABI, - address: l1StandardBridgeAddress[1], - functionName: 'bridgeERC20', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1StandardBridgeABI}__ and `functionName` set to `"bridgeERC20To"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) - */ -export function usePrepareL1StandardBridgeBridgeErc20To( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1StandardBridgeAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1StandardBridgeABI, - address: l1StandardBridgeAddress[1], - functionName: 'bridgeERC20To', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1StandardBridgeABI}__ and `functionName` set to `"bridgeETH"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) - */ -export function usePrepareL1StandardBridgeBridgeEth( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1StandardBridgeAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1StandardBridgeABI, - address: l1StandardBridgeAddress[1], - functionName: 'bridgeETH', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1StandardBridgeABI}__ and `functionName` set to `"bridgeETHTo"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) - */ -export function usePrepareL1StandardBridgeBridgeEthTo( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1StandardBridgeAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1StandardBridgeABI, - address: l1StandardBridgeAddress[1], - functionName: 'bridgeETHTo', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1StandardBridgeABI}__ and `functionName` set to `"depositERC20"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) - */ -export function usePrepareL1StandardBridgeDepositErc20( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1StandardBridgeAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1StandardBridgeABI, - address: l1StandardBridgeAddress[1], - functionName: 'depositERC20', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1StandardBridgeABI}__ and `functionName` set to `"depositERC20To"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) - */ -export function usePrepareL1StandardBridgeDepositErc20To( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1StandardBridgeAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1StandardBridgeABI, - address: l1StandardBridgeAddress[1], - functionName: 'depositERC20To', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1StandardBridgeABI}__ and `functionName` set to `"depositETH"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) - */ -export function usePrepareL1StandardBridgeDepositEth( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1StandardBridgeAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1StandardBridgeABI, - address: l1StandardBridgeAddress[1], - functionName: 'depositETH', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1StandardBridgeABI}__ and `functionName` set to `"depositETHTo"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) - */ -export function usePrepareL1StandardBridgeDepositEthTo( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1StandardBridgeAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1StandardBridgeABI, - address: l1StandardBridgeAddress[1], - functionName: 'depositETHTo', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1StandardBridgeABI}__ and `functionName` set to `"finalizeBridgeERC20"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) - */ -export function usePrepareL1StandardBridgeFinalizeBridgeErc20( - config: Omit< - UsePrepareContractWriteConfig< - typeof l1StandardBridgeABI, - 'finalizeBridgeERC20' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1StandardBridgeAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1StandardBridgeABI, - address: l1StandardBridgeAddress[1], - functionName: 'finalizeBridgeERC20', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1StandardBridgeABI}__ and `functionName` set to `"finalizeBridgeETH"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) - */ -export function usePrepareL1StandardBridgeFinalizeBridgeEth( - config: Omit< - UsePrepareContractWriteConfig< - typeof l1StandardBridgeABI, - 'finalizeBridgeETH' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1StandardBridgeAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1StandardBridgeABI, - address: l1StandardBridgeAddress[1], - functionName: 'finalizeBridgeETH', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1StandardBridgeABI}__ and `functionName` set to `"finalizeERC20Withdrawal"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) - */ -export function usePrepareL1StandardBridgeFinalizeErc20Withdrawal( - config: Omit< - UsePrepareContractWriteConfig< - typeof l1StandardBridgeABI, - 'finalizeERC20Withdrawal' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1StandardBridgeAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1StandardBridgeABI, - address: l1StandardBridgeAddress[1], - functionName: 'finalizeERC20Withdrawal', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1StandardBridgeABI}__ and `functionName` set to `"finalizeETHWithdrawal"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) - */ -export function usePrepareL1StandardBridgeFinalizeEthWithdrawal( - config: Omit< - UsePrepareContractWriteConfig< - typeof l1StandardBridgeABI, - 'finalizeETHWithdrawal' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1StandardBridgeAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1StandardBridgeABI, - address: l1StandardBridgeAddress[1], - functionName: 'finalizeETHWithdrawal', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l1StandardBridgeABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) - */ -export function useL1StandardBridgeEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l1StandardBridgeAddress } = {} as any -) { - return useContractEvent({ - abi: l1StandardBridgeABI, - address: l1StandardBridgeAddress[1], - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l1StandardBridgeABI}__ and `eventName` set to `"ERC20BridgeFinalized"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) - */ -export function useL1StandardBridgeErc20BridgeFinalizedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l1StandardBridgeAddress } = {} as any -) { - return useContractEvent({ - abi: l1StandardBridgeABI, - address: l1StandardBridgeAddress[1], - eventName: 'ERC20BridgeFinalized', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l1StandardBridgeABI}__ and `eventName` set to `"ERC20BridgeInitiated"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) - */ -export function useL1StandardBridgeErc20BridgeInitiatedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l1StandardBridgeAddress } = {} as any -) { - return useContractEvent({ - abi: l1StandardBridgeABI, - address: l1StandardBridgeAddress[1], - eventName: 'ERC20BridgeInitiated', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l1StandardBridgeABI}__ and `eventName` set to `"ERC20DepositInitiated"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) - */ -export function useL1StandardBridgeErc20DepositInitiatedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l1StandardBridgeAddress } = {} as any -) { - return useContractEvent({ - abi: l1StandardBridgeABI, - address: l1StandardBridgeAddress[1], - eventName: 'ERC20DepositInitiated', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l1StandardBridgeABI}__ and `eventName` set to `"ERC20WithdrawalFinalized"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) - */ -export function useL1StandardBridgeErc20WithdrawalFinalizedEvent( - config: Omit< - UseContractEventConfig< - typeof l1StandardBridgeABI, - 'ERC20WithdrawalFinalized' - >, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l1StandardBridgeAddress } = {} as any -) { - return useContractEvent({ - abi: l1StandardBridgeABI, - address: l1StandardBridgeAddress[1], - eventName: 'ERC20WithdrawalFinalized', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l1StandardBridgeABI}__ and `eventName` set to `"ETHBridgeFinalized"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) - */ -export function useL1StandardBridgeEthBridgeFinalizedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l1StandardBridgeAddress } = {} as any -) { - return useContractEvent({ - abi: l1StandardBridgeABI, - address: l1StandardBridgeAddress[1], - eventName: 'ETHBridgeFinalized', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l1StandardBridgeABI}__ and `eventName` set to `"ETHBridgeInitiated"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) - */ -export function useL1StandardBridgeEthBridgeInitiatedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l1StandardBridgeAddress } = {} as any -) { - return useContractEvent({ - abi: l1StandardBridgeABI, - address: l1StandardBridgeAddress[1], - eventName: 'ETHBridgeInitiated', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l1StandardBridgeABI}__ and `eventName` set to `"ETHDepositInitiated"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) - */ -export function useL1StandardBridgeEthDepositInitiatedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l1StandardBridgeAddress } = {} as any -) { - return useContractEvent({ - abi: l1StandardBridgeABI, - address: l1StandardBridgeAddress[1], - eventName: 'ETHDepositInitiated', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l1StandardBridgeABI}__ and `eventName` set to `"ETHWithdrawalFinalized"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) - */ -export function useL1StandardBridgeEthWithdrawalFinalizedEvent( - config: Omit< - UseContractEventConfig< - typeof l1StandardBridgeABI, - 'ETHWithdrawalFinalized' - >, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l1StandardBridgeAddress } = {} as any -) { - return useContractEvent({ - abi: l1StandardBridgeABI, - address: l1StandardBridgeAddress[1], - eventName: 'ETHWithdrawalFinalized', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function useL1StandardBridgeGoerliRead< - TFunctionName extends string, - TSelectData = ReadContractResult< - typeof l1StandardBridgeGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l1StandardBridgeGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' - > & { chainId?: keyof typeof l1StandardBridgeGoerliAddress } = {} as any -) { - return useContractRead({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__ and `functionName` set to `"deposits"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function useL1StandardBridgeGoerliDeposits< - TFunctionName extends 'deposits', - TSelectData = ReadContractResult< - typeof l1StandardBridgeGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l1StandardBridgeGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1StandardBridgeGoerliAddress } = {} as any -) { - return useContractRead({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - functionName: 'deposits', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__ and `functionName` set to `"l2TokenBridge"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function useL1StandardBridgeGoerliL2TokenBridge< - TFunctionName extends 'l2TokenBridge', - TSelectData = ReadContractResult< - typeof l1StandardBridgeGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l1StandardBridgeGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1StandardBridgeGoerliAddress } = {} as any -) { - return useContractRead({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - functionName: 'l2TokenBridge', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__ and `functionName` set to `"messenger"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function useL1StandardBridgeGoerliMessenger< - TFunctionName extends 'messenger', - TSelectData = ReadContractResult< - typeof l1StandardBridgeGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l1StandardBridgeGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1StandardBridgeGoerliAddress } = {} as any -) { - return useContractRead({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - functionName: 'messenger', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__ and `functionName` set to `"otherBridge"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function useL1StandardBridgeGoerliOtherBridge< - TFunctionName extends 'otherBridge', - TSelectData = ReadContractResult< - typeof l1StandardBridgeGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l1StandardBridgeGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1StandardBridgeGoerliAddress } = {} as any -) { - return useContractRead({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - functionName: 'otherBridge', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__ and `functionName` set to `"version"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function useL1StandardBridgeGoerliVersion< - TFunctionName extends 'version', - TSelectData = ReadContractResult< - typeof l1StandardBridgeGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l1StandardBridgeGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1StandardBridgeGoerliAddress } = {} as any -) { - return useContractRead({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - functionName: 'version', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function useL1StandardBridgeGoerliWrite< - TFunctionName extends string, - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1StandardBridgeGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1StandardBridgeGoerliABI, - string - >['request']['abi'], - TFunctionName, - TMode - > & { address?: Address; chainId?: TChainId } - : UseContractWriteConfig< - typeof l1StandardBridgeGoerliABI, - TFunctionName, - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - } = {} as any -) { - return useContractWrite< - typeof l1StandardBridgeGoerliABI, - TFunctionName, - TMode - >({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__ and `functionName` set to `"bridgeERC20"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function useL1StandardBridgeGoerliBridgeErc20< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1StandardBridgeGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1StandardBridgeGoerliABI, - 'bridgeERC20' - >['request']['abi'], - 'bridgeERC20', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'bridgeERC20' - } - : UseContractWriteConfig< - typeof l1StandardBridgeGoerliABI, - 'bridgeERC20', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'bridgeERC20' - } = {} as any -) { - return useContractWrite< - typeof l1StandardBridgeGoerliABI, - 'bridgeERC20', - TMode - >({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - functionName: 'bridgeERC20', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__ and `functionName` set to `"bridgeERC20To"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function useL1StandardBridgeGoerliBridgeErc20To< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1StandardBridgeGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1StandardBridgeGoerliABI, - 'bridgeERC20To' - >['request']['abi'], - 'bridgeERC20To', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'bridgeERC20To' - } - : UseContractWriteConfig< - typeof l1StandardBridgeGoerliABI, - 'bridgeERC20To', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'bridgeERC20To' - } = {} as any -) { - return useContractWrite< - typeof l1StandardBridgeGoerliABI, - 'bridgeERC20To', - TMode - >({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - functionName: 'bridgeERC20To', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__ and `functionName` set to `"bridgeETH"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function useL1StandardBridgeGoerliBridgeEth< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1StandardBridgeGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1StandardBridgeGoerliABI, - 'bridgeETH' - >['request']['abi'], - 'bridgeETH', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'bridgeETH' } - : UseContractWriteConfig< - typeof l1StandardBridgeGoerliABI, - 'bridgeETH', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'bridgeETH' - } = {} as any -) { - return useContractWrite( - { - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - functionName: 'bridgeETH', - ...config, - } as any - ) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__ and `functionName` set to `"bridgeETHTo"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function useL1StandardBridgeGoerliBridgeEthTo< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1StandardBridgeGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1StandardBridgeGoerliABI, - 'bridgeETHTo' - >['request']['abi'], - 'bridgeETHTo', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'bridgeETHTo' - } - : UseContractWriteConfig< - typeof l1StandardBridgeGoerliABI, - 'bridgeETHTo', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'bridgeETHTo' - } = {} as any -) { - return useContractWrite< - typeof l1StandardBridgeGoerliABI, - 'bridgeETHTo', - TMode - >({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - functionName: 'bridgeETHTo', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__ and `functionName` set to `"depositERC20"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function useL1StandardBridgeGoerliDepositErc20< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1StandardBridgeGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1StandardBridgeGoerliABI, - 'depositERC20' - >['request']['abi'], - 'depositERC20', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'depositERC20' - } - : UseContractWriteConfig< - typeof l1StandardBridgeGoerliABI, - 'depositERC20', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'depositERC20' - } = {} as any -) { - return useContractWrite< - typeof l1StandardBridgeGoerliABI, - 'depositERC20', - TMode - >({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - functionName: 'depositERC20', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__ and `functionName` set to `"depositERC20To"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function useL1StandardBridgeGoerliDepositErc20To< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1StandardBridgeGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1StandardBridgeGoerliABI, - 'depositERC20To' - >['request']['abi'], - 'depositERC20To', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'depositERC20To' - } - : UseContractWriteConfig< - typeof l1StandardBridgeGoerliABI, - 'depositERC20To', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'depositERC20To' - } = {} as any -) { - return useContractWrite< - typeof l1StandardBridgeGoerliABI, - 'depositERC20To', - TMode - >({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - functionName: 'depositERC20To', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__ and `functionName` set to `"depositETH"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function useL1StandardBridgeGoerliDepositEth< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1StandardBridgeGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1StandardBridgeGoerliABI, - 'depositETH' - >['request']['abi'], - 'depositETH', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'depositETH' } - : UseContractWriteConfig< - typeof l1StandardBridgeGoerliABI, - 'depositETH', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'depositETH' - } = {} as any -) { - return useContractWrite< - typeof l1StandardBridgeGoerliABI, - 'depositETH', - TMode - >({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - functionName: 'depositETH', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__ and `functionName` set to `"depositETHTo"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function useL1StandardBridgeGoerliDepositEthTo< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1StandardBridgeGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1StandardBridgeGoerliABI, - 'depositETHTo' - >['request']['abi'], - 'depositETHTo', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'depositETHTo' - } - : UseContractWriteConfig< - typeof l1StandardBridgeGoerliABI, - 'depositETHTo', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'depositETHTo' - } = {} as any -) { - return useContractWrite< - typeof l1StandardBridgeGoerliABI, - 'depositETHTo', - TMode - >({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - functionName: 'depositETHTo', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__ and `functionName` set to `"finalizeBridgeERC20"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function useL1StandardBridgeGoerliFinalizeBridgeErc20< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1StandardBridgeGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1StandardBridgeGoerliABI, - 'finalizeBridgeERC20' - >['request']['abi'], - 'finalizeBridgeERC20', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'finalizeBridgeERC20' - } - : UseContractWriteConfig< - typeof l1StandardBridgeGoerliABI, - 'finalizeBridgeERC20', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'finalizeBridgeERC20' - } = {} as any -) { - return useContractWrite< - typeof l1StandardBridgeGoerliABI, - 'finalizeBridgeERC20', - TMode - >({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - functionName: 'finalizeBridgeERC20', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__ and `functionName` set to `"finalizeBridgeETH"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function useL1StandardBridgeGoerliFinalizeBridgeEth< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1StandardBridgeGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1StandardBridgeGoerliABI, - 'finalizeBridgeETH' - >['request']['abi'], - 'finalizeBridgeETH', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'finalizeBridgeETH' - } - : UseContractWriteConfig< - typeof l1StandardBridgeGoerliABI, - 'finalizeBridgeETH', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'finalizeBridgeETH' - } = {} as any -) { - return useContractWrite< - typeof l1StandardBridgeGoerliABI, - 'finalizeBridgeETH', - TMode - >({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - functionName: 'finalizeBridgeETH', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__ and `functionName` set to `"finalizeERC20Withdrawal"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function useL1StandardBridgeGoerliFinalizeErc20Withdrawal< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1StandardBridgeGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1StandardBridgeGoerliABI, - 'finalizeERC20Withdrawal' - >['request']['abi'], - 'finalizeERC20Withdrawal', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'finalizeERC20Withdrawal' - } - : UseContractWriteConfig< - typeof l1StandardBridgeGoerliABI, - 'finalizeERC20Withdrawal', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'finalizeERC20Withdrawal' - } = {} as any -) { - return useContractWrite< - typeof l1StandardBridgeGoerliABI, - 'finalizeERC20Withdrawal', - TMode - >({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - functionName: 'finalizeERC20Withdrawal', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__ and `functionName` set to `"finalizeETHWithdrawal"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function useL1StandardBridgeGoerliFinalizeEthWithdrawal< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1StandardBridgeGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1StandardBridgeGoerliABI, - 'finalizeETHWithdrawal' - >['request']['abi'], - 'finalizeETHWithdrawal', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'finalizeETHWithdrawal' - } - : UseContractWriteConfig< - typeof l1StandardBridgeGoerliABI, - 'finalizeETHWithdrawal', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'finalizeETHWithdrawal' - } = {} as any -) { - return useContractWrite< - typeof l1StandardBridgeGoerliABI, - 'finalizeETHWithdrawal', - TMode - >({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - functionName: 'finalizeETHWithdrawal', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__ and `functionName` set to `"initialize"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function useL1StandardBridgeGoerliInitialize< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l1StandardBridgeGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l1StandardBridgeGoerliABI, - 'initialize' - >['request']['abi'], - 'initialize', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'initialize' } - : UseContractWriteConfig< - typeof l1StandardBridgeGoerliABI, - 'initialize', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'initialize' - } = {} as any -) { - return useContractWrite< - typeof l1StandardBridgeGoerliABI, - 'initialize', - TMode - >({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - functionName: 'initialize', - ...config, - } as any) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function usePrepareL1StandardBridgeGoerliWrite< - TFunctionName extends string ->( - config: Omit< - UsePrepareContractWriteConfig< - typeof l1StandardBridgeGoerliABI, - TFunctionName - >, - 'abi' | 'address' - > & { chainId?: keyof typeof l1StandardBridgeGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__ and `functionName` set to `"bridgeERC20"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function usePrepareL1StandardBridgeGoerliBridgeErc20( - config: Omit< - UsePrepareContractWriteConfig< - typeof l1StandardBridgeGoerliABI, - 'bridgeERC20' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1StandardBridgeGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - functionName: 'bridgeERC20', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__ and `functionName` set to `"bridgeERC20To"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function usePrepareL1StandardBridgeGoerliBridgeErc20To( - config: Omit< - UsePrepareContractWriteConfig< - typeof l1StandardBridgeGoerliABI, - 'bridgeERC20To' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1StandardBridgeGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - functionName: 'bridgeERC20To', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__ and `functionName` set to `"bridgeETH"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function usePrepareL1StandardBridgeGoerliBridgeEth( - config: Omit< - UsePrepareContractWriteConfig< - typeof l1StandardBridgeGoerliABI, - 'bridgeETH' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1StandardBridgeGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - functionName: 'bridgeETH', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__ and `functionName` set to `"bridgeETHTo"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function usePrepareL1StandardBridgeGoerliBridgeEthTo( - config: Omit< - UsePrepareContractWriteConfig< - typeof l1StandardBridgeGoerliABI, - 'bridgeETHTo' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1StandardBridgeGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - functionName: 'bridgeETHTo', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__ and `functionName` set to `"depositERC20"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function usePrepareL1StandardBridgeGoerliDepositErc20( - config: Omit< - UsePrepareContractWriteConfig< - typeof l1StandardBridgeGoerliABI, - 'depositERC20' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1StandardBridgeGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - functionName: 'depositERC20', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__ and `functionName` set to `"depositERC20To"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function usePrepareL1StandardBridgeGoerliDepositErc20To( - config: Omit< - UsePrepareContractWriteConfig< - typeof l1StandardBridgeGoerliABI, - 'depositERC20To' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1StandardBridgeGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - functionName: 'depositERC20To', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__ and `functionName` set to `"depositETH"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function usePrepareL1StandardBridgeGoerliDepositEth( - config: Omit< - UsePrepareContractWriteConfig< - typeof l1StandardBridgeGoerliABI, - 'depositETH' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1StandardBridgeGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - functionName: 'depositETH', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__ and `functionName` set to `"depositETHTo"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function usePrepareL1StandardBridgeGoerliDepositEthTo( - config: Omit< - UsePrepareContractWriteConfig< - typeof l1StandardBridgeGoerliABI, - 'depositETHTo' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1StandardBridgeGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - functionName: 'depositETHTo', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__ and `functionName` set to `"finalizeBridgeERC20"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function usePrepareL1StandardBridgeGoerliFinalizeBridgeErc20( - config: Omit< - UsePrepareContractWriteConfig< - typeof l1StandardBridgeGoerliABI, - 'finalizeBridgeERC20' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1StandardBridgeGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - functionName: 'finalizeBridgeERC20', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__ and `functionName` set to `"finalizeBridgeETH"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function usePrepareL1StandardBridgeGoerliFinalizeBridgeEth( - config: Omit< - UsePrepareContractWriteConfig< - typeof l1StandardBridgeGoerliABI, - 'finalizeBridgeETH' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1StandardBridgeGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - functionName: 'finalizeBridgeETH', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__ and `functionName` set to `"finalizeERC20Withdrawal"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function usePrepareL1StandardBridgeGoerliFinalizeErc20Withdrawal( - config: Omit< - UsePrepareContractWriteConfig< - typeof l1StandardBridgeGoerliABI, - 'finalizeERC20Withdrawal' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1StandardBridgeGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - functionName: 'finalizeERC20Withdrawal', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__ and `functionName` set to `"finalizeETHWithdrawal"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function usePrepareL1StandardBridgeGoerliFinalizeEthWithdrawal( - config: Omit< - UsePrepareContractWriteConfig< - typeof l1StandardBridgeGoerliABI, - 'finalizeETHWithdrawal' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1StandardBridgeGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - functionName: 'finalizeETHWithdrawal', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__ and `functionName` set to `"initialize"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function usePrepareL1StandardBridgeGoerliInitialize( - config: Omit< - UsePrepareContractWriteConfig< - typeof l1StandardBridgeGoerliABI, - 'initialize' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l1StandardBridgeGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - functionName: 'initialize', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function useL1StandardBridgeGoerliEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l1StandardBridgeGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__ and `eventName` set to `"ERC20BridgeFinalized"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function useL1StandardBridgeGoerliErc20BridgeFinalizedEvent( - config: Omit< - UseContractEventConfig< - typeof l1StandardBridgeGoerliABI, - 'ERC20BridgeFinalized' - >, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l1StandardBridgeGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - eventName: 'ERC20BridgeFinalized', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__ and `eventName` set to `"ERC20BridgeInitiated"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function useL1StandardBridgeGoerliErc20BridgeInitiatedEvent( - config: Omit< - UseContractEventConfig< - typeof l1StandardBridgeGoerliABI, - 'ERC20BridgeInitiated' - >, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l1StandardBridgeGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - eventName: 'ERC20BridgeInitiated', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__ and `eventName` set to `"ERC20DepositInitiated"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function useL1StandardBridgeGoerliErc20DepositInitiatedEvent( - config: Omit< - UseContractEventConfig< - typeof l1StandardBridgeGoerliABI, - 'ERC20DepositInitiated' - >, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l1StandardBridgeGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - eventName: 'ERC20DepositInitiated', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__ and `eventName` set to `"ERC20WithdrawalFinalized"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function useL1StandardBridgeGoerliErc20WithdrawalFinalizedEvent( - config: Omit< - UseContractEventConfig< - typeof l1StandardBridgeGoerliABI, - 'ERC20WithdrawalFinalized' - >, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l1StandardBridgeGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - eventName: 'ERC20WithdrawalFinalized', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__ and `eventName` set to `"ETHBridgeFinalized"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function useL1StandardBridgeGoerliEthBridgeFinalizedEvent( - config: Omit< - UseContractEventConfig< - typeof l1StandardBridgeGoerliABI, - 'ETHBridgeFinalized' - >, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l1StandardBridgeGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - eventName: 'ETHBridgeFinalized', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__ and `eventName` set to `"ETHBridgeInitiated"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function useL1StandardBridgeGoerliEthBridgeInitiatedEvent( - config: Omit< - UseContractEventConfig< - typeof l1StandardBridgeGoerliABI, - 'ETHBridgeInitiated' - >, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l1StandardBridgeGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - eventName: 'ETHBridgeInitiated', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__ and `eventName` set to `"ETHDepositInitiated"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function useL1StandardBridgeGoerliEthDepositInitiatedEvent( - config: Omit< - UseContractEventConfig< - typeof l1StandardBridgeGoerliABI, - 'ETHDepositInitiated' - >, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l1StandardBridgeGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - eventName: 'ETHDepositInitiated', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__ and `eventName` set to `"ETHWithdrawalFinalized"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function useL1StandardBridgeGoerliEthWithdrawalFinalizedEvent( - config: Omit< - UseContractEventConfig< - typeof l1StandardBridgeGoerliABI, - 'ETHWithdrawalFinalized' - >, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l1StandardBridgeGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - eventName: 'ETHWithdrawalFinalized', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l1StandardBridgeGoerliABI}__ and `eventName` set to `"Initialized"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) - */ -export function useL1StandardBridgeGoerliInitializedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l1StandardBridgeGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: l1StandardBridgeGoerliABI, - address: l1StandardBridgeGoerliAddress[5], - eventName: 'Initialized', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2CrossDomainMessengerABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) - */ -export function useL2CrossDomainMessengerRead< - TFunctionName extends string, - TSelectData = ReadContractResult< - typeof l2CrossDomainMessengerABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l2CrossDomainMessengerABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' - > & { chainId?: keyof typeof l2CrossDomainMessengerAddress } = {} as any -) { - return useContractRead({ - abi: l2CrossDomainMessengerABI, - address: l2CrossDomainMessengerAddress[420], - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2CrossDomainMessengerABI}__ and `functionName` set to `"MESSAGE_VERSION"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) - */ -export function useL2CrossDomainMessengerMessageVersion< - TFunctionName extends 'MESSAGE_VERSION', - TSelectData = ReadContractResult< - typeof l2CrossDomainMessengerABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l2CrossDomainMessengerABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2CrossDomainMessengerAddress } = {} as any -) { - return useContractRead({ - abi: l2CrossDomainMessengerABI, - address: l2CrossDomainMessengerAddress[420], - functionName: 'MESSAGE_VERSION', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2CrossDomainMessengerABI}__ and `functionName` set to `"MIN_GAS_CALLDATA_OVERHEAD"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) - */ -export function useL2CrossDomainMessengerMinGasCalldataOverhead< - TFunctionName extends 'MIN_GAS_CALLDATA_OVERHEAD', - TSelectData = ReadContractResult< - typeof l2CrossDomainMessengerABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l2CrossDomainMessengerABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2CrossDomainMessengerAddress } = {} as any -) { - return useContractRead({ - abi: l2CrossDomainMessengerABI, - address: l2CrossDomainMessengerAddress[420], - functionName: 'MIN_GAS_CALLDATA_OVERHEAD', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2CrossDomainMessengerABI}__ and `functionName` set to `"MIN_GAS_DYNAMIC_OVERHEAD_DENOMINATOR"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) - */ -export function useL2CrossDomainMessengerMinGasDynamicOverheadDenominator< - TFunctionName extends 'MIN_GAS_DYNAMIC_OVERHEAD_DENOMINATOR', - TSelectData = ReadContractResult< - typeof l2CrossDomainMessengerABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l2CrossDomainMessengerABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2CrossDomainMessengerAddress } = {} as any -) { - return useContractRead({ - abi: l2CrossDomainMessengerABI, - address: l2CrossDomainMessengerAddress[420], - functionName: 'MIN_GAS_DYNAMIC_OVERHEAD_DENOMINATOR', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2CrossDomainMessengerABI}__ and `functionName` set to `"MIN_GAS_DYNAMIC_OVERHEAD_NUMERATOR"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) - */ -export function useL2CrossDomainMessengerMinGasDynamicOverheadNumerator< - TFunctionName extends 'MIN_GAS_DYNAMIC_OVERHEAD_NUMERATOR', - TSelectData = ReadContractResult< - typeof l2CrossDomainMessengerABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l2CrossDomainMessengerABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2CrossDomainMessengerAddress } = {} as any -) { - return useContractRead({ - abi: l2CrossDomainMessengerABI, - address: l2CrossDomainMessengerAddress[420], - functionName: 'MIN_GAS_DYNAMIC_OVERHEAD_NUMERATOR', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2CrossDomainMessengerABI}__ and `functionName` set to `"OTHER_MESSENGER"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) - */ -export function useL2CrossDomainMessengerOtherMessenger< - TFunctionName extends 'OTHER_MESSENGER', - TSelectData = ReadContractResult< - typeof l2CrossDomainMessengerABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l2CrossDomainMessengerABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2CrossDomainMessengerAddress } = {} as any -) { - return useContractRead({ - abi: l2CrossDomainMessengerABI, - address: l2CrossDomainMessengerAddress[420], - functionName: 'OTHER_MESSENGER', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2CrossDomainMessengerABI}__ and `functionName` set to `"RELAY_CALL_OVERHEAD"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) - */ -export function useL2CrossDomainMessengerRelayCallOverhead< - TFunctionName extends 'RELAY_CALL_OVERHEAD', - TSelectData = ReadContractResult< - typeof l2CrossDomainMessengerABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l2CrossDomainMessengerABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2CrossDomainMessengerAddress } = {} as any -) { - return useContractRead({ - abi: l2CrossDomainMessengerABI, - address: l2CrossDomainMessengerAddress[420], - functionName: 'RELAY_CALL_OVERHEAD', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2CrossDomainMessengerABI}__ and `functionName` set to `"RELAY_CONSTANT_OVERHEAD"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) - */ -export function useL2CrossDomainMessengerRelayConstantOverhead< - TFunctionName extends 'RELAY_CONSTANT_OVERHEAD', - TSelectData = ReadContractResult< - typeof l2CrossDomainMessengerABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l2CrossDomainMessengerABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2CrossDomainMessengerAddress } = {} as any -) { - return useContractRead({ - abi: l2CrossDomainMessengerABI, - address: l2CrossDomainMessengerAddress[420], - functionName: 'RELAY_CONSTANT_OVERHEAD', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2CrossDomainMessengerABI}__ and `functionName` set to `"RELAY_GAS_CHECK_BUFFER"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) - */ -export function useL2CrossDomainMessengerRelayGasCheckBuffer< - TFunctionName extends 'RELAY_GAS_CHECK_BUFFER', - TSelectData = ReadContractResult< - typeof l2CrossDomainMessengerABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l2CrossDomainMessengerABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2CrossDomainMessengerAddress } = {} as any -) { - return useContractRead({ - abi: l2CrossDomainMessengerABI, - address: l2CrossDomainMessengerAddress[420], - functionName: 'RELAY_GAS_CHECK_BUFFER', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2CrossDomainMessengerABI}__ and `functionName` set to `"RELAY_RESERVED_GAS"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) - */ -export function useL2CrossDomainMessengerRelayReservedGas< - TFunctionName extends 'RELAY_RESERVED_GAS', - TSelectData = ReadContractResult< - typeof l2CrossDomainMessengerABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l2CrossDomainMessengerABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2CrossDomainMessengerAddress } = {} as any -) { - return useContractRead({ - abi: l2CrossDomainMessengerABI, - address: l2CrossDomainMessengerAddress[420], - functionName: 'RELAY_RESERVED_GAS', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2CrossDomainMessengerABI}__ and `functionName` set to `"baseGas"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) - */ -export function useL2CrossDomainMessengerBaseGas< - TFunctionName extends 'baseGas', - TSelectData = ReadContractResult< - typeof l2CrossDomainMessengerABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l2CrossDomainMessengerABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2CrossDomainMessengerAddress } = {} as any -) { - return useContractRead({ - abi: l2CrossDomainMessengerABI, - address: l2CrossDomainMessengerAddress[420], - functionName: 'baseGas', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2CrossDomainMessengerABI}__ and `functionName` set to `"failedMessages"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) - */ -export function useL2CrossDomainMessengerFailedMessages< - TFunctionName extends 'failedMessages', - TSelectData = ReadContractResult< - typeof l2CrossDomainMessengerABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l2CrossDomainMessengerABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2CrossDomainMessengerAddress } = {} as any -) { - return useContractRead({ - abi: l2CrossDomainMessengerABI, - address: l2CrossDomainMessengerAddress[420], - functionName: 'failedMessages', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2CrossDomainMessengerABI}__ and `functionName` set to `"l1CrossDomainMessenger"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) - */ -export function useL2CrossDomainMessengerL1CrossDomainMessenger< - TFunctionName extends 'l1CrossDomainMessenger', - TSelectData = ReadContractResult< - typeof l2CrossDomainMessengerABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l2CrossDomainMessengerABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2CrossDomainMessengerAddress } = {} as any -) { - return useContractRead({ - abi: l2CrossDomainMessengerABI, - address: l2CrossDomainMessengerAddress[420], - functionName: 'l1CrossDomainMessenger', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2CrossDomainMessengerABI}__ and `functionName` set to `"messageNonce"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) - */ -export function useL2CrossDomainMessengerMessageNonce< - TFunctionName extends 'messageNonce', - TSelectData = ReadContractResult< - typeof l2CrossDomainMessengerABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l2CrossDomainMessengerABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2CrossDomainMessengerAddress } = {} as any -) { - return useContractRead({ - abi: l2CrossDomainMessengerABI, - address: l2CrossDomainMessengerAddress[420], - functionName: 'messageNonce', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2CrossDomainMessengerABI}__ and `functionName` set to `"successfulMessages"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) - */ -export function useL2CrossDomainMessengerSuccessfulMessages< - TFunctionName extends 'successfulMessages', - TSelectData = ReadContractResult< - typeof l2CrossDomainMessengerABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l2CrossDomainMessengerABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2CrossDomainMessengerAddress } = {} as any -) { - return useContractRead({ - abi: l2CrossDomainMessengerABI, - address: l2CrossDomainMessengerAddress[420], - functionName: 'successfulMessages', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2CrossDomainMessengerABI}__ and `functionName` set to `"version"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) - */ -export function useL2CrossDomainMessengerVersion< - TFunctionName extends 'version', - TSelectData = ReadContractResult< - typeof l2CrossDomainMessengerABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l2CrossDomainMessengerABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2CrossDomainMessengerAddress } = {} as any -) { - return useContractRead({ - abi: l2CrossDomainMessengerABI, - address: l2CrossDomainMessengerAddress[420], - functionName: 'version', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2CrossDomainMessengerABI}__ and `functionName` set to `"xDomainMessageSender"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) - */ -export function useL2CrossDomainMessengerXDomainMessageSender< - TFunctionName extends 'xDomainMessageSender', - TSelectData = ReadContractResult< - typeof l2CrossDomainMessengerABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l2CrossDomainMessengerABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2CrossDomainMessengerAddress } = {} as any -) { - return useContractRead({ - abi: l2CrossDomainMessengerABI, - address: l2CrossDomainMessengerAddress[420], - functionName: 'xDomainMessageSender', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l2CrossDomainMessengerABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) - */ -export function useL2CrossDomainMessengerWrite< - TFunctionName extends string, - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l2CrossDomainMessengerAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l2CrossDomainMessengerABI, - string - >['request']['abi'], - TFunctionName, - TMode - > & { address?: Address; chainId?: TChainId } - : UseContractWriteConfig< - typeof l2CrossDomainMessengerABI, - TFunctionName, - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - } = {} as any -) { - return useContractWrite< - typeof l2CrossDomainMessengerABI, - TFunctionName, - TMode - >({ - abi: l2CrossDomainMessengerABI, - address: l2CrossDomainMessengerAddress[420], - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l2CrossDomainMessengerABI}__ and `functionName` set to `"initialize"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) - */ -export function useL2CrossDomainMessengerInitialize< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l2CrossDomainMessengerAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l2CrossDomainMessengerABI, - 'initialize' - >['request']['abi'], - 'initialize', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'initialize' } - : UseContractWriteConfig< - typeof l2CrossDomainMessengerABI, - 'initialize', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'initialize' - } = {} as any -) { - return useContractWrite< - typeof l2CrossDomainMessengerABI, - 'initialize', - TMode - >({ - abi: l2CrossDomainMessengerABI, - address: l2CrossDomainMessengerAddress[420], - functionName: 'initialize', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l2CrossDomainMessengerABI}__ and `functionName` set to `"relayMessage"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) - */ -export function useL2CrossDomainMessengerRelayMessage< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l2CrossDomainMessengerAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l2CrossDomainMessengerABI, - 'relayMessage' - >['request']['abi'], - 'relayMessage', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'relayMessage' - } - : UseContractWriteConfig< - typeof l2CrossDomainMessengerABI, - 'relayMessage', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'relayMessage' - } = {} as any -) { - return useContractWrite< - typeof l2CrossDomainMessengerABI, - 'relayMessage', - TMode - >({ - abi: l2CrossDomainMessengerABI, - address: l2CrossDomainMessengerAddress[420], - functionName: 'relayMessage', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l2CrossDomainMessengerABI}__ and `functionName` set to `"sendMessage"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) - */ -export function useL2CrossDomainMessengerSendMessage< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l2CrossDomainMessengerAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l2CrossDomainMessengerABI, - 'sendMessage' - >['request']['abi'], - 'sendMessage', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'sendMessage' - } - : UseContractWriteConfig< - typeof l2CrossDomainMessengerABI, - 'sendMessage', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'sendMessage' - } = {} as any -) { - return useContractWrite< - typeof l2CrossDomainMessengerABI, - 'sendMessage', - TMode - >({ - abi: l2CrossDomainMessengerABI, - address: l2CrossDomainMessengerAddress[420], - functionName: 'sendMessage', - ...config, - } as any) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l2CrossDomainMessengerABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) - */ -export function usePrepareL2CrossDomainMessengerWrite< - TFunctionName extends string ->( - config: Omit< - UsePrepareContractWriteConfig< - typeof l2CrossDomainMessengerABI, - TFunctionName - >, - 'abi' | 'address' - > & { chainId?: keyof typeof l2CrossDomainMessengerAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l2CrossDomainMessengerABI, - address: l2CrossDomainMessengerAddress[420], - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l2CrossDomainMessengerABI}__ and `functionName` set to `"initialize"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) - */ -export function usePrepareL2CrossDomainMessengerInitialize( - config: Omit< - UsePrepareContractWriteConfig< - typeof l2CrossDomainMessengerABI, - 'initialize' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2CrossDomainMessengerAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l2CrossDomainMessengerABI, - address: l2CrossDomainMessengerAddress[420], - functionName: 'initialize', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l2CrossDomainMessengerABI}__ and `functionName` set to `"relayMessage"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) - */ -export function usePrepareL2CrossDomainMessengerRelayMessage( - config: Omit< - UsePrepareContractWriteConfig< - typeof l2CrossDomainMessengerABI, - 'relayMessage' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2CrossDomainMessengerAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l2CrossDomainMessengerABI, - address: l2CrossDomainMessengerAddress[420], - functionName: 'relayMessage', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l2CrossDomainMessengerABI}__ and `functionName` set to `"sendMessage"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) - */ -export function usePrepareL2CrossDomainMessengerSendMessage( - config: Omit< - UsePrepareContractWriteConfig< - typeof l2CrossDomainMessengerABI, - 'sendMessage' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2CrossDomainMessengerAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l2CrossDomainMessengerABI, - address: l2CrossDomainMessengerAddress[420], - functionName: 'sendMessage', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l2CrossDomainMessengerABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) - */ -export function useL2CrossDomainMessengerEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l2CrossDomainMessengerAddress } = {} as any -) { - return useContractEvent({ - abi: l2CrossDomainMessengerABI, - address: l2CrossDomainMessengerAddress[420], - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l2CrossDomainMessengerABI}__ and `eventName` set to `"FailedRelayedMessage"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) - */ -export function useL2CrossDomainMessengerFailedRelayedMessageEvent( - config: Omit< - UseContractEventConfig< - typeof l2CrossDomainMessengerABI, - 'FailedRelayedMessage' - >, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l2CrossDomainMessengerAddress } = {} as any -) { - return useContractEvent({ - abi: l2CrossDomainMessengerABI, - address: l2CrossDomainMessengerAddress[420], - eventName: 'FailedRelayedMessage', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l2CrossDomainMessengerABI}__ and `eventName` set to `"Initialized"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) - */ -export function useL2CrossDomainMessengerInitializedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l2CrossDomainMessengerAddress } = {} as any -) { - return useContractEvent({ - abi: l2CrossDomainMessengerABI, - address: l2CrossDomainMessengerAddress[420], - eventName: 'Initialized', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l2CrossDomainMessengerABI}__ and `eventName` set to `"RelayedMessage"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) - */ -export function useL2CrossDomainMessengerRelayedMessageEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l2CrossDomainMessengerAddress } = {} as any -) { - return useContractEvent({ - abi: l2CrossDomainMessengerABI, - address: l2CrossDomainMessengerAddress[420], - eventName: 'RelayedMessage', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l2CrossDomainMessengerABI}__ and `eventName` set to `"SentMessage"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) - */ -export function useL2CrossDomainMessengerSentMessageEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l2CrossDomainMessengerAddress } = {} as any -) { - return useContractEvent({ - abi: l2CrossDomainMessengerABI, - address: l2CrossDomainMessengerAddress[420], - eventName: 'SentMessage', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l2CrossDomainMessengerABI}__ and `eventName` set to `"SentMessageExtension1"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) - */ -export function useL2CrossDomainMessengerSentMessageExtension1Event( - config: Omit< - UseContractEventConfig< - typeof l2CrossDomainMessengerABI, - 'SentMessageExtension1' - >, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l2CrossDomainMessengerAddress } = {} as any -) { - return useContractEvent({ - abi: l2CrossDomainMessengerABI, - address: l2CrossDomainMessengerAddress[420], - eventName: 'SentMessageExtension1', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2Erc721BridgeABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000014) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000014) - */ -export function useL2Erc721BridgeRead< - TFunctionName extends string, - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l2Erc721BridgeAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: l2Erc721BridgeABI, - address: - l2Erc721BridgeAddress[chainId as keyof typeof l2Erc721BridgeAddress], - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2Erc721BridgeABI}__ and `functionName` set to `"messenger"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000014) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000014) - */ -export function useL2Erc721BridgeMessenger< - TFunctionName extends 'messenger', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2Erc721BridgeAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: l2Erc721BridgeABI, - address: - l2Erc721BridgeAddress[chainId as keyof typeof l2Erc721BridgeAddress], - functionName: 'messenger', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2Erc721BridgeABI}__ and `functionName` set to `"otherBridge"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000014) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000014) - */ -export function useL2Erc721BridgeOtherBridge< - TFunctionName extends 'otherBridge', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2Erc721BridgeAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: l2Erc721BridgeABI, - address: - l2Erc721BridgeAddress[chainId as keyof typeof l2Erc721BridgeAddress], - functionName: 'otherBridge', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2Erc721BridgeABI}__ and `functionName` set to `"version"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000014) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000014) - */ -export function useL2Erc721BridgeVersion< - TFunctionName extends 'version', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2Erc721BridgeAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: l2Erc721BridgeABI, - address: - l2Erc721BridgeAddress[chainId as keyof typeof l2Erc721BridgeAddress], - functionName: 'version', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l2Erc721BridgeABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000014) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000014) - */ -export function useL2Erc721BridgeWrite< - TFunctionName extends string, - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l2Erc721BridgeAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l2Erc721BridgeABI, - string - >['request']['abi'], - TFunctionName, - TMode - > & { address?: Address; chainId?: TChainId } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: l2Erc721BridgeABI, - address: - l2Erc721BridgeAddress[chainId as keyof typeof l2Erc721BridgeAddress], - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l2Erc721BridgeABI}__ and `functionName` set to `"bridgeERC721"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000014) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000014) - */ -export function useL2Erc721BridgeBridgeErc721< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l2Erc721BridgeAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l2Erc721BridgeABI, - 'bridgeERC721' - >['request']['abi'], - 'bridgeERC721', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'bridgeERC721' - } - : UseContractWriteConfig< - typeof l2Erc721BridgeABI, - 'bridgeERC721', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'bridgeERC721' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: l2Erc721BridgeABI, - address: - l2Erc721BridgeAddress[chainId as keyof typeof l2Erc721BridgeAddress], - functionName: 'bridgeERC721', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l2Erc721BridgeABI}__ and `functionName` set to `"bridgeERC721To"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000014) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000014) - */ -export function useL2Erc721BridgeBridgeErc721To< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l2Erc721BridgeAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l2Erc721BridgeABI, - 'bridgeERC721To' - >['request']['abi'], - 'bridgeERC721To', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'bridgeERC721To' - } - : UseContractWriteConfig< - typeof l2Erc721BridgeABI, - 'bridgeERC721To', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'bridgeERC721To' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: l2Erc721BridgeABI, - address: - l2Erc721BridgeAddress[chainId as keyof typeof l2Erc721BridgeAddress], - functionName: 'bridgeERC721To', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l2Erc721BridgeABI}__ and `functionName` set to `"finalizeBridgeERC721"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000014) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000014) - */ -export function useL2Erc721BridgeFinalizeBridgeErc721< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l2Erc721BridgeAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l2Erc721BridgeABI, - 'finalizeBridgeERC721' - >['request']['abi'], - 'finalizeBridgeERC721', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'finalizeBridgeERC721' - } - : UseContractWriteConfig< - typeof l2Erc721BridgeABI, - 'finalizeBridgeERC721', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'finalizeBridgeERC721' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite< - typeof l2Erc721BridgeABI, - 'finalizeBridgeERC721', - TMode - >({ - abi: l2Erc721BridgeABI, - address: - l2Erc721BridgeAddress[chainId as keyof typeof l2Erc721BridgeAddress], - functionName: 'finalizeBridgeERC721', - ...config, - } as any) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l2Erc721BridgeABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000014) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000014) - */ -export function usePrepareL2Erc721BridgeWrite( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l2Erc721BridgeAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: l2Erc721BridgeABI, - address: - l2Erc721BridgeAddress[chainId as keyof typeof l2Erc721BridgeAddress], - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l2Erc721BridgeABI}__ and `functionName` set to `"bridgeERC721"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000014) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000014) - */ -export function usePrepareL2Erc721BridgeBridgeErc721( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2Erc721BridgeAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: l2Erc721BridgeABI, - address: - l2Erc721BridgeAddress[chainId as keyof typeof l2Erc721BridgeAddress], - functionName: 'bridgeERC721', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l2Erc721BridgeABI}__ and `functionName` set to `"bridgeERC721To"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000014) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000014) - */ -export function usePrepareL2Erc721BridgeBridgeErc721To( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2Erc721BridgeAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: l2Erc721BridgeABI, - address: - l2Erc721BridgeAddress[chainId as keyof typeof l2Erc721BridgeAddress], - functionName: 'bridgeERC721To', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l2Erc721BridgeABI}__ and `functionName` set to `"finalizeBridgeERC721"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000014) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000014) - */ -export function usePrepareL2Erc721BridgeFinalizeBridgeErc721( - config: Omit< - UsePrepareContractWriteConfig< - typeof l2Erc721BridgeABI, - 'finalizeBridgeERC721' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2Erc721BridgeAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: l2Erc721BridgeABI, - address: - l2Erc721BridgeAddress[chainId as keyof typeof l2Erc721BridgeAddress], - functionName: 'finalizeBridgeERC721', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l2Erc721BridgeABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000014) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000014) - */ -export function useL2Erc721BridgeEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l2Erc721BridgeAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractEvent({ - abi: l2Erc721BridgeABI, - address: - l2Erc721BridgeAddress[chainId as keyof typeof l2Erc721BridgeAddress], - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l2Erc721BridgeABI}__ and `eventName` set to `"ERC721BridgeFinalized"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000014) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000014) - */ -export function useL2Erc721BridgeErc721BridgeFinalizedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l2Erc721BridgeAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractEvent({ - abi: l2Erc721BridgeABI, - address: - l2Erc721BridgeAddress[chainId as keyof typeof l2Erc721BridgeAddress], - eventName: 'ERC721BridgeFinalized', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l2Erc721BridgeABI}__ and `eventName` set to `"ERC721BridgeInitiated"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000014) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000014) - */ -export function useL2Erc721BridgeErc721BridgeInitiatedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l2Erc721BridgeAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractEvent({ - abi: l2Erc721BridgeABI, - address: - l2Erc721BridgeAddress[chainId as keyof typeof l2Erc721BridgeAddress], - eventName: 'ERC721BridgeInitiated', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2OutputOracleABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) - */ -export function useL2OutputOracleRead< - TFunctionName extends string, - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l2OutputOracleAddress } = {} as any -) { - return useContractRead({ - abi: l2OutputOracleABI, - address: l2OutputOracleAddress[1], - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2OutputOracleABI}__ and `functionName` set to `"CHALLENGER"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) - */ -export function useL2OutputOracleChallenger< - TFunctionName extends 'CHALLENGER', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2OutputOracleAddress } = {} as any -) { - return useContractRead({ - abi: l2OutputOracleABI, - address: l2OutputOracleAddress[1], - functionName: 'CHALLENGER', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2OutputOracleABI}__ and `functionName` set to `"FINALIZATION_PERIOD_SECONDS"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) - */ -export function useL2OutputOracleFinalizationPeriodSeconds< - TFunctionName extends 'FINALIZATION_PERIOD_SECONDS', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2OutputOracleAddress } = {} as any -) { - return useContractRead({ - abi: l2OutputOracleABI, - address: l2OutputOracleAddress[1], - functionName: 'FINALIZATION_PERIOD_SECONDS', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2OutputOracleABI}__ and `functionName` set to `"L2_BLOCK_TIME"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) - */ -export function useL2OutputOracleL2BlockTime< - TFunctionName extends 'L2_BLOCK_TIME', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2OutputOracleAddress } = {} as any -) { - return useContractRead({ - abi: l2OutputOracleABI, - address: l2OutputOracleAddress[1], - functionName: 'L2_BLOCK_TIME', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2OutputOracleABI}__ and `functionName` set to `"PROPOSER"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) - */ -export function useL2OutputOracleProposer< - TFunctionName extends 'PROPOSER', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2OutputOracleAddress } = {} as any -) { - return useContractRead({ - abi: l2OutputOracleABI, - address: l2OutputOracleAddress[1], - functionName: 'PROPOSER', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2OutputOracleABI}__ and `functionName` set to `"SUBMISSION_INTERVAL"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) - */ -export function useL2OutputOracleSubmissionInterval< - TFunctionName extends 'SUBMISSION_INTERVAL', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2OutputOracleAddress } = {} as any -) { - return useContractRead({ - abi: l2OutputOracleABI, - address: l2OutputOracleAddress[1], - functionName: 'SUBMISSION_INTERVAL', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2OutputOracleABI}__ and `functionName` set to `"computeL2Timestamp"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) - */ -export function useL2OutputOracleComputeL2Timestamp< - TFunctionName extends 'computeL2Timestamp', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2OutputOracleAddress } = {} as any -) { - return useContractRead({ - abi: l2OutputOracleABI, - address: l2OutputOracleAddress[1], - functionName: 'computeL2Timestamp', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2OutputOracleABI}__ and `functionName` set to `"getL2Output"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) - */ -export function useL2OutputOracleGetL2Output< - TFunctionName extends 'getL2Output', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2OutputOracleAddress } = {} as any -) { - return useContractRead({ - abi: l2OutputOracleABI, - address: l2OutputOracleAddress[1], - functionName: 'getL2Output', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2OutputOracleABI}__ and `functionName` set to `"getL2OutputAfter"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) - */ -export function useL2OutputOracleGetL2OutputAfter< - TFunctionName extends 'getL2OutputAfter', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2OutputOracleAddress } = {} as any -) { - return useContractRead({ - abi: l2OutputOracleABI, - address: l2OutputOracleAddress[1], - functionName: 'getL2OutputAfter', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2OutputOracleABI}__ and `functionName` set to `"getL2OutputIndexAfter"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) - */ -export function useL2OutputOracleGetL2OutputIndexAfter< - TFunctionName extends 'getL2OutputIndexAfter', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2OutputOracleAddress } = {} as any -) { - return useContractRead({ - abi: l2OutputOracleABI, - address: l2OutputOracleAddress[1], - functionName: 'getL2OutputIndexAfter', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2OutputOracleABI}__ and `functionName` set to `"latestBlockNumber"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) - */ -export function useL2OutputOracleLatestBlockNumber< - TFunctionName extends 'latestBlockNumber', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2OutputOracleAddress } = {} as any -) { - return useContractRead({ - abi: l2OutputOracleABI, - address: l2OutputOracleAddress[1], - functionName: 'latestBlockNumber', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2OutputOracleABI}__ and `functionName` set to `"latestOutputIndex"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) - */ -export function useL2OutputOracleLatestOutputIndex< - TFunctionName extends 'latestOutputIndex', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2OutputOracleAddress } = {} as any -) { - return useContractRead({ - abi: l2OutputOracleABI, - address: l2OutputOracleAddress[1], - functionName: 'latestOutputIndex', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2OutputOracleABI}__ and `functionName` set to `"nextBlockNumber"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) - */ -export function useL2OutputOracleNextBlockNumber< - TFunctionName extends 'nextBlockNumber', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2OutputOracleAddress } = {} as any -) { - return useContractRead({ - abi: l2OutputOracleABI, - address: l2OutputOracleAddress[1], - functionName: 'nextBlockNumber', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2OutputOracleABI}__ and `functionName` set to `"nextOutputIndex"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) - */ -export function useL2OutputOracleNextOutputIndex< - TFunctionName extends 'nextOutputIndex', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2OutputOracleAddress } = {} as any -) { - return useContractRead({ - abi: l2OutputOracleABI, - address: l2OutputOracleAddress[1], - functionName: 'nextOutputIndex', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2OutputOracleABI}__ and `functionName` set to `"startingBlockNumber"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) - */ -export function useL2OutputOracleStartingBlockNumber< - TFunctionName extends 'startingBlockNumber', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2OutputOracleAddress } = {} as any -) { - return useContractRead({ - abi: l2OutputOracleABI, - address: l2OutputOracleAddress[1], - functionName: 'startingBlockNumber', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2OutputOracleABI}__ and `functionName` set to `"startingTimestamp"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) - */ -export function useL2OutputOracleStartingTimestamp< - TFunctionName extends 'startingTimestamp', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2OutputOracleAddress } = {} as any -) { - return useContractRead({ - abi: l2OutputOracleABI, - address: l2OutputOracleAddress[1], - functionName: 'startingTimestamp', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2OutputOracleABI}__ and `functionName` set to `"version"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) - */ -export function useL2OutputOracleVersion< - TFunctionName extends 'version', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2OutputOracleAddress } = {} as any -) { - return useContractRead({ - abi: l2OutputOracleABI, - address: l2OutputOracleAddress[1], - functionName: 'version', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l2OutputOracleABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) - */ -export function useL2OutputOracleWrite< - TFunctionName extends string, - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l2OutputOracleAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l2OutputOracleABI, - string - >['request']['abi'], - TFunctionName, - TMode - > & { address?: Address; chainId?: TChainId } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - } = {} as any -) { - return useContractWrite({ - abi: l2OutputOracleABI, - address: l2OutputOracleAddress[1], - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l2OutputOracleABI}__ and `functionName` set to `"deleteL2Outputs"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) - */ -export function useL2OutputOracleDeleteL2Outputs< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l2OutputOracleAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l2OutputOracleABI, - 'deleteL2Outputs' - >['request']['abi'], - 'deleteL2Outputs', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'deleteL2Outputs' - } - : UseContractWriteConfig< - typeof l2OutputOracleABI, - 'deleteL2Outputs', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'deleteL2Outputs' - } = {} as any -) { - return useContractWrite({ - abi: l2OutputOracleABI, - address: l2OutputOracleAddress[1], - functionName: 'deleteL2Outputs', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l2OutputOracleABI}__ and `functionName` set to `"initialize"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) - */ -export function useL2OutputOracleInitialize< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l2OutputOracleAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l2OutputOracleABI, - 'initialize' - >['request']['abi'], - 'initialize', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'initialize' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'initialize' - } = {} as any -) { - return useContractWrite({ - abi: l2OutputOracleABI, - address: l2OutputOracleAddress[1], - functionName: 'initialize', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l2OutputOracleABI}__ and `functionName` set to `"proposeL2Output"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) - */ -export function useL2OutputOracleProposeL2Output< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l2OutputOracleAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l2OutputOracleABI, - 'proposeL2Output' - >['request']['abi'], - 'proposeL2Output', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'proposeL2Output' - } - : UseContractWriteConfig< - typeof l2OutputOracleABI, - 'proposeL2Output', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'proposeL2Output' - } = {} as any -) { - return useContractWrite({ - abi: l2OutputOracleABI, - address: l2OutputOracleAddress[1], - functionName: 'proposeL2Output', - ...config, - } as any) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l2OutputOracleABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) - */ -export function usePrepareL2OutputOracleWrite( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l2OutputOracleAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l2OutputOracleABI, - address: l2OutputOracleAddress[1], - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l2OutputOracleABI}__ and `functionName` set to `"deleteL2Outputs"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) - */ -export function usePrepareL2OutputOracleDeleteL2Outputs( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2OutputOracleAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l2OutputOracleABI, - address: l2OutputOracleAddress[1], - functionName: 'deleteL2Outputs', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l2OutputOracleABI}__ and `functionName` set to `"initialize"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) - */ -export function usePrepareL2OutputOracleInitialize( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2OutputOracleAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l2OutputOracleABI, - address: l2OutputOracleAddress[1], - functionName: 'initialize', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l2OutputOracleABI}__ and `functionName` set to `"proposeL2Output"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) - */ -export function usePrepareL2OutputOracleProposeL2Output( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2OutputOracleAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l2OutputOracleABI, - address: l2OutputOracleAddress[1], - functionName: 'proposeL2Output', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l2OutputOracleABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) - */ -export function useL2OutputOracleEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l2OutputOracleAddress } = {} as any -) { - return useContractEvent({ - abi: l2OutputOracleABI, - address: l2OutputOracleAddress[1], - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l2OutputOracleABI}__ and `eventName` set to `"Initialized"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) - */ -export function useL2OutputOracleInitializedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l2OutputOracleAddress } = {} as any -) { - return useContractEvent({ - abi: l2OutputOracleABI, - address: l2OutputOracleAddress[1], - eventName: 'Initialized', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l2OutputOracleABI}__ and `eventName` set to `"OutputProposed"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) - */ -export function useL2OutputOracleOutputProposedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l2OutputOracleAddress } = {} as any -) { - return useContractEvent({ - abi: l2OutputOracleABI, - address: l2OutputOracleAddress[1], - eventName: 'OutputProposed', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l2OutputOracleABI}__ and `eventName` set to `"OutputsDeleted"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) - */ -export function useL2OutputOracleOutputsDeletedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l2OutputOracleAddress } = {} as any -) { - return useContractEvent({ - abi: l2OutputOracleABI, - address: l2OutputOracleAddress[1], - eventName: 'OutputsDeleted', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2OutputOracleGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) - */ -export function useL2OutputOracleGoerliRead< - TFunctionName extends string, - TSelectData = ReadContractResult< - typeof l2OutputOracleGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l2OutputOracleGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' - > & { chainId?: keyof typeof l2OutputOracleGoerliAddress } = {} as any -) { - return useContractRead({ - abi: l2OutputOracleGoerliABI, - address: l2OutputOracleGoerliAddress[5], - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2OutputOracleGoerliABI}__ and `functionName` set to `"challenger"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) - */ -export function useL2OutputOracleGoerliChallenger< - TFunctionName extends 'challenger', - TSelectData = ReadContractResult< - typeof l2OutputOracleGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l2OutputOracleGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2OutputOracleGoerliAddress } = {} as any -) { - return useContractRead({ - abi: l2OutputOracleGoerliABI, - address: l2OutputOracleGoerliAddress[5], - functionName: 'challenger', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2OutputOracleGoerliABI}__ and `functionName` set to `"computeL2Timestamp"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) - */ -export function useL2OutputOracleGoerliComputeL2Timestamp< - TFunctionName extends 'computeL2Timestamp', - TSelectData = ReadContractResult< - typeof l2OutputOracleGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l2OutputOracleGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2OutputOracleGoerliAddress } = {} as any -) { - return useContractRead({ - abi: l2OutputOracleGoerliABI, - address: l2OutputOracleGoerliAddress[5], - functionName: 'computeL2Timestamp', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2OutputOracleGoerliABI}__ and `functionName` set to `"finalizationPeriodSeconds"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) - */ -export function useL2OutputOracleGoerliFinalizationPeriodSeconds< - TFunctionName extends 'finalizationPeriodSeconds', - TSelectData = ReadContractResult< - typeof l2OutputOracleGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l2OutputOracleGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2OutputOracleGoerliAddress } = {} as any -) { - return useContractRead({ - abi: l2OutputOracleGoerliABI, - address: l2OutputOracleGoerliAddress[5], - functionName: 'finalizationPeriodSeconds', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2OutputOracleGoerliABI}__ and `functionName` set to `"getL2Output"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) - */ -export function useL2OutputOracleGoerliGetL2Output< - TFunctionName extends 'getL2Output', - TSelectData = ReadContractResult< - typeof l2OutputOracleGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l2OutputOracleGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2OutputOracleGoerliAddress } = {} as any -) { - return useContractRead({ - abi: l2OutputOracleGoerliABI, - address: l2OutputOracleGoerliAddress[5], - functionName: 'getL2Output', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2OutputOracleGoerliABI}__ and `functionName` set to `"getL2OutputAfter"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) - */ -export function useL2OutputOracleGoerliGetL2OutputAfter< - TFunctionName extends 'getL2OutputAfter', - TSelectData = ReadContractResult< - typeof l2OutputOracleGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l2OutputOracleGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2OutputOracleGoerliAddress } = {} as any -) { - return useContractRead({ - abi: l2OutputOracleGoerliABI, - address: l2OutputOracleGoerliAddress[5], - functionName: 'getL2OutputAfter', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2OutputOracleGoerliABI}__ and `functionName` set to `"getL2OutputIndexAfter"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) - */ -export function useL2OutputOracleGoerliGetL2OutputIndexAfter< - TFunctionName extends 'getL2OutputIndexAfter', - TSelectData = ReadContractResult< - typeof l2OutputOracleGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l2OutputOracleGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2OutputOracleGoerliAddress } = {} as any -) { - return useContractRead({ - abi: l2OutputOracleGoerliABI, - address: l2OutputOracleGoerliAddress[5], - functionName: 'getL2OutputIndexAfter', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2OutputOracleGoerliABI}__ and `functionName` set to `"l2BlockTime"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) - */ -export function useL2OutputOracleGoerliL2BlockTime< - TFunctionName extends 'l2BlockTime', - TSelectData = ReadContractResult< - typeof l2OutputOracleGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l2OutputOracleGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2OutputOracleGoerliAddress } = {} as any -) { - return useContractRead({ - abi: l2OutputOracleGoerliABI, - address: l2OutputOracleGoerliAddress[5], - functionName: 'l2BlockTime', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2OutputOracleGoerliABI}__ and `functionName` set to `"latestBlockNumber"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) - */ -export function useL2OutputOracleGoerliLatestBlockNumber< - TFunctionName extends 'latestBlockNumber', - TSelectData = ReadContractResult< - typeof l2OutputOracleGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l2OutputOracleGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2OutputOracleGoerliAddress } = {} as any -) { - return useContractRead({ - abi: l2OutputOracleGoerliABI, - address: l2OutputOracleGoerliAddress[5], - functionName: 'latestBlockNumber', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2OutputOracleGoerliABI}__ and `functionName` set to `"latestOutputIndex"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) - */ -export function useL2OutputOracleGoerliLatestOutputIndex< - TFunctionName extends 'latestOutputIndex', - TSelectData = ReadContractResult< - typeof l2OutputOracleGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l2OutputOracleGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2OutputOracleGoerliAddress } = {} as any -) { - return useContractRead({ - abi: l2OutputOracleGoerliABI, - address: l2OutputOracleGoerliAddress[5], - functionName: 'latestOutputIndex', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2OutputOracleGoerliABI}__ and `functionName` set to `"nextBlockNumber"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) - */ -export function useL2OutputOracleGoerliNextBlockNumber< - TFunctionName extends 'nextBlockNumber', - TSelectData = ReadContractResult< - typeof l2OutputOracleGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l2OutputOracleGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2OutputOracleGoerliAddress } = {} as any -) { - return useContractRead({ - abi: l2OutputOracleGoerliABI, - address: l2OutputOracleGoerliAddress[5], - functionName: 'nextBlockNumber', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2OutputOracleGoerliABI}__ and `functionName` set to `"nextOutputIndex"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) - */ -export function useL2OutputOracleGoerliNextOutputIndex< - TFunctionName extends 'nextOutputIndex', - TSelectData = ReadContractResult< - typeof l2OutputOracleGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l2OutputOracleGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2OutputOracleGoerliAddress } = {} as any -) { - return useContractRead({ - abi: l2OutputOracleGoerliABI, - address: l2OutputOracleGoerliAddress[5], - functionName: 'nextOutputIndex', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2OutputOracleGoerliABI}__ and `functionName` set to `"proposer"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) - */ -export function useL2OutputOracleGoerliProposer< - TFunctionName extends 'proposer', - TSelectData = ReadContractResult< - typeof l2OutputOracleGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l2OutputOracleGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2OutputOracleGoerliAddress } = {} as any -) { - return useContractRead({ - abi: l2OutputOracleGoerliABI, - address: l2OutputOracleGoerliAddress[5], - functionName: 'proposer', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2OutputOracleGoerliABI}__ and `functionName` set to `"startingBlockNumber"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) - */ -export function useL2OutputOracleGoerliStartingBlockNumber< - TFunctionName extends 'startingBlockNumber', - TSelectData = ReadContractResult< - typeof l2OutputOracleGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l2OutputOracleGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2OutputOracleGoerliAddress } = {} as any -) { - return useContractRead({ - abi: l2OutputOracleGoerliABI, - address: l2OutputOracleGoerliAddress[5], - functionName: 'startingBlockNumber', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2OutputOracleGoerliABI}__ and `functionName` set to `"startingTimestamp"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) - */ -export function useL2OutputOracleGoerliStartingTimestamp< - TFunctionName extends 'startingTimestamp', - TSelectData = ReadContractResult< - typeof l2OutputOracleGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l2OutputOracleGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2OutputOracleGoerliAddress } = {} as any -) { - return useContractRead({ - abi: l2OutputOracleGoerliABI, - address: l2OutputOracleGoerliAddress[5], - functionName: 'startingTimestamp', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2OutputOracleGoerliABI}__ and `functionName` set to `"submissionInterval"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) - */ -export function useL2OutputOracleGoerliSubmissionInterval< - TFunctionName extends 'submissionInterval', - TSelectData = ReadContractResult< - typeof l2OutputOracleGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l2OutputOracleGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2OutputOracleGoerliAddress } = {} as any -) { - return useContractRead({ - abi: l2OutputOracleGoerliABI, - address: l2OutputOracleGoerliAddress[5], - functionName: 'submissionInterval', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2OutputOracleGoerliABI}__ and `functionName` set to `"version"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) - */ -export function useL2OutputOracleGoerliVersion< - TFunctionName extends 'version', - TSelectData = ReadContractResult< - typeof l2OutputOracleGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof l2OutputOracleGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2OutputOracleGoerliAddress } = {} as any -) { - return useContractRead({ - abi: l2OutputOracleGoerliABI, - address: l2OutputOracleGoerliAddress[5], - functionName: 'version', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l2OutputOracleGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) - */ -export function useL2OutputOracleGoerliWrite< - TFunctionName extends string, - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l2OutputOracleGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l2OutputOracleGoerliABI, - string - >['request']['abi'], - TFunctionName, - TMode - > & { address?: Address; chainId?: TChainId } - : UseContractWriteConfig< - typeof l2OutputOracleGoerliABI, - TFunctionName, - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - } = {} as any -) { - return useContractWrite( - { - abi: l2OutputOracleGoerliABI, - address: l2OutputOracleGoerliAddress[5], - ...config, - } as any - ) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l2OutputOracleGoerliABI}__ and `functionName` set to `"deleteL2Outputs"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) - */ -export function useL2OutputOracleGoerliDeleteL2Outputs< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l2OutputOracleGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l2OutputOracleGoerliABI, - 'deleteL2Outputs' - >['request']['abi'], - 'deleteL2Outputs', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'deleteL2Outputs' - } - : UseContractWriteConfig< - typeof l2OutputOracleGoerliABI, - 'deleteL2Outputs', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'deleteL2Outputs' - } = {} as any -) { - return useContractWrite< - typeof l2OutputOracleGoerliABI, - 'deleteL2Outputs', - TMode - >({ - abi: l2OutputOracleGoerliABI, - address: l2OutputOracleGoerliAddress[5], - functionName: 'deleteL2Outputs', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l2OutputOracleGoerliABI}__ and `functionName` set to `"initialize"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) - */ -export function useL2OutputOracleGoerliInitialize< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l2OutputOracleGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l2OutputOracleGoerliABI, - 'initialize' - >['request']['abi'], - 'initialize', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'initialize' } - : UseContractWriteConfig< - typeof l2OutputOracleGoerliABI, - 'initialize', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'initialize' - } = {} as any -) { - return useContractWrite({ - abi: l2OutputOracleGoerliABI, - address: l2OutputOracleGoerliAddress[5], - functionName: 'initialize', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l2OutputOracleGoerliABI}__ and `functionName` set to `"proposeL2Output"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) - */ -export function useL2OutputOracleGoerliProposeL2Output< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l2OutputOracleGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l2OutputOracleGoerliABI, - 'proposeL2Output' - >['request']['abi'], - 'proposeL2Output', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'proposeL2Output' - } - : UseContractWriteConfig< - typeof l2OutputOracleGoerliABI, - 'proposeL2Output', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'proposeL2Output' - } = {} as any -) { - return useContractWrite< - typeof l2OutputOracleGoerliABI, - 'proposeL2Output', - TMode - >({ - abi: l2OutputOracleGoerliABI, - address: l2OutputOracleGoerliAddress[5], - functionName: 'proposeL2Output', - ...config, - } as any) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l2OutputOracleGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) - */ -export function usePrepareL2OutputOracleGoerliWrite< - TFunctionName extends string ->( - config: Omit< - UsePrepareContractWriteConfig< - typeof l2OutputOracleGoerliABI, - TFunctionName - >, - 'abi' | 'address' - > & { chainId?: keyof typeof l2OutputOracleGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l2OutputOracleGoerliABI, - address: l2OutputOracleGoerliAddress[5], - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l2OutputOracleGoerliABI}__ and `functionName` set to `"deleteL2Outputs"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) - */ -export function usePrepareL2OutputOracleGoerliDeleteL2Outputs( - config: Omit< - UsePrepareContractWriteConfig< - typeof l2OutputOracleGoerliABI, - 'deleteL2Outputs' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2OutputOracleGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l2OutputOracleGoerliABI, - address: l2OutputOracleGoerliAddress[5], - functionName: 'deleteL2Outputs', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l2OutputOracleGoerliABI}__ and `functionName` set to `"initialize"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) - */ -export function usePrepareL2OutputOracleGoerliInitialize( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2OutputOracleGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l2OutputOracleGoerliABI, - address: l2OutputOracleGoerliAddress[5], - functionName: 'initialize', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l2OutputOracleGoerliABI}__ and `functionName` set to `"proposeL2Output"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) - */ -export function usePrepareL2OutputOracleGoerliProposeL2Output( - config: Omit< - UsePrepareContractWriteConfig< - typeof l2OutputOracleGoerliABI, - 'proposeL2Output' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2OutputOracleGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l2OutputOracleGoerliABI, - address: l2OutputOracleGoerliAddress[5], - functionName: 'proposeL2Output', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l2OutputOracleGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) - */ -export function useL2OutputOracleGoerliEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l2OutputOracleGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: l2OutputOracleGoerliABI, - address: l2OutputOracleGoerliAddress[5], - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l2OutputOracleGoerliABI}__ and `eventName` set to `"Initialized"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) - */ -export function useL2OutputOracleGoerliInitializedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l2OutputOracleGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: l2OutputOracleGoerliABI, - address: l2OutputOracleGoerliAddress[5], - eventName: 'Initialized', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l2OutputOracleGoerliABI}__ and `eventName` set to `"OutputProposed"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) - */ -export function useL2OutputOracleGoerliOutputProposedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l2OutputOracleGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: l2OutputOracleGoerliABI, - address: l2OutputOracleGoerliAddress[5], - eventName: 'OutputProposed', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l2OutputOracleGoerliABI}__ and `eventName` set to `"OutputsDeleted"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) - */ -export function useL2OutputOracleGoerliOutputsDeletedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l2OutputOracleGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: l2OutputOracleGoerliABI, - address: l2OutputOracleGoerliAddress[5], - eventName: 'OutputsDeleted', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2StandardBridgeABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) - */ -export function useL2StandardBridgeRead< - TFunctionName extends string, - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof l2StandardBridgeABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' - > & { chainId?: keyof typeof l2StandardBridgeAddress } = {} as any -) { - return useContractRead({ - abi: l2StandardBridgeABI, - address: l2StandardBridgeAddress[420], - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2StandardBridgeABI}__ and `functionName` set to `"OTHER_BRIDGE"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) - */ -export function useL2StandardBridgeOtherBridge< - TFunctionName extends 'OTHER_BRIDGE', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof l2StandardBridgeABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2StandardBridgeAddress } = {} as any -) { - return useContractRead({ - abi: l2StandardBridgeABI, - address: l2StandardBridgeAddress[420], - functionName: 'OTHER_BRIDGE', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2StandardBridgeABI}__ and `functionName` set to `"deposits"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) - */ -export function useL2StandardBridgeDeposits< - TFunctionName extends 'deposits', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof l2StandardBridgeABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2StandardBridgeAddress } = {} as any -) { - return useContractRead({ - abi: l2StandardBridgeABI, - address: l2StandardBridgeAddress[420], - functionName: 'deposits', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2StandardBridgeABI}__ and `functionName` set to `"l1TokenBridge"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) - */ -export function useL2StandardBridgeL1TokenBridge< - TFunctionName extends 'l1TokenBridge', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof l2StandardBridgeABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2StandardBridgeAddress } = {} as any -) { - return useContractRead({ - abi: l2StandardBridgeABI, - address: l2StandardBridgeAddress[420], - functionName: 'l1TokenBridge', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2StandardBridgeABI}__ and `functionName` set to `"messenger"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) - */ -export function useL2StandardBridgeMessenger< - TFunctionName extends 'messenger', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof l2StandardBridgeABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2StandardBridgeAddress } = {} as any -) { - return useContractRead({ - abi: l2StandardBridgeABI, - address: l2StandardBridgeAddress[420], - functionName: 'messenger', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2StandardBridgeABI}__ and `functionName` set to `"version"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) - */ -export function useL2StandardBridgeVersion< - TFunctionName extends 'version', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof l2StandardBridgeABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2StandardBridgeAddress } = {} as any -) { - return useContractRead({ - abi: l2StandardBridgeABI, - address: l2StandardBridgeAddress[420], - functionName: 'version', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l2StandardBridgeABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) - */ -export function useL2StandardBridgeWrite< - TFunctionName extends string, - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l2StandardBridgeAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l2StandardBridgeABI, - string - >['request']['abi'], - TFunctionName, - TMode - > & { address?: Address; chainId?: TChainId } - : UseContractWriteConfig< - typeof l2StandardBridgeABI, - TFunctionName, - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - } = {} as any -) { - return useContractWrite({ - abi: l2StandardBridgeABI, - address: l2StandardBridgeAddress[420], - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l2StandardBridgeABI}__ and `functionName` set to `"bridgeERC20"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) - */ -export function useL2StandardBridgeBridgeErc20< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l2StandardBridgeAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l2StandardBridgeABI, - 'bridgeERC20' - >['request']['abi'], - 'bridgeERC20', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'bridgeERC20' - } - : UseContractWriteConfig< - typeof l2StandardBridgeABI, - 'bridgeERC20', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'bridgeERC20' - } = {} as any -) { - return useContractWrite({ - abi: l2StandardBridgeABI, - address: l2StandardBridgeAddress[420], - functionName: 'bridgeERC20', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l2StandardBridgeABI}__ and `functionName` set to `"bridgeERC20To"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) - */ -export function useL2StandardBridgeBridgeErc20To< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l2StandardBridgeAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l2StandardBridgeABI, - 'bridgeERC20To' - >['request']['abi'], - 'bridgeERC20To', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'bridgeERC20To' - } - : UseContractWriteConfig< - typeof l2StandardBridgeABI, - 'bridgeERC20To', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'bridgeERC20To' - } = {} as any -) { - return useContractWrite({ - abi: l2StandardBridgeABI, - address: l2StandardBridgeAddress[420], - functionName: 'bridgeERC20To', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l2StandardBridgeABI}__ and `functionName` set to `"bridgeETH"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) - */ -export function useL2StandardBridgeBridgeEth< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l2StandardBridgeAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l2StandardBridgeABI, - 'bridgeETH' - >['request']['abi'], - 'bridgeETH', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'bridgeETH' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'bridgeETH' - } = {} as any -) { - return useContractWrite({ - abi: l2StandardBridgeABI, - address: l2StandardBridgeAddress[420], - functionName: 'bridgeETH', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l2StandardBridgeABI}__ and `functionName` set to `"bridgeETHTo"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) - */ -export function useL2StandardBridgeBridgeEthTo< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l2StandardBridgeAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l2StandardBridgeABI, - 'bridgeETHTo' - >['request']['abi'], - 'bridgeETHTo', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'bridgeETHTo' - } - : UseContractWriteConfig< - typeof l2StandardBridgeABI, - 'bridgeETHTo', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'bridgeETHTo' - } = {} as any -) { - return useContractWrite({ - abi: l2StandardBridgeABI, - address: l2StandardBridgeAddress[420], - functionName: 'bridgeETHTo', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l2StandardBridgeABI}__ and `functionName` set to `"finalizeBridgeERC20"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) - */ -export function useL2StandardBridgeFinalizeBridgeErc20< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l2StandardBridgeAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l2StandardBridgeABI, - 'finalizeBridgeERC20' - >['request']['abi'], - 'finalizeBridgeERC20', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'finalizeBridgeERC20' - } - : UseContractWriteConfig< - typeof l2StandardBridgeABI, - 'finalizeBridgeERC20', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'finalizeBridgeERC20' - } = {} as any -) { - return useContractWrite< - typeof l2StandardBridgeABI, - 'finalizeBridgeERC20', - TMode - >({ - abi: l2StandardBridgeABI, - address: l2StandardBridgeAddress[420], - functionName: 'finalizeBridgeERC20', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l2StandardBridgeABI}__ and `functionName` set to `"finalizeBridgeETH"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) - */ -export function useL2StandardBridgeFinalizeBridgeEth< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l2StandardBridgeAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l2StandardBridgeABI, - 'finalizeBridgeETH' - >['request']['abi'], - 'finalizeBridgeETH', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'finalizeBridgeETH' - } - : UseContractWriteConfig< - typeof l2StandardBridgeABI, - 'finalizeBridgeETH', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'finalizeBridgeETH' - } = {} as any -) { - return useContractWrite< - typeof l2StandardBridgeABI, - 'finalizeBridgeETH', - TMode - >({ - abi: l2StandardBridgeABI, - address: l2StandardBridgeAddress[420], - functionName: 'finalizeBridgeETH', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l2StandardBridgeABI}__ and `functionName` set to `"finalizeDeposit"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) - */ -export function useL2StandardBridgeFinalizeDeposit< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l2StandardBridgeAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l2StandardBridgeABI, - 'finalizeDeposit' - >['request']['abi'], - 'finalizeDeposit', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'finalizeDeposit' - } - : UseContractWriteConfig< - typeof l2StandardBridgeABI, - 'finalizeDeposit', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'finalizeDeposit' - } = {} as any -) { - return useContractWrite( - { - abi: l2StandardBridgeABI, - address: l2StandardBridgeAddress[420], - functionName: 'finalizeDeposit', - ...config, - } as any - ) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l2StandardBridgeABI}__ and `functionName` set to `"withdraw"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) - */ -export function useL2StandardBridgeWithdraw< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l2StandardBridgeAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l2StandardBridgeABI, - 'withdraw' - >['request']['abi'], - 'withdraw', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'withdraw' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'withdraw' - } = {} as any -) { - return useContractWrite({ - abi: l2StandardBridgeABI, - address: l2StandardBridgeAddress[420], - functionName: 'withdraw', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l2StandardBridgeABI}__ and `functionName` set to `"withdrawTo"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) - */ -export function useL2StandardBridgeWithdrawTo< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l2StandardBridgeAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l2StandardBridgeABI, - 'withdrawTo' - >['request']['abi'], - 'withdrawTo', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'withdrawTo' } - : UseContractWriteConfig< - typeof l2StandardBridgeABI, - 'withdrawTo', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'withdrawTo' - } = {} as any -) { - return useContractWrite({ - abi: l2StandardBridgeABI, - address: l2StandardBridgeAddress[420], - functionName: 'withdrawTo', - ...config, - } as any) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l2StandardBridgeABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) - */ -export function usePrepareL2StandardBridgeWrite( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l2StandardBridgeAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l2StandardBridgeABI, - address: l2StandardBridgeAddress[420], - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l2StandardBridgeABI}__ and `functionName` set to `"bridgeERC20"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) - */ -export function usePrepareL2StandardBridgeBridgeErc20( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2StandardBridgeAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l2StandardBridgeABI, - address: l2StandardBridgeAddress[420], - functionName: 'bridgeERC20', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l2StandardBridgeABI}__ and `functionName` set to `"bridgeERC20To"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) - */ -export function usePrepareL2StandardBridgeBridgeErc20To( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2StandardBridgeAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l2StandardBridgeABI, - address: l2StandardBridgeAddress[420], - functionName: 'bridgeERC20To', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l2StandardBridgeABI}__ and `functionName` set to `"bridgeETH"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) - */ -export function usePrepareL2StandardBridgeBridgeEth( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2StandardBridgeAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l2StandardBridgeABI, - address: l2StandardBridgeAddress[420], - functionName: 'bridgeETH', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l2StandardBridgeABI}__ and `functionName` set to `"bridgeETHTo"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) - */ -export function usePrepareL2StandardBridgeBridgeEthTo( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2StandardBridgeAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l2StandardBridgeABI, - address: l2StandardBridgeAddress[420], - functionName: 'bridgeETHTo', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l2StandardBridgeABI}__ and `functionName` set to `"finalizeBridgeERC20"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) - */ -export function usePrepareL2StandardBridgeFinalizeBridgeErc20( - config: Omit< - UsePrepareContractWriteConfig< - typeof l2StandardBridgeABI, - 'finalizeBridgeERC20' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2StandardBridgeAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l2StandardBridgeABI, - address: l2StandardBridgeAddress[420], - functionName: 'finalizeBridgeERC20', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l2StandardBridgeABI}__ and `functionName` set to `"finalizeBridgeETH"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) - */ -export function usePrepareL2StandardBridgeFinalizeBridgeEth( - config: Omit< - UsePrepareContractWriteConfig< - typeof l2StandardBridgeABI, - 'finalizeBridgeETH' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2StandardBridgeAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l2StandardBridgeABI, - address: l2StandardBridgeAddress[420], - functionName: 'finalizeBridgeETH', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l2StandardBridgeABI}__ and `functionName` set to `"finalizeDeposit"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) - */ -export function usePrepareL2StandardBridgeFinalizeDeposit( - config: Omit< - UsePrepareContractWriteConfig< - typeof l2StandardBridgeABI, - 'finalizeDeposit' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2StandardBridgeAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l2StandardBridgeABI, - address: l2StandardBridgeAddress[420], - functionName: 'finalizeDeposit', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l2StandardBridgeABI}__ and `functionName` set to `"withdraw"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) - */ -export function usePrepareL2StandardBridgeWithdraw( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2StandardBridgeAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l2StandardBridgeABI, - address: l2StandardBridgeAddress[420], - functionName: 'withdraw', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l2StandardBridgeABI}__ and `functionName` set to `"withdrawTo"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) - */ -export function usePrepareL2StandardBridgeWithdrawTo( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2StandardBridgeAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l2StandardBridgeABI, - address: l2StandardBridgeAddress[420], - functionName: 'withdrawTo', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l2StandardBridgeABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) - */ -export function useL2StandardBridgeEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l2StandardBridgeAddress } = {} as any -) { - return useContractEvent({ - abi: l2StandardBridgeABI, - address: l2StandardBridgeAddress[420], - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l2StandardBridgeABI}__ and `eventName` set to `"DepositFinalized"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) - */ -export function useL2StandardBridgeDepositFinalizedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l2StandardBridgeAddress } = {} as any -) { - return useContractEvent({ - abi: l2StandardBridgeABI, - address: l2StandardBridgeAddress[420], - eventName: 'DepositFinalized', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l2StandardBridgeABI}__ and `eventName` set to `"ERC20BridgeFinalized"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) - */ -export function useL2StandardBridgeErc20BridgeFinalizedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l2StandardBridgeAddress } = {} as any -) { - return useContractEvent({ - abi: l2StandardBridgeABI, - address: l2StandardBridgeAddress[420], - eventName: 'ERC20BridgeFinalized', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l2StandardBridgeABI}__ and `eventName` set to `"ERC20BridgeInitiated"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) - */ -export function useL2StandardBridgeErc20BridgeInitiatedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l2StandardBridgeAddress } = {} as any -) { - return useContractEvent({ - abi: l2StandardBridgeABI, - address: l2StandardBridgeAddress[420], - eventName: 'ERC20BridgeInitiated', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l2StandardBridgeABI}__ and `eventName` set to `"ETHBridgeFinalized"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) - */ -export function useL2StandardBridgeEthBridgeFinalizedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l2StandardBridgeAddress } = {} as any -) { - return useContractEvent({ - abi: l2StandardBridgeABI, - address: l2StandardBridgeAddress[420], - eventName: 'ETHBridgeFinalized', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l2StandardBridgeABI}__ and `eventName` set to `"ETHBridgeInitiated"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) - */ -export function useL2StandardBridgeEthBridgeInitiatedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l2StandardBridgeAddress } = {} as any -) { - return useContractEvent({ - abi: l2StandardBridgeABI, - address: l2StandardBridgeAddress[420], - eventName: 'ETHBridgeInitiated', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l2StandardBridgeABI}__ and `eventName` set to `"WithdrawalInitiated"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) - */ -export function useL2StandardBridgeWithdrawalInitiatedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l2StandardBridgeAddress } = {} as any -) { - return useContractEvent({ - abi: l2StandardBridgeABI, - address: l2StandardBridgeAddress[420], - eventName: 'WithdrawalInitiated', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2ToL1MessagePasserABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000016) - */ -export function useL2ToL1MessagePasserRead< - TFunctionName extends string, - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof l2ToL1MessagePasserABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' - > & { chainId?: keyof typeof l2ToL1MessagePasserAddress } = {} as any -) { - return useContractRead({ - abi: l2ToL1MessagePasserABI, - address: l2ToL1MessagePasserAddress[420], - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2ToL1MessagePasserABI}__ and `functionName` set to `"MESSAGE_VERSION"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000016) - */ -export function useL2ToL1MessagePasserMessageVersion< - TFunctionName extends 'MESSAGE_VERSION', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof l2ToL1MessagePasserABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2ToL1MessagePasserAddress } = {} as any -) { - return useContractRead({ - abi: l2ToL1MessagePasserABI, - address: l2ToL1MessagePasserAddress[420], - functionName: 'MESSAGE_VERSION', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2ToL1MessagePasserABI}__ and `functionName` set to `"messageNonce"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000016) - */ -export function useL2ToL1MessagePasserMessageNonce< - TFunctionName extends 'messageNonce', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof l2ToL1MessagePasserABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2ToL1MessagePasserAddress } = {} as any -) { - return useContractRead({ - abi: l2ToL1MessagePasserABI, - address: l2ToL1MessagePasserAddress[420], - functionName: 'messageNonce', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2ToL1MessagePasserABI}__ and `functionName` set to `"sentMessages"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000016) - */ -export function useL2ToL1MessagePasserSentMessages< - TFunctionName extends 'sentMessages', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof l2ToL1MessagePasserABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2ToL1MessagePasserAddress } = {} as any -) { - return useContractRead({ - abi: l2ToL1MessagePasserABI, - address: l2ToL1MessagePasserAddress[420], - functionName: 'sentMessages', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2ToL1MessagePasserABI}__ and `functionName` set to `"version"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000016) - */ -export function useL2ToL1MessagePasserVersion< - TFunctionName extends 'version', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof l2ToL1MessagePasserABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2ToL1MessagePasserAddress } = {} as any -) { - return useContractRead({ - abi: l2ToL1MessagePasserABI, - address: l2ToL1MessagePasserAddress[420], - functionName: 'version', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l2ToL1MessagePasserABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000016) - */ -export function useL2ToL1MessagePasserWrite< - TFunctionName extends string, - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l2ToL1MessagePasserAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l2ToL1MessagePasserABI, - string - >['request']['abi'], - TFunctionName, - TMode - > & { address?: Address; chainId?: TChainId } - : UseContractWriteConfig< - typeof l2ToL1MessagePasserABI, - TFunctionName, - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - } = {} as any -) { - return useContractWrite({ - abi: l2ToL1MessagePasserABI, - address: l2ToL1MessagePasserAddress[420], - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l2ToL1MessagePasserABI}__ and `functionName` set to `"burn"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000016) - */ -export function useL2ToL1MessagePasserBurn< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l2ToL1MessagePasserAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l2ToL1MessagePasserABI, - 'burn' - >['request']['abi'], - 'burn', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'burn' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'burn' - } = {} as any -) { - return useContractWrite({ - abi: l2ToL1MessagePasserABI, - address: l2ToL1MessagePasserAddress[420], - functionName: 'burn', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l2ToL1MessagePasserABI}__ and `functionName` set to `"initiateWithdrawal"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000016) - */ -export function useL2ToL1MessagePasserInitiateWithdrawal< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof l2ToL1MessagePasserAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof l2ToL1MessagePasserABI, - 'initiateWithdrawal' - >['request']['abi'], - 'initiateWithdrawal', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'initiateWithdrawal' - } - : UseContractWriteConfig< - typeof l2ToL1MessagePasserABI, - 'initiateWithdrawal', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'initiateWithdrawal' - } = {} as any -) { - return useContractWrite< - typeof l2ToL1MessagePasserABI, - 'initiateWithdrawal', - TMode - >({ - abi: l2ToL1MessagePasserABI, - address: l2ToL1MessagePasserAddress[420], - functionName: 'initiateWithdrawal', - ...config, - } as any) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l2ToL1MessagePasserABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000016) - */ -export function usePrepareL2ToL1MessagePasserWrite< - TFunctionName extends string ->( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l2ToL1MessagePasserAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l2ToL1MessagePasserABI, - address: l2ToL1MessagePasserAddress[420], - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l2ToL1MessagePasserABI}__ and `functionName` set to `"burn"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000016) - */ -export function usePrepareL2ToL1MessagePasserBurn( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2ToL1MessagePasserAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l2ToL1MessagePasserABI, - address: l2ToL1MessagePasserAddress[420], - functionName: 'burn', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link l2ToL1MessagePasserABI}__ and `functionName` set to `"initiateWithdrawal"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000016) - */ -export function usePrepareL2ToL1MessagePasserInitiateWithdrawal( - config: Omit< - UsePrepareContractWriteConfig< - typeof l2ToL1MessagePasserABI, - 'initiateWithdrawal' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof l2ToL1MessagePasserAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: l2ToL1MessagePasserABI, - address: l2ToL1MessagePasserAddress[420], - functionName: 'initiateWithdrawal', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l2ToL1MessagePasserABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000016) - */ -export function useL2ToL1MessagePasserEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof l2ToL1MessagePasserAddress } = {} as any -) { - return useContractEvent({ - abi: l2ToL1MessagePasserABI, - address: l2ToL1MessagePasserAddress[420], - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l2ToL1MessagePasserABI}__ and `eventName` set to `"MessagePassed"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000016) - */ -export function useL2ToL1MessagePasserMessagePassedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l2ToL1MessagePasserAddress } = {} as any -) { - return useContractEvent({ - abi: l2ToL1MessagePasserABI, - address: l2ToL1MessagePasserAddress[420], - eventName: 'MessagePassed', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l2ToL1MessagePasserABI}__ and `eventName` set to `"WithdrawerBalanceBurnt"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000016) - */ -export function useL2ToL1MessagePasserWithdrawerBalanceBurntEvent( - config: Omit< - UseContractEventConfig< - typeof l2ToL1MessagePasserABI, - 'WithdrawerBalanceBurnt' - >, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof l2ToL1MessagePasserAddress } = {} as any -) { - return useContractEvent({ - abi: l2ToL1MessagePasserABI, - address: l2ToL1MessagePasserAddress[420], - eventName: 'WithdrawerBalanceBurnt', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link mintManagerABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x5C4e7Ba1E219E47948e6e3F55019A647bA501005) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76) - */ -export function useMintManagerRead< - TFunctionName extends string, - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof mintManagerAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: mintManagerABI, - address: mintManagerAddress[chainId as keyof typeof mintManagerAddress], - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link mintManagerABI}__ and `functionName` set to `"DENOMINATOR"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x5C4e7Ba1E219E47948e6e3F55019A647bA501005) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76) - */ -export function useMintManagerDenominator< - TFunctionName extends 'DENOMINATOR', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof mintManagerAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: mintManagerABI, - address: mintManagerAddress[chainId as keyof typeof mintManagerAddress], - functionName: 'DENOMINATOR', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link mintManagerABI}__ and `functionName` set to `"MINT_CAP"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x5C4e7Ba1E219E47948e6e3F55019A647bA501005) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76) - */ -export function useMintManagerMintCap< - TFunctionName extends 'MINT_CAP', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof mintManagerAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: mintManagerABI, - address: mintManagerAddress[chainId as keyof typeof mintManagerAddress], - functionName: 'MINT_CAP', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link mintManagerABI}__ and `functionName` set to `"MINT_PERIOD"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x5C4e7Ba1E219E47948e6e3F55019A647bA501005) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76) - */ -export function useMintManagerMintPeriod< - TFunctionName extends 'MINT_PERIOD', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof mintManagerAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: mintManagerABI, - address: mintManagerAddress[chainId as keyof typeof mintManagerAddress], - functionName: 'MINT_PERIOD', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link mintManagerABI}__ and `functionName` set to `"governanceToken"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x5C4e7Ba1E219E47948e6e3F55019A647bA501005) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76) - */ -export function useMintManagerGovernanceToken< - TFunctionName extends 'governanceToken', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof mintManagerAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: mintManagerABI, - address: mintManagerAddress[chainId as keyof typeof mintManagerAddress], - functionName: 'governanceToken', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link mintManagerABI}__ and `functionName` set to `"mintPermittedAfter"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x5C4e7Ba1E219E47948e6e3F55019A647bA501005) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76) - */ -export function useMintManagerMintPermittedAfter< - TFunctionName extends 'mintPermittedAfter', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof mintManagerAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: mintManagerABI, - address: mintManagerAddress[chainId as keyof typeof mintManagerAddress], - functionName: 'mintPermittedAfter', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link mintManagerABI}__ and `functionName` set to `"owner"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x5C4e7Ba1E219E47948e6e3F55019A647bA501005) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76) - */ -export function useMintManagerOwner< - TFunctionName extends 'owner', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof mintManagerAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: mintManagerABI, - address: mintManagerAddress[chainId as keyof typeof mintManagerAddress], - functionName: 'owner', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link mintManagerABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x5C4e7Ba1E219E47948e6e3F55019A647bA501005) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76) - */ -export function useMintManagerWrite< - TFunctionName extends string, - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof mintManagerAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof mintManagerABI, - string - >['request']['abi'], - TFunctionName, - TMode - > & { address?: Address; chainId?: TChainId } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: mintManagerABI, - address: mintManagerAddress[chainId as keyof typeof mintManagerAddress], - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link mintManagerABI}__ and `functionName` set to `"mint"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x5C4e7Ba1E219E47948e6e3F55019A647bA501005) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76) - */ -export function useMintManagerMint< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof mintManagerAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof mintManagerABI, - 'mint' - >['request']['abi'], - 'mint', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'mint' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'mint' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: mintManagerABI, - address: mintManagerAddress[chainId as keyof typeof mintManagerAddress], - functionName: 'mint', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link mintManagerABI}__ and `functionName` set to `"renounceOwnership"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x5C4e7Ba1E219E47948e6e3F55019A647bA501005) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76) - */ -export function useMintManagerRenounceOwnership< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof mintManagerAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof mintManagerABI, - 'renounceOwnership' - >['request']['abi'], - 'renounceOwnership', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'renounceOwnership' - } - : UseContractWriteConfig< - typeof mintManagerABI, - 'renounceOwnership', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'renounceOwnership' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: mintManagerABI, - address: mintManagerAddress[chainId as keyof typeof mintManagerAddress], - functionName: 'renounceOwnership', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link mintManagerABI}__ and `functionName` set to `"transferOwnership"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x5C4e7Ba1E219E47948e6e3F55019A647bA501005) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76) - */ -export function useMintManagerTransferOwnership< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof mintManagerAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof mintManagerABI, - 'transferOwnership' - >['request']['abi'], - 'transferOwnership', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'transferOwnership' - } - : UseContractWriteConfig< - typeof mintManagerABI, - 'transferOwnership', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'transferOwnership' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: mintManagerABI, - address: mintManagerAddress[chainId as keyof typeof mintManagerAddress], - functionName: 'transferOwnership', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link mintManagerABI}__ and `functionName` set to `"upgrade"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x5C4e7Ba1E219E47948e6e3F55019A647bA501005) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76) - */ -export function useMintManagerUpgrade< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof mintManagerAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof mintManagerABI, - 'upgrade' - >['request']['abi'], - 'upgrade', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'upgrade' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'upgrade' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: mintManagerABI, - address: mintManagerAddress[chainId as keyof typeof mintManagerAddress], - functionName: 'upgrade', - ...config, - } as any) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link mintManagerABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x5C4e7Ba1E219E47948e6e3F55019A647bA501005) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76) - */ -export function usePrepareMintManagerWrite( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof mintManagerAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: mintManagerABI, - address: mintManagerAddress[chainId as keyof typeof mintManagerAddress], - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link mintManagerABI}__ and `functionName` set to `"mint"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x5C4e7Ba1E219E47948e6e3F55019A647bA501005) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76) - */ -export function usePrepareMintManagerMint( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof mintManagerAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: mintManagerABI, - address: mintManagerAddress[chainId as keyof typeof mintManagerAddress], - functionName: 'mint', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link mintManagerABI}__ and `functionName` set to `"renounceOwnership"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x5C4e7Ba1E219E47948e6e3F55019A647bA501005) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76) - */ -export function usePrepareMintManagerRenounceOwnership( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof mintManagerAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: mintManagerABI, - address: mintManagerAddress[chainId as keyof typeof mintManagerAddress], - functionName: 'renounceOwnership', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link mintManagerABI}__ and `functionName` set to `"transferOwnership"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x5C4e7Ba1E219E47948e6e3F55019A647bA501005) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76) - */ -export function usePrepareMintManagerTransferOwnership( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof mintManagerAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: mintManagerABI, - address: mintManagerAddress[chainId as keyof typeof mintManagerAddress], - functionName: 'transferOwnership', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link mintManagerABI}__ and `functionName` set to `"upgrade"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x5C4e7Ba1E219E47948e6e3F55019A647bA501005) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76) - */ -export function usePrepareMintManagerUpgrade( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof mintManagerAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: mintManagerABI, - address: mintManagerAddress[chainId as keyof typeof mintManagerAddress], - functionName: 'upgrade', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link mintManagerABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x5C4e7Ba1E219E47948e6e3F55019A647bA501005) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76) - */ -export function useMintManagerEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof mintManagerAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractEvent({ - abi: mintManagerABI, - address: mintManagerAddress[chainId as keyof typeof mintManagerAddress], - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link mintManagerABI}__ and `eventName` set to `"OwnershipTransferred"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x5C4e7Ba1E219E47948e6e3F55019A647bA501005) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76) - */ -export function useMintManagerOwnershipTransferredEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof mintManagerAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractEvent({ - abi: mintManagerABI, - address: mintManagerAddress[chainId as keyof typeof mintManagerAddress], - eventName: 'OwnershipTransferred', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismMintableErc20FactoryABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function useOptimismMintableErc20FactoryRead< - TFunctionName extends string, - TSelectData = ReadContractResult< - typeof optimismMintableErc20FactoryABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof optimismMintableErc20FactoryABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' - > & { chainId?: keyof typeof optimismMintableErc20FactoryAddress } = {} as any -) { - return useContractRead({ - abi: optimismMintableErc20FactoryABI, - address: optimismMintableErc20FactoryAddress[1], - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismMintableErc20FactoryABI}__ and `functionName` set to `"BRIDGE"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function useOptimismMintableErc20FactoryBridge< - TFunctionName extends 'BRIDGE', - TSelectData = ReadContractResult< - typeof optimismMintableErc20FactoryABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof optimismMintableErc20FactoryABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimismMintableErc20FactoryAddress } = {} as any -) { - return useContractRead({ - abi: optimismMintableErc20FactoryABI, - address: optimismMintableErc20FactoryAddress[1], - functionName: 'BRIDGE', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismMintableErc20FactoryABI}__ and `functionName` set to `"version"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function useOptimismMintableErc20FactoryVersion< - TFunctionName extends 'version', - TSelectData = ReadContractResult< - typeof optimismMintableErc20FactoryABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof optimismMintableErc20FactoryABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimismMintableErc20FactoryAddress } = {} as any -) { - return useContractRead({ - abi: optimismMintableErc20FactoryABI, - address: optimismMintableErc20FactoryAddress[1], - functionName: 'version', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimismMintableErc20FactoryABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function useOptimismMintableErc20FactoryWrite< - TFunctionName extends string, - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof optimismMintableErc20FactoryAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof optimismMintableErc20FactoryABI, - string - >['request']['abi'], - TFunctionName, - TMode - > & { address?: Address; chainId?: TChainId } - : UseContractWriteConfig< - typeof optimismMintableErc20FactoryABI, - TFunctionName, - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - } = {} as any -) { - return useContractWrite< - typeof optimismMintableErc20FactoryABI, - TFunctionName, - TMode - >({ - abi: optimismMintableErc20FactoryABI, - address: optimismMintableErc20FactoryAddress[1], - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimismMintableErc20FactoryABI}__ and `functionName` set to `"createOptimismMintableERC20"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function useOptimismMintableErc20FactoryCreateOptimismMintableErc20< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof optimismMintableErc20FactoryAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof optimismMintableErc20FactoryABI, - 'createOptimismMintableERC20' - >['request']['abi'], - 'createOptimismMintableERC20', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'createOptimismMintableERC20' - } - : UseContractWriteConfig< - typeof optimismMintableErc20FactoryABI, - 'createOptimismMintableERC20', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'createOptimismMintableERC20' - } = {} as any -) { - return useContractWrite< - typeof optimismMintableErc20FactoryABI, - 'createOptimismMintableERC20', - TMode - >({ - abi: optimismMintableErc20FactoryABI, - address: optimismMintableErc20FactoryAddress[1], - functionName: 'createOptimismMintableERC20', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimismMintableErc20FactoryABI}__ and `functionName` set to `"createStandardL2Token"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function useOptimismMintableErc20FactoryCreateStandardL2Token< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof optimismMintableErc20FactoryAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof optimismMintableErc20FactoryABI, - 'createStandardL2Token' - >['request']['abi'], - 'createStandardL2Token', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'createStandardL2Token' - } - : UseContractWriteConfig< - typeof optimismMintableErc20FactoryABI, - 'createStandardL2Token', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'createStandardL2Token' - } = {} as any -) { - return useContractWrite< - typeof optimismMintableErc20FactoryABI, - 'createStandardL2Token', - TMode - >({ - abi: optimismMintableErc20FactoryABI, - address: optimismMintableErc20FactoryAddress[1], - functionName: 'createStandardL2Token', - ...config, - } as any) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link optimismMintableErc20FactoryABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function usePrepareOptimismMintableErc20FactoryWrite< - TFunctionName extends string ->( - config: Omit< - UsePrepareContractWriteConfig< - typeof optimismMintableErc20FactoryABI, - TFunctionName - >, - 'abi' | 'address' - > & { chainId?: keyof typeof optimismMintableErc20FactoryAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: optimismMintableErc20FactoryABI, - address: optimismMintableErc20FactoryAddress[1], - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link optimismMintableErc20FactoryABI}__ and `functionName` set to `"createOptimismMintableERC20"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function usePrepareOptimismMintableErc20FactoryCreateOptimismMintableErc20( - config: Omit< - UsePrepareContractWriteConfig< - typeof optimismMintableErc20FactoryABI, - 'createOptimismMintableERC20' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimismMintableErc20FactoryAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: optimismMintableErc20FactoryABI, - address: optimismMintableErc20FactoryAddress[1], - functionName: 'createOptimismMintableERC20', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link optimismMintableErc20FactoryABI}__ and `functionName` set to `"createStandardL2Token"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function usePrepareOptimismMintableErc20FactoryCreateStandardL2Token( - config: Omit< - UsePrepareContractWriteConfig< - typeof optimismMintableErc20FactoryABI, - 'createStandardL2Token' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimismMintableErc20FactoryAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: optimismMintableErc20FactoryABI, - address: optimismMintableErc20FactoryAddress[1], - functionName: 'createStandardL2Token', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link optimismMintableErc20FactoryABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function useOptimismMintableErc20FactoryEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof optimismMintableErc20FactoryAddress } = {} as any -) { - return useContractEvent({ - abi: optimismMintableErc20FactoryABI, - address: optimismMintableErc20FactoryAddress[1], - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link optimismMintableErc20FactoryABI}__ and `eventName` set to `"OptimismMintableERC20Created"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function useOptimismMintableErc20FactoryOptimismMintableErc20CreatedEvent( - config: Omit< - UseContractEventConfig< - typeof optimismMintableErc20FactoryABI, - 'OptimismMintableERC20Created' - >, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof optimismMintableErc20FactoryAddress } = {} as any -) { - return useContractEvent({ - abi: optimismMintableErc20FactoryABI, - address: optimismMintableErc20FactoryAddress[1], - eventName: 'OptimismMintableERC20Created', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link optimismMintableErc20FactoryABI}__ and `eventName` set to `"StandardL2TokenCreated"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function useOptimismMintableErc20FactoryStandardL2TokenCreatedEvent( - config: Omit< - UseContractEventConfig< - typeof optimismMintableErc20FactoryABI, - 'StandardL2TokenCreated' - >, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof optimismMintableErc20FactoryAddress } = {} as any -) { - return useContractEvent({ - abi: optimismMintableErc20FactoryABI, - address: optimismMintableErc20FactoryAddress[1], - eventName: 'StandardL2TokenCreated', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismMintableErc20FactoryGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function useOptimismMintableErc20FactoryGoerliRead< - TFunctionName extends string, - TSelectData = ReadContractResult< - typeof optimismMintableErc20FactoryGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof optimismMintableErc20FactoryGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' - > & { - chainId?: keyof typeof optimismMintableErc20FactoryGoerliAddress - } = {} as any -) { - return useContractRead({ - abi: optimismMintableErc20FactoryGoerliABI, - address: optimismMintableErc20FactoryGoerliAddress[5], - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismMintableErc20FactoryGoerliABI}__ and `functionName` set to `"bridge"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function useOptimismMintableErc20FactoryGoerliBridge< - TFunctionName extends 'bridge', - TSelectData = ReadContractResult< - typeof optimismMintableErc20FactoryGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof optimismMintableErc20FactoryGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { - chainId?: keyof typeof optimismMintableErc20FactoryGoerliAddress - } = {} as any -) { - return useContractRead({ - abi: optimismMintableErc20FactoryGoerliABI, - address: optimismMintableErc20FactoryGoerliAddress[5], - functionName: 'bridge', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismMintableErc20FactoryGoerliABI}__ and `functionName` set to `"version"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function useOptimismMintableErc20FactoryGoerliVersion< - TFunctionName extends 'version', - TSelectData = ReadContractResult< - typeof optimismMintableErc20FactoryGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof optimismMintableErc20FactoryGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { - chainId?: keyof typeof optimismMintableErc20FactoryGoerliAddress - } = {} as any -) { - return useContractRead({ - abi: optimismMintableErc20FactoryGoerliABI, - address: optimismMintableErc20FactoryGoerliAddress[5], - functionName: 'version', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimismMintableErc20FactoryGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function useOptimismMintableErc20FactoryGoerliWrite< - TFunctionName extends string, - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof optimismMintableErc20FactoryGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof optimismMintableErc20FactoryGoerliABI, - string - >['request']['abi'], - TFunctionName, - TMode - > & { address?: Address; chainId?: TChainId } - : UseContractWriteConfig< - typeof optimismMintableErc20FactoryGoerliABI, - TFunctionName, - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - } = {} as any -) { - return useContractWrite< - typeof optimismMintableErc20FactoryGoerliABI, - TFunctionName, - TMode - >({ - abi: optimismMintableErc20FactoryGoerliABI, - address: optimismMintableErc20FactoryGoerliAddress[5], - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimismMintableErc20FactoryGoerliABI}__ and `functionName` set to `"createOptimismMintableERC20"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function useOptimismMintableErc20FactoryGoerliCreateOptimismMintableErc20< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof optimismMintableErc20FactoryGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof optimismMintableErc20FactoryGoerliABI, - 'createOptimismMintableERC20' - >['request']['abi'], - 'createOptimismMintableERC20', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'createOptimismMintableERC20' - } - : UseContractWriteConfig< - typeof optimismMintableErc20FactoryGoerliABI, - 'createOptimismMintableERC20', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'createOptimismMintableERC20' - } = {} as any -) { - return useContractWrite< - typeof optimismMintableErc20FactoryGoerliABI, - 'createOptimismMintableERC20', - TMode - >({ - abi: optimismMintableErc20FactoryGoerliABI, - address: optimismMintableErc20FactoryGoerliAddress[5], - functionName: 'createOptimismMintableERC20', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimismMintableErc20FactoryGoerliABI}__ and `functionName` set to `"createOptimismMintableERC20WithDecimals"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function useOptimismMintableErc20FactoryGoerliCreateOptimismMintableErc20WithDecimals< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof optimismMintableErc20FactoryGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof optimismMintableErc20FactoryGoerliABI, - 'createOptimismMintableERC20WithDecimals' - >['request']['abi'], - 'createOptimismMintableERC20WithDecimals', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'createOptimismMintableERC20WithDecimals' - } - : UseContractWriteConfig< - typeof optimismMintableErc20FactoryGoerliABI, - 'createOptimismMintableERC20WithDecimals', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'createOptimismMintableERC20WithDecimals' - } = {} as any -) { - return useContractWrite< - typeof optimismMintableErc20FactoryGoerliABI, - 'createOptimismMintableERC20WithDecimals', - TMode - >({ - abi: optimismMintableErc20FactoryGoerliABI, - address: optimismMintableErc20FactoryGoerliAddress[5], - functionName: 'createOptimismMintableERC20WithDecimals', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimismMintableErc20FactoryGoerliABI}__ and `functionName` set to `"createStandardL2Token"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function useOptimismMintableErc20FactoryGoerliCreateStandardL2Token< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof optimismMintableErc20FactoryGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof optimismMintableErc20FactoryGoerliABI, - 'createStandardL2Token' - >['request']['abi'], - 'createStandardL2Token', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'createStandardL2Token' - } - : UseContractWriteConfig< - typeof optimismMintableErc20FactoryGoerliABI, - 'createStandardL2Token', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'createStandardL2Token' - } = {} as any -) { - return useContractWrite< - typeof optimismMintableErc20FactoryGoerliABI, - 'createStandardL2Token', - TMode - >({ - abi: optimismMintableErc20FactoryGoerliABI, - address: optimismMintableErc20FactoryGoerliAddress[5], - functionName: 'createStandardL2Token', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimismMintableErc20FactoryGoerliABI}__ and `functionName` set to `"initialize"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function useOptimismMintableErc20FactoryGoerliInitialize< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof optimismMintableErc20FactoryGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof optimismMintableErc20FactoryGoerliABI, - 'initialize' - >['request']['abi'], - 'initialize', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'initialize' } - : UseContractWriteConfig< - typeof optimismMintableErc20FactoryGoerliABI, - 'initialize', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'initialize' - } = {} as any -) { - return useContractWrite< - typeof optimismMintableErc20FactoryGoerliABI, - 'initialize', - TMode - >({ - abi: optimismMintableErc20FactoryGoerliABI, - address: optimismMintableErc20FactoryGoerliAddress[5], - functionName: 'initialize', - ...config, - } as any) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link optimismMintableErc20FactoryGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function usePrepareOptimismMintableErc20FactoryGoerliWrite< - TFunctionName extends string ->( - config: Omit< - UsePrepareContractWriteConfig< - typeof optimismMintableErc20FactoryGoerliABI, - TFunctionName - >, - 'abi' | 'address' - > & { - chainId?: keyof typeof optimismMintableErc20FactoryGoerliAddress - } = {} as any -) { - return usePrepareContractWrite({ - abi: optimismMintableErc20FactoryGoerliABI, - address: optimismMintableErc20FactoryGoerliAddress[5], - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link optimismMintableErc20FactoryGoerliABI}__ and `functionName` set to `"createOptimismMintableERC20"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function usePrepareOptimismMintableErc20FactoryGoerliCreateOptimismMintableErc20( - config: Omit< - UsePrepareContractWriteConfig< - typeof optimismMintableErc20FactoryGoerliABI, - 'createOptimismMintableERC20' - >, - 'abi' | 'address' | 'functionName' - > & { - chainId?: keyof typeof optimismMintableErc20FactoryGoerliAddress - } = {} as any -) { - return usePrepareContractWrite({ - abi: optimismMintableErc20FactoryGoerliABI, - address: optimismMintableErc20FactoryGoerliAddress[5], - functionName: 'createOptimismMintableERC20', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link optimismMintableErc20FactoryGoerliABI}__ and `functionName` set to `"createOptimismMintableERC20WithDecimals"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function usePrepareOptimismMintableErc20FactoryGoerliCreateOptimismMintableErc20WithDecimals( - config: Omit< - UsePrepareContractWriteConfig< - typeof optimismMintableErc20FactoryGoerliABI, - 'createOptimismMintableERC20WithDecimals' - >, - 'abi' | 'address' | 'functionName' - > & { - chainId?: keyof typeof optimismMintableErc20FactoryGoerliAddress - } = {} as any -) { - return usePrepareContractWrite({ - abi: optimismMintableErc20FactoryGoerliABI, - address: optimismMintableErc20FactoryGoerliAddress[5], - functionName: 'createOptimismMintableERC20WithDecimals', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link optimismMintableErc20FactoryGoerliABI}__ and `functionName` set to `"createStandardL2Token"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function usePrepareOptimismMintableErc20FactoryGoerliCreateStandardL2Token( - config: Omit< - UsePrepareContractWriteConfig< - typeof optimismMintableErc20FactoryGoerliABI, - 'createStandardL2Token' - >, - 'abi' | 'address' | 'functionName' - > & { - chainId?: keyof typeof optimismMintableErc20FactoryGoerliAddress - } = {} as any -) { - return usePrepareContractWrite({ - abi: optimismMintableErc20FactoryGoerliABI, - address: optimismMintableErc20FactoryGoerliAddress[5], - functionName: 'createStandardL2Token', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link optimismMintableErc20FactoryGoerliABI}__ and `functionName` set to `"initialize"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function usePrepareOptimismMintableErc20FactoryGoerliInitialize( - config: Omit< - UsePrepareContractWriteConfig< - typeof optimismMintableErc20FactoryGoerliABI, - 'initialize' - >, - 'abi' | 'address' | 'functionName' - > & { - chainId?: keyof typeof optimismMintableErc20FactoryGoerliAddress - } = {} as any -) { - return usePrepareContractWrite({ - abi: optimismMintableErc20FactoryGoerliABI, - address: optimismMintableErc20FactoryGoerliAddress[5], - functionName: 'initialize', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link optimismMintableErc20FactoryGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function useOptimismMintableErc20FactoryGoerliEvent< - TEventName extends string ->( - config: Omit< - UseContractEventConfig< - typeof optimismMintableErc20FactoryGoerliABI, - TEventName - >, - 'abi' | 'address' - > & { - chainId?: keyof typeof optimismMintableErc20FactoryGoerliAddress - } = {} as any -) { - return useContractEvent({ - abi: optimismMintableErc20FactoryGoerliABI, - address: optimismMintableErc20FactoryGoerliAddress[5], - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link optimismMintableErc20FactoryGoerliABI}__ and `eventName` set to `"Initialized"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function useOptimismMintableErc20FactoryGoerliInitializedEvent( - config: Omit< - UseContractEventConfig< - typeof optimismMintableErc20FactoryGoerliABI, - 'Initialized' - >, - 'abi' | 'address' | 'eventName' - > & { - chainId?: keyof typeof optimismMintableErc20FactoryGoerliAddress - } = {} as any -) { - return useContractEvent({ - abi: optimismMintableErc20FactoryGoerliABI, - address: optimismMintableErc20FactoryGoerliAddress[5], - eventName: 'Initialized', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link optimismMintableErc20FactoryGoerliABI}__ and `eventName` set to `"OptimismMintableERC20Created"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function useOptimismMintableErc20FactoryGoerliOptimismMintableErc20CreatedEvent( - config: Omit< - UseContractEventConfig< - typeof optimismMintableErc20FactoryGoerliABI, - 'OptimismMintableERC20Created' - >, - 'abi' | 'address' | 'eventName' - > & { - chainId?: keyof typeof optimismMintableErc20FactoryGoerliAddress - } = {} as any -) { - return useContractEvent({ - abi: optimismMintableErc20FactoryGoerliABI, - address: optimismMintableErc20FactoryGoerliAddress[5], - eventName: 'OptimismMintableERC20Created', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link optimismMintableErc20FactoryGoerliABI}__ and `eventName` set to `"StandardL2TokenCreated"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function useOptimismMintableErc20FactoryGoerliStandardL2TokenCreatedEvent( - config: Omit< - UseContractEventConfig< - typeof optimismMintableErc20FactoryGoerliABI, - 'StandardL2TokenCreated' - >, - 'abi' | 'address' | 'eventName' - > & { - chainId?: keyof typeof optimismMintableErc20FactoryGoerliAddress - } = {} as any -) { - return useContractEvent({ - abi: optimismMintableErc20FactoryGoerliABI, - address: optimismMintableErc20FactoryGoerliAddress[5], - eventName: 'StandardL2TokenCreated', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismMintableErc20FactoryOptimismGoerliABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function useOptimismMintableErc20FactoryOptimismGoerliRead< - TFunctionName extends string, - TSelectData = ReadContractResult< - typeof optimismMintableErc20FactoryOptimismGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof optimismMintableErc20FactoryOptimismGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' - > & { - chainId?: keyof typeof optimismMintableErc20FactoryOptimismGoerliAddress - } = {} as any -) { - return useContractRead({ - abi: optimismMintableErc20FactoryOptimismGoerliABI, - address: optimismMintableErc20FactoryOptimismGoerliAddress[420], - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismMintableErc20FactoryOptimismGoerliABI}__ and `functionName` set to `"BRIDGE"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function useOptimismMintableErc20FactoryOptimismGoerliBridge< - TFunctionName extends 'BRIDGE', - TSelectData = ReadContractResult< - typeof optimismMintableErc20FactoryOptimismGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof optimismMintableErc20FactoryOptimismGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { - chainId?: keyof typeof optimismMintableErc20FactoryOptimismGoerliAddress - } = {} as any -) { - return useContractRead({ - abi: optimismMintableErc20FactoryOptimismGoerliABI, - address: optimismMintableErc20FactoryOptimismGoerliAddress[420], - functionName: 'BRIDGE', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismMintableErc20FactoryOptimismGoerliABI}__ and `functionName` set to `"version"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function useOptimismMintableErc20FactoryOptimismGoerliVersion< - TFunctionName extends 'version', - TSelectData = ReadContractResult< - typeof optimismMintableErc20FactoryOptimismGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof optimismMintableErc20FactoryOptimismGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { - chainId?: keyof typeof optimismMintableErc20FactoryOptimismGoerliAddress - } = {} as any -) { - return useContractRead({ - abi: optimismMintableErc20FactoryOptimismGoerliABI, - address: optimismMintableErc20FactoryOptimismGoerliAddress[420], - functionName: 'version', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimismMintableErc20FactoryOptimismGoerliABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function useOptimismMintableErc20FactoryOptimismGoerliWrite< - TFunctionName extends string, - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof optimismMintableErc20FactoryOptimismGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof optimismMintableErc20FactoryOptimismGoerliABI, - string - >['request']['abi'], - TFunctionName, - TMode - > & { address?: Address; chainId?: TChainId } - : UseContractWriteConfig< - typeof optimismMintableErc20FactoryOptimismGoerliABI, - TFunctionName, - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - } = {} as any -) { - return useContractWrite< - typeof optimismMintableErc20FactoryOptimismGoerliABI, - TFunctionName, - TMode - >({ - abi: optimismMintableErc20FactoryOptimismGoerliABI, - address: optimismMintableErc20FactoryOptimismGoerliAddress[420], - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimismMintableErc20FactoryOptimismGoerliABI}__ and `functionName` set to `"createOptimismMintableERC20"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function useOptimismMintableErc20FactoryOptimismGoerliCreateOptimismMintableErc20< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof optimismMintableErc20FactoryOptimismGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof optimismMintableErc20FactoryOptimismGoerliABI, - 'createOptimismMintableERC20' - >['request']['abi'], - 'createOptimismMintableERC20', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'createOptimismMintableERC20' - } - : UseContractWriteConfig< - typeof optimismMintableErc20FactoryOptimismGoerliABI, - 'createOptimismMintableERC20', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'createOptimismMintableERC20' - } = {} as any -) { - return useContractWrite< - typeof optimismMintableErc20FactoryOptimismGoerliABI, - 'createOptimismMintableERC20', - TMode - >({ - abi: optimismMintableErc20FactoryOptimismGoerliABI, - address: optimismMintableErc20FactoryOptimismGoerliAddress[420], - functionName: 'createOptimismMintableERC20', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimismMintableErc20FactoryOptimismGoerliABI}__ and `functionName` set to `"createStandardL2Token"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function useOptimismMintableErc20FactoryOptimismGoerliCreateStandardL2Token< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof optimismMintableErc20FactoryOptimismGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof optimismMintableErc20FactoryOptimismGoerliABI, - 'createStandardL2Token' - >['request']['abi'], - 'createStandardL2Token', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'createStandardL2Token' - } - : UseContractWriteConfig< - typeof optimismMintableErc20FactoryOptimismGoerliABI, - 'createStandardL2Token', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'createStandardL2Token' - } = {} as any -) { - return useContractWrite< - typeof optimismMintableErc20FactoryOptimismGoerliABI, - 'createStandardL2Token', - TMode - >({ - abi: optimismMintableErc20FactoryOptimismGoerliABI, - address: optimismMintableErc20FactoryOptimismGoerliAddress[420], - functionName: 'createStandardL2Token', - ...config, - } as any) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link optimismMintableErc20FactoryOptimismGoerliABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function usePrepareOptimismMintableErc20FactoryOptimismGoerliWrite< - TFunctionName extends string ->( - config: Omit< - UsePrepareContractWriteConfig< - typeof optimismMintableErc20FactoryOptimismGoerliABI, - TFunctionName - >, - 'abi' | 'address' - > & { - chainId?: keyof typeof optimismMintableErc20FactoryOptimismGoerliAddress - } = {} as any -) { - return usePrepareContractWrite({ - abi: optimismMintableErc20FactoryOptimismGoerliABI, - address: optimismMintableErc20FactoryOptimismGoerliAddress[420], - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link optimismMintableErc20FactoryOptimismGoerliABI}__ and `functionName` set to `"createOptimismMintableERC20"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function usePrepareOptimismMintableErc20FactoryOptimismGoerliCreateOptimismMintableErc20( - config: Omit< - UsePrepareContractWriteConfig< - typeof optimismMintableErc20FactoryOptimismGoerliABI, - 'createOptimismMintableERC20' - >, - 'abi' | 'address' | 'functionName' - > & { - chainId?: keyof typeof optimismMintableErc20FactoryOptimismGoerliAddress - } = {} as any -) { - return usePrepareContractWrite({ - abi: optimismMintableErc20FactoryOptimismGoerliABI, - address: optimismMintableErc20FactoryOptimismGoerliAddress[420], - functionName: 'createOptimismMintableERC20', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link optimismMintableErc20FactoryOptimismGoerliABI}__ and `functionName` set to `"createStandardL2Token"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function usePrepareOptimismMintableErc20FactoryOptimismGoerliCreateStandardL2Token( - config: Omit< - UsePrepareContractWriteConfig< - typeof optimismMintableErc20FactoryOptimismGoerliABI, - 'createStandardL2Token' - >, - 'abi' | 'address' | 'functionName' - > & { - chainId?: keyof typeof optimismMintableErc20FactoryOptimismGoerliAddress - } = {} as any -) { - return usePrepareContractWrite({ - abi: optimismMintableErc20FactoryOptimismGoerliABI, - address: optimismMintableErc20FactoryOptimismGoerliAddress[420], - functionName: 'createStandardL2Token', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link optimismMintableErc20FactoryOptimismGoerliABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function useOptimismMintableErc20FactoryOptimismGoerliEvent< - TEventName extends string ->( - config: Omit< - UseContractEventConfig< - typeof optimismMintableErc20FactoryOptimismGoerliABI, - TEventName - >, - 'abi' | 'address' - > & { - chainId?: keyof typeof optimismMintableErc20FactoryOptimismGoerliAddress - } = {} as any -) { - return useContractEvent({ - abi: optimismMintableErc20FactoryOptimismGoerliABI, - address: optimismMintableErc20FactoryOptimismGoerliAddress[420], - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link optimismMintableErc20FactoryOptimismGoerliABI}__ and `eventName` set to `"OptimismMintableERC20Created"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function useOptimismMintableErc20FactoryOptimismGoerliOptimismMintableErc20CreatedEvent( - config: Omit< - UseContractEventConfig< - typeof optimismMintableErc20FactoryOptimismGoerliABI, - 'OptimismMintableERC20Created' - >, - 'abi' | 'address' | 'eventName' - > & { - chainId?: keyof typeof optimismMintableErc20FactoryOptimismGoerliAddress - } = {} as any -) { - return useContractEvent({ - abi: optimismMintableErc20FactoryOptimismGoerliABI, - address: optimismMintableErc20FactoryOptimismGoerliAddress[420], - eventName: 'OptimismMintableERC20Created', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link optimismMintableErc20FactoryOptimismGoerliABI}__ and `eventName` set to `"StandardL2TokenCreated"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000012) - */ -export function useOptimismMintableErc20FactoryOptimismGoerliStandardL2TokenCreatedEvent( - config: Omit< - UseContractEventConfig< - typeof optimismMintableErc20FactoryOptimismGoerliABI, - 'StandardL2TokenCreated' - >, - 'abi' | 'address' | 'eventName' - > & { - chainId?: keyof typeof optimismMintableErc20FactoryOptimismGoerliAddress - } = {} as any -) { - return useContractEvent({ - abi: optimismMintableErc20FactoryOptimismGoerliABI, - address: optimismMintableErc20FactoryOptimismGoerliAddress[420], - eventName: 'StandardL2TokenCreated', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismMintableErc721FactoryABI}__. - * - * [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000017) - */ -export function useOptimismMintableErc721FactoryRead< - TFunctionName extends string, - TSelectData = ReadContractResult< - typeof optimismMintableErc721FactoryABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof optimismMintableErc721FactoryABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' - > & { - chainId?: keyof typeof optimismMintableErc721FactoryAddress - } = {} as any -) { - return useContractRead({ - abi: optimismMintableErc721FactoryABI, - address: optimismMintableErc721FactoryAddress[10], - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismMintableErc721FactoryABI}__ and `functionName` set to `"bridge"`. - * - * [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000017) - */ -export function useOptimismMintableErc721FactoryBridge< - TFunctionName extends 'bridge', - TSelectData = ReadContractResult< - typeof optimismMintableErc721FactoryABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof optimismMintableErc721FactoryABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { - chainId?: keyof typeof optimismMintableErc721FactoryAddress - } = {} as any -) { - return useContractRead({ - abi: optimismMintableErc721FactoryABI, - address: optimismMintableErc721FactoryAddress[10], - functionName: 'bridge', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismMintableErc721FactoryABI}__ and `functionName` set to `"isOptimismMintableERC721"`. - * - * [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000017) - */ -export function useOptimismMintableErc721FactoryIsOptimismMintableErc721< - TFunctionName extends 'isOptimismMintableERC721', - TSelectData = ReadContractResult< - typeof optimismMintableErc721FactoryABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof optimismMintableErc721FactoryABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { - chainId?: keyof typeof optimismMintableErc721FactoryAddress - } = {} as any -) { - return useContractRead({ - abi: optimismMintableErc721FactoryABI, - address: optimismMintableErc721FactoryAddress[10], - functionName: 'isOptimismMintableERC721', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismMintableErc721FactoryABI}__ and `functionName` set to `"remoteChainId"`. - * - * [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000017) - */ -export function useOptimismMintableErc721FactoryRemoteChainId< - TFunctionName extends 'remoteChainId', - TSelectData = ReadContractResult< - typeof optimismMintableErc721FactoryABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof optimismMintableErc721FactoryABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { - chainId?: keyof typeof optimismMintableErc721FactoryAddress - } = {} as any -) { - return useContractRead({ - abi: optimismMintableErc721FactoryABI, - address: optimismMintableErc721FactoryAddress[10], - functionName: 'remoteChainId', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismMintableErc721FactoryABI}__ and `functionName` set to `"version"`. - * - * [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000017) - */ -export function useOptimismMintableErc721FactoryVersion< - TFunctionName extends 'version', - TSelectData = ReadContractResult< - typeof optimismMintableErc721FactoryABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof optimismMintableErc721FactoryABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { - chainId?: keyof typeof optimismMintableErc721FactoryAddress - } = {} as any -) { - return useContractRead({ - abi: optimismMintableErc721FactoryABI, - address: optimismMintableErc721FactoryAddress[10], - functionName: 'version', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimismMintableErc721FactoryABI}__. - * - * [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000017) - */ -export function useOptimismMintableErc721FactoryWrite< - TFunctionName extends string, - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof optimismMintableErc721FactoryAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof optimismMintableErc721FactoryABI, - string - >['request']['abi'], - TFunctionName, - TMode - > & { address?: Address; chainId?: TChainId } - : UseContractWriteConfig< - typeof optimismMintableErc721FactoryABI, - TFunctionName, - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - } = {} as any -) { - return useContractWrite< - typeof optimismMintableErc721FactoryABI, - TFunctionName, - TMode - >({ - abi: optimismMintableErc721FactoryABI, - address: optimismMintableErc721FactoryAddress[10], - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimismMintableErc721FactoryABI}__ and `functionName` set to `"createOptimismMintableERC721"`. - * - * [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000017) - */ -export function useOptimismMintableErc721FactoryCreateOptimismMintableErc721< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof optimismMintableErc721FactoryAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof optimismMintableErc721FactoryABI, - 'createOptimismMintableERC721' - >['request']['abi'], - 'createOptimismMintableERC721', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'createOptimismMintableERC721' - } - : UseContractWriteConfig< - typeof optimismMintableErc721FactoryABI, - 'createOptimismMintableERC721', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'createOptimismMintableERC721' - } = {} as any -) { - return useContractWrite< - typeof optimismMintableErc721FactoryABI, - 'createOptimismMintableERC721', - TMode - >({ - abi: optimismMintableErc721FactoryABI, - address: optimismMintableErc721FactoryAddress[10], - functionName: 'createOptimismMintableERC721', - ...config, - } as any) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link optimismMintableErc721FactoryABI}__. - * - * [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000017) - */ -export function usePrepareOptimismMintableErc721FactoryWrite< - TFunctionName extends string ->( - config: Omit< - UsePrepareContractWriteConfig< - typeof optimismMintableErc721FactoryABI, - TFunctionName - >, - 'abi' | 'address' - > & { - chainId?: keyof typeof optimismMintableErc721FactoryAddress - } = {} as any -) { - return usePrepareContractWrite({ - abi: optimismMintableErc721FactoryABI, - address: optimismMintableErc721FactoryAddress[10], - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link optimismMintableErc721FactoryABI}__ and `functionName` set to `"createOptimismMintableERC721"`. - * - * [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000017) - */ -export function usePrepareOptimismMintableErc721FactoryCreateOptimismMintableErc721( - config: Omit< - UsePrepareContractWriteConfig< - typeof optimismMintableErc721FactoryABI, - 'createOptimismMintableERC721' - >, - 'abi' | 'address' | 'functionName' - > & { - chainId?: keyof typeof optimismMintableErc721FactoryAddress - } = {} as any -) { - return usePrepareContractWrite({ - abi: optimismMintableErc721FactoryABI, - address: optimismMintableErc721FactoryAddress[10], - functionName: 'createOptimismMintableERC721', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link optimismMintableErc721FactoryABI}__. - * - * [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000017) - */ -export function useOptimismMintableErc721FactoryEvent< - TEventName extends string ->( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' - > & { - chainId?: keyof typeof optimismMintableErc721FactoryAddress - } = {} as any -) { - return useContractEvent({ - abi: optimismMintableErc721FactoryABI, - address: optimismMintableErc721FactoryAddress[10], - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link optimismMintableErc721FactoryABI}__ and `eventName` set to `"OptimismMintableERC721Created"`. - * - * [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000017) - */ -export function useOptimismMintableErc721FactoryOptimismMintableErc721CreatedEvent( - config: Omit< - UseContractEventConfig< - typeof optimismMintableErc721FactoryABI, - 'OptimismMintableERC721Created' - >, - 'abi' | 'address' | 'eventName' - > & { - chainId?: keyof typeof optimismMintableErc721FactoryAddress - } = {} as any -) { - return useContractEvent({ - abi: optimismMintableErc721FactoryABI, - address: optimismMintableErc721FactoryAddress[10], - eventName: 'OptimismMintableERC721Created', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismMintableErc721FactoryOptimismGoerliABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000017) - */ -export function useOptimismMintableErc721FactoryOptimismGoerliRead< - TFunctionName extends string, - TSelectData = ReadContractResult< - typeof optimismMintableErc721FactoryOptimismGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof optimismMintableErc721FactoryOptimismGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' - > & { - chainId?: keyof typeof optimismMintableErc721FactoryOptimismGoerliAddress - } = {} as any -) { - return useContractRead({ - abi: optimismMintableErc721FactoryOptimismGoerliABI, - address: optimismMintableErc721FactoryOptimismGoerliAddress[420], - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismMintableErc721FactoryOptimismGoerliABI}__ and `functionName` set to `"BRIDGE"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000017) - */ -export function useOptimismMintableErc721FactoryOptimismGoerliBridge< - TFunctionName extends 'BRIDGE', - TSelectData = ReadContractResult< - typeof optimismMintableErc721FactoryOptimismGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof optimismMintableErc721FactoryOptimismGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { - chainId?: keyof typeof optimismMintableErc721FactoryOptimismGoerliAddress - } = {} as any -) { - return useContractRead({ - abi: optimismMintableErc721FactoryOptimismGoerliABI, - address: optimismMintableErc721FactoryOptimismGoerliAddress[420], - functionName: 'BRIDGE', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismMintableErc721FactoryOptimismGoerliABI}__ and `functionName` set to `"REMOTE_CHAIN_ID"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000017) - */ -export function useOptimismMintableErc721FactoryOptimismGoerliRemoteChainId< - TFunctionName extends 'REMOTE_CHAIN_ID', - TSelectData = ReadContractResult< - typeof optimismMintableErc721FactoryOptimismGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof optimismMintableErc721FactoryOptimismGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { - chainId?: keyof typeof optimismMintableErc721FactoryOptimismGoerliAddress - } = {} as any -) { - return useContractRead({ - abi: optimismMintableErc721FactoryOptimismGoerliABI, - address: optimismMintableErc721FactoryOptimismGoerliAddress[420], - functionName: 'REMOTE_CHAIN_ID', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismMintableErc721FactoryOptimismGoerliABI}__ and `functionName` set to `"isOptimismMintableERC721"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000017) - */ -export function useOptimismMintableErc721FactoryOptimismGoerliIsOptimismMintableErc721< - TFunctionName extends 'isOptimismMintableERC721', - TSelectData = ReadContractResult< - typeof optimismMintableErc721FactoryOptimismGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof optimismMintableErc721FactoryOptimismGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { - chainId?: keyof typeof optimismMintableErc721FactoryOptimismGoerliAddress - } = {} as any -) { - return useContractRead({ - abi: optimismMintableErc721FactoryOptimismGoerliABI, - address: optimismMintableErc721FactoryOptimismGoerliAddress[420], - functionName: 'isOptimismMintableERC721', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismMintableErc721FactoryOptimismGoerliABI}__ and `functionName` set to `"version"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000017) - */ -export function useOptimismMintableErc721FactoryOptimismGoerliVersion< - TFunctionName extends 'version', - TSelectData = ReadContractResult< - typeof optimismMintableErc721FactoryOptimismGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof optimismMintableErc721FactoryOptimismGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { - chainId?: keyof typeof optimismMintableErc721FactoryOptimismGoerliAddress - } = {} as any -) { - return useContractRead({ - abi: optimismMintableErc721FactoryOptimismGoerliABI, - address: optimismMintableErc721FactoryOptimismGoerliAddress[420], - functionName: 'version', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimismMintableErc721FactoryOptimismGoerliABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000017) - */ -export function useOptimismMintableErc721FactoryOptimismGoerliWrite< - TFunctionName extends string, - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof optimismMintableErc721FactoryOptimismGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof optimismMintableErc721FactoryOptimismGoerliABI, - string - >['request']['abi'], - TFunctionName, - TMode - > & { address?: Address; chainId?: TChainId } - : UseContractWriteConfig< - typeof optimismMintableErc721FactoryOptimismGoerliABI, - TFunctionName, - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - } = {} as any -) { - return useContractWrite< - typeof optimismMintableErc721FactoryOptimismGoerliABI, - TFunctionName, - TMode - >({ - abi: optimismMintableErc721FactoryOptimismGoerliABI, - address: optimismMintableErc721FactoryOptimismGoerliAddress[420], - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimismMintableErc721FactoryOptimismGoerliABI}__ and `functionName` set to `"createOptimismMintableERC721"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000017) - */ -export function useOptimismMintableErc721FactoryOptimismGoerliCreateOptimismMintableErc721< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof optimismMintableErc721FactoryOptimismGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof optimismMintableErc721FactoryOptimismGoerliABI, - 'createOptimismMintableERC721' - >['request']['abi'], - 'createOptimismMintableERC721', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'createOptimismMintableERC721' - } - : UseContractWriteConfig< - typeof optimismMintableErc721FactoryOptimismGoerliABI, - 'createOptimismMintableERC721', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'createOptimismMintableERC721' - } = {} as any -) { - return useContractWrite< - typeof optimismMintableErc721FactoryOptimismGoerliABI, - 'createOptimismMintableERC721', - TMode - >({ - abi: optimismMintableErc721FactoryOptimismGoerliABI, - address: optimismMintableErc721FactoryOptimismGoerliAddress[420], - functionName: 'createOptimismMintableERC721', - ...config, - } as any) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link optimismMintableErc721FactoryOptimismGoerliABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000017) - */ -export function usePrepareOptimismMintableErc721FactoryOptimismGoerliWrite< - TFunctionName extends string ->( - config: Omit< - UsePrepareContractWriteConfig< - typeof optimismMintableErc721FactoryOptimismGoerliABI, - TFunctionName - >, - 'abi' | 'address' - > & { - chainId?: keyof typeof optimismMintableErc721FactoryOptimismGoerliAddress - } = {} as any -) { - return usePrepareContractWrite({ - abi: optimismMintableErc721FactoryOptimismGoerliABI, - address: optimismMintableErc721FactoryOptimismGoerliAddress[420], - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link optimismMintableErc721FactoryOptimismGoerliABI}__ and `functionName` set to `"createOptimismMintableERC721"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000017) - */ -export function usePrepareOptimismMintableErc721FactoryOptimismGoerliCreateOptimismMintableErc721( - config: Omit< - UsePrepareContractWriteConfig< - typeof optimismMintableErc721FactoryOptimismGoerliABI, - 'createOptimismMintableERC721' - >, - 'abi' | 'address' | 'functionName' - > & { - chainId?: keyof typeof optimismMintableErc721FactoryOptimismGoerliAddress - } = {} as any -) { - return usePrepareContractWrite({ - abi: optimismMintableErc721FactoryOptimismGoerliABI, - address: optimismMintableErc721FactoryOptimismGoerliAddress[420], - functionName: 'createOptimismMintableERC721', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link optimismMintableErc721FactoryOptimismGoerliABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000017) - */ -export function useOptimismMintableErc721FactoryOptimismGoerliEvent< - TEventName extends string ->( - config: Omit< - UseContractEventConfig< - typeof optimismMintableErc721FactoryOptimismGoerliABI, - TEventName - >, - 'abi' | 'address' - > & { - chainId?: keyof typeof optimismMintableErc721FactoryOptimismGoerliAddress - } = {} as any -) { - return useContractEvent({ - abi: optimismMintableErc721FactoryOptimismGoerliABI, - address: optimismMintableErc721FactoryOptimismGoerliAddress[420], - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link optimismMintableErc721FactoryOptimismGoerliABI}__ and `eventName` set to `"OptimismMintableERC721Created"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000017) - */ -export function useOptimismMintableErc721FactoryOptimismGoerliOptimismMintableErc721CreatedEvent( - config: Omit< - UseContractEventConfig< - typeof optimismMintableErc721FactoryOptimismGoerliABI, - 'OptimismMintableERC721Created' - >, - 'abi' | 'address' | 'eventName' - > & { - chainId?: keyof typeof optimismMintableErc721FactoryOptimismGoerliAddress - } = {} as any -) { - return useContractEvent({ - abi: optimismMintableErc721FactoryOptimismGoerliABI, - address: optimismMintableErc721FactoryOptimismGoerliAddress[420], - eventName: 'OptimismMintableERC721Created', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismPortalABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) - */ -export function useOptimismPortalRead< - TFunctionName extends string, - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof optimismPortalAddress } = {} as any -) { - return useContractRead({ - abi: optimismPortalABI, - address: optimismPortalAddress[1], - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismPortalABI}__ and `functionName` set to `"GUARDIAN"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) - */ -export function useOptimismPortalGuardian< - TFunctionName extends 'GUARDIAN', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimismPortalAddress } = {} as any -) { - return useContractRead({ - abi: optimismPortalABI, - address: optimismPortalAddress[1], - functionName: 'GUARDIAN', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismPortalABI}__ and `functionName` set to `"L2_ORACLE"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) - */ -export function useOptimismPortalL2Oracle< - TFunctionName extends 'L2_ORACLE', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimismPortalAddress } = {} as any -) { - return useContractRead({ - abi: optimismPortalABI, - address: optimismPortalAddress[1], - functionName: 'L2_ORACLE', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismPortalABI}__ and `functionName` set to `"SYSTEM_CONFIG"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) - */ -export function useOptimismPortalSystemConfig< - TFunctionName extends 'SYSTEM_CONFIG', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimismPortalAddress } = {} as any -) { - return useContractRead({ - abi: optimismPortalABI, - address: optimismPortalAddress[1], - functionName: 'SYSTEM_CONFIG', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismPortalABI}__ and `functionName` set to `"finalizedWithdrawals"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) - */ -export function useOptimismPortalFinalizedWithdrawals< - TFunctionName extends 'finalizedWithdrawals', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimismPortalAddress } = {} as any -) { - return useContractRead({ - abi: optimismPortalABI, - address: optimismPortalAddress[1], - functionName: 'finalizedWithdrawals', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismPortalABI}__ and `functionName` set to `"isOutputFinalized"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) - */ -export function useOptimismPortalIsOutputFinalized< - TFunctionName extends 'isOutputFinalized', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimismPortalAddress } = {} as any -) { - return useContractRead({ - abi: optimismPortalABI, - address: optimismPortalAddress[1], - functionName: 'isOutputFinalized', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismPortalABI}__ and `functionName` set to `"l2Sender"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) - */ -export function useOptimismPortalL2Sender< - TFunctionName extends 'l2Sender', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimismPortalAddress } = {} as any -) { - return useContractRead({ - abi: optimismPortalABI, - address: optimismPortalAddress[1], - functionName: 'l2Sender', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismPortalABI}__ and `functionName` set to `"minimumGasLimit"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) - */ -export function useOptimismPortalMinimumGasLimit< - TFunctionName extends 'minimumGasLimit', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimismPortalAddress } = {} as any -) { - return useContractRead({ - abi: optimismPortalABI, - address: optimismPortalAddress[1], - functionName: 'minimumGasLimit', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismPortalABI}__ and `functionName` set to `"params"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) - */ -export function useOptimismPortalParams< - TFunctionName extends 'params', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimismPortalAddress } = {} as any -) { - return useContractRead({ - abi: optimismPortalABI, - address: optimismPortalAddress[1], - functionName: 'params', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismPortalABI}__ and `functionName` set to `"paused"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) - */ -export function useOptimismPortalPaused< - TFunctionName extends 'paused', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimismPortalAddress } = {} as any -) { - return useContractRead({ - abi: optimismPortalABI, - address: optimismPortalAddress[1], - functionName: 'paused', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismPortalABI}__ and `functionName` set to `"provenWithdrawals"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) - */ -export function useOptimismPortalProvenWithdrawals< - TFunctionName extends 'provenWithdrawals', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimismPortalAddress } = {} as any -) { - return useContractRead({ - abi: optimismPortalABI, - address: optimismPortalAddress[1], - functionName: 'provenWithdrawals', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismPortalABI}__ and `functionName` set to `"version"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) - */ -export function useOptimismPortalVersion< - TFunctionName extends 'version', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimismPortalAddress } = {} as any -) { - return useContractRead({ - abi: optimismPortalABI, - address: optimismPortalAddress[1], - functionName: 'version', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimismPortalABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) - */ -export function useOptimismPortalWrite< - TFunctionName extends string, - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof optimismPortalAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof optimismPortalABI, - string - >['request']['abi'], - TFunctionName, - TMode - > & { address?: Address; chainId?: TChainId } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - } = {} as any -) { - return useContractWrite({ - abi: optimismPortalABI, - address: optimismPortalAddress[1], - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimismPortalABI}__ and `functionName` set to `"depositTransaction"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) - */ -export function useOptimismPortalDepositTransaction< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof optimismPortalAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof optimismPortalABI, - 'depositTransaction' - >['request']['abi'], - 'depositTransaction', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'depositTransaction' - } - : UseContractWriteConfig< - typeof optimismPortalABI, - 'depositTransaction', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'depositTransaction' - } = {} as any -) { - return useContractWrite< - typeof optimismPortalABI, - 'depositTransaction', - TMode - >({ - abi: optimismPortalABI, - address: optimismPortalAddress[1], - functionName: 'depositTransaction', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimismPortalABI}__ and `functionName` set to `"donateETH"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) - */ -export function useOptimismPortalDonateEth< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof optimismPortalAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof optimismPortalABI, - 'donateETH' - >['request']['abi'], - 'donateETH', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'donateETH' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'donateETH' - } = {} as any -) { - return useContractWrite({ - abi: optimismPortalABI, - address: optimismPortalAddress[1], - functionName: 'donateETH', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimismPortalABI}__ and `functionName` set to `"finalizeWithdrawalTransaction"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) - */ -export function useOptimismPortalFinalizeWithdrawalTransaction< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof optimismPortalAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof optimismPortalABI, - 'finalizeWithdrawalTransaction' - >['request']['abi'], - 'finalizeWithdrawalTransaction', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'finalizeWithdrawalTransaction' - } - : UseContractWriteConfig< - typeof optimismPortalABI, - 'finalizeWithdrawalTransaction', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'finalizeWithdrawalTransaction' - } = {} as any -) { - return useContractWrite< - typeof optimismPortalABI, - 'finalizeWithdrawalTransaction', - TMode - >({ - abi: optimismPortalABI, - address: optimismPortalAddress[1], - functionName: 'finalizeWithdrawalTransaction', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimismPortalABI}__ and `functionName` set to `"initialize"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) - */ -export function useOptimismPortalInitialize< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof optimismPortalAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof optimismPortalABI, - 'initialize' - >['request']['abi'], - 'initialize', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'initialize' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'initialize' - } = {} as any -) { - return useContractWrite({ - abi: optimismPortalABI, - address: optimismPortalAddress[1], - functionName: 'initialize', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimismPortalABI}__ and `functionName` set to `"pause"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) - */ -export function useOptimismPortalPause< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof optimismPortalAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof optimismPortalABI, - 'pause' - >['request']['abi'], - 'pause', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'pause' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'pause' - } = {} as any -) { - return useContractWrite({ - abi: optimismPortalABI, - address: optimismPortalAddress[1], - functionName: 'pause', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimismPortalABI}__ and `functionName` set to `"proveWithdrawalTransaction"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) - */ -export function useOptimismPortalProveWithdrawalTransaction< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof optimismPortalAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof optimismPortalABI, - 'proveWithdrawalTransaction' - >['request']['abi'], - 'proveWithdrawalTransaction', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'proveWithdrawalTransaction' - } - : UseContractWriteConfig< - typeof optimismPortalABI, - 'proveWithdrawalTransaction', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'proveWithdrawalTransaction' - } = {} as any -) { - return useContractWrite< - typeof optimismPortalABI, - 'proveWithdrawalTransaction', - TMode - >({ - abi: optimismPortalABI, - address: optimismPortalAddress[1], - functionName: 'proveWithdrawalTransaction', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimismPortalABI}__ and `functionName` set to `"unpause"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) - */ -export function useOptimismPortalUnpause< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof optimismPortalAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof optimismPortalABI, - 'unpause' - >['request']['abi'], - 'unpause', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'unpause' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'unpause' - } = {} as any -) { - return useContractWrite({ - abi: optimismPortalABI, - address: optimismPortalAddress[1], - functionName: 'unpause', - ...config, - } as any) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link optimismPortalABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) - */ -export function usePrepareOptimismPortalWrite( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof optimismPortalAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: optimismPortalABI, - address: optimismPortalAddress[1], - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link optimismPortalABI}__ and `functionName` set to `"depositTransaction"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) - */ -export function usePrepareOptimismPortalDepositTransaction( - config: Omit< - UsePrepareContractWriteConfig< - typeof optimismPortalABI, - 'depositTransaction' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimismPortalAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: optimismPortalABI, - address: optimismPortalAddress[1], - functionName: 'depositTransaction', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link optimismPortalABI}__ and `functionName` set to `"donateETH"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) - */ -export function usePrepareOptimismPortalDonateEth( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimismPortalAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: optimismPortalABI, - address: optimismPortalAddress[1], - functionName: 'donateETH', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link optimismPortalABI}__ and `functionName` set to `"finalizeWithdrawalTransaction"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) - */ -export function usePrepareOptimismPortalFinalizeWithdrawalTransaction( - config: Omit< - UsePrepareContractWriteConfig< - typeof optimismPortalABI, - 'finalizeWithdrawalTransaction' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimismPortalAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: optimismPortalABI, - address: optimismPortalAddress[1], - functionName: 'finalizeWithdrawalTransaction', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link optimismPortalABI}__ and `functionName` set to `"initialize"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) - */ -export function usePrepareOptimismPortalInitialize( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimismPortalAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: optimismPortalABI, - address: optimismPortalAddress[1], - functionName: 'initialize', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link optimismPortalABI}__ and `functionName` set to `"pause"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) - */ -export function usePrepareOptimismPortalPause( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimismPortalAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: optimismPortalABI, - address: optimismPortalAddress[1], - functionName: 'pause', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link optimismPortalABI}__ and `functionName` set to `"proveWithdrawalTransaction"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) - */ -export function usePrepareOptimismPortalProveWithdrawalTransaction( - config: Omit< - UsePrepareContractWriteConfig< - typeof optimismPortalABI, - 'proveWithdrawalTransaction' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimismPortalAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: optimismPortalABI, - address: optimismPortalAddress[1], - functionName: 'proveWithdrawalTransaction', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link optimismPortalABI}__ and `functionName` set to `"unpause"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) - */ -export function usePrepareOptimismPortalUnpause( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimismPortalAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: optimismPortalABI, - address: optimismPortalAddress[1], - functionName: 'unpause', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link optimismPortalABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) - */ -export function useOptimismPortalEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof optimismPortalAddress } = {} as any -) { - return useContractEvent({ - abi: optimismPortalABI, - address: optimismPortalAddress[1], - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link optimismPortalABI}__ and `eventName` set to `"Initialized"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) - */ -export function useOptimismPortalInitializedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof optimismPortalAddress } = {} as any -) { - return useContractEvent({ - abi: optimismPortalABI, - address: optimismPortalAddress[1], - eventName: 'Initialized', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link optimismPortalABI}__ and `eventName` set to `"Paused"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) - */ -export function useOptimismPortalPausedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof optimismPortalAddress } = {} as any -) { - return useContractEvent({ - abi: optimismPortalABI, - address: optimismPortalAddress[1], - eventName: 'Paused', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link optimismPortalABI}__ and `eventName` set to `"TransactionDeposited"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) - */ -export function useOptimismPortalTransactionDepositedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof optimismPortalAddress } = {} as any -) { - return useContractEvent({ - abi: optimismPortalABI, - address: optimismPortalAddress[1], - eventName: 'TransactionDeposited', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link optimismPortalABI}__ and `eventName` set to `"Unpaused"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) - */ -export function useOptimismPortalUnpausedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof optimismPortalAddress } = {} as any -) { - return useContractEvent({ - abi: optimismPortalABI, - address: optimismPortalAddress[1], - eventName: 'Unpaused', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link optimismPortalABI}__ and `eventName` set to `"WithdrawalFinalized"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) - */ -export function useOptimismPortalWithdrawalFinalizedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof optimismPortalAddress } = {} as any -) { - return useContractEvent({ - abi: optimismPortalABI, - address: optimismPortalAddress[1], - eventName: 'WithdrawalFinalized', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link optimismPortalABI}__ and `eventName` set to `"WithdrawalProven"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) - */ -export function useOptimismPortalWithdrawalProvenEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof optimismPortalAddress } = {} as any -) { - return useContractEvent({ - abi: optimismPortalABI, - address: optimismPortalAddress[1], - eventName: 'WithdrawalProven', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismPortalGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) - */ -export function useOptimismPortalGoerliRead< - TFunctionName extends string, - TSelectData = ReadContractResult< - typeof optimismPortalGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof optimismPortalGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' - > & { chainId?: keyof typeof optimismPortalGoerliAddress } = {} as any -) { - return useContractRead({ - abi: optimismPortalGoerliABI, - address: optimismPortalGoerliAddress[5], - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismPortalGoerliABI}__ and `functionName` set to `"finalizedWithdrawals"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) - */ -export function useOptimismPortalGoerliFinalizedWithdrawals< - TFunctionName extends 'finalizedWithdrawals', - TSelectData = ReadContractResult< - typeof optimismPortalGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof optimismPortalGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimismPortalGoerliAddress } = {} as any -) { - return useContractRead({ - abi: optimismPortalGoerliABI, - address: optimismPortalGoerliAddress[5], - functionName: 'finalizedWithdrawals', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismPortalGoerliABI}__ and `functionName` set to `"guardian"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) - */ -export function useOptimismPortalGoerliGuardian< - TFunctionName extends 'guardian', - TSelectData = ReadContractResult< - typeof optimismPortalGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof optimismPortalGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimismPortalGoerliAddress } = {} as any -) { - return useContractRead({ - abi: optimismPortalGoerliABI, - address: optimismPortalGoerliAddress[5], - functionName: 'guardian', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismPortalGoerliABI}__ and `functionName` set to `"isOutputFinalized"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) - */ -export function useOptimismPortalGoerliIsOutputFinalized< - TFunctionName extends 'isOutputFinalized', - TSelectData = ReadContractResult< - typeof optimismPortalGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof optimismPortalGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimismPortalGoerliAddress } = {} as any -) { - return useContractRead({ - abi: optimismPortalGoerliABI, - address: optimismPortalGoerliAddress[5], - functionName: 'isOutputFinalized', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismPortalGoerliABI}__ and `functionName` set to `"l2Oracle"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) - */ -export function useOptimismPortalGoerliL2Oracle< - TFunctionName extends 'l2Oracle', - TSelectData = ReadContractResult< - typeof optimismPortalGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof optimismPortalGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimismPortalGoerliAddress } = {} as any -) { - return useContractRead({ - abi: optimismPortalGoerliABI, - address: optimismPortalGoerliAddress[5], - functionName: 'l2Oracle', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismPortalGoerliABI}__ and `functionName` set to `"l2Sender"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) - */ -export function useOptimismPortalGoerliL2Sender< - TFunctionName extends 'l2Sender', - TSelectData = ReadContractResult< - typeof optimismPortalGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof optimismPortalGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimismPortalGoerliAddress } = {} as any -) { - return useContractRead({ - abi: optimismPortalGoerliABI, - address: optimismPortalGoerliAddress[5], - functionName: 'l2Sender', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismPortalGoerliABI}__ and `functionName` set to `"minimumGasLimit"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) - */ -export function useOptimismPortalGoerliMinimumGasLimit< - TFunctionName extends 'minimumGasLimit', - TSelectData = ReadContractResult< - typeof optimismPortalGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof optimismPortalGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimismPortalGoerliAddress } = {} as any -) { - return useContractRead({ - abi: optimismPortalGoerliABI, - address: optimismPortalGoerliAddress[5], - functionName: 'minimumGasLimit', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismPortalGoerliABI}__ and `functionName` set to `"params"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) - */ -export function useOptimismPortalGoerliParams< - TFunctionName extends 'params', - TSelectData = ReadContractResult< - typeof optimismPortalGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof optimismPortalGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimismPortalGoerliAddress } = {} as any -) { - return useContractRead({ - abi: optimismPortalGoerliABI, - address: optimismPortalGoerliAddress[5], - functionName: 'params', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismPortalGoerliABI}__ and `functionName` set to `"paused"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) - */ -export function useOptimismPortalGoerliPaused< - TFunctionName extends 'paused', - TSelectData = ReadContractResult< - typeof optimismPortalGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof optimismPortalGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimismPortalGoerliAddress } = {} as any -) { - return useContractRead({ - abi: optimismPortalGoerliABI, - address: optimismPortalGoerliAddress[5], - functionName: 'paused', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismPortalGoerliABI}__ and `functionName` set to `"provenWithdrawals"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) - */ -export function useOptimismPortalGoerliProvenWithdrawals< - TFunctionName extends 'provenWithdrawals', - TSelectData = ReadContractResult< - typeof optimismPortalGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof optimismPortalGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimismPortalGoerliAddress } = {} as any -) { - return useContractRead({ - abi: optimismPortalGoerliABI, - address: optimismPortalGoerliAddress[5], - functionName: 'provenWithdrawals', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismPortalGoerliABI}__ and `functionName` set to `"systemConfig"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) - */ -export function useOptimismPortalGoerliSystemConfig< - TFunctionName extends 'systemConfig', - TSelectData = ReadContractResult< - typeof optimismPortalGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof optimismPortalGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimismPortalGoerliAddress } = {} as any -) { - return useContractRead({ - abi: optimismPortalGoerliABI, - address: optimismPortalGoerliAddress[5], - functionName: 'systemConfig', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismPortalGoerliABI}__ and `functionName` set to `"version"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) - */ -export function useOptimismPortalGoerliVersion< - TFunctionName extends 'version', - TSelectData = ReadContractResult< - typeof optimismPortalGoerliABI, - TFunctionName - > ->( - config: Omit< - UseContractReadConfig< - typeof optimismPortalGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimismPortalGoerliAddress } = {} as any -) { - return useContractRead({ - abi: optimismPortalGoerliABI, - address: optimismPortalGoerliAddress[5], - functionName: 'version', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimismPortalGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) - */ -export function useOptimismPortalGoerliWrite< - TFunctionName extends string, - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof optimismPortalGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof optimismPortalGoerliABI, - string - >['request']['abi'], - TFunctionName, - TMode - > & { address?: Address; chainId?: TChainId } - : UseContractWriteConfig< - typeof optimismPortalGoerliABI, - TFunctionName, - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - } = {} as any -) { - return useContractWrite( - { - abi: optimismPortalGoerliABI, - address: optimismPortalGoerliAddress[5], - ...config, - } as any - ) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimismPortalGoerliABI}__ and `functionName` set to `"depositTransaction"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) - */ -export function useOptimismPortalGoerliDepositTransaction< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof optimismPortalGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof optimismPortalGoerliABI, - 'depositTransaction' - >['request']['abi'], - 'depositTransaction', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'depositTransaction' - } - : UseContractWriteConfig< - typeof optimismPortalGoerliABI, - 'depositTransaction', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'depositTransaction' - } = {} as any -) { - return useContractWrite< - typeof optimismPortalGoerliABI, - 'depositTransaction', - TMode - >({ - abi: optimismPortalGoerliABI, - address: optimismPortalGoerliAddress[5], - functionName: 'depositTransaction', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimismPortalGoerliABI}__ and `functionName` set to `"donateETH"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) - */ -export function useOptimismPortalGoerliDonateEth< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof optimismPortalGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof optimismPortalGoerliABI, - 'donateETH' - >['request']['abi'], - 'donateETH', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'donateETH' } - : UseContractWriteConfig< - typeof optimismPortalGoerliABI, - 'donateETH', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'donateETH' - } = {} as any -) { - return useContractWrite({ - abi: optimismPortalGoerliABI, - address: optimismPortalGoerliAddress[5], - functionName: 'donateETH', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimismPortalGoerliABI}__ and `functionName` set to `"finalizeWithdrawalTransaction"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) - */ -export function useOptimismPortalGoerliFinalizeWithdrawalTransaction< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof optimismPortalGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof optimismPortalGoerliABI, - 'finalizeWithdrawalTransaction' - >['request']['abi'], - 'finalizeWithdrawalTransaction', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'finalizeWithdrawalTransaction' - } - : UseContractWriteConfig< - typeof optimismPortalGoerliABI, - 'finalizeWithdrawalTransaction', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'finalizeWithdrawalTransaction' - } = {} as any -) { - return useContractWrite< - typeof optimismPortalGoerliABI, - 'finalizeWithdrawalTransaction', - TMode - >({ - abi: optimismPortalGoerliABI, - address: optimismPortalGoerliAddress[5], - functionName: 'finalizeWithdrawalTransaction', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimismPortalGoerliABI}__ and `functionName` set to `"initialize"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) - */ -export function useOptimismPortalGoerliInitialize< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof optimismPortalGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof optimismPortalGoerliABI, - 'initialize' - >['request']['abi'], - 'initialize', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'initialize' } - : UseContractWriteConfig< - typeof optimismPortalGoerliABI, - 'initialize', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'initialize' - } = {} as any -) { - return useContractWrite({ - abi: optimismPortalGoerliABI, - address: optimismPortalGoerliAddress[5], - functionName: 'initialize', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimismPortalGoerliABI}__ and `functionName` set to `"pause"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) - */ -export function useOptimismPortalGoerliPause< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof optimismPortalGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof optimismPortalGoerliABI, - 'pause' - >['request']['abi'], - 'pause', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'pause' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'pause' - } = {} as any -) { - return useContractWrite({ - abi: optimismPortalGoerliABI, - address: optimismPortalGoerliAddress[5], - functionName: 'pause', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimismPortalGoerliABI}__ and `functionName` set to `"proveWithdrawalTransaction"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) - */ -export function useOptimismPortalGoerliProveWithdrawalTransaction< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof optimismPortalGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof optimismPortalGoerliABI, - 'proveWithdrawalTransaction' - >['request']['abi'], - 'proveWithdrawalTransaction', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'proveWithdrawalTransaction' - } - : UseContractWriteConfig< - typeof optimismPortalGoerliABI, - 'proveWithdrawalTransaction', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'proveWithdrawalTransaction' - } = {} as any -) { - return useContractWrite< - typeof optimismPortalGoerliABI, - 'proveWithdrawalTransaction', - TMode - >({ - abi: optimismPortalGoerliABI, - address: optimismPortalGoerliAddress[5], - functionName: 'proveWithdrawalTransaction', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimismPortalGoerliABI}__ and `functionName` set to `"unpause"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) - */ -export function useOptimismPortalGoerliUnpause< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof optimismPortalGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof optimismPortalGoerliABI, - 'unpause' - >['request']['abi'], - 'unpause', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'unpause' } - : UseContractWriteConfig< - typeof optimismPortalGoerliABI, - 'unpause', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'unpause' - } = {} as any -) { - return useContractWrite({ - abi: optimismPortalGoerliABI, - address: optimismPortalGoerliAddress[5], - functionName: 'unpause', - ...config, - } as any) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link optimismPortalGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) - */ -export function usePrepareOptimismPortalGoerliWrite< - TFunctionName extends string ->( - config: Omit< - UsePrepareContractWriteConfig< - typeof optimismPortalGoerliABI, - TFunctionName - >, - 'abi' | 'address' - > & { chainId?: keyof typeof optimismPortalGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: optimismPortalGoerliABI, - address: optimismPortalGoerliAddress[5], - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link optimismPortalGoerliABI}__ and `functionName` set to `"depositTransaction"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) - */ -export function usePrepareOptimismPortalGoerliDepositTransaction( - config: Omit< - UsePrepareContractWriteConfig< - typeof optimismPortalGoerliABI, - 'depositTransaction' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimismPortalGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: optimismPortalGoerliABI, - address: optimismPortalGoerliAddress[5], - functionName: 'depositTransaction', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link optimismPortalGoerliABI}__ and `functionName` set to `"donateETH"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) - */ -export function usePrepareOptimismPortalGoerliDonateEth( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimismPortalGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: optimismPortalGoerliABI, - address: optimismPortalGoerliAddress[5], - functionName: 'donateETH', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link optimismPortalGoerliABI}__ and `functionName` set to `"finalizeWithdrawalTransaction"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) - */ -export function usePrepareOptimismPortalGoerliFinalizeWithdrawalTransaction( - config: Omit< - UsePrepareContractWriteConfig< - typeof optimismPortalGoerliABI, - 'finalizeWithdrawalTransaction' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimismPortalGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: optimismPortalGoerliABI, - address: optimismPortalGoerliAddress[5], - functionName: 'finalizeWithdrawalTransaction', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link optimismPortalGoerliABI}__ and `functionName` set to `"initialize"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) - */ -export function usePrepareOptimismPortalGoerliInitialize( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimismPortalGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: optimismPortalGoerliABI, - address: optimismPortalGoerliAddress[5], - functionName: 'initialize', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link optimismPortalGoerliABI}__ and `functionName` set to `"pause"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) - */ -export function usePrepareOptimismPortalGoerliPause( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimismPortalGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: optimismPortalGoerliABI, - address: optimismPortalGoerliAddress[5], - functionName: 'pause', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link optimismPortalGoerliABI}__ and `functionName` set to `"proveWithdrawalTransaction"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) - */ -export function usePrepareOptimismPortalGoerliProveWithdrawalTransaction( - config: Omit< - UsePrepareContractWriteConfig< - typeof optimismPortalGoerliABI, - 'proveWithdrawalTransaction' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimismPortalGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: optimismPortalGoerliABI, - address: optimismPortalGoerliAddress[5], - functionName: 'proveWithdrawalTransaction', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link optimismPortalGoerliABI}__ and `functionName` set to `"unpause"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) - */ -export function usePrepareOptimismPortalGoerliUnpause( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimismPortalGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: optimismPortalGoerliABI, - address: optimismPortalGoerliAddress[5], - functionName: 'unpause', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link optimismPortalGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) - */ -export function useOptimismPortalGoerliEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof optimismPortalGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: optimismPortalGoerliABI, - address: optimismPortalGoerliAddress[5], - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link optimismPortalGoerliABI}__ and `eventName` set to `"Initialized"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) - */ -export function useOptimismPortalGoerliInitializedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof optimismPortalGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: optimismPortalGoerliABI, - address: optimismPortalGoerliAddress[5], - eventName: 'Initialized', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link optimismPortalGoerliABI}__ and `eventName` set to `"Paused"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) - */ -export function useOptimismPortalGoerliPausedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof optimismPortalGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: optimismPortalGoerliABI, - address: optimismPortalGoerliAddress[5], - eventName: 'Paused', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link optimismPortalGoerliABI}__ and `eventName` set to `"TransactionDeposited"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) - */ -export function useOptimismPortalGoerliTransactionDepositedEvent( - config: Omit< - UseContractEventConfig< - typeof optimismPortalGoerliABI, - 'TransactionDeposited' - >, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof optimismPortalGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: optimismPortalGoerliABI, - address: optimismPortalGoerliAddress[5], - eventName: 'TransactionDeposited', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link optimismPortalGoerliABI}__ and `eventName` set to `"Unpaused"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) - */ -export function useOptimismPortalGoerliUnpausedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof optimismPortalGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: optimismPortalGoerliABI, - address: optimismPortalGoerliAddress[5], - eventName: 'Unpaused', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link optimismPortalGoerliABI}__ and `eventName` set to `"WithdrawalFinalized"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) - */ -export function useOptimismPortalGoerliWithdrawalFinalizedEvent( - config: Omit< - UseContractEventConfig< - typeof optimismPortalGoerliABI, - 'WithdrawalFinalized' - >, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof optimismPortalGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: optimismPortalGoerliABI, - address: optimismPortalGoerliAddress[5], - eventName: 'WithdrawalFinalized', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link optimismPortalGoerliABI}__ and `eventName` set to `"WithdrawalProven"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) - */ -export function useOptimismPortalGoerliWithdrawalProvenEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof optimismPortalGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: optimismPortalGoerliABI, - address: optimismPortalGoerliAddress[5], - eventName: 'WithdrawalProven', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimistABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - */ -export function useOptimistRead< - TFunctionName extends string, - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof optimistAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: optimistABI, - address: optimistAddress[chainId as keyof typeof optimistAddress], - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimistABI}__ and `functionName` set to `"ATTESTATION_STATION"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - */ -export function useOptimistAttestationStation< - TFunctionName extends 'ATTESTATION_STATION', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimistAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: optimistABI, - address: optimistAddress[chainId as keyof typeof optimistAddress], - functionName: 'ATTESTATION_STATION', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimistABI}__ and `functionName` set to `"BASE_URI_ATTESTATION_KEY"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - */ -export function useOptimistBaseUriAttestationKey< - TFunctionName extends 'BASE_URI_ATTESTATION_KEY', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimistAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: optimistABI, - address: optimistAddress[chainId as keyof typeof optimistAddress], - functionName: 'BASE_URI_ATTESTATION_KEY', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimistABI}__ and `functionName` set to `"BASE_URI_ATTESTOR"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - */ -export function useOptimistBaseUriAttestor< - TFunctionName extends 'BASE_URI_ATTESTOR', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimistAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: optimistABI, - address: optimistAddress[chainId as keyof typeof optimistAddress], - functionName: 'BASE_URI_ATTESTOR', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimistABI}__ and `functionName` set to `"OPTIMIST_ALLOWLIST"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - */ -export function useOptimistOptimistAllowlist< - TFunctionName extends 'OPTIMIST_ALLOWLIST', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimistAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: optimistABI, - address: optimistAddress[chainId as keyof typeof optimistAddress], - functionName: 'OPTIMIST_ALLOWLIST', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimistABI}__ and `functionName` set to `"approve"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - */ -export function useOptimistApprove< - TFunctionName extends 'approve', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimistAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: optimistABI, - address: optimistAddress[chainId as keyof typeof optimistAddress], - functionName: 'approve', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimistABI}__ and `functionName` set to `"balanceOf"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - */ -export function useOptimistBalanceOf< - TFunctionName extends 'balanceOf', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimistAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: optimistABI, - address: optimistAddress[chainId as keyof typeof optimistAddress], - functionName: 'balanceOf', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimistABI}__ and `functionName` set to `"baseURI"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - */ -export function useOptimistBaseUri< - TFunctionName extends 'baseURI', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimistAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: optimistABI, - address: optimistAddress[chainId as keyof typeof optimistAddress], - functionName: 'baseURI', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimistABI}__ and `functionName` set to `"getApproved"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - */ -export function useOptimistGetApproved< - TFunctionName extends 'getApproved', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimistAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: optimistABI, - address: optimistAddress[chainId as keyof typeof optimistAddress], - functionName: 'getApproved', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimistABI}__ and `functionName` set to `"isApprovedForAll"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - */ -export function useOptimistIsApprovedForAll< - TFunctionName extends 'isApprovedForAll', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimistAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: optimistABI, - address: optimistAddress[chainId as keyof typeof optimistAddress], - functionName: 'isApprovedForAll', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimistABI}__ and `functionName` set to `"isOnAllowList"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - */ -export function useOptimistIsOnAllowList< - TFunctionName extends 'isOnAllowList', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimistAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: optimistABI, - address: optimistAddress[chainId as keyof typeof optimistAddress], - functionName: 'isOnAllowList', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimistABI}__ and `functionName` set to `"name"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - */ -export function useOptimistName< - TFunctionName extends 'name', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimistAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: optimistABI, - address: optimistAddress[chainId as keyof typeof optimistAddress], - functionName: 'name', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimistABI}__ and `functionName` set to `"ownerOf"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - */ -export function useOptimistOwnerOf< - TFunctionName extends 'ownerOf', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimistAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: optimistABI, - address: optimistAddress[chainId as keyof typeof optimistAddress], - functionName: 'ownerOf', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimistABI}__ and `functionName` set to `"supportsInterface"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - */ -export function useOptimistSupportsInterface< - TFunctionName extends 'supportsInterface', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimistAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: optimistABI, - address: optimistAddress[chainId as keyof typeof optimistAddress], - functionName: 'supportsInterface', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimistABI}__ and `functionName` set to `"symbol"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - */ -export function useOptimistSymbol< - TFunctionName extends 'symbol', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimistAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: optimistABI, - address: optimistAddress[chainId as keyof typeof optimistAddress], - functionName: 'symbol', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimistABI}__ and `functionName` set to `"tokenIdOfAddress"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - */ -export function useOptimistTokenIdOfAddress< - TFunctionName extends 'tokenIdOfAddress', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimistAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: optimistABI, - address: optimistAddress[chainId as keyof typeof optimistAddress], - functionName: 'tokenIdOfAddress', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimistABI}__ and `functionName` set to `"tokenURI"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - */ -export function useOptimistTokenUri< - TFunctionName extends 'tokenURI', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimistAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: optimistABI, - address: optimistAddress[chainId as keyof typeof optimistAddress], - functionName: 'tokenURI', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimistABI}__ and `functionName` set to `"version"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - */ -export function useOptimistVersion< - TFunctionName extends 'version', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimistAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: optimistABI, - address: optimistAddress[chainId as keyof typeof optimistAddress], - functionName: 'version', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimistABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - */ -export function useOptimistWrite< - TFunctionName extends string, - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof optimistAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof optimistABI, - string - >['request']['abi'], - TFunctionName, - TMode - > & { address?: Address; chainId?: TChainId } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: optimistABI, - address: optimistAddress[chainId as keyof typeof optimistAddress], - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimistABI}__ and `functionName` set to `"burn"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - */ -export function useOptimistBurn< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof optimistAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof optimistABI, - 'burn' - >['request']['abi'], - 'burn', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'burn' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'burn' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: optimistABI, - address: optimistAddress[chainId as keyof typeof optimistAddress], - functionName: 'burn', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimistABI}__ and `functionName` set to `"initialize"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - */ -export function useOptimistInitialize< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof optimistAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof optimistABI, - 'initialize' - >['request']['abi'], - 'initialize', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'initialize' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'initialize' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: optimistABI, - address: optimistAddress[chainId as keyof typeof optimistAddress], - functionName: 'initialize', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimistABI}__ and `functionName` set to `"mint"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - */ -export function useOptimistMint< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof optimistAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof optimistABI, - 'mint' - >['request']['abi'], - 'mint', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'mint' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'mint' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: optimistABI, - address: optimistAddress[chainId as keyof typeof optimistAddress], - functionName: 'mint', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimistABI}__ and `functionName` set to `"safeTransferFrom"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - */ -export function useOptimistSafeTransferFrom< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof optimistAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof optimistABI, - 'safeTransferFrom' - >['request']['abi'], - 'safeTransferFrom', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'safeTransferFrom' - } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'safeTransferFrom' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: optimistABI, - address: optimistAddress[chainId as keyof typeof optimistAddress], - functionName: 'safeTransferFrom', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimistABI}__ and `functionName` set to `"setApprovalForAll"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - */ -export function useOptimistSetApprovalForAll< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof optimistAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof optimistABI, - 'setApprovalForAll' - >['request']['abi'], - 'setApprovalForAll', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'setApprovalForAll' - } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'setApprovalForAll' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: optimistABI, - address: optimistAddress[chainId as keyof typeof optimistAddress], - functionName: 'setApprovalForAll', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimistABI}__ and `functionName` set to `"transferFrom"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - */ -export function useOptimistTransferFrom< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof optimistAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof optimistABI, - 'transferFrom' - >['request']['abi'], - 'transferFrom', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'transferFrom' - } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'transferFrom' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: optimistABI, - address: optimistAddress[chainId as keyof typeof optimistAddress], - functionName: 'transferFrom', - ...config, - } as any) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link optimistABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - */ -export function usePrepareOptimistWrite( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof optimistAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: optimistABI, - address: optimistAddress[chainId as keyof typeof optimistAddress], - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link optimistABI}__ and `functionName` set to `"burn"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - */ -export function usePrepareOptimistBurn( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimistAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: optimistABI, - address: optimistAddress[chainId as keyof typeof optimistAddress], - functionName: 'burn', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link optimistABI}__ and `functionName` set to `"initialize"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - */ -export function usePrepareOptimistInitialize( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimistAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: optimistABI, - address: optimistAddress[chainId as keyof typeof optimistAddress], - functionName: 'initialize', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link optimistABI}__ and `functionName` set to `"mint"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - */ -export function usePrepareOptimistMint( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimistAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: optimistABI, - address: optimistAddress[chainId as keyof typeof optimistAddress], - functionName: 'mint', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link optimistABI}__ and `functionName` set to `"safeTransferFrom"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - */ -export function usePrepareOptimistSafeTransferFrom( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimistAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: optimistABI, - address: optimistAddress[chainId as keyof typeof optimistAddress], - functionName: 'safeTransferFrom', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link optimistABI}__ and `functionName` set to `"setApprovalForAll"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - */ -export function usePrepareOptimistSetApprovalForAll( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimistAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: optimistABI, - address: optimistAddress[chainId as keyof typeof optimistAddress], - functionName: 'setApprovalForAll', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link optimistABI}__ and `functionName` set to `"transferFrom"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - */ -export function usePrepareOptimistTransferFrom( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimistAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: optimistABI, - address: optimistAddress[chainId as keyof typeof optimistAddress], - functionName: 'transferFrom', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link optimistABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - */ -export function useOptimistEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof optimistAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractEvent({ - abi: optimistABI, - address: optimistAddress[chainId as keyof typeof optimistAddress], - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link optimistABI}__ and `eventName` set to `"Approval"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - */ -export function useOptimistApprovalEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof optimistAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractEvent({ - abi: optimistABI, - address: optimistAddress[chainId as keyof typeof optimistAddress], - eventName: 'Approval', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link optimistABI}__ and `eventName` set to `"ApprovalForAll"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - */ -export function useOptimistApprovalForAllEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof optimistAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractEvent({ - abi: optimistABI, - address: optimistAddress[chainId as keyof typeof optimistAddress], - eventName: 'ApprovalForAll', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link optimistABI}__ and `eventName` set to `"Initialized"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - */ -export function useOptimistInitializedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof optimistAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractEvent({ - abi: optimistABI, - address: optimistAddress[chainId as keyof typeof optimistAddress], - eventName: 'Initialized', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link optimistABI}__ and `eventName` set to `"Transfer"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) - */ -export function useOptimistTransferEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof optimistAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractEvent({ - abi: optimistABI, - address: optimistAddress[chainId as keyof typeof optimistAddress], - eventName: 'Transfer', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimistAllowlistABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) - */ -export function useOptimistAllowlistRead< - TFunctionName extends string, - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof optimistAllowlistABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' - > & { chainId?: keyof typeof optimistAllowlistAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: optimistAllowlistABI, - address: - optimistAllowlistAddress[ - chainId as keyof typeof optimistAllowlistAddress - ], - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimistAllowlistABI}__ and `functionName` set to `"ALLOWLIST_ATTESTOR"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) - */ -export function useOptimistAllowlistAllowlistAttestor< - TFunctionName extends 'ALLOWLIST_ATTESTOR', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof optimistAllowlistABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimistAllowlistAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: optimistAllowlistABI, - address: - optimistAllowlistAddress[ - chainId as keyof typeof optimistAllowlistAddress - ], - functionName: 'ALLOWLIST_ATTESTOR', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimistAllowlistABI}__ and `functionName` set to `"ATTESTATION_STATION"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) - */ -export function useOptimistAllowlistAttestationStation< - TFunctionName extends 'ATTESTATION_STATION', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof optimistAllowlistABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimistAllowlistAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: optimistAllowlistABI, - address: - optimistAllowlistAddress[ - chainId as keyof typeof optimistAllowlistAddress - ], - functionName: 'ATTESTATION_STATION', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimistAllowlistABI}__ and `functionName` set to `"COINBASE_QUEST_ATTESTOR"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) - */ -export function useOptimistAllowlistCoinbaseQuestAttestor< - TFunctionName extends 'COINBASE_QUEST_ATTESTOR', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof optimistAllowlistABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimistAllowlistAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: optimistAllowlistABI, - address: - optimistAllowlistAddress[ - chainId as keyof typeof optimistAllowlistAddress - ], - functionName: 'COINBASE_QUEST_ATTESTOR', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimistAllowlistABI}__ and `functionName` set to `"COINBASE_QUEST_ELIGIBLE_ATTESTATION_KEY"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) - */ -export function useOptimistAllowlistCoinbaseQuestEligibleAttestationKey< - TFunctionName extends 'COINBASE_QUEST_ELIGIBLE_ATTESTATION_KEY', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof optimistAllowlistABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimistAllowlistAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: optimistAllowlistABI, - address: - optimistAllowlistAddress[ - chainId as keyof typeof optimistAllowlistAddress - ], - functionName: 'COINBASE_QUEST_ELIGIBLE_ATTESTATION_KEY', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimistAllowlistABI}__ and `functionName` set to `"OPTIMIST_CAN_MINT_ATTESTATION_KEY"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) - */ -export function useOptimistAllowlistOptimistCanMintAttestationKey< - TFunctionName extends 'OPTIMIST_CAN_MINT_ATTESTATION_KEY', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof optimistAllowlistABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimistAllowlistAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: optimistAllowlistABI, - address: - optimistAllowlistAddress[ - chainId as keyof typeof optimistAllowlistAddress - ], - functionName: 'OPTIMIST_CAN_MINT_ATTESTATION_KEY', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimistAllowlistABI}__ and `functionName` set to `"OPTIMIST_INVITER"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) - */ -export function useOptimistAllowlistOptimistInviter< - TFunctionName extends 'OPTIMIST_INVITER', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof optimistAllowlistABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimistAllowlistAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: optimistAllowlistABI, - address: - optimistAllowlistAddress[ - chainId as keyof typeof optimistAllowlistAddress - ], - functionName: 'OPTIMIST_INVITER', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimistAllowlistABI}__ and `functionName` set to `"isAllowedToMint"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) - */ -export function useOptimistAllowlistIsAllowedToMint< - TFunctionName extends 'isAllowedToMint', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof optimistAllowlistABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimistAllowlistAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: optimistAllowlistABI, - address: - optimistAllowlistAddress[ - chainId as keyof typeof optimistAllowlistAddress - ], - functionName: 'isAllowedToMint', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimistAllowlistABI}__ and `functionName` set to `"version"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) - */ -export function useOptimistAllowlistVersion< - TFunctionName extends 'version', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof optimistAllowlistABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimistAllowlistAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: optimistAllowlistABI, - address: - optimistAllowlistAddress[ - chainId as keyof typeof optimistAllowlistAddress - ], - functionName: 'version', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimistInviterABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - */ -export function useOptimistInviterRead< - TFunctionName extends string, - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof optimistInviterABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' - > & { chainId?: keyof typeof optimistInviterAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: optimistInviterABI, - address: - optimistInviterAddress[chainId as keyof typeof optimistInviterAddress], - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimistInviterABI}__ and `functionName` set to `"ATTESTATION_STATION"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - */ -export function useOptimistInviterAttestationStation< - TFunctionName extends 'ATTESTATION_STATION', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof optimistInviterABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimistInviterAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: optimistInviterABI, - address: - optimistInviterAddress[chainId as keyof typeof optimistInviterAddress], - functionName: 'ATTESTATION_STATION', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimistInviterABI}__ and `functionName` set to `"CAN_INVITE_ATTESTATION_KEY"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - */ -export function useOptimistInviterCanInviteAttestationKey< - TFunctionName extends 'CAN_INVITE_ATTESTATION_KEY', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof optimistInviterABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimistInviterAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: optimistInviterABI, - address: - optimistInviterAddress[chainId as keyof typeof optimistInviterAddress], - functionName: 'CAN_INVITE_ATTESTATION_KEY', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimistInviterABI}__ and `functionName` set to `"CLAIMABLE_INVITE_TYPEHASH"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - */ -export function useOptimistInviterClaimableInviteTypehash< - TFunctionName extends 'CLAIMABLE_INVITE_TYPEHASH', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof optimistInviterABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimistInviterAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: optimistInviterABI, - address: - optimistInviterAddress[chainId as keyof typeof optimistInviterAddress], - functionName: 'CLAIMABLE_INVITE_TYPEHASH', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimistInviterABI}__ and `functionName` set to `"EIP712_VERSION"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - */ -export function useOptimistInviterEip712Version< - TFunctionName extends 'EIP712_VERSION', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof optimistInviterABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimistInviterAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: optimistInviterABI, - address: - optimistInviterAddress[chainId as keyof typeof optimistInviterAddress], - functionName: 'EIP712_VERSION', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimistInviterABI}__ and `functionName` set to `"INVITE_GRANTER"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - */ -export function useOptimistInviterInviteGranter< - TFunctionName extends 'INVITE_GRANTER', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof optimistInviterABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimistInviterAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: optimistInviterABI, - address: - optimistInviterAddress[chainId as keyof typeof optimistInviterAddress], - functionName: 'INVITE_GRANTER', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimistInviterABI}__ and `functionName` set to `"MIN_COMMITMENT_PERIOD"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - */ -export function useOptimistInviterMinCommitmentPeriod< - TFunctionName extends 'MIN_COMMITMENT_PERIOD', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof optimistInviterABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimistInviterAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: optimistInviterABI, - address: - optimistInviterAddress[chainId as keyof typeof optimistInviterAddress], - functionName: 'MIN_COMMITMENT_PERIOD', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimistInviterABI}__ and `functionName` set to `"commitmentTimestamps"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - */ -export function useOptimistInviterCommitmentTimestamps< - TFunctionName extends 'commitmentTimestamps', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof optimistInviterABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimistInviterAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: optimistInviterABI, - address: - optimistInviterAddress[chainId as keyof typeof optimistInviterAddress], - functionName: 'commitmentTimestamps', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimistInviterABI}__ and `functionName` set to `"inviteCounts"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - */ -export function useOptimistInviterInviteCounts< - TFunctionName extends 'inviteCounts', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof optimistInviterABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimistInviterAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: optimistInviterABI, - address: - optimistInviterAddress[chainId as keyof typeof optimistInviterAddress], - functionName: 'inviteCounts', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimistInviterABI}__ and `functionName` set to `"usedNonces"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - */ -export function useOptimistInviterUsedNonces< - TFunctionName extends 'usedNonces', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof optimistInviterABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimistInviterAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: optimistInviterABI, - address: - optimistInviterAddress[chainId as keyof typeof optimistInviterAddress], - functionName: 'usedNonces', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimistInviterABI}__ and `functionName` set to `"version"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - */ -export function useOptimistInviterVersion< - TFunctionName extends 'version', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof optimistInviterABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimistInviterAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: optimistInviterABI, - address: - optimistInviterAddress[chainId as keyof typeof optimistInviterAddress], - functionName: 'version', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimistInviterABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - */ -export function useOptimistInviterWrite< - TFunctionName extends string, - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof optimistInviterAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof optimistInviterABI, - string - >['request']['abi'], - TFunctionName, - TMode - > & { address?: Address; chainId?: TChainId } - : UseContractWriteConfig< - typeof optimistInviterABI, - TFunctionName, - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: optimistInviterABI, - address: - optimistInviterAddress[chainId as keyof typeof optimistInviterAddress], - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimistInviterABI}__ and `functionName` set to `"claimInvite"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - */ -export function useOptimistInviterClaimInvite< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof optimistInviterAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof optimistInviterABI, - 'claimInvite' - >['request']['abi'], - 'claimInvite', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'claimInvite' - } - : UseContractWriteConfig< - typeof optimistInviterABI, - 'claimInvite', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'claimInvite' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: optimistInviterABI, - address: - optimistInviterAddress[chainId as keyof typeof optimistInviterAddress], - functionName: 'claimInvite', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimistInviterABI}__ and `functionName` set to `"commitInvite"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - */ -export function useOptimistInviterCommitInvite< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof optimistInviterAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof optimistInviterABI, - 'commitInvite' - >['request']['abi'], - 'commitInvite', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'commitInvite' - } - : UseContractWriteConfig< - typeof optimistInviterABI, - 'commitInvite', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'commitInvite' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: optimistInviterABI, - address: - optimistInviterAddress[chainId as keyof typeof optimistInviterAddress], - functionName: 'commitInvite', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimistInviterABI}__ and `functionName` set to `"initialize"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - */ -export function useOptimistInviterInitialize< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof optimistInviterAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof optimistInviterABI, - 'initialize' - >['request']['abi'], - 'initialize', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'initialize' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'initialize' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: optimistInviterABI, - address: - optimistInviterAddress[chainId as keyof typeof optimistInviterAddress], - functionName: 'initialize', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimistInviterABI}__ and `functionName` set to `"setInviteCounts"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - */ -export function useOptimistInviterSetInviteCounts< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof optimistInviterAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof optimistInviterABI, - 'setInviteCounts' - >['request']['abi'], - 'setInviteCounts', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'setInviteCounts' - } - : UseContractWriteConfig< - typeof optimistInviterABI, - 'setInviteCounts', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'setInviteCounts' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: optimistInviterABI, - address: - optimistInviterAddress[chainId as keyof typeof optimistInviterAddress], - functionName: 'setInviteCounts', - ...config, - } as any) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link optimistInviterABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - */ -export function usePrepareOptimistInviterWrite( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof optimistInviterAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: optimistInviterABI, - address: - optimistInviterAddress[chainId as keyof typeof optimistInviterAddress], - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link optimistInviterABI}__ and `functionName` set to `"claimInvite"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - */ -export function usePrepareOptimistInviterClaimInvite( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimistInviterAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: optimistInviterABI, - address: - optimistInviterAddress[chainId as keyof typeof optimistInviterAddress], - functionName: 'claimInvite', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link optimistInviterABI}__ and `functionName` set to `"commitInvite"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - */ -export function usePrepareOptimistInviterCommitInvite( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimistInviterAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: optimistInviterABI, - address: - optimistInviterAddress[chainId as keyof typeof optimistInviterAddress], - functionName: 'commitInvite', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link optimistInviterABI}__ and `functionName` set to `"initialize"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - */ -export function usePrepareOptimistInviterInitialize( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimistInviterAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: optimistInviterABI, - address: - optimistInviterAddress[chainId as keyof typeof optimistInviterAddress], - functionName: 'initialize', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link optimistInviterABI}__ and `functionName` set to `"setInviteCounts"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - */ -export function usePrepareOptimistInviterSetInviteCounts( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof optimistInviterAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: optimistInviterABI, - address: - optimistInviterAddress[chainId as keyof typeof optimistInviterAddress], - functionName: 'setInviteCounts', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link optimistInviterABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - */ -export function useOptimistInviterEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof optimistInviterAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractEvent({ - abi: optimistInviterABI, - address: - optimistInviterAddress[chainId as keyof typeof optimistInviterAddress], - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link optimistInviterABI}__ and `eventName` set to `"Initialized"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - */ -export function useOptimistInviterInitializedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof optimistInviterAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractEvent({ - abi: optimistInviterABI, - address: - optimistInviterAddress[chainId as keyof typeof optimistInviterAddress], - eventName: 'Initialized', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link optimistInviterABI}__ and `eventName` set to `"InviteClaimed"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) - */ -export function useOptimistInviterInviteClaimedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof optimistInviterAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractEvent({ - abi: optimistInviterABI, - address: - optimistInviterAddress[chainId as keyof typeof optimistInviterAddress], - eventName: 'InviteClaimed', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link portalSenderABI}__. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x0A893d9576b9cFD9EF78595963dc973238E78210) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xe7FACd39531ee3C313330E93B4d7a8B8A3c84Aa4) - */ -export function usePortalSenderRead< - TFunctionName extends string, - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof portalSenderAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: portalSenderABI, - address: portalSenderAddress[chainId as keyof typeof portalSenderAddress], - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link portalSenderABI}__ and `functionName` set to `"PORTAL"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x0A893d9576b9cFD9EF78595963dc973238E78210) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xe7FACd39531ee3C313330E93B4d7a8B8A3c84Aa4) - */ -export function usePortalSenderPortal< - TFunctionName extends 'PORTAL', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof portalSenderAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: portalSenderABI, - address: portalSenderAddress[chainId as keyof typeof portalSenderAddress], - functionName: 'PORTAL', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link portalSenderABI}__. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x0A893d9576b9cFD9EF78595963dc973238E78210) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xe7FACd39531ee3C313330E93B4d7a8B8A3c84Aa4) - */ -export function usePortalSenderWrite< - TFunctionName extends string, - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof portalSenderAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof portalSenderABI, - string - >['request']['abi'], - TFunctionName, - TMode - > & { address?: Address; chainId?: TChainId } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: portalSenderABI, - address: portalSenderAddress[chainId as keyof typeof portalSenderAddress], - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link portalSenderABI}__ and `functionName` set to `"donate"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x0A893d9576b9cFD9EF78595963dc973238E78210) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xe7FACd39531ee3C313330E93B4d7a8B8A3c84Aa4) - */ -export function usePortalSenderDonate< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof portalSenderAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof portalSenderABI, - 'donate' - >['request']['abi'], - 'donate', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'donate' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'donate' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: portalSenderABI, - address: portalSenderAddress[chainId as keyof typeof portalSenderAddress], - functionName: 'donate', - ...config, - } as any) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link portalSenderABI}__. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x0A893d9576b9cFD9EF78595963dc973238E78210) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xe7FACd39531ee3C313330E93B4d7a8B8A3c84Aa4) - */ -export function usePreparePortalSenderWrite( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof portalSenderAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: portalSenderABI, - address: portalSenderAddress[chainId as keyof typeof portalSenderAddress], - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link portalSenderABI}__ and `functionName` set to `"donate"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x0A893d9576b9cFD9EF78595963dc973238E78210) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xe7FACd39531ee3C313330E93B4d7a8B8A3c84Aa4) - */ -export function usePreparePortalSenderDonate( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof portalSenderAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: portalSenderABI, - address: portalSenderAddress[chainId as keyof typeof portalSenderAddress], - functionName: 'donate', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link protocolVersionsABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) - */ -export function useProtocolVersionsRead< - TFunctionName extends string, - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof protocolVersionsABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' - > & { chainId?: keyof typeof protocolVersionsAddress } = {} as any -) { - return useContractRead({ - abi: protocolVersionsABI, - address: protocolVersionsAddress[5], - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link protocolVersionsABI}__ and `functionName` set to `"RECOMMENDED_SLOT"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) - */ -export function useProtocolVersionsRecommendedSlot< - TFunctionName extends 'RECOMMENDED_SLOT', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof protocolVersionsABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof protocolVersionsAddress } = {} as any -) { - return useContractRead({ - abi: protocolVersionsABI, - address: protocolVersionsAddress[5], - functionName: 'RECOMMENDED_SLOT', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link protocolVersionsABI}__ and `functionName` set to `"REQUIRED_SLOT"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) - */ -export function useProtocolVersionsRequiredSlot< - TFunctionName extends 'REQUIRED_SLOT', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof protocolVersionsABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof protocolVersionsAddress } = {} as any -) { - return useContractRead({ - abi: protocolVersionsABI, - address: protocolVersionsAddress[5], - functionName: 'REQUIRED_SLOT', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link protocolVersionsABI}__ and `functionName` set to `"owner"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) - */ -export function useProtocolVersionsOwner< - TFunctionName extends 'owner', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof protocolVersionsABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof protocolVersionsAddress } = {} as any -) { - return useContractRead({ - abi: protocolVersionsABI, - address: protocolVersionsAddress[5], - functionName: 'owner', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link protocolVersionsABI}__ and `functionName` set to `"recommended"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) - */ -export function useProtocolVersionsRecommended< - TFunctionName extends 'recommended', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof protocolVersionsABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof protocolVersionsAddress } = {} as any -) { - return useContractRead({ - abi: protocolVersionsABI, - address: protocolVersionsAddress[5], - functionName: 'recommended', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link protocolVersionsABI}__ and `functionName` set to `"required"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) - */ -export function useProtocolVersionsRequired< - TFunctionName extends 'required', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof protocolVersionsABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof protocolVersionsAddress } = {} as any -) { - return useContractRead({ - abi: protocolVersionsABI, - address: protocolVersionsAddress[5], - functionName: 'required', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link protocolVersionsABI}__ and `functionName` set to `"version"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) - */ -export function useProtocolVersionsVersion< - TFunctionName extends 'version', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof protocolVersionsABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof protocolVersionsAddress } = {} as any -) { - return useContractRead({ - abi: protocolVersionsABI, - address: protocolVersionsAddress[5], - functionName: 'version', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link protocolVersionsABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) - */ -export function useProtocolVersionsWrite< - TFunctionName extends string, - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof protocolVersionsAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof protocolVersionsABI, - string - >['request']['abi'], - TFunctionName, - TMode - > & { address?: Address; chainId?: TChainId } - : UseContractWriteConfig< - typeof protocolVersionsABI, - TFunctionName, - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - } = {} as any -) { - return useContractWrite({ - abi: protocolVersionsABI, - address: protocolVersionsAddress[5], - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link protocolVersionsABI}__ and `functionName` set to `"initialize"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) - */ -export function useProtocolVersionsInitialize< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof protocolVersionsAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof protocolVersionsABI, - 'initialize' - >['request']['abi'], - 'initialize', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'initialize' } - : UseContractWriteConfig< - typeof protocolVersionsABI, - 'initialize', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'initialize' - } = {} as any -) { - return useContractWrite({ - abi: protocolVersionsABI, - address: protocolVersionsAddress[5], - functionName: 'initialize', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link protocolVersionsABI}__ and `functionName` set to `"renounceOwnership"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) - */ -export function useProtocolVersionsRenounceOwnership< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof protocolVersionsAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof protocolVersionsABI, - 'renounceOwnership' - >['request']['abi'], - 'renounceOwnership', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'renounceOwnership' - } - : UseContractWriteConfig< - typeof protocolVersionsABI, - 'renounceOwnership', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'renounceOwnership' - } = {} as any -) { - return useContractWrite< - typeof protocolVersionsABI, - 'renounceOwnership', - TMode - >({ - abi: protocolVersionsABI, - address: protocolVersionsAddress[5], - functionName: 'renounceOwnership', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link protocolVersionsABI}__ and `functionName` set to `"setRecommended"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) - */ -export function useProtocolVersionsSetRecommended< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof protocolVersionsAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof protocolVersionsABI, - 'setRecommended' - >['request']['abi'], - 'setRecommended', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'setRecommended' - } - : UseContractWriteConfig< - typeof protocolVersionsABI, - 'setRecommended', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'setRecommended' - } = {} as any -) { - return useContractWrite({ - abi: protocolVersionsABI, - address: protocolVersionsAddress[5], - functionName: 'setRecommended', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link protocolVersionsABI}__ and `functionName` set to `"setRequired"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) - */ -export function useProtocolVersionsSetRequired< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof protocolVersionsAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof protocolVersionsABI, - 'setRequired' - >['request']['abi'], - 'setRequired', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'setRequired' - } - : UseContractWriteConfig< - typeof protocolVersionsABI, - 'setRequired', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'setRequired' - } = {} as any -) { - return useContractWrite({ - abi: protocolVersionsABI, - address: protocolVersionsAddress[5], - functionName: 'setRequired', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link protocolVersionsABI}__ and `functionName` set to `"transferOwnership"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) - */ -export function useProtocolVersionsTransferOwnership< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof protocolVersionsAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof protocolVersionsABI, - 'transferOwnership' - >['request']['abi'], - 'transferOwnership', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'transferOwnership' - } - : UseContractWriteConfig< - typeof protocolVersionsABI, - 'transferOwnership', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'transferOwnership' - } = {} as any -) { - return useContractWrite< - typeof protocolVersionsABI, - 'transferOwnership', - TMode - >({ - abi: protocolVersionsABI, - address: protocolVersionsAddress[5], - functionName: 'transferOwnership', - ...config, - } as any) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link protocolVersionsABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) - */ -export function usePrepareProtocolVersionsWrite( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof protocolVersionsAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: protocolVersionsABI, - address: protocolVersionsAddress[5], - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link protocolVersionsABI}__ and `functionName` set to `"initialize"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) - */ -export function usePrepareProtocolVersionsInitialize( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof protocolVersionsAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: protocolVersionsABI, - address: protocolVersionsAddress[5], - functionName: 'initialize', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link protocolVersionsABI}__ and `functionName` set to `"renounceOwnership"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) - */ -export function usePrepareProtocolVersionsRenounceOwnership( - config: Omit< - UsePrepareContractWriteConfig< - typeof protocolVersionsABI, - 'renounceOwnership' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof protocolVersionsAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: protocolVersionsABI, - address: protocolVersionsAddress[5], - functionName: 'renounceOwnership', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link protocolVersionsABI}__ and `functionName` set to `"setRecommended"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) - */ -export function usePrepareProtocolVersionsSetRecommended( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof protocolVersionsAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: protocolVersionsABI, - address: protocolVersionsAddress[5], - functionName: 'setRecommended', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link protocolVersionsABI}__ and `functionName` set to `"setRequired"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) - */ -export function usePrepareProtocolVersionsSetRequired( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof protocolVersionsAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: protocolVersionsABI, - address: protocolVersionsAddress[5], - functionName: 'setRequired', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link protocolVersionsABI}__ and `functionName` set to `"transferOwnership"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) - */ -export function usePrepareProtocolVersionsTransferOwnership( - config: Omit< - UsePrepareContractWriteConfig< - typeof protocolVersionsABI, - 'transferOwnership' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof protocolVersionsAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: protocolVersionsABI, - address: protocolVersionsAddress[5], - functionName: 'transferOwnership', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link protocolVersionsABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) - */ -export function useProtocolVersionsEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof protocolVersionsAddress } = {} as any -) { - return useContractEvent({ - abi: protocolVersionsABI, - address: protocolVersionsAddress[5], - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link protocolVersionsABI}__ and `eventName` set to `"ConfigUpdate"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) - */ -export function useProtocolVersionsConfigUpdateEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof protocolVersionsAddress } = {} as any -) { - return useContractEvent({ - abi: protocolVersionsABI, - address: protocolVersionsAddress[5], - eventName: 'ConfigUpdate', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link protocolVersionsABI}__ and `eventName` set to `"Initialized"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) - */ -export function useProtocolVersionsInitializedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof protocolVersionsAddress } = {} as any -) { - return useContractEvent({ - abi: protocolVersionsABI, - address: protocolVersionsAddress[5], - eventName: 'Initialized', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link protocolVersionsABI}__ and `eventName` set to `"OwnershipTransferred"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) - */ -export function useProtocolVersionsOwnershipTransferredEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof protocolVersionsAddress } = {} as any -) { - return useContractEvent({ - abi: protocolVersionsABI, - address: protocolVersionsAddress[5], - eventName: 'OwnershipTransferred', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link proxyAdminABI}__. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) - */ -export function useProxyAdminRead< - TFunctionName extends string, - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof proxyAdminAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: proxyAdminABI, - address: proxyAdminAddress[chainId as keyof typeof proxyAdminAddress], - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link proxyAdminABI}__ and `functionName` set to `"addressManager"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) - */ -export function useProxyAdminAddressManager< - TFunctionName extends 'addressManager', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof proxyAdminAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: proxyAdminABI, - address: proxyAdminAddress[chainId as keyof typeof proxyAdminAddress], - functionName: 'addressManager', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link proxyAdminABI}__ and `functionName` set to `"getProxyAdmin"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) - */ -export function useProxyAdminGetProxyAdmin< - TFunctionName extends 'getProxyAdmin', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof proxyAdminAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: proxyAdminABI, - address: proxyAdminAddress[chainId as keyof typeof proxyAdminAddress], - functionName: 'getProxyAdmin', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link proxyAdminABI}__ and `functionName` set to `"getProxyImplementation"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) - */ -export function useProxyAdminGetProxyImplementation< - TFunctionName extends 'getProxyImplementation', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof proxyAdminAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: proxyAdminABI, - address: proxyAdminAddress[chainId as keyof typeof proxyAdminAddress], - functionName: 'getProxyImplementation', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link proxyAdminABI}__ and `functionName` set to `"implementationName"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) - */ -export function useProxyAdminImplementationName< - TFunctionName extends 'implementationName', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof proxyAdminAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: proxyAdminABI, - address: proxyAdminAddress[chainId as keyof typeof proxyAdminAddress], - functionName: 'implementationName', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link proxyAdminABI}__ and `functionName` set to `"isUpgrading"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) - */ -export function useProxyAdminIsUpgrading< - TFunctionName extends 'isUpgrading', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof proxyAdminAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: proxyAdminABI, - address: proxyAdminAddress[chainId as keyof typeof proxyAdminAddress], - functionName: 'isUpgrading', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link proxyAdminABI}__ and `functionName` set to `"owner"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) - */ -export function useProxyAdminOwner< - TFunctionName extends 'owner', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof proxyAdminAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: proxyAdminABI, - address: proxyAdminAddress[chainId as keyof typeof proxyAdminAddress], - functionName: 'owner', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link proxyAdminABI}__ and `functionName` set to `"proxyType"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) - */ -export function useProxyAdminProxyType< - TFunctionName extends 'proxyType', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof proxyAdminAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: proxyAdminABI, - address: proxyAdminAddress[chainId as keyof typeof proxyAdminAddress], - functionName: 'proxyType', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link proxyAdminABI}__. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) - */ -export function useProxyAdminWrite< - TFunctionName extends string, - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof proxyAdminAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof proxyAdminABI, - string - >['request']['abi'], - TFunctionName, - TMode - > & { address?: Address; chainId?: TChainId } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: proxyAdminABI, - address: proxyAdminAddress[chainId as keyof typeof proxyAdminAddress], - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link proxyAdminABI}__ and `functionName` set to `"changeProxyAdmin"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) - */ -export function useProxyAdminChangeProxyAdmin< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof proxyAdminAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof proxyAdminABI, - 'changeProxyAdmin' - >['request']['abi'], - 'changeProxyAdmin', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'changeProxyAdmin' - } - : UseContractWriteConfig< - typeof proxyAdminABI, - 'changeProxyAdmin', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'changeProxyAdmin' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: proxyAdminABI, - address: proxyAdminAddress[chainId as keyof typeof proxyAdminAddress], - functionName: 'changeProxyAdmin', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link proxyAdminABI}__ and `functionName` set to `"renounceOwnership"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) - */ -export function useProxyAdminRenounceOwnership< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof proxyAdminAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof proxyAdminABI, - 'renounceOwnership' - >['request']['abi'], - 'renounceOwnership', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'renounceOwnership' - } - : UseContractWriteConfig< - typeof proxyAdminABI, - 'renounceOwnership', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'renounceOwnership' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: proxyAdminABI, - address: proxyAdminAddress[chainId as keyof typeof proxyAdminAddress], - functionName: 'renounceOwnership', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link proxyAdminABI}__ and `functionName` set to `"setAddress"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) - */ -export function useProxyAdminSetAddress< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof proxyAdminAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof proxyAdminABI, - 'setAddress' - >['request']['abi'], - 'setAddress', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'setAddress' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'setAddress' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: proxyAdminABI, - address: proxyAdminAddress[chainId as keyof typeof proxyAdminAddress], - functionName: 'setAddress', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link proxyAdminABI}__ and `functionName` set to `"setAddressManager"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) - */ -export function useProxyAdminSetAddressManager< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof proxyAdminAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof proxyAdminABI, - 'setAddressManager' - >['request']['abi'], - 'setAddressManager', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'setAddressManager' - } - : UseContractWriteConfig< - typeof proxyAdminABI, - 'setAddressManager', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'setAddressManager' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: proxyAdminABI, - address: proxyAdminAddress[chainId as keyof typeof proxyAdminAddress], - functionName: 'setAddressManager', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link proxyAdminABI}__ and `functionName` set to `"setImplementationName"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) - */ -export function useProxyAdminSetImplementationName< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof proxyAdminAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof proxyAdminABI, - 'setImplementationName' - >['request']['abi'], - 'setImplementationName', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'setImplementationName' - } - : UseContractWriteConfig< - typeof proxyAdminABI, - 'setImplementationName', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'setImplementationName' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite( - { - abi: proxyAdminABI, - address: proxyAdminAddress[chainId as keyof typeof proxyAdminAddress], - functionName: 'setImplementationName', - ...config, - } as any - ) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link proxyAdminABI}__ and `functionName` set to `"setProxyType"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) - */ -export function useProxyAdminSetProxyType< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof proxyAdminAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof proxyAdminABI, - 'setProxyType' - >['request']['abi'], - 'setProxyType', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'setProxyType' - } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'setProxyType' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: proxyAdminABI, - address: proxyAdminAddress[chainId as keyof typeof proxyAdminAddress], - functionName: 'setProxyType', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link proxyAdminABI}__ and `functionName` set to `"setUpgrading"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) - */ -export function useProxyAdminSetUpgrading< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof proxyAdminAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof proxyAdminABI, - 'setUpgrading' - >['request']['abi'], - 'setUpgrading', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'setUpgrading' - } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'setUpgrading' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: proxyAdminABI, - address: proxyAdminAddress[chainId as keyof typeof proxyAdminAddress], - functionName: 'setUpgrading', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link proxyAdminABI}__ and `functionName` set to `"transferOwnership"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) - */ -export function useProxyAdminTransferOwnership< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof proxyAdminAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof proxyAdminABI, - 'transferOwnership' - >['request']['abi'], - 'transferOwnership', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'transferOwnership' - } - : UseContractWriteConfig< - typeof proxyAdminABI, - 'transferOwnership', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'transferOwnership' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: proxyAdminABI, - address: proxyAdminAddress[chainId as keyof typeof proxyAdminAddress], - functionName: 'transferOwnership', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link proxyAdminABI}__ and `functionName` set to `"upgrade"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) - */ -export function useProxyAdminUpgrade< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof proxyAdminAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof proxyAdminABI, - 'upgrade' - >['request']['abi'], - 'upgrade', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'upgrade' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'upgrade' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: proxyAdminABI, - address: proxyAdminAddress[chainId as keyof typeof proxyAdminAddress], - functionName: 'upgrade', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link proxyAdminABI}__ and `functionName` set to `"upgradeAndCall"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) - */ -export function useProxyAdminUpgradeAndCall< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof proxyAdminAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof proxyAdminABI, - 'upgradeAndCall' - >['request']['abi'], - 'upgradeAndCall', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'upgradeAndCall' - } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'upgradeAndCall' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: proxyAdminABI, - address: proxyAdminAddress[chainId as keyof typeof proxyAdminAddress], - functionName: 'upgradeAndCall', - ...config, - } as any) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link proxyAdminABI}__. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) - */ -export function usePrepareProxyAdminWrite( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof proxyAdminAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: proxyAdminABI, - address: proxyAdminAddress[chainId as keyof typeof proxyAdminAddress], - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link proxyAdminABI}__ and `functionName` set to `"changeProxyAdmin"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) - */ -export function usePrepareProxyAdminChangeProxyAdmin( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof proxyAdminAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: proxyAdminABI, - address: proxyAdminAddress[chainId as keyof typeof proxyAdminAddress], - functionName: 'changeProxyAdmin', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link proxyAdminABI}__ and `functionName` set to `"renounceOwnership"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) - */ -export function usePrepareProxyAdminRenounceOwnership( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof proxyAdminAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: proxyAdminABI, - address: proxyAdminAddress[chainId as keyof typeof proxyAdminAddress], - functionName: 'renounceOwnership', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link proxyAdminABI}__ and `functionName` set to `"setAddress"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) - */ -export function usePrepareProxyAdminSetAddress( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof proxyAdminAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: proxyAdminABI, - address: proxyAdminAddress[chainId as keyof typeof proxyAdminAddress], - functionName: 'setAddress', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link proxyAdminABI}__ and `functionName` set to `"setAddressManager"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) - */ -export function usePrepareProxyAdminSetAddressManager( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof proxyAdminAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: proxyAdminABI, - address: proxyAdminAddress[chainId as keyof typeof proxyAdminAddress], - functionName: 'setAddressManager', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link proxyAdminABI}__ and `functionName` set to `"setImplementationName"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) - */ -export function usePrepareProxyAdminSetImplementationName( - config: Omit< - UsePrepareContractWriteConfig< - typeof proxyAdminABI, - 'setImplementationName' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof proxyAdminAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: proxyAdminABI, - address: proxyAdminAddress[chainId as keyof typeof proxyAdminAddress], - functionName: 'setImplementationName', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link proxyAdminABI}__ and `functionName` set to `"setProxyType"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) - */ -export function usePrepareProxyAdminSetProxyType( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof proxyAdminAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: proxyAdminABI, - address: proxyAdminAddress[chainId as keyof typeof proxyAdminAddress], - functionName: 'setProxyType', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link proxyAdminABI}__ and `functionName` set to `"setUpgrading"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) - */ -export function usePrepareProxyAdminSetUpgrading( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof proxyAdminAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: proxyAdminABI, - address: proxyAdminAddress[chainId as keyof typeof proxyAdminAddress], - functionName: 'setUpgrading', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link proxyAdminABI}__ and `functionName` set to `"transferOwnership"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) - */ -export function usePrepareProxyAdminTransferOwnership( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof proxyAdminAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: proxyAdminABI, - address: proxyAdminAddress[chainId as keyof typeof proxyAdminAddress], - functionName: 'transferOwnership', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link proxyAdminABI}__ and `functionName` set to `"upgrade"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) - */ -export function usePrepareProxyAdminUpgrade( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof proxyAdminAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: proxyAdminABI, - address: proxyAdminAddress[chainId as keyof typeof proxyAdminAddress], - functionName: 'upgrade', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link proxyAdminABI}__ and `functionName` set to `"upgradeAndCall"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) - */ -export function usePrepareProxyAdminUpgradeAndCall( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof proxyAdminAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: proxyAdminABI, - address: proxyAdminAddress[chainId as keyof typeof proxyAdminAddress], - functionName: 'upgradeAndCall', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link proxyAdminABI}__. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) - */ -export function useProxyAdminEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof proxyAdminAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractEvent({ - abi: proxyAdminABI, - address: proxyAdminAddress[chainId as keyof typeof proxyAdminAddress], - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link proxyAdminABI}__ and `eventName` set to `"OwnershipTransferred"`. - * - * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) - * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) - */ -export function useProxyAdminOwnershipTransferredEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof proxyAdminAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractEvent({ - abi: proxyAdminABI, - address: proxyAdminAddress[chainId as keyof typeof proxyAdminAddress], - eventName: 'OwnershipTransferred', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link schemaRegistryABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x6232208d66bAc2305b46b4Cb6BCB3857B298DF13) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2545fa928d5d278cA75Fd47306e4a89096ff6403) - */ -export function useSchemaRegistryRead< - TFunctionName extends string, - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof schemaRegistryAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: schemaRegistryABI, - address: - schemaRegistryAddress[chainId as keyof typeof schemaRegistryAddress], - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link schemaRegistryABI}__ and `functionName` set to `"getSchema"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x6232208d66bAc2305b46b4Cb6BCB3857B298DF13) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2545fa928d5d278cA75Fd47306e4a89096ff6403) - */ -export function useSchemaRegistryGetSchema< - TFunctionName extends 'getSchema', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof schemaRegistryAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: schemaRegistryABI, - address: - schemaRegistryAddress[chainId as keyof typeof schemaRegistryAddress], - functionName: 'getSchema', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link schemaRegistryABI}__ and `functionName` set to `"version"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x6232208d66bAc2305b46b4Cb6BCB3857B298DF13) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2545fa928d5d278cA75Fd47306e4a89096ff6403) - */ -export function useSchemaRegistryVersion< - TFunctionName extends 'version', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof schemaRegistryAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractRead({ - abi: schemaRegistryABI, - address: - schemaRegistryAddress[chainId as keyof typeof schemaRegistryAddress], - functionName: 'version', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link schemaRegistryABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x6232208d66bAc2305b46b4Cb6BCB3857B298DF13) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2545fa928d5d278cA75Fd47306e4a89096ff6403) - */ -export function useSchemaRegistryWrite< - TFunctionName extends string, - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof schemaRegistryAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof schemaRegistryABI, - string - >['request']['abi'], - TFunctionName, - TMode - > & { address?: Address; chainId?: TChainId } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: schemaRegistryABI, - address: - schemaRegistryAddress[chainId as keyof typeof schemaRegistryAddress], - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link schemaRegistryABI}__ and `functionName` set to `"register"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x6232208d66bAc2305b46b4Cb6BCB3857B298DF13) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2545fa928d5d278cA75Fd47306e4a89096ff6403) - */ -export function useSchemaRegistryRegister< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof schemaRegistryAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof schemaRegistryABI, - 'register' - >['request']['abi'], - 'register', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'register' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'register' - } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractWrite({ - abi: schemaRegistryABI, - address: - schemaRegistryAddress[chainId as keyof typeof schemaRegistryAddress], - functionName: 'register', - ...config, - } as any) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link schemaRegistryABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x6232208d66bAc2305b46b4Cb6BCB3857B298DF13) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2545fa928d5d278cA75Fd47306e4a89096ff6403) - */ -export function usePrepareSchemaRegistryWrite( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof schemaRegistryAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: schemaRegistryABI, - address: - schemaRegistryAddress[chainId as keyof typeof schemaRegistryAddress], - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link schemaRegistryABI}__ and `functionName` set to `"register"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x6232208d66bAc2305b46b4Cb6BCB3857B298DF13) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2545fa928d5d278cA75Fd47306e4a89096ff6403) - */ -export function usePrepareSchemaRegistryRegister( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof schemaRegistryAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return usePrepareContractWrite({ - abi: schemaRegistryABI, - address: - schemaRegistryAddress[chainId as keyof typeof schemaRegistryAddress], - functionName: 'register', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link schemaRegistryABI}__. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x6232208d66bAc2305b46b4Cb6BCB3857B298DF13) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2545fa928d5d278cA75Fd47306e4a89096ff6403) - */ -export function useSchemaRegistryEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof schemaRegistryAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractEvent({ - abi: schemaRegistryABI, - address: - schemaRegistryAddress[chainId as keyof typeof schemaRegistryAddress], - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link schemaRegistryABI}__ and `eventName` set to `"Registered"`. - * - * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x6232208d66bAc2305b46b4Cb6BCB3857B298DF13) - * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2545fa928d5d278cA75Fd47306e4a89096ff6403) - */ -export function useSchemaRegistryRegisteredEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof schemaRegistryAddress } = {} as any -) { - const { chain } = useNetwork() - const defaultChainId = useChainId() - const chainId = config.chainId ?? chain?.id ?? defaultChainId - return useContractEvent({ - abi: schemaRegistryABI, - address: - schemaRegistryAddress[chainId as keyof typeof schemaRegistryAddress], - eventName: 'Registered', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link sequencerFeeVaultABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000011) - */ -export function useSequencerFeeVaultRead< - TFunctionName extends string, - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof sequencerFeeVaultABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' - > & { chainId?: keyof typeof sequencerFeeVaultAddress } = {} as any -) { - return useContractRead({ - abi: sequencerFeeVaultABI, - address: sequencerFeeVaultAddress[420], - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link sequencerFeeVaultABI}__ and `functionName` set to `"MIN_WITHDRAWAL_AMOUNT"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000011) - */ -export function useSequencerFeeVaultMinWithdrawalAmount< - TFunctionName extends 'MIN_WITHDRAWAL_AMOUNT', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof sequencerFeeVaultABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof sequencerFeeVaultAddress } = {} as any -) { - return useContractRead({ - abi: sequencerFeeVaultABI, - address: sequencerFeeVaultAddress[420], - functionName: 'MIN_WITHDRAWAL_AMOUNT', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link sequencerFeeVaultABI}__ and `functionName` set to `"RECIPIENT"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000011) - */ -export function useSequencerFeeVaultRecipient< - TFunctionName extends 'RECIPIENT', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof sequencerFeeVaultABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof sequencerFeeVaultAddress } = {} as any -) { - return useContractRead({ - abi: sequencerFeeVaultABI, - address: sequencerFeeVaultAddress[420], - functionName: 'RECIPIENT', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link sequencerFeeVaultABI}__ and `functionName` set to `"l1FeeWallet"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000011) - */ -export function useSequencerFeeVaultL1FeeWallet< - TFunctionName extends 'l1FeeWallet', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof sequencerFeeVaultABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof sequencerFeeVaultAddress } = {} as any -) { - return useContractRead({ - abi: sequencerFeeVaultABI, - address: sequencerFeeVaultAddress[420], - functionName: 'l1FeeWallet', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link sequencerFeeVaultABI}__ and `functionName` set to `"totalProcessed"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000011) - */ -export function useSequencerFeeVaultTotalProcessed< - TFunctionName extends 'totalProcessed', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof sequencerFeeVaultABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof sequencerFeeVaultAddress } = {} as any -) { - return useContractRead({ - abi: sequencerFeeVaultABI, - address: sequencerFeeVaultAddress[420], - functionName: 'totalProcessed', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link sequencerFeeVaultABI}__ and `functionName` set to `"version"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000011) - */ -export function useSequencerFeeVaultVersion< - TFunctionName extends 'version', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof sequencerFeeVaultABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof sequencerFeeVaultAddress } = {} as any -) { - return useContractRead({ - abi: sequencerFeeVaultABI, - address: sequencerFeeVaultAddress[420], - functionName: 'version', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link sequencerFeeVaultABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000011) - */ -export function useSequencerFeeVaultWrite< - TFunctionName extends string, - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof sequencerFeeVaultAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof sequencerFeeVaultABI, - string - >['request']['abi'], - TFunctionName, - TMode - > & { address?: Address; chainId?: TChainId } - : UseContractWriteConfig< - typeof sequencerFeeVaultABI, - TFunctionName, - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - } = {} as any -) { - return useContractWrite({ - abi: sequencerFeeVaultABI, - address: sequencerFeeVaultAddress[420], - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link sequencerFeeVaultABI}__ and `functionName` set to `"withdraw"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000011) - */ -export function useSequencerFeeVaultWithdraw< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof sequencerFeeVaultAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof sequencerFeeVaultABI, - 'withdraw' - >['request']['abi'], - 'withdraw', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'withdraw' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'withdraw' - } = {} as any -) { - return useContractWrite({ - abi: sequencerFeeVaultABI, - address: sequencerFeeVaultAddress[420], - functionName: 'withdraw', - ...config, - } as any) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link sequencerFeeVaultABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000011) - */ -export function usePrepareSequencerFeeVaultWrite( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof sequencerFeeVaultAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: sequencerFeeVaultABI, - address: sequencerFeeVaultAddress[420], - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link sequencerFeeVaultABI}__ and `functionName` set to `"withdraw"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000011) - */ -export function usePrepareSequencerFeeVaultWithdraw( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof sequencerFeeVaultAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: sequencerFeeVaultABI, - address: sequencerFeeVaultAddress[420], - functionName: 'withdraw', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link sequencerFeeVaultABI}__. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000011) - */ -export function useSequencerFeeVaultEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof sequencerFeeVaultAddress } = {} as any -) { - return useContractEvent({ - abi: sequencerFeeVaultABI, - address: sequencerFeeVaultAddress[420], - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link sequencerFeeVaultABI}__ and `eventName` set to `"Withdrawal"`. - * - * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000011) - */ -export function useSequencerFeeVaultWithdrawalEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof sequencerFeeVaultAddress } = {} as any -) { - return useContractEvent({ - abi: sequencerFeeVaultABI, - address: sequencerFeeVaultAddress[420], - eventName: 'Withdrawal', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemConfigABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) - */ -export function useSystemConfigRead< - TFunctionName extends string, - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof systemConfigAddress } = {} as any -) { - return useContractRead({ - abi: systemConfigABI, - address: systemConfigAddress[1], - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemConfigABI}__ and `functionName` set to `"UNSAFE_BLOCK_SIGNER_SLOT"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) - */ -export function useSystemConfigUnsafeBlockSignerSlot< - TFunctionName extends 'UNSAFE_BLOCK_SIGNER_SLOT', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigAddress } = {} as any -) { - return useContractRead({ - abi: systemConfigABI, - address: systemConfigAddress[1], - functionName: 'UNSAFE_BLOCK_SIGNER_SLOT', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemConfigABI}__ and `functionName` set to `"batcherHash"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) - */ -export function useSystemConfigBatcherHash< - TFunctionName extends 'batcherHash', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigAddress } = {} as any -) { - return useContractRead({ - abi: systemConfigABI, - address: systemConfigAddress[1], - functionName: 'batcherHash', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemConfigABI}__ and `functionName` set to `"gasLimit"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) - */ -export function useSystemConfigGasLimit< - TFunctionName extends 'gasLimit', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigAddress } = {} as any -) { - return useContractRead({ - abi: systemConfigABI, - address: systemConfigAddress[1], - functionName: 'gasLimit', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemConfigABI}__ and `functionName` set to `"minimumGasLimit"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) - */ -export function useSystemConfigMinimumGasLimit< - TFunctionName extends 'minimumGasLimit', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigAddress } = {} as any -) { - return useContractRead({ - abi: systemConfigABI, - address: systemConfigAddress[1], - functionName: 'minimumGasLimit', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemConfigABI}__ and `functionName` set to `"overhead"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) - */ -export function useSystemConfigOverhead< - TFunctionName extends 'overhead', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigAddress } = {} as any -) { - return useContractRead({ - abi: systemConfigABI, - address: systemConfigAddress[1], - functionName: 'overhead', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemConfigABI}__ and `functionName` set to `"owner"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) - */ -export function useSystemConfigOwner< - TFunctionName extends 'owner', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigAddress } = {} as any -) { - return useContractRead({ - abi: systemConfigABI, - address: systemConfigAddress[1], - functionName: 'owner', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemConfigABI}__ and `functionName` set to `"resourceConfig"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) - */ -export function useSystemConfigResourceConfig< - TFunctionName extends 'resourceConfig', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigAddress } = {} as any -) { - return useContractRead({ - abi: systemConfigABI, - address: systemConfigAddress[1], - functionName: 'resourceConfig', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemConfigABI}__ and `functionName` set to `"scalar"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) - */ -export function useSystemConfigScalar< - TFunctionName extends 'scalar', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigAddress } = {} as any -) { - return useContractRead({ - abi: systemConfigABI, - address: systemConfigAddress[1], - functionName: 'scalar', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemConfigABI}__ and `functionName` set to `"unsafeBlockSigner"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) - */ -export function useSystemConfigUnsafeBlockSigner< - TFunctionName extends 'unsafeBlockSigner', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigAddress } = {} as any -) { - return useContractRead({ - abi: systemConfigABI, - address: systemConfigAddress[1], - functionName: 'unsafeBlockSigner', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemConfigABI}__ and `functionName` set to `"version"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) - */ -export function useSystemConfigVersion< - TFunctionName extends 'version', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigAddress } = {} as any -) { - return useContractRead({ - abi: systemConfigABI, - address: systemConfigAddress[1], - functionName: 'version', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemConfigABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) - */ -export function useSystemConfigWrite< - TFunctionName extends string, - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof systemConfigAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof systemConfigABI, - string - >['request']['abi'], - TFunctionName, - TMode - > & { address?: Address; chainId?: TChainId } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - } = {} as any -) { - return useContractWrite({ - abi: systemConfigABI, - address: systemConfigAddress[1], - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemConfigABI}__ and `functionName` set to `"initialize"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) - */ -export function useSystemConfigInitialize< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof systemConfigAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof systemConfigABI, - 'initialize' - >['request']['abi'], - 'initialize', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'initialize' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'initialize' - } = {} as any -) { - return useContractWrite({ - abi: systemConfigABI, - address: systemConfigAddress[1], - functionName: 'initialize', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemConfigABI}__ and `functionName` set to `"renounceOwnership"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) - */ -export function useSystemConfigRenounceOwnership< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof systemConfigAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof systemConfigABI, - 'renounceOwnership' - >['request']['abi'], - 'renounceOwnership', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'renounceOwnership' - } - : UseContractWriteConfig< - typeof systemConfigABI, - 'renounceOwnership', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'renounceOwnership' - } = {} as any -) { - return useContractWrite({ - abi: systemConfigABI, - address: systemConfigAddress[1], - functionName: 'renounceOwnership', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemConfigABI}__ and `functionName` set to `"setBatcherHash"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) - */ -export function useSystemConfigSetBatcherHash< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof systemConfigAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof systemConfigABI, - 'setBatcherHash' - >['request']['abi'], - 'setBatcherHash', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'setBatcherHash' - } - : UseContractWriteConfig< - typeof systemConfigABI, - 'setBatcherHash', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'setBatcherHash' - } = {} as any -) { - return useContractWrite({ - abi: systemConfigABI, - address: systemConfigAddress[1], - functionName: 'setBatcherHash', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemConfigABI}__ and `functionName` set to `"setGasConfig"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) - */ -export function useSystemConfigSetGasConfig< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof systemConfigAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof systemConfigABI, - 'setGasConfig' - >['request']['abi'], - 'setGasConfig', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'setGasConfig' - } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'setGasConfig' - } = {} as any -) { - return useContractWrite({ - abi: systemConfigABI, - address: systemConfigAddress[1], - functionName: 'setGasConfig', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemConfigABI}__ and `functionName` set to `"setGasLimit"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) - */ -export function useSystemConfigSetGasLimit< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof systemConfigAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof systemConfigABI, - 'setGasLimit' - >['request']['abi'], - 'setGasLimit', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'setGasLimit' - } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'setGasLimit' - } = {} as any -) { - return useContractWrite({ - abi: systemConfigABI, - address: systemConfigAddress[1], - functionName: 'setGasLimit', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemConfigABI}__ and `functionName` set to `"setResourceConfig"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) - */ -export function useSystemConfigSetResourceConfig< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof systemConfigAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof systemConfigABI, - 'setResourceConfig' - >['request']['abi'], - 'setResourceConfig', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'setResourceConfig' - } - : UseContractWriteConfig< - typeof systemConfigABI, - 'setResourceConfig', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'setResourceConfig' - } = {} as any -) { - return useContractWrite({ - abi: systemConfigABI, - address: systemConfigAddress[1], - functionName: 'setResourceConfig', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemConfigABI}__ and `functionName` set to `"setUnsafeBlockSigner"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) - */ -export function useSystemConfigSetUnsafeBlockSigner< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof systemConfigAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof systemConfigABI, - 'setUnsafeBlockSigner' - >['request']['abi'], - 'setUnsafeBlockSigner', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'setUnsafeBlockSigner' - } - : UseContractWriteConfig< - typeof systemConfigABI, - 'setUnsafeBlockSigner', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'setUnsafeBlockSigner' - } = {} as any -) { - return useContractWrite< - typeof systemConfigABI, - 'setUnsafeBlockSigner', - TMode - >({ - abi: systemConfigABI, - address: systemConfigAddress[1], - functionName: 'setUnsafeBlockSigner', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemConfigABI}__ and `functionName` set to `"transferOwnership"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) - */ -export function useSystemConfigTransferOwnership< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof systemConfigAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof systemConfigABI, - 'transferOwnership' - >['request']['abi'], - 'transferOwnership', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'transferOwnership' - } - : UseContractWriteConfig< - typeof systemConfigABI, - 'transferOwnership', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'transferOwnership' - } = {} as any -) { - return useContractWrite({ - abi: systemConfigABI, - address: systemConfigAddress[1], - functionName: 'transferOwnership', - ...config, - } as any) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link systemConfigABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) - */ -export function usePrepareSystemConfigWrite( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof systemConfigAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: systemConfigABI, - address: systemConfigAddress[1], - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link systemConfigABI}__ and `functionName` set to `"initialize"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) - */ -export function usePrepareSystemConfigInitialize( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: systemConfigABI, - address: systemConfigAddress[1], - functionName: 'initialize', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link systemConfigABI}__ and `functionName` set to `"renounceOwnership"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) - */ -export function usePrepareSystemConfigRenounceOwnership( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: systemConfigABI, - address: systemConfigAddress[1], - functionName: 'renounceOwnership', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link systemConfigABI}__ and `functionName` set to `"setBatcherHash"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) - */ -export function usePrepareSystemConfigSetBatcherHash( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: systemConfigABI, - address: systemConfigAddress[1], - functionName: 'setBatcherHash', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link systemConfigABI}__ and `functionName` set to `"setGasConfig"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) - */ -export function usePrepareSystemConfigSetGasConfig( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: systemConfigABI, - address: systemConfigAddress[1], - functionName: 'setGasConfig', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link systemConfigABI}__ and `functionName` set to `"setGasLimit"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) - */ -export function usePrepareSystemConfigSetGasLimit( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: systemConfigABI, - address: systemConfigAddress[1], - functionName: 'setGasLimit', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link systemConfigABI}__ and `functionName` set to `"setResourceConfig"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) - */ -export function usePrepareSystemConfigSetResourceConfig( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: systemConfigABI, - address: systemConfigAddress[1], - functionName: 'setResourceConfig', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link systemConfigABI}__ and `functionName` set to `"setUnsafeBlockSigner"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) - */ -export function usePrepareSystemConfigSetUnsafeBlockSigner( - config: Omit< - UsePrepareContractWriteConfig< - typeof systemConfigABI, - 'setUnsafeBlockSigner' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: systemConfigABI, - address: systemConfigAddress[1], - functionName: 'setUnsafeBlockSigner', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link systemConfigABI}__ and `functionName` set to `"transferOwnership"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) - */ -export function usePrepareSystemConfigTransferOwnership( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: systemConfigABI, - address: systemConfigAddress[1], - functionName: 'transferOwnership', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link systemConfigABI}__. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) - */ -export function useSystemConfigEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof systemConfigAddress } = {} as any -) { - return useContractEvent({ - abi: systemConfigABI, - address: systemConfigAddress[1], - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link systemConfigABI}__ and `eventName` set to `"ConfigUpdate"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) - */ -export function useSystemConfigConfigUpdateEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof systemConfigAddress } = {} as any -) { - return useContractEvent({ - abi: systemConfigABI, - address: systemConfigAddress[1], - eventName: 'ConfigUpdate', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link systemConfigABI}__ and `eventName` set to `"Initialized"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) - */ -export function useSystemConfigInitializedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof systemConfigAddress } = {} as any -) { - return useContractEvent({ - abi: systemConfigABI, - address: systemConfigAddress[1], - eventName: 'Initialized', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link systemConfigABI}__ and `eventName` set to `"OwnershipTransferred"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) - */ -export function useSystemConfigOwnershipTransferredEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof systemConfigAddress } = {} as any -) { - return useContractEvent({ - abi: systemConfigABI, - address: systemConfigAddress[1], - eventName: 'OwnershipTransferred', - ...config, - } as UseContractEventConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemConfigGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export function useSystemConfigGoerliRead< - TFunctionName extends string, - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof systemConfigGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' - > & { chainId?: keyof typeof systemConfigGoerliAddress } = {} as any -) { - return useContractRead({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemConfigGoerliABI}__ and `functionName` set to `"BATCH_INBOX_SLOT"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export function useSystemConfigGoerliBatchInboxSlot< - TFunctionName extends 'BATCH_INBOX_SLOT', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof systemConfigGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigGoerliAddress } = {} as any -) { - return useContractRead({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - functionName: 'BATCH_INBOX_SLOT', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemConfigGoerliABI}__ and `functionName` set to `"L1_CROSS_DOMAIN_MESSENGER_SLOT"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export function useSystemConfigGoerliL1CrossDomainMessengerSlot< - TFunctionName extends 'L1_CROSS_DOMAIN_MESSENGER_SLOT', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof systemConfigGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigGoerliAddress } = {} as any -) { - return useContractRead({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - functionName: 'L1_CROSS_DOMAIN_MESSENGER_SLOT', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemConfigGoerliABI}__ and `functionName` set to `"L1_ERC_721_BRIDGE_SLOT"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export function useSystemConfigGoerliL1Erc_721BridgeSlot< - TFunctionName extends 'L1_ERC_721_BRIDGE_SLOT', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof systemConfigGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigGoerliAddress } = {} as any -) { - return useContractRead({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - functionName: 'L1_ERC_721_BRIDGE_SLOT', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemConfigGoerliABI}__ and `functionName` set to `"L1_STANDARD_BRIDGE_SLOT"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export function useSystemConfigGoerliL1StandardBridgeSlot< - TFunctionName extends 'L1_STANDARD_BRIDGE_SLOT', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof systemConfigGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigGoerliAddress } = {} as any -) { - return useContractRead({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - functionName: 'L1_STANDARD_BRIDGE_SLOT', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemConfigGoerliABI}__ and `functionName` set to `"L2_OUTPUT_ORACLE_SLOT"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export function useSystemConfigGoerliL2OutputOracleSlot< - TFunctionName extends 'L2_OUTPUT_ORACLE_SLOT', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof systemConfigGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigGoerliAddress } = {} as any -) { - return useContractRead({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - functionName: 'L2_OUTPUT_ORACLE_SLOT', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemConfigGoerliABI}__ and `functionName` set to `"OPTIMISM_MINTABLE_ERC20_FACTORY_SLOT"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export function useSystemConfigGoerliOptimismMintableErc20FactorySlot< - TFunctionName extends 'OPTIMISM_MINTABLE_ERC20_FACTORY_SLOT', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof systemConfigGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigGoerliAddress } = {} as any -) { - return useContractRead({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - functionName: 'OPTIMISM_MINTABLE_ERC20_FACTORY_SLOT', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemConfigGoerliABI}__ and `functionName` set to `"OPTIMISM_PORTAL_SLOT"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export function useSystemConfigGoerliOptimismPortalSlot< - TFunctionName extends 'OPTIMISM_PORTAL_SLOT', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof systemConfigGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigGoerliAddress } = {} as any -) { - return useContractRead({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - functionName: 'OPTIMISM_PORTAL_SLOT', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemConfigGoerliABI}__ and `functionName` set to `"UNSAFE_BLOCK_SIGNER_SLOT"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export function useSystemConfigGoerliUnsafeBlockSignerSlot< - TFunctionName extends 'UNSAFE_BLOCK_SIGNER_SLOT', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof systemConfigGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigGoerliAddress } = {} as any -) { - return useContractRead({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - functionName: 'UNSAFE_BLOCK_SIGNER_SLOT', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemConfigGoerliABI}__ and `functionName` set to `"batchInbox"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export function useSystemConfigGoerliBatchInbox< - TFunctionName extends 'batchInbox', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof systemConfigGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigGoerliAddress } = {} as any -) { - return useContractRead({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - functionName: 'batchInbox', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemConfigGoerliABI}__ and `functionName` set to `"batcherHash"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export function useSystemConfigGoerliBatcherHash< - TFunctionName extends 'batcherHash', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof systemConfigGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigGoerliAddress } = {} as any -) { - return useContractRead({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - functionName: 'batcherHash', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemConfigGoerliABI}__ and `functionName` set to `"gasLimit"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export function useSystemConfigGoerliGasLimit< - TFunctionName extends 'gasLimit', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof systemConfigGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigGoerliAddress } = {} as any -) { - return useContractRead({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - functionName: 'gasLimit', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemConfigGoerliABI}__ and `functionName` set to `"l1CrossDomainMessenger"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export function useSystemConfigGoerliL1CrossDomainMessenger< - TFunctionName extends 'l1CrossDomainMessenger', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof systemConfigGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigGoerliAddress } = {} as any -) { - return useContractRead({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - functionName: 'l1CrossDomainMessenger', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemConfigGoerliABI}__ and `functionName` set to `"l1ERC721Bridge"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export function useSystemConfigGoerliL1Erc721Bridge< - TFunctionName extends 'l1ERC721Bridge', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof systemConfigGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigGoerliAddress } = {} as any -) { - return useContractRead({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - functionName: 'l1ERC721Bridge', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemConfigGoerliABI}__ and `functionName` set to `"l1StandardBridge"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export function useSystemConfigGoerliL1StandardBridge< - TFunctionName extends 'l1StandardBridge', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof systemConfigGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigGoerliAddress } = {} as any -) { - return useContractRead({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - functionName: 'l1StandardBridge', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemConfigGoerliABI}__ and `functionName` set to `"l2OutputOracle"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export function useSystemConfigGoerliL2OutputOracle< - TFunctionName extends 'l2OutputOracle', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof systemConfigGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigGoerliAddress } = {} as any -) { - return useContractRead({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - functionName: 'l2OutputOracle', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemConfigGoerliABI}__ and `functionName` set to `"minimumGasLimit"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export function useSystemConfigGoerliMinimumGasLimit< - TFunctionName extends 'minimumGasLimit', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof systemConfigGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigGoerliAddress } = {} as any -) { - return useContractRead({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - functionName: 'minimumGasLimit', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemConfigGoerliABI}__ and `functionName` set to `"optimismMintableERC20Factory"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export function useSystemConfigGoerliOptimismMintableErc20Factory< - TFunctionName extends 'optimismMintableERC20Factory', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof systemConfigGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigGoerliAddress } = {} as any -) { - return useContractRead({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - functionName: 'optimismMintableERC20Factory', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemConfigGoerliABI}__ and `functionName` set to `"optimismPortal"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export function useSystemConfigGoerliOptimismPortal< - TFunctionName extends 'optimismPortal', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof systemConfigGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigGoerliAddress } = {} as any -) { - return useContractRead({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - functionName: 'optimismPortal', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemConfigGoerliABI}__ and `functionName` set to `"overhead"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export function useSystemConfigGoerliOverhead< - TFunctionName extends 'overhead', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof systemConfigGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigGoerliAddress } = {} as any -) { - return useContractRead({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - functionName: 'overhead', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemConfigGoerliABI}__ and `functionName` set to `"owner"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export function useSystemConfigGoerliOwner< - TFunctionName extends 'owner', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof systemConfigGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigGoerliAddress } = {} as any -) { - return useContractRead({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - functionName: 'owner', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemConfigGoerliABI}__ and `functionName` set to `"resourceConfig"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export function useSystemConfigGoerliResourceConfig< - TFunctionName extends 'resourceConfig', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof systemConfigGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigGoerliAddress } = {} as any -) { - return useContractRead({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - functionName: 'resourceConfig', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemConfigGoerliABI}__ and `functionName` set to `"scalar"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export function useSystemConfigGoerliScalar< - TFunctionName extends 'scalar', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof systemConfigGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigGoerliAddress } = {} as any -) { - return useContractRead({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - functionName: 'scalar', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemConfigGoerliABI}__ and `functionName` set to `"startBlock"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export function useSystemConfigGoerliStartBlock< - TFunctionName extends 'startBlock', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof systemConfigGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigGoerliAddress } = {} as any -) { - return useContractRead({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - functionName: 'startBlock', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemConfigGoerliABI}__ and `functionName` set to `"unsafeBlockSigner"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export function useSystemConfigGoerliUnsafeBlockSigner< - TFunctionName extends 'unsafeBlockSigner', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof systemConfigGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigGoerliAddress } = {} as any -) { - return useContractRead({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - functionName: 'unsafeBlockSigner', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemConfigGoerliABI}__ and `functionName` set to `"version"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export function useSystemConfigGoerliVersion< - TFunctionName extends 'version', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig< - typeof systemConfigGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigGoerliAddress } = {} as any -) { - return useContractRead({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - functionName: 'version', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemConfigGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export function useSystemConfigGoerliWrite< - TFunctionName extends string, - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof systemConfigGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof systemConfigGoerliABI, - string - >['request']['abi'], - TFunctionName, - TMode - > & { address?: Address; chainId?: TChainId } - : UseContractWriteConfig< - typeof systemConfigGoerliABI, - TFunctionName, - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - } = {} as any -) { - return useContractWrite({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemConfigGoerliABI}__ and `functionName` set to `"initialize"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export function useSystemConfigGoerliInitialize< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof systemConfigGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof systemConfigGoerliABI, - 'initialize' - >['request']['abi'], - 'initialize', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'initialize' } - : UseContractWriteConfig< - typeof systemConfigGoerliABI, - 'initialize', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'initialize' - } = {} as any -) { - return useContractWrite({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - functionName: 'initialize', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemConfigGoerliABI}__ and `functionName` set to `"renounceOwnership"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export function useSystemConfigGoerliRenounceOwnership< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof systemConfigGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof systemConfigGoerliABI, - 'renounceOwnership' - >['request']['abi'], - 'renounceOwnership', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'renounceOwnership' - } - : UseContractWriteConfig< - typeof systemConfigGoerliABI, - 'renounceOwnership', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'renounceOwnership' - } = {} as any -) { - return useContractWrite< - typeof systemConfigGoerliABI, - 'renounceOwnership', - TMode - >({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - functionName: 'renounceOwnership', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemConfigGoerliABI}__ and `functionName` set to `"setBatcherHash"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export function useSystemConfigGoerliSetBatcherHash< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof systemConfigGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof systemConfigGoerliABI, - 'setBatcherHash' - >['request']['abi'], - 'setBatcherHash', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'setBatcherHash' - } - : UseContractWriteConfig< - typeof systemConfigGoerliABI, - 'setBatcherHash', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'setBatcherHash' - } = {} as any -) { - return useContractWrite< - typeof systemConfigGoerliABI, - 'setBatcherHash', - TMode - >({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - functionName: 'setBatcherHash', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemConfigGoerliABI}__ and `functionName` set to `"setGasConfig"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export function useSystemConfigGoerliSetGasConfig< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof systemConfigGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof systemConfigGoerliABI, - 'setGasConfig' - >['request']['abi'], - 'setGasConfig', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'setGasConfig' - } - : UseContractWriteConfig< - typeof systemConfigGoerliABI, - 'setGasConfig', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'setGasConfig' - } = {} as any -) { - return useContractWrite({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - functionName: 'setGasConfig', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemConfigGoerliABI}__ and `functionName` set to `"setGasLimit"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export function useSystemConfigGoerliSetGasLimit< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof systemConfigGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof systemConfigGoerliABI, - 'setGasLimit' - >['request']['abi'], - 'setGasLimit', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'setGasLimit' - } - : UseContractWriteConfig< - typeof systemConfigGoerliABI, - 'setGasLimit', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'setGasLimit' - } = {} as any -) { - return useContractWrite({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - functionName: 'setGasLimit', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemConfigGoerliABI}__ and `functionName` set to `"setResourceConfig"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export function useSystemConfigGoerliSetResourceConfig< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof systemConfigGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof systemConfigGoerliABI, - 'setResourceConfig' - >['request']['abi'], - 'setResourceConfig', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'setResourceConfig' - } - : UseContractWriteConfig< - typeof systemConfigGoerliABI, - 'setResourceConfig', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'setResourceConfig' - } = {} as any -) { - return useContractWrite< - typeof systemConfigGoerliABI, - 'setResourceConfig', - TMode - >({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - functionName: 'setResourceConfig', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemConfigGoerliABI}__ and `functionName` set to `"setUnsafeBlockSigner"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export function useSystemConfigGoerliSetUnsafeBlockSigner< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof systemConfigGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof systemConfigGoerliABI, - 'setUnsafeBlockSigner' - >['request']['abi'], - 'setUnsafeBlockSigner', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'setUnsafeBlockSigner' - } - : UseContractWriteConfig< - typeof systemConfigGoerliABI, - 'setUnsafeBlockSigner', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'setUnsafeBlockSigner' - } = {} as any -) { - return useContractWrite< - typeof systemConfigGoerliABI, - 'setUnsafeBlockSigner', - TMode - >({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - functionName: 'setUnsafeBlockSigner', - ...config, - } as any) -} - -/** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemConfigGoerliABI}__ and `functionName` set to `"transferOwnership"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export function useSystemConfigGoerliTransferOwnership< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof systemConfigGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof systemConfigGoerliABI, - 'transferOwnership' - >['request']['abi'], - 'transferOwnership', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'transferOwnership' - } - : UseContractWriteConfig< - typeof systemConfigGoerliABI, - 'transferOwnership', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'transferOwnership' - } = {} as any -) { - return useContractWrite< - typeof systemConfigGoerliABI, - 'transferOwnership', - TMode - >({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - functionName: 'transferOwnership', - ...config, - } as any) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link systemConfigGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export function usePrepareSystemConfigGoerliWrite( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof systemConfigGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link systemConfigGoerliABI}__ and `functionName` set to `"initialize"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export function usePrepareSystemConfigGoerliInitialize( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - functionName: 'initialize', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link systemConfigGoerliABI}__ and `functionName` set to `"renounceOwnership"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export function usePrepareSystemConfigGoerliRenounceOwnership( - config: Omit< - UsePrepareContractWriteConfig< - typeof systemConfigGoerliABI, - 'renounceOwnership' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - functionName: 'renounceOwnership', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link systemConfigGoerliABI}__ and `functionName` set to `"setBatcherHash"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export function usePrepareSystemConfigGoerliSetBatcherHash( - config: Omit< - UsePrepareContractWriteConfig< - typeof systemConfigGoerliABI, - 'setBatcherHash' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - functionName: 'setBatcherHash', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link systemConfigGoerliABI}__ and `functionName` set to `"setGasConfig"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export function usePrepareSystemConfigGoerliSetGasConfig( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - functionName: 'setGasConfig', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link systemConfigGoerliABI}__ and `functionName` set to `"setGasLimit"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export function usePrepareSystemConfigGoerliSetGasLimit( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - functionName: 'setGasLimit', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link systemConfigGoerliABI}__ and `functionName` set to `"setResourceConfig"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export function usePrepareSystemConfigGoerliSetResourceConfig( - config: Omit< - UsePrepareContractWriteConfig< - typeof systemConfigGoerliABI, - 'setResourceConfig' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - functionName: 'setResourceConfig', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link systemConfigGoerliABI}__ and `functionName` set to `"setUnsafeBlockSigner"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export function usePrepareSystemConfigGoerliSetUnsafeBlockSigner( - config: Omit< - UsePrepareContractWriteConfig< - typeof systemConfigGoerliABI, - 'setUnsafeBlockSigner' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - functionName: 'setUnsafeBlockSigner', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link systemConfigGoerliABI}__ and `functionName` set to `"transferOwnership"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export function usePrepareSystemConfigGoerliTransferOwnership( - config: Omit< - UsePrepareContractWriteConfig< - typeof systemConfigGoerliABI, - 'transferOwnership' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemConfigGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - functionName: 'transferOwnership', - ...config, - } as UsePrepareContractWriteConfig) -} + { name: '_to', internalType: 'address payable', type: 'address' }, + { name: '_amount', internalType: 'uint256', type: 'uint256' }, + ], + name: 'withdrawETH', + outputs: [], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [{ name: '_to', internalType: 'address payable', type: 'address' }], + name: 'withdrawETH', + outputs: [], + }, + { + stateMutability: 'nonpayable', + type: 'function', + inputs: [], + name: 'withdrawFromTeleportr', + outputs: [], + }, + { stateMutability: 'payable', type: 'receive' }, +] as const /** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link systemConfigGoerliABI}__. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) + * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) */ -export function useSystemConfigGoerliEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' - > & { chainId?: keyof typeof systemConfigGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - ...config, - } as UseContractEventConfig) -} +export const teleportrWithdrawerAddress = { + 1: '0x78A25524D90E3D0596558fb43789bD800a5c3007', +} as const /** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link systemConfigGoerliABI}__ and `eventName` set to `"ConfigUpdate"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) + * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) */ -export function useSystemConfigGoerliConfigUpdateEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof systemConfigGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - eventName: 'ConfigUpdate', - ...config, - } as UseContractEventConfig) -} +export const teleportrWithdrawerConfig = { + address: teleportrWithdrawerAddress, + abi: teleportrWithdrawerABI, +} as const -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link systemConfigGoerliABI}__ and `eventName` set to `"Initialized"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export function useSystemConfigGoerliInitializedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof systemConfigGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - eventName: 'Initialized', - ...config, - } as UseContractEventConfig) -} +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// eslintIgnore +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// -/** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link systemConfigGoerliABI}__ and `eventName` set to `"OwnershipTransferred"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) - */ -export function useSystemConfigGoerliOwnershipTransferredEvent( - config: Omit< - UseContractEventConfig< - typeof systemConfigGoerliABI, - 'OwnershipTransferred' - >, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof systemConfigGoerliAddress } = {} as any -) { - return useContractEvent({ - abi: systemConfigGoerliABI, - address: systemConfigGoerliAddress[5], - eventName: 'OwnershipTransferred', - ...config, - } as UseContractEventConfig) -} +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +// React +////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// /** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemDictatorABI}__. + * Wraps __{@link useContractRead}__ with `abi` set to __{@link addressManagerABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdE1FCfB0851916CA5101820A69b13a4E276bd81F) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xa6f73589243a6A7a9023b1Fa0651b1d89c177111) */ -export function useSystemDictatorRead< +export function useAddressManagerRead< TFunctionName extends string, - TSelectData = ReadContractResult + TSelectData = ReadContractResult >( config: Omit< - UseContractReadConfig, + UseContractReadConfig, 'abi' | 'address' - > & { chainId?: keyof typeof systemDictatorAddress } = {} as any -) { - return useContractRead({ - abi: systemDictatorABI, - address: systemDictatorAddress[1], - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemDictatorABI}__ and `functionName` set to `"EXIT_1_NO_RETURN_STEP"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) - */ -export function useSystemDictatorExit_1NoReturnStep< - TFunctionName extends 'EXIT_1_NO_RETURN_STEP', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemDictatorAddress } = {} as any -) { - return useContractRead({ - abi: systemDictatorABI, - address: systemDictatorAddress[1], - functionName: 'EXIT_1_NO_RETURN_STEP', - ...config, - } as UseContractReadConfig) -} - -/** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemDictatorABI}__ and `functionName` set to `"PROXY_TRANSFER_STEP"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) - */ -export function useSystemDictatorProxyTransferStep< - TFunctionName extends 'PROXY_TRANSFER_STEP', - TSelectData = ReadContractResult ->( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemDictatorAddress } = {} as any + > & { chainId?: keyof typeof addressManagerAddress } = {} as any ) { + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId return useContractRead({ - abi: systemDictatorABI, - address: systemDictatorAddress[1], - functionName: 'PROXY_TRANSFER_STEP', + abi: addressManagerABI, + address: + addressManagerAddress[chainId as keyof typeof addressManagerAddress], ...config, - } as UseContractReadConfig) + } as UseContractReadConfig) } /** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemDictatorABI}__ and `functionName` set to `"config"`. + * Wraps __{@link useContractWrite}__ with `abi` set to __{@link addressManagerABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdE1FCfB0851916CA5101820A69b13a4E276bd81F) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xa6f73589243a6A7a9023b1Fa0651b1d89c177111) */ -export function useSystemDictatorConfig< - TFunctionName extends 'config', - TSelectData = ReadContractResult +export function useAddressManagerWrite< + TFunctionName extends string, + TMode extends WriteContractMode = undefined, + TChainId extends number = keyof typeof addressManagerAddress >( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemDictatorAddress } = {} as any + config: TMode extends 'prepared' + ? UseContractWriteConfig< + PrepareWriteContractResult< + typeof addressManagerABI, + string + >['request']['abi'], + TFunctionName, + TMode + > & { address?: Address; chainId?: TChainId } + : UseContractWriteConfig & { + abi?: never + address?: never + chainId?: TChainId + } = {} as any ) { - return useContractRead({ - abi: systemDictatorABI, - address: systemDictatorAddress[1], - functionName: 'config', + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractWrite({ + abi: addressManagerABI, + address: + addressManagerAddress[chainId as keyof typeof addressManagerAddress], ...config, - } as UseContractReadConfig) + } as any) } /** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemDictatorABI}__ and `functionName` set to `"currentStep"`. + * Wraps __{@link useContractEvent}__ with `abi` set to __{@link addressManagerABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdE1FCfB0851916CA5101820A69b13a4E276bd81F) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xa6f73589243a6A7a9023b1Fa0651b1d89c177111) */ -export function useSystemDictatorCurrentStep< - TFunctionName extends 'currentStep', - TSelectData = ReadContractResult ->( +export function useAddressManagerEvent( config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemDictatorAddress } = {} as any + UseContractEventConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof addressManagerAddress } = {} as any ) { - return useContractRead({ - abi: systemDictatorABI, - address: systemDictatorAddress[1], - functionName: 'currentStep', + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractEvent({ + abi: addressManagerABI, + address: + addressManagerAddress[chainId as keyof typeof addressManagerAddress], ...config, - } as UseContractReadConfig) + } as UseContractEventConfig) } /** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemDictatorABI}__ and `functionName` set to `"dynamicConfigSet"`. + * Wraps __{@link useContractRead}__ with `abi` set to __{@link assetReceiverABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) */ -export function useSystemDictatorDynamicConfigSet< - TFunctionName extends 'dynamicConfigSet', - TSelectData = ReadContractResult +export function useAssetReceiverRead< + TFunctionName extends string, + TSelectData = ReadContractResult >( config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemDictatorAddress } = {} as any + UseContractReadConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof assetReceiverAddress } = {} as any ) { + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId return useContractRead({ - abi: systemDictatorABI, - address: systemDictatorAddress[1], - functionName: 'dynamicConfigSet', + abi: assetReceiverABI, + address: assetReceiverAddress[chainId as keyof typeof assetReceiverAddress], ...config, - } as UseContractReadConfig) + } as UseContractReadConfig) } /** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemDictatorABI}__ and `functionName` set to `"exited"`. + * Wraps __{@link useContractWrite}__ with `abi` set to __{@link assetReceiverABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) */ -export function useSystemDictatorExited< - TFunctionName extends 'exited', - TSelectData = ReadContractResult +export function useAssetReceiverWrite< + TFunctionName extends string, + TMode extends WriteContractMode = undefined, + TChainId extends number = keyof typeof assetReceiverAddress >( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemDictatorAddress } = {} as any + config: TMode extends 'prepared' + ? UseContractWriteConfig< + PrepareWriteContractResult< + typeof assetReceiverABI, + string + >['request']['abi'], + TFunctionName, + TMode + > & { address?: Address; chainId?: TChainId } + : UseContractWriteConfig & { + abi?: never + address?: never + chainId?: TChainId + } = {} as any ) { - return useContractRead({ - abi: systemDictatorABI, - address: systemDictatorAddress[1], - functionName: 'exited', + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractWrite({ + abi: assetReceiverABI, + address: assetReceiverAddress[chainId as keyof typeof assetReceiverAddress], ...config, - } as UseContractReadConfig) + } as any) } /** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemDictatorABI}__ and `functionName` set to `"finalized"`. + * Wraps __{@link useContractEvent}__ with `abi` set to __{@link assetReceiverABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x15DdA60616Ffca20371ED1659dBB78E888f65556) */ -export function useSystemDictatorFinalized< - TFunctionName extends 'finalized', - TSelectData = ReadContractResult ->( +export function useAssetReceiverEvent( config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemDictatorAddress } = {} as any + UseContractEventConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof assetReceiverAddress } = {} as any ) { - return useContractRead({ - abi: systemDictatorABI, - address: systemDictatorAddress[1], - functionName: 'finalized', + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractEvent({ + abi: assetReceiverABI, + address: assetReceiverAddress[chainId as keyof typeof assetReceiverAddress], ...config, - } as UseContractReadConfig) + } as UseContractEventConfig) } /** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemDictatorABI}__ and `functionName` set to `"l2OutputOracleDynamicConfig"`. + * Wraps __{@link useContractRead}__ with `abi` set to __{@link attestationStationABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0xEE36eaaD94d1Cc1d0eccaDb55C38bFfB6Be06C77) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0xEE36eaaD94d1Cc1d0eccaDb55C38bFfB6Be06C77) */ -export function useSystemDictatorL2OutputOracleDynamicConfig< - TFunctionName extends 'l2OutputOracleDynamicConfig', - TSelectData = ReadContractResult +export function useAttestationStationRead< + TFunctionName extends string, + TSelectData = ReadContractResult >( config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemDictatorAddress } = {} as any + UseContractReadConfig< + typeof attestationStationABI, + TFunctionName, + TSelectData + >, + 'abi' | 'address' + > & { chainId?: keyof typeof attestationStationAddress } = {} as any ) { + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId return useContractRead({ - abi: systemDictatorABI, - address: systemDictatorAddress[1], - functionName: 'l2OutputOracleDynamicConfig', + abi: attestationStationABI, + address: + attestationStationAddress[ + chainId as keyof typeof attestationStationAddress + ], ...config, - } as UseContractReadConfig) + } as UseContractReadConfig) } /** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemDictatorABI}__ and `functionName` set to `"oldL1CrossDomainMessenger"`. + * Wraps __{@link useContractWrite}__ with `abi` set to __{@link attestationStationABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0xEE36eaaD94d1Cc1d0eccaDb55C38bFfB6Be06C77) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0xEE36eaaD94d1Cc1d0eccaDb55C38bFfB6Be06C77) */ -export function useSystemDictatorOldL1CrossDomainMessenger< - TFunctionName extends 'oldL1CrossDomainMessenger', - TSelectData = ReadContractResult +export function useAttestationStationWrite< + TFunctionName extends string, + TMode extends WriteContractMode = undefined, + TChainId extends number = keyof typeof attestationStationAddress >( - config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemDictatorAddress } = {} as any + config: TMode extends 'prepared' + ? UseContractWriteConfig< + PrepareWriteContractResult< + typeof attestationStationABI, + string + >['request']['abi'], + TFunctionName, + TMode + > & { address?: Address; chainId?: TChainId } + : UseContractWriteConfig< + typeof attestationStationABI, + TFunctionName, + TMode + > & { + abi?: never + address?: never + chainId?: TChainId + } = {} as any ) { - return useContractRead({ - abi: systemDictatorABI, - address: systemDictatorAddress[1], - functionName: 'oldL1CrossDomainMessenger', + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractWrite({ + abi: attestationStationABI, + address: + attestationStationAddress[ + chainId as keyof typeof attestationStationAddress + ], ...config, - } as UseContractReadConfig) + } as any) } /** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemDictatorABI}__ and `functionName` set to `"optimismPortalDynamicConfig"`. + * Wraps __{@link useContractEvent}__ with `abi` set to __{@link attestationStationABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0xEE36eaaD94d1Cc1d0eccaDb55C38bFfB6Be06C77) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0xEE36eaaD94d1Cc1d0eccaDb55C38bFfB6Be06C77) */ -export function useSystemDictatorOptimismPortalDynamicConfig< - TFunctionName extends 'optimismPortalDynamicConfig', - TSelectData = ReadContractResult ->( +export function useAttestationStationEvent( config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemDictatorAddress } = {} as any + UseContractEventConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof attestationStationAddress } = {} as any ) { - return useContractRead({ - abi: systemDictatorABI, - address: systemDictatorAddress[1], - functionName: 'optimismPortalDynamicConfig', + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractEvent({ + abi: attestationStationABI, + address: + attestationStationAddress[ + chainId as keyof typeof attestationStationAddress + ], ...config, - } as UseContractReadConfig) + } as UseContractEventConfig) } /** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemDictatorABI}__ and `functionName` set to `"owner"`. + * Wraps __{@link useContractRead}__ with `abi` set to __{@link baseFeeVaultABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000019) */ -export function useSystemDictatorOwner< - TFunctionName extends 'owner', - TSelectData = ReadContractResult +export function useBaseFeeVaultRead< + TFunctionName extends string, + TSelectData = ReadContractResult >( config: Omit< - UseContractReadConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemDictatorAddress } = {} as any + UseContractReadConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof baseFeeVaultAddress } = {} as any ) { return useContractRead({ - abi: systemDictatorABI, - address: systemDictatorAddress[1], - functionName: 'owner', + abi: baseFeeVaultABI, + address: baseFeeVaultAddress[420], ...config, - } as UseContractReadConfig) + } as UseContractReadConfig) } /** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemDictatorABI}__. + * Wraps __{@link useContractWrite}__ with `abi` set to __{@link baseFeeVaultABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000019) */ -export function useSystemDictatorWrite< +export function useBaseFeeVaultWrite< TFunctionName extends string, TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof systemDictatorAddress + TChainId extends number = keyof typeof baseFeeVaultAddress >( config: TMode extends 'prepared' ? UseContractWriteConfig< PrepareWriteContractResult< - typeof systemDictatorABI, + typeof baseFeeVaultABI, string >['request']['abi'], TFunctionName, TMode > & { address?: Address; chainId?: TChainId } - : UseContractWriteConfig & { + : UseContractWriteConfig & { abi?: never address?: never chainId?: TChainId } = {} as any ) { - return useContractWrite({ - abi: systemDictatorABI, - address: systemDictatorAddress[1], + return useContractWrite({ + abi: baseFeeVaultABI, + address: baseFeeVaultAddress[420], ...config, } as any) } /** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemDictatorABI}__ and `functionName` set to `"exit1"`. + * Wraps __{@link useContractEvent}__ with `abi` set to __{@link baseFeeVaultABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000019) */ -export function useSystemDictatorExit1< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof systemDictatorAddress +export function useBaseFeeVaultEvent( + config: Omit< + UseContractEventConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof baseFeeVaultAddress } = {} as any +) { + return useContractEvent({ + abi: baseFeeVaultABI, + address: baseFeeVaultAddress[420], + ...config, + } as UseContractEventConfig) +} + +/** + * Wraps __{@link useContractRead}__ with `abi` set to __{@link checkBalanceHighABI}__. + * + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x7eC64a8a591bFf829ff6C8be76074D540ACb813F) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x7eC64a8a591bFf829ff6C8be76074D540ACb813F) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5d7103853f12109A7d27F118e54BbC654ad847E9) + */ +export function useCheckBalanceHighRead< + TFunctionName extends string, + TSelectData = ReadContractResult >( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof systemDictatorABI, - 'exit1' - >['request']['abi'], - 'exit1', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'exit1' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'exit1' - } = {} as any + config: Omit< + UseContractReadConfig< + typeof checkBalanceHighABI, + TFunctionName, + TSelectData + >, + 'abi' | 'address' + > & { chainId?: keyof typeof checkBalanceHighAddress } = {} as any ) { - return useContractWrite({ - abi: systemDictatorABI, - address: systemDictatorAddress[1], - functionName: 'exit1', + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractRead({ + abi: checkBalanceHighABI, + address: + checkBalanceHighAddress[chainId as keyof typeof checkBalanceHighAddress], + ...config, + } as UseContractReadConfig) +} + +/** + * Wraps __{@link useContractEvent}__ with `abi` set to __{@link checkBalanceHighABI}__. + * + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x7eC64a8a591bFf829ff6C8be76074D540ACb813F) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x7eC64a8a591bFf829ff6C8be76074D540ACb813F) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5d7103853f12109A7d27F118e54BbC654ad847E9) + */ +export function useCheckBalanceHighEvent( + config: Omit< + UseContractEventConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof checkBalanceHighAddress } = {} as any +) { + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractEvent({ + abi: checkBalanceHighABI, + address: + checkBalanceHighAddress[chainId as keyof typeof checkBalanceHighAddress], + ...config, + } as UseContractEventConfig) +} + +/** + * Wraps __{@link useContractRead}__ with `abi` set to __{@link checkBalanceLowABI}__. + * + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x381a4eFC2A2C914eA1889722bB4B44Fa6BD5b640) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x381a4eFC2A2C914eA1889722bB4B44Fa6BD5b640) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x7Ce13D154FAEE5C8B3E6b19d4Add16f21d884474) + */ +export function useCheckBalanceLowRead< + TFunctionName extends string, + TSelectData = ReadContractResult +>( + config: Omit< + UseContractReadConfig< + typeof checkBalanceLowABI, + TFunctionName, + TSelectData + >, + 'abi' | 'address' + > & { chainId?: keyof typeof checkBalanceLowAddress } = {} as any +) { + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractRead({ + abi: checkBalanceLowABI, + address: + checkBalanceLowAddress[chainId as keyof typeof checkBalanceLowAddress], ...config, - } as any) + } as UseContractReadConfig) } /** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemDictatorABI}__ and `functionName` set to `"finalize"`. + * Wraps __{@link useContractEvent}__ with `abi` set to __{@link checkBalanceLowABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x381a4eFC2A2C914eA1889722bB4B44Fa6BD5b640) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x381a4eFC2A2C914eA1889722bB4B44Fa6BD5b640) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x7Ce13D154FAEE5C8B3E6b19d4Add16f21d884474) */ -export function useSystemDictatorFinalize< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof systemDictatorAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof systemDictatorABI, - 'finalize' - >['request']['abi'], - 'finalize', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'finalize' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'finalize' - } = {} as any +export function useCheckBalanceLowEvent( + config: Omit< + UseContractEventConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof checkBalanceLowAddress } = {} as any ) { - return useContractWrite({ - abi: systemDictatorABI, - address: systemDictatorAddress[1], - functionName: 'finalize', + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractEvent({ + abi: checkBalanceLowABI, + address: + checkBalanceLowAddress[chainId as keyof typeof checkBalanceLowAddress], ...config, - } as any) + } as UseContractEventConfig) } /** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemDictatorABI}__ and `functionName` set to `"initialize"`. + * Wraps __{@link useContractRead}__ with `abi` set to __{@link checkGelatoLowABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4f7CFc43f6D262a085F3b946cAC69E7a8E39BBAa) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4f7CFc43f6D262a085F3b946cAC69E7a8E39BBAa) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0xF9c8a4Cb4021f57F9f6d69799cA9BefF64524862) */ -export function useSystemDictatorInitialize< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof systemDictatorAddress +export function useCheckGelatoLowRead< + TFunctionName extends string, + TSelectData = ReadContractResult >( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof systemDictatorABI, - 'initialize' - >['request']['abi'], - 'initialize', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'initialize' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'initialize' - } = {} as any + config: Omit< + UseContractReadConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof checkGelatoLowAddress } = {} as any ) { - return useContractWrite({ - abi: systemDictatorABI, - address: systemDictatorAddress[1], - functionName: 'initialize', + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractRead({ + abi: checkGelatoLowABI, + address: + checkGelatoLowAddress[chainId as keyof typeof checkGelatoLowAddress], ...config, - } as any) + } as UseContractReadConfig) } /** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemDictatorABI}__ and `functionName` set to `"phase1"`. + * Wraps __{@link useContractEvent}__ with `abi` set to __{@link checkGelatoLowABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4f7CFc43f6D262a085F3b946cAC69E7a8E39BBAa) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4f7CFc43f6D262a085F3b946cAC69E7a8E39BBAa) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0xF9c8a4Cb4021f57F9f6d69799cA9BefF64524862) */ -export function useSystemDictatorPhase1< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof systemDictatorAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof systemDictatorABI, - 'phase1' - >['request']['abi'], - 'phase1', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'phase1' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'phase1' - } = {} as any +export function useCheckGelatoLowEvent( + config: Omit< + UseContractEventConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof checkGelatoLowAddress } = {} as any ) { - return useContractWrite({ - abi: systemDictatorABI, - address: systemDictatorAddress[1], - functionName: 'phase1', + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractEvent({ + abi: checkGelatoLowABI, + address: + checkGelatoLowAddress[chainId as keyof typeof checkGelatoLowAddress], ...config, - } as any) + } as UseContractEventConfig) } /** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemDictatorABI}__ and `functionName` set to `"phase2"`. + * Wraps __{@link useContractRead}__ with `abi` set to __{@link checkTrueABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5c741a38cb11424711231777D71689C458eE835D) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5c741a38cb11424711231777D71689C458eE835D) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x47443D0C184e022F19BD1578F5bca6B8a9F58E32) */ -export function useSystemDictatorPhase2< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof systemDictatorAddress +export function useCheckTrueRead< + TFunctionName extends string, + TSelectData = ReadContractResult >( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof systemDictatorABI, - 'phase2' - >['request']['abi'], - 'phase2', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'phase2' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'phase2' - } = {} as any + config: Omit< + UseContractReadConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof checkTrueAddress } = {} as any ) { - return useContractWrite({ - abi: systemDictatorABI, - address: systemDictatorAddress[1], - functionName: 'phase2', + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractRead({ + abi: checkTrueABI, + address: checkTrueAddress[chainId as keyof typeof checkTrueAddress], ...config, - } as any) + } as UseContractReadConfig) } /** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemDictatorABI}__ and `functionName` set to `"renounceOwnership"`. + * Wraps __{@link useContractRead}__ with `abi` set to __{@link drippieABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) + * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) */ -export function useSystemDictatorRenounceOwnership< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof systemDictatorAddress +export function useDrippieRead< + TFunctionName extends string, + TSelectData = ReadContractResult >( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof systemDictatorABI, - 'renounceOwnership' - >['request']['abi'], - 'renounceOwnership', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'renounceOwnership' - } - : UseContractWriteConfig< - typeof systemDictatorABI, - 'renounceOwnership', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'renounceOwnership' - } = {} as any + config: Omit< + UseContractReadConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof drippieAddress } = {} as any ) { - return useContractWrite( - { - abi: systemDictatorABI, - address: systemDictatorAddress[1], - functionName: 'renounceOwnership', - ...config, - } as any - ) + return useContractRead({ + abi: drippieABI, + address: drippieAddress[1], + ...config, + } as UseContractReadConfig) } /** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemDictatorABI}__ and `functionName` set to `"step1"`. + * Wraps __{@link useContractWrite}__ with `abi` set to __{@link drippieABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) + * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) */ -export function useSystemDictatorStep1< +export function useDrippieWrite< + TFunctionName extends string, TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof systemDictatorAddress + TChainId extends number = keyof typeof drippieAddress >( config: TMode extends 'prepared' ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof systemDictatorABI, - 'step1' - >['request']['abi'], - 'step1', + PrepareWriteContractResult['request']['abi'], + TFunctionName, TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'step1' } - : UseContractWriteConfig & { + > & { address?: Address; chainId?: TChainId } + : UseContractWriteConfig & { abi?: never address?: never chainId?: TChainId - functionName?: 'step1' } = {} as any ) { - return useContractWrite({ - abi: systemDictatorABI, - address: systemDictatorAddress[1], - functionName: 'step1', + return useContractWrite({ + abi: drippieABI, + address: drippieAddress[1], ...config, } as any) } /** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemDictatorABI}__ and `functionName` set to `"step2"`. + * Wraps __{@link useContractEvent}__ with `abi` set to __{@link drippieABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) + * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) */ -export function useSystemDictatorStep2< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof systemDictatorAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof systemDictatorABI, - 'step2' - >['request']['abi'], - 'step2', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'step2' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'step2' - } = {} as any +export function useDrippieEvent( + config: Omit< + UseContractEventConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof drippieAddress } = {} as any ) { - return useContractWrite({ - abi: systemDictatorABI, - address: systemDictatorAddress[1], - functionName: 'step2', + return useContractEvent({ + abi: drippieABI, + address: drippieAddress[1], ...config, - } as any) + } as UseContractEventConfig) } /** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemDictatorABI}__ and `functionName` set to `"step3"`. + * Wraps __{@link useContractRead}__ with `abi` set to __{@link drippieGoerliABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) + * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) */ -export function useSystemDictatorStep3< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof systemDictatorAddress +export function useDrippieGoerliRead< + TFunctionName extends string, + TSelectData = ReadContractResult >( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof systemDictatorABI, - 'step3' - >['request']['abi'], - 'step3', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'step3' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'step3' - } = {} as any + config: Omit< + UseContractReadConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof drippieGoerliAddress } = {} as any ) { - return useContractWrite({ - abi: systemDictatorABI, - address: systemDictatorAddress[1], - functionName: 'step3', + return useContractRead({ + abi: drippieGoerliABI, + address: drippieGoerliAddress[5], ...config, - } as any) + } as UseContractReadConfig) } /** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemDictatorABI}__ and `functionName` set to `"step4"`. + * Wraps __{@link useContractWrite}__ with `abi` set to __{@link drippieGoerliABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) + * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) */ -export function useSystemDictatorStep4< +export function useDrippieGoerliWrite< + TFunctionName extends string, TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof systemDictatorAddress + TChainId extends number = keyof typeof drippieGoerliAddress >( config: TMode extends 'prepared' ? UseContractWriteConfig< PrepareWriteContractResult< - typeof systemDictatorABI, - 'step4' + typeof drippieGoerliABI, + string >['request']['abi'], - 'step4', + TFunctionName, TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'step4' } - : UseContractWriteConfig & { + > & { address?: Address; chainId?: TChainId } + : UseContractWriteConfig & { abi?: never address?: never chainId?: TChainId - functionName?: 'step4' } = {} as any ) { - return useContractWrite({ - abi: systemDictatorABI, - address: systemDictatorAddress[1], - functionName: 'step4', + return useContractWrite({ + abi: drippieGoerliABI, + address: drippieGoerliAddress[5], ...config, } as any) } /** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemDictatorABI}__ and `functionName` set to `"step5"`. + * Wraps __{@link useContractEvent}__ with `abi` set to __{@link drippieGoerliABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) + * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x44b3A2a040057eBafC601A78647e805fd58B1f50) */ -export function useSystemDictatorStep5< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof systemDictatorAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof systemDictatorABI, - 'step5' - >['request']['abi'], - 'step5', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'step5' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'step5' - } = {} as any +export function useDrippieGoerliEvent( + config: Omit< + UseContractEventConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof drippieGoerliAddress } = {} as any ) { - return useContractWrite({ - abi: systemDictatorABI, - address: systemDictatorAddress[1], - functionName: 'step5', + return useContractEvent({ + abi: drippieGoerliABI, + address: drippieGoerliAddress[5], ...config, - } as any) + } as UseContractEventConfig) } /** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemDictatorABI}__ and `functionName` set to `"transferOwnership"`. + * Wraps __{@link useContractRead}__ with `abi` set to __{@link drippieOptimismGoerliABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x8D8d533C16D23847EB04EEB0925be8900Dd3af86) */ -export function useSystemDictatorTransferOwnership< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof systemDictatorAddress +export function useDrippieOptimismGoerliRead< + TFunctionName extends string, + TSelectData = ReadContractResult< + typeof drippieOptimismGoerliABI, + TFunctionName + > >( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof systemDictatorABI, - 'transferOwnership' - >['request']['abi'], - 'transferOwnership', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'transferOwnership' - } - : UseContractWriteConfig< - typeof systemDictatorABI, - 'transferOwnership', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'transferOwnership' - } = {} as any + config: Omit< + UseContractReadConfig< + typeof drippieOptimismGoerliABI, + TFunctionName, + TSelectData + >, + 'abi' | 'address' + > & { chainId?: keyof typeof drippieOptimismGoerliAddress } = {} as any ) { - return useContractWrite( - { - abi: systemDictatorABI, - address: systemDictatorAddress[1], - functionName: 'transferOwnership', - ...config, - } as any - ) + return useContractRead({ + abi: drippieOptimismGoerliABI, + address: drippieOptimismGoerliAddress[420], + ...config, + } as UseContractReadConfig) } /** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemDictatorABI}__ and `functionName` set to `"updateDynamicConfig"`. + * Wraps __{@link useContractWrite}__ with `abi` set to __{@link drippieOptimismGoerliABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x8D8d533C16D23847EB04EEB0925be8900Dd3af86) */ -export function useSystemDictatorUpdateDynamicConfig< +export function useDrippieOptimismGoerliWrite< + TFunctionName extends string, TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof systemDictatorAddress + TChainId extends number = keyof typeof drippieOptimismGoerliAddress >( config: TMode extends 'prepared' ? UseContractWriteConfig< PrepareWriteContractResult< - typeof systemDictatorABI, - 'updateDynamicConfig' + typeof drippieOptimismGoerliABI, + string >['request']['abi'], - 'updateDynamicConfig', + TFunctionName, TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'updateDynamicConfig' - } + > & { address?: Address; chainId?: TChainId } : UseContractWriteConfig< - typeof systemDictatorABI, - 'updateDynamicConfig', + typeof drippieOptimismGoerliABI, + TFunctionName, TMode > & { abi?: never address?: never chainId?: TChainId - functionName?: 'updateDynamicConfig' } = {} as any ) { return useContractWrite< - typeof systemDictatorABI, - 'updateDynamicConfig', + typeof drippieOptimismGoerliABI, + TFunctionName, TMode >({ - abi: systemDictatorABI, - address: systemDictatorAddress[1], - functionName: 'updateDynamicConfig', + abi: drippieOptimismGoerliABI, + address: drippieOptimismGoerliAddress[420], ...config, } as any) } /** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link systemDictatorABI}__. + * Wraps __{@link useContractEvent}__ with `abi` set to __{@link drippieOptimismGoerliABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x8D8d533C16D23847EB04EEB0925be8900Dd3af86) */ -export function usePrepareSystemDictatorWrite( +export function useDrippieOptimismGoerliEvent( config: Omit< - UsePrepareContractWriteConfig, + UseContractEventConfig, 'abi' | 'address' - > & { chainId?: keyof typeof systemDictatorAddress } = {} as any + > & { chainId?: keyof typeof drippieOptimismGoerliAddress } = {} as any ) { - return usePrepareContractWrite({ - abi: systemDictatorABI, - address: systemDictatorAddress[1], + return useContractEvent({ + abi: drippieOptimismGoerliABI, + address: drippieOptimismGoerliAddress[420], ...config, - } as UsePrepareContractWriteConfig) + } as UseContractEventConfig) } /** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link systemDictatorABI}__ and `functionName` set to `"exit1"`. + * Wraps __{@link useContractRead}__ with `abi` set to __{@link easABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) */ -export function usePrepareSystemDictatorExit1( +export function useEasRead< + TFunctionName extends string, + TSelectData = ReadContractResult +>( config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemDictatorAddress } = {} as any + UseContractReadConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof easAddress } = {} as any ) { - return usePrepareContractWrite({ - abi: systemDictatorABI, - address: systemDictatorAddress[1], - functionName: 'exit1', + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractRead({ + abi: easABI, + address: easAddress[chainId as keyof typeof easAddress], ...config, - } as UsePrepareContractWriteConfig) + } as UseContractReadConfig) } /** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link systemDictatorABI}__ and `functionName` set to `"finalize"`. + * Wraps __{@link useContractWrite}__ with `abi` set to __{@link easABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) + */ +export function useEasWrite< + TFunctionName extends string, + TMode extends WriteContractMode = undefined, + TChainId extends number = keyof typeof easAddress +>( + config: TMode extends 'prepared' + ? UseContractWriteConfig< + PrepareWriteContractResult['request']['abi'], + TFunctionName, + TMode + > & { address?: Address; chainId?: TChainId } + : UseContractWriteConfig & { + abi?: never + address?: never + chainId?: TChainId + } = {} as any +) { + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractWrite({ + abi: easABI, + address: easAddress[chainId as keyof typeof easAddress], + ...config, + } as any) +} + +/** + * Wraps __{@link useContractEvent}__ with `abi` set to __{@link easABI}__. + * + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4E0275Ea5a89e7a3c1B58411379D1a0eDdc5b088) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x5A633F1cc84B03F7588486CF2F386c102061E6e1) */ -export function usePrepareSystemDictatorFinalize( +export function useEasEvent( config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemDictatorAddress } = {} as any + UseContractEventConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof easAddress } = {} as any ) { - return usePrepareContractWrite({ - abi: systemDictatorABI, - address: systemDictatorAddress[1], - functionName: 'finalize', + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractEvent({ + abi: easABI, + address: easAddress[chainId as keyof typeof easAddress], ...config, - } as UsePrepareContractWriteConfig) + } as UseContractEventConfig) } /** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link systemDictatorABI}__ and `functionName` set to `"initialize"`. + * Wraps __{@link useContractRead}__ with `abi` set to __{@link gasPriceOracleABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000000F) */ -export function usePrepareSystemDictatorInitialize( +export function useGasPriceOracleRead< + TFunctionName extends string, + TSelectData = ReadContractResult +>( config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemDictatorAddress } = {} as any + UseContractReadConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof gasPriceOracleAddress } = {} as any ) { - return usePrepareContractWrite({ - abi: systemDictatorABI, - address: systemDictatorAddress[1], - functionName: 'initialize', + return useContractRead({ + abi: gasPriceOracleABI, + address: gasPriceOracleAddress[420], ...config, - } as UsePrepareContractWriteConfig) + } as UseContractReadConfig) } /** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link systemDictatorABI}__ and `functionName` set to `"phase1"`. + * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1BlockABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000015) */ -export function usePrepareSystemDictatorPhase1( +export function useL1BlockRead< + TFunctionName extends string, + TSelectData = ReadContractResult +>( config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemDictatorAddress } = {} as any + UseContractReadConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof l1BlockAddress } = {} as any ) { - return usePrepareContractWrite({ - abi: systemDictatorABI, - address: systemDictatorAddress[1], - functionName: 'phase1', + return useContractRead({ + abi: l1BlockABI, + address: l1BlockAddress[420], ...config, - } as UsePrepareContractWriteConfig) + } as UseContractReadConfig) } /** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link systemDictatorABI}__ and `functionName` set to `"phase2"`. + * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1BlockABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000015) + */ +export function useL1BlockWrite< + TFunctionName extends string, + TMode extends WriteContractMode = undefined, + TChainId extends number = keyof typeof l1BlockAddress +>( + config: TMode extends 'prepared' + ? UseContractWriteConfig< + PrepareWriteContractResult['request']['abi'], + TFunctionName, + TMode + > & { address?: Address; chainId?: TChainId } + : UseContractWriteConfig & { + abi?: never + address?: never + chainId?: TChainId + } = {} as any +) { + return useContractWrite({ + abi: l1BlockABI, + address: l1BlockAddress[420], + ...config, + } as any) +} + +/** + * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1CrossDomainMessengerABI}__. + * + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) */ -export function usePrepareSystemDictatorPhase2( +export function useL1CrossDomainMessengerRead< + TFunctionName extends string, + TSelectData = ReadContractResult< + typeof l1CrossDomainMessengerABI, + TFunctionName + > +>( config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemDictatorAddress } = {} as any + UseContractReadConfig< + typeof l1CrossDomainMessengerABI, + TFunctionName, + TSelectData + >, + 'abi' | 'address' + > & { chainId?: keyof typeof l1CrossDomainMessengerAddress } = {} as any ) { - return usePrepareContractWrite({ - abi: systemDictatorABI, - address: systemDictatorAddress[1], - functionName: 'phase2', + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractRead({ + abi: l1CrossDomainMessengerABI, + address: + l1CrossDomainMessengerAddress[ + chainId as keyof typeof l1CrossDomainMessengerAddress + ], ...config, - } as UsePrepareContractWriteConfig) + } as UseContractReadConfig) } /** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link systemDictatorABI}__ and `functionName` set to `"renounceOwnership"`. + * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1CrossDomainMessengerABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) */ -export function usePrepareSystemDictatorRenounceOwnership( - config: Omit< - UsePrepareContractWriteConfig< - typeof systemDictatorABI, - 'renounceOwnership' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemDictatorAddress } = {} as any +export function useL1CrossDomainMessengerWrite< + TFunctionName extends string, + TMode extends WriteContractMode = undefined, + TChainId extends number = keyof typeof l1CrossDomainMessengerAddress +>( + config: TMode extends 'prepared' + ? UseContractWriteConfig< + PrepareWriteContractResult< + typeof l1CrossDomainMessengerABI, + string + >['request']['abi'], + TFunctionName, + TMode + > & { address?: Address; chainId?: TChainId } + : UseContractWriteConfig< + typeof l1CrossDomainMessengerABI, + TFunctionName, + TMode + > & { + abi?: never + address?: never + chainId?: TChainId + } = {} as any ) { - return usePrepareContractWrite({ - abi: systemDictatorABI, - address: systemDictatorAddress[1], - functionName: 'renounceOwnership', + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractWrite< + typeof l1CrossDomainMessengerABI, + TFunctionName, + TMode + >({ + abi: l1CrossDomainMessengerABI, + address: + l1CrossDomainMessengerAddress[ + chainId as keyof typeof l1CrossDomainMessengerAddress + ], ...config, - } as UsePrepareContractWriteConfig) + } as any) } /** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link systemDictatorABI}__ and `functionName` set to `"step1"`. + * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l1CrossDomainMessengerABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x25ace71c97B33Cc4729CF772ae268934F7ab5fA1) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5086d1eEF304eb5284A0f6720f79403b4e9bE294) */ -export function usePrepareSystemDictatorStep1( +export function useL1CrossDomainMessengerEvent( config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemDictatorAddress } = {} as any + UseContractEventConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof l1CrossDomainMessengerAddress } = {} as any ) { - return usePrepareContractWrite({ - abi: systemDictatorABI, - address: systemDictatorAddress[1], - functionName: 'step1', + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractEvent({ + abi: l1CrossDomainMessengerABI, + address: + l1CrossDomainMessengerAddress[ + chainId as keyof typeof l1CrossDomainMessengerAddress + ], ...config, - } as UsePrepareContractWriteConfig) + } as UseContractEventConfig) } /** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link systemDictatorABI}__ and `functionName` set to `"step2"`. + * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1Erc721BridgeABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5a7749f83b81B301cAb5f48EB8516B986DAef23D) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9) */ -export function usePrepareSystemDictatorStep2( +export function useL1Erc721BridgeRead< + TFunctionName extends string, + TSelectData = ReadContractResult +>( config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemDictatorAddress } = {} as any + UseContractReadConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof l1Erc721BridgeAddress } = {} as any ) { - return usePrepareContractWrite({ - abi: systemDictatorABI, - address: systemDictatorAddress[1], - functionName: 'step2', + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractRead({ + abi: l1Erc721BridgeABI, + address: + l1Erc721BridgeAddress[chainId as keyof typeof l1Erc721BridgeAddress], ...config, - } as UsePrepareContractWriteConfig) + } as UseContractReadConfig) } /** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link systemDictatorABI}__ and `functionName` set to `"step3"`. + * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1Erc721BridgeABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5a7749f83b81B301cAb5f48EB8516B986DAef23D) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9) */ -export function usePrepareSystemDictatorStep3( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemDictatorAddress } = {} as any +export function useL1Erc721BridgeWrite< + TFunctionName extends string, + TMode extends WriteContractMode = undefined, + TChainId extends number = keyof typeof l1Erc721BridgeAddress +>( + config: TMode extends 'prepared' + ? UseContractWriteConfig< + PrepareWriteContractResult< + typeof l1Erc721BridgeABI, + string + >['request']['abi'], + TFunctionName, + TMode + > & { address?: Address; chainId?: TChainId } + : UseContractWriteConfig & { + abi?: never + address?: never + chainId?: TChainId + } = {} as any ) { - return usePrepareContractWrite({ - abi: systemDictatorABI, - address: systemDictatorAddress[1], - functionName: 'step3', + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractWrite({ + abi: l1Erc721BridgeABI, + address: + l1Erc721BridgeAddress[chainId as keyof typeof l1Erc721BridgeAddress], ...config, - } as UsePrepareContractWriteConfig) + } as any) } /** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link systemDictatorABI}__ and `functionName` set to `"step4"`. + * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l1Erc721BridgeABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x5a7749f83b81B301cAb5f48EB8516B986DAef23D) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x8DD330DdE8D9898d43b4dc840Da27A07dF91b3c9) */ -export function usePrepareSystemDictatorStep4( +export function useL1Erc721BridgeEvent( config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemDictatorAddress } = {} as any + UseContractEventConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof l1Erc721BridgeAddress } = {} as any ) { - return usePrepareContractWrite({ - abi: systemDictatorABI, - address: systemDictatorAddress[1], - functionName: 'step4', + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractEvent({ + abi: l1Erc721BridgeABI, + address: + l1Erc721BridgeAddress[chainId as keyof typeof l1Erc721BridgeAddress], ...config, - } as UsePrepareContractWriteConfig) + } as UseContractEventConfig) } /** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link systemDictatorABI}__ and `functionName` set to `"step5"`. + * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1FeeVaultABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000001a) */ -export function usePrepareSystemDictatorStep5( +export function useL1FeeVaultRead< + TFunctionName extends string, + TSelectData = ReadContractResult +>( config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemDictatorAddress } = {} as any + UseContractReadConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof l1FeeVaultAddress } = {} as any ) { - return usePrepareContractWrite({ - abi: systemDictatorABI, - address: systemDictatorAddress[1], - functionName: 'step5', + return useContractRead({ + abi: l1FeeVaultABI, + address: l1FeeVaultAddress[420], ...config, - } as UsePrepareContractWriteConfig) + } as UseContractReadConfig) } /** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link systemDictatorABI}__ and `functionName` set to `"transferOwnership"`. + * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1FeeVaultABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000001a) */ -export function usePrepareSystemDictatorTransferOwnership( - config: Omit< - UsePrepareContractWriteConfig< - typeof systemDictatorABI, - 'transferOwnership' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemDictatorAddress } = {} as any +export function useL1FeeVaultWrite< + TFunctionName extends string, + TMode extends WriteContractMode = undefined, + TChainId extends number = keyof typeof l1FeeVaultAddress +>( + config: TMode extends 'prepared' + ? UseContractWriteConfig< + PrepareWriteContractResult< + typeof l1FeeVaultABI, + string + >['request']['abi'], + TFunctionName, + TMode + > & { address?: Address; chainId?: TChainId } + : UseContractWriteConfig & { + abi?: never + address?: never + chainId?: TChainId + } = {} as any ) { - return usePrepareContractWrite({ - abi: systemDictatorABI, - address: systemDictatorAddress[1], - functionName: 'transferOwnership', + return useContractWrite({ + abi: l1FeeVaultABI, + address: l1FeeVaultAddress[420], ...config, - } as UsePrepareContractWriteConfig) + } as any) } /** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link systemDictatorABI}__ and `functionName` set to `"updateDynamicConfig"`. + * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l1FeeVaultABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x420000000000000000000000000000000000001a) */ -export function usePrepareSystemDictatorUpdateDynamicConfig( +export function useL1FeeVaultEvent( config: Omit< - UsePrepareContractWriteConfig< - typeof systemDictatorABI, - 'updateDynamicConfig' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemDictatorAddress } = {} as any + UseContractEventConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof l1FeeVaultAddress } = {} as any ) { - return usePrepareContractWrite({ - abi: systemDictatorABI, - address: systemDictatorAddress[1], - functionName: 'updateDynamicConfig', + return useContractEvent({ + abi: l1FeeVaultABI, + address: l1FeeVaultAddress[420], ...config, - } as UsePrepareContractWriteConfig) + } as UseContractEventConfig) } /** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link systemDictatorABI}__. + * Wraps __{@link useContractRead}__ with `abi` set to __{@link l1StandardBridgeABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) */ -export function useSystemDictatorEvent( +export function useL1StandardBridgeRead< + TFunctionName extends string, + TSelectData = ReadContractResult +>( config: Omit< - UseContractEventConfig, + UseContractReadConfig< + typeof l1StandardBridgeABI, + TFunctionName, + TSelectData + >, 'abi' | 'address' - > & { chainId?: keyof typeof systemDictatorAddress } = {} as any + > & { chainId?: keyof typeof l1StandardBridgeAddress } = {} as any ) { - return useContractEvent({ - abi: systemDictatorABI, - address: systemDictatorAddress[1], + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractRead({ + abi: l1StandardBridgeABI, + address: + l1StandardBridgeAddress[chainId as keyof typeof l1StandardBridgeAddress], ...config, - } as UseContractEventConfig) + } as UseContractReadConfig) } /** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link systemDictatorABI}__ and `eventName` set to `"Initialized"`. + * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l1StandardBridgeABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) */ -export function useSystemDictatorInitializedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof systemDictatorAddress } = {} as any +export function useL1StandardBridgeWrite< + TFunctionName extends string, + TMode extends WriteContractMode = undefined, + TChainId extends number = keyof typeof l1StandardBridgeAddress +>( + config: TMode extends 'prepared' + ? UseContractWriteConfig< + PrepareWriteContractResult< + typeof l1StandardBridgeABI, + string + >['request']['abi'], + TFunctionName, + TMode + > & { address?: Address; chainId?: TChainId } + : UseContractWriteConfig< + typeof l1StandardBridgeABI, + TFunctionName, + TMode + > & { + abi?: never + address?: never + chainId?: TChainId + } = {} as any ) { - return useContractEvent({ - abi: systemDictatorABI, - address: systemDictatorAddress[1], - eventName: 'Initialized', + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractWrite({ + abi: l1StandardBridgeABI, + address: + l1StandardBridgeAddress[chainId as keyof typeof l1StandardBridgeAddress], ...config, - } as UseContractEventConfig) + } as any) } /** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link systemDictatorABI}__ and `eventName` set to `"OwnershipTransferred"`. + * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l1StandardBridgeABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x99C9fc46f92E8a1c0deC1b1747d010903E884bE1) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x636Af16bf2f682dD3109e60102b8E1A089FedAa8) */ -export function useSystemDictatorOwnershipTransferredEvent( +export function useL1StandardBridgeEvent( config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof systemDictatorAddress } = {} as any + UseContractEventConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof l1StandardBridgeAddress } = {} as any ) { + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId return useContractEvent({ - abi: systemDictatorABI, - address: systemDictatorAddress[1], - eventName: 'OwnershipTransferred', + abi: l1StandardBridgeABI, + address: + l1StandardBridgeAddress[chainId as keyof typeof l1StandardBridgeAddress], ...config, - } as UseContractEventConfig) + } as UseContractEventConfig) } /** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemDictatorGoerliABI}__. + * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2CrossDomainMessengerABI}__. * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) */ -export function useSystemDictatorGoerliRead< +export function useL2CrossDomainMessengerRead< TFunctionName extends string, TSelectData = ReadContractResult< - typeof systemDictatorGoerliABI, + typeof l2CrossDomainMessengerABI, TFunctionName > >( config: Omit< UseContractReadConfig< - typeof systemDictatorGoerliABI, + typeof l2CrossDomainMessengerABI, TFunctionName, TSelectData >, 'abi' | 'address' - > & { chainId?: keyof typeof systemDictatorGoerliAddress } = {} as any + > & { chainId?: keyof typeof l2CrossDomainMessengerAddress } = {} as any ) { return useContractRead({ - abi: systemDictatorGoerliABI, - address: systemDictatorGoerliAddress[5], + abi: l2CrossDomainMessengerABI, + address: l2CrossDomainMessengerAddress[420], ...config, - } as UseContractReadConfig) + } as UseContractReadConfig) } /** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemDictatorGoerliABI}__ and `functionName` set to `"EXIT_1_NO_RETURN_STEP"`. + * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l2CrossDomainMessengerABI}__. * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) */ -export function useSystemDictatorGoerliExit_1NoReturnStep< - TFunctionName extends 'EXIT_1_NO_RETURN_STEP', - TSelectData = ReadContractResult< - typeof systemDictatorGoerliABI, - TFunctionName - > +export function useL2CrossDomainMessengerWrite< + TFunctionName extends string, + TMode extends WriteContractMode = undefined, + TChainId extends number = keyof typeof l2CrossDomainMessengerAddress >( - config: Omit< - UseContractReadConfig< - typeof systemDictatorGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemDictatorGoerliAddress } = {} as any + config: TMode extends 'prepared' + ? UseContractWriteConfig< + PrepareWriteContractResult< + typeof l2CrossDomainMessengerABI, + string + >['request']['abi'], + TFunctionName, + TMode + > & { address?: Address; chainId?: TChainId } + : UseContractWriteConfig< + typeof l2CrossDomainMessengerABI, + TFunctionName, + TMode + > & { + abi?: never + address?: never + chainId?: TChainId + } = {} as any ) { - return useContractRead({ - abi: systemDictatorGoerliABI, - address: systemDictatorGoerliAddress[5], - functionName: 'EXIT_1_NO_RETURN_STEP', + return useContractWrite< + typeof l2CrossDomainMessengerABI, + TFunctionName, + TMode + >({ + abi: l2CrossDomainMessengerABI, + address: l2CrossDomainMessengerAddress[420], ...config, - } as UseContractReadConfig) + } as any) } /** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemDictatorGoerliABI}__ and `functionName` set to `"PROXY_TRANSFER_STEP"`. + * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l2CrossDomainMessengerABI}__. * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000007) */ -export function useSystemDictatorGoerliProxyTransferStep< - TFunctionName extends 'PROXY_TRANSFER_STEP', - TSelectData = ReadContractResult< - typeof systemDictatorGoerliABI, - TFunctionName - > ->( +export function useL2CrossDomainMessengerEvent( config: Omit< - UseContractReadConfig< - typeof systemDictatorGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemDictatorGoerliAddress } = {} as any + UseContractEventConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof l2CrossDomainMessengerAddress } = {} as any ) { - return useContractRead({ - abi: systemDictatorGoerliABI, - address: systemDictatorGoerliAddress[5], - functionName: 'PROXY_TRANSFER_STEP', + return useContractEvent({ + abi: l2CrossDomainMessengerABI, + address: l2CrossDomainMessengerAddress[420], ...config, - } as UseContractReadConfig) + } as UseContractEventConfig) } /** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemDictatorGoerliABI}__ and `functionName` set to `"config"`. + * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2Erc721BridgeABI}__. * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000014) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000014) */ -export function useSystemDictatorGoerliConfig< - TFunctionName extends 'config', - TSelectData = ReadContractResult< - typeof systemDictatorGoerliABI, - TFunctionName - > +export function useL2Erc721BridgeRead< + TFunctionName extends string, + TSelectData = ReadContractResult >( config: Omit< - UseContractReadConfig< - typeof systemDictatorGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemDictatorGoerliAddress } = {} as any + UseContractReadConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof l2Erc721BridgeAddress } = {} as any ) { + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId return useContractRead({ - abi: systemDictatorGoerliABI, - address: systemDictatorGoerliAddress[5], - functionName: 'config', + abi: l2Erc721BridgeABI, + address: + l2Erc721BridgeAddress[chainId as keyof typeof l2Erc721BridgeAddress], ...config, - } as UseContractReadConfig) + } as UseContractReadConfig) } /** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemDictatorGoerliABI}__ and `functionName` set to `"currentStep"`. + * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l2Erc721BridgeABI}__. * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000014) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000014) */ -export function useSystemDictatorGoerliCurrentStep< - TFunctionName extends 'currentStep', - TSelectData = ReadContractResult< - typeof systemDictatorGoerliABI, - TFunctionName - > +export function useL2Erc721BridgeWrite< + TFunctionName extends string, + TMode extends WriteContractMode = undefined, + TChainId extends number = keyof typeof l2Erc721BridgeAddress >( - config: Omit< - UseContractReadConfig< - typeof systemDictatorGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemDictatorGoerliAddress } = {} as any + config: TMode extends 'prepared' + ? UseContractWriteConfig< + PrepareWriteContractResult< + typeof l2Erc721BridgeABI, + string + >['request']['abi'], + TFunctionName, + TMode + > & { address?: Address; chainId?: TChainId } + : UseContractWriteConfig & { + abi?: never + address?: never + chainId?: TChainId + } = {} as any ) { - return useContractRead({ - abi: systemDictatorGoerliABI, - address: systemDictatorGoerliAddress[5], - functionName: 'currentStep', + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractWrite({ + abi: l2Erc721BridgeABI, + address: + l2Erc721BridgeAddress[chainId as keyof typeof l2Erc721BridgeAddress], ...config, - } as UseContractReadConfig) + } as any) } /** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemDictatorGoerliABI}__ and `functionName` set to `"dynamicConfigSet"`. + * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l2Erc721BridgeABI}__. * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000014) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000014) */ -export function useSystemDictatorGoerliDynamicConfigSet< - TFunctionName extends 'dynamicConfigSet', - TSelectData = ReadContractResult< - typeof systemDictatorGoerliABI, - TFunctionName - > ->( +export function useL2Erc721BridgeEvent( config: Omit< - UseContractReadConfig< - typeof systemDictatorGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemDictatorGoerliAddress } = {} as any + UseContractEventConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof l2Erc721BridgeAddress } = {} as any ) { - return useContractRead({ - abi: systemDictatorGoerliABI, - address: systemDictatorGoerliAddress[5], - functionName: 'dynamicConfigSet', + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractEvent({ + abi: l2Erc721BridgeABI, + address: + l2Erc721BridgeAddress[chainId as keyof typeof l2Erc721BridgeAddress], ...config, - } as UseContractReadConfig) + } as UseContractEventConfig) } /** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemDictatorGoerliABI}__ and `functionName` set to `"finalized"`. + * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2OutputOracleABI}__. * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) */ -export function useSystemDictatorGoerliFinalized< - TFunctionName extends 'finalized', - TSelectData = ReadContractResult< - typeof systemDictatorGoerliABI, - TFunctionName - > +export function useL2OutputOracleRead< + TFunctionName extends string, + TSelectData = ReadContractResult >( config: Omit< - UseContractReadConfig< - typeof systemDictatorGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemDictatorGoerliAddress } = {} as any + UseContractReadConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof l2OutputOracleAddress } = {} as any ) { + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId return useContractRead({ - abi: systemDictatorGoerliABI, - address: systemDictatorGoerliAddress[5], - functionName: 'finalized', + abi: l2OutputOracleABI, + address: + l2OutputOracleAddress[chainId as keyof typeof l2OutputOracleAddress], ...config, - } as UseContractReadConfig) + } as UseContractReadConfig) } /** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemDictatorGoerliABI}__ and `functionName` set to `"l2OutputOracleDynamicConfig"`. + * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l2OutputOracleABI}__. * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) */ -export function useSystemDictatorGoerliL2OutputOracleDynamicConfig< - TFunctionName extends 'l2OutputOracleDynamicConfig', - TSelectData = ReadContractResult< - typeof systemDictatorGoerliABI, - TFunctionName - > +export function useL2OutputOracleWrite< + TFunctionName extends string, + TMode extends WriteContractMode = undefined, + TChainId extends number = keyof typeof l2OutputOracleAddress >( - config: Omit< - UseContractReadConfig< - typeof systemDictatorGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemDictatorGoerliAddress } = {} as any + config: TMode extends 'prepared' + ? UseContractWriteConfig< + PrepareWriteContractResult< + typeof l2OutputOracleABI, + string + >['request']['abi'], + TFunctionName, + TMode + > & { address?: Address; chainId?: TChainId } + : UseContractWriteConfig & { + abi?: never + address?: never + chainId?: TChainId + } = {} as any ) { - return useContractRead({ - abi: systemDictatorGoerliABI, - address: systemDictatorGoerliAddress[5], - functionName: 'l2OutputOracleDynamicConfig', + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractWrite({ + abi: l2OutputOracleABI, + address: + l2OutputOracleAddress[chainId as keyof typeof l2OutputOracleAddress], ...config, - } as UseContractReadConfig) + } as any) } /** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemDictatorGoerliABI}__ and `functionName` set to `"oldL1CrossDomainMessenger"`. + * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l2OutputOracleABI}__. * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xdfe97868233d1aa22e815a266982f2cf17685a27) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xE6Dfba0953616Bacab0c9A8ecb3a9BBa77FC15c0) */ -export function useSystemDictatorGoerliOldL1CrossDomainMessenger< - TFunctionName extends 'oldL1CrossDomainMessenger', - TSelectData = ReadContractResult< - typeof systemDictatorGoerliABI, - TFunctionName - > ->( +export function useL2OutputOracleEvent( config: Omit< - UseContractReadConfig< - typeof systemDictatorGoerliABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemDictatorGoerliAddress } = {} as any + UseContractEventConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof l2OutputOracleAddress } = {} as any ) { - return useContractRead({ - abi: systemDictatorGoerliABI, - address: systemDictatorGoerliAddress[5], - functionName: 'oldL1CrossDomainMessenger', + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractEvent({ + abi: l2OutputOracleABI, + address: + l2OutputOracleAddress[chainId as keyof typeof l2OutputOracleAddress], ...config, - } as UseContractReadConfig) + } as UseContractEventConfig) } /** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemDictatorGoerliABI}__ and `functionName` set to `"owner"`. + * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2StandardBridgeABI}__. * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) */ -export function useSystemDictatorGoerliOwner< - TFunctionName extends 'owner', - TSelectData = ReadContractResult< - typeof systemDictatorGoerliABI, - TFunctionName - > +export function useL2StandardBridgeRead< + TFunctionName extends string, + TSelectData = ReadContractResult >( config: Omit< UseContractReadConfig< - typeof systemDictatorGoerliABI, + typeof l2StandardBridgeABI, TFunctionName, TSelectData >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemDictatorGoerliAddress } = {} as any + 'abi' | 'address' + > & { chainId?: keyof typeof l2StandardBridgeAddress } = {} as any ) { return useContractRead({ - abi: systemDictatorGoerliABI, - address: systemDictatorGoerliAddress[5], - functionName: 'owner', + abi: l2StandardBridgeABI, + address: l2StandardBridgeAddress[420], ...config, - } as UseContractReadConfig) + } as UseContractReadConfig) } /** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemDictatorGoerliABI}__. + * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l2StandardBridgeABI}__. * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) */ -export function useSystemDictatorGoerliWrite< +export function useL2StandardBridgeWrite< TFunctionName extends string, TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof systemDictatorGoerliAddress + TChainId extends number = keyof typeof l2StandardBridgeAddress >( config: TMode extends 'prepared' ? UseContractWriteConfig< PrepareWriteContractResult< - typeof systemDictatorGoerliABI, + typeof l2StandardBridgeABI, string >['request']['abi'], TFunctionName, TMode > & { address?: Address; chainId?: TChainId } : UseContractWriteConfig< - typeof systemDictatorGoerliABI, + typeof l2StandardBridgeABI, TFunctionName, TMode > & { @@ -38667,924 +10622,909 @@ export function useSystemDictatorGoerliWrite< chainId?: TChainId } = {} as any ) { - return useContractWrite( - { - abi: systemDictatorGoerliABI, - address: systemDictatorGoerliAddress[5], - ...config, - } as any - ) + return useContractWrite({ + abi: l2StandardBridgeABI, + address: l2StandardBridgeAddress[420], + ...config, + } as any) } /** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemDictatorGoerliABI}__ and `functionName` set to `"exit1"`. + * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l2StandardBridgeABI}__. * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000010) */ -export function useSystemDictatorGoerliExit1< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof systemDictatorGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof systemDictatorGoerliABI, - 'exit1' - >['request']['abi'], - 'exit1', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'exit1' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'exit1' - } = {} as any +export function useL2StandardBridgeEvent( + config: Omit< + UseContractEventConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof l2StandardBridgeAddress } = {} as any ) { - return useContractWrite({ - abi: systemDictatorGoerliABI, - address: systemDictatorGoerliAddress[5], - functionName: 'exit1', + return useContractEvent({ + abi: l2StandardBridgeABI, + address: l2StandardBridgeAddress[420], ...config, - } as any) + } as UseContractEventConfig) } /** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemDictatorGoerliABI}__ and `functionName` set to `"finalize"`. + * Wraps __{@link useContractRead}__ with `abi` set to __{@link l2ToL1MessagePasserABI}__. * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000016) */ -export function useSystemDictatorGoerliFinalize< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof systemDictatorGoerliAddress +export function useL2ToL1MessagePasserRead< + TFunctionName extends string, + TSelectData = ReadContractResult >( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof systemDictatorGoerliABI, - 'finalize' - >['request']['abi'], - 'finalize', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'finalize' } - : UseContractWriteConfig< - typeof systemDictatorGoerliABI, - 'finalize', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'finalize' - } = {} as any + config: Omit< + UseContractReadConfig< + typeof l2ToL1MessagePasserABI, + TFunctionName, + TSelectData + >, + 'abi' | 'address' + > & { chainId?: keyof typeof l2ToL1MessagePasserAddress } = {} as any ) { - return useContractWrite({ - abi: systemDictatorGoerliABI, - address: systemDictatorGoerliAddress[5], - functionName: 'finalize', + return useContractRead({ + abi: l2ToL1MessagePasserABI, + address: l2ToL1MessagePasserAddress[420], ...config, - } as any) + } as UseContractReadConfig) } /** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemDictatorGoerliABI}__ and `functionName` set to `"initialize"`. + * Wraps __{@link useContractWrite}__ with `abi` set to __{@link l2ToL1MessagePasserABI}__. * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000016) */ -export function useSystemDictatorGoerliInitialize< +export function useL2ToL1MessagePasserWrite< + TFunctionName extends string, TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof systemDictatorGoerliAddress + TChainId extends number = keyof typeof l2ToL1MessagePasserAddress >( config: TMode extends 'prepared' ? UseContractWriteConfig< PrepareWriteContractResult< - typeof systemDictatorGoerliABI, - 'initialize' + typeof l2ToL1MessagePasserABI, + string >['request']['abi'], - 'initialize', + TFunctionName, TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'initialize' } + > & { address?: Address; chainId?: TChainId } : UseContractWriteConfig< - typeof systemDictatorGoerliABI, - 'initialize', + typeof l2ToL1MessagePasserABI, + TFunctionName, TMode > & { abi?: never address?: never chainId?: TChainId - functionName?: 'initialize' } = {} as any ) { - return useContractWrite({ - abi: systemDictatorGoerliABI, - address: systemDictatorGoerliAddress[5], - functionName: 'initialize', + return useContractWrite({ + abi: l2ToL1MessagePasserABI, + address: l2ToL1MessagePasserAddress[420], ...config, } as any) } /** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemDictatorGoerliABI}__ and `functionName` set to `"renounceOwnership"`. + * Wraps __{@link useContractEvent}__ with `abi` set to __{@link l2ToL1MessagePasserABI}__. * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000016) */ -export function useSystemDictatorGoerliRenounceOwnership< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof systemDictatorGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof systemDictatorGoerliABI, - 'renounceOwnership' - >['request']['abi'], - 'renounceOwnership', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'renounceOwnership' - } - : UseContractWriteConfig< - typeof systemDictatorGoerliABI, - 'renounceOwnership', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'renounceOwnership' - } = {} as any +export function useL2ToL1MessagePasserEvent( + config: Omit< + UseContractEventConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof l2ToL1MessagePasserAddress } = {} as any ) { - return useContractWrite< - typeof systemDictatorGoerliABI, - 'renounceOwnership', - TMode - >({ - abi: systemDictatorGoerliABI, - address: systemDictatorGoerliAddress[5], - functionName: 'renounceOwnership', + return useContractEvent({ + abi: l2ToL1MessagePasserABI, + address: l2ToL1MessagePasserAddress[420], + ...config, + } as UseContractEventConfig) +} + +/** + * Wraps __{@link useContractRead}__ with `abi` set to __{@link mintManagerABI}__. + * + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x5C4e7Ba1E219E47948e6e3F55019A647bA501005) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76) + */ +export function useMintManagerRead< + TFunctionName extends string, + TSelectData = ReadContractResult +>( + config: Omit< + UseContractReadConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof mintManagerAddress } = {} as any +) { + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractRead({ + abi: mintManagerABI, + address: mintManagerAddress[chainId as keyof typeof mintManagerAddress], ...config, - } as any) + } as UseContractReadConfig) } /** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemDictatorGoerliABI}__ and `functionName` set to `"step1"`. + * Wraps __{@link useContractWrite}__ with `abi` set to __{@link mintManagerABI}__. * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x5C4e7Ba1E219E47948e6e3F55019A647bA501005) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76) */ -export function useSystemDictatorGoerliStep1< +export function useMintManagerWrite< + TFunctionName extends string, TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof systemDictatorGoerliAddress + TChainId extends number = keyof typeof mintManagerAddress >( config: TMode extends 'prepared' ? UseContractWriteConfig< PrepareWriteContractResult< - typeof systemDictatorGoerliABI, - 'step1' + typeof mintManagerABI, + string >['request']['abi'], - 'step1', + TFunctionName, TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'step1' } - : UseContractWriteConfig & { + > & { address?: Address; chainId?: TChainId } + : UseContractWriteConfig & { abi?: never address?: never chainId?: TChainId - functionName?: 'step1' } = {} as any ) { - return useContractWrite({ - abi: systemDictatorGoerliABI, - address: systemDictatorGoerliAddress[5], - functionName: 'step1', + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractWrite({ + abi: mintManagerABI, + address: mintManagerAddress[chainId as keyof typeof mintManagerAddress], ...config, } as any) } /** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemDictatorGoerliABI}__ and `functionName` set to `"step2"`. + * Wraps __{@link useContractEvent}__ with `abi` set to __{@link mintManagerABI}__. * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x5C4e7Ba1E219E47948e6e3F55019A647bA501005) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x038a8825A3C3B0c08d52Cc76E5E361953Cf6Dc76) */ -export function useSystemDictatorGoerliStep2< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof systemDictatorGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof systemDictatorGoerliABI, - 'step2' - >['request']['abi'], - 'step2', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'step2' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'step2' - } = {} as any +export function useMintManagerEvent( + config: Omit< + UseContractEventConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof mintManagerAddress } = {} as any ) { - return useContractWrite({ - abi: systemDictatorGoerliABI, - address: systemDictatorGoerliAddress[5], - functionName: 'step2', + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractEvent({ + abi: mintManagerABI, + address: mintManagerAddress[chainId as keyof typeof mintManagerAddress], ...config, - } as any) + } as UseContractEventConfig) } /** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemDictatorGoerliABI}__ and `functionName` set to `"step3"`. + * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismMintableErc20FactoryABI}__. * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) + * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000012) */ -export function useSystemDictatorGoerliStep3< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof systemDictatorGoerliAddress +export function useOptimismMintableErc20FactoryRead< + TFunctionName extends string, + TSelectData = ReadContractResult< + typeof optimismMintableErc20FactoryABI, + TFunctionName + > >( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof systemDictatorGoerliABI, - 'step3' - >['request']['abi'], - 'step3', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'step3' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'step3' - } = {} as any + config: Omit< + UseContractReadConfig< + typeof optimismMintableErc20FactoryABI, + TFunctionName, + TSelectData + >, + 'abi' | 'address' + > & { chainId?: keyof typeof optimismMintableErc20FactoryAddress } = {} as any ) { - return useContractWrite({ - abi: systemDictatorGoerliABI, - address: systemDictatorGoerliAddress[5], - functionName: 'step3', + return useContractRead({ + abi: optimismMintableErc20FactoryABI, + address: optimismMintableErc20FactoryAddress[1], ...config, - } as any) + } as UseContractReadConfig) } /** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemDictatorGoerliABI}__ and `functionName` set to `"step4"`. + * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimismMintableErc20FactoryABI}__. * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) + * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000012) */ -export function useSystemDictatorGoerliStep4< +export function useOptimismMintableErc20FactoryWrite< + TFunctionName extends string, TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof systemDictatorGoerliAddress + TChainId extends number = keyof typeof optimismMintableErc20FactoryAddress >( config: TMode extends 'prepared' ? UseContractWriteConfig< PrepareWriteContractResult< - typeof systemDictatorGoerliABI, - 'step4' + typeof optimismMintableErc20FactoryABI, + string >['request']['abi'], - 'step4', + TFunctionName, + TMode + > & { address?: Address; chainId?: TChainId } + : UseContractWriteConfig< + typeof optimismMintableErc20FactoryABI, + TFunctionName, TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'step4' } - : UseContractWriteConfig & { + > & { abi?: never address?: never chainId?: TChainId - functionName?: 'step4' } = {} as any ) { - return useContractWrite({ - abi: systemDictatorGoerliABI, - address: systemDictatorGoerliAddress[5], - functionName: 'step4', + return useContractWrite< + typeof optimismMintableErc20FactoryABI, + TFunctionName, + TMode + >({ + abi: optimismMintableErc20FactoryABI, + address: optimismMintableErc20FactoryAddress[1], ...config, } as any) } /** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemDictatorGoerliABI}__ and `functionName` set to `"step5"`. + * Wraps __{@link useContractEvent}__ with `abi` set to __{@link optimismMintableErc20FactoryABI}__. * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) + * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000012) */ -export function useSystemDictatorGoerliStep5< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof systemDictatorGoerliAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof systemDictatorGoerliABI, - 'step5' - >['request']['abi'], - 'step5', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'step5' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'step5' - } = {} as any +export function useOptimismMintableErc20FactoryEvent( + config: Omit< + UseContractEventConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof optimismMintableErc20FactoryAddress } = {} as any ) { - return useContractWrite({ - abi: systemDictatorGoerliABI, - address: systemDictatorGoerliAddress[5], - functionName: 'step5', + return useContractEvent({ + abi: optimismMintableErc20FactoryABI, + address: optimismMintableErc20FactoryAddress[1], ...config, - } as any) + } as UseContractEventConfig) } /** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemDictatorGoerliABI}__ and `functionName` set to `"step6"`. + * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismMintableErc20FactoryGoerliABI}__. * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) + * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000012) */ -export function useSystemDictatorGoerliStep6< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof systemDictatorGoerliAddress +export function useOptimismMintableErc20FactoryGoerliRead< + TFunctionName extends string, + TSelectData = ReadContractResult< + typeof optimismMintableErc20FactoryGoerliABI, + TFunctionName + > >( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof systemDictatorGoerliABI, - 'step6' - >['request']['abi'], - 'step6', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'step6' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'step6' - } = {} as any + config: Omit< + UseContractReadConfig< + typeof optimismMintableErc20FactoryGoerliABI, + TFunctionName, + TSelectData + >, + 'abi' | 'address' + > & { + chainId?: keyof typeof optimismMintableErc20FactoryGoerliAddress + } = {} as any ) { - return useContractWrite({ - abi: systemDictatorGoerliABI, - address: systemDictatorGoerliAddress[5], - functionName: 'step6', + return useContractRead({ + abi: optimismMintableErc20FactoryGoerliABI, + address: optimismMintableErc20FactoryGoerliAddress[5], ...config, - } as any) + } as UseContractReadConfig) } /** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemDictatorGoerliABI}__ and `functionName` set to `"transferOwnership"`. + * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimismMintableErc20FactoryGoerliABI}__. * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) + * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000012) */ -export function useSystemDictatorGoerliTransferOwnership< +export function useOptimismMintableErc20FactoryGoerliWrite< + TFunctionName extends string, TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof systemDictatorGoerliAddress + TChainId extends number = keyof typeof optimismMintableErc20FactoryGoerliAddress >( config: TMode extends 'prepared' ? UseContractWriteConfig< PrepareWriteContractResult< - typeof systemDictatorGoerliABI, - 'transferOwnership' + typeof optimismMintableErc20FactoryGoerliABI, + string >['request']['abi'], - 'transferOwnership', + TFunctionName, TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'transferOwnership' - } + > & { address?: Address; chainId?: TChainId } : UseContractWriteConfig< - typeof systemDictatorGoerliABI, - 'transferOwnership', + typeof optimismMintableErc20FactoryGoerliABI, + TFunctionName, TMode > & { abi?: never address?: never chainId?: TChainId - functionName?: 'transferOwnership' } = {} as any ) { - return useContractWrite< - typeof systemDictatorGoerliABI, - 'transferOwnership', - TMode - >({ - abi: systemDictatorGoerliABI, - address: systemDictatorGoerliAddress[5], - functionName: 'transferOwnership', + return useContractWrite< + typeof optimismMintableErc20FactoryGoerliABI, + TFunctionName, + TMode + >({ + abi: optimismMintableErc20FactoryGoerliABI, + address: optimismMintableErc20FactoryGoerliAddress[5], + ...config, + } as any) +} + +/** + * Wraps __{@link useContractEvent}__ with `abi` set to __{@link optimismMintableErc20FactoryGoerliABI}__. + * + * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000012) + */ +export function useOptimismMintableErc20FactoryGoerliEvent< + TEventName extends string +>( + config: Omit< + UseContractEventConfig< + typeof optimismMintableErc20FactoryGoerliABI, + TEventName + >, + 'abi' | 'address' + > & { + chainId?: keyof typeof optimismMintableErc20FactoryGoerliAddress + } = {} as any +) { + return useContractEvent({ + abi: optimismMintableErc20FactoryGoerliABI, + address: optimismMintableErc20FactoryGoerliAddress[5], + ...config, + } as UseContractEventConfig) +} + +/** + * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismMintableErc20FactoryOptimismGoerliABI}__. + * + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000012) + */ +export function useOptimismMintableErc20FactoryOptimismGoerliRead< + TFunctionName extends string, + TSelectData = ReadContractResult< + typeof optimismMintableErc20FactoryOptimismGoerliABI, + TFunctionName + > +>( + config: Omit< + UseContractReadConfig< + typeof optimismMintableErc20FactoryOptimismGoerliABI, + TFunctionName, + TSelectData + >, + 'abi' | 'address' + > & { + chainId?: keyof typeof optimismMintableErc20FactoryOptimismGoerliAddress + } = {} as any +) { + return useContractRead({ + abi: optimismMintableErc20FactoryOptimismGoerliABI, + address: optimismMintableErc20FactoryOptimismGoerliAddress[420], ...config, - } as any) + } as UseContractReadConfig) } /** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemDictatorGoerliABI}__ and `functionName` set to `"updateL2OutputOracleDynamicConfig"`. + * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimismMintableErc20FactoryOptimismGoerliABI}__. * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000012) */ -export function useSystemDictatorGoerliUpdateL2OutputOracleDynamicConfig< +export function useOptimismMintableErc20FactoryOptimismGoerliWrite< + TFunctionName extends string, TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof systemDictatorGoerliAddress + TChainId extends number = keyof typeof optimismMintableErc20FactoryOptimismGoerliAddress >( config: TMode extends 'prepared' ? UseContractWriteConfig< PrepareWriteContractResult< - typeof systemDictatorGoerliABI, - 'updateL2OutputOracleDynamicConfig' + typeof optimismMintableErc20FactoryOptimismGoerliABI, + string >['request']['abi'], - 'updateL2OutputOracleDynamicConfig', + TFunctionName, TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'updateL2OutputOracleDynamicConfig' - } + > & { address?: Address; chainId?: TChainId } : UseContractWriteConfig< - typeof systemDictatorGoerliABI, - 'updateL2OutputOracleDynamicConfig', + typeof optimismMintableErc20FactoryOptimismGoerliABI, + TFunctionName, TMode > & { abi?: never address?: never chainId?: TChainId - functionName?: 'updateL2OutputOracleDynamicConfig' } = {} as any ) { return useContractWrite< - typeof systemDictatorGoerliABI, - 'updateL2OutputOracleDynamicConfig', + typeof optimismMintableErc20FactoryOptimismGoerliABI, + TFunctionName, TMode >({ - abi: systemDictatorGoerliABI, - address: systemDictatorGoerliAddress[5], - functionName: 'updateL2OutputOracleDynamicConfig', + abi: optimismMintableErc20FactoryOptimismGoerliABI, + address: optimismMintableErc20FactoryOptimismGoerliAddress[420], ...config, } as any) } /** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link systemDictatorGoerliABI}__. + * Wraps __{@link useContractEvent}__ with `abi` set to __{@link optimismMintableErc20FactoryOptimismGoerliABI}__. * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000012) */ -export function usePrepareSystemDictatorGoerliWrite< - TFunctionName extends string +export function useOptimismMintableErc20FactoryOptimismGoerliEvent< + TEventName extends string >( config: Omit< - UsePrepareContractWriteConfig< - typeof systemDictatorGoerliABI, - TFunctionName + UseContractEventConfig< + typeof optimismMintableErc20FactoryOptimismGoerliABI, + TEventName >, 'abi' | 'address' - > & { chainId?: keyof typeof systemDictatorGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: systemDictatorGoerliABI, - address: systemDictatorGoerliAddress[5], - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link systemDictatorGoerliABI}__ and `functionName` set to `"exit1"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) - */ -export function usePrepareSystemDictatorGoerliExit1( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemDictatorGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: systemDictatorGoerliABI, - address: systemDictatorGoerliAddress[5], - functionName: 'exit1', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link systemDictatorGoerliABI}__ and `functionName` set to `"finalize"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) - */ -export function usePrepareSystemDictatorGoerliFinalize( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemDictatorGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: systemDictatorGoerliABI, - address: systemDictatorGoerliAddress[5], - functionName: 'finalize', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link systemDictatorGoerliABI}__ and `functionName` set to `"initialize"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) - */ -export function usePrepareSystemDictatorGoerliInitialize( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemDictatorGoerliAddress } = {} as any + > & { + chainId?: keyof typeof optimismMintableErc20FactoryOptimismGoerliAddress + } = {} as any ) { - return usePrepareContractWrite({ - abi: systemDictatorGoerliABI, - address: systemDictatorGoerliAddress[5], - functionName: 'initialize', + return useContractEvent({ + abi: optimismMintableErc20FactoryOptimismGoerliABI, + address: optimismMintableErc20FactoryOptimismGoerliAddress[420], ...config, - } as UsePrepareContractWriteConfig) + } as UseContractEventConfig) } /** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link systemDictatorGoerliABI}__ and `functionName` set to `"renounceOwnership"`. + * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismMintableErc721FactoryABI}__. * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) + * [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000017) */ -export function usePrepareSystemDictatorGoerliRenounceOwnership( +export function useOptimismMintableErc721FactoryRead< + TFunctionName extends string, + TSelectData = ReadContractResult< + typeof optimismMintableErc721FactoryABI, + TFunctionName + > +>( config: Omit< - UsePrepareContractWriteConfig< - typeof systemDictatorGoerliABI, - 'renounceOwnership' + UseContractReadConfig< + typeof optimismMintableErc721FactoryABI, + TFunctionName, + TSelectData >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemDictatorGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: systemDictatorGoerliABI, - address: systemDictatorGoerliAddress[5], - functionName: 'renounceOwnership', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link systemDictatorGoerliABI}__ and `functionName` set to `"step1"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) - */ -export function usePrepareSystemDictatorGoerliStep1( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemDictatorGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: systemDictatorGoerliABI, - address: systemDictatorGoerliAddress[5], - functionName: 'step1', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link systemDictatorGoerliABI}__ and `functionName` set to `"step2"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) - */ -export function usePrepareSystemDictatorGoerliStep2( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemDictatorGoerliAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: systemDictatorGoerliABI, - address: systemDictatorGoerliAddress[5], - functionName: 'step2', - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link systemDictatorGoerliABI}__ and `functionName` set to `"step3"`. - * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) - */ -export function usePrepareSystemDictatorGoerliStep3( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemDictatorGoerliAddress } = {} as any + 'abi' | 'address' + > & { + chainId?: keyof typeof optimismMintableErc721FactoryAddress + } = {} as any ) { - return usePrepareContractWrite({ - abi: systemDictatorGoerliABI, - address: systemDictatorGoerliAddress[5], - functionName: 'step3', + return useContractRead({ + abi: optimismMintableErc721FactoryABI, + address: optimismMintableErc721FactoryAddress[10], ...config, - } as UsePrepareContractWriteConfig) + } as UseContractReadConfig) } /** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link systemDictatorGoerliABI}__ and `functionName` set to `"step4"`. + * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimismMintableErc721FactoryABI}__. * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) + * [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000017) */ -export function usePrepareSystemDictatorGoerliStep4( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemDictatorGoerliAddress } = {} as any +export function useOptimismMintableErc721FactoryWrite< + TFunctionName extends string, + TMode extends WriteContractMode = undefined, + TChainId extends number = keyof typeof optimismMintableErc721FactoryAddress +>( + config: TMode extends 'prepared' + ? UseContractWriteConfig< + PrepareWriteContractResult< + typeof optimismMintableErc721FactoryABI, + string + >['request']['abi'], + TFunctionName, + TMode + > & { address?: Address; chainId?: TChainId } + : UseContractWriteConfig< + typeof optimismMintableErc721FactoryABI, + TFunctionName, + TMode + > & { + abi?: never + address?: never + chainId?: TChainId + } = {} as any ) { - return usePrepareContractWrite({ - abi: systemDictatorGoerliABI, - address: systemDictatorGoerliAddress[5], - functionName: 'step4', + return useContractWrite< + typeof optimismMintableErc721FactoryABI, + TFunctionName, + TMode + >({ + abi: optimismMintableErc721FactoryABI, + address: optimismMintableErc721FactoryAddress[10], ...config, - } as UsePrepareContractWriteConfig) + } as any) } /** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link systemDictatorGoerliABI}__ and `functionName` set to `"step5"`. + * Wraps __{@link useContractEvent}__ with `abi` set to __{@link optimismMintableErc721FactoryABI}__. * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) + * [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x4200000000000000000000000000000000000017) */ -export function usePrepareSystemDictatorGoerliStep5( +export function useOptimismMintableErc721FactoryEvent< + TEventName extends string +>( config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemDictatorGoerliAddress } = {} as any + UseContractEventConfig, + 'abi' | 'address' + > & { + chainId?: keyof typeof optimismMintableErc721FactoryAddress + } = {} as any ) { - return usePrepareContractWrite({ - abi: systemDictatorGoerliABI, - address: systemDictatorGoerliAddress[5], - functionName: 'step5', + return useContractEvent({ + abi: optimismMintableErc721FactoryABI, + address: optimismMintableErc721FactoryAddress[10], ...config, - } as UsePrepareContractWriteConfig) + } as UseContractEventConfig) } /** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link systemDictatorGoerliABI}__ and `functionName` set to `"step6"`. + * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismMintableErc721FactoryOptimismGoerliABI}__. * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000017) */ -export function usePrepareSystemDictatorGoerliStep6( +export function useOptimismMintableErc721FactoryOptimismGoerliRead< + TFunctionName extends string, + TSelectData = ReadContractResult< + typeof optimismMintableErc721FactoryOptimismGoerliABI, + TFunctionName + > +>( config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemDictatorGoerliAddress } = {} as any + UseContractReadConfig< + typeof optimismMintableErc721FactoryOptimismGoerliABI, + TFunctionName, + TSelectData + >, + 'abi' | 'address' + > & { + chainId?: keyof typeof optimismMintableErc721FactoryOptimismGoerliAddress + } = {} as any ) { - return usePrepareContractWrite({ - abi: systemDictatorGoerliABI, - address: systemDictatorGoerliAddress[5], - functionName: 'step6', + return useContractRead({ + abi: optimismMintableErc721FactoryOptimismGoerliABI, + address: optimismMintableErc721FactoryOptimismGoerliAddress[420], ...config, - } as UsePrepareContractWriteConfig) + } as UseContractReadConfig) } /** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link systemDictatorGoerliABI}__ and `functionName` set to `"transferOwnership"`. + * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimismMintableErc721FactoryOptimismGoerliABI}__. * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000017) */ -export function usePrepareSystemDictatorGoerliTransferOwnership( - config: Omit< - UsePrepareContractWriteConfig< - typeof systemDictatorGoerliABI, - 'transferOwnership' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemDictatorGoerliAddress } = {} as any +export function useOptimismMintableErc721FactoryOptimismGoerliWrite< + TFunctionName extends string, + TMode extends WriteContractMode = undefined, + TChainId extends number = keyof typeof optimismMintableErc721FactoryOptimismGoerliAddress +>( + config: TMode extends 'prepared' + ? UseContractWriteConfig< + PrepareWriteContractResult< + typeof optimismMintableErc721FactoryOptimismGoerliABI, + string + >['request']['abi'], + TFunctionName, + TMode + > & { address?: Address; chainId?: TChainId } + : UseContractWriteConfig< + typeof optimismMintableErc721FactoryOptimismGoerliABI, + TFunctionName, + TMode + > & { + abi?: never + address?: never + chainId?: TChainId + } = {} as any ) { - return usePrepareContractWrite({ - abi: systemDictatorGoerliABI, - address: systemDictatorGoerliAddress[5], - functionName: 'transferOwnership', + return useContractWrite< + typeof optimismMintableErc721FactoryOptimismGoerliABI, + TFunctionName, + TMode + >({ + abi: optimismMintableErc721FactoryOptimismGoerliABI, + address: optimismMintableErc721FactoryOptimismGoerliAddress[420], ...config, - } as UsePrepareContractWriteConfig) + } as any) } /** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link systemDictatorGoerliABI}__ and `functionName` set to `"updateL2OutputOracleDynamicConfig"`. + * Wraps __{@link useContractEvent}__ with `abi` set to __{@link optimismMintableErc721FactoryOptimismGoerliABI}__. * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000017) */ -export function usePrepareSystemDictatorGoerliUpdateL2OutputOracleDynamicConfig( +export function useOptimismMintableErc721FactoryOptimismGoerliEvent< + TEventName extends string +>( config: Omit< - UsePrepareContractWriteConfig< - typeof systemDictatorGoerliABI, - 'updateL2OutputOracleDynamicConfig' + UseContractEventConfig< + typeof optimismMintableErc721FactoryOptimismGoerliABI, + TEventName >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof systemDictatorGoerliAddress } = {} as any + 'abi' | 'address' + > & { + chainId?: keyof typeof optimismMintableErc721FactoryOptimismGoerliAddress + } = {} as any ) { - return usePrepareContractWrite({ - abi: systemDictatorGoerliABI, - address: systemDictatorGoerliAddress[5], - functionName: 'updateL2OutputOracleDynamicConfig', + return useContractEvent({ + abi: optimismMintableErc721FactoryOptimismGoerliABI, + address: optimismMintableErc721FactoryOptimismGoerliAddress[420], ...config, - } as UsePrepareContractWriteConfig) + } as UseContractEventConfig) } /** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link systemDictatorGoerliABI}__. + * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimismPortalABI}__. * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) */ -export function useSystemDictatorGoerliEvent( +export function useOptimismPortalRead< + TFunctionName extends string, + TSelectData = ReadContractResult +>( config: Omit< - UseContractEventConfig, + UseContractReadConfig, 'abi' | 'address' - > & { chainId?: keyof typeof systemDictatorGoerliAddress } = {} as any + > & { chainId?: keyof typeof optimismPortalAddress } = {} as any ) { - return useContractEvent({ - abi: systemDictatorGoerliABI, - address: systemDictatorGoerliAddress[5], + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractRead({ + abi: optimismPortalABI, + address: + optimismPortalAddress[chainId as keyof typeof optimismPortalAddress], ...config, - } as UseContractEventConfig) + } as UseContractReadConfig) } /** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link systemDictatorGoerliABI}__ and `eventName` set to `"Initialized"`. + * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimismPortalABI}__. * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) */ -export function useSystemDictatorGoerliInitializedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof systemDictatorGoerliAddress } = {} as any +export function useOptimismPortalWrite< + TFunctionName extends string, + TMode extends WriteContractMode = undefined, + TChainId extends number = keyof typeof optimismPortalAddress +>( + config: TMode extends 'prepared' + ? UseContractWriteConfig< + PrepareWriteContractResult< + typeof optimismPortalABI, + string + >['request']['abi'], + TFunctionName, + TMode + > & { address?: Address; chainId?: TChainId } + : UseContractWriteConfig & { + abi?: never + address?: never + chainId?: TChainId + } = {} as any ) { - return useContractEvent({ - abi: systemDictatorGoerliABI, - address: systemDictatorGoerliAddress[5], - eventName: 'Initialized', + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractWrite({ + abi: optimismPortalABI, + address: + optimismPortalAddress[chainId as keyof typeof optimismPortalAddress], ...config, - } as UseContractEventConfig) + } as any) } /** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link systemDictatorGoerliABI}__ and `eventName` set to `"OwnershipTransferred"`. + * Wraps __{@link useContractEvent}__ with `abi` set to __{@link optimismPortalABI}__. * - * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xbEb5Fc579115071764c7423A4f12eDde41f106Ed) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x5b47E1A08Ea6d985D6649300584e6722Ec4B1383) */ -export function useSystemDictatorGoerliOwnershipTransferredEvent( +export function useOptimismPortalEvent( config: Omit< - UseContractEventConfig< - typeof systemDictatorGoerliABI, - 'OwnershipTransferred' - >, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof systemDictatorGoerliAddress } = {} as any + UseContractEventConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof optimismPortalAddress } = {} as any ) { + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId return useContractEvent({ - abi: systemDictatorGoerliABI, - address: systemDictatorGoerliAddress[5], - eventName: 'OwnershipTransferred', + abi: optimismPortalABI, + address: + optimismPortalAddress[chainId as keyof typeof optimismPortalAddress], ...config, - } as UseContractEventConfig) + } as UseContractEventConfig) } /** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link teleportrWithdrawerABI}__. + * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimistABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) */ -export function useTeleportrWithdrawerRead< +export function useOptimistRead< TFunctionName extends string, - TSelectData = ReadContractResult + TSelectData = ReadContractResult >( config: Omit< - UseContractReadConfig< - typeof teleportrWithdrawerABI, - TFunctionName, - TSelectData - >, + UseContractReadConfig, 'abi' | 'address' - > & { chainId?: keyof typeof teleportrWithdrawerAddress } = {} as any + > & { chainId?: keyof typeof optimistAddress } = {} as any ) { + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId return useContractRead({ - abi: teleportrWithdrawerABI, - address: teleportrWithdrawerAddress[1], + abi: optimistABI, + address: optimistAddress[chainId as keyof typeof optimistAddress], ...config, - } as UseContractReadConfig) + } as UseContractReadConfig) } /** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link teleportrWithdrawerABI}__ and `functionName` set to `"data"`. + * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimistABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) */ -export function useTeleportrWithdrawerData< - TFunctionName extends 'data', - TSelectData = ReadContractResult +export function useOptimistWrite< + TFunctionName extends string, + TMode extends WriteContractMode = undefined, + TChainId extends number = keyof typeof optimistAddress >( - config: Omit< - UseContractReadConfig< - typeof teleportrWithdrawerABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof teleportrWithdrawerAddress } = {} as any + config: TMode extends 'prepared' + ? UseContractWriteConfig< + PrepareWriteContractResult< + typeof optimistABI, + string + >['request']['abi'], + TFunctionName, + TMode + > & { address?: Address; chainId?: TChainId } + : UseContractWriteConfig & { + abi?: never + address?: never + chainId?: TChainId + } = {} as any ) { - return useContractRead({ - abi: teleportrWithdrawerABI, - address: teleportrWithdrawerAddress[1], - functionName: 'data', + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractWrite({ + abi: optimistABI, + address: optimistAddress[chainId as keyof typeof optimistAddress], ...config, - } as UseContractReadConfig) + } as any) } /** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link teleportrWithdrawerABI}__ and `functionName` set to `"owner"`. + * Wraps __{@link useContractEvent}__ with `abi` set to __{@link optimistABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2335022c740d17c2837f9C884Bfe4fFdbf0A95D5) */ -export function useTeleportrWithdrawerOwner< - TFunctionName extends 'owner', - TSelectData = ReadContractResult ->( +export function useOptimistEvent( config: Omit< - UseContractReadConfig< - typeof teleportrWithdrawerABI, - TFunctionName, - TSelectData - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof teleportrWithdrawerAddress } = {} as any + UseContractEventConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof optimistAddress } = {} as any ) { - return useContractRead({ - abi: teleportrWithdrawerABI, - address: teleportrWithdrawerAddress[1], - functionName: 'owner', + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractEvent({ + abi: optimistABI, + address: optimistAddress[chainId as keyof typeof optimistAddress], ...config, - } as UseContractReadConfig) + } as UseContractEventConfig) } /** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link teleportrWithdrawerABI}__ and `functionName` set to `"recipient"`. + * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimistAllowlistABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x482b1945D58f2E9Db0CEbe13c7fcFc6876b41180) */ -export function useTeleportrWithdrawerRecipient< - TFunctionName extends 'recipient', - TSelectData = ReadContractResult +export function useOptimistAllowlistRead< + TFunctionName extends string, + TSelectData = ReadContractResult >( config: Omit< UseContractReadConfig< - typeof teleportrWithdrawerABI, + typeof optimistAllowlistABI, TFunctionName, TSelectData >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof teleportrWithdrawerAddress } = {} as any + 'abi' | 'address' + > & { chainId?: keyof typeof optimistAllowlistAddress } = {} as any ) { + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId return useContractRead({ - abi: teleportrWithdrawerABI, - address: teleportrWithdrawerAddress[1], - functionName: 'recipient', + abi: optimistAllowlistABI, + address: + optimistAllowlistAddress[ + chainId as keyof typeof optimistAllowlistAddress + ], ...config, - } as UseContractReadConfig) + } as UseContractReadConfig) } /** - * Wraps __{@link useContractRead}__ with `abi` set to __{@link teleportrWithdrawerABI}__ and `functionName` set to `"teleportr"`. + * Wraps __{@link useContractRead}__ with `abi` set to __{@link optimistInviterABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) */ -export function useTeleportrWithdrawerTeleportr< - TFunctionName extends 'teleportr', - TSelectData = ReadContractResult +export function useOptimistInviterRead< + TFunctionName extends string, + TSelectData = ReadContractResult >( config: Omit< UseContractReadConfig< - typeof teleportrWithdrawerABI, + typeof optimistInviterABI, TFunctionName, TSelectData >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof teleportrWithdrawerAddress } = {} as any + 'abi' | 'address' + > & { chainId?: keyof typeof optimistInviterAddress } = {} as any ) { + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId return useContractRead({ - abi: teleportrWithdrawerABI, - address: teleportrWithdrawerAddress[1], - functionName: 'teleportr', + abi: optimistInviterABI, + address: + optimistInviterAddress[chainId as keyof typeof optimistInviterAddress], ...config, - } as UseContractReadConfig) + } as UseContractReadConfig) } /** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link teleportrWithdrawerABI}__. + * Wraps __{@link useContractWrite}__ with `abi` set to __{@link optimistInviterABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) */ -export function useTeleportrWithdrawerWrite< +export function useOptimistInviterWrite< TFunctionName extends string, TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof teleportrWithdrawerAddress + TChainId extends number = keyof typeof optimistInviterAddress >( config: TMode extends 'prepared' ? UseContractWriteConfig< PrepareWriteContractResult< - typeof teleportrWithdrawerABI, + typeof optimistInviterABI, string >['request']['abi'], TFunctionName, TMode > & { address?: Address; chainId?: TChainId } : UseContractWriteConfig< - typeof teleportrWithdrawerABI, + typeof optimistInviterABI, TFunctionName, TMode > & { @@ -39593,762 +11533,741 @@ export function useTeleportrWithdrawerWrite< chainId?: TChainId } = {} as any ) { - return useContractWrite({ - abi: teleportrWithdrawerABI, - address: teleportrWithdrawerAddress[1], + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractWrite({ + abi: optimistInviterABI, + address: + optimistInviterAddress[chainId as keyof typeof optimistInviterAddress], ...config, } as any) } /** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link teleportrWithdrawerABI}__ and `functionName` set to `"CALL"`. + * Wraps __{@link useContractEvent}__ with `abi` set to __{@link optimistInviterABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x073031A1E1b8F5458Ed41Ce56331F5fd7e1de929) */ -export function useTeleportrWithdrawerCall< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof teleportrWithdrawerAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof teleportrWithdrawerABI, - 'CALL' - >['request']['abi'], - 'CALL', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'CALL' } - : UseContractWriteConfig & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'CALL' - } = {} as any +export function useOptimistInviterEvent( + config: Omit< + UseContractEventConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof optimistInviterAddress } = {} as any ) { - return useContractWrite({ - abi: teleportrWithdrawerABI, - address: teleportrWithdrawerAddress[1], - functionName: 'CALL', + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractEvent({ + abi: optimistInviterABI, + address: + optimistInviterAddress[chainId as keyof typeof optimistInviterAddress], ...config, - } as any) + } as UseContractEventConfig) } /** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link teleportrWithdrawerABI}__ and `functionName` set to `"DELEGATECALL"`. + * Wraps __{@link useContractRead}__ with `abi` set to __{@link portalSenderABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x0A893d9576b9cFD9EF78595963dc973238E78210) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xe7FACd39531ee3C313330E93B4d7a8B8A3c84Aa4) */ -export function useTeleportrWithdrawerDelegatecall< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof teleportrWithdrawerAddress +export function usePortalSenderRead< + TFunctionName extends string, + TSelectData = ReadContractResult >( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof teleportrWithdrawerABI, - 'DELEGATECALL' - >['request']['abi'], - 'DELEGATECALL', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'DELEGATECALL' - } - : UseContractWriteConfig< - typeof teleportrWithdrawerABI, - 'DELEGATECALL', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'DELEGATECALL' - } = {} as any + config: Omit< + UseContractReadConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof portalSenderAddress } = {} as any ) { - return useContractWrite( - { - abi: teleportrWithdrawerABI, - address: teleportrWithdrawerAddress[1], - functionName: 'DELEGATECALL', - ...config, - } as any - ) + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractRead({ + abi: portalSenderABI, + address: portalSenderAddress[chainId as keyof typeof portalSenderAddress], + ...config, + } as UseContractReadConfig) } /** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link teleportrWithdrawerABI}__ and `functionName` set to `"setData"`. + * Wraps __{@link useContractWrite}__ with `abi` set to __{@link portalSenderABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x0A893d9576b9cFD9EF78595963dc973238E78210) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xe7FACd39531ee3C313330E93B4d7a8B8A3c84Aa4) */ -export function useTeleportrWithdrawerSetData< +export function usePortalSenderWrite< + TFunctionName extends string, TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof teleportrWithdrawerAddress + TChainId extends number = keyof typeof portalSenderAddress >( config: TMode extends 'prepared' ? UseContractWriteConfig< PrepareWriteContractResult< - typeof teleportrWithdrawerABI, - 'setData' + typeof portalSenderABI, + string >['request']['abi'], - 'setData', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'setData' } - : UseContractWriteConfig< - typeof teleportrWithdrawerABI, - 'setData', + TFunctionName, TMode - > & { + > & { address?: Address; chainId?: TChainId } + : UseContractWriteConfig & { abi?: never address?: never chainId?: TChainId - functionName?: 'setData' } = {} as any ) { - return useContractWrite({ - abi: teleportrWithdrawerABI, - address: teleportrWithdrawerAddress[1], - functionName: 'setData', + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractWrite({ + abi: portalSenderABI, + address: portalSenderAddress[chainId as keyof typeof portalSenderAddress], ...config, } as any) } /** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link teleportrWithdrawerABI}__ and `functionName` set to `"setOwner"`. + * Wraps __{@link useContractRead}__ with `abi` set to __{@link protocolVersionsABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) + * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) */ -export function useTeleportrWithdrawerSetOwner< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof teleportrWithdrawerAddress +export function useProtocolVersionsRead< + TFunctionName extends string, + TSelectData = ReadContractResult >( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof teleportrWithdrawerABI, - 'setOwner' - >['request']['abi'], - 'setOwner', - TMode - > & { address?: Address; chainId?: TChainId; functionName?: 'setOwner' } - : UseContractWriteConfig< - typeof teleportrWithdrawerABI, - 'setOwner', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'setOwner' - } = {} as any + config: Omit< + UseContractReadConfig< + typeof protocolVersionsABI, + TFunctionName, + TSelectData + >, + 'abi' | 'address' + > & { chainId?: keyof typeof protocolVersionsAddress } = {} as any ) { - return useContractWrite({ - abi: teleportrWithdrawerABI, - address: teleportrWithdrawerAddress[1], - functionName: 'setOwner', + return useContractRead({ + abi: protocolVersionsABI, + address: protocolVersionsAddress[5], ...config, - } as any) + } as UseContractReadConfig) } /** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link teleportrWithdrawerABI}__ and `functionName` set to `"setRecipient"`. + * Wraps __{@link useContractWrite}__ with `abi` set to __{@link protocolVersionsABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) + * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) */ -export function useTeleportrWithdrawerSetRecipient< +export function useProtocolVersionsWrite< + TFunctionName extends string, TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof teleportrWithdrawerAddress + TChainId extends number = keyof typeof protocolVersionsAddress >( config: TMode extends 'prepared' ? UseContractWriteConfig< PrepareWriteContractResult< - typeof teleportrWithdrawerABI, - 'setRecipient' + typeof protocolVersionsABI, + string >['request']['abi'], - 'setRecipient', + TFunctionName, TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'setRecipient' - } + > & { address?: Address; chainId?: TChainId } : UseContractWriteConfig< - typeof teleportrWithdrawerABI, - 'setRecipient', + typeof protocolVersionsABI, + TFunctionName, TMode > & { abi?: never address?: never chainId?: TChainId - functionName?: 'setRecipient' } = {} as any ) { - return useContractWrite( - { - abi: teleportrWithdrawerABI, - address: teleportrWithdrawerAddress[1], - functionName: 'setRecipient', - ...config, - } as any - ) + return useContractWrite({ + abi: protocolVersionsABI, + address: protocolVersionsAddress[5], + ...config, + } as any) } /** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link teleportrWithdrawerABI}__ and `functionName` set to `"setTeleportr"`. + * Wraps __{@link useContractEvent}__ with `abi` set to __{@link protocolVersionsABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) + * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x0C24F5098774aA366827D667494e9F889f7cFc08) */ -export function useTeleportrWithdrawerSetTeleportr< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof teleportrWithdrawerAddress +export function useProtocolVersionsEvent( + config: Omit< + UseContractEventConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof protocolVersionsAddress } = {} as any +) { + return useContractEvent({ + abi: protocolVersionsABI, + address: protocolVersionsAddress[5], + ...config, + } as UseContractEventConfig) +} + +/** + * Wraps __{@link useContractRead}__ with `abi` set to __{@link proxyAdminABI}__. + * + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) + */ +export function useProxyAdminRead< + TFunctionName extends string, + TSelectData = ReadContractResult >( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof teleportrWithdrawerABI, - 'setTeleportr' - >['request']['abi'], - 'setTeleportr', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'setTeleportr' - } - : UseContractWriteConfig< - typeof teleportrWithdrawerABI, - 'setTeleportr', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'setTeleportr' - } = {} as any + config: Omit< + UseContractReadConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof proxyAdminAddress } = {} as any ) { - return useContractWrite( - { - abi: teleportrWithdrawerABI, - address: teleportrWithdrawerAddress[1], - functionName: 'setTeleportr', - ...config, - } as any - ) + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractRead({ + abi: proxyAdminABI, + address: proxyAdminAddress[chainId as keyof typeof proxyAdminAddress], + ...config, + } as UseContractReadConfig) } /** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link teleportrWithdrawerABI}__ and `functionName` set to `"withdrawERC20"`. + * Wraps __{@link useContractWrite}__ with `abi` set to __{@link proxyAdminABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) */ -export function useTeleportrWithdrawerWithdrawErc20< +export function useProxyAdminWrite< + TFunctionName extends string, TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof teleportrWithdrawerAddress + TChainId extends number = keyof typeof proxyAdminAddress >( config: TMode extends 'prepared' ? UseContractWriteConfig< PrepareWriteContractResult< - typeof teleportrWithdrawerABI, - 'withdrawERC20' + typeof proxyAdminABI, + string >['request']['abi'], - 'withdrawERC20', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'withdrawERC20' - } - : UseContractWriteConfig< - typeof teleportrWithdrawerABI, - 'withdrawERC20', + TFunctionName, TMode - > & { + > & { address?: Address; chainId?: TChainId } + : UseContractWriteConfig & { abi?: never address?: never chainId?: TChainId - functionName?: 'withdrawERC20' } = {} as any ) { - return useContractWrite< - typeof teleportrWithdrawerABI, - 'withdrawERC20', - TMode - >({ - abi: teleportrWithdrawerABI, - address: teleportrWithdrawerAddress[1], - functionName: 'withdrawERC20', + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractWrite({ + abi: proxyAdminABI, + address: proxyAdminAddress[chainId as keyof typeof proxyAdminAddress], ...config, } as any) } /** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link teleportrWithdrawerABI}__ and `functionName` set to `"withdrawERC721"`. + * Wraps __{@link useContractEvent}__ with `abi` set to __{@link proxyAdminABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x4200000000000000000000000000000000000018) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x4200000000000000000000000000000000000018) */ -export function useTeleportrWithdrawerWithdrawErc721< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof teleportrWithdrawerAddress ->( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof teleportrWithdrawerABI, - 'withdrawERC721' - >['request']['abi'], - 'withdrawERC721', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'withdrawERC721' - } - : UseContractWriteConfig< - typeof teleportrWithdrawerABI, - 'withdrawERC721', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'withdrawERC721' - } = {} as any +export function useProxyAdminEvent( + config: Omit< + UseContractEventConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof proxyAdminAddress } = {} as any ) { - return useContractWrite< - typeof teleportrWithdrawerABI, - 'withdrawERC721', - TMode - >({ - abi: teleportrWithdrawerABI, - address: teleportrWithdrawerAddress[1], - functionName: 'withdrawERC721', + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractEvent({ + abi: proxyAdminABI, + address: proxyAdminAddress[chainId as keyof typeof proxyAdminAddress], ...config, - } as any) + } as UseContractEventConfig) } /** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link teleportrWithdrawerABI}__ and `functionName` set to `"withdrawETH"`. + * Wraps __{@link useContractRead}__ with `abi` set to __{@link schemaRegistryABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x6232208d66bAc2305b46b4Cb6BCB3857B298DF13) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2545fa928d5d278cA75Fd47306e4a89096ff6403) */ -export function useTeleportrWithdrawerWithdrawEth< - TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof teleportrWithdrawerAddress +export function useSchemaRegistryRead< + TFunctionName extends string, + TSelectData = ReadContractResult >( - config: TMode extends 'prepared' - ? UseContractWriteConfig< - PrepareWriteContractResult< - typeof teleportrWithdrawerABI, - 'withdrawETH' - >['request']['abi'], - 'withdrawETH', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'withdrawETH' - } - : UseContractWriteConfig< - typeof teleportrWithdrawerABI, - 'withdrawETH', - TMode - > & { - abi?: never - address?: never - chainId?: TChainId - functionName?: 'withdrawETH' - } = {} as any + config: Omit< + UseContractReadConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof schemaRegistryAddress } = {} as any ) { - return useContractWrite({ - abi: teleportrWithdrawerABI, - address: teleportrWithdrawerAddress[1], - functionName: 'withdrawETH', + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractRead({ + abi: schemaRegistryABI, + address: + schemaRegistryAddress[chainId as keyof typeof schemaRegistryAddress], ...config, - } as any) + } as UseContractReadConfig) } /** - * Wraps __{@link useContractWrite}__ with `abi` set to __{@link teleportrWithdrawerABI}__ and `functionName` set to `"withdrawFromTeleportr"`. + * Wraps __{@link useContractWrite}__ with `abi` set to __{@link schemaRegistryABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x6232208d66bAc2305b46b4Cb6BCB3857B298DF13) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2545fa928d5d278cA75Fd47306e4a89096ff6403) */ -export function useTeleportrWithdrawerWithdrawFromTeleportr< +export function useSchemaRegistryWrite< + TFunctionName extends string, TMode extends WriteContractMode = undefined, - TChainId extends number = keyof typeof teleportrWithdrawerAddress + TChainId extends number = keyof typeof schemaRegistryAddress >( config: TMode extends 'prepared' ? UseContractWriteConfig< PrepareWriteContractResult< - typeof teleportrWithdrawerABI, - 'withdrawFromTeleportr' + typeof schemaRegistryABI, + string >['request']['abi'], - 'withdrawFromTeleportr', - TMode - > & { - address?: Address - chainId?: TChainId - functionName?: 'withdrawFromTeleportr' - } - : UseContractWriteConfig< - typeof teleportrWithdrawerABI, - 'withdrawFromTeleportr', + TFunctionName, TMode - > & { + > & { address?: Address; chainId?: TChainId } + : UseContractWriteConfig & { abi?: never address?: never chainId?: TChainId - functionName?: 'withdrawFromTeleportr' } = {} as any ) { - return useContractWrite< - typeof teleportrWithdrawerABI, - 'withdrawFromTeleportr', - TMode - >({ - abi: teleportrWithdrawerABI, - address: teleportrWithdrawerAddress[1], - functionName: 'withdrawFromTeleportr', + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractWrite({ + abi: schemaRegistryABI, + address: + schemaRegistryAddress[chainId as keyof typeof schemaRegistryAddress], ...config, } as any) } /** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link teleportrWithdrawerABI}__. + * Wraps __{@link useContractEvent}__ with `abi` set to __{@link schemaRegistryABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) + * - [__View Contract on Op Mainnet Optimism Explorer__](https://explorer.optimism.io/address/0x6232208d66bAc2305b46b4Cb6BCB3857B298DF13) + * - [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x2545fa928d5d278cA75Fd47306e4a89096ff6403) */ -export function usePrepareTeleportrWithdrawerWrite< - TFunctionName extends string ->( +export function useSchemaRegistryEvent( config: Omit< - UsePrepareContractWriteConfig, + UseContractEventConfig, 'abi' | 'address' - > & { chainId?: keyof typeof teleportrWithdrawerAddress } = {} as any -) { - return usePrepareContractWrite({ - abi: teleportrWithdrawerABI, - address: teleportrWithdrawerAddress[1], - ...config, - } as UsePrepareContractWriteConfig) -} - -/** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link teleportrWithdrawerABI}__ and `functionName` set to `"CALL"`. - * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) - */ -export function usePrepareTeleportrWithdrawerCall( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof teleportrWithdrawerAddress } = {} as any + > & { chainId?: keyof typeof schemaRegistryAddress } = {} as any ) { - return usePrepareContractWrite({ - abi: teleportrWithdrawerABI, - address: teleportrWithdrawerAddress[1], - functionName: 'CALL', + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractEvent({ + abi: schemaRegistryABI, + address: + schemaRegistryAddress[chainId as keyof typeof schemaRegistryAddress], ...config, - } as UsePrepareContractWriteConfig) + } as UseContractEventConfig) } /** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link teleportrWithdrawerABI}__ and `functionName` set to `"DELEGATECALL"`. + * Wraps __{@link useContractRead}__ with `abi` set to __{@link sequencerFeeVaultABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000011) */ -export function usePrepareTeleportrWithdrawerDelegatecall( +export function useSequencerFeeVaultRead< + TFunctionName extends string, + TSelectData = ReadContractResult +>( config: Omit< - UsePrepareContractWriteConfig< - typeof teleportrWithdrawerABI, - 'DELEGATECALL' + UseContractReadConfig< + typeof sequencerFeeVaultABI, + TFunctionName, + TSelectData >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof teleportrWithdrawerAddress } = {} as any + 'abi' | 'address' + > & { chainId?: keyof typeof sequencerFeeVaultAddress } = {} as any ) { - return usePrepareContractWrite({ - abi: teleportrWithdrawerABI, - address: teleportrWithdrawerAddress[1], - functionName: 'DELEGATECALL', + return useContractRead({ + abi: sequencerFeeVaultABI, + address: sequencerFeeVaultAddress[420], ...config, - } as UsePrepareContractWriteConfig) + } as UseContractReadConfig) } /** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link teleportrWithdrawerABI}__ and `functionName` set to `"setData"`. + * Wraps __{@link useContractWrite}__ with `abi` set to __{@link sequencerFeeVaultABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000011) */ -export function usePrepareTeleportrWithdrawerSetData( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof teleportrWithdrawerAddress } = {} as any +export function useSequencerFeeVaultWrite< + TFunctionName extends string, + TMode extends WriteContractMode = undefined, + TChainId extends number = keyof typeof sequencerFeeVaultAddress +>( + config: TMode extends 'prepared' + ? UseContractWriteConfig< + PrepareWriteContractResult< + typeof sequencerFeeVaultABI, + string + >['request']['abi'], + TFunctionName, + TMode + > & { address?: Address; chainId?: TChainId } + : UseContractWriteConfig< + typeof sequencerFeeVaultABI, + TFunctionName, + TMode + > & { + abi?: never + address?: never + chainId?: TChainId + } = {} as any ) { - return usePrepareContractWrite({ - abi: teleportrWithdrawerABI, - address: teleportrWithdrawerAddress[1], - functionName: 'setData', + return useContractWrite({ + abi: sequencerFeeVaultABI, + address: sequencerFeeVaultAddress[420], ...config, - } as UsePrepareContractWriteConfig) + } as any) } /** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link teleportrWithdrawerABI}__ and `functionName` set to `"setOwner"`. + * Wraps __{@link useContractEvent}__ with `abi` set to __{@link sequencerFeeVaultABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) + * [__View Contract on Optimism Goerli Etherscan__](https://goerli-optimism.etherscan.io/address/0x4200000000000000000000000000000000000011) */ -export function usePrepareTeleportrWithdrawerSetOwner( +export function useSequencerFeeVaultEvent( config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof teleportrWithdrawerAddress } = {} as any + UseContractEventConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof sequencerFeeVaultAddress } = {} as any ) { - return usePrepareContractWrite({ - abi: teleportrWithdrawerABI, - address: teleportrWithdrawerAddress[1], - functionName: 'setOwner', + return useContractEvent({ + abi: sequencerFeeVaultABI, + address: sequencerFeeVaultAddress[420], ...config, - } as UsePrepareContractWriteConfig) + } as UseContractEventConfig) } /** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link teleportrWithdrawerABI}__ and `functionName` set to `"setRecipient"`. + * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemConfigABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) */ -export function usePrepareTeleportrWithdrawerSetRecipient( - config: Omit< - UsePrepareContractWriteConfig< - typeof teleportrWithdrawerABI, - 'setRecipient' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof teleportrWithdrawerAddress } = {} as any +export function useSystemConfigRead< + TFunctionName extends string, + TSelectData = ReadContractResult +>( + config: Omit< + UseContractReadConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof systemConfigAddress } = {} as any ) { - return usePrepareContractWrite({ - abi: teleportrWithdrawerABI, - address: teleportrWithdrawerAddress[1], - functionName: 'setRecipient', + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractRead({ + abi: systemConfigABI, + address: systemConfigAddress[chainId as keyof typeof systemConfigAddress], ...config, - } as UsePrepareContractWriteConfig) + } as UseContractReadConfig) } /** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link teleportrWithdrawerABI}__ and `functionName` set to `"setTeleportr"`. + * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemConfigABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) */ -export function usePrepareTeleportrWithdrawerSetTeleportr( - config: Omit< - UsePrepareContractWriteConfig< - typeof teleportrWithdrawerABI, - 'setTeleportr' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof teleportrWithdrawerAddress } = {} as any +export function useSystemConfigWrite< + TFunctionName extends string, + TMode extends WriteContractMode = undefined, + TChainId extends number = keyof typeof systemConfigAddress +>( + config: TMode extends 'prepared' + ? UseContractWriteConfig< + PrepareWriteContractResult< + typeof systemConfigABI, + string + >['request']['abi'], + TFunctionName, + TMode + > & { address?: Address; chainId?: TChainId } + : UseContractWriteConfig & { + abi?: never + address?: never + chainId?: TChainId + } = {} as any ) { - return usePrepareContractWrite({ - abi: teleportrWithdrawerABI, - address: teleportrWithdrawerAddress[1], - functionName: 'setTeleportr', + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractWrite({ + abi: systemConfigABI, + address: systemConfigAddress[chainId as keyof typeof systemConfigAddress], ...config, - } as UsePrepareContractWriteConfig) + } as any) } /** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link teleportrWithdrawerABI}__ and `functionName` set to `"withdrawERC20"`. + * Wraps __{@link useContractEvent}__ with `abi` set to __{@link systemConfigABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) + * - [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x229047fed2591dbec1eF1118d64F7aF3dB9EB290) + * - [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0xAe851f927Ee40dE99aaBb7461C00f9622ab91d60) */ -export function usePrepareTeleportrWithdrawerWithdrawErc20( +export function useSystemConfigEvent( config: Omit< - UsePrepareContractWriteConfig< - typeof teleportrWithdrawerABI, - 'withdrawERC20' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof teleportrWithdrawerAddress } = {} as any + UseContractEventConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof systemConfigAddress } = {} as any ) { - return usePrepareContractWrite({ - abi: teleportrWithdrawerABI, - address: teleportrWithdrawerAddress[1], - functionName: 'withdrawERC20', + const { chain } = useNetwork() + const defaultChainId = useChainId() + const chainId = config.chainId ?? chain?.id ?? defaultChainId + return useContractEvent({ + abi: systemConfigABI, + address: systemConfigAddress[chainId as keyof typeof systemConfigAddress], ...config, - } as UsePrepareContractWriteConfig) + } as UseContractEventConfig) } /** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link teleportrWithdrawerABI}__ and `functionName` set to `"withdrawERC721"`. + * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemDictatorABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) + * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) */ -export function usePrepareTeleportrWithdrawerWithdrawErc721( +export function useSystemDictatorRead< + TFunctionName extends string, + TSelectData = ReadContractResult +>( config: Omit< - UsePrepareContractWriteConfig< - typeof teleportrWithdrawerABI, - 'withdrawERC721' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof teleportrWithdrawerAddress } = {} as any + UseContractReadConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof systemDictatorAddress } = {} as any ) { - return usePrepareContractWrite({ - abi: teleportrWithdrawerABI, - address: teleportrWithdrawerAddress[1], - functionName: 'withdrawERC721', + return useContractRead({ + abi: systemDictatorABI, + address: systemDictatorAddress[1], ...config, - } as UsePrepareContractWriteConfig) + } as UseContractReadConfig) } /** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link teleportrWithdrawerABI}__ and `functionName` set to `"withdrawETH"`. + * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemDictatorABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) + * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) */ -export function usePrepareTeleportrWithdrawerWithdrawEth( - config: Omit< - UsePrepareContractWriteConfig, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof teleportrWithdrawerAddress } = {} as any +export function useSystemDictatorWrite< + TFunctionName extends string, + TMode extends WriteContractMode = undefined, + TChainId extends number = keyof typeof systemDictatorAddress +>( + config: TMode extends 'prepared' + ? UseContractWriteConfig< + PrepareWriteContractResult< + typeof systemDictatorABI, + string + >['request']['abi'], + TFunctionName, + TMode + > & { address?: Address; chainId?: TChainId } + : UseContractWriteConfig & { + abi?: never + address?: never + chainId?: TChainId + } = {} as any ) { - return usePrepareContractWrite({ - abi: teleportrWithdrawerABI, - address: teleportrWithdrawerAddress[1], - functionName: 'withdrawETH', + return useContractWrite({ + abi: systemDictatorABI, + address: systemDictatorAddress[1], ...config, - } as UsePrepareContractWriteConfig) + } as any) } /** - * Wraps __{@link usePrepareContractWrite}__ with `abi` set to __{@link teleportrWithdrawerABI}__ and `functionName` set to `"withdrawFromTeleportr"`. + * Wraps __{@link useContractEvent}__ with `abi` set to __{@link systemDictatorABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) + * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0xB4453CEb33d2e67FA244A24acf2E50CEF31F53cB) */ -export function usePrepareTeleportrWithdrawerWithdrawFromTeleportr( +export function useSystemDictatorEvent( config: Omit< - UsePrepareContractWriteConfig< - typeof teleportrWithdrawerABI, - 'withdrawFromTeleportr' - >, - 'abi' | 'address' | 'functionName' - > & { chainId?: keyof typeof teleportrWithdrawerAddress } = {} as any + UseContractEventConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof systemDictatorAddress } = {} as any ) { - return usePrepareContractWrite({ - abi: teleportrWithdrawerABI, - address: teleportrWithdrawerAddress[1], - functionName: 'withdrawFromTeleportr', + return useContractEvent({ + abi: systemDictatorABI, + address: systemDictatorAddress[1], ...config, - } as UsePrepareContractWriteConfig) + } as UseContractEventConfig) } /** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link teleportrWithdrawerABI}__. + * Wraps __{@link useContractRead}__ with `abi` set to __{@link systemDictatorGoerliABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) + * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) */ -export function useTeleportrWithdrawerEvent( +export function useSystemDictatorGoerliRead< + TFunctionName extends string, + TSelectData = ReadContractResult< + typeof systemDictatorGoerliABI, + TFunctionName + > +>( config: Omit< - UseContractEventConfig, + UseContractReadConfig< + typeof systemDictatorGoerliABI, + TFunctionName, + TSelectData + >, 'abi' | 'address' - > & { chainId?: keyof typeof teleportrWithdrawerAddress } = {} as any + > & { chainId?: keyof typeof systemDictatorGoerliAddress } = {} as any ) { - return useContractEvent({ - abi: teleportrWithdrawerABI, - address: teleportrWithdrawerAddress[1], + return useContractRead({ + abi: systemDictatorGoerliABI, + address: systemDictatorGoerliAddress[5], ...config, - } as UseContractEventConfig) + } as UseContractReadConfig) } /** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link teleportrWithdrawerABI}__ and `eventName` set to `"OwnerUpdated"`. + * Wraps __{@link useContractWrite}__ with `abi` set to __{@link systemDictatorGoerliABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) + * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) */ -export function useTeleportrWithdrawerOwnerUpdatedEvent( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof teleportrWithdrawerAddress } = {} as any +export function useSystemDictatorGoerliWrite< + TFunctionName extends string, + TMode extends WriteContractMode = undefined, + TChainId extends number = keyof typeof systemDictatorGoerliAddress +>( + config: TMode extends 'prepared' + ? UseContractWriteConfig< + PrepareWriteContractResult< + typeof systemDictatorGoerliABI, + string + >['request']['abi'], + TFunctionName, + TMode + > & { address?: Address; chainId?: TChainId } + : UseContractWriteConfig< + typeof systemDictatorGoerliABI, + TFunctionName, + TMode + > & { + abi?: never + address?: never + chainId?: TChainId + } = {} as any ) { - return useContractEvent({ - abi: teleportrWithdrawerABI, - address: teleportrWithdrawerAddress[1], - eventName: 'OwnerUpdated', - ...config, - } as UseContractEventConfig) + return useContractWrite( + { + abi: systemDictatorGoerliABI, + address: systemDictatorGoerliAddress[5], + ...config, + } as any + ) } /** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link teleportrWithdrawerABI}__ and `eventName` set to `"ReceivedETH"`. + * Wraps __{@link useContractEvent}__ with `abi` set to __{@link systemDictatorGoerliABI}__. * - * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) + * [__View Contract on Goerli Etherscan__](https://goerli.etherscan.io/address/0x1f0613A44c9a8ECE7B3A2e0CdBdF0F5B47A50971) */ -export function useTeleportrWithdrawerReceivedEthEvent( +export function useSystemDictatorGoerliEvent( config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof teleportrWithdrawerAddress } = {} as any + UseContractEventConfig, + 'abi' | 'address' + > & { chainId?: keyof typeof systemDictatorGoerliAddress } = {} as any ) { return useContractEvent({ - abi: teleportrWithdrawerABI, - address: teleportrWithdrawerAddress[1], - eventName: 'ReceivedETH', + abi: systemDictatorGoerliABI, + address: systemDictatorGoerliAddress[5], ...config, - } as UseContractEventConfig) + } as UseContractEventConfig) } /** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link teleportrWithdrawerABI}__ and `eventName` set to `"WithdrewERC20"`. + * Wraps __{@link useContractRead}__ with `abi` set to __{@link teleportrWithdrawerABI}__. * * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) */ -export function useTeleportrWithdrawerWithdrewErc20Event( +export function useTeleportrWithdrawerRead< + TFunctionName extends string, + TSelectData = ReadContractResult +>( config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' + UseContractReadConfig< + typeof teleportrWithdrawerABI, + TFunctionName, + TSelectData + >, + 'abi' | 'address' > & { chainId?: keyof typeof teleportrWithdrawerAddress } = {} as any ) { - return useContractEvent({ + return useContractRead({ abi: teleportrWithdrawerABI, address: teleportrWithdrawerAddress[1], - eventName: 'WithdrewERC20', ...config, - } as UseContractEventConfig) + } as UseContractReadConfig) } /** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link teleportrWithdrawerABI}__ and `eventName` set to `"WithdrewERC721"`. + * Wraps __{@link useContractWrite}__ with `abi` set to __{@link teleportrWithdrawerABI}__. * * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) */ -export function useTeleportrWithdrawerWithdrewErc721Event( - config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' - > & { chainId?: keyof typeof teleportrWithdrawerAddress } = {} as any +export function useTeleportrWithdrawerWrite< + TFunctionName extends string, + TMode extends WriteContractMode = undefined, + TChainId extends number = keyof typeof teleportrWithdrawerAddress +>( + config: TMode extends 'prepared' + ? UseContractWriteConfig< + PrepareWriteContractResult< + typeof teleportrWithdrawerABI, + string + >['request']['abi'], + TFunctionName, + TMode + > & { address?: Address; chainId?: TChainId } + : UseContractWriteConfig< + typeof teleportrWithdrawerABI, + TFunctionName, + TMode + > & { + abi?: never + address?: never + chainId?: TChainId + } = {} as any ) { - return useContractEvent({ + return useContractWrite({ abi: teleportrWithdrawerABI, address: teleportrWithdrawerAddress[1], - eventName: 'WithdrewERC721', ...config, - } as UseContractEventConfig) + } as any) } /** - * Wraps __{@link useContractEvent}__ with `abi` set to __{@link teleportrWithdrawerABI}__ and `eventName` set to `"WithdrewETH"`. + * Wraps __{@link useContractEvent}__ with `abi` set to __{@link teleportrWithdrawerABI}__. * * [__View Contract on Ethereum Etherscan__](https://etherscan.io/address/0x78A25524D90E3D0596558fb43789bD800a5c3007) */ -export function useTeleportrWithdrawerWithdrewEthEvent( +export function useTeleportrWithdrawerEvent( config: Omit< - UseContractEventConfig, - 'abi' | 'address' | 'eventName' + UseContractEventConfig, + 'abi' | 'address' > & { chainId?: keyof typeof teleportrWithdrawerAddress } = {} as any ) { return useContractEvent({ abi: teleportrWithdrawerABI, address: teleportrWithdrawerAddress[1], - eventName: 'WithdrewETH', ...config, - } as UseContractEventConfig) + } as UseContractEventConfig) } diff --git a/packages/contracts-ts/wagmi.config.ts b/packages/contracts-ts/wagmi.config.ts index d05e9b08e178d..d9f8b19fc748c 100644 --- a/packages/contracts-ts/wagmi.config.ts +++ b/packages/contracts-ts/wagmi.config.ts @@ -372,11 +372,34 @@ export default defineConfig([ { out: 'src/actions.ts', contracts: contractsWithFilteredDuplicates, - plugins: [eslintIgnorePlugin, actions()], + plugins: [ + eslintIgnorePlugin, + actions({ + getContract: true, + // don't include actions because they can be more simply done via getContract + prepareWriteContract: false, + readContract: false, + watchContractEvent: false, + writeContract: false, + }), + ], }, { out: 'src/react.ts', contracts: contractsWithFilteredDuplicates, - plugins: [eslintIgnorePlugin, react()], + plugins: [ + eslintIgnorePlugin, + react({ + useContractRead: true, + useContractWrite: true, + useContractEvent: true, + // don't include more niche actions to keep api more simple + useContractFunctionRead: false, + useContractFunctionWrite: false, + useContractItemEvent: false, + usePrepareContractFunctionWrite: false, + usePrepareContractWrite: false, + }), + ], }, ]) diff --git a/packages/core-utils/package.json b/packages/core-utils/package.json index 2f34a075c2b3c..ec7ad40203525 100644 --- a/packages/core-utils/package.json +++ b/packages/core-utils/package.json @@ -49,7 +49,7 @@ "node-fetch": "^2.6.7" }, "devDependencies": { - "@types/node": "^20.8.5", + "@types/node": "^20.8.9", "mocha": "^10.2.0" } } diff --git a/packages/fee-estimation/package.json b/packages/fee-estimation/package.json index 54d55d4abe70b..616f42e1ed14b 100644 --- a/packages/fee-estimation/package.json +++ b/packages/fee-estimation/package.json @@ -35,17 +35,17 @@ }, "devDependencies": { "@eth-optimism/contracts-ts": "workspace:^", - "@testing-library/jest-dom": "^6.0.1", + "@testing-library/jest-dom": "^6.1.4", "@testing-library/react-hooks": "^8.0.1", "@vitest/coverage-istanbul": "^0.34.6", - "abitype": "^0.10.1", + "abitype": "^0.10.2", "isomorphic-fetch": "^3.0.0", "jest-dom": "link:@types/@testing-library/jest-dom", "jsdom": "^22.1.0", "tsup": "^7.2.0", "typescript": "^5.2.2", - "viem": "^1.16.5", - "vite": "^4.4.10", + "viem": "^1.18.6", + "vite": "^4.5.0", "vitest": "^0.34.2" }, "peerDependencies": { diff --git a/packages/sdk/hardhat.config.ts b/packages/sdk/hardhat.config.ts index 7b3fedc4b7808..717317b8a9334 100644 --- a/packages/sdk/hardhat.config.ts +++ b/packages/sdk/hardhat.config.ts @@ -24,7 +24,27 @@ const config: HardhatUserConfig = { devnetL1: { url: 'http://localhost:8545', accounts: [ - 'ac0974bec39a17e36ba4a6b4d238ff944bacb478cbed5efcae784d7bf4f2ff80', + // warning: keys 0 - 12 (incl) are used by the system + 'ac0974bec39a17e36ba4a6b4d238ff944bacb478cbed5efcae784d7bf4f2ff80', // 0 + '59c6995e998f97a5a0044966f0945389dc9e86dae88c7a8412f4603b6b78690d', // 1 + '5de4111afa1a4b94908f83103eb1f1706367c2e68ca870fc3fb9a804cdab365a', // 2 + '7c852118294e51e653712a81e05800f419141751be58f605c371e15141b007a6', // 3 + '47e179ec197488593b187f80a00eb0da91f1b9d0b13f8733639f19c30a34926a', // 4 + '8b3a350cf5c34c9194ca85829a2df0ec3153be0318b5e2d3348e872092edffba', // 5 + '92db14e403b83dfe3df233f83dfa3a0d7096f21ca9b0d6d6b8d88b2b4ec1564e', // 6 + '4bbbf85ce3377467afe5d46f804f221813b2bb87f24d81f60f1fcdbf7cbf4356', // 7 + 'dbda1821b80551c9d65939329250298aa3472ba22feea921c0cf5d620ea67b97', // 8 + '2a871d0798f97d79848a013d4936a73bf4cc922c825d33c1cf7073dff6d409c6', // 9 + 'f214f2b2cd398c806f84e317254e0f0b801d0643303237d97a22a48e01628897', // 10 + '701b615bbdfb9de65240bc28bd21bbc0d996645a3dd57e7b12bc2bdf6f192c82', // 11 + 'a267530f49f8280200edf313ee7af6b827f2a8bce2897751d06a843f644967b1', // 12 + '47c99abed3324a2707c28affff1267e45918ec8c3f20b8aa892e8b065d2942dd', // 13 + 'c526ee95bf44d8fc405a158bb884d9d1238d99f0612e9f33d006bb0789009aaa', // 14 + '8166f546bab6da521a8369cab06c5d2b9e46670292d85c875ee9ec20e84ffb61', // 15 + 'ea6c44ac03bff858b476bba40716402b03e41b8e97e276d1baec7c37d42484a0', // 16 + '689af8efa8c651a91ad287602527f3af2fe9f6501a7ac4b061667b5a93e037fd', // 17 + 'de9be858da4a475276426320d5e9262ecfc3ba460bfac56360bfa6c4c28b4ee0', // 18 + 'df57089febbacf7ba0bc227dafbffa9fc08a93fdc68e1e42411a14efcf23656e', // 19 ], }, hivenet: { diff --git a/packages/sdk/package.json b/packages/sdk/package.json index 33516d2b24348..a4f84d52f9db1 100644 --- a/packages/sdk/package.json +++ b/packages/sdk/package.json @@ -41,22 +41,22 @@ "@ethersproject/transactions": "^5.7.0", "@nomiclabs/hardhat-ethers": "^2.2.3", "@nomiclabs/hardhat-waffle": "^2.0.1", - "@types/chai": "^4.3.7", + "@types/chai": "^4.3.8", "@types/chai-as-promised": "^7.1.5", - "@types/mocha": "^10.0.2", - "@types/node": "^20.8.5", + "@types/mocha": "^10.0.4", + "@types/node": "^20.8.9", "chai-as-promised": "^7.1.1", "ethereum-waffle": "^4.0.10", "ethers": "^5.7.2", - "hardhat": "^2.18.1", - "hardhat-deploy": "^0.11.42", + "hardhat": "^2.19.0", + "hardhat-deploy": "^0.11.43", "isomorphic-fetch": "^3.0.0", "mocha": "^10.2.0", "nyc": "^15.1.0", "ts-node": "^10.9.1", - "typedoc": "^0.25.2", + "typedoc": "^0.25.3", "typescript": "^5.2.2", - "viem": "^1.16.5", + "viem": "^1.18.6", "vitest": "^0.34.2", "zod": "^3.22.4" }, @@ -65,7 +65,7 @@ "@eth-optimism/contracts-bedrock": "workspace:*", "@eth-optimism/core-utils": "workspace:*", "lodash": "^4.17.21", - "merkletreejs": "^0.3.10", + "merkletreejs": "^0.3.11", "rlp": "^2.2.7" }, "peerDependencies": { diff --git a/packages/sdk/tasks/deposit-erc20.ts b/packages/sdk/tasks/deposit-erc20.ts index d96cd60f4e1e7..cad8bd5d16c49 100644 --- a/packages/sdk/tasks/deposit-erc20.ts +++ b/packages/sdk/tasks/deposit-erc20.ts @@ -2,6 +2,7 @@ import { promises as fs } from 'fs' import { task, types } from 'hardhat/config' import { HardhatRuntimeEnvironment } from 'hardhat/types' +import { SignerWithAddress } from '@nomiclabs/hardhat-ethers/signers' import '@nomiclabs/hardhat-ethers' import 'hardhat-deploy' import { Event, Contract, Wallet, providers, utils, ethers } from 'ethers' @@ -27,11 +28,9 @@ import { const deployWETH9 = async ( hre: HardhatRuntimeEnvironment, + signer: SignerWithAddress, wrap: boolean ): Promise => { - const signers = await hre.ethers.getSigners() - const signer = signers[0] - const Factory__WETH9 = new hre.ethers.ContractFactory( Artifact__WETH9.abi, Artifact__WETH9.bytecode.object, @@ -117,13 +116,16 @@ task('deposit-erc20', 'Deposits WETH9 onto L2.') '', types.string ) + .addOptionalParam('signerIndex', 'Index of signer to use', 0, types.int) .setAction(async (args, hre) => { const signers = await hre.ethers.getSigners() if (signers.length === 0) { throw new Error('No configured signers') } - // Use the first configured signer for simplicity - const signer = signers[0] + if (args.signerIndex < 0 || signers.length <= args.signerIndex) { + throw new Error('Invalid signer index') + } + const signer = signers[args.signerIndex] const address = await signer.getAddress() console.log(`Using signer ${address}`) @@ -137,7 +139,7 @@ task('deposit-erc20', 'Deposits WETH9 onto L2.') const l2Provider = new providers.StaticJsonRpcProvider(args.l2ProviderUrl) const l2Signer = new hre.ethers.Wallet( - hre.network.config.accounts[0], + hre.network.config.accounts[args.signerIndex], l2Provider ) @@ -219,7 +221,7 @@ task('deposit-erc20', 'Deposits WETH9 onto L2.') console.log(params) console.log('Deploying WETH9 to L1') - const WETH9 = await deployWETH9(hre, true) + const WETH9 = await deployWETH9(hre, signer, true) console.log(`Deployed to ${WETH9.address}`) console.log('Creating L2 WETH9') diff --git a/packages/sdk/tasks/deposit-eth.ts b/packages/sdk/tasks/deposit-eth.ts index fe298a6176998..62a9539f8ded3 100644 --- a/packages/sdk/tasks/deposit-eth.ts +++ b/packages/sdk/tasks/deposit-eth.ts @@ -50,14 +50,17 @@ task('deposit-eth', 'Deposits ether to L2.') '', types.string ) + .addOptionalParam('signerIndex', 'Index of signer to use', 0, types.int) .addOptionalParam('withdrawAmount', 'Amount to withdraw', '', types.string) .setAction(async (args, hre) => { const signers = await hre.ethers.getSigners() if (signers.length === 0) { throw new Error('No configured signers') } - // Use the first configured signer for simplicity - const signer = signers[0] + if (args.signerIndex < 0 || signers.length <= args.signerIndex) { + throw new Error('Invalid signer index') + } + const signer = signers[args.signerIndex] const address = await signer.getAddress() console.log(`Using signer ${address}`) @@ -81,7 +84,7 @@ task('deposit-eth', 'Deposits ether to L2.') : amount.div(2) const l2Signer = new hre.ethers.Wallet( - hre.network.config.accounts[0], + hre.network.config.accounts[args.signerIndex], l2Provider ) diff --git a/packages/web3js-plugin/package.json b/packages/web3js-plugin/package.json index 4058f83ec42b0..aad802334e52f 100644 --- a/packages/web3js-plugin/package.json +++ b/packages/web3js-plugin/package.json @@ -33,17 +33,17 @@ }, "devDependencies": { "@eth-optimism/contracts-ts": "workspace:^", - "@swc/core": "^1.3.92", + "@swc/core": "^1.3.95", "@vitest/coverage-istanbul": "^0.34.6", "tsup": "^7.2.0", "typescript": "^5.2.2", - "viem": "^1.16.5", - "vite": "^4.4.10", + "viem": "^1.18.6", + "vite": "^4.5.0", "vitest": "^0.34.1", "zod": "^3.22.4" }, "dependencies": { - "@ethereumjs/rlp": "^5.0.0", + "@ethereumjs/rlp": "^5.0.1", "web3-eth": "^4.0.3", "web3-eth-accounts": "^4.0.3" }, diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 821c652e34362..660a73172202b 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -17,76 +17,76 @@ importers: devDependencies: '@babel/eslint-parser': specifier: ^7.18.2 - version: 7.22.15(@babel/core@7.22.10)(eslint@8.51.0) + version: 7.22.15(@babel/core@7.22.10)(eslint@8.53.0) '@changesets/changelog-github': specifier: ^0.4.8 version: 0.4.8 '@types/chai': - specifier: ^4.3.7 - version: 4.3.7 + specifier: ^4.3.8 + version: 4.3.8 '@types/chai-as-promised': specifier: ^7.1.4 version: 7.1.5 '@types/mocha': - specifier: ^10.0.2 - version: 10.0.2 + specifier: ^10.0.4 + version: 10.0.4 '@types/node': - specifier: ^20.8.5 - version: 20.8.5 + specifier: ^20.8.9 + version: 20.8.9 '@typescript-eslint/eslint-plugin': - specifier: ^6.7.5 - version: 6.7.5(@typescript-eslint/parser@6.7.5)(eslint@8.51.0)(typescript@5.2.2) + specifier: ^6.10.0 + version: 6.10.0(@typescript-eslint/parser@6.9.1)(eslint@8.53.0)(typescript@5.2.2) '@typescript-eslint/parser': - specifier: ^6.7.5 - version: 6.7.5(eslint@8.51.0)(typescript@5.2.2) + specifier: ^6.9.1 + version: 6.9.1(eslint@8.53.0)(typescript@5.2.2) chai: specifier: ^4.3.10 version: 4.3.10 depcheck: - specifier: ^1.4.3 - version: 1.4.6 + specifier: ^1.4.7 + version: 1.4.7 doctoc: specifier: ^2.2.0 version: 2.2.1 eslint: - specifier: ^8.51.0 - version: 8.51.0 + specifier: ^8.53.0 + version: 8.53.0 eslint-config-prettier: specifier: ^8.3.0 - version: 8.3.0(eslint@8.51.0) + version: 8.3.0(eslint@8.53.0) eslint-config-standard: specifier: ^16.0.3 - version: 16.0.3(eslint-plugin-import@2.28.1)(eslint-plugin-node@11.1.0)(eslint-plugin-promise@5.2.0)(eslint@8.51.0) + version: 16.0.3(eslint-plugin-import@2.29.0)(eslint-plugin-node@11.1.0)(eslint-plugin-promise@5.2.0)(eslint@8.53.0) eslint-plugin-import: - specifier: ^2.26.0 - version: 2.28.1(@typescript-eslint/parser@6.7.5)(eslint@8.51.0) + specifier: ^2.29.0 + version: 2.29.0(@typescript-eslint/parser@6.9.1)(eslint@8.53.0) eslint-plugin-jsdoc: specifier: ^35.1.2 - version: 35.5.1(eslint@8.51.0) + version: 35.5.1(eslint@8.53.0) eslint-plugin-node: specifier: ^11.1.0 - version: 11.1.0(eslint@8.51.0) + version: 11.1.0(eslint@8.53.0) eslint-plugin-prefer-arrow: specifier: ^1.2.3 - version: 1.2.3(eslint@8.51.0) + version: 1.2.3(eslint@8.53.0) eslint-plugin-prettier: specifier: ^4.0.0 - version: 4.2.1(eslint-config-prettier@8.3.0)(eslint@8.51.0)(prettier@2.8.8) + version: 4.2.1(eslint-config-prettier@8.3.0)(eslint@8.53.0)(prettier@2.8.8) eslint-plugin-promise: specifier: ^5.1.0 - version: 5.2.0(eslint@8.51.0) + version: 5.2.0(eslint@8.53.0) eslint-plugin-react: specifier: ^7.24.0 - version: 7.33.2(eslint@8.51.0) + version: 7.33.2(eslint@8.53.0) eslint-plugin-unicorn: - specifier: ^48.0.1 - version: 48.0.1(eslint@8.51.0) + specifier: ^49.0.0 + version: 49.0.0(eslint@8.53.0) husky: specifier: ^8.0.3 version: 8.0.3 lint-staged: - specifier: 14.0.1 - version: 14.0.1 + specifier: 15.0.2 + version: 15.0.2 markdownlint: specifier: ^0.31.0 version: 0.31.1 @@ -97,8 +97,8 @@ importers: specifier: ^10.2.0 version: 10.2.0 nx: - specifier: 16.10.0 - version: 16.10.0 + specifier: 17.0.3 + version: 17.0.3 nx-cloud: specifier: latest version: 16.5.2 @@ -130,7 +130,7 @@ importers: devDependencies: tsup: specifier: ^7.2.0 - version: 7.2.0(@swc/core@1.3.92)(typescript@5.2.2) + version: 7.2.0(@swc/core@1.3.95)(typescript@5.2.2) vitest: specifier: ^0.34.4 version: 0.34.4 @@ -175,19 +175,19 @@ importers: version: 5.7.0 '@nomiclabs/hardhat-ethers': specifier: ^2.2.3 - version: 2.2.3(ethers@5.7.2)(hardhat@2.18.1) + version: 2.2.3(ethers@5.7.2)(hardhat@2.19.0) '@nomiclabs/hardhat-waffle': specifier: ^2.0.6 - version: 2.0.6(@nomiclabs/hardhat-ethers@2.2.3)(@types/sinon-chai@3.2.5)(ethereum-waffle@4.0.10)(ethers@5.7.2)(hardhat@2.18.1) + version: 2.0.6(@nomiclabs/hardhat-ethers@2.2.3)(@types/sinon-chai@3.2.5)(ethereum-waffle@4.0.10)(ethers@5.7.2)(hardhat@2.19.0) hardhat: - specifier: ^2.18.1 - version: 2.18.1(ts-node@10.9.1)(typescript@5.2.2) + specifier: ^2.19.0 + version: 2.19.0(ts-node@10.9.1)(typescript@5.2.2) ts-node: specifier: ^10.9.1 - version: 10.9.1(@types/node@20.8.5)(typescript@5.2.2) + version: 10.9.1(@types/node@20.8.9)(typescript@5.2.2) tsx: - specifier: ^3.12.7 - version: 3.12.7 + specifier: ^3.14.0 + version: 3.14.0 packages/common-ts: dependencies: @@ -195,8 +195,8 @@ importers: specifier: workspace:* version: link:../core-utils '@sentry/node': - specifier: ^7.74.0 - version: 7.74.0 + specifier: ^7.77.0 + version: 7.77.0 bcfg: specifier: ^0.2.1 version: 0.2.1 @@ -204,8 +204,8 @@ importers: specifier: ^1.20.2 version: 1.20.2 commander: - specifier: ^11.0.0 - version: 11.0.0 + specifier: ^11.1.0 + version: 11.1.0 dotenv: specifier: ^16.3.1 version: 16.3.1 @@ -228,8 +228,8 @@ importers: specifier: ^1.10.0 version: 1.10.0 pino: - specifier: ^8.16.0 - version: 8.16.0 + specifier: ^8.16.1 + version: 8.16.1 pino-multi-stream: specifier: ^6.0.0 version: 6.0.0 @@ -250,14 +250,14 @@ importers: specifier: ^4.17.19 version: 4.17.19 '@types/morgan': - specifier: ^1.9.6 - version: 1.9.6 + specifier: ^1.9.7 + version: 1.9.7 '@types/pino': specifier: ^7.0.5 version: 7.0.5 '@types/pino-multi-stream': - specifier: ^5.1.4 - version: 5.1.4 + specifier: ^5.1.5 + version: 5.1.5 chai: specifier: ^4.3.10 version: 4.3.10 @@ -268,14 +268,14 @@ importers: packages/contracts-bedrock: devDependencies: '@typescript-eslint/eslint-plugin': - specifier: ^6.7.5 - version: 6.7.5(@typescript-eslint/parser@6.7.5)(eslint@8.51.0)(typescript@5.2.2) + specifier: ^6.10.0 + version: 6.10.0(@typescript-eslint/parser@6.9.1)(eslint@8.53.0)(typescript@5.2.2) '@typescript-eslint/parser': - specifier: ^6.7.5 - version: 6.7.5(eslint@8.51.0)(typescript@5.2.2) + specifier: ^6.9.1 + version: 6.9.1(eslint@8.53.0)(typescript@5.2.2) tsx: - specifier: ^3.12.7 - version: 3.12.7 + specifier: ^3.14.0 + version: 3.14.0 typescript: specifier: ^5.2.2 version: 5.2.2 @@ -298,18 +298,18 @@ importers: specifier: ^18.2.0 version: 18.2.0(react@18.2.0) viem: - specifier: ^1.16.5 - version: 1.16.5(typescript@5.2.2)(zod@3.22.4) + specifier: ^1.18.6 + version: 1.18.6(typescript@5.2.2)(zod@3.22.4) wagmi: specifier: '>1.0.0' - version: 1.0.1(react-dom@18.2.0)(react@18.2.0)(typescript@5.2.2)(viem@1.16.5) + version: 1.0.1(react-dom@18.2.0)(react@18.2.0)(typescript@5.2.2)(viem@1.18.6) devDependencies: '@eth-optimism/contracts-bedrock': specifier: workspace:* version: link:../contracts-bedrock '@testing-library/jest-dom': - specifier: ^6.0.1 - version: 6.0.1(vitest@0.34.2) + specifier: ^6.1.4 + version: 6.1.4(vitest@0.34.2) '@testing-library/react-hooks': specifier: ^8.0.1 version: 8.0.1(react-dom@18.2.0)(react@18.2.0) @@ -321,13 +321,13 @@ importers: version: 0.34.6(vitest@0.34.2) '@wagmi/cli': specifier: ^1.5.2 - version: 1.5.2(@wagmi/core@1.4.3)(typescript@5.2.2)(wagmi@1.0.1) + version: 1.5.2(@wagmi/core@1.4.5)(typescript@5.2.2)(wagmi@1.0.1) '@wagmi/core': - specifier: ^1.4.3 - version: 1.4.3(react@18.2.0)(typescript@5.2.2)(viem@1.16.5) + specifier: ^1.4.5 + version: 1.4.5(react@18.2.0)(typescript@5.2.2)(viem@1.18.6) abitype: - specifier: ^0.10.1 - version: 0.10.1(typescript@5.2.2) + specifier: ^0.10.2 + version: 0.10.2(typescript@5.2.2) glob: specifier: ^10.3.10 version: 10.3.10 @@ -342,13 +342,13 @@ importers: version: 22.1.0 tsup: specifier: ^7.2.0 - version: 7.2.0(@swc/core@1.3.92)(typescript@5.2.2) + version: 7.2.0(@swc/core@1.3.95)(typescript@5.2.2) typescript: specifier: ^5.2.2 version: 5.2.2 vite: - specifier: ^4.4.10 - version: 4.4.10(@types/node@20.8.5) + specifier: ^4.5.0 + version: 4.5.0(@types/node@20.8.9) vitest: specifier: ^0.34.2 version: 0.34.2(jsdom@22.1.0) @@ -399,8 +399,8 @@ importers: version: 2.6.7 devDependencies: '@types/node': - specifier: ^20.8.5 - version: 20.8.5 + specifier: ^20.8.9 + version: 20.8.9 mocha: specifier: ^10.2.0 version: 10.2.0 @@ -411,8 +411,8 @@ importers: specifier: workspace:^ version: link:../contracts-ts '@testing-library/jest-dom': - specifier: ^6.0.1 - version: 6.0.1(vitest@0.34.2) + specifier: ^6.1.4 + version: 6.1.4(vitest@0.34.2) '@testing-library/react-hooks': specifier: ^8.0.1 version: 8.0.1(react@17.0.2) @@ -420,8 +420,8 @@ importers: specifier: ^0.34.6 version: 0.34.6(vitest@0.34.2) abitype: - specifier: ^0.10.1 - version: 0.10.1(typescript@5.2.2) + specifier: ^0.10.2 + version: 0.10.2(typescript@5.2.2) isomorphic-fetch: specifier: ^3.0.0 version: 3.0.0 @@ -433,16 +433,16 @@ importers: version: 22.1.0 tsup: specifier: ^7.2.0 - version: 7.2.0(@swc/core@1.3.92)(typescript@5.2.2) + version: 7.2.0(@swc/core@1.3.95)(typescript@5.2.2) typescript: specifier: ^5.2.2 version: 5.2.2 viem: - specifier: ^1.16.5 - version: 1.16.5(typescript@5.2.2)(zod@3.22.4) + specifier: ^1.18.6 + version: 1.18.6(typescript@5.2.2)(zod@3.22.4) vite: - specifier: ^4.4.10 - version: 4.4.10(@types/node@20.8.5) + specifier: ^4.5.0 + version: 4.5.0(@types/node@20.8.9) vitest: specifier: ^0.34.2 version: 0.34.2(jsdom@22.1.0) @@ -462,8 +462,8 @@ importers: specifier: ^4.17.21 version: 4.17.21 merkletreejs: - specifier: ^0.3.10 - version: 0.3.10 + specifier: ^0.3.11 + version: 0.3.11 rlp: specifier: ^2.2.7 version: 2.2.7 @@ -479,22 +479,22 @@ importers: version: 5.7.0 '@nomiclabs/hardhat-ethers': specifier: ^2.2.3 - version: 2.2.3(ethers@5.7.2)(hardhat@2.18.1) + version: 2.2.3(ethers@5.7.2)(hardhat@2.19.0) '@nomiclabs/hardhat-waffle': specifier: ^2.0.1 - version: 2.0.1(@nomiclabs/hardhat-ethers@2.2.3)(ethereum-waffle@4.0.10)(ethers@5.7.2)(hardhat@2.18.1) + version: 2.0.1(@nomiclabs/hardhat-ethers@2.2.3)(ethereum-waffle@4.0.10)(ethers@5.7.2)(hardhat@2.19.0) '@types/chai': - specifier: ^4.3.7 - version: 4.3.7 + specifier: ^4.3.8 + version: 4.3.8 '@types/chai-as-promised': specifier: ^7.1.5 version: 7.1.5 '@types/mocha': - specifier: ^10.0.2 - version: 10.0.2 + specifier: ^10.0.4 + version: 10.0.4 '@types/node': - specifier: ^20.8.5 - version: 20.8.5 + specifier: ^20.8.9 + version: 20.8.9 chai-as-promised: specifier: ^7.1.1 version: 7.1.1(chai@4.3.10) @@ -505,11 +505,11 @@ importers: specifier: ^5.7.2 version: 5.7.2 hardhat: - specifier: ^2.18.1 - version: 2.18.1(ts-node@10.9.1)(typescript@5.2.2) + specifier: ^2.19.0 + version: 2.19.0(ts-node@10.9.1)(typescript@5.2.2) hardhat-deploy: - specifier: ^0.11.42 - version: 0.11.42 + specifier: ^0.11.43 + version: 0.11.43 isomorphic-fetch: specifier: ^3.0.0 version: 3.0.0 @@ -521,16 +521,16 @@ importers: version: 15.1.0 ts-node: specifier: ^10.9.1 - version: 10.9.1(@types/node@20.8.5)(typescript@5.2.2) + version: 10.9.1(@types/node@20.8.9)(typescript@5.2.2) typedoc: - specifier: ^0.25.2 - version: 0.25.2(typescript@5.2.2) + specifier: ^0.25.3 + version: 0.25.3(typescript@5.2.2) typescript: specifier: ^5.2.2 version: 5.2.2 viem: - specifier: ^1.16.5 - version: 1.16.5(typescript@5.2.2)(zod@3.22.4) + specifier: ^1.18.6 + version: 1.18.6(typescript@5.2.2)(zod@3.22.4) vitest: specifier: ^0.34.2 version: 0.34.2 @@ -541,8 +541,8 @@ importers: packages/web3js-plugin: dependencies: '@ethereumjs/rlp': - specifier: ^5.0.0 - version: 5.0.0 + specifier: ^5.0.1 + version: 5.0.1 web3: specifier: '>= 4.0.3 < 5.x' version: 4.0.3 @@ -557,23 +557,23 @@ importers: specifier: workspace:^ version: link:../contracts-ts '@swc/core': - specifier: ^1.3.92 - version: 1.3.92 + specifier: ^1.3.95 + version: 1.3.95 '@vitest/coverage-istanbul': specifier: ^0.34.6 version: 0.34.6(vitest@0.34.1) tsup: specifier: ^7.2.0 - version: 7.2.0(@swc/core@1.3.92)(typescript@5.2.2) + version: 7.2.0(@swc/core@1.3.95)(typescript@5.2.2) typescript: specifier: ^5.2.2 version: 5.2.2 viem: - specifier: ^1.16.5 - version: 1.16.5(typescript@5.2.2)(zod@3.22.4) + specifier: ^1.18.6 + version: 1.18.6(typescript@5.2.2)(zod@3.22.4) vite: - specifier: ^4.4.10 - version: 4.4.10(@types/node@20.8.5) + specifier: ^4.5.0 + version: 4.5.0(@types/node@20.8.9) vitest: specifier: ^0.34.1 version: 0.34.1 @@ -588,8 +588,8 @@ packages: engines: {node: '>=0.10.0'} dev: true - /@adobe/css-tools@4.2.0: - resolution: {integrity: sha512-E09FiIft46CmH5Qnjb0wsW54/YQd69LsxeKUOWawmws1XWvyFGURnAChH0mlr7YPFR1ofwvUQfcL0J3lMxXqPA==} + /@adobe/css-tools@4.3.1: + resolution: {integrity: sha512-/62yikz7NLScCGAAST5SHdnjaDJQBDq0M2muyRTpf2VQhw6StBg2ALiu73zSJQ4fMVLA+0uBhBHAle7Wg+2kSg==} dev: true /@adraffy/ens-normalize@1.9.4: @@ -603,11 +603,11 @@ packages: '@jridgewell/trace-mapping': 0.3.19 dev: true - /@babel/code-frame@7.22.10: - resolution: {integrity: sha512-/KKIMG4UEL35WmI9OlvMhurwtytjvXoFcGNrOvyG9zIzA8YmPjVtIZUf7b05+TPO7G7/GEmLHDaoCgACHl9hhA==} + /@babel/code-frame@7.22.13: + resolution: {integrity: sha512-XktuhWlJ5g+3TJXc5upd9Ks1HutSArik6jf2eAjYFyIOf4ej3RN+184cZbzDvbPnuTJIUhPKKJE3cIsYTiAT3w==} engines: {node: '>=6.9.0'} dependencies: - '@babel/highlight': 7.22.10 + '@babel/highlight': 7.22.20 chalk: 2.4.2 /@babel/compat-data@7.22.9: @@ -620,7 +620,7 @@ packages: engines: {node: '>=6.9.0'} dependencies: '@ampproject/remapping': 2.2.1 - '@babel/code-frame': 7.22.10 + '@babel/code-frame': 7.22.13 '@babel/generator': 7.22.10 '@babel/helper-compilation-targets': 7.22.10 '@babel/helper-module-transforms': 7.22.9(@babel/core@7.22.10) @@ -638,7 +638,7 @@ packages: - supports-color dev: true - /@babel/eslint-parser@7.22.15(@babel/core@7.22.10)(eslint@8.51.0): + /@babel/eslint-parser@7.22.15(@babel/core@7.22.10)(eslint@8.53.0): resolution: {integrity: sha512-yc8OOBIQk1EcRrpizuARSQS0TWAcOMpEJ1aafhNznaeYkeL+OhqnDObGFylB8ka8VFF/sZc+S4RzHyO+3LjQxg==} engines: {node: ^10.13.0 || ^12.13.0 || >=14.0.0} peerDependencies: @@ -647,7 +647,7 @@ packages: dependencies: '@babel/core': 7.22.10 '@nicolo-ribaudo/eslint-scope-5-internals': 5.1.1-v1 - eslint: 8.51.0 + eslint: 8.53.0 eslint-visitor-keys: 2.1.0 semver: 6.3.1 dev: true @@ -662,6 +662,16 @@ packages: jsesc: 2.5.2 dev: true + /@babel/generator@7.23.0: + resolution: {integrity: sha512-lN85QRR+5IbYrMWM6Y4pE/noaQtg4pNiqeNGX60eqOfo6gtEj6uw/JagelB8vVztSd7R6M5n1+PQkDbHbBRU4g==} + engines: {node: '>=6.9.0'} + dependencies: + '@babel/types': 7.23.0 + '@jridgewell/gen-mapping': 0.3.3 + '@jridgewell/trace-mapping': 0.3.19 + jsesc: 2.5.2 + dev: true + /@babel/helper-compilation-targets@7.22.10: resolution: {integrity: sha512-JMSwHD4J7SLod0idLq5PKgI+6g/hLD/iuWBq08ZX49xE14VpVEojJ5rHWptpirV2j020MvypRLAXAO50igCJ5Q==} engines: {node: '>=6.9.0'} @@ -673,6 +683,11 @@ packages: semver: 6.3.1 dev: true + /@babel/helper-environment-visitor@7.22.20: + resolution: {integrity: sha512-zfedSIzFhat/gFhWfHtgWvlec0nqB9YEIVrpuwjruLlXfUSnA8cJB0miHKwqDnQ7d32aKo2xt88/xZptwxbfhA==} + engines: {node: '>=6.9.0'} + dev: true + /@babel/helper-environment-visitor@7.22.5: resolution: {integrity: sha512-XGmhECfVA/5sAt+H+xpSg0mfrHq6FzNr9Oxh7PSEBBRUb/mL7Kz3NICXb194rCqAEdxkhPT1a88teizAFyvk8Q==} engines: {node: '>=6.9.0'} @@ -686,11 +701,19 @@ packages: '@babel/types': 7.22.10 dev: true + /@babel/helper-function-name@7.23.0: + resolution: {integrity: sha512-OErEqsrxjZTJciZ4Oo+eoZqeW9UIiOcuYKRJA4ZAgV9myA+pOXhhmpfNCKjEH/auVfEYVFJ6y1Tc4r0eIApqiw==} + engines: {node: '>=6.9.0'} + dependencies: + '@babel/template': 7.22.15 + '@babel/types': 7.23.0 + dev: true + /@babel/helper-hoist-variables@7.22.5: resolution: {integrity: sha512-wGjk9QZVzvknA6yKIUURb8zY3grXCcOZt+/7Wcy8O2uctxhplmUPkOdlgoNhmdVee2c92JXbf1xpMtVNbfoxRw==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.22.10 + '@babel/types': 7.23.0 dev: true /@babel/helper-module-imports@7.22.5: @@ -711,7 +734,7 @@ packages: '@babel/helper-module-imports': 7.22.5 '@babel/helper-simple-access': 7.22.5 '@babel/helper-split-export-declaration': 7.22.6 - '@babel/helper-validator-identifier': 7.22.5 + '@babel/helper-validator-identifier': 7.22.20 dev: true /@babel/helper-simple-access@7.22.5: @@ -725,7 +748,7 @@ packages: resolution: {integrity: sha512-AsUnxuLhRYsisFiaJwvp1QF+I3KjD5FOxut14q/GzovUe6orHLesW2C7d754kRm53h5gqrz6sFl6sxc4BVtE/g==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.22.10 + '@babel/types': 7.23.0 dev: true /@babel/helper-string-parser@7.22.5: @@ -733,8 +756,8 @@ packages: engines: {node: '>=6.9.0'} dev: true - /@babel/helper-validator-identifier@7.22.5: - resolution: {integrity: sha512-aJXu+6lErq8ltp+JhkJUfk1MTGyuA4v7f3pA+BJ5HLfNC6nAQ0Cpi9uOquUj8Hehg0aUiHzWQbOVJGao6ztBAQ==} + /@babel/helper-validator-identifier@7.22.20: + resolution: {integrity: sha512-Y4OZ+ytlatR8AI+8KZfKuL5urKp7qey08ha31L8b3BwewJAoJamTzyvxPR/5D+KkdJCGPq/+8TukHBlY10FX9A==} engines: {node: '>=6.9.0'} /@babel/helper-validator-option@7.22.5: @@ -753,11 +776,11 @@ packages: - supports-color dev: true - /@babel/highlight@7.22.10: - resolution: {integrity: sha512-78aUtVcT7MUscr0K5mIEnkwxPE0MaxkR5RxRwuHaQ+JuU5AmTPhY+do2mdzVTnIJJpyBglql2pehuBIWHug+WQ==} + /@babel/highlight@7.22.20: + resolution: {integrity: sha512-dkdMCN3py0+ksCgYmGG8jKeGA/8Tk+gJwSYYlFGxG5lmhfKNoAy004YpLxpS1W2J8m/EK2Ew+yOs9pVRwO89mg==} engines: {node: '>=6.9.0'} dependencies: - '@babel/helper-validator-identifier': 7.22.5 + '@babel/helper-validator-identifier': 7.22.20 chalk: 2.4.2 js-tokens: 4.0.0 @@ -769,8 +792,8 @@ packages: '@babel/types': 7.22.10 dev: true - /@babel/parser@7.22.5: - resolution: {integrity: sha512-DFZMC9LJUG9PLOclRC32G63UXwzqS2koQC8dkx+PLdmt1xSePYpbT/NbsrJy8Q/muXz7o/h/d4A7Fuyixm559Q==} + /@babel/parser@7.23.0: + resolution: {integrity: sha512-vvPKKdMemU85V9WE/l5wZEmImpCtLqbnTvqDS2U1fJ96KrxoW7KrXhNsNCblQlg8Ck4b85yxdTyelsMUgFUXiw==} engines: {node: '>=6.0.0'} hasBin: true dependencies: @@ -790,11 +813,20 @@ packages: dependencies: regenerator-runtime: 0.13.11 + /@babel/template@7.22.15: + resolution: {integrity: sha512-QPErUVm4uyJa60rkI73qneDacvdvzxshT3kksGqlGWYdOTIUOwJ7RDUL8sGqslY1uXWSL6xMFKEXDS3ox2uF0w==} + engines: {node: '>=6.9.0'} + dependencies: + '@babel/code-frame': 7.22.13 + '@babel/parser': 7.23.0 + '@babel/types': 7.23.0 + dev: true + /@babel/template@7.22.5: resolution: {integrity: sha512-X7yV7eiwAxdj9k94NEylvbVHLiVG1nvzCV2EAowhxLTwODV1jl9UzZ48leOC0sH7OnuHrIkllaBgneUykIcZaw==} engines: {node: '>=6.9.0'} dependencies: - '@babel/code-frame': 7.22.10 + '@babel/code-frame': 7.22.13 '@babel/parser': 7.22.10 '@babel/types': 7.22.10 dev: true @@ -803,7 +835,7 @@ packages: resolution: {integrity: sha512-Q/urqV4pRByiNNpb/f5OSv28ZlGJiFiiTh+GAHktbIrkPhPbl90+uW6SmpoLyZqutrg9AEaEf3Q/ZBRHBXgxig==} engines: {node: '>=6.9.0'} dependencies: - '@babel/code-frame': 7.22.10 + '@babel/code-frame': 7.22.13 '@babel/generator': 7.22.10 '@babel/helper-environment-visitor': 7.22.5 '@babel/helper-function-name': 7.22.5 @@ -817,18 +849,18 @@ packages: - supports-color dev: true - /@babel/traverse@7.22.5: - resolution: {integrity: sha512-7DuIjPgERaNo6r+PZwItpjCZEa5vyw4eJGufeLxrPdBXBoLcCJCIasvK6pK/9DVNrLZTLFhUGqaC6X/PA007TQ==} + /@babel/traverse@7.23.2: + resolution: {integrity: sha512-azpe59SQ48qG6nu2CzcMLbxUudtN+dOM9kDbUqGq3HXUJRlo7i8fvPoxQUzYgLZ4cMVmuZgm8vvBpNeRhd6XSw==} engines: {node: '>=6.9.0'} dependencies: - '@babel/code-frame': 7.22.10 - '@babel/generator': 7.22.10 - '@babel/helper-environment-visitor': 7.22.5 - '@babel/helper-function-name': 7.22.5 + '@babel/code-frame': 7.22.13 + '@babel/generator': 7.23.0 + '@babel/helper-environment-visitor': 7.22.20 + '@babel/helper-function-name': 7.23.0 '@babel/helper-hoist-variables': 7.22.5 '@babel/helper-split-export-declaration': 7.22.6 - '@babel/parser': 7.22.10 - '@babel/types': 7.22.10 + '@babel/parser': 7.23.0 + '@babel/types': 7.23.0 debug: 4.3.4(supports-color@8.1.1) globals: 11.12.0 transitivePeerDependencies: @@ -840,7 +872,16 @@ packages: engines: {node: '>=6.9.0'} dependencies: '@babel/helper-string-parser': 7.22.5 - '@babel/helper-validator-identifier': 7.22.5 + '@babel/helper-validator-identifier': 7.22.20 + to-fast-properties: 2.0.0 + dev: true + + /@babel/types@7.23.0: + resolution: {integrity: sha512-0oIyUfKoI3mSqMvsxBdclDwxXKXAUA8v/apZbc+iSyARYou1o8ZGDxbUYyLFoW2arqS2jDGqJuZvv1d/io1axg==} + engines: {node: '>=6.9.0'} + dependencies: + '@babel/helper-string-parser': 7.22.5 + '@babel/helper-validator-identifier': 7.22.20 to-fast-properties: 2.0.0 dev: true @@ -1166,27 +1207,6 @@ packages: jsdoc-type-pratt-parser: 1.0.4 dev: true - /@esbuild-kit/cjs-loader@2.4.2: - resolution: {integrity: sha512-BDXFbYOJzT/NBEtp71cvsrGPwGAMGRB/349rwKuoxNSiKjPraNNnlK6MIIabViCjqZugu6j+xeMDlEkWdHHJSg==} - dependencies: - '@esbuild-kit/core-utils': 3.1.0 - get-tsconfig: 4.7.0 - dev: true - - /@esbuild-kit/core-utils@3.1.0: - resolution: {integrity: sha512-Uuk8RpCg/7fdHSceR1M6XbSZFSuMrxcePFuGgyvsBn+u339dk5OeL4jv2EojwTN2st/unJGsVm4qHWjWNmJ/tw==} - dependencies: - esbuild: 0.17.19 - source-map-support: 0.5.21 - dev: true - - /@esbuild-kit/esm-loader@2.5.5: - resolution: {integrity: sha512-Qwfvj/qoPbClxCRNuac1Du01r9gvNOT+pMYtJDapfB1eoGN1YlJ1BixLyL9WVENRx5RXgNLdfYdx/CuswlGhMw==} - dependencies: - '@esbuild-kit/core-utils': 3.1.0 - get-tsconfig: 4.7.0 - dev: true - /@esbuild/android-arm64@0.16.17: resolution: {integrity: sha512-MIGl6p5sc3RDTLLkYL1MyL8BMRN4tLMRCn+yRJJmEDvYZ2M7tmAf80hx1kbNEUX2KJ50RRtxZ4JHLvCfuB6kBg==} engines: {node: '>=12'} @@ -1196,8 +1216,8 @@ packages: dev: true optional: true - /@esbuild/android-arm64@0.17.19: - resolution: {integrity: sha512-KBMWvEZooR7+kzY0BtbTQn0OAYY7CsiydT63pVEaPtVYF0hXbUaOyZog37DKxK7NF3XacBJOpYT4adIJh+avxA==} + /@esbuild/android-arm64@0.18.15: + resolution: {integrity: sha512-NI/gnWcMl2kXt1HJKOn2H69SYn4YNheKo6NZt1hyfKWdMbaGadxjZIkcj4Gjk/WPxnbFXs9/3HjGHaknCqjrww==} engines: {node: '>=12'} cpu: [arm64] os: [android] @@ -1205,8 +1225,8 @@ packages: dev: true optional: true - /@esbuild/android-arm64@0.18.15: - resolution: {integrity: sha512-NI/gnWcMl2kXt1HJKOn2H69SYn4YNheKo6NZt1hyfKWdMbaGadxjZIkcj4Gjk/WPxnbFXs9/3HjGHaknCqjrww==} + /@esbuild/android-arm64@0.18.20: + resolution: {integrity: sha512-Nz4rJcchGDtENV0eMKUNa6L12zz2zBDXuhj/Vjh18zGqB44Bi7MBMSXjgunJgjRhCmKOjnPuZp4Mb6OKqtMHLQ==} engines: {node: '>=12'} cpu: [arm64] os: [android] @@ -1223,8 +1243,8 @@ packages: dev: true optional: true - /@esbuild/android-arm@0.17.19: - resolution: {integrity: sha512-rIKddzqhmav7MSmoFCmDIb6e2W57geRsM94gV2l38fzhXMwq7hZoClug9USI2pFRGL06f4IOPHHpFNOkWieR8A==} + /@esbuild/android-arm@0.18.15: + resolution: {integrity: sha512-wlkQBWb79/jeEEoRmrxt/yhn5T1lU236OCNpnfRzaCJHZ/5gf82uYx1qmADTBWE0AR/v7FiozE1auk2riyQd3w==} engines: {node: '>=12'} cpu: [arm] os: [android] @@ -1232,8 +1252,8 @@ packages: dev: true optional: true - /@esbuild/android-arm@0.18.15: - resolution: {integrity: sha512-wlkQBWb79/jeEEoRmrxt/yhn5T1lU236OCNpnfRzaCJHZ/5gf82uYx1qmADTBWE0AR/v7FiozE1auk2riyQd3w==} + /@esbuild/android-arm@0.18.20: + resolution: {integrity: sha512-fyi7TDI/ijKKNZTUJAQqiG5T7YjJXgnzkURqmGj13C6dCqckZBLdl4h7bkhHt/t0WP+zO9/zwroDvANaOqO5Sw==} engines: {node: '>=12'} cpu: [arm] os: [android] @@ -1250,8 +1270,8 @@ packages: dev: true optional: true - /@esbuild/android-x64@0.17.19: - resolution: {integrity: sha512-uUTTc4xGNDT7YSArp/zbtmbhO0uEEK9/ETW29Wk1thYUJBz3IVnvgEiEwEa9IeLyvnpKrWK64Utw2bgUmDveww==} + /@esbuild/android-x64@0.18.15: + resolution: {integrity: sha512-FM9NQamSaEm/IZIhegF76aiLnng1kEsZl2eve/emxDeReVfRuRNmvT28l6hoFD9TsCxpK+i4v8LPpEj74T7yjA==} engines: {node: '>=12'} cpu: [x64] os: [android] @@ -1259,8 +1279,8 @@ packages: dev: true optional: true - /@esbuild/android-x64@0.18.15: - resolution: {integrity: sha512-FM9NQamSaEm/IZIhegF76aiLnng1kEsZl2eve/emxDeReVfRuRNmvT28l6hoFD9TsCxpK+i4v8LPpEj74T7yjA==} + /@esbuild/android-x64@0.18.20: + resolution: {integrity: sha512-8GDdlePJA8D6zlZYJV/jnrRAi6rOiNaCC/JclcXpB+KIuvfBN4owLtgzY2bsxnx666XjJx2kDPUmnTtR8qKQUg==} engines: {node: '>=12'} cpu: [x64] os: [android] @@ -1277,8 +1297,8 @@ packages: dev: true optional: true - /@esbuild/darwin-arm64@0.17.19: - resolution: {integrity: sha512-80wEoCfF/hFKM6WE1FyBHc9SfUblloAWx6FJkFWTWiCoht9Mc0ARGEM47e67W9rI09YoUxJL68WHfDRYEAvOhg==} + /@esbuild/darwin-arm64@0.18.15: + resolution: {integrity: sha512-XmrFwEOYauKte9QjS6hz60FpOCnw4zaPAb7XV7O4lx1r39XjJhTN7ZpXqJh4sN6q60zbP6QwAVVA8N/wUyBH/w==} engines: {node: '>=12'} cpu: [arm64] os: [darwin] @@ -1286,8 +1306,8 @@ packages: dev: true optional: true - /@esbuild/darwin-arm64@0.18.15: - resolution: {integrity: sha512-XmrFwEOYauKte9QjS6hz60FpOCnw4zaPAb7XV7O4lx1r39XjJhTN7ZpXqJh4sN6q60zbP6QwAVVA8N/wUyBH/w==} + /@esbuild/darwin-arm64@0.18.20: + resolution: {integrity: sha512-bxRHW5kHU38zS2lPTPOyuyTm+S+eobPUnTNkdJEfAddYgEcll4xkT8DB9d2008DtTbl7uJag2HuE5NZAZgnNEA==} engines: {node: '>=12'} cpu: [arm64] os: [darwin] @@ -1304,8 +1324,8 @@ packages: dev: true optional: true - /@esbuild/darwin-x64@0.17.19: - resolution: {integrity: sha512-IJM4JJsLhRYr9xdtLytPLSH9k/oxR3boaUIYiHkAawtwNOXKE8KoU8tMvryogdcT8AU+Bflmh81Xn6Q0vTZbQw==} + /@esbuild/darwin-x64@0.18.15: + resolution: {integrity: sha512-bMqBmpw1e//7Fh5GLetSZaeo9zSC4/CMtrVFdj+bqKPGJuKyfNJ5Nf2m3LknKZTS+Q4oyPiON+v3eaJ59sLB5A==} engines: {node: '>=12'} cpu: [x64] os: [darwin] @@ -1313,8 +1333,8 @@ packages: dev: true optional: true - /@esbuild/darwin-x64@0.18.15: - resolution: {integrity: sha512-bMqBmpw1e//7Fh5GLetSZaeo9zSC4/CMtrVFdj+bqKPGJuKyfNJ5Nf2m3LknKZTS+Q4oyPiON+v3eaJ59sLB5A==} + /@esbuild/darwin-x64@0.18.20: + resolution: {integrity: sha512-pc5gxlMDxzm513qPGbCbDukOdsGtKhfxD1zJKXjCCcU7ju50O7MeAZ8c4krSJcOIJGFR+qx21yMMVYwiQvyTyQ==} engines: {node: '>=12'} cpu: [x64] os: [darwin] @@ -1331,8 +1351,8 @@ packages: dev: true optional: true - /@esbuild/freebsd-arm64@0.17.19: - resolution: {integrity: sha512-pBwbc7DufluUeGdjSU5Si+P3SoMF5DQ/F/UmTSb8HXO80ZEAJmrykPyzo1IfNbAoaqw48YRpv8shwd1NoI0jcQ==} + /@esbuild/freebsd-arm64@0.18.15: + resolution: {integrity: sha512-LoTK5N3bOmNI9zVLCeTgnk5Rk0WdUTrr9dyDAQGVMrNTh9EAPuNwSTCgaKOKiDpverOa0htPcO9NwslSE5xuLA==} engines: {node: '>=12'} cpu: [arm64] os: [freebsd] @@ -1340,8 +1360,8 @@ packages: dev: true optional: true - /@esbuild/freebsd-arm64@0.18.15: - resolution: {integrity: sha512-LoTK5N3bOmNI9zVLCeTgnk5Rk0WdUTrr9dyDAQGVMrNTh9EAPuNwSTCgaKOKiDpverOa0htPcO9NwslSE5xuLA==} + /@esbuild/freebsd-arm64@0.18.20: + resolution: {integrity: sha512-yqDQHy4QHevpMAaxhhIwYPMv1NECwOvIpGCZkECn8w2WFHXjEwrBn3CeNIYsibZ/iZEUemj++M26W3cNR5h+Tw==} engines: {node: '>=12'} cpu: [arm64] os: [freebsd] @@ -1358,8 +1378,8 @@ packages: dev: true optional: true - /@esbuild/freebsd-x64@0.17.19: - resolution: {integrity: sha512-4lu+n8Wk0XlajEhbEffdy2xy53dpR06SlzvhGByyg36qJw6Kpfk7cp45DR/62aPH9mtJRmIyrXAS5UWBrJT6TQ==} + /@esbuild/freebsd-x64@0.18.15: + resolution: {integrity: sha512-62jX5n30VzgrjAjOk5orYeHFq6sqjvsIj1QesXvn5OZtdt5Gdj0vUNJy9NIpjfdNdqr76jjtzBJKf+h2uzYuTQ==} engines: {node: '>=12'} cpu: [x64] os: [freebsd] @@ -1367,8 +1387,8 @@ packages: dev: true optional: true - /@esbuild/freebsd-x64@0.18.15: - resolution: {integrity: sha512-62jX5n30VzgrjAjOk5orYeHFq6sqjvsIj1QesXvn5OZtdt5Gdj0vUNJy9NIpjfdNdqr76jjtzBJKf+h2uzYuTQ==} + /@esbuild/freebsd-x64@0.18.20: + resolution: {integrity: sha512-tgWRPPuQsd3RmBZwarGVHZQvtzfEBOreNuxEMKFcd5DaDn2PbBxfwLcj4+aenoh7ctXcbXmOQIn8HI6mCSw5MQ==} engines: {node: '>=12'} cpu: [x64] os: [freebsd] @@ -1385,8 +1405,8 @@ packages: dev: true optional: true - /@esbuild/linux-arm64@0.17.19: - resolution: {integrity: sha512-ct1Tg3WGwd3P+oZYqic+YZF4snNl2bsnMKRkb3ozHmnM0dGWuxcPTTntAF6bOP0Sp4x0PjSF+4uHQ1xvxfRKqg==} + /@esbuild/linux-arm64@0.18.15: + resolution: {integrity: sha512-BWncQeuWDgYv0jTNzJjaNgleduV4tMbQjmk/zpPh/lUdMcNEAxy+jvneDJ6RJkrqloG7tB9S9rCrtfk/kuplsQ==} engines: {node: '>=12'} cpu: [arm64] os: [linux] @@ -1394,8 +1414,8 @@ packages: dev: true optional: true - /@esbuild/linux-arm64@0.18.15: - resolution: {integrity: sha512-BWncQeuWDgYv0jTNzJjaNgleduV4tMbQjmk/zpPh/lUdMcNEAxy+jvneDJ6RJkrqloG7tB9S9rCrtfk/kuplsQ==} + /@esbuild/linux-arm64@0.18.20: + resolution: {integrity: sha512-2YbscF+UL7SQAVIpnWvYwM+3LskyDmPhe31pE7/aoTMFKKzIc9lLbyGUpmmb8a8AixOL61sQ/mFh3jEjHYFvdA==} engines: {node: '>=12'} cpu: [arm64] os: [linux] @@ -1412,8 +1432,8 @@ packages: dev: true optional: true - /@esbuild/linux-arm@0.17.19: - resolution: {integrity: sha512-cdmT3KxjlOQ/gZ2cjfrQOtmhG4HJs6hhvm3mWSRDPtZ/lP5oe8FWceS10JaSJC13GBd4eH/haHnqf7hhGNLerA==} + /@esbuild/linux-arm@0.18.15: + resolution: {integrity: sha512-dT4URUv6ir45ZkBqhwZwyFV6cH61k8MttIwhThp2BGiVtagYvCToF+Bggyx2VI57RG4Fbt21f9TmXaYx0DeUJg==} engines: {node: '>=12'} cpu: [arm] os: [linux] @@ -1421,8 +1441,8 @@ packages: dev: true optional: true - /@esbuild/linux-arm@0.18.15: - resolution: {integrity: sha512-dT4URUv6ir45ZkBqhwZwyFV6cH61k8MttIwhThp2BGiVtagYvCToF+Bggyx2VI57RG4Fbt21f9TmXaYx0DeUJg==} + /@esbuild/linux-arm@0.18.20: + resolution: {integrity: sha512-/5bHkMWnq1EgKr1V+Ybz3s1hWXok7mDFUMQ4cG10AfW3wL02PSZi5kFpYKrptDsgb2WAJIvRcDm+qIvXf/apvg==} engines: {node: '>=12'} cpu: [arm] os: [linux] @@ -1439,8 +1459,8 @@ packages: dev: true optional: true - /@esbuild/linux-ia32@0.17.19: - resolution: {integrity: sha512-w4IRhSy1VbsNxHRQpeGCHEmibqdTUx61Vc38APcsRbuVgK0OPEnQ0YD39Brymn96mOx48Y2laBQGqgZ0j9w6SQ==} + /@esbuild/linux-ia32@0.18.15: + resolution: {integrity: sha512-JPXORvgHRHITqfms1dWT/GbEY89u848dC08o0yK3fNskhp0t2TuNUnsrrSgOdH28ceb1hJuwyr8R/1RnyPwocw==} engines: {node: '>=12'} cpu: [ia32] os: [linux] @@ -1448,8 +1468,8 @@ packages: dev: true optional: true - /@esbuild/linux-ia32@0.18.15: - resolution: {integrity: sha512-JPXORvgHRHITqfms1dWT/GbEY89u848dC08o0yK3fNskhp0t2TuNUnsrrSgOdH28ceb1hJuwyr8R/1RnyPwocw==} + /@esbuild/linux-ia32@0.18.20: + resolution: {integrity: sha512-P4etWwq6IsReT0E1KHU40bOnzMHoH73aXp96Fs8TIT6z9Hu8G6+0SHSw9i2isWrD2nbx2qo5yUqACgdfVGx7TA==} engines: {node: '>=12'} cpu: [ia32] os: [linux] @@ -1466,8 +1486,8 @@ packages: dev: true optional: true - /@esbuild/linux-loong64@0.17.19: - resolution: {integrity: sha512-2iAngUbBPMq439a+z//gE+9WBldoMp1s5GWsUSgqHLzLJ9WoZLZhpwWuym0u0u/4XmZ3gpHmzV84PonE+9IIdQ==} + /@esbuild/linux-loong64@0.18.15: + resolution: {integrity: sha512-kArPI0DopjJCEplsVj/H+2Qgzz7vdFSacHNsgoAKpPS6W/Ndh8Oe24HRDQ5QCu4jHgN6XOtfFfLpRx3TXv/mEg==} engines: {node: '>=12'} cpu: [loong64] os: [linux] @@ -1475,8 +1495,8 @@ packages: dev: true optional: true - /@esbuild/linux-loong64@0.18.15: - resolution: {integrity: sha512-kArPI0DopjJCEplsVj/H+2Qgzz7vdFSacHNsgoAKpPS6W/Ndh8Oe24HRDQ5QCu4jHgN6XOtfFfLpRx3TXv/mEg==} + /@esbuild/linux-loong64@0.18.20: + resolution: {integrity: sha512-nXW8nqBTrOpDLPgPY9uV+/1DjxoQ7DoB2N8eocyq8I9XuqJ7BiAMDMf9n1xZM9TgW0J8zrquIb/A7s3BJv7rjg==} engines: {node: '>=12'} cpu: [loong64] os: [linux] @@ -1493,8 +1513,8 @@ packages: dev: true optional: true - /@esbuild/linux-mips64el@0.17.19: - resolution: {integrity: sha512-LKJltc4LVdMKHsrFe4MGNPp0hqDFA1Wpt3jE1gEyM3nKUvOiO//9PheZZHfYRfYl6AwdTH4aTcXSqBerX0ml4A==} + /@esbuild/linux-mips64el@0.18.15: + resolution: {integrity: sha512-b/tmngUfO02E00c1XnNTw/0DmloKjb6XQeqxaYuzGwHe0fHVgx5/D6CWi+XH1DvkszjBUkK9BX7n1ARTOst59w==} engines: {node: '>=12'} cpu: [mips64el] os: [linux] @@ -1502,8 +1522,8 @@ packages: dev: true optional: true - /@esbuild/linux-mips64el@0.18.15: - resolution: {integrity: sha512-b/tmngUfO02E00c1XnNTw/0DmloKjb6XQeqxaYuzGwHe0fHVgx5/D6CWi+XH1DvkszjBUkK9BX7n1ARTOst59w==} + /@esbuild/linux-mips64el@0.18.20: + resolution: {integrity: sha512-d5NeaXZcHp8PzYy5VnXV3VSd2D328Zb+9dEq5HE6bw6+N86JVPExrA6O68OPwobntbNJ0pzCpUFZTo3w0GyetQ==} engines: {node: '>=12'} cpu: [mips64el] os: [linux] @@ -1520,8 +1540,8 @@ packages: dev: true optional: true - /@esbuild/linux-ppc64@0.17.19: - resolution: {integrity: sha512-/c/DGybs95WXNS8y3Ti/ytqETiW7EU44MEKuCAcpPto3YjQbyK3IQVKfF6nbghD7EcLUGl0NbiL5Rt5DMhn5tg==} + /@esbuild/linux-ppc64@0.18.15: + resolution: {integrity: sha512-KXPY69MWw79QJkyvUYb2ex/OgnN/8N/Aw5UDPlgoRtoEfcBqfeLodPr42UojV3NdkoO4u10NXQdamWm1YEzSKw==} engines: {node: '>=12'} cpu: [ppc64] os: [linux] @@ -1529,8 +1549,8 @@ packages: dev: true optional: true - /@esbuild/linux-ppc64@0.18.15: - resolution: {integrity: sha512-KXPY69MWw79QJkyvUYb2ex/OgnN/8N/Aw5UDPlgoRtoEfcBqfeLodPr42UojV3NdkoO4u10NXQdamWm1YEzSKw==} + /@esbuild/linux-ppc64@0.18.20: + resolution: {integrity: sha512-WHPyeScRNcmANnLQkq6AfyXRFr5D6N2sKgkFo2FqguP44Nw2eyDlbTdZwd9GYk98DZG9QItIiTlFLHJHjxP3FA==} engines: {node: '>=12'} cpu: [ppc64] os: [linux] @@ -1547,8 +1567,8 @@ packages: dev: true optional: true - /@esbuild/linux-riscv64@0.17.19: - resolution: {integrity: sha512-FC3nUAWhvFoutlhAkgHf8f5HwFWUL6bYdvLc/TTuxKlvLi3+pPzdZiFKSWz/PF30TB1K19SuCxDTI5KcqASJqA==} + /@esbuild/linux-riscv64@0.18.15: + resolution: {integrity: sha512-komK3NEAeeGRnvFEjX1SfVg6EmkfIi5aKzevdvJqMydYr9N+pRQK0PGJXk+bhoPZwOUgLO4l99FZmLGk/L1jWg==} engines: {node: '>=12'} cpu: [riscv64] os: [linux] @@ -1556,8 +1576,8 @@ packages: dev: true optional: true - /@esbuild/linux-riscv64@0.18.15: - resolution: {integrity: sha512-komK3NEAeeGRnvFEjX1SfVg6EmkfIi5aKzevdvJqMydYr9N+pRQK0PGJXk+bhoPZwOUgLO4l99FZmLGk/L1jWg==} + /@esbuild/linux-riscv64@0.18.20: + resolution: {integrity: sha512-WSxo6h5ecI5XH34KC7w5veNnKkju3zBRLEQNY7mv5mtBmrP/MjNBCAlsM2u5hDBlS3NGcTQpoBvRzqBcRtpq1A==} engines: {node: '>=12'} cpu: [riscv64] os: [linux] @@ -1574,8 +1594,8 @@ packages: dev: true optional: true - /@esbuild/linux-s390x@0.17.19: - resolution: {integrity: sha512-IbFsFbxMWLuKEbH+7sTkKzL6NJmG2vRyy6K7JJo55w+8xDk7RElYn6xvXtDW8HCfoKBFK69f3pgBJSUSQPr+4Q==} + /@esbuild/linux-s390x@0.18.15: + resolution: {integrity: sha512-632T5Ts6gQ2WiMLWRRyeflPAm44u2E/s/TJvn+BP6M5mnHSk93cieaypj3VSMYO2ePTCRqAFXtuYi1yv8uZJNA==} engines: {node: '>=12'} cpu: [s390x] os: [linux] @@ -1583,8 +1603,8 @@ packages: dev: true optional: true - /@esbuild/linux-s390x@0.18.15: - resolution: {integrity: sha512-632T5Ts6gQ2WiMLWRRyeflPAm44u2E/s/TJvn+BP6M5mnHSk93cieaypj3VSMYO2ePTCRqAFXtuYi1yv8uZJNA==} + /@esbuild/linux-s390x@0.18.20: + resolution: {integrity: sha512-+8231GMs3mAEth6Ja1iK0a1sQ3ohfcpzpRLH8uuc5/KVDFneH6jtAJLFGafpzpMRO6DzJ6AvXKze9LfFMrIHVQ==} engines: {node: '>=12'} cpu: [s390x] os: [linux] @@ -1601,8 +1621,8 @@ packages: dev: true optional: true - /@esbuild/linux-x64@0.17.19: - resolution: {integrity: sha512-68ngA9lg2H6zkZcyp22tsVt38mlhWde8l3eJLWkyLrp4HwMUr3c1s/M2t7+kHIhvMjglIBrFpncX1SzMckomGw==} + /@esbuild/linux-x64@0.18.15: + resolution: {integrity: sha512-MsHtX0NgvRHsoOtYkuxyk4Vkmvk3PLRWfA4okK7c+6dT0Fu4SUqXAr9y4Q3d8vUf1VWWb6YutpL4XNe400iQ1g==} engines: {node: '>=12'} cpu: [x64] os: [linux] @@ -1610,8 +1630,8 @@ packages: dev: true optional: true - /@esbuild/linux-x64@0.18.15: - resolution: {integrity: sha512-MsHtX0NgvRHsoOtYkuxyk4Vkmvk3PLRWfA4okK7c+6dT0Fu4SUqXAr9y4Q3d8vUf1VWWb6YutpL4XNe400iQ1g==} + /@esbuild/linux-x64@0.18.20: + resolution: {integrity: sha512-UYqiqemphJcNsFEskc73jQ7B9jgwjWrSayxawS6UVFZGWrAAtkzjxSqnoclCXxWtfwLdzU+vTpcNYhpn43uP1w==} engines: {node: '>=12'} cpu: [x64] os: [linux] @@ -1628,8 +1648,8 @@ packages: dev: true optional: true - /@esbuild/netbsd-x64@0.17.19: - resolution: {integrity: sha512-CwFq42rXCR8TYIjIfpXCbRX0rp1jo6cPIUPSaWwzbVI4aOfX96OXY8M6KNmtPcg7QjYeDmN+DD0Wp3LaBOLf4Q==} + /@esbuild/netbsd-x64@0.18.15: + resolution: {integrity: sha512-djST6s+jQiwxMIVQ5rlt24JFIAr4uwUnzceuFL7BQT4CbrRtqBPueS4GjXSiIpmwVri1Icj/9pFRJ7/aScvT+A==} engines: {node: '>=12'} cpu: [x64] os: [netbsd] @@ -1637,8 +1657,8 @@ packages: dev: true optional: true - /@esbuild/netbsd-x64@0.18.15: - resolution: {integrity: sha512-djST6s+jQiwxMIVQ5rlt24JFIAr4uwUnzceuFL7BQT4CbrRtqBPueS4GjXSiIpmwVri1Icj/9pFRJ7/aScvT+A==} + /@esbuild/netbsd-x64@0.18.20: + resolution: {integrity: sha512-iO1c++VP6xUBUmltHZoMtCUdPlnPGdBom6IrO4gyKPFFVBKioIImVooR5I83nTew5UOYrk3gIJhbZh8X44y06A==} engines: {node: '>=12'} cpu: [x64] os: [netbsd] @@ -1655,8 +1675,8 @@ packages: dev: true optional: true - /@esbuild/openbsd-x64@0.17.19: - resolution: {integrity: sha512-cnq5brJYrSZ2CF6c35eCmviIN3k3RczmHz8eYaVlNasVqsNY+JKohZU5MKmaOI+KkllCdzOKKdPs762VCPC20g==} + /@esbuild/openbsd-x64@0.18.15: + resolution: {integrity: sha512-naeRhUIvhsgeounjkF5mvrNAVMGAm6EJWiabskeE5yOeBbLp7T89tAEw0j5Jm/CZAwyLe3c67zyCWH6fsBLCpw==} engines: {node: '>=12'} cpu: [x64] os: [openbsd] @@ -1664,8 +1684,8 @@ packages: dev: true optional: true - /@esbuild/openbsd-x64@0.18.15: - resolution: {integrity: sha512-naeRhUIvhsgeounjkF5mvrNAVMGAm6EJWiabskeE5yOeBbLp7T89tAEw0j5Jm/CZAwyLe3c67zyCWH6fsBLCpw==} + /@esbuild/openbsd-x64@0.18.20: + resolution: {integrity: sha512-e5e4YSsuQfX4cxcygw/UCPIEP6wbIL+se3sxPdCiMbFLBWu0eiZOJ7WoD+ptCLrmjZBK1Wk7I6D/I3NglUGOxg==} engines: {node: '>=12'} cpu: [x64] os: [openbsd] @@ -1682,8 +1702,8 @@ packages: dev: true optional: true - /@esbuild/sunos-x64@0.17.19: - resolution: {integrity: sha512-vCRT7yP3zX+bKWFeP/zdS6SqdWB8OIpaRq/mbXQxTGHnIxspRtigpkUcDMlSCOejlHowLqII7K2JKevwyRP2rg==} + /@esbuild/sunos-x64@0.18.15: + resolution: {integrity: sha512-qkT2+WxyKbNIKV1AEhI8QiSIgTHMcRctzSaa/I3kVgMS5dl3fOeoqkb7pW76KwxHoriImhx7Mg3TwN/auMDsyQ==} engines: {node: '>=12'} cpu: [x64] os: [sunos] @@ -1691,8 +1711,8 @@ packages: dev: true optional: true - /@esbuild/sunos-x64@0.18.15: - resolution: {integrity: sha512-qkT2+WxyKbNIKV1AEhI8QiSIgTHMcRctzSaa/I3kVgMS5dl3fOeoqkb7pW76KwxHoriImhx7Mg3TwN/auMDsyQ==} + /@esbuild/sunos-x64@0.18.20: + resolution: {integrity: sha512-kDbFRFp0YpTQVVrqUd5FTYmWo45zGaXe0X8E1G/LKFC0v8x0vWrhOWSLITcCn63lmZIxfOMXtCfti/RxN/0wnQ==} engines: {node: '>=12'} cpu: [x64] os: [sunos] @@ -1709,8 +1729,8 @@ packages: dev: true optional: true - /@esbuild/win32-arm64@0.17.19: - resolution: {integrity: sha512-yYx+8jwowUstVdorcMdNlzklLYhPxjniHWFKgRqH7IFlUEa0Umu3KuYplf1HUZZ422e3NU9F4LGb+4O0Kdcaag==} + /@esbuild/win32-arm64@0.18.15: + resolution: {integrity: sha512-HC4/feP+pB2Vb+cMPUjAnFyERs+HJN7E6KaeBlFdBv799MhD+aPJlfi/yk36SED58J9TPwI8MAcVpJgej4ud0A==} engines: {node: '>=12'} cpu: [arm64] os: [win32] @@ -1718,8 +1738,8 @@ packages: dev: true optional: true - /@esbuild/win32-arm64@0.18.15: - resolution: {integrity: sha512-HC4/feP+pB2Vb+cMPUjAnFyERs+HJN7E6KaeBlFdBv799MhD+aPJlfi/yk36SED58J9TPwI8MAcVpJgej4ud0A==} + /@esbuild/win32-arm64@0.18.20: + resolution: {integrity: sha512-ddYFR6ItYgoaq4v4JmQQaAI5s7npztfV4Ag6NrhiaW0RrnOXqBkgwZLofVTlq1daVTQNhtI5oieTvkRPfZrePg==} engines: {node: '>=12'} cpu: [arm64] os: [win32] @@ -1736,8 +1756,8 @@ packages: dev: true optional: true - /@esbuild/win32-ia32@0.17.19: - resolution: {integrity: sha512-eggDKanJszUtCdlVs0RB+h35wNlb5v4TWEkq4vZcmVt5u/HiDZrTXe2bWFQUez3RgNHwx/x4sk5++4NSSicKkw==} + /@esbuild/win32-ia32@0.18.15: + resolution: {integrity: sha512-ovjwoRXI+gf52EVF60u9sSDj7myPixPxqzD5CmkEUmvs+W9Xd0iqISVBQn8xcx4ciIaIVlWCuTbYDOXOnOL44Q==} engines: {node: '>=12'} cpu: [ia32] os: [win32] @@ -1745,8 +1765,8 @@ packages: dev: true optional: true - /@esbuild/win32-ia32@0.18.15: - resolution: {integrity: sha512-ovjwoRXI+gf52EVF60u9sSDj7myPixPxqzD5CmkEUmvs+W9Xd0iqISVBQn8xcx4ciIaIVlWCuTbYDOXOnOL44Q==} + /@esbuild/win32-ia32@0.18.20: + resolution: {integrity: sha512-Wv7QBi3ID/rROT08SABTS7eV4hX26sVduqDOTe1MvGMjNd3EjOz4b7zeexIR62GTIEKrfJXKL9LFxTYgkyeu7g==} engines: {node: '>=12'} cpu: [ia32] os: [win32] @@ -1763,8 +1783,8 @@ packages: dev: true optional: true - /@esbuild/win32-x64@0.17.19: - resolution: {integrity: sha512-lAhycmKnVOuRYNtRtatQR1LPQf2oYCkRGkSFnseDAKPl8lu5SOsK/e1sXe5a0Pc5kHIHe6P2I/ilntNv2xf3cA==} + /@esbuild/win32-x64@0.18.15: + resolution: {integrity: sha512-imUxH9a3WJARyAvrG7srLyiK73XdX83NXQkjKvQ+7vPh3ZxoLrzvPkQKKw2DwZ+RV2ZB6vBfNHP8XScAmQC3aA==} engines: {node: '>=12'} cpu: [x64] os: [win32] @@ -1772,8 +1792,8 @@ packages: dev: true optional: true - /@esbuild/win32-x64@0.18.15: - resolution: {integrity: sha512-imUxH9a3WJARyAvrG7srLyiK73XdX83NXQkjKvQ+7vPh3ZxoLrzvPkQKKw2DwZ+RV2ZB6vBfNHP8XScAmQC3aA==} + /@esbuild/win32-x64@0.18.20: + resolution: {integrity: sha512-kTdfRcSiDfQca/y9QIkng02avJ+NCaQvrMejlsB3RRv5sE9rRoeBPISaZpKxHELzRxZyLvNts1P27W3wV+8geQ==} engines: {node: '>=12'} cpu: [x64] os: [win32] @@ -1781,13 +1801,13 @@ packages: dev: true optional: true - /@eslint-community/eslint-utils@4.4.0(eslint@8.51.0): + /@eslint-community/eslint-utils@4.4.0(eslint@8.53.0): resolution: {integrity: sha512-1/sA4dwrzBAyeUoQ6oxahHKmrZvsnLCg4RfxW3ZFGGmQkSNQPFNLV9CUEFQP1x9EYXHTo5p6xdhZM1Ne9p/AfA==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} peerDependencies: eslint: ^6.0.0 || ^7.0.0 || >=8.0.0 dependencies: - eslint: 8.51.0 + eslint: 8.53.0 eslint-visitor-keys: 3.4.3 dev: true @@ -1796,8 +1816,8 @@ packages: engines: {node: ^12.0.0 || ^14.0.0 || >=16.0.0} dev: true - /@eslint/eslintrc@2.1.2: - resolution: {integrity: sha512-+wvgpDsrB1YqAMdEUCcnTlpfVBH7Vqn6A/NT3D8WVXFIaKMlErPIZT3oCIAVCOtarRpMtelZLqJeU3t7WY6X6g==} + /@eslint/eslintrc@2.1.3: + resolution: {integrity: sha512-yZzuIG+jnVu6hNSzFEN07e8BxF3uAzYtQb6uDkaYZLo6oYZDCq454c5kB8zxnzfCYyP4MIuyBn10L0DqwujTmA==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} dependencies: ajv: 6.12.6 @@ -1813,8 +1833,8 @@ packages: - supports-color dev: true - /@eslint/js@8.51.0: - resolution: {integrity: sha512-HxjQ8Qn+4SI3/AFv6sOrDB+g6PpUTDwSJiQqOrnneEk8L71161srI9gjzzZvYVbzHiVg/BvcH95+cK/zfIt4pg==} + /@eslint/js@8.53.0: + resolution: {integrity: sha512-Kn7K8dx/5U6+cT1yEhpX1w4PCSg0M+XyRILPgvwcEBjerFWCwQj5sbr3/VmxqV0JGHCBCzyd6LxypEuehypY1w==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} dev: true @@ -1994,8 +2014,8 @@ packages: engines: {node: '>=14'} hasBin: true - /@ethereumjs/rlp@5.0.0: - resolution: {integrity: sha512-WuS1l7GJmB0n0HsXLozCoEFc9IwYgf3l0gCkKVYgR67puVF1O4OpEaN0hWmm1c+iHUHFCKt1hJrvy5toLg+6ag==} + /@ethereumjs/rlp@5.0.1: + resolution: {integrity: sha512-Ab/Hfzz+T9Zl+65Nkg+9xAmwKPLicsnQ4NW49pgvJp9ovefuic95cgOS9CbPc9izIEgsqm1UitV0uNveCvud9w==} engines: {node: '>=18'} hasBin: true dev: false @@ -2386,11 +2406,11 @@ packages: '@trufflesuite/bigint-buffer': 1.1.9 dev: true - /@humanwhocodes/config-array@0.11.11: - resolution: {integrity: sha512-N2brEuAadi0CcdeMXUkhbZB84eskAc8MEX1By6qEchoVywSgXPIjou4rYsl0V3Hj0ZnuGycGCjdNgockbzeWNA==} + /@humanwhocodes/config-array@0.11.13: + resolution: {integrity: sha512-JSBDMiDKSzQVngfRjOdFXgFfklaXI4K9nLF49Auh21lmBWRLIK3+xTErTWD4KU54pb6coM6ESE7Awz/FNU3zgQ==} engines: {node: '>=10.10.0'} dependencies: - '@humanwhocodes/object-schema': 1.2.1 + '@humanwhocodes/object-schema': 2.0.1 debug: 4.3.4(supports-color@8.1.1) minimatch: 3.1.2 transitivePeerDependencies: @@ -2402,8 +2422,8 @@ packages: engines: {node: '>=12.22'} dev: true - /@humanwhocodes/object-schema@1.2.1: - resolution: {integrity: sha512-ZnQMnLV4e7hDlUvw8H+U8ASL02SS2Gn6+9Ac3wGGLIe7+je2AeAOxPY+izIPJDfFDb7eDjev0Us8MO1iFRN8hA==} + /@humanwhocodes/object-schema@2.0.1: + resolution: {integrity: sha512-dvuCeX5fC9dXgJn9t+X5atfmgQAzUOWqS1254Gh0m6i8wKd10ebXkfNKiRK+1GWi/yTvvLDHpoxLr0xxxeslWw==} dev: true /@isaacs/cliui@8.0.2: @@ -2927,17 +2947,17 @@ packages: '@nomicfoundation/solidity-analyzer-win32-x64-msvc': 0.1.1 dev: true - /@nomiclabs/hardhat-ethers@2.2.3(ethers@5.7.2)(hardhat@2.18.1): + /@nomiclabs/hardhat-ethers@2.2.3(ethers@5.7.2)(hardhat@2.19.0): resolution: {integrity: sha512-YhzPdzb612X591FOe68q+qXVXGG2ANZRvDo0RRUtimev85rCrAlv/TLMEZw5c+kq9AbzocLTVX/h2jVIFPL9Xg==} peerDependencies: ethers: ^5.0.0 hardhat: ^2.0.0 dependencies: ethers: 5.7.2 - hardhat: 2.18.1(ts-node@10.9.1)(typescript@5.2.2) + hardhat: 2.19.0(ts-node@10.9.1)(typescript@5.2.2) dev: true - /@nomiclabs/hardhat-waffle@2.0.1(@nomiclabs/hardhat-ethers@2.2.3)(ethereum-waffle@4.0.10)(ethers@5.7.2)(hardhat@2.18.1): + /@nomiclabs/hardhat-waffle@2.0.1(@nomiclabs/hardhat-ethers@2.2.3)(ethereum-waffle@4.0.10)(ethers@5.7.2)(hardhat@2.19.0): resolution: {integrity: sha512-2YR2V5zTiztSH9n8BYWgtv3Q+EL0N5Ltm1PAr5z20uAY4SkkfylJ98CIqt18XFvxTD5x4K2wKBzddjV9ViDAZQ==} peerDependencies: '@nomiclabs/hardhat-ethers': ^2.0.0 @@ -2945,15 +2965,15 @@ packages: ethers: ^5.0.0 hardhat: ^2.0.0 dependencies: - '@nomiclabs/hardhat-ethers': 2.2.3(ethers@5.7.2)(hardhat@2.18.1) + '@nomiclabs/hardhat-ethers': 2.2.3(ethers@5.7.2)(hardhat@2.19.0) '@types/sinon-chai': 3.2.5 '@types/web3': 1.0.19 ethereum-waffle: 4.0.10(@ensdomains/ens@0.4.5)(@ensdomains/resolver@0.2.4)(@ethersproject/abi@5.7.0)(@ethersproject/providers@5.7.2)(ethers@5.7.2)(typescript@5.2.2) ethers: 5.7.2 - hardhat: 2.18.1(ts-node@10.9.1)(typescript@5.2.2) + hardhat: 2.19.0(ts-node@10.9.1)(typescript@5.2.2) dev: true - /@nomiclabs/hardhat-waffle@2.0.6(@nomiclabs/hardhat-ethers@2.2.3)(@types/sinon-chai@3.2.5)(ethereum-waffle@4.0.10)(ethers@5.7.2)(hardhat@2.18.1): + /@nomiclabs/hardhat-waffle@2.0.6(@nomiclabs/hardhat-ethers@2.2.3)(@types/sinon-chai@3.2.5)(ethereum-waffle@4.0.10)(ethers@5.7.2)(hardhat@2.19.0): resolution: {integrity: sha512-+Wz0hwmJGSI17B+BhU/qFRZ1l6/xMW82QGXE/Gi+WTmwgJrQefuBs1lIf7hzQ1hLk6hpkvb/zwcNkpVKRYTQYg==} peerDependencies: '@nomiclabs/hardhat-ethers': ^2.0.0 @@ -2962,11 +2982,11 @@ packages: ethers: ^5.0.0 hardhat: ^2.0.0 dependencies: - '@nomiclabs/hardhat-ethers': 2.2.3(ethers@5.7.2)(hardhat@2.18.1) + '@nomiclabs/hardhat-ethers': 2.2.3(ethers@5.7.2)(hardhat@2.19.0) '@types/sinon-chai': 3.2.5 ethereum-waffle: 4.0.10(@ensdomains/ens@0.4.5)(@ensdomains/resolver@0.2.4)(@ethersproject/abi@5.7.0)(@ethersproject/providers@5.7.2)(ethers@5.7.2)(typescript@5.2.2) ethers: 5.7.2 - hardhat: 2.18.1(ts-node@10.9.1)(typescript@5.2.2) + hardhat: 2.19.0(ts-node@10.9.1)(typescript@5.2.2) dev: true /@nrwl/nx-cloud@16.5.2: @@ -2977,11 +2997,11 @@ packages: - debug dev: true - /@nrwl/tao@16.10.0: - resolution: {integrity: sha512-QNAanpINbr+Pod6e1xNgFbzK1x5wmZl+jMocgiEFXZ67KHvmbD6MAQQr0MMz+GPhIu7EE4QCTLTyCEMlAG+K5Q==} + /@nrwl/tao@17.0.3: + resolution: {integrity: sha512-X6zcwf6c3z7TuztRJWM/OCfzm7+LI4Uw4coc9+PWr44ohHkgId2wEJTzXrDT3+lvv8DgwPpgWPwqntw+YcgRYg==} hasBin: true dependencies: - nx: 16.10.0 + nx: 17.0.3 tslib: 2.6.2 transitivePeerDependencies: - '@swc-node/register' @@ -2989,8 +3009,8 @@ packages: - debug dev: true - /@nx/nx-darwin-arm64@16.10.0: - resolution: {integrity: sha512-YF+MIpeuwFkyvM5OwgY/rTNRpgVAI/YiR0yTYCZR+X3AAvP775IVlusNgQ3oedTBRUzyRnI4Tknj1WniENFsvQ==} + /@nx/nx-darwin-arm64@17.0.3: + resolution: {integrity: sha512-KA75JC/hgkt9qwK4dnN1tlaTXWdYItkNMjji6YjkyAYabbLKQKVcQoPocYP/RB/Gng+vNslXwuug2atgxDf43g==} engines: {node: '>= 10'} cpu: [arm64] os: [darwin] @@ -2998,8 +3018,8 @@ packages: dev: true optional: true - /@nx/nx-darwin-x64@16.10.0: - resolution: {integrity: sha512-ypi6YxwXgb0kg2ixKXE3pwf5myVNUgWf1CsV5OzVccCM8NzheMO51KDXTDmEpXdzUsfT0AkO1sk5GZeCjhVONg==} + /@nx/nx-darwin-x64@17.0.3: + resolution: {integrity: sha512-YVWk9jNibD7fzn8oNBl/UNu8NEfcVwFo5wiNyfOql495yP0tyGdZNHD4i/7aS2Y654G1JYDRf7TutJ7wWFU8bg==} engines: {node: '>= 10'} cpu: [x64] os: [darwin] @@ -3007,8 +3027,8 @@ packages: dev: true optional: true - /@nx/nx-freebsd-x64@16.10.0: - resolution: {integrity: sha512-UeEYFDmdbbDkTQamqvtU8ibgu5jQLgFF1ruNb/U4Ywvwutw2d4ruOMl2e0u9hiNja9NFFAnDbvzrDcMo7jYqYw==} + /@nx/nx-freebsd-x64@17.0.3: + resolution: {integrity: sha512-yiYkfY+3IrlBrlaXN6SO4Fnb0a+Ti+FPwAqRPpH6q3uTCh0NmNgE99ydtT31ZbgCF1ZwRK8NdCbuNO3w9uznwA==} engines: {node: '>= 10'} cpu: [x64] os: [freebsd] @@ -3016,8 +3036,8 @@ packages: dev: true optional: true - /@nx/nx-linux-arm-gnueabihf@16.10.0: - resolution: {integrity: sha512-WV3XUC2DB6/+bz1sx+d1Ai9q2Cdr+kTZRN50SOkfmZUQyEBaF6DRYpx/a4ahhxH3ktpNfyY8Maa9OEYxGCBkQA==} + /@nx/nx-linux-arm-gnueabihf@17.0.3: + resolution: {integrity: sha512-x4h6QJlESJZ0bigUlxNEVyi7F/VWQQx+1IBptofXhK5eTOPjJ5qgINdM38AZg+kBJDz5XOVMDejg6RzHlhs0Tg==} engines: {node: '>= 10'} cpu: [arm] os: [linux] @@ -3025,8 +3045,8 @@ packages: dev: true optional: true - /@nx/nx-linux-arm64-gnu@16.10.0: - resolution: {integrity: sha512-aWIkOUw995V3ItfpAi5FuxQ+1e9EWLS1cjWM1jmeuo+5WtaKToJn5itgQOkvSlPz+HSLgM3VfXMvOFALNk125g==} + /@nx/nx-linux-arm64-gnu@17.0.3: + resolution: {integrity: sha512-1lysnsZv9FS+9fciK0qh5PhsQ8U+vyFoR/jiJl+3vqYNUwEmNLD0VEAZzpZL2SJXQqD5E0bjuQpYxiD7YRXImQ==} engines: {node: '>= 10'} cpu: [arm64] os: [linux] @@ -3034,8 +3054,8 @@ packages: dev: true optional: true - /@nx/nx-linux-arm64-musl@16.10.0: - resolution: {integrity: sha512-uO6Gg+irqpVcCKMcEPIQcTFZ+tDI02AZkqkP7koQAjniLEappd8DnUBSQdcn53T086pHpdc264X/ZEpXFfrKWQ==} + /@nx/nx-linux-arm64-musl@17.0.3: + resolution: {integrity: sha512-0/bvSpbc4vOy9E24fu0ajDGe3SO8lmLtlxjXwGRcnzlt/MWM8sazoO0lX163/X2wF6tuL6+HXHOr6AeqsdeRXQ==} engines: {node: '>= 10'} cpu: [arm64] os: [linux] @@ -3043,8 +3063,8 @@ packages: dev: true optional: true - /@nx/nx-linux-x64-gnu@16.10.0: - resolution: {integrity: sha512-134PW/u/arNFAQKpqMJniC7irbChMPz+W+qtyKPAUXE0XFKPa7c1GtlI/wK2dvP9qJDZ6bKf0KtA0U/m2HMUOA==} + /@nx/nx-linux-x64-gnu@17.0.3: + resolution: {integrity: sha512-tKO6MYUxpUsHMuZrYy8hG20RIOdBY3kyEK8wxH8JZZaXKeYUK+5vv5DavWpY5wuu2jffNIJNsbUzcrqOlcbDOg==} engines: {node: '>= 10'} cpu: [x64] os: [linux] @@ -3052,8 +3072,8 @@ packages: dev: true optional: true - /@nx/nx-linux-x64-musl@16.10.0: - resolution: {integrity: sha512-q8sINYLdIJxK/iUx9vRk5jWAWb/2O0PAbOJFwv4qkxBv4rLoN7y+otgCZ5v0xfx/zztFgk/oNY4lg5xYjIso2Q==} + /@nx/nx-linux-x64-musl@17.0.3: + resolution: {integrity: sha512-H88yBLrI51m6NGoCkpBYhacRyTBfDuf7x00SnxSfD1yLlxCazPUG7CGkMedpzXo10YHxCFvg7B/Fa23DRRleUg==} engines: {node: '>= 10'} cpu: [x64] os: [linux] @@ -3061,8 +3081,8 @@ packages: dev: true optional: true - /@nx/nx-win32-arm64-msvc@16.10.0: - resolution: {integrity: sha512-moJkL9kcqxUdJSRpG7dET3UeLIciwrfP08mzBQ12ewo8K8FzxU8ZUsTIVVdNrwt01CXOdXoweGfdQLjJ4qTURA==} + /@nx/nx-win32-arm64-msvc@17.0.3: + resolution: {integrity: sha512-bKzmzjvgLB4IzLWTySqXgBgXawfw0ZSjUkscFQ3ZHrK9loMba1Ue8Ugy2DktlkUrCyPmGSot+YZViTzWP75C3w==} engines: {node: '>= 10'} cpu: [arm64] os: [win32] @@ -3070,8 +3090,8 @@ packages: dev: true optional: true - /@nx/nx-win32-x64-msvc@16.10.0: - resolution: {integrity: sha512-5iV2NKZnzxJwZZ4DM5JVbRG/nkhAbzEskKaLBB82PmYGKzaDHuMHP1lcPoD/rtYMlowZgNA/RQndfKvPBPwmXA==} + /@nx/nx-win32-x64-msvc@17.0.3: + resolution: {integrity: sha512-SJssAOyUM1IW9t84/Uzau9JHo14hnG5mxvcrborNGlLq+WnP0jzISVs7gvV2xWZ9j1JemxA5KLbkMuIkJyR6qQ==} engines: {node: '>= 10'} cpu: [x64] os: [win32] @@ -3079,15 +3099,6 @@ packages: dev: true optional: true - /@parcel/watcher@2.0.4: - resolution: {integrity: sha512-cTDi+FUDBIUOBKEtj+nhiJ71AZVlkAsQFuGQTun5tV9mwQBQgZvhCzG+URPQc8myeN32yRVZEfVAPCs1RW+Jvg==} - engines: {node: '>= 10.0.0'} - requiresBuild: true - dependencies: - node-addon-api: 3.2.1 - node-gyp-build: 4.6.0 - dev: true - /@pedrouid/environment@1.0.1: resolution: {integrity: sha512-HaW78NszGzRZd9SeoI3JD11JqY+lubnaOx7Pewj5pfjqWXOEATpeKIFb9Z4t2WBUK2iryiXX3lzWwmYWgUL0Ug==} @@ -3186,7 +3197,7 @@ packages: resolution: {integrity: sha512-gYw0ki/EAuV1oSyMxpqandHjnthZjYYy+YWpTAzf8BqfXM3ItcZLpjxfg+3+mXW8HIO+3jw6T9iiqEXsqHaMMw==} dependencies: '@safe-global/safe-gateway-typescript-sdk': 3.7.3 - viem: 1.16.5(typescript@5.2.2)(zod@3.22.4) + viem: 1.18.6(typescript@5.2.2)(zod@3.22.4) transitivePeerDependencies: - bufferutil - encoding @@ -3240,14 +3251,13 @@ packages: '@noble/hashes': 1.3.2 '@scure/base': 1.1.3 - /@sentry-internal/tracing@7.74.0: - resolution: {integrity: sha512-JK6IRGgdtZjswGfaGIHNWIThffhOHzVIIaGmglui+VFIzOsOqePjoxaDV0MEvzafxXZD7eWqGE5RGuZ0n6HFVg==} + /@sentry-internal/tracing@7.77.0: + resolution: {integrity: sha512-8HRF1rdqWwtINqGEdx8Iqs9UOP/n8E0vXUu3Nmbqj4p5sQPA7vvCfq+4Y4rTqZFc7sNdFpDsRION5iQEh8zfZw==} engines: {node: '>=8'} dependencies: - '@sentry/core': 7.74.0 - '@sentry/types': 7.74.0 - '@sentry/utils': 7.74.0 - tslib: 2.6.2 + '@sentry/core': 7.77.0 + '@sentry/types': 7.77.0 + '@sentry/utils': 7.77.0 dev: false /@sentry/core@5.30.0: @@ -3261,13 +3271,12 @@ packages: tslib: 1.14.1 dev: true - /@sentry/core@7.74.0: - resolution: {integrity: sha512-83NRuqn7nDZkSVBN5yJQqcpXDG4yMYiB7TkYUKrGTzBpRy6KUOrkCdybuKk0oraTIGiGSe5WEwCFySiNgR9FzA==} + /@sentry/core@7.77.0: + resolution: {integrity: sha512-Tj8oTYFZ/ZD+xW8IGIsU6gcFXD/gfE+FUxUaeSosd9KHwBQNOLhZSsYo/tTVf/rnQI/dQnsd4onPZLiL+27aTg==} engines: {node: '>=8'} dependencies: - '@sentry/types': 7.74.0 - '@sentry/utils': 7.74.0 - tslib: 2.6.2 + '@sentry/types': 7.77.0 + '@sentry/utils': 7.77.0 dev: false /@sentry/hub@5.30.0: @@ -3305,18 +3314,15 @@ packages: - supports-color dev: true - /@sentry/node@7.74.0: - resolution: {integrity: sha512-uBmW2/z0cz/WFIG74ZF7lSipO0XNzMf9yrdqnZXnGDYsUZE4I4QiqDN0hNi6fkTgf9MYRC8uFem2OkAvyPJ74Q==} + /@sentry/node@7.77.0: + resolution: {integrity: sha512-Ob5tgaJOj0OYMwnocc6G/CDLWC7hXfVvKX/ofkF98+BbN/tQa5poL+OwgFn9BA8ud8xKzyGPxGU6LdZ8Oh3z/g==} engines: {node: '>=8'} dependencies: - '@sentry-internal/tracing': 7.74.0 - '@sentry/core': 7.74.0 - '@sentry/types': 7.74.0 - '@sentry/utils': 7.74.0 - cookie: 0.5.0 + '@sentry-internal/tracing': 7.77.0 + '@sentry/core': 7.77.0 + '@sentry/types': 7.77.0 + '@sentry/utils': 7.77.0 https-proxy-agent: 5.0.1 - lru_map: 0.3.3 - tslib: 2.6.2 transitivePeerDependencies: - supports-color dev: false @@ -3337,8 +3343,8 @@ packages: engines: {node: '>=6'} dev: true - /@sentry/types@7.74.0: - resolution: {integrity: sha512-rI5eIRbUycWjn6s6o3yAjjWtIvYSxZDdnKv5je2EZINfLKcMPj1dkl6wQd2F4y7gLfD/N6Y0wZYIXC3DUdJQQg==} + /@sentry/types@7.77.0: + resolution: {integrity: sha512-nfb00XRJVi0QpDHg+JkqrmEBHsqBnxJu191Ded+Cs1OJ5oPXEW6F59LVcBScGvMqe+WEk1a73eH8XezwfgrTsA==} engines: {node: '>=8'} dev: false @@ -3350,12 +3356,11 @@ packages: tslib: 1.14.1 dev: true - /@sentry/utils@7.74.0: - resolution: {integrity: sha512-k3np8nuTPtx5KDODPtULfFln4UXdE56MZCcF19Jv6Ljxf+YN/Ady1+0Oi3e0XoSvFpWNyWnglauT7M65qCE6kg==} + /@sentry/utils@7.77.0: + resolution: {integrity: sha512-NmM2kDOqVchrey3N5WSzdQoCsyDkQkiRxExPaNI2oKQ/jMWHs9yt0tSy7otPBcXs0AP59ihl75Bvm1tDRcsp5g==} engines: {node: '>=8'} dependencies: - '@sentry/types': 7.74.0 - tslib: 2.6.2 + '@sentry/types': 7.77.0 dev: false /@sinclair/typebox@0.27.8: @@ -3508,8 +3513,8 @@ packages: '@stablelib/random': 1.0.2 '@stablelib/wipe': 1.0.1 - /@swc/core-darwin-arm64@1.3.92: - resolution: {integrity: sha512-v7PqZUBtIF6Q5Cp48gqUiG8zQQnEICpnfNdoiY3xjQAglCGIQCjJIDjreZBoeZQZspB27lQN4eZ43CX18+2SnA==} + /@swc/core-darwin-arm64@1.3.95: + resolution: {integrity: sha512-VAuBAP3MNetO/yBIBzvorUXq7lUBwhfpJxYViSxyluMwtoQDhE/XWN598TWMwMl1ZuImb56d7eUsuFdjgY7pJw==} engines: {node: '>=10'} cpu: [arm64] os: [darwin] @@ -3517,8 +3522,8 @@ packages: dev: true optional: true - /@swc/core-darwin-x64@1.3.92: - resolution: {integrity: sha512-Q3XIgQfXyxxxms3bPN+xGgvwk0TtG9l89IomApu+yTKzaIIlf051mS+lGngjnh9L0aUiCp6ICyjDLtutWP54fw==} + /@swc/core-darwin-x64@1.3.95: + resolution: {integrity: sha512-20vF2rvUsN98zGLZc+dsEdHvLoCuiYq/1B+TDeE4oolgTFDmI1jKO+m44PzWjYtKGU9QR95sZ6r/uec0QC5O4Q==} engines: {node: '>=10'} cpu: [x64] os: [darwin] @@ -3526,8 +3531,8 @@ packages: dev: true optional: true - /@swc/core-linux-arm-gnueabihf@1.3.92: - resolution: {integrity: sha512-tnOCoCpNVXC+0FCfG84PBZJyLlz0Vfj9MQhyhCvlJz9hQmvpf8nTdKH7RHrOn8VfxtUBLdVi80dXgIFgbvl7qA==} + /@swc/core-linux-arm-gnueabihf@1.3.95: + resolution: {integrity: sha512-oEudEM8PST1MRNGs+zu0cx5i9uP8TsLE4/L9HHrS07Ck0RJ3DCj3O2fU832nmLe2QxnAGPwBpSO9FntLfOiWEQ==} engines: {node: '>=10'} cpu: [arm] os: [linux] @@ -3535,8 +3540,8 @@ packages: dev: true optional: true - /@swc/core-linux-arm64-gnu@1.3.92: - resolution: {integrity: sha512-lFfGhX32w8h1j74Iyz0Wv7JByXIwX11OE9UxG+oT7lG0RyXkF4zKyxP8EoxfLrDXse4Oop434p95e3UNC3IfCw==} + /@swc/core-linux-arm64-gnu@1.3.95: + resolution: {integrity: sha512-pIhFI+cuC1aYg+0NAPxwT/VRb32f2ia8oGxUjQR6aJg65gLkUYQzdwuUmpMtFR2WVf7WVFYxUnjo4UyMuyh3ng==} engines: {node: '>=10'} cpu: [arm64] os: [linux] @@ -3544,8 +3549,8 @@ packages: dev: true optional: true - /@swc/core-linux-arm64-musl@1.3.92: - resolution: {integrity: sha512-rOZtRcLj57MSAbiecMsqjzBcZDuaCZ8F6l6JDwGkQ7u1NYR57cqF0QDyU7RKS1Jq27Z/Vg21z5cwqoH5fLN+Sg==} + /@swc/core-linux-arm64-musl@1.3.95: + resolution: {integrity: sha512-ZpbTr+QZDT4OPJfjPAmScqdKKaT+wGurvMU5AhxLaf85DuL8HwUwwlL0n1oLieLc47DwIJEMuKQkYhXMqmJHlg==} engines: {node: '>=10'} cpu: [arm64] os: [linux] @@ -3553,8 +3558,8 @@ packages: dev: true optional: true - /@swc/core-linux-x64-gnu@1.3.92: - resolution: {integrity: sha512-qptoMGnBL6v89x/Qpn+l1TH1Y0ed+v0qhNfAEVzZvCvzEMTFXphhlhYbDdpxbzRmCjH6GOGq7Y+xrWt9T1/ARg==} + /@swc/core-linux-x64-gnu@1.3.95: + resolution: {integrity: sha512-n9SuHEFtdfSJ+sHdNXNRuIOVprB8nbsz+08apKfdo4lEKq6IIPBBAk5kVhPhkjmg2dFVHVo4Tr/OHXM1tzWCCw==} engines: {node: '>=10'} cpu: [x64] os: [linux] @@ -3562,8 +3567,8 @@ packages: dev: true optional: true - /@swc/core-linux-x64-musl@1.3.92: - resolution: {integrity: sha512-g2KrJ43bZkCZHH4zsIV5ErojuV1OIpUHaEyW1gf7JWKaFBpWYVyubzFPvPkjcxHGLbMsEzO7w/NVfxtGMlFH/Q==} + /@swc/core-linux-x64-musl@1.3.95: + resolution: {integrity: sha512-L1JrVlsXU3LC0WwmVnMK9HrOT2uhHahAoPNMJnZQpc18a0paO9fqifPG8M/HjNRffMUXR199G/phJsf326UvVg==} engines: {node: '>=10'} cpu: [x64] os: [linux] @@ -3571,8 +3576,8 @@ packages: dev: true optional: true - /@swc/core-win32-arm64-msvc@1.3.92: - resolution: {integrity: sha512-3MCRGPAYDoQ8Yyd3WsCMc8eFSyKXY5kQLyg/R5zEqA0uthomo0m0F5/fxAJMZGaSdYkU1DgF73ctOWOf+Z/EzQ==} + /@swc/core-win32-arm64-msvc@1.3.95: + resolution: {integrity: sha512-YaP4x/aZbUyNdqCBpC2zL8b8n58MEpOUpmOIZK6G1SxGi+2ENht7gs7+iXpWPc0sy7X3YPKmSWMAuui0h8lgAA==} engines: {node: '>=10'} cpu: [arm64] os: [win32] @@ -3580,8 +3585,8 @@ packages: dev: true optional: true - /@swc/core-win32-ia32-msvc@1.3.92: - resolution: {integrity: sha512-zqTBKQhgfWm73SVGS8FKhFYDovyRl1f5dTX1IwSKynO0qHkRCqJwauFJv/yevkpJWsI2pFh03xsRs9HncTQKSA==} + /@swc/core-win32-ia32-msvc@1.3.95: + resolution: {integrity: sha512-w0u3HI916zT4BC/57gOd+AwAEjXeUlQbGJ9H4p/gzs1zkSHtoDQghVUNy3n/ZKp9KFod/95cA8mbVF9t1+6epQ==} engines: {node: '>=10'} cpu: [ia32] os: [win32] @@ -3589,8 +3594,8 @@ packages: dev: true optional: true - /@swc/core-win32-x64-msvc@1.3.92: - resolution: {integrity: sha512-41bE66ddr9o/Fi1FBh0sHdaKdENPTuDpv1IFHxSg0dJyM/jX8LbkjnpdInYXHBxhcLVAPraVRrNsC4SaoPw2Pg==} + /@swc/core-win32-x64-msvc@1.3.95: + resolution: {integrity: sha512-5RGnMt0S6gg4Gc6QtPUJ3Qs9Un4sKqccEzgH/tj7V/DVTJwKdnBKxFZfgQ34OR2Zpz7zGOn889xwsFVXspVWNA==} engines: {node: '>=10'} cpu: [x64] os: [win32] @@ -3598,8 +3603,8 @@ packages: dev: true optional: true - /@swc/core@1.3.92: - resolution: {integrity: sha512-vx0vUrf4YTEw59njOJ46Ha5i0cZTMYdRHQ7KXU29efN1MxcmJH2RajWLPlvQarOP1ab9iv9cApD7SMchDyx2vA==} + /@swc/core@1.3.95: + resolution: {integrity: sha512-PMrNeuqIusq9DPDooV3FfNEbZuTu5jKAc04N3Hm6Uk2Fl49cqElLFQ4xvl4qDmVDz97n3n/C1RE0/f6WyGPEiA==} engines: {node: '>=10'} requiresBuild: true peerDependencies: @@ -3611,16 +3616,16 @@ packages: '@swc/counter': 0.1.1 '@swc/types': 0.1.5 optionalDependencies: - '@swc/core-darwin-arm64': 1.3.92 - '@swc/core-darwin-x64': 1.3.92 - '@swc/core-linux-arm-gnueabihf': 1.3.92 - '@swc/core-linux-arm64-gnu': 1.3.92 - '@swc/core-linux-arm64-musl': 1.3.92 - '@swc/core-linux-x64-gnu': 1.3.92 - '@swc/core-linux-x64-musl': 1.3.92 - '@swc/core-win32-arm64-msvc': 1.3.92 - '@swc/core-win32-ia32-msvc': 1.3.92 - '@swc/core-win32-x64-msvc': 1.3.92 + '@swc/core-darwin-arm64': 1.3.95 + '@swc/core-darwin-x64': 1.3.95 + '@swc/core-linux-arm-gnueabihf': 1.3.95 + '@swc/core-linux-arm64-gnu': 1.3.95 + '@swc/core-linux-arm64-musl': 1.3.95 + '@swc/core-linux-x64-gnu': 1.3.95 + '@swc/core-linux-x64-musl': 1.3.95 + '@swc/core-win32-arm64-msvc': 1.3.95 + '@swc/core-win32-ia32-msvc': 1.3.95 + '@swc/core-win32-x64-msvc': 1.3.95 dev: true /@swc/counter@0.1.1: @@ -3673,7 +3678,7 @@ packages: resolution: {integrity: sha512-0DGPd9AR3+iDTjGoMpxIkAsUihHZ3Ai6CneU6bRRrffXMgzCdlNk43jTrD2/5LT6CBb3MWTP8v510JzYtahD2w==} engines: {node: '>=14'} dependencies: - '@babel/code-frame': 7.22.10 + '@babel/code-frame': 7.22.13 '@babel/runtime': 7.22.6 '@types/aria-query': 5.0.1 aria-query: 5.1.3 @@ -3683,8 +3688,8 @@ packages: pretty-format: 27.5.1 dev: false - /@testing-library/jest-dom@6.0.1(vitest@0.34.2): - resolution: {integrity: sha512-0hx/AWrJp8EKr8LmC5jrV3Lx8TZySH7McU1Ix2czBPQnLd458CefSEGjZy7w8kaBRA6LhoPkGjoZ3yqSs338IQ==} + /@testing-library/jest-dom@6.1.4(vitest@0.34.2): + resolution: {integrity: sha512-wpoYrCYwSZ5/AxcrjLxJmCU6I5QAJXslEeSiMQqaWmP2Kzpd1LvF/qxmAIW2qposULGWq2gw30GgVNFLSc2Jnw==} engines: {node: '>=14', npm: '>=6', yarn: '>=1'} peerDependencies: '@jest/globals': '>= 28' @@ -3701,7 +3706,7 @@ packages: vitest: optional: true dependencies: - '@adobe/css-tools': 4.2.0 + '@adobe/css-tools': 4.3.1 '@babel/runtime': 7.22.6 aria-query: 5.3.0 chalk: 3.0.0 @@ -3855,42 +3860,42 @@ packages: /@types/bn.js@4.11.6: resolution: {integrity: sha512-pqr857jrp2kPuO9uRjZ3PwnJTjoQy+fcdxvBTvHm6dkmEL9q+hDD/2j/0ELOBPtPnS8LjCX0gI9nbl8lVkadpg==} dependencies: - '@types/node': 20.8.5 + '@types/node': 20.8.9 dev: true /@types/bn.js@5.1.0: resolution: {integrity: sha512-QSSVYj7pYFN49kW77o2s9xTCwZ8F2xLbjLLSEVh8D2F4JUhZtPAGOFLTD+ffqksBx/u4cE/KImFjyhqCjn/LIA==} dependencies: - '@types/node': 20.8.5 + '@types/node': 20.8.9 dev: true /@types/body-parser@1.19.1: resolution: {integrity: sha512-a6bTJ21vFOGIkwM0kzh9Yr89ziVxq4vYH2fQ6N8AeipEzai/cFK6aGMArIkUeIdRIgpwQa+2bXiLuUJCpSf2Cg==} dependencies: '@types/connect': 3.4.35 - '@types/node': 20.8.5 + '@types/node': 20.8.9 dev: true /@types/chai-as-promised@7.1.5: resolution: {integrity: sha512-jStwss93SITGBwt/niYrkf2C+/1KTeZCZl1LaeezTlqppAKeoQC7jxyqYuP72sxBGKCIbw7oHgbYssIRzT5FCQ==} dependencies: - '@types/chai': 4.3.7 + '@types/chai': 4.3.8 dev: true /@types/chai-subset@1.3.3: resolution: {integrity: sha512-frBecisrNGz+F4T6bcc+NLeolfiojh5FxW2klu669+8BARtyQv2C/GkNW6FUodVe4BroGMP/wER/YDGc7rEllw==} dependencies: - '@types/chai': 4.3.7 - dev: true - - /@types/chai@4.3.6: - resolution: {integrity: sha512-VOVRLM1mBxIRxydiViqPcKn6MIxZytrbMpd6RJLIWKxUNr3zux8no0Oc7kJx0WAPIitgZ0gkrDS+btlqQpubpw==} + '@types/chai': 4.3.8 dev: true /@types/chai@4.3.7: resolution: {integrity: sha512-/k+vesl92vMvMygmQrFe9Aimxi6oQXFUX9mA5HanTrKUSAMoLauSi6PNFOdRw0oeqilaW600GNx2vSaT2f8aIQ==} dev: true + /@types/chai@4.3.8: + resolution: {integrity: sha512-yW/qTM4mRBBcsA9Xw9FbcImYtFPY7sgr+G/O5RDYVmxiy9a+pE5FyoFUi8JYCZY5nicj8atrr1pcfPiYpeNGOA==} + dev: true + /@types/change-case@2.3.1: resolution: {integrity: sha512-HYiGjhmGInNzJjtt6ciXEfl2s8ZQGUQpPiwgWSth1fycE69hXbV/RgWH7MvSq2QPhMBzi4SGhu1vE+cMx1xB8g==} deprecated: This is a stub types definition for change-case (https://github.com/blakeembrey/change-case). change-case provides its own type definitions, so you don't need @types/change-case installed! @@ -3901,7 +3906,7 @@ packages: /@types/connect@3.4.35: resolution: {integrity: sha512-cdeYyv4KWoEgpBISTxWvqYsVy444DOqehiF3fM3ne10AmJ62RSyNkUnxMJXHQWRQQX2eR94m5y1IZyDwBjV9FQ==} dependencies: - '@types/node': 20.8.5 + '@types/node': 20.8.9 /@types/dateformat@5.0.0: resolution: {integrity: sha512-SZg4JdHIWHQGEokbYGZSDvo5wA4TLYPXaqhigs/wH+REDOejcJzgH+qyY+HtEUtWOZxEUkbhbdYPqQDiEgrXeA==} @@ -3915,7 +3920,7 @@ packages: /@types/express-serve-static-core@4.17.35: resolution: {integrity: sha512-wALWQwrgiB2AWTT91CB62b6Yt0sNHpznUXeZEcnPU3DRdlDIz74x8Qg1UUYKSVFi+va5vKOLYRBI1bRKiLLKIg==} dependencies: - '@types/node': 20.8.5 + '@types/node': 20.8.9 '@types/qs': 6.9.7 '@types/range-parser': 1.2.4 '@types/send': 0.17.1 @@ -3934,7 +3939,7 @@ packages: resolution: {integrity: sha512-IO+MJPVhoqz+28h1qLAcBEH2+xHMK6MTyHJc7MTnnYb6wsoLR29POVGJ7LycmVXIqyy/4/2ShP5sUwTXuOwb/w==} dependencies: '@types/minimatch': 5.1.2 - '@types/node': 20.8.4 + '@types/node': 20.8.8 dev: true /@types/is-ci@3.0.0: @@ -3961,7 +3966,7 @@ packages: dependencies: '@types/abstract-leveldown': 5.0.2 '@types/level-errors': 3.0.0 - '@types/node': 20.8.5 + '@types/node': 20.8.9 dev: true /@types/lru-cache@5.1.1: @@ -3993,17 +3998,17 @@ packages: /@types/mkdirp@0.5.2: resolution: {integrity: sha512-U5icWpv7YnZYGsN4/cmh3WD2onMY0aJIiTE6+51TwJCttdHvtCYmkBNOobHlXwrJRL0nkH9jH4kD+1FAdMN4Tg==} dependencies: - '@types/node': 20.8.5 + '@types/node': 20.8.9 dev: true - /@types/mocha@10.0.2: - resolution: {integrity: sha512-NaHL0+0lLNhX6d9rs+NSt97WH/gIlRHmszXbQ/8/MV/eVcFNdeJ/GYhrFuUc8K7WuPhRhTSdMkCp8VMzhUq85w==} + /@types/mocha@10.0.4: + resolution: {integrity: sha512-xKU7bUjiFTIttpWaIZ9qvgg+22O1nmbA+HRxdlR+u6TWsGfmFdXrheJoK4fFxrHNVIOBDvDNKZG+LYBpMHpX3w==} dev: true - /@types/morgan@1.9.6: - resolution: {integrity: sha512-xfKogz5WcKww2DAiVT9zxMgrqQt+Shq8tDVeLT+otoj6dJnkRkyJxMF51mHtUc3JCPKGk5x1EBU0buuGpfftlQ==} + /@types/morgan@1.9.7: + resolution: {integrity: sha512-4sJFBUBrIZkP5EvMm1L6VCXp3SQe8dnXqlVpe1jsmTjS1JQVmSjnpMNs8DosQd6omBi/K7BSKJ6z/Mc3ki0K9g==} dependencies: - '@types/node': 20.8.4 + '@types/node': 20.8.8 dev: true /@types/ms@0.7.31: @@ -4012,7 +4017,7 @@ packages: /@types/node-fetch@2.6.4: resolution: {integrity: sha512-1ZX9fcN4Rvkvgv4E6PAY5WXUFWFcRWxZa3EW83UjycOB9ljJCedb2CupIP4RZMEwF/M3eTcCihbBRgwtGbg5Rg==} dependencies: - '@types/node': 20.8.5 + '@types/node': 20.8.9 form-data: 3.0.1 dev: true @@ -4023,16 +4028,16 @@ packages: /@types/node@12.20.55: resolution: {integrity: sha512-J8xLz7q2OFulZ2cyGTLE1TbbZcjpno7FaN6zdJNrgAdrJ+DZzh/uFR6YrTb4C+nXakvud8Q4+rbhoIWlYQbUFQ==} - /@types/node@20.8.4: - resolution: {integrity: sha512-ZVPnqU58giiCjSxjVUESDtdPk4QR5WQhhINbc9UBrKLU68MX5BF6kbQzTrkwbolyr0X8ChBpXfavr5mZFKZQ5A==} + /@types/node@20.8.8: + resolution: {integrity: sha512-YRsdVxq6OaLfmR9Hy816IMp33xOBjfyOgUd77ehqg96CFywxAPbDbXvAsuN2KVg2HOT8Eh6uAfU+l4WffwPVrQ==} dependencies: undici-types: 5.25.3 dev: true - /@types/node@20.8.5: - resolution: {integrity: sha512-SPlobFgbidfIeOYlzXiEjSYeIJiOCthv+9tSQVpvk4PAdIIc+2SmjNVzWXk9t0Y7dl73Zdf+OgXKHX9XtkqUpw==} + /@types/node@20.8.9: + resolution: {integrity: sha512-UzykFsT3FhHb1h7yD4CA4YhBHq545JC0YnEz41xkipN88eKQtL6rSgocL5tbAP6Ola9Izm/Aw4Ora8He4x0BHg==} dependencies: - undici-types: 5.25.3 + undici-types: 5.26.5 /@types/normalize-package-data@2.4.1: resolution: {integrity: sha512-Gj7cI7z+98M282Tqmp2K5EIsoouUEzbBJhQQzDE3jSIRk6r9gsz0oUokqIUR4u1R3dMHo0pDHM7sNOHyhulypw==} @@ -4044,11 +4049,11 @@ packages: /@types/pbkdf2@3.1.0: resolution: {integrity: sha512-Cf63Rv7jCQ0LaL8tNXmEyqTHuIJxRdlS5vMh1mj5voN4+QFhVZnlZruezqpWYDiJ8UTzhP0VmeLXCmBk66YrMQ==} dependencies: - '@types/node': 20.8.5 + '@types/node': 20.8.9 dev: true - /@types/pino-multi-stream@5.1.4: - resolution: {integrity: sha512-+UrFCcIx4cUo473GwCt5/v8m0r+W08iuaphu8L5bx76zcShvQRWPtKkRxImUCLXW9bHpPFHAJZKANMP/vAbycA==} + /@types/pino-multi-stream@5.1.5: + resolution: {integrity: sha512-md4VfNYACuZZVgBbYqv9D4msKIyLmIdyf/kdjT7HG/xhjM18pKseDGylME0nPvNR66bpYQ2i4v4zPWe8FzwZPA==} dependencies: '@types/pino': 6.3.11 dev: true @@ -4062,13 +4067,13 @@ packages: /@types/pino-std-serializers@2.4.1: resolution: {integrity: sha512-17XcksO47M24IVTVKPeAByWUd3Oez7EbIjXpSbzMPhXVzgjGtrOa49gKBwxH9hb8dKv58OelsWQ+A1G1l9S3wQ==} dependencies: - '@types/node': 20.8.5 + '@types/node': 20.8.9 dev: true /@types/pino@6.3.11: resolution: {integrity: sha512-S7+fLONqSpHeW9d7TApUqO6VN47KYgOXhCNKwGBVLHObq8HhaAYlVqUNdfnvoXjCMiwE5xcPm/5R2ZUh8bgaXQ==} dependencies: - '@types/node': 20.8.5 + '@types/node': 20.8.9 '@types/pino-pretty': 4.7.1 '@types/pino-std-serializers': 2.4.1 sonic-boom: 2.8.0 @@ -4078,7 +4083,7 @@ packages: resolution: {integrity: sha512-wKoab31pknvILkxAF8ss+v9iNyhw5Iu/0jLtRkUD74cNfOOLJNnqfFKAv0r7wVaTQxRZtWrMpGfShwwBjOcgcg==} deprecated: This is a stub types definition. pino provides its own type definitions, so you do not need this installed. dependencies: - pino: 8.16.0 + pino: 8.16.1 dev: true /@types/prettier@2.3.2: @@ -4114,7 +4119,7 @@ packages: /@types/readable-stream@2.3.15: resolution: {integrity: sha512-oM5JSKQCcICF1wvGgmecmHldZ48OZamtMxcGGVICOJA8o8cahXC1zEVAif8iwoc5j8etxFaRFnf095+CDsuoFQ==} dependencies: - '@types/node': 20.8.5 + '@types/node': 20.8.9 safe-buffer: 5.1.2 dev: true @@ -4125,7 +4130,7 @@ packages: /@types/secp256k1@4.0.3: resolution: {integrity: sha512-Da66lEIFeIz9ltsdMZcpQvmrmmoqrfju8pm1BH8WbYjZSwUgCwXLb9C+9XYogwBITnbsSaMdVPb2ekf7TV+03w==} dependencies: - '@types/node': 20.8.5 + '@types/node': 20.8.9 dev: true /@types/seedrandom@3.0.1: @@ -4144,20 +4149,20 @@ packages: resolution: {integrity: sha512-Cwo8LE/0rnvX7kIIa3QHCkcuF21c05Ayb0ZfxPiv0W8VRiZiNW/WuRupHKpqqGVGf7SUA44QSOUKaEd9lIrd/Q==} dependencies: '@types/mime': 1.3.2 - '@types/node': 20.8.5 + '@types/node': 20.8.9 dev: true /@types/serve-static@1.13.10: resolution: {integrity: sha512-nCkHGI4w7ZgAdNkrEu0bv+4xNV/XDqW+DydknebMOQwkpDGx8G+HTlj7R7ABI8i8nKxVw0wtKPi1D+lPOkh4YQ==} dependencies: '@types/mime': 1.3.2 - '@types/node': 20.8.5 + '@types/node': 20.8.9 dev: true /@types/sinon-chai@3.2.5: resolution: {integrity: sha512-bKQqIpew7mmIGNRlxW6Zli/QVyc3zikpGzCa797B/tRnD9OtHvZ/ts8sYXV+Ilj9u3QRaUEM8xrjgd1gwm1BpQ==} dependencies: - '@types/chai': 4.3.7 + '@types/chai': 4.3.8 '@types/sinon': 10.0.2 dev: true @@ -4188,16 +4193,16 @@ packages: /@types/ws@7.4.7: resolution: {integrity: sha512-JQbbmxZTZehdc2iszGKs5oC3NFnjeay7mtAWrdt7qNtAVK0g19muApzAy4bm9byz79xa2ZnO/BOBC2R8RC5Lww==} dependencies: - '@types/node': 20.8.5 + '@types/node': 20.8.9 /@types/ws@8.5.3: resolution: {integrity: sha512-6YOoWjruKj1uLf3INHH7D3qTXwFfEsg1kf3c0uDdSBJwfa/llkwIjrAGV7j7mVgGNbzTQ3HiHKKDXl6bJPD97w==} dependencies: - '@types/node': 20.8.5 + '@types/node': 20.8.9 dev: false - /@typescript-eslint/eslint-plugin@6.7.5(@typescript-eslint/parser@6.7.5)(eslint@8.51.0)(typescript@5.2.2): - resolution: {integrity: sha512-JhtAwTRhOUcP96D0Y6KYnwig/MRQbOoLGXTON2+LlyB/N35SP9j1boai2zzwXb7ypKELXMx3DVk9UTaEq1vHEw==} + /@typescript-eslint/eslint-plugin@6.10.0(@typescript-eslint/parser@6.9.1)(eslint@8.53.0)(typescript@5.2.2): + resolution: {integrity: sha512-uoLj4g2OTL8rfUQVx2AFO1hp/zja1wABJq77P6IclQs6I/m9GLrm7jCdgzZkvWdDCQf1uEvoa8s8CupsgWQgVg==} engines: {node: ^16.0.0 || >=18.0.0} peerDependencies: '@typescript-eslint/parser': ^6.0.0 || ^6.0.0-alpha @@ -4208,13 +4213,13 @@ packages: optional: true dependencies: '@eslint-community/regexpp': 4.6.2 - '@typescript-eslint/parser': 6.7.5(eslint@8.51.0)(typescript@5.2.2) - '@typescript-eslint/scope-manager': 6.7.5 - '@typescript-eslint/type-utils': 6.7.5(eslint@8.51.0)(typescript@5.2.2) - '@typescript-eslint/utils': 6.7.5(eslint@8.51.0)(typescript@5.2.2) - '@typescript-eslint/visitor-keys': 6.7.5 + '@typescript-eslint/parser': 6.9.1(eslint@8.53.0)(typescript@5.2.2) + '@typescript-eslint/scope-manager': 6.10.0 + '@typescript-eslint/type-utils': 6.10.0(eslint@8.53.0)(typescript@5.2.2) + '@typescript-eslint/utils': 6.10.0(eslint@8.53.0)(typescript@5.2.2) + '@typescript-eslint/visitor-keys': 6.10.0 debug: 4.3.4(supports-color@8.1.1) - eslint: 8.51.0 + eslint: 8.53.0 graphemer: 1.4.0 ignore: 5.2.4 natural-compare: 1.4.0 @@ -4225,8 +4230,8 @@ packages: - supports-color dev: true - /@typescript-eslint/parser@6.7.5(eslint@8.51.0)(typescript@5.2.2): - resolution: {integrity: sha512-bIZVSGx2UME/lmhLcjdVc7ePBwn7CLqKarUBL4me1C5feOd663liTGjMBGVcGr+BhnSLeP4SgwdvNnnkbIdkCw==} + /@typescript-eslint/parser@6.9.1(eslint@8.53.0)(typescript@5.2.2): + resolution: {integrity: sha512-C7AK2wn43GSaCUZ9do6Ksgi2g3mwFkMO3Cis96kzmgudoVaKyt62yNzJOktP0HDLb/iO2O0n2lBOzJgr6Q/cyg==} engines: {node: ^16.0.0 || >=18.0.0} peerDependencies: eslint: ^7.0.0 || ^8.0.0 @@ -4235,27 +4240,35 @@ packages: typescript: optional: true dependencies: - '@typescript-eslint/scope-manager': 6.7.5 - '@typescript-eslint/types': 6.7.5 - '@typescript-eslint/typescript-estree': 6.7.5(typescript@5.2.2) - '@typescript-eslint/visitor-keys': 6.7.5 + '@typescript-eslint/scope-manager': 6.9.1 + '@typescript-eslint/types': 6.9.1 + '@typescript-eslint/typescript-estree': 6.9.1(typescript@5.2.2) + '@typescript-eslint/visitor-keys': 6.9.1 debug: 4.3.4(supports-color@8.1.1) - eslint: 8.51.0 + eslint: 8.53.0 typescript: 5.2.2 transitivePeerDependencies: - supports-color dev: true - /@typescript-eslint/scope-manager@6.7.5: - resolution: {integrity: sha512-GAlk3eQIwWOJeb9F7MKQ6Jbah/vx1zETSDw8likab/eFcqkjSD7BI75SDAeC5N2L0MmConMoPvTsmkrg71+B1A==} + /@typescript-eslint/scope-manager@6.10.0: + resolution: {integrity: sha512-TN/plV7dzqqC2iPNf1KrxozDgZs53Gfgg5ZHyw8erd6jd5Ta/JIEcdCheXFt9b1NYb93a1wmIIVW/2gLkombDg==} + engines: {node: ^16.0.0 || >=18.0.0} + dependencies: + '@typescript-eslint/types': 6.10.0 + '@typescript-eslint/visitor-keys': 6.10.0 + dev: true + + /@typescript-eslint/scope-manager@6.9.1: + resolution: {integrity: sha512-38IxvKB6NAne3g/+MyXMs2Cda/Sz+CEpmm+KLGEM8hx/CvnSRuw51i8ukfwB/B/sESdeTGet1NH1Wj7I0YXswg==} engines: {node: ^16.0.0 || >=18.0.0} dependencies: - '@typescript-eslint/types': 6.7.5 - '@typescript-eslint/visitor-keys': 6.7.5 + '@typescript-eslint/types': 6.9.1 + '@typescript-eslint/visitor-keys': 6.9.1 dev: true - /@typescript-eslint/type-utils@6.7.5(eslint@8.51.0)(typescript@5.2.2): - resolution: {integrity: sha512-Gs0qos5wqxnQrvpYv+pf3XfcRXW6jiAn9zE/K+DlmYf6FcpxeNYN0AIETaPR7rHO4K2UY+D0CIbDP9Ut0U4m1g==} + /@typescript-eslint/type-utils@6.10.0(eslint@8.53.0)(typescript@5.2.2): + resolution: {integrity: sha512-wYpPs3hgTFblMYwbYWPT3eZtaDOjbLyIYuqpwuLBBqhLiuvJ+9sEp2gNRJEtR5N/c9G1uTtQQL5AhV0fEPJYcg==} engines: {node: ^16.0.0 || >=18.0.0} peerDependencies: eslint: ^7.0.0 || ^8.0.0 @@ -4264,23 +4277,49 @@ packages: typescript: optional: true dependencies: - '@typescript-eslint/typescript-estree': 6.7.5(typescript@5.2.2) - '@typescript-eslint/utils': 6.7.5(eslint@8.51.0)(typescript@5.2.2) + '@typescript-eslint/typescript-estree': 6.10.0(typescript@5.2.2) + '@typescript-eslint/utils': 6.10.0(eslint@8.53.0)(typescript@5.2.2) debug: 4.3.4(supports-color@8.1.1) - eslint: 8.51.0 + eslint: 8.53.0 ts-api-utils: 1.0.1(typescript@5.2.2) typescript: 5.2.2 transitivePeerDependencies: - supports-color dev: true - /@typescript-eslint/types@6.7.5: - resolution: {integrity: sha512-WboQBlOXtdj1tDFPyIthpKrUb+kZf2VroLZhxKa/VlwLlLyqv/PwUNgL30BlTVZV1Wu4Asu2mMYPqarSO4L5ZQ==} + /@typescript-eslint/types@6.10.0: + resolution: {integrity: sha512-36Fq1PWh9dusgo3vH7qmQAj5/AZqARky1Wi6WpINxB6SkQdY5vQoT2/7rW7uBIsPDcvvGCLi4r10p0OJ7ITAeg==} + engines: {node: ^16.0.0 || >=18.0.0} + dev: true + + /@typescript-eslint/types@6.9.1: + resolution: {integrity: sha512-BUGslGOb14zUHOUmDB2FfT6SI1CcZEJYfF3qFwBeUrU6srJfzANonwRYHDpLBuzbq3HaoF2XL2hcr01c8f8OaQ==} engines: {node: ^16.0.0 || >=18.0.0} dev: true - /@typescript-eslint/typescript-estree@6.7.5(typescript@5.2.2): - resolution: {integrity: sha512-NhJiJ4KdtwBIxrKl0BqG1Ur+uw7FiOnOThcYx9DpOGJ/Abc9z2xNzLeirCG02Ig3vkvrc2qFLmYSSsaITbKjlg==} + /@typescript-eslint/typescript-estree@6.10.0(typescript@5.2.2): + resolution: {integrity: sha512-ek0Eyuy6P15LJVeghbWhSrBCj/vJpPXXR+EpaRZqou7achUWL8IdYnMSC5WHAeTWswYQuP2hAZgij/bC9fanBg==} + engines: {node: ^16.0.0 || >=18.0.0} + peerDependencies: + typescript: '*' + peerDependenciesMeta: + typescript: + optional: true + dependencies: + '@typescript-eslint/types': 6.10.0 + '@typescript-eslint/visitor-keys': 6.10.0 + debug: 4.3.4(supports-color@8.1.1) + globby: 11.1.0 + is-glob: 4.0.3 + semver: 7.5.4 + ts-api-utils: 1.0.1(typescript@5.2.2) + typescript: 5.2.2 + transitivePeerDependencies: + - supports-color + dev: true + + /@typescript-eslint/typescript-estree@6.9.1(typescript@5.2.2): + resolution: {integrity: sha512-U+mUylTHfcqeO7mLWVQ5W/tMLXqVpRv61wm9ZtfE5egz7gtnmqVIw9ryh0mgIlkKk9rZLY3UHygsBSdB9/ftyw==} engines: {node: ^16.0.0 || >=18.0.0} peerDependencies: typescript: '*' @@ -4288,8 +4327,8 @@ packages: typescript: optional: true dependencies: - '@typescript-eslint/types': 6.7.5 - '@typescript-eslint/visitor-keys': 6.7.5 + '@typescript-eslint/types': 6.9.1 + '@typescript-eslint/visitor-keys': 6.9.1 debug: 4.3.4(supports-color@8.1.1) globby: 11.1.0 is-glob: 4.0.3 @@ -4300,33 +4339,45 @@ packages: - supports-color dev: true - /@typescript-eslint/utils@6.7.5(eslint@8.51.0)(typescript@5.2.2): - resolution: {integrity: sha512-pfRRrH20thJbzPPlPc4j0UNGvH1PjPlhlCMq4Yx7EGjV7lvEeGX0U6MJYe8+SyFutWgSHsdbJ3BXzZccYggezA==} + /@typescript-eslint/utils@6.10.0(eslint@8.53.0)(typescript@5.2.2): + resolution: {integrity: sha512-v+pJ1/RcVyRc0o4wAGux9x42RHmAjIGzPRo538Z8M1tVx6HOnoQBCX/NoadHQlZeC+QO2yr4nNSFWOoraZCAyg==} engines: {node: ^16.0.0 || >=18.0.0} peerDependencies: eslint: ^7.0.0 || ^8.0.0 dependencies: - '@eslint-community/eslint-utils': 4.4.0(eslint@8.51.0) + '@eslint-community/eslint-utils': 4.4.0(eslint@8.53.0) '@types/json-schema': 7.0.12 '@types/semver': 7.5.0 - '@typescript-eslint/scope-manager': 6.7.5 - '@typescript-eslint/types': 6.7.5 - '@typescript-eslint/typescript-estree': 6.7.5(typescript@5.2.2) - eslint: 8.51.0 + '@typescript-eslint/scope-manager': 6.10.0 + '@typescript-eslint/types': 6.10.0 + '@typescript-eslint/typescript-estree': 6.10.0(typescript@5.2.2) + eslint: 8.53.0 semver: 7.5.4 transitivePeerDependencies: - supports-color - typescript dev: true - /@typescript-eslint/visitor-keys@6.7.5: - resolution: {integrity: sha512-3MaWdDZtLlsexZzDSdQWsFQ9l9nL8B80Z4fImSpyllFC/KLqWQRdEcB+gGGO+N3Q2uL40EsG66wZLsohPxNXvg==} + /@typescript-eslint/visitor-keys@6.10.0: + resolution: {integrity: sha512-xMGluxQIEtOM7bqFCo+rCMh5fqI+ZxV5RUUOa29iVPz1OgCZrtc7rFnz5cLUazlkPKYqX+75iuDq7m0HQ48nCg==} + engines: {node: ^16.0.0 || >=18.0.0} + dependencies: + '@typescript-eslint/types': 6.10.0 + eslint-visitor-keys: 3.4.3 + dev: true + + /@typescript-eslint/visitor-keys@6.9.1: + resolution: {integrity: sha512-MUaPUe/QRLEffARsmNfmpghuQkW436DvESW+h+M52w0coICHRfD6Np9/K6PdACwnrq1HmuLl+cSPZaJmeVPkSw==} engines: {node: ^16.0.0 || >=18.0.0} dependencies: - '@typescript-eslint/types': 6.7.5 + '@typescript-eslint/types': 6.9.1 eslint-visitor-keys: 3.4.3 dev: true + /@ungap/structured-clone@1.2.0: + resolution: {integrity: sha512-zuVdFrMJiuCDQUMCzQaD6KL28MjnqqN8XnAqiEq9PNm/hCPTSGfrXCOfwj1ow4LFb/tNymJPwsNbVePc1xFqrQ==} + dev: true + /@vitest/coverage-istanbul@0.34.6(vitest@0.34.1): resolution: {integrity: sha512-5KaBNZPDSk2ybavC3rZ1pWGniw7sJ5usuwVGRUYzJwiBfWvnLpuUer7bjw7qUCRGdKJXrBgb/Dsgif9rkwMX/A==} peerDependencies: @@ -4475,56 +4526,56 @@ packages: pretty-format: 29.7.0 dev: true - /@vue/compiler-core@3.2.36: - resolution: {integrity: sha512-bbyZM5hvBicv0PW3KUfVi+x3ylHnfKG7DOn5wM+f2OztTzTjLEyBb/5yrarIYpmnGitVGbjZqDbODyW4iK8hqw==} + /@vue/compiler-core@3.3.4: + resolution: {integrity: sha512-cquyDNvZ6jTbf/+x+AgM2Arrp6G4Dzbb0R64jiG804HRMfRiFXWI6kqUVqZ6ZR0bQhIoQjB4+2bhNtVwndW15g==} dependencies: - '@babel/parser': 7.22.10 - '@vue/shared': 3.2.36 + '@babel/parser': 7.23.0 + '@vue/shared': 3.3.4 estree-walker: 2.0.2 - source-map: 0.6.1 + source-map-js: 1.0.2 dev: true - /@vue/compiler-dom@3.2.36: - resolution: {integrity: sha512-tcOTAOiW4s24QLnq+ON6J+GRONXJ+A/mqKCORi0LSlIh8XQlNnlm24y8xIL8la+ZDgkdbjarQ9ZqYSvEja6gVA==} + /@vue/compiler-dom@3.3.4: + resolution: {integrity: sha512-wyM+OjOVpuUukIq6p5+nwHYtj9cFroz9cwkfmP9O1nzH68BenTTv0u7/ndggT8cIQlnBeOo6sUT/gvHcIkLA5w==} dependencies: - '@vue/compiler-core': 3.2.36 - '@vue/shared': 3.2.36 + '@vue/compiler-core': 3.3.4 + '@vue/shared': 3.3.4 dev: true - /@vue/compiler-sfc@3.2.36: - resolution: {integrity: sha512-AvGb4bTj4W8uQ4BqaSxo7UwTEqX5utdRSMyHy58OragWlt8nEACQ9mIeQh3K4di4/SX+41+pJrLIY01lHAOFOA==} + /@vue/compiler-sfc@3.3.4: + resolution: {integrity: sha512-6y/d8uw+5TkCuzBkgLS0v3lSM3hJDntFEiUORM11pQ/hKvkhSKZrXW6i69UyXlJQisJxuUEJKAWEqWbWsLeNKQ==} dependencies: - '@babel/parser': 7.22.10 - '@vue/compiler-core': 3.2.36 - '@vue/compiler-dom': 3.2.36 - '@vue/compiler-ssr': 3.2.36 - '@vue/reactivity-transform': 3.2.36 - '@vue/shared': 3.2.36 + '@babel/parser': 7.23.0 + '@vue/compiler-core': 3.3.4 + '@vue/compiler-dom': 3.3.4 + '@vue/compiler-ssr': 3.3.4 + '@vue/reactivity-transform': 3.3.4 + '@vue/shared': 3.3.4 estree-walker: 2.0.2 - magic-string: 0.25.9 + magic-string: 0.30.1 postcss: 8.4.27 - source-map: 0.6.1 + source-map-js: 1.0.2 dev: true - /@vue/compiler-ssr@3.2.36: - resolution: {integrity: sha512-+KugInUFRvOxEdLkZwE+W43BqHyhBh0jpYXhmqw1xGq2dmE6J9eZ8UUSOKNhdHtQ/iNLWWeK/wPZkVLUf3YGaw==} + /@vue/compiler-ssr@3.3.4: + resolution: {integrity: sha512-m0v6oKpup2nMSehwA6Uuu+j+wEwcy7QmwMkVNVfrV9P2qE5KshC6RwOCq8fjGS/Eak/uNb8AaWekfiXxbBB6gQ==} dependencies: - '@vue/compiler-dom': 3.2.36 - '@vue/shared': 3.2.36 + '@vue/compiler-dom': 3.3.4 + '@vue/shared': 3.3.4 dev: true - /@vue/reactivity-transform@3.2.36: - resolution: {integrity: sha512-Jk5o2BhpODC9XTA7o4EL8hSJ4JyrFWErLtClG3NH8wDS7ri9jBDWxI7/549T7JY9uilKsaNM+4pJASLj5dtRwA==} + /@vue/reactivity-transform@3.3.4: + resolution: {integrity: sha512-MXgwjako4nu5WFLAjpBnCj/ieqcjE2aJBINUNQzkZQfzIZA4xn+0fV1tIYBJvvva3N3OvKGofRLvQIwEQPpaXw==} dependencies: - '@babel/parser': 7.22.10 - '@vue/compiler-core': 3.2.36 - '@vue/shared': 3.2.36 + '@babel/parser': 7.23.0 + '@vue/compiler-core': 3.3.4 + '@vue/shared': 3.3.4 estree-walker: 2.0.2 - magic-string: 0.25.9 + magic-string: 0.30.1 dev: true - /@vue/shared@3.2.36: - resolution: {integrity: sha512-JtB41wXl7Au3+Nl3gD16Cfpj7k/6aCroZ6BbOiCMFCMvrOpkg/qQUXTso2XowaNqBbnkuGHurLAqkLBxNGc1hQ==} + /@vue/shared@3.3.4: + resolution: {integrity: sha512-7OjdcV8vQ74eiz1TZLzZP4JwqM5fA94K6yntPS5Z25r9HDuGNzaGdgvwKYq6S+MxwF0TFRwe50fIR/MYnakdkQ==} dev: true /@wagmi/chains@0.2.22(typescript@5.2.2): @@ -4537,7 +4588,7 @@ packages: dependencies: typescript: 5.2.2 - /@wagmi/cli@1.5.2(@wagmi/core@1.4.3)(typescript@5.2.2)(wagmi@1.0.1): + /@wagmi/cli@1.5.2(@wagmi/core@1.4.5)(typescript@5.2.2)(wagmi@1.0.1): resolution: {integrity: sha512-UfLMYhW6mQBCjR8A5s01Chf9GpHzdpcuuBuzJ36QGXcMSJAxylz5ImVZWfCRV0ct1UruydjKVSW1QSI6azNxRQ==} engines: {node: '>=14'} hasBin: true @@ -4553,7 +4604,7 @@ packages: wagmi: optional: true dependencies: - '@wagmi/core': 1.4.3(react@18.2.0)(typescript@5.2.2)(viem@1.16.5) + '@wagmi/core': 1.4.5(react@18.2.0)(typescript@5.2.2)(viem@1.18.6) abitype: 0.8.7(typescript@5.2.2)(zod@3.22.3) abort-controller: 3.0.0 bundle-require: 3.1.2(esbuild@0.16.17) @@ -4575,15 +4626,15 @@ packages: picocolors: 1.0.0 prettier: 2.8.8 typescript: 5.2.2 - viem: 1.16.5(typescript@5.2.2)(zod@3.22.3) - wagmi: 1.0.1(react-dom@18.2.0)(react@18.2.0)(typescript@5.2.2)(viem@1.16.5) + viem: 1.18.6(typescript@5.2.2)(zod@3.22.3) + wagmi: 1.0.1(react-dom@18.2.0)(react@18.2.0)(typescript@5.2.2)(viem@1.18.6) zod: 3.22.3 transitivePeerDependencies: - bufferutil - utf-8-validate dev: true - /@wagmi/connectors@1.0.1(@wagmi/chains@0.2.22)(react@18.2.0)(typescript@5.2.2)(viem@1.16.5): + /@wagmi/connectors@1.0.1(@wagmi/chains@0.2.22)(react@18.2.0)(typescript@5.2.2)(viem@1.18.6): resolution: {integrity: sha512-fl01vym19DE1uoE+MlASw5zo3Orr/YXlJRjOKLaKYtV+Q7jOLY4TwHgq7sEMs+JYOvFICFBEAlWNNxidr51AqQ==} peerDependencies: '@wagmi/chains': '>=0.2.0' @@ -4606,7 +4657,7 @@ packages: abitype: 0.8.1(typescript@5.2.2) eventemitter3: 4.0.7 typescript: 5.2.2 - viem: 1.16.5(typescript@5.2.2)(zod@3.22.4) + viem: 1.18.6(typescript@5.2.2)(zod@3.22.4) transitivePeerDependencies: - '@react-native-async-storage/async-storage' - bufferutil @@ -4618,8 +4669,8 @@ packages: - utf-8-validate - zod - /@wagmi/connectors@3.1.2(react@18.2.0)(typescript@5.2.2)(viem@1.16.5): - resolution: {integrity: sha512-IlLKErqCzQRBUcCvXGPowcczbWcvJtEG006gPsAoePNJEXCHEWoKASghgu+L/bqD7006Z6mW6zlTNjcSQJvFAg==} + /@wagmi/connectors@3.1.3(react@18.2.0)(typescript@5.2.2)(viem@1.18.6): + resolution: {integrity: sha512-UgwsQKQDFObJVJMf9pDfFoXTv710o4zrTHyhIWKBTMMkLpCMsMxN5+ZaDhBYt/BgoRinfRYQo8uwuwLhxE6Log==} peerDependencies: typescript: '>=5.0.4' viem: '>=0.3.35' @@ -4631,14 +4682,14 @@ packages: '@ledgerhq/connect-kit-loader': 1.1.0 '@safe-global/safe-apps-provider': 0.17.1(typescript@5.2.2) '@safe-global/safe-apps-sdk': 8.0.0(typescript@5.2.2) - '@walletconnect/ethereum-provider': 2.10.1(@walletconnect/modal@2.6.2) + '@walletconnect/ethereum-provider': 2.10.2(@walletconnect/modal@2.6.2) '@walletconnect/legacy-provider': 2.0.0 '@walletconnect/modal': 2.6.2(react@18.2.0) - '@walletconnect/utils': 2.10.1 + '@walletconnect/utils': 2.10.2 abitype: 0.8.7(typescript@5.2.2)(zod@3.22.3) eventemitter3: 4.0.7 typescript: 5.2.2 - viem: 1.16.5(typescript@5.2.2)(zod@3.22.4) + viem: 1.18.6(typescript@5.2.2)(zod@3.22.4) transitivePeerDependencies: - '@react-native-async-storage/async-storage' - '@types/react' @@ -4651,7 +4702,7 @@ packages: - zod dev: true - /@wagmi/core@1.0.1(react@18.2.0)(typescript@5.2.2)(viem@1.16.5): + /@wagmi/core@1.0.1(react@18.2.0)(typescript@5.2.2)(viem@1.18.6): resolution: {integrity: sha512-Zzg4Ob92QMF9NsC+z5/8JZjMn3NCCnwVWGJlv79qRX9mp5Ku40OzJNvqDnjcSGjshe6H0L/KtFZAqTlmu8lT7w==} peerDependencies: typescript: '>=4.9.4' @@ -4661,11 +4712,11 @@ packages: optional: true dependencies: '@wagmi/chains': 0.2.22(typescript@5.2.2) - '@wagmi/connectors': 1.0.1(@wagmi/chains@0.2.22)(react@18.2.0)(typescript@5.2.2)(viem@1.16.5) + '@wagmi/connectors': 1.0.1(@wagmi/chains@0.2.22)(react@18.2.0)(typescript@5.2.2)(viem@1.18.6) abitype: 0.8.1(typescript@5.2.2) eventemitter3: 4.0.7 typescript: 5.2.2 - viem: 1.16.5(typescript@5.2.2)(zod@3.22.4) + viem: 1.18.6(typescript@5.2.2)(zod@3.22.4) zustand: 4.3.9(react@18.2.0) transitivePeerDependencies: - '@react-native-async-storage/async-storage' @@ -4679,8 +4730,8 @@ packages: - utf-8-validate - zod - /@wagmi/core@1.4.3(react@18.2.0)(typescript@5.2.2)(viem@1.16.5): - resolution: {integrity: sha512-CIV9jwv5ue+WpqmA3FvwGa+23cppe7oIaz6TRnlGm0Hm0wDImSaQSWqcsFyOPvleD29oOIJ8e3KnHINEvI64AA==} + /@wagmi/core@1.4.5(react@18.2.0)(typescript@5.2.2)(viem@1.18.6): + resolution: {integrity: sha512-N9luRb1Uk4tBN9kaYcQSWKE9AsRt/rvZaFt5IZech4JPzNN2sQlfhKd9GEjOXYRDqEPHdDvos7qyBKiDNTz4GA==} peerDependencies: typescript: '>=5.0.4' viem: '>=0.3.35' @@ -4688,11 +4739,11 @@ packages: typescript: optional: true dependencies: - '@wagmi/connectors': 3.1.2(react@18.2.0)(typescript@5.2.2)(viem@1.16.5) + '@wagmi/connectors': 3.1.3(react@18.2.0)(typescript@5.2.2)(viem@1.18.6) abitype: 0.8.7(typescript@5.2.2)(zod@3.22.3) eventemitter3: 4.0.7 typescript: 5.2.2 - viem: 1.16.5(typescript@5.2.2)(zod@3.22.4) + viem: 1.18.6(typescript@5.2.2)(zod@3.22.4) zustand: 4.3.9(react@18.2.0) transitivePeerDependencies: - '@react-native-async-storage/async-storage' @@ -4707,8 +4758,8 @@ packages: - zod dev: true - /@walletconnect/core@2.10.1: - resolution: {integrity: sha512-WAoXfmj+Zy5q48TnrKUjmHXJCBahzKwbul+noepRZf7JDtUAZ9IOWpUjg+UPRbfK5EiWZ0TF42S6SXidf7EHoQ==} + /@walletconnect/core@2.10.2: + resolution: {integrity: sha512-JQz/xp3SLEpTeRQctdck2ugSBVEpMxoSE+lFi2voJkZop1hv6P+uqr6E4PzjFluAjeAnKlT1xvra0aFWjPWVcw==} dependencies: '@walletconnect/heartbeat': 1.2.1 '@walletconnect/jsonrpc-provider': 1.0.13 @@ -4721,8 +4772,8 @@ packages: '@walletconnect/relay-auth': 1.0.4 '@walletconnect/safe-json': 1.0.2 '@walletconnect/time': 1.0.2 - '@walletconnect/types': 2.10.1 - '@walletconnect/utils': 2.10.1 + '@walletconnect/types': 2.10.2 + '@walletconnect/utils': 2.10.2 events: 3.3.0 lodash.isequal: 4.5.0 uint8arrays: 3.1.1 @@ -4779,8 +4830,8 @@ packages: dependencies: tslib: 1.14.1 - /@walletconnect/ethereum-provider@2.10.1(@walletconnect/modal@2.6.2): - resolution: {integrity: sha512-Yhoz8EXkKzxOlBT6G+elphqCx/gkH6RxD9/ZAiy9lLc8Ng5p1gvKCVVP5zsGNE9FbkKmHd+J9JJRzn2Bw2yqtQ==} + /@walletconnect/ethereum-provider@2.10.2(@walletconnect/modal@2.6.2): + resolution: {integrity: sha512-QMYFZ6+rVq2CJLdIPdKK0j1Qm66UA27oQU5V2SrL8EVwl7wFfm0Bq7fnL+qAWeDpn612dNeNErpk/ROa1zWlWg==} peerDependencies: '@walletconnect/modal': '>=2' peerDependenciesMeta: @@ -4792,10 +4843,10 @@ packages: '@walletconnect/jsonrpc-types': 1.0.3 '@walletconnect/jsonrpc-utils': 1.0.8 '@walletconnect/modal': 2.6.2(react@18.2.0) - '@walletconnect/sign-client': 2.10.1 - '@walletconnect/types': 2.10.1 - '@walletconnect/universal-provider': 2.10.1 - '@walletconnect/utils': 2.10.1 + '@walletconnect/sign-client': 2.10.2 + '@walletconnect/types': 2.10.2 + '@walletconnect/universal-provider': 2.10.2 + '@walletconnect/utils': 2.10.2 events: 3.3.0 transitivePeerDependencies: - '@react-native-async-storage/async-storage' @@ -5018,17 +5069,17 @@ packages: dependencies: tslib: 1.14.1 - /@walletconnect/sign-client@2.10.1: - resolution: {integrity: sha512-iG3eJGi1yXeG3xGeVSSMf8wDFyx239B0prLQfy1uYDtYFb2ynnH/09oqAZyKn96W5nfQzUgM2Mz157PVdloH3Q==} + /@walletconnect/sign-client@2.10.2: + resolution: {integrity: sha512-vviSLV3f92I0bReX+OLr1HmbH0uIzYEQQFd1MzIfDk9PkfFT/LLAHhUnDaIAMkIdippqDcJia+5QEtT4JihL3Q==} dependencies: - '@walletconnect/core': 2.10.1 + '@walletconnect/core': 2.10.2 '@walletconnect/events': 1.0.1 '@walletconnect/heartbeat': 1.2.1 '@walletconnect/jsonrpc-utils': 1.0.8 '@walletconnect/logger': 2.0.1 '@walletconnect/time': 1.0.2 - '@walletconnect/types': 2.10.1 - '@walletconnect/utils': 2.10.1 + '@walletconnect/types': 2.10.2 + '@walletconnect/utils': 2.10.2 events: 3.3.0 transitivePeerDependencies: - '@react-native-async-storage/async-storage' @@ -5060,8 +5111,8 @@ packages: dependencies: tslib: 1.14.1 - /@walletconnect/types@2.10.1: - resolution: {integrity: sha512-7pccAhajQdiH2kYywjE1XI64IqRI+4ioyGy0wvz8d0UFQ/DSG3MLKR8jHf5aTOafQQ/HRLz6xvlzN4a7gIVkUQ==} + /@walletconnect/types@2.10.2: + resolution: {integrity: sha512-luNV+07Wdla4STi9AejseCQY31tzWKQ5a7C3zZZaRK/di+rFaAAb7YW04OP4klE7tw/mJRGPTlekZElmHxO8kQ==} dependencies: '@walletconnect/events': 1.0.1 '@walletconnect/heartbeat': 1.2.1 @@ -5087,17 +5138,17 @@ packages: - '@react-native-async-storage/async-storage' - lokijs - /@walletconnect/universal-provider@2.10.1: - resolution: {integrity: sha512-81QxTH/X4dRoYCz0U9iOrBYOcj7N897ONcB57wsGhEkV7Rc9htmWJq2CzeOuxvVZ+pNZkE+/aw9LrhizO1Ltxg==} + /@walletconnect/universal-provider@2.10.2: + resolution: {integrity: sha512-wFgI0LbQ3D56sgaUMsgOHCM5m8WLxiC71BGuCKQfApgsbNMVKugYVy2zWHyUyi8sqTQHI+uSaVpDev4UHq9LEw==} dependencies: '@walletconnect/jsonrpc-http-connection': 1.0.7 '@walletconnect/jsonrpc-provider': 1.0.13 '@walletconnect/jsonrpc-types': 1.0.3 '@walletconnect/jsonrpc-utils': 1.0.8 '@walletconnect/logger': 2.0.1 - '@walletconnect/sign-client': 2.10.1 - '@walletconnect/types': 2.10.1 - '@walletconnect/utils': 2.10.1 + '@walletconnect/sign-client': 2.10.2 + '@walletconnect/types': 2.10.2 + '@walletconnect/utils': 2.10.2 events: 3.3.0 transitivePeerDependencies: - '@react-native-async-storage/async-storage' @@ -5128,8 +5179,8 @@ packages: - lokijs - utf-8-validate - /@walletconnect/utils@2.10.1: - resolution: {integrity: sha512-DM0dKgm9O58l7VqJEyV2OVv16XRePhDAReI23let6WdW1dSpw/Y/A89Lp99ZJOjLm2FxyblMRF3YRaZtHwBffw==} + /@walletconnect/utils@2.10.2: + resolution: {integrity: sha512-syxXRpc2yhSknMu3IfiBGobxOY7fLfLTJuw+ppKaeO6WUdZpIit3wfuGOcc0Ms3ZPFCrGfyGOoZsCvgdXtptRg==} dependencies: '@stablelib/chacha20poly1305': 1.0.1 '@stablelib/hkdf': 1.0.1 @@ -5139,7 +5190,7 @@ packages: '@walletconnect/relay-api': 1.0.9 '@walletconnect/safe-json': 1.0.2 '@walletconnect/time': 1.0.2 - '@walletconnect/types': 2.10.1 + '@walletconnect/types': 2.10.2 '@walletconnect/window-getters': 1.0.1 '@walletconnect/window-metadata': 1.0.1 detect-browser: 5.3.0 @@ -5240,8 +5291,8 @@ packages: resolution: {integrity: sha512-j2afSsaIENvHZN2B8GOpF566vZ5WVk5opAiMTvWgaQT8DkbOqsTfvNAvHoRGU2zzP8cPoqys+xHTRDWW8L+/BA==} dev: true - /abitype@0.10.1(typescript@5.2.2): - resolution: {integrity: sha512-nFx5F2RniXGXw2Ci1uu6iDGnP/z3hW+H65G7cxrs5JDF3Ot9GuYkBJCRAB9EZ5QIi3dNByZaCrGFUn8LLkLQbw==} + /abitype@0.10.2(typescript@5.2.2): + resolution: {integrity: sha512-1XndI+RKFWK4+TXCNv1683MRyX5NGmlHXCvqzjOqhSS3PQrxT2QYRZq1bMPPRNjn89B3eVaM2w7y3jVj/OIUzA==} peerDependencies: typescript: '>=5.0.4' zod: ^3 >=3.22.0 @@ -5596,6 +5647,17 @@ packages: is-string: 1.0.7 dev: true + /array-includes@3.1.7: + resolution: {integrity: sha512-dlcsNBIiWhPkHdOEEKnehA+RNUWDc4UqFtnIXU4uuYDPtA4LDkr7qip2p0VvFAEXNDr0yWZ9PJyIRiGjRLQzwQ==} + engines: {node: '>= 0.4'} + dependencies: + call-bind: 1.0.2 + define-properties: 1.2.0 + es-abstract: 1.22.1 + get-intrinsic: 1.2.1 + is-string: 1.0.7 + dev: true + /array-union@2.1.0: resolution: {integrity: sha512-HGyxoOTYUyCM6stUe6EJgnd4EoewAI7zMdfqO+kGjnlZmBDz/cR5pf8r/cR4Wq60sL/p0IkcjUEEPwS3GFrIyw==} engines: {node: '>=8'} @@ -5605,8 +5667,8 @@ packages: engines: {node: '>=12'} dev: true - /array.prototype.findlastindex@1.2.2: - resolution: {integrity: sha512-tb5thFFlUcp7NdNF6/MpDk/1r/4awWG1FIz3YqDf+/zJSTezBb+/5WViH41obXULHVpDzoiCLpJ/ZO9YbJMsdw==} + /array.prototype.findlastindex@1.2.3: + resolution: {integrity: sha512-LzLoiOMAxvy+Gd3BAq3B7VeIgPdo+Q8hthvKtXybMvRV0jrXfJM/t8mw7nNlpEcVlVUnCnM2KSX4XU5HmpodOA==} engines: {node: '>= 0.4'} dependencies: call-bind: 1.0.2 @@ -5624,6 +5686,17 @@ packages: define-properties: 1.2.0 es-abstract: 1.22.1 es-shim-unscopables: 1.0.0 + dev: false + + /array.prototype.flat@1.3.2: + resolution: {integrity: sha512-djYB+Zx2vLewY8RWlNCUdHjDXs2XOgm602S9E7P/UpHgfeHL00cRiIF+IN/G/aUJ7kGPb6yO/ErDI5V2s8iycA==} + engines: {node: '>= 0.4'} + dependencies: + call-bind: 1.0.2 + define-properties: 1.2.0 + es-abstract: 1.22.1 + es-shim-unscopables: 1.0.0 + dev: true /array.prototype.flatmap@1.3.1: resolution: {integrity: sha512-8UGn9O1FDVvMNB0UlLv4voxRMze7+FpHyF5mSMRjWHUMlpoDViniy05870VlxhfgTnLbpuwTzvD76MTtWxB/mQ==} @@ -5635,6 +5708,16 @@ packages: es-shim-unscopables: 1.0.0 dev: true + /array.prototype.flatmap@1.3.2: + resolution: {integrity: sha512-Ewyx0c9PmpcsByhSW4r+9zDU7sGjFc86qf/kKtuSCRdhfbk0SNLLkaT5qvcHnRGgc5NP/ly/y+qkXkqONX54CQ==} + engines: {node: '>= 0.4'} + dependencies: + call-bind: 1.0.2 + define-properties: 1.2.0 + es-abstract: 1.22.1 + es-shim-unscopables: 1.0.0 + dev: true + /array.prototype.tosorted@1.1.1: resolution: {integrity: sha512-pZYPXPRl2PqWcsUs6LOMn+1f1532nEoPTYowBtqLwAW+W8vSVhkIGnmOX1t/UQjD6YGI0vcD2B1U7ZFGQH9jnQ==} dependencies: @@ -5742,8 +5825,8 @@ packages: - debug dev: true - /axios@1.4.0: - resolution: {integrity: sha512-S4XCWMEmzvo64T9GfvQDOXgYRDJ/wsSZc7Jvdgx5u1sd0JwsuPLqb3SYmusag+edF6ziyMensPVqLTSc1PiSEA==} + /axios@1.5.1: + resolution: {integrity: sha512-Q28iYCWzNHjAm+yEAot5QaAMxhMghWLFVf7rRdwhUI+c2jix2DUXjAHXVi+s1ibs3mjPO/cCgbA++3BjD0vP/A==} dependencies: follow-redirects: 1.15.2(debug@4.3.4) form-data: 4.0.0 @@ -6101,7 +6184,7 @@ packages: /call-bind@1.0.2: resolution: {integrity: sha512-7O+FbCihrB5WGbFYesctwmTKae6rOiIzmz1icreWJ+0aA7LJfuqhEso2T9ncpcFtzMQtzXf2QGGueWJGTYsqrA==} dependencies: - function-bind: 1.1.1 + function-bind: 1.1.2 get-intrinsic: 1.2.1 /callsite@1.0.0: @@ -6477,8 +6560,8 @@ packages: typical: 5.2.0 dev: true - /commander@11.0.0: - resolution: {integrity: sha512-9HMlXtt/BNoYr8ooyjjNRdIilOTkVJXB+GhxMTtOKwk0R4j4lS4NpjuqmRxroBfnfTSHQIHQB7wryHhXarNjmQ==} + /commander@11.1.0: + resolution: {integrity: sha512-yPVavfyCcRhmorC7rWlkHn15b4wDVgVmBA7kV4QVBsF7kv/9TKJAbAXVTxvTnwP8HHKjRCJDClKbciiYS7p0DQ==} engines: {node: '>=16'} /commander@2.20.3: @@ -6581,8 +6664,8 @@ packages: /core-util-is@1.0.2: resolution: {integrity: sha512-3lqz5YjWTYnW6dlDa5TLaTCcShfar1e40rmcJVwCBJC6mWlFuj0eCHIElmG1g5kyuJ/GD+8Wn4FFCcz4gJPfaQ==} - /cosmiconfig@7.0.1: - resolution: {integrity: sha512-a1YWNUV2HwGimB7dU2s1wUMurNKjpx60HxBB6xUM8Re+2s1g1IIfJvFR0/iCF+XHdE0GMTKTuLR32UQff4TEyQ==} + /cosmiconfig@7.1.0: + resolution: {integrity: sha512-AdmX6xUzdNASswsFtmwSt7Vj8po9IuqXm0UXz7QKPuEUmPB4XyjGfaAr2PSuELMwkRMVH1EpIkX5bTZGRB3eCA==} engines: {node: '>=10'} dependencies: '@types/parse-json': 4.0.0 @@ -6657,8 +6740,8 @@ packages: which: 2.0.2 dev: true - /crypto-js@3.3.0: - resolution: {integrity: sha512-DIT51nX0dCfKltpRiXV+/TVZq+Qq2NgF4644+K7Ttnla7zEzqc+kjJyiB96BHNyUTBxyjzRcZYpUdZa+QAqi6Q==} + /crypto-js@4.2.0: + resolution: {integrity: sha512-KALDyEYgpY+Rlob/iriUtjV6d5Eq+Y191A5g4UqLAi8CyGP9N1+FdVbkc1SxKc2r4YAYqG8JzO2KGL+AizD70Q==} dev: false /css.escape@1.5.1: @@ -6866,26 +6949,26 @@ packages: resolution: {integrity: sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ==} engines: {node: '>=0.4.0'} - /depcheck@1.4.6: - resolution: {integrity: sha512-Jxy9+u1DE+Svj2N0V/ueEQiOgH2X3KRPAsBfM0m/vCtuiG5QSC//b1mt0rbN/u3BFFEzXqpHzYiwDjmvAydEsw==} + /depcheck@1.4.7: + resolution: {integrity: sha512-1lklS/bV5chOxwNKA/2XUUk/hPORp8zihZsXflr8x0kLwmcZ9Y9BsS6Hs3ssvA+2wUVbG0U2Ciqvm1SokNjPkA==} engines: {node: '>=10'} hasBin: true dependencies: - '@babel/parser': 7.22.5 - '@babel/traverse': 7.22.5 - '@vue/compiler-sfc': 3.2.36 + '@babel/parser': 7.23.0 + '@babel/traverse': 7.23.2 + '@vue/compiler-sfc': 3.3.4 callsite: 1.0.0 camelcase: 6.3.0 - cosmiconfig: 7.0.1 + cosmiconfig: 7.1.0 debug: 4.3.4(supports-color@8.1.1) - deps-regex: 0.1.4 + deps-regex: 0.2.0 findup-sync: 5.0.0 ignore: 5.2.4 is-core-module: 2.13.0 js-yaml: 3.14.1 json5: 2.2.3 lodash: 4.17.21 - minimatch: 3.1.2 + minimatch: 7.4.6 multimatch: 5.0.0 please-upgrade-node: 3.2.0 readdirp: 3.6.0 @@ -6902,8 +6985,8 @@ packages: resolution: {integrity: sha512-g7nH6P6dyDioJogAAGprGpCtVImJhpPk/roCzdb3fIh61/s/nPsfR6onyMwkCAR/OlC3yBC0lESvUoQEAssIrw==} engines: {node: '>= 0.8'} - /deps-regex@0.1.4: - resolution: {integrity: sha512-3tzwGYogSJi8HoG93R5x9NrdefZQOXgHgGih/7eivloOq6yC6O+yoFxZnkgP661twvfILONfoKRdF9GQOGx2RA==} + /deps-regex@0.2.0: + resolution: {integrity: sha512-PwuBojGMQAYbWkMXOY9Pd/NWCDNHVH12pnS7WHqZkTSeMESe4hwnKKRp0yR87g37113x4JPbo/oIvXY+s/f56Q==} dev: true /dequal@2.0.3: @@ -7265,7 +7348,7 @@ packages: define-properties: 1.2.0 es-abstract: 1.22.1 es-set-tostringtag: 2.0.1 - function-bind: 1.1.1 + function-bind: 1.1.2 get-intrinsic: 1.2.1 globalthis: 1.0.3 has-property-descriptors: 1.0.0 @@ -7339,36 +7422,6 @@ packages: '@esbuild/win32-x64': 0.16.17 dev: true - /esbuild@0.17.19: - resolution: {integrity: sha512-XQ0jAPFkK/u3LcVRcvVHQcTIqD6E2H1fvZMA5dQPSOWb3suUbWbfbRf94pjc0bNzRYLfIrDRQXr7X+LHIm5oHw==} - engines: {node: '>=12'} - hasBin: true - requiresBuild: true - optionalDependencies: - '@esbuild/android-arm': 0.17.19 - '@esbuild/android-arm64': 0.17.19 - '@esbuild/android-x64': 0.17.19 - '@esbuild/darwin-arm64': 0.17.19 - '@esbuild/darwin-x64': 0.17.19 - '@esbuild/freebsd-arm64': 0.17.19 - '@esbuild/freebsd-x64': 0.17.19 - '@esbuild/linux-arm': 0.17.19 - '@esbuild/linux-arm64': 0.17.19 - '@esbuild/linux-ia32': 0.17.19 - '@esbuild/linux-loong64': 0.17.19 - '@esbuild/linux-mips64el': 0.17.19 - '@esbuild/linux-ppc64': 0.17.19 - '@esbuild/linux-riscv64': 0.17.19 - '@esbuild/linux-s390x': 0.17.19 - '@esbuild/linux-x64': 0.17.19 - '@esbuild/netbsd-x64': 0.17.19 - '@esbuild/openbsd-x64': 0.17.19 - '@esbuild/sunos-x64': 0.17.19 - '@esbuild/win32-arm64': 0.17.19 - '@esbuild/win32-ia32': 0.17.19 - '@esbuild/win32-x64': 0.17.19 - dev: true - /esbuild@0.18.15: resolution: {integrity: sha512-3WOOLhrvuTGPRzQPU6waSDWrDTnQriia72McWcn6UCi43GhCHrXH4S59hKMeez+IITmdUuUyvbU9JIp+t3xlPQ==} engines: {node: '>=12'} @@ -7399,6 +7452,36 @@ packages: '@esbuild/win32-x64': 0.18.15 dev: true + /esbuild@0.18.20: + resolution: {integrity: sha512-ceqxoedUrcayh7Y7ZX6NdbbDzGROiyVBgC4PriJThBKSVPWnnFHZAkfI1lJT8QFkOwH4qOS2SJkS4wvpGl8BpA==} + engines: {node: '>=12'} + hasBin: true + requiresBuild: true + optionalDependencies: + '@esbuild/android-arm': 0.18.20 + '@esbuild/android-arm64': 0.18.20 + '@esbuild/android-x64': 0.18.20 + '@esbuild/darwin-arm64': 0.18.20 + '@esbuild/darwin-x64': 0.18.20 + '@esbuild/freebsd-arm64': 0.18.20 + '@esbuild/freebsd-x64': 0.18.20 + '@esbuild/linux-arm': 0.18.20 + '@esbuild/linux-arm64': 0.18.20 + '@esbuild/linux-ia32': 0.18.20 + '@esbuild/linux-loong64': 0.18.20 + '@esbuild/linux-mips64el': 0.18.20 + '@esbuild/linux-ppc64': 0.18.20 + '@esbuild/linux-riscv64': 0.18.20 + '@esbuild/linux-s390x': 0.18.20 + '@esbuild/linux-x64': 0.18.20 + '@esbuild/netbsd-x64': 0.18.20 + '@esbuild/openbsd-x64': 0.18.20 + '@esbuild/sunos-x64': 0.18.20 + '@esbuild/win32-arm64': 0.18.20 + '@esbuild/win32-ia32': 0.18.20 + '@esbuild/win32-x64': 0.18.20 + dev: true + /escalade@3.1.1: resolution: {integrity: sha512-k0er2gUkLf8O0zKJiAhmkTnJlTvINGv7ygDNPbeIsX/TJjGJZHuh9B2UxbsaEkmlEo9MfhrSzmhIlhRlI2GXnw==} engines: {node: '>=6'} @@ -7416,16 +7499,16 @@ packages: engines: {node: '>=10'} dev: true - /eslint-config-prettier@8.3.0(eslint@8.51.0): + /eslint-config-prettier@8.3.0(eslint@8.53.0): resolution: {integrity: sha512-BgZuLUSeKzvlL/VUjx/Yb787VQ26RU3gGjA3iiFvdsp/2bMfVIWUVP7tjxtjS0e+HP409cPlPvNkQloz8C91ew==} hasBin: true peerDependencies: eslint: '>=7.0.0' dependencies: - eslint: 8.51.0 + eslint: 8.53.0 dev: true - /eslint-config-standard@16.0.3(eslint-plugin-import@2.28.1)(eslint-plugin-node@11.1.0)(eslint-plugin-promise@5.2.0)(eslint@8.51.0): + /eslint-config-standard@16.0.3(eslint-plugin-import@2.29.0)(eslint-plugin-node@11.1.0)(eslint-plugin-promise@5.2.0)(eslint@8.53.0): resolution: {integrity: sha512-x4fmJL5hGqNJKGHSjnLdgA6U6h1YW/G2dW9fA+cyVur4SK6lyue8+UgNKWlZtUDTXvgKDD/Oa3GQjmB5kjtVvg==} peerDependencies: eslint: ^7.12.1 @@ -7433,23 +7516,23 @@ packages: eslint-plugin-node: ^11.1.0 eslint-plugin-promise: ^4.2.1 || ^5.0.0 dependencies: - eslint: 8.51.0 - eslint-plugin-import: 2.28.1(@typescript-eslint/parser@6.7.5)(eslint@8.51.0) - eslint-plugin-node: 11.1.0(eslint@8.51.0) - eslint-plugin-promise: 5.2.0(eslint@8.51.0) + eslint: 8.53.0 + eslint-plugin-import: 2.29.0(@typescript-eslint/parser@6.9.1)(eslint@8.53.0) + eslint-plugin-node: 11.1.0(eslint@8.53.0) + eslint-plugin-promise: 5.2.0(eslint@8.53.0) dev: true /eslint-import-resolver-node@0.3.9: resolution: {integrity: sha512-WFj2isz22JahUv+B788TlO3N6zL3nNJGU8CcZbPZvVEkBPaJdCV4vy5wyghty5ROFbCRnm132v8BScu5/1BQ8g==} dependencies: debug: 3.2.7 - is-core-module: 2.13.0 + is-core-module: 2.13.1 resolve: 1.22.4 transitivePeerDependencies: - supports-color dev: true - /eslint-module-utils@2.8.0(@typescript-eslint/parser@6.7.5)(eslint-import-resolver-node@0.3.9)(eslint@8.51.0): + /eslint-module-utils@2.8.0(@typescript-eslint/parser@6.9.1)(eslint-import-resolver-node@0.3.9)(eslint@8.53.0): resolution: {integrity: sha512-aWajIYfsqCKRDgUfjEXNN/JlrzauMuSEy5sbd7WXbtW3EH6A6MpwEh42c7qD+MqQo9QMJ6fWLAeIJynx0g6OAw==} engines: {node: '>=4'} peerDependencies: @@ -7470,27 +7553,27 @@ packages: eslint-import-resolver-webpack: optional: true dependencies: - '@typescript-eslint/parser': 6.7.5(eslint@8.51.0)(typescript@5.2.2) + '@typescript-eslint/parser': 6.9.1(eslint@8.53.0)(typescript@5.2.2) debug: 3.2.7 - eslint: 8.51.0 + eslint: 8.53.0 eslint-import-resolver-node: 0.3.9 transitivePeerDependencies: - supports-color dev: true - /eslint-plugin-es@3.0.1(eslint@8.51.0): + /eslint-plugin-es@3.0.1(eslint@8.53.0): resolution: {integrity: sha512-GUmAsJaN4Fc7Gbtl8uOBlayo2DqhwWvEzykMHSCZHU3XdJ+NSzzZcVhXh3VxX5icqQ+oQdIEawXX8xkR3mIFmQ==} engines: {node: '>=8.10.0'} peerDependencies: eslint: '>=4.19.1' dependencies: - eslint: 8.51.0 + eslint: 8.53.0 eslint-utils: 2.1.0 regexpp: 3.2.0 dev: true - /eslint-plugin-import@2.28.1(@typescript-eslint/parser@6.7.5)(eslint@8.51.0): - resolution: {integrity: sha512-9I9hFlITvOV55alzoKBI+K9q74kv0iKMeY6av5+umsNwayt59fz692daGyjR+oStBQgx6nwR9rXldDev3Clw+A==} + /eslint-plugin-import@2.29.0(@typescript-eslint/parser@6.9.1)(eslint@8.53.0): + resolution: {integrity: sha512-QPOO5NO6Odv5lpoTkddtutccQjysJuFxoPS7fAHO+9m9udNHvTCPSAMW9zGAYj8lAIdr40I8yPCdUYrncXtrwg==} engines: {node: '>=4'} peerDependencies: '@typescript-eslint/parser': '*' @@ -7499,23 +7582,23 @@ packages: '@typescript-eslint/parser': optional: true dependencies: - '@typescript-eslint/parser': 6.7.5(eslint@8.51.0)(typescript@5.2.2) - array-includes: 3.1.6 - array.prototype.findlastindex: 1.2.2 - array.prototype.flat: 1.3.1 - array.prototype.flatmap: 1.3.1 + '@typescript-eslint/parser': 6.9.1(eslint@8.53.0)(typescript@5.2.2) + array-includes: 3.1.7 + array.prototype.findlastindex: 1.2.3 + array.prototype.flat: 1.3.2 + array.prototype.flatmap: 1.3.2 debug: 3.2.7 doctrine: 2.1.0 - eslint: 8.51.0 + eslint: 8.53.0 eslint-import-resolver-node: 0.3.9 - eslint-module-utils: 2.8.0(@typescript-eslint/parser@6.7.5)(eslint-import-resolver-node@0.3.9)(eslint@8.51.0) - has: 1.0.3 - is-core-module: 2.13.0 + eslint-module-utils: 2.8.0(@typescript-eslint/parser@6.9.1)(eslint-import-resolver-node@0.3.9)(eslint@8.53.0) + hasown: 2.0.0 + is-core-module: 2.13.1 is-glob: 4.0.3 minimatch: 3.1.2 - object.fromentries: 2.0.6 - object.groupby: 1.0.0 - object.values: 1.1.6 + object.fromentries: 2.0.7 + object.groupby: 1.0.1 + object.values: 1.1.7 semver: 6.3.1 tsconfig-paths: 3.14.2 transitivePeerDependencies: @@ -7524,7 +7607,7 @@ packages: - supports-color dev: true - /eslint-plugin-jsdoc@35.5.1(eslint@8.51.0): + /eslint-plugin-jsdoc@35.5.1(eslint@8.53.0): resolution: {integrity: sha512-pPYPWtsykwVEue1tYEyoppBj4dgF7XicF67tLLLraY6RQYBq7qMKjUHji19+hfiTtYKKBD0YfeK8hgjPAE5viw==} engines: {node: '>=12'} peerDependencies: @@ -7533,7 +7616,7 @@ packages: '@es-joy/jsdoccomment': 0.9.0-alpha.1 comment-parser: 1.1.6-beta.0 debug: 4.3.4(supports-color@8.1.1) - eslint: 8.51.0 + eslint: 8.53.0 esquery: 1.4.0 jsdoc-type-pratt-parser: 1.1.1 lodash: 4.17.21 @@ -7544,14 +7627,14 @@ packages: - supports-color dev: true - /eslint-plugin-node@11.1.0(eslint@8.51.0): + /eslint-plugin-node@11.1.0(eslint@8.53.0): resolution: {integrity: sha512-oUwtPJ1W0SKD0Tr+wqu92c5xuCeQqB3hSCHasn/ZgjFdA9iDGNkNf2Zi9ztY7X+hNuMib23LNGRm6+uN+KLE3g==} engines: {node: '>=8.10.0'} peerDependencies: eslint: '>=5.16.0' dependencies: - eslint: 8.51.0 - eslint-plugin-es: 3.0.1(eslint@8.51.0) + eslint: 8.53.0 + eslint-plugin-es: 3.0.1(eslint@8.53.0) eslint-utils: 2.1.0 ignore: 5.2.4 minimatch: 3.1.2 @@ -7559,15 +7642,15 @@ packages: semver: 6.3.1 dev: true - /eslint-plugin-prefer-arrow@1.2.3(eslint@8.51.0): + /eslint-plugin-prefer-arrow@1.2.3(eslint@8.53.0): resolution: {integrity: sha512-J9I5PKCOJretVuiZRGvPQxCbllxGAV/viI20JO3LYblAodofBxyMnZAJ+WGeClHgANnSJberTNoFWWjrWKBuXQ==} peerDependencies: eslint: '>=2.0.0' dependencies: - eslint: 8.51.0 + eslint: 8.53.0 dev: true - /eslint-plugin-prettier@4.2.1(eslint-config-prettier@8.3.0)(eslint@8.51.0)(prettier@2.8.8): + /eslint-plugin-prettier@4.2.1(eslint-config-prettier@8.3.0)(eslint@8.53.0)(prettier@2.8.8): resolution: {integrity: sha512-f/0rXLXUt0oFYs8ra4w49wYZBG5GKZpAYsJSm6rnYL5uVDjd+zowwMwVZHnAjf4edNrKpCDYfXDgmRE/Ak7QyQ==} engines: {node: '>=12.0.0'} peerDependencies: @@ -7578,22 +7661,22 @@ packages: eslint-config-prettier: optional: true dependencies: - eslint: 8.51.0 - eslint-config-prettier: 8.3.0(eslint@8.51.0) + eslint: 8.53.0 + eslint-config-prettier: 8.3.0(eslint@8.53.0) prettier: 2.8.8 prettier-linter-helpers: 1.0.0 dev: true - /eslint-plugin-promise@5.2.0(eslint@8.51.0): + /eslint-plugin-promise@5.2.0(eslint@8.53.0): resolution: {integrity: sha512-SftLb1pUG01QYq2A/hGAWfDRXqYD82zE7j7TopDOyNdU+7SvvoXREls/+PRTY17vUXzXnZA/zfnyKgRH6x4JJw==} engines: {node: ^10.12.0 || >=12.0.0} peerDependencies: eslint: ^7.0.0 dependencies: - eslint: 8.51.0 + eslint: 8.53.0 dev: true - /eslint-plugin-react@7.33.2(eslint@8.51.0): + /eslint-plugin-react@7.33.2(eslint@8.53.0): resolution: {integrity: sha512-73QQMKALArI8/7xGLNI/3LylrEYrlKZSb5C9+q3OtOewTnMQi5cT+aE9E41sLCmli3I9PGGmD1yiZydyo4FEPw==} engines: {node: '>=4'} peerDependencies: @@ -7604,7 +7687,7 @@ packages: array.prototype.tosorted: 1.1.1 doctrine: 2.1.0 es-iterator-helpers: 1.0.13 - eslint: 8.51.0 + eslint: 8.53.0 estraverse: 5.3.0 jsx-ast-utils: 3.2.0 minimatch: 3.1.2 @@ -7618,22 +7701,21 @@ packages: string.prototype.matchall: 4.0.8 dev: true - /eslint-plugin-unicorn@48.0.1(eslint@8.51.0): - resolution: {integrity: sha512-FW+4r20myG/DqFcCSzoumaddKBicIPeFnTrifon2mWIzlfyvzwyqZjqVP7m4Cqr/ZYisS2aiLghkUWaPg6vtCw==} + /eslint-plugin-unicorn@49.0.0(eslint@8.53.0): + resolution: {integrity: sha512-0fHEa/8Pih5cmzFW5L7xMEfUTvI9WKeQtjmKpTUmY+BiFCDxkxrTdnURJOHKykhtwIeyYsxnecbGvDCml++z4Q==} engines: {node: '>=16'} peerDependencies: - eslint: '>=8.44.0' + eslint: '>=8.52.0' dependencies: - '@babel/helper-validator-identifier': 7.22.5 - '@eslint-community/eslint-utils': 4.4.0(eslint@8.51.0) + '@babel/helper-validator-identifier': 7.22.20 + '@eslint-community/eslint-utils': 4.4.0(eslint@8.53.0) ci-info: 3.8.0 clean-regexp: 1.0.0 - eslint: 8.51.0 + eslint: 8.53.0 esquery: 1.5.0 indent-string: 4.0.0 is-builtin-module: 3.2.1 jsesc: 3.0.2 - lodash: 4.17.21 pluralize: 8.0.0 read-pkg-up: 7.0.1 regexp-tree: 0.1.27 @@ -7680,18 +7762,19 @@ packages: engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} dev: true - /eslint@8.51.0: - resolution: {integrity: sha512-2WuxRZBrlwnXi+/vFSJyjMqrNjtJqiasMzehF0shoLaW7DzS3/9Yvrmq5JiT66+pNjiX4UBnLDiKHcWAr/OInA==} + /eslint@8.53.0: + resolution: {integrity: sha512-N4VuiPjXDUa4xVeV/GC/RV3hQW9Nw+Y463lkWaKKXKYMvmRiRDAtfpuPFLN+E1/6ZhyR8J2ig+eVREnYgUsiag==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} hasBin: true dependencies: - '@eslint-community/eslint-utils': 4.4.0(eslint@8.51.0) + '@eslint-community/eslint-utils': 4.4.0(eslint@8.53.0) '@eslint-community/regexpp': 4.6.2 - '@eslint/eslintrc': 2.1.2 - '@eslint/js': 8.51.0 - '@humanwhocodes/config-array': 0.11.11 + '@eslint/eslintrc': 2.1.3 + '@eslint/js': 8.53.0 + '@humanwhocodes/config-array': 0.11.13 '@humanwhocodes/module-importer': 1.0.1 '@nodelib/fs.walk': 1.2.8 + '@ungap/structured-clone': 1.2.0 ajv: 6.12.6 chalk: 4.1.2 cross-spawn: 7.0.3 @@ -8049,18 +8132,18 @@ packages: strip-final-newline: 3.0.0 dev: true - /execa@7.2.0: - resolution: {integrity: sha512-UduyVP7TLB5IcAQl+OzLyLcS/l32W/GLg+AhHJ+ow40FOk2U3SAllPwR44v4vmdFwIWqpdwxxpQbF1n5ta9seA==} - engines: {node: ^14.18.0 || ^16.14.0 || >=18.0.0} + /execa@8.0.1: + resolution: {integrity: sha512-VyhnebXciFV2DESc+p6B+y0LjSm0krU4OgJN44qFAhBY0TJ+1V61tYD2+wHusZ6F9n5K+vl8k0sTy7PEfV4qpg==} + engines: {node: '>=16.17'} dependencies: cross-spawn: 7.0.3 - get-stream: 6.0.1 - human-signals: 4.3.1 + get-stream: 8.0.1 + human-signals: 5.0.0 is-stream: 3.0.0 merge-stream: 2.0.0 npm-run-path: 5.1.0 onetime: 6.0.0 - signal-exit: 3.0.7 + signal-exit: 4.1.0 strip-final-newline: 3.0.0 dev: true @@ -8372,7 +8455,7 @@ packages: engines: {node: '>=14'} dependencies: cross-spawn: 7.0.3 - signal-exit: 4.0.2 + signal-exit: 4.1.0 dev: true /forever-agent@0.6.1: @@ -8524,8 +8607,8 @@ packages: dev: true optional: true - /function-bind@1.1.1: - resolution: {integrity: sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==} + /function-bind@1.1.2: + resolution: {integrity: sha512-7XHNxH7qX9xG5mIwxkhumTox/MIRNcOgDrxWsMt2pAr23WHp6MrRlN7FBSFpCpr+oVO0F744iUgR82nJMfG2SA==} /function.prototype.name@1.1.5: resolution: {integrity: sha512-uN7m/BzVKQnCUF/iW8jYea67v++2u7m5UgENbHRtdDVclOUP+FMPlCNdmk0h/ysGyo2tavMJEDqJAkJdRa1vMA==} @@ -8600,7 +8683,7 @@ packages: /get-intrinsic@1.2.1: resolution: {integrity: sha512-2DcsyfABl+gVHEfCOaTrWgyt+tb6MSEGmKq+kI5HwLbIYgjgmMcV8KQ41uaKz1xxUcn9tJtgFbQUEVcEbd0FYw==} dependencies: - function-bind: 1.1.1 + function-bind: 1.1.2 has: 1.0.3 has-proto: 1.0.1 has-symbols: 1.0.3 @@ -8622,6 +8705,11 @@ packages: engines: {node: '>=10'} dev: true + /get-stream@8.0.1: + resolution: {integrity: sha512-VaUJspBffn/LMCJVoMvSAdmscJyS1auj5Zulnn5UoYcY531UWmdwhRWkcGKnGU93m5HSXP9LP2usOryrBtQowA==} + engines: {node: '>=16'} + dev: true + /get-symbol-description@1.0.0: resolution: {integrity: sha512-2EmdH1YvIQiZpltCNgkuiUnyukzxM/R6NDJX31Ke3BG1Nq5b0S2PhX59UKi9vZpPDQVdqn+1IcaAwnzTT5vCjw==} engines: {node: '>= 0.4'} @@ -8629,8 +8717,8 @@ packages: call-bind: 1.0.2 get-intrinsic: 1.2.1 - /get-tsconfig@4.7.0: - resolution: {integrity: sha512-pmjiZ7xtB8URYm74PlGJozDNyhvsVLUcpBa8DZBG3bWHwaHa9bPiRpiSfovw+fjhwONSCWKRyk+JQHEGZmMrzw==} + /get-tsconfig@4.7.2: + resolution: {integrity: sha512-wuMsz4leaj5hbGgg4IvDU0bqJagpftG5l5cXIAvo8uZrqn0NJqwtfupTN00VnkQJPcIRrxYrm1Ue24btpCha2A==} dependencies: resolve-pkg-maps: 1.0.0 dev: true @@ -8824,8 +8912,8 @@ packages: engines: {node: '>=6'} dev: false - /hardhat-deploy@0.11.42: - resolution: {integrity: sha512-sd0zzHV2Px2qxPCvIt0BCJm41rx/aS7ruOOXEUFe54rUk+8ViFNSSUll6BD9YaRzyfVBDMn9FT4Q40DakJ0tJA==} + /hardhat-deploy@0.11.43: + resolution: {integrity: sha512-D760CjDtinwjOCpKOvdyRtIJYLQIYXmhfgkFe+AkxlYM9bPZ/T4tZ/xIB2tR89ZT+z0hF1YuZFBXIL3/G/9T5g==} dependencies: '@ethersproject/abi': 5.7.0 '@ethersproject/abstract-signer': 5.7.0 @@ -8857,8 +8945,8 @@ packages: - utf-8-validate dev: true - /hardhat@2.18.1(ts-node@10.9.1)(typescript@5.2.2): - resolution: {integrity: sha512-b55rW7Ka+fvJeg6oWuBTXoYQEUurevCCankjGNTwczwD3GnkhV9GEei7KUT+9IKmWx3lC+zyxlFxeDbg0gUoHw==} + /hardhat@2.19.0(ts-node@10.9.1)(typescript@5.2.2): + resolution: {integrity: sha512-kMpwovOEfrFRQXEopCP+JTcKVwSYVj8rnXE0LynxDqnh06yvyKCQknmXL6IVYTHQL6Csysc/yNbCHQbjSeJGpA==} hasBin: true peerDependencies: ts-node: '*' @@ -8913,7 +9001,7 @@ packages: solc: 0.7.3(debug@4.3.4) source-map-support: 0.5.21 stacktrace-parser: 0.1.10 - ts-node: 10.9.1(@types/node@20.8.5)(typescript@5.2.2) + ts-node: 10.9.1(@types/node@20.8.9)(typescript@5.2.2) tsort: 0.0.1 typescript: 5.2.2 undici: 5.24.0 @@ -8964,7 +9052,7 @@ packages: resolution: {integrity: sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==} engines: {node: '>= 0.4.0'} dependencies: - function-bind: 1.1.1 + function-bind: 1.1.2 /hash-base@3.1.0: resolution: {integrity: sha512-1nmYp/rhMDiE7AYkDw+lLwlAzz0AntGIe51F3RfFfEqyQ3feY2eI/NcwC6umIQVOASPMsWJLJScWKSSvzL9IVA==} @@ -8989,6 +9077,12 @@ packages: type-fest: 0.8.1 dev: true + /hasown@2.0.0: + resolution: {integrity: sha512-vUptKVTpIJhcczKBbgnS+RtcuYMB8+oNzPK2/Hp3hanz8JmpATdmmgLgSaadVREkDm+e2giHwY3ZRkyjSIDDFA==} + engines: {node: '>= 0.4'} + dependencies: + function-bind: 1.1.2 + /he@1.2.0: resolution: {integrity: sha512-F/1DnUGPopORZi0ni+CvrCgHQ5FyEAHRLSApuYWMmrbSwoN2Mn/7k+Gl38gJnR7yyDZk6WLXwiGod1JOWNDKGw==} hasBin: true @@ -9097,9 +9191,9 @@ packages: engines: {node: '>=12.20.0'} dev: true - /human-signals@4.3.1: - resolution: {integrity: sha512-nZXjEF2nbo7lIw3mgYjItAfgQXog3OjJogSbKa2CQIIvSGWcKgeJnQlNXip6NglNzYH45nSRiEVimMvYL8DDqQ==} - engines: {node: '>=14.18.0'} + /human-signals@5.0.0: + resolution: {integrity: sha512-AXcZb6vzzrFAUE61HnN4mpLqd/cSIwNQjtNWR0euPm6y0iqx3G4gOXaIDdtdDwZmhwe82LA6+zinmW4UBWVePQ==} + engines: {node: '>=16.17.0'} dev: true /humanize-ms@1.2.1: @@ -9292,6 +9386,12 @@ packages: resolution: {integrity: sha512-Z7dk6Qo8pOCp3l4tsX2C5ZVas4V+UxwQodwZhLopL91TX8UyyHEXafPcyoeeWuLrwzHcr3igO78wNLwHJHsMCQ==} dependencies: has: 1.0.3 + dev: true + + /is-core-module@2.13.1: + resolution: {integrity: sha512-hHrIjvZsftOsvKSn2TRYl63zvxsgE0K+0mYMoH6gD4omR5IWB2KynivBQczo3+wF1cCkjzvptnI9Q0sPU66ilw==} + dependencies: + hasown: 2.0.0 /is-date-object@1.0.5: resolution: {integrity: sha512-9YQaSxsAiSwcvS33MBk3wTCVnWK+HhF8VZR2jRxehM16QcVOdHqPn4VPHmRK4lSr38n9JriurInLcP90xsYNfQ==} @@ -10133,34 +10233,28 @@ packages: uc.micro: 1.0.6 dev: true - /lint-staged@14.0.1: - resolution: {integrity: sha512-Mw0cL6HXnHN1ag0mN/Dg4g6sr8uf8sn98w2Oc1ECtFto9tvRF7nkXGJRbx8gPlHyoR0pLyBr2lQHbWwmUHe1Sw==} - engines: {node: ^16.14.0 || >=18.0.0} + /lint-staged@15.0.2: + resolution: {integrity: sha512-vnEy7pFTHyVuDmCAIFKR5QDO8XLVlPFQQyujQ/STOxe40ICWqJ6knS2wSJ/ffX/Lw0rz83luRDh+ET7toN+rOw==} + engines: {node: '>=18.12.0'} hasBin: true dependencies: chalk: 5.3.0 - commander: 11.0.0 + commander: 11.1.0 debug: 4.3.4(supports-color@8.1.1) - execa: 7.2.0 + execa: 8.0.1 lilconfig: 2.1.0 - listr2: 6.6.1 + listr2: 7.0.2 micromatch: 4.0.5 pidtree: 0.6.0 string-argv: 0.3.2 - yaml: 2.3.1 + yaml: 2.3.3 transitivePeerDependencies: - - enquirer - supports-color dev: true - /listr2@6.6.1: - resolution: {integrity: sha512-+rAXGHh0fkEWdXBmX+L6mmfmXmXvDGEKzkjxO+8mP3+nI/r/CWznVBvsibXdxda9Zz0OW2e2ikphN3OwCT/jSg==} + /listr2@7.0.2: + resolution: {integrity: sha512-rJysbR9GKIalhTbVL2tYbF2hVyDnrf7pFUZBwjPaMIdadYHmeT+EVi/Bu3qd7ETQPahTotg2WRCatXwRBW554g==} engines: {node: '>=16.0.0'} - peerDependencies: - enquirer: '>= 2.3.0 < 3' - peerDependenciesMeta: - enquirer: - optional: true dependencies: cli-truncate: 3.1.0 colorette: 2.0.20 @@ -10358,6 +10452,7 @@ packages: /lru_map@0.3.3: resolution: {integrity: sha512-Pn9cox5CsMYngeDbmChANltQl+5pi6XmTrraMSzhPmMBbmgcxmqWry0U3PGapCU1yB4/LqCcom7qhHZiF/jGfQ==} + dev: true /ltgt@2.2.1: resolution: {integrity: sha512-AI2r85+4MquTw9ZYqabu4nMwy9Oftlfa/e/52t9IjtfG+mGBbTNdAoZ3RQKLHR6r0wQnwZnPIEh/Ya6XTWAKNA==} @@ -10372,12 +10467,6 @@ packages: hasBin: true dev: false - /magic-string@0.25.9: - resolution: {integrity: sha512-RmF0AsMzgt25qzqqLc1+MbHmhdx0ojF2Fvs4XnOqz2ZOBXzzkEwc/dJQZCYHAn7v1jbVOjAZfK8msRn4BxO4VQ==} - dependencies: - sourcemap-codec: 1.4.8 - dev: true - /magic-string@0.30.1: resolution: {integrity: sha512-mbVKXPmS0z0G4XqFDCTllmDQ6coZzn94aMlb0o/A4HEHJCKcanlDZwYJgwnkmgD3jyWhUgj9VsPrfd972yPffA==} engines: {node: '>=12'} @@ -10697,13 +10786,13 @@ packages: semaphore-async-await: 1.5.1 dev: true - /merkletreejs@0.3.10: - resolution: {integrity: sha512-lin42tKfRdkW+6iE5pjtQ9BnH+1Hk3sJ5Fn9hUUSjcXRcJbSISHgPCfYvMNEXiNqZPhz/TyRPEV30qgnujsQ7A==} + /merkletreejs@0.3.11: + resolution: {integrity: sha512-LJKTl4iVNTndhL+3Uz/tfkjD0klIWsHlUzgtuNnNrsf7bAlXR30m+xYB7lHr5Z/l6e/yAIsr26Dabx6Buo4VGQ==} engines: {node: '>= 7.6.0'} dependencies: bignumber.js: 9.0.1 buffer-reverse: 1.0.1 - crypto-js: 3.3.0 + crypto-js: 4.2.0 treeify: 1.1.0 web3-utils: 1.10.1 dev: false @@ -10870,6 +10959,13 @@ packages: brace-expansion: 2.0.1 dev: true + /minimatch@7.4.6: + resolution: {integrity: sha512-sBz8G/YjVniEz6lKPNpKxXwazJe4c19fEfV2GDMX6AjFz+MX9uDWIZW8XreVhkFW3fkIdTv/gxWr/Kks5FFAVw==} + engines: {node: '>=10'} + dependencies: + brace-expansion: 2.0.1 + dev: true + /minimatch@9.0.3: resolution: {integrity: sha512-RHiac9mvaRw0x3AYRgDC1CxAP7HTcNrrECeA8YYJeWnpo+2Q5CegtZjaotWTWxDG3UeGA1coE05iH1mPjT/2mg==} engines: {node: '>=16 || 14 >=14.17'} @@ -11078,10 +11174,6 @@ packages: /node-addon-api@2.0.2: resolution: {integrity: sha512-Ntyt4AIXyaLIuMHF6IOoTakB3K+RWxwtsHNRxllEoA6vPwP9o4866g6YWDLUdnucilZhmkxiHwHr11gAENw+QA==} - /node-addon-api@3.2.1: - resolution: {integrity: sha512-mmcei9JghVNDYydghQmeDX8KoAm0FAiYyIcUt/N4nhyAipB17pllZQDOJD2fotxABnt4Mdz+dKTO7eftLg4d0A==} - dev: true - /node-domexception@1.0.0: resolution: {integrity: sha512-/jKZoMpw0F8GRwl4/eLROPA3cfcXtLApP0QzLmUT/HuPCZWyB7IY9ZrMeKw2O/nFIqPQB3PVM9aYm0F312AXDQ==} engines: {node: '>=10.5.0'} @@ -11224,8 +11316,8 @@ packages: - debug dev: true - /nx@16.10.0: - resolution: {integrity: sha512-gZl4iCC0Hx0Qe1VWmO4Bkeul2nttuXdPpfnlcDKSACGu3ZIo+uySqwOF8yBAxSTIf8xe2JRhgzJN1aFkuezEBg==} + /nx@17.0.3: + resolution: {integrity: sha512-VShJISKCYt3iVJoMUPZiv67+0tiItxWMnfVmTmPZPio2Fu+wGc9U4ijjPxcmp2RJmLRaxkB9cn5rlrAvkIrNMA==} hasBin: true requiresBuild: true peerDependencies: @@ -11237,12 +11329,11 @@ packages: '@swc/core': optional: true dependencies: - '@nrwl/tao': 16.10.0 - '@parcel/watcher': 2.0.4 + '@nrwl/tao': 17.0.3 '@yarnpkg/lockfile': 1.1.0 '@yarnpkg/parsers': 3.0.0-rc.46 '@zkochan/js-yaml': 0.0.6 - axios: 1.4.0 + axios: 1.5.1 chalk: 4.1.2 cli-cursor: 3.1.0 cli-spinners: 2.6.1 @@ -11274,16 +11365,16 @@ packages: yargs: 17.7.2 yargs-parser: 21.1.1 optionalDependencies: - '@nx/nx-darwin-arm64': 16.10.0 - '@nx/nx-darwin-x64': 16.10.0 - '@nx/nx-freebsd-x64': 16.10.0 - '@nx/nx-linux-arm-gnueabihf': 16.10.0 - '@nx/nx-linux-arm64-gnu': 16.10.0 - '@nx/nx-linux-arm64-musl': 16.10.0 - '@nx/nx-linux-x64-gnu': 16.10.0 - '@nx/nx-linux-x64-musl': 16.10.0 - '@nx/nx-win32-arm64-msvc': 16.10.0 - '@nx/nx-win32-x64-msvc': 16.10.0 + '@nx/nx-darwin-arm64': 17.0.3 + '@nx/nx-darwin-x64': 17.0.3 + '@nx/nx-freebsd-x64': 17.0.3 + '@nx/nx-linux-arm-gnueabihf': 17.0.3 + '@nx/nx-linux-arm64-gnu': 17.0.3 + '@nx/nx-linux-arm64-musl': 17.0.3 + '@nx/nx-linux-x64-gnu': 17.0.3 + '@nx/nx-linux-x64-musl': 17.0.3 + '@nx/nx-win32-arm64-msvc': 17.0.3 + '@nx/nx-win32-x64-msvc': 17.0.3 transitivePeerDependencies: - debug dev: true @@ -11374,8 +11465,17 @@ packages: es-abstract: 1.22.1 dev: true - /object.groupby@1.0.0: - resolution: {integrity: sha512-70MWG6NfRH9GnbZOikuhPPYzpUpof9iW2J9E4dW7FXTqPNb6rllE6u39SKwwiNh8lCwX3DDb5OgcKGiEBrTTyw==} + /object.fromentries@2.0.7: + resolution: {integrity: sha512-UPbPHML6sL8PI/mOqPwsH4G6iyXcCGzLin8KvEPenOZN5lpCNBZZQ+V62vdjB1mQHrmqGQt5/OJzemUA+KJmEA==} + engines: {node: '>= 0.4'} + dependencies: + call-bind: 1.0.2 + define-properties: 1.2.0 + es-abstract: 1.22.1 + dev: true + + /object.groupby@1.0.1: + resolution: {integrity: sha512-HqaQtqLnp/8Bn4GL16cj+CUYbnpe1bh0TtEaWvybszDG4tgxCJuRpV8VGuvNaI1fAnI4lUJzDG55MXcOH4JZcQ==} dependencies: call-bind: 1.0.2 define-properties: 1.2.0 @@ -11399,6 +11499,15 @@ packages: es-abstract: 1.22.1 dev: true + /object.values@1.1.7: + resolution: {integrity: sha512-aU6xnDFYT3x17e/f0IiiwlGPTy2jzMySGfUB4fq6z7CV8l85CWHDk5ErhyhpfDHhrOMwGFhSQkhMGHaIotA6Ng==} + engines: {node: '>= 0.4'} + dependencies: + call-bind: 1.0.2 + define-properties: 1.2.0 + es-abstract: 1.22.1 + dev: true + /obliterator@1.6.1: resolution: {integrity: sha512-9WXswnqINnnhOG/5SLimUlzuU1hFJUc8zkwyD59Sd+dPOMf05PmnYG/d6Q7HZ+KmgkZJa1PxRso6QdM3sTNHig==} dev: true @@ -11643,7 +11752,7 @@ packages: resolution: {integrity: sha512-ayCKvm/phCGxOkYRSCM82iDwct8/EonSEgCSxWxD7ve6jHggsFl4fZVQBPRNgQoKiuV/odhFrGzQXZwbifC8Rg==} engines: {node: '>=8'} dependencies: - '@babel/code-frame': 7.22.10 + '@babel/code-frame': 7.22.13 error-ex: 1.3.2 json-parse-even-better-errors: 2.3.1 lines-and-columns: 1.2.4 @@ -11859,7 +11968,7 @@ packages: engines: {node: '>=10'} hasBin: true dependencies: - '@sentry/node': 7.74.0 + '@sentry/node': 7.77.0 commander: 2.20.3 pumpify: 2.0.1 split2: 3.2.2 @@ -11890,8 +11999,8 @@ packages: sonic-boom: 2.8.0 thread-stream: 0.15.2 - /pino@8.16.0: - resolution: {integrity: sha512-UUmvQ/7KTZt/vHjhRrnyS7h+J7qPBQnpG80V56xmIC+o9IqYmQOw/UIny9S9zYDfRBR0ClouCr464EkBMIT7Fw==} + /pino@8.16.1: + resolution: {integrity: sha512-3bKsVhBmgPjGV9pyn4fO/8RtoVDR8ssW1ev819FsRXlRNgW8gR/9Kx+gCK4UPWd4JjrRDLWpzd/pb1AyWm3MGA==} hasBin: true dependencies: atomic-sleep: 1.0.0 @@ -11953,7 +12062,7 @@ packages: optional: true dependencies: lilconfig: 2.1.0 - yaml: 2.3.1 + yaml: 2.3.2 dev: true /postcss@8.4.27: @@ -12559,7 +12668,7 @@ packages: resolution: {integrity: sha512-Sb+mjNHOULsBv818T40qSPeRiuWLyaGMa5ewydRLFimneixmVy2zdivRl+AF6jaYPC8ERxGDmFSiqui6SfPd+g==} hasBin: true dependencies: - is-core-module: 2.13.0 + is-core-module: 2.13.1 path-parse: 1.0.7 supports-preserve-symlinks-flag: 1.0.0 dev: true @@ -12568,7 +12677,7 @@ packages: resolution: {integrity: sha512-PXNdCiPqDqeUou+w1C2eTQbNfxKSuMxqTCuvlmmMsk1NWHL5fRrhY6Pl0qEYYc6+QqGClco1Qj8XnjPego4wfg==} hasBin: true dependencies: - is-core-module: 2.13.0 + is-core-module: 2.13.1 path-parse: 1.0.7 supports-preserve-symlinks-flag: 1.0.0 @@ -12576,7 +12685,7 @@ packages: resolution: {integrity: sha512-iMDbmAWtfU+MHpxt/I5iWI7cY6YVEZUQ3MBgPQ++XD1PELuJHIl82xBmObyP2KyQmkNB2dsqF7seoQQiAn5yDQ==} hasBin: true dependencies: - is-core-module: 2.13.0 + is-core-module: 2.13.1 path-parse: 1.0.7 supports-preserve-symlinks-flag: 1.0.0 dev: true @@ -12894,8 +13003,8 @@ packages: /signal-exit@3.0.7: resolution: {integrity: sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ==} - /signal-exit@4.0.2: - resolution: {integrity: sha512-MY2/qGx4enyjprQnFaZsHib3Yadh3IXyV2C321GY0pjGfVBu4un0uDJkwgdxqO+Rdx8JMT8IfJIRwbYVz3Ob3Q==} + /signal-exit@4.1.0: + resolution: {integrity: sha512-bzyZ1e88w9O1iNJbKnOlvYTrWPDl46O1bG0D3XInv+9tkPrxrN8jUUTiFlDkkmKWgn1M6CfIA13SuGqOa9Korw==} engines: {node: '>=14'} dev: true @@ -13021,11 +13130,6 @@ packages: whatwg-url: 7.1.0 dev: true - /sourcemap-codec@1.4.8: - resolution: {integrity: sha512-9NykojV5Uih4lgo5So5dtw+f0JgJX30KCNI8gwhz2J9A15wD0Ml6tjHKwf6fTSa6fAdVBdZeNOs9eJ71qCk8vA==} - deprecated: Please use @jridgewell/sourcemap-codec instead - dev: true - /spawn-wrap@2.0.0: resolution: {integrity: sha512-EeajNjfN9zMnULLwhZZQU3GWBoFNkbngTUPfaawT4RkMiviTxcX0qfhVbGey39mfctfDHkWtuecgQ8NJcyQWHg==} engines: {node: '>=8'} @@ -13651,7 +13755,7 @@ packages: tsconfig-paths: 3.14.2 dev: true - /ts-node@10.9.1(@types/node@20.8.5)(typescript@5.2.2): + /ts-node@10.9.1(@types/node@20.8.9)(typescript@5.2.2): resolution: {integrity: sha512-NtVysVPkxxrwFGUUxGYhfux8k78pQB3JqYBXlLRZgdGUqTO5wU/UyHop5p70iEbGhB7q5KmiZiU0Y3KlJrScEw==} hasBin: true peerDependencies: @@ -13670,7 +13774,7 @@ packages: '@tsconfig/node12': 1.0.11 '@tsconfig/node14': 1.0.3 '@tsconfig/node16': 1.0.4 - '@types/node': 20.8.5 + '@types/node': 20.8.9 acorn: 8.10.0 acorn-walk: 8.2.0 arg: 4.1.3 @@ -13741,7 +13845,7 @@ packages: resolution: {integrity: sha512-Tyrf5mxF8Ofs1tNoxA13lFeZ2Zrbd6cKbuH3V+MQ5sb6DtBj5FjrXVsRWT8YvNAQTqNoz66dz1WsbigI22aEnw==} dev: true - /tsup@7.2.0(@swc/core@1.3.92)(typescript@5.2.2): + /tsup@7.2.0(@swc/core@1.3.95)(typescript@5.2.2): resolution: {integrity: sha512-vDHlczXbgUvY3rWvqFEbSqmC1L7woozbzngMqTtL2PGBODTtWlRwGDDawhvWzr5c1QjKe4OAKqJGfE1xeXUvtQ==} engines: {node: '>=16.14'} hasBin: true @@ -13757,7 +13861,7 @@ packages: typescript: optional: true dependencies: - '@swc/core': 1.3.92 + '@swc/core': 1.3.95 bundle-require: 4.0.1(esbuild@0.18.15) cac: 6.7.14 chokidar: 3.5.3 @@ -13778,13 +13882,13 @@ packages: - ts-node dev: true - /tsx@3.12.7: - resolution: {integrity: sha512-C2Ip+jPmqKd1GWVQDvz/Eyc6QJbGfE7NrR3fx5BpEHMZsEHoIxHL1j+lKdGobr8ovEyqeNkPLSKp6SCSOt7gmw==} + /tsx@3.14.0: + resolution: {integrity: sha512-xHtFaKtHxM9LOklMmJdI3BEnQq/D5F73Of2E1GDrITi9sgoVkvIsrQUTY1G8FlmGtA+awCI4EBlTRRYxkL2sRg==} hasBin: true dependencies: - '@esbuild-kit/cjs-loader': 2.4.2 - '@esbuild-kit/core-utils': 3.1.0 - '@esbuild-kit/esm-loader': 2.5.5 + esbuild: 0.18.20 + get-tsconfig: 4.7.2 + source-map-support: 0.5.21 optionalDependencies: fsevents: 2.3.3 dev: true @@ -13931,8 +14035,8 @@ packages: dependencies: is-typedarray: 1.0.0 - /typedoc@0.25.2(typescript@5.2.2): - resolution: {integrity: sha512-286F7BeATBiWe/qC4PCOCKlSTwfnsLbC/4cZ68oGBbvAqb9vV33quEOXx7q176OXotD+JdEerdQ1OZGJ818lnA==} + /typedoc@0.25.3(typescript@5.2.2): + resolution: {integrity: sha512-Ow8Bo7uY1Lwy7GTmphRIMEo6IOZ+yYUyrc8n5KXIZg1svpqhZSWgni2ZrDhe+wLosFS8yswowUzljTAV/3jmWw==} engines: {node: '>= 16'} hasBin: true peerDependencies: @@ -13993,6 +14097,10 @@ packages: /undici-types@5.25.3: resolution: {integrity: sha512-Ga1jfYwRn7+cP9v8auvEXN1rX3sWqlayd4HP7OKk4mZWylEmu3KzXDUGrQUN6Ol7qo1gPvB2e5gX6udnyEPgdA==} + dev: true + + /undici-types@5.26.5: + resolution: {integrity: sha512-JlCMO+ehdEIKqlFxk6IfVoAUVmgz7cU7zD/h9XZ0qzeosSHmUJVOzSQvvYSYWXkFXC+IfLKSIffhv0sVZup6pA==} /undici@5.24.0: resolution: {integrity: sha512-OKlckxBjFl0oXxcj9FU6oB8fDAaiRUq+D8jrFWGmOfI/gIyjk/IeS75LMzgYKUaeHzLUcYvf9bbJGSrUwTfwwQ==} @@ -14226,8 +14334,8 @@ packages: vfile-message: 2.0.4 dev: true - /viem@1.16.5(typescript@5.2.2)(zod@3.22.3): - resolution: {integrity: sha512-D8aE6cp/5w6PDtOOkJjkN+FtLyfsNWkfE78N4yTgCt4BG7KsBsePp4O68r1IaTVTVa41anebiZAy9kNEIwAXiw==} + /viem@1.18.6(typescript@5.2.2)(zod@3.22.3): + resolution: {integrity: sha512-oKkrxF2aqxjJ4pmm0ko7j+ZFRekP6VGIknSroV+6+dF+T31bscltPZwJ0fOJDxCOVhoVtxrKFRTkkasEVDblUA==} peerDependencies: typescript: '>=5.0.4' peerDependenciesMeta: @@ -14249,8 +14357,8 @@ packages: - zod dev: true - /viem@1.16.5(typescript@5.2.2)(zod@3.22.4): - resolution: {integrity: sha512-D8aE6cp/5w6PDtOOkJjkN+FtLyfsNWkfE78N4yTgCt4BG7KsBsePp4O68r1IaTVTVa41anebiZAy9kNEIwAXiw==} + /viem@1.18.6(typescript@5.2.2)(zod@3.22.4): + resolution: {integrity: sha512-oKkrxF2aqxjJ4pmm0ko7j+ZFRekP6VGIknSroV+6+dF+T31bscltPZwJ0fOJDxCOVhoVtxrKFRTkkasEVDblUA==} peerDependencies: typescript: '>=5.0.4' peerDependenciesMeta: @@ -14271,7 +14379,7 @@ packages: - utf-8-validate - zod - /vite-node@0.34.1(@types/node@20.8.5): + /vite-node@0.34.1(@types/node@20.8.9): resolution: {integrity: sha512-odAZAL9xFMuAg8aWd7nSPT+hU8u2r9gU3LRm9QKjxBEF2rRdWpMuqkrkjvyVQEdNFiBctqr2Gg4uJYizm5Le6w==} engines: {node: '>=v14.18.0'} hasBin: true @@ -14281,7 +14389,7 @@ packages: mlly: 1.4.0 pathe: 1.1.1 picocolors: 1.0.0 - vite: 4.4.10(@types/node@20.8.5) + vite: 4.5.0(@types/node@20.8.9) transitivePeerDependencies: - '@types/node' - less @@ -14293,7 +14401,7 @@ packages: - terser dev: true - /vite-node@0.34.2(@types/node@20.8.4): + /vite-node@0.34.2(@types/node@20.8.8): resolution: {integrity: sha512-JtW249Zm3FB+F7pQfH56uWSdlltCo1IOkZW5oHBzeQo0iX4jtC7o1t9aILMGd9kVekXBP2lfJBEQt9rBh07ebA==} engines: {node: '>=v14.18.0'} hasBin: true @@ -14303,7 +14411,7 @@ packages: mlly: 1.4.0 pathe: 1.1.1 picocolors: 1.0.0 - vite: 4.4.10(@types/node@20.8.4) + vite: 4.5.0(@types/node@20.8.8) transitivePeerDependencies: - '@types/node' - less @@ -14315,7 +14423,7 @@ packages: - terser dev: true - /vite-node@0.34.2(@types/node@20.8.5): + /vite-node@0.34.2(@types/node@20.8.9): resolution: {integrity: sha512-JtW249Zm3FB+F7pQfH56uWSdlltCo1IOkZW5oHBzeQo0iX4jtC7o1t9aILMGd9kVekXBP2lfJBEQt9rBh07ebA==} engines: {node: '>=v14.18.0'} hasBin: true @@ -14325,7 +14433,7 @@ packages: mlly: 1.4.0 pathe: 1.1.1 picocolors: 1.0.0 - vite: 4.4.10(@types/node@20.8.5) + vite: 4.5.0(@types/node@20.8.9) transitivePeerDependencies: - '@types/node' - less @@ -14337,7 +14445,7 @@ packages: - terser dev: true - /vite-node@0.34.4(@types/node@20.8.4): + /vite-node@0.34.4(@types/node@20.8.8): resolution: {integrity: sha512-ho8HtiLc+nsmbwZMw8SlghESEE3KxJNp04F/jPUCLVvaURwt0d+r9LxEqCX5hvrrOQ0GSyxbYr5ZfRYhQ0yVKQ==} engines: {node: '>=v14.18.0'} hasBin: true @@ -14347,7 +14455,7 @@ packages: mlly: 1.4.0 pathe: 1.1.1 picocolors: 1.0.0 - vite: 4.4.10(@types/node@20.8.4) + vite: 4.5.0(@types/node@20.8.8) transitivePeerDependencies: - '@types/node' - less @@ -14359,7 +14467,7 @@ packages: - terser dev: true - /vite@4.4.10(@types/node@20.8.4): + /vite@4.4.10(@types/node@20.8.8): resolution: {integrity: sha512-TzIjiqx9BEXF8yzYdF2NTf1kFFbjMjUSV0LFZ3HyHoI3SGSPLnnFUKiIQtL3gl2AjHvMrprOvQ3amzaHgQlAxw==} engines: {node: ^14.18.0 || >=16.0.0} hasBin: true @@ -14387,16 +14495,16 @@ packages: terser: optional: true dependencies: - '@types/node': 20.8.4 - esbuild: 0.18.15 + '@types/node': 20.8.8 + esbuild: 0.18.20 postcss: 8.4.27 rollup: 3.28.0 optionalDependencies: fsevents: 2.3.3 dev: true - /vite@4.4.10(@types/node@20.8.5): - resolution: {integrity: sha512-TzIjiqx9BEXF8yzYdF2NTf1kFFbjMjUSV0LFZ3HyHoI3SGSPLnnFUKiIQtL3gl2AjHvMrprOvQ3amzaHgQlAxw==} + /vite@4.5.0(@types/node@20.8.8): + resolution: {integrity: sha512-ulr8rNLA6rkyFAlVWw2q5YJ91v098AFQ2R0PRFwPzREXOUJQPtFUG0t+/ZikhaOCDqFoDhN6/v8Sq0o4araFAw==} engines: {node: ^14.18.0 || >=16.0.0} hasBin: true peerDependencies: @@ -14423,16 +14531,16 @@ packages: terser: optional: true dependencies: - '@types/node': 20.8.5 - esbuild: 0.18.15 + '@types/node': 20.8.8 + esbuild: 0.18.20 postcss: 8.4.27 rollup: 3.28.0 optionalDependencies: fsevents: 2.3.3 dev: true - /vite@4.4.9(@types/node@20.8.4): - resolution: {integrity: sha512-2mbUn2LlUmNASWwSCNSJ/EG2HuSRTnVNaydp6vMCm5VIqJsjMfbIWtbH2kDuwUVW5mMUKKZvGPX/rqeqVvv1XA==} + /vite@4.5.0(@types/node@20.8.9): + resolution: {integrity: sha512-ulr8rNLA6rkyFAlVWw2q5YJ91v098AFQ2R0PRFwPzREXOUJQPtFUG0t+/ZikhaOCDqFoDhN6/v8Sq0o4araFAw==} engines: {node: ^14.18.0 || >=16.0.0} hasBin: true peerDependencies: @@ -14459,8 +14567,8 @@ packages: terser: optional: true dependencies: - '@types/node': 20.8.4 - esbuild: 0.18.15 + '@types/node': 20.8.9 + esbuild: 0.18.20 postcss: 8.4.27 rollup: 3.28.0 optionalDependencies: @@ -14498,9 +14606,9 @@ packages: webdriverio: optional: true dependencies: - '@types/chai': 4.3.7 + '@types/chai': 4.3.8 '@types/chai-subset': 1.3.3 - '@types/node': 20.8.5 + '@types/node': 20.8.9 '@vitest/expect': 0.34.1 '@vitest/runner': 0.34.1 '@vitest/snapshot': 0.34.1 @@ -14519,8 +14627,8 @@ packages: strip-literal: 1.0.1 tinybench: 2.5.0 tinypool: 0.7.0 - vite: 4.4.10(@types/node@20.8.5) - vite-node: 0.34.1(@types/node@20.8.5) + vite: 4.5.0(@types/node@20.8.9) + vite-node: 0.34.1(@types/node@20.8.9) why-is-node-running: 2.2.2 transitivePeerDependencies: - less @@ -14563,9 +14671,9 @@ packages: webdriverio: optional: true dependencies: - '@types/chai': 4.3.7 + '@types/chai': 4.3.8 '@types/chai-subset': 1.3.3 - '@types/node': 20.8.5 + '@types/node': 20.8.9 '@vitest/expect': 0.34.2 '@vitest/runner': 0.34.2 '@vitest/snapshot': 0.34.2 @@ -14584,8 +14692,8 @@ packages: strip-literal: 1.0.1 tinybench: 2.5.0 tinypool: 0.7.0 - vite: 4.4.10(@types/node@20.8.5) - vite-node: 0.34.2(@types/node@20.8.5) + vite: 4.5.0(@types/node@20.8.9) + vite-node: 0.34.2(@types/node@20.8.9) why-is-node-running: 2.2.2 transitivePeerDependencies: - less @@ -14630,7 +14738,7 @@ packages: dependencies: '@types/chai': 4.3.7 '@types/chai-subset': 1.3.3 - '@types/node': 20.8.4 + '@types/node': 20.8.8 '@vitest/expect': 0.34.2 '@vitest/runner': 0.34.2 '@vitest/snapshot': 0.34.2 @@ -14650,8 +14758,8 @@ packages: strip-literal: 1.0.1 tinybench: 2.5.0 tinypool: 0.7.0 - vite: 4.4.10(@types/node@20.8.4) - vite-node: 0.34.2(@types/node@20.8.4) + vite: 4.5.0(@types/node@20.8.8) + vite-node: 0.34.2(@types/node@20.8.8) why-is-node-running: 2.2.2 transitivePeerDependencies: - less @@ -14694,9 +14802,9 @@ packages: webdriverio: optional: true dependencies: - '@types/chai': 4.3.6 + '@types/chai': 4.3.7 '@types/chai-subset': 1.3.3 - '@types/node': 20.8.4 + '@types/node': 20.8.8 '@vitest/expect': 0.34.4 '@vitest/runner': 0.34.4 '@vitest/snapshot': 0.34.4 @@ -14715,8 +14823,8 @@ packages: strip-literal: 1.0.1 tinybench: 2.5.0 tinypool: 0.7.0 - vite: 4.4.9(@types/node@20.8.4) - vite-node: 0.34.4(@types/node@20.8.4) + vite: 4.4.10(@types/node@20.8.8) + vite-node: 0.34.4(@types/node@20.8.8) why-is-node-running: 2.2.2 transitivePeerDependencies: - less @@ -14743,7 +14851,7 @@ packages: xml-name-validator: 4.0.0 dev: true - /wagmi@1.0.1(react-dom@18.2.0)(react@18.2.0)(typescript@5.2.2)(viem@1.16.5): + /wagmi@1.0.1(react-dom@18.2.0)(react@18.2.0)(typescript@5.2.2)(viem@1.18.6): resolution: {integrity: sha512-+2UkZG9eA3tKqXj1wvlvI8mL0Bcff7Tf5CKfUOyQsdKcY+J5rfwYYya25G+jja57umpHFtfxRaL7xDkNjehrRg==} peerDependencies: react: '>=17.0.0' @@ -14756,12 +14864,12 @@ packages: '@tanstack/query-sync-storage-persister': 4.29.25 '@tanstack/react-query': 4.29.25(react-dom@18.2.0)(react@18.2.0) '@tanstack/react-query-persist-client': 4.29.25(@tanstack/react-query@4.29.25) - '@wagmi/core': 1.0.1(react@18.2.0)(typescript@5.2.2)(viem@1.16.5) + '@wagmi/core': 1.0.1(react@18.2.0)(typescript@5.2.2)(viem@1.18.6) abitype: 0.8.1(typescript@5.2.2) react: 18.2.0 typescript: 5.2.2 use-sync-external-store: 1.2.0(react@18.2.0) - viem: 1.16.5(typescript@5.2.2)(zod@3.22.4) + viem: 1.18.6(typescript@5.2.2)(zod@3.22.4) transitivePeerDependencies: - '@react-native-async-storage/async-storage' - bufferutil @@ -14794,7 +14902,7 @@ packages: web3-providers-http: 4.0.4 web3-providers-ws: 4.0.4 web3-types: 1.1.0 - web3-utils: 4.0.4 + web3-utils: 4.0.5 web3-validator: 2.0.0 optionalDependencies: web3-providers-ipc: 4.0.5 @@ -14818,7 +14926,6 @@ packages: dependencies: web3-types: 1.1.1 dev: false - optional: true /web3-eth-abi@4.1.0: resolution: {integrity: sha512-qd+zCGKi2YsL2KkbM5M8Qztles/WPOvFpw6Lg3a904DRIVxkIvWdQfoK0JbA6Vbt8DSVKCc4rpZ15D6I/wfBKQ==} @@ -14828,7 +14935,7 @@ packages: '@ethersproject/bignumber': 5.7.0 web3-errors: 1.1.0 web3-types: 1.1.0 - web3-utils: 4.0.4 + web3-utils: 4.0.5 dev: false /web3-eth-accounts@4.0.3: @@ -14853,7 +14960,7 @@ packages: ethereum-cryptography: 2.1.2 web3-errors: 1.1.0 web3-types: 1.1.0 - web3-utils: 4.0.4 + web3-utils: 4.0.5 web3-validator: 2.0.0 dev: false @@ -14866,7 +14973,7 @@ packages: web3-eth: 4.1.0 web3-eth-abi: 4.1.0 web3-types: 1.1.0 - web3-utils: 4.0.4 + web3-utils: 4.0.5 web3-validator: 2.0.0 transitivePeerDependencies: - bufferutil @@ -14885,7 +14992,7 @@ packages: web3-eth-contract: 4.0.4 web3-net: 4.0.4 web3-types: 1.1.0 - web3-utils: 4.0.4 + web3-utils: 4.0.5 web3-validator: 2.0.0 transitivePeerDependencies: - bufferutil @@ -14899,7 +15006,7 @@ packages: dependencies: web3-errors: 1.1.0 web3-types: 1.1.0 - web3-utils: 4.0.4 + web3-utils: 4.0.5 web3-validator: 2.0.0 dev: false @@ -14911,7 +15018,7 @@ packages: web3-eth: 4.1.0 web3-rpc-methods: 1.1.0 web3-types: 1.1.0 - web3-utils: 4.0.4 + web3-utils: 4.0.5 web3-validator: 2.0.0 transitivePeerDependencies: - bufferutil @@ -14953,7 +15060,7 @@ packages: web3-providers-ws: 4.0.4 web3-rpc-methods: 1.1.0 web3-types: 1.1.0 - web3-utils: 4.0.4 + web3-utils: 4.0.5 web3-validator: 2.0.0 transitivePeerDependencies: - bufferutil @@ -14968,7 +15075,7 @@ packages: web3-core: 4.1.0 web3-rpc-methods: 1.1.0 web3-types: 1.1.0 - web3-utils: 4.0.4 + web3-utils: 4.0.5 transitivePeerDependencies: - bufferutil - encoding @@ -14982,7 +15089,7 @@ packages: cross-fetch: 3.1.8 web3-errors: 1.1.0 web3-types: 1.1.0 - web3-utils: 4.0.4 + web3-utils: 4.0.5 transitivePeerDependencies: - encoding dev: false @@ -15006,7 +15113,7 @@ packages: isomorphic-ws: 5.0.0(ws@8.13.0) web3-errors: 1.1.0 web3-types: 1.1.0 - web3-utils: 4.0.4 + web3-utils: 4.0.5 ws: 8.13.0(bufferutil@4.0.7)(utf-8-validate@5.0.10) transitivePeerDependencies: - bufferutil @@ -15036,7 +15143,6 @@ packages: engines: {node: '>=14', npm: '>=6.12.0'} requiresBuild: true dev: false - optional: true /web3-utils@1.10.1: resolution: {integrity: sha512-r6iUUw/uMnNcWXjhRv33Nyrhxq3VGOPBXeSzxhOXIci4SvC/LPTpROY0uTrMX7ztKyODYrHp8WhTkEf+ZnHssw==} @@ -15064,14 +15170,12 @@ packages: /web3-utils@4.0.5: resolution: {integrity: sha512-43xIM7rr3htYNzliVQLpWLQmEf4XX8IXgjvqLcEuC/xje14O5UQM4kamRCtz8v3JZN3X6QTfsV6Zgby67mVmCg==} engines: {node: '>=14', npm: '>=6.12.0'} - requiresBuild: true dependencies: ethereum-cryptography: 2.1.2 web3-errors: 1.1.1 web3-types: 1.1.1 web3-validator: 2.0.1 dev: false - optional: true /web3-validator@1.0.2: resolution: {integrity: sha512-orx1CQAEnwJUnl/8iF2II2zSA4wiooNJvFmVE0Dbmt/kE370SugIDViQP76snhxtouG2AXzz4GyKbPCMlLGh/A==} @@ -15106,7 +15210,6 @@ packages: web3-types: 1.1.1 zod: 3.22.4 dev: false - optional: true /web3@4.0.3: resolution: {integrity: sha512-rUMxui5f52yPWjiMRQV6xqIrTQSovYM2CNhl57y+xj/fGXNLbI1D5FsLPnUMZjMaFHJBTteaBxq/sTEaw/1jNA==} @@ -15414,6 +15517,16 @@ packages: engines: {node: '>= 14'} dev: true + /yaml@2.3.2: + resolution: {integrity: sha512-N/lyzTPaJasoDmfV7YTrYCI0G/3ivm/9wdG0aHuheKowWQwGTsK0Eoiw6utmzAnI6pkJa0DUVygvp3spqqEKXg==} + engines: {node: '>= 14'} + dev: true + + /yaml@2.3.3: + resolution: {integrity: sha512-zw0VAJxgeZ6+++/su5AFoqBbZbrEakwu+X0M5HmcwUiBL7AzcuPKjj5we4xfQLp78LkEMpD0cOnUhmgOVy3KdQ==} + engines: {node: '>= 14'} + dev: true + /yargs-parser@18.1.3: resolution: {integrity: sha512-o50j0JeToy/4K6OZcaQmW6lyXXKhq7csREXcDwk2omFPJEwUNOVtJKvmDr9EI1fAJZUyZcRF7kxGBWmRXudrCQ==} engines: {node: '>=6'} diff --git a/proxyd/Dockerfile b/proxyd/Dockerfile index 86eb7b14d62e5..b066e0ecafe7e 100644 --- a/proxyd/Dockerfile +++ b/proxyd/Dockerfile @@ -1,4 +1,4 @@ -FROM golang:1.20.4-alpine3.18 as builder +FROM golang:1.21.3-alpine3.18 as builder ARG GITCOMMIT=docker ARG GITDATE=docker @@ -14,7 +14,7 @@ RUN make proxyd FROM alpine:3.18 -RUN apk add bind-tools jq curl +RUN apk add bind-tools jq curl bash git redis COPY ./proxyd/entrypoint.sh /bin/entrypoint.sh diff --git a/proxyd/Dockerfile.ignore b/proxyd/Dockerfile.ignore new file mode 100644 index 0000000000000..eac1d0bc0b269 --- /dev/null +++ b/proxyd/Dockerfile.ignore @@ -0,0 +1,3 @@ +# ignore everything but proxyd, proxyd defines all its dependencies in the go.mod +* +!/proxyd diff --git a/proxyd/backend.go b/proxyd/backend.go index 24b2897236f13..b558ff833c593 100644 --- a/proxyd/backend.go +++ b/proxyd/backend.go @@ -22,6 +22,7 @@ import ( "github.com/ethereum/go-ethereum/rpc" "github.com/gorilla/websocket" "github.com/prometheus/client_golang/prometheus" + "github.com/xaionaro-go/weightedshuffle" "golang.org/x/sync/semaphore" sw "github.com/ethereum-optimism/optimism/proxyd/pkg/avg-sliding-window" @@ -98,6 +99,18 @@ var ( HTTPErrorCode: 400, } + ErrRequestBodyTooLarge = &RPCErr{ + Code: JSONRPCErrorInternal - 21, + Message: "request body too large", + HTTPErrorCode: 413, + } + + ErrBackendResponseTooLarge = &RPCErr{ + Code: JSONRPCErrorInternal - 20, + Message: "backend response too large", + HTTPErrorCode: 500, + } + ErrBackendUnexpectedJSONRPC = errors.New("backend returned an unexpected JSON-RPC response") ErrConsensusGetReceiptsCantBeBatched = errors.New("consensus_getReceipts cannot be batched") @@ -127,6 +140,7 @@ type Backend struct { wsURL string authUsername string authPassword string + headers map[string]string client *LimitedHTTPClient dialer *websocket.Dialer maxRetries int @@ -147,6 +161,8 @@ type Backend struct { latencySlidingWindow *sw.AvgSlidingWindow networkRequestsSlidingWindow *sw.AvgSlidingWindow networkErrorsSlidingWindow *sw.AvgSlidingWindow + + weight int } type BackendOpt func(b *Backend) @@ -158,6 +174,12 @@ func WithBasicAuth(username, password string) BackendOpt { } } +func WithHeaders(headers map[string]string) BackendOpt { + return func(b *Backend) { + b.headers = headers + } +} + func WithTimeout(timeout time.Duration) BackendOpt { return func(b *Backend) { b.client.Timeout = timeout @@ -227,6 +249,12 @@ func WithConsensusForcedCandidate(forcedCandidate bool) BackendOpt { } } +func WithWeight(weight int) BackendOpt { + return func(b *Backend) { + b.weight = weight + } +} + func WithMaxDegradedLatencyThreshold(maxDegradedLatencyThreshold time.Duration) BackendOpt { return func(b *Backend) { b.maxDegradedLatencyThreshold = maxDegradedLatencyThreshold @@ -339,6 +367,14 @@ func (b *Backend) Forward(ctx context.Context, reqs []*RPCReq, isBatch bool) ([] res, err := b.doForward(ctx, reqs, isBatch) switch err { case nil: // do nothing + case ErrBackendResponseTooLarge: + log.Warn( + "backend response too large", + "name", b.Name, + "req_id", GetReqID(ctx), + "max", b.maxResponseSize, + ) + RecordBatchRPCError(ctx, b.Name, reqs, err) case ErrConsensusGetReceiptsCantBeBatched: log.Warn( "Received unsupported batch request for consensus_getReceipts", @@ -515,6 +551,10 @@ func (b *Backend) doForward(ctx context.Context, rpcReqs []*RPCReq, isBatch bool httpReq.Header.Set("content-type", "application/json") httpReq.Header.Set("X-Forwarded-For", xForwardedFor) + for name, value := range b.headers { + httpReq.Header.Set(name, value) + } + start := time.Now() httpRes, err := b.client.DoLimited(httpReq) if err != nil { @@ -543,7 +583,10 @@ func (b *Backend) doForward(ctx context.Context, rpcReqs []*RPCReq, isBatch bool } defer httpRes.Body.Close() - resB, err := io.ReadAll(io.LimitReader(httpRes.Body, b.maxResponseSize)) + resB, err := io.ReadAll(LimitReader(httpRes.Body, b.maxResponseSize)) + if errors.Is(err, ErrLimitReaderOverLimit) { + return nil, ErrBackendResponseTooLarge + } if err != nil { b.networkErrorsSlidingWindow.Incr() RecordBackendNetworkErrorRateSlidingWindow(b, b.ErrorRate()) @@ -660,17 +703,18 @@ func sortBatchRPCResponse(req []*RPCReq, res []*RPCRes) { } type BackendGroup struct { - Name string - Backends []*Backend - Consensus *ConsensusPoller + Name string + Backends []*Backend + WeightedRouting bool + Consensus *ConsensusPoller } -func (bg *BackendGroup) Forward(ctx context.Context, rpcReqs []*RPCReq, isBatch bool) ([]*RPCRes, error) { +func (bg *BackendGroup) Forward(ctx context.Context, rpcReqs []*RPCReq, isBatch bool) ([]*RPCRes, string, error) { if len(rpcReqs) == 0 { - return nil, nil + return nil, "", nil } - backends := bg.Backends + backends := bg.orderedBackendsForRequest() overriddenResponses := make([]*indexedReqRes, 0) rewrittenReqs := make([]*RPCReq, 0, len(rpcReqs)) @@ -678,7 +722,6 @@ func (bg *BackendGroup) Forward(ctx context.Context, rpcReqs []*RPCReq, isBatch if bg.Consensus != nil { // When `consensus_aware` is set to `true`, the backend group acts as a load balancer // serving traffic from any backend that agrees in the consensus group - backends = bg.loadBalancedConsensusGroup() // We also rewrite block tags to enforce compliance with consensus rctx := RewriteContext{ @@ -726,12 +769,17 @@ func (bg *BackendGroup) Forward(ctx context.Context, rpcReqs []*RPCReq, isBatch res := make([]*RPCRes, 0) var err error + servedBy := fmt.Sprintf("%s/%s", bg.Name, back.Name) + if len(rpcReqs) > 0 { res, err = back.Forward(ctx, rpcReqs, isBatch) if errors.Is(err, ErrConsensusGetReceiptsCantBeBatched) || errors.Is(err, ErrConsensusGetReceiptsInvalidTarget) || errors.Is(err, ErrMethodNotWhitelisted) { - return nil, err + return nil, "", err + } + if errors.Is(err, ErrBackendResponseTooLarge) { + return nil, servedBy, err } if errors.Is(err, ErrBackendOffline) { log.Warn( @@ -773,11 +821,11 @@ func (bg *BackendGroup) Forward(ctx context.Context, rpcReqs []*RPCReq, isBatch } } - return res, nil + return res, servedBy, nil } RecordUnserviceableRequest(ctx, RPCRequestSourceHTTP) - return nil, ErrNoBackends + return nil, "", ErrNoBackends } func (bg *BackendGroup) ProxyWS(ctx context.Context, clientConn *websocket.Conn, methodWhitelist *StringSet) (*WSProxier, error) { @@ -817,6 +865,27 @@ func (bg *BackendGroup) ProxyWS(ctx context.Context, clientConn *websocket.Conn, return nil, ErrNoBackends } +func weightedShuffle(backends []*Backend) { + weight := func(i int) float64 { + return float64(backends[i].weight) + } + + weightedshuffle.ShuffleInplace(backends, weight, nil) +} + +func (bg *BackendGroup) orderedBackendsForRequest() []*Backend { + if bg.Consensus != nil { + return bg.loadBalancedConsensusGroup() + } else if bg.WeightedRouting { + result := make([]*Backend, len(bg.Backends)) + copy(result, bg.Backends) + weightedShuffle(result) + return result + } else { + return bg.Backends + } +} + func (bg *BackendGroup) loadBalancedConsensusGroup() []*Backend { cg := bg.Consensus.GetConsensusGroup() @@ -844,6 +913,10 @@ func (bg *BackendGroup) loadBalancedConsensusGroup() []*Backend { backendsDegraded[i], backendsDegraded[j] = backendsDegraded[j], backendsDegraded[i] }) + if bg.WeightedRouting { + weightedShuffle(backendsHealthy) + } + // healthy are put into a priority position // degraded backends are used as fallback backendsHealthy = append(backendsHealthy, backendsDegraded...) @@ -1169,6 +1242,6 @@ func RecordBatchRPCForward(ctx context.Context, backendName string, reqs []*RPCR } func stripXFF(xff string) string { - ipList := strings.Split(xff, ", ") + ipList := strings.Split(xff, ",") return strings.TrimSpace(ipList[0]) } diff --git a/proxyd/backend_test.go b/proxyd/backend_test.go new file mode 100644 index 0000000000000..7be23bfed7bc5 --- /dev/null +++ b/proxyd/backend_test.go @@ -0,0 +1,21 @@ +package proxyd + +import ( + "github.com/stretchr/testify/assert" + "testing" +) + +func TestStripXFF(t *testing.T) { + tests := []struct { + in, out string + }{ + {"1.2.3, 4.5.6, 7.8.9", "1.2.3"}, + {"1.2.3,4.5.6", "1.2.3"}, + {" 1.2.3 , 4.5.6 ", "1.2.3"}, + } + + for _, test := range tests { + actual := stripXFF(test.in) + assert.Equal(t, test.out, actual) + } +} diff --git a/proxyd/cache.go b/proxyd/cache.go index e60c6bd8ced0d..a93a39371357e 100644 --- a/proxyd/cache.go +++ b/proxyd/cache.go @@ -128,7 +128,7 @@ type rpcCache struct { func newRPCCache(cache Cache) RPCCache { staticHandler := &StaticMethodHandler{cache: cache} debugGetRawReceiptsHandler := &StaticMethodHandler{cache: cache, - filter: func(req *RPCReq) bool { + filterGet: func(req *RPCReq) bool { // cache only if the request is for a block hash var p []rpc.BlockNumberOrHash @@ -141,6 +141,14 @@ func newRPCCache(cache Cache) RPCCache { } return p[0].BlockHash != nil }, + filterPut: func(req *RPCReq, res *RPCRes) bool { + // don't cache if response contains 0 receipts + rawReceipts, ok := res.Result.([]interface{}) + if !ok { + return false + } + return len(rawReceipts) > 0 + }, } handlers := map[string]RPCMethodHandler{ "eth_chainId": staticHandler, diff --git a/proxyd/cache_test.go b/proxyd/cache_test.go index 93d0b8e011bce..da47e7c4d60d5 100644 --- a/proxyd/cache_test.go +++ b/proxyd/cache_test.go @@ -110,7 +110,7 @@ func TestRPCCacheImmutableRPCs(t *testing.T) { }, res: &RPCRes{ JSONRPC: "2.0", - Result: `{"debug_getRawReceipts":"!"}`, + Result: []interface{}{"a"}, ID: ID, }, name: "debug_getRawReceipts", diff --git a/proxyd/cmd/proxyd/main.go b/proxyd/cmd/proxyd/main.go index a97aacb6739de..10a1518cdb6fe 100644 --- a/proxyd/cmd/proxyd/main.go +++ b/proxyd/cmd/proxyd/main.go @@ -1,8 +1,12 @@ package main import ( + "net" + "net/http" + "net/http/pprof" "os" "os/signal" + "strconv" "syscall" "github.com/BurntSushi/toml" @@ -52,6 +56,17 @@ func main() { ), ) + if config.Server.EnablePprof { + log.Info("starting pprof", "addr", "0.0.0.0", "port", "6060") + pprofSrv := StartPProf("0.0.0.0", 6060) + log.Info("started pprof server", "addr", pprofSrv.Addr) + defer func() { + if err := pprofSrv.Close(); err != nil { + log.Error("failed to stop pprof server", "err", err) + } + }() + } + _, shutdown, err := proxyd.Start(config) if err != nil { log.Crit("error starting proxyd", "err", err) @@ -63,3 +78,25 @@ func main() { log.Info("caught signal, shutting down", "signal", recvSig) shutdown() } + +func StartPProf(hostname string, port int) *http.Server { + mux := http.NewServeMux() + + // have to do below to support multiple servers, since the + // pprof import only uses DefaultServeMux + mux.Handle("/debug/pprof/", http.HandlerFunc(pprof.Index)) + mux.Handle("/debug/pprof/cmdline", http.HandlerFunc(pprof.Cmdline)) + mux.Handle("/debug/pprof/profile", http.HandlerFunc(pprof.Profile)) + mux.Handle("/debug/pprof/symbol", http.HandlerFunc(pprof.Symbol)) + mux.Handle("/debug/pprof/trace", http.HandlerFunc(pprof.Trace)) + + addr := net.JoinHostPort(hostname, strconv.Itoa(port)) + srv := &http.Server{ + Handler: mux, + Addr: addr, + } + + go srv.ListenAndServe() + + return srv +} diff --git a/proxyd/config.go b/proxyd/config.go index 14e3ece28e018..0e86b0b832dc4 100644 --- a/proxyd/config.go +++ b/proxyd/config.go @@ -22,8 +22,10 @@ type ServerConfig struct { MaxUpstreamBatchSize int `toml:"max_upstream_batch_size"` - EnableRequestLog bool `toml:"enable_request_log"` - MaxRequestBodyLogLen int `toml:"max_request_body_log_len"` + EnableRequestLog bool `toml:"enable_request_log"` + MaxRequestBodyLogLen int `toml:"max_request_body_log_len"` + EnablePprof bool `toml:"enable_pprof"` + EnableXServedByHeader bool `toml:"enable_served_by_header"` } type CacheConfig struct { @@ -49,6 +51,7 @@ type RateLimitConfig struct { ExemptUserAgents []string `toml:"exempt_user_agents"` ErrorMessage string `toml:"error_message"` MethodOverrides map[string]*RateLimitMethodOverride `toml:"method_overrides"` + IPHeaderOverride string `toml:"ip_header_override"` } type RateLimitMethodOverride struct { @@ -80,17 +83,20 @@ type BackendOptions struct { } type BackendConfig struct { - Username string `toml:"username"` - Password string `toml:"password"` - RPCURL string `toml:"rpc_url"` - WSURL string `toml:"ws_url"` - WSPort int `toml:"ws_port"` - MaxRPS int `toml:"max_rps"` - MaxWSConns int `toml:"max_ws_conns"` - CAFile string `toml:"ca_file"` - ClientCertFile string `toml:"client_cert_file"` - ClientKeyFile string `toml:"client_key_file"` - StripTrailingXFF bool `toml:"strip_trailing_xff"` + Username string `toml:"username"` + Password string `toml:"password"` + RPCURL string `toml:"rpc_url"` + WSURL string `toml:"ws_url"` + WSPort int `toml:"ws_port"` + MaxRPS int `toml:"max_rps"` + MaxWSConns int `toml:"max_ws_conns"` + CAFile string `toml:"ca_file"` + ClientCertFile string `toml:"client_cert_file"` + ClientKeyFile string `toml:"client_key_file"` + StripTrailingXFF bool `toml:"strip_trailing_xff"` + Headers map[string]string `toml:"headers"` + + Weight int `toml:"weight"` ConsensusSkipPeerCountCheck bool `toml:"consensus_skip_peer_count"` ConsensusForcedCandidate bool `toml:"consensus_forced_candidate"` @@ -102,6 +108,8 @@ type BackendsConfig map[string]*BackendConfig type BackendGroupConfig struct { Backends []string `toml:"backends"` + WeightedRouting bool `toml:"weighted_routing"` + ConsensusAware bool `toml:"consensus_aware"` ConsensusAsyncHandler string `toml:"consensus_handler"` diff --git a/proxyd/example.config.toml b/proxyd/example.config.toml index cce4896926d5c..b54b342f5189b 100644 --- a/proxyd/example.config.toml +++ b/proxyd/example.config.toml @@ -98,6 +98,8 @@ backends = ["infura"] # consensus_max_update_threshold = "20s" # Maximum block lag, default 8 # consensus_max_block_lag = 16 +# Maximum block range (for eth_getLogs method), no default +# consensus_max_block_range = 20000 # Minimum peer count, default 3 # consensus_min_peer_count = 4 diff --git a/proxyd/go.mod b/proxyd/go.mod index ac36a0cba36b3..5130774ebd359 100644 --- a/proxyd/go.mod +++ b/proxyd/go.mod @@ -1,82 +1,85 @@ module github.com/ethereum-optimism/optimism/proxyd -go 1.20 +go 1.21 require ( - github.com/BurntSushi/toml v1.2.0 + github.com/BurntSushi/toml v1.3.2 github.com/alicebob/miniredis v2.5.0+incompatible github.com/emirpasic/gods v1.18.1 - github.com/ethereum/go-ethereum v1.12.1 - github.com/go-redsync/redsync/v4 v4.9.4 + github.com/ethereum/go-ethereum v1.13.4 + github.com/go-redsync/redsync/v4 v4.10.0 github.com/golang/snappy v0.0.5-0.20220116011046-fa5810519dcb github.com/gorilla/mux v1.8.0 github.com/gorilla/websocket v1.5.0 - github.com/hashicorp/golang-lru v0.5.5-0.20210104140557-80c98217689d + github.com/hashicorp/golang-lru v1.0.2 github.com/pkg/errors v0.9.1 - github.com/prometheus/client_golang v1.14.0 - github.com/redis/go-redis/v9 v9.1.0 - github.com/rs/cors v1.8.2 - github.com/stretchr/testify v1.8.2 + github.com/prometheus/client_golang v1.17.0 + github.com/redis/go-redis/v9 v9.2.1 + github.com/rs/cors v1.10.1 + github.com/stretchr/testify v1.8.4 github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7 - golang.org/x/sync v0.3.0 + github.com/xaionaro-go/weightedshuffle v0.0.0-20211213010739-6a74fbc7d24a + golang.org/x/sync v0.4.0 gopkg.in/yaml.v3 v3.0.1 ) require ( - github.com/DataDog/zstd v1.5.2 // indirect - github.com/VictoriaMetrics/fastcache v1.9.0 // indirect - github.com/alicebob/gopher-json v0.0.0-20200520072559-a9ecdc9d1d3a // indirect + github.com/DataDog/zstd v1.5.5 // indirect + github.com/Microsoft/go-winio v0.6.1 // indirect + github.com/VictoriaMetrics/fastcache v1.12.1 // indirect + github.com/alicebob/gopher-json v0.0.0-20230218143504-906a9b012302 // indirect github.com/beorn7/perks v1.0.1 // indirect - github.com/bits-and-blooms/bitset v1.7.0 // indirect - github.com/btcsuite/btcd/btcec/v2 v2.2.0 // indirect + github.com/bits-and-blooms/bitset v1.10.0 // indirect + github.com/btcsuite/btcd/btcec/v2 v2.3.2 // indirect github.com/cespare/xxhash/v2 v2.2.0 // indirect - github.com/cockroachdb/errors v1.9.1 // indirect + github.com/cockroachdb/errors v1.11.1 // indirect github.com/cockroachdb/logtags v0.0.0-20230118201751-21c54148d20b // indirect - github.com/cockroachdb/pebble v0.0.0-20230209160836-829675f94811 // indirect - github.com/cockroachdb/redact v1.1.3 // indirect + github.com/cockroachdb/pebble v0.0.0-20231020221949-babd592d2360 // 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 - github.com/consensys/gnark-crypto v0.12.0 // indirect - github.com/crate-crypto/go-kzg-4844 v0.3.0 // indirect + github.com/consensys/gnark-crypto v0.12.1 // indirect + github.com/crate-crypto/go-kzg-4844 v0.7.0 // indirect github.com/davecgh/go-spew v1.1.1 // indirect - github.com/deckarep/golang-set/v2 v2.1.0 // indirect - github.com/decred/dcrd/dcrec/secp256k1/v4 v4.0.1 // indirect + github.com/deckarep/golang-set/v2 v2.3.1 // indirect + github.com/decred/dcrd/dcrec/secp256k1/v4 v4.2.0 // indirect github.com/dgryski/go-rendezvous v0.0.0-20200823014737-9f7001d12a5f // indirect - github.com/ethereum/c-kzg-4844 v0.3.0 // indirect - github.com/getsentry/sentry-go v0.18.0 // indirect - github.com/go-ole/go-ole v1.2.6 // indirect + github.com/ethereum/c-kzg-4844 v0.4.0 // indirect + github.com/getsentry/sentry-go v0.25.0 // indirect + github.com/go-ole/go-ole v1.3.0 // indirect github.com/go-stack/stack v1.8.1 // indirect github.com/gofrs/flock v0.8.1 // indirect github.com/gogo/protobuf v1.3.2 // indirect - github.com/golang/protobuf v1.5.2 // indirect github.com/gomodule/redigo v1.8.9 // indirect github.com/hashicorp/errwrap v1.1.0 // indirect github.com/hashicorp/go-multierror v1.1.1 // indirect github.com/holiman/bloomfilter/v2 v2.0.3 // indirect github.com/holiman/uint256 v1.2.3 // indirect - github.com/klauspost/compress v1.15.15 // indirect + github.com/klauspost/compress v1.17.1 // indirect github.com/kr/pretty v0.3.1 // indirect github.com/kr/text v0.2.0 // indirect - github.com/mattn/go-runewidth v0.0.13 // indirect - github.com/matttproud/golang_protobuf_extensions v1.0.4 // indirect + github.com/mattn/go-runewidth v0.0.15 // indirect + github.com/matttproud/golang_protobuf_extensions/v2 v2.0.0 // indirect github.com/mmcloughlin/addchain v0.4.0 // indirect github.com/olekukonko/tablewriter v0.0.5 // indirect github.com/pmezard/go-difflib v1.0.0 // indirect - github.com/prometheus/client_model v0.3.0 // indirect - github.com/prometheus/common v0.39.0 // indirect - github.com/prometheus/procfs v0.9.0 // indirect - github.com/rivo/uniseg v0.2.0 // indirect - github.com/rogpeppe/go-internal v1.9.0 // indirect + github.com/prometheus/client_model v0.5.0 // indirect + github.com/prometheus/common v0.45.0 // indirect + github.com/prometheus/procfs v0.12.0 // indirect + github.com/rivo/uniseg v0.4.4 // indirect + github.com/rogpeppe/go-internal v1.11.0 // indirect github.com/shirou/gopsutil v3.21.11+incompatible // indirect github.com/supranational/blst v0.3.11 // indirect - github.com/tklauser/go-sysconf v0.3.10 // indirect - github.com/tklauser/numcpus v0.4.0 // indirect - github.com/yuin/gopher-lua v0.0.0-20210529063254-f4c35e4016d9 // indirect - github.com/yusufpapurcu/wmi v1.2.2 // indirect - golang.org/x/crypto v0.10.0 // indirect - golang.org/x/exp v0.0.0-20230515195305-f3d0a9c9a5cc // indirect - golang.org/x/sys v0.9.0 // indirect - golang.org/x/text v0.10.0 // indirect - google.golang.org/protobuf v1.28.1 // indirect - gopkg.in/natefinch/npipe.v2 v2.0.0-20160621034901-c1b8fa8bdcce // indirect + github.com/tklauser/go-sysconf v0.3.12 // indirect + github.com/tklauser/numcpus v0.6.1 // indirect + github.com/yuin/gopher-lua v1.1.0 // indirect + github.com/yusufpapurcu/wmi v1.2.3 // indirect + golang.org/x/crypto v0.14.0 // indirect + golang.org/x/exp v0.0.0-20231006140011-7918f672742d // indirect + golang.org/x/mod v0.13.0 // indirect + golang.org/x/sys v0.13.0 // indirect + golang.org/x/text v0.13.0 // indirect + golang.org/x/tools v0.14.0 // indirect + google.golang.org/protobuf v1.31.0 // indirect rsc.io/tmplfunc v0.0.3 // indirect ) diff --git a/proxyd/go.sum b/proxyd/go.sum index f709e088f40da..b6621d659e996 100644 --- a/proxyd/go.sum +++ b/proxyd/go.sum @@ -1,179 +1,114 @@ -cloud.google.com/go v0.26.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw= -github.com/AndreasBriese/bbloom v0.0.0-20190306092124-e2d15f34fcf9/go.mod h1:bOvUY6CB00SOBii9/FifXqc0awNKxLFCL/+pkDPuyl8= -github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= -github.com/BurntSushi/toml v1.2.0 h1:Rt8g24XnyGTyglgET/PRUNlrUeu9F5L+7FilkXfZgs0= -github.com/BurntSushi/toml v1.2.0/go.mod h1:CxXYINrC8qIiEnFrOxCa7Jy5BFHlXnUU2pbicEuybxQ= -github.com/CloudyKit/fastprinter v0.0.0-20200109182630-33d98a066a53/go.mod h1:+3IMCy2vIlbG1XG/0ggNQv0SvxCAIpPM5b1nCz56Xno= -github.com/CloudyKit/jet/v3 v3.0.0/go.mod h1:HKQPgSJmdK8hdoAbKUUWajkHyHo4RaU5rMdUywE7VMo= -github.com/DataDog/zstd v1.5.2 h1:vUG4lAyuPCXO0TLbXvPv7EB7cNK1QV/luu55UHLrrn8= -github.com/DataDog/zstd v1.5.2/go.mod h1:g4AWEaM3yOg3HYfnJ3YIawPnVdXJh9QME85blwSAmyw= -github.com/Joker/hpp v1.0.0/go.mod h1:8x5n+M1Hp5hC0g8okX3sR3vFQwynaX/UgSOM9MeBKzY= -github.com/Shopify/goreferrer v0.0.0-20181106222321-ec9c9a553398/go.mod h1:a1uqRtAwp2Xwc6WNPJEufxJ7fx3npB4UV/JOLmbu5I0= -github.com/VictoriaMetrics/fastcache v1.9.0 h1:oMwsS6c8abz98B7ytAewQ7M1ZN/Im/iwKoE1euaFvhs= -github.com/VictoriaMetrics/fastcache v1.9.0/go.mod h1:otoTS3xu+6IzF/qByjqzjp3rTuzM3Qf0ScU1UTj97iU= -github.com/ajg/form v1.5.1/go.mod h1:uL1WgH+h2mgNtvBq0339dVnzXdBETtL2LeUXaIv25UY= -github.com/alicebob/gopher-json v0.0.0-20200520072559-a9ecdc9d1d3a h1:HbKu58rmZpUGpz5+4FfNmIU+FmZg2P3Xaj2v2bfNWmk= -github.com/alicebob/gopher-json v0.0.0-20200520072559-a9ecdc9d1d3a/go.mod h1:SGnFV6hVsYE877CKEZ6tDNTjaSXYUk6QqoIK6PrAtcc= +github.com/BurntSushi/toml v1.3.2 h1:o7IhLm0Msx3BaB+n3Ag7L8EVlByGnpq14C4YWiu/gL8= +github.com/BurntSushi/toml v1.3.2/go.mod h1:CxXYINrC8qIiEnFrOxCa7Jy5BFHlXnUU2pbicEuybxQ= +github.com/DataDog/zstd v1.5.5 h1:oWf5W7GtOLgp6bciQYDmhHHjdhYkALu6S/5Ni9ZgSvQ= +github.com/DataDog/zstd v1.5.5/go.mod h1:g4AWEaM3yOg3HYfnJ3YIawPnVdXJh9QME85blwSAmyw= +github.com/Microsoft/go-winio v0.6.1 h1:9/kr64B9VUZrLm5YYwbGtUJnMgqWVOdUAXu6Migciow= +github.com/Microsoft/go-winio v0.6.1/go.mod h1:LRdKpFKfdobln8UmuiYcKPot9D2v6svN5+sAH+4kjUM= +github.com/VictoriaMetrics/fastcache v1.12.1 h1:i0mICQuojGDL3KblA7wUNlY5lOK6a4bwt3uRKnkZU40= +github.com/VictoriaMetrics/fastcache v1.12.1/go.mod h1:tX04vaqcNoQeGLD+ra5pU5sWkuxnzWhEzLwhP9w653o= +github.com/alicebob/gopher-json v0.0.0-20230218143504-906a9b012302 h1:uvdUDbHQHO85qeSydJtItA4T55Pw6BtAejd0APRJOCE= +github.com/alicebob/gopher-json v0.0.0-20230218143504-906a9b012302/go.mod h1:SGnFV6hVsYE877CKEZ6tDNTjaSXYUk6QqoIK6PrAtcc= github.com/alicebob/miniredis v2.5.0+incompatible h1:yBHoLpsyjupjz3NL3MhKMVkR41j82Yjf3KFv7ApYzUI= github.com/alicebob/miniredis v2.5.0+incompatible/go.mod h1:8HZjEj4yU0dwhYHky+DxYx+6BMjkBbe5ONFIF1MXffk= github.com/allegro/bigcache v1.2.1-0.20190218064605-e24eb225f156 h1:eMwmnE/GDgah4HI848JfFxHt+iPb26b4zyfspmqY0/8= github.com/allegro/bigcache v1.2.1-0.20190218064605-e24eb225f156/go.mod h1:Cb/ax3seSYIx7SuZdm2G2xzfwmv3TPSk2ucNfQESPXM= -github.com/armon/consul-api v0.0.0-20180202201655-eb2c6b5be1b6/go.mod h1:grANhF5doyWs3UAsr3K4I6qtAmlQcZDesFNEHPZAzj8= -github.com/aymerick/raymond v2.0.3-0.20180322193309-b565731e1464+incompatible/go.mod h1:osfaiScAUVup+UC9Nfq76eWqDhXlp+4UYaA8uhTBO6g= github.com/beorn7/perks v1.0.1 h1:VlbKKnNfV8bJzeqoa4cOKqO6bYr3WgKZxO8Z16+hsOM= github.com/beorn7/perks v1.0.1/go.mod h1:G2ZrVWU2WbWT9wwq4/hrbKbnv/1ERSJQ0ibhJ6rlkpw= -github.com/bits-and-blooms/bitset v1.7.0 h1:YjAGVd3XmtK9ktAbX8Zg2g2PwLIMjGREZJHlV4j7NEo= -github.com/bits-and-blooms/bitset v1.7.0/go.mod h1:gIdJ4wp64HaoK2YrL1Q5/N7Y16edYb8uY+O0FJTyyDA= -github.com/bsm/ginkgo/v2 v2.5.0/go.mod h1:AiKlXPm7ItEHNc/2+OkrNG4E0ITzojb9/xWzvQ9XZ9w= -github.com/bsm/ginkgo/v2 v2.9.5 h1:rtVBYPs3+TC5iLUVOis1B9tjLTup7Cj5IfzosKtvTJ0= -github.com/bsm/gomega v1.20.0/go.mod h1:JifAceMQ4crZIWYUKrlGcmbN3bqHogVTADMD2ATsbwk= -github.com/bsm/gomega v1.26.0 h1:LhQm+AFcgV2M0WyKroMASzAzCAJVpAxQXv4SaI9a69Y= -github.com/btcsuite/btcd/btcec/v2 v2.2.0 h1:fzn1qaOt32TuLjFlkzYSsBC35Q3KUjT1SwPxiMSCF5k= -github.com/btcsuite/btcd/btcec/v2 v2.2.0/go.mod h1:U7MHm051Al6XmscBQ0BoNydpOTsFAn707034b5nY8zU= +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/bsm/ginkgo/v2 v2.12.0 h1:Ny8MWAHyOepLGlLKYmXG4IEkioBysk6GpaRTLC8zwWs= +github.com/bsm/ginkgo/v2 v2.12.0/go.mod h1:SwYbGRRDovPVboqFv0tPTcG1sN61LM1Z4ARdbAV9g4c= +github.com/bsm/gomega v1.27.10 h1:yeMWxP2pV2fG3FgAODIY8EiRE3dy0aeFYt4l7wh6yKA= +github.com/bsm/gomega v1.27.10/go.mod h1:JyEr/xRbxbtgWNi8tIEVPUYZ5Dzef52k01W3YH0H+O0= +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/chaincfg/chainhash v1.0.1 h1:q0rUy8C/TYNBQS1+CGKw68tLOFYSNEs0TFnxxnS9+4U= -github.com/census-instrumentation/opencensus-proto v0.2.1/go.mod h1:f6KPmirojxKA12rnyqOA5BBL4O983OfeGPqjHWSTneU= -github.com/cespare/xxhash/v2 v2.1.2/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= +github.com/btcsuite/btcd/chaincfg/chainhash v1.0.1/go.mod h1:7SFka0XMvUgj3hfZtydOrQY2mwhPclbT2snogU7SQQc= github.com/cespare/xxhash/v2 v2.2.0 h1:DC2CZ1Ep5Y4k3ZQ899DldepgrayRUGE6BBZ/cd9Cj44= github.com/cespare/xxhash/v2 v2.2.0/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= -github.com/chzyer/logex v1.1.10/go.mod h1:+Ywpsq7O8HXn0nuIou7OrIPyXbp3wmkHB+jjWRnGsAI= -github.com/chzyer/readline v0.0.0-20180603132655-2972be24d48e/go.mod h1:nSuG5e5PlCu98SY8svDHJxuZscDgtXS6KTTbou5AhLI= -github.com/chzyer/test v0.0.0-20180213035817-a1ea475d72b1/go.mod h1:Q3SI9o4m/ZMnBNeIyt5eFwwo7qiLfzFZmjNmxjkiQlU= -github.com/client9/misspell v0.3.4/go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDkc90ppPyw= -github.com/cncf/udpa/go v0.0.0-20201120205902-5459f2c99403/go.mod h1:WmhPx2Nbnhtbo57+VJT5O0JRkEi1Wbu0z5j0R8u5Hbk= -github.com/cockroachdb/datadriven v1.0.2 h1:H9MtNqVoVhvd9nCBwOyDjUEdZCREqbIdCJD93PBm/jA= -github.com/cockroachdb/datadriven v1.0.2/go.mod h1:a9RdTaap04u637JoCzcUoIcDmvwSUtcUFtT/C3kJlTU= -github.com/cockroachdb/errors v1.9.1 h1:yFVvsI0VxmRShfawbt/laCIDy/mtTqqnvoNgiy5bEV8= -github.com/cockroachdb/errors v1.9.1/go.mod h1:2sxOtL2WIc096WSZqZ5h8fa17rdDq9HZOZLBCor4mBk= -github.com/cockroachdb/logtags v0.0.0-20211118104740-dabe8e521a4f/go.mod h1:Vz9DsVWQQhf3vs21MhPMZpMGSht7O/2vFW2xusFUVOs= +github.com/cockroachdb/datadriven v1.0.3-0.20230413201302-be42291fc80f h1:otljaYPt5hWxV3MUfO5dFPFiOXg9CyG5/kCfayTqsJ4= +github.com/cockroachdb/datadriven v1.0.3-0.20230413201302-be42291fc80f/go.mod h1:a9RdTaap04u637JoCzcUoIcDmvwSUtcUFtT/C3kJlTU= +github.com/cockroachdb/errors v1.11.1 h1:xSEW75zKaKCWzR3OfxXUxgrk/NtT4G1MiOv5lWZazG8= +github.com/cockroachdb/errors v1.11.1/go.mod h1:8MUxA3Gi6b25tYlFEBGLf+D8aISL+M4MIpiWMSNRfxw= 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-20230209160836-829675f94811 h1:ytcWPaNPhNoGMWEhDvS3zToKcDpRsLuRolQJBVGdozk= -github.com/cockroachdb/pebble v0.0.0-20230209160836-829675f94811/go.mod h1:Nb5lgvnQ2+oGlE/EyZy4+2/CxRh9KfvCXnag1vtpxVM= -github.com/cockroachdb/redact v1.1.3 h1:AKZds10rFSIj7qADf0g46UixK8NNLwWTNdCIGS5wfSQ= -github.com/cockroachdb/redact v1.1.3/go.mod h1:BVNblN9mBWFyMyqK1k3AAiSxhvhfK2oOZZ2lK+dpvRg= -github.com/codegangsta/inject v0.0.0-20150114235600-33e0aa1cb7c0/go.mod h1:4Zcjuz89kmFXt9morQgcfYZAYZ5n8WHjt81YYWIwtTM= +github.com/cockroachdb/pebble v0.0.0-20231020221949-babd592d2360 h1:x1dzGu9e1FYmkG8mL9emtdWD1EzH/17SijnoLvKvPiM= +github.com/cockroachdb/pebble v0.0.0-20231020221949-babd592d2360/go.mod h1:sEHm5NOXxyiAoKWhoFxT8xMgd/f3RA6qUqQ1BXKrh2E= +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= +github.com/cockroachdb/tokenbucket v0.0.0-20230807174530-cc333fc44b06/go.mod h1:7nc4anLGjupUW/PeY5qiNYsdNXj7zopG+eqsS7To5IQ= github.com/consensys/bavard v0.1.13 h1:oLhMLOFGTLdlda/kma4VOJazblc7IM5y5QPd2A/YjhQ= github.com/consensys/bavard v0.1.13/go.mod h1:9ItSMtA/dXMAiL7BG6bqW2m3NdSEObYWoH223nGHukI= -github.com/consensys/gnark-crypto v0.12.0 h1:1OnSpOykNkUIBIBJKdhwy2p0JlW5o+Az02ICzZmvvdg= -github.com/consensys/gnark-crypto v0.12.0/go.mod h1:v2Gy7L/4ZRosZ7Ivs+9SfUDr0f5UlG+EM5t7MPHiLuY= -github.com/coreos/etcd v3.3.10+incompatible/go.mod h1:uF7uidLiAD3TWHmW31ZFd/JWoc32PjwdhPthX9715RE= -github.com/coreos/go-etcd v2.0.0+incompatible/go.mod h1:Jez6KQU2B/sWsbdaef3ED8NzMklzPG4d5KIOhIy30Tk= -github.com/coreos/go-semver v0.2.0/go.mod h1:nnelYz7RCh+5ahJtPPxZlU+153eP4D4r3EedlOD2RNk= -github.com/cpuguy83/go-md2man v1.0.10/go.mod h1:SmD6nW6nTyfqj6ABTjUi3V3JVMnlJmwcJI5acqYI6dE= -github.com/crate-crypto/go-kzg-4844 v0.3.0 h1:UBlWE0CgyFqqzTI+IFyCzA7A3Zw4iip6uzRv5NIXG0A= -github.com/crate-crypto/go-kzg-4844 v0.3.0/go.mod h1:SBP7ikXEgDnUPONgm33HtuDZEDtWa3L4QtN1ocJSEQ4= +github.com/consensys/gnark-crypto v0.12.1 h1:lHH39WuuFgVHONRl3J0LRBtuYdQTumFSDtJF7HpyG8M= +github.com/consensys/gnark-crypto v0.12.1/go.mod h1:v2Gy7L/4ZRosZ7Ivs+9SfUDr0f5UlG+EM5t7MPHiLuY= +github.com/crate-crypto/go-kzg-4844 v0.7.0 h1:C0vgZRk4q4EZ/JgPfzuSoxdCq3C3mOZMBShovmncxvA= +github.com/crate-crypto/go-kzg-4844 v0.7.0/go.mod h1:1kMhvPgI0Ky3yIa+9lFySEBUBXkYxeOi8ZF1sYioxhc= github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c= github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= -github.com/deckarep/golang-set/v2 v2.1.0 h1:g47V4Or+DUdzbs8FxCCmgb6VYd+ptPAngjM6dtGktsI= -github.com/deckarep/golang-set/v2 v2.1.0/go.mod h1:VAky9rY/yGXJOLEDv3OMci+7wtDpOF4IN+y82NBOac4= -github.com/decred/dcrd/crypto/blake256 v1.0.0 h1:/8DMNYp9SGi5f0w7uCm6d6M4OU2rGFK09Y2A4Xv7EE0= -github.com/decred/dcrd/crypto/blake256 v1.0.0/go.mod h1:sQl2p6Y26YV+ZOcSTP6thNdn47hh8kt6rqSlvmrXFAc= -github.com/decred/dcrd/dcrec/secp256k1/v4 v4.0.1 h1:YLtO71vCjJRCBcrPMtQ9nqBsqpA1m5sE92cU+pd5Mcc= -github.com/decred/dcrd/dcrec/secp256k1/v4 v4.0.1/go.mod h1:hyedUtir6IdtD/7lIxGeCxkaw7y45JueMRL4DIyJDKs= -github.com/dgraph-io/badger v1.6.0/go.mod h1:zwt7syl517jmP8s94KqSxTlM6IMsdhYy6psNgSztDR4= -github.com/dgryski/go-farm v0.0.0-20190423205320-6a90982ecee2/go.mod h1:SqUrOPUnsFjfmXRMNPybcSiG0BgUW2AuFH8PAnS2iTw= +github.com/deckarep/golang-set/v2 v2.3.1 h1:vjmkvJt/IV27WXPyYQpAh4bRyWJc5Y435D17XQ9QU5A= +github.com/deckarep/golang-set/v2 v2.3.1/go.mod h1:VAky9rY/yGXJOLEDv3OMci+7wtDpOF4IN+y82NBOac4= +github.com/decred/dcrd/crypto/blake256 v1.0.1 h1:7PltbUIQB7u/FfZ39+DGa/ShuMyJ5ilcvdfma9wOH6Y= +github.com/decred/dcrd/crypto/blake256 v1.0.1/go.mod h1:2OfgNZ5wDpcsFmHmCK5gZTPcCXqlm2ArzUIkw9czNJo= +github.com/decred/dcrd/dcrec/secp256k1/v4 v4.2.0 h1:8UrgZ3GkP4i/CLijOJx79Yu+etlyjdBU4sfcs2WYQMs= +github.com/decred/dcrd/dcrec/secp256k1/v4 v4.2.0/go.mod h1:v57UDF4pDQJcEfFUCRop3lJL149eHGSe9Jvczhzjo/0= github.com/dgryski/go-rendezvous v0.0.0-20200823014737-9f7001d12a5f h1:lO4WD4F/rVNCu3HqELle0jiPLLBs70cWOduZpkS1E78= github.com/dgryski/go-rendezvous v0.0.0-20200823014737-9f7001d12a5f/go.mod h1:cuUVRXasLTGF7a8hSLbxyZXjz+1KgoB3wDUb6vlszIc= -github.com/dustin/go-humanize v1.0.0/go.mod h1:HtrtbFcZ19U5GC7JDqmcUSB87Iq5E25KnS6fMYU6eOk= -github.com/eknkc/amber v0.0.0-20171010120322-cdade1c07385/go.mod h1:0vRUJqYpeSZifjYj7uP3BG/gKcuzL9xWVV/Y+cK33KM= github.com/emirpasic/gods v1.18.1 h1:FXtiHYKDGKCW2KzwZKx0iC0PQmdlorYgdFG9jPXJ1Bc= github.com/emirpasic/gods v1.18.1/go.mod h1:8tpGGwCnJ5H4r6BWwaV6OrWmMoPhUl5jm/FMNAnJvWQ= -github.com/envoyproxy/go-control-plane v0.9.0/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4= -github.com/envoyproxy/go-control-plane v0.9.1-0.20191026205805-5f8ba28d4473/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4= -github.com/envoyproxy/go-control-plane v0.9.9-0.20210217033140-668b12f5399d/go.mod h1:cXg6YxExXjJnVBQHBLXeUAgxn2UodCpnH306RInaBQk= -github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c= -github.com/etcd-io/bbolt v1.3.3/go.mod h1:ZF2nL25h33cCyBtcyWeZ2/I3HQOfTP+0PIEvHjkjCrw= -github.com/ethereum/c-kzg-4844 v0.3.0 h1:3Y3hD6l5i0dEYsBL50C+Om644kve3pNqoAcvE26o9zI= -github.com/ethereum/c-kzg-4844 v0.3.0/go.mod h1:WI2Nd82DMZAAZI1wV2neKGost9EKjvbpQR9OqE5Qqa8= -github.com/ethereum/go-ethereum v1.12.1 h1:1kXDPxhLfyySuQYIfRxVBGYuaHdxNNxevA73vjIwsgk= -github.com/ethereum/go-ethereum v1.12.1/go.mod h1:zKetLweqBR8ZS+1O9iJWI8DvmmD2NzD19apjEWDCsnw= -github.com/fasthttp-contrib/websocket v0.0.0-20160511215533-1f3b11f56072/go.mod h1:duJ4Jxv5lDcvg4QuQr0oowTf7dz4/CR8NtyCooz9HL8= -github.com/fatih/structs v1.1.0/go.mod h1:9NiDSp5zOcgEDl+j00MP/WkGVPOlPRLejGD8Ga6PJ7M= +github.com/ethereum/c-kzg-4844 v0.4.0 h1:3MS1s4JtA868KpJxroZoepdV0ZKBp3u/O5HcZ7R3nlY= +github.com/ethereum/c-kzg-4844 v0.4.0/go.mod h1:VewdlzQmpT5QSrVhbBuGoCdFJkpaJlO1aQputP83wc0= +github.com/ethereum/go-ethereum v1.13.4 h1:25HJnaWVg3q1O7Z62LaaI6S9wVq8QCw3K88g8wEzrcM= +github.com/ethereum/go-ethereum v1.13.4/go.mod h1:I0U5VewuuTzvBtVzKo7b3hJzDhXOUtn9mJW7SsIPB0Q= 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.6.0 h1:n+5WquG0fcWoWp6xPWfHdbskMCQaFnG6PfBrh1Ky4HY= -github.com/gavv/httpexpect v2.0.0+incompatible/go.mod h1:x+9tiU1YnrOvnB725RkpoLv1M62hOWzwo5OXotisrKc= -github.com/getsentry/sentry-go v0.12.0/go.mod h1:NSap0JBYWzHND8oMbyi0+XZhUalc1TBdRL1M71JZW2c= -github.com/getsentry/sentry-go v0.18.0 h1:MtBW5H9QgdcJabtZcuJG80BMOwaBpkRDZkxRkNC1sN0= -github.com/getsentry/sentry-go v0.18.0/go.mod h1:Kgon4Mby+FJ7ZWHFUAZgVaIa8sxHtnRJRLTXZr51aKQ= -github.com/gin-contrib/sse v0.0.0-20190301062529-5545eab6dad3/go.mod h1:VJ0WA2NBN22VlZ2dKZQPAPnyWw5XTlK1KymzLKsr59s= -github.com/gin-gonic/gin v1.4.0/go.mod h1:OW2EZn3DO8Ln9oIKOvM++LBO+5UPHJJDH72/q/3rZdM= -github.com/go-check/check v0.0.0-20180628173108-788fd7840127/go.mod h1:9ES+weclKsC9YodN5RgxqK/VD9HM9JsCSh7rNhMZE98= -github.com/go-errors/errors v1.0.1/go.mod h1:f4zRHt4oKfwPJE5k8C9vpYG+aDHdBFUsgrm6/TyX73Q= +github.com/fsnotify/fsnotify v1.6.0/go.mod h1:sl3t1tCWJFWoRz9R8WJCbQihKKwmorjAbSClcnxKAGw= +github.com/getsentry/sentry-go v0.25.0 h1:q6Eo+hS+yoJlTO3uu/azhQadsD8V+jQn2D8VvX1eOyI= +github.com/getsentry/sentry-go v0.25.0/go.mod h1:lc76E2QywIyW8WuBnwl8Lc4bkmQH4+w1gwTf25trprY= github.com/go-errors/errors v1.4.2 h1:J6MZopCL4uSllY1OfXM374weqZFFItUbrImctkmUxIA= -github.com/go-logr/logr v1.2.2/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A= -github.com/go-logr/logr v1.2.3/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A= -github.com/go-logr/stdr v1.2.2/go.mod h1:mMo/vtBO5dYbehREoey6XUKy/eSumjCCveDpRre4VKE= -github.com/go-martini/martini v0.0.0-20170121215854-22fa46961aab/go.mod h1:/P9AEU963A2AYjv4d1V5eVL1CQbEJq6aCNHDDjibzu8= -github.com/go-ole/go-ole v1.2.6 h1:/Fpf6oFPoeFik9ty7siob0G6Ke8QvQEuVcuChpwXzpY= +github.com/go-errors/errors v1.4.2/go.mod h1:sIVyrIiJhuEF+Pj9Ebtd6P/rEYROXFi3BopGUQ5a5Og= github.com/go-ole/go-ole v1.2.6/go.mod h1:pprOEPIfldk/42T2oK7lQ4v4JSDwmV0As9GaiUsvbm0= +github.com/go-ole/go-ole v1.3.0 h1:Dt6ye7+vXGIKZ7Xtk4s6/xVdGDQynvom7xCFEdWr6uE= +github.com/go-ole/go-ole v1.3.0/go.mod h1:5LS6F96DhAwUc7C+1HLexzMXY1xGRSryjyPPKW6zv78= github.com/go-redis/redis v6.15.9+incompatible h1:K0pv1D7EQUjfyoMql+r/jZqCLizCGKFlFgcHWWmHQjg= github.com/go-redis/redis v6.15.9+incompatible/go.mod h1:NAIEuMOZ/fxfXJIrKDQDz8wamY7mA7PouImQ2Jvg6kA= github.com/go-redis/redis/v7 v7.4.0 h1:7obg6wUoj05T0EpY0o8B59S9w5yeMWql7sw2kwNW1x4= github.com/go-redis/redis/v7 v7.4.0/go.mod h1:JDNMw23GTyLNC4GZu9njt15ctBQVn7xjRfnwdHj/Dcg= github.com/go-redis/redis/v8 v8.11.4 h1:kHoYkfZP6+pe04aFTnhDH6GDROa5yJdHJVNxV3F46Tg= github.com/go-redis/redis/v8 v8.11.4/go.mod h1:2Z2wHZXdQpCDXEGzqMockDpNyYvi2l4Pxt6RJr792+w= -github.com/go-redsync/redsync/v4 v4.9.4 h1:vRmYusI+qF95XSpApHAdeu+RjyDvxBXbMthbc/x148c= -github.com/go-redsync/redsync/v4 v4.9.4/go.mod h1:RqBDXUw0q+u9FJTeD2gMzGtHeSVV93DiqGl10B9Hn/4= +github.com/go-redsync/redsync/v4 v4.10.0 h1:hTeAak4C73mNBQSTq6KCKDFaiIlfC+z5yTTl8fCJuBs= +github.com/go-redsync/redsync/v4 v4.10.0/go.mod h1:ZfayzutkgeBmEmBlUR3j+rF6kN44UUGtEdfzhBFZTPc= github.com/go-stack/stack v1.8.1 h1:ntEHSVwIt7PNXNpgPmVfMrNhLtgjlmnZha2kOpuRiDw= github.com/go-stack/stack v1.8.1/go.mod h1:dcoOX6HbPZSZptuspn9bctJ+N/CnF5gGygcUP3XYfe4= -github.com/go-task/slim-sprig v0.0.0-20210107165309-348f09dbbbc0/go.mod h1:fyg7847qk6SyHyPtNmDHnmrv/HOrqktSC+C9fM+CJOE= -github.com/gobwas/httphead v0.0.0-20180130184737-2c6c146eadee/go.mod h1:L0fX3K22YWvt/FAX9NnzrNzcI4wNYi9Yku4O0LKYflo= -github.com/gobwas/pool v0.2.0/go.mod h1:q8bcK0KcYlCgd9e7WYLm9LpyS+YeLd8JVDW6WezmKEw= -github.com/gobwas/ws v1.0.2/go.mod h1:szmBTxLgaFppYjEmNtny/v3w89xOydFnnZMcgRRu/EM= github.com/gofrs/flock v0.8.1 h1:+gYjHKf32LDeiEEFhQaotPbLuUXjY5ZqxKgXy7n59aw= github.com/gofrs/flock v0.8.1/go.mod h1:F1TvTiK9OcQqauNUHlbJvyl9Qa1QvF/gOUDKA14jxHU= -github.com/gogo/googleapis v0.0.0-20180223154316-0cd9801be74a/go.mod h1:gf4bu3Q80BeJ6H1S1vYPm8/ELATdvryBaNFGgqEef3s= -github.com/gogo/googleapis v1.4.1/go.mod h1:2lpHqI5OcWCtVElxXnPt+s8oJvMpySlOyM6xDCrzib4= -github.com/gogo/protobuf v1.2.0/go.mod h1:r8qH/GZQm5c6nD/R0oafs1akxWv10x8SbQlK7atdtwQ= github.com/gogo/protobuf v1.3.2 h1:Ov1cvc58UF3b5XjBnZv7+opcTcQFZebYjWzi34vdm4Q= github.com/gogo/protobuf v1.3.2/go.mod h1:P1XiOD3dCwIKUDQYPy72D8LYyHL2YPYrpS2s69NZV8Q= -github.com/gogo/status v1.1.0/go.mod h1:BFv9nrluPLmrS0EmGVvLaPNmRosr9KapBYd5/hpY1WM= -github.com/golang-jwt/jwt v3.2.2+incompatible/go.mod h1:8pz2t5EyA70fFQQSrl6XZXzqecmYZeUEB8OUGHkxJ+I= -github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q= -github.com/golang/mock v1.1.1/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A= -github.com/golang/mock v1.6.0/go.mod h1:p6yTPP+5HYm5mzsMV8JkE6ZKdX+/wYM6Hr+LicevLPs= github.com/golang/protobuf v1.2.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= -github.com/golang/protobuf v1.3.1/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= -github.com/golang/protobuf v1.3.2/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= -github.com/golang/protobuf v1.3.5/go.mod h1:6O5/vntMXwX2lRkT1hjjk0nAC1IDOTvTlVgjlRvqsdk= github.com/golang/protobuf v1.4.0-rc.1/go.mod h1:ceaxUfeHdC40wWswd/P6IGgMaK3YpKi5j83Wpe3EHw8= github.com/golang/protobuf v1.4.0-rc.1.0.20200221234624-67d41d38c208/go.mod h1:xKAWHe0F5eneWXFV3EuXVDTCmh+JuBKY0li0aMyXATA= github.com/golang/protobuf v1.4.0-rc.2/go.mod h1:LlEzMj4AhA7rCAGe4KMBDvJI+AwstrUpVNzEA03Pprs= github.com/golang/protobuf v1.4.0-rc.4.0.20200313231945-b860323f09d0/go.mod h1:WU3c8KckQ9AFe+yFwt9sWVRKCVIyN9cPHBJSNnbL67w= github.com/golang/protobuf v1.4.0/go.mod h1:jodUvKwWbYaEsadDk5Fwe5c77LiNKVO9IDvqG2KuDX0= -github.com/golang/protobuf v1.4.1/go.mod h1:U8fpvMrcmy5pZrNK1lt4xCsGvpyWQ/VVv6QDs8UjoX8= github.com/golang/protobuf v1.4.2/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI= github.com/golang/protobuf v1.5.0/go.mod h1:FsONVRAS9T7sI+LIUmWTfcYkHO4aIWwzhcaSAoJOfIk= -github.com/golang/protobuf v1.5.2 h1:ROPKBNFfQgOUMifHyP+KYbvpjbdoFNs+aK7DXlji0Tw= -github.com/golang/protobuf v1.5.2/go.mod h1:XVQd3VNwM+JqD3oG2Ue2ip4fOMUkwXdXDdiuN0vRsmY= github.com/golang/snappy v0.0.4/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= github.com/golang/snappy v0.0.5-0.20220116011046-fa5810519dcb h1:PBC98N2aIaM3XXiurYmW7fx4GZkL8feAMVq7nEjURHk= github.com/golang/snappy v0.0.5-0.20220116011046-fa5810519dcb/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= -github.com/gomodule/redigo v1.7.1-0.20190724094224-574c33c3df38/go.mod h1:B4C85qUVwatsJoIUNIfCRsp7qO0iAmpGFZ4EELWSbC4= github.com/gomodule/redigo v1.8.9 h1:Sl3u+2BI/kk+VEatbj0scLdrFhjPmbxOc1myhDP41ws= github.com/gomodule/redigo v1.8.9/go.mod h1:7ArFNvsTjH8GMMzB4uy1snslv2BwmginuMs06a1uzZE= -github.com/google/go-cmp v0.2.0/go.mod h1:oXzfMopK8JAjlY9xF4vHSVASa0yLyX7SntLO5aqRK0M= github.com/google/go-cmp v0.3.0/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU= github.com/google/go-cmp v0.3.1/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU= github.com/google/go-cmp v0.4.0/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= -github.com/google/go-cmp v0.5.0/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.5.5/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= -github.com/google/go-cmp v0.5.6/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= -github.com/google/go-cmp v0.5.8/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= github.com/google/go-cmp v0.5.9 h1:O2Tfq5qg4qc4AmwVlvv0oLiVAGB7enBSJ2x2DqQFi38= github.com/google/go-cmp v0.5.9/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= -github.com/google/go-querystring v1.0.0/go.mod h1:odCYkC5MyYFN7vkCjXpyrEuKhc/BUO6wN/zVPAxq5ck= -github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= -github.com/google/pprof v0.0.0-20210407192527-94a9f03dee38/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= github.com/google/subcommands v1.2.0/go.mod h1:ZjhPrFU+Olkh9WazFPsl27BQ4UPiG37m3yTrtFlrHVk= -github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= -github.com/gopherjs/gopherjs v0.0.0-20181017120253-0766667cb4d1/go.mod h1:wJfORRmW1u3UXTncJ5qlYoELFm8eSnnEO6hX4iZ3EWY= github.com/gorilla/mux v1.8.0 h1:i40aqfkR1h2SlN9hojwV5ZA91wcXFOvkdNIeFDP5koI= github.com/gorilla/mux v1.8.0/go.mod h1:DVbg23sWSpFRCP0SfiEN6jmj59UnW/n46BH5rLB71So= -github.com/gorilla/websocket v1.4.1/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE= github.com/gorilla/websocket v1.5.0 h1:PPwGk2jz7EePpoHN/+ClbZu8SPxiqlu12wZP/3sWmnc= github.com/gorilla/websocket v1.5.0/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE= github.com/hashicorp/errwrap v1.0.0/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brvKWEqk/Jc4= @@ -181,434 +116,176 @@ github.com/hashicorp/errwrap v1.1.0 h1:OxrOeh75EUXMY8TBjag2fzXGZ40LB6IKw45YeGUDY github.com/hashicorp/errwrap v1.1.0/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brvKWEqk/Jc4= github.com/hashicorp/go-multierror v1.1.1 h1:H5DkEtf6CXdFp0N0Em5UCwQpXMWke8IA0+lD48awMYo= github.com/hashicorp/go-multierror v1.1.1/go.mod h1:iw975J/qwKPdAO1clOe2L8331t/9/fmwbPZ6JB6eMoM= -github.com/hashicorp/go-version v1.2.0/go.mod h1:fltr4n8CU8Ke44wwGCBoEymUuxUHl09ZGVZPK5anwXA= -github.com/hashicorp/golang-lru v0.5.5-0.20210104140557-80c98217689d h1:dg1dEPuWpEqDnvIw251EVy4zlP8gWbsGj4BsUKCRpYs= -github.com/hashicorp/golang-lru v0.5.5-0.20210104140557-80c98217689d/go.mod h1:iADmTwqILo4mZ8BN3D2Q6+9jd8WM5uGBxy+E8yxSoD4= -github.com/hashicorp/hcl v1.0.0/go.mod h1:E5yfLk+7swimpb2L/Alb/PJmXilQ/rhwaUYs4T20WEQ= +github.com/hashicorp/golang-lru v1.0.2 h1:dV3g9Z/unq5DpblPpw+Oqcv4dU/1omnb4Ok8iPY6p1c= +github.com/hashicorp/golang-lru v1.0.2/go.mod h1:iADmTwqILo4mZ8BN3D2Q6+9jd8WM5uGBxy+E8yxSoD4= github.com/holiman/bloomfilter/v2 v2.0.3 h1:73e0e/V0tCydx14a0SCYS/EWCxgwLZ18CZcZKVu0fao= github.com/holiman/bloomfilter/v2 v2.0.3/go.mod h1:zpoh+gs7qcpqrHr3dB55AMiJwo0iURXE7ZOP9L9hSkA= github.com/holiman/uint256 v1.2.3 h1:K8UWO1HUJpRMXBxbmaY1Y8IAMZC/RsKB+ArEnnK4l5o= github.com/holiman/uint256 v1.2.3/go.mod h1:SC8Ryt4n+UBbPbIBKaG9zbbDlp4jOru9xFZmPzLUTxw= github.com/hpcloud/tail v1.0.0/go.mod h1:ab1qPbhIpdTxEkNHXyeSf5vhxWSCs/tWer42PpOxQnU= -github.com/hydrogen18/memlistener v0.0.0-20200120041712-dcc25e7acd91/go.mod h1:qEIFzExnS6016fRpRfxrExeVn2gbClQA99gQhnIcdhE= -github.com/ianlancetaylor/demangle v0.0.0-20200824232613-28f6c0f3b639/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= -github.com/imkira/go-interpol v1.1.0/go.mod h1:z0h2/2T3XF8kyEPpRgJ3kmNv+C43p+I/CoI+jC3w2iA= -github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8= -github.com/iris-contrib/blackfriday v2.0.0+incompatible/go.mod h1:UzZ2bDEoaSGPbkg6SAB4att1aAwTmVIx/5gCVqeyUdI= -github.com/iris-contrib/go.uuid v2.0.0+incompatible/go.mod h1:iz2lgM/1UnEf1kP0L/+fafWORmlnuysV2EMP8MW+qe0= -github.com/iris-contrib/jade v1.1.3/go.mod h1:H/geBymxJhShH5kecoiOCSssPX7QWYH7UaeZTSWddIk= -github.com/iris-contrib/pongo2 v0.0.1/go.mod h1:Ssh+00+3GAZqSQb30AvBRNxBx7rf0GqwkjqxNd0u65g= -github.com/iris-contrib/schema v0.0.1/go.mod h1:urYA3uvUNG1TIIjOSCzHr9/LmbQo8LrOcOqfqxa4hXw= -github.com/json-iterator/go v1.1.6/go.mod h1:+SdeFBvtyEkXs7REEP0seUULqWtbJapLOCVDaaPEHmU= -github.com/json-iterator/go v1.1.9/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= -github.com/jtolds/gls v4.20.0+incompatible/go.mod h1:QJZ7F/aHp+rZTRtaJ1ow/lLfFfVYBRgL+9YlvaHOwJU= -github.com/k0kubun/colorstring v0.0.0-20150214042306-9440f1994b88/go.mod h1:3w7q1U84EfirKl04SVQ/s7nPm1ZPhiXd34z40TNz36k= -github.com/kataras/golog v0.0.10/go.mod h1:yJ8YKCmyL+nWjERB90Qwn+bdyBZsaQwU3bTVFgkFIp8= -github.com/kataras/iris/v12 v12.1.8/go.mod h1:LMYy4VlP67TQ3Zgriz8RE2h2kMZV2SgMYbq3UhfoFmE= -github.com/kataras/neffos v0.0.14/go.mod h1:8lqADm8PnbeFfL7CLXh1WHw53dG27MC3pgi2R1rmoTE= -github.com/kataras/pio v0.0.2/go.mod h1:hAoW0t9UmXi4R5Oyq5Z4irTbaTsOemSrDGUtaTl7Dro= -github.com/kataras/sitemap v0.0.5/go.mod h1:KY2eugMKiPwsJgx7+U103YZehfvNGOXURubcGyk0Bz8= github.com/kisielk/errcheck v1.5.0/go.mod h1:pFxgyoBC7bSaBwPgfKdkLd5X25qrDl4LWUI2bnpBCr8= github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck= -github.com/klauspost/compress v1.8.2/go.mod h1:RyIbtBH6LamlWaDj8nUwkbUhJ87Yi3uG0guNDohfE1A= -github.com/klauspost/compress v1.9.7/go.mod h1:RyIbtBH6LamlWaDj8nUwkbUhJ87Yi3uG0guNDohfE1A= -github.com/klauspost/compress v1.15.15 h1:EF27CXIuDsYJ6mmvtBRlEuB2UVOqHG1tAXgZ7yIO+lw= -github.com/klauspost/compress v1.15.15/go.mod h1:ZcK2JAFqKOpnBlxcLsJzYfrS9X1akm9fHZNnD9+Vo/4= -github.com/klauspost/cpuid v1.2.1/go.mod h1:Pj4uuM528wm8OyEC2QMXAi2YiTZ96dNQPGgoMS4s3ek= -github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo= -github.com/kr/pretty v0.3.0/go.mod h1:640gp4NfQd8pI5XOwp5fnNeVWj67G7CFk/SaSQn7NBk= +github.com/klauspost/compress v1.17.1 h1:NE3C767s2ak2bweCZo3+rdP4U/HoyVXLv/X9f2gPS5g= +github.com/klauspost/compress v1.17.1/go.mod h1:ntbaceVETuRiXiv4DpjP66DpAtAGkEQskQzEyD//IeE= github.com/kr/pretty v0.3.1 h1:flRD4NNwYAUpkphVc1HcthR4KEIFJ65n8Mw5qdRn3LE= github.com/kr/pretty v0.3.1/go.mod h1:hoEshYVHaxMs3cyo3Yncou5ZscifuDolrwPKZanG3xk= -github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ= -github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI= github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY= github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE= github.com/kylelemons/godebug v1.1.0 h1:RPNrshWIDI6G2gRW9EHilWtl7Z6Sb1BR0xunSBf0SNc= -github.com/labstack/echo/v4 v4.5.0/go.mod h1:czIriw4a0C1dFun+ObrXp7ok03xON0N1awStJ6ArI7Y= -github.com/labstack/gommon v0.3.0/go.mod h1:MULnywXg0yavhxWKc+lOruYdAhDwPK9wf0OL7NoOu+k= +github.com/kylelemons/godebug v1.1.0/go.mod h1:9/0rRGxNHcop5bhtWyNeEfOS8JIWk580+fNqagV/RAw= github.com/leanovate/gopter v0.2.9 h1:fQjYxZaynp97ozCzfOyOuAGOU4aU/z37zf/tOujFk7c= -github.com/magiconair/properties v1.8.0/go.mod h1:PppfXfuXeibc/6YijjN8zIbojt8czPbwD3XqdrwzmxQ= -github.com/mattn/go-colorable v0.1.2/go.mod h1:U0ppj6V5qS13XJ6of8GYAs25YV2eR4EVcfRqFIhoBtE= -github.com/mattn/go-colorable v0.1.8/go.mod h1:u6P/XSegPjTcexA+o6vUJrdnUu04hMope9wVRipJSqc= -github.com/mattn/go-colorable v0.1.11/go.mod h1:u5H1YNBxpqRaxsYJYSkiCWKzEfiAb1Gb520KVy5xxl4= -github.com/mattn/go-isatty v0.0.7/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s= -github.com/mattn/go-isatty v0.0.8/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s= -github.com/mattn/go-isatty v0.0.9/go.mod h1:YNRxwqDuOph6SZLI9vUUz6OYw3QyUt7WiY2yME+cCiQ= -github.com/mattn/go-isatty v0.0.12/go.mod h1:cbi8OIDigv2wuxKPP5vlRcQ1OAZbq2CE4Kysco4FUpU= -github.com/mattn/go-isatty v0.0.14/go.mod h1:7GGIvUiUoEMVVmxf/4nioHXj79iQHKdU27kJ6hsGG94= +github.com/leanovate/gopter v0.2.9/go.mod h1:U2L/78B+KVFIx2VmW6onHJQzXtFb+p5y3y2Sh+Jxxv8= github.com/mattn/go-runewidth v0.0.9/go.mod h1:H031xJmbD/WCDINGzjvQ9THkh0rPKHF+m2gUSrubnMI= -github.com/mattn/go-runewidth v0.0.13 h1:lTGmDsbAYt5DmK6OnoV7EuIF1wEIFAcxld6ypU4OSgU= -github.com/mattn/go-runewidth v0.0.13/go.mod h1:Jdepj2loyihRzMpdS35Xk/zdY8IAYHsh153qUoGf23w= -github.com/mattn/goveralls v0.0.2/go.mod h1:8d1ZMHsd7fW6IRPKQh46F2WRpyib5/X4FOpevwGNQEw= -github.com/matttproud/golang_protobuf_extensions v1.0.4 h1:mmDVorXM7PCGKw94cs5zkfA9PSy5pEvNWRP0ET0TIVo= -github.com/matttproud/golang_protobuf_extensions v1.0.4/go.mod h1:BSXmuO+STAnVfrANrmjBb36TMTDstsz7MSK+HVaYKv4= -github.com/mediocregopher/radix/v3 v3.4.2/go.mod h1:8FL3F6UQRXHXIBSPUs5h0RybMF8i4n7wVopoX3x7Bv8= -github.com/microcosm-cc/bluemonday v1.0.2/go.mod h1:iVP4YcDBq+n/5fb23BhYFvIMq/leAFZyRl6bYmGDlGc= -github.com/mitchellh/go-homedir v1.1.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0= -github.com/mitchellh/mapstructure v1.1.2/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y= +github.com/mattn/go-runewidth v0.0.15 h1:UNAjwbU9l54TA3KzvqLGxwWjHmMgBUVhBiTjelZgg3U= +github.com/mattn/go-runewidth v0.0.15/go.mod h1:Jdepj2loyihRzMpdS35Xk/zdY8IAYHsh153qUoGf23w= +github.com/matttproud/golang_protobuf_extensions/v2 v2.0.0 h1:jWpvCLoY8Z/e3VKvlsiIGKtc+UG6U5vzxaoagmhXfyg= +github.com/matttproud/golang_protobuf_extensions/v2 v2.0.0/go.mod h1:QUyp042oQthUoa9bqDv0ER0wrtXnBruoNd7aNjkbP+k= github.com/mmcloughlin/addchain v0.4.0 h1:SobOdjm2xLj1KkXN5/n0xTIWyZA2+s99UCY1iPfkHRY= github.com/mmcloughlin/addchain v0.4.0/go.mod h1:A86O+tHqZLMNO4w6ZZ4FlVQEadcoqkyU72HC5wJ4RlU= github.com/mmcloughlin/profile v0.1.1/go.mod h1:IhHD7q1ooxgwTgjxQYkACGA77oFTDdFVejUS1/tS/qU= -github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= -github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= -github.com/modern-go/reflect2 v0.0.0-20180701023420-4b7aa43c6742/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0= -github.com/modern-go/reflect2 v1.0.1/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0= -github.com/moul/http2curl v1.0.0/go.mod h1:8UbvGypXm98wA/IqH45anm5Y2Z6ep6O31QGOAZ3H0fQ= -github.com/nats-io/jwt v0.3.0/go.mod h1:fRYCDE99xlTsqUzISS1Bi75UBJ6ljOJQOAAu5VglpSg= -github.com/nats-io/nats.go v1.9.1/go.mod h1:ZjDU1L/7fJ09jvUSRVBR2e7+RnLiiIQyqyzEE/Zbp4w= -github.com/nats-io/nkeys v0.1.0/go.mod h1:xpnFELMwJABBLVhffcfd1MZx6VsNRFpEugbxziKVo7w= -github.com/nats-io/nuid v1.0.1/go.mod h1:19wcPz3Ph3q0Jbyiqsd0kePYG7A95tJPxeL+1OSON2c= +github.com/nxadm/tail v1.4.4 h1:DQuhQpB1tVlglWS2hLQ5OV6B5r8aGxSrPc5Qo6uTN78= github.com/nxadm/tail v1.4.4/go.mod h1:kenIhsEOeOJmVchQTgglprH7qJGnHDVpk1VPCcaMI8A= -github.com/nxadm/tail v1.4.8 h1:nPr65rt6Y5JFSKQO7qToXr7pePgD6Gwiw05lkbyAQTE= -github.com/nxadm/tail v1.4.8/go.mod h1:+ncqLTQzXmGhMZNUePPaPqPvBxHAIsmXswZKocGu+AU= -github.com/oklog/ulid/v2 v2.1.0/go.mod h1:rcEKHmBBKfef9DhnvX7y1HZBYxjXb0cP5ExxNsTT1QQ= github.com/olekukonko/tablewriter v0.0.5 h1:P2Ga83D34wi1o9J6Wh1mRuqd4mF/x/lgBS7N7AbDhec= github.com/olekukonko/tablewriter v0.0.5/go.mod h1:hPp6KlRPjbx+hW8ykQs1w3UBbZlj6HuIJcUGPhkA7kY= github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= -github.com/onsi/ginkgo v1.10.1/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= -github.com/onsi/ginkgo v1.10.3/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= github.com/onsi/ginkgo v1.12.1/go.mod h1:zj2OWP4+oCPe1qIXoGWkgMRwljMUYCdkwsT2108oapk= +github.com/onsi/ginkgo v1.14.0 h1:2mOpI4JVVPBN+WQRa0WKH2eXR+Ey+uK4n7Zj0aYpIQA= github.com/onsi/ginkgo v1.14.0/go.mod h1:iSB4RoI2tjJc9BBv4NKIKWKya62Rps+oPG/Lv9klQyY= -github.com/onsi/ginkgo v1.16.4 h1:29JGrr5oVBm5ulCWet69zQkzWipVXIol6ygQUe/EzNc= -github.com/onsi/ginkgo v1.16.4/go.mod h1:dX+/inL/fNMqNlz0e9LfyB9TswhZpCVdJM/Z6Vvnwo0= -github.com/onsi/ginkgo/v2 v2.1.3/go.mod h1:vw5CSIxN1JObi/U8gcbwft7ZxR2dgaR70JSE3/PpL4c= -github.com/onsi/ginkgo/v2 v2.1.4/go.mod h1:um6tUpWM/cxCK3/FK8BXqEiUMUwRgSM4JXG47RKZmLU= -github.com/onsi/ginkgo/v2 v2.1.6/go.mod h1:MEH45j8TBi6u9BMogfbp0stKC5cdGjumZj5Y7AG4VIk= -github.com/onsi/ginkgo/v2 v2.3.0/go.mod h1:Eew0uilEqZmIEZr8JrvYlvOM7Rr6xzTmMV8AyFNU9d0= -github.com/onsi/ginkgo/v2 v2.4.0/go.mod h1:iHkDK1fKGcBoEHT5W7YBq4RFWaQulw+caOMkAt4OrFo= -github.com/onsi/ginkgo/v2 v2.5.0/go.mod h1:Luc4sArBICYCS8THh8v3i3i5CuSZO+RaQRaJoeNwomw= -github.com/onsi/ginkgo/v2 v2.7.0/go.mod h1:yjiuMwPokqY1XauOgju45q3sJt6VzQ/Fict1LFVcsAo= -github.com/onsi/ginkgo/v2 v2.8.0/go.mod h1:6JsQiECmxCa3V5st74AL/AmsV482EDdVrGaVW6z3oYU= -github.com/onsi/gomega v1.7.0/go.mod h1:ex+gbHU/CVuBBDIJjb2X0qEXbFg53c61hWP/1CpauHY= github.com/onsi/gomega v1.7.1/go.mod h1:XdKZgCCFLUoM/7CFJVPcG8C1xQ1AJ0vpAezJrB7JYyY= +github.com/onsi/gomega v1.10.1 h1:o0+MgICZLuZ7xjH7Vx6zS/zcu93/BEp1VwkIW1mEXCE= github.com/onsi/gomega v1.10.1/go.mod h1:iN09h71vgCQne3DLsj+A5owkum+a2tYe+TOCB1ybHNo= -github.com/onsi/gomega v1.16.0/go.mod h1:HnhC7FXeEQY45zxNK3PPoIUhzk/80Xly9PcubAlGdZY= -github.com/onsi/gomega v1.17.0/go.mod h1:HnhC7FXeEQY45zxNK3PPoIUhzk/80Xly9PcubAlGdZY= -github.com/onsi/gomega v1.19.0/go.mod h1:LY+I3pBVzYsTBU1AnDwOSxaYi9WoWiqgwooUqq9yPro= -github.com/onsi/gomega v1.20.1/go.mod h1:DtrZpjmvpn2mPm4YWQa0/ALMDj9v4YxLgojwPeREyVo= -github.com/onsi/gomega v1.21.1/go.mod h1:iYAIXgPSaDHak0LCMA+AWBpIKBr8WZicMxnE8luStNc= -github.com/onsi/gomega v1.22.1/go.mod h1:x6n7VNe4hw0vkyYUM4mjIXx3JbLiPaBPNgB7PRQ1tuM= -github.com/onsi/gomega v1.24.0/go.mod h1:Z/NWtiqwBrwUt4/2loMmHL63EDLnYHmVbuBpDr2vQAg= -github.com/onsi/gomega v1.24.1/go.mod h1:3AOiACssS3/MajrniINInwbfOOtfZvplPzuRSmvt1jM= -github.com/onsi/gomega v1.25.0/go.mod h1:r+zV744Re+DiYCIPRlYOTxn0YkOLcAnW8k1xXdMPGhM= -github.com/onsi/gomega v1.26.0 h1:03cDLK28U6hWvCAns6NeydX3zIm4SF3ci69ulidS32Q= -github.com/onsi/gomega v1.26.0/go.mod h1:r+zV744Re+DiYCIPRlYOTxn0YkOLcAnW8k1xXdMPGhM= -github.com/pborman/getopt v0.0.0-20170112200414-7148bc3a4c30/go.mod h1:85jBQOZwpVEaDAr341tbn15RS4fCAsIst0qp7i8ex1o= -github.com/pelletier/go-toml v1.2.0/go.mod h1:5z9KED0ma1S8pY6P1sdut58dfprrGBbd/94hg7ilaic= github.com/pingcap/errors v0.11.4 h1:lFuQV/oaUMGcD2tqt+01ROSmJs75VG1ToEOkZIZ4nE4= github.com/pingcap/errors v0.11.4/go.mod h1:Oi8TUi2kEtXXLMJk9l1cGmz20kV3TaQ0usTwv5KuLY8= github.com/pkg/diff v0.0.0-20210226163009-20ebb0f2a09e/go.mod h1:pJLUxLENpZxwdsKMEsNbx1VGcRFpLqf3715MtcvvzbA= -github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4= github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= -github.com/prometheus/client_golang v1.14.0 h1:nJdhIvne2eSX/XRAFV9PcvFFRbrjbcTUj0VP62TMhnw= -github.com/prometheus/client_golang v1.14.0/go.mod h1:8vpkKitgIVNcqrRBWh1C4TIUQgYNtG/XQE4E/Zae36Y= -github.com/prometheus/client_model v0.0.0-20190812154241-14fe0d1b01d4/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= -github.com/prometheus/client_model v0.3.0 h1:UBgGFHqYdG/TPFD1B1ogZywDqEkwp3fBMvqdiQ7Xew4= -github.com/prometheus/client_model v0.3.0/go.mod h1:LDGWKZIo7rky3hgvBe+caln+Dr3dPggB5dvjtD7w9+w= -github.com/prometheus/common v0.39.0 h1:oOyhkDq05hPZKItWVBkJ6g6AtGxi+fy7F4JvUV8uhsI= -github.com/prometheus/common v0.39.0/go.mod h1:6XBZ7lYdLCbkAVhwRsWTZn+IN5AB9F/NXd5w0BbEX0Y= -github.com/prometheus/procfs v0.9.0 h1:wzCHvIvM5SxWqYvwgVL7yJY8Lz3PKn49KQtpgMYJfhI= -github.com/prometheus/procfs v0.9.0/go.mod h1:+pB4zwohETzFnmlpe6yd2lSc+0/46IYZRB/chUwxUZY= -github.com/redis/go-redis/v9 v9.0.2/go.mod h1:/xDTe9EF1LM61hek62Poq2nzQSGj0xSrEtEHbBQevps= -github.com/redis/go-redis/v9 v9.1.0 h1:137FnGdk+EQdCbye1FW+qOEcY5S+SpY9T0NiuqvtfMY= -github.com/redis/go-redis/v9 v9.1.0/go.mod h1:urWj3He21Dj5k4TK1y59xH8Uj6ATueP8AH1cY3lZl4c= -github.com/rivo/uniseg v0.2.0 h1:S1pD9weZBuJdFmowNwbpi7BJ8TNftyUImj/0WQi72jY= +github.com/prometheus/client_golang v1.17.0 h1:rl2sfwZMtSthVU752MqfjQozy7blglC+1SOtjMAMh+Q= +github.com/prometheus/client_golang v1.17.0/go.mod h1:VeL+gMmOAxkS2IqfCq0ZmHSL+LjWfWDUmp1mBz9JgUY= +github.com/prometheus/client_model v0.5.0 h1:VQw1hfvPvk3Uv6Qf29VrPF32JB6rtbgI6cYPYQjL0Qw= +github.com/prometheus/client_model v0.5.0/go.mod h1:dTiFglRmd66nLR9Pv9f0mZi7B7fk5Pm3gvsjB5tr+kI= +github.com/prometheus/common v0.45.0 h1:2BGz0eBc2hdMDLnO/8n0jeB3oPrt2D08CekT0lneoxM= +github.com/prometheus/common v0.45.0/go.mod h1:YJmSTw9BoKxJplESWWxlbyttQR4uaEcGyv9MZjVOJsY= +github.com/prometheus/procfs v0.12.0 h1:jluTpSng7V9hY0O2R9DzzJHYb2xULk9VTR1V1R/k6Bo= +github.com/prometheus/procfs v0.12.0/go.mod h1:pcuDEFsWDnvcgNzo4EEweacyhjeA9Zk3cnaOZAZEfOo= +github.com/redis/go-redis/v9 v9.2.1 h1:WlYJg71ODF0dVspZZCpYmoF1+U1Jjk9Rwd7pq6QmlCg= +github.com/redis/go-redis/v9 v9.2.1/go.mod h1:hdY0cQFCN4fnSYT6TkisLufl/4W5UIXyv0b/CLO2V2M= +github.com/redis/rueidis v1.0.19 h1:s65oWtotzlIFN8eMPhyYwxlwLR1lUdhza2KtWprKYSo= +github.com/redis/rueidis v1.0.19/go.mod h1:8B+r5wdnjwK3lTFml5VtxjzGOQAC+5UmujoD12pDrEo= github.com/rivo/uniseg v0.2.0/go.mod h1:J6wj4VEh+S6ZtnVlnTBMWIodfgj8LQOQFoIToxlJtxc= -github.com/rogpeppe/go-internal v1.6.1/go.mod h1:xXDCJY+GAPziupqXw64V24skbSoqbTEfhy4qGm1nDQc= -github.com/rogpeppe/go-internal v1.8.1/go.mod h1:JeRgkft04UBgHMgCIwADu4Pn6Mtm5d4nPKWu0nJ5d+o= -github.com/rogpeppe/go-internal v1.9.0 h1:73kH8U+JUqXU8lRuOHeVHaa/SZPifC7BkcraZVejAe8= +github.com/rivo/uniseg v0.4.4 h1:8TfxU8dW6PdqD27gjM8MVNuicgxIjxpm4K7x4jp8sis= +github.com/rivo/uniseg v0.4.4/go.mod h1:FN3SvrM+Zdj16jyLfmOkMNblXMcoc8DfTHruCPUcx88= github.com/rogpeppe/go-internal v1.9.0/go.mod h1:WtVeX8xhTBvf0smdhujwtBcq4Qrzq/fJaraNFVN+nFs= -github.com/rs/cors v1.8.2 h1:KCooALfAYGs415Cwu5ABvv9n9509fSiG5SQJn/AQo4U= -github.com/rs/cors v1.8.2/go.mod h1:XyqrcTp5zjWr1wsJ8PIRZssZ8b/WMcMf71DJnit4EMU= -github.com/rueian/rueidis v0.0.93 h1:cG905akj2+QyHx0x9y4mN0K8vLi6M94QiyoLulXS3l0= -github.com/rueian/rueidis v0.0.93/go.mod h1:lo6LBci0D986usi5Wxjb4RVNaWENKYbHZSnufGJ9bTE= -github.com/russross/blackfriday v1.5.2/go.mod h1:JO/DiYxRf+HjHt06OyowR9PTA263kcR/rfWxYHBV53g= -github.com/ryanuber/columnize v2.1.0+incompatible/go.mod h1:sm1tb6uqfes/u+d4ooFouqFdy9/2g9QGwK3SQygK0Ts= -github.com/schollz/closestmatch v2.1.0+incompatible/go.mod h1:RtP1ddjLong6gTkbtmuhtR2uUrrJOpYzYRvbcPAid+g= -github.com/sergi/go-diff v1.0.0/go.mod h1:0CfEIISq7TuYL3j771MWULgwwjU+GofnZX9QAmXWZgo= +github.com/rogpeppe/go-internal v1.11.0 h1:cWPaGQEPrBb5/AsnsZesgZZ9yb1OQ+GOISoDNXVBh4M= +github.com/rogpeppe/go-internal v1.11.0/go.mod h1:ddIwULY96R17DhadqLgMfk9H9tvdUzkipdSkR5nkCZA= +github.com/rs/cors v1.10.1 h1:L0uuZVXIKlI1SShY2nhFfo44TYvDPQ1w4oFkUJNfhyo= +github.com/rs/cors v1.10.1/go.mod h1:XyqrcTp5zjWr1wsJ8PIRZssZ8b/WMcMf71DJnit4EMU= github.com/shirou/gopsutil v3.21.11+incompatible h1:+1+c1VGhc88SSonWP6foOcLhvnKlUeu/erjjvaPEYiI= github.com/shirou/gopsutil v3.21.11+incompatible/go.mod h1:5b4v6he4MtMOwMlS0TUMTu2PcXUg8+E1lC7eC3UO/RA= -github.com/shurcooL/sanitized_anchor_name v1.0.0/go.mod h1:1NzhyTcUVG4SuEtjjoZeVRXNmyL/1OwPU0+IJeTBvfc= -github.com/smartystreets/assertions v0.0.0-20180927180507-b2de0cb4f26d/go.mod h1:OnSkiWE9lh6wB0YB77sQom3nweQdgAjqCqsofrRNTgc= -github.com/smartystreets/goconvey v1.6.4/go.mod h1:syvi0/a8iFYH4r/RixwvyeAJjdLS9QV7WQ/tjFTllLA= -github.com/spf13/afero v1.1.2/go.mod h1:j4pytiNVoe2o6bmDsKpLACNPDBIoEAkihy7loJ1B0CQ= -github.com/spf13/cast v1.3.0/go.mod h1:Qx5cxh0v+4UWYiBimWS+eyWzqEqokIECu5etghLkUJE= -github.com/spf13/cobra v0.0.5/go.mod h1:3K3wKZymM7VvHMDS9+Akkh4K60UwM26emMESw8tLCHU= -github.com/spf13/jwalterweatherman v1.0.0/go.mod h1:cQK4TGJAtQXfYWX+Ddv3mKDzgVb68N+wFjFa4jdeBTo= -github.com/spf13/pflag v1.0.3/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4= -github.com/spf13/viper v1.3.2/go.mod h1:ZiWeW+zYFKm7srdB9IoDzzZXaJaI5eL9QjNiN/DMA2s= github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= -github.com/stretchr/objx v0.4.0/go.mod h1:YvHI0jy2hoMjB+UWwv71VJQ9isScKT/TqJzVSSt89Yw= -github.com/stretchr/objx v0.5.0/go.mod h1:Yh+to48EsGEfYuaHDzXPcE3xhTkx73EhmCGUpEOglKo= -github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs= github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI= -github.com/stretchr/testify v1.4.0/go.mod h1:j7eGeouHqKxXV5pUuKE4zz7dFj8WfuZ+81PSLYec5m4= -github.com/stretchr/testify v1.5.1/go.mod h1:5W2xD1RspED5o8YsWQXVCued0rvSQ+mT+I5cxcmMvtA= github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= -github.com/stretchr/testify v1.7.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= -github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU= -github.com/stretchr/testify v1.8.1/go.mod h1:w2LPCIKwWwSfY2zedu0+kehJoqGctiVI29o6fzry7u4= -github.com/stretchr/testify v1.8.2 h1:+h33VjcLVPDHtOdpUCuF+7gSuG3yGIftsP1YvFihtJ8= -github.com/stretchr/testify v1.8.2/go.mod h1:w2LPCIKwWwSfY2zedu0+kehJoqGctiVI29o6fzry7u4= +github.com/stretchr/testify v1.8.4 h1:CcVxjf3Q8PM0mHUKJCdn+eZZtm5yQwehR5yeSVQQcUk= +github.com/stretchr/testify v1.8.4/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo= github.com/stvp/tempredis v0.0.0-20181119212430-b82af8480203 h1:QVqDTf3h2WHt08YuiTGPZLls0Wq99X9bWd0Q5ZSBesM= github.com/stvp/tempredis v0.0.0-20181119212430-b82af8480203/go.mod h1:oqN97ltKNihBbwlX8dLpwxCl3+HnXKV/R0e+sRLd9C8= github.com/supranational/blst v0.3.11 h1:LyU6FolezeWAhvQk0k6O/d49jqgO52MSDDfYgbeoEm4= github.com/supranational/blst v0.3.11/go.mod h1:jZJtfjgudtNl4en1tzwPIV3KjUnQUvG3/j+w+fVonLw= github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7 h1:epCh84lMvA70Z7CTTCmYQn2CKbY8j86K7/FAIr141uY= github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7/go.mod h1:q4W45IWZaF22tdD+VEXcAWRA037jwmWEB5VWYORlTpc= -github.com/tklauser/go-sysconf v0.3.10 h1:IJ1AZGZRWbY8T5Vfk04D9WOA5WSejdflXxP03OUqALw= -github.com/tklauser/go-sysconf v0.3.10/go.mod h1:C8XykCvCb+Gn0oNCWPIlcb0RuglQTYaQ2hGm7jmxEFk= -github.com/tklauser/numcpus v0.4.0 h1:E53Dm1HjH1/R2/aoCtXtPgzmElmn51aOkhCFSuZq//o= -github.com/tklauser/numcpus v0.4.0/go.mod h1:1+UI3pD8NW14VMwdgJNJ1ESk2UnwhAnz5hMwiKKqXCQ= -github.com/ugorji/go v1.1.4/go.mod h1:uQMGLiO92mf5W77hV/PUCpI3pbzQx3CRekS0kk+RGrc= -github.com/ugorji/go v1.1.7/go.mod h1:kZn38zHttfInRq0xu/PH0az30d+z6vm202qpg1oXVMw= -github.com/ugorji/go/codec v0.0.0-20181204163529-d75b2dcb6bc8/go.mod h1:VFNgLljTbGfSG7qAOspJ7OScBnGdDN/yBr0sguwnwf0= -github.com/ugorji/go/codec v1.1.7/go.mod h1:Ax+UKWsSmolVDwsd+7N3ZtXu+yMGCf907BLYF3GoBXY= -github.com/urfave/negroni v1.0.0/go.mod h1:Meg73S6kFm/4PpbYdq35yYWoCZ9mS/YSx+lKnmiohz4= -github.com/valyala/bytebufferpool v1.0.0/go.mod h1:6bBcMArwyJ5K/AmCkWv1jt77kVWyCJ6HpOuEn7z0Csc= -github.com/valyala/fasthttp v1.6.0/go.mod h1:FstJa9V+Pj9vQ7OJie2qMHdwemEDaDiSdBnvPM1Su9w= -github.com/valyala/fasttemplate v1.0.1/go.mod h1:UQGH1tvbgY+Nz5t2n7tXsz52dQxojPUpymEIMZ47gx8= -github.com/valyala/fasttemplate v1.2.1/go.mod h1:KHLXt3tVN2HBp8eijSv/kGJopbvo7S+qRAEEKiv+SiQ= -github.com/valyala/tcplisten v0.0.0-20161114210144-ceec8f93295a/go.mod h1:v3UYOV9WzVtRmSR+PDvWpU/qWl4Wa5LApYYX4ZtKbio= -github.com/xeipuuv/gojsonpointer v0.0.0-20180127040702-4e3ac2762d5f/go.mod h1:N2zxlSyiKSe5eX1tZViRH5QA0qijqEDrYZiPEAiq3wU= -github.com/xeipuuv/gojsonreference v0.0.0-20180127040603-bd5ef7bd5415/go.mod h1:GwrjFmJcFw6At/Gs6z4yjiIwzuJ1/+UwLxMQDVQXShQ= -github.com/xeipuuv/gojsonschema v1.2.0/go.mod h1:anYRn/JVcOK2ZgGU+IjEV4nwlhoK5sQluxsYJ78Id3Y= -github.com/xordataexchange/crypt v0.0.3-0.20170626215501-b2862e3d0a77/go.mod h1:aYKd//L2LvnjZzWKhF00oedf4jCCReLcmhLdhm1A27Q= -github.com/yalp/jsonpath v0.0.0-20180802001716-5cc68e5049a0/go.mod h1:/LWChgwKmvncFJFHJ7Gvn9wZArjbV5/FppcK2fKk/tI= -github.com/yudai/gojsondiff v1.0.0/go.mod h1:AY32+k2cwILAkW1fbgxQ5mUmMiZFgLIV+FBNExI05xg= -github.com/yudai/golcs v0.0.0-20170316035057-ecda9a501e82/go.mod h1:lgjkn3NuSvDfVJdfcVVdX+jpBxNmX4rDAzaS45IcYoM= -github.com/yudai/pp v2.0.1+incompatible/go.mod h1:PuxR/8QJ7cyCkFp/aUDS+JY727OFEZkTdatxwunjIkc= +github.com/tklauser/go-sysconf v0.3.12 h1:0QaGUFOdQaIVdPgfITYzaTegZvdCjmYO52cSFAEVmqU= +github.com/tklauser/go-sysconf v0.3.12/go.mod h1:Ho14jnntGE1fpdOqQEEaiKRpvIavV0hSfmBq8nJbHYI= +github.com/tklauser/numcpus v0.6.1 h1:ng9scYS7az0Bk4OZLvrNXNSAO2Pxr1XXRAPyjhIx+Fk= +github.com/tklauser/numcpus v0.6.1/go.mod h1:1XfjsgE2zo8GVw7POkMbHENHzVg3GzmoZ9fESEdAacY= +github.com/xaionaro-go/weightedshuffle v0.0.0-20211213010739-6a74fbc7d24a h1:WS5nQycV+82Ndezq0UcMcGVG416PZgcJPqI/bLM824A= +github.com/xaionaro-go/weightedshuffle v0.0.0-20211213010739-6a74fbc7d24a/go.mod h1:0KAUfC65le2kMu4fnBxm7Xj3PkQ3MBpJbF5oMmqufBc= github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= -github.com/yuin/goldmark v1.3.5/go.mod h1:mwnBkeHKe2W/ZEtQ+71ViKU8L12m81fl3OWwC1Zlc8k= -github.com/yuin/goldmark v1.4.1/go.mod h1:mwnBkeHKe2W/ZEtQ+71ViKU8L12m81fl3OWwC1Zlc8k= -github.com/yuin/goldmark v1.4.13/go.mod h1:6yULJ656Px+3vBD8DxQVa3kxgyrAnzto9xy5taEt/CY= -github.com/yuin/gopher-lua v0.0.0-20210529063254-f4c35e4016d9 h1:k/gmLsJDWwWqbLCur2yWnJzwQEKRcAHXo6seXGuSwWw= -github.com/yuin/gopher-lua v0.0.0-20210529063254-f4c35e4016d9/go.mod h1:E1AXubJBdNmFERAOucpDIxNzeGfLzg0mYh+UfMWdChA= -github.com/yusufpapurcu/wmi v1.2.2 h1:KBNDSne4vP5mbSWnJbO+51IMOXJB67QiYCSBrubbPRg= -github.com/yusufpapurcu/wmi v1.2.2/go.mod h1:SBZ9tNy3G9/m5Oi98Zks0QjeHVDvuK0qfxQmPyzfmi0= -go.opentelemetry.io/otel v1.12.0/go.mod h1:geaoz0L0r1BEOR81k7/n9W4TCXYCJ7bPO7K374jQHG0= -go.opentelemetry.io/otel/metric v0.35.0/go.mod h1:qAcbhaTRFU6uG8QM7dDo7XvFsWcugziq/5YI065TokQ= -go.opentelemetry.io/otel/sdk v1.12.0/go.mod h1:WYcvtgquYvgODEvxOry5owO2y9MyciW7JqMz6cpXShE= -go.opentelemetry.io/otel/sdk/metric v0.35.0/go.mod h1:eDyp1GxSiwV98kr7w4pzrszQh/eze9MqBqPd2bCPmyE= -go.opentelemetry.io/otel/trace v1.12.0/go.mod h1:pHlgBynn6s25qJ2szD+Bv+iwKJttjHSI3lUAyf0GNuQ= -go.uber.org/goleak v1.2.0/go.mod h1:XJYK+MuIchqpmGmUSAzotztawfKvYLUIgg7guXrwVUo= -golang.org/x/crypto v0.0.0-20181203042331-505ab145d0a9/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= +github.com/yuin/gopher-lua v1.1.0 h1:BojcDhfyDWgU2f2TOzYK/g5p2gxMrku8oupLDqlnSqE= +github.com/yuin/gopher-lua v1.1.0/go.mod h1:GBR0iDaNXjAgGg9zfCvksxSRnQx76gclCIb7kdAd1Pw= +github.com/yusufpapurcu/wmi v1.2.3 h1:E1ctvB7uKFMOJw3fdOW32DwGE9I7t++CRUEMKvFoFiw= +github.com/yusufpapurcu/wmi v1.2.3/go.mod h1:SBZ9tNy3G9/m5Oi98Zks0QjeHVDvuK0qfxQmPyzfmi0= golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= -golang.org/x/crypto v0.0.0-20190701094942-4def268fd1a4/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= -golang.org/x/crypto v0.0.0-20191227163750-53104e6ec876/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= -golang.org/x/crypto v0.0.0-20210322153248-0c34fe9e7dc2/go.mod h1:T9bdIzuCu7OtxOm1hfPfRQxPLYneinmdGuTeoZ9dtd4= -golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= -golang.org/x/crypto v0.1.0/go.mod h1:RecgLatLF4+eUMCP1PoPZQb+cVrJcOPbHkTkbkB9sbw= -golang.org/x/crypto v0.10.0 h1:LKqV2xt9+kDzSTfOhx4FrkEBcMrAgHSYgzywV9zcGmM= -golang.org/x/crypto v0.10.0/go.mod h1:o4eNf7Ede1fv+hwOwZsTHl9EsPFO6q6ZvYR8vYfY45I= -golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= -golang.org/x/exp v0.0.0-20230515195305-f3d0a9c9a5cc h1:mCRnTeVUjcrhlRmO0VK8a6k6Rrf6TF9htwo2pJVSjIU= -golang.org/x/exp v0.0.0-20230515195305-f3d0a9c9a5cc/go.mod h1:V1LtkGg67GoY2N1AnLN78QLrzxkLyJw7RJb1gzOOz9w= -golang.org/x/lint v0.0.0-20181026193005-c67002cb31c3/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE= -golang.org/x/lint v0.0.0-20190227174305-5b3e6a55c961/go.mod h1:wehouNa3lNwaWXcvxsM5YxQ5yQlVC4a0KAMCusXpPoU= -golang.org/x/lint v0.0.0-20190313153728-d0100b6bd8b3/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc= -golang.org/x/lint v0.0.0-20190930215403-16217165b5de/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc= -golang.org/x/lint v0.0.0-20210508222113-6edffad5e616/go.mod h1:3xt1FjdF8hUf6vQPIChWIBhFzV8gjjsPE/fR3IyQdNY= -golang.org/x/mod v0.1.1-0.20191105210325-c90efee705ee/go.mod h1:QqPTAvyqsEbceGzBzNggFXnrqF1CaUcvgkdR5Ot7KZg= +golang.org/x/crypto v0.14.0 h1:wBqGXzWJW6m1XrIKlAH0Hs1JJ7+9KBwnIO8v66Q9cHc= +golang.org/x/crypto v0.14.0/go.mod h1:MVFd36DqK4CsrnJYDkBA3VC4m2GkXAM0PvzMCn4JQf4= +golang.org/x/exp v0.0.0-20231006140011-7918f672742d h1:jtJma62tbqLibJ5sFQz8bKtEM8rJBtfilJ2qTU199MI= +golang.org/x/exp v0.0.0-20231006140011-7918f672742d/go.mod h1:ldy0pHrwJyGW56pPQzzkH36rKxoZW1tw7ZJpeKx+hdo= golang.org/x/mod v0.2.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= -golang.org/x/mod v0.4.2/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= -golang.org/x/mod v0.6.0-dev.0.20220106191415-9b9b3d81d5e3/go.mod h1:3p9vT2HGsQu2K1YbXdKPJLVgG5VJdoTa1poYQBtP1AY= -golang.org/x/mod v0.6.0-dev.0.20220419223038-86c51ed26bb4/go.mod h1:jJ57K6gSWd91VN4djpZkiMVwK6gcyfeH4XE8wZrZaV4= -golang.org/x/mod v0.6.0/go.mod h1:4mET923SAdbXp2ki8ey+zGs1SLqsuM2Y0uvdZR/fUNI= -golang.org/x/mod v0.7.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs= -golang.org/x/net v0.0.0-20180724234803-3673e40ba225/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= -golang.org/x/net v0.0.0-20180826012351-8a410e7b638d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= +golang.org/x/mod v0.13.0 h1:I/DsJXRlw/8l/0c24sM9yb0T4z9liZTduXvdAWYiysY= +golang.org/x/mod v0.13.0/go.mod h1:hTbmBsO62+eylJbnUtE2MGJUyE7QWk4xUqPFrRgJ+7c= golang.org/x/net v0.0.0-20180906233101-161cd47e91fd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= -golang.org/x/net v0.0.0-20181220203305-927f97764cc3/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= -golang.org/x/net v0.0.0-20190213061140-3a22650c66bd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= -golang.org/x/net v0.0.0-20190311183353-d8887717615a/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= -golang.org/x/net v0.0.0-20190327091125-710a502c58a2/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= -golang.org/x/net v0.0.0-20190503192946-f4e77d36d62c/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= -golang.org/x/net v0.0.0-20190827160401-ba9fcec4b297/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= -golang.org/x/net v0.0.0-20190923162816-aa69164e4478/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= -golang.org/x/net v0.0.0-20191209160850-c0dbc17a3553/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20200226121028-0de0cce0169b/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20200520004742-59133d7f0dd7/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A= golang.org/x/net v0.0.0-20200813134508-3edf25e44fcc/go.mod h1:/O7V0waA8r7cgGh81Ro3o1hOxt32SMVPicZroKQ2sZA= golang.org/x/net v0.0.0-20201021035429-f5854403a974/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= -golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= -golang.org/x/net v0.0.0-20210405180319-a5a99cb37ef4/go.mod h1:p54w0d4576C0XHj96bSt6lcn1PtDYWL6XObtHCRCNQM= -golang.org/x/net v0.0.0-20210428140749-89ef3d95e781/go.mod h1:OJAsFXCWl8Ukc7SiCT/9KSuxbyM7479/AVlXFRxuMCk= -golang.org/x/net v0.0.0-20211008194852-3b03d305991f/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= -golang.org/x/net v0.0.0-20211015210444-4f30a5c0130f/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= -golang.org/x/net v0.0.0-20220225172249-27dd8689420f/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= -golang.org/x/net v0.0.0-20220425223048-2871e0cb64e4/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= -golang.org/x/net v0.0.0-20220722155237-a158d28d115b/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c= -golang.org/x/net v0.1.0/go.mod h1:Cx3nUiGt4eDBEyega/BKRp+/AlGL8hYe7U9odMt2Cco= -golang.org/x/net v0.2.0/go.mod h1:KqCZLdyyvdV855qA2rE3GC2aiw5xGR5TEjj8smXukLY= -golang.org/x/net v0.3.0/go.mod h1:MBQ8lrhLObU/6UmLb4fmbmk5OcyYmqtbGd/9yIeKjEE= -golang.org/x/net v0.5.0/go.mod h1:DivGGAXEgPSlEBzxGzZI+ZLohi+xUj054jfeKui00ws= -golang.org/x/net v0.10.0 h1:X2//UzNDwYmtCLn7To6G58Wr6f5ahEAQgKNzv9Y951M= -golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U= +golang.org/x/net v0.17.0 h1:pVaXccu2ozPjCXewfr1S7xza/zcXTity9cCdXQYSjIM= +golang.org/x/net v0.17.0/go.mod h1:NxSsAGuq816PNPmqtQdLE42eU2Fs7NoRIZrHJAlaCOE= golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.0.0-20181108010431-42b317875d0f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.0.0-20181221193216-37e7f081c4d4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.0.0-20190227155943-e225da77a7e6/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20190911185100-cd5d95a43a6e/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.0.0-20210220032951-036812b2e83c/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.1.0/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.3.0 h1:ftCYgMx6zT/asHUrPw8BLLscYtGznsLAnjq5RH9P66E= -golang.org/x/sync v0.3.0/go.mod h1:FU7BRWz2tNW+3quACPkgCx/L+uEAv1htQ0V83Z9Rj+Y= -golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= +golang.org/x/sync v0.4.0 h1:zxkM55ReGkDlKSM+Fu41A+zmbZuaPVbGMzvvdUPznYQ= +golang.org/x/sync v0.4.0/go.mod h1:FU7BRWz2tNW+3quACPkgCx/L+uEAv1htQ0V83Z9Rj+Y= golang.org/x/sys v0.0.0-20180909124046-d0be0721c37e/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20181205085412-a5c9d58dba9a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20190204203706-41f3e6584952/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20190222072716-a9d3bda3a223/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20190626221950-04f50cda93cb/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20190813064441-fde4db37ae7a/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190904154756-749cb33beabd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190916202348-b4ddaad3f8a3/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191005200804-aed5e4c7ecf9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20191010194322-b09406accb47/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191120155948-bd437916bb0e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20191204072324-ce4227a45e2e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200116001909-b77594299b42/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200223170610-d5e6a3e2c0ae/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200323222414-85ca7c5b95cd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200519105757-fe76b779f299/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200814200057-3d37ad5750ed/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210112080510-489259a85091/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210330210617-4fbd30eecc44/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210403161142-5e06dd20ab57/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210423082822-04245dca01da/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210510120138-977fb7262007/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20210927094055-39ccf1dd6fa6/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20211007075335-d3039528d8ac/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20211019181941-9d821ace8654/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20211216021012-1d35b9e2eb4e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20220128215802-99c3d69c2c27/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20220204135822-1c1b9b1eba6a/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20220209214540-3681064d5158/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20220319134239-a9b59b0215f8/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20220422013727-9388b58f7150/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20220919091848-fb04ddd9f9c8/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.1.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.2.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.3.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.4.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.9.0 h1:KS/R3tvhPqvJvwcKfnBHJwwthS11LRhmM5D59eEXa0s= -golang.org/x/sys v0.9.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -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.1.0/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= -golang.org/x/term v0.2.0/go.mod h1:TVmDHMZPmdnySmBfhjOoOdhjzdE1h4u1VwSiw2l1Nuc= -golang.org/x/term v0.3.0/go.mod h1:q750SLmJuPmVoN1blW3UFBPREJfb1KmY3vwxfr+nFDA= -golang.org/x/term v0.4.0/go.mod h1:9P2UbLfCdcvo3p/nzKvsmas4TnlujnuoV9hGgYzW1lQ= +golang.org/x/sys v0.5.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.13.0 h1:Af8nKPmuFypiUBjVoU9V20FiaFXOcuZI21p0ycVYYGE= +golang.org/x/sys v0.13.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= -golang.org/x/text v0.3.5/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= -golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= -golang.org/x/text v0.3.7/go.mod h1:u+2+/6zg+i71rQMx5EYifcz6MCKuco9NR6JIITiCfzQ= -golang.org/x/text v0.4.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= -golang.org/x/text v0.5.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= -golang.org/x/text v0.6.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= -golang.org/x/text v0.10.0 h1:UpjohKhiEgNc0CSauXmwYftY1+LlaC75SJwh0SgCX58= -golang.org/x/text v0.10.0/go.mod h1:TvPlkZtksWOMsz7fbANvkp4WM8x/WCo/om8BMLbz+aE= -golang.org/x/time v0.0.0-20201208040808-7e3f01d25324/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= +golang.org/x/text v0.13.0 h1:ablQoSUd0tRdKxZewP80B+BaqeKJuVhuRxj/dkrun3k= +golang.org/x/text v0.13.0/go.mod h1:TvPlkZtksWOMsz7fbANvkp4WM8x/WCo/om8BMLbz+aE= golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= -golang.org/x/tools v0.0.0-20181221001348-537d06c36207/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= -golang.org/x/tools v0.0.0-20190114222345-bf090417da8b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= -golang.org/x/tools v0.0.0-20190226205152-f727befe758c/go.mod h1:9Yl7xja0Znq3iFh3HoIrodX9oNMXvdceNzlUR8zjMvY= -golang.org/x/tools v0.0.0-20190311212946-11955173bddd/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= -golang.org/x/tools v0.0.0-20190327201419-c70d86f8b7cf/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= -golang.org/x/tools v0.0.0-20190328211700-ab21143f2384/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= -golang.org/x/tools v0.0.0-20190524140312-2c0ae7006135/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q= golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= -golang.org/x/tools v0.0.0-20200130002326-2f3ba24bd6e7/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= golang.org/x/tools v0.0.0-20200619180055-7c47624df98f/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE= -golang.org/x/tools v0.0.0-20201224043029-2b0845dc783e/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= golang.org/x/tools v0.0.0-20210106214847-113979e3529a/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= -golang.org/x/tools v0.1.1/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= -golang.org/x/tools v0.1.3/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= -golang.org/x/tools v0.1.5/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= -golang.org/x/tools v0.1.10/go.mod h1:Uh6Zz+xoGYZom868N8YTex3t7RhtHDBrE8Gzo9bV56E= -golang.org/x/tools v0.1.12/go.mod h1:hNGJHUnrk76NpqgfD5Aqm5Crs+Hm0VOH/i9J2+nxYbc= -golang.org/x/tools v0.2.0/go.mod h1:y4OqIKeOV/fWJetJ8bXPU1sEVniLMIyDAZWeHdV+NTA= -golang.org/x/tools v0.4.0/go.mod h1:UE5sM2OK9E/d67R0ANs2xJizIymRP5gJU295PvKXxjQ= -golang.org/x/tools v0.5.0/go.mod h1:N+Kgy78s5I24c24dU8OfWNEotWjutIs8SnJvn5IDq+k= +golang.org/x/tools v0.14.0 h1:jvNa2pY0M4r62jkRQ6RwEZZyPcymeL9XZMLBbV7U2nc= +golang.org/x/tools v0.14.0/go.mod h1:uYBEerGOWcJyEORxN+Ek8+TT266gXkNlHdJBwexUsBg= golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= +golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1 h1:go1bK/D/BFZV2I8cIQd1NKEZ+0owSTG1fDTci4IqFcE= golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= -google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM= -google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= -google.golang.org/genproto v0.0.0-20180518175338-11a468237815/go.mod h1:JiN7NxoALGmiZfu7CAH4rXhgtRTLTxftemlI0sWmxmc= -google.golang.org/genproto v0.0.0-20180817151627-c66870c02cf8/go.mod h1:JiN7NxoALGmiZfu7CAH4rXhgtRTLTxftemlI0sWmxmc= -google.golang.org/genproto v0.0.0-20190819201941-24fa4b261c55/go.mod h1:DMBHOl98Agz4BDEuKkezgsaosCRResVns1a3J2ZsMNc= -google.golang.org/genproto v0.0.0-20200526211855-cb27e3aa2013/go.mod h1:NbSheEEYHJ7i3ixzK3sjbqSGDJWnxyFXZblF3eUsNvo= -google.golang.org/genproto v0.0.0-20210624195500-8bfb893ecb84/go.mod h1:SzzZ/N+nwJDaO1kznhnlzqS8ocJICar6hYhVyhi++24= -google.golang.org/grpc v1.12.0/go.mod h1:yo6s7OP7yaDglbqo1J04qKzAhqBH6lvTonzMVmEdcZw= -google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= -google.golang.org/grpc v1.23.0/go.mod h1:Y5yQAOtifL1yxbo5wqy6BxZv8vAUGQwXBOALyacEbxg= -google.golang.org/grpc v1.25.1/go.mod h1:c3i+UQWmh7LiEpx4sFZnkU36qjEYZ0imhYfXVyQciAY= -google.golang.org/grpc v1.27.0/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8abTk= -google.golang.org/grpc v1.38.0/go.mod h1:NREThFqKR1f3iQ6oBuvc5LadQuXVGo9rkm5ZGrQdJfM= google.golang.org/protobuf v0.0.0-20200109180630-ec00e32a8dfd/go.mod h1:DFci5gLYBciE7Vtevhsrf46CRTquxDuWsQurQQe4oz8= google.golang.org/protobuf v0.0.0-20200221191635-4d8936d0db64/go.mod h1:kwYJMbMJ01Woi6D6+Kah6886xMZcty6N08ah7+eCXa0= google.golang.org/protobuf v0.0.0-20200228230310-ab0ca4ff8a60/go.mod h1:cfTl7dwQJ+fmap5saPgwCLgHXTUD7jkjRqWcaiX5VyM= google.golang.org/protobuf v1.20.1-0.20200309200217-e05f789c0967/go.mod h1:A+miEFZTKqfCUM6K7xSMQL9OKL/b6hQv+e19PK+JZNE= google.golang.org/protobuf v1.21.0/go.mod h1:47Nbq4nVaFHyn7ilMalzfO3qCViNmqZ2kzikPIcrTAo= -google.golang.org/protobuf v1.22.0/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU= google.golang.org/protobuf v1.23.0/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU= -google.golang.org/protobuf v1.23.1-0.20200526195155-81db48ad09cc/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU= -google.golang.org/protobuf v1.25.0/go.mod h1:9JNX74DMeImyA3h4bdi1ymwjUzf21/xIlbajtzgsN7c= 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.28.0/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= -google.golang.org/protobuf v1.28.1 h1:d0NfwRgPtno5B1Wa6L2DAG+KivqkdutMf1UhdNx175w= -google.golang.org/protobuf v1.28.1/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= +google.golang.org/protobuf v1.31.0 h1:g0LDEJHgrBl9N9r17Ru3sqWhkIx2NB67okBHPwC7hs8= +google.golang.org/protobuf v1.31.0/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= -gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= -gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk= -gopkg.in/errgo.v2 v2.1.0/go.mod h1:hNsd1EY+bozCKY1Ytp96fpM3vjJbqLJn88ws8XvfDNI= +gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q= gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMys= -gopkg.in/go-playground/assert.v1 v1.2.1/go.mod h1:9RXL0bg/zibRAgZUYszZSwO/z8Y/a8bDuhia5mkpMnE= -gopkg.in/go-playground/validator.v8 v8.18.2/go.mod h1:RX2a/7Ha8BgOhfk7j780h4/u/RRjR0eouCJSH80/M2Y= -gopkg.in/ini.v1 v1.51.1/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k= -gopkg.in/mgo.v2 v2.0.0-20180705113604-9856a29383ce/go.mod h1:yeKp02qBN3iKW1OzL3MGk2IdtZzaj7SFntXj72NppTA= -gopkg.in/natefinch/npipe.v2 v2.0.0-20160621034901-c1b8fa8bdcce h1:+JknDZhAj8YMt7GC73Ei8pv4MzjDUNPHgQWJdtMAaDU= -gopkg.in/natefinch/npipe.v2 v2.0.0-20160621034901-c1b8fa8bdcce/go.mod h1:5AcXVHNjg+BDxry382+8OKon8SEWiKktQR07RKPsv1c= gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 h1:uRGJdciOHaEIrze2W8Q3AKkepLTh2hOroT7a+7czfdQ= gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7/go.mod h1:dt/ZhP58zS4L8KSrWDmTeBkI65Dw0HsyUHuEVlX15mw= -gopkg.in/yaml.v2 v2.2.1/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= -gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.4/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.3.0/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.4.0 h1:D8xgwECY7CYvx+Y2n4sBz93Jn9JRvxdiyyo8CTfuKaY= gopkg.in/yaml.v2 v2.4.0/go.mod h1:RDklbk79AGWmwhnvt/jBztapEOGDOx6ZbXqjP6csGnQ= -gopkg.in/yaml.v3 v3.0.0-20191120175047-4206685974f2/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= -gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= -honnef.co/go/tools v0.0.0-20190102054323-c2f93a96b099/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= -honnef.co/go/tools v0.0.0-20190523083050-ea95bdfd59fc/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= rsc.io/tmplfunc v0.0.3 h1:53XFQh69AfOa8Tw0Jm7t+GV7KZhOi6jzsCzTtKbMvzU= rsc.io/tmplfunc v0.0.3/go.mod h1:AG3sTPzElb1Io3Yg4voV9AGZJuleGAwaVRxL9M49PhA= diff --git a/proxyd/integration_tests/batching_test.go b/proxyd/integration_tests/batching_test.go index e40745da31cb2..c1f8b386d09a5 100644 --- a/proxyd/integration_tests/batching_test.go +++ b/proxyd/integration_tests/batching_test.go @@ -20,6 +20,9 @@ func TestBatching(t *testing.T) { ethAccountsResponse2 := `{"jsonrpc": "2.0", "result": [], "id": 2}` + backendResTooLargeResponse1 := `{"error":{"code":-32020,"message":"backend response too large"},"id":1,"jsonrpc":"2.0"}` + backendResTooLargeResponse2 := `{"error":{"code":-32020,"message":"backend response too large"},"id":2,"jsonrpc":"2.0"}` + type mockResult struct { method string id string @@ -40,6 +43,7 @@ func TestBatching(t *testing.T) { expectedRes string maxUpstreamBatchSize int numExpectedForwards int + maxResponseSizeBytes int64 }{ { name: "backend returns batches out of order", @@ -128,11 +132,24 @@ func TestBatching(t *testing.T) { maxUpstreamBatchSize: 2, numExpectedForwards: 1, }, + { + name: "large upstream response gets dropped", + mocks: []mockResult{chainIDMock1, chainIDMock2}, + reqs: []*proxyd.RPCReq{ + NewRPCReq("1", "eth_chainId", nil), + NewRPCReq("2", "eth_chainId", nil), + }, + expectedRes: asArray(backendResTooLargeResponse1, backendResTooLargeResponse2), + maxUpstreamBatchSize: 2, + numExpectedForwards: 1, + maxResponseSizeBytes: 1, + }, } for _, tt := range tests { t.Run(tt.name, func(t *testing.T) { config.Server.MaxUpstreamBatchSize = tt.maxUpstreamBatchSize + config.BackendOptions.MaxResponseSizeBytes = tt.maxResponseSizeBytes handler := tt.handler if handler == nil { diff --git a/proxyd/integration_tests/caching_test.go b/proxyd/integration_tests/caching_test.go index e4a64d95e3aaf..e74b85b4a7bf1 100644 --- a/proxyd/integration_tests/caching_test.go +++ b/proxyd/integration_tests/caching_test.go @@ -27,6 +27,7 @@ func TestCaching(t *testing.T) { hdlr.SetRoute("eth_getTransactionByBlockHashAndIndex", "999", "eth_getTransactionByBlockHashAndIndex") hdlr.SetRoute("eth_getUncleByBlockHashAndIndex", "999", "eth_getUncleByBlockHashAndIndex") hdlr.SetRoute("eth_getTransactionReceipt", "999", "eth_getTransactionReceipt") + hdlr.SetRoute("debug_getRawReceipts", "999", "debug_getRawReceipts") /* not cacheable */ hdlr.SetRoute("eth_getBlockByNumber", "999", "eth_getBlockByNumber") hdlr.SetRoute("eth_blockNumber", "999", "eth_blockNumber") @@ -180,6 +181,30 @@ func TestCaching(t *testing.T) { RequireEqualJSON(t, resRaw, resCache) require.Equal(t, 2, countRequests(backend, "eth_getBlockByHash")) }) + + t.Run("debug_getRawReceipts with 0 receipts should not be cached", func(t *testing.T) { + backend.Reset() + hdlr.SetRoute("debug_getRawReceipts", "999", []string{}) + resRaw, _, err := client.SendRPC("debug_getRawReceipts", []interface{}{"0x88420081ab9c6d50dc57af36b541c6b8a7b3e9c0d837b0414512c4c5883560ff"}) + require.NoError(t, err) + resCache, _, err := client.SendRPC("debug_getRawReceipts", []interface{}{"0x88420081ab9c6d50dc57af36b541c6b8a7b3e9c0d837b0414512c4c5883560ff"}) + require.NoError(t, err) + RequireEqualJSON(t, []byte("{\"id\":999,\"jsonrpc\":\"2.0\",\"result\":[]}"), resRaw) + RequireEqualJSON(t, resRaw, resCache) + require.Equal(t, 2, countRequests(backend, "debug_getRawReceipts")) + }) + + t.Run("debug_getRawReceipts with more than 0 receipts should be cached", func(t *testing.T) { + backend.Reset() + hdlr.SetRoute("debug_getRawReceipts", "999", []string{"a"}) + resRaw, _, err := client.SendRPC("debug_getRawReceipts", []interface{}{"0x88420081ab9c6d50dc57af36b541c6b8a7b3e9c0d837b0414512c4c5883560bb"}) + require.NoError(t, err) + resCache, _, err := client.SendRPC("debug_getRawReceipts", []interface{}{"0x88420081ab9c6d50dc57af36b541c6b8a7b3e9c0d837b0414512c4c5883560bb"}) + require.NoError(t, err) + RequireEqualJSON(t, []byte("{\"id\":999,\"jsonrpc\":\"2.0\",\"result\":[\"a\"]}"), resRaw) + RequireEqualJSON(t, resRaw, resCache) + require.Equal(t, 1, countRequests(backend, "debug_getRawReceipts")) + }) } func TestBatchCaching(t *testing.T) { diff --git a/proxyd/integration_tests/mock_backend_test.go b/proxyd/integration_tests/mock_backend_test.go index ade879c6ee847..bf45d03f1cbb2 100644 --- a/proxyd/integration_tests/mock_backend_test.go +++ b/proxyd/integration_tests/mock_backend_test.go @@ -77,6 +77,7 @@ func (h *BatchRPCResponseRouter) SetRoute(method string, id string, result inter switch result.(type) { case string: + case []string: case nil: break default: diff --git a/proxyd/integration_tests/testdata/caching.toml b/proxyd/integration_tests/testdata/caching.toml index f3c132763caf6..41bc65b9a785a 100644 --- a/proxyd/integration_tests/testdata/caching.toml +++ b/proxyd/integration_tests/testdata/caching.toml @@ -33,3 +33,4 @@ eth_getTransactionByHash = "main" eth_getTransactionByBlockHashAndIndex = "main" eth_getUncleByBlockHashAndIndex = "main" eth_getTransactionReceipt = "main" +debug_getRawReceipts = "main" diff --git a/proxyd/integration_tests/testdata/consensus_responses.yml b/proxyd/integration_tests/testdata/consensus_responses.yml index e4720b00153be..642c3340f04bc 100644 --- a/proxyd/integration_tests/testdata/consensus_responses.yml +++ b/proxyd/integration_tests/testdata/consensus_responses.yml @@ -185,6 +185,27 @@ } } - method: debug_getRawReceipts + block: 0x55 + response: > + { + "jsonrpc": "2.0", + "id": 67, + "result": { + "_": "debug_getRawReceipts" + } + } +- method: debug_getRawReceipts + block: 0xc6ef2fc5426d6ad6fd9e2a26abeab0aa2411b7ab17f30a99d3cb96aed1d1055b + response: > + { + "jsonrpc": "2.0", + "id": 67, + "result": { + "_": "debug_getRawReceipts" + } + } +- method: debug_getRawReceipts + block: 0x101 response: > { "jsonrpc": "2.0", diff --git a/proxyd/integration_tests/testdata/size_limits.toml b/proxyd/integration_tests/testdata/size_limits.toml new file mode 100644 index 0000000000000..bd4afab534b94 --- /dev/null +++ b/proxyd/integration_tests/testdata/size_limits.toml @@ -0,0 +1,21 @@ +whitelist_error_message = "rpc method is not whitelisted custom message" + +[server] +rpc_port = 8545 +max_request_body_size_bytes = 150 + +[backend] +response_timeout_seconds = 1 +max_response_size_bytes = 1 + +[backends] +[backends.good] +rpc_url = "$GOOD_BACKEND_RPC_URL" +ws_url = "$GOOD_BACKEND_RPC_URL" + +[backend_groups] +[backend_groups.main] +backends = ["good"] + +[rpc_method_mappings] +eth_chainId = "main" \ No newline at end of file diff --git a/proxyd/integration_tests/validation_test.go b/proxyd/integration_tests/validation_test.go index fed2c8aa447c2..5f7d5aefacaba 100644 --- a/proxyd/integration_tests/validation_test.go +++ b/proxyd/integration_tests/validation_test.go @@ -1,6 +1,7 @@ package integration_tests import ( + "fmt" "os" "strings" "testing" @@ -227,6 +228,31 @@ func TestBatchRPCValidation(t *testing.T) { } } +func TestSizeLimits(t *testing.T) { + goodBackend := NewMockBackend(BatchedResponseHandler(200, goodResponse)) + defer goodBackend.Close() + + require.NoError(t, os.Setenv("GOOD_BACKEND_RPC_URL", goodBackend.URL())) + + config := ReadConfig("size_limits") + client := NewProxydClient("http://127.0.0.1:8545") + _, shutdown, err := proxyd.Start(config) + require.NoError(t, err) + defer shutdown() + + payload := strings.Repeat("barf", 1024*1024) + out, code, err := client.SendRequest([]byte(fmt.Sprintf(`{"jsonrpc": "2.0", "method": "eth_chainId", "params": [%s], "id": 1}`, payload))) + require.NoError(t, err) + require.Equal(t, `{"jsonrpc":"2.0","error":{"code":-32021,"message":"request body too large"},"id":null}`, strings.TrimSpace(string(out))) + require.Equal(t, 413, code) + + // The default response is already over the size limit in size_limits.toml. + out, code, err = client.SendRequest([]byte(`{"jsonrpc": "2.0", "method": "eth_chainId", "params": [], "id": 1}`)) + require.NoError(t, err) + require.Equal(t, `{"jsonrpc":"2.0","error":{"code":-32020,"message":"backend response too large"},"id":1}`, strings.TrimSpace(string(out))) + require.Equal(t, 500, code) +} + func asArray(in ...string) string { return "[" + strings.Join(in, ",") + "]" } diff --git a/proxyd/methods.go b/proxyd/methods.go index ffaf89dd60bcd..08ea773288ab2 100644 --- a/proxyd/methods.go +++ b/proxyd/methods.go @@ -17,9 +17,10 @@ type RPCMethodHandler interface { } type StaticMethodHandler struct { - cache Cache - m sync.RWMutex - filter func(*RPCReq) bool + cache Cache + m sync.RWMutex + filterGet func(*RPCReq) bool + filterPut func(*RPCReq, *RPCRes) bool } func (e *StaticMethodHandler) key(req *RPCReq) string { @@ -34,7 +35,7 @@ func (e *StaticMethodHandler) GetRPCMethod(ctx context.Context, req *RPCReq) (*R if e.cache == nil { return nil, nil } - if e.filter != nil && !e.filter(req) { + if e.filterGet != nil && !e.filterGet(req) { return nil, nil } @@ -67,7 +68,12 @@ func (e *StaticMethodHandler) PutRPCMethod(ctx context.Context, req *RPCReq, res if e.cache == nil { return nil } - if e.filter != nil && !e.filter(req) { + // if there is a filter on get, we don't want to cache it because its irretrievable + if e.filterGet != nil && !e.filterGet(req) { + return nil + } + // response filter + if e.filterPut != nil && !e.filterPut(req, res) { return nil } diff --git a/proxyd/proxyd.go b/proxyd/proxyd.go index 853a38a54cffa..87d9055970235 100644 --- a/proxyd/proxyd.go +++ b/proxyd/proxyd.go @@ -130,6 +130,18 @@ func Start(config *Config) (*Server, func(), error) { } opts = append(opts, WithBasicAuth(cfg.Username, passwordVal)) } + + headers := map[string]string{} + for headerName, headerValue := range cfg.Headers { + headerValue, err := ReadFromEnvOrConfig(headerValue) + if err != nil { + return nil, nil, err + } + + headers[headerName] = headerValue + } + opts = append(opts, WithHeaders(headers)) + tlsConfig, err := configureBackendTLS(cfg) if err != nil { return nil, nil, err @@ -144,6 +156,7 @@ func Start(config *Config) (*Server, func(), error) { opts = append(opts, WithProxydIP(os.Getenv("PROXYD_IP"))) opts = append(opts, WithConsensusSkipPeerCountCheck(cfg.ConsensusSkipPeerCountCheck)) opts = append(opts, WithConsensusForcedCandidate(cfg.ConsensusForcedCandidate)) + opts = append(opts, WithWeight(cfg.Weight)) receiptsTarget, err := ReadFromEnvOrConfig(cfg.ConsensusReceiptsTarget) if err != nil { @@ -174,11 +187,12 @@ func Start(config *Config) (*Server, func(), error) { } backends = append(backends, backendsByName[bName]) } - group := &BackendGroup{ - Name: bgName, - Backends: backends, + + backendGroups[bgName] = &BackendGroup{ + Name: bgName, + Backends: backends, + WeightedRouting: bg.WeightedRouting, } - backendGroups[bgName] = group } var wsBackendGroup *BackendGroup @@ -235,6 +249,7 @@ func Start(config *Config) (*Server, func(), error) { resolvedAuth, secondsToDuration(config.Server.TimeoutSeconds), config.Server.MaxUpstreamBatchSize, + config.Server.EnableXServedByHeader, rpcCache, config.RateLimit, config.SenderRateLimit, diff --git a/proxyd/reader.go b/proxyd/reader.go new file mode 100644 index 0000000000000..b16301f1f0870 --- /dev/null +++ b/proxyd/reader.go @@ -0,0 +1,32 @@ +package proxyd + +import ( + "errors" + "io" +) + +var ErrLimitReaderOverLimit = errors.New("over read limit") + +func LimitReader(r io.Reader, n int64) io.Reader { return &LimitedReader{r, n} } + +// A LimitedReader reads from R but limits the amount of +// data returned to just N bytes. Each call to Read +// updates N to reflect the new amount remaining. +// Unlike the standard library version, Read returns +// ErrLimitReaderOverLimit when N <= 0. +type LimitedReader struct { + R io.Reader // underlying reader + N int64 // max bytes remaining +} + +func (l *LimitedReader) Read(p []byte) (int, error) { + if l.N <= 0 { + return 0, ErrLimitReaderOverLimit + } + if int64(len(p)) > l.N { + p = p[0:l.N] + } + n, err := l.R.Read(p) + l.N -= int64(n) + return n, err +} diff --git a/proxyd/reader_test.go b/proxyd/reader_test.go new file mode 100644 index 0000000000000..2ee23456edfc1 --- /dev/null +++ b/proxyd/reader_test.go @@ -0,0 +1,43 @@ +package proxyd + +import ( + "github.com/stretchr/testify/require" + "io" + "strings" + "testing" +) + +func TestLimitReader(t *testing.T) { + data := "hellohellohellohello" + r := LimitReader(strings.NewReader(data), 3) + buf := make([]byte, 3) + + // Buffer reads OK + n, err := r.Read(buf) + require.NoError(t, err) + require.Equal(t, 3, n) + + // Buffer is over limit + n, err = r.Read(buf) + require.Equal(t, ErrLimitReaderOverLimit, err) + require.Equal(t, 0, n) + + // Buffer on initial read is over size + buf = make([]byte, 16) + r = LimitReader(strings.NewReader(data), 3) + n, err = r.Read(buf) + require.NoError(t, err) + require.Equal(t, 3, n) + + // test with read all where the limit is less than the data + r = LimitReader(strings.NewReader(data), 3) + out, err := io.ReadAll(r) + require.Equal(t, ErrLimitReaderOverLimit, err) + require.Equal(t, "hel", string(out)) + + // test with read all where the limit is more than the data + r = LimitReader(strings.NewReader(data), 21) + out, err = io.ReadAll(r) + require.NoError(t, err) + require.Equal(t, data, string(out)) +} diff --git a/proxyd/rewriter.go b/proxyd/rewriter.go index 98b59ec1d72b1..605787eff3128 100644 --- a/proxyd/rewriter.go +++ b/proxyd/rewriter.go @@ -66,25 +66,26 @@ func RewriteRequest(rctx RewriteContext, req *RPCReq, res *RPCRes) (RewriteResul "eth_newFilter": return rewriteRange(rctx, req, res, 0) case "debug_getRawReceipts", "consensus_getReceipts": - return rewriteParam(rctx, req, res, 0, true) + return rewriteParam(rctx, req, res, 0, true, false) case "eth_getBalance", "eth_getCode", "eth_getTransactionCount", "eth_call": - return rewriteParam(rctx, req, res, 1, false) - case "eth_getStorageAt": - return rewriteParam(rctx, req, res, 2, false) + return rewriteParam(rctx, req, res, 1, false, true) + case "eth_getStorageAt", + "eth_getProof": + return rewriteParam(rctx, req, res, 2, false, true) case "eth_getBlockTransactionCountByNumber", "eth_getUncleCountByBlockNumber", "eth_getBlockByNumber", "eth_getTransactionByBlockNumberAndIndex", "eth_getUncleByBlockNumberAndIndex": - return rewriteParam(rctx, req, res, 0, false) + return rewriteParam(rctx, req, res, 0, false, false) } return RewriteNone, nil } -func rewriteParam(rctx RewriteContext, req *RPCReq, res *RPCRes, pos int, required bool) (RewriteResult, error) { +func rewriteParam(rctx RewriteContext, req *RPCReq, res *RPCRes, pos int, required bool, blockNrOrHash bool) (RewriteResult, error) { var p []interface{} err := json.Unmarshal(req.Params, &p) if err != nil { @@ -99,13 +100,38 @@ func rewriteParam(rctx RewriteContext, req *RPCReq, res *RPCRes, pos int, requir return RewriteNone, nil } - s, ok := p[pos].(string) - if !ok { - return RewriteOverrideError, errors.New("expected string") - } - val, rw, err := rewriteTag(rctx, s) - if err != nil { - return RewriteOverrideError, err + // support for https://eips.ethereum.org/EIPS/eip-1898 + var val interface{} + var rw bool + if blockNrOrHash { + bnh, err := remarshalBlockNumberOrHash(p[pos]) + if err != nil { + // fallback to string + s, ok := p[pos].(string) + if ok { + val, rw, err = rewriteTag(rctx, s) + if err != nil { + return RewriteOverrideError, err + } + } else { + return RewriteOverrideError, errors.New("expected BlockNumberOrHash or string") + } + } else { + val, rw, err = rewriteTagBlockNumberOrHash(rctx, bnh) + if err != nil { + return RewriteOverrideError, err + } + } + } else { + s, ok := p[pos].(string) + if !ok { + return RewriteOverrideError, errors.New("expected string") + } + + val, rw, err = rewriteTag(rctx, s) + if err != nil { + return RewriteOverrideError, err + } } if rw { @@ -210,14 +236,23 @@ func rewriteTagMap(rctx RewriteContext, m map[string]interface{}, key string) (b return false, nil } -func rewriteTag(rctx RewriteContext, current string) (string, bool, error) { +func remarshalBlockNumberOrHash(current interface{}) (*rpc.BlockNumberOrHash, error) { jv, err := json.Marshal(current) if err != nil { - return "", false, err + return nil, err } var bnh rpc.BlockNumberOrHash err = bnh.UnmarshalJSON(jv) + if err != nil { + return nil, err + } + + return &bnh, nil +} + +func rewriteTag(rctx RewriteContext, current string) (string, bool, error) { + bnh, err := remarshalBlockNumberOrHash(current) if err != nil { return "", false, err } @@ -245,3 +280,31 @@ func rewriteTag(rctx RewriteContext, current string) (string, bool, error) { return current, false, nil } + +func rewriteTagBlockNumberOrHash(rctx RewriteContext, current *rpc.BlockNumberOrHash) (*rpc.BlockNumberOrHash, bool, error) { + // this is a hash, not a block number + if current.BlockNumber == nil { + return current, false, nil + } + + switch *current.BlockNumber { + case rpc.PendingBlockNumber, + rpc.EarliestBlockNumber: + return current, false, nil + case rpc.FinalizedBlockNumber: + bn := rpc.BlockNumberOrHashWithNumber(rpc.BlockNumber(rctx.finalized)) + return &bn, true, nil + case rpc.SafeBlockNumber: + bn := rpc.BlockNumberOrHashWithNumber(rpc.BlockNumber(rctx.safe)) + return &bn, true, nil + case rpc.LatestBlockNumber: + bn := rpc.BlockNumberOrHashWithNumber(rpc.BlockNumber(rctx.latest)) + return &bn, true, nil + default: + if current.BlockNumber.Int64() > int64(rctx.latest) { + return nil, false, ErrRewriteBlockOutOfRange + } + } + + return current, false, nil +} diff --git a/proxyd/rewriter_test.go b/proxyd/rewriter_test.go index 94bc5c962d336..1f0d80ba25c99 100644 --- a/proxyd/rewriter_test.go +++ b/proxyd/rewriter_test.go @@ -5,7 +5,9 @@ import ( "strings" "testing" + "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common/hexutil" + "github.com/ethereum/go-ethereum/rpc" "github.com/stretchr/testify/require" ) @@ -282,12 +284,14 @@ func TestRewriteRequest(t *testing.T) { }, expected: RewriteOverrideRequest, check: func(t *testing.T, args args) { - var p []string + var p []interface{} err := json.Unmarshal(args.req.Params, &p) require.Nil(t, err) require.Equal(t, 2, len(p)) require.Equal(t, "0x123", p[0]) - require.Equal(t, hexutil.Uint64(100).String(), p[1]) + bnh, err := remarshalBlockNumberOrHash(p[1]) + require.Nil(t, err) + require.Equal(t, rpc.BlockNumberOrHashWithNumber(100), *bnh) }, }, { @@ -314,12 +318,14 @@ func TestRewriteRequest(t *testing.T) { }, expected: RewriteOverrideRequest, check: func(t *testing.T, args args) { - var p []string + var p []interface{} err := json.Unmarshal(args.req.Params, &p) require.Nil(t, err) require.Equal(t, 2, len(p)) require.Equal(t, "0x123", p[0]) - require.Equal(t, hexutil.Uint64(100).String(), p[1]) + bnh, err := remarshalBlockNumberOrHash(p[1]) + require.Nil(t, err) + require.Equal(t, rpc.BlockNumberOrHashWithNumber(100), *bnh) }, }, { @@ -359,13 +365,15 @@ func TestRewriteRequest(t *testing.T) { }, expected: RewriteOverrideRequest, check: func(t *testing.T, args args) { - var p []string + var p []interface{} err := json.Unmarshal(args.req.Params, &p) require.Nil(t, err) require.Equal(t, 3, len(p)) require.Equal(t, "0x123", p[0]) require.Equal(t, "5", p[1]) - require.Equal(t, hexutil.Uint64(100).String(), p[2]) + bnh, err := remarshalBlockNumberOrHash(p[2]) + require.Nil(t, err) + require.Equal(t, rpc.BlockNumberOrHashWithNumber(100), *bnh) }, }, { @@ -377,13 +385,15 @@ func TestRewriteRequest(t *testing.T) { }, expected: RewriteOverrideRequest, check: func(t *testing.T, args args) { - var p []string + var p []interface{} err := json.Unmarshal(args.req.Params, &p) require.Nil(t, err) require.Equal(t, 3, len(p)) require.Equal(t, "0x123", p[0]) require.Equal(t, "5", p[1]) - require.Equal(t, hexutil.Uint64(100).String(), p[2]) + bnh, err := remarshalBlockNumberOrHash(p[2]) + require.Nil(t, err) + require.Equal(t, rpc.BlockNumberOrHashWithNumber(100), *bnh) }, }, { @@ -517,6 +527,88 @@ func TestRewriteRequest(t *testing.T) { }, expected: RewriteNone, }, + // eip1898 + { + name: "eth_getStorageAt using rpc.BlockNumberOrHash at genesis (blockNumber)", + args: args{ + rctx: RewriteContext{latest: hexutil.Uint64(100)}, + req: &RPCReq{Method: "eth_getStorageAt", Params: mustMarshalJSON([]interface{}{ + "0xae851f927ee40de99aabb7461c00f9622ab91d60", + "10", + map[string]interface{}{ + "blockNumber": "0x0", + }})}, + res: nil, + }, + expected: RewriteNone, + }, + { + name: "eth_getStorageAt using rpc.BlockNumberOrHash at genesis (hash)", + args: args{ + rctx: RewriteContext{latest: hexutil.Uint64(100)}, + req: &RPCReq{Method: "eth_getStorageAt", Params: mustMarshalJSON([]interface{}{ + "0xae851f927ee40de99aabb7461c00f9622ab91d60", + "10", + map[string]interface{}{ + "blockHash": "0xd4e56740f876aef8c010b86a40d5f56745a118d0906a34e69aec8c0db1cb8fa3", + "requireCanonical": true, + }})}, + res: nil, + }, + expected: RewriteNone, + check: func(t *testing.T, args args) { + var p []interface{} + err := json.Unmarshal(args.req.Params, &p) + require.Nil(t, err) + require.Equal(t, 3, len(p)) + require.Equal(t, "0xae851f927ee40de99aabb7461c00f9622ab91d60", p[0]) + require.Equal(t, "10", p[1]) + bnh, err := remarshalBlockNumberOrHash(p[2]) + require.Nil(t, err) + require.Equal(t, rpc.BlockNumberOrHashWithHash(common.HexToHash("0xd4e56740f876aef8c010b86a40d5f56745a118d0906a34e69aec8c0db1cb8fa3"), true), *bnh) + require.True(t, bnh.RequireCanonical) + }, + }, + { + name: "eth_getStorageAt using rpc.BlockNumberOrHash at latest (blockNumber)", + args: args{ + rctx: RewriteContext{latest: hexutil.Uint64(100)}, + req: &RPCReq{Method: "eth_getStorageAt", Params: mustMarshalJSON([]interface{}{ + "0xae851f927ee40de99aabb7461c00f9622ab91d60", + "10", + map[string]interface{}{ + "blockNumber": "latest", + }})}, + res: nil, + }, + expected: RewriteOverrideRequest, + check: func(t *testing.T, args args) { + var p []interface{} + err := json.Unmarshal(args.req.Params, &p) + require.Nil(t, err) + require.Equal(t, 3, len(p)) + require.Equal(t, "0xae851f927ee40de99aabb7461c00f9622ab91d60", p[0]) + require.Equal(t, "10", p[1]) + bnh, err := remarshalBlockNumberOrHash(p[2]) + require.Nil(t, err) + require.Equal(t, rpc.BlockNumberOrHashWithNumber(100), *bnh) + }, + }, + { + name: "eth_getStorageAt using rpc.BlockNumberOrHash out of range", + args: args{ + rctx: RewriteContext{latest: hexutil.Uint64(100)}, + req: &RPCReq{Method: "eth_getStorageAt", Params: mustMarshalJSON([]interface{}{ + "0xae851f927ee40de99aabb7461c00f9622ab91d60", + "10", + map[string]interface{}{ + "blockNumber": "0x111", + }})}, + res: nil, + }, + expected: RewriteOverrideError, + expectedErr: ErrRewriteBlockOutOfRange, + }, } // generalize tests for other methods with same interface and behavior @@ -528,6 +620,7 @@ func TestRewriteRequest(t *testing.T) { tests = generalize(tests, "eth_getBlockByNumber", "eth_getUncleCountByBlockNumber") tests = generalize(tests, "eth_getBlockByNumber", "eth_getTransactionByBlockNumberAndIndex") tests = generalize(tests, "eth_getBlockByNumber", "eth_getUncleByBlockNumberAndIndex") + tests = generalize(tests, "eth_getStorageSlotAt", "eth_getProof") for _, tt := range tests { t.Run(tt.name, func(t *testing.T) { diff --git a/proxyd/server.go b/proxyd/server.go index 2c45aa72d3bd7..5d262da40c897 100644 --- a/proxyd/server.go +++ b/proxyd/server.go @@ -31,18 +31,20 @@ import ( ) const ( - ContextKeyAuth = "authorization" - ContextKeyReqID = "req_id" - ContextKeyXForwardedFor = "x_forwarded_for" - MaxBatchRPCCallsHardLimit = 100 - cacheStatusHdr = "X-Proxyd-Cache-Status" - defaultRPCTimeout = 10 * time.Second - defaultBodySizeLimit = 256 * opt.KiB - defaultWSHandshakeTimeout = 10 * time.Second - defaultWSReadTimeout = 2 * time.Minute - defaultWSWriteTimeout = 10 * time.Second - maxRequestBodyLogLen = 2000 - defaultMaxUpstreamBatchSize = 10 + ContextKeyAuth = "authorization" + ContextKeyReqID = "req_id" + ContextKeyXForwardedFor = "x_forwarded_for" + DefaultMaxBatchRPCCallsLimit = 100 + MaxBatchRPCCallsHardLimit = 1000 + cacheStatusHdr = "X-Proxyd-Cache-Status" + defaultRPCTimeout = 10 * time.Second + defaultBodySizeLimit = 256 * opt.KiB + defaultWSHandshakeTimeout = 10 * time.Second + defaultWSReadTimeout = 2 * time.Minute + defaultWSWriteTimeout = 10 * time.Second + maxRequestBodyLogLen = 2000 + defaultMaxUpstreamBatchSize = 10 + defaultRateLimitHeader = "X-Forwarded-For" ) var emptyArrayResponse = json.RawMessage("[]") @@ -59,6 +61,7 @@ type Server struct { timeout time.Duration maxUpstreamBatchSize int maxBatchSize int + enableServedByHeader bool upgrader *websocket.Upgrader mainLim FrontendRateLimiter overrideLims map[string]FrontendRateLimiter @@ -71,6 +74,7 @@ type Server struct { wsServer *http.Server cache RPCCache srvMu sync.Mutex + rateLimitHeader string } type limiterFunc func(method string) bool @@ -84,6 +88,7 @@ func NewServer( authenticatedPaths map[string]string, timeout time.Duration, maxUpstreamBatchSize int, + enableServedByHeader bool, cache RPCCache, rateLimitConfig RateLimitConfig, senderRateLimitConfig SenderRateLimitConfig, @@ -108,7 +113,11 @@ func NewServer( maxUpstreamBatchSize = defaultMaxUpstreamBatchSize } - if maxBatchSize == 0 || maxBatchSize > MaxBatchRPCCallsHardLimit { + if maxBatchSize == 0 { + maxBatchSize = DefaultMaxBatchRPCCallsLimit + } + + if maxBatchSize > MaxBatchRPCCallsHardLimit { maxBatchSize = MaxBatchRPCCallsHardLimit } @@ -161,6 +170,11 @@ func NewServer( senderLim = limiterFactory(time.Duration(senderRateLimitConfig.Interval), senderRateLimitConfig.Limit, "senders") } + rateLimitHeader := defaultRateLimitHeader + if rateLimitConfig.IPHeaderOverride != "" { + rateLimitHeader = rateLimitConfig.IPHeaderOverride + } + return &Server{ BackendGroups: backendGroups, wsBackendGroup: wsBackendGroup, @@ -170,6 +184,7 @@ func NewServer( authenticatedPaths: authenticatedPaths, timeout: timeout, maxUpstreamBatchSize: maxUpstreamBatchSize, + enableServedByHeader: enableServedByHeader, cache: cache, enableRequestLog: enableRequestLog, maxRequestBodyLogLen: maxRequestBodyLogLen, @@ -184,6 +199,7 @@ func NewServer( allowedChainIds: senderRateLimitConfig.AllowedChainIds, limExemptOrigins: limExemptOrigins, limExemptUserAgents: limExemptUserAgents, + rateLimitHeader: rateLimitHeader, }, nil } @@ -311,7 +327,13 @@ func (s *Server) HandleRPC(w http.ResponseWriter, r *http.Request) { "remote_ip", xff, ) - body, err := io.ReadAll(io.LimitReader(r.Body, s.maxBodySize)) + body, err := io.ReadAll(LimitReader(r.Body, s.maxBodySize)) + if errors.Is(err, ErrLimitReaderOverLimit) { + log.Error("request body too large", "req_id", GetReqID(ctx)) + RecordRPCError(ctx, BackendProxyd, MethodUnknown, ErrRequestBodyTooLarge) + writeRPCError(ctx, w, nil, ErrRequestBodyTooLarge) + return + } if err != nil { log.Error("error reading request body", "err", err) writeRPCError(ctx, w, nil, ErrInternal) @@ -349,7 +371,7 @@ func (s *Server) HandleRPC(w http.ResponseWriter, r *http.Request) { return } - batchRes, batchContainsCached, err := s.handleBatchRPC(ctx, reqs, isLimited, true) + batchRes, batchContainsCached, servedBy, err := s.handleBatchRPC(ctx, reqs, isLimited, true) if err == context.DeadlineExceeded { writeRPCError(ctx, w, nil, ErrGatewayTimeout) return @@ -363,14 +385,16 @@ func (s *Server) HandleRPC(w http.ResponseWriter, r *http.Request) { writeRPCError(ctx, w, nil, ErrInternal) return } - + if s.enableServedByHeader { + w.Header().Set("x-served-by", servedBy) + } setCacheHeader(w, batchContainsCached) writeBatchRPCRes(ctx, w, batchRes) return } rawBody := json.RawMessage(body) - backendRes, cached, err := s.handleBatchRPC(ctx, []json.RawMessage{rawBody}, isLimited, false) + backendRes, cached, servedBy, err := s.handleBatchRPC(ctx, []json.RawMessage{rawBody}, isLimited, false) if err != nil { if errors.Is(err, ErrConsensusGetReceiptsCantBeBatched) || errors.Is(err, ErrConsensusGetReceiptsInvalidTarget) { @@ -380,11 +404,14 @@ func (s *Server) HandleRPC(w http.ResponseWriter, r *http.Request) { writeRPCError(ctx, w, nil, ErrInternal) return } + if s.enableServedByHeader { + w.Header().Set("x-served-by", servedBy) + } setCacheHeader(w, cached) writeRPCRes(ctx, w, backendRes[0]) } -func (s *Server) handleBatchRPC(ctx context.Context, reqs []json.RawMessage, isLimited limiterFunc, isBatch bool) ([]*RPCRes, bool, error) { +func (s *Server) handleBatchRPC(ctx context.Context, reqs []json.RawMessage, isLimited limiterFunc, isBatch bool) ([]*RPCRes, bool, string, error) { // A request set is transformed into groups of batches. // Each batch group maps to a forwarded JSON-RPC batch request (subject to maxUpstreamBatchSize constraints) // A groupID is used to decouple Requests that have duplicate ID so they're not part of the same batch that's @@ -470,6 +497,7 @@ func (s *Server) handleBatchRPC(ctx context.Context, reqs []json.RawMessage, isL batches[batchGroup] = append(batches[batchGroup], batchElem{parsedReq, i}) } + servedBy := make(map[string]bool, 0) var cached bool for group, batch := range batches { var cacheMisses []batchElem @@ -494,17 +522,18 @@ func (s *Server) handleBatchRPC(ctx context.Context, reqs []json.RawMessage, isL "batch_index", i, ) batchRPCShortCircuitsTotal.Inc() - return nil, false, context.DeadlineExceeded + return nil, false, "", context.DeadlineExceeded } start := i * s.maxUpstreamBatchSize end := int(math.Min(float64(start+s.maxUpstreamBatchSize), float64(len(cacheMisses)))) elems := cacheMisses[start:end] - res, err := s.BackendGroups[group.backendGroup].Forward(ctx, createBatchRequest(elems), isBatch) + res, sb, err := s.BackendGroups[group.backendGroup].Forward(ctx, createBatchRequest(elems), isBatch) + servedBy[sb] = true if err != nil { if errors.Is(err, ErrConsensusGetReceiptsCantBeBatched) || errors.Is(err, ErrConsensusGetReceiptsInvalidTarget) { - return nil, false, err + return nil, false, "", err } log.Error( "error forwarding RPC batch", @@ -536,7 +565,15 @@ func (s *Server) handleBatchRPC(ctx context.Context, reqs []json.RawMessage, isL } } - return responses, cached, nil + servedByString := "" + for sb, _ := range servedBy { + if servedByString != "" { + servedByString += ", " + } + servedByString += sb + } + + return responses, cached, servedByString, nil } func (s *Server) HandleWS(w http.ResponseWriter, r *http.Request) { @@ -579,7 +616,7 @@ func (s *Server) HandleWS(w http.ResponseWriter, r *http.Request) { func (s *Server) populateContext(w http.ResponseWriter, r *http.Request) context.Context { vars := mux.Vars(r) authorization := vars["authorization"] - xff := r.Header.Get("X-Forwarded-For") + xff := r.Header.Get(s.rateLimitHeader) if xff == "" { ipPort := strings.Split(r.RemoteAddr, ":") if len(ipPort) == 2 { diff --git a/proxyd/tools/mockserver/handler/handler.go b/proxyd/tools/mockserver/handler/handler.go index 0f6880c853f3b..0f9bfcad63cb0 100644 --- a/proxyd/tools/mockserver/handler/handler.go +++ b/proxyd/tools/mockserver/handler/handler.go @@ -77,7 +77,7 @@ func (mh *MockedHandler) Handler(w http.ResponseWriter, req *http.Request) { for _, r := range requests { method := r["method"] block := "" - if method == "eth_getBlockByNumber" { + if method == "eth_getBlockByNumber" || method == "debug_getRawReceipts" { block = (r["params"].([]interface{})[0]).(string) } diff --git a/proxyd/tools/mockserver/node1.yml b/proxyd/tools/mockserver/node1.yml index c14f328172e1b..313c65349f727 100644 --- a/proxyd/tools/mockserver/node1.yml +++ b/proxyd/tools/mockserver/node1.yml @@ -41,4 +41,12 @@ "hash": "hash34", "number": "0x3" } - } \ No newline at end of file + } +- method: debug_getRawReceipts + block: 0x88420081ab9c6d50dc57af36b541c6b8a7b3e9c0d837b0414512c4c5883560ff + response: > + {"jsonrpc":"2.0","id":1,"result":[]} +- method: debug_getRawReceipts + block: 0x88420081ab9c6d50dc57af36b541c6b8a7b3e9c0d837b0414512c4c5883560bb + response: > + {"jsonrpc":"2.0","id":1,"result":["0x02f902c10183037ec5b9010000000000000000000000000200000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000000000400000000000000000008000000000000000000000000000000000000020000020000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002800000000000000000000000000000000000000000000000200000000000000000000000000000000f901b6f8d994297a60578fd0e13076bf06cfeb2bbcd74f2680d2e1a0e5c486bee358a5fff5e4d70dc5fdaaf14806df125ffde843a8c40db608264812b8a00000000000000000000000000000000000000000000000000000000000000060000000000000000000000000000000000000000000000000000282bde1ac0c0000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000016573937382e393939393939393939393939395334393600000000000000000000f8d994297a60578fd0e13076bf06cfeb2bbcd74f2680d2e1a01309ab74031e37b46ee8ce9ff667a17a5c69a500a05d167e4c89ad8b0bc40bf9b8a0000000000000000000000000cd28ab95ae80b31255b2258a116cd2c1a371e0f3000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000652d2a700000000000000000000000000000000000000000000000000000000000000016573937382e393939393939393939393939395334393600000000000000000000","0x02f9039f01830645cdb9010000000020000000000000001000000000000000008004000000000000004000000000000000000002000000000000000000000000000000000000000000000000000000a00000000000000000000000200000000000000000000000000000000000000000000000400000000000000000000000000000000000000008000000000000000000004000400800000020000000000000000000000002000000000000000000000000000000200000000000040000000000000000000000001000000100100200000002000000000100000000010000020000000000000000000000000010000000000000000000000000000000000000000000000000000008040000f90294f8dc944638ac6b5727a8b9586d3eba5b44be4b74ed41fcf863a02ac69ee804d9a7a0984249f508dfab7cb2534b465b6ce1580f99a38ba9c5e631a0000000000000000000000000f08f78880122a9ee99f4f68dcab02177aeb08160a0000000000000000000000000f08f78880122a9ee99f4f68dcab02177aeb08160b8600000000000000000000000000000000000000000000000000032cdc63449c00000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000000f8dc944638ac6b5727a8b9586d3eba5b44be4b74ed41fcf863a031b2166ff604fc5672ea5df08a78081d2bc6d746cadce880747f3643d819e83da0000000000000000000000000f08f78880122a9ee99f4f68dcab02177aeb08160a0000000000000000000000000f08f78880122a9ee99f4f68dcab02177aeb08160b8600000000000000000000000000000000000000000000000000032cdc63449c00000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000000f85a947ad11bb9216bc9dc4cbd488d7618cbfd433d1e75f842a04641df4a962071e12719d8c8c8e5ac7fc4d97b927346a3d7a335b1f7517e133ca0e4bac2a8774c733b2c6da6ddf718b53614f36417dfaac90b23d2747d82d2251580f87a947fd7eea37c53abf356cc80e71144d62cd8af27d3f842a0db5c7652857aa163daadd670e116628fb42e869d8ac4251ef8971d9e5727df1ba04bd009c947444055f7e29f16c227e544387b9de8b571888d37f50becee99d76ea00000000000000000000000000000000000000000000000000000000000000001","0x02f90327018307aa96b9010000000000000000000000000028000000000000000000000000000000400000000000000000000000000000000000000000000000020000000000000000000000000000100000000000000000000000000000000000000000000000000000004000001000000000000000000000000000000000004000000000000000000000000000000000008000000000000000000000000000000000000000000000008000000000021000000000000000000000002040000000000000000000000000000000000000000000000000000000000000008000000000000000001000000000000000000000000000010000000000000000000000000000000000000000004000f9021cf9013c94af4159a80b6cc41ed517db1c453d1ef5c2e4db72f863a05e3c1311ea442664e8b1611bfabef659120ea7a0a2cfc0667700bebc69cbffe1a000000000000000000000000000000000000000000000000000000000000b574ea0eef6d16b5a91e0c5aa2df75fbb865f2be353c5052294a97ee3522d6b1ed674bfb8c00000000000000000000000006bebc4925716945d46f0ec336d5c2564f419682c000000000000000000000000000000000000000000000000000000000000000c000000000000000000000000b47d4ece2bd3d6457b9abcde547e332832a6881b5e8697f86a16fd1e3006843062eda71ce901c9f888b5abb4736b9ca9bb36748e000000000000000000000000000000000000000000000000000000000000000b00000000000000000000000000000000000000000000000000000000652d2a70f8db946bebc4925716945d46f0ec336d5c2564f419682cf842a0ff64905f73a67fb594e0f940a8075a860db489ad991e032f48c81123eb52d60ba000000000000000000000000000000000000000000000000000000000000b574eb88000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000034a36c4ece2bd3d6457b9abcde547e332832a6770a0000000000000000000000000000000000000000000000000095094d8053e000000000000000000000000000","0x02f901a70183083234b9010000000000000000040000000000000000000000020000100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000008000000000000004000000000000000000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000040000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000800000000400000001000000000000000000000000000000000000000000000f89df89b94326c977e6efc84e512bb9c30f76e30c160ed06fbf863a0ddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa00000000000000000000000004281ecf07378ee595c564a59048801330f3084eea0000000000000000000000000cd5d6cadfd3b4c77415859a5d6999f2eea1da5d4a0000000000000000000000000000000000000000000000001158e460913d00000","0x02f9040a0183094189b9010000000000000000000000100000000000000000000000000000000000000000000002000000000010000000000000000000000000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000000000000000000004000000000000000000008000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000000008008000000000000000000000000000f902fff902fc94be72771b59f99adc9c07a43295fcada66cb865b9f842a035ee444266c4bfac0b9704ee4fc68807fe38d1e96b299a097442f8169f48d57da00000000000000000000000000000000000000000000000000000000000000027b902a000000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000028000000000000000000000000000000000000000000000000000000000652d2a700000000000000000000000000000000000000000000000000000000000000027000000000000000000000000bc365d43d4761fd03738ebefa5ff3d7ccf8256a70000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000018000000000000000000000000000000000000000000000000000000000000001c000000000000000000000000000000000000000000000000000038d7ea4c6800000000000000000000000000000000000000000000000000000000000652e78100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000183635326432363837663661356263626235613934643639370000000000000000000000000000000000000000000000000000000000000000000000000000001836353235626563643837396139613163653935363364643800000000000000000000000000000000000000000000000000000000000000000000000000000000","0x02f9039f01830c0891b9010000000020000000000000001000000000000000008004000000000000004000000000000000000002000000000000000000000000000000000000000000000000000000000000000000000004000000200000000000000000000000000000000000000000000000400000000040000800000000000000000000000008000000000000000040004000400800000020200000000000000000000002000000000000000200000000000000200000000000040000800000000000000000000000000100000000000002000000000100000000000000000000000000000200000000000010000000000000000000000000000000000000000000000000000108000000f90294f8dc944638ac6b5727a8b9586d3eba5b44be4b74ed41fcf863a02ac69ee804d9a7a0984249f508dfab7cb2534b465b6ce1580f99a38ba9c5e631a0000000000000000000000000ffb08a46d802102de79b998be6fe0975e44cb212a0000000000000000000000000ffb08a46d802102de79b998be6fe0975e44cb212b8600000000000000000000000000000000000000000000000000032cdc63449c00000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000000f8dc944638ac6b5727a8b9586d3eba5b44be4b74ed41fcf863a031b2166ff604fc5672ea5df08a78081d2bc6d746cadce880747f3643d819e83da0000000000000000000000000ffb08a46d802102de79b998be6fe0975e44cb212a0000000000000000000000000ffb08a46d802102de79b998be6fe0975e44cb212b8600000000000000000000000000000000000000000000000000032cdc63449c00000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000000f85a947ad11bb9216bc9dc4cbd488d7618cbfd433d1e75f842a04641df4a962071e12719d8c8c8e5ac7fc4d97b927346a3d7a335b1f7517e133ca0c48bab3c23e29b52ad3d5b5a41b22448c12d59d5f986b479fdcc485cae9e794a80f87a947fd7eea37c53abf356cc80e71144d62cd8af27d3f842a0db5c7652857aa163daadd670e116628fb42e869d8ac4251ef8971d9e5727df1ba0d6910807a825d1b186bc97aaa5ae83f44bc11533f05f3bd567dd916e5de20de1a00000000000000000000000000000000000000000000000000000000000000001","0x02f9024a01837e0c08b9010000000000800000000000000100000000000000000000000000000000000000000000000000004000000000000200000000000000000000000000000000001000000000000000000000000000000000000000000040000000000040000000000800000000000000000000000000000000000000000000000000000000000000000000000000400020000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000f9013ff9013c94c25708eaf0329888c4db0fa5746647ecca92f257f863a09efce6407f8b9dc575789c1e4cc190f025c452249eb8f7913c49958c9a5535dea000000000000000000000000000000000000000000000000000000000652d2a70a0000000000000000000000000a02d09d454861a0ccd2e8518886cdcec37ecdd2cb8c00000000000000000000000000000000000000000000000000000000000000b220000000000000000000000000000000000000000000000000000000000000b220000000000000000000000000000000000000000000000000000000000000b22000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000066372656174650000000000000000000000000000000000000000000000000000","0x02f9039f018380d310b9010000000020000000000000001000000000000000008404000000000000004000000000000000000002000000000000000000000000000000000040000000000000000000000000000000000000000000200000000000000200000000000000000000000000000000400000000000000000000000000000000000000008000000000000000000004000400800000020000000001000000000000002400000000000000000000000000020200010000000040000000000000000000000000000000100000000400002000000000100000000000000000000000000000000000000000010000000000000000000000000000000000040000000000000000008000000f90294f8dc944638ac6b5727a8b9586d3eba5b44be4b74ed41fcf863a02ac69ee804d9a7a0984249f508dfab7cb2534b465b6ce1580f99a38ba9c5e631a0000000000000000000000000cbee1403a6adee830dfd02d763341687d81482eba0000000000000000000000000cbee1403a6adee830dfd02d763341687d81482ebb8600000000000000000000000000000000000000000000000000032cdc63449c00000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000000f8dc944638ac6b5727a8b9586d3eba5b44be4b74ed41fcf863a031b2166ff604fc5672ea5df08a78081d2bc6d746cadce880747f3643d819e83da0000000000000000000000000cbee1403a6adee830dfd02d763341687d81482eba0000000000000000000000000cbee1403a6adee830dfd02d763341687d81482ebb8600000000000000000000000000000000000000000000000000032cdc63449c00000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000000f85a947ad11bb9216bc9dc4cbd488d7618cbfd433d1e75f842a04641df4a962071e12719d8c8c8e5ac7fc4d97b927346a3d7a335b1f7517e133ca0f9cacd1bc3956dffcb1a7d556066528a92396aa2e7da07a02904b3bfd886661180f87a947fd7eea37c53abf356cc80e71144d62cd8af27d3f842a0db5c7652857aa163daadd670e116628fb42e869d8ac4251ef8971d9e5727df1ba00c4d6405faf20e9cb06cdcc5159705b5a4d42ee7ea60a15f20784e82a0b31786a00000000000000000000000000000000000000000000000000000000000000001","0x02f9010901838210d3b9010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0","0x02f90c3f018388b358b9010000000000000000000000000000000000000040000000000200000000000004100000000002000000000000000000000000001000000000680000010000000009004020200000000008080008000800000000000000002000000000000000000040040000220000800000002080000800000000000000020000002090000000000000008400000000000000000000000000000000280000000200000000000040000000004000020000000000000000000000000000000000000000000000000000021002000008000000000000000000000000000800000000200100000820001005000000000000000000080000000000000000000000000040000000000000f90b34f89b948bd0e58032e5343c888eba4e72332176fffa7371f863a0ddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa00000000000000000000000004ac853547fa1fe3f4690e452b904578f7d46a531a00000000000000000000000000000000000000000000000000000000000000000a0000000000000000000000000000000000000000000000000016345785d8a0000f85894c9b7edc65488bdbb428526b03935090aef40ff03e1a0df21c415b78ed2552cc9971249e32a053abce6087a0ae0fbf3f78db5174a3493a0000000000000000000000000000000000000000000000000000098b591d3ac0ef8d9946f3a314c1279148e53f51af154817c3ef2c827b1e1a0b0c632f55f1e1b3b2c3d82f41ee4716bb4c00f0f5d84cdafc141581bb8757a4fb8a0000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000022000100000000000000000000000000000000000000000000000000000000000493e0000000000000000000000000000000000000000000000000000000000000f8d99436ebea3941907c438ca8ca2b1065deef21ccdaede1a04e41ee13e03cd5e0446487b524fdc48af6acf26c074dacdbdfb6b574b42c8146b8a0000000000000000000000000000000000000000000000000000000000000277a0000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000300000000000000000000000011f66d6864fcce84d5000e1e981dd586766339490000000000000000000000000000000000000000000000000000213ae829dcc5f9019a946f3a314c1279148e53f51af154817c3ef2c827b1e1a0e9bded5f24a4168e4f3bf44e00298c993b22376aad8c58c7dda9718a54cbea82b90160000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000001140000000000000d54278911f66d6864fcce84d5000e1e981dd58676633949277ab92de63eb7d8a652bf80385906812f92d49c5139000000000000000000000000000000000000000000000000000000000000000700000000000000000000000000000000000000000000000000000000000000a07355534400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000016345785d8a0000000000000000000000000000000000000000000000000000000000000000277a00000000000000000000000000000000000000000000000000000000000000144ac853547fa1fe3f4690e452b904578f7d46a531000000000000000000000000000000000000000000000000f9013d9411f66d6864fcce84d5000e1e981dd58676633949f884a0aae74fdfb502b568e3ca6f5aa448a255c90a2f24c4a6104d65ae45f097b37388a00000000000000000000000004ac853547fa1fe3f4690e452b904578f7d46a531a00000000000000000000000000000000000000000000000000000000000000007a0000000000000000000000000000000000000000000000000000000000000277ab8a000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000d540000000000000000000000000000000000000000000000000000000000000028b92de63eb7d8a652bf80385906812f92d49c513911f66d6864fcce84d5000e1e981dd58676633949000000000000000000000000000000000000000000000000f85894c9b7edc65488bdbb428526b03935090aef40ff03e1a0df21c415b78ed2552cc9971249e32a053abce6087a0ae0fbf3f78db5174a3493a00000000000000000000000000000000000000000000000000000381ece38c000f8d9946f3a314c1279148e53f51af154817c3ef2c827b1e1a0b0c632f55f1e1b3b2c3d82f41ee4716bb4c00f0f5d84cdafc141581bb8757a4fb8a0000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000022000100000000000000000000000000000000000000000000000000000000000493e0000000000000000000000000000000000000000000000000000000000000f8d99436ebea3941907c438ca8ca2b1065deef21ccdaede1a04e41ee13e03cd5e0446487b524fdc48af6acf26c074dacdbdfb6b574b42c8146b8a0000000000000000000000000000000000000000000000000000000000000279f0000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000300000000000000000000000011f66d6864fcce84d5000e1e981dd586766339490000000000000000000000000000000000000000000000000000d027724dc000f9019a946f3a314c1279148e53f51af154817c3ef2c827b1e1a0e9bded5f24a4168e4f3bf44e00298c993b22376aad8c58c7dda9718a54cbea82b9016000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000114000000000000ac19278911f66d6864fcce84d5000e1e981dd58676633949279f4c11ccee50b70daa47c41849e45316d975b26102000000000000000000000000000000000000000000000000000000000000000700000000000000000000000000000000000000000000000000000000000000a07355534400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000016345785d8a0000000000000000000000000000000000000000000000000000000000000000277a00000000000000000000000000000000000000000000000000000000000000144ac853547fa1fe3f4690e452b904578f7d46a531000000000000000000000000000000000000000000000000f9013d9411f66d6864fcce84d5000e1e981dd58676633949f884a0aae74fdfb502b568e3ca6f5aa448a255c90a2f24c4a6104d65ae45f097b37388a00000000000000000000000004ac853547fa1fe3f4690e452b904578f7d46a531a00000000000000000000000000000000000000000000000000000000000000007a0000000000000000000000000000000000000000000000000000000000000279fb8a00000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000ac1900000000000000000000000000000000000000000000000000000000000000284c11ccee50b70daa47c41849e45316d975b2610211f66d6864fcce84d5000e1e981dd58676633949000000000000000000000000000000000000000000000000f8bb94593be683204ff3501e6e4851956a2da310e393b6f842a0c1e18b2a3583b6bc0879a3f3f657c41adfb512076938208ec0b389d6d19874cba00000000000000000000000004ac853547fa1fe3f4690e452b904578f7d46a531b8607355534400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000016345785d8a0000000000000000000000000000000000000000000000000000000000000000277a","0x02f901a7018389386bb9010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000008000000000000000000010000000000000000000000000000020000000000000000000800000000000000000000000010000000000000004000000000000000000000000000000000000000000000000000000000000000000000100400000000000000000000000000000400000000000000000000000002000000000000000000000000000000000000000000000000000020000000000000000001000000000000000000000000000000000000000000000000f89df89b946199f797b524166122f1c6e6a78ff321389bb686f863a0ddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa00000000000000000000000000000000000000000000000000000000000000000a0000000000000000000000000e43f4840dad185beef6daa8e7328b521e6a1a2a0a000000000000000000000000000000000000000000000d3c21bcecceda1000000","0x02f908fa01838cb5bdb90100000000004000000000040000000000000000000000005000000022000004000000000000000000000000000000000000000000000000000000000200002000000000000000080000000000080000000000000400004000000000004000000000000000000002010000000000000000000000000008000000000000100000000000000000000000000000000000001000000000000800000000000000200000000a0000000000000000000000100000000000000000080000000000000000000000000002000000000000000000000000200240000000800000000000000000000010000000040000000000000000000000000000000800000000000000000000f907eff9025d9400000000000000adc04c56bf30ac9d3c0aaf14dcf863a09d9af8e38d66c62e2c12f0225249fd9d721c54b83f48d9352c97c6cacdcb6f31a0000000000000000000000000f8de191520e37592aa84c62f650b067805cf1845a0000000000000000000000000ea2b4e7f02b859305093f9f4778a19d66ca176d5b901e0392f9c488837a9a75f4b5a139bed7757ebec5091b7e0b6f1ce70cbbbc75050e50000000000000000000000006f030b74371167d3b71cf3214e749b0d1814c0490000000000000000000000000000000000000000000000000000000000000080000000000000000000000000000000000000000000000000000000000000012000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000001000000000000000000000000d3664b5e72b46eaba722ab6f43c22dbf4018195400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011e1a300000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000010000000000000000000000002715ccea428f8c7694f7e78b2c89cb454c5f7294000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002c68af0bb140000000000000000000000000000f8de191520e37592aa84c62f650b067805cf1845f9025d9400000000000000adc04c56bf30ac9d3c0aaf14dcf863a09d9af8e38d66c62e2c12f0225249fd9d721c54b83f48d9352c97c6cacdcb6f31a00000000000000000000000006f030b74371167d3b71cf3214e749b0d1814c049a0000000000000000000000000ea2b4e7f02b859305093f9f4778a19d66ca176d5b901e0ea28a862f3530833f82dc3d97407cf3a23fb593335f2b11f9ade8d62576f14fe0000000000000000000000006f030b74371167d3b71cf3214e749b0d1814c04900000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000120000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000010000000000000000000000002715ccea428f8c7694f7e78b2c89cb454c5f7294000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002c68af0bb14000000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000001000000000000000000000000d3664b5e72b46eaba722ab6f43c22dbf4018195400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011e1a3000000000000000000000000006f030b74371167d3b71cf3214e749b0d1814c049f8b99400000000000000adc04c56bf30ac9d3c0aaf14dce1a04b9f2d36e1b4c93de62cc077b00b1a91d84b6c31b4a14e012718dcca230689e7b88000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000002392f9c488837a9a75f4b5a139bed7757ebec5091b7e0b6f1ce70cbbbc75050e5ea28a862f3530833f82dc3d97407cf3a23fb593335f2b11f9ade8d62576f14fef89b94d3664b5e72b46eaba722ab6f43c22dbf40181954f863a08c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925a0000000000000000000000000f8de191520e37592aa84c62f650b067805cf1845a000000000000000000000000000000000000000adc04c56bf30ac9d3c0aaf14dca00000000000000000000000000000000000000000000000000000000017d78400f89b94d3664b5e72b46eaba722ab6f43c22dbf40181954f863a0ddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa0000000000000000000000000f8de191520e37592aa84c62f650b067805cf1845a00000000000000000000000006f030b74371167d3b71cf3214e749b0d1814c049a00000000000000000000000000000000000000000000000000000000011e1a300f89b942715ccea428f8c7694f7e78b2c89cb454c5f7294f863a08c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925a00000000000000000000000006f030b74371167d3b71cf3214e749b0d1814c049a000000000000000000000000000000000000000adc04c56bf30ac9d3c0aaf14dca0000000000000000000000000000000000000000000000035a66e2580ecd70000f89b942715ccea428f8c7694f7e78b2c89cb454c5f7294f863a0ddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa00000000000000000000000006f030b74371167d3b71cf3214e749b0d1814c049a0000000000000000000000000f8de191520e37592aa84c62f650b067805cf1845a000000000000000000000000000000000000000000000000002c68af0bb140000","0x02f9036101838ed0a2b9010000000000000000080000000000000000000000000040000000000008000000000000000000010000002000008000000000004000000000000000000000000000000000000000000001000008000000000000000000000000000000000000000000000000000000000000000000000000000000000000002000000010000000000000000048000000000000000000000000000000400000000000000000000000000000010000000000000000008000000000000000000000000000000000000000020002000000000000000000000000008000000000000000000000000000000000800000000000000000000000008000000000000000000000000000000000f90256f89b94eea85fdf0b05d1e0107a61b4b4db1f345854b952f863a0ddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa000000000000000000000000030f7fd07ce431d090f8ec59c3b635a4df42a00a1a0000000000000000000000000c1b71d1ad2de3fcbecda73c3273296dd45863c21a00000000000000000000000000000000000000000000000012f9aa3647286b60ff89b94fb7378d0997b0092be6bbf278ca9b8058c24752ff863a0ddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa0000000000000000000000000c1b71d1ad2de3fcbecda73c3273296dd45863c21a000000000000000000000000030f7fd07ce431d090f8ec59c3b635a4df42a00a1a0000000000000000000000000000000000000000000000001314fb37062980000f901199430f7fd07ce431d090f8ec59c3b635a4df42a00a1e1a03b841dc9ab51e3104bda4f61b41e4271192d22cd19da5ee6e292dc8e2744f713b8e00000000000000000000000009563fdb01bfbf3d6c548c2c64e446cb5900aca88000000000000000000000000c1b71d1ad2de3fcbecda73c3273296dd45863c2100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001314fb370629800000000000000000000000000000000000000000000000000012f9aa3647286b60fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc8","0x02f905c40183904383b9010000000000000000000008000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000000140000000000000000000000000000000000000000000000000000010000000000000000000000000100000020002000000020000000800000000000000000000000200000000000000010000000000000200000000000000000000000000000000000000000000000000000000000000000000000000000800000000000006000000000000800000100000000000000000000000000000000000000000000001000000000020000000000000000000800000000800000000000000000000004000000000000000f904b9f901ba94db249fda431b6385ad5e028f3aa31f3f51ebaef2e1a0cdb9fb741d82c65a081bb855b5e42174193549c537fd57a199609593827cff71b90180000000000000000000000000762f1119123806fc0aa4c58f61a9da096910200b0000000000000000000000000000000000000000000000000000000000004443000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000a000000000000000000000000000000000000000000000000000000000000000e0000000000000000000000000000000000000000000000000000000000000000c7a6b4554482e676f65726c690000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000006d0c7a6b4554482e676f65726c693f616c656f316d397673377a68787632783232673963667a7a74616e6c72356d357a63617334726a616d7768796a6e74336636746737656772717266703676720080c6a47e8d030000000000000000000000000000000000000000000000000000000000000000000000000000000000000000f9019a94762f1119123806fc0aa4c58f61a9da096910200be1a08636abd6d0e464fe725a13346c7ac779b73561c705506044a2e6b2cdb1295ea5b901600000000000000000000000000000000000000000000000000000000000000000000000000000000000000000532e91ca086964251519359271b99bd08427314f000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000c0000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000038d7ea4c68000000000000000000000000000000000000000000000000000000000000000000c7a6b4554482e676f65726c690000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003f616c656f316d397673377a68787632783232673963667a7a74616e6c72356d357a63617334726a616d7768796a6e743366367467376567727172667036767200f9015c94532e91ca086964251519359271b99bd08427314ff863a0fed162bc92844d868aeee15dc79af2ef4aac1ef57805f4eec865983f4d35efd9a00000000000000000000000000000000000000000000000000000000000000000a0000000000000000000000000660aba6ca934d1537a95cc4454469a1026ed6252b8e00000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000038d7ea4c68000000000000000000000000000000000000000000000000000002386f26fc10000000000000000000000000000000000000000000000000000000000000000003f616c656f316d397673377a68787632783232673963667a7a74616e6c72356d357a63617334726a616d7768796a6e743366367467376567727172667036767200","0x02f901a7018390a504b9010000000000000000000000000000000000000000000000000080000000000000000000000000000000000000000100000004000000000000000000000000200000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002000000000000000000000020000000000000000000000000000000000000000000000000020000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010000000000400000000000001000000000000000000000000000000000000f89df89b94fad6367e97217cc51b4cd838cc086831f81d38c2f863a08c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925a000000000000000000000000028cd70b79775193ea6f75f0808870b0b9eb1ad01a00000000000000000000000001c5d511f65c99ff3ea07dcca7ed91146ed5351e2a00000000000000000000000000000000000000000000000000000000000000000","0x02f909ad018396c005b901000000400000040000000000000000000000000000000000000000000000000000000000000000000000000000000010000040000000000200000000004020000000000000a0080000080000080000000000000000020000000000800000000000000000000000000000000000000000000000000400000000000000188000000000000000000000001000000000000000010010000020000000000000000000000a0001000000001001000040000000400000000000001000000000000000000000000002000000000000000002000000010000800000000000000000000000000490100000000000000000000001000004000000000010000000000000000000f908a2f89b94a375a26dbb09f5c57fb54264f393ad6952d1d2def863a0ddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa00000000000000000000000002e5357a050c29c8e9781516ac176c276f3c9c5faa0000000000000000000000000633f534ddc7ccced21f70e3e6956e669daa49d41a000000000000000000000000000000000000000000000000000000000003d0900f89b94a375a26dbb09f5c57fb54264f393ad6952d1d2def863a08c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925a00000000000000000000000002e5357a050c29c8e9781516ac176c276f3c9c5faa0000000000000000000000000633f534ddc7ccced21f70e3e6956e669daa49d41a00000000000000000000000000000000000000000000000000000f4312ed20263f89b94633f534ddc7ccced21f70e3e6956e669daa49d41f863a05548c837ab068cf56a2c2479df0882a4922fd203edb7517321831d95078c5f62a0000000000000000000000000a375a26dbb09f5c57fb54264f393ad6952d1d2dea00000000000000000000000002e5357a050c29c8e9781516ac176c276f3c9c5faa000000000000000000000000000000000000000000000000000000000003d0900f89b94a375a26dbb09f5c57fb54264f393ad6952d1d2def863a0ddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa0000000000000000000000000633f534ddc7ccced21f70e3e6956e669daa49d41a000000000000000000000000064046eaf582638f26ba3ff17ea51705f1367cbc3a000000000000000000000000000000000000000000000000000000000003d0900f8dd94633f534ddc7ccced21f70e3e6956e669daa49d41f884a0023916d46c0d18491146f8b0bc7d927a62a0559c8ca79920bda7dc7db1fc72f3a0000000000000000000000000a375a26dbb09f5c57fb54264f393ad6952d1d2dea00000000000000000000000002e5357a050c29c8e9781516ac176c276f3c9c5faa000000000000000000000000064046eaf582638f26ba3ff17ea51705f1367cbc3b84000000000000000000000000000000000000000000000000000000000ffffffff00000000000000000000000000000000000000000000000000000000003d0900f8fc9464046eaf582638f26ba3ff17ea51705f1367cbc3f863a051dfc81761c6e241cfba4adcd6a3af365b7b8305f76dc043f1b1b8bc22f73fdea000000000000000000000000000000000000000000000000000000000ffffffffa00000000000000000000000002e5357a050c29c8e9781516ac176c276f3c9c5fab88000000000000000000000000000000000000000000000000000000000000120f200000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000003782dace9d900000ffffffffffffffffffffffffffffffffffffffffffffffffffd46bd89546914bf89b94a375a26dbb09f5c57fb54264f393ad6952d1d2def863a0ddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa00000000000000000000000002e5357a050c29c8e9781516ac176c276f3c9c5faa0000000000000000000000000633f534ddc7ccced21f70e3e6956e669daa49d41a000000000000000000000000000000000000000000000000000000000003d0900f89b94a375a26dbb09f5c57fb54264f393ad6952d1d2def863a08c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925a00000000000000000000000002e5357a050c29c8e9781516ac176c276f3c9c5faa0000000000000000000000000633f534ddc7ccced21f70e3e6956e669daa49d41a00000000000000000000000000000000000000000000000000000f4312e94f963f89b94633f534ddc7ccced21f70e3e6956e669daa49d41f863a05548c837ab068cf56a2c2479df0882a4922fd203edb7517321831d95078c5f62a0000000000000000000000000a375a26dbb09f5c57fb54264f393ad6952d1d2dea00000000000000000000000002e5357a050c29c8e9781516ac176c276f3c9c5faa000000000000000000000000000000000000000000000000000000000003d0900f89b94a375a26dbb09f5c57fb54264f393ad6952d1d2def863a0ddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa0000000000000000000000000633f534ddc7ccced21f70e3e6956e669daa49d41a000000000000000000000000064046eaf582638f26ba3ff17ea51705f1367cbc3a000000000000000000000000000000000000000000000000000000000003d0900f8dd94633f534ddc7ccced21f70e3e6956e669daa49d41f884a0023916d46c0d18491146f8b0bc7d927a62a0559c8ca79920bda7dc7db1fc72f3a0000000000000000000000000a375a26dbb09f5c57fb54264f393ad6952d1d2dea00000000000000000000000002e5357a050c29c8e9781516ac176c276f3c9c5faa000000000000000000000000064046eaf582638f26ba3ff17ea51705f1367cbc3b84000000000000000000000000000000000000000000000000000000000658e7c8000000000000000000000000000000000000000000000000000000000003d0900f8fc9464046eaf582638f26ba3ff17ea51705f1367cbc3f863a051dfc81761c6e241cfba4adcd6a3af365b7b8305f76dc043f1b1b8bc22f73fdea000000000000000000000000000000000000000000000000000000000658e7c80a00000000000000000000000002e5357a050c29c8e9781516ac176c276f3c9c5fab8800000000000000000000000000000000000000000000000000000000000011e9a00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003782dace9d900000000000000000000000000000000000000000000000000000002e45f9fa00bf77","0x02f9055c01839a4ac9b90100000000000004000000000000000000000000000000000000000000000000000000000004000000000000000000001000004000000000020000000000402000000000000080080000000000080000000000000000020000000000800000000000000000000000000000000000000000000000000400000000000000100000000000000000000000001000040000000000010010000000000000000000000000400a0800000000001001000040000000400000000000001000000000000004000000008002000000000000000000000100004000000000000000000000010000000090100000000000000000000001000004000000000010000000000000000000f90451f89b94a375a26dbb09f5c57fb54264f393ad6952d1d2def863a0ddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa000000000000000000000000046fcab71245e2ff12ecc0ba8d3490aec95617b54a0000000000000000000000000633f534ddc7ccced21f70e3e6956e669daa49d41a000000000000000000000000000000000000000000000000000000000003d0900f89b94a375a26dbb09f5c57fb54264f393ad6952d1d2def863a08c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925a000000000000000000000000046fcab71245e2ff12ecc0ba8d3490aec95617b54a0000000000000000000000000633f534ddc7ccced21f70e3e6956e669daa49d41a0000000000000000000000000000000000000000000000000000000003e7f2450f89b94633f534ddc7ccced21f70e3e6956e669daa49d41f863a05548c837ab068cf56a2c2479df0882a4922fd203edb7517321831d95078c5f62a0000000000000000000000000a375a26dbb09f5c57fb54264f393ad6952d1d2dea000000000000000000000000046fcab71245e2ff12ecc0ba8d3490aec95617b54a000000000000000000000000000000000000000000000000000000000003d0900f89b94a375a26dbb09f5c57fb54264f393ad6952d1d2def863a0ddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa0000000000000000000000000633f534ddc7ccced21f70e3e6956e669daa49d41a0000000000000000000000000f1675ffed677b2e7ee0c87574ebd279049d9ebf9a000000000000000000000000000000000000000000000000000000000003d0900f8dd94633f534ddc7ccced21f70e3e6956e669daa49d41f884a0023916d46c0d18491146f8b0bc7d927a62a0559c8ca79920bda7dc7db1fc72f3a0000000000000000000000000a375a26dbb09f5c57fb54264f393ad6952d1d2dea000000000000000000000000046fcab71245e2ff12ecc0ba8d3490aec95617b54a0000000000000000000000000f1675ffed677b2e7ee0c87574ebd279049d9ebf9b84000000000000000000000000000000000000000000000000000000000ffffffff00000000000000000000000000000000000000000000000000000000003d0900f8fc94f1675ffed677b2e7ee0c87574ebd279049d9ebf9f863a051dfc81761c6e241cfba4adcd6a3af365b7b8305f76dc043f1b1b8bc22f73fdea000000000000000000000000000000000000000000000000000000000ffffffffa000000000000000000000000046fcab71245e2ff12ecc0ba8d3490aec95617b54b880ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa18700000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000003782dace9d900000fffffffffffffffffffffffffffffffffffffffffffffff3d3b3ce837117c4f3","0x02f9032701839baf92b9010000000000000000000000000000000000000000000000000000000000400000000000000000000000000200000000000000000000020000001200000000000000000000100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000021000000000000000000000002440000000000000000000000000000000001000000000000000000000000000008000000000000000001000000000000000000000000000000000000008000000000000000000000000000000004000f9021cf9013c94af4159a80b6cc41ed517db1c453d1ef5c2e4db72f863a05e3c1311ea442664e8b1611bfabef659120ea7a0a2cfc0667700bebc69cbffe1a000000000000000000000000000000000000000000000000000000000000b574fa0c16ec891aba6a3f7b381a53cdd85e9d84741f080b35012c1f376edcac6e95f10b8c00000000000000000000000006bebc4925716945d46f0ec336d5c2564f419682c000000000000000000000000000000000000000000000000000000000000000c000000000000000000000000f5ce611c7321438f8a30aab16852d68da4f5ab5a4de176e8c0279273cbe8a9919b029628c5cc2def297494bb2b1d1a470ae6ce18000000000000000000000000000000000000000000000000000000000000000b00000000000000000000000000000000000000000000000000000000652d2a70f8db946bebc4925716945d46f0ec336d5c2564f419682cf842a0ff64905f73a67fb594e0f940a8075a860db489ad991e032f48c81123eb52d60ba000000000000000000000000000000000000000000000000000000000000b574fb88000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000034e4bd611c7321438f8a30aab16852d68da4f59a490000000000000000000000000000000000000000000000000429d069189e0000000000000000000000000000","0x02f901ff01839ceb65b9010000000000010002000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000040000000800000000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000800000000000000020000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000f8f5f85894d5c325d183c592c94998000c5e0eed9e6655c020e1a09866f8ddfe70bb512b2f2b28b49d4017c43f7ba775f1a20c61c13eea8cdac111a0c9afd20a1f61bb629588d82d72e13914812259d13161284b98747c955d62317ef89994d5c325d183c592c94998000c5e0eed9e6655c020e1a0d342ddf7a308dec111745b00315c14b7efb2bdae570a6856e088ed0c65a3576cb8600336df0b24cf3302afadbc4c828662c60c2cdae602e59beaab7011bf3fd5a223000000000000000000000000000000000000000000000000000000000004d0e5020abc24e9cfc67a97e463deef1ab573cb11d9cd618bedee85c2df85fac6faa2","0x02f901ff01839e2744b9010000000000010002000000000000000000000000000000000000000000000000000000002000000000000000001000000000000000000000000000800000000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000000000000000000000000000080000000000000000000000800000000000000000000000000000000000000000000000000000000000000f8f5f85894de29d060d45901fb19ed6c6e959eb22d8626708ee1a09866f8ddfe70bb512b2f2b28b49d4017c43f7ba775f1a20c61c13eea8cdac111a035ceccc734a10ae9c593304774276b4b6324223b019c38c6662ab923022b2c8af89994de29d060d45901fb19ed6c6e959eb22d8626708ee1a0d342ddf7a308dec111745b00315c14b7efb2bdae570a6856e088ed0c65a3576cb860022db625db05534a27ea14675f8d22d7c603e0981ceff2b02504791b75c4f56100000000000000000000000000000000000000000000000000000000000d7c61019e776def80129482e5f6282056f7318bedf7bc30a4ae7cdf8814d8d0b28a99","0x02f901ff01839f6317b9010000000000010002000000000000000000000000000000000000000000000000000000002000000000000000001000000000000000000000000000800000000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000000000000000000000000000080000000000000000000000800000000000000000000000000000000000000000000000000000000000000f8f5f85894de29d060d45901fb19ed6c6e959eb22d8626708ee1a09866f8ddfe70bb512b2f2b28b49d4017c43f7ba775f1a20c61c13eea8cdac111a01331bfa0165c171aefba1e6eebd55d52bc2389726c1d0594f4a9e2f7812b42e4f89994de29d060d45901fb19ed6c6e959eb22d8626708ee1a0d342ddf7a308dec111745b00315c14b7efb2bdae570a6856e088ed0c65a3576cb86002e2bf007e02d68956b61be94c5661c8c8d1fb7ae552a0b2e7f3869d20d7aa0700000000000000000000000000000000000000000000000000000000000d7c620467725c6a4525d13c195701bf88f4f3c65329438cf8a437c928067d9a80556e","0x02f9033f0183a10e1fb9010000000000010002000000000000000000000000000000000000000000000000000000002000000000000000001000000000000000000000000000800000000040000040000000000000000200000000000000000000002000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000020000000000004000000000000000080000000200400000000000800000000000000000000000000000000000000000000000000000000000000f90234f85894de29d060d45901fb19ed6c6e959eb22d8626708ee1a09866f8ddfe70bb512b2f2b28b49d4017c43f7ba775f1a20c61c13eea8cdac111a074c803dcb95e04990c3e71db65899a9e0282003a967632e13eb6ce45d598fb45f9013c94de29d060d45901fb19ed6c6e959eb22d8626708ef863a04264ac208b5fde633ccdd42e0f12c3d6d443a4f3779bbf886925b94665b63a22a0073314940630fd6dcda0d772d4c972c4e0a9946bef9dabf4ef84eda8ef542b82a0000000000000000000000000c3511006c04ef1d78af4c8e0e74ec18a6e64ff9eb8c00000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000000000000000000000000000001f36e2be14d65c7a832d1a863ecfa06c6730634700000000000000000000000000000000000000000000000000470de4df8200000000000000000000000000000000000000000000000000000000000000000000f89994de29d060d45901fb19ed6c6e959eb22d8626708ee1a0d342ddf7a308dec111745b00315c14b7efb2bdae570a6856e088ed0c65a3576cb8600427eee54195a8dc4d35b17e5cbc8e18b6e8eebdaf2017f6e12dac62232ca9e000000000000000000000000000000000000000000000000000000000000d7c6300b1121da2e28ad38fb1736373bb7fe4787b73c881995bbd391b17aa113a2cc8","0x02f901ff0183a249e6b9010000000000010002000000000000000000000000000000000000000000000000000000002000000000000000001000000000000000000000000000800000000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000000000000000000000000000080000000000000000000000800000000000000000000000000000000000000000000000000000000000000f8f5f85894de29d060d45901fb19ed6c6e959eb22d8626708ee1a09866f8ddfe70bb512b2f2b28b49d4017c43f7ba775f1a20c61c13eea8cdac111a0d4d6f16309b51be964a0482c4cd816fadeaa8759216dd9bbc20773ba36c75ccaf89994de29d060d45901fb19ed6c6e959eb22d8626708ee1a0d342ddf7a308dec111745b00315c14b7efb2bdae570a6856e088ed0c65a3576cb8600001d0bd72454b02cd7386951338297e0da0f5a8c1076a24c1425928dce0838300000000000000000000000000000000000000000000000000000000000d7c64028c033938806df04fcc792f72f91ca04c3c20963eec03addb44fecf6fa795de","0x02f901090183a29beeb9010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0","0x02f9041e0183a8526db9010000000200000000400000000000000000000000000020000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000010000020000000000000000000000000000004000000080000000004000000002000000000000000000000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000800200010000000000000000000000000000000000000000000000000000000040000000000000000f90313f8b994caf156a3dd652e2b493fe9e53f3d526d3cbbd4a8e1a0e2db1e7820b0cca1226a7e7d5cc2a3df28542b04da0f0aa7949f2a74519ef5a0b880000000000000000000000000307c2d86e3638a5afce36115dcbc856260748d310000000000000000000000000000000000000000000000000000b588ff18e000000000000000000000000000307c2d86e3638a5afce36115dcbc856260748d310000000000000000000000000000000000000000000000000000000000000000f87994caf156a3dd652e2b493fe9e53f3d526d3cbbd4a8e1a0305bf06329ff886b42ab3ed2979092b17d3a7fc67e7de42ee393a24c8e39fee7b840000000000000000000000000307c2d86e3638a5afce36115dcbc856260748d31000000000000000000000000307c2d86e3638a5afce36115dcbc856260748d31f901da9475d8ec64bf68b364b1f45249774e78df2f401399e1a0c6cb9661759518374091eb98266dd634614ae793b31549daff33e83d6dee0165b901a0000000000000000000000000caf156a3dd652e2b493fe9e53f3d526d3cbbd4a8000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000001200000000000000000000000004a1c82542ebdb854ece6ce5355b5c48eb299ecd8000000000000000000000000000000000000000000000000000aa87bee53800000000000000000000000000000000000000000000000000000000000000003840000000000000000000000000000000000000000000000000000b588ff18e000000000000000000000000000307c2d86e3638a5afce36115dcbc856260748d31000000000000000000000000000000000000000000000000000000000001518000000000000000000000000000000000000000000000000000000000000151800000000000000000000000000000000000000000000000000000000000001388000000000000000000000000000000000000000000000000000000000000001e347468207465737420636f6c6c656374697665206f6e203136204f6374200000","0x02f908450183ab3259b9010000000000004048000010000004005000000000080000000000000000000000080002000000000000008200000004008450000000000000000000100000200200000001000000000040000008200000000000000000000000000000102000000100000000000000000000000480000000000000000000000000000010000000000200000000024000000000000000000010000000000000000001004200400000020000000000000000000000001400000000000000000000040000000200000000000002000000080000000000020000000000000000040000000000000000001010000000000000000000000000000000000000000000000000800000000000f9073af89b944031bc992179a7742bb99ec99da67f852c11927af863a08c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925a0000000000000000000000000aed889cc423f93ae00d140fce00a4aa6b05aa783a0000000000000000000000000d029d527e1d700c549f4e04662035b8a8624ce4fa00000000000000000000000000000000000000000000000000000000000000000f89b944031bc992179a7742bb99ec99da67f852c11927af863a0ddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa0000000000000000000000000aed889cc423f93ae00d140fce00a4aa6b05aa783a0000000000000000000000000d029d527e1d700c549f4e04662035b8a8624ce4fa000000000000000000000000000000000000000000000000000000000000003e8f902de94d9005878cb1a830355dbf4d814a835c54022038ef884a04b388aecf9fa6cc92253704e5975a6129a4f735bdbd99567df4ed0094ee4ceb5a00000000000000000000000000ded20eaea674409ccfeca298385f361ad359a43a00000000000000000000000004200000000000000000000000000000000000007a0000000000000000000000000000000000000000000000000000000000000170db9024000000000000000000000000000000000000000000000000000000000001e8480000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000652d2a7000000000000000000000000000000000000000000000000000000000000001a4cbd4ece90000000000000000000000004200000000000000000000000000000000000010000000000000000000000000d029d527e1d700c549f4e04662035b8a8624ce4f0000000000000000000000000000000000000000000000000000000000000080000000000000000000000000000000000000000000000000000000000000170d00000000000000000000000000000000000000000000000000000000000000e4662a633a0000000000000000000000003c3a81e81dc49a522a592e7622a7e711c06bf354000000000000000000000000deaddeaddeaddeaddeaddeaddeaddeaddead0000000000000000000000000000aed889cc423f93ae00d140fce00a4aa6b05aa783000000000000000000000000aed889cc423f93ae00d140fce00a4aa6b05aa78300000000000000000000000000000000000000000000000000000000000003e800000000000000000000000000000000000000000000000000000000000000c000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000f901fc94fcdc20eaea674409ccfeca298385f361ad358932f842a0cb0f7ffd78f9aee47a248fae8db181db6eee833039123e026dcbff529522e52aa00000000000000000000000004200000000000000000000000000000000000010b901a0000000000000000000000000d029d527e1d700c549f4e04662035b8a8624ce4f0000000000000000000000000000000000000000000000000000000000000080000000000000000000000000000000000000000000000000000000000000170d00000000000000000000000000000000000000000000000000000000001e848000000000000000000000000000000000000000000000000000000000000000e4662a633a0000000000000000000000003c3a81e81dc49a522a592e7622a7e711c06bf354000000000000000000000000deaddeaddeaddeaddeaddeaddeaddeaddead0000000000000000000000000000aed889cc423f93ae00d140fce00a4aa6b05aa783000000000000000000000000aed889cc423f93ae00d140fce00a4aa6b05aa78300000000000000000000000000000000000000000000000000000000000003e800000000000000000000000000000000000000000000000000000000000000c0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000f9011d94d029d527e1d700c549f4e04662035b8a8624ce4ff884a0718594027abd4eaed59f95162563e0cc6d0e8d5b86b1c7be8b1b0ac3343d0396a00000000000000000000000004031bc992179a7742bb99ec99da67f852c11927aa0000000000000000000000000deaddeaddeaddeaddeaddeaddeaddeaddead0000a0000000000000000000000000aed889cc423f93ae00d140fce00a4aa6b05aa783b880000000000000000000000000aed889cc423f93ae00d140fce00a4aa6b05aa78300000000000000000000000000000000000000000000000000000000000003e800000000000000000000000000000000000000000000000000000000000000600000000000000000000000000000000000000000000000000000000000000000","0xf901090183ab8461b9010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0","0xf901090183abd669b9010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0","0xf903640183ae0bfcb9010000000000100000400000000000000000000000000000084000000000000000000000000000000000000000000000020000000000000000000000000000000000000040008800000000100008000000000000000000000000000000000000000000000000020000000000000000000800000000000000000000000010000000000002000000000000000000000000000000000000000002000000000000000000000000000000000000001000000000000000020080000000000000040000000080040002000000000000000000000000000000000000000000010000000020000000000000200000000000000000000000000000001002000000000000000000f90259f9011c94980205d352f198748b626f6f7c38a8a5663ec981f863a02bd2d8a84b748439fd50d79a49502b4eb5faa25b864da6a9ab5c150704be9a4da0000000000000000000000000000000000000000000000000000000000000006ea00000000000000000000000009f40916d0dfb2f8f5fb63d8f76826d09041f2eaeb8a000000000000000000000000000000000000000000000000000000000000000600000000000000000000000000000000000000000000000000000000000000d68efdc6e047f712f4bff82fc800f5309ca0c4e8e7ba32b255b212fef748ed80af200000000000000000000000000000000000000000000000000000000000000148a555e4fc287650f5e8ca1778a35dd44e893d6aa000000000000000000000000f89b949f40916d0dfb2f8f5fb63d8f76826d09041f2eaef863a0ddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa00000000000000000000000000000000000000000000000000000000000000000a0000000000000000000000000363413eb82ff4ebda8e70f8e0f9615b684d2f9eda00000000000000000000000000000000000000000000000000de0b6b3a7640000f89b949f40916d0dfb2f8f5fb63d8f76826d09041f2eaef863a0bf551ec93859b170f9b2141bd9298bf3f64322c6f7beb2543a0cb669834118bfa0000000000000000000000000000000000000000000000000000000000000006ea0000000000000000000000000363413eb82ff4ebda8e70f8e0f9615b684d2f9eda00000000000000000000000000000000000000000000000000de0b6b3a7640000","0xf903640183b08524b9010000000000002000000000000000000000000000000040000000000000000000000000000000000020000000000000000000000000000000000000000000000000000040000800000000000008000000000001000000000000000000000000000000000000020000000000000000000800000000000020000000000010000000000002004000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000020080000100400000040000000080100002000000000000000000000000000000000000000000010000000020000000000000200000000000000000000000000000001002000000000000000000f90259f9011c94980205d352f198748b626f6f7c38a8a5663ec981f863a02bd2d8a84b748439fd50d79a49502b4eb5faa25b864da6a9ab5c150704be9a4da0000000000000000000000000000000000000000000000000000000000000006ea00000000000000000000000004f7a67464b5976d7547c860109e4432d50afb38eb8a0000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000001a400c8fb05948cf6527abe1b570154f613139797c9cf1ace53bd3c8f4a8f756a703f60000000000000000000000000000000000000000000000000000000000000014dd69db25f6d620a7bad3023c5d32761d353d3de9000000000000000000000000f89b944f7a67464b5976d7547c860109e4432d50afb38ef863a0ddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa00000000000000000000000004f7a67464b5976d7547c860109e4432d50afb38ea00000000000000000000000000000000000000000000000000000000000000000a00000000000000000000000000000000000000000000000005805420c76fdc3d1f89b944f7a67464b5976d7547c860109e4432d50afb38ef863a0bf551ec93859b170f9b2141bd9298bf3f64322c6f7beb2543a0cb669834118bfa0000000000000000000000000000000000000000000000000000000000000006ea000000000000000000000000095ac38e1c9af5a6d868c1b376e7c0ba9b9251ca5a00000000000000000000000000000000000000000000000005805420c76fdc3d1","0xf903640183b2fe40b9010000000000002000000000000000000000000000000040000000000000000000000000000000000000000000010000000000000000000000000000000000000000000040000800000000000008000000000001000000000100000000000000000000000000020000000000000000000800000000000020000000000010000000000002000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000020080000100000000040000000080100002000000000000000000000000000000000000000000010000000020000000000000200000008000000000000000000000001002000000000000000000f90259f9011c94980205d352f198748b626f6f7c38a8a5663ec981f863a02bd2d8a84b748439fd50d79a49502b4eb5faa25b864da6a9ab5c150704be9a4da0000000000000000000000000000000000000000000000000000000000000006ea00000000000000000000000004f7a67464b5976d7547c860109e4432d50afb38eb8a0000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000001a400d1b36efb5ef48c1953b391dadade996e546aebdeea81b118ac2eefda2a548bac50000000000000000000000000000000000000000000000000000000000000014dd69db25f6d620a7bad3023c5d32761d353d3de9000000000000000000000000f89b944f7a67464b5976d7547c860109e4432d50afb38ef863a0ddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa00000000000000000000000004f7a67464b5976d7547c860109e4432d50afb38ea00000000000000000000000000000000000000000000000000000000000000000a00000000000000000000000000000000000000000000000005735cbdc26b5d43af89b944f7a67464b5976d7547c860109e4432d50afb38ef863a0bf551ec93859b170f9b2141bd9298bf3f64322c6f7beb2543a0cb669834118bfa0000000000000000000000000000000000000000000000000000000000000006ea0000000000000000000000000f7db1e439db7a79a8f91cbde7c0069a97b89c813a00000000000000000000000000000000000000000000000005735cbdc26b5d43a","0xf902c40183b4a7bab9010000000040000000080000000000000000000000000000000001000002000000000000000000000000000000000000000000000000000000000000000000002000000040000000000000000000000000000000000000020000000000000000000000000000000000000040000000000000000000000008000000000000000000000000000010000000000000000000000000000000000002000000000000000000000000000000000000000000200000000000000000000000000000040000000080000020000000000000000000000000000000000000000000010000000000000000000000200000000000000000000000000000000000000000000000000000f901b9f8dc94980205d352f198748b626f6f7c38a8a5663ec981f863a074bbc026808dcba59692d6a8bb20596849ca718e10e2432c6cdf48af865bc5d9a0000000000000000000000000000000000000000000000000000000000000006ea0000000000000000000000000a6bf2be6c60175601bf88217c75dd4b14abb5fbbb860312401a801d73bde5cacb7e2eeba637d09c23f9a18dff6504cbdc8f7d7b2e348312401a801d73bde5cacb7e2eeba637d09c23f9a18dff6504cbdc8f7d7b2e3480000000000000000000000000000000000000000000000000000000000000014f8d994a6bf2be6c60175601bf88217c75dd4b14abb5fbbe1a0293e3a2153dc5c8d3667cbd6ede71a71674b2381e5dc4b40c91ad0e813447c0fb8a0000000000000000000000000980205d352f198748b626f6f7c38a8a5663ec981cf507db63af850463ebaaeffe5f783680e6aa364627d07c6488f5ba313ebbcca000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000000","0xf903640183b6bf22b9010000000000002000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000800000000000008000000000001000000000000000000000000000000000000020000000000000000000800000000000020000000000010000000008002002000000000000000000000000000000000000002000000000000000000000000000000000040000000000000000000020180000100000000040000000000140002000000000000000000000000000000000000000000000000000020000000000000200000000000000000000000000000001002000000000400000000f90259f9011c94980205d352f198748b626f6f7c38a8a5663ec981f863a02bd2d8a84b748439fd50d79a49502b4eb5faa25b864da6a9ab5c150704be9a4da0000000000000000000000000000000000000000000000000000000000000006fa00000000000000000000000004f7a67464b5976d7547c860109e4432d50afb38eb8a000000000000000000000000000000000000000000000000000000000000000600000000000000000000000000000000000000000000000000000000000073bd808065379db49bfa5292e83432fd6ede06ae24792f0d266ac89be03f7925229ce0000000000000000000000000000000000000000000000000000000000000014dd69db25f6d620a7bad3023c5d32761d353d3de9000000000000000000000000f89b944f7a67464b5976d7547c860109e4432d50afb38ef863a0ddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa00000000000000000000000004f7a67464b5976d7547c860109e4432d50afb38ea00000000000000000000000000000000000000000000000000000000000000000a00000000000000000000000000000000000000000000000000a7da3311d85502df89b944f7a67464b5976d7547c860109e4432d50afb38ef863a0bf551ec93859b170f9b2141bd9298bf3f64322c6f7beb2543a0cb669834118bfa0000000000000000000000000000000000000000000000000000000000000006fa0000000000000000000000000c677f78297d40138b68be496ae34d861dc9edbeba00000000000000000000000000000000000000000000000000a7da3311d85502d","0xf902c40183b86890b9010000000040000000080000000000000000000000000000000001000002000000000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000020000000000000000000000000000000000000040000000000000000000000008000000000000000000000000000010000000000000000000000000000000000002000000000000000000000000000000000040000000200000000000000100000000000000040000000000040020000000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000f901b9f8dc94980205d352f198748b626f6f7c38a8a5663ec981f863a074bbc026808dcba59692d6a8bb20596849ca718e10e2432c6cdf48af865bc5d9a0000000000000000000000000000000000000000000000000000000000000006fa0000000000000000000000000a6bf2be6c60175601bf88217c75dd4b14abb5fbbb86031f7494a39416159f52b17758dda7bdafa4215dcf706dfc06cd6f8933b817d2031f7494a39416159f52b17758dda7bdafa4215dcf706dfc06cd6f8933b817d200000000000000000000000000000000000000000000000000000000000000014f8d994a6bf2be6c60175601bf88217c75dd4b14abb5fbbe1a0293e3a2153dc5c8d3667cbd6ede71a71674b2381e5dc4b40c91ad0e813447c0fb8a0000000000000000000000000980205d352f198748b626f6f7c38a8a5663ec981ea46511277ad0d9d47ff09d07eb1e1298bcefa6a6da798de1e0af884002aceb1000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000000","0x02f902460183e60720b9010000000004000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000008002000000000000000000000000000000000000000000000020000000000000000000800000000000000000000000010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000001000000000000080004002000000000000000000000000000000000000000100000000000020000000000000001000000000000000000000000000000000020000000000000000f9013bf89b9488045945952b374abf696602941b51149bad8ab4f863a0ddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa00000000000000000000000000000000000000000000000000000000000000000a0000000000000000000000000e8c83b0cb059fe98f4e0bb2b7be404565e5aaa75a00000000000000000000000000000000000000000033b2e3c9fd0803ce8000000f89c9488045945952b374abf696602941b51149bad8ab4f884a02f8788117e7eff1d82e926ec794901d17c78024a50270940304540a733656f0da00000000000000000000000000000000000000000000000000000000000000000a0000000000000000000000000e8c83b0cb059fe98f4e0bb2b7be404565e5aaa75a0000000000000000000000000e8c83b0cb059fe98f4e0bb2b7be404565e5aaa7580","0xf901090183e65928b9010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0","0x02f901e50183e6f1e1b9010000000000000000000000000000000000000000000000000000000000000000000000000000000000001080000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000040000040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000f8dbf8d99416324d80bfc68b1fec6c288f0dac640a044d2678e1a0a7fc99ed7617309ee23f63ae90196a1e490d362e6f6a547a59bc809ee2291782b8a00000000000000000000000000000000000000000000000000000000000000060000000000000000000000000000000000000000000000000000000000180ab5200000000000000000000000000000000000000000000000000000000652d2a5500000000000000000000000000000000000000000000000000000000000000074144412f55534400000000000000000000000000000000000000000000000000","0x02f901e50183e78ab2b9010000000000000000000000000400000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000000000800040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000f8dbf8d994e7a43467520e4d12d1f9e94b99d6f041786aadcee1a0a7fc99ed7617309ee23f63ae90196a1e490d362e6f6a547a59bc809ee2291782b8a0000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000024cba3965500000000000000000000000000000000000000000000000000000000652d2a550000000000000000000000000000000000000000000000000000000000000008574554482f555344000000000000000000000000000000000000000000000000","0x02f901e50183e82377b9010000000000000000000000000000000000000000000000000000000000000000000000080000000000001000000020000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000f8dbf8d994b52a8b962ff3d8a6a0937896ff3da3879eac64e3e1a0a7fc99ed7617309ee23f63ae90196a1e490d362e6f6a547a59bc809ee2291782b8a000000000000000000000000000000000000000000000000000000000000000600000000000000000000000000000000000000000000000000000000005f6321e00000000000000000000000000000000000000000000000000000000652d2a560000000000000000000000000000000000000000000000000000000000000008555344542f555344000000000000000000000000000000000000000000000000","0xf901090183e8ef8fb9010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0","0x02f901e50183e9883cb9010000000002000000000000000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000080000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000001000000000000f8dbf8d994117a5ab00f93469bea455f0864ef9ad8d9630cc9e1a0a7fc99ed7617309ee23f63ae90196a1e490d362e6f6a547a59bc809ee2291782b8a0000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000007e060100000000000000000000000000000000000000000000000000000000652d2a5800000000000000000000000000000000000000000000000000000000000000074752542f55534400000000000000000000000000000000000000000000000000","0x02f901e50183ea2101b9010000000000000000000000000000000000000000000000000000004000000000000000000000000000001000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000800000000000000000000000800000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000f8dbf8d994bbbf9614de2b788a66d970b552a79fae6419abdce1a0a7fc99ed7617309ee23f63ae90196a1e490d362e6f6a547a59bc809ee2291782b8a000000000000000000000000000000000000000000000000000000000000000600000000000000000000000000000000000000000000000000000000005eebd8700000000000000000000000000000000000000000000000000000000652d2a580000000000000000000000000000000000000000000000000000000000000008465241582f555344000000000000000000000000000000000000000000000000","0x02f901e50183eab9d2b9010000000000000000000000000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000200f8dbf8d99439f46d72bb20c7bcb8a2cdf52630fac1496e859ae1a0a7fc99ed7617309ee23f63ae90196a1e490d362e6f6a547a59bc809ee2291782b8a0000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000024f8bc612d00000000000000000000000000000000000000000000000000000000652d2a5a0000000000000000000000000000000000000000000000000000000000000008574554482f555344000000000000000000000000000000000000000000000000","0x02f901e50183eb528bb9010000000000000000000000000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000020000000010000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000f8dbf8d9945ae58e9dec27619572a42dad916e413afa89e46de1a0a7fc99ed7617309ee23f63ae90196a1e490d362e6f6a547a59bc809ee2291782b8a000000000000000000000000000000000000000000000000000000000000000600000000000000000000000000000000000000000000000000000000000019d1f00000000000000000000000000000000000000000000000000000000652d2a5c000000000000000000000000000000000000000000000000000000000000000842414e4b2f555344000000000000000000000000000000000000000000000000","0x02f9043a0183ed1237b9010000200000000000000000002080000000000000000000000000010000000000000000000000000000000000000000200000000000000000000000020000000000000000000400000000002008000000300000000000000000000000008000000000000000008000100000000000000000000000000000000000020010000000000000000080000000004000000000000000000001000000080000104000000000000000000000000000000000000000000000000000000000000000000000000000204002000000001000000000000000000000000000001000000000000020000000000000000000000000000000000000000000000001400000000000000000f9032ff87a94b4fbf271143f4fbf7b91a5ded31805e42b2208d6f842a0e1fffcc4923d04b559f4d29a8bfc6cda04eb5b0d3c460751c2402c5c5cc9109ca00000000000000000000000007a250d5630b4cf539739df2c5dacb4c659f2488da0000000000000000000000000000000000000000000000000000000e8d4a51000f89b94b4fbf271143f4fbf7b91a5ded31805e42b2208d6f863a0ddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa00000000000000000000000007a250d5630b4cf539739df2c5dacb4c659f2488da000000000000000000000000077f0ea26bae49c9f412a1511730c7c1d3382f697a0000000000000000000000000000000000000000000000000000000e8d4a51000f89b94257c2c98163227062e5a33095a20fc7604ee52b5f863a0ddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa000000000000000000000000077f0ea26bae49c9f412a1511730c7c1d3382f697a0000000000000000000000000185d901fe591ce516ed9e192b33da3ef14d53b93a0000000000000000000000000000000000000000000000000042a7d29b88844e5f8799477f0ea26bae49c9f412a1511730c7c1d3382f697e1a01c411e9a96e071241c2f21f7726b17ae89e3cab4c78be50e062b03a9fffbbad1b840000000000000000000000000000000000000000000007b61de650eaa9bccab150000000000000000000000000000000000000000000000001adafd27de2bd68bf8fc9477f0ea26bae49c9f412a1511730c7c1d3382f697f863a0d78ad95fa46c994b6551d0da85fc275fe613ce37657fb8d5e3d130840159d822a00000000000000000000000007a250d5630b4cf539739df2c5dacb4c659f2488da0000000000000000000000000185d901fe591ce516ed9e192b33da3ef14d53b93b8800000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000e8d4a51000000000000000000000000000000000000000000000000000042a7d29b88844e50000000000000000000000000000000000000000000000000000000000000000","0x02f901e50183edaafcb9010000000000000000000000000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000800000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000f8dbf8d994aac02884a376dc5145389ba37f08b0dde08d3f18e1a0a7fc99ed7617309ee23f63ae90196a1e490d362e6f6a547a59bc809ee2291782b8a00000000000000000000000000000000000000000000000000000000000000060000000000000000000000000000000000000000000000000000000000b37b80500000000000000000000000000000000000000000000000000000000652d2a5e0000000000000000000000000000000000000000000000000000000000000008445944582f555344000000000000000000000000000000000000000000000000","0x02f901e50183ee43c1b9010000000000000000000000000000000000000000000000000000000000000000000000000000000000001000000000000000000000008000000000000010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000400040000000000000000004000000000000000000000000000000000000000000000000000000000000000000000000000f8dbf8d994402a30f83bbfc2203e1fc5d8a9bb41e1b0ddc639e1a0a7fc99ed7617309ee23f63ae90196a1e490d362e6f6a547a59bc809ee2291782b8a0000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000024df2e4ee100000000000000000000000000000000000000000000000000000000652d2a5f00000000000000000000000000000000000000000000000000000000000000074554482f55534400000000000000000000000000000000000000000000000000","0x02f901e50183eedc86b9010000000000000000000000000000000000000000000000000000000000000000040000000000000000001000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000f8dbf8d9943ae963e586b6c1d16f371ac0a1260cdaed6a76bde1a0a7fc99ed7617309ee23f63ae90196a1e490d362e6f6a547a59bc809ee2291782b8a0000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000024dcbf623800000000000000000000000000000000000000000000000000000000652d2a5f00000000000000000000000000000000000000000000000000000000000000074554482f55534400000000000000000000000000000000000000000000000000","0x02f901e50183ef753fb9010000000000000000000000000000000000000000000000000000000000000040000000000000000000001000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000f8dbf8d994c8f4aeb27fce1f361cda3aadcda992c7ed7b0e74e1a0a7fc99ed7617309ee23f63ae90196a1e490d362e6f6a547a59bc809ee2291782b8a0000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000005b67ef00000000000000000000000000000000000000000000000000000000652d2a610000000000000000000000000000000000000000000000000000000000000008444f47452f555344000000000000000000000000000000000000000000000000","0x02f901e50183f00e04b9010000000000000000000000000000000000000000000000000000000004000000000000000000000000001000000000000400000000000000000000000010000000000000000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000f8dbf8d99460cfba755fac7178e9a8e133699ad2f7dcf6ad9ae1a0a7fc99ed7617309ee23f63ae90196a1e490d362e6f6a547a59bc809ee2291782b8a0000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000229ca2bd00000000000000000000000000000000000000000000000000000000652d2a620000000000000000000000000000000000000000000000000000000000000008555255532f555344000000000000000000000000000000000000000000000000","0x02f901098083f0647ab9010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0","0x02f901e50183f0fd33b9010000000000000000000000000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000010000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000f8dbf8d9945e3b4e52af7f15f4e4e12033d71cfc3afbc7d3c0e1a0a7fc99ed7617309ee23f63ae90196a1e490d362e6f6a547a59bc809ee2291782b8a000000000000000000000000000000000000000000000000000000000000000600000000000000000000000000000000000000000000000000000000002c0f30100000000000000000000000000000000000000000000000000000000652d2a6400000000000000000000000000000000000000000000000000000000000000074f4d472f55534400000000000000000000000000000000000000000000000000","0x02f901e50183f195ecb9010000000000000000000000000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000010000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000000000002000000f8dbf8d994ffd9e1167e2ad8f323464832ad99a03bda99b7b7e1a0a7fc99ed7617309ee23f63ae90196a1e490d362e6f6a547a59bc809ee2291782b8a000000000000000000000000000000000000000000000000000000000000000600000000000000000000000000000000000000000000000000000000000150ea000000000000000000000000000000000000000000000000000000000652d2a64000000000000000000000000000000000000000000000000000000000000000847414c412f555344000000000000000000000000000000000000000000000000","0x02f901098083f22563b9010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0","0x02f901e50183f2be28b9010000000000000000000000000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000010000000000000000000000000800000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000080000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000f8dbf8d9940e324d90e9180df65e63438b2af37458b7b7b500e1a0a7fc99ed7617309ee23f63ae90196a1e490d362e6f6a547a59bc809ee2291782b8a0000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000004f47321cd00000000000000000000000000000000000000000000000000000000652d2a690000000000000000000000000000000000000000000000000000000000000007424e422f55534400000000000000000000000000000000000000000000000000","0x02f901e50183f356f9b9010000000000000000000000000000000000000000000000000000000000000000000000000000200000001000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000000000000000040000000000000000f8dbf8d9944a7d0e32e82aea46773c348896761addc51dfb11e1a0a7fc99ed7617309ee23f63ae90196a1e490d362e6f6a547a59bc809ee2291782b8a0000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000105dd23061100000000000000000000000000000000000000000000000000000000652d2a6900000000000000000000000000000000000000000000000000000000000000074254432f55534400000000000000000000000000000000000000000000000000","0x02f901e50183f3e4dab9010000000000000000000000000000000000000000000000000000000000000000000000000000000000001080000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000040000040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000f8dbf8d99416324d80bfc68b1fec6c288f0dac640a044d2678e1a0a7fc99ed7617309ee23f63ae90196a1e490d362e6f6a547a59bc809ee2291782b8a00000000000000000000000000000000000000000000000000000000000000060000000000000000000000000000000000000000000000000000000018227472200000000000000000000000000000000000000000000000000000000652d2a690000000000000000000000000000000000000000000000000000000000000008414156452f555344000000000000000000000000000000000000000000000000","0x02f901e50183f472c7b9010000000000000000000000000400000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000000000800040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000f8dbf8d994e7a43467520e4d12d1f9e94b99d6f041786aadcee1a0a7fc99ed7617309ee23f63ae90196a1e490d362e6f6a547a59bc809ee2291782b8a0000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000285d0fb605900000000000000000000000000000000000000000000000000000000652d2a6a0000000000000000000000000000000000000000000000000000000000000008574254432f555344000000000000000000000000000000000000000000000000","0x02f901e50183f50b8cb9010000000000000000000000000000000000000000000000000000000000000000000000000000000002001000000000000000000000000000000000000010000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000040000000000000020000000000000000000000000000000000000000000000000000000000000000000000000000000f8dbf8d99407c4eee621098c526403b30bdcb17b3722719dcee1a0a7fc99ed7617309ee23f63ae90196a1e490d362e6f6a547a59bc809ee2291782b8a0000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000024dfc6ecd300000000000000000000000000000000000000000000000000000000652d2a6a00000000000000000000000000000000000000000000000000000000000000074554482f55534400000000000000000000000000000000000000000000000000","0x02f901e50183f59979b9010000000000000000000000000000000000000000000000000000000000000000000000080000000000001000000020000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000f8dbf8d994b52a8b962ff3d8a6a0937896ff3da3879eac64e3e1a0a7fc99ed7617309ee23f63ae90196a1e490d362e6f6a547a59bc809ee2291782b8a00000000000000000000000000000000000000000000000000000000000000060000000000000000000000000000000000000000000000000000002870fd6b6be00000000000000000000000000000000000000000000000000000000652d2a6a0000000000000000000000000000000000000000000000000000000000000008574254432f555344000000000000000000000000000000000000000000000000","0x02f904240183f78797b9010000000000100000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000800600000000000000000000000000000000000000000001082000000000001001000000000000000000000000000000020000000000000000000800000000000000000000000000000000000000000000000000000000000000000000000580000000000000000000000200000000001000000000000000000000000000000000000000000000000000000000000000000000000020000000000000004000000000000000000000000020000000000000000000000000000000000000000000000000000000000000020000f90319f901dc949054f0d5f352fafe6ebf0ec14654da0362dc96caf842a0f6a97944f31ea060dfde0566e4167c1a1082551e64b60ecb14d599a9d023d451a00000000000000000000000000000000000000000000000000000000000011eb6b901800000000000000000000000000000000000000000000000d51cfff1e9a1af7c000000000000000000000000006af57e73d328e2a8ec95e01178d1e2a2a387d66a00000000000000000000000000000000000000000000000000000000000000a00000000000000000000000000000000000000000000000000000000000000140000000000000000000000012332e3d78c6cc4a1a0c4dae81535bc000065fa80300000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000d51cfff1e9a1af7c000000000000000000000000000000000000000000000000d51cfff1e9a1af7c000000000000000000000000000000000000000000000000d51cfff1e9a1af7c000000000000000000000000000000000000000000000000d51cfff1e9a1af7c0000000000000000000000000000000000000000000000000000000000000000040001020300000000000000000000000000000000000000000000000000000000f89b949054f0d5f352fafe6ebf0ec14654da0362dc96caf863a00109fc6f55cf40689f02fbaad7af7fe7bbac8a3d2186600afc7d3e10cac60271a00000000000000000000000000000000000000000000000000000000000011eb6a00000000000000000000000000000000000000000000000000000000000000000a000000000000000000000000000000000000000000000000000000000652d2a70f89b949054f0d5f352fafe6ebf0ec14654da0362dc96caf863a00559884fd3a460db3073b7fc896cc77986f16e378210ded43186175bf646fc5fa00000000000000000000000000000000000000000000000d51cfff1e9a1af7c00a00000000000000000000000000000000000000000000000000000000000011eb6a000000000000000000000000000000000000000000000000000000000652d2a70","0x02f901e50183f8156cb9010000000000000000000000000000000000000000000000000000004000000000000000000000000000001000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000800000000000000000000000800000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000f8dbf8d994bbbf9614de2b788a66d970b552a79fae6419abdce1a0a7fc99ed7617309ee23f63ae90196a1e490d362e6f6a547a59bc809ee2291782b8a000000000000000000000000000000000000000000000000000000000000000600000000000000000000000000000000000000000000000000000000001c062a100000000000000000000000000000000000000000000000000000000652d2a6c000000000000000000000000000000000000000000000000000000000000000853414e442f555344000000000000000000000000000000000000000000000000","0x02f901e50183f8ae31b9010000000000000000000000000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002000000000000000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000000000200000000f8dbf8d994e5d686595da780e6fbe88c31b77c1225974c89fbe1a0a7fc99ed7617309ee23f63ae90196a1e490d362e6f6a547a59bc809ee2291782b8a0000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000024df3d91e000000000000000000000000000000000000000000000000000000000652d2a6d00000000000000000000000000000000000000000000000000000000000000074554482f55534400000000000000000000000000000000000000000000000000","0x02f901e50183f93c06b9010000000000000000000000000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000200f8dbf8d99439f46d72bb20c7bcb8a2cdf52630fac1496e859ae1a0a7fc99ed7617309ee23f63ae90196a1e490d362e6f6a547a59bc809ee2291782b8a000000000000000000000000000000000000000000000000000000000000000600000000000000000000000000000000000000000000000000000000005f4f04b00000000000000000000000000000000000000000000000000000000652d2a6e0000000000000000000000000000000000000000000000000000000000000008555344432f555344000000000000000000000000000000000000000000000000","0x02f901090183f9a412b9010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0","0x02f901c80183faf748b9010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000008000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000200000000000000000000000080000000000000004000000000800000000000000000000000000000000000000000000000200000000000000000400000000010000000000000000000000000000000000000000000000004800200000000000000000004000000010000000000000000000000000000000f8bef8bc94e5ff3b57695079f808a24256734483cd3889fa9ef884a0a7aaf2512769da4e444e3de247be2564225c2e7a8f74cfe528e46e17d24868e2a08a767b2e89133b95f135e6803d3b75eb52b9636707f38d986de63283fd028beba0000000000000000000000000000000000000000000000000000000000000803ca000000000000000000000000000000000000000000000000000000000003c1c98a000000000000000000000000000000000000000000000000000000000652d2a70","0x02f901090183fb5cb4b9010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0","0x02f901090183fbb880b9010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0","0x02f901090183fdf200b9010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0","0x02f901090183fe5538b9010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0","0x02f901090183febd24b9010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0","0xf90246018401009066b9010000000000000002000000000000000000000000000000000000800000000000000000000000000000000000000800000000000000000000000000000000000000000100000000000000000008020000000000040000000000000000000000000000000000000008000000000000000000100000000000000000800010800000000000000000000000000000010000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000010000000000000000002000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000040000000004000000000000044f9013af89b9470e53130c4638aa80d5a8abf12983f66e0b1d05ff863a0ddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa00000000000000000000000003e62eb1d9f503f1db36bcfcabdaa7488718eee09a0000000000000000000000000e8c84a631d71e1bb7083d3a82a3a74870a286b97a0000000000000000000000000000000000000000000000000016345785d8a0000f89b943e62eb1d9f503f1db36bcfcabdaa7488718eee09f863a0cb339b570a7f0b25afa7333371ff11192092a0aeace12b671f4c212f2815c6fea0000000000000000000000000000000000000000000000000000000000000235aa0000000000000000000000000e8c84a631d71e1bb7083d3a82a3a74870a286b97a0191ae0366d4470dec94ac0ad040496453fecc903ffbad13da54e39498f84b0ff","0x02f9010a01840100f0f6b9010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0","0x02f9010a0184010158f2b9010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0","0x02f9010a01840101d1feb9010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0","0x02f9010a0184010239f6b9010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0","0x02f9010a01840102a1f2b9010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0","0x02f90365018401048fdfb9010000000002000000000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000020000000000000002000000000000000000800000008000000000000040000000000000000002000000000000000000000000000100000000200000000000000200000000010000800000000000000000000000008000000000000000000000000000000000000000004000000000000000000000000800000000000000000000008000000002000000000000002000000000000000000000000000000000000800000000400000000000000000000002000000000000000000000004000000000000000000000000200f90259f89b948f6d296024766b919473f0ef3b1f7addd3f710dff863a0ddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa00000000000000000000000003dd070f9ee183bd667700d668b35b8932438118ea0000000000000000000000000f2ce1c36503401e5fcdecb17b53ac20939ac05d6a000000000000000000000000000000000000000000000000000000000000004d6f89b94d87ba7a50b2e7e660f678a895e4b72e7cb4ccd9cf863a0ddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa0000000000000000000000000f2ce1c36503401e5fcdecb17b53ac20939ac05d6a00000000000000000000000003dd070f9ee183bd667700d668b35b8932438118ea00000000000000000000000000000000000000000000000000000000000550ab9f9011c943dd070f9ee183bd667700d668b35b8932438118ef863a0c42079f94a6350d7e6235f29174924f928cc2ac818eb64fed8004e115fbcca67a0000000000000000000000000e592427a0aece92de3edee1f18e0157c05861564a0000000000000000000000000f2ce1c36503401e5fcdecb17b53ac20939ac05d6b8a0fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffb2a0000000000000000000000000000000000000000000000000000000000550ab90000000000000000000000000000000000000042fb2bb8fcdc72e6c302336a2800000000000000000000000000000000000000000000000000000000609fce5a000000000000000000000000000000000000000000000000000000000001487c","0x02f9010a01840105994fb9010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0","0x02f9010a01840106126bb9010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0","0xf9018601840106f418b9010000000000000000000000000020000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000020000000000000000001000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000080000000000000000000000000000000000000000000000000000000000000000000010f87bf87994b33a774f60c3eeea880c09bd56f18def648f8fbbe1a0b78ebc573f1f889ca9e1e0fb62c843c836f3d3a2e1f43ef62940e9b894f4ea4cb8400000000000000000000000000000000000000000000000000e507b8392b34d0000000000000000000000000000000000000000000000000000000000652d2a70","0x02f9010a018401075be8b9010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0","0x02f901c901840108af12b9010000000000000000000000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000100000000000000040000000000000000000000000000000000000000000000020000000000000000000000000000000000080000000100000000000000000000000000000000000000200000000000000000000000000000000000000004000020000800000000000000000000000000000000000000000000000000000000000000000000000000002000400000000000000000000000000000000000040000000000000000000001000000000000000000000000000000000000000000040000f8bef8bc943f97a3e25166de26eef93ad91e382215b21fecf7f884a0a7aaf2512769da4e444e3de247be2564225c2e7a8f74cfe528e46e17d24868e2a048f9d6c5064b083c5c5f17c6f18f8ac529863c506fc2d65b5ebb26571dfa1ec0a00000000000000000000000000000000000000000000000000000000000007097a0000000000000000000000000000000000000000000000000000000000034c740a000000000000000000000000000000000000000000000000000000000652d2a70","0x02f9010a01840109284ab9010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0","0x02f9010a01840109a406b9010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0","0x02f9010a0184010a1d2eb9010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0","0x02f9010a0184010a8536b9010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0","0x02f9010a0184010aead2b9010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0","0x02f9010a0184010b52b2b9010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0","0x02f9010a0184010bc95ab9010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0","0x02f9010a0184010c428ab9010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0","0xf901a80184010cc606b9010000000000000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000080000000000000020000000000000000000800000000000000000000000010000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000040001000000000000000000000000000000000000000002000000008000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000000000f89df89b94ccb2505976e9d2fd355c73c3f1a004446d1dfedaf863a0ddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa0000000000000000000000000c813edb526830d24a2ce5801d9ef5026a3967529a00000000000000000000000000000000000000000000000000000000000000000a0000000000000000000000000000000000000000000000000000000000000000a"]} diff --git a/specs/deposits.md b/specs/deposits.md index 442a4592db285..89ac821fbd97b 100644 --- a/specs/deposits.md +++ b/specs/deposits.md @@ -213,8 +213,9 @@ The RLP-encoded consensus-enforced fields are: - `bloom` (standard): bloom filter of the transaction logs. - `logs` (standard): log events emitted by the EVM processing. - `depositNonce` (unique extension): Optional field. The deposit transaction persists the nonce used during execution. - - Before Regolith, this `depositNonce` field must always be omitted. - - With Regolith, this `depositNonce` field must always be included. +- `depositNonceVersion` (unique extension): Optional field. The value must be 1 if the field is present + - Before Canyon, these `depositNonce` & `depositNonceVersion` fields must always be omitted. + - With Canyon, these `depositNonce` & `depositNonceVersion` fields must always be included. Starting with Regolith, the receipt API responses utilize the receipt changes for more accurate response data: @@ -308,9 +309,9 @@ A reference implementation of the L1 Attributes predeploy contract can be found [L1Block.sol]: ../packages/contracts-bedrock/src/L2/L1Block.sol -After running `pnpm build` in the `packages/contracts` directory, the bytecode to add to the genesis -file will be located in the `deployedBytecode` field of the build artifacts file at -`/packages/contracts/artifacts/contracts/L2/L1Block.sol/L1Block.json`. +After running `pnpm build` in the `packages/contracts-bedrock` directory, the bytecode to add to +the genesis file will be located in the `deployedBytecode` field of the build artifacts file at +`/packages/contracts-bedrock/forge-artifacts/L1Block.sol/L1Block.json`. ## User-Deposited Transactions diff --git a/specs/derivation.md b/specs/derivation.md index fede4a23caf3b..c271455b946d1 100644 --- a/specs/derivation.md +++ b/specs/derivation.md @@ -513,11 +513,14 @@ New frames for timed-out channels are dropped instead of buffered. #### Reading -The channel-bank can only output data from the first opened channel. - Upon reading, while the first opened channel is timed-out, remove it from the channel-bank. -Once the first opened channel, if any, is not timed-out and is ready, then it is read and removed from the channel-bank. +Prior to the Canyon network upgrade, once the first opened channel, if any, is not timed-out and is ready, +then it is read and removed from the channel-bank. After the Canyon network upgrade, the entire channel bank +is scanned in FIFO order (by open time) & the first ready (i.e. not timed-out) channel will be returned. + +The canyon behavior will activate when frames from a L1 block whose timestamp is greater than or equal to the +canyon time first enter the channel queue. A channel is ready if: @@ -534,7 +537,7 @@ a new channel is opened, tagged with the current L1 block, and appended to the c Frame insertion conditions: - New frames matching timed-out channels that have not yet been pruned from the channel-bank are dropped. -- Duplicate frames (by frame number) for frames that have not yet been pruned from the channel-bank are dropped. +- Duplicate frames (by frame number) for frames that have not been pruned from the channel-bank are dropped. - Duplicate closes (new frame `is_last == 1`, but the channel has already seen a closing frame and has not yet been pruned from the channel-bank) are dropped. @@ -691,9 +694,12 @@ equivalents. The `v2` methods are backwards compatible with `v1` payloads but su [`engine_getPayloadV2`]: exec-engine.md#engine_getpayloadv2 [`engine_newPayloadV2`]: exec-engine.md#engine_newpayloadv2 -The execution payload is an object of type [`ExecutionPayloadV1`][eth-payload]. +The execution payload is an object of type [`ExecutionPayloadV2`][eth-payload]. + +[eth-payload]: https://github.com/ethereum/execution-apis/blob/main/src/engine/shanghai.md#payloadattributesv2 -[eth-payload]: https://github.com/ethereum/execution-apis/blob/main/src/engine/paris.md#executionpayloadv1 +With V2 of the execution payload, before Canyon the withdrawals field is required to be nil. After Canyon the +withdrawals field is required to be non-nil. The op-node should set the withdrawals field to be an empty list. #### Forkchoice synchronization @@ -889,7 +895,7 @@ without dispute (fault proof challenge window), a name-collision with the proof- [deriving-payload-attr]: #deriving-payload-attributes For every L2 block derived from L1 data, we need to build [payload attributes][g-payload-attr], -represented by an [expanded version][expanded-payload] of the [`PayloadAttributesV1`][eth-payload] object, +represented by an [expanded version][expanded-payload] of the [`PayloadAttributesV2`][eth-payload] object, which includes additional `transactions` and `noTxPool` fields. This process happens during the payloads-attributes queue ran by a verifier node, as well as during block-production @@ -909,7 +915,7 @@ This block is part of a [sequencing epoch][g-sequencing-epoch], whose number matches that of an L1 block (its *[L1 origin][g-l1-origin]*). This L1 block is used to derive L1 attributes and (for the first L2 block in the epoch) user deposits. -Therefore, a [`PayloadAttributesV1`][expanded-payload] object must include the following transactions: +Therefore, a [`PayloadAttributesV2`][expanded-payload] object must include the following transactions: - one or more [deposited transactions][g-deposited], of two kinds: - a single *[L1 attributes deposited transaction][g-l1-attr-deposit]*, derived from the L1 origin. @@ -930,7 +936,7 @@ entries. [payload attributes]: #building-individual-payload-attributes -After deriving the transactions list, the rollup node constructs a [`PayloadAttributesV1`][extended-attributes] as +After deriving the transactions list, the rollup node constructs a [`PayloadAttributesV2`][extended-attributes] as follows: - `timestamp` is set to the batch's timestamp. @@ -940,6 +946,7 @@ follows: encoded with [EIP-2718]. - `noTxPool` is set to `true`, to use the exact above `transactions` list when constructing the block. - `gasLimit` is set to the current `gasLimit` value in the [system configuration][g-system-config] of this payload. +- `withdrawals` is set to nil prior to Canyon and an empty array after Canyon [extended-attributes]: exec-engine.md#extended-payloadattributesv1 [Fee Vaults]: exec-engine.md#fee-vaults diff --git a/specs/exec-engine.md b/specs/exec-engine.md index b72372ea78f38..a442fe3b9ceed 100644 --- a/specs/exec-engine.md +++ b/specs/exec-engine.md @@ -4,6 +4,7 @@ **Table of Contents** +- [1559 Parameters](#1559-parameters) - [Deposited transaction processing](#deposited-transaction-processing) - [Deposited transaction boundaries](#deposited-transaction-boundaries) - [Fees](#fees) @@ -13,7 +14,7 @@ - [L1-Cost fees (L1 Fee Vault)](#l1-cost-fees-l1-fee-vault) - [Engine API](#engine-api) - [`engine_forkchoiceUpdatedV2`](#engine_forkchoiceupdatedv2) - - [Extended PayloadAttributesV1](#extended-payloadattributesv1) + - [Extended PayloadAttributesV2](#extended-payloadattributesv2) - [`engine_newPayloadV2`](#engine_newpayloadv2) - [`engine_getPayloadV2`](#engine_getpayloadv2) - [`engine_signalSuperchainV1`](#engine_signalsuperchainv1) @@ -26,6 +27,14 @@ This document outlines the modifications, configuration and usage of a L1 execution engine for L2. +## 1559 Parameters + +The execution engine must be able to take a per chain configuration which specifies the EIP-1559 Denominator +and EIP-1559 elasticity. After Canyon it should also take a new value `EIP1559DenominatorCanyon` and use that as +the denominator in the 1559 formula rather than the prior denominator. + +The formula for EIP-1559 is not otherwise modified. + ## Deposited transaction processing The Engine interfaces abstract away transaction types with [EIP-2718][eip-2718]. @@ -140,17 +149,18 @@ Within the rollup, the types of forkchoice updates translate as: - `finalizedBlockHash`: irreversible block hash, matches lower boundary of the dispute period. To support rollup functionality, one backwards-compatible change is introduced -to [`engine_forkchoiceUpdatedV2`][engine_forkchoiceUpdatedV2]: the extended `PayloadAttributesV1` +to [`engine_forkchoiceUpdatedV2`][engine_forkchoiceUpdatedV2]: the extended `PayloadAttributesV2` -#### Extended PayloadAttributesV1 +#### Extended PayloadAttributesV2 -[`PayloadAttributesV1`][PayloadAttributesV1] is extended to: +[`PayloadAttributesV2`][PayloadAttributesV2] is extended to: ```js -PayloadAttributesV1: { +PayloadAttributesV2: { timestamp: QUANTITY random: DATA (32 bytes) suggestedFeeRecipient: DATA (20 bytes) + withdrawals: array of WithdrawalV1 transactions: array of DATA noTxPool: bool gasLimit: QUANTITY or null @@ -163,7 +173,7 @@ to a JSON array. Each item of the `transactions` array is a byte list encoding a transaction: `TransactionType || TransactionPayload` or `LegacyTransaction`, as defined in [EIP-2718][eip-2718]. -This is equivalent to the `transactions` field in [`ExecutionPayloadV1`][ExecutionPayloadV1] +This is equivalent to the `transactions` field in [`ExecutionPayloadV2`][ExecutionPayloadV2] The `transactions` field is optional: @@ -301,7 +311,7 @@ the operation within the engine is the exact same as with L1 (although with an E [eip-2718-transactions]: https://eips.ethereum.org/EIPS/eip-2718#transactions [exec-api-data]: https://github.com/ethereum/execution-apis/blob/769c53c94c4e487337ad0edea9ee0dce49c79bfa/src/engine/specification.md#structures [l1-api-spec]: https://github.com/ethereum/execution-apis/blob/769c53c94c4e487337ad0edea9ee0dce49c79bfa/src/engine/specification.md -[PayloadAttributesV1]: https://github.com/ethereum/execution-apis/blob/769c53c94c4e487337ad0edea9ee0dce49c79bfa/src/engine/specification.md#PayloadAttributesV1 +[PayloadAttributesV2]: https://github.com/ethereum/execution-apis/blob/584905270d8ad665718058060267061ecfd79ca5/src/engine/shanghai.md#PayloadAttributesV2 [ExecutionPayloadV1]: https://github.com/ethereum/execution-apis/blob/769c53c94c4e487337ad0edea9ee0dce49c79bfa/src/engine/specification.md#ExecutionPayloadV1 [engine_forkchoiceUpdatedV2]: https://github.com/ethereum/execution-apis/blob/584905270d8ad665718058060267061ecfd79ca5/src/engine/shanghai.md#engine_forkchoiceupdatedv2 [engine_newPayloadV2]: https://github.com/ethereum/execution-apis/blob/584905270d8ad665718058060267061ecfd79ca5/src/engine/shanghai.md#engine_newpayloadv2 diff --git a/specs/glossary.md b/specs/glossary.md index 166d1fac4e02e..d163aae6c5947 100644 --- a/specs/glossary.md +++ b/specs/glossary.md @@ -392,7 +392,7 @@ proof][fault-proof]. Data availability is the guarantee that some data will be "available" (i.e. *retrievable*) during a reasonably long time window. In Optimism's case, the data in question are [sequencer batches][sequencer-batch] that [validators][validator] -needs in order to verify the sequencer's work and validate the L2 chain. +need in order to verify the sequencer's work and validate the L2 chain. The [finalization period][finalization-period] should be taken as the lower bound on the availability window, since that is when data availability is the most crucial, as it is needed to perform a [fault proof][fault-proof]. @@ -471,9 +471,8 @@ channels available. These transactions carry one or more full frames, which may channel's frame may be split between multiple batcher transactions. When submitted to Ethereum calldata, the batcher transaction's receiver must be the sequencer inbox address. The -transaction must also be signed by a recognized batch submitter account. - -> **TODO** specify where these recognized batch submitter accounts are stored +transaction must also be signed by a recognized batch submitter account. The recognized batch submitter account +is stored in the [System Configuration][system-config]. ## Channel Timeout @@ -798,7 +797,7 @@ In these specifications, "execution engine" always refer to the L2 execution eng [Solidity events]: https://docs.soliditylang.org/en/latest/contracts.html?highlight=events#events [nano-header]: https://github.com/norswap/nanoeth/blob/cc5d94a349c90627024f3cd629a2d830008fec72/src/com/norswap/nanoeth/blocks/BlockHeader.java#L22-L156 [yellow]: https://ethereum.github.io/yellowpaper/paper.pdf -[engine-api]: https://github.com/ethereum/execution-apis/blob/main/src/engine/paris.md#PayloadAttributesV1 +[engine-api]: https://github.com/ethereum/execution-apis/blob/main/src/engine/shanghai.md#PayloadAttributesV2 [merge]: https://ethereum.org/en/eth2/merge/ [mempool]: https://www.quicknode.com/guides/defi/how-to-access-ethereum-mempool [L1 consensus layer]: https://github.com/ethereum/consensus-specs/#readme diff --git a/specs/meta/devnet.md b/specs/meta/devnet.md index ad9de46e9ce95..b39a55a04d4ff 100644 --- a/specs/meta/devnet.md +++ b/specs/meta/devnet.md @@ -12,7 +12,7 @@ You can spin up a local devnet via `docker compose`. For convenience, we have defined `make` targets to start and stop the devnet with a single command. To run the devnet, you will need `docker` installed. -Then, as a precondition, make sure that you have compiled the contracts by `cd`ing into `packages/contracts` +Then, as a precondition, make sure that you have compiled the contracts by `cd`ing into `packages/contracts-bedrock` and running `pnpm i` followed by `pnpm build`. You'll only need to do this if you change the contracts in the future. Then, run the following: diff --git a/specs/predeploys.md b/specs/predeploys.md index f3942821c7555..5aa93d7bc8700 100644 --- a/specs/predeploys.md +++ b/specs/predeploys.md @@ -23,6 +23,7 @@ - [L1FeeVault](#l1feevault) - [SchemaRegistry](#schemaregistry) - [EAS](#eas) +- [create2Deployer](#create2deployer) @@ -45,7 +46,7 @@ and there is no proxy deployed at that account. The following table includes each of the predeploys. The system version indicates when the predeploy was introduced. The possible values are `Legacy` -or `Bedrock`. Deprecated contracts should not be used. +or `Bedrock` or `Canyon`. Deprecated contracts should not be used. | Name | Address | Introduced | Deprecated | Proxied | | ----------------------------- | ------------------------------------------ | ---------- | ---------- |---------| @@ -69,6 +70,7 @@ or `Bedrock`. Deprecated contracts should not be used. | L1FeeVault | 0x420000000000000000000000000000000000001a | Bedrock | No | Yes | | SchemaRegistry | 0x4200000000000000000000000000000000000020 | Bedrock | No | Yes | | EAS | 0x4200000000000000000000000000000000000021 | Bedrock | No | Yes | +| create2Deployer | 0x13b0D85CcB8bf860b6b79AF3029fCA081AE9beF2 | Canyon | No | No | ## LegacyMessagePasser @@ -332,3 +334,54 @@ protocol. Address: `0x4200000000000000000000000000000000000021` The `EAS` predeploy implements the `Ethereum Attestation Service` protocol. + +## create2Deployer + +[Implementation](https://github.com/mdehoog/create2deployer/blob/69b9a8e112b15f9257ce8c62b70a09914e7be29c/contracts/Create2Deployer.sol) + +The create2Deployer is a nice Solidity wrapper around the CREATE2 opcode. It provides the following ABI. + +```solidity + /** + * @dev Deploys a contract using `CREATE2`. The address where the + * contract will be deployed can be known in advance via {computeAddress}. + * + * The bytecode for a contract can be obtained from Solidity with + * `type(contractName).creationCode`. + * + * Requirements: + * - `bytecode` must not be empty. + * - `salt` must have not been used for `bytecode` already. + * - the factory must have a balance of at least `value`. + * - if `value` is non-zero, `bytecode` must have a `payable` constructor. + */ + function deploy(uint256 value, bytes32 salt, bytes memory code) public + + /** + * @dev Deployment of the {ERC1820Implementer}. + * Further information: https://eips.ethereum.org/EIPS/eip-1820 + */ + function deployERC1820Implementer(uint256 value, bytes32 salt) + + /** + * @dev Returns the address where a contract will be stored if deployed via {deploy}. + * Any change in the `bytecodeHash` or `salt` will result in a new destination address. + */ + function computeAddress(bytes32 salt, bytes32 codeHash) public view returns (address) + + /** + * @dev Returns the address where a contract will be stored if deployed via {deploy} from a + * contract located at `deployer`. If `deployer` is this contract's address, returns the + * same value as {computeAddress}. + */ + function computeAddressWithDeployer( + bytes32 salt, + bytes32 codeHash, + address deployer + ) public pure returns (address) +``` + +Address: `0x13b0D85CcB8bf860b6b79AF3029fCA081AE9beF2` + +When Canyon activates, the contract code at `0x13b0D85CcB8bf860b6b79AF3029fCA081AE9beF2` is set to +`0x6080604052600436106100435760003560e01c8063076c37b21461004f578063481286e61461007157806356299481146100ba57806366cfa057146100da57600080fd5b3661004a57005b600080fd5b34801561005b57600080fd5b5061006f61006a366004610327565b6100fa565b005b34801561007d57600080fd5b5061009161008c366004610327565b61014a565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390f35b3480156100c657600080fd5b506100916100d5366004610349565b61015d565b3480156100e657600080fd5b5061006f6100f53660046103ca565b610172565b61014582826040518060200161010f9061031a565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe082820381018352601f90910116604052610183565b505050565b600061015683836102e7565b9392505050565b600061016a8484846102f0565b949350505050565b61017d838383610183565b50505050565b6000834710156101f4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f437265617465323a20696e73756666696369656e742062616c616e636500000060448201526064015b60405180910390fd5b815160000361025f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f437265617465323a2062797465636f6465206c656e677468206973207a65726f60448201526064016101eb565b8282516020840186f5905073ffffffffffffffffffffffffffffffffffffffff8116610156576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601960248201527f437265617465323a204661696c6564206f6e206465706c6f790000000000000060448201526064016101eb565b60006101568383305b6000604051836040820152846020820152828152600b8101905060ff815360559020949350505050565b61014e806104ad83390190565b6000806040838503121561033a57600080fd5b50508035926020909101359150565b60008060006060848603121561035e57600080fd5b8335925060208401359150604084013573ffffffffffffffffffffffffffffffffffffffff8116811461039057600080fd5b809150509250925092565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6000806000606084860312156103df57600080fd5b8335925060208401359150604084013567ffffffffffffffff8082111561040557600080fd5b818601915086601f83011261041957600080fd5b81358181111561042b5761042b61039b565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f011681019083821181831017156104715761047161039b565b8160405282815289602084870101111561048a57600080fd5b826020860160208301376000602084830101528095505050505050925092509256fe608060405234801561001057600080fd5b5061012e806100206000396000f3fe6080604052348015600f57600080fd5b506004361060285760003560e01c8063249cb3fa14602d575b600080fd5b603c603836600460b1565b604e565b60405190815260200160405180910390f35b60008281526020818152604080832073ffffffffffffffffffffffffffffffffffffffff8516845290915281205460ff16608857600060aa565b7fa2ef4600d742022d532d4747cb3547474667d6f13804902513b2ec01c848f4b45b9392505050565b6000806040838503121560c357600080fd5b82359150602083013573ffffffffffffffffffffffffffffffffffffffff8116811460ed57600080fd5b80915050925092905056fea26469706673582212205ffd4e6cede7d06a5daf93d48d0541fc68189eeb16608c1999a82063b666eb1164736f6c63430008130033a2646970667358221220fdc4a0fe96e3b21c108ca155438d37c9143fb01278a3c1d274948bad89c564ba64736f6c63430008130033`. diff --git a/specs/rollup-node-p2p.md b/specs/rollup-node-p2p.md index 6ae3b725413f1..2733d41220462 100644 --- a/specs/rollup-node-p2p.md +++ b/specs/rollup-node-p2p.md @@ -51,7 +51,8 @@ and are adopted by several other blockchains, most notably the [L1 consensus lay - [Topic configuration](#topic-configuration) - [Topic validation](#topic-validation) - [Gossip Topics](#gossip-topics) - - [`blocks`](#blocks) + - [`blocksv1`](#blocksv1) + - [`blocksv2`](#blocksv2) - [Block encoding](#block-encoding) - [Block signatures](#block-signatures) - [Block validation](#block-validation) @@ -247,9 +248,15 @@ The extended validator emits one of the following validation signals: ## Gossip Topics -### `blocks` +There are two topics for distributing blocks to other nodes faster than proxying through L1 would. These are: -The primary topic of the L2, to distribute blocks to other nodes faster than proxying through L1 would. +### `blocksv1` + +Pre-Canyon/Shanghai blocks are broadcast on `/optimism//0/blocks`. + +### `blocksv2` + +Post-Canyon/Shanghai blocks are broadcast on `/optimism//1/blocks`. #### Block encoding @@ -282,6 +289,9 @@ An [extended-validator] checks the incoming messages as follows, in order of ope (graceful boundary for worst-case propagation and clock skew) - `[REJECT]` if the `payload.timestamp` is more than 5 seconds into the future - `[REJECT]` if the `block_hash` in the `payload` is not valid +- `[REJECT]` if the block is on the V1 topic and has withdrawals +- `[REJECT]` if the block is on the V2 topic and does not have withdrawals +- `[REJECT]` if the block is on the V2 topic and has a non-zero amount of withdrawals - `[REJECT]` if more than 5 different blocks have been seen with the same block height - `[IGNORE]` if the block has already been seen - `[REJECT]` if the signature by the sequencer is not valid diff --git a/specs/safe-liveness-checking.md b/specs/safe-liveness-checking.md new file mode 100644 index 0000000000000..654516bd5201e --- /dev/null +++ b/specs/safe-liveness-checking.md @@ -0,0 +1,194 @@ +# Safe Liveness Checking + + + +**Table of Contents** + +- [Liveness checking Mechanism](#liveness-checking-mechanism) +- [Liveness checking methodology](#liveness-checking-methodology) + - [The liveness guard](#the-liveness-guard) + - [The liveness module](#the-liveness-module) + - [Owner removal call flow](#owner-removal-call-flow) + - [Shutdown](#shutdown) + - [Security Properties](#security-properties) + - [In the guard](#in-the-guard) + - [In the module](#in-the-module) + - [Interdependency between the guard and module](#interdependency-between-the-guard-and-module) +- [Operational considerations](#operational-considerations) + - [Manual validation of new owner liveness](#manual-validation-of-new-owner-liveness) + - [Deploying the liveness checking system](#deploying-the-liveness-checking-system) + - [Modify the liveness checking system](#modify-the-liveness-checking-system) + - [Replacing the module](#replacing-the-module) + - [Replacing the guard](#replacing-the-guard) + + + +## Liveness checking Mechanism + +The Security Security Council uses a specially extended Safe multisig contract to ensure that +any loss of access to a signer's keys is identified and addressed within a predictable period of +time. + +This mechanism is intended only to be used to remove signers who have lost access to their keys, or +are otherwise inactive. It is not intended to be used to remove signers who are acting in bad faith, +or any other subjective criteria, such cases should be addressed by governance, and the removal +handled via the standard Safe ownership management functionality. + +## Liveness checking methodology + +This is achieved using two types of contracts which the Safe contract has built-in support for: + +1. **Guard contracts:** can execute pre- and post- transaction checks. +1. **Module contracts:** a contract which is added to the Safe by the signers, and thenceforth is + authorized to execute transactions via the Safe. This means the module must properly implement + auth conditions internally. + +### The liveness guard + +For implementing liveness checks a `LivenessGuard` is created which receives the signatures from +each executed transaction, and tracks the latest time at which a transaction was signed by each +signer. This time is made publicly available by calling a `lastLive(address)(Timestamp)` method. + +Owners are recorded in this mapping in one of 4 ways: + +1. Upon deployment, the guard reads the current set of owners from the Safe contract. +1. When a new owner is added to the safe. Similarly, when an owner is removed from the Safe, it's + entry is deleted from the mapping. +1. When a transaction is executed, the signatures on that transaction are passed to the guard and + used to identify the signers. If more than the required number of signatures is provided, they + are ignored. +1. An owner may call the contract's `showLiveness()()` method directly in order to prove liveness. + +Note that the first two methods do not require the owner to actually sign anything. However these mechanisms +are necessary to prevent new owners from being removed before they have had a chance to show liveness. + +### The liveness module + +A `LivenessModule` is also created which does the following: + +1. Has a function `removeOwners()` that anyone may call to specify one or more owners to be removed from the + Safe. +1. The Module would then check the `LivenessGuard.lastLive()` to determine if the signer is + eligible for removal. +1. If so, it will call the Safe's `removeSigner()` to remove the non-live signer, and if necessary + reduce the threshold. +1. When a member is removed, the signing parameters are modified such that `M/N` is the lowest ratio + which remains greater than or equal to 75%. Using integer math, this can be expressed as `M = (N * 75 + 99) / 100`. + +### Owner removal call flow + +The following diagram illustrates the flow for removing a single owner. The `verifyFinalState` +box indicates calls to the Safe which ensure the final state is valid. + +```mermaid +sequenceDiagram + participant User + participant LivenessModule + participant LivenessGuard + participant Safe + User->>LivenessModule: removeOwners([previousOwner], [owner]) + LivenessModule->>LivenessGuard: lastLive(owner) + LivenessModule->>Safe: getOwners() + LivenessModule->>Safe: removeOwner(previousOwner, owner) + + alt verifyFinalState + LivenessModule->>Safe: getOwners() + LivenessModule->>Safe: getThreshold() + LivenessModule->>Safe: getGuard() + end +``` + +### Shutdown + +In the unlikely event that the signer set (`N`) is reduced below the allowed minimum number of + owners, then (and only then) is a shutdown mechanism activated which removes the existing + signers, and hands control of the multisig over to a predetermined entity. + +### Security Properties + +The following security properties must be upheld: + +#### In the guard + +1. Signatures are assigned to the correct signer. +1. Non-signers are unable to create a record of having signed. +1. An owner cannot be censored or griefed such that their signing is not recorded. +1. Owners may demonstrate liveness either by signing a transaction or by calling directly to the + guard. +1. It must be impossible for the guard's `checkTransaction` or `checkAfterExecution` method to + permanently revert given any calldata and the current state. +1. The guard correctly handles updates to the owners list, such that new owners are recorded, and + removed owners are deleted. + 1. An `ownersBefore` enumerable set variable is used to accomplish this, it must be emptied at + the end of the `checkAfterExecution` call. + +#### In the module + +1. During a shutdown the module correctly removes all signers, and converts the safe to a 1 of 1. +1. The module only removes an owner if they have not demonstrated liveness during the interval, or + if enough other owners have been removed to activate the shutdown mechanism. +1. The module correctly sets the Safe's threshold upon removing a signer. + +Note: neither the module nor guard attempt to prevent a quorum of owners from removing either the liveness +module or guard. There are legitimate reasons they might wish to do so. Moreover, if such a quorum +of owners exists, there is no benefit to removing them, as they are defacto 'sufficiently live'. + +### Interdependency between the guard and module + +The guard has no dependency on the module, and can be used independently to track liveness of +Safe owners. + +This means that the module can be removed or replaced without any affect on the guard. + +The module however does have a dependency on the guard; if the guard is removed from the Safe, then +the module will no longer be functional and calls to its `removeOwners` function will revert. + +## Operational considerations + +### Manual validation of new owner liveness + +As [noted above](#the-liveness-guard) newly added owners are recorded in the guard without +necessarily having signed a transaction. Off-chain validation of the liveness of an address must +therefore be done prior to adding a new owner. + +### Deploying the liveness checking system + +[deploying]: #deploying-the-liveness-checking-system + +The module and guard are intended to be deployed and installed on the safe in the following +sequence: + +1. Deploy the guard contract + 2. The guard's constructor will read the Safe's owners and set a timestamp +1. Deploy the module. +1. Set the guard on the safe. +1. Enable the module on the safe. + +This order of operations is necessary to satisfy the constructor checks in the module, and is +intended to prevent owners from being immediately removable. + +Note that changes to the owners set should not be made between the time the module is deployed, and +when it is enabled on the Safe, otherwise the checks made in the module's constructor may be +invalidated. If such changes are made, a new module should be deployed. + +### Modify the liveness checking system + +Changes to the liveness checking system should be done in the following manner: + +#### Replacing the module + +The module can safely be removed without affecting the operation of the guard. A new module can then +be added. + +Note: none of the module's parameters are modifiable. In order to update the security properties +enforced by the module, it must be replaced. + +#### Replacing the guard + +The safe can only have one guard contract at a time, and if the guard is removed the module will +cease to function. This does not affect the ability of the Safe to operate normally, however the +module should be removed as a best practice. + +If a new guard is added, eg. as a means of upgrading it, then a new module will also need to be +deployed and enabled. Once both the guard and module have been removed, they can be replaced +according to the steps in the [Deployment][deploying] section above. diff --git a/specs/span-batches.md b/specs/span-batches.md index 9b1b17db5f993..7fe6392d680fc 100644 --- a/specs/span-batches.md +++ b/specs/span-batches.md @@ -9,6 +9,7 @@ - [Introduction](#introduction) - [Span batch format](#span-batch-format) +- [Span batch Activation Rule](#span-batch-activation-rule) - [Optimization Strategies](#optimization-strategies) - [Truncating information and storing only necessary data](#truncating-information-and-storing-only-necessary-data) - [`tx_data_headers` removal from initial specs](#tx_data_headers-removal-from-initial-specs) @@ -63,6 +64,8 @@ Span-batches address these inefficiencies, with a new batch format version. ## Span batch format +[span-batch-format]: #span-batch-format + Note that span-batches, unlike previous singular batches, encode *a range of consecutive* L2 blocks at the same time. @@ -94,7 +97,7 @@ Where: - `l1_origin_check`: the block hash of the last L1 origin is referenced. The hash is truncated to 20 bytes for efficiency, i.e. `span_end.l1_origin.hash[:20]`. - `payload = block_count ++ origin_bits ++ block_tx_counts ++ txs`: - - `block_count`: `uvarint` number of L2 blocks. + - `block_count`: `uvarint` number of L2 blocks. This is at least 1, empty span batches are invalid. - `origin_bits`: bitlist of `block_count` bits, right-padded to a multiple of 8 bits: 1 bit per L2 block, indicating if the L1 origin changed this L2 block. - `block_tx_counts`: for each block, a `uvarint` of `len(block.transactions)`. @@ -130,6 +133,7 @@ Where: - `prefix = rel_timestamp ++ l1_origin_num ++ parent_check ++ l1_origin_check`: - Identical to `batch_version` 1 - `payload = block_count ++ origin_bits ++ block_tx_counts ++ txs ++ fee_recipients`: + - An empty span-batch, i.e. with `block_count == 0`, is invalid and must not be processed. - Every field definition identical to `batch_version` 1 except that `fee_recipients` is added to support more decentralized sequencing. - `fee_recipients = fee_recipients_idxs + fee_recipients_set` @@ -143,6 +147,25 @@ Where: [EIP-1559]: https://eips.ethereum.org/EIPS/eip-1559 +Total size of encoded span batch is limited to `MAX_SPAN_BATCH_SIZE` (currently 10,000,000 bytes, +equal to `MAX_RLP_BYTES_PER_CHANNEL`). Therefore every field size of span batch will be implicitly limited to +`MAX_SPAN_BATCH_SIZE` . There can be at least single span batch per channel, and channel size is limited +to `MAX_RLP_BYTES_PER_CHANNEL` and you may think that there is already an implicit limit. However, having an explicit +limit for span batch is helpful for several reasons. We may save computation costs by avoiding malicious input while +decoding. For example, lets say bad batcher wrote span batch which `block_count = max.Uint64`. We may early return using +the explicit limit, not trying to consume data until EOF is reached. We can also safely preallocate memory for decoding +because we know the upper limit of memory usage. + +## Span batch Activation Rule + +The span batch upgrade is activated based on timestamp. + +Activation Rule: `upgradeTime != null && span_start.l1_origin.timestamp >= upgradeTime` + +`span_start.l1_origin.timestamp` is the L1 origin block timestamp of the first block in the span batch. +This rule ensures that every chain activity regarding this span batch is done after the hard fork. +i.e. Every block in the span is created, submitted to the L1, and derived from the L1 after the hard fork. + ## Optimization Strategies ### Truncating information and storing only necessary data @@ -247,14 +270,29 @@ Span-batches share the same queue with v0 batches: batches are processed in L1 i A set of modified validation rules apply to the span-batches. Rules are enforced with the [contextual definitions](./derivation.md#batch-queue) as v0-batch validation: -`batch`, `epoch`, `inclusion_block_number`, `next_timestamp`, `next_epoch`, `batch_origin` +`epoch`, `inclusion_block_number`, `next_timestamp` + +Definitions: + +- `batch` as defined in the [Span batch format section][span-batch-format]. +- `prev_l2_block` is the L2 block from the current safe chain, + whose timestamp is at `span_start.timestamp - l2_block_time` Span-batch rules, in validation order: -- `batch.start_timestamp > next_timestamp` -> `future`: i.e. the batch must be ready to process. -- `batch.start_timestamp < next_timestamp` -> `drop`: i.e. the batch must not be too old. -- `batch.parent_check != safe_l2_head.hash[:20]` -> `drop`: i.e. the checked part of the parent hash must be equal - to the L2 safe head block hash. +- `batch_origin` is determined like with singular batches: + - `batch.epoch_num == epoch.number+1`: + - If `next_epoch` is not known -> `undecided`: + i.e. a batch that changes the L1 origin cannot be processed until we have the L1 origin data. + - If known, then define `batch_origin` as `next_epoch` +- `batch_origin.timestamp < span_batch_upgrade_timestamp` -> `drop`: + i.e. enforce the [span batch upgrade activation rule](#span-batch-activation-rule). +- `span_start.timestamp > next_timestamp` -> `future`: i.e. the batch must be ready to process, + but does not have to start exactly at the `next_timestamp`, since it can overlap with previously processed blocks, +- `span_end.timestamp < next_timestamp` -> `drop`: i.e. the batch must have at least one new block to process. +- If there's no `prev_l2_block` in the current safe chain -> `drop`: i.e. the timestamp must be aligned. +- `batch.parent_check != prev_l2_block.hash[:20]` -> `drop`: + i.e. the checked part of the parent hash must be equal to the same part of the corresponding L2 block hash. - Sequencing-window checks: - Note: The sequencing window is enforced for the *batch as a whole*: if the batch was partially invalid instead, it would drop the oldest L2 blocks, @@ -266,7 +304,7 @@ Span-batch rules, in validation order: - Rules: - `start_epoch_num + sequence_window_size < inclusion_block_number` -> `drop`: i.e. the batch must be included timely. - - `start_epoch_num > epoch.number + 1` -> `drop`: + - `start_epoch_num > prev_l2_block.l1_origin.number + 1` -> `drop`: i.e. the L1 origin cannot change by more than one L1 block per L2 block. - If `batch.l1_origin_check` does not match the canonical L1 chain at `end_epoch_num` -> `drop`: verify the batch is intended for this L1 chain. @@ -274,9 +312,8 @@ Span-batch rules, in validation order: is past `inclusion_block_number` because of the following invariant. - Invariant: the epoch-num in the batch is always less than the inclusion block number, if and only if the L1 epoch hash is correct. - - `start_epoch_num < epoch.number` -> `drop`: must have been duplicate batch, - we may be past this L1 block in the safe L2 chain. If a span-batch overlaps with older information, - it is dropped, since partially valid span-batches are not accepted. + - `start_epoch_num < prev_l2_block.l1_origin.number` -> `drop`: + epoch number cannot be older than the origin of parent block - Max Sequencer time-drift checks: - Note: The max time-drift is enforced for the *batch as a whole*, to keep the possible output variants small. - Variables: @@ -285,7 +322,7 @@ Span-batch rules, in validation order: - `next_epoch`: `block_input.origin`'s next L1 block. It may reach to the next origin outside the L1 origins of the span. - Rules: - - For each `block_input` that can be read from the span-batch: + - For each `block_input` whose timestamp is greater than `safe_head.timestamp`: - `block_input.timestamp < block_input.origin.time` -> `drop`: enforce the min L2 timestamp rule. - `block_input.timestamp > block_input.origin.time + max_sequencer_drift`: enforce the L2 timestamp drift rule, but with exceptions to preserve above min L2 timestamp invariant: @@ -304,6 +341,16 @@ Span-batch rules, in validation order: that is invalid or derived by other means exclusively: - any transaction that is empty (zero length `tx_data`) - any [deposited transactions][g-deposit-tx-type] (identified by the transaction type prefix byte in `tx_data`) +- Overlapped blocks checks: + - Note: If the span batch overlaps the current L2 safe chain, we must validate all overlapped blocks. + - Variables: + - `block_input`: an L2 block derived from the span-batch. + - `safe_block`: an L2 block from the current L2 safe chain, at same timestamp as `block_input` + - Rules: + - For each `block_input`, whose timestamp is less than `next_timestamp`: + - `block_input.l1_origin.number != safe_block.l1_origin.number` -> `drop` + - `block_input.transactions != safe_block.transactions` -> `drop` + - compare excluding deposit transactions Once validated, the batch-queue then emits a block-input for each of the blocks included in the span-batch. The next derivation stage is thus only aware of individual block inputs, similar to the previous V0 batch, diff --git a/specs/superchain-upgrades.md b/specs/superchain-upgrades.md index 244c318622e95..5824767963a87 100644 --- a/specs/superchain-upgrades.md +++ b/specs/superchain-upgrades.md @@ -32,6 +32,7 @@ chains following the same Superchain Target upgrade synchronously. - [OP-Stack Protocol versions](#op-stack-protocol-versions) - [Post-Bedrock Network upgrades](#post-bedrock-network-upgrades) - [Regolith](#regolith) +- [Canyon](#canyon) @@ -128,6 +129,7 @@ Patch version changes indicate backward compatible bug fixes and improvements. Pre-releases of the protocol are proposals: these are not stable targets for production usage. A pre-release might not satisfy the intended compatibility requirements as denoted by its associated normal version. The `` must be non-zero to apply to the protocol version. +The `` `0`-value is reserved for non-prereleases, i.e. `v3.1.0` is higher than `v3.1.0-1`. Node-software may support a pre-release, but must not activate any protocol changes without the user explicitly opting in through the means of a feature-flag or configuration change. @@ -198,7 +200,10 @@ and are then retrieved from the superchain target configuration. ### L2 Block-number based activation (deprecated) -Activation rule: `x != null && x >= upgradeNumber` +Activation rule: `upgradeNumber != null && block.number >= upgradeNumber` + +Starting at, and including, the L2 `block` with `block.number >= upgradeNumber`, the upgrade rules apply. +If the upgrade block-number `upgradeNumber` is not specified in the configuration, the upgrade is ignored. This block number based method has commonly been used in L1 up until the Bellatrix/Paris upgrade, a.k.a. The Merge, which was upgraded through special rules. @@ -206,22 +211,19 @@ which was upgraded through special rules. This method is not superchain-compatible, as the activation-parameter is chain-specific (different chains may have different block-heights at the same moment in time). -Starting at, and including, the L2 `block` with `block.number == x`, the upgrade rules apply. -If the upgrade block-number `x` is not specified in the configuration, the upgrade is ignored. - This applies to the L2 block number, not to the L1-origin block number. This means that an L2 upgrade may be inactive, and then active, without changing the L1-origin. ### L2 Block-timestamp based activation -Activation rule: `x != null && x >= upgradeTime` +Activation rule: `upgradeTime != null && block.timestamp >= upgradeTime` + +Starting at, and including, the L2 `block` with `block.timestamp >= upgradeTime`, the upgrade rules apply. +If the upgrade block-timestamp `upgradeTime` is not specified in the configuration, the upgrade is ignored. This is the preferred superchain upgrade activation-parameter type: it is synchronous between all L2 chains and compatible with post-Merge timestamp-based chain upgrades in L1. -Starting at, and including, the L2 `block` with `block.timestamp == x`, the upgrade rules apply. -If the upgrade block-timestamp `x` is not specified in the configuration, the upgrade is ignored. - This applies to the L2 block timestamp, not to the L1-origin block timestamp. This means that an L2 upgrade may be inactive, and then active, without changing the L1-origin. @@ -244,6 +246,7 @@ but the matching L1-origin information may not be present at the time of activat ([announcement](https://optimism.mirror.xyz/gQWKlrDqHzdKPsB1iUnI-cVN3v0NvsWnazK7ajlt1fI)). - `v3.0.0-1`: 2023 Jan 13th - Bedrock pre-release, deployed on OP-Goerli, and later Base-Goerli. - `v3.0.0`: 2023 Jun 6th - Bedrock, including the Regolith hardfork improvements, first deployed on OP-Mainnet. +- `v4.0.0`: TBD - Canyon ## Post-Bedrock Network upgrades @@ -272,3 +275,24 @@ The [execution engine specification](./exec-engine.md) specifies the L1 cost fun The Regolith upgrade uses a *L2 block-timestamp* activation-rule, and is specified in both the rollup-node (`regolith_time`) and execution engine (`config.regolithTime`). + +## Canyon + +The Canyon upgrade contains the Shapella upgrade from L1 and some minor protocol fixes. + +- Shapella Upgrade + - [EIP-3651: Warm COINBASE](https://eips.ethereum.org/EIPS/eip-3651) + - [EIP-3855: PUSH0 instruction](https://eips.ethereum.org/EIPS/eip-3855) + - [EIP-3860: Limit and meter initcode](https://eips.ethereum.org/EIPS/eip-3860) + - [EIP-4895: Beacon chain push withdrawals as operations](https://eips.ethereum.org/EIPS/eip-4895) + - [Withdrawlas are prohibited in P2P Blocks](./rollup-node-p2p.md#block-validation) + - [Withdrawals should be set to the empty array with Canyon](./derivation.md#building-individual-payload-attributes) + - [EIP-6049: Deprecate SELFDESTRUCT](https://eips.ethereum.org/EIPS/eip-6049) +- [Modifies the EIP-1559 Denominator](./exec-engine.md#1559-parameters) +- [Channel Ordering Fix](./derivation.md#reading) +- [Adds the deposit nonce & deposit nonce version to the deposit receipt hash](./deposits.md#deposit-receipt) +- [Deploys the create2Deployer to `0x13b0D85CcB8bf860b6b79AF3029fCA081AE9beF2`](./predeploys.md#create2deployer) + +The Canyon upgrade uses a *L2 block-timestamp* activation-rule, and is specified in both the +rollup-node (`canyon_time`) and execution engine (`config.canyonTime`). Shanghai time in the +execution engine should be set to the same time as the Canyon time. diff --git a/ufm-test-services/metamask/Dockerfile b/ufm-test-services/metamask/Dockerfile index 1e9631470ab03..b09e7bc3912fe 100644 --- a/ufm-test-services/metamask/Dockerfile +++ b/ufm-test-services/metamask/Dockerfile @@ -7,6 +7,8 @@ WORKDIR /app # Update PATH ENV PATH /app/node_modules/.bin:$PATH +RUN npm i -g pnpm + RUN if [ "$METAMASK_PLAYWRIGHT_RUN_HEADLESS" != "false" ]; then \ apt-get update && \ apt-get install -y xvfb && \ @@ -14,8 +16,8 @@ RUN if [ "$METAMASK_PLAYWRIGHT_RUN_HEADLESS" != "false" ]; then \ fi # Copy necessary files and directories -COPY package.json /app/ -RUN npm install +COPY package.json pnpm-lock.yaml pnpm-workspace.yaml /app/ +RUN pnpm install --frozen-lockfile COPY tests /app/tests/ COPY playwright.config.ts /app/ COPY start.sh /app/ diff --git a/ufm-test-services/metamask/pnpm-lock.yaml b/ufm-test-services/metamask/pnpm-lock.yaml index 12734e6daf228..99b1aa1b35ed4 100644 --- a/ufm-test-services/metamask/pnpm-lock.yaml +++ b/ufm-test-services/metamask/pnpm-lock.yaml @@ -80,7 +80,7 @@ packages: '@babel/helpers': 7.22.15 '@babel/parser': 7.22.16 '@babel/template': 7.22.15 - '@babel/traverse': 7.22.20 + '@babel/traverse': 7.23.2 '@babel/types': 7.22.19 convert-source-map: 1.9.0 debug: 4.3.4(supports-color@8.1.1) @@ -101,18 +101,28 @@ packages: jsesc: 2.5.2 dev: true + /@babel/generator@7.23.0: + resolution: {integrity: sha512-lN85QRR+5IbYrMWM6Y4pE/noaQtg4pNiqeNGX60eqOfo6gtEj6uw/JagelB8vVztSd7R6M5n1+PQkDbHbBRU4g==} + engines: {node: '>=6.9.0'} + dependencies: + '@babel/types': 7.23.0 + '@jridgewell/gen-mapping': 0.3.3 + '@jridgewell/trace-mapping': 0.3.19 + jsesc: 2.5.2 + dev: true + /@babel/helper-annotate-as-pure@7.22.5: resolution: {integrity: sha512-LvBTxu8bQSQkcyKOU+a1btnNFQ1dMAd0R6PyW3arXes06F6QLWLIrd681bxRPIXlrMGR3XYnW9JyML7dP3qgxg==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.22.19 + '@babel/types': 7.23.0 dev: true /@babel/helper-builder-binary-assignment-operator-visitor@7.22.15: resolution: {integrity: sha512-QkBXwGgaoC2GtGZRoma6kv7Szfv06khvhFav67ZExau2RaXzy8MpHSMO2PNoP2XtmQphJQRHFfg77Bq731Yizw==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.22.19 + '@babel/types': 7.23.0 dev: true /@babel/helper-compilation-targets@7.22.15: @@ -135,7 +145,7 @@ packages: '@babel/core': 7.22.20 '@babel/helper-annotate-as-pure': 7.22.5 '@babel/helper-environment-visitor': 7.22.20 - '@babel/helper-function-name': 7.22.5 + '@babel/helper-function-name': 7.23.0 '@babel/helper-member-expression-to-functions': 7.22.15 '@babel/helper-optimise-call-expression': 7.22.5 '@babel/helper-replace-supers': 7.22.20(@babel/core@7.22.20) @@ -176,26 +186,26 @@ packages: engines: {node: '>=6.9.0'} dev: true - /@babel/helper-function-name@7.22.5: - resolution: {integrity: sha512-wtHSq6jMRE3uF2otvfuD3DIvVhOsSNshQl0Qrd7qC9oQJzHvOL4qQXlQn2916+CXGywIjpGuIkoyZRRxHPiNQQ==} + /@babel/helper-function-name@7.23.0: + resolution: {integrity: sha512-OErEqsrxjZTJciZ4Oo+eoZqeW9UIiOcuYKRJA4ZAgV9myA+pOXhhmpfNCKjEH/auVfEYVFJ6y1Tc4r0eIApqiw==} engines: {node: '>=6.9.0'} dependencies: '@babel/template': 7.22.15 - '@babel/types': 7.22.19 + '@babel/types': 7.23.0 dev: true /@babel/helper-hoist-variables@7.22.5: resolution: {integrity: sha512-wGjk9QZVzvknA6yKIUURb8zY3grXCcOZt+/7Wcy8O2uctxhplmUPkOdlgoNhmdVee2c92JXbf1xpMtVNbfoxRw==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.22.19 + '@babel/types': 7.23.0 dev: true /@babel/helper-member-expression-to-functions@7.22.15: resolution: {integrity: sha512-qLNsZbgrNh0fDQBCPocSL8guki1hcPvltGDv/NxvUoABwFq7GkKSu1nRXeJkVZc+wJvne2E0RKQz+2SQrz6eAA==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.22.19 + '@babel/types': 7.23.0 dev: true /@babel/helper-module-imports@7.22.15: @@ -223,7 +233,7 @@ packages: resolution: {integrity: sha512-HBwaojN0xFRx4yIvpwGqxiV2tUfl7401jlok564NgB9EHS1y6QT17FmKWm4ztqjeVdXLuC4fSvHc5ePpQjoTbw==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.22.19 + '@babel/types': 7.23.0 dev: true /@babel/helper-plugin-utils@7.22.5: @@ -266,14 +276,14 @@ packages: resolution: {integrity: sha512-tK14r66JZKiC43p8Ki33yLBVJKlQDFoA8GYN67lWCDCqoL6EMMSuM9b+Iff2jHaM/RRFYl7K+iiru7hbRqNx8Q==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.22.19 + '@babel/types': 7.23.0 dev: true /@babel/helper-split-export-declaration@7.22.6: resolution: {integrity: sha512-AsUnxuLhRYsisFiaJwvp1QF+I3KjD5FOxut14q/GzovUe6orHLesW2C7d754kRm53h5gqrz6sFl6sxc4BVtE/g==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.22.19 + '@babel/types': 7.23.0 dev: true /@babel/helper-string-parser@7.22.5: @@ -295,9 +305,9 @@ packages: resolution: {integrity: sha512-pms/UwkOpnQe/PDAEdV/d7dVCoBbB+R4FvYoHGZz+4VPcg7RtYy2KP7S2lbuWM6FCSgob5wshfGESbC/hzNXZw==} engines: {node: '>=6.9.0'} dependencies: - '@babel/helper-function-name': 7.22.5 + '@babel/helper-function-name': 7.23.0 '@babel/template': 7.22.15 - '@babel/types': 7.22.19 + '@babel/types': 7.23.0 dev: true /@babel/helpers@7.22.15: @@ -305,7 +315,7 @@ packages: engines: {node: '>=6.9.0'} dependencies: '@babel/template': 7.22.15 - '@babel/traverse': 7.22.20 + '@babel/traverse': 7.23.2 '@babel/types': 7.22.19 transitivePeerDependencies: - supports-color @@ -328,6 +338,14 @@ packages: '@babel/types': 7.22.19 dev: true + /@babel/parser@7.23.0: + resolution: {integrity: sha512-vvPKKdMemU85V9WE/l5wZEmImpCtLqbnTvqDS2U1fJ96KrxoW7KrXhNsNCblQlg8Ck4b85yxdTyelsMUgFUXiw==} + engines: {node: '>=6.0.0'} + hasBin: true + dependencies: + '@babel/types': 7.23.0 + dev: true + /@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression@7.22.15(@babel/core@7.22.20): resolution: {integrity: sha512-FB9iYlz7rURmRJyXRKEnalYPPdn87H5no108cyuQQyMwlpJ2SJtpIUBI27kdTin956pz+LPypkPVPUTlxOmrsg==} engines: {node: '>=6.9.0'} @@ -616,7 +634,7 @@ packages: '@babel/helper-annotate-as-pure': 7.22.5 '@babel/helper-compilation-targets': 7.22.15 '@babel/helper-environment-visitor': 7.22.20 - '@babel/helper-function-name': 7.22.5 + '@babel/helper-function-name': 7.23.0 '@babel/helper-optimise-call-expression': 7.22.5 '@babel/helper-plugin-utils': 7.22.5 '@babel/helper-replace-supers': 7.22.20(@babel/core@7.22.20) @@ -717,7 +735,7 @@ packages: dependencies: '@babel/core': 7.22.20 '@babel/helper-compilation-targets': 7.22.15 - '@babel/helper-function-name': 7.22.5 + '@babel/helper-function-name': 7.23.0 '@babel/helper-plugin-utils': 7.22.5 dev: true @@ -1141,7 +1159,7 @@ packages: '@babel/plugin-transform-unicode-regex': 7.22.5(@babel/core@7.22.20) '@babel/plugin-transform-unicode-sets-regex': 7.22.5(@babel/core@7.22.20) '@babel/preset-modules': 0.1.6-no-external-plugins(@babel/core@7.22.20) - '@babel/types': 7.22.19 + '@babel/types': 7.23.0 babel-plugin-polyfill-corejs2: 0.4.5(@babel/core@7.22.20) babel-plugin-polyfill-corejs3: 0.8.3(@babel/core@7.22.20) babel-plugin-polyfill-regenerator: 0.5.2(@babel/core@7.22.20) @@ -1158,7 +1176,7 @@ packages: dependencies: '@babel/core': 7.22.20 '@babel/helper-plugin-utils': 7.22.5 - '@babel/types': 7.22.19 + '@babel/types': 7.23.0 esutils: 2.0.3 dev: true @@ -1186,22 +1204,22 @@ packages: engines: {node: '>=6.9.0'} dependencies: '@babel/code-frame': 7.22.13 - '@babel/parser': 7.22.16 - '@babel/types': 7.22.19 + '@babel/parser': 7.23.0 + '@babel/types': 7.23.0 dev: true - /@babel/traverse@7.22.20: - resolution: {integrity: sha512-eU260mPZbU7mZ0N+X10pxXhQFMGTeLb9eFS0mxehS8HZp9o1uSnFeWQuG1UPrlxgA7QoUzFhOnilHDp0AXCyHw==} + /@babel/traverse@7.23.2: + resolution: {integrity: sha512-azpe59SQ48qG6nu2CzcMLbxUudtN+dOM9kDbUqGq3HXUJRlo7i8fvPoxQUzYgLZ4cMVmuZgm8vvBpNeRhd6XSw==} engines: {node: '>=6.9.0'} dependencies: '@babel/code-frame': 7.22.13 - '@babel/generator': 7.22.15 + '@babel/generator': 7.23.0 '@babel/helper-environment-visitor': 7.22.20 - '@babel/helper-function-name': 7.22.5 + '@babel/helper-function-name': 7.23.0 '@babel/helper-hoist-variables': 7.22.5 '@babel/helper-split-export-declaration': 7.22.6 - '@babel/parser': 7.22.16 - '@babel/types': 7.22.19 + '@babel/parser': 7.23.0 + '@babel/types': 7.23.0 debug: 4.3.4(supports-color@8.1.1) globals: 11.12.0 transitivePeerDependencies: @@ -1217,6 +1235,15 @@ packages: to-fast-properties: 2.0.0 dev: true + /@babel/types@7.23.0: + resolution: {integrity: sha512-0oIyUfKoI3mSqMvsxBdclDwxXKXAUA8v/apZbc+iSyARYou1o8ZGDxbUYyLFoW2arqS2jDGqJuZvv1d/io1axg==} + engines: {node: '>=6.9.0'} + dependencies: + '@babel/helper-string-parser': 7.22.5 + '@babel/helper-validator-identifier': 7.22.20 + to-fast-properties: 2.0.0 + dev: true + /@colors/colors@1.5.0: resolution: {integrity: sha512-ooWCrlZP11i8GImSjTHYHLkvFDP48nS4+204nGb1RiX/WXYHmJA2III9/e2DWVabCESdW7hBAEzHRqUn9OUVvQ==} engines: {node: '>=0.1.90'}